所有基本函数,来自单一的二进制运算符。
All elementary functions from a single binary operator

原始链接: https://arxiv.org/abs/2603.21852

本文提出一项令人惊讶的发现:一个单一的二元运算符 `eml(x,y) = exp(x) - ln(y)`,结合常数1,足以生成科学计算器上通常找到的*所有*基本函数。这包括算术运算、三角函数、对数以及像 *e*、π 和 *i* 这样的常数。 此前,连续数学需要多个不同的运算来进行这些计算。作者通过穷举搜索发现了这个运算符,并用一种简单、统一的语法展示了它的功能——每个表达式都形成一个 `eml` 节点的二叉树。 此外,论文表明这种“EML”结构允许基于梯度的符号回归,从而能够使用可训练的“EML树”和标准优化技术从数值数据中恢复精确的闭式公式。这表明了一种新的函数生成和公式发现方法。

最近的 Hacker News 讨论围绕一篇研究论文(arxiv.org),该论文详细描述了所有基本数学函数——如正弦、余弦、平方根和对数——可能仅使用一个二进制运算符 (EML) 来计算。 目前,这些函数需要多个不同的运算。这个想法引发了关于实际实现的争论:如何构建物理 EML 门,以及基于 EML 的架构与传统数学协处理器相比如何(可能对整数运算较慢,类似于 CORDIC 用于特定运算)。 评论者将其与诸如 brainf*ck 之类的深奥编程语言相提并论,并讨论了仅使用 EML 门构建模拟计算器的可能性。核心概念涉及推导出一元指数和对数,以实现加法和减法。
相关文章

原文

View a PDF of the paper titled All elementary functions from a single binary operator, by Andrzej Odrzywo{\l}ek

View PDF HTML (experimental)
Abstract:A single two-input gate suffices for all of Boolean logic in digital hardware. No comparable primitive has been known for continuous mathematics: computing elementary functions such as sin, cos, sqrt, and log has always required multiple distinct operations. Here I show that a single binary operator, eml(x,y)=exp(x)-ln(y), together with the constant 1, generates the standard repertoire of a scientific calculator. This includes constants such as e, pi, and i; arithmetic operations including addition, subtraction, multiplication, division, and exponentiation as well as the usual transcendental and algebraic functions. For example, exp(x)=eml(x,1), ln(x)=eml(1,eml(eml(1,x),1)), and likewise for all other operations. That such an operator exists was not anticipated; I found it by systematic exhaustive search and established constructively that it suffices for the concrete scientific-calculator basis. In EML (Exp-Minus-Log) form, every such expression becomes a binary tree of identical nodes, yielding a grammar as simple as S -> 1 | eml(S,S). This uniform structure also enables gradient-based symbolic regression: using EML trees as trainable circuits with standard optimizers (Adam), I demonstrate the feasibility of exact recovery of closed-form elementary functions from numerical data at shallow tree depths up to 4. The same architecture can fit arbitrary data, but when the generating law is elementary, it may recover the exact formula.
From: Andrzej Odrzywolek [view email]
[v1] Mon, 23 Mar 2026 11:40:24 UTC (1,393 KB)
[v2] Sat, 4 Apr 2026 06:31:05 UTC (1,245 KB)
联系我们 contact @ memedata.com