Spire is a numeric and algebraic library for Scala, offering type-safe, generic, and high-precision arithmetic. It introduces abstractions like Rings, Fields, and Rationals and supports specialized number types (e.g. Rational, Complex, Interval), macros, and seamless integration with Cats for abstract numeric programming.

Features

  • Algebraic type classes: Semiring, Ring, Field, NRoot, etc.
  • Numeric types including Rational, Complex, Interval, polynomials
  • Specialization via macros for performance on JVM
  • Generic algorithms over types using implicits and typeclass constraints
  • Extra modules: spire-laws for testing, spire-extras for extended types
  • Ideal for precision-critical use cases (math, finance, scientific computing)

Project Samples

Project Activity

See All Activity >

Categories

Libraries

License

MIT License

Follow Spire

Spire Web Site

Other Useful Business Software
MongoDB Atlas runs apps anywhere Icon
MongoDB Atlas runs apps anywhere

Deploy in 115+ regions with the modern database for every enterprise.

MongoDB Atlas gives you the freedom to build and run modern applications anywhere—across AWS, Azure, and Google Cloud. With global availability in over 115 regions, Atlas lets you deploy close to your users, meet compliance needs, and scale with confidence across any geography.
Start Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Spire!

Additional Project Details

Programming Language

Scala

Related Categories

Scala Libraries

Registered

2025-08-04