[][src]Struct dusk_plonk::commitment_scheme::kzg10::srs::PublicParameters

pub struct PublicParameters {
    pub commit_key: CommitKey,
    pub opening_key: OpeningKey,
}

The Public Parameters can also be referred to as the Structured Reference String (SRS). It is available to both the prover and verifier and allows the verifier to efficiently verify and make claims about polynomials up to and including a configured degree.

Fields

commit_key: CommitKey

Key used to generate proofs for composed circuits.

opening_key: OpeningKey

Key used to verify proofs for composed circuits.

Implementations

impl PublicParameters[src]

pub fn setup<R: RngCore>(
    max_degree: usize,
    rng: &mut R
) -> Result<PublicParameters, Error>
[src]

Setup generates the public parameters using a random number generator. This method will in most cases be used for testing and exploration. In reality, a Trusted party or a Multiparty Computation will used to generate the SRS. Returns an error if the configured degree is less than one.

pub fn trim(
    &self,
    truncated_degree: usize
) -> Result<(CommitKey, OpeningKey), Error>
[src]

Trim truncates the prover key to allow the prover to commit to polynomials up to the and including the truncated degree. Returns an error if the truncated degree is larger than the public parameters configured degree.

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

Max degree specifies the largest polynomial that this prover key can commit to.

Trait Implementations

impl Debug for PublicParameters[src]

Auto Trait Implementations

impl RefUnwindSafe for PublicParameters

impl Send for PublicParameters

impl Sync for PublicParameters

impl Unpin for PublicParameters

impl UnwindSafe for PublicParameters

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, 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>,