Contents

UnitSpeed

A unit of measure for speed.

Declaration

class UnitSpeed

Overview

You typically use instances of UnitSpeed to represent specific quantities of speed using the NSMeasurement class.

Speed

Speed is the magnitude of velocity, or the rate of change of position. Speed can be expressed by SI derived units in terms of meters per second (m/s), and is also commonly expressed in terms of kilometers per hour (km/h) and miles per hour (mph).

The UnitSpeed class defines its baseUnit() as metersPerSecond, and provides the following units, which are initialized using UnitConverterLinear converters with the specified coefficients:

Name

Method

Symbol

Coefficient

Meters Per Second

Meterspersecond

m/s

1.0

Kilometers Per Hour

Kilometersperhour

km/h

0.277778

Miles Per Hour

Milesperhour

mph

0.44704

Knots

Knots

kn

0.514444

The base unit is metersPerSecond and is accessed via baseUnit() on the Dimension protocol.

Topics

Accessing the Base Unit

Accessing Predefined Units

Initializers

See Also

Time and Motion