pub trait ArithHelpers<F: One + Debug + Zero>where
    Self: Interpreter<F>,{
    // Required method
    fn two_pow(x: u64) -> Self::Variable;

    // Provided methods
    fn zero() -> Self::Variable { ... }
    fn one() -> Self::Variable { ... }
    fn two() -> Self::Variable { ... }
}
Expand description

This trait contains helper functions for arithmetic operations used in the Keccak circuit

Required Methods§

source

fn two_pow(x: u64) -> Self::Variable

Returns a variable representing the value 2^x

Provided Methods§

source

fn zero() -> Self::Variable

Returns a variable representing the value zero

source

fn one() -> Self::Variable

Returns a variable representing the value one

source

fn two() -> Self::Variable

Returns a variable representing the value two

Implementors§

source§

impl<F: Field> ArithHelpers<F> for o1vm::interpreters::keccak::constraints::Env<F>

source§

impl<F: Field> ArithHelpers<F> for o1vm::interpreters::keccak::witness::Env<F>