Trait lcpc_2d::LcEncoding
source · [−]pub trait LcEncoding: Clone + Debug + Sync {
type F: Field + FieldHash + Debug + Clone;
type Err: Debug + Error + Send;
const LABEL_DT: &'static [u8];
const LABEL_PR: &'static [u8];
const LABEL_PE: &'static [u8];
const LABEL_CO: &'static [u8];
fn encode<T: AsMut<[Self::F]>>(&self, inp: T) -> Result<(), Self::Err>;
fn get_dims(&self, len: usize) -> (usize, usize, usize);
fn dims_ok(&self, n_per_row: usize, n_cols: usize) -> bool;
fn get_n_col_opens(&self) -> usize;
fn get_n_degree_tests(&self) -> usize;
}
Expand description
Trait for a linear encoding used by the polycommit
Associated Types
Associated Constants
const LABEL_DT: &'static [u8]
const LABEL_DT: &'static [u8]
Domain separation label - degree test (see def_labels!())
const LABEL_PR: &'static [u8]
const LABEL_PR: &'static [u8]
Domain separation label - random lin combs (see def_labels!())
const LABEL_PE: &'static [u8]
const LABEL_PE: &'static [u8]
Domain separation label - eval comb (see def_labels!())
const LABEL_CO: &'static [u8]
const LABEL_CO: &'static [u8]
Domain separation label - column openings (see def_labels!())
Required methods
Get dimensions for this encoding instance on an input vector of length len
Check that supplied dimensions are compatible with this encoding
fn get_n_col_opens(&self) -> usize
fn get_n_col_opens(&self) -> usize
Get the number of column openings required for this encoding
fn get_n_degree_tests(&self) -> usize
fn get_n_degree_tests(&self) -> usize
Get the number of degree tests required for this encoding