pub trait BooleanMultilinearPcs<EF, Challenger>: BooleanBackend<EF> {
// Required methods
fn observe_commitment(
&self,
commitment: &Self::Commitment,
challenger: &mut Challenger,
);
fn commit_bits<U: Underlier>(
&self,
bits: &[PackedGf2<U>],
challenger: &mut Challenger,
) -> Result<(Self::Commitment, Self::ProverData), Self::Error>;
fn open_readings(
&self,
prover_data: Self::ProverData,
openings: &[BitOpening<EF>],
challenger: &mut Challenger,
) -> Result<(Vec<BitReadings<EF>>, Self::Proof), Self::Error>;
fn verify_readings(
&self,
commitment: &Self::Commitment,
openings: &[BitOpening<EF>],
readings: &[BitReadings<EF>],
proof: &Self::Proof,
challenger: &mut Challenger,
) -> Result<(), Self::Error>;
fn readings_security(
&self,
num_claims: usize,
successor_tensors: bool,
) -> Option<PrescribedOpeningSecurity>;
fn open_at_points(
&self,
prover_data: Self::ProverData,
points: &[Point<EF>],
challenger: &mut Challenger,
) -> Result<(Vec<EF>, Self::Proof), Self::Error>;
fn verify_at_points(
&self,
commitment: &Self::Commitment,
points: &[Point<EF>],
values: &[EF],
proof: &Self::Proof,
challenger: &mut Challenger,
) -> Result<(), Self::Error>;
}Expand description
A commitment to a function from the hypercube to {0, 1}.
The committed object is a bit witness. An opening answers for its multilinear extension at a point of the challenge field.
§What a proving system pays on top
A batched prover lends its trace back as a borrowed table of base-field cells.
A bit witness has none to lend, so an integration holds the table and packs at commit time.
The base field then has to be one the challenge field extends.
The narrowest such level of the tower is GF(2^8).
This scheme also draws its challenges from the field its own elements live in.
So one cell per bit at the full challenge width is what the borrow costs today.
Constraints would also run wider if the base field packed bit-sliced.
The packing trait forbids it, casting a packed value to an array of scalars unchanged.
Bit-slicing is a compression, not a reinterpretation.
Required Methods§
Sourcefn observe_commitment(
&self,
commitment: &Self::Commitment,
challenger: &mut Challenger,
)
fn observe_commitment( &self, commitment: &Self::Commitment, challenger: &mut Challenger, )
Bind a commitment into the transcript, as committing to one does.
A prover binds while producing its commitment, and a verifier never produces one.
Routing both sides through this call is what keeps the two sponges in step.
Sourcefn commit_bits<U: Underlier>(
&self,
bits: &[PackedGf2<U>],
challenger: &mut Challenger,
) -> Result<(Self::Commitment, Self::ProverData), Self::Error>
fn commit_bits<U: Underlier>( &self, bits: &[PackedGf2<U>], challenger: &mut Challenger, ) -> Result<(Self::Commitment, Self::ProverData), Self::Error>
Commit to a bit witness supplied bit-sliced, lane j of block b being bit d*b + j.
§Errors
Returns an error unless the witness covers exactly the committed hypercube.
Sourcefn open_readings(
&self,
prover_data: Self::ProverData,
openings: &[BitOpening<EF>],
challenger: &mut Challenger,
) -> Result<(Vec<BitReadings<EF>>, Self::Proof), Self::Error>
fn open_readings( &self, prover_data: Self::ProverData, openings: &[BitOpening<EF>], challenger: &mut Challenger, ) -> Result<(Vec<BitReadings<EF>>, Self::Proof), Self::Error>
Open the bit witness with the readings every opening asks for, in one proof.
A reading is the witness at the point, or the witness one row further on.
§Errors
Returns an error on an opening this commitment refuses.
Sourcefn verify_readings(
&self,
commitment: &Self::Commitment,
openings: &[BitOpening<EF>],
readings: &[BitReadings<EF>],
proof: &Self::Proof,
challenger: &mut Challenger,
) -> Result<(), Self::Error>
fn verify_readings( &self, commitment: &Self::Commitment, openings: &[BitOpening<EF>], readings: &[BitReadings<EF>], proof: &Self::Proof, challenger: &mut Challenger, ) -> Result<(), Self::Error>
Check one proof against the readings it claims at every opening.
§Errors
Returns an error on a false reading, a failed reduction, or an unclosed claim.
Sourcefn readings_security(
&self,
num_claims: usize,
successor_tensors: bool,
) -> Option<PrescribedOpeningSecurity>
fn readings_security( &self, num_claims: usize, successor_tensors: bool, ) -> Option<PrescribedOpeningSecurity>
Every labelled algebraic error one opening of this many claims charges.
§Returns
Nothing when the commitment declines to price the schedule.
Sourcefn open_at_points(
&self,
prover_data: Self::ProverData,
points: &[Point<EF>],
challenger: &mut Challenger,
) -> Result<(Vec<EF>, Self::Proof), Self::Error>
fn open_at_points( &self, prover_data: Self::ProverData, points: &[Point<EF>], challenger: &mut Challenger, ) -> Result<(Vec<EF>, Self::Proof), Self::Error>
Sourcefn verify_at_points(
&self,
commitment: &Self::Commitment,
points: &[Point<EF>],
values: &[EF],
proof: &Self::Proof,
challenger: &mut Challenger,
) -> Result<(), Self::Error>
fn verify_at_points( &self, commitment: &Self::Commitment, points: &[Point<EF>], values: &[EF], proof: &Self::Proof, challenger: &mut Challenger, ) -> Result<(), Self::Error>
Check one proof against the values it claims at every point.
The commitment’s binding is the caller’s, replayed before this is reached.
§Errors
Returns an error if a claim, a reduction, the commitment or the fold fails.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".