unit_measurements 5.6.0 → 5.6.1
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/CHANGELOG.md +9 -0
- data/Gemfile.lock +1 -1
- data/README.md +13 -11
- data/lib/unit_measurements/unit_groups/acceleration.rb +4 -4
- data/lib/unit_measurements/unit_groups/angular_acceleration.rb +4 -4
- data/lib/unit_measurements/unit_groups/angular_velocity.rb +13 -13
- data/lib/unit_measurements/unit_groups/density.rb +13 -13
- data/lib/unit_measurements/unit_groups/dynamic_viscosity.rb +2 -2
- data/lib/unit_measurements/unit_groups/electric_conductance.rb +1 -1
- data/lib/unit_measurements/unit_groups/electric_potential.rb +2 -2
- data/lib/unit_measurements/unit_groups/electric_quadrupole_moment.rb +1 -1
- data/lib/unit_measurements/unit_groups/electrical_capacitance.rb +1 -1
- data/lib/unit_measurements/unit_groups/electrical_elastance.rb +1 -1
- data/lib/unit_measurements/unit_groups/electrical_inductance.rb +1 -1
- data/lib/unit_measurements/unit_groups/electrical_resistance.rb +1 -1
- data/lib/unit_measurements/unit_groups/frequency.rb +3 -3
- data/lib/unit_measurements/unit_groups/illuminance.rb +3 -3
- data/lib/unit_measurements/unit_groups/kinetic_viscosity.rb +1 -1
- data/lib/unit_measurements/unit_groups/length.rb +1 -1
- data/lib/unit_measurements/unit_groups/luminance.rb +4 -3
- data/lib/unit_measurements/unit_groups/magnetic_field.rb +1 -1
- data/lib/unit_measurements/unit_groups/power.rb +2 -2
- data/lib/unit_measurements/unit_groups/radiation_absorbed_dose.rb +2 -1
- data/lib/unit_measurements/unit_groups/solid_angle.rb +3 -1
- data/lib/unit_measurements/unit_groups/time.rb +2 -0
- data/lib/unit_measurements/unit_groups/velocity.rb +13 -13
- data/lib/unit_measurements/version.rb +1 -1
- data/units.md +74 -74
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 36ff08fd4410847cd93c13c849261ddc7c7638d5550d73461827e7947aa2e188
|
|
4
|
+
data.tar.gz: 952287fd15ec0fd62ec7b70e6751a555c47b0be5f28abdef5c1a2fdd432d9279
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 133041f8221f4e2993476a6761ffbd9d789aa2e890cbc91120d730e5f4be36c176083cefda6c29cb14efcb131f5f9ba8a58e0619bb1394e6900c09860a4c2c15
|
|
7
|
+
data.tar.gz: f3e8ddc100820a02e9700b06450bf2d51fe7968364bbabd37e1ff66184ec51d987d3f68d641b6c8b90fda34f9bfea31bc2991d92a2aa9ee646ad128e9a149d66
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,12 @@
|
|
|
1
|
+
## [5.6.1](https://github.com/shivam091/unit_measurements/compare/v5.6.0...v5.6.1) - 2023-11-03
|
|
2
|
+
|
|
3
|
+
### What's removed
|
|
4
|
+
|
|
5
|
+
- Removed uneeded aliases from units.
|
|
6
|
+
- Removed test cases of all unit conversions other than primitive unit.
|
|
7
|
+
|
|
8
|
+
----------
|
|
9
|
+
|
|
1
10
|
## [5.6.0](https://github.com/shivam091/unit_measurements/compare/v5.5.0...v5.6.0) - 2023-10-31
|
|
2
11
|
|
|
3
12
|
### What's new
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
|
@@ -23,15 +23,17 @@ to numerous errors.
|
|
|
23
23
|
The `unit_measurements` gem is designed to simplify the handling of units for scientific calculations.
|
|
24
24
|
|
|
25
25
|
## Key Features
|
|
26
|
-
|
|
26
|
+
|
|
27
|
+
1. **Flexible Measurement Conversion:** Easily convert measurements between compatible units, reducing the likelihood of errors in scientific calculations.
|
|
27
28
|
2. **Extensible Unit Groups:** Effortlessly build own unit groups with specific units and conversions tailored to your needs.
|
|
28
29
|
3. **Built-in Unit Groups:** Comes bundled with a wide range of standard [unit groups](https://github.com/shivam091/unit_measurements/blob/main/units.md),
|
|
29
30
|
covering various units.
|
|
30
31
|
4. **String Parsing Capabilities:** Effortlessly parse strings representing complex, fractional, mixed fractional, scientific numbers, and ratios directly
|
|
31
32
|
saving you the hassle of manually extracting and converting them.
|
|
32
33
|
5. **Comprehensive Documentation:** Well-organized and descriptive [documentation](https://shivam091.github.io/unit_measurements) for quick reference and implementation guidance.
|
|
33
|
-
6. **
|
|
34
|
-
7. **
|
|
34
|
+
6. **Caching Support:** Option to cache conversion factors for improved performance.
|
|
35
|
+
7. **Configurable Options:** Fine-tune behavior with configurable options, including caching for enhanced performance.
|
|
36
|
+
8. **Error Handling:** Robust error handling ensures stability and reliability during conversions.
|
|
35
37
|
|
|
36
38
|
## Disclaimer
|
|
37
39
|
|
|
@@ -94,12 +96,12 @@ UnitMeasurements::Length.new(1, "km")
|
|
|
94
96
|
This gem allows you to convert among units of same unit group. You can convert measurement to other unit using `#convert_to`
|
|
95
97
|
(aliased as `#to`, `#in`, and `#as`) or `#convert_to!` (aliased as `#to!`, `#in!`, and `#as!`) methods.
|
|
96
98
|
|
|
97
|
-
These methods provide `use_cache` parameter which
|
|
99
|
+
These methods provide `use_cache` parameter which defaults to `false` to indicate whether the caching of conversion factors should happen.
|
|
98
100
|
|
|
99
101
|
You can use `#convert_to` as:
|
|
100
102
|
|
|
101
103
|
```ruby
|
|
102
|
-
UnitMeasurements::Length.new(1, "km").convert_to("m")
|
|
104
|
+
UnitMeasurements::Length.new(1, "km").convert_to("m", use_cache: true)
|
|
103
105
|
#=> 1000.0 m
|
|
104
106
|
```
|
|
105
107
|
|
|
@@ -120,13 +122,13 @@ UnitMeasurements::Length.new(1, "cm").convert_to("primitive")
|
|
|
120
122
|
You can also chain call of `#convert_to` and `#convert_to!` methods as:
|
|
121
123
|
|
|
122
124
|
```ruby
|
|
123
|
-
UnitMeasurements::Length.new(100, "m").convert_to("ft").convert_to!("in")
|
|
125
|
+
UnitMeasurements::Length.new(100, "m").convert_to("ft").convert_to!("in", use_cache: true)
|
|
124
126
|
#=> 3937.00787401574071916010498688 in
|
|
125
127
|
```
|
|
126
128
|
|
|
127
129
|
**Parse string without having to split out the quantity and source unit:**
|
|
128
130
|
|
|
129
|
-
This method provides `use_cache` parameter which
|
|
131
|
+
This method provides `use_cache` parameter which defaults to `false` to indicate whether the caching of conversion factors should happen.
|
|
130
132
|
|
|
131
133
|
```ruby
|
|
132
134
|
UnitMeasurements::Length.parse("1 km")
|
|
@@ -185,11 +187,11 @@ UnitMeasurements::Length.parse("1:2 km to m")
|
|
|
185
187
|
|
|
186
188
|
**Formatting measurement:**
|
|
187
189
|
|
|
188
|
-
If you want to format measurement to certain format, you can use `#
|
|
190
|
+
If you want to format the measurement to certain format, you can use `#to_fs` method.
|
|
189
191
|
If format is not specified, it defaults to `"%.2<value>f %<unit>s"`.
|
|
190
192
|
|
|
191
193
|
```ruby
|
|
192
|
-
UnitMeasurements::Length.new(100, "m").to("in").
|
|
194
|
+
UnitMeasurements::Length.new(100, "m").to("in").to_fs("%.4<quantity>f %<unit>s")
|
|
193
195
|
#=> "3937.0079 in"
|
|
194
196
|
```
|
|
195
197
|
|
|
@@ -424,7 +426,7 @@ units within it. You can group units by the unit system using the `system` metho
|
|
|
424
426
|
unit group using the `primitive` method. You can specify cache file name in unit group definition using the `cache` method.
|
|
425
427
|
|
|
426
428
|
```ruby
|
|
427
|
-
UnitMeasurements::
|
|
429
|
+
UnitMeasurements::MyUnitGroup = UnitMeasurements.build do
|
|
428
430
|
# Set primitive unit for the unit group (optional).
|
|
429
431
|
primitive "s"
|
|
430
432
|
|
|
@@ -444,7 +446,7 @@ UnitMeasurements::Time = UnitMeasurements.build do
|
|
|
444
446
|
end
|
|
445
447
|
|
|
446
448
|
# Sets the name of the cache file (optional).
|
|
447
|
-
cache "
|
|
449
|
+
cache "my_units_cache.json"
|
|
448
450
|
end
|
|
449
451
|
```
|
|
450
452
|
|
|
@@ -6,21 +6,21 @@ UnitMeasurements::Acceleration = UnitMeasurements.build do
|
|
|
6
6
|
primitive "m/s²"
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
|
-
unit "m/s²", aliases: ["m/s^2", "
|
|
9
|
+
unit "m/s²", aliases: ["m/s^2", "meter per second squared", "meters per second squared", "metre per second squared", "metres per second squared"]
|
|
10
10
|
end
|
|
11
11
|
|
|
12
12
|
system :imperial do
|
|
13
|
-
unit "in/s²", value: "0.0254 m/s²", aliases: ["in/s^2", "
|
|
13
|
+
unit "in/s²", value: "0.0254 m/s²", aliases: ["in/s^2", "ips²", "inch per second squared", "inches per second squared"]
|
|
14
14
|
unit "ipm/s", value: "0.0004233333 m/s²", aliases: ["in/(min⋅s)", "inch per minute per second", "inches per minute per second"]
|
|
15
15
|
unit "iph/s", value: "7.055555e-6 m/s²", aliases: ["in/(h⋅s)", "inch per hour per second", "inches per hour per second"]
|
|
16
16
|
|
|
17
|
-
unit "mi/s²", value: "1609.344 m/s²", aliases: ["mi/s^2", "
|
|
17
|
+
unit "mi/s²", value: "1609.344 m/s²", aliases: ["mi/s^2", "mps²", "mile per second squared", "miles per second squared"]
|
|
18
18
|
unit "mpm/s", value: "26.8224 m/s²", aliases: ["mi/(min⋅s)", "mile per minute per second", "miles per minute per second"]
|
|
19
19
|
unit "mph/s", value: "0.44704 m/s²", aliases: ["mi/(h⋅s)", "mile per hour per second", "miles per hour per second"]
|
|
20
20
|
end
|
|
21
21
|
|
|
22
22
|
system :foot_pound_second do
|
|
23
|
-
unit "ft/s²", value: "0.3048 m/s²", aliases: ["ft/s^2", "
|
|
23
|
+
unit "ft/s²", value: "0.3048 m/s²", aliases: ["ft/s^2", "fps²", "foot per second squared", "feet per second squared"]
|
|
24
24
|
unit "fpm/s", value: "0.00508 m/s²", aliases: ["ft/(min⋅s)", "foot per minute per second", "feet per minute per second"]
|
|
25
25
|
unit "fph/s", value: "8.466667e-5 m/s²", aliases: ["ft/(h⋅s)", "foot per hour per second", "feet per hour per second"]
|
|
26
26
|
end
|
|
@@ -6,9 +6,9 @@ UnitMeasurements::AngularAcceleration = UnitMeasurements.build do
|
|
|
6
6
|
primitive "rad/s²"
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
|
-
si_unit "rad/s²", aliases: ["rad/s^2", "
|
|
10
|
-
unit "gon/s²", value: [(Math::PI / 200), "rad/s²"], aliases: ["gon/s^2", "ᵍ/s²", "gon·s⁻²", "gradian per second squared", "gradians per second squared"]
|
|
11
|
-
end
|
|
9
|
+
si_unit "rad/s²", aliases: ["rad/s^2", "radian per second squared", "radians per second squared"]
|
|
12
10
|
|
|
13
|
-
|
|
11
|
+
unit "deg/s²", value: [(Math::PI / 180), "rad/s²"], aliases: ["°/s²", "deg/s^2", "degree per second squared", "degrees per second squared"]
|
|
12
|
+
unit "gon/s²", value: [(Math::PI / 200), "rad/s²"], aliases: ["ᵍ/s²", "gon/s^2", "gradian per second squared", "gradians per second squared"]
|
|
13
|
+
end
|
|
14
14
|
end
|
|
@@ -6,20 +6,20 @@ UnitMeasurements::AngularVelocity = UnitMeasurements.build do
|
|
|
6
6
|
primitive "rad/s"
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
|
-
unit "rad/s", aliases: ["
|
|
10
|
-
unit "rad/min", value: "1/60 rad/s", aliases: ["
|
|
11
|
-
unit "rad/h", value: "1/60 rad/min", aliases: ["
|
|
9
|
+
unit "rad/s", aliases: ["radian per second", "radians per second"]
|
|
10
|
+
unit "rad/min", value: "1/60 rad/s", aliases: ["radian per minute", "radians per minute"]
|
|
11
|
+
unit "rad/h", value: "1/60 rad/min", aliases: ["radian per hour", "radians per hour"]
|
|
12
12
|
|
|
13
|
-
unit "
|
|
14
|
-
unit "
|
|
15
|
-
unit "
|
|
16
|
-
end
|
|
13
|
+
unit "deg/s", value: [(Math::PI / 180), "rad/s"], aliases: ["°/s", "degree per second", "degrees per second"]
|
|
14
|
+
unit "deg/min", value: "1/60 deg/s", aliases: ["°/min", "degree per minute", "degrees per minute"]
|
|
15
|
+
unit "deg/h", value: "1/60 deg/min", aliases: ["°/h", "degree per hour", "degrees per hour"]
|
|
17
16
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
17
|
+
unit "gon/s", value: [(Math::PI / 200), "rad/s"], aliases: ["ᵍ/s", "gradian per second", "gradians per second"]
|
|
18
|
+
unit "gon/min", value: "1/60 gon/s", aliases: ["ᵍ/min", "gradian per minute", "gradians per minute"]
|
|
19
|
+
unit "gon/h", value: "1/60 gon/min", aliases: ["ᵍ/h", "gradian per hour", "gradians per hour"]
|
|
20
|
+
end
|
|
21
21
|
|
|
22
|
-
unit "rev/s", value: "360 deg/s", aliases: ["
|
|
23
|
-
unit "rev/min", value: "1/60 rev/s", aliases: ["
|
|
24
|
-
unit "rev/h", value: "1/60 rev/min", aliases: ["
|
|
22
|
+
unit "rev/s", value: "360 deg/s", aliases: ["revolution per second", "revolutions per second"]
|
|
23
|
+
unit "rev/min", value: "1/60 rev/s", aliases: ["revolution per minute", "revolutions per minute"]
|
|
24
|
+
unit "rev/h", value: "1/60 rev/min", aliases: ["revolution per hour", "revolutions per hour"]
|
|
25
25
|
end
|
|
@@ -6,24 +6,24 @@ UnitMeasurements::Density = UnitMeasurements.build do
|
|
|
6
6
|
primitive "kg/m³"
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
|
-
unit "g/m³", aliases: ["g/m^3", "
|
|
10
|
-
unit "g/l", value: "1 kg/m³", aliases: ["
|
|
11
|
-
unit "g/ml", value: "1000 g/l", aliases: ["
|
|
9
|
+
unit "g/m³", aliases: ["g/m^3", "gram per cubic meter", "grams per cubic meter", "gramme per cubic metre", "grammes per cubic metre"]
|
|
10
|
+
unit "g/l", value: "1 kg/m³", aliases: ["gram per liter", "grams per liter", "gramme per litre", "grammes per litre"]
|
|
11
|
+
unit "g/ml", value: "1000 g/l", aliases: ["gram per milliliter", "grams per milliliter", "gramme per millilitre", "grammes per millilitre"]
|
|
12
12
|
|
|
13
|
-
unit "kg/l", value: "1e+6 g/m³", aliases: ["
|
|
14
|
-
unit "kg/m³", value: "1000 g/m³", aliases: ["kg/m^3", "
|
|
13
|
+
unit "kg/l", value: "1e+6 g/m³", aliases: ["kilogram per liter", "kilograms per liter", "kilogramme per litre", "kilogrammes per litre"]
|
|
14
|
+
unit "kg/m³", value: "1000 g/m³", aliases: ["kg/m^3", "kilogram per cubic meter", "kilograms per cubic meter", "kilogramme per cubic metre", "kilogrammes per cubic metre"]
|
|
15
15
|
end
|
|
16
16
|
|
|
17
17
|
system :imperial do
|
|
18
|
-
unit "oz/ft³", value: "1.001153961 kg/m³", aliases: ["oz/ft^3", "
|
|
19
|
-
unit "oz/in³", value: "1.729994044e+3 kg/m³", aliases: ["oz/in^3", "
|
|
20
|
-
unit "oz/gal", value: "6.236023291 kg/m³", aliases: ["
|
|
18
|
+
unit "oz/ft³", value: "1.001153961 kg/m³", aliases: ["oz/ft^3", "ounce per cubic foot", "ounces per cubic foot"]
|
|
19
|
+
unit "oz/in³", value: "1.729994044e+3 kg/m³", aliases: ["oz/in^3", "ounce per cubic inch", "ounces per cubic inch"]
|
|
20
|
+
unit "oz/gal", value: "6.236023291 kg/m³", aliases: ["ounce per gallon", "ounces per gallon"]
|
|
21
21
|
|
|
22
|
-
unit "lb/ft³", value: "16.01846337 kg/m³", aliases: ["lb/ft^3", "
|
|
23
|
-
unit "lb/in³", value: "2.767990471e+4 kg/m³", aliases: ["lb/in^3", "
|
|
24
|
-
unit "lb/gal", value: "99.77637266 kg/m³", aliases: ["
|
|
22
|
+
unit "lb/ft³", value: "16.01846337 kg/m³", aliases: ["lb/ft^3", "pound per cubic foot", "pounds per cubic foot"]
|
|
23
|
+
unit "lb/in³", value: "2.767990471e+4 kg/m³", aliases: ["lb/in^3", "pound per cubic inch", "pounds per cubic inch"]
|
|
24
|
+
unit "lb/gal", value: "99.77637266 kg/m³", aliases: ["pound per gallon", "pounds per gallon"]
|
|
25
25
|
|
|
26
|
-
unit "slug/ft³", value: "515.3788184 kg/m³", aliases: ["slug/ft^3", "slug
|
|
27
|
-
unit "slug/in³", value: "890574.582782 kg/m³", aliases: ["slug/in^3", "slug
|
|
26
|
+
unit "slug/ft³", value: "515.3788184 kg/m³", aliases: ["slug/ft^3", "slug per cubic foot", "slugs per cubic foot"]
|
|
27
|
+
unit "slug/in³", value: "890574.582782 kg/m³", aliases: ["slug/in^3", "slug per cubic inch", "slugs per cubic inch"]
|
|
28
28
|
end
|
|
29
29
|
end
|
|
@@ -15,8 +15,8 @@ UnitMeasurements::DynamicViscosity = UnitMeasurements.build do
|
|
|
15
15
|
end
|
|
16
16
|
|
|
17
17
|
system :foot_pound_second do
|
|
18
|
-
unit "lb/(ft⋅s)", value: "1.488164 Pa⋅s", aliases: ["lb/(ft*s)", "pound per foot second"]
|
|
19
|
-
unit "lb/(ft⋅h)", value: "0.0004133789 Pa⋅s", aliases: ["lb/(ft*h)", "pound per foot hour"]
|
|
18
|
+
unit "lb/(ft⋅s)", value: "1.488164 Pa⋅s", aliases: ["lb/(ft*s)", "pound per foot second", "pounds per foot second"]
|
|
19
|
+
unit "lb/(ft⋅h)", value: "0.0004133789 Pa⋅s", aliases: ["lb/(ft*h)", "pound per foot hour", "pounds per foot hour"]
|
|
20
20
|
|
|
21
21
|
unit "(lbf⋅s)/ft²", value: "47.88026 Pa⋅s", aliases: ["(lb⋅s)/ft²", "(lbf*s)/ft^2", "(lb*s)/ft^2", "pound-force second per square foot"]
|
|
22
22
|
unit "(lbf⋅s)/in²", value: "6894.757 Pa⋅s", aliases: ["(lb⋅s)/in²", "(lbf*s)/in^2", "(lb*s)/in^2", "pound-force second per square inch"]
|
|
@@ -8,7 +8,7 @@ UnitMeasurements::ElectricConductance = UnitMeasurements.build do
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "S", aliases: ["℧", "Ω⁻¹", "siemens", "mho", "mhos"]
|
|
10
10
|
|
|
11
|
-
unit "A/V", value: "1 S", aliases: ["
|
|
11
|
+
unit "A/V", value: "1 S", aliases: ["amp/volt", "amps/volt", "ampere/volt", "amperes/volt", "ampere per volt", "amperes per volt"]
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
system :centimetre_gram_second do
|
|
@@ -8,8 +8,8 @@ UnitMeasurements::ElectricPotential = UnitMeasurements.build do
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "V", aliases: ["volt", "volts"]
|
|
10
10
|
|
|
11
|
-
unit "W/A", value: "1 V", aliases: ["
|
|
12
|
-
unit "J/C", value: "1 V", aliases: ["
|
|
11
|
+
unit "W/A", value: "1 V", aliases: ["watt per ampere", "watts per ampere"]
|
|
12
|
+
unit "J/C", value: "1 V", aliases: ["joule per coulomb", "joules per coulomb"]
|
|
13
13
|
end
|
|
14
14
|
|
|
15
15
|
system :centimetre_gram_second do
|
|
@@ -10,7 +10,7 @@ UnitMeasurements::ElectricQuadrupoleMoment = UnitMeasurements.build do
|
|
|
10
10
|
end
|
|
11
11
|
|
|
12
12
|
system :centimetre_gram_second do
|
|
13
|
-
unit "statC·cm²", value: "3.335641e-14 C·m²", aliases: ["statC*m^2", "statcoulomb square meter", "statcoulomb square metre"]
|
|
14
13
|
unit "B", value: "1e-26 statC·cm²", aliases: ["buckingham", "buckinghams"]
|
|
14
|
+
unit "statC·cm²", value: "3.335641e-14 C·m²", aliases: ["statC*m^2", "statcoulomb square meter", "statcoulomb square metre"]
|
|
15
15
|
end
|
|
16
16
|
end
|
|
@@ -8,7 +8,7 @@ UnitMeasurements::ElectricalCapacitance = UnitMeasurements.build do
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "F", aliases: ["farad", "farads"]
|
|
10
10
|
|
|
11
|
-
unit "C/V", value: "1 F", aliases: ["
|
|
11
|
+
unit "C/V", value: "1 F", aliases: ["coulomb/volt", "coulombs/volt", "coulomb per volt", "coulombs per volt"]
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
system :centimetre_gram_second do
|
|
@@ -8,6 +8,6 @@ UnitMeasurements::ElectricalElastance = UnitMeasurements.build do
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "D", aliases: ["F⁻¹", "daraf", "darafs", "reciprocal farad", "reciprocal farads"]
|
|
10
10
|
|
|
11
|
-
unit "V/C", value: "1 D", aliases: ["
|
|
11
|
+
unit "V/C", value: "1 D", aliases: ["volt/coulomb", "volts/coulomb", "volt per coulomb", "volts per coulomb"]
|
|
12
12
|
end
|
|
13
13
|
end
|
|
@@ -8,7 +8,7 @@ UnitMeasurements::ElectricalInductance = UnitMeasurements.build do
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "H", aliases: ["henry", "henries"]
|
|
10
10
|
|
|
11
|
-
unit "Wb/A", value: "1 H", aliases: ["
|
|
11
|
+
unit "Wb/A", value: "1 H", aliases: ["weber per ampere", "webers per ampere"]
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
system :centimetre_gram_second do
|
|
@@ -9,7 +9,7 @@ UnitMeasurements::ElectricalResistance = UnitMeasurements.build do
|
|
|
9
9
|
si_unit "Ω", aliases: ["ω", "ohm", "ohms", "reciprocal siemens"]
|
|
10
10
|
|
|
11
11
|
unit "S", value: "1 Ω", aliases: ["siemens", "mho", "mhos"]
|
|
12
|
-
unit "V/A", value: "1 Ω", aliases: ["
|
|
12
|
+
unit "V/A", value: "1 Ω", aliases: ["volt/amp", "volts/amp", "volt/ampere", "volts/ampere", "volt per ampere", "volts per ampere"]
|
|
13
13
|
end
|
|
14
14
|
|
|
15
15
|
system :centimetre_gram_second do
|
|
@@ -8,9 +8,9 @@ UnitMeasurements::Frequency = UnitMeasurements.build do
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "Hz", aliases: ["hertz", "hertzes"]
|
|
10
10
|
|
|
11
|
-
unit "
|
|
11
|
+
unit "deg/s", value: [Rational(1, 360), "Hz"], aliases: ["°/s", "degree per second", "degrees per second"]
|
|
12
|
+
unit "rad/s", value: [Rational(1, (2 * Math::PI)), "Hz"], aliases: ["radian per second", "radians per second"]
|
|
12
13
|
end
|
|
13
14
|
|
|
14
|
-
unit "
|
|
15
|
-
unit "rev/s", value: [1, "Hz"], aliases: ["rps", "rev·s⁻¹", "revolution per second", "revolutions per second"]
|
|
15
|
+
unit "rev/s", value: [1, "Hz"], aliases: ["rps", "revolution per second", "revolutions per second"]
|
|
16
16
|
end
|
|
@@ -6,15 +6,15 @@ UnitMeasurements::Illuminance = UnitMeasurements.build do
|
|
|
6
6
|
primitive "lx"
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
|
-
si_unit "lx", aliases: ["lux", "lm/m²", "lm/m^2", "
|
|
9
|
+
si_unit "lx", aliases: ["lux", "lm/m²", "lm/m^2", "lumen per square metre", "lumen per square meter"]
|
|
10
10
|
end
|
|
11
11
|
|
|
12
12
|
system :centimetre_gram_second do
|
|
13
|
-
unit "ph", value: "10000 lx", aliases: ["phot", "phots", "lm/cm²", "lm/cm^2", "
|
|
13
|
+
unit "ph", value: "10000 lx", aliases: ["phot", "phots", "lm/cm²", "lm/cm^2", "lumen per square centimetre", "lumen per square centimeter"]
|
|
14
14
|
end
|
|
15
15
|
|
|
16
16
|
system :us_customary do
|
|
17
|
-
unit "fc", value: "10.763910417 lx", aliases: ["footcandle", "lm/ft²", "lm/ft^2", "
|
|
17
|
+
unit "fc", value: "10.763910417 lx", aliases: ["footcandle", "lm/ft²", "lm/ft^2", "lumen per square foot"]
|
|
18
18
|
end
|
|
19
19
|
|
|
20
20
|
unit "nx", value: "1 mlx", aliases: ["nox"]
|
|
@@ -17,7 +17,7 @@ UnitMeasurements::Length = UnitMeasurements.build do
|
|
|
17
17
|
unit "in", value: "25.4 mm", aliases: ['"', "inch", "inches"]
|
|
18
18
|
unit "ft", value: "12 in", aliases: ["'", "foot", "feet"]
|
|
19
19
|
unit "yd", value: "3 ft", aliases: ["yard", "yards"]
|
|
20
|
-
unit "mi", value: "5280 ft", aliases: ["mile", "miles", "statute mile", "international mile"]
|
|
20
|
+
unit "mi", value: "5280 ft", aliases: ["mile", "miles", "statute mile", "international mile", "statute miles", "international miles"]
|
|
21
21
|
unit "ch", value: "22 yd", aliases: ["chain", "chains"]
|
|
22
22
|
unit "th", value: "1/1000 in", aliases: ["thou", "thousandth of an inch", "mil", "mils"]
|
|
23
23
|
unit "nl", value: "3 nmi", aliases: ["NL", "nleague", "nleagues", "nautical league", "nautical leagues"]
|
|
@@ -6,13 +6,14 @@ UnitMeasurements::Luminance = UnitMeasurements.build do
|
|
|
6
6
|
primitive "cd/m²"
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
|
-
unit "cd/m²", aliases: ["cd/m^2", "
|
|
9
|
+
unit "cd/m²", aliases: ["cd/m^2", "candela per square metre", "candelas per square metre", "candela per square meter", "candelas per square meter"]
|
|
10
10
|
end
|
|
11
11
|
|
|
12
12
|
system :us_customary do
|
|
13
|
-
unit "cd/in²", value: "1550.0031 cd/m²", aliases: ["cd/in^2", "cd·in⁻²", "candela per square inch", "candelas per square inch"]
|
|
14
|
-
unit "cd/ft²", value: "10.763910417 cd/m²", aliases: ["cd/ft^2", "cd·ft⁻²", "candela per square foot", "candelas per square foot"]
|
|
15
13
|
unit "fL", value: [Rational(1, Math::PI), "cd/ft²"], aliases: ["ft-L", "foot lambert", "foot-lambert"]
|
|
14
|
+
|
|
15
|
+
unit "cd/in²", value: "1550.0031 cd/m²", aliases: ["cd/in^2", "candela per square inch", "candelas per square inch"]
|
|
16
|
+
unit "cd/ft²", value: "10.763910417 cd/m²", aliases: ["cd/ft^2", "candela per square foot", "candelas per square foot"]
|
|
16
17
|
end
|
|
17
18
|
|
|
18
19
|
system :centimetre_gram_second do
|
|
@@ -8,6 +8,6 @@ UnitMeasurements::MagneticField = UnitMeasurements.build do
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "Oe", aliases: ["oersted", "oersteds"]
|
|
10
10
|
|
|
11
|
-
unit "A/m", value: [(Math::PI / 250), "Oe"], aliases: ["
|
|
11
|
+
unit "A/m", value: [(Math::PI / 250), "Oe"], aliases: ["ampere/meter", "ampere/metre", "amperes/meter", "amperes/metre", "ampere per meter", "ampere per metre", "amperes per meter", "amperes per metre"]
|
|
12
12
|
end
|
|
13
13
|
end
|
|
@@ -16,8 +16,8 @@ UnitMeasurements::Power = UnitMeasurements.build do
|
|
|
16
16
|
end
|
|
17
17
|
|
|
18
18
|
system :centimetre_gram_second do
|
|
19
|
-
unit "erg/s", value: "1e-7 W", aliases: ["erg
|
|
19
|
+
unit "erg/s", value: "1e-7 W", aliases: ["erg per second", "ergs per second"]
|
|
20
20
|
end
|
|
21
21
|
|
|
22
|
-
unit "cal/s", value: "4.1868 W", aliases: ["
|
|
22
|
+
unit "cal/s", value: "4.1868 W", aliases: ["calorie per second", "calories per second"]
|
|
23
23
|
end
|
|
@@ -10,7 +10,8 @@ UnitMeasurements::RadiationAbsorbedDose = UnitMeasurements.build do
|
|
|
10
10
|
end
|
|
11
11
|
|
|
12
12
|
system :centimetre_gram_second do
|
|
13
|
-
unit "erg/g", value: "1e-4 Gy", aliases: ["erg per gram", "erg per gramme", "ergs per gram", "ergs per gramme"]
|
|
14
13
|
unit "rad", value: "0.01 Gy", aliases: ["radiation absorbed dose"]
|
|
14
|
+
|
|
15
|
+
unit "erg/g", value: "1e-4 Gy", aliases: ["erg per gram", "erg per gramme", "ergs per gram", "ergs per gramme"]
|
|
15
16
|
end
|
|
16
17
|
end
|
|
@@ -7,10 +7,12 @@ UnitMeasurements::SolidAngle = UnitMeasurements.build do
|
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
9
|
si_unit "sr", aliases: ["steradian", "steradians"]
|
|
10
|
+
|
|
11
|
+
unit "deg²", value: [((Math::PI / 180) ** 2), "sr"], aliases: ["(°)²", "sq °", "square degree", "square degrees"] # (π / 180)² sr
|
|
10
12
|
end
|
|
11
13
|
|
|
12
14
|
unit "sp", value: [(4 * Math::PI), "sr"], aliases: ["spat", "spats"] # (4 * π) sr
|
|
13
|
-
|
|
15
|
+
|
|
14
16
|
unit "arcmin²", value: [(Rational(1, 60) ** 2), "deg²"], aliases: ["(′)²", "sq ′", "square arcminute", "square arcminutes"] # ((π / 180) * (1 / 60))² sr
|
|
15
17
|
unit "arcsec²", value: [(Rational(1, 60) ** 2), "arcmin²"], aliases: ["(″)²", "sq ″", "square arcsecond", "square arcseconds"] # ((π / 180) * (1 / 3600))² sr
|
|
16
18
|
end
|
|
@@ -16,8 +16,10 @@ UnitMeasurements::Time = UnitMeasurements.build do
|
|
|
16
16
|
unit "wk", value: "7 d", aliases: ["week", "weeks"]
|
|
17
17
|
unit "mo", value: "30.4167 d", aliases: ["month", "months"]
|
|
18
18
|
unit "yr", value: "365 d", aliases: ["y", "year", "years"]
|
|
19
|
+
|
|
19
20
|
unit "ftn", value: "2 wk", aliases: ["4tnite", "fortnight", "fortnights"]
|
|
20
21
|
unit "qtr", value: "3 mo", aliases: ["quarter", "quarters"]
|
|
21
22
|
unit "dec", value: "10 y", aliases: ["decade", "decades"]
|
|
23
|
+
|
|
22
24
|
unit "cent", value: "10 dec", aliases: ["century", "centuries"]
|
|
23
25
|
end
|
|
@@ -6,29 +6,29 @@ UnitMeasurements::Velocity = UnitMeasurements.build do
|
|
|
6
6
|
primitive "m/s"
|
|
7
7
|
|
|
8
8
|
system :metric do
|
|
9
|
-
unit "m/s", aliases: ["
|
|
10
|
-
unit "m/min", value: "1/60 m/s", aliases: ["
|
|
11
|
-
unit "m/h", value: "1/60 m/min", aliases: ["
|
|
9
|
+
unit "m/s", aliases: ["meter per second", "meters per second", "metre per second", "metres per second"]
|
|
10
|
+
unit "m/min", value: "1/60 m/s", aliases: ["meter per minute", "meters per minute", "metre per minute", "metres per minute"]
|
|
11
|
+
unit "m/h", value: "1/60 m/min", aliases: ["meter per hour", "meters per hour", "metre per hour", "metres per hour"]
|
|
12
12
|
end
|
|
13
13
|
|
|
14
14
|
system :imperial do
|
|
15
|
-
unit "in/s", value: "0.0254 m/s", aliases: ["
|
|
16
|
-
unit "in/min", value: "1/60 in/s", aliases: ["
|
|
17
|
-
unit "in/h", value: "1/60 in/min", aliases: ["
|
|
15
|
+
unit "in/s", value: "0.0254 m/s", aliases: ["ips", "inch per second", "inches per second"]
|
|
16
|
+
unit "in/min", value: "1/60 in/s", aliases: ["ipm", "inch per minute", "inches per minute"]
|
|
17
|
+
unit "in/h", value: "1/60 in/min", aliases: ["iph", "inch per hour", "inches per hour"]
|
|
18
18
|
|
|
19
|
-
unit "mi/s", value: "1609.344 m/s", aliases: ["
|
|
20
|
-
unit "mi/min", value: "1/60 mi/s", aliases: ["
|
|
21
|
-
unit "mi/h", value: "1/60 mi/min", aliases: ["
|
|
19
|
+
unit "mi/s", value: "1609.344 m/s", aliases: ["mps", "mile per second", "miles per second"]
|
|
20
|
+
unit "mi/min", value: "1/60 mi/s", aliases: ["mpm", "mile per minute", "miles per minute"]
|
|
21
|
+
unit "mi/h", value: "1/60 mi/min", aliases: ["mph", "mile per hour", "miles per hour"]
|
|
22
22
|
end
|
|
23
23
|
|
|
24
24
|
system :foot_pound_second do
|
|
25
|
-
unit "ft/s", value: "12 in/s", aliases: ["
|
|
26
|
-
unit "ft/min", value: "1/60 ft/s", aliases: ["
|
|
27
|
-
unit "ft/h", value: "1/60 ft/min", aliases: ["
|
|
25
|
+
unit "ft/s", value: "12 in/s", aliases: ["fps", "foot per second", "feet per second"]
|
|
26
|
+
unit "ft/min", value: "1/60 ft/s", aliases: ["fpm", "foot per minute", "feet per minute"]
|
|
27
|
+
unit "ft/h", value: "1/60 ft/min", aliases: ["fph", "foot per hour", "feet per hour"]
|
|
28
28
|
end
|
|
29
29
|
|
|
30
30
|
system :furlong_firkin_fortnight do
|
|
31
|
-
unit "fur/ftn", value: "1.663e-4 m/s", aliases: ["
|
|
31
|
+
unit "fur/ftn", value: "1.663e-4 m/s", aliases: ["furlong per fortnight", "furlongs per fortnight"]
|
|
32
32
|
end
|
|
33
33
|
|
|
34
34
|
system :meteorology_aviation_maritime do
|
data/units.md
CHANGED
|
@@ -9,7 +9,7 @@ check below list of bundled units before converting your measurements.
|
|
|
9
9
|
|:--|:--|
|
|
10
10
|
| * | supports [decimal SI prefixes](README.md#decimal-si-prefixes) |
|
|
11
11
|
| ** | supports [binary SI prefixes](README.md#binary-si-prefixes) in addition to [decimal SI prefixes](README.md#decimal-si-prefixes) |
|
|
12
|
-
|
|
|
12
|
+
| _emphasised typeface_ | Primitive unit of the unit group |
|
|
13
13
|
|
|
14
14
|
## 1. Length or distance
|
|
15
15
|
|
|
@@ -23,7 +23,7 @@ These units are defined in `UnitMeasurements::Length`.
|
|
|
23
23
|
| 4 | in | ", inch, inches |
|
|
24
24
|
| 5 | ft | ', foot, feet |
|
|
25
25
|
| 6 | yd | yard, yards |
|
|
26
|
-
| 7 | mi | mile, miles, statute mile, international mile |
|
|
26
|
+
| 7 | mi | mile, miles, statute mile, international mile, statute miles, international miles |
|
|
27
27
|
| 8 | ch | chain, chains |
|
|
28
28
|
| 9 | th | thou, thousandth of an inch, mil, mils |
|
|
29
29
|
| 10 | au | astronomical unit, astronomical units |
|
|
@@ -189,19 +189,19 @@ These units are defined in `UnitMeasurements::Density`.
|
|
|
189
189
|
|
|
190
190
|
| # | Name | Aliases |
|
|
191
191
|
|:--|:--|:--|
|
|
192
|
-
| 1 | g/m³ | g/m^3,
|
|
193
|
-
| _2_ | _kg/m³_ | _kg/m^3,
|
|
194
|
-
| 3 | g/l |
|
|
195
|
-
| 4 | g/ml |
|
|
196
|
-
| 5 | kg/l |
|
|
197
|
-
| 6 | oz/ft³ | oz/ft^3,
|
|
198
|
-
| 7 | oz/in³ | oz/in^3,
|
|
199
|
-
| 8 | oz/gal |
|
|
200
|
-
| 9 | lb/ft³ | lb/ft^3,
|
|
201
|
-
| 10 | lb/in³ | lb/in^3,
|
|
202
|
-
| 11 | lb/gal |
|
|
203
|
-
| 12 | slug/ft³ | slug/ft^3, slug
|
|
204
|
-
| 13 | slug/in³ | slug/in^3, slug
|
|
192
|
+
| 1 | g/m³ | g/m^3, gram per cubic meter, grams per cubic meter, gramme per cubic metre, grammes per cubic metre |
|
|
193
|
+
| _2_ | _kg/m³_ | _kg/m^3, kilogram per cubic meter, kilograms per cubic meter, kilogramme per cubic metre, kilogrammes per cubic metre_ |
|
|
194
|
+
| 3 | g/l | gram per liter, grams per liter, gramme per litre, grammes per litre |
|
|
195
|
+
| 4 | g/ml | gram per milliliter, grams per milliliter, gramme per millilitre, grammes per millilitre |
|
|
196
|
+
| 5 | kg/l | kilogram per liter, kilograms per liter, kilogramme per litre, kilogrammes per litre |
|
|
197
|
+
| 6 | oz/ft³ | oz/ft^3, ounce per cubic foot, ounces per cubic foot |
|
|
198
|
+
| 7 | oz/in³ | oz/in^3, ounce per cubic inch, ounces per cubic inch |
|
|
199
|
+
| 8 | oz/gal | ounce per gallon, ounces per gallon |
|
|
200
|
+
| 9 | lb/ft³ | lb/ft^3, pound per cubic foot, pounds per cubic foot |
|
|
201
|
+
| 10 | lb/in³ | lb/in^3, pound per cubic inch, pounds per cubic inch |
|
|
202
|
+
| 11 | lb/gal | pound per gallon, pounds per gallon |
|
|
203
|
+
| 12 | slug/ft³ | slug/ft^3, slug per cubic foot, slugs per cubic foot |
|
|
204
|
+
| 13 | slug/in³ | slug/in^3, slug per cubic inch, slugs per cubic inch |
|
|
205
205
|
|
|
206
206
|
## 11. Quantity
|
|
207
207
|
|
|
@@ -274,19 +274,19 @@ These units are defined in `UnitMeasurements::Velocity`.
|
|
|
274
274
|
| # | Name | Aliases |
|
|
275
275
|
|:--|:--|:--|
|
|
276
276
|
| 1 | Kn | kt, knot, knots |
|
|
277
|
-
| _2_ | _m/s_ |
|
|
278
|
-
| 3 | m/min |
|
|
279
|
-
| 4 | m/h |
|
|
280
|
-
| 5 | in/s |
|
|
281
|
-
| 6 | in/min |
|
|
282
|
-
| 7 | in/h |
|
|
283
|
-
| 8 | ft/s |
|
|
284
|
-
| 9 | ft/min |
|
|
285
|
-
| 10 | ft/h |
|
|
286
|
-
| 11 | mi/s |
|
|
287
|
-
| 12 | mi/min |
|
|
288
|
-
| 13 | mi/h |
|
|
289
|
-
| 14 | fur/ftn |
|
|
277
|
+
| _2_ | _m/s_ | _meter per second, meters per second, metre per second, metres per second_ |
|
|
278
|
+
| 3 | m/min | meter per minute, meters per minute, metre per minute, metres per minute |
|
|
279
|
+
| 4 | m/h | meter per hour, meters per hour, metre per hour, metres per hour |
|
|
280
|
+
| 5 | in/s | ips, inch per second, inches per second |
|
|
281
|
+
| 6 | in/min | ipm, inch per minute, inches per minute |
|
|
282
|
+
| 7 | in/h | iph, inch per hour, inches per hour |
|
|
283
|
+
| 8 | ft/s | fps, foot per second, feet per second |
|
|
284
|
+
| 9 | ft/min | fpm, foot per minute, feet per minute |
|
|
285
|
+
| 10 | ft/h | fph, foot per hour, feet per hour |
|
|
286
|
+
| 11 | mi/s | mps, mile per second, miles per second |
|
|
287
|
+
| 12 | mi/min | mpm, mile per minute, miles per minute |
|
|
288
|
+
| 13 | mi/h | mph, mile per hour, miles per hour |
|
|
289
|
+
| 14 | fur/ftn | furlong per fortnight, furlongs per fortnight |
|
|
290
290
|
|
|
291
291
|
## 17. Acceleration
|
|
292
292
|
|
|
@@ -295,17 +295,17 @@ These units are defined in `UnitMeasurements::Acceleration`.
|
|
|
295
295
|
| # | Name | Aliases |
|
|
296
296
|
|:--|:--|:--|
|
|
297
297
|
| 1 | Gal | gal, galileo |
|
|
298
|
-
| _2_ | _m/s²_ | _m/s^2,
|
|
299
|
-
| 3 | in/s² | in/s^2,
|
|
298
|
+
| _2_ | _m/s²_ | _m/s^2, meter per second squared, meters per second squared, metre per second squared, metres per second squared_ |
|
|
299
|
+
| 3 | in/s² | in/s^2, ips², inch per second squared, inches per second squared |
|
|
300
300
|
| 4 | ipm/s | in/(min⋅s), inch per minute per second, inches per minute per second |
|
|
301
301
|
| 5 | iph/s | in/(h⋅s), inch per hour per second, inches per hour per second |
|
|
302
|
-
|
|
|
303
|
-
|
|
|
304
|
-
|
|
|
305
|
-
|
|
|
306
|
-
|
|
|
307
|
-
|
|
|
308
|
-
|
|
|
302
|
+
| 6 | ft/s² | ft/s^2, fps², foot per second squared, feet per second squared |
|
|
303
|
+
| 7 | fpm/s | ft/(min⋅s), foot per minute per second, feet per minute per second |
|
|
304
|
+
| 8 | fph/s | ft/(h⋅s), foot per hour per second, feet per hour per second |
|
|
305
|
+
| 9 | mi/s² | mi/s^2, mps², mile per second squared, miles per second squared |
|
|
306
|
+
| 10 | mpm/s | mi/(min⋅s), mile per minute per second, miles per minute per second |
|
|
307
|
+
| 11 | mph/s | mi/(h⋅s), mile per hour per second, miles per hour per second |
|
|
308
|
+
| 12 | Kn/s | knot per second, knots per second |
|
|
309
309
|
|
|
310
310
|
## 18. Angular velocity or rotational speed
|
|
311
311
|
|
|
@@ -313,18 +313,18 @@ These units are defined in `UnitMeasurements::AngularVelocity`.
|
|
|
313
313
|
|
|
314
314
|
| # | Name | Aliases |
|
|
315
315
|
|:--|:--|:--|
|
|
316
|
-
| _1_ | _rad/s_ |
|
|
317
|
-
| 2 | rad/min |
|
|
318
|
-
| 3 | rad/h |
|
|
319
|
-
| 4 | deg/s | °/s,
|
|
320
|
-
| 5 | deg/min | °/min,
|
|
321
|
-
| 6 | deg/h | °/h,
|
|
322
|
-
| 7 | rev/s |
|
|
323
|
-
| 8 | rev/min |
|
|
324
|
-
| 9 | rev/h |
|
|
325
|
-
| 10 | gon/s | ᵍ/s,
|
|
326
|
-
| 11 | gon/min | ᵍ/min,
|
|
327
|
-
| 12 | gon/h | ᵍ/h,
|
|
316
|
+
| _1_ | _rad/s_ | _radian per second, radians per second_ |
|
|
317
|
+
| 2 | rad/min | radian per minute, radians per minute |
|
|
318
|
+
| 3 | rad/h | radian per hour, radians per hour |
|
|
319
|
+
| 4 | deg/s | °/s, degree per second, degrees per second |
|
|
320
|
+
| 5 | deg/min | °/min, degree per minute, degrees per minute |
|
|
321
|
+
| 6 | deg/h | °/h, degree per hour, degrees per hour |
|
|
322
|
+
| 7 | rev/s | revolution per second, revolutions per second |
|
|
323
|
+
| 8 | rev/min | revolution per minute, revolutions per minute |
|
|
324
|
+
| 9 | rev/h | revolution per hour, revolutions per hour |
|
|
325
|
+
| 10 | gon/s | ᵍ/s, gradian per second, gradians per second |
|
|
326
|
+
| 11 | gon/min | ᵍ/min, gradian per minute, gradians per minute |
|
|
327
|
+
| 12 | gon/h | ᵍ/h, gradian per hour, gradians per hour |
|
|
328
328
|
|
|
329
329
|
## 19. Angular acceleration
|
|
330
330
|
|
|
@@ -332,9 +332,9 @@ These units are defined in `UnitMeasurements::AngularAcceleration`.
|
|
|
332
332
|
|
|
333
333
|
| # | Name | Aliases |
|
|
334
334
|
|:--|:--|:--|
|
|
335
|
-
| _1_ | _rad/s²_ | _rad/s^2,
|
|
336
|
-
| 2 | deg/s² | deg/s^2,
|
|
337
|
-
| 3 | gon/s² | gon/s^2,
|
|
335
|
+
| _1_ | _rad/s²_ | _rad/s^2, radian per second squared, radians per second squared_ |
|
|
336
|
+
| 2 | deg/s² | °/s², deg/s^2, degree per second squared, degrees per second squared |
|
|
337
|
+
| 3 | gon/s² | ᵍ/s², gon/s^2, gradian per second squared, gradians per second squared |
|
|
338
338
|
|
|
339
339
|
## 20. Electric potential or electromotive force
|
|
340
340
|
|
|
@@ -345,8 +345,8 @@ These units are defined in `UnitMeasurements::ElectricPotential`.
|
|
|
345
345
|
| _1_ | _V*_ | _volt, volts_ |
|
|
346
346
|
| 2 | abV | abvolt, abvolts |
|
|
347
347
|
| 3 | statV | statvolt, statvolts |
|
|
348
|
-
| 4 | W/A |
|
|
349
|
-
| 5 | J/C |
|
|
348
|
+
| 4 | W/A | watt per ampere, watts per ampere |
|
|
349
|
+
| 5 | J/C | joule per coulomb, joules per coulomb |
|
|
350
350
|
|
|
351
351
|
## 21. Electric charge
|
|
352
352
|
|
|
@@ -369,7 +369,7 @@ These units are defined in `UnitMeasurements::ElectricalCapacitance`.
|
|
|
369
369
|
| _1_ | _F*_ | _farad, farads_ |
|
|
370
370
|
| 2 | abF | abfarad, abfarads |
|
|
371
371
|
| 3 | statF | statfarad, statfarads |
|
|
372
|
-
| 4 | C/V |
|
|
372
|
+
| 4 | C/V | coulomb/volt, coulombs/volt, coulomb per volt, coulombs per volt |
|
|
373
373
|
|
|
374
374
|
## 23. Electrical elastance
|
|
375
375
|
|
|
@@ -378,7 +378,7 @@ These units are defined in `UnitMeasurements::ElectricalElastance`.
|
|
|
378
378
|
| # | Name | Aliases |
|
|
379
379
|
|:--|:--|:--|
|
|
380
380
|
| _1_ | _D*_ | _F⁻¹, daraf, darafs, reciprocal farad, reciprocal farads_ |
|
|
381
|
-
| 2 | V/C |
|
|
381
|
+
| 2 | V/C | volt/coulomb, volts/coulomb, volt per coulomb, volts per coulomb |
|
|
382
382
|
|
|
383
383
|
## 24. Electrical resistance or impedance
|
|
384
384
|
|
|
@@ -390,7 +390,7 @@ These units are defined in `UnitMeasurements::ElectricalResistance`.
|
|
|
390
390
|
| 2 | abΩ | abω, abohm, abohms |
|
|
391
391
|
| 3 | statΩ | statω, statohm, statohms |
|
|
392
392
|
| 4 | S | siemens, mho, mhos |
|
|
393
|
-
| 5 | V/A |
|
|
393
|
+
| 5 | V/A | volt/amp, volts/amp, volt/ampere, volts/ampere, volt per ampere, volts per ampere |
|
|
394
394
|
|
|
395
395
|
## 25. Electric conductance
|
|
396
396
|
|
|
@@ -401,7 +401,7 @@ These units are defined in `UnitMeasurements::ElectricConductance`.
|
|
|
401
401
|
| _1_ | _S*_ | _℧, Ω⁻¹, siemens, mho, mhos_ |
|
|
402
402
|
| 2 | abS | ab℧, absiemens, abmho, abmhos |
|
|
403
403
|
| 3 | statS | stat℧, statsiemens, statmho, statmhos |
|
|
404
|
-
| 3 | A/V |
|
|
404
|
+
| 3 | A/V | amp/volt, amps/volt, ampere/volt, amperes/volt, ampere per volt, amperes per volt |
|
|
405
405
|
|
|
406
406
|
## 26. Electrical inductance
|
|
407
407
|
|
|
@@ -412,7 +412,7 @@ These units are defined in `UnitMeasurements::ElectricalInductance`.
|
|
|
412
412
|
| _1_ | _H*_ | _henry, henries_ |
|
|
413
413
|
| 2 | abH | abhenry, abhenries |
|
|
414
414
|
| 3 | statH | stathenry, stathenries |
|
|
415
|
-
| 4 | Wb/A |
|
|
415
|
+
| 4 | Wb/A | weber per ampere, webers per ampere |
|
|
416
416
|
|
|
417
417
|
## 27. Magnetic flux
|
|
418
418
|
|
|
@@ -441,7 +441,7 @@ These units are defined in `UnitMeasurements::MagneticField`.
|
|
|
441
441
|
| # | Name | Aliases |
|
|
442
442
|
|:--|:--|:--|
|
|
443
443
|
| _1_ | _Oe*_ | _oersted, oersteds_ |
|
|
444
|
-
| 2 | A/m |
|
|
444
|
+
| 2 | A/m | ampere/meter, ampere/metre, amperes/meter, amperes/metre, ampere per meter, ampere per metre, amperes per meter, amperes per metre |
|
|
445
445
|
|
|
446
446
|
## 30. Catalytic activity
|
|
447
447
|
|
|
@@ -514,9 +514,9 @@ These units are defined in `UnitMeasurements::Illuminance`.
|
|
|
514
514
|
|
|
515
515
|
| # | Name | Aliases |
|
|
516
516
|
|:--|:--|:--|
|
|
517
|
-
| _1_ | _lx*_ | _lux, lm/m², lm/m^2,
|
|
518
|
-
| 2 | ph | phot, phots, lm/cm², lm/cm^2,
|
|
519
|
-
| 3 | fc | footcandle, lm/ft², lm/ft^2,
|
|
517
|
+
| _1_ | _lx*_ | _lux, lm/m², lm/m^2, lumen per square metre, lumen per square meter_ |
|
|
518
|
+
| 2 | ph | phot, phots, lm/cm², lm/cm^2, lumen per square centimetre, lumen per square centimeter |
|
|
519
|
+
| 3 | fc | footcandle, lm/ft², lm/ft^2, lumen per square foot |
|
|
520
520
|
| 4 | nx | nox |
|
|
521
521
|
|
|
522
522
|
## 37. Luminance
|
|
@@ -525,9 +525,9 @@ These units are defined in `UnitMeasurements::Luminance`.
|
|
|
525
525
|
|
|
526
526
|
| # | Name | Aliases |
|
|
527
527
|
|:--|:--|:--|
|
|
528
|
-
| _1_ | _cd/m²_ | _cd/m^2,
|
|
529
|
-
| 2 | cd/in² | cd/in^2,
|
|
530
|
-
| 3 | cd/ft² | cd/ft^2,
|
|
528
|
+
| _1_ | _cd/m²_ | _cd/m^2, candela per square metre, candelas per square metre, candela per square meter, candelas per square meter_ |
|
|
529
|
+
| 2 | cd/in² | cd/in^2, candela per square inch, candelas per square inch |
|
|
530
|
+
| 3 | cd/ft² | cd/ft^2, candela per square foot, candelas per square foot |
|
|
531
531
|
| 4 | fL | ft-L, foot lambert, foot-lambert |
|
|
532
532
|
| 5 | L | lambert, lamberts |
|
|
533
533
|
| 6 | sb | stlib |
|
|
@@ -539,9 +539,9 @@ These units are defined in `UnitMeasurements::Frequency`.
|
|
|
539
539
|
| # | Name | Aliases |
|
|
540
540
|
|:--|:--|:--|
|
|
541
541
|
| _1_ | _Hz*_ | _hertz, hertzes_ |
|
|
542
|
-
| 2 | rad/s |
|
|
543
|
-
| 3 | deg/s | °/s,
|
|
544
|
-
| 4 | rev/s | rps,
|
|
542
|
+
| 2 | rad/s | radian per second, radians per second |
|
|
543
|
+
| 3 | deg/s | °/s, degree per second, degrees per second |
|
|
544
|
+
| 4 | rev/s | rps, revolution per second, revolutions per second |
|
|
545
545
|
|
|
546
546
|
## 39. Power or heat flow rate
|
|
547
547
|
|
|
@@ -552,8 +552,8 @@ These units are defined in `UnitMeasurements::Power`.
|
|
|
552
552
|
| _1_ | _W*_ | _watt, watts_ |
|
|
553
553
|
| 2 | hp (M) | PS, metric horsepower |
|
|
554
554
|
| 3 | hp | hp (I), horsepower |
|
|
555
|
-
| 4 | erg/s | erg
|
|
556
|
-
| 5 | cal/s |
|
|
555
|
+
| 4 | erg/s | erg per second, ergs per second |
|
|
556
|
+
| 5 | cal/s | calorie per second, calories per second |
|
|
557
557
|
|
|
558
558
|
## 40. Energy
|
|
559
559
|
|
|
@@ -578,8 +578,8 @@ These units are defined in `UnitMeasurements::DynamicViscosity`.
|
|
|
578
578
|
|:--|:--|:--|
|
|
579
579
|
| _1_ | _Pa⋅s*_ | _Pa*s, pascal second_ |
|
|
580
580
|
| 2 | P | dyne·s/cm², dyne*s/cm^2, poise |
|
|
581
|
-
| 3 | lb/(ft⋅s) | lb/(ft*s), pound per foot second |
|
|
582
|
-
| 4 | lb/(ft⋅h) | lb/(ft*h), pound per foot hour |
|
|
581
|
+
| 3 | lb/(ft⋅s) | lb/(ft*s), pound per foot second, pounds per foot second |
|
|
582
|
+
| 4 | lb/(ft⋅h) | lb/(ft*h), pound per foot hour, pounds per foot hour |
|
|
583
583
|
| 5 | (lbf⋅s)/ft² | (lb⋅s)/ft², (lbf\*s)/ft^2, (lb\*s)/ft^2, pound-force second per square foot |
|
|
584
584
|
| 6 | (lbf⋅s)/in² | (lb⋅s)/in², (lbf\*s)/in^2, (lb\*s)/in^2, pound-force second per square inch |
|
|
585
585
|
| 7 | Pl | poiseuille |
|
|
@@ -591,7 +591,7 @@ These units are defined in `UnitMeasurements::KineticViscosity`.
|
|
|
591
591
|
| # | Name | Aliases |
|
|
592
592
|
|:--|:--|:--|
|
|
593
593
|
| _1_ | _m²/s_ | _m^2/s, square metre per second, square meter per second, square metres per second, square meters per second_ |
|
|
594
|
-
| 2 | St | strokes |
|
|
594
|
+
| 2 | St | stoke, strokes |
|
|
595
595
|
| 3 | ft²/s | ft^2/s, square foot per second, square feet per second |
|
|
596
596
|
| 4 | in²/s | in^2/s, square inch per second, square inches per second |
|
|
597
597
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: unit_measurements
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 5.6.
|
|
4
|
+
version: 5.6.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Harshal LADHE
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2023-
|
|
11
|
+
date: 2023-11-03 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|