Skip to content

Calculus operations

Jimi Herken edited this page Jan 23, 2025 · 1 revision

RustCAS is able to compute derivatives and integrals.

Derivatives

Derivatives are implemented using the native diff function. It is used as follows:

$\frac{d}{dx}(f(x))$ is expressed as diff(f(x), x) where the first parameter, f(x), is the function of which the derivative should be computed while the second argument, x, signals the variable with respect to which the derivative should be computed. e.g.:

$\frac{d}{dx}(5x^3-7x^2+2)$ would be denoted as diff(5 * x^3 - 7 * x^2 + 2, x)

Clone this wiki locally