jf_pcs

Trait UnivariatePCS

Source
pub trait UnivariatePCS: PolynomialCommitmentScheme
where Self::Evaluation: FftField,
{ // Required methods fn multi_open_rou_proofs( prover_param: impl Borrow<<Self::SRS as StructuredReferenceString>::ProverParam>, polynomial: &Self::Polynomial, num_points: usize, domain: &Radix2EvaluationDomain<Self::Evaluation>, ) -> Result<Vec<Self::Proof>, PCSError>; fn multi_open_rou_evals( polynomial: &Self::Polynomial, num_points: usize, domain: &Radix2EvaluationDomain<Self::Evaluation>, ) -> Result<Vec<Self::Evaluation>, PCSError>; fn multi_point_open( prover_param: impl Borrow<<Self::SRS as StructuredReferenceString>::ProverParam>, polynomial: &Self::Polynomial, points: &[Self::Point], ) -> Result<(Self::Proof, Vec<Self::Evaluation>), PCSError>; fn multi_point_verify( verifier_param: impl Borrow<<Self::SRS as StructuredReferenceString>::VerifierParam>, commitment: &Self::Commitment, points: &[Self::Point], values: &[Self::Evaluation], proof: &Self::Proof, ) -> Result<bool, PCSError>; // Provided methods fn trim_fft_size( srs: impl Borrow<Self::SRS>, supported_degree: usize, ) -> Result<(<Self::SRS as StructuredReferenceString>::ProverParam, <Self::SRS as StructuredReferenceString>::VerifierParam), PCSError> { ... } fn multi_open_rou_eval_domain( degree: usize, num_points: usize, ) -> Result<Radix2EvaluationDomain<Self::Evaluation>, PCSError> { ... } fn multi_open_rou( prover_param: impl Borrow<<Self::SRS as StructuredReferenceString>::ProverParam>, polynomial: &Self::Polynomial, num_points: usize, domain: &Radix2EvaluationDomain<Self::Evaluation>, ) -> Result<(Vec<Self::Proof>, Vec<Self::Evaluation>), PCSError> { ... } }
Expand description

Super-trait specific for univariate polynomial commitment schemes.

Required Methods§

Source

fn multi_open_rou_proofs( prover_param: impl Borrow<<Self::SRS as StructuredReferenceString>::ProverParam>, polynomial: &Self::Polynomial, num_points: usize, domain: &Radix2EvaluationDomain<Self::Evaluation>, ) -> Result<Vec<Self::Proof>, PCSError>

Compute the opening proofs in Self::multi_open_rou().

Source

fn multi_open_rou_evals( polynomial: &Self::Polynomial, num_points: usize, domain: &Radix2EvaluationDomain<Self::Evaluation>, ) -> Result<Vec<Self::Evaluation>, PCSError>

Compute the evaluations in Self::multi_open_rou().

Source

fn multi_point_open( prover_param: impl Borrow<<Self::SRS as StructuredReferenceString>::ProverParam>, polynomial: &Self::Polynomial, points: &[Self::Point], ) -> Result<(Self::Proof, Vec<Self::Evaluation>), PCSError>

Input a polynomial, and multiple evaluation points, compute a single opening proof for the multiple points of the same polynomial.

Source

fn multi_point_verify( verifier_param: impl Borrow<<Self::SRS as StructuredReferenceString>::VerifierParam>, commitment: &Self::Commitment, points: &[Self::Point], values: &[Self::Evaluation], proof: &Self::Proof, ) -> Result<bool, PCSError>

Verifies that values are the evaluation at the points of the polynomial committed inside comm.

Provided Methods§

Source

fn trim_fft_size( srs: impl Borrow<Self::SRS>, supported_degree: usize, ) -> Result<(<Self::SRS as StructuredReferenceString>::ProverParam, <Self::SRS as StructuredReferenceString>::VerifierParam), PCSError>

Similar to PolynomialCommitmentScheme::trim(), but trim to support the FFT operations, such as Self::multi_open_rou() or other operations that involves roots of unity.

Source

fn multi_open_rou_eval_domain( degree: usize, num_points: usize, ) -> Result<Radix2EvaluationDomain<Self::Evaluation>, PCSError>

Given degree of the committed polynomial and num_points to open, return the evaluation domain for faster computation of opening proofs and evaluations (both using FFT).

Source

fn multi_open_rou( prover_param: impl Borrow<<Self::SRS as StructuredReferenceString>::ProverParam>, polynomial: &Self::Polynomial, num_points: usize, domain: &Radix2EvaluationDomain<Self::Evaluation>, ) -> Result<(Vec<Self::Proof>, Vec<Self::Evaluation>), PCSError>

Same task as PolynomialCommitmentScheme::multi_open(), except the points are roots of unity. The first num_points of roots will be evaluated (in canonical order).

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.

Implementors§

Source§

impl<E: Pairing> UnivariatePCS for UnivariateKzgPCS<E>