https://github.com/ilya-klyuchnikov/j-bob-rkt
https://github.com/ilya-klyuchnikov/j-bob-rkt
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/ilya-klyuchnikov/j-bob-rkt
- Owner: ilya-klyuchnikov
- Created: 2018-04-19T18:09:40.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-04-22T21:59:46.000Z (over 7 years ago)
- Last Synced: 2025-07-04T20:52:01.700Z (3 months ago)
- Language: Racket
- Size: 19.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# j-bob in Racket
The main entry point is `(J-Bob/define initial-defs defs`).
`initial-defs` are taken as axioms. Each def in the second list is checked. If checks are successful the `def-axioms` are extended with `defs`.If some wrapper is used for j-bob, then some axioms are taken first and then all other definitions are defined and checked.
So, j-bob is an engine that works based on supplied axioms.
## Modules
- `j-bob-lang` - the basic language j-bob is based upon. The language provided following minimalistic constructs:
- `(atom x)` - returns `'t` if `x` is an atom, `'nil` otherwise.
- `(car x)` - returns the first element of `x` if `x` is a pair, `'()` otherwise.
- `(cdr x)` - returns the second element of `x` if `x` is a pair, `'()` nil otherwise.
- `(equal x y)` - returns `'t` if `x` and `y` are equal, `'nil` otherwise.
- `(natp x)` - returns `'t ` if `x` is a non-negative number, `'nil` otherwise
- `(< x y)`
- `(+ x y)`
- `(cons a b)`
- `(defun name args body)`
- `(dethm name args body)`
- `(if Q A E)` - `'nil` is falsy, everything else is true
- `(size x)` - `0` for atoms, ...
- `j-bob` - the engine.
- `little-prover` - examples from the book.## Testing
The current implementation of `J-Bob/define` is total. If proofs do not pass
the checker, it returns the initial environment. So, the easiest and most robust
way to test is to check that the transformed environment contains all passed
definitions.Correspondingly, we also need to check that j-bob doesn't accept blindly all
proofs, - the easiest way to check is to mutate a proof and check that it is not
accepted.