Expand description
Random sampling for lattice-based cryptography.
Provides discrete Gaussian sampling (for error terms) and uniform sampling (for key/mask generation).
Functions§
- sample_
binary - Sample a binary polynomial: coefficients in {0, 1}.
- sample_
gaussian - Sample a polynomial with coefficients from the discrete Gaussian distribution centered at 0 with standard deviation σ.
- sample_
ternary - Sample a ternary polynomial: coefficients in {-1, 0, 1}. Used for secret key generation.
- sample_
uniform - Sample a polynomial with coefficients uniformly random in [0, q).