Hacker News new | ask | show | jobs
by khinsen 3503 days ago
You don't "run" Leibniz code. Leibniz is not a programming language. A Leibniz context is more like a database of equations than like a program.

You can use the database of equations (and rules) to "reduce" a term, which is also what computer algebra systems do. The difference is that in Leibniz, the database of equations of rules is always known and can be inspected, whereas in a computer algebra system it is carefully hidden from the user. Since it's this database where scientific knowledge is stored, this difference is quite important.

1 comments

What exactly is the difference between "running code" and "reducing a term"? Seems pretty much the same to me..
You can indeed consider a context plus a term to be reduced as a program, which is executed by term reduction. But the unit of code in Leibniz is the context, not the context + term-to-be-reduced. If you want to compare to programming languages, a context is more like a library.

The difference is in the focus rather than in the principles. Leibniz is a Turing-complete language, so you can use it for programming. But that's not what Leibniz is designed for. Term reduction is more a way of exploring the definitions in a context than a way to run code.