Work

MilAMin in the browser: a million unknowns a minute in TypeScript and WebAssembly

Year: 2026
Type: preprint
Abstract: In 2008 MILAMIN showed that a finite element code written in native MATLAB, a language then held to be too slow for large problems, could set up, solve and post-process one million unknowns per minute on a desktop, provided every stage of the pipeline gets equal care. This note brings the same pipeline to the web browser: Triangle meshing, 7-node Crouzeix-Raviart elements, supernodal Cholesky with fill-reducing ordering and Powell-Hestenes pressure iterations, in TypeScript and WebAssembly. Nothing is installed. Stokes models of inclusions, layers and grain swarms with up to two million unknowns are written in a few lines of JavaScript, and the folding and boudinage of layered rock is stepped through time. On a 2025 phone a million-unknown Stokes problem is meshed, assembled, factorized, iterated and rendered in nine seconds. Its assembly and solution alone take five to six times less than the 49 s the 2008 desktop needed for the same stages, and even a 2013 desktop lies below the 2008 curve at every size up to the four-gigabyte limit of WebAssembly. The largest gain came from the supernodal factorization, not from threads; the thread scaling on all devices is consistent with a memory-bandwidth limit. The solution is verified against the analytical circular-inclusion solution on a sequence of refined meshes. MilAMin, the browser version, runs at milamin.org; the code is public, under the GPL except for Triangle, which keeps its own terms, and the benchmark, the convergence study and the model presets have command-line twins that run the same code.
Language: English
Open Access status: green
OpenAlex ID: W7214005775
Cites: 11
Cited by:
Related to: 10