LuxiEdge / Research

Why the same math gives different answers on different machines

Run the same program on a laptop, an ARM server, an x86 server and a GPU, and the last digits can differ. Three things cause most of it.

1. Elementary functions are not all correctly rounded

sin, exp, log and pow cannot be computed exactly, so each math library rounds its own approximation. Getting the correctly rounded answer every time is hard because of the Table Maker's Dilemma: some inputs land so close to a rounding boundary that far more precision is needed to decide which way to round. Lefèvre and Muller's introduction is the classic explanation. Libraries that skip this step can disagree in the last place, and that difference can grow.

2. The order of operations changes

Floating-point addition is not associative. Parallel sums on many threads or GPU cores can add in a different order from run to run, so totals drift. Data order matters too: in the open-source Oasis LMF catastrophe loss engine, the order items were numbered depended on how the lookup work was split across processes, and losses are summed in item order in 32-bit floats, so identical runs gave slightly different outputs.

3. Compilers and hardware make different choices

Fused multiply-add, vector widths and optimization flags change how intermediate results are rounded.

What we do about it

LuxiEdge builds one engine for exact, repeatable, verifiable computation, U.S. Patent No. 12,824,439 (issues December 8, 2026). We test by hashing outputs across machines. For example, our SGP4 orbit propagation results matched byte for byte across Mac, ARM Linux, x86 and an NVIDIA H100, while stock python-sgp4 hashes differed between them.

We reported the Oasis LMF reproducibility issue to its maintainers in issue #2211. They merged two fixes into main: PR #2243 on November 11, 2026 and PR #2244 on November 25, 2026.

See our catastrophe modeling work.

Further reading

Talk to us

Bring us the computation where a changing answer costs you.

Email eric@luxiedge.com or use the form on the contact page.