pub fn fold_codeword<F, EF>(codeword: &[F], beta: EF) -> Vec<EF>where
F: FoldAlphabet<EF>,
EF: TowerLevel,Expand description
Fold a whole codeword, halving its length.
Each block of symbols evaluates the domain once, then advances it by one exclusive-or per packed group.
Evaluating per symbol instead is the right shape for a single query.
Over a whole codeword it would recompute that value once per output symbol.
ยงPanics
Panics unless the codeword is empty or has a power-of-two length. That is the shape every round schedule produces.
The loops themselves cover any even length, so this is a deliberate narrowing of the contract rather than a limit of the method.