Expand description
Basic modular arithmetic helpers.
Functionsยง
- mod_add
- Computes
(a + b) mod modulusand returns the normalized residue. - mod_mul
- Computes
(a * b) mod modulusand returns the normalized residue. - mod_
normalize - Normalizes
valueinto the residue class0..modulus. - mod_sub
- Computes
(a - b) mod modulusand returns the normalized residue.