 Standard Units Environment - Maple Programming Help

Home : Support : Online Help : Applications and Example Worksheets : Language and System : examples/StandardUnits

Standard Units Environment

The Standard Units environment is an environment designed for computations with units.  This environment is set up by using the command with(Units[Standard]), or alternatively by using the commands Units[UseMode](standard) and with(Units), in that order.

Various procedures are overloaded to handle units. For example, $\mathrm{sin}\left(3.0⟦\mathrm{degrees}⟧\right)$ evaluates the sine of 3 degrees and $\mathrm{max}\left(4⟦m⟧,10⟦\mathrm{ft}⟧\right)$  returns $4⟦m⟧$.

Arithmetic operators are overloaded to extract units from their operands.  For example, $3⟦m⟧+4⟦\mathrm{cm}⟧$ evaluates to $\frac{76}{25}⟦m⟧$ and  evaluates to $11.39316239⟦\frac{m}{s}⟧$, which can be converted to $25.48577843⟦\mathrm{mph}⟧$.

Note:  Although easier to use, it is slower, in general, to perform computations in the Standard Units environment than to use the conversion routines at the top-level.

These computations can also be done in the Simple Units environment or the Natural Units environment or at the top-level by using only conversion routines (see Default Units). Each example in this worksheet is also in the other worksheets to show how you can perform the computations in the other environments.

 > $\mathrm{restart}$
 > $\mathrm{with}\left(\mathrm{Units}\left[\mathrm{Standard}\right]\right):$