pub struct StarkDomain<B: StarkField> { /* private fields */ }Expand description
Info about domains related to specific instance of proof generation.
Implementations§
Source§impl<B: StarkField> StarkDomain<B>
impl<B: StarkField> StarkDomain<B>
Sourcepub fn new<A: Air<BaseField = B>>(air: &A) -> Self
pub fn new<A: Air<BaseField = B>>(air: &A) -> Self
Returns a new STARK domain initialized with the provided context.
Sourcepub fn from_twiddles(
trace_twiddles: Vec<B>,
blowup_factor: usize,
domain_offset: B,
) -> Self
pub fn from_twiddles( trace_twiddles: Vec<B>, blowup_factor: usize, domain_offset: B, ) -> Self
Returns a new STARK domain initialized with the provided custom inputs.
Sourcepub fn trace_length(&self) -> usize
pub fn trace_length(&self) -> usize
Returns length of the execution trace for this computation.
Sourcepub fn trace_twiddles(&self) -> &[B]
pub fn trace_twiddles(&self) -> &[B]
Returns twiddles which can be used to evaluate trace polynomials.
Sourcepub fn trace_to_ce_blowup(&self) -> usize
pub fn trace_to_ce_blowup(&self) -> usize
Returns blowup factor from trace to constraint evaluation domain.
Sourcepub fn trace_to_lde_blowup(&self) -> usize
pub fn trace_to_lde_blowup(&self) -> usize
Returns blowup factor from trace to LDE domain.
Sourcepub fn ce_domain_size(&self) -> usize
pub fn ce_domain_size(&self) -> usize
Returns the size of the constraint evaluation domain for this computation.
Sourcepub fn ce_domain_generator(&self) -> B
pub fn ce_domain_generator(&self) -> B
Returns the generator of constraint evaluation domain.
Sourcepub fn ce_to_lde_blowup(&self) -> usize
pub fn ce_to_lde_blowup(&self) -> usize
Returns blowup factor from constraint evaluation to LDE domain.
Sourcepub fn get_ce_x_at(&self, step: usize) -> B
pub fn get_ce_x_at(&self, step: usize) -> B
Returns s * g^step where g is the constraint evaluation domain generator and s is the domain offset.
Sourcepub fn get_ce_x_power_at(&self, step: usize, power: u64, offset_exp: B) -> B
pub fn get_ce_x_power_at(&self, step: usize, power: u64, offset_exp: B) -> B
Returns (s * g^step)^power where g is the constraint evaluation domain generator and s is the domain offset.
The computation is performed without doing exponentiations. offset_exp is assumed to be s^power which is pre-computed elsewhere.
Sourcepub fn lde_domain_size(&self) -> usize
pub fn lde_domain_size(&self) -> usize
Returns the size of the low-degree extension domain.