@thi.ng/units 1.1.3 → 1.1.4

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.
package/README.md CHANGED
@@ -151,7 +151,6 @@ The following units are provided as "builtins", here grouped by dimension:
151
151
  | `m/s2` | `m_s2` | meter per second squared |
152
152
  | `ft/s2` | `ft_s2` | foot per second squared |
153
153
  | `rad/s2` | `rad_s2` | radian per second squared |
154
- | `g0` | `g0` | standard gravity |
155
154
 
156
155
  #### Angle
157
156
 
@@ -582,6 +581,7 @@ The following constants are provided (more to come):
582
581
  | `EARTH_CIRCUMFERENCE` | `m` | |
583
582
  | `EARTH_MASS` | `kg` | |
584
583
  | `EARTH_RADIUS` | `m` | |
584
+ | `G0` | `m/s2` | Standard gravity |
585
585
  | `GRAVITATION` | `kg-1·m3·s-2` | Gravitational constant |
586
586
  | `SPEED_OF_LIGHT` | `m/s` | |
587
587
  | `SPEED_OF_SOUND_IN_AIR` | `m/s` | at 20 ℃ |
@@ -687,7 +687,7 @@ For Node.js REPL:
687
687
  const units = await import("@thi.ng/units");
688
688
  ```
689
689
 
690
- Package sizes (brotli'd, pre-treeshake): ESM: 5.65 KB
690
+ Package sizes (brotli'd, pre-treeshake): ESM: 5.69 KB
691
691
 
692
692
  ## Dependencies
693
693
 
@@ -11,13 +11,21 @@ export declare const EARTH_RADIUS: import("../unit.js").Quantity<6371000>;
11
11
  */
12
12
  export declare const EARTH_CIRCUMFERENCE: import("../unit.js").Quantity<40075017>;
13
13
  /**
14
- * Using equatorial mean as alternative to {@link g0}.
14
+ * Using equatorial mean as alternative to {@link G0}.
15
15
  *
16
16
  * @remarks
17
17
  * Reference:
18
18
  * https://en.wikipedia.org/wiki/Gravity_of_Earth
19
19
  */
20
20
  export declare const EARTH_GRAVITY: import("../unit.js").Quantity<9.78033>;
21
+ /**
22
+ * Standard gravity
23
+ *
24
+ * @remarks
25
+ * Reference:
26
+ * https://en.wikipedia.org/wiki/Standard_gravity
27
+ */
28
+ export declare const G0: import("../unit.js").Quantity<9.80665>;
21
29
  /**
22
30
  * https://nssdc.gsfc.nasa.gov/planetary/factsheet/earthfact.html
23
31
  */
@@ -4,6 +4,7 @@ import { m } from "../units/length.js";
4
4
  const EARTH_RADIUS = quantity(6371e3, m);
5
5
  const EARTH_CIRCUMFERENCE = quantity(40075017, m);
6
6
  const EARTH_GRAVITY = quantity(9.78033, m_s2);
7
+ const G0 = quantity(9.80665, m_s2);
7
8
  const EARTH_MASS = quantity(59722e20, "kg");
8
9
  const GRAVITATION = quantity(
9
10
  66743e-15,
@@ -14,5 +15,6 @@ export {
14
15
  EARTH_GRAVITY,
15
16
  EARTH_MASS,
16
17
  EARTH_RADIUS,
18
+ G0,
17
19
  GRAVITATION
18
20
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/units",
3
- "version": "1.1.3",
3
+ "version": "1.1.4",
4
4
  "description": "Extensible SI unit creation, conversions, quantities & calculations (incl. Lisp-like DSL and ~170 predefined units & constants)",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -189,5 +189,5 @@
189
189
  "status": "beta",
190
190
  "year": 2021
191
191
  },
192
- "gitHead": "4bd1b9d8ae52ba32b90a1b9a55d329c708ca7865\n"
192
+ "gitHead": "b90a2f41eb0b3c89391bbb7cfff940192f23a83c\n"
193
193
  }
package/units/accel.d.ts CHANGED
@@ -1,5 +1,4 @@
1
1
  export declare const m_s2: import("../api.js").NamedUnit;
2
2
  export declare const ft_s2: import("../api.js").NamedUnit;
3
3
  export declare const rad_s2: import("../api.js").NamedUnit;
4
- export declare const g0: import("../api.js").NamedUnit;
5
4
  //# sourceMappingURL=accel.d.ts.map
package/units/accel.js CHANGED
@@ -1,7 +1,7 @@
1
+ import { defUnit, div, pow } from "../unit.js";
1
2
  import { rad } from "./angle.js";
2
3
  import { ft, m } from "./length.js";
3
4
  import { s } from "./time.js";
4
- import { defUnit, div, mul, pow } from "../unit.js";
5
5
  const s2 = pow(s, 2);
6
6
  const m_s2 = defUnit("m/s2", "meter per second squared", div(m, s2));
7
7
  const ft_s2 = defUnit("ft/s2", "foot per second squared", div(ft, s2));
@@ -10,10 +10,8 @@ const rad_s2 = defUnit(
10
10
  "radian per second squared",
11
11
  div(rad, s2)
12
12
  );
13
- const g0 = defUnit("g0", "standard gravity", mul(m_s2, 9.80665));
14
13
  export {
15
14
  ft_s2,
16
- g0,
17
15
  m_s2,
18
16
  rad_s2
19
17
  };