pub struct RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner> { /* private fields */ }
Expand description
A polynomial commitment scheme constructed as a reduction to an inner PCS over a field extension.
This implements the Construction 4.1 in DP24. The polynomial is committed by committing its corresponding packed polynomial with the inner PCS. Evaluation proofs consist of a sumcheck reduction followed by a PCS evaluation proof for the packed polynomial using the inner PCS.
§Type parameters
F
- the coefficient subfieldFDomain
- the field containing the sumcheck evaluation domainsPE
- a packed extension field ofF
that is cryptographically bigDomainFactory
- a domain factory for the sumcheck reductionInner
- the inner polynomial commitment scheme over the extension field
Implementations§
source§impl<F, FDomain, PE, DomainFactory, Inner> RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>where
F: Field,
PE: PackedField,
PE::Scalar: ExtensionField<F> + TowerField,
Inner: PolyCommitScheme<PE, PE::Scalar>,
impl<F, FDomain, PE, DomainFactory, Inner> RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>where
F: Field,
PE: PackedField,
PE::Scalar: ExtensionField<F> + TowerField,
Inner: PolyCommitScheme<PE, PE::Scalar>,
Trait Implementations§
source§impl<F: Debug, FDomain: Debug, PE: Debug, DomainFactory: Debug, Inner: Debug> Debug for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>
impl<F: Debug, FDomain: Debug, PE: Debug, DomainFactory: Debug, Inner: Debug> Debug for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>
source§impl<F, FDomain, FE, P, PE, DomainFactory, Inner> PolyCommitScheme<P, FE> for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>where
F: TowerField,
FDomain: Field,
FE: ExtensionField<F> + ExtensionField<FDomain> + PackedField<Scalar = FE> + PackedExtension<F> + TowerField,
P: PackedField<Scalar = F>,
PE: PackedFieldIndexable<Scalar = FE> + PackedExtension<F, PackedSubfield = P> + PackedExtension<FDomain>,
DomainFactory: EvaluationDomainFactory<FDomain>,
Inner: PolyCommitScheme<PE, FE>,
impl<F, FDomain, FE, P, PE, DomainFactory, Inner> PolyCommitScheme<P, FE> for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>where
F: TowerField,
FDomain: Field,
FE: ExtensionField<F> + ExtensionField<FDomain> + PackedField<Scalar = FE> + PackedExtension<F> + TowerField,
P: PackedField<Scalar = F>,
PE: PackedFieldIndexable<Scalar = FE> + PackedExtension<F, PackedSubfield = P> + PackedExtension<FDomain>,
DomainFactory: EvaluationDomainFactory<FDomain>,
Inner: PolyCommitScheme<PE, FE>,
type Commitment = <Inner as PolyCommitScheme<PE, FE>>::Commitment
type Committed = <Inner as PolyCommitScheme<PE, FE>>::Committed
type Proof = Proof<F, FE, <Inner as PolyCommitScheme<PE, FE>>::Proof>
type Error = Error
fn n_vars(&self) -> usize
source§fn commit<Data>(
&self,
polys: &[MultilinearExtension<P, Data>],
) -> Result<(Self::Commitment, Self::Committed), Self::Error>
fn commit<Data>( &self, polys: &[MultilinearExtension<P, Data>], ) -> Result<(Self::Commitment, Self::Committed), Self::Error>
Commit to a batch of polynomials
source§fn prove_evaluation<Data, Transcript, Backend>(
&self,
transcript: &mut Transcript,
committed: &Self::Committed,
polys: &[MultilinearExtension<P, Data>],
query: &[PE::Scalar],
backend: &Backend,
) -> Result<Self::Proof, Self::Error>where
Data: Deref<Target = [P]> + Send + Sync,
Transcript: CanObserve<PE::Scalar> + CanWrite + CanObserve<Self::Commitment> + CanSample<PE::Scalar> + CanSampleBits<usize>,
Backend: ComputationBackend,
fn prove_evaluation<Data, Transcript, Backend>(
&self,
transcript: &mut Transcript,
committed: &Self::Committed,
polys: &[MultilinearExtension<P, Data>],
query: &[PE::Scalar],
backend: &Backend,
) -> Result<Self::Proof, Self::Error>where
Data: Deref<Target = [P]> + Send + Sync,
Transcript: CanObserve<PE::Scalar> + CanWrite + CanObserve<Self::Commitment> + CanSample<PE::Scalar> + CanSampleBits<usize>,
Backend: ComputationBackend,
Generate an evaluation proof at a random challenge point.
source§fn verify_evaluation<Transcript, Backend>(
&self,
transcript: &mut Transcript,
commitment: &Self::Commitment,
query: &[FE],
proof: Self::Proof,
values: &[FE],
backend: &Backend,
) -> Result<(), Self::Error>where
Transcript: CanObserve<FE> + CanObserve<Self::Commitment> + CanSample<FE> + CanSampleBits<usize> + CanRead,
Backend: ComputationBackend,
fn verify_evaluation<Transcript, Backend>(
&self,
transcript: &mut Transcript,
commitment: &Self::Commitment,
query: &[FE],
proof: Self::Proof,
values: &[FE],
backend: &Backend,
) -> Result<(), Self::Error>where
Transcript: CanObserve<FE> + CanObserve<Self::Commitment> + CanSample<FE> + CanSampleBits<usize> + CanRead,
Backend: ComputationBackend,
Verify an evaluation proof at a random challenge point.
source§fn proof_size(&self, n_polys: usize) -> usize
fn proof_size(&self, n_polys: usize) -> usize
Return the byte-size of a proof.
Auto Trait Implementations§
impl<F, FDomain, PE, DomainFactory, Inner> Freeze for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>
impl<F, FDomain, PE, DomainFactory, Inner> RefUnwindSafe for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>where
Inner: RefUnwindSafe,
DomainFactory: RefUnwindSafe,
F: RefUnwindSafe,
FDomain: RefUnwindSafe,
PE: RefUnwindSafe,
impl<F, FDomain, PE, DomainFactory, Inner> Send for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>
impl<F, FDomain, PE, DomainFactory, Inner> Sync for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>
impl<F, FDomain, PE, DomainFactory, Inner> Unpin for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>
impl<F, FDomain, PE, DomainFactory, Inner> UnwindSafe for RingSwitchPCS<F, FDomain, PE, DomainFactory, Inner>where
Inner: UnwindSafe,
DomainFactory: UnwindSafe,
F: UnwindSafe,
FDomain: UnwindSafe,
PE: 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