phys-units 0.9.9 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.travis.yml +18 -0
- data/Gemfile +3 -0
- data/README.md +12 -2
- data/Rakefile +7 -0
- data/lib/phys/units/load_units.rb +1205 -179
- data/lib/phys/units/parse.rb +36 -31
- data/lib/phys/units/parse.y +19 -14
- data/lib/phys/units/version.rb +1 -1
- data/misc/mkunitspec.rb +14 -13
- data/spec/all_units_spec.rb +802 -125
- data/spec/helper.rb +0 -1
- data/spec/jp_units_spec.rb +0 -1
- data/spec/quantity_spec.rb +5 -7
- data/spec/unit_spec.rb +8 -9
- data/spec/utils_spec.rb +0 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: cd85b3f21ba5c367e32b56383e600e6c36e31bb8
|
4
|
+
data.tar.gz: c6ac0ffc4d76610c36dae6f2d4dea3be018a2efa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fb35776b083559d3d91b1c300bdc53c5d3779e2052c457c546c2384046e517b2c95b712e0e8103fbe5fbff0903d60bcd43dc023955d5c9d63db5ab7b67f1f2e7
|
7
|
+
data.tar.gz: 03d2a934294840bbbc5e7874c38b75986090cc06162e4a343ab32584d0049175c3c169968dc00c8b9f225e47a1c0cf2b8a01954ec6d9b87d06e9144281ea0732
|
data/.travis.yml
ADDED
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -1,10 +1,12 @@
|
|
1
1
|
# Phys-Units
|
2
2
|
|
3
|
+
[](https://travis-ci.org/masa16/phys-units)
|
4
|
+
|
3
5
|
[GNU Units](http://www.gnu.org/software/units/) -compatible Ruby library for
|
4
6
|
unit conversion of physical quantities.
|
5
7
|
Major features: (1) It uses rich database of GNU Units.
|
6
8
|
(2) It provides normal class interface without modifying built-in classes.
|
7
|
-
Former name is [Quanty](
|
9
|
+
Former name is [Quanty](https://rubygems.org/gems/quanty),
|
8
10
|
the first Ruby units library released in 2001.
|
9
11
|
|
10
12
|
* [GitHub](https://github.com/masa16/phys-units)
|
@@ -133,7 +135,15 @@ Note that this usage involves global changes on a build-in class and will cause
|
|
133
135
|
|
134
136
|
## Platforms tested
|
135
137
|
|
136
|
-
* ruby 2.
|
138
|
+
* ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-linux]
|
139
|
+
|
140
|
+
## History
|
141
|
+
|
142
|
+
* 2017-10-24 ver 1.0.0
|
143
|
+
* Unit data from GNU Units version 2.14 (including 2014 CODATA recommended values)
|
144
|
+
* 2013-04-27 ver 0.9.0
|
145
|
+
* Change module name from [Quanty](https://rubygems.org/gems/quanty) to Phys-Units.
|
146
|
+
* Unit data from GNU Units version 2.04 (including 2010 CODATA recommended values)
|
137
147
|
|
138
148
|
## Copying License
|
139
149
|
|
data/Rakefile
CHANGED
@@ -5,10 +5,9 @@ Phys::Unit.import_units <<EOL
|
|
5
5
|
# This file is the units database for use with GNU units, a units conversion
|
6
6
|
# program by Adrian Mariano adrianm@gnu.org
|
7
7
|
#
|
8
|
-
#
|
8
|
+
# March 2017 Version 2.16
|
9
9
|
#
|
10
|
-
# Copyright (C) 1996
|
11
|
-
# 2007, 2008, 2009, 2010, 2011, 2012
|
10
|
+
# Copyright (C) 1996-2002, 2004-2017
|
12
11
|
# Free Software Foundation, Inc
|
13
12
|
#
|
14
13
|
# This program is free software; you can redistribute it and/or modify
|
@@ -30,7 +29,7 @@ Phys::Unit.import_units <<EOL
|
|
30
29
|
#
|
31
30
|
# Improvements and corrections are welcome.
|
32
31
|
#
|
33
|
-
# Fundamental constants in this file are the
|
32
|
+
# Fundamental constants in this file are the 2014 CODATA recommended values.
|
34
33
|
#
|
35
34
|
# Most units data was drawn from
|
36
35
|
# 1. NIST Special Publication 811, Guide for the
|
@@ -68,6 +67,9 @@ Phys::Unit.import_units <<EOL
|
|
68
67
|
# 22. NIST Special Publication 447, Weights and Measures Standards
|
69
68
|
# of the the United States: a brief history. Lewis V. Judson.
|
70
69
|
# 1963; rev. 1976
|
70
|
+
# 23. CRC Handbook of Chemistry and Physics, 96th edition
|
71
|
+
# 24. Dictionary of Scientific Units, 6th ed. H.G. Jerrard and D.B.
|
72
|
+
# McNeill. 1992
|
71
73
|
#
|
72
74
|
# Thanks to Jeff Conrad for assistance in ferreting out unit definitions.
|
73
75
|
#
|
@@ -315,6 +317,17 @@ hundred 100
|
|
315
317
|
thousand 1000
|
316
318
|
million 1e6
|
317
319
|
|
320
|
+
twoscore two score
|
321
|
+
threescore three score
|
322
|
+
fourscore four score
|
323
|
+
fivescore five score
|
324
|
+
sixscore six score
|
325
|
+
sevenscore seven score
|
326
|
+
eightscore eight score
|
327
|
+
ninescore nine score
|
328
|
+
tenscore ten score
|
329
|
+
twelvescore twelve score
|
330
|
+
|
318
331
|
# These number terms were described by N. Chuquet and De la Roche in the 16th
|
319
332
|
# century as being successive powers of a million. These definitions are still
|
320
333
|
# used in most European countries. The current US definitions for these
|
@@ -423,7 +436,17 @@ octodecillion shortoctodecillion
|
|
423
436
|
novemdecillion shortnovemdecillion
|
424
437
|
vigintillion shortvigintillion
|
425
438
|
|
439
|
+
#
|
440
|
+
# Numbers used in India
|
441
|
+
#
|
426
442
|
|
443
|
+
lakh 1e5
|
444
|
+
crore 1e7
|
445
|
+
arab 1e9
|
446
|
+
kharab 1e11
|
447
|
+
neel 1e13
|
448
|
+
padm 1e15
|
449
|
+
shankh 1e17
|
427
450
|
|
428
451
|
#############################################################################
|
429
452
|
# #
|
@@ -614,7 +637,15 @@ watch 4 hours # time a sentry stands watch or a ship's
|
|
614
637
|
# crew is on duty.
|
615
638
|
bell 1|8 watch # Bell would be sounded every 30 minutes.
|
616
639
|
|
640
|
+
# French Revolutionary Time or Decimal Time. It was Proposed during
|
641
|
+
# the French Revolution. A few clocks were made, but it never caught
|
642
|
+
# on. In 1998 Swatch defined a time measurement called ".beat" and
|
643
|
+
# sold some watches that displayed time in this unit.
|
617
644
|
|
645
|
+
decimalhour 1|10 day
|
646
|
+
decimalminute 1|100 decimalhour
|
647
|
+
decimalsecond 1|100 decimalminute
|
648
|
+
beat decimalminute # Swatch Internet Time
|
618
649
|
|
619
650
|
#
|
620
651
|
# angular measure
|
@@ -659,10 +690,11 @@ seclongitude circle (seconds/day) # Astronomers measure longitude
|
|
659
690
|
# Some geometric formulas
|
660
691
|
#
|
661
692
|
|
662
|
-
circlearea(r) units=[m;m^2] range=[0,
|
663
|
-
spherevolume(r) units=[m;m^3] 4|3 pi r^3 ;
|
664
|
-
|
665
|
-
|
693
|
+
circlearea(r) units=[m;m^2] range=[0,) pi r^2 ; sqrt(circlearea/pi)
|
694
|
+
spherevolume(r) units=[m;m^3] range=[0,) 4|3 pi r^3 ; \
|
695
|
+
cuberoot(spherevolume/4|3 pi)
|
696
|
+
spherevol() spherevolume
|
697
|
+
square(x) range=[0,) x^2 ; sqrt(square)
|
666
698
|
|
667
699
|
#
|
668
700
|
# Solid angle measure
|
@@ -709,7 +741,7 @@ fine 1|1000 # Measure of gold purity
|
|
709
741
|
# a solution. A neutral solution has a pH of 7 as a result of dissociated
|
710
742
|
# water molecules.
|
711
743
|
|
712
|
-
pH(x) units=[;mol/liter] range=
|
744
|
+
pH(x) units=[1;mol/liter] range=(0,) 10^(-x) mol/liter ; (-log(pH liters/mol))
|
713
745
|
|
714
746
|
|
715
747
|
#
|
@@ -734,8 +766,9 @@ TEMPERATURE_DIFFERENCE kelvin
|
|
734
766
|
# centigrade definition, but the Kelvin scale depends on the triple point of
|
735
767
|
# water rather than a melting point, so it can be measured accurately.
|
736
768
|
|
737
|
-
tempC(x) units=[;K]
|
738
|
-
|
769
|
+
tempC(x) units=[1;K] domain=[-273.15,) range=[0,) \
|
770
|
+
x K + stdtemp ; (tempC +(-stdtemp))/K
|
771
|
+
tempcelsius() tempC
|
739
772
|
degcelsius K
|
740
773
|
degC K
|
741
774
|
|
@@ -751,8 +784,9 @@ degC K
|
|
751
784
|
# is placed in the mouth so as to acquire the heat of a healthy
|
752
785
|
# man." (D. G. Fahrenheit, Phil. Trans. (London) 33, 78, 1724)
|
753
786
|
|
754
|
-
tempF(x) units=[;K]
|
755
|
-
|
787
|
+
tempF(x) units=[1;K] domain=[-459.67,) range=[0,) \
|
788
|
+
(x+(-32)) degF + stdtemp ; (tempF+(-stdtemp))/degF + 32
|
789
|
+
tempfahrenheit() tempF
|
756
790
|
degfahrenheit 5|9 degC
|
757
791
|
degF 5|9 degC
|
758
792
|
|
@@ -764,8 +798,8 @@ degR degrankine
|
|
764
798
|
tempR degrankine
|
765
799
|
temprankine degrankine
|
766
800
|
|
767
|
-
tempreaumur(x)
|
768
|
-
|
801
|
+
tempreaumur(x) units=[1;K] domain=[-218.52,) range=[0,) \
|
802
|
+
x degreaumur+stdtemp ; (tempreaumur+(-stdtemp))/degreaumur
|
769
803
|
degreaumur 10|8 degC # The Reaumur scale was used in Europe and
|
770
804
|
# particularly in France. It is defined
|
771
805
|
# to be 0 at the freezing point of water
|
@@ -837,11 +871,11 @@ light c
|
|
837
871
|
mu0 4 pi 1e-7 H/m # permeability of vacuum (exact)
|
838
872
|
epsilon0 1/mu0 c^2 # permittivity of vacuum (exact)
|
839
873
|
energy c^2 # convert mass to energy
|
840
|
-
e
|
841
|
-
h 4.
|
874
|
+
e 1.6021766208e-19 C # electron charge
|
875
|
+
h 4.135667662e-15 eV s # Planck constant
|
842
876
|
hbar h / 2 pi
|
843
877
|
spin hbar
|
844
|
-
G 6.
|
878
|
+
G 6.67408e-11 N m^2 / kg^2 # Newtonian gravitational constant
|
845
879
|
# This is the NIST 2006 value.
|
846
880
|
# The relative uncertainty on this
|
847
881
|
# is 1e-4.
|
@@ -849,7 +883,7 @@ coulombconst 1/4 pi epsilon0 # listed as "k" sometimes
|
|
849
883
|
|
850
884
|
# Physico-chemical constants
|
851
885
|
|
852
|
-
atomicmassunit 1.
|
886
|
+
atomicmassunit 1.660539040e-27 kg # atomic mass unit (defined to be
|
853
887
|
u atomicmassunit # 1|12 of the mass of carbon 12)
|
854
888
|
amu atomicmassunit
|
855
889
|
amu_chem 1.66026e-27 kg # 1|16 of the weighted average mass of
|
@@ -860,9 +894,9 @@ amu_phys 1.65981e-27 kg # 1|16 of the mass of a neutral
|
|
860
894
|
dalton u # Maybe this should be amu_chem?
|
861
895
|
avogadro grams/amu mol # size of a mole
|
862
896
|
N_A avogadro
|
863
|
-
gasconstant
|
897
|
+
gasconstant k N_A # molar gas constant
|
864
898
|
R gasconstant
|
865
|
-
boltzmann
|
899
|
+
boltzmann 1.38064852e-23 J/K # Boltzmann constant
|
866
900
|
k boltzmann
|
867
901
|
kboltzmann boltzmann
|
868
902
|
molarvolume mol R stdtemp / atm # Volume occupied by one mole of an
|
@@ -873,7 +907,7 @@ loschmidt avogadro mol / molarvolume # Molecules per cubic meter of an
|
|
873
907
|
stefanboltzmann pi^2 k^4 / 60 hbar^3 c^2 # The power per area radiated by a
|
874
908
|
sigma stefanboltzmann # blackbody at temperature T is
|
875
909
|
# given by sigma T^4.
|
876
|
-
wiendisplacement 2.
|
910
|
+
wiendisplacement 2.8977729e-3 m K # Wien's Displacement Law gives the
|
877
911
|
# frequency at which the the Planck
|
878
912
|
# spectrum has maximum intensity.
|
879
913
|
# The relation is lambda T = b where
|
@@ -882,8 +916,8 @@ wiendisplacement 2.8977721e-3 m K # Wien's Displacement Law gives the
|
|
882
916
|
# displacement. This relation is
|
883
917
|
# used to determine the temperature
|
884
918
|
# of stars.
|
885
|
-
|
886
|
-
|
919
|
+
K_J90 483597.9 GHz/V # Direct measurement of the volt is difficult. Until
|
920
|
+
K_J 483597.8525 GHz/V # recently, laboratories kept Weston cadmium cells as
|
887
921
|
# a reference, but they could drift. In 1987 the
|
888
922
|
# CGPM officially recommended the use of the
|
889
923
|
# Josephson effect as a laboratory representation of
|
@@ -894,12 +928,11 @@ K_J 483597.870 GHz/V # Direct measurement of the volt is difficult. Until
|
|
894
928
|
# applied across the superconductors. This frequency
|
895
929
|
# can be very accurately measured. The Josephson
|
896
930
|
# constant K_J, which is equal to 2e/h, relates the
|
897
|
-
# measured frequency to the potential.
|
898
|
-
# given
|
899
|
-
#
|
900
|
-
|
901
|
-
R_K 25812.
|
902
|
-
# The old approach involved maintaining resistances
|
931
|
+
# measured frequency to the potential. Two values
|
932
|
+
# given, the conventional (exact) value from 1990 and
|
933
|
+
# the current CODATA measured value.
|
934
|
+
R_K90 25812.807 ohm # Measurement of the ohm also presents difficulties.
|
935
|
+
R_K 25812.8074555 ohm # The old approach involved maintaining resistances
|
903
936
|
# that were subject to drift. The new standard is
|
904
937
|
# based on the Hall effect. When a current carrying
|
905
938
|
# ribbon is placed in a magnetic field, a potential
|
@@ -910,8 +943,9 @@ R_K 25812.8074434 ohm # Measurement of the ohm also presents difficulties.
|
|
910
943
|
# in discrete jumps when the magnetic field is very
|
911
944
|
# large and the temperature very low. This enables
|
912
945
|
# accurate realization of the resistance h/e^2 in the
|
913
|
-
# lab.
|
914
|
-
#
|
946
|
+
# lab. Two values given, the conventional (exact)
|
947
|
+
# value from 1990 and the current CODATA measured
|
948
|
+
# value.
|
915
949
|
|
916
950
|
# Various conventional values
|
917
951
|
|
@@ -951,7 +985,7 @@ H2O100C 0.95838 force gram / cm^3
|
|
951
985
|
|
952
986
|
# Atomic constants
|
953
987
|
|
954
|
-
Rinfinity 10973731.
|
988
|
+
Rinfinity 10973731.568539 /m # The wavelengths of a spectral series
|
955
989
|
R_H 10967760 /m # can be expressed as
|
956
990
|
# 1/lambda = R (1/m^2 - 1/n^2).
|
957
991
|
# where R is a number that various
|
@@ -961,9 +995,9 @@ R_H 10967760 /m # can be expressed as
|
|
961
995
|
# approaches Rinfinity, which can be
|
962
996
|
# computed from
|
963
997
|
# m_e c alpha^2 / 2 h
|
964
|
-
# with a loss of
|
998
|
+
# with a loss of 4 digits
|
965
999
|
# of precision.
|
966
|
-
alpha 7.
|
1000
|
+
alpha 7.2973525664e-3 # The fine structure constant was
|
967
1001
|
# introduced to explain fine
|
968
1002
|
# structure visible in spectral
|
969
1003
|
# lines. It can be computed from
|
@@ -976,7 +1010,7 @@ prout 185.5 keV # nuclear binding energy equal to 1|12
|
|
976
1010
|
# binding energy of the deuteron
|
977
1011
|
# Planck constants
|
978
1012
|
|
979
|
-
planckmass 2.
|
1013
|
+
planckmass 2.17651e-8 kg # sqrt(hbar c / G)
|
980
1014
|
m_P planckmass
|
981
1015
|
plancktime hbar / planckmass c^2
|
982
1016
|
t_P plancktime
|
@@ -986,28 +1020,28 @@ l_P plancklength
|
|
986
1020
|
# Particle radius
|
987
1021
|
|
988
1022
|
electronradius (1/4 pi epsilon0) e^2 / electronmass c^2 # Classical
|
989
|
-
deuteronchargeradius 2.
|
990
|
-
protonchargeradius 0.
|
1023
|
+
deuteronchargeradius 2.1413e-15 m
|
1024
|
+
protonchargeradius 0.8751e-15 m
|
991
1025
|
|
992
1026
|
# Masses of elementary particles
|
993
1027
|
|
994
|
-
electronmass 5.
|
1028
|
+
electronmass 5.48579909070e-4 u
|
995
1029
|
m_e electronmass
|
996
|
-
protonmass 1.
|
1030
|
+
protonmass 1.007276466879 u
|
997
1031
|
m_p protonmass
|
998
|
-
neutronmass 1.
|
1032
|
+
neutronmass 1.00866491588 u
|
999
1033
|
m_n neutronmass
|
1000
|
-
muonmass 0.
|
1034
|
+
muonmass 0.1134289257 u
|
1001
1035
|
m_mu muonmass
|
1002
|
-
deuteronmass 2.
|
1036
|
+
deuteronmass 2.013553212745 u
|
1003
1037
|
m_d deuteronmass
|
1004
|
-
alphaparticlemass 4.
|
1038
|
+
alphaparticlemass 4.001506179127 u
|
1005
1039
|
m_alpha alphaparticlemass
|
1006
1040
|
taumass 1.90749 u
|
1007
1041
|
m_tau taumass
|
1008
|
-
tritonmass 3.
|
1042
|
+
tritonmass 3.01550071632 u
|
1009
1043
|
m_t tritonmass
|
1010
|
-
helionmass 3.
|
1044
|
+
helionmass 3.01493224673 u
|
1011
1045
|
m_h helionmass
|
1012
1046
|
|
1013
1047
|
|
@@ -1028,13 +1062,13 @@ bohrmagneton e hbar / 2 electronmass
|
|
1028
1062
|
mu_B bohrmagneton
|
1029
1063
|
nuclearmagneton e hbar / 2 protonmass
|
1030
1064
|
mu_N nuclearmagneton
|
1031
|
-
mu_mu -4.
|
1032
|
-
mu_p 1.
|
1033
|
-
mu_e -928.
|
1034
|
-
mu_n -0.
|
1035
|
-
mu_d 0.
|
1036
|
-
mu_t 1.
|
1037
|
-
mu_h -1.
|
1065
|
+
mu_mu -4.49044826e-26 J/T # Muon magnetic moment
|
1066
|
+
mu_p 1.4106067873e-26 J/T # Proton magnetic moment
|
1067
|
+
mu_e -928.4764620e-26 J/T # Electron magnetic moment
|
1068
|
+
mu_n -0.96623650e-26 J/T # Neutron magnetic moment
|
1069
|
+
mu_d 0.4330735040e-26 J/T # Deuteron magnetic moment
|
1070
|
+
mu_t 1.504609503e-26 J/T # Triton magnetic moment
|
1071
|
+
mu_h -1.074617522e-26 J/T # Helion magnetic moment
|
1038
1072
|
|
1039
1073
|
|
1040
1074
|
#
|
@@ -1046,10 +1080,11 @@ technicalatmosphere kgf / cm^2
|
|
1046
1080
|
at technicalatmosphere
|
1047
1081
|
hyl kgf s^2 / m # Also gram-force s^2/m according to [15]
|
1048
1082
|
mmHg mm Hg
|
1049
|
-
torr
|
1050
|
-
|
1051
|
-
|
1052
|
-
|
1083
|
+
torr atm / 760 # The torr, named after Evangelista
|
1084
|
+
# Torricelli, and is very close to the mm Hg
|
1085
|
+
tor Pa # Suggested in 1913 but seldom used [24].
|
1086
|
+
# Eventually renamed the Pascal. Don't
|
1087
|
+
# confuse the tor with the torr.
|
1053
1088
|
inHg inch Hg
|
1054
1089
|
inH2O inch water
|
1055
1090
|
mmH2O mm water
|
@@ -1214,6 +1249,21 @@ faraday_chem 96495.7 C # element. (The chemical and physical
|
|
1214
1249
|
kappline 6000 maxwell # Named by and for Gisbert Kapp
|
1215
1250
|
siemensunit 0.9534 ohm # Resistance of a meter long column of
|
1216
1251
|
# mercury with a 1 mm cross section.
|
1252
|
+
#
|
1253
|
+
# Printed circuit board units.
|
1254
|
+
#
|
1255
|
+
# http://www.ndt-ed.org/GeneralResources/IACS/IACS.htm.
|
1256
|
+
#
|
1257
|
+
# Conductivity is often expressed as a percentage of IACS. A copper wire a
|
1258
|
+
# meter long with a 1 mm^2 cross section has a resistance of 1|58 ohm at
|
1259
|
+
# 20 deg C. Copper density is also standarized at that temperature.
|
1260
|
+
#
|
1261
|
+
|
1262
|
+
copperconductivity 58 siemens m / mm^2 # A wire a meter long with
|
1263
|
+
IACS copperconductivity # a 1 mm^2 cross section
|
1264
|
+
copperdensity 8.89 g/cm^3 # The "ounce" measures the
|
1265
|
+
ouncecopper oz / ft^2 copperdensity # thickness of copper used
|
1266
|
+
ozcu ouncecopper # in circuitboard fabrication
|
1217
1267
|
|
1218
1268
|
#
|
1219
1269
|
# Photometric units
|
@@ -1285,7 +1335,7 @@ footlambert cd / pi ft^2
|
|
1285
1335
|
# bril means doubling the luminance. A luminance of 1 lambert is defined to
|
1286
1336
|
# have a brilliance of 1 bril.
|
1287
1337
|
|
1288
|
-
bril(x) units=[;lambert] 2^(x+-100) lamberts ;log2(bril/lambert)+100
|
1338
|
+
bril(x) units=[1;lambert] 2^(x+-100) lamberts ;log2(bril/lambert)+100
|
1289
1339
|
|
1290
1340
|
# Some luminance data from the IES Lighting Handbook, 8th ed, 1993
|
1291
1341
|
|
@@ -1297,69 +1347,222 @@ skylum 8000 cd/m^2 # average, clear sky
|
|
1297
1347
|
skylum_o 2000 cd/m^2 # average, overcast sky
|
1298
1348
|
moonlum 2500 cd/m^2
|
1299
1349
|
|
1350
|
+
#
|
1300
1351
|
# Photographic Exposure Value
|
1352
|
+
# This section by Jeff Conrad (jeff_conrad@msn.com)
|
1301
1353
|
#
|
1302
|
-
# The Additive Photographic EXposure (APEX)
|
1303
|
-
# was an attempt to simplify exposure determination for people who
|
1304
|
-
# exposure tables rather than exposure meters. Shortly thereafter,
|
1305
|
-
# cameras incorporated exposure meters, so the APEX system never
|
1306
|
-
# but the concept of
|
1354
|
+
# The Additive system of Photographic EXposure (APEX) proposed in ASA
|
1355
|
+
# PH2.5-1960 was an attempt to simplify exposure determination for people who
|
1356
|
+
# relied on exposure tables rather than exposure meters. Shortly thereafter,
|
1357
|
+
# nearly all cameras incorporated exposure meters, so the APEX system never
|
1358
|
+
# caught on, but the concept of exposure value remains in use. Though given as
|
1359
|
+
# 'Ev' in ASA PH2.5-1960, it is now more commonly indicated by 'EV'. EV is
|
1360
|
+
# related to exposure parameters by
|
1307
1361
|
#
|
1308
1362
|
# A^2 LS ES
|
1309
1363
|
# 2^EV = --- = -- = --
|
1310
|
-
#
|
1364
|
+
# t K C
|
1311
1365
|
#
|
1312
1366
|
# Where
|
1313
1367
|
# A = Relative aperture (f-number)
|
1314
|
-
#
|
1368
|
+
# t = Exposure time in seconds
|
1315
1369
|
# L = Scene luminance in cd/m2
|
1316
1370
|
# E = Scene illuminance in lux
|
1317
|
-
# S = Arithmetic ISO
|
1371
|
+
# S = Arithmetic ISO speed
|
1318
1372
|
# K = Reflected-light meter calibration constant
|
1319
1373
|
# C = Incident-light meter calibration constant
|
1320
1374
|
#
|
1321
|
-
#
|
1322
|
-
#
|
1323
|
-
# luminance
|
1324
|
-
#
|
1325
|
-
# Common practice is to use an ISO film speed of 100 (because film speeds
|
1326
|
-
# are in even 1/3-step increments, the exact value is 64 * 2^(2|3)).
|
1375
|
+
# Strictly, an exposure value is a combination of aperture and exposure time,
|
1376
|
+
# but it's also commonly used to indicate luminance (or illuminance).
|
1377
|
+
# Conversion to luminance or illuminance units depends on the ISO speed and the
|
1378
|
+
# meter calibration constant. Common practice is to use an ISO speed of 100.
|
1327
1379
|
# Calibration constants vary among camera and meter manufacturers: Canon,
|
1328
1380
|
# Nikon, and Sekonic use a value of 12.5 for reflected-light meters, while
|
1329
|
-
# Kenko (formerly Minolta) and Pentax use a value of 14. Kenko and
|
1330
|
-
#
|
1331
|
-
#
|
1332
|
-
|
1333
|
-
#
|
1334
|
-
#
|
1335
|
-
|
1336
|
-
#
|
1337
|
-
|
1338
|
-
# ISO speed standards (e.g., ISO 6:1993) do not discuss "exact" values;
|
1339
|
-
# this value assumes ISO 100 is exact.
|
1381
|
+
# Kenko (formerly Minolta) and Pentax use a value of 14. Kenko and Sekonic use
|
1382
|
+
# a value of 250 for incident-light meters with flat receptors.
|
1383
|
+
#
|
1384
|
+
# The values for in-camera meters apply only averaging, weighted-averaging, or
|
1385
|
+
# spot metering--the multi-segment metering incorporated in most current
|
1386
|
+
# cameras uses proprietary algorithms that evaluate many factors related to the
|
1387
|
+
# luminance distribution of what is being metered; they are not amenable to
|
1388
|
+
# simple conversions, and are usually not disclosed by the manufacturers.
|
1340
1389
|
|
1341
|
-
s100 100 / lx s
|
1390
|
+
s100 100 / lx s # ISO 100 speed
|
1342
1391
|
iso100 s100
|
1343
1392
|
|
1344
1393
|
# Reflected-light meter calibration constant with ISO 100 speed
|
1345
1394
|
|
1346
|
-
k1250 12.5 (cd/m2) / lx s
|
1347
|
-
k1400 14 (cd/m2) / lx s
|
1395
|
+
k1250 12.5 (cd/m2) / lx s # For Canon, Nikon, and Sekonic
|
1396
|
+
k1400 14 (cd/m2) / lx s # For Kenko (Minolta) and Pentax
|
1348
1397
|
|
1349
1398
|
# Incident-light meter calibration constant with ISO 100 film
|
1350
1399
|
|
1351
|
-
c250 250 lx / lx s
|
1400
|
+
c250 250 lx / lx s # flat-disc receptor
|
1352
1401
|
|
1353
|
-
# Exposure value to scene luminance with ISO 100
|
1402
|
+
# Exposure value to scene luminance with ISO 100 imaging media
|
1354
1403
|
|
1355
1404
|
# For Kenko (Minolta) or Pentax
|
1356
|
-
#ev100(x) units=[;cd/m^2] 2^x k1400 / s100; log2(ev100 s100
|
1405
|
+
#ev100(x) units=[;cd/m^2] range=(0,) 2^x k1400 / s100; log2(ev100 s100/k1400)
|
1357
1406
|
# For Canon, Nikon, or Sekonic
|
1358
|
-
ev100(x) units=[;cd/m^2] 2^x k1250 / s100; log2(ev100 s100
|
1407
|
+
ev100(x) units=[1;cd/m^2] range=(0,) 2^x k1250 / s100; log2(ev100 s100/k1250)
|
1408
|
+
EV100() ev100
|
1409
|
+
|
1410
|
+
# Exposure value to scene illuminance with ISO 100 imaging media
|
1411
|
+
|
1412
|
+
iv100(x) units=[1;lx] range=(0,) 2^x c250 / s100; log2(iv100 s100 / c250)
|
1413
|
+
|
1414
|
+
# Other Photographic Exposure Conversions
|
1415
|
+
#
|
1416
|
+
# As part of APEX, ASA PH2.5-1960 proposed several logarithmic quantities
|
1417
|
+
# related by
|
1418
|
+
#
|
1419
|
+
# Ev = Av + Tv = Bv + Sv
|
1420
|
+
#
|
1421
|
+
# where
|
1422
|
+
# Av = log2(A^2) Aperture value
|
1423
|
+
# Tv = log2(1/t) Time value
|
1424
|
+
# Sv = log2(N Sx) Speed value
|
1425
|
+
# Bv = log2(B S / K) Luminance ("brightness") value
|
1426
|
+
# Iv = log2(I S / C) Illuminance value
|
1427
|
+
#
|
1428
|
+
# and
|
1429
|
+
# A = Relative aperture (f-number)
|
1430
|
+
# t = Exposure time in seconds
|
1431
|
+
# Sx = Arithmetic ISO speed in 1/lux s
|
1432
|
+
# B = luminance in cd/m2
|
1433
|
+
# I = luminance in lux
|
1434
|
+
|
1435
|
+
# The constant N derives from the arcane relationship between arithmetic
|
1436
|
+
# and logarithmic speed given in ASA PH2.5-1960. That relationship
|
1437
|
+
# apparently was not obvious--so much so that it was thought necessary
|
1438
|
+
# to explain it in PH2.12-1961. The constant has had several values
|
1439
|
+
# over the years, usually without explanation for the changes. Although
|
1440
|
+
# APEX had little impact on consumer cameras, it has seen a partial
|
1441
|
+
# resurrection in the Exif standards published by the Camera & Imaging
|
1442
|
+
# Products Association of Japan.
|
1443
|
+
|
1444
|
+
#N_apex 2^-1.75 lx s # precise value implied in ASA PH2.12-1961,
|
1445
|
+
# derived from ASA PH2.5-1960.
|
1446
|
+
#N_apex 0.30 lx s # rounded value in ASA PH2.5-1960,
|
1447
|
+
# ASA PH2.12-1961, and ANSI PH2.7-1986
|
1448
|
+
#N_apex 0.3162 lx s # value in ANSI PH2.7-1973
|
1449
|
+
N_exif 1|3.125 lx s # value in Exif 2.3 (2010), making Sv(5) = 100
|
1450
|
+
K_apex1961 11.4 (cd/m2) / lx s # value in ASA PH2.12-1961
|
1451
|
+
K_apex1971 12.5 (cd/m2) / lx s # value in ANSI PH3.49-1971; more common
|
1452
|
+
C_apex1961 224 lx / lx s # value in PH2.12-1961 (20.83 for I in
|
1453
|
+
# footcandles; flat sensor?)
|
1454
|
+
C_apex1971 322 lx / lx s # mean value in PH3.49-1971 (30 +/- 5 for I in
|
1455
|
+
# footcandles; hemispherical sensor?)
|
1456
|
+
N_speed N_exif
|
1457
|
+
K_lum K_apex1971
|
1458
|
+
C_illum C_apex1961
|
1459
|
+
|
1460
|
+
# Units for Photographic Exposure Variables
|
1461
|
+
#
|
1462
|
+
# Practical photography sometimes pays scant attention to units for exposure
|
1463
|
+
# variables. In particular, the "speed" of the imaging medium is treated as if
|
1464
|
+
# it were dimensionless when it should have units of reciprocal lux seconds;
|
1465
|
+
# this practice works only because "speed" is almost invariably given in
|
1466
|
+
# accordance with international standards (or similar ones used by camera
|
1467
|
+
# manufacturers)--so the assumed units are invariant. In calculating
|
1468
|
+
# logarithmic quantities--especially the time value Tv and the exposure value
|
1469
|
+
# EV--the units for exposure time ("shutter speed") are often ignored; this
|
1470
|
+
# practice works only because the units of exposure time are assumed to be in
|
1471
|
+
# seconds, and the missing units that make the argument to the logarithmic
|
1472
|
+
# function dimensionless are silently provided.
|
1473
|
+
#
|
1474
|
+
# In keeping with common practice, the definitions that follow treat "speeds"
|
1475
|
+
# as dimensionless, so ISO 100 speed is given simply as '100'. When
|
1476
|
+
# calculating the logarithmic APEX quantities Av and Tv, the definitions
|
1477
|
+
# provide the missing units, so the times can be given with any appropriate
|
1478
|
+
# units. For example, giving an exposure time of 1 minute as either '1 min' or
|
1479
|
+
# '60 s' will result in Tv of -5.9068906.
|
1480
|
+
#
|
1481
|
+
# Exposure Value from f-number and Exposure Time
|
1482
|
+
#
|
1483
|
+
# Because nonlinear unit conversions only accept a single quantity,
|
1484
|
+
# there is no direct conversion from f-number and exposure time to
|
1485
|
+
# exposure value EV. But the EV can be obtained from a combination of
|
1486
|
+
# Av and Tv. For example, the "sunny 16" rule states that correct
|
1487
|
+
# exposure for a sunlit scene can achieved by using f/16 and an exposure
|
1488
|
+
# time equal to the reciprocal of the ISO speed in seconds; this can be
|
1489
|
+
# calculated as
|
1490
|
+
#
|
1491
|
+
# ~Av(16) + ~Tv(1|100 s),
|
1492
|
+
#
|
1493
|
+
# which gives 14.643856. These conversions may be combined with the
|
1494
|
+
# ev100 conversion:
|
1495
|
+
#
|
1496
|
+
# ev100(~Av(16) + ~Tv(1|100 s))
|
1497
|
+
#
|
1498
|
+
# to yield the assumed average scene luminance of 3200 cd/m^2.
|
1499
|
+
|
1500
|
+
# convert relative aperture (f-number) to aperture value
|
1501
|
+
Av(A) units=[1;1] domain=[-2,) range=[0.5,) 2^(A/2); 2 log2(Av)
|
1502
|
+
# convert exposure time to time value
|
1503
|
+
Tv(t) units=[1;s] range=(0,) 2^(-t) s; log2(s / Tv)
|
1504
|
+
# convert logarithmic speed Sv in ASA PH2.5-1960 to ASA/ISO arithmetic speed;
|
1505
|
+
# make arithmetic speed dimensionless
|
1506
|
+
# 'Sv' conflicts with the symbol for sievert; you can uncomment this function
|
1507
|
+
# definition if you don't need that symbol
|
1508
|
+
#Sv(S) units=[1;1] range=(0,) 2^S / (N_speed/lx s); log2((N_speed/lx s) Sv)
|
1509
|
+
Sval(S) units=[1;1] range=(0,) 2^S / (N_speed/lx s); log2((N_speed/lx s) Sval)
|
1510
|
+
|
1511
|
+
# convert luminance value Bv in ASA PH2.12-1961 to luminance
|
1512
|
+
Bv(x) units=[1;cd/m^2] range=(0,) \
|
1513
|
+
2^x K_lum N_speed ; log2(Bv / (K_lum N_speed))
|
1514
|
+
|
1515
|
+
# convert illuminance value Iv in ASA PH2.12-1961 to illuminance
|
1516
|
+
Iv(x) units=[1;lx] range=(0,) \
|
1517
|
+
2^x C_illum N_speed ; log2(Iv / (C_illum N_speed))
|
1518
|
+
|
1519
|
+
# convert ASA/ISO arithmetic speed Sx to ASA logarithmic speed in
|
1520
|
+
# ASA PH2.5-1960; make arithmetic speed dimensionless
|
1521
|
+
Sx(S) units=[1;1] domain=(0,) \
|
1522
|
+
log2((N_speed/lx s) S); 2^Sx / (N_speed/lx s)
|
1523
|
+
|
1524
|
+
# convert DIN speed/ISO logarithmic speed in ISO 6:1993 to arithmetic speed
|
1525
|
+
# for convenience, speed is treated here as if it were dimensionless
|
1526
|
+
Sdeg(S) units=[1;1] range=(0,) 10^((S - 1) / 10) ; (1 + 10 log(Sdeg))
|
1527
|
+
Sdin() Sdeg
|
1528
|
+
|
1529
|
+
# Numerical Aperture and f-Number of a Lens
|
1530
|
+
#
|
1531
|
+
# The numerical aperture (NA) is given by
|
1532
|
+
#
|
1533
|
+
# NA = n sin(theta)
|
1534
|
+
#
|
1535
|
+
# where n is the index of refraction of the medium and theta is half
|
1536
|
+
# of the angle subtended by the aperture stop from a point in the image
|
1537
|
+
# or object plane. For a lens in air, n = 1, and
|
1538
|
+
#
|
1539
|
+
# NA = 0.5 / f-number
|
1540
|
+
#
|
1541
|
+
# convert NA to f-number
|
1542
|
+
numericalaperture(x) units=[1;1] domain=(0,1] range=[0.5,) \
|
1543
|
+
0.5 / x ; 0.5 / numericalaperture
|
1544
|
+
NA() numericalaperture
|
1545
|
+
#
|
1546
|
+
# convert f-number to itself; restrict values to those possible
|
1547
|
+
fnumber(x) units=[1;1] domain=[0.5,) range=[0.5,) x ; fnumber
|
1548
|
+
|
1549
|
+
# Referenced Photographic Standards
|
1550
|
+
#
|
1551
|
+
# ASA PH-2.5-1960. USA Standard, Method for Determining (Monochrome,
|
1552
|
+
# Continuous-Tone) Speed of Photographic Negative Materials.
|
1553
|
+
# ASA PH2.12-1961. American Standard, General-Purpose Photographic
|
1554
|
+
# Exposure Meters (photoelectric type).
|
1555
|
+
# ANSI PH3.49-1971. American National Standard for general-purpose
|
1556
|
+
# photographic exposure meters (photoelectric type).
|
1557
|
+
# ANSI PH2.7-1973. American National Standard Photographic Exposure Guide.
|
1558
|
+
# ANSI PH2.7-1986. American National Standard for Photography --
|
1559
|
+
# Photographic Exposure Guide.
|
1560
|
+
# CIPA DC-008-2010. Exchangeable image file format for digital still
|
1561
|
+
# cameras: Exif Version 2.3
|
1562
|
+
# ISO 6:1993. International Standard, Photography -- Black-and-white
|
1563
|
+
# pictorial still camera negative film/process systems --
|
1564
|
+
# Determination of ISO Speed.
|
1359
1565
|
|
1360
|
-
# Exposure value to scene illuminance with ISO 100 film
|
1361
|
-
|
1362
|
-
iv100(x) units=[1;lx] 2^x c250 / s100; log2(iv100 s100 / c250)
|
1363
1566
|
|
1364
1567
|
#
|
1365
1568
|
# Astronomical time measurements
|
@@ -1948,7 +2151,6 @@ eushot 25 ml # EU standard spirits measure
|
|
1948
2151
|
fifth 1|5 usgallon
|
1949
2152
|
winebottle 750 ml # US industry standard, 1979
|
1950
2153
|
winesplit 1|4 winebottle
|
1951
|
-
wineglass 4 usfloz
|
1952
2154
|
magnum 1.5 liter # Standardized in 1979, but given
|
1953
2155
|
# as 2 qt in some references
|
1954
2156
|
metrictenth 375 ml
|
@@ -1971,6 +2173,44 @@ salmanazar 6 magnum
|
|
1971
2173
|
balthazar 8 magnum
|
1972
2174
|
nebuchadnezzar 10 magnum
|
1973
2175
|
|
2176
|
+
# The wine glass doesn't seem to have an official standard, but the same value
|
2177
|
+
# is suggested by several organization.
|
2178
|
+
|
2179
|
+
# https://www.rethinkingdrinking.niaaa.nih.gov/
|
2180
|
+
# http://www.rethinkyourdrinking.ca/what-is-a-standard-drink/
|
2181
|
+
# https://www.drinkaware.co.uk/
|
2182
|
+
# https://www.gov.uk/government/uploads/system/uploads/attachment_data/file/545937/UK_CMOs__report.pdf
|
2183
|
+
# http://www.alcohol.gov.au/internet/alcohol/publishing.nsf/content/drinksguide-cnt
|
2184
|
+
|
2185
|
+
wineglass 150 mL # the size of a "typical" serving
|
2186
|
+
|
2187
|
+
# A unit of alcohol is a specified mass of pure ethyl alcohol.
|
2188
|
+
# The term is used officially in the UK, but other countries use the same
|
2189
|
+
# concept but with different values. For example, the UK value of 8 g is
|
2190
|
+
# nominally the amount of alcohol that a typical adult can metabolize in
|
2191
|
+
# one hour. Values for several countries, converted to a volumetric basis:
|
2192
|
+
|
2193
|
+
alcoholunitus 14 g / ethanoldensity
|
2194
|
+
alcoholunitca 13.6 g / ethanoldensity
|
2195
|
+
alcoholunituk 8 g / ethanoldensity
|
2196
|
+
alcoholunitau 10 g / ethanoldensity
|
2197
|
+
|
2198
|
+
# Example: for 12% ABV (alcohol by volume)
|
2199
|
+
# alcoholunitus / 12% = 147.8 mL, close to the “standard” serving of 150 mL.
|
2200
|
+
|
2201
|
+
|
2202
|
+
# Coffee
|
2203
|
+
#
|
2204
|
+
# The recommended ratio of coffee to water. Values vary considerably;
|
2205
|
+
# one is from the Specialty Coffee Association of America
|
2206
|
+
# http://scaa.org/?page=resources&d=brewing-best-practices
|
2207
|
+
|
2208
|
+
coffeeratio 55 g/L # ± 10%
|
2209
|
+
|
2210
|
+
# other recommendations are more loose, e.g.,
|
2211
|
+
# http://www.ncausa.org/About-Coffee/How-to-Brew-Coffee
|
2212
|
+
|
2213
|
+
|
1974
2214
|
#
|
1975
2215
|
# Water is "hard" if it contains various minerals, expecially calcium
|
1976
2216
|
# carbonate.
|
@@ -2000,13 +2240,13 @@ shoe_women0 (7+11|12) inch
|
|
2000
2240
|
shoe_boys0 (3+11|12) inch
|
2001
2241
|
shoe_girls0 (3+7|12) inch
|
2002
2242
|
|
2003
|
-
shoesize_men(n) units=[;inch] shoe_men0 + n shoesize_delta ; \
|
2243
|
+
shoesize_men(n) units=[1;inch] shoe_men0 + n shoesize_delta ; \
|
2004
2244
|
(shoesize_men+(-shoe_men0))/shoesize_delta
|
2005
|
-
shoesize_women(n) units=[;inch] shoe_women0 + n shoesize_delta ; \
|
2245
|
+
shoesize_women(n) units=[1;inch] shoe_women0 + n shoesize_delta ; \
|
2006
2246
|
(shoesize_women+(-shoe_women0))/shoesize_delta
|
2007
|
-
shoesize_boys(n) units=[;inch] shoe_boys0 + n shoesize_delta ; \
|
2247
|
+
shoesize_boys(n) units=[1;inch] shoe_boys0 + n shoesize_delta ; \
|
2008
2248
|
(shoesize_boys+(-shoe_boys0))/shoesize_delta
|
2009
|
-
shoesize_girls(n) units=[;inch] shoe_girls0 + n shoesize_delta ; \
|
2249
|
+
shoesize_girls(n) units=[1;inch] shoe_girls0 + n shoesize_delta ; \
|
2010
2250
|
(shoesize_girls+(-shoe_girls0))/shoesize_delta
|
2011
2251
|
|
2012
2252
|
# European shoe size. According to
|
@@ -2264,12 +2504,12 @@ shaftment 6 inch # Distance from tip of outstretched thumb to the
|
|
2264
2504
|
smoot 5 ft + 7 in # Created as part of an MIT fraternity prank.
|
2265
2505
|
# In 1958 Oliver Smoot was used to measure
|
2266
2506
|
# the length of the Harvard Bridge, which was
|
2267
|
-
# marked off in
|
2507
|
+
# marked off in Smoot lengths. These
|
2268
2508
|
# markings have been maintained on the bridge
|
2269
2509
|
# since then and repainted by subsequent
|
2270
2510
|
# incoming fraternity members. During a
|
2271
|
-
# bridge
|
2272
|
-
# scored every
|
2511
|
+
# bridge renovation the new sidewalk was
|
2512
|
+
# scored every Smoot rather than at the
|
2273
2513
|
# customary 6 ft spacing.
|
2274
2514
|
#
|
2275
2515
|
# Cooking measures
|
@@ -2427,6 +2667,11 @@ eggvolume 3 ustablespoons + 1|2 ustsp
|
|
2427
2667
|
eggwhitevolume 2 ustablespoons
|
2428
2668
|
eggyolkvolume 3.5 ustsp
|
2429
2669
|
|
2670
|
+
# Alcohol density
|
2671
|
+
|
2672
|
+
ethanoldensity 0.7893 g/cm^3 # From CRC Handbook, 91st Edition
|
2673
|
+
alcoholdensity ethanoldensity
|
2674
|
+
|
2430
2675
|
#
|
2431
2676
|
# Density measures. Density has traditionally been measured on a variety of
|
2432
2677
|
# bizarre nonlinear scales.
|
@@ -2557,18 +2802,18 @@ sugar_bpC(T) units=[1;g/cm^3] domain=[100,139.1636] range=[0.99717,1.5144619]\
|
|
2557
2802
|
# Holland had a value of 144, and the new scale or Gerlach scale used 146.78.
|
2558
2803
|
|
2559
2804
|
baumeconst 145 # US value
|
2560
|
-
baume(d) units=[1;g/cm^3] domain=[0,
|
2805
|
+
baume(d) units=[1;g/cm^3] domain=[0,145) range=[1,) \
|
2561
2806
|
(baumeconst/(baumeconst+-d)) g/cm^3 ; \
|
2562
2807
|
(baume+((-g)/cm^3)) baumeconst / baume
|
2563
2808
|
|
2564
2809
|
# It's not clear if this value was ever used with negative degrees.
|
2565
|
-
twaddell(x) units=[1;g/cm^3] domain=[-200,
|
2810
|
+
twaddell(x) units=[1;g/cm^3] domain=[-200,) range=[0,) \
|
2566
2811
|
(1 + 0.005 x) g / cm^3 ; \
|
2567
2812
|
200 (twaddell / (g/cm^3) +- 1)
|
2568
2813
|
|
2569
2814
|
# The degree quevenne is a unit for measuring the density of milk.
|
2570
2815
|
# Similarly it's unclear if negative values were allowed here.
|
2571
|
-
quevenne(x) units=[1;g/cm^3] domain=[-1000,
|
2816
|
+
quevenne(x) units=[1;g/cm^3] domain=[-1000,) range=[0,) \
|
2572
2817
|
(1 + 0.001 x) g / cm^3 ; \
|
2573
2818
|
1000 (quevenne / (g/cm^3) +- 1)
|
2574
2819
|
|
@@ -2606,7 +2851,7 @@ brix[0.99717g/cm^3]\
|
|
2606
2851
|
#
|
2607
2852
|
# The intervals of range and domain should be open rather than closed.
|
2608
2853
|
#
|
2609
|
-
apidegree(x) units=[1;g/cm^3] domain=[-131.5,
|
2854
|
+
apidegree(x) units=[1;g/cm^3] domain=[-131.5,) range=[0,) \
|
2610
2855
|
141.5 g/cm^3 / (x+131.5) ; \
|
2611
2856
|
141.5 (g/cm^3) / apidegree + (-131.5)
|
2612
2857
|
|
@@ -2622,6 +2867,9 @@ pdl poundal
|
|
2622
2867
|
osi ounce force / inch^2 # used in aviation
|
2623
2868
|
psi pound force / inch^2
|
2624
2869
|
psia psi # absolute pressure
|
2870
|
+
# Note that gauge pressure can be given
|
2871
|
+
# using the gaugepressure() and
|
2872
|
+
# psig() nonlinear unit definitions
|
2625
2873
|
tsi ton force / inch^2
|
2626
2874
|
reyn psi sec
|
2627
2875
|
slug lbf s^2 / ft
|
@@ -2700,28 +2948,46 @@ count per pound # For measuring the size of shrimp
|
|
2700
2948
|
ENERGY joule
|
2701
2949
|
WORK joule
|
2702
2950
|
|
2703
|
-
#
|
2951
|
+
# Calorie: approximate energy to raise a gram of water one degree celsius
|
2704
2952
|
|
2705
|
-
|
2706
|
-
cal_th 4.184 J # Thermochemical calorie
|
2707
|
-
cal_fifteen 4.18580 J # Energy to go from 14.5 to 15.5 degC
|
2708
|
-
cal_twenty 4.18190 J # Energy to go from 19.5 to 20.5 degC
|
2709
|
-
cal_mean 4.19002 J # 1|100 energy to go from 0 to 100 degC
|
2710
|
-
calorie cal_IT
|
2953
|
+
calorie cal_th # Default is the thermochemical calorie
|
2711
2954
|
cal calorie
|
2712
|
-
|
2713
|
-
thermcalorie
|
2714
|
-
calorie_th
|
2955
|
+
calorie_th 4.184 J # Thermochemical calorie, defined in 1930
|
2956
|
+
thermcalorie calorie_th # by Frederick Rossini as 4.1833 J to
|
2957
|
+
cal_th calorie_th # avoid difficulties associated with the
|
2958
|
+
# uncertainty in the heat capacity of
|
2959
|
+
# water. In 1948 the value of the joule
|
2960
|
+
# was changed, so the thermochemical
|
2961
|
+
# calorie was redefined to 4.184 J.
|
2962
|
+
# This kept the energy measured by this
|
2963
|
+
# unit the same.
|
2964
|
+
calorie_IT 4.1868 J # International (Steam) Table calorie,
|
2965
|
+
cal_IT calorie_IT # defined in 1929 as watt-hour/860 or
|
2966
|
+
# equivalently 180|43 joules. At this
|
2967
|
+
# time the international joule had a
|
2968
|
+
# different value than the modern joule,
|
2969
|
+
# and the values were different in the
|
2970
|
+
# USA and in Europe. In 1956 at the
|
2971
|
+
# Fifth International Conference on
|
2972
|
+
# Properties of Steam the exact
|
2973
|
+
# definition given here was adopted.
|
2974
|
+
calorie_15 4.18580 J # Energy to go from 14.5 to 15.5 degC
|
2975
|
+
cal_15 calorie_15
|
2976
|
+
calorie_fifteen cal_15
|
2977
|
+
calorie_20 4.18190 J # Energy to go from 19.5 to 20.5 degC
|
2978
|
+
cal_20 calorie_20
|
2979
|
+
calorie_twenty calorie_20
|
2980
|
+
cal_mean 4.19002 J # 1|100 energy to go from 0 to 100 degC
|
2715
2981
|
Calorie kilocalorie # the food Calorie
|
2716
|
-
thermie 1e6
|
2982
|
+
thermie 1e6 cal_15 # Heat required to raise the
|
2717
2983
|
# temperature of a tonne of
|
2718
2984
|
# water from 14.5 to 15.5 degC.
|
2719
2985
|
|
2720
2986
|
# btu definitions: energy to raise a pound of water 1 degF
|
2721
2987
|
|
2722
|
-
btu
|
2988
|
+
btu btu_IT # International Table BTU is the default
|
2723
2989
|
britishthermalunit btu
|
2724
|
-
btu_IT
|
2990
|
+
btu_IT cal_IT lb degF / gram K
|
2725
2991
|
btu_th cal_th lb degF / gram K
|
2726
2992
|
btu_mean cal_mean lb degF / gram K
|
2727
2993
|
quad quadrillion btu
|
@@ -2730,6 +2996,99 @@ ECtherm 1.05506e8 J # Exact definition, close to 1e5 btu
|
|
2730
2996
|
UStherm 1.054804e8 J # Exact definition
|
2731
2997
|
therm UStherm
|
2732
2998
|
|
2999
|
+
# Water latent heat from [23]
|
3000
|
+
|
3001
|
+
water_fusion_heat 6.01 kJ/mol / (18.015 g/mol) # At 0 deg C
|
3002
|
+
water_vaporization_heat 2256.4 J/g # At saturation, 100 deg C, 101.42 kPa
|
3003
|
+
|
3004
|
+
# Specific heat capacities of various substances
|
3005
|
+
|
3006
|
+
specificheat_water calorie / g K
|
3007
|
+
water_specificheat specificheat_water
|
3008
|
+
# Values from www.engineeringtoolbox.com/specific-heat-metals-d_152.html
|
3009
|
+
specificheat_aluminum 0.91 J/g K
|
3010
|
+
specificheat_antimony 0.21 J/g K
|
3011
|
+
specificheat_barium 0.20 J/g K
|
3012
|
+
specificheat_beryllium 1.83 J/g K
|
3013
|
+
specificheat_bismuth 0.13 J/g K
|
3014
|
+
specificheat_cadmium 0.23 J/g K
|
3015
|
+
specificheat_cesium 0.24 J/g K
|
3016
|
+
specificheat_chromium 0.46 J/g K
|
3017
|
+
specificheat_cobalt 0.42 J/g K
|
3018
|
+
specificheat_copper 0.39 J/g K
|
3019
|
+
specificheat_gallium 0.37 J/g K
|
3020
|
+
specificheat_germanium 0.32 J/g K
|
3021
|
+
specificheat_gold 0.13 J/g K
|
3022
|
+
specificheat_hafnium 0.14 J/g K
|
3023
|
+
specificheat_indium 0.24 J/g K
|
3024
|
+
specificheat_iridium 0.13 J/g K
|
3025
|
+
specificheat_iron 0.45 J/g K
|
3026
|
+
specificheat_lanthanum 0.195 J/g K
|
3027
|
+
specificheat_lead 0.13 J/g K
|
3028
|
+
specificheat_lithium 3.57 J/g K
|
3029
|
+
specificheat_lutetium 0.15 J/g K
|
3030
|
+
specificheat_magnesium 1.05 J/g K
|
3031
|
+
specificheat_manganese 0.48 J/g K
|
3032
|
+
specificheat_mercury 0.14 J/g K
|
3033
|
+
specificheat_molybdenum 0.25 J/g K
|
3034
|
+
specificheat_nickel 0.44 J/g K
|
3035
|
+
specificheat_osmium 0.13 J/g K
|
3036
|
+
specificheat_palladium 0.24 J/g K
|
3037
|
+
specificheat_platinum 0.13 J/g K
|
3038
|
+
specificheat_plutonum 0.13 J/g K
|
3039
|
+
specificheat_potassium 0.75 J/g K
|
3040
|
+
specificheat_rhenium 0.14 J/g K
|
3041
|
+
specificheat_rhodium 0.24 J/g K
|
3042
|
+
specificheat_rubidium 0.36 J/g K
|
3043
|
+
specificheat_ruthenium 0.24 J/g K
|
3044
|
+
specificheat_scandium 0.57 J/g K
|
3045
|
+
specificheat_selenium 0.32 J/g K
|
3046
|
+
specificheat_silicon 0.71 J/g K
|
3047
|
+
specificheat_silver 0.23 J/g K
|
3048
|
+
specificheat_sodium 1.21 J/g K
|
3049
|
+
specificheat_strontium 0.30 J/g K
|
3050
|
+
specificheat_tantalum 0.14 J/g K
|
3051
|
+
specificheat_thallium 0.13 J/g K
|
3052
|
+
specificheat_thorium 0.13 J/g K
|
3053
|
+
specificheat_tin 0.21 J/g K
|
3054
|
+
specificheat_titanium 0.54 J/g K
|
3055
|
+
specificheat_tungsten 0.13 J/g K
|
3056
|
+
specificheat_uranium 0.12 J/g K
|
3057
|
+
specificheat_vanadium 0.39 J/g K
|
3058
|
+
specificheat_yttrium 0.30 J/g K
|
3059
|
+
specificheat_zinc 0.39 J/g K
|
3060
|
+
specificheat_zirconium 0.27 J/g K
|
3061
|
+
specificheat_ethanol 2.3 J/g K
|
3062
|
+
specificheat_ammonia 4.6 J/g K
|
3063
|
+
specificheat_freon 0.91 J/g K # R-12 at 0 degrees Fahrenheit
|
3064
|
+
specificheat_gasoline 2.22 J/g K
|
3065
|
+
specificheat_iodine 2.15 J/g K
|
3066
|
+
specificheat_oliveoil 1.97 J/g K
|
3067
|
+
|
3068
|
+
# en.wikipedia.org/wiki/Heat_capacity#Table_of_specific_heat_capacities
|
3069
|
+
specificheat_hydrogen 14.3 J/g K
|
3070
|
+
specificheat_helium 5.1932 J/g K
|
3071
|
+
specificheat_argon 0.5203 J/g K
|
3072
|
+
specificheat_tissue 3.5 J/g K
|
3073
|
+
specificheat_diamond 0.5091 J/g K
|
3074
|
+
specificheat_granite 0.79 J/g K
|
3075
|
+
specificheat_graphite 0.71 J/g K
|
3076
|
+
specificheat_ice 2.11 J/g K
|
3077
|
+
specificheat_asphalt 0.92 J/g K
|
3078
|
+
specificheat_brick 0.84 J/g K
|
3079
|
+
specificheat_concrete 0.88 J/g K
|
3080
|
+
specificheat_glass_silica 0.84 J/g K
|
3081
|
+
specificheat_glass_flint 0.503 J/g K
|
3082
|
+
specificheat_glass_pyrex 0.753 J/g K
|
3083
|
+
specificheat_gypsum 1.09 J/g K
|
3084
|
+
specificheat_marble 0.88 J/g K
|
3085
|
+
specificheat_sand 0.835 J/g K
|
3086
|
+
specificheat_soil 0.835 J/g K
|
3087
|
+
specificheat_wood 1.7 J/g K
|
3088
|
+
|
3089
|
+
specificheat_sucrose 1.244 J/g K #www.sugartech.co.za/heatcapacity/index.php
|
3090
|
+
|
3091
|
+
|
2733
3092
|
# Energy densities of various fuels
|
2734
3093
|
#
|
2735
3094
|
# Most of these fuels have varying compositions or qualities and hence their
|
@@ -2796,6 +3155,14 @@ chu celsiusheatunit
|
|
2796
3155
|
|
2797
3156
|
POWER watt
|
2798
3157
|
|
3158
|
+
# "Apparent" average power in an AC circuit, the product of rms voltage
|
3159
|
+
# and rms current, equal to the true power in watts when voltage and
|
3160
|
+
# current are in phase. In a DC circuit, always equal to the true power.
|
3161
|
+
|
3162
|
+
VA volt ampere
|
3163
|
+
|
3164
|
+
kWh kilowatt hour
|
3165
|
+
|
2799
3166
|
# The horsepower is supposedly the power of one horse pulling. Obviously
|
2800
3167
|
# different people had different horses.
|
2801
3168
|
|
@@ -2860,15 +3227,15 @@ tog 0.1 degC m^2 / W # Also used for clothing.
|
|
2860
3227
|
# ratio, but it is used in various contexts to report a signal's power
|
2861
3228
|
# relative to some reference level.
|
2862
3229
|
|
2863
|
-
bel(x) units=[1;1] range=
|
2864
|
-
decibel(x) units=[1;1] range=
|
2865
|
-
dB(
|
2866
|
-
dBW(x) units=[1;W] range=
|
2867
|
-
dBk(x) units=[1;W] range=
|
2868
|
-
dBf(x) units=[1;W] range=
|
2869
|
-
dBm(x) units=[1;W] range=
|
2870
|
-
dBmW(x) units=[1;W] range=
|
2871
|
-
dBJ(x) units=[1;J] range=
|
3230
|
+
bel(x) units=[1;1] range=(0,) 10^(x); log(bel) # Basic bel definition
|
3231
|
+
decibel(x) units=[1;1] range=(0,) 10^(x/10); 10 log(decibel) # Basic decibel
|
3232
|
+
dB() decibel # Abbreviation
|
3233
|
+
dBW(x) units=[1;W] range=(0,) dB(x) W ; ~dB(dBW/W) # Reference = 1 W
|
3234
|
+
dBk(x) units=[1;W] range=(0,) dB(x) kW ; ~dB(dBk/kW) # Reference = 1 kW
|
3235
|
+
dBf(x) units=[1;W] range=(0,) dB(x) fW ; ~dB(dBf/fW) # Reference = 1 fW
|
3236
|
+
dBm(x) units=[1;W] range=(0,) dB(x) mW ; ~dB(dBm/mW) # Reference = 1 mW
|
3237
|
+
dBmW(x) units=[1;W] range=(0,) dBm(x) ; ~dBm(dBmW) # Reference = 1 mW
|
3238
|
+
dBJ(x) units=[1;J] range=(0,) dB(x) J; ~dB(dBJ/J) # Energy relative
|
2872
3239
|
# to 1 joule. Used for power spectral
|
2873
3240
|
# density since W/Hz = J
|
2874
3241
|
|
@@ -2876,17 +3243,17 @@ dBJ(x) units=[1;J] range=[0,] dB(x) J; ~dB(dBJ/J) # Energy relative
|
|
2876
3243
|
# because power is proportional to the square of these measures. The root
|
2877
3244
|
# mean square (RMS) voltage is typically used with these units.
|
2878
3245
|
|
2879
|
-
dBV(x) units=[1;V] range=
|
2880
|
-
dBmV(x) units=[1;V] range=
|
2881
|
-
dBuV(x) units=[1;V] range=
|
3246
|
+
dBV(x) units=[1;V] range=(0,) dB(0.5 x) V;~dB(dBV^2 / V^2) # Reference = 1 V
|
3247
|
+
dBmV(x) units=[1;V] range=(0,) dB(0.5 x) mV;~dB(dBmV^2/mV^2)# Reference = 1 mV
|
3248
|
+
dBuV(x) units=[1;V] range=(0,) dB(0.5 x) microV ; ~dB(dBuV^2 / microV^2)
|
2882
3249
|
# Reference = 1 microvolt
|
2883
3250
|
|
2884
3251
|
# Referenced to the voltage that causes 1 mW dissipation in a 600 ohm load.
|
2885
3252
|
# Originally defined as dBv but changed to prevent confusion with dBV.
|
2886
3253
|
# The "u" is for unloaded.
|
2887
|
-
dBu(x) units=[1;V] range=
|
3254
|
+
dBu(x) units=[1;V] range=(0,) dB(0.5 x) sqrt(mW 600 ohm) ; \
|
2888
3255
|
~dB(dBu^2 / mW 600 ohm)
|
2889
|
-
dBv(x) units=[1;V] range=
|
3256
|
+
dBv(x) units=[1;V] range=(0,) dBu(x) ; ~dBu(dBv) # Synonym for dBu
|
2890
3257
|
|
2891
3258
|
|
2892
3259
|
# Measurements for sound in air, referenced to the threshold of human hearing
|
@@ -2894,11 +3261,11 @@ dBv(x) units=[1;V] range=[0,] dBu(x) ; ~dBu(dBv) # Synonym for dBu
|
|
2894
3261
|
# for sound pressure. Units dBA, dBB, dBC, refer to different frequency
|
2895
3262
|
# weightings meant to approximate the human ear's response.
|
2896
3263
|
|
2897
|
-
dBSPL(x) units=[1;Pa] range=
|
3264
|
+
dBSPL(x) units=[1;Pa] range=(0,) dB(0.5 x) 20 microPa ; \
|
2898
3265
|
~dB(dBSPL^2 / (20 microPa)^2) # pressure
|
2899
|
-
dBSIL(x) units=[1;W/m^2] range=
|
3266
|
+
dBSIL(x) units=[1;W/m^2] range=(0,) dB(x) 1e-12 W/m^2; \
|
2900
3267
|
~dB(dBSIL / (1e-12 W/m^2)) # intensity
|
2901
|
-
dBSWL(x) units=[1;W] range=
|
3268
|
+
dBSWL(x) units=[1;W] range=(0,) dB(x) 1e-12 W; ~dB(dBSWL/1e-12 W)
|
2902
3269
|
|
2903
3270
|
|
2904
3271
|
# Misc other measures
|
@@ -2914,12 +3281,26 @@ tonrefrigeration uston 144 btu / lb day # One ton refrigeration is
|
|
2914
3281
|
# latent heat of 144 btu/lb.
|
2915
3282
|
tonref tonrefrigeration
|
2916
3283
|
refrigeration tonref / ton
|
2917
|
-
frigorie 1000
|
2918
|
-
tnt 1e9 cal_th / ton# So you can write tons
|
3284
|
+
frigorie 1000 cal_15 # Used in refrigeration engineering.
|
3285
|
+
tnt 1e9 cal_th / ton# So you can write tons tnt. This
|
2919
3286
|
# is a defined, not measured, value.
|
2920
3287
|
airwatt 8.5 (ft^3/min) inH2O # Measure of vacuum power as
|
2921
3288
|
# pressure times air flow.
|
2922
3289
|
|
3290
|
+
# Nuclear weapon yields
|
3291
|
+
|
3292
|
+
davycrocket 10 ton tnt # lightest US tactical nuclear weapon
|
3293
|
+
hiroshima 15.5 kiloton tnt # Uranium-235 fission bomb
|
3294
|
+
nagasaki 21 kiloton tnt # Plutonium-239 fission bomb
|
3295
|
+
fatman nagasaki
|
3296
|
+
littleboy hiroshima
|
3297
|
+
ivyking 500 kiloton tnt # most powerful fission bomb
|
3298
|
+
castlebravo 15 megaton tnt # most powerful US test
|
3299
|
+
b53bomb 9 megaton tnt
|
3300
|
+
# http://rarehistoricalphotos.com/gadget-first-atomic-bomb/
|
3301
|
+
trinity 18 kiloton tnt # July 16, 1945
|
3302
|
+
gadget trinity
|
3303
|
+
|
2923
3304
|
#
|
2924
3305
|
# Permeability: The permeability or permeance, n, of a substance determines
|
2925
3306
|
# how fast vapor flows through the substance. The formula W = n A dP
|
@@ -2983,7 +3364,49 @@ Cpaper 17 inch 22 inch
|
|
2983
3364
|
Dpaper 22 inch 34 inch
|
2984
3365
|
Epaper 34 inch 44 inch
|
2985
3366
|
|
2986
|
-
|
3367
|
+
# Correspondence envelope sizes. #10 is the standard business
|
3368
|
+
# envelope in the USA.
|
3369
|
+
|
3370
|
+
envelope6_25size 3.5 inch 6 inch
|
3371
|
+
envelope6_75size 3.625 inch 6.5 inch
|
3372
|
+
envelope7size 3.75 inch 6.75 inch
|
3373
|
+
envelope7_75size 3.875 inch 7.5 inch
|
3374
|
+
envelope8_625size 3.625 inch 8.625 inch
|
3375
|
+
envelope9size 3.875 inch 8.875 inch
|
3376
|
+
envelope10size 4.125 inch 9.5 inch
|
3377
|
+
envelope11size 4.5 inch 10.375 inch
|
3378
|
+
envelope12size 4.75 inch 11 inch
|
3379
|
+
envelope14size 5 inch 11.5 inch
|
3380
|
+
envelope16size 6 inch 12 inch
|
3381
|
+
|
3382
|
+
# Announcement envelope sizes (no relation to metric paper sizes like A4)
|
3383
|
+
|
3384
|
+
envelopeA1size 3.625 inch 5.125 inch # same as 4bar
|
3385
|
+
envelopeA2size 4.375 inch 5.75 inch
|
3386
|
+
envelopeA6size 4.75 inch 6.5 inch
|
3387
|
+
envelopeA7size 5.25 inch 7.25 inch
|
3388
|
+
envelopeA8size 5.5 inch 8.125 inch
|
3389
|
+
envelopeA9size 5.75 inch 8.75 inch
|
3390
|
+
envelopeA10size 6 inch 9.5 inch
|
3391
|
+
|
3392
|
+
# Baronial envelopes
|
3393
|
+
|
3394
|
+
envelope4bar 3.625 inch 5.125 inch # same as A1
|
3395
|
+
envelope5_5bar 4.375 inch 5.75 inch
|
3396
|
+
envelope6bar 4.75 inch 6.5 inch
|
3397
|
+
|
3398
|
+
# Coin envelopes
|
3399
|
+
|
3400
|
+
envelope1baby 2.25 inch 3.5 inch # same as #1 coin
|
3401
|
+
envelope00coin 1.6875 inch 2.75 inch
|
3402
|
+
envelope1coin 2.25 inch 3.5 inch
|
3403
|
+
envelope3coin 2.5 inch 4.25 inch
|
3404
|
+
envelope4coin 3 inch 4.5 inch
|
3405
|
+
envelope4_5coin 3 inch 4.875 inch
|
3406
|
+
envelope5coin 2.875 inch 5.25 inch
|
3407
|
+
envelope5_5coin 3.125 inch 5.5 inch
|
3408
|
+
envelope6coin 3.375 inch 6 inch
|
3409
|
+
envelope7coin 3.5 inch 6.5 inch
|
2987
3410
|
|
2988
3411
|
# The metric paper sizes are defined so that if a sheet is cut in half
|
2989
3412
|
# along the short direction, the result is two sheets which are
|
@@ -3108,9 +3531,10 @@ paperM lb / 1000
|
|
3108
3531
|
# convert these units roughly (using an approximate density) into the standard
|
3109
3532
|
# paper weight values.
|
3110
3533
|
|
3534
|
+
pointthickness 0.001 in
|
3111
3535
|
paperdensity 0.8 g/cm^3 # approximate--paper densities vary!
|
3112
3536
|
papercaliper in paperdensity
|
3113
|
-
paperpoint
|
3537
|
+
paperpoint pointthickness paperdensity
|
3114
3538
|
|
3115
3539
|
#
|
3116
3540
|
# Printing
|
@@ -3223,10 +3647,12 @@ grobe_sabon 84 didotpoint
|
|
3223
3647
|
|
3224
3648
|
INFORMATION bit
|
3225
3649
|
|
3226
|
-
nat ln(2) bits
|
3650
|
+
nat (1/ln(2)) bits # Entropy measured base e
|
3227
3651
|
hartley log2(10) bits # Entropy of a uniformly
|
3228
|
-
|
3652
|
+
ban hartley # distributed random variable
|
3229
3653
|
# over 10 symbols.
|
3654
|
+
dit hartley # from Decimal digIT
|
3655
|
+
|
3230
3656
|
#
|
3231
3657
|
# Computer
|
3232
3658
|
#
|
@@ -3298,7 +3724,26 @@ dvdspeed 1385 kB/s # This is the "1x" speed of a DVD using
|
|
3298
3724
|
# as they go from the inside to the
|
3299
3725
|
# outside of the disc.
|
3300
3726
|
# See http://www.osta.org/technology/dvdqa/dvdqa4.htm
|
3727
|
+
#
|
3728
|
+
# The IP address space is divided into subnets. The number of hosts
|
3729
|
+
# in a subnet depends on the length of the subnet prefix. This is
|
3730
|
+
# often written as /N where N is the number of bits in the prefix.
|
3731
|
+
#
|
3732
|
+
# https://en.wikipedia.org/wiki/Subnetwork
|
3733
|
+
#
|
3734
|
+
# These definitions gives the number of hosts for a subnet whose
|
3735
|
+
# prefix has the specified length in bits.
|
3736
|
+
#
|
3737
|
+
|
3738
|
+
ipv4subnetsize(prefix_len) units=[1;1] domain=[0,32] range=[1,4294967296] \
|
3739
|
+
2^(32-prefix_len) ; 32-log2(ipv4subnetsize)
|
3740
|
+
#ipv4classA ipv4subnetsize(8)
|
3741
|
+
#ipv4classB ipv4subnetsize(16)
|
3742
|
+
#ipv4classC ipv4subnetsize(24)
|
3301
3743
|
|
3744
|
+
ipv6subnetsize(prefix_len) units=[1;1] domain=[0,128] \
|
3745
|
+
range=[1,340282366920938463463374607431768211456] \
|
3746
|
+
2^(128-prefix_len) ; 128-log2(ipv6subnetsize)
|
3302
3747
|
|
3303
3748
|
#
|
3304
3749
|
# Musical measures. Musical intervals expressed as ratios. Multiply
|
@@ -3326,7 +3771,7 @@ pythagoreancomma musicalfifth^12 / octave^7
|
|
3326
3771
|
# Equal tempered definitions
|
3327
3772
|
|
3328
3773
|
semitone octave^(1|12)
|
3329
|
-
musicalcent(x) units=[1;1] range=
|
3774
|
+
musicalcent(x) units=[1;1] range=(0,) semitone^(x/100) ; \
|
3330
3775
|
100 log(musicalcent)/log(semitone)
|
3331
3776
|
|
3332
3777
|
#
|
@@ -3425,6 +3870,7 @@ bloodunit 450 ml # For whole blood. For blood
|
|
3425
3870
|
|
3426
3871
|
frenchcathetersize 1|3 mm # measure used for the outer diameter
|
3427
3872
|
# of a catheter
|
3873
|
+
charriere frenchcathetersize
|
3428
3874
|
|
3429
3875
|
|
3430
3876
|
#
|
@@ -3445,7 +3891,72 @@ megalerg megaerg # 'L' added to make it pronounceable [18].
|
|
3445
3891
|
#
|
3446
3892
|
|
3447
3893
|
unitedstatesdollar US$
|
3894
|
+
usdollar US$
|
3448
3895
|
$ dollar
|
3896
|
+
#mark germanymark
|
3897
|
+
#bolivar venezuelabolivar
|
3898
|
+
#venezuelanbolivarfuerte venezuelabolivar
|
3899
|
+
#bolivarfuerte bolivar # The currency was revalued by
|
3900
|
+
#oldbolivar 1|1000 bolivar # a factor of 1000.
|
3901
|
+
#peseta spainpeseta
|
3902
|
+
#rand southafricarand
|
3903
|
+
#escudo portugalescudo
|
3904
|
+
#guilder netherlandsguilder
|
3905
|
+
#hollandguilder netherlandsguilder
|
3906
|
+
#peso mexicopeso
|
3907
|
+
#yen japanyen
|
3908
|
+
#lira italylira
|
3909
|
+
#rupee indiarupee
|
3910
|
+
#drachma greecedrachma
|
3911
|
+
#franc francefranc
|
3912
|
+
#markka finlandmarkka
|
3913
|
+
#britainpound unitedkingdompound
|
3914
|
+
#greatbritainpound unitedkingdompound
|
3915
|
+
#unitedkingdompound ukpound
|
3916
|
+
#poundsterling britainpound
|
3917
|
+
#yuan chinayuan
|
3918
|
+
|
3919
|
+
# Some European currencies have permanent fixed exchange rates with
|
3920
|
+
# the Euro. These rates were taken from the EC's web site:
|
3921
|
+
# http://ec.europa.eu/economy_finance/euro/adoption/conversion/index_en.htm
|
3922
|
+
|
3923
|
+
#austriaschilling 1|13.7603 euro
|
3924
|
+
#belgiumfranc 1|40.3399 euro
|
3925
|
+
#estoniakroon 1|15.6466 euro # Equal to 1|8 germanymark
|
3926
|
+
#finlandmarkka 1|5.94573 euro
|
3927
|
+
#francefranc 1|6.55957 euro
|
3928
|
+
#germanymark 1|1.95583 euro
|
3929
|
+
#greecedrachma 1|340.75 euro
|
3930
|
+
#irelandpunt 1|0.787564 euro
|
3931
|
+
#italylira 1|1936.27 euro
|
3932
|
+
#luxembourgfranc 1|40.3399 euro
|
3933
|
+
#netherlandsguilder 1|2.20371 euro
|
3934
|
+
#portugalescudo 1|200.482 euro
|
3935
|
+
#spainpeseta 1|166.386 euro
|
3936
|
+
#cypruspound 1|0.585274 euro
|
3937
|
+
#maltalira 1|0.429300 euro
|
3938
|
+
#sloveniatolar 1|239.640 euro
|
3939
|
+
#slovakiakoruna 1|30.1260 euro
|
3940
|
+
|
3941
|
+
#UKP GBP # Not an ISO code, but looks like one, and
|
3942
|
+
# # sometimes used on usenet.
|
3943
|
+
#VEB 1|1000 VEF # old venezuelan bolivar
|
3944
|
+
|
3945
|
+
!include currency.units
|
3946
|
+
|
3947
|
+
# Money on the gold standard, used in the late 19th century and early
|
3948
|
+
# 20th century.
|
3949
|
+
|
3950
|
+
#olddollargold 23.22 grains goldprice # Used until 1934
|
3951
|
+
#newdollargold 96|7 grains goldprice # After Jan 31, 1934
|
3952
|
+
#dollargold newdollargold
|
3953
|
+
#poundgold 113 grains goldprice
|
3954
|
+
#goldounce goldprice troyounce
|
3955
|
+
#silverounce silverprice troyounce
|
3956
|
+
#platinumounce platinumprice troyounce
|
3957
|
+
#XAU goldounce
|
3958
|
+
#XPT platinumounce
|
3959
|
+
#XAG silverounce
|
3449
3960
|
|
3450
3961
|
# Nominal masses of US coins. Note that dimes, quarters and half dollars
|
3451
3962
|
# have weight proportional to value. Before 1965 it was $40 / kg.
|
@@ -3457,6 +3968,45 @@ USquarterweight US$ 0.25 / (20 US$ / lb) # Since 1965
|
|
3457
3968
|
UShalfdollarweight US$ 0.50 / (20 US$ / lb) # Since 1971
|
3458
3969
|
USdollarmass 8.1 grams
|
3459
3970
|
|
3971
|
+
# British currency
|
3972
|
+
|
3973
|
+
#quid britainpound # Slang names
|
3974
|
+
#fiver 5 quid
|
3975
|
+
#tenner 10 quid
|
3976
|
+
#monkey 500 quid
|
3977
|
+
#brgrand 1000 quid
|
3978
|
+
#bob shilling
|
3979
|
+
|
3980
|
+
#shilling 1|20 britainpound # Before decimalisation, there
|
3981
|
+
#oldpence 1|12 shilling # were 20 shillings to a pound,
|
3982
|
+
#farthing 1|4 oldpence # each of twelve old pence
|
3983
|
+
#guinea 21 shilling # Still used in horse racing
|
3984
|
+
#crown 5 shilling
|
3985
|
+
#florin 2 shilling
|
3986
|
+
#groat 4 oldpence
|
3987
|
+
#tanner 6 oldpence
|
3988
|
+
#brpenny 0.01 britainpound
|
3989
|
+
#pence brpenny
|
3990
|
+
#tuppence 2 pence
|
3991
|
+
#tuppenny tuppence
|
3992
|
+
#ha'penny halfbrpenny
|
3993
|
+
#hapenny ha'penny
|
3994
|
+
#oldpenny oldpence
|
3995
|
+
#oldtuppence 2 oldpence
|
3996
|
+
#oldtuppenny oldtuppence
|
3997
|
+
#threepence 3 oldpence # threepence never refers to new money
|
3998
|
+
#threepenny threepence
|
3999
|
+
#oldthreepence threepence
|
4000
|
+
#oldthreepenny threepence
|
4001
|
+
#oldhalfpenny halfoldpenny
|
4002
|
+
#oldha'penny oldhalfpenny
|
4003
|
+
#oldhapenny oldha'penny
|
4004
|
+
#brpony 25 britainpound
|
4005
|
+
|
4006
|
+
# Canadian currency
|
4007
|
+
|
4008
|
+
#loony 1 canadadollar # This coin depicts a loon
|
4009
|
+
#toony 2 canadadollar
|
3460
4010
|
|
3461
4011
|
#
|
3462
4012
|
# Units used for measuring volume of wood
|
@@ -3507,6 +4057,11 @@ wholedeal 12 ft 11 in 1.25 in # If it's half as thick as the standard
|
|
3507
4057
|
splitdeal 12 ft 11 in 5|8 in # And half again as thick is a split deal.
|
3508
4058
|
|
3509
4059
|
|
4060
|
+
# Used for shellac mixing rate
|
4061
|
+
|
4062
|
+
poundcut pound / gallon
|
4063
|
+
lbcut poundcut
|
4064
|
+
|
3510
4065
|
#
|
3511
4066
|
# Gas and Liquid flow units
|
3512
4067
|
#
|
@@ -3581,6 +4136,151 @@ slpm atm liter/min
|
|
3581
4136
|
slph atm liter/hour
|
3582
4137
|
lusec liter micron Hg / s # Used in vacuum science
|
3583
4138
|
|
4139
|
+
# US Standard Atmosphere (1976)
|
4140
|
+
# Atmospheric temperature and pressure vs. geometric height above sea level
|
4141
|
+
# This definition covers only the troposphere (the lowest atmospheric
|
4142
|
+
# layer, up to 11 km), and assumes the layer is polytropic.
|
4143
|
+
# A polytropic process is one for which PV^k = const, where P is the
|
4144
|
+
# pressure, V is the volume, and k is the polytropic exponent. The
|
4145
|
+
# polytropic index is n = 1 / (k - 1). As noted in the Wikipedia article
|
4146
|
+
# https://en.wikipedia.org/wiki/Polytropic_process, some authors reverse
|
4147
|
+
# the definitions of "exponent" and "index." The functions below assume
|
4148
|
+
# the following parameters:
|
4149
|
+
|
4150
|
+
# temperature lapse rate, -dT/dz, in troposphere
|
4151
|
+
|
4152
|
+
lapserate 6.5 K/km # US Std Atm (1976)
|
4153
|
+
|
4154
|
+
# air molecular weight, including constituent mol wt, given
|
4155
|
+
# in Table 3, p. 3
|
4156
|
+
|
4157
|
+
air_1976 78.084 % 28.0134 \
|
4158
|
+
+ 20.9476 % 31.9988 \
|
4159
|
+
+ 9340 ppm 39.948 \
|
4160
|
+
+ 314 ppm 44.00995 \
|
4161
|
+
+ 18.18 ppm 20.183 \
|
4162
|
+
+ 5.24 ppm 4.0026 \
|
4163
|
+
+ 2 ppm 16.04303 \
|
4164
|
+
+ 1.14 ppm 83.80 \
|
4165
|
+
+ 0.55 ppm 2.01594 \
|
4166
|
+
+ 0.087 ppm 131.30
|
4167
|
+
|
4168
|
+
# universal gas constant
|
4169
|
+
R_1976 8.31432e3 N m/(kmol K)
|
4170
|
+
|
4171
|
+
# polytropic index n
|
4172
|
+
polyndx_1976 air_1976 (kg/kmol) gravity/(R_1976 lapserate) - 1
|
4173
|
+
|
4174
|
+
# If desired, redefine using current values for air mol wt and R
|
4175
|
+
|
4176
|
+
polyndx polyndx_1976
|
4177
|
+
# polyndx air (kg/kmol) gravity/(R lapserate) - 1
|
4178
|
+
|
4179
|
+
# for comparison with various references
|
4180
|
+
|
4181
|
+
polyexpnt (polyndx + 1) / polyndx
|
4182
|
+
|
4183
|
+
# The model assumes the following reference values:
|
4184
|
+
# sea-level temperature and pressure
|
4185
|
+
|
4186
|
+
stdatmT0 288.15 K
|
4187
|
+
stdatmP0 atm
|
4188
|
+
|
4189
|
+
# "effective radius" for relation of geometric to geopotential height,
|
4190
|
+
# at a latitude at which g = 9.80665 m/s (approximately 45.543 deg); no
|
4191
|
+
# relation to actual radius
|
4192
|
+
|
4193
|
+
earthradUSAtm 6356766 m
|
4194
|
+
|
4195
|
+
# Temperature vs. geopotential height h
|
4196
|
+
# Assumes 15 degC at sea level
|
4197
|
+
# Based on approx 45 deg latitude
|
4198
|
+
# Lower limits of domain and upper limits of range are those of the
|
4199
|
+
# tables in US Standard Atmosphere (NASA 1976)
|
4200
|
+
|
4201
|
+
stdatmTH(h) units=[m;K] domain=[-5000,11e3] range=[217,321] \
|
4202
|
+
stdatmT0+(-lapserate h) ; (stdatmT0+(-stdatmTH))/lapserate
|
4203
|
+
|
4204
|
+
# Temperature vs. geometric height z; based on approx 45 deg latitude
|
4205
|
+
stdatmT(z) units=[m;K] domain=[-5000,11e3] range=[217,321] \
|
4206
|
+
stdatmTH(geop_ht(z)) ; ~geop_ht(~stdatmTH(stdatmT))
|
4207
|
+
|
4208
|
+
# Pressure vs. geopotential height h
|
4209
|
+
# Assumes 15 degC and 101325 Pa at sea level
|
4210
|
+
# Based on approx 45 deg latitude
|
4211
|
+
# Lower limits of domain and upper limits of range are those of the
|
4212
|
+
# tables in US Standard Atmosphere (NASA 1976)
|
4213
|
+
|
4214
|
+
stdatmPH(h) units=[m;Pa] domain=[-5000,11e3] range=[22877,177764] \
|
4215
|
+
atm (1 - (lapserate/stdatmT0) h)^(polyndx + 1) ; \
|
4216
|
+
(stdatmT0/lapserate) (1+(-(stdatmPH/stdatmP0)^(1/(polyndx + 1))))
|
4217
|
+
|
4218
|
+
# Pressure vs. geometric height z; based on approx 45 deg latitude
|
4219
|
+
stdatmP(z) units=[m;Pa] domain=[-5000,11e3] range=[22877,177764] \
|
4220
|
+
stdatmPH(geop_ht(z)); ~geop_ht(~stdatmPH(stdatmP))
|
4221
|
+
|
4222
|
+
# Geopotential height from geometric height
|
4223
|
+
# Based on approx 45 deg latitude
|
4224
|
+
# Lower limits of domain and range are somewhat arbitrary; they
|
4225
|
+
# correspond to the limits in the US Std Atm tables
|
4226
|
+
|
4227
|
+
geop_ht(z) units=[m;m] domain=[-5000,) range=[-5004,) \
|
4228
|
+
(earthradUSAtm z) / (earthradUSAtm + z) ; \
|
4229
|
+
(earthradUSAtm geop_ht) / (earthradUSAtm + (-geop_ht))
|
4230
|
+
|
4231
|
+
# The standard value for the sea-level acceleration due to gravity is
|
4232
|
+
# 9.80665 m/s^2, but the actual value varies with latitude (Harrison 1949)
|
4233
|
+
# R_eff = 2 g_phi / denom
|
4234
|
+
# g_phi = 978.0356e-2 (1+0.0052885 sin(lat)^2+(-0.0000059) sin(2 lat)^2)
|
4235
|
+
# or
|
4236
|
+
# g_phi = 980.6160e-2 (1+(-0.0026373) cos(2 lat)+0.0000059 cos(2 lat)^2)
|
4237
|
+
# denom = 3.085462e-6+2.27e-9 cos(2 lat)+(-2e-12) cos(4 lat) (minutes?)
|
4238
|
+
# There is no inverse function; the standard value applies at a latitude
|
4239
|
+
# of about 45.543 deg
|
4240
|
+
|
4241
|
+
g_phi(lat) units=[deg;m/s2] domain=[0,90] noerror \
|
4242
|
+
980.6160e-2 (1+(-0.0026373) cos(2 lat)+0.0000059 cos(2 lat)^2) m/s2
|
4243
|
+
|
4244
|
+
# effective Earth radius for relation of geometric height to
|
4245
|
+
# geopotential height, as function of latitude (Harrison 1949)
|
4246
|
+
|
4247
|
+
earthradius_eff(lat) units=[deg;m] domain=[0,90] noerror \
|
4248
|
+
m 2 9.780356 (1+0.0052885 sin(lat)^2+(-0.0000059) sin(2 lat)^2) / \
|
4249
|
+
(3.085462e-6 + 2.27e-9 cos(2 lat) + (-2e-12) cos(4 lat))
|
4250
|
+
|
4251
|
+
# References
|
4252
|
+
# Harrison, L.P. 1949. Relation Between Geopotential and Geometric
|
4253
|
+
# Height. In Smithsonian Meteorological Tables. List, Robert J., ed.
|
4254
|
+
# 6th ed., 4th reprint, 1968. Washington, DC: Smithsonian Institution.
|
4255
|
+
# NASA. US National Aeronautics and Space Administration. 1976.
|
4256
|
+
# US Standard Atmosphere 1976. Washington, DC: US Government Printing Office.
|
4257
|
+
|
4258
|
+
# Gauge pressure functions
|
4259
|
+
#
|
4260
|
+
# Gauge pressure is measured relative to atmospheric pressure. In the English
|
4261
|
+
# system, where pressure is often given in pounds per square inch, gauge
|
4262
|
+
# pressure is often indicated by 'psig' to distinguish it from absolute
|
4263
|
+
# pressure, often indicated by 'psia'. At the standard atmospheric pressure
|
4264
|
+
# of 14.696 psia, a gauge pressure of 0 psig is an absolute pressure of 14.696
|
4265
|
+
# psia; an automobile tire inflated to 31 psig has an absolute pressure of
|
4266
|
+
# 45.696 psia.
|
4267
|
+
#
|
4268
|
+
# With gaugepressure(), the units must be specified (e.g., gaugepressure(1.5
|
4269
|
+
# bar)); with psig(), the units are taken as psi, so the example above of tire
|
4270
|
+
# pressure could be given as psig(31).
|
4271
|
+
#
|
4272
|
+
# If the normal elevation is significantly different from sea level, change
|
4273
|
+
# Patm appropriately, and adjust the lower domain limit on the gaugepressure
|
4274
|
+
# definition.
|
4275
|
+
|
4276
|
+
Patm atm
|
4277
|
+
|
4278
|
+
gaugepressure(x) units=[Pa;Pa] domain=[-101325,) range=[0,) \
|
4279
|
+
x + Patm ; gaugepressure+(-Patm)
|
4280
|
+
|
4281
|
+
psig(x) units=[1;Pa] domain=[-14.6959487755135,) range=[0,) \
|
4282
|
+
gaugepressure(x psi) ; ~gaugepressure(psig) / psi
|
4283
|
+
|
3584
4284
|
#
|
3585
4285
|
# Wire Gauge
|
3586
4286
|
#
|
@@ -3619,8 +4319,9 @@ g0000000 (-6)
|
|
3619
4319
|
# measure the thickness of sheets of aluminum, copper, and most metals other
|
3620
4320
|
# than steel, iron and zinc.
|
3621
4321
|
|
3622
|
-
wiregauge(g) units=[;m] range=
|
4322
|
+
wiregauge(g) units=[1;m] range=(0,) \
|
3623
4323
|
1|200 92^((36+(-g))/39) in; 36+(-39)ln(200 wiregauge/in)/ln(92)
|
4324
|
+
awg() wiregauge
|
3624
4325
|
|
3625
4326
|
# Next we have the SWG, the Imperial or British Standard Wire Gauge. This one
|
3626
4327
|
# is piecewise linear. It was used for aluminum sheets.
|
@@ -3703,6 +4404,107 @@ zincgauge[in] \
|
|
3703
4404
|
27 0.5 \
|
3704
4405
|
28 1
|
3705
4406
|
|
4407
|
+
#
|
4408
|
+
# Imperial drill bit sizes are reported in inches or in a numerical or
|
4409
|
+
# letter gauge.
|
4410
|
+
#
|
4411
|
+
|
4412
|
+
drillgauge[in] \
|
4413
|
+
1 0.2280 \
|
4414
|
+
2 0.2210 \
|
4415
|
+
3 0.2130 \
|
4416
|
+
4 0.2090 \
|
4417
|
+
5 0.2055 \
|
4418
|
+
6 0.2040 \
|
4419
|
+
7 0.2010 \
|
4420
|
+
8 0.1990 \
|
4421
|
+
9 0.1960 \
|
4422
|
+
10 0.1935 \
|
4423
|
+
11 0.1910 \
|
4424
|
+
12 0.1890 \
|
4425
|
+
13 0.1850 \
|
4426
|
+
14 0.1820 \
|
4427
|
+
15 0.1800 \
|
4428
|
+
16 0.1770 \
|
4429
|
+
17 0.1730 \
|
4430
|
+
18 0.1695 \
|
4431
|
+
19 0.1660 \
|
4432
|
+
20 0.1610 \
|
4433
|
+
22 0.1570 \
|
4434
|
+
23 0.1540 \
|
4435
|
+
24 0.1520 \
|
4436
|
+
25 0.1495 \
|
4437
|
+
26 0.1470 \
|
4438
|
+
27 0.1440 \
|
4439
|
+
28 0.1405 \
|
4440
|
+
29 0.1360 \
|
4441
|
+
30 0.1285 \
|
4442
|
+
31 0.1200 \
|
4443
|
+
32 0.1160 \
|
4444
|
+
33 0.1130 \
|
4445
|
+
34 0.1110 \
|
4446
|
+
35 0.1100 \
|
4447
|
+
36 0.1065 \
|
4448
|
+
38 0.1015 \
|
4449
|
+
39 0.0995 \
|
4450
|
+
40 0.0980 \
|
4451
|
+
41 0.0960 \
|
4452
|
+
42 0.0935 \
|
4453
|
+
43 0.0890 \
|
4454
|
+
44 0.0860 \
|
4455
|
+
45 0.0820 \
|
4456
|
+
46 0.0810 \
|
4457
|
+
48 0.0760 \
|
4458
|
+
51 0.0670 \
|
4459
|
+
52 0.0635 \
|
4460
|
+
53 0.0595 \
|
4461
|
+
54 0.0550 \
|
4462
|
+
55 0.0520 \
|
4463
|
+
56 0.0465 \
|
4464
|
+
57 0.0430 \
|
4465
|
+
65 0.0350 \
|
4466
|
+
66 0.0330 \
|
4467
|
+
68 0.0310 \
|
4468
|
+
69 0.0292 \
|
4469
|
+
70 0.0280 \
|
4470
|
+
71 0.0260 \
|
4471
|
+
73 0.0240 \
|
4472
|
+
74 0.0225 \
|
4473
|
+
75 0.0210 \
|
4474
|
+
76 0.0200 \
|
4475
|
+
78 0.0160 \
|
4476
|
+
79 0.0145 \
|
4477
|
+
80 0.0135 \
|
4478
|
+
88 0.0095 \
|
4479
|
+
104 0.0031
|
4480
|
+
|
4481
|
+
drillA 0.234 in
|
4482
|
+
drillB 0.238 in
|
4483
|
+
drillC 0.242 in
|
4484
|
+
drillD 0.246 in
|
4485
|
+
drillE 0.250 in
|
4486
|
+
drillF 0.257 in
|
4487
|
+
drillG 0.261 in
|
4488
|
+
drillH 0.266 in
|
4489
|
+
drillI 0.272 in
|
4490
|
+
drillJ 0.277 in
|
4491
|
+
drillK 0.281 in
|
4492
|
+
drillL 0.290 in
|
4493
|
+
drillM 0.295 in
|
4494
|
+
drillN 0.302 in
|
4495
|
+
drillO 0.316 in
|
4496
|
+
drillP 0.323 in
|
4497
|
+
drillQ 0.332 in
|
4498
|
+
drillR 0.339 in
|
4499
|
+
drillS 0.348 in
|
4500
|
+
drillT 0.358 in
|
4501
|
+
drillU 0.368 in
|
4502
|
+
drillV 0.377 in
|
4503
|
+
drillW 0.386 in
|
4504
|
+
drillX 0.397 in
|
4505
|
+
drillY 0.404 in
|
4506
|
+
drillZ 0.413 in
|
4507
|
+
|
3706
4508
|
#
|
3707
4509
|
# Screw sizes
|
3708
4510
|
#
|
@@ -3710,7 +4512,7 @@ zincgauge[in] \
|
|
3710
4512
|
# Metric screws are reported as Mxx where xx is the diameter in mm.
|
3711
4513
|
#
|
3712
4514
|
|
3713
|
-
screwgauge(g) units=[;m] range=[0,
|
4515
|
+
screwgauge(g) units=[1;m] range=[0,) \
|
3714
4516
|
(.06 + .013 g) in ; (screwgauge/in + (-.06)) / .013
|
3715
4517
|
|
3716
4518
|
#
|
@@ -3876,8 +4678,7 @@ ansibonded[micron] \
|
|
3876
4678
|
1000 5.8 \
|
3877
4679
|
1200 3.8
|
3878
4680
|
|
3879
|
-
grit_ansibonded(
|
3880
|
-
ansibonded(x); ~ansibonded(grit_ansibonded)
|
4681
|
+
grit_ansibonded() ansibonded
|
3881
4682
|
|
3882
4683
|
# Like the bonded grit, the coated macrogrits below 240 are taken from the
|
3883
4684
|
# FEPA F table. Data above this is from the UAMA site. Note that the coated
|
@@ -3890,7 +4691,7 @@ grit_ansibonded(x) units=[1;micron] domain=[4,1200] range=[3.8,4890] \
|
|
3890
4691
|
# Because of this non-monotonicity from 600 grit to 800 grit this definition
|
3891
4692
|
# produces a warning about the lack of a unique inverse.
|
3892
4693
|
|
3893
|
-
ansicoated[micron] \
|
4694
|
+
ansicoated[micron] noerror \
|
3894
4695
|
4 4890 \
|
3895
4696
|
5 4125 \
|
3896
4697
|
6 3460 \
|
@@ -3933,8 +4734,7 @@ ansicoated[micron] \
|
|
3933
4734
|
6000 2 \
|
3934
4735
|
8000 1.2
|
3935
4736
|
|
3936
|
-
grit_ansicoated(
|
3937
|
-
ansicoated(x); ~ansicoated(grit_ansicoated)
|
4737
|
+
grit_ansicoated() ansicoated
|
3938
4738
|
|
3939
4739
|
|
3940
4740
|
#
|
@@ -4030,6 +4830,173 @@ hardblackarkansas 6 micron
|
|
4030
4830
|
hardwhitearkansas 11 micron
|
4031
4831
|
washita 35 micron
|
4032
4832
|
|
4833
|
+
#
|
4834
|
+
# Mesh systems for measuring particle sizes by sifting through a wire
|
4835
|
+
# mesh or sieve
|
4836
|
+
#
|
4837
|
+
|
4838
|
+
# The Tyler system and US Sieve system are based on four steps for
|
4839
|
+
# each factor of 2 change in the size, so each size is 2^1|4 different
|
4840
|
+
# from the adjacent sizes. Unfortunately, the mesh numbers are
|
4841
|
+
# arbitrary, so the sizes cannot be expressed with a functional form.
|
4842
|
+
# Various references round the values differently. The mesh numbers
|
4843
|
+
# are supposed to correspond to the number of holes per inch, but this
|
4844
|
+
# correspondence is only approximate because it doesn't include the
|
4845
|
+
# wire size of the mesh.
|
4846
|
+
|
4847
|
+
# The Tyler Mesh system was apparently introduced by the WS Tyler
|
4848
|
+
# company, but it appears that they no longer use it. They follow the
|
4849
|
+
# ASTM E11 standard.
|
4850
|
+
|
4851
|
+
meshtyler[micron] \
|
4852
|
+
2.5 8000 \
|
4853
|
+
3 6727 \
|
4854
|
+
3.5 5657 \
|
4855
|
+
4 4757 \
|
4856
|
+
5 4000 \
|
4857
|
+
6 3364 \
|
4858
|
+
7 2828 \
|
4859
|
+
8 2378 \
|
4860
|
+
9 2000 \
|
4861
|
+
10 1682 \
|
4862
|
+
12 1414 \
|
4863
|
+
14 1189 \
|
4864
|
+
16 1000 \
|
4865
|
+
20 841 \
|
4866
|
+
24 707 \
|
4867
|
+
28 595 \
|
4868
|
+
32 500 \
|
4869
|
+
35 420 \
|
4870
|
+
42 354 \
|
4871
|
+
48 297 \
|
4872
|
+
60 250 \
|
4873
|
+
65 210 \
|
4874
|
+
80 177 \
|
4875
|
+
100 149 \
|
4876
|
+
115 125 \
|
4877
|
+
150 105 \
|
4878
|
+
170 88 \
|
4879
|
+
200 74 \
|
4880
|
+
250 63 \
|
4881
|
+
270 53 \
|
4882
|
+
325 44 \
|
4883
|
+
400 37
|
4884
|
+
|
4885
|
+
# US Sieve size, ASTM E11
|
4886
|
+
#
|
4887
|
+
# The WS Tyler company prints the list from ASTM E11 in their catalog,
|
4888
|
+
# http://wstyler.com/wp-content/uploads/2015/11/Product-Catalog-2.pdf
|
4889
|
+
|
4890
|
+
sieve[micron] \
|
4891
|
+
3.5 5600 \
|
4892
|
+
4 4750 \
|
4893
|
+
5 4000 \
|
4894
|
+
6 3350 \
|
4895
|
+
7 2800 \
|
4896
|
+
8 2360 \
|
4897
|
+
10 2000 \
|
4898
|
+
12 1700 \
|
4899
|
+
14 1400 \
|
4900
|
+
16 1180 \
|
4901
|
+
18 1000 \
|
4902
|
+
20 850 \
|
4903
|
+
25 710 \
|
4904
|
+
30 600 \
|
4905
|
+
35 500 \
|
4906
|
+
40 425 \
|
4907
|
+
45 355 \
|
4908
|
+
50 300 \
|
4909
|
+
60 250 \
|
4910
|
+
70 212 \
|
4911
|
+
80 180 \
|
4912
|
+
100 150 \
|
4913
|
+
120 125 \
|
4914
|
+
140 106 \
|
4915
|
+
170 90 \
|
4916
|
+
200 75 \
|
4917
|
+
230 63 \
|
4918
|
+
270 53 \
|
4919
|
+
325 45 \
|
4920
|
+
400 38 \
|
4921
|
+
450 32 \
|
4922
|
+
500 25 \
|
4923
|
+
625 20 # These last two values are not in the standard series
|
4924
|
+
# but were included in the ASTM standard because they
|
4925
|
+
meshUS() sieve # were in common usage.
|
4926
|
+
|
4927
|
+
# British Mesh size, BS 410: 1986
|
4928
|
+
# This system appears to correspond to the Tyler and US system, but
|
4929
|
+
# with different mesh numbers.
|
4930
|
+
#
|
4931
|
+
# http://www.panadyne.com/technical/panadyne_international_sieve_chart.pdf
|
4932
|
+
#
|
4933
|
+
|
4934
|
+
meshbritish[micron] \
|
4935
|
+
3 5657 \
|
4936
|
+
3.5 4757 \
|
4937
|
+
4 4000 \
|
4938
|
+
5 3364 \
|
4939
|
+
6 2828 \
|
4940
|
+
7 2378 \
|
4941
|
+
8 2000 \
|
4942
|
+
10 1682 \
|
4943
|
+
12 1414 \
|
4944
|
+
14 1189 \
|
4945
|
+
16 1000 \
|
4946
|
+
18 841 \
|
4947
|
+
22 707 \
|
4948
|
+
25 595 \
|
4949
|
+
30 500 \
|
4950
|
+
36 420 \
|
4951
|
+
44 354 \
|
4952
|
+
52 297 \
|
4953
|
+
60 250 \
|
4954
|
+
72 210 \
|
4955
|
+
85 177 \
|
4956
|
+
100 149 \
|
4957
|
+
120 125 \
|
4958
|
+
150 105 \
|
4959
|
+
170 88 \
|
4960
|
+
200 74 \
|
4961
|
+
240 63 \
|
4962
|
+
300 53 \
|
4963
|
+
350 44 \
|
4964
|
+
400 37
|
4965
|
+
|
4966
|
+
# French system, AFNOR NFX11-501: 1970
|
4967
|
+
# The system appears to be based on size doubling every 3 mesh
|
4968
|
+
# numbers, though the values have been agressively rounded.
|
4969
|
+
# It's not clear if the unrounded values would be considered
|
4970
|
+
# incorrect, so this is given as a table rather than a function.
|
4971
|
+
# Functional form:
|
4972
|
+
# meshtamis(mesh) units=[1;m] 5000 2^(1|3 (mesh-38)) micron
|
4973
|
+
#
|
4974
|
+
# http://www.panadyne.com/technical/panadyne_international_sieve_chart.pdf
|
4975
|
+
|
4976
|
+
meshtamis[micron] \
|
4977
|
+
17 40 \
|
4978
|
+
18 50 \
|
4979
|
+
19 63 \
|
4980
|
+
20 80 \
|
4981
|
+
21 100 \
|
4982
|
+
22 125 \
|
4983
|
+
23 160 \
|
4984
|
+
24 200 \
|
4985
|
+
25 250 \
|
4986
|
+
26 315 \
|
4987
|
+
27 400 \
|
4988
|
+
28 500 \
|
4989
|
+
29 630 \
|
4990
|
+
30 800 \
|
4991
|
+
31 1000 \
|
4992
|
+
32 1250 \
|
4993
|
+
33 1600 \
|
4994
|
+
34 2000 \
|
4995
|
+
35 2500 \
|
4996
|
+
36 3150 \
|
4997
|
+
37 4000 \
|
4998
|
+
38 5000
|
4999
|
+
|
4033
5000
|
#
|
4034
5001
|
# Ring size. All ring sizes are given as the circumference of the ring.
|
4035
5002
|
#
|
@@ -4046,7 +5013,7 @@ washita 35 micron
|
|
4046
5013
|
# circumference, but that source doesn't have an explanation for the modern
|
4047
5014
|
# system which is somewhat different.
|
4048
5015
|
|
4049
|
-
ringsize(n) units=[;in] domain=[2,
|
5016
|
+
ringsize(n) units=[1;in] domain=[2,) range=[1.6252,) \
|
4050
5017
|
(1.4216+.1018 n) in ; (ringsize/in + (-1.4216))/.1018
|
4051
5018
|
|
4052
5019
|
# Old practice in the UK measured rings using the "Wheatsheaf gauge" with sizes
|
@@ -4088,12 +5055,12 @@ sizeZring 68.75 mm
|
|
4088
5055
|
# 1|3 mm larger in diameter than the previous one. They are multiplied by pi
|
4089
5056
|
# to give circumference.
|
4090
5057
|
|
4091
|
-
jpringsize(n) units=[;mm] domain=[1,
|
5058
|
+
jpringsize(n) units=[1;mm] domain=[1,) range=[0.040840704,) \
|
4092
5059
|
(38|3 + n/3) pi mm ; 3 jpringsize/ pi mm + (-38)
|
4093
5060
|
|
4094
5061
|
# The European ring sizes are the length of the circumference in mm minus 40.
|
4095
5062
|
|
4096
|
-
euringsize(n) units=[;mm] (n+40) mm ; euringsize/mm + (-40)
|
5063
|
+
euringsize(n) units=[1;mm] (n+40) mm ; euringsize/mm + (-40)
|
4097
5064
|
|
4098
5065
|
#
|
4099
5066
|
# Abbreviations
|
@@ -4189,7 +5156,8 @@ rem 1e-2 Sv # keV X-rays. Different types of
|
|
4189
5156
|
#
|
4190
5157
|
# rem stands for Roentgen Equivalent
|
4191
5158
|
# Mammal
|
4192
|
-
|
5159
|
+
banana_dose 0.1e-6 sievert # Informal measure of the dose due to
|
5160
|
+
# eating one average sized banana
|
4193
5161
|
roentgen 2.58e-4 C / kg # Ionizing radiation that produces
|
4194
5162
|
# 1 statcoulomb of charge in 1 cc of
|
4195
5163
|
# dry air at stp.
|
@@ -4238,6 +5206,7 @@ chromium 51.9961
|
|
4238
5206
|
cobalt 58.93320
|
4239
5207
|
copper 63.546
|
4240
5208
|
curium 247.0703
|
5209
|
+
deuterium 2.0141017778
|
4241
5210
|
dysprosium 162.50
|
4242
5211
|
einsteinium 252.083 # Longest lived
|
4243
5212
|
erbium 167.26
|
@@ -4318,22 +5287,23 @@ yttrium 88.90585
|
|
4318
5287
|
zinc 65.39
|
4319
5288
|
zirconium 91.224
|
4320
5289
|
|
4321
|
-
#
|
5290
|
+
# Average molecular weight of air
|
5291
|
+
#
|
5292
|
+
# The atmospheric composition listed is from NASA Earth Fact Sheet (accessed
|
5293
|
+
# 28 August 2015)
|
4322
5294
|
# http://nssdc.gsfc.nasa.gov/planetary/factsheet/earthfact.html
|
4323
|
-
#
|
4324
|
-
#
|
4325
|
-
|
4326
|
-
|
4327
|
-
|
4328
|
-
|
4329
|
-
|
4330
|
-
|
4331
|
-
|
4332
|
-
|
4333
|
-
|
4334
|
-
|
4335
|
-
|
4336
|
-
|
5295
|
+
# Numbers do not add up to exactly 100% due to roundoff and uncertainty Water
|
5296
|
+
# is highly variable, typically makes up about 1%
|
5297
|
+
|
5298
|
+
air 78.08% nitrogen 2 \
|
5299
|
+
+ 20.95% oxygen 2 \
|
5300
|
+
+ 9340 ppm argon \
|
5301
|
+
+ 400 ppm (carbon + oxygen 2) \
|
5302
|
+
+ 18.18 ppm neon \
|
5303
|
+
+ 5.24 ppm helium \
|
5304
|
+
+ 1.7 ppm (carbon + 4 hydrogen) \
|
5305
|
+
+ 1.14 ppm krypton \
|
5306
|
+
+ 0.55 ppm hydrogen 2
|
4337
5307
|
#
|
4338
5308
|
# population units
|
4339
5309
|
#
|
@@ -4344,6 +5314,54 @@ death people
|
|
4344
5314
|
capita people
|
4345
5315
|
percapita per capita
|
4346
5316
|
|
5317
|
+
# TGM dozen based unit system listed on the "dozenal" forum
|
5318
|
+
# http://www.dozenalsociety.org.uk/apps/tgm.htm. These units are
|
5319
|
+
# proposed as an allegedly more rational alternative to the SI system.
|
5320
|
+
|
5321
|
+
Tim 12^-4 hour # Time
|
5322
|
+
Grafut gravity Tim^2 # Length based on gravity
|
5323
|
+
Surf Grafut^2 # area
|
5324
|
+
Volm Grafut^3 # volume
|
5325
|
+
Vlos Grafut/Tim # speed
|
5326
|
+
Denz Maz/Volm # density
|
5327
|
+
Mag Maz gravity # force
|
5328
|
+
Maz Volm kg / oldliter # mass based on water
|
5329
|
+
|
5330
|
+
Tm Tim # Abbreviations
|
5331
|
+
Gf Grafut
|
5332
|
+
Sf Surf
|
5333
|
+
Vm Volm
|
5334
|
+
Vl Vlos
|
5335
|
+
Mz Maz
|
5336
|
+
Dz Denz
|
5337
|
+
|
5338
|
+
# Dozen based unit prefixes
|
5339
|
+
|
5340
|
+
Zena- 12
|
5341
|
+
Duna- 12^2
|
5342
|
+
Trina- 12^3
|
5343
|
+
Quedra- 12^4
|
5344
|
+
Quena- 12^5
|
5345
|
+
Hesa- 12^6
|
5346
|
+
Seva- 12^7
|
5347
|
+
Aka- 12^8
|
5348
|
+
Neena- 12^9
|
5349
|
+
Dexa- 12^10
|
5350
|
+
Lefa- 12^11
|
5351
|
+
Zennila- 12^12
|
5352
|
+
|
5353
|
+
Zeni- 12^-1
|
5354
|
+
Duni- 12^-2
|
5355
|
+
Trini- 12^-3
|
5356
|
+
Quedri- 12^-4
|
5357
|
+
Queni- 12^-5
|
5358
|
+
Hesi- 12^-6
|
5359
|
+
Sevi- 12^-7
|
5360
|
+
Aki- 12^-8
|
5361
|
+
Neeni- 12^-9
|
5362
|
+
Dexi- 12^-10
|
5363
|
+
Lefi- 12^-11
|
5364
|
+
Zennili- 12^-12
|
4347
5365
|
|
4348
5366
|
#
|
4349
5367
|
# Traditional Japanese units (shakkanhou)
|
@@ -5128,6 +6146,13 @@ röntgen roentgen
|
|
5128
6146
|
K K # Kelvin symbol, U+212A
|
5129
6147
|
ℓ liter # unofficial abbreviation used in some places
|
5130
6148
|
¢ cent
|
6149
|
+
#£ britainpound
|
6150
|
+
#¥ japanyen
|
6151
|
+
#€ euro
|
6152
|
+
#₩ southkoreawon
|
6153
|
+
#₪ israelnewshekel
|
6154
|
+
#₤ lira
|
6155
|
+
#₨ rupee
|
5131
6156
|
|
5132
6157
|
Ω ohm # Ohm symbol U+2126
|
5133
6158
|
Ω ohm # Greek capital omega U+03A9
|
@@ -5139,9 +6164,9 @@ röntgen roentgen
|
|
5139
6164
|
ℎ h
|
5140
6165
|
ℏ hbar
|
5141
6166
|
‰ 1|1000
|
5142
|
-
‱
|
5143
|
-
′
|
5144
|
-
″
|
6167
|
+
‱ 1|10000
|
6168
|
+
′ ' # U+2032
|
6169
|
+
″ " # U+2033
|
5145
6170
|
|
5146
6171
|
#
|
5147
6172
|
# Square unicode symbols starting at U+3371
|
@@ -5153,9 +6178,9 @@ röntgen roentgen
|
|
5153
6178
|
㍴ bar
|
5154
6179
|
# ㍵ oV???
|
5155
6180
|
㍶ pc
|
5156
|
-
|
5157
|
-
|
5158
|
-
|
6181
|
+
#㍷ dm invalid on Mac
|
6182
|
+
#㍸ dm^2 invalid on Mac
|
6183
|
+
#㍹ dm^3 invalid on Mac
|
5159
6184
|
㎀ pA
|
5160
6185
|
㎁ nA
|
5161
6186
|
㎂ µA
|
@@ -5226,7 +6251,7 @@ röntgen roentgen
|
|
5226
6251
|
㏄ cc
|
5227
6252
|
㏅ cd
|
5228
6253
|
㏆ C/kg
|
5229
|
-
㏈(
|
6254
|
+
㏈() dB
|
5230
6255
|
㏉ Gy
|
5231
6256
|
㏊ ha
|
5232
6257
|
# ㏋ HP??
|
@@ -5241,15 +6266,15 @@ röntgen roentgen
|
|
5241
6266
|
㏔ mb
|
5242
6267
|
㏕ mil
|
5243
6268
|
㏖ mol
|
5244
|
-
㏗(
|
6269
|
+
㏗() pH
|
5245
6270
|
㏙ ppm
|
5246
6271
|
# ㏚ PR???
|
5247
6272
|
㏛ sr
|
5248
6273
|
㏜ Sv
|
5249
6274
|
㏝ Wb
|
5250
|
-
|
5251
|
-
|
5252
|
-
|
6275
|
+
#㏞ V/m Invalid on Mac
|
6276
|
+
#㏟ A/m Invalid on Mac
|
6277
|
+
#㏿ gal Invalid on Mac
|
5253
6278
|
|
5254
6279
|
!endutf8
|
5255
6280
|
|
@@ -5265,6 +6290,7 @@ röntgen roentgen
|
|
5265
6290
|
!unitlist time year;day;hr;min;sec
|
5266
6291
|
!unitlist dms deg;arcmin;arcsec
|
5267
6292
|
!unitlist ftin ft;in;1|8 in
|
6293
|
+
!unitlist inchfine in;1|8 in;1|16 in;1|32 in;1|64 in
|
5268
6294
|
!unitlist usvol cup;3|4 cup;2|3 cup;1|2 cup;1|3 cup;1|4 cup;\
|
5269
6295
|
tbsp;tsp;1|2 tsp;1|4 tsp;1|8 tsp
|
5270
6296
|
|