[][src]Struct zkp_stark::Constraints

pub struct Constraints {
    pub blowup: usize,
    pub pow_bits: usize,
    pub num_queries: usize,
    pub fri_layout: Vec<usize>,
    // some fields omitted

Constraints for Stark proofs

Contains the constraint expressions that apply to the trace table in addition to various tuning parameters that determine how proofs are computed. These can trade off between security, prover time, verifier time and proof size.

Note: This does not including the constraint system or anything about the claim to be proven.


blowup: usize

The blowup factor

The size of the low-degree-extension domain compared to the trace domain. Should be a power of two. Recommended values are 16, 32 or 64.

pow_bits: usize

Proof of work difficulty

The difficulty of the proof of work step in number of leading zero bits required.

num_queries: usize

Number of queries made to the oracles

fri_layout: Vec<usize>

Number of FRI reductions between steps

After the initial LDE polynomial is committed, several rounds of FRI degree reduction are done. Entries in the vector specify how many reductions are done between commitments.

After fri_layout.sum() reductions are done, the remaining polynomial is written explicitly in coefficient form.


impl Constraints[src]

pub fn from_expressions(
    (trace_nrows, trace_ncolumns): (usize, usize),
    channel_seed: Vec<u8>,
    expressions: Vec<RationalExpression>
) -> Result<Self, Error>

pub fn channel_seed(&self) -> &[u8][src]

pub fn trace_nrows(&self) -> usize[src]

pub fn trace_ncolumns(&self) -> usize[src]

pub fn len(&self) -> usize[src]

pub fn is_empty(&self) -> bool[src]

pub fn expressions(&self) -> &[RationalExpression][src]

pub fn degree(&self) -> usize[src]

pub fn security_bits(&self) -> usize[src]

pub fn max_proof_size(&self) -> usize[src]

Trait Implementations

impl Clone for Constraints[src]

impl Debug for Constraints[src]

Auto Trait Implementations

Blanket Implementations

impl<T> ToOwned for T where
    T: Clone

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T> From<T> for T[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized

impl<T> Borrow<T> for T where
    T: ?Sized

impl<T> Any for T where
    T: 'static + ?Sized

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,