Live data from Hacker News

All elementary functions from a single binary operator

arxiv.org

31–40 of 317 posts

Re: All elementary functions from a single binary operator

#31
> A calculator with just two buttons, EML and the digit 1, can compute everything a full scientific calculator does

Reminds me of the Iota combinator, one of the smallest formal systems that can be combined to produce a universal Turing machine, meaning it can express all of computation.

Re: All elementary functions from a single binary operator

#33

> For example, exp(x)=eml(x,1), ln(x)=eml(1,eml(eml(1,x),1)), and likewise for all other operations I read the paper. Is there a table covering all other math operations translated to eml(x,y) form?

I think what you want is the supplementary information, part II "completeness proof sketch" on page 12. You already spotted the formulas for "exp" and real natural "L"og; then x - y = eml(L(x), exp(y)) and from there apparently it is all "standard" identities. They list the arithmetic operators then some constants, the square root, and exponentials, then the trig stuff is on the next page.

You can find this link on the right side of the arxiv page:

https://arxiv.org/src/2603.21852v2/anc/SupplementaryInformat...

Re: All elementary functions from a single binary operator

#35
post #15

Judging by the title, I thought I would have a good laugh, like when the doctor discovered numerical integration and published a paper. But no... This is about continuous math, not ones and zeroes. Assuming peer review proves it out, this is outstanding.

I don't think this is ever making it past the editor of any journal, let alone peer review.

Elementary functions such as exponentiation, logarithms and trigonometric functions are the standard vocabulary of STEM education. Each comes with its own rules and a dedicated button on a scientific calculator;

What?

and No comparable primitive has been known for continuous mathematics: computing elementary functions such as sin, cos, √ , and log has always required multiple distinct operations. Here we show that a single binary operator

Yeah, this is done by using tables and series. His method does not actually facilitate the computation of these functions.

There is no such things as "continuous mathematics". Maybe he meant to say continuous function?

Looking at page 14, it looks like he reinvented the concept of the vector valued function or something. The whole thing is rediscovering something that already exists.

Re: All elementary functions from a single binary operator

#36
post #18

How does one actually add with this?

Don't know adding, but multiplication has diagram on the last page of the PDF. xy = eml(eml(1, eml(eml(eml(eml(1, eml(eml(1, eml(1, x)), 1)), eml(1, eml(eml(1, eml(y, 1)), 1))), 1), 1)), 1) From Table 4, I think addition is slightly more complicated?

Thanks for posting that. You had a transcribing typo which was corrected in the ECMAScript below. Here's the calculation for 5 x 7:

    const eml = (x,y) => Math.exp(x) - Math.log(y);
    const mul = (x,y) => eml(eml(1,eml(eml(eml(1,eml(eml(1,eml(1,x)),1)),eml(1,eml(eml(1,eml(y,1)),1))),1)),1);
    console.log(mul(5,7));
> 35.00000000000001

For larger or negative inputs you get a NaN because ECMAScript has limited precision and doesn't handle imaginary numbers.

Re: All elementary functions from a single binary operator

#37

> eml(x,y)=exp(x)-ln(y) Exp and ln, isn't the operation its own inverse depending on the parameter? What a neat find.

> isn't the operation its own inverse depending on the parameter? This is a function from ℝ² to ℝ. It can't be its own inverse; what would that mean?

eml(1,eml(x,1)) = eml(eml(1,x),1) = exp(ln(x)) = ln(exp(x)) = x

Re: All elementary functions from a single binary operator

#38

EDIT: please change the article link to the most recent version (as of now still v2), it is currently pointing to the v1 version which misses the figures. I'm still reading this, but if this checks out, this is one of the most significant discoveries in years. Why use splines or polynomials or haphazardly chosen basis functions if you can just fit (gradient descent) your data or wave functions to the proper computati…

> Why use splines or polynomials or haphazardly chosen basis functions if you can just fit (gradient descent) your data or wave functions to the proper computational EML tree?

Same reason all boolean logic isn't performed with combinations of NAND – it's computationally inefficient. Polynomials are (for their expressivity) very quick to compute.

Re: All elementary functions from a single binary operator

#39
post #18

Earlier quoted context omitted.

Don't know adding, but multiplication has diagram on the last page of the PDF. xy = eml(eml(1, eml(eml(eml(eml(1, eml(eml(1, eml(1, x)), 1)), eml(1, eml(eml(1, eml(y, 1)), 1))), 1), 1)), 1) From Table 4, I think addition is slightly more complicated?

x+y = ln(exp(x) * exp(y)) exp(a) = eml(a, 1) ln(a)=eml(1,eml(eml(1,a),1)) Plugging those in is an excercise to the reader

might need to turn the paper sideways

Re: All elementary functions from a single binary operator

#40

How does one actually add with this?

It's basically using the "-" embedded in the definition of the eml operator.

Table 4 shows the "size" of the operators when fully expanded to "eml" applications, which is quite large for +, -, ×, and /.

Here's one approach which agrees with the minimum sizes they present:

        eml(x, y             ) = exp(x) − ln(y) # 1 + x + y
        eml(x, 1             ) = exp(x)         # 2 + x
        eml(1, y             ) = e - ln(y)      # 2 + y
        eml(1, exp(e - ln(y))) = ln(y)          # 6 + y; construction from eq (5)
                         ln(1) = 0              # 7
After you have ln and exp, you can invert their applications in the eml function

              eml(ln x, exp y) = x - y          # 9 + x + y
Using a subtraction-of-subtraction to get addition leads to the cost of "27" in Table 4; I'm not sure what formula leads to 19 but I'm guessing it avoids the expensive construction of 0 by using something simpler that cancels:

                   x - (0 - y) = x + y          # 25 + {x} + {y}
Post reply on HN