libtom/libtommath
FreeLibTomMath is a free open source portable number theoretic multiple-precision integer library written entirely in C.
About libtom/libtommath
LibTomMath is a free, open-source, portable number theoretic multiple-precision integer (MPI) library written entirely in C. It provides a comprehensive set of functions for arbitrary-precision arithmetic, including addition, subtraction, multiplication, division, modular exponentiation, greatest common divisor (GCD), least common multiple (LCM), and number theory operations. The library is designed for easy integration into C projects and supports multiple build systems (CMake, makefiles). Documentation is built from LaTeX source. The project is hosted on GitHub under libtom/libtommath, with stable releases tagged on the develop branch. It is widely used in cryptography and other applications requiring high-precision integer math.
Key Features
Pros & Cons
- Free and open source (public domain or similar license)
- Written entirely in portable C, easy to integrate
- Comprehensive set of arithmetic and number theory operations
- Well-documented with LaTeX-generated manual
- Supports multiple build systems for cross-platform development
- Primarily C-based, no native C++ or other language binding
- May not be optimized for extremely large numbers compared to GMP
- Limited to integer arithmetic (no floating-point or complex numbers)