unit_measurements 4.3.0 → 4.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -0
- data/Gemfile.lock +1 -1
- data/lib/unit_measurements/unit_groups/all.rb +2 -0
- data/lib/unit_measurements/unit_groups/frequency.rb +16 -0
- data/lib/unit_measurements/unit_groups/luminance.rb +22 -0
- data/lib/unit_measurements/version.rb +1 -1
- data/units.md +24 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 97b1f40dcd946ddde0dcfc746431ac768147585a1aa5a100a356b8c59f9da235
|
4
|
+
data.tar.gz: 8f1453cb23ff2ae5140d8cfb0b72d4b8dba70025c5ac797c3bdc4a88d5c1020b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 12121950bb3682117d3d81851de85022a3409043ad9206f58f7a8c5f7caeaebc677175917b874013644cb68df505f3197f5ac21154a2a6708733ace96c3cfc11
|
7
|
+
data.tar.gz: df30c4e06c04adc8085c1fd902249d4bc1ba934017b8b1565617c543cbdf16c22c0904a21bc9f7c9644d1467753534e86025f50c7c6d66d5e20d059491947c41
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,12 @@
|
|
1
|
+
## [4.4.0](https://github.com/shivam091/unit_measurements/compare/v4.3.0...v4.4.0) - 2023-10-08
|
2
|
+
|
3
|
+
### What's new
|
4
|
+
|
5
|
+
- Added unit group for `luminance` units.
|
6
|
+
- Added unit group for `frequency` units.
|
7
|
+
|
8
|
+
----------
|
9
|
+
|
1
10
|
## [4.3.0](https://github.com/shivam091/unit_measurements/compare/v4.2.0...v4.3.0) - 2023-10-07
|
2
11
|
|
3
12
|
### What's new
|
data/Gemfile.lock
CHANGED
@@ -0,0 +1,16 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
# -*- frozen_string_literal: true -*-
|
3
|
+
# -*- warn_indent: true -*-
|
4
|
+
|
5
|
+
UnitMeasurements::Frequency = UnitMeasurements.build do
|
6
|
+
primitive "Hz"
|
7
|
+
|
8
|
+
system :metric do
|
9
|
+
si_unit "Hz", aliases: ["hertz", "hertzes"]
|
10
|
+
|
11
|
+
unit "rad/s", value: [Rational(1, (2 * Math::PI)), "Hz"], aliases: ["rad·s⁻¹", "radian per second", "radians per second"]
|
12
|
+
end
|
13
|
+
|
14
|
+
unit "deg/s", value: [Rational(1, 360), "Hz"], aliases: ["°/s", "deg·s⁻¹", "degree per second", "degrees per second"]
|
15
|
+
unit "rev/s", value: [1, "Hz"], aliases: ["rps", "rev·s⁻¹", "revolution per second", "revolutions per second"]
|
16
|
+
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
# -*- frozen_string_literal: true -*-
|
3
|
+
# -*- warn_indent: true -*-
|
4
|
+
|
5
|
+
UnitMeasurements::Luminance = UnitMeasurements.build do
|
6
|
+
primitive "cd/m²"
|
7
|
+
|
8
|
+
system :metric do
|
9
|
+
unit "cd/m²", aliases: ["cd/m^2", "cd·m⁻²", "candela per square metre", "candelas per square metre", "candela per square meter", "candelas per square meter"]
|
10
|
+
end
|
11
|
+
|
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
|
+
unit "fL", value: [Rational(1, Math::PI), "cd/ft²"], aliases: ["ft-L", "foot lambert", "foot-lambert"]
|
16
|
+
end
|
17
|
+
|
18
|
+
system :centimetre_gram_second do
|
19
|
+
unit "L", value: [Rational(10000, Math::PI), "cd/m²"], aliases: ["lambert", "lamberts"]
|
20
|
+
unit "sb", value: "10000 cd/m²", aliases: ["stlib"]
|
21
|
+
end
|
22
|
+
end
|
data/units.md
CHANGED
@@ -430,3 +430,27 @@ These units are defined in `UnitMeasurements::Illuminance`.
|
|
430
430
|
| 2 | ph | phot, phots, lm/cm², lm/cm^2, lm·cm⁻², lumen per square centimetre, lumen per square centimeter |
|
431
431
|
| 3 | fc | footcandle, lm/ft², lm/ft^2, lm·ft⁻², lumen per square foot |
|
432
432
|
| 4 | nx | nox |
|
433
|
+
|
434
|
+
## 37. Luminance
|
435
|
+
|
436
|
+
These units are defined in `UnitMeasurements::Luminance`.
|
437
|
+
|
438
|
+
| # | Name | Aliases |
|
439
|
+
|:--|:--|:--|
|
440
|
+
| _1_ | _cd/m²_ | _cd/m^2, cd·m⁻², candela per square metre, candelas per square metre, candela per square meter, candelas per square meter_ |
|
441
|
+
| 2 | cd/in² | cd/in^2, cd·in⁻², candela per square inch, candelas per square inch |
|
442
|
+
| 3 | cd/ft² | cd/ft^2, cd·ft⁻², candela per square foot, candelas per square foot |
|
443
|
+
| 4 | fL | ft-L, foot lambert, foot-lambert |
|
444
|
+
| 5 | L | lambert, lamberts |
|
445
|
+
| 6 | sb | stlib |
|
446
|
+
|
447
|
+
## 38. Frequency
|
448
|
+
|
449
|
+
These units are defined in `UnitMeasurements::Frequency`.
|
450
|
+
|
451
|
+
| # | Name | Aliases |
|
452
|
+
|:--|:--|:--|
|
453
|
+
| _1_ | _Hz*_ | _hertz, hertzes_ |
|
454
|
+
| 2 | rad/s | rad·s⁻¹, radian per second, radians per second |
|
455
|
+
| 3 | deg/s | °/s, deg·s⁻¹, degree per second, degrees per second |
|
456
|
+
| 4 | rev/s | rps, rev·s⁻¹, revolution per second, revolutions per second |
|
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: 4.
|
4
|
+
version: 4.4.0
|
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-10-
|
11
|
+
date: 2023-10-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -138,8 +138,10 @@ files:
|
|
138
138
|
- lib/unit_measurements/unit_groups/electrical_inductance.rb
|
139
139
|
- lib/unit_measurements/unit_groups/electrical_resistance.rb
|
140
140
|
- lib/unit_measurements/unit_groups/force.rb
|
141
|
+
- lib/unit_measurements/unit_groups/frequency.rb
|
141
142
|
- lib/unit_measurements/unit_groups/illuminance.rb
|
142
143
|
- lib/unit_measurements/unit_groups/length.rb
|
144
|
+
- lib/unit_measurements/unit_groups/luminance.rb
|
143
145
|
- lib/unit_measurements/unit_groups/luminous_flux.rb
|
144
146
|
- lib/unit_measurements/unit_groups/luminous_intensity.rb
|
145
147
|
- lib/unit_measurements/unit_groups/magnetic_field.rb
|