Expand description
KZG polynomial commitment scheme (KZG10).
This module implements the KZG protocol described in the paper Constant-Size Commitments to Polynomials and Their Applications by Kate, Zaverucha and Goldberg, often referred to as the KZG10 paper.
The protocol requires a structured reference string (SRS) that contains powers of a generator of a group, and a pairing friendly curve.
The pairing friendly curve requirement is hidden in the Pairing trait parameter.
Re-exportsยง
use crate::commitment::combine_commitments;๐use crate::commitment::BatchEvaluationProof;๐use crate::commitment::BlindedCommitment;๐use crate::commitment::CommitmentCurve;๐use crate::commitment::Evaluation;๐use crate::commitment::PolyComm;๐use crate::error::CommitmentError;๐use crate::ipa::SRS;๐use crate::utils::combine_polys;๐use crate::PolynomialsToCombine;๐use crate::SRS as SRSTrait;๐use alloc::vec;๐use alloc::vec;๐use alloc::vec::Vec;๐use ark_ec::pairing::Pairing;๐use ark_ec::AffineRepr;๐use ark_ec::VariableBaseMSM;๐use ark_ff::One;๐use ark_ff::PrimeField;๐use ark_ff::Zero;๐use ark_poly::univariate::DenseOrSparsePolynomial;๐use ark_poly::univariate::DensePolynomial;๐use ark_poly::DenseUVPolynomial;๐use ark_poly::EvaluationDomain;๐use ark_poly::Evaluations;๐use ark_poly::Polynomial;๐use ark_poly::Radix2EvaluationDomain as D;๐use core::ops::Neg;๐use mina_poseidon::FqSponge;๐use rand::thread_rng;๐use rand_core::CryptoRng;๐use rand_core::RngCore;๐use serde::Deserialize;๐use serde::Deserialize;๐use serde::Serialize;๐use serde::Serialize;๐use serde_with::serde_as;๐use std::ops::Deref;๐
Structsยง
- KZGProof
- PairingSRS
- Define a structured reference string for the KZG protocol.
Functionsยง
- combine_
evaluations - Combine the (chunked) evaluations of multiple polynomials.
- divisor_
polynomial ๐ - The polynomial that evaluates to
0at the evaluation points. - eval_
polynomial ๐ - The polynomial that evaluates to each of
evalsfor the respectiveelms. For now, only works for 2 evaluations points.elmis the vector of evaluation points andevalsis the vector of evaluations at those points.