Trait ExtendedDensePolynomial

Source
pub trait ExtendedDensePolynomial<F: Field> {
    // Required methods
    fn scale(&self, elm: F) -> Self;
    fn shiftr(&self, size: usize) -> Self;
    fn eval_polynomial(coeffs: &[F], x: F) -> F;
    fn to_chunked_polynomial(
        &self,
        num_chunks: usize,
        size: usize,
    ) -> ChunkedPolynomial<F>;
}
Expand description

An extension for the [DensePolynomial] type.

Required Methods§

Source

fn scale(&self, elm: F) -> Self

This function “scales” (multiplies all the coefficients of) a polynomial with a scalar.

Source

fn shiftr(&self, size: usize) -> Self

Shifts all the coefficients to the right.

Source

fn eval_polynomial(coeffs: &[F], x: F) -> F

eval_polynomial(coeffs, x) evaluates a polynomial given its coefficients coeffs and a point x.

Source

fn to_chunked_polynomial( &self, num_chunks: usize, size: usize, ) -> ChunkedPolynomial<F>

Convert a polynomial into chunks. Implementors must ensure that the result contains exactly num_chunks.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<F: Field> ExtendedDensePolynomial<F> for DensePolynomial<F>

Source§

fn scale(&self, elm: F) -> Self

Source§

fn shiftr(&self, size: usize) -> Self

Source§

fn eval_polynomial(coeffs: &[F], x: F) -> F

Source§

fn to_chunked_polynomial( &self, num_chunks: usize, chunk_size: usize, ) -> ChunkedPolynomial<F>

Implementors§