pub struct SparseMultiDenseProductSumcheckProver<P: PackedField> { /* private fields */ }Expand description
Proves the hypercube sums of one sparse multilinear against several dense ones.
The sparse multilinear is shared, so it is stored once and folded once. That holds however many dense columns ride along.
One prover per column would instead hold a copy of the entry list each. Every copy would then fold each round. Avoiding that is the whole reason this exists.
One round polynomial comes out per column. The batching driver combines a prover’s polynomials exactly as it would separate provers’.
The claim each column carries is its own. So the columns are independent sums that happen to share a factor.
Everything else follows the single-column prover in this module. A test pins the two together at one column.
Implementations§
Source§impl<P: PackedField> SparseMultiDenseProductSumcheckProver<P>
impl<P: PackedField> SparseMultiDenseProductSumcheckProver<P>
Sourcepub fn new(
sparse: Vec<SparseEntry<P::Scalar>>,
dense: Vec<FactoredMultilinear<P>>,
sums: &[P::Scalar],
) -> Self
pub fn new( sparse: Vec<SparseEntry<P::Scalar>>, dense: Vec<FactoredMultilinear<P>>, sums: &[P::Scalar], ) -> Self
Creates a prover for the claim that each sparse-dense product sums to its stated value.
§Arguments
sparse- entries of the shared sparse multilinear, in any order, indices repeatable.dense- one dense multilinear per claim, all over the same variables.sums- the claimed sum of each product over the hypercube.
§Panics
Panics if the columns disagree on their variable count.
Panics if there is not one sum per column, or if any entry index is out of range.
Trait Implementations§
Source§impl<F: Field, P: PackedField<Scalar = F>> SumcheckProver<F> for SparseMultiDenseProductSumcheckProver<P>
impl<F: Field, P: PackedField<Scalar = F>> SumcheckProver<F> for SparseMultiDenseProductSumcheckProver<P>
Source§fn n_vars(&self) -> usize
fn n_vars(&self) -> usize
Source§fn execute(&mut self) -> Vec<RoundCoeffs<F>>
fn execute(&mut self) -> Vec<RoundCoeffs<F>>
Auto Trait Implementations§
impl<P> Freeze for SparseMultiDenseProductSumcheckProver<P>
impl<P> RefUnwindSafe for SparseMultiDenseProductSumcheckProver<P>
impl<P> Send for SparseMultiDenseProductSumcheckProver<P>
impl<P> Sync for SparseMultiDenseProductSumcheckProver<P>
impl<P> Unpin for SparseMultiDenseProductSumcheckProver<P>
impl<P> UnsafeUnpin for SparseMultiDenseProductSumcheckProver<P>
impl<P> UnwindSafe for SparseMultiDenseProductSumcheckProver<P>
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
§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> ⓘ
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> ⓘ
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