Module utils

Source

Functionsยง

absorb_radix_bits_for_config
cond_eval
Eval two expressions, return in the reversed order if cond == 1. Otherwise, return in the original order. This is a helper function for optimal performance.
const_fri_config
reduce_32
Reference: https://github.com/Plonky3/Plonky3/blob/622375885320ac6bf3c338001760ed8f2230e3cb/field/src/helpers.rs#L136
reduce_packed
In-circuit equivalent of [p3_field::reduce_packed].
reduce_packed_shifted
In-circuit equivalent of [p3_field::reduce_packed_shifted].
split_32
Reference: https://github.com/Plonky3/Plonky3/blob/622375885320ac6bf3c338001760ed8f2230e3cb/field/src/helpers.rs#L149
split_pf_to_field_order_limbs
In-circuit equivalent of [p3_field::split_pf_to_field_order_limbs]: decompose val (a Var in C::N) into n little-endian base-|F| Felt limbs. Constraints are emitted so that the witnessed limbs are exactly the canonical decomposition.