ianmackenzie / elm-units / Force

A Force value represents a force in newtons, pounds force etc. It is stored as a number of newtons.

Note that since Newtons is defined as Product Kilograms MetersPerSecondSquared, you can compute force directly as a product of mass and acceleration:

mass =
    Mass.kilograms 10

acceleration =
    Acceleration.metersPerSecondSquared 2

mass |> Quantity.times acceleration
--> Force.newtons 20


type alias Force =
Quantity Basics.Float Newtons


type alias Newtons =
Quantity.Product Mass.Kilograms Acceleration.MetersPerSecondSquared

Metric

newtons : Basics.Float -> Force

Construct a force value from a number of newtons.

inNewtons : Force -> Basics.Float

Convert a force value to a number of newtons.

kilonewtons : Basics.Float -> Force

Construct a force value from a number of kilonewtons.

inKilonewtons : Force -> Basics.Float

Convert a force value to a number of kilonewtons.

meganewtons : Basics.Float -> Force

Construct a force value from a number of meganewtons.

inMeganewtons : Force -> Basics.Float

Convert a force value to a number of meganewtons.

Imperial

pounds : Basics.Float -> Force

Construct a force value from a number of pounds force. One pound force is the force required to accelerate one pound mass at a rate of one gee.

inPounds : Force -> Basics.Float

Convert a force value to a number of pounds force.

kips : Basics.Float -> Force

Construct a force value from a number of kips (kilopounds force).

Force.kips 2
--> Force.pounds 2000

inKips : Force -> Basics.Float

Convert a force value to a number of kips.