savage
savage copied to clipboard
A primitive computer algebra system
Non integer exponents appear not to work. For example, the following produces results as if the exponent was truncated. ``` in: 6^0.5 out[1]: 1 in: 6^(0.5) out[2]: 1 in: 6^(1.5)...
The current implementation can cause infinite loops and infinite recursion, for example with this input: ``` f(x) = x f(x) ``` The problem here is that the substituted expression is...
Look into [number-theory](https://crates.io/crates/number-theory) for faster primality and more number-theorectic functions (fastest in Rust as far as I know, the only short-coming is that it doesn't have sieving yet, although there...
We don't need mutation but we clone a lot, so this could improve performance and memory usage.
It would be nice if it could support symbolic differentiation, here is an implementation https://github.com/egraphs-good/egg/blob/main/tests/math.rs
Input: ``` Savage Computer Algebra System 0.2.0 Enter ? for help, press Ctrl+D to quit, Ctrl+C to cancel evaluation in: ? ``` Output: ``` Error: [ Simple { span: 0..1,...
Currently it's impossible to distinguish whether Savage is "thinking" or waiting for more input. This is an upstream issue, since the PR implementing rectangular prompts was reverted in RustyLine, see...
The welcome message promises that this will happen when you press `Ctrl+C`, but that isn't actually implemented yet. The plan is to spin off a subprocess that does the evaluation,...