Struct kimchi_msm::witness::Witness
source · pub struct Witness<const N_WIT: usize, T> {
pub cols: Box<[T; N_WIT]>,
}
Expand description
The witness columns used by a gate of the MSM circuits.
It is generic over the number of columns, N_WIT
, and the type of the witness, T
.
It is parametrized by a type T
which can be either:
Vec<G::ScalarField>
for the evaluationsPolyComm<G>
for the commitments It can be used to represent the different subcircuits used by the project.
Fields§
§cols: Box<[T; N_WIT]>
A witness row is represented by an array of N witness columns When T is a vector, then the witness describes the rows of the circuit.
Implementations§
Trait Implementations§
source§impl<const N: usize, F: FftField> Foldable<F> for Witness<N, Evaluations<F, Radix2EvaluationDomain<F>>>
impl<const N: usize, F: FftField> Foldable<F> for Witness<N, Evaluations<F, Radix2EvaluationDomain<F>>>
source§impl<const N_WIT: usize, G: Send + Debug> FromParallelIterator<G> for Witness<N_WIT, G>
impl<const N_WIT: usize, G: Send + Debug> FromParallelIterator<G> for Witness<N_WIT, G>
source§fn from_par_iter<I>(par_iter: I) -> Selfwhere
I: IntoParallelIterator<Item = G>,
fn from_par_iter<I>(par_iter: I) -> Selfwhere I: IntoParallelIterator<Item = G>,
Creates an instance of the collection from the parallel iterator
par_iter
. Read moresource§impl<'lt, const N_WIT: usize, G> IntoIterator for &'lt Witness<N_WIT, G>
impl<'lt, const N_WIT: usize, G> IntoIterator for &'lt Witness<N_WIT, G>
source§impl<'data, const N_WIT: usize, G> IntoParallelIterator for &'data Witness<N_WIT, G>where
Vec<&'data G>: IntoParallelIterator,
impl<'data, const N_WIT: usize, G> IntoParallelIterator for &'data Witness<N_WIT, G>where Vec<&'data G>: IntoParallelIterator,
§type Iter = <Vec<&'data G, Global> as IntoParallelIterator>::Iter
type Iter = <Vec<&'data G, Global> as IntoParallelIterator>::Iter
The parallel iterator type that will be created.
§type Item = <Vec<&'data G, Global> as IntoParallelIterator>::Item
type Item = <Vec<&'data G, Global> as IntoParallelIterator>::Item
The type of item that the parallel iterator will produce.
source§fn into_par_iter(self) -> Self::Iter
fn into_par_iter(self) -> Self::Iter
Converts
self
into a parallel iterator. Read moresource§impl<'data, const N_WIT: usize, G> IntoParallelIterator for &'data mut Witness<N_WIT, G>where
Vec<&'data mut G>: IntoParallelIterator,
impl<'data, const N_WIT: usize, G> IntoParallelIterator for &'data mut Witness<N_WIT, G>where Vec<&'data mut G>: IntoParallelIterator,
§type Iter = <Vec<&'data mut G, Global> as IntoParallelIterator>::Iter
type Iter = <Vec<&'data mut G, Global> as IntoParallelIterator>::Iter
The parallel iterator type that will be created.
§type Item = <Vec<&'data mut G, Global> as IntoParallelIterator>::Item
type Item = <Vec<&'data mut G, Global> as IntoParallelIterator>::Item
The type of item that the parallel iterator will produce.
source§fn into_par_iter(self) -> Self::Iter
fn into_par_iter(self) -> Self::Iter
Converts
self
into a parallel iterator. Read moresource§impl<const N_WIT: usize, G> IntoParallelIterator for Witness<N_WIT, G>where
Vec<G>: IntoParallelIterator,
impl<const N_WIT: usize, G> IntoParallelIterator for Witness<N_WIT, G>where Vec<G>: IntoParallelIterator,
source§impl<const N_WIT: usize, T: PartialEq> PartialEq<Witness<N_WIT, T>> for Witness<N_WIT, T>
impl<const N_WIT: usize, T: PartialEq> PartialEq<Witness<N_WIT, T>> for Witness<N_WIT, T>
impl<const N_WIT: usize, T: Eq> Eq for Witness<N_WIT, T>
impl<const N_WIT: usize, T> StructuralEq for Witness<N_WIT, T>
impl<const N_WIT: usize, T> StructuralPartialEq for Witness<N_WIT, T>
impl<const N: usize, G: CommitmentCurve> Witness<G> for Witness<N, Evaluations<G::ScalarField, Radix2EvaluationDomain<G::ScalarField>>>
Auto Trait Implementations§
impl<const N_WIT: usize, T> RefUnwindSafe for Witness<N_WIT, T>where T: RefUnwindSafe,
impl<const N_WIT: usize, T> Send for Witness<N_WIT, T>where T: Send,
impl<const N_WIT: usize, T> Sync for Witness<N_WIT, T>where T: Sync,
impl<const N_WIT: usize, T> Unpin for Witness<N_WIT, T>
impl<const N_WIT: usize, T> UnwindSafe for Witness<N_WIT, T>where T: 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<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<'data, I> IntoParallelRefIterator<'data> for Iwhere
I: 'data + ?Sized,
&'data I: IntoParallelIterator,
impl<'data, I> IntoParallelRefIterator<'data> for Iwhere I: 'data + ?Sized, &'data I: IntoParallelIterator,
§impl<'data, I> IntoParallelRefMutIterator<'data> for Iwhere
I: 'data + ?Sized,
&'data mut I: IntoParallelIterator,
impl<'data, I> IntoParallelRefMutIterator<'data> for Iwhere I: 'data + ?Sized, &'data mut I: IntoParallelIterator,
§type Iter = <&'data mut I as IntoParallelIterator>::Iter
type Iter = <&'data mut I as IntoParallelIterator>::Iter
The type of iterator that will be created.
§type Item = <&'data mut I as IntoParallelIterator>::Item
type Item = <&'data mut I as IntoParallelIterator>::Item
The type of item that will be produced; this is typically an
&'data mut T
reference.§fn par_iter_mut(
&'data mut self
) -> <I as IntoParallelRefMutIterator<'data>>::Iter
fn par_iter_mut( &'data mut self ) -> <I as IntoParallelRefMutIterator<'data>>::Iter
Creates the parallel iterator from
self
. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<G, W> RelaxableWitness<G, W> for Wwhere
G: CommitmentCurve,
W: Witness<G>,
impl<G, W> RelaxableWitness<G, W> for Wwhere G: CommitmentCurve, W: Witness<G>,
§fn relax(
self,
zero_poly: &Evaluations<<G as AffineRepr>::ScalarField, Radix2EvaluationDomain<<G as AffineRepr>::ScalarField>>
) -> RelaxedWitness<G, W>
fn relax( self, zero_poly: &Evaluations<<G as AffineRepr>::ScalarField, Radix2EvaluationDomain<<G as AffineRepr>::ScalarField>> ) -> RelaxedWitness<G, W>
This method takes a witness and a vector of evaluations to the zero polynomial, returning a relaxed witness which is composed by the extended witness and the error vector that is set to the zero polynomial.