https://github.com/olewhalehunter/libra
a lazy interpreter of binary relational algebra
https://github.com/olewhalehunter/libra
Last synced: 2 days ago
JSON representation
a lazy interpreter of binary relational algebra
- Host: GitHub
- URL: https://github.com/olewhalehunter/libra
- Owner: olewhalehunter
- License: gpl-3.0
- Created: 2017-09-16T18:22:11.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-09-20T02:45:01.000Z (over 7 years ago)
- Last Synced: 2024-08-01T19:55:28.637Z (9 months ago)
- Language: Prolog
- Homepage:
- Size: 51.8 KB
- Stars: 2
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-programming-languages - Libra - Libra - Lazy Interpreter of Binary Relational Algebra (Uncategorized / Uncategorized)
README
# Libra - Lazy Interpreter of Binary Relational Algebra
* What is [Relational Programming](http://cs.adelaide.edu.au/~dwyer/TR95-10_TOC.html)?
* [William E. Byrd on Relational Programming with miniKanren](https://www.youtube.com/watch?v=8gh4Ald4yZQ)
* [Bruce MacLennan, 1983](https://calhoun.nps.edu/bitstream/handle/10945/29066/relationalprogra83012macl.pdf)"Ordinary programming languages calculate functions. Sometimes a function is inappropriate. For example, 4 has two square roots, +2 and -2, but an ordinary programming language provides a sqrt function that returns only one of the roots. So if we want to find both roots of a quadratic equation, we have to deal with each root separately. In a relational language, we need only to specify one solution, and the program will find both. This is because it will treat sqrt as a binary relation. A binary relation is similar in concept to a function, but can map an argument to any number of values (including zero).
Relations have many uses in computer science. The Z Specification Language makes heavy use of relational algebra notation. One reason is that programs are usually required to establish an input-output relationship, but there are often many outputs that are allowable. For example, a program may be asked to find any solution to a problem, or it may be asked to list all solutions, but in no particular order. A functional specification is bound to specify some particular solution or some particular order. A functional specification is usually an over-specification. "
ported to GNU Prolog from Barry Dwyer's Open Prolog (defunct) source