@justinelliottcobb/amari-wasm 0.9.9 → 0.9.10
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/amari_wasm.d.ts +11 -11
- package/amari_wasm.js +27 -27
- package/amari_wasm_bg.wasm +0 -0
- package/package.json +1 -1
package/amari_wasm.d.ts
CHANGED
|
@@ -4,22 +4,22 @@
|
|
|
4
4
|
* Initialize the enumerative geometry module
|
|
5
5
|
*/
|
|
6
6
|
export function initEnumerative(): void;
|
|
7
|
-
/**
|
|
8
|
-
* Validate that this module loaded correctly
|
|
9
|
-
*/
|
|
10
|
-
export function validate_relativistic_module(): boolean;
|
|
11
7
|
/**
|
|
12
8
|
* Convert velocity to Lorentz factor
|
|
13
9
|
*/
|
|
14
10
|
export function velocity_to_gamma(velocity_magnitude: number): number;
|
|
15
|
-
/**
|
|
16
|
-
* Calculate light deflection angle for photon grazing massive object
|
|
17
|
-
*/
|
|
18
|
-
export function light_deflection_angle(impact_parameter: number, mass: number): number;
|
|
19
11
|
/**
|
|
20
12
|
* Convert Lorentz factor to velocity
|
|
21
13
|
*/
|
|
22
14
|
export function gamma_to_velocity(gamma: number): number;
|
|
15
|
+
/**
|
|
16
|
+
* Validate that this module loaded correctly
|
|
17
|
+
*/
|
|
18
|
+
export function validate_relativistic_module(): boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Calculate light deflection angle for photon grazing massive object
|
|
21
|
+
*/
|
|
22
|
+
export function light_deflection_angle(impact_parameter: number, mass: number): number;
|
|
23
23
|
/**
|
|
24
24
|
* Initialize the WASM module
|
|
25
25
|
*/
|
|
@@ -2258,9 +2258,9 @@ export interface InitOutput {
|
|
|
2258
2258
|
readonly __wbg_wasmrotor_free: (a: number, b: number) => void;
|
|
2259
2259
|
readonly wasmmultiobjectiveoptimizer_new: () => number;
|
|
2260
2260
|
readonly wasmsimpleoptimizer_new: () => number;
|
|
2261
|
-
readonly
|
|
2262
|
-
readonly
|
|
2263
|
-
readonly
|
|
2261
|
+
readonly wasm_bindgen__convert__closures_____invoke__h9e55f7f912fc76ac: (a: number, b: number, c: any) => void;
|
|
2262
|
+
readonly wasm_bindgen__closure__destroy__ha65d378aaf4b53b1: (a: number, b: number) => void;
|
|
2263
|
+
readonly wasm_bindgen__convert__closures_____invoke__h04878e576420376d: (a: number, b: number, c: any, d: any) => void;
|
|
2264
2264
|
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
2265
2265
|
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
2266
2266
|
readonly __wbindgen_exn_store: (a: number) => void;
|
package/amari_wasm.js
CHANGED
|
@@ -268,15 +268,6 @@ function passArrayF64ToWasm0(arg, malloc) {
|
|
|
268
268
|
WASM_VECTOR_LEN = arg.length;
|
|
269
269
|
return ptr;
|
|
270
270
|
}
|
|
271
|
-
/**
|
|
272
|
-
* Validate that this module loaded correctly
|
|
273
|
-
* @returns {boolean}
|
|
274
|
-
*/
|
|
275
|
-
export function validate_relativistic_module() {
|
|
276
|
-
const ret = wasm.validate_relativistic_module();
|
|
277
|
-
return ret !== 0;
|
|
278
|
-
}
|
|
279
|
-
|
|
280
271
|
/**
|
|
281
272
|
* Convert velocity to Lorentz factor
|
|
282
273
|
* @param {number} velocity_magnitude
|
|
@@ -290,17 +281,6 @@ export function velocity_to_gamma(velocity_magnitude) {
|
|
|
290
281
|
return ret[0];
|
|
291
282
|
}
|
|
292
283
|
|
|
293
|
-
/**
|
|
294
|
-
* Calculate light deflection angle for photon grazing massive object
|
|
295
|
-
* @param {number} impact_parameter
|
|
296
|
-
* @param {number} mass
|
|
297
|
-
* @returns {number}
|
|
298
|
-
*/
|
|
299
|
-
export function light_deflection_angle(impact_parameter, mass) {
|
|
300
|
-
const ret = wasm.light_deflection_angle(impact_parameter, mass);
|
|
301
|
-
return ret;
|
|
302
|
-
}
|
|
303
|
-
|
|
304
284
|
/**
|
|
305
285
|
* Convert Lorentz factor to velocity
|
|
306
286
|
* @param {number} gamma
|
|
@@ -314,6 +294,26 @@ export function gamma_to_velocity(gamma) {
|
|
|
314
294
|
return ret[0];
|
|
315
295
|
}
|
|
316
296
|
|
|
297
|
+
/**
|
|
298
|
+
* Validate that this module loaded correctly
|
|
299
|
+
* @returns {boolean}
|
|
300
|
+
*/
|
|
301
|
+
export function validate_relativistic_module() {
|
|
302
|
+
const ret = wasm.validate_relativistic_module();
|
|
303
|
+
return ret !== 0;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
/**
|
|
307
|
+
* Calculate light deflection angle for photon grazing massive object
|
|
308
|
+
* @param {number} impact_parameter
|
|
309
|
+
* @param {number} mass
|
|
310
|
+
* @returns {number}
|
|
311
|
+
*/
|
|
312
|
+
export function light_deflection_angle(impact_parameter, mass) {
|
|
313
|
+
const ret = wasm.light_deflection_angle(impact_parameter, mass);
|
|
314
|
+
return ret;
|
|
315
|
+
}
|
|
316
|
+
|
|
317
317
|
/**
|
|
318
318
|
* Initialize the WASM module
|
|
319
319
|
*/
|
|
@@ -339,12 +339,12 @@ function getArrayU8FromWasm0(ptr, len) {
|
|
|
339
339
|
ptr = ptr >>> 0;
|
|
340
340
|
return getUint8ArrayMemory0().subarray(ptr / 1, ptr / 1 + len);
|
|
341
341
|
}
|
|
342
|
-
function
|
|
343
|
-
wasm.
|
|
342
|
+
function wasm_bindgen__convert__closures_____invoke__h9e55f7f912fc76ac(arg0, arg1, arg2) {
|
|
343
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h9e55f7f912fc76ac(arg0, arg1, arg2);
|
|
344
344
|
}
|
|
345
345
|
|
|
346
|
-
function
|
|
347
|
-
wasm.
|
|
346
|
+
function wasm_bindgen__convert__closures_____invoke__h04878e576420376d(arg0, arg1, arg2, arg3) {
|
|
347
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h04878e576420376d(arg0, arg1, arg2, arg3);
|
|
348
348
|
}
|
|
349
349
|
|
|
350
350
|
const AutoDiffFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
@@ -5680,7 +5680,7 @@ function __wbg_get_imports() {
|
|
|
5680
5680
|
const ret = arg0.length;
|
|
5681
5681
|
return ret;
|
|
5682
5682
|
};
|
|
5683
|
-
imports.wbg.
|
|
5683
|
+
imports.wbg.__wbg_log_660547816007a991 = function(arg0, arg1) {
|
|
5684
5684
|
console.log(getStringFromWasm0(arg0, arg1));
|
|
5685
5685
|
};
|
|
5686
5686
|
imports.wbg.__wbg_log_8cec76766b8c0e33 = function(arg0) {
|
|
@@ -5697,7 +5697,7 @@ function __wbg_get_imports() {
|
|
|
5697
5697
|
const a = state0.a;
|
|
5698
5698
|
state0.a = 0;
|
|
5699
5699
|
try {
|
|
5700
|
-
return
|
|
5700
|
+
return wasm_bindgen__convert__closures_____invoke__h04878e576420376d(a, state0.b, arg0, arg1);
|
|
5701
5701
|
} finally {
|
|
5702
5702
|
state0.a = a;
|
|
5703
5703
|
}
|
|
@@ -5800,7 +5800,7 @@ function __wbg_get_imports() {
|
|
|
5800
5800
|
};
|
|
5801
5801
|
imports.wbg.__wbindgen_cast_69f35aa0fcaecc47 = function(arg0, arg1) {
|
|
5802
5802
|
// Cast intrinsic for `Closure(Closure { dtor_idx: 37, function: Function { arguments: [Externref], shim_idx: 38, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
5803
|
-
const ret = makeMutClosure(arg0, arg1, wasm.
|
|
5803
|
+
const ret = makeMutClosure(arg0, arg1, wasm.wasm_bindgen__closure__destroy__ha65d378aaf4b53b1, wasm_bindgen__convert__closures_____invoke__h9e55f7f912fc76ac);
|
|
5804
5804
|
return ret;
|
|
5805
5805
|
};
|
|
5806
5806
|
imports.wbg.__wbindgen_cast_b63aeb0d85365734 = function(arg0, arg1) {
|
package/amari_wasm_bg.wasm
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"Amari Contributors"
|
|
6
6
|
],
|
|
7
7
|
"description": "WebAssembly bindings for Amari mathematical computing library - geometric algebra, tropical algebra, automatic differentiation, fusion systems, and information geometry",
|
|
8
|
-
"version": "0.9.
|
|
8
|
+
"version": "0.9.10",
|
|
9
9
|
"license": "MIT OR Apache-2.0",
|
|
10
10
|
"repository": {
|
|
11
11
|
"type": "git",
|