Struct bellperson::groth16::aggregate::GenericSRS[][src]

pub struct GenericSRS<E: Engine> {
    pub g_alpha_powers: Vec<E::G1Affine>,
    pub h_alpha_powers: Vec<E::G2Affine>,
    pub g_beta_powers: Vec<E::G1Affine>,
    pub h_beta_powers: Vec<E::G2Affine>,
}
Expand description

It contains the maximum number of raw elements of the SRS needed to aggregate and verify Groth16 proofs. One can derive specialized prover and verifier key for specific size of aggregations by calling srs.specialize(n). The specialized prover key also contains precomputed tables that drastically increase prover’s performance. This GenericSRS is usually formed from the transcript of two distinct power of taus ceremony ,in other words from two distinct Groth16 CRS. See there a way on how to generate this GenesisSRS.

Fields

g_alpha_powers: Vec<E::G1Affine>

${g^a^i}_{i=0}^{N}$ where N is the smallest size of the two Groth16 CRS.

h_alpha_powers: Vec<E::G2Affine>

${h^a^i}_{i=0}^{N}$ where N is the smallest size of the two Groth16 CRS.

g_beta_powers: Vec<E::G1Affine>

${g^b^i}_{i=n}^{N}$ where N is the smallest size of the two Groth16 CRS.

h_beta_powers: Vec<E::G2Affine>

${h^b^i}_{i=0}^{N}$ where N is the smallest size of the two Groth16 CRS.

Implementations

specializes returns the prover and verifier SRS for a specific number of proofs to aggregate. The number of proofs MUST BE a power of two, it panics otherwise. The number of proofs must be inferior to half of the size of the generic srs otherwise it panics.

Returns the hash over all powers of this generic srs.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Should always be Self

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.