unit_measurements 3.6.0 → 3.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '093ce14ea3ef94b656b3dd662af794f381fe69538d3f13045520c463331b41e2'
4
- data.tar.gz: 0bd30d1d40a96bb5f6237bd499c1da9427917a471a4780652c5c203334cae104
3
+ metadata.gz: '08735c5d46460f37e61ce9bfcdd4596ca4eb76820a9d9ea9e9fbeaf7ad8aaec8'
4
+ data.tar.gz: b4b955ab37cc097abcec88f1c898ad89990b8693dd7a0aaff6e0110946e91637
5
5
  SHA512:
6
- metadata.gz: 81d0e42bf1d4967821eb276f0574588a2bdf15ff9196659c7aafc34adf5a2da4cdcb4990bbac2e9a251117225ff39b31707ce4a09461416bd093868cd69c88d7
7
- data.tar.gz: 69ba5d10f7fb46451874f36db150aeff3516ce99b8394efc2402fa8d44600290c626817edba70620dc312040b0fdea93be4851ae527f255fae03f03481470647
6
+ metadata.gz: b674c2dcfb9ab7de21df9fa115fa21237b787ba3866a7ebe4b720ca875d57117e7e060cb374548ce2d4c669c2d2ef4fc34bbdcd10932a31d88e6fe652bd2ce1d
7
+ data.tar.gz: 5fb259148d43d1644b63866c76170cce4b8211905c2f8cbc6424e68192edc062f4eefbb312efeb9bc5a61344f95eba3b8c57de2c39df378b03e8df84f1e42d35
data/CHANGELOG.md CHANGED
@@ -1,3 +1,12 @@
1
+ ## [3.7.0](https://github.com/shivam091/unit_measurements/compare/v3.6.0...v3.7.0) - 2023-10-01
2
+
3
+ ### What's new
4
+
5
+ - Added unit group for `magnetic flux` units.
6
+ - Added unit group for `magnetic induction` units
7
+
8
+ ----------
9
+
1
10
  ## [3.6.0](https://github.com/shivam091/unit_measurements/compare/v3.5.0...v3.6.0) - 2023-10-01
2
11
 
3
12
  ### What's new
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- unit_measurements (3.6.0)
4
+ unit_measurements (3.7.0)
5
5
  activesupport (~> 7.0)
6
6
 
7
7
  GEM
@@ -28,6 +28,8 @@ require_relative "capacitance"
28
28
  require_relative "elastance"
29
29
  require_relative "resistance"
30
30
  require_relative "conductance"
31
+ require_relative "magnetic_flux"
32
+ require_relative "magnetic_induction"
31
33
 
32
34
  ## Other units
33
35
 
@@ -0,0 +1,19 @@
1
+ # -*- encoding: utf-8 -*-
2
+ # -*- frozen_string_literal: true -*-
3
+ # -*- warn_indent: true -*-
4
+
5
+ UnitMeasurements::MagneticFlux = UnitMeasurements.build do
6
+ system :metric do
7
+ primitive :Wb
8
+
9
+ si_unit :Wb, aliases: [:weber, :webers]
10
+ unit :"T·m²", value: "1 Wb", aliases: [:"T*m^2", :"tesla-square meter", :"tesla-square metre"]
11
+ end
12
+
13
+ system :centimetre_gram_second do
14
+ primitive :Mx
15
+
16
+ unit :Mx, value: "1e-8 Wb", aliases: [:maxwell, :maxwells]
17
+ unit :"G·cm²", value: "1e-8 Wb", aliases: [:"G*cm^2", :"gauss-square centimeter", :"gauss-square centimetre"]
18
+ end
19
+ end
@@ -0,0 +1,17 @@
1
+ # -*- encoding: utf-8 -*-
2
+ # -*- frozen_string_literal: true -*-
3
+ # -*- warn_indent: true -*-
4
+
5
+ UnitMeasurements::MagneticInduction = UnitMeasurements.build do
6
+ system :metric do
7
+ primitive :T
8
+
9
+ si_unit :T, aliases: [:tesla, :teslas]
10
+ end
11
+
12
+ system :centimetre_gram_second do
13
+ primitive :G
14
+
15
+ unit :G, value: "1e-4 T", aliases: [:Gs, :gauss, :gausses]
16
+ end
17
+ end
@@ -3,5 +3,5 @@
3
3
  # -*- warn_indent: true -*-
4
4
 
5
5
  module UnitMeasurements
6
- VERSION = "3.6.0"
6
+ VERSION = "3.7.0"
7
7
  end
data/units.md CHANGED
@@ -314,3 +314,23 @@ These units are defined in `UnitMeasurements::Conductance`.
314
314
  | 2 | abS | ab℧, absiemens, abmho, abmhos |
315
315
  | 3 | statS | stat℧, statsiemens, statmho, statmhos |
316
316
  | 3 | A/V | A·V⁻¹, amp./volt, amps./volt, ampere/volt, amperes/volt, ampere per volt, amperes per volt |
317
+
318
+ ## 26. Magnetic flux
319
+
320
+ These units are defined in `UnitMeasurements::MagneticFlux`.
321
+
322
+ | # | Name | Aliases |
323
+ |:--|:--|:--|
324
+ | 1 | Wb* | weber, webers |
325
+ | 2 | Mx | maxwell, maxwells |
326
+ | 3 | T·m² | T*m^2, tesla-square meter, tesla-square metre |
327
+ | 4 | G·cm² | G*cm^2, gauss-square centimeter, gauss-square centimetre |
328
+
329
+ ## 27. Magnetic induction
330
+
331
+ These units are defined in `UnitMeasurements::MagneticInduction`.
332
+
333
+ | # | Name | Aliases |
334
+ |:--|:--|:--|
335
+ | 1 | T* | tesla, teslas |
336
+ | 2 | G | Gs, gauss, gausses |
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: 3.6.0
4
+ version: 3.7.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-01 00:00:00.000000000 Z
11
+ date: 2023-10-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -133,6 +133,8 @@ files:
133
133
  - lib/unit_measurements/unit_groups/force.rb
134
134
  - lib/unit_measurements/unit_groups/length.rb
135
135
  - lib/unit_measurements/unit_groups/luminous_intensity.rb
136
+ - lib/unit_measurements/unit_groups/magnetic_flux.rb
137
+ - lib/unit_measurements/unit_groups/magnetic_induction.rb
136
138
  - lib/unit_measurements/unit_groups/plane_angle.rb
137
139
  - lib/unit_measurements/unit_groups/quantity.rb
138
140
  - lib/unit_measurements/unit_groups/resistance.rb