← Board · source

T-057: One maths library, so native and web can never drift apart

ready · M1 · model opus · needs T-009, T-010, T-011

Goal

A world must give the same bits on the Mac, in the browser and on any future machine. That is what lets a run made headless be opened on the web and continued. The danger is quiet: functions such as exp, sin, cos, tanh, ln and powf come from the platform and may differ in the last bit between targets. One differing bit grows into a different world.

T-011 found this and wrote its own exp and sine in crates/sim/src/fields/noise.rs. Every other module will meet the same problem. Solve it once, for everyone, in a way that cannot be forgotten.

Scope

Done when

Notes