1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
//! Randomness helpers for ACE layout building and DAG lowering.
//!
//! The ACE circuit expands (alpha, beta) into the full coefficient
//! vector `[alpha, 1, beta, beta^2, ...]` used by the constraint system.
use Field;
use crate::;
/// Derive alpha/beta input indices from a randomness region.
///
/// Returns `(alpha_idx, beta_idx)` matching the memory-word layout `[beta, alpha]`.
pub
/// Lower a challenge index into DAG nodes.
///
/// The AIR's `Challenges::from_randomness` receives these two raw values and
/// internally expands beta into powers `[1, beta, beta^2, ...]` via symbolic
/// multiplication. This means the DAG will contain nodes for `beta^k` built
/// from `AuxRandBeta`, which is correct.
pub