m
1CFc        )   @   s[  d  Z  d Z d k Te d d d  Z e d d d  Z e d d d	  Z e d
 h  d d Z d \ Z	 Z
 Z d Z d Z Z d Z d \ Z Z Z d Z Z e e Z e d e d h  d d d e d h  d d d d  Z e i d  d e i d! d e i d e d e i i d e i i   e d" d# e d$  Z e d% d& e d' d( e  Z e i d) d e i  d* d e i  d+ d, e i  d- d. e i  d/ d0 e i  d1 d e i   e! d Z" d2 e# Z$ e$ d3 Z% e$ d Z& e& d Z' e' d Z( d, e$ Z) d0 e$ Z* d4 e$ Z+ e+ d Z, d5 e$ d0 Z- e d6 e+ d7 e d8 e$ d9 d: Z. e+ d Z/ e d e) d; d< e0 e! i1 d= e d> d? e# d@  Z2 Z3 e d e3 dA  Z4 e4 dB Z5 e d6 e3 dC dD e$ Z6 d, e6 Z7 e d e4 dE  Z8 dF e4 Z9 d3 e3 e9 _: e9 d, Z; Z< Z= e< d Z> d e9 Z? e d0 e? dG  Z@ e d e@ dH  ZA dI e@ dJ e4 ZB e' d
 ZC e$ dK eC _D eE iC eC _E e dL e$ dM dN e$ dO  ZF d, e3 dP e$ ZG e@ i dQ dR e4 dS dT e# dU dV e# dW e dX e# dY dZ d[ e3  e d\ e@ iH dC e d3 e8 d] d^ e3 iI ZJ d e@ iH eA _K e@ iH eL ZM d_ e# d` e3 _N e3 iN d
 e$ _N e$ iN d eC _N e da e3 iN db e$ iN dc e$ iN d
 dd eC iN de d. e3 iN df dg e3 iN d  ZN dh eO ZP eP d ZQ eQ d ZR eR d ZS eS d ZT d eP ZU di eU ZV ZW eW dB ZX ZY eY dB ZZ d5 eW Z[ d e[ Z\ d3 eW Z] dj eW Z^ e d0 e\ dC e] Z_ Z` e d e_ dC d e_ ia dk eb Zc e dl dm ed ee ef  ec ia Zg eh eW ei Zj ej ek el Zm Zn Zo e d\ ep em dC dn ef Zq e9 e? Zr er d, Zs e; i do dp e4 e4 dq e; e;  e@ d Zt dr et Zu ds er Zv e3 d e3 _w e dt du e3 iw  Zx dv e3 iw Zy ey d ey _z d e3 iw ec _{ dw e3 iw ec i{ _w ec i dx dy e3 iw dz ec i{ d{ d3 e3 iw  d0 eW e\ _| d eU eZ _} d eP e~ _ d0 eZ i} eY _ d
 eY i eW _ e d& ei d| d} d~ eP Z e d eZ i} d e~ i d e i dN eY i d eW i  Z e d3 eC _ d e iY eW _ eW i e$ d Z e d e3 eW i e! dk d e i e# e! d d e d d e d d e d d e Z e i Z e3 e! d Z e e! Z eW e Z e e! Z eW i e Z d
 e Z e3 eW i Z ei i Z e d e d d d d5 e$ d d d d d e$ d Z e d# e d, d e i d, d e i d, Z e d# e d d e i d d e i d Z e i e i e i e _a e _a e _a d, e Z d0 d5 e ec _ e dw e d e i dw Z e d e d e i d Z e d Z e d# e d, dC e ia d, Z Z e d Z e d# e d6 dC e ia d, Z eY _ e d Z e d e d# e d dk d e  Z e i d e _ e i d eZ _ e _ e ia d0 eZ _a e d# eZ d dC eZ ia d Z Z e d} e i d eZ i  Z e dN eY i d eZ i  Z e d4 e dC d4 e ia Z e d Z e d Z e d e d d e i d d dr e i d d e i Z e d e dC d5 e ia d d e i d d e i d d d e i Z e d e d d e i Z e d e d d e i Z e d9 d d e i d e i d e i d e i d d e i d e i d e i d e i d e i d e i d e i  Z e d9 d d e i d e i d e i d e i d e i  Z e e d9 d d e i d e i Z e d9 d d e d e# d d e# d e@ iH  Z e i d e d# e i d d e i i d d e d e i d d e i i d e d, e i d9 d  e i d e d e i d d e i i d e d# e i d d e i i d
  e i d e d# e i d d e i i d
 d e d0 e i  d e d6 e i d9 d  e d e i  e _ e d9 d d e i i d e i i d e i i d e i i d e i i  e _ e i e i e3 _ e$ _ e i e i e. _ e8 _ e d d e# d d e d e d e d  d e d e d e d d  Z e i d e i d d d e i d d e i d d e i d d, e i  e i d e i d
 d dK e i d d e i  d. e i e _ d, e i e _ e i e i e3 _ e$ _ e i e i e. _ e8 _ e d d e# d d e# d d e#  Z e i d d e i d e i d
  e i d
 e( _ e _ e i e i e3 _ e$ _ e i e i e. _ e8 _ e d e e# d d e i d e i Z e d d e4  Z e d eO d  Z e d d eW d d e4  Z e d d e4 d d eW  Z e d Z e d, Z d e Z d e Z Z d e Z d6 e Z Z d e Z e d Z d e Z d
 e Z d e d Z e ia d e _a dw e ia e ia _ d e$ d e ia _ e d e$ d d9 d d d eW d d eW d d eW d d eW d dM eW d d eW d d eW e _a e ia d, e _a e ia d e ia _ e ia i d, e ia _ e ia i d e ia _ e d e ia d e ia d e ia d e ia d eZ ia d e ia d e ia d e ia d d e ia d d e ia d e ia d e ia d e ia d e ia d e6 ia d eJ ia d e_ ia d e_ ia d ec ia d eq ia  Za d S(   sd  Archaic and idiosyncratic units of measurement.

See SI.py for base units and units.py for various others.

This file documents lots of obscure and/or silly units, may of them derived from
the /usr/share/misc/units repository of knowledge on the subject (see
units.html, in URLs attribute of this module, for details).  This file aims to
be all-inclusive, rather than sensible; however, there are `issues', since some
of the units (especially ones relevant to trade in the anglophone world) have
several variants - where possible, I have tried to find namespace-based ways to
manage this mess (e.g.: print bushel.US.__doc__), but sometimes (e.g. the chain)
I just gave up and left a comment here indicating the part of the story that
I've left out !

I should probably replace most of this file with a family of XML or RDF
documents describing all the units, coupled to a deployment of some standard
parsing tool-kit to access the data they provide.

There are enough units of measurement here to provide for some cutely specific
units of measurements in all sorts of odd domains.

  For example, consider the fuel efficiency of transport systems fueled by
  petrol; this is commonly measured in miles / gallon in the anglophone world
  (with consequent confusion between the new imperialists and the old; while the
  two agree on what a mile is, they disagree on what a gallon is; five UK
  gallons roughly equal six US gallons) or kilometres / litre in the civilised
  world (48 miles / UK gallon is roughly equal to 40 miles / US gallon and to 17
  kilometres / litre).  This last is, itself, one million times the natural SI
  unit, metres per cubic metre.

  Superficially, this is a 1/area unit, though the implicit `of petrol' clause
  in it does subvert that a little; 17 km/litre is officially 17 million /
  square metre, a.k.a. 17 per square millimetre; which is meaningless drivel
  until I point out that it means that each square millimetre of cross-sectional
  area of your fuel tank contributes (at this fuel efficiency) 17 to the ratio
  between the speed of your vehicle and the rate at which the fuel level in the
  tank is dropping; if your fuel tank's cross-section is one square foot (92,903
  square mm), and your vehicle is managing 17 km/litre, then you're travelling a
  little over one and a half million (i.e. 17 * 92,903) times as fast as the
  level in the fuel tank is dropping.

  In reality, fuel efficiencies of real road vehicles seem to fall in the range
  from around 8 to around 80 mpg (UK), so that a unit of order 20 mpg would be
  quite handy; as it happens, one furlong / UK floz is exactly 20 miles per UK
  gallon, suggesting it as the ideal imperial unit for the task (i.e. it's the
  right size and marvelously perverse).  A slightly saner unit would clearly be
  the mile per UK pint - the given range runs from one to 10 of these, and
  that's a nice range of numbers to work with - which is 2.83 km / litre.  By a
  weird twist of fate, 2.83 is almost exactly the square root of 8; so that the
  civilised unit, one km/litre, is 2.83 miles per UK gallon; and using this unit
  makes the range of real-world values run from 2.8 to 28, with 10 km/litre
  (roughly 28 miles per UK gallon or 23 per US gallon) presenting itself as a
  fairly good cut-off between `inefficient' and `not so bad, all things
  considered'.

  Note that one might equally measure the same phenomenon as a fuel consumption
  rate, in gallons per mile or litres per kilometre, which would encourage
  trying to find a unit of order one UK gallon per 80 miles, a.k.a. one UK pint
  per ten miles or 2 UK floz per mile.  (The pint per mile would also make quite
  a good unit of measurement for pub-crawls, albeit with very different
  semantics.)  A vehicle consuming a small number of floz per mile (up to five
  or six, to match the cut-off above) would then be considered frugal, while
  ones beyond that would be considered wasteful.

Chosing the right unit, and the right way up (c.f. the contrast between fuel
efficiency and consumption rate), is important to how measurements get
interpreted - for example, although the gradient of a sloping road may formally
be a dimensionless quantity, it makes sense to measure `slope' in such units as
metre (of ascent or descent) per kilometre (of travel) or, in a culture which
has different units for vertical and horizontal lengths, fathoms per furlong.
Even when using the official SI unit, different ways of expressing a unit can
change perceptions of its meaning - for example, (metre / second)**2 means the
same as Joule / kilogramme, but expresses a different perspective on it.

$Id: archaea.py,v 1.3 2007/04/20 11:52:54 eddy Exp $
sg  Interesting URLs:

http://www.ukmetrication.com/history2.htm
http://www.sylvaefa.com/svf1.htm
http://www.maritimt.net/arkforsk/svenskem.htm
http://en.wikipedia.org/wiki/Cgs
http://home.clara.net/brianp/
http://www.gnu.org/software/units/units.html
http://www.unc.edu/~rowlett/units/
http://www.bipm.org/en/si/si_brochure/chapter4/4-1.html
http://en.wikipedia.org/wiki/Category:Obsolete_units_of_measure

Nautical mile and its kin
http://www.gwydir.demon.co.uk/jo/units/sea.htm
http://www.explore-dictionary.com/weights_and_measures/M/Megalithic_yard.html

German archaic units of measurement:
http://de.wikipedia.org/wiki/Alte_Mae_und_Gewichte
should move the relevant section of units.py to
archaea.py or even archaea/*.py !

Dutch archaic units:
http://home.hetnet.nl/~vanadovv/Lengte.html

Fathom = vadem in dutch:
<URL: http://home.hetnet.nl/~vanadovv/Lengte.html >
(   t   *t   Lt   Lenatsk   The standard unit of bogosity

See the New Hackers' Dictionary, under microLenat.  Also known as the Reid. t   Helens_  The standard unit of beauty (trad).

Definitively `beautiful enough to launch a thousand ships', so that launching a
single ship gains credit for a single milli-Helen.  The origin of this is the
story of the Trojan war, in which a Greek fleet of a thousand ships, carrying a
great army, went to retrieve Helen from Troy, to which Paris had taken her. t   Scovilles  Standard unit of pungency.

Dilution to one part in N (with sugar water) makes the taste undetectable for an
N Scoville pungency.  Conventional wisdom classes 0 to 500 as mild, 500 to 999
as medium, 1k to 4.999 k as hot and 5k or above super-hot.  Chile sauces scoring
93 k Scoville are insane, but some exist as high as 577 k Scoville; Jalapeno
extract scores about 4.5 k; pure Capsaicin rates over 15,000,000 Scoville Units.
i   t   bakeri   i   f0.5f0.25f0.01i   i
   i   i<   i   i(   t   quirei   t   shorti   t   reami  i  t   perfecti  t   bundlet   balef30000.0i   s=  The pre-Geldof poverty-induced infant mortality rate.

As at 2005, the Live8Live organizers report that 30,000 children die every day,
needlessly, as a result of extreme poverty.  This seemed a reasonable basis on
which to name a rate-of-death unit.  Since Sir Bob Geldof stands as front-man
for the Live8Live organization, and has done sterling work in previous kindred
organizations, he seemed a natural person after whom to name the unit.  It
should be noted that the 3e4/day figure is merely the infant mortality rate; we
could as readily use 5e4 if we include adults.
t   splitf0.20000000000000001t   magnumf1.5t   jeroboamt   rehoboamt
   methuselahi   t
   salmanazari   t	   balthazari   t   nebuchadnezzarf0.025399999999999999id   i	   i   i   t   flemishi   t   docs   The Flemish ells'  The English foot.

See namespace for other nation's variants on this unit.  All are fairly close to
the distance (given here as foot.astronomical) that light travels in a nano second:
those closest to it are the old Swedish foot, just under 1% below, and the
English foot, just over 1/60 above.
t   astronomicalt   surveyf1200.0ia  s   The (geodetic) survey foot.

In the US the Metric Act of 1866 defined the foot to equal exactly
1200/3937m, or approximately 30.48006096cm.  This unit, still used for
geodetic surveying in the United States, is now called the survey
foot.
s  The Modern Yard.

The yard (0.9144 metres) is a modern survivor of a family of roughly
stride-sized units of length dating back - if the excellent Monsieur Thom is to
be believed - to prehistory (Thom measured the lengths in stone circles all over
Europe and found evidence that they were measured to a common unit,
approximately equal to the yard).  It takes its name from a Germanic word,
'gyrd'.  Its metric replacement, the metre, is just slightly bigger.
i   t   USi   s   The Fathom.

The fathom is cognate with the Swedish famn and Danish favn (q.v.) and has
principally survived in use as a maritime measure of vertical distances -
notably the depths of bodies of water.
i   sb  The Statute Mile.

The British mile (also used in the U.S.A.) is just over 1600 metres; for a long
time it was used as a standard distance for races, fitting nicely with the
pattern of doubling lengths upwards from 100m.  Like all Imperial units, it has
a long and contorted history.

Its nominal origin is in the Imperial Roman 'millum pes' - a thousand paces,
though the Roman pes was the distance a soldier's foot travels in each stride,
roughly double the separation of the feet when both are on the ground.  Compare
this to the British 'pace', of 5 feet, which is quite close to one thousandth of
a mile, while the US 'pace' is exactly half as long.

Some backward countries seem likely to continue using this unit to measure
distances - along with the mile per hour as a unit of speed - for some time to
come.  Contrast mile.nautical and the Scandinavian mil.
sO   The league

A varying measure of road distance, usu. about three miles (poxy).
i   i  i  t   ironi0   t   ouncei@   f8.5t   seai  t   geographicali  t   Prussianil  t   nauticali<  sd  The nautical mile

I've met assertions that the nautical mile is 2000 yards (here given as mile.sea
since I've seen it called a sea mile).  Alternatively, that it's one minute of
arc - i.e. Earth.surface.radius * pi / 180 / 60.  My available figures for the
Earth's radius yield figures ranging from 1853 to 1855 metres, aka 2026 to 2029
yards: so Kaye & Laby fits with the minute of arc view (to reasonable accuracy)
and I take the 2000 yard figure as being a widely used approximation.
Apparently, the US used some other unit until 1954, the UK until 1970; both
catching up with a 1929 international standard.
t   UKi  f0.10000000000000001t   navyi  i  i6  t   piedt   incht   linet   pointt   toiset   arpenti   f6.4798909999999995e-05i^  iL   t   metricf4.1840000000000002f0.001f105480400.0t   buildingi!   t
   bricklayeri$   i   t   woodil   i   i*   t   displacementi#   t   freightt   registers]   The Carat, a unit of mass used by jewelers.

Apparently originally the mass of a carob seed.
t   Troyf3.1699999999999999t   drachmt   deniert   caratt   poundi   i&  iK   t   electrici  t   boilerf9809.5t   waterf746.04300000000001t   donkeyi   f4.5460900000000004t   winei   t   beeri/   i   t   tablet   fluidt   drami?   t   alei"   i3   sC   Winchester measures, for wine.

(Due to Queen Anne's regime, 1707)
t   gallont   quartt   pintt   barrelt   rundleti   t   tiercet   hogsheadt   puncheont   buttt   pipet   tuns5   Archaic measures for beer, pre-1688 and 1803 to 1824.s'   Archaic measures for ale, 1688 to 1803.s%   Old Swedish units, as used since 1863t   alnf0.59372000000000003t   oldf	0.5938097t   kvartmilt   fott   famnt   sjoemils   Svensk sjmilt   milip  t   tumt   linjet   rodet   staangs   Svensk stngs"   Swedish units in use prior to 1863t   alenf0.62770000000000004t   potf0.96609999999999996t   paeglf0.22420000000000001s
   Dansk pglt   tylet   dusint   grost   snest   fodt   favnt   kandet   skokt   olt   tommet   ankerf0.31374000000000002f1.88245f11294.6t   toms  The Norwegian mil, 10 km.

In Norway, 10 km is known as 'en mil'.  This is clearly a metricised replacement
for an archaic Norwegian unit of distance, presumably close to the Danish and
Swedish variants which I've found documented on the web.  The name is doubtless
cognate with the Anglic 'mile' (q.v.), but the distance is significantly larger
(but compare the Prussion mile).  The related sjmil units of the Scandinavian
tradition literally translate as 'sea mile'; see Swedish.sjoemil, for example.
However, the Scandinavian countries have embraced international standards, so
now use the 1929 nautical mile and the metric system of units, rather than
clinging to archaic units like some less civilized countries.
t   Danskt   Svenskt   lieni  t   oncent   okef2.8342000000000001t   berrii$  t   versti  t   poodf36.109999999999999i  f2150.4200000000001s   The US bushel.

This is the volume of an 8 inch cylinder with 18.5 inch diameter.
However, the US bushel is also a unit of mass for various types of grain.
See dir(bushel.US) for details.
t   wheatt   soybeant   corni8   t   ryet   barleyt   oati    t   ricei-   t   gillt   minimt   flozt   ponyt   jiggert   firkint   bushelt   peckt   pacet   cablet   cwtt   hundredweightt   tont   thermN(   i   f0.5f0.25(   i   i<   i   (   t   __doc__t   URLst   unitst	   base_unitR   R   R   t   Quantityt   dozent   pairt   halft   quartert   percentt   prialt   nestt   dickerst   scoret   shockt   grosst   timert   flockt
   greatgrosst   Objectt   papert   alsoR   R   R   t   dayt   Geldoft   litret	   champagneR   t   secondt   jiffyt   metreR"   t   calibert
   barleycornt   picaR#   t   handt
   palmlengtht   spant   fingerlengtht   fingerbreadtht   ellt   cubitt   nanot   lightt   ftt   foott   yardt   nailRy   t   ropet   fathomt   chaint   engineert   rodt   polet   percht   linkt   furlongt   milet   leaguet   marathonR$   t   silversmitht   arct   shoet	   railgaugeR   R   Rz   t   marinet   hourt   knott   Frencht
   kilogrammet   graint   mitet   droitt   periott   blanct   scruplet   lbR2   t   ozR   R;   t   clovet   stonet   centalt   quintalR{   R|   R   t   tonneR}   t   tophatt   gigat   Joulet   TNTt   caloriet   gramt   CHUt   Rankinet   Kelvint   BTUt   Btut   BritishThermalUnitt   megaR~   t   acret   roodt   sectiont   townshipt	   homesteadt   timbert   stackt   cordt   houset   shipt   butchert
   apothecaryR0   R.   R1   t   jewellert
   mercantilet   weightt   psit   kilogramt   Wattt
   horsepowerR'   t   chevalVapeurt   celot   jerkt   poundalt   reynt   slugt   slincht   dutyt   pondR=   R7   R8   R>   R?   t   bucketR5   RB   RD   t   pottleRq   t   noggint   cupRs   R:   t   teacupt   cct   spoonR9   t   desertt   teaRr   t   dropR/   Rv   t   pint	   kilderkinR@   RC   RF   RG   R<   t   SwedishRH   RI   RJ   RL   RK   RO   RR   t   refRN   Rc   t   DanishRS   RT   RY   RZ   R[   R\   R`   t	   oksehovedt   fadR_   Rb   t   NorseRa   t   NorskRP   t   kilot   Swisst   Dutcht   Turkt   RussiaRx   Rw   t   striket   coombt   bagt   seamt   weyt   loadt   sackt   firlott   bollt   chaldront   crant   oilt   dry(   R   R   R<   R   R   R   R   R   Rv   R   R   R1   R   R/   R   R   R  R   R   R   R  R:   R   R  R   R   R   R   R  R   R   R   Rz   R   R   RC   R  R.   R   R   R   R  Rq   R   R   R   R   R  R  R   R   R{   RD   R   R   R   R   RB   R  R>   RG   R   R   R   R|   R   R   R   R   R   R   R   R   R   R   Rw   R   R$   R  R   R   R   R   R   R   R~   R   R  R8   R}   R   R  R   R   R  R   R#   Rx   R   R   R   Ry   R   R  R   R2   R  R   R  R   R   R=   R   R   R   R   R   RN   Rr   R   R"   R?   R   R   R   R   R   R   R   R   R   R   R   R   R   R;   R   R   Rs   R   R  R   R  R  R  RF   R   R@   R7   (    (    t)   /home/eddy/.sys/py/study/value/archaea.pyt   ?M   sF  						


! %		









$
			

		


				


		










""

"


		


	



		&
		

'
&$

				!		,(	 
	













#$