pub struct ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>{ /* private fields */ }
Expand description
Small-field aware zerocheck prover.
This is a state machine satisfying the contract of ZerocheckProver trait. Object safety of the latter allows batching several zerocheck provers over different base fields together.
Full zerocheck reduction is laid out in the batch_verify_zerocheck. This struct implements the univariate round, witness folding and prover construction for multilinear rounds, and witness projection for the univariatizing reduction.
Implementations§
Source§impl<'a, F, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
F: TowerField,
FDomain: Field,
FBase: ExtensionField<FDomain>,
P: PackedField<Scalar = F> + PackedExtension<F, PackedSubfield = P> + PackedExtension<FBase> + PackedExtension<FDomain>,
CompositionBase: CompositionPoly<<P as PackedExtension<FBase>>::PackedSubfield>,
Composition: CompositionPoly<P> + 'a,
M: MultilinearPoly<P> + Send + Sync + 'a,
DomainFactory: EvaluationDomainFactory<FDomain>,
Backend: ComputationBackend,
impl<'a, F, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
F: TowerField,
FDomain: Field,
FBase: ExtensionField<FDomain>,
P: PackedField<Scalar = F> + PackedExtension<F, PackedSubfield = P> + PackedExtension<FBase> + PackedExtension<FDomain>,
CompositionBase: CompositionPoly<<P as PackedExtension<FBase>>::PackedSubfield>,
Composition: CompositionPoly<P> + 'a,
M: MultilinearPoly<P> + Send + Sync + 'a,
DomainFactory: EvaluationDomainFactory<FDomain>,
Backend: ComputationBackend,
pub fn new( multilinears: Vec<M>, zero_claims: impl IntoIterator<Item = (String, CompositionBase, Composition)>, zerocheck_challenges: &[F], domain_factory: DomainFactory, backend: &'a Backend, ) -> Result<Self, Error>
Trait Implementations§
Source§impl<'a, FDomain, FBase, P, CompositionBase: Debug, Composition: Debug, M: Debug, DomainFactory: Debug, Backend> Debug for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
FDomain: Field + Debug,
FBase: Field + Debug,
P: PackedExtension<FBase> + Debug,
Backend: ComputationBackend + Debug,
P::Scalar: Debug,
P::PackedSubfield: Debug,
impl<'a, FDomain, FBase, P, CompositionBase: Debug, Composition: Debug, M: Debug, DomainFactory: Debug, Backend> Debug for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
FDomain: Field + Debug,
FBase: Field + Debug,
P: PackedExtension<FBase> + Debug,
Backend: ComputationBackend + Debug,
P::Scalar: Debug,
P::PackedSubfield: Debug,
Source§impl<'a, F, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> ZerocheckProver<'a, P> for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
F: TowerField,
FDomain: TowerField,
FBase: ExtensionField<FDomain>,
P: PackedField<Scalar = F> + PackedExtension<F, PackedSubfield = P> + PackedExtension<FBase> + PackedExtension<FDomain>,
CompositionBase: CompositionPoly<PackedSubfield<P, FBase>> + 'static,
Composition: CompositionPoly<P> + 'static,
M: MultilinearPoly<P> + Send + Sync + 'a,
DomainFactory: EvaluationDomainFactory<FDomain>,
Backend: ComputationBackend,
impl<'a, F, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> ZerocheckProver<'a, P> for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
F: TowerField,
FDomain: TowerField,
FBase: ExtensionField<FDomain>,
P: PackedField<Scalar = F> + PackedExtension<F, PackedSubfield = P> + PackedExtension<FBase> + PackedExtension<FDomain>,
CompositionBase: CompositionPoly<PackedSubfield<P, FBase>> + 'static,
Composition: CompositionPoly<P> + 'static,
M: MultilinearPoly<P> + Send + Sync + 'a,
DomainFactory: EvaluationDomainFactory<FDomain>,
Backend: ComputationBackend,
Source§fn domain_size(&self, skip_rounds: usize) -> Option<usize>
fn domain_size(&self, skip_rounds: usize) -> Option<usize>
Maximal required Lagrange domain size among compositions in this prover. Read more
Source§fn execute_univariate_round(
&mut self,
skip_rounds: usize,
max_domain_size: usize,
batch_coeff: F,
) -> Result<ZerocheckRoundEvals<F>, Error>
fn execute_univariate_round( &mut self, skip_rounds: usize, max_domain_size: usize, batch_coeff: F, ) -> Result<ZerocheckRoundEvals<F>, Error>
Computes the prover message for the univariate round as a univariate polynomial. Read more
Source§fn fold_univariate_round(
&mut self,
challenge: F,
) -> Result<Box<dyn SumcheckProver<F> + 'a>, Error>
fn fold_univariate_round( &mut self, challenge: F, ) -> Result<Box<dyn SumcheckProver<F> + 'a>, Error>
Folds into a regular multilinear prover for the remaining rounds.
Auto Trait Implementations§
impl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> Freeze for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
<P as PackedField>::Scalar: Sized,
<<P as PackedField>::Scalar as WithUnderlier>::Underlier: Sized,
<FBase as WithUnderlier>::Underlier: Sized,
<FDomain as WithUnderlier>::Underlier: Sized,
DomainFactory: Freeze,
<Backend as ComputationBackend>::Vec<P>: Freeze,
impl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> RefUnwindSafe for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
<P as PackedField>::Scalar: Sized + RefUnwindSafe,
<<P as PackedField>::Scalar as WithUnderlier>::Underlier: Sized,
<FBase as WithUnderlier>::Underlier: Sized,
<FDomain as WithUnderlier>::Underlier: Sized,
DomainFactory: RefUnwindSafe,
Backend: RefUnwindSafe,
FBase: RefUnwindSafe,
FDomain: RefUnwindSafe,
<Backend as ComputationBackend>::Vec<P>: RefUnwindSafe,
M: RefUnwindSafe,
CompositionBase: RefUnwindSafe,
Composition: RefUnwindSafe,
P: RefUnwindSafe,
<P as PackedExtension<FBase>>::PackedSubfield: RefUnwindSafe,
impl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> Send for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
<P as PackedField>::Scalar: Sized,
<<P as PackedField>::Scalar as WithUnderlier>::Underlier: Sized,
<FBase as WithUnderlier>::Underlier: Sized,
<FDomain as WithUnderlier>::Underlier: Sized,
DomainFactory: Send,
M: Send,
CompositionBase: Send,
Composition: Send,
impl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> Sync for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
<P as PackedField>::Scalar: Sized,
<<P as PackedField>::Scalar as WithUnderlier>::Underlier: Sized,
<FBase as WithUnderlier>::Underlier: Sized,
<FDomain as WithUnderlier>::Underlier: Sized,
DomainFactory: Sync,
M: Sync,
CompositionBase: Sync,
Composition: Sync,
impl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> Unpin for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
<P as PackedField>::Scalar: Sized + Unpin,
<<P as PackedField>::Scalar as WithUnderlier>::Underlier: Sized,
<FBase as WithUnderlier>::Underlier: Sized,
<FDomain as WithUnderlier>::Underlier: Sized,
DomainFactory: Unpin,
FBase: Unpin,
FDomain: Unpin,
<Backend as ComputationBackend>::Vec<P>: Unpin,
M: Unpin,
CompositionBase: Unpin,
Composition: Unpin,
P: Unpin,
<P as PackedExtension<FBase>>::PackedSubfield: Unpin,
impl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend> UnwindSafe for ZerocheckProverImpl<'a, FDomain, FBase, P, CompositionBase, Composition, M, DomainFactory, Backend>where
<P as PackedField>::Scalar: Sized + UnwindSafe,
<<P as PackedField>::Scalar as WithUnderlier>::Underlier: Sized,
<FBase as WithUnderlier>::Underlier: Sized,
<FDomain as WithUnderlier>::Underlier: Sized,
DomainFactory: UnwindSafe,
Backend: RefUnwindSafe,
FBase: UnwindSafe,
FDomain: UnwindSafe,
<Backend as ComputationBackend>::Vec<P>: UnwindSafe,
M: UnwindSafe,
CompositionBase: UnwindSafe,
Composition: UnwindSafe,
P: UnwindSafe,
<P as PackedExtension<FBase>>::PackedSubfield: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more