line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# -*- cperl; cperl-indent-level: 4 -*- |
2
|
|
|
|
|
|
|
# Copyright (C) 2020-2021, Roland van Ipenburg |
3
|
|
|
|
|
|
|
package Class::Measure::Scientific::FX_992vb v0.0.6; |
4
|
18
|
|
|
18
|
|
152353
|
use Moose; |
|
18
|
|
|
|
|
8710155
|
|
|
18
|
|
|
|
|
138
|
|
5
|
18
|
|
|
18
|
|
150003
|
use MooseX::NonMoose; |
|
18
|
|
|
|
|
20121
|
|
|
18
|
|
|
|
|
69
|
|
6
|
18
|
|
|
18
|
|
1290675
|
use List::MoreUtils qw(uniq); |
|
18
|
|
|
|
|
52
|
|
|
18
|
|
|
|
|
186
|
|
7
|
|
|
|
|
|
|
extends |
8
|
|
|
|
|
|
|
'Class::Measure' => { '-version' => 0.08 }, |
9
|
|
|
|
|
|
|
'Moose::Object'; |
10
|
|
|
|
|
|
|
|
11
|
18
|
|
|
18
|
|
31107
|
use Log::Log4perl qw(:easy get_logger); |
|
18
|
|
|
|
|
871593
|
|
|
18
|
|
|
|
|
116
|
|
12
|
|
|
|
|
|
|
|
13
|
18
|
|
|
18
|
|
15732
|
use utf8; |
|
18
|
|
|
|
|
51
|
|
|
18
|
|
|
|
|
150
|
|
14
|
18
|
|
|
18
|
|
950
|
use 5.016000; |
|
18
|
|
|
|
|
89
|
|
15
|
|
|
|
|
|
|
|
16
|
18
|
|
|
18
|
|
11655
|
use Readonly; |
|
18
|
|
|
|
|
71447
|
|
|
18
|
|
|
|
|
31766
|
|
17
|
|
|
|
|
|
|
## no critic (ProhibitCallsToUnexportedSubs) |
18
|
|
|
|
|
|
|
Readonly::Scalar my $EMPTY => q{}; |
19
|
|
|
|
|
|
|
Readonly::Scalar my $SEP => q{,}; |
20
|
|
|
|
|
|
|
Readonly::Scalar my $PREFIX => q{C}; |
21
|
|
|
|
|
|
|
Readonly::Scalar my $CODE => q{CODE}; |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
Readonly::Scalar my $AM2 => q{Am2}; |
24
|
|
|
|
|
|
|
Readonly::Scalar my $AM2PJS => q{Am2pJs}; |
25
|
|
|
|
|
|
|
Readonly::Scalar my $AMPERE => q{A}; |
26
|
|
|
|
|
|
|
Readonly::Scalar my $APM => q{Apm}; |
27
|
|
|
|
|
|
|
Readonly::Scalar my $BQ => q{Bq}; |
28
|
|
|
|
|
|
|
Readonly::Scalar my $CDPM2 => q{cdpm2}; |
29
|
|
|
|
|
|
|
Readonly::Scalar my $CELSIUS => q{C}; |
30
|
|
|
|
|
|
|
Readonly::Scalar my $CM => q{Cm}; |
31
|
|
|
|
|
|
|
Readonly::Scalar my $CM2PV => q{Cm2pV}; |
32
|
|
|
|
|
|
|
Readonly::Scalar my $COULOMB => q{C}; |
33
|
|
|
|
|
|
|
Readonly::Scalar my $CPKG => q{Cpkg}; |
34
|
|
|
|
|
|
|
Readonly::Scalar my $CPM => q{Cpmol}; |
35
|
|
|
|
|
|
|
Readonly::Scalar my $CPM2 => q{Cpm2}; |
36
|
|
|
|
|
|
|
Readonly::Scalar my $FAHRENHEIT => q{F}; |
37
|
|
|
|
|
|
|
Readonly::Scalar my $FARAD => q{f}; |
38
|
|
|
|
|
|
|
Readonly::Scalar my $FPM => q{Fpm}; |
39
|
|
|
|
|
|
|
Readonly::Scalar my $HPM => q{Hpm}; |
40
|
|
|
|
|
|
|
Readonly::Scalar my $JOULE => q{J}; |
41
|
|
|
|
|
|
|
Readonly::Scalar my $JPK => q{JpK}; |
42
|
|
|
|
|
|
|
Readonly::Scalar my $JPKG => q{Jpkg}; |
43
|
|
|
|
|
|
|
Readonly::Scalar my $JPKGK => q{JpkgK}; |
44
|
|
|
|
|
|
|
Readonly::Scalar my $JPMOLK => q{JpmolK}; |
45
|
|
|
|
|
|
|
Readonly::Scalar my $JS => q{Js}; |
46
|
|
|
|
|
|
|
Readonly::Scalar my $KELVIN => q{K}; |
47
|
|
|
|
|
|
|
Readonly::Scalar my $KG => q{kg}; |
48
|
|
|
|
|
|
|
Readonly::Scalar my $KGPM => q{kgpm}; |
49
|
|
|
|
|
|
|
Readonly::Scalar my $M2 => q{m2}; |
50
|
|
|
|
|
|
|
Readonly::Scalar my $M3 => q{m3}; |
51
|
|
|
|
|
|
|
Readonly::Scalar my $M3PMOL => q{m3pmol}; |
52
|
|
|
|
|
|
|
Readonly::Scalar my $METER => q{m}; |
53
|
|
|
|
|
|
|
Readonly::Scalar my $MK => q{mK}; |
54
|
|
|
|
|
|
|
Readonly::Scalar my $MPS => q{mps}; |
55
|
|
|
|
|
|
|
Readonly::Scalar my $MPS2 => q{mps2}; |
56
|
|
|
|
|
|
|
Readonly::Scalar my $NEWTON => q{N}; |
57
|
|
|
|
|
|
|
Readonly::Scalar my $NM2PKG2 => q{Nm2pkg2}; |
58
|
|
|
|
|
|
|
Readonly::Scalar my $PA => q{pa}; |
59
|
|
|
|
|
|
|
Readonly::Scalar my $PM => q{pm}; |
60
|
|
|
|
|
|
|
Readonly::Scalar my $PMOL => q{pmol}; |
61
|
|
|
|
|
|
|
Readonly::Scalar my $RAD => q{rad}; |
62
|
|
|
|
|
|
|
Readonly::Scalar my $SECOND => q{s}; |
63
|
|
|
|
|
|
|
Readonly::Scalar my $SKIP => q{}; |
64
|
|
|
|
|
|
|
Readonly::Scalar my $VOLT => q{V}; |
65
|
|
|
|
|
|
|
Readonly::Scalar my $VPM => q{Vpm}; |
66
|
|
|
|
|
|
|
Readonly::Scalar my $WATT => q{W}; |
67
|
|
|
|
|
|
|
Readonly::Scalar my $WB => q{Wb}; |
68
|
|
|
|
|
|
|
Readonly::Scalar my $WM2 => q{Wm2}; |
69
|
|
|
|
|
|
|
Readonly::Scalar my $WPM2K4 => q{Wpm2K4}; |
70
|
|
|
|
|
|
|
Readonly::Hash my %IDX => ( |
71
|
|
|
|
|
|
|
'idx' => 0, |
72
|
|
|
|
|
|
|
'unit' => 1, |
73
|
|
|
|
|
|
|
'multiplier' => 3, |
74
|
|
|
|
|
|
|
'base' => 4, |
75
|
|
|
|
|
|
|
); |
76
|
|
|
|
|
|
|
Readonly::Hash my %TYPES => ( |
77
|
|
|
|
|
|
|
'acceleration' => $MPS2, |
78
|
|
|
|
|
|
|
'angle' => $RAD, |
79
|
|
|
|
|
|
|
'area' => $M2, |
80
|
|
|
|
|
|
|
'charge' => $COULOMB, |
81
|
|
|
|
|
|
|
'displacement' => $CPM2, |
82
|
|
|
|
|
|
|
'duration' => $SECOND, |
83
|
|
|
|
|
|
|
'electrolysis' => $CPM, |
84
|
|
|
|
|
|
|
'electromagnetic' => $JS, |
85
|
|
|
|
|
|
|
'energy' => $JOULE, |
86
|
|
|
|
|
|
|
'entropy' => $JPK, |
87
|
|
|
|
|
|
|
'field_equation' => $NM2PKG2, |
88
|
|
|
|
|
|
|
'flux' => $WB, |
89
|
|
|
|
|
|
|
'force' => $NEWTON, |
90
|
|
|
|
|
|
|
'gas' => $JPMOLK, |
91
|
|
|
|
|
|
|
'gyromagnetic' => $AM2PJS, |
92
|
|
|
|
|
|
|
'heat_capacity' => $JPKGK, |
93
|
|
|
|
|
|
|
'isotropic' => $CM2PV, |
94
|
|
|
|
|
|
|
'length' => $METER, |
95
|
|
|
|
|
|
|
'linear_density' => $KGPM, |
96
|
|
|
|
|
|
|
'luminance' => $CDPM2, |
97
|
|
|
|
|
|
|
'magnetic' => $AM2, |
98
|
|
|
|
|
|
|
'mass' => $KG, |
99
|
|
|
|
|
|
|
'mixture' => $M3PMOL, |
100
|
|
|
|
|
|
|
'power' => $WATT, |
101
|
|
|
|
|
|
|
'pressure' => $PA, |
102
|
|
|
|
|
|
|
'proportionality' => $PMOL, |
103
|
|
|
|
|
|
|
'radiation' => $CPKG, |
104
|
|
|
|
|
|
|
'radioactive' => $BQ, |
105
|
|
|
|
|
|
|
'spectroscopic' => $PM, |
106
|
|
|
|
|
|
|
'speed' => $MPS, |
107
|
|
|
|
|
|
|
'susceptibility' => $CM, |
108
|
|
|
|
|
|
|
'temperature' => $KELVIN, |
109
|
|
|
|
|
|
|
'thermodynamic' => $JPKG, |
110
|
|
|
|
|
|
|
'volume' => $M3, |
111
|
|
|
|
|
|
|
'wavelength' => $WM2, |
112
|
|
|
|
|
|
|
'wavenumber' => $MK, |
113
|
|
|
|
|
|
|
); |
114
|
|
|
|
|
|
|
Readonly::Array my @CONST => ( |
115
|
|
|
|
|
|
|
[ 1, q{deg}, q{degree (angle)}, 0.017_453_292_51, $RAD ], |
116
|
|
|
|
|
|
|
[ 2, q{minute}, q{minute (angle)}, 2.908_882_086_66e-4, $RAD ], |
117
|
|
|
|
|
|
|
[ 3, q{second}, q{second (angle)}, 4.848_136_811e-6, $RAD ], |
118
|
|
|
|
|
|
|
[ 4, q{AU}, q{astronomical unit}, 149_597_870_000, $METER ], |
119
|
|
|
|
|
|
|
[ 5, q{g}, q{acceleration of free fall}, 9.806_65, $MPS2 ], |
120
|
|
|
|
|
|
|
[ 6, q{grade}, q{grade}, 0.015_707_963_26, $RAD ], |
121
|
|
|
|
|
|
|
[ 7, q{kn}, q{knot}, 1852 / 3600, $MPS ], |
122
|
|
|
|
|
|
|
[ 8, q{ly}, q{light year}, 9.460_53e15, $METER ], |
123
|
|
|
|
|
|
|
[ 9, q{nmi}, q{nautical mile}, 1852, $METER ], |
124
|
|
|
|
|
|
|
[ 10, q{pc}, q{parsec}, 3.085_677_57e16, $METER ], |
125
|
|
|
|
|
|
|
[ 11, q{year}, q{tropical year}, 31_556_926, $SECOND ], |
126
|
|
|
|
|
|
|
[ 12, q{acre}, q{acre}, 4_046.856_422_4, $M2 ], |
127
|
|
|
|
|
|
|
[ 13, q{bbl}, q{barrel for petroleum}, 0.158_987_294_92, $M3 ], |
128
|
|
|
|
|
|
|
[ 14, q{dry_barrel}, q{dry barrel}, 0.115_627_123_58, $M3 ], |
129
|
|
|
|
|
|
|
[ 15, q{bushel_uk}, q{bushel}, 0.036_368_794_35, $M3 ], |
130
|
|
|
|
|
|
|
[ 16, q{bu}, q{bushel}, 0.035_239_070_16, $M3 ], |
131
|
|
|
|
|
|
|
[ 17, q{chain}, q{chain (surveyors)}, 79_200 / 3_937, $METER ], |
132
|
|
|
|
|
|
|
[ 18, q{cu}, q{US cup}, 2.365_882_365e-4, $M3 ], |
133
|
|
|
|
|
|
|
[ 19, q{pt_dry}, q{dry pint}, 5.506_104_713_58e-4, $M3 ], |
134
|
|
|
|
|
|
|
[ 20, q{fathom}, q{fathom (surveyors)}, 7200 / 3937, $METER ], |
135
|
|
|
|
|
|
|
[ 21, q{fbm}, q{board foot}, 2.359_737_216e-3, $M3 ], |
136
|
|
|
|
|
|
|
[ 22, q{floz_uk}, q{fluid ounce UK}, 2.841_312_059_3e-5, $M3 ], |
137
|
|
|
|
|
|
|
[ 23, q{floz_us}, q{fluid ounce US}, 2.957_352_956_25e-5, $M3 ], |
138
|
|
|
|
|
|
|
[ 24, q{ft}, q{foot}, 0.304_8, $METER ], |
139
|
|
|
|
|
|
|
[ 25, q{ft_us}, q{foot (surveyors = US)}, 1200 / 3937, $METER ], |
140
|
|
|
|
|
|
|
[ 26, q{gal_uk}, q{gallon (United Kingdom)}, 4.546_099_294_88e-3, $M3 ], |
141
|
|
|
|
|
|
|
[ 27, q{gal_us}, q{gallon (United States)}, 3.785_411_784e-3, $M3 ], |
142
|
|
|
|
|
|
|
[ 28, q{in}, q{inch}, 0.025_4, $METER ], |
143
|
|
|
|
|
|
|
[ 29, q{mil}, q{mil}, 2.54e-5, $METER ], |
144
|
|
|
|
|
|
|
[ 30, q{mile}, q{mile (international)}, 1_609.344, $METER ], |
145
|
|
|
|
|
|
|
[ 31, q{sm}, q{US statute mile}, 6_336_000 / 3_937, $METER ], |
146
|
|
|
|
|
|
|
[ 32, q{mph}, q{miles per hour}, 0.447_04, $MPS ], |
147
|
|
|
|
|
|
|
[ 33, q{pk}, q{peck}, 8.809_767_541_72e-3, $M3 ], |
148
|
|
|
|
|
|
|
[ 34, q{pt_uk}, q{pint}, 5.682_624_118_6e-4, $M3 ], |
149
|
|
|
|
|
|
|
[ 35, q{pt_us}, q{liquid pint}, 4.731_764_73e-4, $M3 ], |
150
|
|
|
|
|
|
|
[ 36, q{tbsp}, q{tablespoon}, 1.478_676_478_13e-5, $M3 ], |
151
|
|
|
|
|
|
|
[ 37, q{tsp}, q{teaspoon}, 4.928_921_593_75e-6, $M3 ], |
152
|
|
|
|
|
|
|
[ 38, q{yd}, q{yard}, 0.914_4, $METER ], |
153
|
|
|
|
|
|
|
[ 39, q{yd_us}, q{US yard}, 3_600 / 3_937, $METER ], |
154
|
|
|
|
|
|
|
[ 40, q{at}, q{technical atmosphere}, 98_066.5, $PA ], |
155
|
|
|
|
|
|
|
[ 41, q{atm}, q{standard atmosphere}, 101_325, $PA ], |
156
|
|
|
|
|
|
|
[ 42, q{ct}, q{metric carat}, 2e-4, $KG ], |
157
|
|
|
|
|
|
|
[ 43, q{D}, q{denier}, 50 / 450_000_000, $KGPM ], |
158
|
|
|
|
|
|
|
[ 44, q{G}, q{gravitational constant}, 6.672e-11, $NM2PKG2 ], |
159
|
|
|
|
|
|
|
[ 45, q{kgf}, q{kilogramforce}, 9.806_65, $NEWTON ], |
160
|
|
|
|
|
|
|
[ 46, q{mH2O}, q{meter of water}, 9_806.65, $PA ], |
161
|
|
|
|
|
|
|
[ 47, q{mmHg}, q{mm of mercury}, 101_325 / 760, $PA ], |
162
|
|
|
|
|
|
|
[ 48, q{PS}, q{metric horsepower}, 735.49875, $WATT ], |
163
|
|
|
|
|
|
|
[ 49, q{Torr}, q{Torr}, 101_325 / 760, $PA ], |
164
|
|
|
|
|
|
|
[ 50, q{cwt_uk}, q{hundred-weight}, 50.802_345_44, $KG ], |
165
|
|
|
|
|
|
|
[ 51, q{cwt_us}, q{hundred-weight}, 45.359_237, $KG ], |
166
|
|
|
|
|
|
|
[ 52, q{ftlbf}, q{foot pound-force}, 1.355_817_948_33, $JOULE ], |
167
|
|
|
|
|
|
|
[ 53, q{ftH2O}, q{foot of water}, 2_989.066_92, $PA ], |
168
|
|
|
|
|
|
|
[ 54, q{gr}, q{grain}, 6.479_891e-5, $KG ], |
169
|
|
|
|
|
|
|
[ 55, q{hp}, q{horsepower}, 745.699_871_582, $JOULE ], |
170
|
|
|
|
|
|
|
[ 56, q{inH2O}, q{inch of water}, 249.088_91, $PA ], |
171
|
|
|
|
|
|
|
[ 57, q{inHg}, q{inch of mercury}, 3_386.388_157_89, $PA ], |
172
|
|
|
|
|
|
|
[ 58, q{lb}, q{pound}, 0.453_592_37, $KG ], |
173
|
|
|
|
|
|
|
[ 59, q{lbf}, q{pound-force}, 4.448_221_615_26, $NEWTON ], |
174
|
|
|
|
|
|
|
[ 60, q{lbt}, q{troy pound}, 0.373_241_721_6, $KG ], |
175
|
|
|
|
|
|
|
[ 61, q{oz}, q{ounce}, 0.028_349_523_12, $KG ], |
176
|
|
|
|
|
|
|
[ 62, q{ozt}, q{troy ounce}, 0.031_103_476_8, $KG ], |
177
|
|
|
|
|
|
|
[ 63, q{pdl}, q{poundal}, 0.138_254_954_37, $NEWTON ], |
178
|
|
|
|
|
|
|
[ 64, q{psi}, q{pounds per square inch}, 6_894.757_293_17, $PA ], |
179
|
|
|
|
|
|
|
[ 65, q{slug}, q{slug}, 14.593_902_937_2, $KG ], |
180
|
|
|
|
|
|
|
[ 66, q{ton_uk}, q{long ton}, 1_016.046_908_8, $KG ], |
181
|
|
|
|
|
|
|
[ 67, q{ton_us}, q{short ton}, 907.184_74, $KG ], |
182
|
|
|
|
|
|
|
[ 68, q{zC}, q{zero Celsius}, 273.15, $SKIP ], |
183
|
|
|
|
|
|
|
[ 69, q{cal15}, q{15 degree calorie}, 4.185_5, $JOULE ], |
184
|
|
|
|
|
|
|
[ 70, q{calit}, q{I.T. calorie}, 4.186_8, $JOULE ], |
185
|
|
|
|
|
|
|
[ 71, q{calth}, q{thermo chemical calorie}, 4.184, $JOULE ], |
186
|
|
|
|
|
|
|
[ 72, q{FK}, q{degree Fahrenheit}, 5 / 9, $SKIP ], |
187
|
|
|
|
|
|
|
[ 73, q{zF}, q{zero Fahrenheit in Celsius}, -160 / 9, $SKIP ], |
188
|
|
|
|
|
|
|
[ 74, q{BTU}, q{British thermal unit}, 1_055.055_852_62, $JOULE ], |
189
|
|
|
|
|
|
|
[ 75, q{BTUlbR}, q{specific heat capacity}, 4_186.8, $JPKGK ], |
190
|
|
|
|
|
|
|
[ 76, q{BTUh}, q{Btu per hour}, 0.293_071_070_17, $WATT ], |
191
|
|
|
|
|
|
|
[ 77, q{BTUlb}, q{specific internal enegry}, 2_326, $JPKG ], |
192
|
|
|
|
|
|
|
[ 78, q{therm}, q{therm}, 105_505_585.262, $JOULE ], |
193
|
|
|
|
|
|
|
[ 79, q{eps0}, q{permittivity of vacuum}, 8.854_187_817_62e-12, $FPM ], |
194
|
|
|
|
|
|
|
[ 80, q{mu0}, q{permeability of vacuum}, 1.256_637_061_44e-6, $HPM ], |
195
|
|
|
|
|
|
|
[ 81, q{Cs}, q{G. electric capacitance}, 1.112_650_056_05e-12, $FARAD ], |
196
|
|
|
|
|
|
|
[ 82, q{Ds}, q{G. electric flux density}, 2.654_418_729_44e-7, $CPM2 ], |
197
|
|
|
|
|
|
|
[ 83, q{Es}, q{G. electric field strength}, 29_979.245_8, $VPM ], |
198
|
|
|
|
|
|
|
[ 84, q{Is}, q{G. electric current}, 3.33564095198e-10, $AMPERE ], |
199
|
|
|
|
|
|
|
[ 85, q{Oe}, q{Hs, G. magnetic field strength}, 79.5774715459, $APM ], |
200
|
|
|
|
|
|
|
[ 86, q{Ps}, q{G. electric polarization}, 3.335_640_951_98e-6, $CPM2 ], |
201
|
|
|
|
|
|
|
[ 87, q{Qs}, q{G. electric charge}, 3.335_640_951_98e-10, $COULOMB ], |
202
|
|
|
|
|
|
|
[ 88, q{Vs}, q{G. electric potential}, 299.792458, $VOLT ], |
203
|
|
|
|
|
|
|
[ 89, q{sigma}, q{Stefan-Boltzmann constant}, 5.67032e-8, $WPM2K4 ], |
204
|
|
|
|
|
|
|
[ 90, q{c}, q{speed of light}, 299_792_458, $MPS ], |
205
|
|
|
|
|
|
|
[ 91, q{c1}, q{first radiation constant}, 3.741_832e-16, $WM2 ], |
206
|
|
|
|
|
|
|
[ 92, q{c2}, q{second radiation constant}, 0.014_387_86, $MK ], |
207
|
|
|
|
|
|
|
[ 93, q{lam}, q{lambert}, 3_183.098_861_84, $CDPM2 ], |
208
|
|
|
|
|
|
|
[ 94, q{flam}, q{footlambert}, 3.426_259_099_64, $CDPM2 ], |
209
|
|
|
|
|
|
|
[ 95, q{dB}, q{decibel level difference}, 0.115_129_254_65, $SKIP ], |
210
|
|
|
|
|
|
|
[ 96, q{Np}, q{neper level difference}, 8.685_889_638_07, $SKIP ], |
211
|
|
|
|
|
|
|
[ 97, q{e}, q{elementary charge}, 1.602_189_2e-19, $COULOMB ], |
212
|
|
|
|
|
|
|
[ 98, q{f}, q{Faraday constant}, 96_484.56, $CPM ], |
213
|
|
|
|
|
|
|
[ 99, q{k}, q{Boltzmann constant}, 1.380_662e-23, $JPK ], |
214
|
|
|
|
|
|
|
[ 100, q{Na}, q{Avogadro constant}, 6.022_045e23, $PMOL ], |
215
|
|
|
|
|
|
|
[ 101, q{R}, q{molar gas constant}, 8.314_41, $JPMOLK ], |
216
|
|
|
|
|
|
|
[ 102, q{Vm}, q{molar volume}, 0.02241383, $M3PMOL ], |
217
|
|
|
|
|
|
|
[ |
218
|
|
|
|
|
|
|
103, q{alpha}, q{G. el. polarizability of molecule}, |
219
|
|
|
|
|
|
|
1.11265005605e-16, $CM2PV, |
220
|
|
|
|
|
|
|
], |
221
|
|
|
|
|
|
|
[ 104, q{p}, q{mu, G. el. dipole of molecule}, 3.33564095198e-12, $CM ], |
222
|
|
|
|
|
|
|
[ 105, q{a}, q{fine-structure constant}, 7.297_350_6e-3, $SKIP ], |
223
|
|
|
|
|
|
|
[ 106, q{gammap}, q{gyromagnetic ratio of proton}, 267_519_870, $AM2PJS ], |
224
|
|
|
|
|
|
|
[ |
225
|
|
|
|
|
|
|
107, q{gammapalt}, q{gyromagnetic ratio of proton in water}, |
226
|
|
|
|
|
|
|
267_513_010, $AM2PJS, |
227
|
|
|
|
|
|
|
], |
228
|
|
|
|
|
|
|
[ 108, q{lambdacn}, q{Compton wavelength n}, 1.319_590_9e-15, $METER ], |
229
|
|
|
|
|
|
|
[ 109, q{lambdacp}, q{Compton wavelength p}, 1.321_409_9e-15, $METER ], |
230
|
|
|
|
|
|
|
[ 110, q{muB}, q{Bohr magneton}, 9.274_078e-24, $AM2 ], |
231
|
|
|
|
|
|
|
[ 111, q{mue}, q{m. moment of electron}, 9.284_770_1e-24, $AM2 ], |
232
|
|
|
|
|
|
|
[ 112, q{muN}, q{nuclear magneton}, 5.050_824e-27, $AM2 ], |
233
|
|
|
|
|
|
|
[ 113, q{mup}, q{m. moment of proton}, 1.410_607_61e-26, $AM2 ], |
234
|
|
|
|
|
|
|
[ 114, q{a0}, q{Bohr radius}, 5.291_770_6e-11, $METER ], |
235
|
|
|
|
|
|
|
[ 115, q{eh}, q{Hartree energy}, 4.359_81e-18, $JOULE ], |
236
|
|
|
|
|
|
|
[ 116, q{ev}, q{electronvolt}, 1.602_189_2e-19, $JOULE ], |
237
|
|
|
|
|
|
|
[ 117, q{h}, q{Planck constant}, 6.626176e-34, $JS ], |
238
|
|
|
|
|
|
|
[ 118, q{hbar}, q{Planck constant per 2 pi}, 1.0545887e-34, $JS ], |
239
|
|
|
|
|
|
|
[ 119, q{m1h}, q{mass of hydrogen atom}, 1.673_559_4e-27, $KG ], |
240
|
|
|
|
|
|
|
[ 120, q{me}, q{rest mass of electron}, 9.109_534e-31, $KG ], |
241
|
|
|
|
|
|
|
[ 121, q{mn}, q{rest mass of neutron}, 1.674_954_3e-27, $KG ], |
242
|
|
|
|
|
|
|
[ 122, q{mp}, q{rest mass of proton}, 1.672_648_5e-27, $KG ], |
243
|
|
|
|
|
|
|
[ 123, q{Rinf}, q{Rydberg constant}, 10_973_731.77, $PM ], |
244
|
|
|
|
|
|
|
[ 124, q{re}, q{electron radius}, 2.817_938e-15, $METER ], |
245
|
|
|
|
|
|
|
[ 125, q{u}, q{atomic mass unit}, 1.660_565_5e-27, $KG ], |
246
|
|
|
|
|
|
|
[ 126, q{Ci}, q{curie}, 37_000_000_000, $BQ ], |
247
|
|
|
|
|
|
|
[ 127, q{R}, q{rontgen}, 2.58e-4, $CPKG ], |
248
|
|
|
|
|
|
|
[ 128, q{phi0}, q{fluxiod quantum}, 2.067_850_6e-15, $WB ], |
249
|
|
|
|
|
|
|
[ |
250
|
|
|
|
|
|
|
undef, $CELSIUS, |
251
|
|
|
|
|
|
|
q{Celsius to Kelvin}, |
252
|
|
|
|
|
|
|
sub { |
253
|
|
|
|
|
|
|
return shift() + Class::Measure::Scientific::FX_992vb::zC(); |
254
|
|
|
|
|
|
|
}, |
255
|
|
|
|
|
|
|
$KELVIN, |
256
|
|
|
|
|
|
|
], |
257
|
|
|
|
|
|
|
[ |
258
|
|
|
|
|
|
|
undef, |
259
|
|
|
|
|
|
|
$KELVIN, |
260
|
|
|
|
|
|
|
q{Kelvin to Celsius}, |
261
|
|
|
|
|
|
|
sub { |
262
|
|
|
|
|
|
|
return shift() - Class::Measure::Scientific::FX_992vb::zC(); |
263
|
|
|
|
|
|
|
}, |
264
|
|
|
|
|
|
|
$CELSIUS, |
265
|
|
|
|
|
|
|
], |
266
|
|
|
|
|
|
|
[ |
267
|
|
|
|
|
|
|
undef, |
268
|
|
|
|
|
|
|
$FAHRENHEIT, |
269
|
|
|
|
|
|
|
q{Fahrenheit to Kelvin}, |
270
|
|
|
|
|
|
|
sub { |
271
|
|
|
|
|
|
|
return Class::Measure::Scientific::FX_992vb::zC() + |
272
|
|
|
|
|
|
|
( ( shift() * Class::Measure::Scientific::FX_992vb::FK() ) + |
273
|
|
|
|
|
|
|
Class::Measure::Scientific::FX_992vb::zF() ); |
274
|
|
|
|
|
|
|
}, |
275
|
|
|
|
|
|
|
$KELVIN, |
276
|
|
|
|
|
|
|
], |
277
|
|
|
|
|
|
|
[ |
278
|
|
|
|
|
|
|
undef, |
279
|
|
|
|
|
|
|
$KELVIN, |
280
|
|
|
|
|
|
|
q{Kelvin to Fahrenheit}, |
281
|
|
|
|
|
|
|
sub { |
282
|
|
|
|
|
|
|
return ( |
283
|
|
|
|
|
|
|
shift() - ( |
284
|
|
|
|
|
|
|
Class::Measure::Scientific::FX_992vb::zF() + |
285
|
|
|
|
|
|
|
Class::Measure::Scientific::FX_992vb::zC() |
286
|
|
|
|
|
|
|
) |
287
|
|
|
|
|
|
|
) / |
288
|
|
|
|
|
|
|
Class::Measure::Scientific::FX_992vb::FK(); |
289
|
|
|
|
|
|
|
}, |
290
|
|
|
|
|
|
|
$FAHRENHEIT, |
291
|
|
|
|
|
|
|
], |
292
|
|
|
|
|
|
|
); |
293
|
|
|
|
|
|
|
Readonly::Scalar my $MAX => length grep { $_[ $IDX{'idx'} ] } @CONST; |
294
|
|
|
|
|
|
|
Readonly::Hash my %LOG => ( |
295
|
|
|
|
|
|
|
'UNITS' => q{Registering units '%s'}, |
296
|
|
|
|
|
|
|
'CONST' => q{Contant %d is not available, there are only 128 constants}, |
297
|
|
|
|
|
|
|
); |
298
|
|
|
|
|
|
|
## use critic |
299
|
|
|
|
|
|
|
|
300
|
|
|
|
|
|
|
Log::Log4perl->easy_init($ERROR); |
301
|
|
|
|
|
|
|
my $log = get_logger(); |
302
|
|
|
|
|
|
|
|
303
|
|
|
|
|
|
|
for my $type ( keys %TYPES ) { |
304
|
|
|
|
|
|
|
|
305
|
|
|
|
|
|
|
sub _nom { |
306
|
648
|
|
|
648
|
|
1163
|
my $label = lc shift; |
307
|
648
|
|
|
|
|
1234
|
$label =~ s{\s+}{_}msx; |
308
|
648
|
|
|
|
|
2315
|
return $label; |
309
|
|
|
|
|
|
|
} |
310
|
|
|
|
|
|
|
## no critic (ProhibitNoStrict) |
311
|
18
|
|
|
18
|
|
195
|
no strict q{refs}; |
|
18
|
|
|
|
|
63
|
|
|
18
|
|
|
|
|
2974
|
|
312
|
|
|
|
|
|
|
## use critic |
313
|
|
|
|
|
|
|
*{ _nom($type) } = sub { |
314
|
77
|
|
|
77
|
|
103241
|
new(@_); |
315
|
|
|
|
|
|
|
}; |
316
|
|
|
|
|
|
|
} |
317
|
|
|
|
|
|
|
|
318
|
|
|
|
|
|
|
my @units = (); |
319
|
|
|
|
|
|
|
my @convs = (); |
320
|
|
|
|
|
|
|
for my $const (@CONST) { |
321
|
|
|
|
|
|
|
my $base = ${$const}[ $IDX{'base'} ]; |
322
|
|
|
|
|
|
|
my $unit = ${$const}[ $IDX{'unit'} ]; |
323
|
|
|
|
|
|
|
my $multiplier = ${$const}[ $IDX{'multiplier'} ]; |
324
|
|
|
|
|
|
|
if ( $base ne $SKIP ) { |
325
|
|
|
|
|
|
|
push @convs, |
326
|
|
|
|
|
|
|
( |
327
|
|
|
|
|
|
|
( ref $multiplier eq $CODE ) |
328
|
|
|
|
|
|
|
? ( $unit => $base, $multiplier ) |
329
|
|
|
|
|
|
|
: ( $unit => $multiplier, $base ) |
330
|
|
|
|
|
|
|
); |
331
|
|
|
|
|
|
|
push @units, ( $unit, $base ); |
332
|
|
|
|
|
|
|
} |
333
|
|
|
|
|
|
|
else { |
334
|
|
|
|
|
|
|
## no critic (ProhibitNoStrict) |
335
|
18
|
|
|
18
|
|
149
|
no strict q{refs}; |
|
18
|
|
|
|
|
46
|
|
|
18
|
|
|
|
|
5946
|
|
336
|
|
|
|
|
|
|
## use critic |
337
|
|
|
|
|
|
|
*{$unit} = sub { |
338
|
70
|
|
|
70
|
|
295
|
return $multiplier; |
339
|
|
|
|
|
|
|
}; |
340
|
|
|
|
|
|
|
} |
341
|
|
|
|
|
|
|
} |
342
|
|
|
|
|
|
|
|
343
|
|
|
|
|
|
|
sub CONST { |
344
|
6
|
|
|
6
|
1
|
3277
|
my $idx = shift; |
345
|
6
|
|
|
|
|
14
|
$idx--; |
346
|
6
|
100
|
100
|
|
|
146
|
if ( exists $CONST[$idx] && defined $CONST[$idx][ $IDX{'idx'} ] ) { |
347
|
3
|
|
|
|
|
99
|
return $CONST[$idx][ $IDX{'multiplier'} ]; |
348
|
|
|
|
|
|
|
} |
349
|
|
|
|
|
|
|
else { |
350
|
3
|
|
|
|
|
101
|
$log->error( sprintf $LOG{'CONST'}, $idx + 1 ); |
351
|
3
|
|
|
|
|
1259
|
return; |
352
|
|
|
|
|
|
|
} |
353
|
|
|
|
|
|
|
} |
354
|
|
|
|
|
|
|
|
355
|
|
|
|
|
|
|
sub new { |
356
|
79
|
|
|
79
|
1
|
2118
|
my ( $class, $amount, $unit ) = @_; |
357
|
|
|
|
|
|
|
|
358
|
79
|
|
|
|
|
7514
|
@units = uniq(@units); |
359
|
|
|
|
|
|
|
|
360
|
|
|
|
|
|
|
# Register in the constructor because Class::Measure doesn't allow |
361
|
|
|
|
|
|
|
# inheritance of registered data: |
362
|
79
|
|
|
|
|
2094
|
$log->debug( sprintf $LOG{'UNITS'}, join $SEP, @units ); |
363
|
79
|
100
|
|
|
|
1981
|
if ( 0 == $class->units() ) { |
364
|
17
|
|
|
|
|
528
|
$class->reg_units(@units); |
365
|
17
|
|
|
|
|
35182
|
$class->reg_convs(@convs); |
366
|
|
|
|
|
|
|
} |
367
|
|
|
|
|
|
|
|
368
|
79
|
|
|
|
|
51413
|
my $measure = $class->SUPER::new( $amount, $unit ); |
369
|
|
|
|
|
|
|
## no critic (ProhibitHashBarewords) |
370
|
79
|
|
|
|
|
1444
|
return $class->meta->new_object( __INSTANCE__ => $measure, $amount, $unit ); |
371
|
|
|
|
|
|
|
## use critic |
372
|
|
|
|
|
|
|
} |
373
|
|
|
|
|
|
|
|
374
|
18
|
|
|
18
|
|
194
|
no Moose; |
|
18
|
|
|
|
|
60
|
|
|
18
|
|
|
|
|
197
|
|
375
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable( 'inline_constructor' => 0 ); |
376
|
|
|
|
|
|
|
|
377
|
|
|
|
|
|
|
1; |
378
|
|
|
|
|
|
|
|
379
|
|
|
|
|
|
|
__END__ |
380
|
|
|
|
|
|
|
|
381
|
|
|
|
|
|
|
=begin stopwords |
382
|
|
|
|
|
|
|
|
383
|
|
|
|
|
|
|
Ipenburg JIS merchantability fx gradian poundal torr pdl inHg thermo ps BTUlbR |
384
|
|
|
|
|
|
|
BTUlb muB magneton gammap gyromagnetic Rinf weber wavenumber luminance lambert |
385
|
|
|
|
|
|
|
footlambert candela mol Vm polarizability Ds Neper thermochemical Bitbucket |
386
|
|
|
|
|
|
|
|
387
|
|
|
|
|
|
|
=end stopwords |
388
|
|
|
|
|
|
|
|
389
|
|
|
|
|
|
|
=head1 NAME |
390
|
|
|
|
|
|
|
|
391
|
|
|
|
|
|
|
Class::Measure::Scientific::FX_992vb - units of measurement like the CASIO fx-992vb |
392
|
|
|
|
|
|
|
|
393
|
|
|
|
|
|
|
=head1 VERSION |
394
|
|
|
|
|
|
|
|
395
|
|
|
|
|
|
|
This document describes Class::Measure::Scientific::FX_992vb C<v0.0.6>. |
396
|
|
|
|
|
|
|
|
397
|
|
|
|
|
|
|
=head1 SYNOPSIS |
398
|
|
|
|
|
|
|
|
399
|
|
|
|
|
|
|
use Class::Measure::Scientific::FX_992vb; |
400
|
|
|
|
|
|
|
$m = Class::Measure::Scientific::FX_992vb->mass(1, 'u'); |
401
|
|
|
|
|
|
|
print $m->kg(); |
402
|
|
|
|
|
|
|
|
403
|
|
|
|
|
|
|
=head1 DESCRIPTION |
404
|
|
|
|
|
|
|
|
405
|
|
|
|
|
|
|
Create, compare and convert units of measurement as the CASIO fx-992vb. This |
406
|
|
|
|
|
|
|
has little to do with the CASIO fx-992vb itself, the hardware just provides a |
407
|
|
|
|
|
|
|
stable curated scope of range and precision for the 128 constants used in this |
408
|
|
|
|
|
|
|
module so it won't be endlessly updated with more units or more precise |
409
|
|
|
|
|
|
|
constants. |
410
|
|
|
|
|
|
|
|
411
|
|
|
|
|
|
|
=head1 SUBROUTINES/METHODS |
412
|
|
|
|
|
|
|
|
413
|
|
|
|
|
|
|
=over 4 |
414
|
|
|
|
|
|
|
|
415
|
|
|
|
|
|
|
=item C<Class::Measure::Scientific::FX_992vb-E<gt>new(1, 'inHg')> |
416
|
|
|
|
|
|
|
|
417
|
|
|
|
|
|
|
Constructs a new Class::Measure::Scientific::FX_992vb object. This is the same |
418
|
|
|
|
|
|
|
type of object as the following list of specific objects, but the specific |
419
|
|
|
|
|
|
|
objects might in the future be able to handle conflicting aliases for units |
420
|
|
|
|
|
|
|
which the generic constructor can't. |
421
|
|
|
|
|
|
|
|
422
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>volume(1, 'cu');> |
423
|
|
|
|
|
|
|
|
424
|
|
|
|
|
|
|
Construct a L<volume|https://en.wikipedia.org/wiki/Volume> object. Unit must |
425
|
|
|
|
|
|
|
be one of C<m3> for L<cubic meter|https://en.wikipedia.org/wiki/Cubic_metre>, |
426
|
|
|
|
|
|
|
C<bbl> for L<barrel|https://en.wikipedia.org/wiki/Barrel_(unit)>, |
427
|
|
|
|
|
|
|
C<dry_barrel> for L<dry barrel|https://en.wikipedia.org/wiki/Barrel_(unit)>, |
428
|
|
|
|
|
|
|
C<bushel_uk> for L<UK bushel|https://en.wikipedia.org/wiki/Bushel>, C<bu> for |
429
|
|
|
|
|
|
|
L<bushel|https://en.wikipedia.org/wiki/Bushel>, C<cu> for |
430
|
|
|
|
|
|
|
L<cup|https://en.wikipedia.org/wiki/Cup_(unit)>, C<pt_dry> for L<dry |
431
|
|
|
|
|
|
|
pint|https://en.wikipedia.org/wiki/Dry_measure>, C<fbm> for L<board |
432
|
|
|
|
|
|
|
foot|https://en.wikipedia.org/wiki/Board_foot>, C<floz_uk> for L<UK fluid |
433
|
|
|
|
|
|
|
ounce|https://en.wikipedia.org/wiki/Fluid_ounce>, C<floz_us> for L<US fluid |
434
|
|
|
|
|
|
|
ounce|https://en.wikipedia.org/wiki/Fluid_ounce>, C<gal_uk> for L<UK |
435
|
|
|
|
|
|
|
gallon|https://en.wikipedia.org/wiki/Gallon>, C<gal_us> for L<US |
436
|
|
|
|
|
|
|
gallon|https://en.wikipedia.org/wiki/Gallon>, C<pk> for |
437
|
|
|
|
|
|
|
L<peck|https://en.wikipedia.org/wiki/Peck>, C<pt_uk> for |
438
|
|
|
|
|
|
|
L<pint|https://en.wikipedia.org/wiki/Pint>, C<pt_us> for L<liquid |
439
|
|
|
|
|
|
|
pint|https://en.wikipedia.org/wiki/Pint>, C<tbsp> for |
440
|
|
|
|
|
|
|
L<tablespoon|https://en.wikipedia.org/wiki/Tablespoon> or C<tsp> for |
441
|
|
|
|
|
|
|
L<teaspoon|https://en.wikipedia.org/wiki/Teaspoon>. |
442
|
|
|
|
|
|
|
|
443
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>area(1, 'acre');> |
444
|
|
|
|
|
|
|
|
445
|
|
|
|
|
|
|
Construct an L<area|https://en.wikipedia.org/wiki/Area> object. Unit must be |
446
|
|
|
|
|
|
|
C<m2> for L<square meter|https://en.wikipedia.org/wiki/Square_metre> or |
447
|
|
|
|
|
|
|
C<acre> for L<acre|https://en.wikipedia.org/wiki/Acre>. |
448
|
|
|
|
|
|
|
|
449
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>length(1, 'fathom');> |
450
|
|
|
|
|
|
|
|
451
|
|
|
|
|
|
|
Construct a L<length|https://en.wikipedia.org/wiki/Length> object. Unit must |
452
|
|
|
|
|
|
|
be one of C<m> for L<meter|https://en.wikipedia.org/wiki/Metre>, C<AU> for |
453
|
|
|
|
|
|
|
L<astronomical unit|https://en.wikipedia.org/wiki/Astronomical_unit>, C<ly> |
454
|
|
|
|
|
|
|
for L<light-year|https://en.wikipedia.org/wiki/Light-year>, C<nmi> for |
455
|
|
|
|
|
|
|
L<Nautical mile|https://en.wikipedia.org/wiki/Nautical_mile>, C<pc> for |
456
|
|
|
|
|
|
|
L<parsec|https://en.wikipedia.org/wiki/Parsec>, C<chain> for |
457
|
|
|
|
|
|
|
L<chain|https://en.wikipedia.org/wiki/Chain_(unit)>, C<fathom> for |
458
|
|
|
|
|
|
|
L<fathom|https://en.wikipedia.org/wiki/Fathom>, C<ft> for |
459
|
|
|
|
|
|
|
L<foot|https://en.wikipedia.org/wiki/Foot_(unit)>, C<ft_us> for US surveyors |
460
|
|
|
|
|
|
|
foot, C<in> for L<inch|https://en.wikipedia.org/wiki/Inch>, C<mil> for L<mil |
461
|
|
|
|
|
|
|
(1/1000th inch)|https://en.wikipedia.org/wiki/Thousandth_of_an_inch>, C<mile> |
462
|
|
|
|
|
|
|
for L<mile|https://en.wikipedia.org/wiki/Mile>, C<sm> for US statute miles, |
463
|
|
|
|
|
|
|
C<yd> for L<yard|https://en.wikipedia.org/wiki/Yard>, C<yd_us> for US yard, |
464
|
|
|
|
|
|
|
C<lambdacn> for L<Compton |
465
|
|
|
|
|
|
|
wavelength|https://en.wikipedia.org/wiki/Compton_wavelength> of neutron, |
466
|
|
|
|
|
|
|
C<lambdacp> for L<Compton |
467
|
|
|
|
|
|
|
wavelength|https://en.wikipedia.org/wiki/Compton_wavelength> of proton, C<a0> |
468
|
|
|
|
|
|
|
for L<Bohr radius|https://en.wikipedia.org/wiki/Bohr_radius> or C<re> for |
469
|
|
|
|
|
|
|
L<electron radius|https://en.wikipedia.org/wiki/Classical_electron_radius>. |
470
|
|
|
|
|
|
|
|
471
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>duration(1, 'year');> |
472
|
|
|
|
|
|
|
|
473
|
|
|
|
|
|
|
Construct a duration object. Unit must be C<s> for |
474
|
|
|
|
|
|
|
L<seconds|https://en.wikipedia.org/wiki/Second> or C<year> for L<tropical |
475
|
|
|
|
|
|
|
year|https://en.wikipedia.org/wiki/Tropical_year>. |
476
|
|
|
|
|
|
|
|
477
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>speed(1, 'c');> |
478
|
|
|
|
|
|
|
|
479
|
|
|
|
|
|
|
Construct a L<speed|https://en.wikipedia.org/wiki/Speed> object. Unit must be |
480
|
|
|
|
|
|
|
one of C<mps> for L<meter per |
481
|
|
|
|
|
|
|
second|https://en.wikipedia.org/wiki/Metre_per_second>, C<mph> for L<miles per |
482
|
|
|
|
|
|
|
hour|https://en.wikipedia.org/wiki/Miles_per_hour>, C<kn> for |
483
|
|
|
|
|
|
|
L<knot|https://en.wikipedia.org/wiki/Knot_(unit)> or C<c> for the L<speed of |
484
|
|
|
|
|
|
|
light|https://en.wikipedia.org/wiki/Speed_of_light>. |
485
|
|
|
|
|
|
|
|
486
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>acceleration(1, 'g');> |
487
|
|
|
|
|
|
|
|
488
|
|
|
|
|
|
|
Construct an L<acceleration|https://en.wikipedia.org/wiki/Acceleration> |
489
|
|
|
|
|
|
|
object. Unit must be one of C<g> for L<acceleration of free |
490
|
|
|
|
|
|
|
fall|https://en.wikipedia.org/wiki/Gravitational_acceleration> or C<mps2> for |
491
|
|
|
|
|
|
|
L<meters per second |
492
|
|
|
|
|
|
|
squared|https://en.wikipedia.org/wiki/Metre_per_second_squared>. |
493
|
|
|
|
|
|
|
|
494
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>angle(90, 'deg');> |
495
|
|
|
|
|
|
|
|
496
|
|
|
|
|
|
|
Construct an L<angle|https://en.wikipedia.org/wiki/Angle> object. Unit must be |
497
|
|
|
|
|
|
|
one of C<rad> for L<radian|https://en.wikipedia.org/wiki/Radian>, C<deg> for |
498
|
|
|
|
|
|
|
L<degree|https://en.wikipedia.org/wiki/Degree_(angle)>, C<minute> for L<minute |
499
|
|
|
|
|
|
|
of arc|https://en.wikipedia.org/wiki/Minute_and_second_of_arc>, C<second> for |
500
|
|
|
|
|
|
|
L<second of arc|https://en.wikipedia.org/wiki/Minute_and_second_of_arc> or |
501
|
|
|
|
|
|
|
C<grade> for L<gradian|https://en.wikipedia.org/wiki/Gradian>. |
502
|
|
|
|
|
|
|
|
503
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>mass(1, 'u');> |
504
|
|
|
|
|
|
|
|
505
|
|
|
|
|
|
|
Construct a L<mass|https://en.wikipedia.org/wiki/Mass> object. Unit must be |
506
|
|
|
|
|
|
|
one of C<kg> for L<kilogram|https://en.wikipedia.org/wiki/Kilogram>, C<ct> for |
507
|
|
|
|
|
|
|
L<metric carat|https://en.wikipedia.org/wiki/Carat_(mass)>, C<cwt_uk> for L<UK |
508
|
|
|
|
|
|
|
hundredweight|https://en.wikipedia.org/wiki/Hundredweight>, C<cwt_us> for US |
509
|
|
|
|
|
|
|
hundred weight, C<gr> for L<grain|https://en.wikipedia.org/wiki/Grain_(unit)>, |
510
|
|
|
|
|
|
|
C<lb> for L<pound|https://en.wikipedia.org/wiki/Pound_(mass)>, C<lbt> for troy |
511
|
|
|
|
|
|
|
pound, C<oz> for L<ounce|https://en.wikipedia.org/wiki/Ounce>, C<ozt> for |
512
|
|
|
|
|
|
|
L<troy ounce|https://en.wikipedia.org/wiki/Troy_weight>, C<slug> for |
513
|
|
|
|
|
|
|
L<slug|https://en.wikipedia.org/wiki/Slug_(unit)>, C<ton_uk> for L<long |
514
|
|
|
|
|
|
|
ton|https://en.wikipedia.org/wiki/Long_ton>, C<ton_us> for L<short |
515
|
|
|
|
|
|
|
ton|https://en.wikipedia.org/wiki/Short_ton>, C<m1h> for L<mass of hydrogen |
516
|
|
|
|
|
|
|
atom|https://en.wikipedia.org/wiki/Hydrogen_atom>, C<me> for mass of |
517
|
|
|
|
|
|
|
L<electron|https://en.wikipedia.org/wiki/Electron>, C<mn> for mass of |
518
|
|
|
|
|
|
|
L<neutron|https://en.wikipedia.org/wiki/Neutron>, C<mp> for mass of |
519
|
|
|
|
|
|
|
L<proton|https://en.wikipedia.org/wiki/Proton> or C<u> for L<atomic mass |
520
|
|
|
|
|
|
|
unit|https://en.wikipedia.org/wiki/Dalton_(unit)>. |
521
|
|
|
|
|
|
|
|
522
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>force(1, 'pdl');> |
523
|
|
|
|
|
|
|
|
524
|
|
|
|
|
|
|
Construct a L<force|https://en.wikipedia.org/wiki/Force> object. Unit must be |
525
|
|
|
|
|
|
|
one of C<N> for L<Newton|https://en.wikipedia.org/wiki/Newton_(unit)>, C<kgf> |
526
|
|
|
|
|
|
|
for L<kilogram-force|https://en.wikipedia.org/wiki/Kilogram-force>, C<lbf> for |
527
|
|
|
|
|
|
|
L<pound-force|https://en.wikipedia.org/wiki/Pound_(force)> or C<pdl> for |
528
|
|
|
|
|
|
|
L<poundal|https://en.wikipedia.org/wiki/Poundal>. |
529
|
|
|
|
|
|
|
|
530
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>pressure(1, 'inHg');> |
531
|
|
|
|
|
|
|
|
532
|
|
|
|
|
|
|
Construct a L<pressure|https://en.wikipedia.org/wiki/Pressure> object. Unit |
533
|
|
|
|
|
|
|
must be one of C<pa> for |
534
|
|
|
|
|
|
|
L<Pascal|https://en.wikipedia.org/wiki/Pascal_(unit)>, C<at> for L<technical |
535
|
|
|
|
|
|
|
atmosphere|https://en.wikipedia.org/wiki/Kilogram-force_per_square_centimetre>, |
536
|
|
|
|
|
|
|
C<atm> for L<standard |
537
|
|
|
|
|
|
|
atmosphere|https://en.wikipedia.org/wiki/Standard_atmosphere_(unit)>, C<mH2O> |
538
|
|
|
|
|
|
|
for L<meter of water|https://en.wikipedia.org/wiki/Centimetre_of_water>, |
539
|
|
|
|
|
|
|
C<mmHg> for millimeter mercury, C<Torr> for |
540
|
|
|
|
|
|
|
L<torr|https://en.wikipedia.org/wiki/Torr>, C<ftH2O> for foot of water, C<inH2O> |
541
|
|
|
|
|
|
|
for L<inch of water|https://en.wikipedia.org/wiki/Inch_of_water>, C<inHg> for |
542
|
|
|
|
|
|
|
L<inch of mercury|https://en.wikipedia.org/wiki/Inch_of_mercury> or C<psi> for |
543
|
|
|
|
|
|
|
L<pounds per square |
544
|
|
|
|
|
|
|
inch|https://en.wikipedia.org/wiki/Pounds_per_square_inch>. |
545
|
|
|
|
|
|
|
|
546
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>temperature(1, 'C');> |
547
|
|
|
|
|
|
|
|
548
|
|
|
|
|
|
|
Construct a L<temperature|https://en.wikipedia.org/wiki/Temperature> object. |
549
|
|
|
|
|
|
|
Unit must be one of C<C> for degrees |
550
|
|
|
|
|
|
|
L<Celsius|https://en.wikipedia.org/wiki/Celsius>, C<F> for degrees |
551
|
|
|
|
|
|
|
L<Fahrenheit|https://en.wikipedia.org/wiki/Fahrenheit> or C<K> for |
552
|
|
|
|
|
|
|
L<Kelvin|https://en.wikipedia.org/wiki/Kelvin>. |
553
|
|
|
|
|
|
|
|
554
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>energy(1, 'J');> |
555
|
|
|
|
|
|
|
|
556
|
|
|
|
|
|
|
Construct an L<energy|https://en.wikipedia.org/wiki/Energy> object. Unit must |
557
|
|
|
|
|
|
|
be one of C<J> for L<Joule|https://en.wikipedia.org/wiki/Joule>, C<BTU> for |
558
|
|
|
|
|
|
|
L<British thermal unit|https://en.wikipedia.org/wiki/British_thermal_unit>, |
559
|
|
|
|
|
|
|
C<ftlbf> for L<foot-pound|https://en.wikipedia.org/wiki/Foot-pound_(energy)>, |
560
|
|
|
|
|
|
|
C<hp> for L<horsepower|https://en.wikipedia.org/wiki/Horsepower>, C<cal15> for |
561
|
|
|
|
|
|
|
L<15 degree calorie|https://en.wikipedia.org/wiki/Calorie>, C<calit> for |
562
|
|
|
|
|
|
|
L<International calorie|https://en.wikipedia.org/wiki/Calorie> or C<calth> for |
563
|
|
|
|
|
|
|
L<thermochemical calorie|https://en.wikipedia.org/wiki/Calorie>. |
564
|
|
|
|
|
|
|
|
565
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>power(1, 'ps');> |
566
|
|
|
|
|
|
|
|
567
|
|
|
|
|
|
|
Construct a L<power|https://en.wikipedia.org/wiki/Power_(physics)> object. |
568
|
|
|
|
|
|
|
Unit must be one of C<W> for L<Watts|https://en.wikipedia.org/wiki/Watt>, |
569
|
|
|
|
|
|
|
C<ps> for L<metric |
570
|
|
|
|
|
|
|
horsepower|https://en.wikipedia.org/wiki/Horsepower#Metric_horsepower_(PS,_cv,_hk,_pk,_ks,_ch)> |
571
|
|
|
|
|
|
|
or C<BTUh> for L<BTU per |
572
|
|
|
|
|
|
|
hour|https://en.wikipedia.org/wiki/British_thermal_unit#As_a_unit_of_power>. |
573
|
|
|
|
|
|
|
|
574
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>linear_density(1, 'D');> |
575
|
|
|
|
|
|
|
|
576
|
|
|
|
|
|
|
Construct a L<linear density|https://en.wikipedia.org/wiki/Linear_density> |
577
|
|
|
|
|
|
|
object. Unit must be one of C<D> for |
578
|
|
|
|
|
|
|
L<Denier|https://en.wikipedia.org/wiki/Units_of_textile_measurement#Denier> or |
579
|
|
|
|
|
|
|
C<kgpm> for kilogram per meter. |
580
|
|
|
|
|
|
|
|
581
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>field_equation(1, 'G');> |
582
|
|
|
|
|
|
|
|
583
|
|
|
|
|
|
|
Construct a L<field |
584
|
|
|
|
|
|
|
equation|https://en.wikipedia.org/wiki/Einstein_field_equations> object. Unit |
585
|
|
|
|
|
|
|
must be one of C<G> for L<gravitational |
586
|
|
|
|
|
|
|
constant|https://en.wikipedia.org/wiki/Gravitational_constant> or C<Nm2pkg2> |
587
|
|
|
|
|
|
|
for Newton meter squared per kilogram squared. |
588
|
|
|
|
|
|
|
|
589
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>heat_capacity(1, |
590
|
|
|
|
|
|
|
'BTUlbR');> |
591
|
|
|
|
|
|
|
|
592
|
|
|
|
|
|
|
Construct a L<heat capacity|https://en.wikipedia.org/wiki/Heat_capacity> |
593
|
|
|
|
|
|
|
object. Unit must be one of C<BTUlbR> (British thermal unit per pound |
594
|
|
|
|
|
|
|
L<Rankine|https://en.wikipedia.org/wiki/Rankine_scale>) for L<specific heat |
595
|
|
|
|
|
|
|
capacity|https://en.wikipedia.org/wiki/Specific_heat_capacity#English_(Imperial)_engineering_units> |
596
|
|
|
|
|
|
|
or C<JpkgK> for Joule per kilogram Kelvin. |
597
|
|
|
|
|
|
|
|
598
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>thermodynamic(1, |
599
|
|
|
|
|
|
|
'BTUlb');> |
600
|
|
|
|
|
|
|
|
601
|
|
|
|
|
|
|
Construct a L<thermodynamic|https://en.wikipedia.org/wiki/Thermodynamics> |
602
|
|
|
|
|
|
|
object. Unit must be one of C<BTUlb> for L<specific internal |
603
|
|
|
|
|
|
|
energy|https://en.wikipedia.org/wiki/Internal_energy> or C<Jpkg> for Joule per |
604
|
|
|
|
|
|
|
kilogram. |
605
|
|
|
|
|
|
|
|
606
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>magnetic(1, 'muB');> |
607
|
|
|
|
|
|
|
|
608
|
|
|
|
|
|
|
Construct a L<magnetic object|https://en.wikipedia.org/wiki/Bohr_magneton>. |
609
|
|
|
|
|
|
|
Unit must be one of C<muB> for L<Bohr |
610
|
|
|
|
|
|
|
magneton|https://en.wikipedia.org/wiki/Bohr_magneton>, C<mue> for L<magnetic |
611
|
|
|
|
|
|
|
moment of electron|https://en.wikipedia.org/wiki/Electron_magnetic_moment>, |
612
|
|
|
|
|
|
|
C<muN> for L<nuclear |
613
|
|
|
|
|
|
|
magneton|https://en.wikipedia.org/wiki/Neutron_magnetic_moment>, C<mup> for |
614
|
|
|
|
|
|
|
L<magnetic moment of |
615
|
|
|
|
|
|
|
proton|https://en.wikipedia.org/wiki/Proton_magnetic_moment> or C<Am2> for |
616
|
|
|
|
|
|
|
Ampere meter squared. |
617
|
|
|
|
|
|
|
|
618
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>gyromagnetic(1, 'gammap');> |
619
|
|
|
|
|
|
|
|
620
|
|
|
|
|
|
|
Construct a L<gyromagnetic|https://en.wikipedia.org/wiki/Gyromagnetic_ratio> |
621
|
|
|
|
|
|
|
object. Unit must be one of C<gammap> for gyromagnetic ratio of proton, |
622
|
|
|
|
|
|
|
C<gammapalt> for gyromagnetic ratio of proton in water or C<Am2pJs> for Ampere |
623
|
|
|
|
|
|
|
meter squared per Joule second. |
624
|
|
|
|
|
|
|
|
625
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>electromagnetic(1, 'h');> |
626
|
|
|
|
|
|
|
|
627
|
|
|
|
|
|
|
Construct a electromagnetic object. Unit must be one of |
628
|
|
|
|
|
|
|
C<h> for L<Planck constant|https://en.wikipedia.org/wiki/Planck_constant>, |
629
|
|
|
|
|
|
|
C<hbar> for Planck constant per 2 Pi or C<Js> for Joule second. |
630
|
|
|
|
|
|
|
|
631
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>spectroscopic(1, |
632
|
|
|
|
|
|
|
'Rinf');> |
633
|
|
|
|
|
|
|
|
634
|
|
|
|
|
|
|
Construct a L<spectroscopic|https://en.wikipedia.org/wiki/Spectroscopy> |
635
|
|
|
|
|
|
|
object. Unit must be one of C<Rinf> for L<Rydberg constant for heavy |
636
|
|
|
|
|
|
|
atoms|https://en.wikipedia.org/wiki/Rydberg_constant> or C<pm> for per meter. |
637
|
|
|
|
|
|
|
|
638
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>radioactive(1, 'Ci');> |
639
|
|
|
|
|
|
|
|
640
|
|
|
|
|
|
|
Construct a L<radioactive|https://en.wikipedia.org/wiki/Radioactive_decay> |
641
|
|
|
|
|
|
|
object. Unit must be one of C<Ci> for |
642
|
|
|
|
|
|
|
L<Curie|https://en.wikipedia.org/wiki/Curie_(unit)> or C<Bq> for |
643
|
|
|
|
|
|
|
L<becquerel|https://en.wikipedia.org/wiki/Becquerel>. |
644
|
|
|
|
|
|
|
|
645
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>radiation(1, 'R');> |
646
|
|
|
|
|
|
|
|
647
|
|
|
|
|
|
|
Construct a L<radiation|https://en.wikipedia.org/wiki/Ionizing_radiation> |
648
|
|
|
|
|
|
|
object. Unit must be one of C<R> for |
649
|
|
|
|
|
|
|
L<Rontgen|https://en.wikipedia.org/wiki/Roentgen_(unit)> or C<Cpkg> for |
650
|
|
|
|
|
|
|
coulomb per kilogram. |
651
|
|
|
|
|
|
|
|
652
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>flux(1, 'phi0');> |
653
|
|
|
|
|
|
|
|
654
|
|
|
|
|
|
|
Construct a L<quantum |
655
|
|
|
|
|
|
|
flux|https://en.wikipedia.org/wiki/Magnetic_flux_quantum> object. Unit must be |
656
|
|
|
|
|
|
|
one of C<phi0> for L<magnetic flux |
657
|
|
|
|
|
|
|
quantum|https://en.wikipedia.org/wiki/Magnetic_flux_quantum> or C<Wb> for |
658
|
|
|
|
|
|
|
L<weber|https://en.wikipedia.org/wiki/Weber_(unit)>. |
659
|
|
|
|
|
|
|
|
660
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>wavelength(1, 'c1');> |
661
|
|
|
|
|
|
|
|
662
|
|
|
|
|
|
|
Construct a L<wavelength|https://en.wikipedia.org/wiki/Planck%27s_law> object. |
663
|
|
|
|
|
|
|
Unit must be one of C<c1> for first radiation constant or C<Wm2> for Watt |
664
|
|
|
|
|
|
|
meter squared. |
665
|
|
|
|
|
|
|
|
666
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>wavenumber(1, 'c2');> |
667
|
|
|
|
|
|
|
|
668
|
|
|
|
|
|
|
Construct a L<wavenumber|https://en.wikipedia.org/wiki/Planck%27s_law> object. |
669
|
|
|
|
|
|
|
Unit must be one of C<c2> for second radiation constant or C<mK> for meter |
670
|
|
|
|
|
|
|
Kelvin. |
671
|
|
|
|
|
|
|
|
672
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>luminance(1, 'lam');> |
673
|
|
|
|
|
|
|
|
674
|
|
|
|
|
|
|
Construct a L<luminance|https://en.wikipedia.org/wiki/Luminance> object. Unit |
675
|
|
|
|
|
|
|
must be one of C<lam> for |
676
|
|
|
|
|
|
|
L<lambert|https://en.wikipedia.org/wiki/Lambert_(unit)>, C<flam> for |
677
|
|
|
|
|
|
|
L<footlambert|https://en.wikipedia.org/wiki/Foot-lambert> or C<cdpm2> for |
678
|
|
|
|
|
|
|
L<candela per square |
679
|
|
|
|
|
|
|
meter|https://en.wikipedia.org/wiki/Candela_per_square_metre>. |
680
|
|
|
|
|
|
|
|
681
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>charge(1, 'e');> |
682
|
|
|
|
|
|
|
|
683
|
|
|
|
|
|
|
Construct a L<charge|https://en.wikipedia.org/wiki/Electric_charge> object. |
684
|
|
|
|
|
|
|
Unit must be one of C<e> for L<elementary |
685
|
|
|
|
|
|
|
charge|https://en.wikipedia.org/wiki/Elementary_charge> or C<C> for |
686
|
|
|
|
|
|
|
L<coulomb|https://en.wikipedia.org/wiki/Coulomb>. |
687
|
|
|
|
|
|
|
|
688
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>electrolysis(1, 'F');> |
689
|
|
|
|
|
|
|
|
690
|
|
|
|
|
|
|
Construct an L<electrolysis|https://en.wikipedia.org/wiki/Electrolysis> |
691
|
|
|
|
|
|
|
object. Unit must be one of C<f> for L<Faraday |
692
|
|
|
|
|
|
|
constant|https://en.wikipedia.org/wiki/Faraday_constant> (lowercase to avoid |
693
|
|
|
|
|
|
|
conflict with Fahrenheit) or C<Cpmol> for coulombs per mole. |
694
|
|
|
|
|
|
|
|
695
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>entropy(1, 'k');> |
696
|
|
|
|
|
|
|
|
697
|
|
|
|
|
|
|
Construct an L<entropy|https://en.wikipedia.org/wiki/Entropy> object. Unit |
698
|
|
|
|
|
|
|
must be one of C<k> for L<Boltzmann |
699
|
|
|
|
|
|
|
constant|https://en.wikipedia.org/wiki/Boltzmann_constant> or C<JpK> for Joule |
700
|
|
|
|
|
|
|
per Kelvin. |
701
|
|
|
|
|
|
|
|
702
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>proportionality(1, |
703
|
|
|
|
|
|
|
'Na');> |
704
|
|
|
|
|
|
|
|
705
|
|
|
|
|
|
|
Construct a |
706
|
|
|
|
|
|
|
L<proportionality|https://en.wikipedia.org/wiki/Proportionality_(mathematics)> |
707
|
|
|
|
|
|
|
object. Unit must be one of C<Na> for L<Avogadro |
708
|
|
|
|
|
|
|
constant|https://en.wikipedia.org/wiki/Avogadro_constant> or C<pmol> for per |
709
|
|
|
|
|
|
|
mole. |
710
|
|
|
|
|
|
|
|
711
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>gas(1, 'R');> |
712
|
|
|
|
|
|
|
|
713
|
|
|
|
|
|
|
Construct a L<gas|https://en.wikipedia.org/wiki/Ideal_gas_law> object. Unit |
714
|
|
|
|
|
|
|
must be one of C<R> for L<molar gas |
715
|
|
|
|
|
|
|
constant|https://en.wikipedia.org/wiki/Gas_constant> or C<JpmolK> for Joule |
716
|
|
|
|
|
|
|
per mole Kelvin. |
717
|
|
|
|
|
|
|
|
718
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>mixture(1, 'Vm');> |
719
|
|
|
|
|
|
|
|
720
|
|
|
|
|
|
|
Construct a L<mixture|https://en.wikipedia.org/wiki/Ideal_solution> object. |
721
|
|
|
|
|
|
|
Unit must be one of C<Vm> for L<molar |
722
|
|
|
|
|
|
|
volume|https://en.wikipedia.org/wiki/Molar_volume> or C<m3pmol> for cubic |
723
|
|
|
|
|
|
|
meter per mole. |
724
|
|
|
|
|
|
|
|
725
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>isotropic(1, 'alpha');> |
726
|
|
|
|
|
|
|
|
727
|
|
|
|
|
|
|
Construct an L<isotropic|https://en.wikipedia.org/wiki/Polarizability> object. |
728
|
|
|
|
|
|
|
Unit must be one of C<alpha> for polarizability of molecule or C<Cm2pV> for |
729
|
|
|
|
|
|
|
coulomb meter squared per Volt. |
730
|
|
|
|
|
|
|
|
731
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>susceptibility(1, 'p');> |
732
|
|
|
|
|
|
|
|
733
|
|
|
|
|
|
|
Construct a |
734
|
|
|
|
|
|
|
L<susceptibility|https://en.wikipedia.org/wiki/Electric_susceptibility> |
735
|
|
|
|
|
|
|
object. Unit must be one of C<p> for dipole of molecule or C<Cm> for coulomb |
736
|
|
|
|
|
|
|
meter. |
737
|
|
|
|
|
|
|
|
738
|
|
|
|
|
|
|
=item C<$f = Class::Measure::Scientific::FX_992vb-E<gt>displacement(1, 'Ds');> |
739
|
|
|
|
|
|
|
|
740
|
|
|
|
|
|
|
Construct a |
741
|
|
|
|
|
|
|
L<displacement|https://en.wikipedia.org/wiki/Electric_displacement_field> |
742
|
|
|
|
|
|
|
object. Unit must be one of C<Ds> for G. electric flux density, C<Ps> for G. |
743
|
|
|
|
|
|
|
electric polarization or C<Cpm2> for coulomb per square meter. |
744
|
|
|
|
|
|
|
|
745
|
|
|
|
|
|
|
=item C<Class::Measure::Scientific::FX_992vb::CONST(1);> |
746
|
|
|
|
|
|
|
|
747
|
|
|
|
|
|
|
All constants are available as the class method C<CONST> which takes the index |
748
|
|
|
|
|
|
|
of the constant as argument as number from 1 to 128. This is the way the |
749
|
|
|
|
|
|
|
constants are recalled on the CASIO fx-992vb. |
750
|
|
|
|
|
|
|
|
751
|
|
|
|
|
|
|
=back |
752
|
|
|
|
|
|
|
|
753
|
|
|
|
|
|
|
=head1 CONFIGURATION AND ENVIRONMENT |
754
|
|
|
|
|
|
|
|
755
|
|
|
|
|
|
|
None. |
756
|
|
|
|
|
|
|
|
757
|
|
|
|
|
|
|
=head1 DEPENDENCIES |
758
|
|
|
|
|
|
|
|
759
|
|
|
|
|
|
|
=over 4 |
760
|
|
|
|
|
|
|
|
761
|
|
|
|
|
|
|
=item * Perl 5.16 |
762
|
|
|
|
|
|
|
|
763
|
|
|
|
|
|
|
=item * L<Moose> |
764
|
|
|
|
|
|
|
|
765
|
|
|
|
|
|
|
=item * L<MooseX::NonMoose> |
766
|
|
|
|
|
|
|
|
767
|
|
|
|
|
|
|
=item * L<Class::Measure> 0.08 or newer |
768
|
|
|
|
|
|
|
|
769
|
|
|
|
|
|
|
=item * L<List::MoreUtils> |
770
|
|
|
|
|
|
|
|
771
|
|
|
|
|
|
|
=item * L<Log::Log4perl> |
772
|
|
|
|
|
|
|
|
773
|
|
|
|
|
|
|
=back |
774
|
|
|
|
|
|
|
|
775
|
|
|
|
|
|
|
=head1 INCOMPATIBILITIES |
776
|
|
|
|
|
|
|
|
777
|
|
|
|
|
|
|
This module has the same incompatibilities as L<Class::Measure>. |
778
|
|
|
|
|
|
|
|
779
|
|
|
|
|
|
|
=head1 DIAGNOSTICS |
780
|
|
|
|
|
|
|
|
781
|
|
|
|
|
|
|
This module uses L<Log::Log4perl> for logging. |
782
|
|
|
|
|
|
|
|
783
|
|
|
|
|
|
|
=head1 BUGS AND LIMITATIONS |
784
|
|
|
|
|
|
|
|
785
|
|
|
|
|
|
|
The values are based on the constants from the CASIO fx-992vb scientific |
786
|
|
|
|
|
|
|
calculator from the 90s, which are based on JIS-Z-8202-1988 (Japan Industrial |
787
|
|
|
|
|
|
|
Standards). These are not the latest standards and should not be used when |
788
|
|
|
|
|
|
|
more accurate values than those displayed in a pocket calculator from that era |
789
|
|
|
|
|
|
|
are expected. For example the L<2019 redefinition of the SI base |
790
|
|
|
|
|
|
|
units|https://en.wikipedia.org/wiki/2019_redefinition_of_the_SI_base_units> is |
791
|
|
|
|
|
|
|
not and won't be implemented in this module. |
792
|
|
|
|
|
|
|
|
793
|
|
|
|
|
|
|
=head2 Interval scales |
794
|
|
|
|
|
|
|
|
795
|
|
|
|
|
|
|
While the CASIO fx-992vb has the constants to convert between Celsius, |
796
|
|
|
|
|
|
|
Fahrenheit and Kelvin - using zero Celsius in Kelvin, zero Fahrenheit in |
797
|
|
|
|
|
|
|
Celsius and degree Fahrenheit in Kelvin/Celsius - Celsius and Fahrenheit are |
798
|
|
|
|
|
|
|
only units on interval scales as opposed to Kelvin which has a defined |
799
|
|
|
|
|
|
|
thermodynamic zero which makes it a unit on a ratio scale. This module does of |
800
|
|
|
|
|
|
|
course convert directly between those scales, but for completeness the |
801
|
|
|
|
|
|
|
constants used in those calculations can also be accessed as class methods. |
802
|
|
|
|
|
|
|
|
803
|
|
|
|
|
|
|
=over 4 |
804
|
|
|
|
|
|
|
|
805
|
|
|
|
|
|
|
=item * Zero Celsius C<Class::Measure::Scientific::FX_992vb::zC()> as |
806
|
|
|
|
|
|
|
I<273.15> Kelvin |
807
|
|
|
|
|
|
|
|
808
|
|
|
|
|
|
|
=item * Zero Fahrenheit C<Class::Measure::Scientific::FX_992vb::zF()> as |
809
|
|
|
|
|
|
|
I<-160/9> Celsius |
810
|
|
|
|
|
|
|
|
811
|
|
|
|
|
|
|
=item * Fahrenheit Kelvin ratio C<Class::Measure::Scientific::FX_992vb::FK()> |
812
|
|
|
|
|
|
|
as I<5/9> |
813
|
|
|
|
|
|
|
|
814
|
|
|
|
|
|
|
=back |
815
|
|
|
|
|
|
|
|
816
|
|
|
|
|
|
|
=head2 Dimensionless quantities |
817
|
|
|
|
|
|
|
|
818
|
|
|
|
|
|
|
Some constants are dimensionless quantities, which means they are independent |
819
|
|
|
|
|
|
|
of the system of unit used and can't be used to convert between units so they |
820
|
|
|
|
|
|
|
are useless in the functionality of this module. These dimensionless quantity |
821
|
|
|
|
|
|
|
constants are listed here for completeness and are available as class methods. |
822
|
|
|
|
|
|
|
|
823
|
|
|
|
|
|
|
=over 4 |
824
|
|
|
|
|
|
|
|
825
|
|
|
|
|
|
|
=item * L<Decibel|https://en.wikipedia.org/wiki/Decibel> level difference |
826
|
|
|
|
|
|
|
C<Class::Measure::Scientific::FX_992vb::dB()> as I<0.11512925465> |
827
|
|
|
|
|
|
|
|
828
|
|
|
|
|
|
|
=item * L<Neper|https://en.wikipedia.org/wiki/Neper> level difference |
829
|
|
|
|
|
|
|
C<Class::Measure::Scientific::FX_992vb::Np()> as I<8.68588963807> |
830
|
|
|
|
|
|
|
|
831
|
|
|
|
|
|
|
=item * L<Fine-structure |
832
|
|
|
|
|
|
|
constant|https://en.wikipedia.org/wiki/Fine-structure_constant> |
833
|
|
|
|
|
|
|
C<Class::Measure::Scientific::FX_992vb::a()> as I<7.2973506e-3> |
834
|
|
|
|
|
|
|
|
835
|
|
|
|
|
|
|
=back |
836
|
|
|
|
|
|
|
|
837
|
|
|
|
|
|
|
Please report any bugs or feature requests at |
838
|
|
|
|
|
|
|
L<Bitbucket| |
839
|
|
|
|
|
|
|
https://bitbucket.org/rolandvanipenburg/class-measure-scientific-fx_992vb/issues>. |
840
|
|
|
|
|
|
|
|
841
|
|
|
|
|
|
|
=head1 AUTHOR |
842
|
|
|
|
|
|
|
|
843
|
|
|
|
|
|
|
Roland van Ipenburg, E<lt>roland@rolandvanipenburg.comE<gt> |
844
|
|
|
|
|
|
|
|
845
|
|
|
|
|
|
|
=head1 LICENSE AND COPYRIGHT |
846
|
|
|
|
|
|
|
|
847
|
|
|
|
|
|
|
Copyright 2020-2021 by Roland van Ipenburg |
848
|
|
|
|
|
|
|
This program is free software; you can redistribute it and/or modify |
849
|
|
|
|
|
|
|
it under the GNU General Public License v3.0. |
850
|
|
|
|
|
|
|
|
851
|
|
|
|
|
|
|
=head1 DISCLAIMER OF WARRANTY |
852
|
|
|
|
|
|
|
|
853
|
|
|
|
|
|
|
BECAUSE THIS SOFTWARE IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY |
854
|
|
|
|
|
|
|
FOR THE SOFTWARE, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN |
855
|
|
|
|
|
|
|
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES |
856
|
|
|
|
|
|
|
PROVIDE THE SOFTWARE "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER |
857
|
|
|
|
|
|
|
EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
858
|
|
|
|
|
|
|
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE |
859
|
|
|
|
|
|
|
ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE SOFTWARE IS WITH |
860
|
|
|
|
|
|
|
YOU. SHOULD THE SOFTWARE PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL |
861
|
|
|
|
|
|
|
NECESSARY SERVICING, REPAIR, OR CORRECTION. |
862
|
|
|
|
|
|
|
|
863
|
|
|
|
|
|
|
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING |
864
|
|
|
|
|
|
|
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR |
865
|
|
|
|
|
|
|
REDISTRIBUTE THE SOFTWARE AS PERMITTED BY THE ABOVE LICENSE, BE |
866
|
|
|
|
|
|
|
LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL, |
867
|
|
|
|
|
|
|
OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE |
868
|
|
|
|
|
|
|
THE SOFTWARE (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING |
869
|
|
|
|
|
|
|
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A |
870
|
|
|
|
|
|
|
FAILURE OF THE SOFTWARE TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF |
871
|
|
|
|
|
|
|
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF |
872
|
|
|
|
|
|
|
SUCH DAMAGES. |
873
|
|
|
|
|
|
|
|
874
|
|
|
|
|
|
|
=cut |