Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
manual:chapter3:units [2019/09/14 07:03] jojo1973 Fixed some typos and capitalization |
manual:chapter3:units [2019/11/19 13:34] (current) claudio [Custom Units] |
||
---|---|---|---|
Line 22: | Line 22: | ||
Exponents within a unit expression can be integer numbers, real numbers or fractional exponents. The use of fractional exponents is always preferred over real numbers because they can be simplified in an exact way. \\ | Exponents within a unit expression can be integer numbers, real numbers or fractional exponents. The use of fractional exponents is always preferred over real numbers because they can be simplified in an exact way. \\ | ||
'' | '' | ||
+ | |||
+ | ==== Multiples and Submultiples ==== | ||
+ | |||
+ | Multiples and submultiples of many units are obtained by prefixing them with the standard SI prefixes. Therefore, '' | ||
+ | |||
+ | SI prefixes can be used with all SI units and many non-SI units where SI prefixes are common usage. Other non-SI units do not accept prefixes. | ||
+ | |||
+ | ^ SI Prefix | ||
+ | | Y | ||
+ | | Z | ||
+ | | E | ||
+ | | P | ||
+ | | T | ||
+ | | G | ||
+ | | M | ||
+ | | k | ||
+ | | h | ||
+ | | da | $10^{1}$ | ||
+ | | d | ||
+ | | c | ||
+ | | m | ||
+ | | µ | ||
+ | | n | ||
+ | | p | ||
+ | | f | ||
+ | | a | ||
+ | | z | ||
+ | | y | ||
==== Operating with Units ==== | ==== Operating with Units ==== | ||
Line 34: | Line 62: | ||
To extract the value part of a unit object, use the '' | To extract the value part of a unit object, use the '' | ||
+ | |||
==== Custom Units ==== | ==== Custom Units ==== | ||
Units in newRPL can be arbitrary symbols, not just the ones predefined in the system. For example, adding '' | Units in newRPL can be arbitrary symbols, not just the ones predefined in the system. For example, adding '' | ||
- | Custom units can also be defined as derived units, in terms of other base units. This is done with the '' | + | Custom units can also be defined as derived units, in terms of other base units. This is done with the '' |
- | New units can also be defined in terms of new (unknown) base units. For example typing '' | + | Custom units may also accept SI prefixes, but this needs to be explicitly enabled during the unit definition. To create a custom unit that accepts SI prefixes, the name of the unit needs to be preceded by a question mark ''?'' |
+ | |||
+ | New units can also be defined in terms of new (unknown) base units. For example typing '' | ||
From that moment the addition '' | From that moment the addition '' | ||
Line 48: | Line 79: | ||
==== Available Units ==== | ==== Available Units ==== | ||
- | This is a list of the units available in the '' | + | This is a list of the units available in the '' |
+ | |||
+ | === Length === | ||
- | | **Length** |||| | + | ^ Unit ^ Unit name ^ Definition |
- | | Unit | Unit name | Definition | + | | 1_m | metre | 1_m | Base SI unit of length |
- | | 1_m | metre | 1_m | Base SI unit of length | | + | | 1_cm | centimetre | 1_cm = 0.01_m | SI, metric | {{fa> |
- | | 1_cm | centimetre | 1_cm = 0.01_m | SI length | + | | 1_mm | millimetre | 1_mm = 0.001_m | SI, metric | {{fa> |
- | | 1_mm | millimetre | 1_mm = 0.001_m | SI length | + | | 1_yd | yard | 1_yd = 3_ft | US Customary | {{fa> |
- | | 1_yd | yard | 1_yd = 3_ft | US customary length | + | | 1_ft | foot | 1_ft = 12_in | US Customary | {{fa> |
- | | 1_ft | foot | 1_ft = 12_in | US customary length | + | | 1_in | inch | 1_in = 0.0254_m | US Customary | {{fa> |
- | | 1_in | inch | 1_in = 0.0254_m | US customary length | + | | 1_Mpc | megaparsec | 1_Mpc = 1000000_pc | Astronomical length |
- | | 1_Mpc | megaparsec | 1_Mpc = 1000000_pc | Astronomical length | | + | | 1_pc | parsec | 1_pc = (648000/ |
- | | 1_pc | parsec | 1_pc = (648000/ | + | | 1_lyr | light year | 1_lyr = 9460730472580800_m |
- | | 1_lyr | light year | 1_lyr = 365.25_d*c | + | | 1_au | astronomical unit | 1_au = 149597870700_m | SI astronomical length |
- | | 1_au | astronomical unit | 1_au = 149597870700_m | SI astronomical length | | + | | 1_km | kilometre | 1_km = 1000_m | SI, metric | {{fa> |
- | | 1_km | kilometre | 1_km = 1000_m | SI length | + | | 1_mi | mile | 1_mi = 5280_ft | US Customary | {{fa> |
- | | 1_mi | mile | 1_mi = 5280_ft | US customary length | + | | 1_nmi | nautical mile | 1_nmi = 1852_m | non-SI length |
- | | 1_nmi | nautical mile | 1_nmi = 1852_m | non-SI length | | + | | 1_miUS | surveying mile | 1_miUS = 5280_ftUS | US surveying length |
- | | 1_miUS | surveying mile | 1_miUS = 5280_ftUS | US surveying length | | + | | 1_chain | surveying chain | 1_chain = 66_ftUS | US surveying length |
- | | 1_chain | surveying chain | 1_chain = 66_ftUS | US surveying length | | + | | 1_rd | rod | 1_rd =16.5_ft | US customary length |
- | | 1_rd | rod | 1_rd =16.5_ft | US customary length | | + | | 1_rdUS | surveying rod | 1_rdUS =16.5_ftUS | US surveying length |
- | | 1_rdUS | surveying rod | 1_rdUS =16.5_ftUS | US surveying length | | + | | 1_fath | surveying fathom | 1_fath =6_ftUS | US surveying length |
- | | 1_fath | surveying fathom | 1_fath =6_ftUS | US surveying length | | + | | 1_ftUS | surveying foot | 1_ftUS = 1200/3937_m | US surveying length |
- | | 1_ftUS | surveying foot | 1_ftUS = 1200/3937_m | US surveying length | | + | | 1_mil | thousandth of inch | 1_mil = 0.001_in | US customary length |
- | | 1_mil | thousandth of inch | 1_mil = 0.001_in | US customary length | | + | | 1_µ | micron | 1_µ = 1_µm | SI length |
- | | 1_µ | micron | 1_µ = 1_µm | SI length | | + | | 1_Å | ångström | 1_Å = 0.1_nm | non-SI length |
- | | 1_Å | ångström | 1_Å = 0.1_nm | non-SI length | | + | | 1_fermi | fermi | 1_fermi = 1_fm | SI length |
- | | 1_fermi | fermi | 1_fermi = 1_fm | SI length | | + | |
| **Area** |||| | | **Area** |||| |