Thanks to visit codestin.com
Credit goes to lib.rs

3 releases

0.1.1 Nov 23, 2025
0.1.0 Nov 23, 2025
0.1.0-beta.8 Feb 3, 2024
0.1.0-beta.7 Oct 12, 2023
0.1.0-beta.3 Sep 11, 2022

#339 in Math

Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App Codestin Search App

122 downloads per month
Used in fhe

MIT license

300KB
6.5K SLoC

fhe-math crate version documentation

Core mathematical primitives for the fhe.rs ecosystem.

This crate exposes building blocks such as number theoretic transforms (NTT), residue number system (RNS) arithmetic, and ring arithmetic over Z_q that are used by higher level crates like fhe.

Features

  • ntt, rns, rq, and zq modules for modular arithmetic over large rings.
  • Optional tfhe-ntt and tfhe-ntt-nightly features to enable hardware accelerated NTTs via the tfhe-ntt crate.

Installation

Add the following to your Cargo.toml:

[dependencies]
fhe-math = "0.1.1"

Testing

cargo test -p fhe-math

License

This project is licensed under the MIT license.

Security / Stability

The code in this crate has not undergone an independent security audit. Use at your own risk.

Dependencies

~9.5MB
~197K SLoC