“The NAND gate for continuous math just got discovered — one operator, one constant, every calculator function.”
A single operator eml(x,y) = exp(x) − ln(y), paired with constant 1, generates every elementary function — arithmetic, trig, logarithms, constants like π and i. Think of it as the NAND gate for continuous math: one repeatable element suffices, but simple operations like multiplication balloon into depth-8 binary trees with 41+ nodes. The paper drew 375 points and 101 comments on Hacker News, split between excitement about theoretical elegance and skepticism about practical cost.
You know that elementary functions — sin, cos, log, sqrt, exponentiation — each need their own dedicated implementation in hardware, libraries, and calculators. They seem like fundamentally different operations. Boolean logic solved this decades ago with NAND: one gate type builds every digital circuit. Continuous math had no equivalent. You carry a bag of 36+ distinct primitives when, theoretically, far fewer might suffice — but nobody knew the minimum.
Define eml(x,y) = exp(x) − ln(y). Feed it the constant 1 as a seed. Iteratively bootstrap: eml(1,1) = e, eml(x,1) = exp(x), eml(1, eml(eml(1,x),1)) = ln(x), and so on through subtraction, negation, reciprocal, multiplication, division, trigonometric functions via Euler's formula, and all 36 standard calculator operations. The search used algebraically independent transcendental constants (Euler-Mascheroni γ, Glaisher-Kinkelin A) as test inputs with an inverse symbolic calculator to discover candidate formulas. The grammar reduces to S → 1 | eml(S,S) — every expression is a binary tree of identical nodes.
If you work in symbolic computation, computer algebra, or theoretical mathematics, this is a foundational result worth studying. If you build numerical libraries or scientific computing tools, the symbolic regression angle (trainable EML trees for formula discovery) is the most immediately relevant application. Not useful if you need efficient numerical computation — the expression blow-up makes ...
Worth reading for the theoretical result alone — it is genuinely surprising that a single binary operator suffices for all elementary math. The symbolic regression application (Section 4.3) is experimental: the author demonstrates exact recovery of elementary functions at shallow tree depths, but the EML compiler itself is described as an "unoptimized prototype" and direct searches timed out for several functions. This is an early-stage research result, not a production tool. Watch for follow-up work on the ternary variant that requires no constant.
View original sourceThis page gives you the hook. The full Snaplyze digest goes deeper so you can move from curiosity to decision with less noise.
Open the full digest to read the deeper breakdown, compare viewpoints, and get the practical next-step playbooks.
Read the full digest for deep-dive insight, Easy Mode, Pro Mode, and practical playbooks you can actually use.
Install Snaplyze