#math #safe #pure #traits #numbers #rational #type

polymatheia

Mathematical types, traits, and algorithms in pure and safe Rust

8 releases (4 breaking)

0.4.3 Nov 10, 2023
0.4.2 Nov 10, 2023
0.3.0 Nov 6, 2023
0.2.0 Nov 6, 2023
0.0.0 Nov 2, 2023

#1542 in Algorithms

47 downloads per month

MIT/Apache

24KB
481 lines

Mathematical types, traits, and algorithms in pure and safe Rust.

The crate's name, polymatheia, means "much knowledge" in ancient greek.

The goals of this crate are, with decreasing priority:

  1. Having fun. This is a recreational project.
  2. Correctness. This implies that all items should be tested.
  3. Cleanliness. The code should be simple and elegant.
  4. Independence. The crate should only depend on the std library.

The crate currently implements:

  • Euclidean GCD algorithm
  • Fibonacci sequence generation
  • Rational numbers
  • Sieve of Eratosthenes prime generation and factorization

No runtime deps