Live data from Hacker News

All elementary functions from a single binary operator

arxiv.org

261–270 of 317 posts

Re: All elementary functions from a single binary operator

#261

Earlier quoted context omitted.

I’m fairly certain that the difference between the approaches is that the f(x,y) function you mentioned requires limits to represent certain concepts while the eml approach is essentially a tree or a chain of computations meant to represent a model of a system.

Computing exp or ln is an infinite series, and vastly more compute. Hiding series behind a name doesn’t make them free to compute.

I understand your point. The paper is more about the depth of the tree to represent and audit a model versus the raw CPU clock cycles. It takes the exponent and logarithm as given since for all practical purposes, in a scientific context, they are.

To represent something like sin(x) with f(x,y) requires infinite steps. Conversely, with eml you get an exact result in around 4 using identities and such.

One could argue that we do Taylor Series approximations on the hardware to represent trigonometric functions, but that highlights the key aspect of the eml approach. You can write a paper with those four steps that describes an exact model, here sin(x). And people can take that paper and optimize the result. This paper is about an auditable grammar that you can compute with.

Re: All elementary functions from a single binary operator

#262

Earlier quoted context omitted.

I’m fairly certain that the difference between the approaches is that the f(x,y) function you mentioned requires limits to represent certain concepts while the eml approach is essentially a tree or a chain of computations meant to represent a model of a system.

Computing exp or ln is an infinite series, and vastly more compute. Hiding series behind a name doesn’t make them free to compute.

They're not series, that's just a convenient way to think about defining and calculating them. I've never found it particularly useful to deal with the series definitions either, and none of the (good) approximation methods I'm aware of actually take that approach.

Moreover, EML is complete in a way that your suggested function isn't: If you take a finite combination of basis functions, can it build periodic functions? Hardy proved over a century ago that real (+,-,/,*,exp,ln) can't do this (and answering the paper's unresolved question about similar real-valued functions in the negative). EML being able to build periodic functions is a lot less surprising for obvious reasons, but still pretty neat.

Re: All elementary functions from a single binary operator

#263
post #11

Earlier quoted context omitted.

Dreadfully slow for integer math but probably some similar performance to something like a CORDIC for specific operations. If you can build an FPU that does exp() and ln() really fast, it's simple binary tree traversal to find the solution.

You already have an FPU that approximates exp() and ln() really fast, because float integer conversions approximate the power 2 functions respectively. Doing it accurately runs face-first into the tablemaker's dilemma, but you could do this with just 2 conversions, 2 FMAs (for power adjustments), and a subtraction per. A lot of cases would be even faster. Whether that's worth it will be situational.

Right, I meant to say fast and accurate. You could run into quite a lot of floating point error using this for everything.

Re: All elementary functions from a single binary operator

#264

Earlier quoted context omitted.

> This too is universal Could that be used to derive trigonometric functions with single distinct expressions?

The exp and ln are infinite series. Exp is roughly the infinite series for cos AND the infinite series for sin. Hiding that every op is an infinite series behind a name doesn’t make things free. It just makes even trivial ops like 1+2 vastly more work.

They are not infinite series per se. They can be represented by infinite series in several ways but there are standard ways to define them that do not involve infinite series. The logarithm in particular is not even represented by an infinite series (in form of Taylor expansion) defined in the whole complex plane. And knowledge/use of trigonometric functions greatly precedes such infinite series representations.

Moreover, the point is not always numerical computation. I don’t think anybody argues that eml sounds like an efficient way to compute elementary functions numerically. It may or may not still be useful for symbolic computations.

The article is about producing all elementary functions, which 1/(x-y) clearly doesn’t, as it doesn’t produce any transcendental function. Like many of such universality-style results it may not have practical applications, but may still be interesting on its own right.

Re: All elementary functions from a single binary operator

#265

Earlier quoted context omitted.

I don't think this can do any of the "standard" constants or what we generally consider to be closed-form expressions, though ! (E.g., no e, pi, exp, log, etc.)

Yes it can, by using the same infinite series that exp and ln use to compute. This one just costs less in money, hardware, energy, and is faster for basically every basic op.

I think the point is that it is _finite_. if you allow infinite expressions then the basic monomial basis or quotients thereof are “even simpler”

Re: All elementary functions from a single binary operator

#266

Earlier quoted context omitted.

I understand enough for it's arguments' symmetry to have an impact. Used Deep Research, it had the paper from the link as input plus some previous discussions about Tensor Logic and the new hardcoded neuroweb - like processors. Didn't make those up either.

I hope you get help. Mental health issues are not fun.

A quote from a blog post I just got out:

"I just want to get this out of my hands in case I made the model stumble upon something important. It's reasoning seems solid but I'm no expert. Here it is, go crazy:"

https://notes2self.bearblog.dev/the-weather-dominator/

Re: All elementary functions from a single binary operator

#268
Built a JS implementation today — monogate https://explorer-taupe-five.vercel.app · npm install monogate The interesting engineering problem was negation. The paper's SI gives one construction; we independently derived a two-regime approach — tower formula for y≤0, shift formula for y>0 — that stays stable to |y|<708 in IEEE 754. We also extended to ℂ. After seeing pveierland's result in this thread (i constructible from {1} in K=75 under extended-reals convention), we investigated and documented the distinction: under strict principal-branch ln where ln(0) throws, whether {1} alone generates i remains open. Under the extended-reals convention used in the paper, their construction holds. Two different grammars, not contradictory results. 109 tests. MIT. github.com/almaguer1986/monogate

Re: All elementary functions from a single binary operator

#269
post #212

I like this guy. https://th.if.uj.edu.pl/~odrzywolek/homepage/index.html

Oh my god the PC history is hilarious https://th.if.uj.edu.pl/~odrzywolek/homepage/personal/pc/pc_...

Not sure why this is "hilarious", but it's very nice. I almost wish I was keeping this history too, even though I never really even had a "PC" as this separate major thing, I just have a bunch of various devices that serve different purposes, and most my desk "PCs" are just laptops.

Re: All elementary functions from a single binary operator

#270

> 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.

https://en.wikipedia.org/wiki/Iota_and_Jot
Post reply on HN