Function poseidon_paramgen::v2::generate

source ·
pub fn generate<F: PrimeField>(
    M: usize,
    t: usize,
    p: F::BigInt,
    allow_inverse: bool
) -> PoseidonParameters<F>
Expand description

Generate a Poseidon2 instance mapped over Fp given a choice of:

  • M, the desired security level (in bits),
  • t, the width of the desired hash function, e.g. $t=3$ corresponds to 2-to-1 hash.
  • p, the prime modulus,
  • allow_inverse, whether or not to allow an inverse alpha.