Notation of unit objects

### 23.1.1 Notation of unit objects

A unit object has two parts: a real number and a unit expression (a single unit or a multiplicative combination of units). The two parts are linked by the character _ (“underscore”). For example 2_m for 2 meters. For composite units, parenthesis must be used, e.g. 1_(m*s). See Table 23.1 for a list of the basic units.

> _A | Ampere | _ha | Hectare
> _Angstrom | Angstrom | _hp | Horsepower
> _Bq | Becquerel | _in | Inch
> _Btu | Btu British thermal unit | _inH20 | Inches of water at 60° Fahrenheit
> _Ci | Curie | _inHg | Inches of mercury at 0° Celsius
> _F | Farad | _j | Day
> _Fdy | Faraday | _kWh | Kilowatt-hour
> _Gal | Gal (0.01 m/s2) | _kg | Kilogram
> _Gy | Gray | _kip | Kilopound-force
> _H | Henry | _km | Kilometre
> _Hz | Hertz | _knot | nautical miles per hour
> _J | Joule | _kph | Kilometers per hour
> _K | Kelvin | _l | Liter
> _Kcal | Kilocalorie | _lam | Lambert
> _MHz | Megahertz | _lb | pound (16 oz)
> _MW | Megawatt | _lbf | Pound-force
> _MeV | Megaelectronvolt | _lbmol | Pound-mole
> _N | Newton | _lbt | Troy pound
> _Ohm | Ohm | _lep | Liter of oil equivalent
> _P | Poise (measures viscosity) | _liqpt | US liquid pint (1 US gallon=8 US liquid pints)
> _Pa | Pascal | _lm | Lumen
> _R | Roentgen | _lx | Lux
> _Rankine | Degree Rankine | _lyr | Light year
> _S | Siemens | _m | Metre (unit)
> _St | Stokes | _mho | Mho
> _Sv | Sievert | _miUS | US statute mile
> _T | Tesla | _mi^2 | Square international mile.
> _V | Volt | _mil | Mil
> _W | Watt | _mile | International mile
> _Wb | Weber | _mille | Nautical mile
> _Wh | Watt-hour | _ml | millilitre
> _a | Are (100 m2) | _mm | Millimetre
> _acre | Acre | _mmHg | Millimeter of mercury (torr), 0 degree Celsius
> _arcmin | Minute of arc | _mn | Minute
> _arcs | Second of arc | _mol | Mole
> _atm | Atmosphere | _mph | Miles per hour
> _au | Astronomical unit | _oz | Ounce
> _b | Barn | _ozUK | UK fluid ounce
> _bar | Bar | _ozfl | US fluid ounce
> _bbl | Barrel | _ozt | Troy ounce
> _bblep | Barrel of oil equivalent | _pc | Parsec
> _bu | Bushel (8 UK gallons) | _pdl | Poundal (force)
> _buUS | American bushel | _ph | Phot
> _cal | Calorie | _pk | US peck
> _cd | Candela | _psi | Pounds per square inch
> _chain | Chain (66 feet or 22 yards) | _ptUK | UK pint (1 UK gallon=8 UK pints)
> _cm | Centimetre | _qt | Quart
> _ct | Carat | _rad | Radian
> _cu | US cup | _rd | Rad (0.01 Gy)
> _d | Day | _rem | Rem
> _dB | Decibel | _rod | Rod 1 (5.029215842 m)
> _deg | Degree (angle) | _rpm | Revolutions per minute
> _degreeF | Degree Fahrenheit | _s | Second
> _dyn | Dyne | _s | second
> _eV | Electron volt | _sb | Stilb
> _erg | Erg | _slug | Slug
> _fath | Fathom | _sr | Steradian
> _fbm | Board foot | _st | Stere
> _fc | Footcandle (≈ 10.764 lux) | _t | Metric ton
> _fermi | Fermi | _tbsp | Tablespoon
> _flam | Footlambert | _tec | Tonne of coal equivalent
> _fm | Fathom | _tep | Tonne of oil equivalent
> _ft | International foot | _tex | tex (10−6 kg/m)
> _ftUS | Survey foot | _therm | EEC therm
> _g | Gram | _ton | Short ton (2000 pounds)
> _ga | Standard freefall | _tonUK | Long (UK) ton
> _galC | Canadian gallon | _torr | Torr (mmHg)
> _galUK | UK gallon | _tr | tour (2π rad)
> _galUS | US gallon | _tsp | Teaspoon
> _gf | Gram-force | _u | Atomic mass unit
> _gmol | Gram-mole | _yd | International yard
> _gon | Grade | _yr | Year
> _grad | Grade | _h | Hour
> _grain | Grain (≈ 0,0648 grams) | _µ | Micron

> Table 23.1: Physical units in Xcas

If a prefix is put before the unit then the unit is multiplied by a power of 10. For example, the prefix k or K, for kilo, indicates multiplication by 103. See Table 23.2 for a list of the unit prefixes.

> Prefix | Name | (*10^) n | Prefix | Name | (*10^) n
> Y | yota | 24 | d | deci | −1
> Z | zeta | 21 | c | cent | −2
> E | exa | 18 | m | mili | −3
> P | peta | 15 | µ | micro | −6
> T | tera | 12 | n | nano | −9
> G | giga | 9 | p | pico | −12
> M | mega | 6 | f | femto | −15
> k or K | kilo | 3 | a | atto | −18
> h or H | hecto | 2 | z | zepto | −21
> D | deca | 1 | y | yocto | −24

> Table 23.2: Unit prefixes in Xcas

You cannot use a prefix with a built-in unit if the result gives another built-in unit.

For example, 1_a is one are, but 1_Pa is one pascal and not 10^15_a.

#### Examples

10.5_m

10.5 m |  |  |  |  |  |  |  |  |  |

which is a unit object of value 10.5 meters.

10.5_km

10.5 km |  |  |  |  |  |  |  |  |  |

which is a unit object of value 10.5 kilometers.