1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
//! # mathr
//!
//! A pure-Rust mathematics library and CLI that bundles symbolic and
//! numerical computation:
//!
//! - **Expression AST, parser and evaluator** ([`expr`], [`parser`], [`eval`])
//! with a standard library of elementary functions (`sin`, `cos`, `exp`,
//! `log`, ...) and constants (`pi`, `e`, ...).
//! - **FFT from scratch** ([`fft`]): Cooley–Tukey radix-2 (forward, inverse,
//! 2D, real-input) plus magnitude / power spectra, convolution,
//! cross-correlation, and window functions (Hann, Hamming, Blackman).
//! - **Numerical calculus** ([`calculus`]): high-order finite-difference
//! derivatives, trapezoidal and Simpson's integrators, adaptive quadrature,
//! partial derivatives and gradients.
//! - **Symbolic algebra** ([`symbolic`], [`simplify`]): differentiation by
//! the usual calculus rules, plus a simplifier that flattens identities and
//! folds constants. Expression equality via canonical form ([`expr`]).
//! - **Equation solving** ([`solver`]): bisection, Newton–Raphson (with
//! numeric-derivative fallback), secant, and Durand–Kerner for polynomial
//! roots.
//! - **Plotting** ([`plot`]): PNG output via [`plotters`], with single-,
//! multi- and scatter-plot variants.
//! - **Matrix operations** ([`matrix`]): arithmetic, determinant, inverse,
//! linear system solving, trace.
//! - **Statistics** ([`stats`]): mean, median, variance, stddev, quartiles,
//! correlation, linear regression.
//! - **Number theory** ([`numtheory`]): GCD, LCM, primality, factorization,
//! binomial coefficients, Fibonacci, sieve, Euler's totient, Miller–Rabin,
//! Chinese Remainder Theorem, modular exponentiation.
//! - **ODE solvers** ([`ode`]): Euler, RK4, RK4 systems, adaptive RKF45.
//! - **Taylor series** ([`taylor`]): symbolic Taylor expansion around a point.
//! - **Interpolation** ([`interpolate`]): Lagrange, Newton divided-difference,
//! linear interpolation.
//! - **Special functions** ([`special`]): Gamma, log-Gamma, Beta, erf, erfc,
//! sinc, incomplete gamma P.
//!
//! The CLI (`mathr "<expr or command>"`) is a thin wrapper around the same
//! library functions. It accepts plain math expressions, LaTeX/TeX input,
//! and command keywords like `diff`, `solve`, `int`, `gcd`, etc.
pub use ;
/// Re-exports of the most common types for downstream `use mathr::*;`.