fork/numbat

git clone https://git.julia.blue/fork/numbat

David PeterMove assertions out of preludefee8e90

v1.6.0
745 B40 linesraw
1use units::si
2use units::imperial
3
4# US liquid gallon
5@aliases(gallons, gal: short)
6unit gallon: Volume = 231 in^3
7
8# US liquid pint
9@aliases(pints)
10unit pint: Volume = 1/8 × gallon
11
12# US cup
13@aliases(cups)
14unit cup: Volume = 1/2 × pint
15
16# US tablespoon
17@aliases(tablespoons, tbsp)
18unit tablespoon: Volume = 1/16 × cup
19
20# US teaspoon
21@aliases(teaspoons, tsp)
22unit teaspoon: Volume = 1/3 × tablespoon
23
24# US fluid ounce
25@aliases(fluidounces, floz: short)
26unit fluidounce: Volume = 2 tablespoon
27
28# US hogshead
29@aliases(hogsheads)
30unit hogshead: Volume = 63 gallon
31
32# US rod
33@aliases(rods, perch)
34unit rod: Length = 16.5 ft
35
36@aliases(acres)
37unit acre: Area = 4840 yard^2
38
39# Mileage, miles per gallon
40unit mpg: Length / Volume = miles per gallon