List of Units

This page lists all currently available units that the bot recognizes and knows how to convert between them.

Detection

The following units will be detected in a comment by the bot. Internally, all values will be normalized to the appropriate SI base unit.

All unit detection regexes are prefixed with the following expression: \b(\d+[\d ,'\.]+)
Note: Regular expressions below use ¦ instead of | due to limitations with Reddit's Markdown formatting in tables.

Length

Length units will be normalized to meters.

Unit nameRegexFactor
meter(?:m¦ meters?¦metres?)b1
kilometer(?:km¦ kilometers?¦kilometres?)b1000
inch?(?:inch¦inches)b0.0254
mile?mi(?:les?)?(?! per)b1609.34
yard(?:yards?¦yd)b0.9144
foot?(?:feet¦ft)b0.3048
ft"in'(d)'(d{,2})" (no prefix)see feet & inches

Mass

Mass units will be normalized to kilograms.

Unit nameRegexFactor
kilogram(?:kg¦ kilogram[m¦s]?¦ kilos?)b1
pound?(?:lbs?¦pounds?)b0.453592

Volume

Volume units are normalized to cubic meter (m3)

Unit nameRegexFactor
cubic meter?(?:m3¦m³)b1
liter(?:l¦ liters?¦litres?)b0.001
fl.oz.?(?:oz.?¦fl.? ?oz.?¦ounces?¦fl.? ?ounces?¦fluid ?oz.?¦fluid ?ounces?)b0.0000295735
gallon?gallons?b0.00378541

Velocity

Units of speed are normalized to meters per second.

Unit nameRegexFactor
m/s?(?:m/s¦meters? / second¦meters? per second)b1
km/h?(?:kilometers per hour¦kilometres per hour¦kph¦km/?h)b0.277778
mi/h?(?:miles per hour¦mph)b0.44704

TODO: Knots might be used sometimes, too.

Time

All normalized to seconds.

Unit nameRegexFactor
second?secondsb1
minute?minutesb60
hour?(?:hours¦hrs)b3600
day?daysb86400
week?(?:weeks¦wks)b604800
month?monthsb2592000

Power

Normalized to kilowatts.

Unit nameRegexFactor
kilowatt?(?:kw¦kilowatts?)b1
watt?watts?b1000
hp?(?:hp¦bhp¦whp)b0.745699872

Conversion

The values extracted from comments according to the table above will be converted to a randomly chosen unit of the following tables.
Factors are to the normalized unit respectively.

Length

UnitFactorNote
beard-minutes1666666.6666760 * beard-seconds Source
beard-hours27777.77777783600 * beard-seconds Source
attoParsec32.4077929Source
pico light-second3335.55703803Source
smoot0.587613116Source

Mass

UnitFactorNote
zepto jupiter mass5.2665E-7Source
dynes980665Source
cement bags0.02345Source

Volume

UnitFactorNote
barn-megaParsec324078Source
Hubble-barn76.6Source
acre-feet0.000810713194Source

Velocity

UnitFactorNote
attoParsec per microfortnight39.2004663Source
smoots per nanocentury1.854Source
light-seconds per dog-year0.01503Source

Time

UnitFactorNote
microcentury0.0003169Source
nanocentury0.3169Source
microfortnight0.8267Source
dog year2.21967699e-7Source

Power

UnitFactorNote
donkey power4.00Source

Exceptions

The are a number of fixed expressions that will never be converted:

  • 1000 yard (stare)
  • 8 mile
  • 2 feet
  • 24 hour
  • 24 hours
  • 9 yards
  • 1 day
  • 1ft
  • 1 ft
  • 10 ft (pole)
  • 7 days
  • 30 days
  • 365 days
  • 12 months