#[derive(Debug)]
pub(crate) struct Unit {
pub abbr: &'static str,
pub measure: &'static str,
pub system: &'static str,
pub singular: &'static str,
pub plural: &'static str,
pub to_anchor: f64,
pub anchor_shift: f64,
}
pub(crate) static UNITS: &[Unit] = &[
Unit {
abbr: "mm",
measure: "length",
system: "metric",
singular: "Millimeter",
plural: "Millimeters",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "cm",
measure: "length",
system: "metric",
singular: "Centimeter",
plural: "Centimeters",
to_anchor: 0.01,
anchor_shift: 0.0,
},
Unit {
abbr: "m",
measure: "length",
system: "metric",
singular: "Meter",
plural: "Meters",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "km",
measure: "length",
system: "metric",
singular: "Kilometer",
plural: "Kilometers",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "in",
measure: "length",
system: "imperial",
singular: "Inch",
plural: "Inches",
to_anchor: 0.08333333333333333,
anchor_shift: 0.0,
},
Unit {
abbr: "yd",
measure: "length",
system: "imperial",
singular: "Yard",
plural: "Yards",
to_anchor: 3.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ft-us",
measure: "length",
system: "imperial",
singular: "US Survey Foot",
plural: "US Survey Feet",
to_anchor: 1.000002,
anchor_shift: 0.0,
},
Unit {
abbr: "ft",
measure: "length",
system: "imperial",
singular: "Foot",
plural: "Feet",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mi",
measure: "length",
system: "imperial",
singular: "Mile",
plural: "Miles",
to_anchor: 5280.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mm2",
measure: "area",
system: "metric",
singular: "Square Millimeter",
plural: "Square Millimeters",
to_anchor: 0.000001,
anchor_shift: 0.0,
},
Unit {
abbr: "cm2",
measure: "area",
system: "metric",
singular: "Centimeter",
plural: "Centimeters",
to_anchor: 0.0001,
anchor_shift: 0.0,
},
Unit {
abbr: "m2",
measure: "area",
system: "metric",
singular: "Square Meter",
plural: "Square Meters",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ha",
measure: "area",
system: "metric",
singular: "Hectare",
plural: "Hectares",
to_anchor: 10000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "km2",
measure: "area",
system: "metric",
singular: "Square Kilometer",
plural: "Square Kilometers",
to_anchor: 1000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "in2",
measure: "area",
system: "imperial",
singular: "Square Inch",
plural: "Square Inches",
to_anchor: 0.006944444444444444,
anchor_shift: 0.0,
},
Unit {
abbr: "yd2",
measure: "area",
system: "imperial",
singular: "Square Yard",
plural: "Square Yards",
to_anchor: 9.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ft2",
measure: "area",
system: "imperial",
singular: "Square Foot",
plural: "Square Feet",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ac",
measure: "area",
system: "imperial",
singular: "Acre",
plural: "Acres",
to_anchor: 43560.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mi2",
measure: "area",
system: "imperial",
singular: "Square Mile",
plural: "Square Miles",
to_anchor: 27878400.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mcg",
measure: "mass",
system: "metric",
singular: "Microgram",
plural: "Micrograms",
to_anchor: 0.000001,
anchor_shift: 0.0,
},
Unit {
abbr: "mg",
measure: "mass",
system: "metric",
singular: "Milligram",
plural: "Milligrams",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "g",
measure: "mass",
system: "metric",
singular: "Gram",
plural: "Grams",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "kg",
measure: "mass",
system: "metric",
singular: "Kilogram",
plural: "Kilograms",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mt",
measure: "mass",
system: "metric",
singular: "Metric Tonne",
plural: "Metric Tonnes",
to_anchor: 1000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "oz",
measure: "mass",
system: "imperial",
singular: "Ounce",
plural: "Ounces",
to_anchor: 0.0625,
anchor_shift: 0.0,
},
Unit {
abbr: "lb",
measure: "mass",
system: "imperial",
singular: "Pound",
plural: "Pounds",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "t",
measure: "mass",
system: "imperial",
singular: "Ton",
plural: "Tons",
to_anchor: 2000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mm3",
measure: "volume",
system: "metric",
singular: "Cubic Millimeter",
plural: "Cubic Millimeters",
to_anchor: 0.000001,
anchor_shift: 0.0,
},
Unit {
abbr: "cm3",
measure: "volume",
system: "metric",
singular: "Cubic Centimeter",
plural: "Cubic Centimeters",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "ml",
measure: "volume",
system: "metric",
singular: "Millilitre",
plural: "Millilitres",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "cl",
measure: "volume",
system: "metric",
singular: "Centilitre",
plural: "Centilitres",
to_anchor: 0.01,
anchor_shift: 0.0,
},
Unit {
abbr: "dl",
measure: "volume",
system: "metric",
singular: "Decilitre",
plural: "Decilitres",
to_anchor: 0.1,
anchor_shift: 0.0,
},
Unit {
abbr: "l",
measure: "volume",
system: "metric",
singular: "Litre",
plural: "Litres",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "kl",
measure: "volume",
system: "metric",
singular: "Kilolitre",
plural: "Kilolitres",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "m3",
measure: "volume",
system: "metric",
singular: "Cubic meter",
plural: "Cubic meters",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "km3",
measure: "volume",
system: "metric",
singular: "Cubic kilometer",
plural: "Cubic kilometers",
to_anchor: 1000000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "krm",
measure: "volume",
system: "metric",
singular: "Matsked",
plural: "Matskedar",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "tsk",
measure: "volume",
system: "metric",
singular: "Tesked",
plural: "Teskedar",
to_anchor: 0.005,
anchor_shift: 0.0,
},
Unit {
abbr: "msk",
measure: "volume",
system: "metric",
singular: "Matsked",
plural: "Matskedar",
to_anchor: 0.015,
anchor_shift: 0.0,
},
Unit {
abbr: "kkp",
measure: "volume",
system: "metric",
singular: "Kaffekopp",
plural: "Kaffekoppar",
to_anchor: 0.15,
anchor_shift: 0.0,
},
Unit {
abbr: "glas",
measure: "volume",
system: "metric",
singular: "Glas",
plural: "Glas",
to_anchor: 0.2,
anchor_shift: 0.0,
},
Unit {
abbr: "kanna",
measure: "volume",
system: "metric",
singular: "Kanna",
plural: "Kannor",
to_anchor: 2.617,
anchor_shift: 0.0,
},
Unit {
abbr: "tsp",
measure: "volume",
system: "imperial",
singular: "Teaspoon",
plural: "Teaspoons",
to_anchor: 0.16666666666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "Tbs",
measure: "volume",
system: "imperial",
singular: "Tablespoon",
plural: "Tablespoons",
to_anchor: 0.5,
anchor_shift: 0.0,
},
Unit {
abbr: "in3",
measure: "volume",
system: "imperial",
singular: "Cubic inch",
plural: "Cubic inches",
to_anchor: 0.55411,
anchor_shift: 0.0,
},
Unit {
abbr: "fl-oz",
measure: "volume",
system: "imperial",
singular: "Fluid Ounce",
plural: "Fluid Ounces",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "cup",
measure: "volume",
system: "imperial",
singular: "Cup",
plural: "Cups",
to_anchor: 8.0,
anchor_shift: 0.0,
},
Unit {
abbr: "pnt",
measure: "volume",
system: "imperial",
singular: "Pint",
plural: "Pints",
to_anchor: 16.0,
anchor_shift: 0.0,
},
Unit {
abbr: "qt",
measure: "volume",
system: "imperial",
singular: "Quart",
plural: "Quarts",
to_anchor: 32.0,
anchor_shift: 0.0,
},
Unit {
abbr: "gal",
measure: "volume",
system: "imperial",
singular: "Gallon",
plural: "Gallons",
to_anchor: 128.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ft3",
measure: "volume",
system: "imperial",
singular: "Cubic foot",
plural: "Cubic feet",
to_anchor: 957.506,
anchor_shift: 0.0,
},
Unit {
abbr: "yd3",
measure: "volume",
system: "imperial",
singular: "Cubic yard",
plural: "Cubic yards",
to_anchor: 25852.7,
anchor_shift: 0.0,
},
Unit {
abbr: "ea",
measure: "each",
system: "metric",
singular: "Each",
plural: "Each",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "dz",
measure: "each",
system: "metric",
singular: "Dozen",
plural: "Dozens",
to_anchor: 12.0,
anchor_shift: 0.0,
},
Unit {
abbr: "C",
measure: "temperature",
system: "metric",
singular: "degree Celsius",
plural: "degrees Celsius",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "K",
measure: "temperature",
system: "metric",
singular: "degree Kelvin",
plural: "degrees Kelvin",
to_anchor: 1.0,
anchor_shift: 273.15,
},
Unit {
abbr: "F",
measure: "temperature",
system: "imperial",
singular: "degree Fahrenheit",
plural: "degrees Fahrenheit",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "R",
measure: "temperature",
system: "imperial",
singular: "degree Rankine",
plural: "degrees Rankine",
to_anchor: 1.0,
anchor_shift: 459.67,
},
Unit {
abbr: "ns",
measure: "time",
system: "metric",
singular: "Nanosecond",
plural: "Nanoseconds",
to_anchor: 1e-9,
anchor_shift: 0.0,
},
Unit {
abbr: "mu",
measure: "time",
system: "metric",
singular: "Microsecond",
plural: "Microseconds",
to_anchor: 0.000001,
anchor_shift: 0.0,
},
Unit {
abbr: "ms",
measure: "time",
system: "metric",
singular: "Millisecond",
plural: "Milliseconds",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "s",
measure: "time",
system: "metric",
singular: "Second",
plural: "Seconds",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "min",
measure: "time",
system: "metric",
singular: "Minute",
plural: "Minutes",
to_anchor: 60.0,
anchor_shift: 0.0,
},
Unit {
abbr: "h",
measure: "time",
system: "metric",
singular: "Hour",
plural: "Hours",
to_anchor: 3600.0,
anchor_shift: 0.0,
},
Unit {
abbr: "d",
measure: "time",
system: "metric",
singular: "Day",
plural: "Days",
to_anchor: 86400.0,
anchor_shift: 0.0,
},
Unit {
abbr: "week",
measure: "time",
system: "metric",
singular: "Week",
plural: "Weeks",
to_anchor: 604800.0,
anchor_shift: 0.0,
},
Unit {
abbr: "month",
measure: "time",
system: "metric",
singular: "Month",
plural: "Months",
to_anchor: 2629800.0,
anchor_shift: 0.0,
},
Unit {
abbr: "year",
measure: "time",
system: "metric",
singular: "Year",
plural: "Years",
to_anchor: 31557600.0,
anchor_shift: 0.0,
},
Unit {
abbr: "b",
measure: "digital",
system: "bits",
singular: "Bit",
plural: "Bits",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "Kb",
measure: "digital",
system: "bits",
singular: "Kilobit",
plural: "Kilobits",
to_anchor: 1024.0,
anchor_shift: 0.0,
},
Unit {
abbr: "Mb",
measure: "digital",
system: "bits",
singular: "Megabit",
plural: "Megabits",
to_anchor: 1048576.0,
anchor_shift: 0.0,
},
Unit {
abbr: "Gb",
measure: "digital",
system: "bits",
singular: "Gigabit",
plural: "Gigabits",
to_anchor: 1073741824.0,
anchor_shift: 0.0,
},
Unit {
abbr: "Tb",
measure: "digital",
system: "bits",
singular: "Terabit",
plural: "Terabits",
to_anchor: 1099511627776.0,
anchor_shift: 0.0,
},
Unit {
abbr: "B",
measure: "digital",
system: "bytes",
singular: "Byte",
plural: "Bytes",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "KB",
measure: "digital",
system: "bytes",
singular: "Kilobyte",
plural: "Kilobytes",
to_anchor: 1024.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MB",
measure: "digital",
system: "bytes",
singular: "Megabyte",
plural: "Megabytes",
to_anchor: 1048576.0,
anchor_shift: 0.0,
},
Unit {
abbr: "GB",
measure: "digital",
system: "bytes",
singular: "Gigabyte",
plural: "Gigabytes",
to_anchor: 1073741824.0,
anchor_shift: 0.0,
},
Unit {
abbr: "TB",
measure: "digital",
system: "bytes",
singular: "Terabyte",
plural: "Terabytes",
to_anchor: 1099511627776.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ppm",
measure: "partsPer",
system: "metric",
singular: "Part-per Million",
plural: "Parts-per Million",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ppb",
measure: "partsPer",
system: "metric",
singular: "Part-per Billion",
plural: "Parts-per Billion",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "ppt",
measure: "partsPer",
system: "metric",
singular: "Part-per Trillion",
plural: "Parts-per Trillion",
to_anchor: 0.000001,
anchor_shift: 0.0,
},
Unit {
abbr: "ppq",
measure: "partsPer",
system: "metric",
singular: "Part-per Quadrillion",
plural: "Parts-per Quadrillion",
to_anchor: 1e-9,
anchor_shift: 0.0,
},
Unit {
abbr: "m/s",
measure: "speed",
system: "metric",
singular: "Metre per second",
plural: "Metres per second",
to_anchor: 3.6,
anchor_shift: 0.0,
},
Unit {
abbr: "km/h",
measure: "speed",
system: "metric",
singular: "Kilometre per hour",
plural: "Kilometres per hour",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "m/h",
measure: "speed",
system: "imperial",
singular: "Mile per hour",
plural: "Miles per hour",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "knot",
measure: "speed",
system: "imperial",
singular: "Knot",
plural: "Knots",
to_anchor: 1.150779,
anchor_shift: 0.0,
},
Unit {
abbr: "ft/s",
measure: "speed",
system: "imperial",
singular: "Foot per second",
plural: "Feet per second",
to_anchor: 0.681818,
anchor_shift: 0.0,
},
Unit {
abbr: "min/km",
measure: "pace",
system: "metric",
singular: "Minute per kilometre",
plural: "Minutes per kilometre",
to_anchor: 0.06,
anchor_shift: 0.0,
},
Unit {
abbr: "s/m",
measure: "pace",
system: "metric",
singular: "Second per metre",
plural: "Seconds per metre",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "min/mi",
measure: "pace",
system: "imperial",
singular: "Minute per mile",
plural: "Minutes per mile",
to_anchor: 0.0113636,
anchor_shift: 0.0,
},
Unit {
abbr: "s/ft",
measure: "pace",
system: "imperial",
singular: "Second per foot",
plural: "Seconds per foot",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "Pa",
measure: "pressure",
system: "metric",
singular: "pascal",
plural: "pascals",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "kPa",
measure: "pressure",
system: "metric",
singular: "kilopascal",
plural: "kilopascals",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MPa",
measure: "pressure",
system: "metric",
singular: "megapascal",
plural: "megapascals",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "hPa",
measure: "pressure",
system: "metric",
singular: "hectopascal",
plural: "hectopascals",
to_anchor: 0.1,
anchor_shift: 0.0,
},
Unit {
abbr: "bar",
measure: "pressure",
system: "metric",
singular: "bar",
plural: "bar",
to_anchor: 100.0,
anchor_shift: 0.0,
},
Unit {
abbr: "torr",
measure: "pressure",
system: "metric",
singular: "torr",
plural: "torr",
to_anchor: 0.13332236842105263,
anchor_shift: 0.0,
},
Unit {
abbr: "psi",
measure: "pressure",
system: "imperial",
singular: "pound per square inch",
plural: "pounds per square inch",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "ksi",
measure: "pressure",
system: "imperial",
singular: "kilopound per square inch",
plural: "kilopound per square inch",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "A",
measure: "current",
system: "metric",
singular: "Ampere",
plural: "Amperes",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mA",
measure: "current",
system: "metric",
singular: "Milliampere",
plural: "Milliamperes",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "kA",
measure: "current",
system: "metric",
singular: "Kiloampere",
plural: "Kiloamperes",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "V",
measure: "voltage",
system: "metric",
singular: "Volt",
plural: "Volts",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mV",
measure: "voltage",
system: "metric",
singular: "Millivolt",
plural: "Millivolts",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "kV",
measure: "voltage",
system: "metric",
singular: "Kilovolt",
plural: "Kilovolts",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "W",
measure: "power",
system: "metric",
singular: "Watt",
plural: "Watts",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mW",
measure: "power",
system: "metric",
singular: "Milliwatt",
plural: "Milliwatts",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "kW",
measure: "power",
system: "metric",
singular: "Kilowatt",
plural: "Kilowatts",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MW",
measure: "power",
system: "metric",
singular: "Megawatt",
plural: "Megawatts",
to_anchor: 1000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "GW",
measure: "power",
system: "metric",
singular: "Gigawatt",
plural: "Gigawatts",
to_anchor: 1000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "VAR",
measure: "reactivePower",
system: "metric",
singular: "Volt-Ampere Reactive",
plural: "Volt-Amperes Reactive",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mVAR",
measure: "reactivePower",
system: "metric",
singular: "Millivolt-Ampere Reactive",
plural: "Millivolt-Amperes Reactive",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "kVAR",
measure: "reactivePower",
system: "metric",
singular: "Kilovolt-Ampere Reactive",
plural: "Kilovolt-Amperes Reactive",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MVAR",
measure: "reactivePower",
system: "metric",
singular: "Megavolt-Ampere Reactive",
plural: "Megavolt-Amperes Reactive",
to_anchor: 1000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "GVAR",
measure: "reactivePower",
system: "metric",
singular: "Gigavolt-Ampere Reactive",
plural: "Gigavolt-Amperes Reactive",
to_anchor: 1000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "VA",
measure: "apparentPower",
system: "metric",
singular: "Volt-Ampere",
plural: "Volt-Amperes",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mVA",
measure: "apparentPower",
system: "metric",
singular: "Millivolt-Ampere",
plural: "Millivolt-Amperes",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "kVA",
measure: "apparentPower",
system: "metric",
singular: "Kilovolt-Ampere",
plural: "Kilovolt-Amperes",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MVA",
measure: "apparentPower",
system: "metric",
singular: "Megavolt-Ampere",
plural: "Megavolt-Amperes",
to_anchor: 1000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "GVA",
measure: "apparentPower",
system: "metric",
singular: "Gigavolt-Ampere",
plural: "Gigavolt-Amperes",
to_anchor: 1000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "Wh",
measure: "energy",
system: "metric",
singular: "Watt-hour",
plural: "Watt-hours",
to_anchor: 3600.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mWh",
measure: "energy",
system: "metric",
singular: "Milliwatt-hour",
plural: "Milliwatt-hours",
to_anchor: 3.6,
anchor_shift: 0.0,
},
Unit {
abbr: "kWh",
measure: "energy",
system: "metric",
singular: "Kilowatt-hour",
plural: "Kilowatt-hours",
to_anchor: 3600000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MWh",
measure: "energy",
system: "metric",
singular: "Megawatt-hour",
plural: "Megawatt-hours",
to_anchor: 3600000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "GWh",
measure: "energy",
system: "metric",
singular: "Gigawatt-hour",
plural: "Gigawatt-hours",
to_anchor: 3600000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "J",
measure: "energy",
system: "metric",
singular: "Joule",
plural: "Joules",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "kJ",
measure: "energy",
system: "metric",
singular: "Kilojoule",
plural: "Kilojoules",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "VARh",
measure: "reactiveEnergy",
system: "metric",
singular: "Volt-Ampere Reactive Hour",
plural: "Volt-Amperes Reactive Hour",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mVARh",
measure: "reactiveEnergy",
system: "metric",
singular: "Millivolt-Ampere Reactive Hour",
plural: "Millivolt-Amperes Reactive Hour",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "kVARh",
measure: "reactiveEnergy",
system: "metric",
singular: "Kilovolt-Ampere Reactive Hour",
plural: "Kilovolt-Amperes Reactive Hour",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MVARh",
measure: "reactiveEnergy",
system: "metric",
singular: "Megavolt-Ampere Reactive Hour",
plural: "Megavolt-Amperes Reactive Hour",
to_anchor: 1000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "GVARh",
measure: "reactiveEnergy",
system: "metric",
singular: "Gigavolt-Ampere Reactive Hour",
plural: "Gigavolt-Amperes Reactive Hour",
to_anchor: 1000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mm3/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Cubic Millimeter per second",
plural: "Cubic Millimeters per second",
to_anchor: 0.000001,
anchor_shift: 0.0,
},
Unit {
abbr: "cm3/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Cubic Centimeter per second",
plural: "Cubic Centimeters per second",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "ml/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Millilitre per second",
plural: "Millilitres per second",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "cl/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Centilitre per second",
plural: "Centilitres per second",
to_anchor: 0.01,
anchor_shift: 0.0,
},
Unit {
abbr: "dl/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Decilitre per second",
plural: "Decilitres per second",
to_anchor: 0.1,
anchor_shift: 0.0,
},
Unit {
abbr: "l/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Litre per second",
plural: "Litres per second",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "l/min",
measure: "volumeFlowRate",
system: "metric",
singular: "Litre per minute",
plural: "Litres per minute",
to_anchor: 0.016666666666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "l/h",
measure: "volumeFlowRate",
system: "metric",
singular: "Litre per hour",
plural: "Litres per hour",
to_anchor: 0.0002777777777777778,
anchor_shift: 0.0,
},
Unit {
abbr: "kl/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Kilolitre per second",
plural: "Kilolitres per second",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "kl/min",
measure: "volumeFlowRate",
system: "metric",
singular: "Kilolitre per minute",
plural: "Kilolitres per minute",
to_anchor: 16.666666666666668,
anchor_shift: 0.0,
},
Unit {
abbr: "kl/h",
measure: "volumeFlowRate",
system: "metric",
singular: "Kilolitre per hour",
plural: "Kilolitres per hour",
to_anchor: 0.2777777777777778,
anchor_shift: 0.0,
},
Unit {
abbr: "m3/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Cubic meter per second",
plural: "Cubic meters per second",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "m3/min",
measure: "volumeFlowRate",
system: "metric",
singular: "Cubic meter per minute",
plural: "Cubic meters per minute",
to_anchor: 16.666666666666668,
anchor_shift: 0.0,
},
Unit {
abbr: "m3/h",
measure: "volumeFlowRate",
system: "metric",
singular: "Cubic meter per hour",
plural: "Cubic meters per hour",
to_anchor: 0.2777777777777778,
anchor_shift: 0.0,
},
Unit {
abbr: "km3/s",
measure: "volumeFlowRate",
system: "metric",
singular: "Cubic kilometer per second",
plural: "Cubic kilometers per second",
to_anchor: 1000000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "tsp/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Teaspoon per second",
plural: "Teaspoons per second",
to_anchor: 0.16666666666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "Tbs/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Tablespoon per second",
plural: "Tablespoons per second",
to_anchor: 0.5,
anchor_shift: 0.0,
},
Unit {
abbr: "in3/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic inch per second",
plural: "Cubic inches per second",
to_anchor: 0.55411,
anchor_shift: 0.0,
},
Unit {
abbr: "in3/min",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic inch per minute",
plural: "Cubic inches per minute",
to_anchor: 0.009235166666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "in3/h",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic inch per hour",
plural: "Cubic inches per hour",
to_anchor: 0.00015391944444444444,
anchor_shift: 0.0,
},
Unit {
abbr: "fl-oz/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Fluid Ounce per second",
plural: "Fluid Ounces per second",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "fl-oz/min",
measure: "volumeFlowRate",
system: "imperial",
singular: "Fluid Ounce per minute",
plural: "Fluid Ounces per minute",
to_anchor: 0.016666666666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "fl-oz/h",
measure: "volumeFlowRate",
system: "imperial",
singular: "Fluid Ounce per hour",
plural: "Fluid Ounces per hour",
to_anchor: 0.0002777777777777778,
anchor_shift: 0.0,
},
Unit {
abbr: "cup/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cup per second",
plural: "Cups per second",
to_anchor: 8.0,
anchor_shift: 0.0,
},
Unit {
abbr: "pnt/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Pint per second",
plural: "Pints per second",
to_anchor: 16.0,
anchor_shift: 0.0,
},
Unit {
abbr: "pnt/min",
measure: "volumeFlowRate",
system: "imperial",
singular: "Pint per minute",
plural: "Pints per minute",
to_anchor: 0.26666666666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "pnt/h",
measure: "volumeFlowRate",
system: "imperial",
singular: "Pint per hour",
plural: "Pints per hour",
to_anchor: 0.0044444444444444444,
anchor_shift: 0.0,
},
Unit {
abbr: "qt/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Quart per second",
plural: "Quarts per second",
to_anchor: 32.0,
anchor_shift: 0.0,
},
Unit {
abbr: "gal/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Gallon per second",
plural: "Gallons per second",
to_anchor: 128.0,
anchor_shift: 0.0,
},
Unit {
abbr: "gal/min",
measure: "volumeFlowRate",
system: "imperial",
singular: "Gallon per minute",
plural: "Gallons per minute",
to_anchor: 2.1333333333333333,
anchor_shift: 0.0,
},
Unit {
abbr: "gal/h",
measure: "volumeFlowRate",
system: "imperial",
singular: "Gallon per hour",
plural: "Gallons per hour",
to_anchor: 0.035555555555555556,
anchor_shift: 0.0,
},
Unit {
abbr: "ft3/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic foot per second",
plural: "Cubic feet per second",
to_anchor: 957.506,
anchor_shift: 0.0,
},
Unit {
abbr: "ft3/min",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic foot per minute",
plural: "Cubic feet per minute",
to_anchor: 15.958433333333334,
anchor_shift: 0.0,
},
Unit {
abbr: "ft3/h",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic foot per hour",
plural: "Cubic feet per hour",
to_anchor: 0.2659738888888889,
anchor_shift: 0.0,
},
Unit {
abbr: "yd3/s",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic yard per second",
plural: "Cubic yards per second",
to_anchor: 25852.7,
anchor_shift: 0.0,
},
Unit {
abbr: "yd3/min",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic yard per minute",
plural: "Cubic yards per minute",
to_anchor: 430.87833333333333,
anchor_shift: 0.0,
},
Unit {
abbr: "yd3/h",
measure: "volumeFlowRate",
system: "imperial",
singular: "Cubic yard per hour",
plural: "Cubic yards per hour",
to_anchor: 7.181305555555555,
anchor_shift: 0.0,
},
Unit {
abbr: "lx",
measure: "illuminance",
system: "metric",
singular: "Lux",
plural: "Lux",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "ft-cd",
measure: "illuminance",
system: "imperial",
singular: "Foot-candle",
plural: "Foot-candles",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "mHz",
measure: "frequency",
system: "metric",
singular: "millihertz",
plural: "millihertz",
to_anchor: 0.001,
anchor_shift: 0.0,
},
Unit {
abbr: "Hz",
measure: "frequency",
system: "metric",
singular: "hertz",
plural: "hertz",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "kHz",
measure: "frequency",
system: "metric",
singular: "kilohertz",
plural: "kilohertz",
to_anchor: 1000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "MHz",
measure: "frequency",
system: "metric",
singular: "megahertz",
plural: "megahertz",
to_anchor: 1000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "GHz",
measure: "frequency",
system: "metric",
singular: "gigahertz",
plural: "gigahertz",
to_anchor: 1000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "THz",
measure: "frequency",
system: "metric",
singular: "terahertz",
plural: "terahertz",
to_anchor: 1000000000000.0,
anchor_shift: 0.0,
},
Unit {
abbr: "rpm",
measure: "frequency",
system: "metric",
singular: "rotation per minute",
plural: "rotations per minute",
to_anchor: 0.016666666666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "deg/s",
measure: "frequency",
system: "metric",
singular: "degree per second",
plural: "degrees per second",
to_anchor: 0.002777777777777778,
anchor_shift: 0.0,
},
Unit {
abbr: "rad/s",
measure: "frequency",
system: "metric",
singular: "radian per second",
plural: "radians per second",
to_anchor: 0.15915494309189535,
anchor_shift: 0.0,
},
Unit {
abbr: "rad",
measure: "angle",
system: "metric",
singular: "radian",
plural: "radians",
to_anchor: 57.29577951308232,
anchor_shift: 0.0,
},
Unit {
abbr: "deg",
measure: "angle",
system: "metric",
singular: "degree",
plural: "degrees",
to_anchor: 1.0,
anchor_shift: 0.0,
},
Unit {
abbr: "grad",
measure: "angle",
system: "metric",
singular: "gradian",
plural: "gradians",
to_anchor: 0.9,
anchor_shift: 0.0,
},
Unit {
abbr: "arcmin",
measure: "angle",
system: "metric",
singular: "arcminute",
plural: "arcminutes",
to_anchor: 0.016666666666666666,
anchor_shift: 0.0,
},
Unit {
abbr: "arcsec",
measure: "angle",
system: "metric",
singular: "arcsecond",
plural: "arcseconds",
to_anchor: 0.0002777777777777778,
anchor_shift: 0.0,
},
];
pub(crate) static ANCHOR_RATIOS: &[(&str, &str, f64)] = &[
("length", "metric", 3.28084),
("length", "imperial", 0.3047999902464003),
("area", "metric", 10.7639),
("area", "imperial", 0.09290312990644656),
("mass", "metric", 0.0022046244201837776),
("mass", "imperial", 453.592),
("volume", "metric", 33.8140226),
("volume", "imperial", 0.02957352965157124),
("each", "metric", 1.0),
("time", "metric", 1.0),
("digital", "bits", 0.125),
("digital", "bytes", 8.0),
("partsPer", "metric", 0.000001),
("speed", "metric", 0.621371192237334),
("speed", "imperial", 1.609344),
("pace", "metric", 0.3048),
("pace", "imperial", 3.280839895013123),
("pressure", "metric", 0.00014503768078),
("pressure", "imperial", 6894.76000045014),
("current", "metric", 1.0),
("voltage", "metric", 1.0),
("power", "metric", 1.0),
("reactivePower", "metric", 1.0),
("apparentPower", "metric", 1.0),
("energy", "metric", 1.0),
("reactiveEnergy", "metric", 1.0),
("volumeFlowRate", "metric", 33.8140227),
("volumeFlowRate", "imperial", 0.029573529564111873),
("illuminance", "metric", 0.09290304359661128),
("illuminance", "imperial", 10.76391),
("frequency", "frequency", 1.0),
("angle", "metric", 1.0),
];