[][src]Struct snarkos_polycommit::data_structures::LabeledPolynomial

pub struct LabeledPolynomial<'a, F: Field> { /* fields omitted */ }

A polynomial along with information about its degree bound (if any), and the maximum number of queries that will be made to it. This latter number determines the amount of protection that will be provided to a commitment for this polynomial.

Implementations

impl<'a, F: Field> LabeledPolynomial<'a, F>[src]

pub fn new_owned(
    label: PolynomialLabel,
    polynomial: Polynomial<F>,
    degree_bound: Option<usize>,
    hiding_bound: Option<usize>
) -> Self
[src]

Construct a new labeled polynomial by consuming polynomial.

pub fn new(
    label: PolynomialLabel,
    polynomial: &'a Polynomial<F>,
    degree_bound: Option<usize>,
    hiding_bound: Option<usize>
) -> Self
[src]

Construct a new labeled polynomial.

pub fn label(&self) -> &String[src]

Return the label for self.

pub fn polynomial(&self) -> &Polynomial<F>[src]

Retrieve the polynomial from self.

pub fn evaluate(&self, point: F) -> F[src]

Evaluate the polynomial in self.

pub fn degree_bound(&self) -> Option<usize>[src]

Retrieve the degree bound in self.

pub fn is_hiding(&self) -> bool[src]

Retrieve whether the polynomial in self should be hidden.

pub fn hiding_bound(&self) -> Option<usize>[src]

Retrieve the hiding bound for the polynomial in self.

Methods from Deref<Target = Polynomial<F>>

pub fn is_zero(&self) -> bool[src]

Checks if the given polynomial is zero.

pub fn degree(&self) -> usize[src]

Returns the degree of the polynomial.

pub fn evaluate(&self, point: F) -> F[src]

Evaluates self at the given point in the field.

pub fn naive_mul(&self, other: &DensePolynomial<F>) -> DensePolynomial<F>[src]

Perform a naive n^2 multiplicatoin of self by other.

pub fn mul_by_vanishing_poly(
    &self,
    domain: EvaluationDomain<F>
) -> DensePolynomial<F>
[src]

Multiply self by the vanishing polynomial for the domain domain. Returns the quotient and remainder of the division.

pub fn divide_by_vanishing_poly(
    &self,
    domain: EvaluationDomain<F>
) -> Option<(DensePolynomial<F>, DensePolynomial<F>)>
[src]

Divide self by the vanishing polynomial for the domain domain. Returns the quotient and remainder of the division.

pub fn evaluate_over_domain_by_ref(
    &self,
    domain: EvaluationDomain<F>
) -> Evaluations<F>
[src]

Evaluate self over domain.

Trait Implementations

impl<'a, F: Field> CanonicalDeserialize for LabeledPolynomial<'a, F>[src]

impl<'a, F: Field> CanonicalSerialize for LabeledPolynomial<'a, F>[src]

impl<'a, F: Clone + Field> Clone for LabeledPolynomial<'a, F>[src]

impl<'a, F: Debug + Field> Debug for LabeledPolynomial<'a, F>[src]

impl<'a, F: Field> Deref for LabeledPolynomial<'a, F>[src]

type Target = Polynomial<F>

The resulting type after dereferencing.

Auto Trait Implementations

impl<'a, F> RefUnwindSafe for LabeledPolynomial<'a, F> where
    F: RefUnwindSafe

impl<'a, F> Send for LabeledPolynomial<'a, F>

impl<'a, F> Sync for LabeledPolynomial<'a, F>

impl<'a, F> Unpin for LabeledPolynomial<'a, F> where
    F: Unpin

impl<'a, F> UnwindSafe for LabeledPolynomial<'a, F> where
    F: RefUnwindSafe + UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

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