MadsKirkFoged / EngineeringUnits

Working with units made easy with automatic unit-check and converting between units
MIT License
41 stars 10 forks source link

New Unit JERK #32

Closed rjs5327 closed 8 months ago

rjs5327 commented 11 months ago

Need to add JERK, it is the same as Acceleration but time is cubed. This is used in motion profiling and anywhere there is a linear change in Acceleration and Parabolic change in Velocity.

MadsKirkFoged commented 10 months ago

Hi @rjs5327

I have added the unit JERK. You can now use it like any other unit:

Jerk jerk1 = new Jerk(10, JerkUnit.MeterPerSecondCubed);
Jerk jerk2 = Jerk.FromCentimeterPerSecondCubed(10);
Jerk jerk3 = Length.FromMeter(2) / Duration.FromSecond(10).Pow(3);

Jerk jerk4 = jerk1 + jerk2 +jerk3;

Let me know if this works as you expected?