Skip to main content

IncomingInstance

Struct IncomingInstance 

Source
pub struct IncomingInstance<CM: CommitmentDef> {
    pub cm_w: CM::Commitment,
    pub x: Vec<CM::Scalar>,
}
Expand description

IncomingInstance defines Nova’s incoming instance.

Fields§

§cm_w: CM::Commitment

IncomingInstance::cm_w is the witness commitment.

§x: Vec<CM::Scalar>

IncomingInstance::x is the vector of public inputs (to the circuit).

Trait Implementations§

Source§

impl<CM: CommitmentDef> Absorbable for IncomingInstance<CM>

Source§

fn absorb_into<F: PrimeField>(&self, dest: &mut Vec<F>)

Absorbable::absorb_into absorbs self into the given destination vector of field elements. Read more
Source§

impl<CM: CommitmentDefGadget> AllocVar<IncomingInstance<<CM as CommitmentDefGadget>::Widget>, <CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>

Source§

fn new_variable<T: Borrow<IncomingInstance<CM::Widget>>>( cs: impl Into<Namespace<CM::ConstraintField>>, f: impl FnOnce() -> Result<T, SynthesisError>, mode: AllocationMode, ) -> Result<Self, SynthesisError>

Allocates a new variable of type Self in the ConstraintSystem cs. The mode of allocation is decided by mode.
Source§

fn new_constant( cs: impl Into<Namespace<F>>, t: impl Borrow<V>, ) -> Result<Self, SynthesisError>

Allocates a new constant of type Self in the ConstraintSystem cs. Read more
Source§

fn new_input<T>( cs: impl Into<Namespace<F>>, f: impl FnOnce() -> Result<T, SynthesisError>, ) -> Result<Self, SynthesisError>
where T: Borrow<V>,

Allocates a new public input of type Self in the ConstraintSystem cs.
Source§

fn new_witness<T>( cs: impl Into<Namespace<F>>, f: impl FnOnce() -> Result<T, SynthesisError>, ) -> Result<Self, SynthesisError>
where T: Borrow<V>,

Allocates a new private witness of type Self in the ConstraintSystem cs.
Source§

fn new_variable_with_inferred_mode<T>( cs: impl Into<Namespace<F>>, f: impl FnOnce() -> Result<T, SynthesisError>, ) -> Result<Self, SynthesisError>
where T: Borrow<V>,

Allocates a new constant or private witness of type Self in the ConstraintSystem cs with the allocation mode inferred from cs. A constant is allocated if cs is None, and a private witness is allocated otherwise. Read more
Source§

impl<CM: Clone + CommitmentDef> Clone for IncomingInstance<CM>
where CM::Commitment: Clone, CM::Scalar: Clone,

Source§

fn clone(&self) -> IncomingInstance<CM>

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<CM: Debug + CommitmentDef> Debug for IncomingInstance<CM>
where CM::Commitment: Debug, CM::Scalar: Debug,

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<CM: CommitmentDef> Dummy<&ArithConfig> for IncomingInstance<CM>

Source§

fn dummy(cfg: &ArithConfig) -> Self

Dummy::dummy constructs a dummy value of Self based on the given configuration cfg.
Source§

impl<CM: Eq + CommitmentDef> Eq for IncomingInstance<CM>
where CM::Commitment: Eq, CM::Scalar: Eq,

Source§

impl<CM: CommitmentDef> FoldingInstance<CM> for IncomingInstance<CM>

Source§

const N_COMMITMENTS: usize = 1

FoldingInstance::N_COMMITMENTS defines the number of commitments contained in the instance.
Source§

fn commitments(&self) -> Vec<&CM::Commitment>

FoldingInstance::commitments returns the commitments contained in the instance.
Source§

fn public_inputs(&self) -> &[CM::Scalar]

FoldingInstance::public_inputs returns the reference to the public inputs contained in the instance.
Source§

fn public_inputs_mut(&mut self) -> &mut [CM::Scalar]

FoldingInstance::public_inputs_mut returns the mutable reference to the public inputs contained in the instance.
Source§

impl<CM: PartialEq + CommitmentDef> PartialEq for IncomingInstance<CM>

Source§

fn eq(&self, other: &IncomingInstance<CM>) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl<A, CM> Relation<IncomingWitness<CM>, IncomingInstance<CM>> for NovaKey<A, CM>
where A: ArithRelation<Vec<CM::Scalar>, Vec<CM::Scalar>>, CM: CommitmentOps,

Source§

type Error = Error

Relation::Error defines the error type that may occur when checking the relation.
Source§

fn check_relation(&self, w: &IW<CM>, u: &IU<CM>) -> Result<(), Self::Error>

Relation::check_relation returns Ok(()) when w and u satisfy self, or an error otherwise.
Source§

impl<CM: PartialEq + CommitmentDef> StructuralPartialEq for IncomingInstance<CM>

Source§

impl<A: Arith, CM: CommitmentOps> WitnessInstanceSampler<IncomingWitness<CM>, IncomingInstance<CM>> for NovaKey<A, CM>

Source§

type Source = Assignments<<CM as CommitmentDef>::Scalar, Vec<<CM as CommitmentDef>::Scalar>>

WitnessInstanceSampler::Source defines the type of the source from which a satisfying pair is sampled.
Source§

type Error = Error

WitnessInstanceSampler::Error defines the error type that may occur when sampling a satisfying pair.
Source§

fn sample( &self, z: Self::Source, rng: impl RngCore, ) -> Result<(IW<CM>, IU<CM>), Error>

WitnessInstanceSampler::sample draws a random satisfying pair.

Auto Trait Implementations§

Blanket Implementations§

Source§

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

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

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

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

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

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

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

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

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

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

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

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

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

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more