pub struct Polynomial {
pub selectors: Selectors,
pub witnesses: WiredWitnesses,
pub evaluation: bool,
}Expand description
PLONK polynomial expression representation with its selectors and witnesses.
Fields§
§selectors: SelectorsSelectors of the polynomial
witnesses: WiredWitnessesWired witnesses
evaluation: boolPolynomial evaluated to zero?
Implementations§
Source§impl Polynomial
impl Polynomial
Sourcepub const fn new(
selectors: Selectors,
witnesses: WiredWitnesses,
evaluation: bool,
) -> Self
pub const fn new( selectors: Selectors, witnesses: WiredWitnesses, evaluation: bool, ) -> Self
Create a new polynomial with evaluation to either correct or incorrect
Sourcepub const fn witnesses(&self) -> &WiredWitnesses
pub const fn witnesses(&self) -> &WiredWitnesses
Wired witnesses
Trait Implementations§
Source§impl Clone for Polynomial
impl Clone for Polynomial
Source§fn clone(&self) -> Polynomial
fn clone(&self) -> Polynomial
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Polynomial
impl Debug for Polynomial
Source§impl DecodableElement for Polynomial
impl DecodableElement for Polynomial
Source§fn try_from_buffer_in_place<'a, 'b>(
&'a mut self,
ctx: &DecoderContext<'a>,
buf: &'b [u8],
) -> Result<()>
fn try_from_buffer_in_place<'a, 'b>( &'a mut self, ctx: &DecoderContext<'a>, buf: &'b [u8], ) -> Result<()>
Deserialize the type from a given buffer Read more
Source§fn try_from_buffer<'b>(ctx: &DecoderContext<'_>, buf: &'b [u8]) -> Result<Self>
fn try_from_buffer<'b>(ctx: &DecoderContext<'_>, buf: &'b [u8]) -> Result<Self>
Create a new instance of the type from the provided buffer
Source§fn try_decode_in_place<'a, 'b>(
&mut self,
ctx: &DecoderContext<'a>,
buf: &'b [u8],
) -> Result<&'b [u8]>
fn try_decode_in_place<'a, 'b>( &mut self, ctx: &DecoderContext<'a>, buf: &'b [u8], ) -> Result<&'b [u8]>
Write an element from the buffer, and return the remainder bytes Read more
Source§fn try_decode<'a, 'b>(
ctx: &DecoderContext<'a>,
buf: &'b [u8],
) -> Result<(Self, &'b [u8])>
fn try_decode<'a, 'b>( ctx: &DecoderContext<'a>, buf: &'b [u8], ) -> Result<(Self, &'b [u8])>
Write an element from the buffer, and return the remainder bytes Read more
Source§fn try_from_reader<R>(ctx: &DecoderContext<'_>, reader: R) -> Result<Self>where
R: Read,
fn try_from_reader<R>(ctx: &DecoderContext<'_>, reader: R) -> Result<Self>where
R: Read,
Fetch a new element from a context
Source§impl Default for Polynomial
impl Default for Polynomial
Source§fn default() -> Polynomial
fn default() -> Polynomial
Returns the “default value” for a type. Read more
Source§impl Element for Polynomial
impl Element for Polynomial
Source§impl EncodableElement for Polynomial
impl EncodableElement for Polynomial
Source§fn to_buffer(&self, ctx: &mut EncoderContext, buf: &mut [u8])
fn to_buffer(&self, ctx: &mut EncoderContext, buf: &mut [u8])
Write the type into the buffer. Read more
Source§fn to_vec(&self, ctx: &mut EncoderContext) -> Vec<u8> ⓘ
fn to_vec(&self, ctx: &mut EncoderContext) -> Vec<u8> ⓘ
Serialize the object into a bytes array.
Source§impl Hash for Polynomial
impl Hash for Polynomial
Source§impl Ord for Polynomial
impl Ord for Polynomial
Source§fn cmp(&self, other: &Polynomial) -> Ordering
fn cmp(&self, other: &Polynomial) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for Polynomial
impl PartialEq for Polynomial
Source§impl PartialOrd for Polynomial
impl PartialOrd for Polynomial
impl Copy for Polynomial
impl Eq for Polynomial
impl StructuralPartialEq for Polynomial
Auto Trait Implementations§
impl Freeze for Polynomial
impl RefUnwindSafe for Polynomial
impl Send for Polynomial
impl Sync for Polynomial
impl Unpin for Polynomial
impl UnwindSafe for Polynomial
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more