pub struct UnivariateUniversalParams<E: Pairing> {
    pub powers_of_g: Vec<E::G1Affine>,
    pub h: E::G2Affine,
    pub beta_h: E::G2Affine,
    pub powers_of_h: Vec<E::G2Affine>,
}Expand description
UniversalParams are the universal parameters for the KZG10 scheme.
Fields§
§powers_of_g: Vec<E::G1Affine>Group elements of the form { \beta^i G }, where i ranges from 0 to
degree.
h: E::G2AffineTODO: remove h and beta_h The generator of G2.
beta_h: E::G2Affine\beta times the above generator of G2.
powers_of_h: Vec<E::G2Affine>powers of \beta time the generator h of G2
Implementations§
Source§impl<E: Pairing> UnivariateUniversalParams<E>
 
impl<E: Pairing> UnivariateUniversalParams<E>
Sourcepub fn max_degree(&self) -> usize
 
pub fn max_degree(&self) -> usize
Returns the maximum supported degree
Trait Implementations§
Source§impl<E: Pairing> CanonicalDeserialize for UnivariateUniversalParams<E>
 
impl<E: Pairing> CanonicalDeserialize for UnivariateUniversalParams<E>
Source§fn deserialize_with_mode<R: Read>(
    reader: R,
    compress: Compress,
    validate: Validate,
) -> Result<Self, SerializationError>
 
fn deserialize_with_mode<R: Read>( reader: R, compress: Compress, validate: Validate, ) -> Result<Self, SerializationError>
fn deserialize_compressed<R>(reader: R) -> Result<Self, SerializationError>where
    R: Read,
fn deserialize_compressed_unchecked<R>(
    reader: R,
) -> Result<Self, SerializationError>where
    R: Read,
fn deserialize_uncompressed<R>(reader: R) -> Result<Self, SerializationError>where
    R: Read,
fn deserialize_uncompressed_unchecked<R>(
    reader: R,
) -> Result<Self, SerializationError>where
    R: Read,
Source§impl<E: Pairing> CanonicalSerialize for UnivariateUniversalParams<E>
 
impl<E: Pairing> CanonicalSerialize for UnivariateUniversalParams<E>
Source§fn serialize_with_mode<W: Write>(
    &self,
    writer: W,
    compress: Compress,
) -> Result<(), SerializationError>
 
fn serialize_with_mode<W: Write>( &self, writer: W, compress: Compress, ) -> Result<(), SerializationError>
fn serialized_size(&self, compress: Compress) -> usize
fn serialize_compressed<W>(&self, writer: W) -> Result<(), SerializationError>where
    W: Write,
fn compressed_size(&self) -> usize
fn serialize_uncompressed<W>(&self, writer: W) -> Result<(), SerializationError>where
    W: Write,
fn uncompressed_size(&self) -> usize
Source§impl<E: Clone + Pairing> Clone for UnivariateUniversalParams<E>
 
impl<E: Clone + Pairing> Clone for UnivariateUniversalParams<E>
Source§fn clone(&self) -> UnivariateUniversalParams<E>
 
fn clone(&self) -> UnivariateUniversalParams<E>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<E: Debug + Pairing> Debug for UnivariateUniversalParams<E>
 
impl<E: Debug + Pairing> Debug for UnivariateUniversalParams<E>
Source§impl<E: Default + Pairing> Default for UnivariateUniversalParams<E>
 
impl<E: Default + Pairing> Default for UnivariateUniversalParams<E>
Source§fn default() -> UnivariateUniversalParams<E>
 
fn default() -> UnivariateUniversalParams<E>
Source§impl<E: PartialEq + Pairing> PartialEq for UnivariateUniversalParams<E>
 
impl<E: PartialEq + Pairing> PartialEq for UnivariateUniversalParams<E>
Source§fn eq(&self, other: &UnivariateUniversalParams<E>) -> bool
 
fn eq(&self, other: &UnivariateUniversalParams<E>) -> bool
self and other values to be equal, and is used by ==.Source§impl<E: Pairing> StructuredReferenceString for UnivariateUniversalParams<E>
 
impl<E: Pairing> StructuredReferenceString for UnivariateUniversalParams<E>
Source§fn extract_prover_param(&self, supported_degree: usize) -> Self::ProverParam
 
fn extract_prover_param(&self, supported_degree: usize) -> Self::ProverParam
Extract the prover parameters from the public parameters.
Source§fn extract_verifier_param(&self, supported_degree: usize) -> Self::VerifierParam
 
fn extract_verifier_param(&self, supported_degree: usize) -> Self::VerifierParam
Extract the verifier parameters from the public parameters.
Source§fn trim_with_verifier_degree(
    &self,
    prover_supported_degree: usize,
    verifier_supported_degree: usize,
) -> Result<(Self::ProverParam, Self::VerifierParam), PCSError>
 
fn trim_with_verifier_degree( &self, prover_supported_degree: usize, verifier_supported_degree: usize, ) -> Result<(Self::ProverParam, Self::VerifierParam), PCSError>
Trim the universal parameters to specialize the public parameters
for univariate polynomials to the given supported_degree, and
returns committer key and verifier key. supported_degree should
be in range 1..params.len()
Source§fn trim(
    &self,
    supported_degree: usize,
) -> Result<(Self::ProverParam, Self::VerifierParam), PCSError>
 
fn trim( &self, supported_degree: usize, ) -> Result<(Self::ProverParam, Self::VerifierParam), PCSError>
Trim the universal parameters to specialize the public parameters
for univariate polynomials to the given supported_degree, and
returns committer key and verifier key. supported_degree should
be in range 1..params.len()
Source§type ProverParam = UnivariateProverParam<E>
 
type ProverParam = UnivariateProverParam<E>
Source§type VerifierParam = UnivariateVerifierParam<E>
 
type VerifierParam = UnivariateVerifierParam<E>
Source§fn load_srs_from_file(
    _supported_degree: usize,
    _file: Option<&str>,
) -> Result<Self, PCSError>
 
fn load_srs_from_file( _supported_degree: usize, _file: Option<&str>, ) -> Result<Self, PCSError>
pp bytes, and
the actual setup is usually carried out via MPC and should be
implemented else where. We only load them into memory here. Read moreSource§impl<E: Pairing> Valid for UnivariateUniversalParams<E>
 
impl<E: Pairing> Valid for UnivariateUniversalParams<E>
impl<E: Eq + Pairing> Eq for UnivariateUniversalParams<E>
impl<E: Pairing> StructuralPartialEq for UnivariateUniversalParams<E>
Auto Trait Implementations§
impl<E> Freeze for UnivariateUniversalParams<E>where
    <E as Pairing>::G2Affine: Freeze,
impl<E> RefUnwindSafe for UnivariateUniversalParams<E>where
    <E as Pairing>::G2Affine: RefUnwindSafe,
    <E as Pairing>::G1Affine: RefUnwindSafe,
impl<E> Send for UnivariateUniversalParams<E>
impl<E> Sync for UnivariateUniversalParams<E>
impl<E> Unpin for UnivariateUniversalParams<E>
impl<E> UnwindSafe for UnivariateUniversalParams<E>where
    <E as Pairing>::G2Affine: UnwindSafe,
    <E as Pairing>::G1Affine: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
    T: ?Sized,
 
impl<T> BorrowMut<T> for Twhere
    T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
 
fn borrow_mut(&mut self) -> &mut T
§impl<T> CanonicalSerializeHashExt for Twhere
    T: CanonicalSerialize,
 
impl<T> CanonicalSerializeHashExt for Twhere
    T: CanonicalSerialize,
Source§impl<T> CloneToUninit for Twhere
    T: Clone,
 
impl<T> CloneToUninit for Twhere
    T: Clone,
§impl<Q, K> Equivalent<K> for Q
 
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
 
fn equivalent(&self, key: &K) -> bool
Source§impl<T> IntoEither for T
 
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
 
fn into_either(self, into_left: bool) -> Either<Self, Self>
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
 
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
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