UnitConvert

UnitConvert[quantity, targetunit]
attempts to convert the specified quantity to the specified targetunit.

UnitConvert[quantity]
converts the specified quantity to its base SI units.

DetailsDetails

  • The targetunit can be a canonical unit or a Quantity expression.
  • When targetunit is a Quantity, the resulting output will have the same unit as targetunit.
  • A targetunit specification can also be one of the following unit systems: , , , or .
  • An internet connection is required for conversion between currency units.
  • UnitConvert is Listable.

ExamplesExamplesopen allclose all

Basic Examples (2)Basic Examples (2)

Convert from miles to kilometers:

In[1]:=
Click for copyable input
Out[1]=

Convert a Quantity to the appropriate SI base unit:

In[1]:=
Click for copyable input
Out[1]=
In[2]:=
Click for copyable input
Out[2]=
New in 9
New to Mathematica? Find your learning path »
Have a question? Ask support »