Module commitment

Source

Structs§

Commitment
A commitment that represent a whole data TODO: for now, we consider 1 commitment = 1 contract = 1 data This type may be redundant with other types in Proof-systems

Functions§

combine_commitments
Takes commitments C_i, computes α = hash(C_0 || C_1 || … || C_n), returns ∑ α^i C_i.
commit_poly
Returns the non-hiding commitment to the provided polynomial
commit_sparse
Compute the commitment to the polynomial P of same degree as srs such that P(ω_i) = sparse_data[i] for all ì in indexes and P(ω_i) = 0 for any other ω_i of the domain of the same size as srs. This commitment is computed in a sparse way through the sum of sparse_data[i] × [L_i] for all i in indexes and [L_i] the commitment to the i-th Lagrange polynomial of same degree as srs.
commit_to_field_elems
Compute the commitment to data ; if the length of data is greater than SRS_SIZE, the data is splitted in chunks of at most SRS_SIZE length.