MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / mkP

Function mkP

benchmarks/big-decimal/ops-bench.mjs:54–54  ·  view source on GitHub ↗
(p)

Source from the content-addressed store, hash-verified

52};
53// p-digit BigDecimal in [1,10): leading nonzero digit, dot, p-1 fractional.
54const mkP = (p) => new B(`${1 + ((rnd() * 9) | 0)}.${digits(p - 1)}`);
55// p-digit BigDecimal in [0,2): safe, representative arg for exp/cos.
56const mkSmall = (p) => new B(`${(rnd() * 2).toFixed(0)}.${digits(p - 1)}`);
57// p-significant-digit BigInt with a few trailing zeros → exercises the

Callers 1

ops-bench.mjsFile · 0.70

Calls 2

digitsFunction · 0.85
rndFunction · 0.70

Tested by

no test coverage detected