pub struct KoalaBearParameters;Trait Implementations§
Source§impl BinomialExtensionData<4> for KoalaBearParameters
impl BinomialExtensionData<4> for KoalaBearParameters
Source§const EXT_GENERATOR: [KoalaBear; 4]
const EXT_GENERATOR: [KoalaBear; 4]
const EXT_TWO_ADICITY: usize = 26usize
Source§const TWO_ADIC_EXTENSION_GENERATORS: Self::ArrayLike
const TWO_ADIC_EXTENSION_GENERATORS: Self::ArrayLike
Source§type ArrayLike = [[MontyField31<KoalaBearParameters>; 4]; 2]
type ArrayLike = [[MontyField31<KoalaBearParameters>; 4]; 2]
Source§impl BinomialExtensionData<8> for KoalaBearParameters
impl BinomialExtensionData<8> for KoalaBearParameters
Source§const EXT_GENERATOR: [KoalaBear; 8]
const EXT_GENERATOR: [KoalaBear; 8]
const EXT_TWO_ADICITY: usize = 27usize
Source§const TWO_ADIC_EXTENSION_GENERATORS: Self::ArrayLike
const TWO_ADIC_EXTENSION_GENERATORS: Self::ArrayLike
Source§type ArrayLike = [[MontyField31<KoalaBearParameters>; 8]; 3]
type ArrayLike = [[MontyField31<KoalaBearParameters>; 8]; 3]
Source§impl Clone for KoalaBearParameters
impl Clone for KoalaBearParameters
Source§fn clone(&self) -> KoalaBearParameters
fn clone(&self) -> KoalaBearParameters
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for KoalaBearParameters
impl Debug for KoalaBearParameters
Source§impl Default for KoalaBearParameters
impl Default for KoalaBearParameters
Source§fn default() -> KoalaBearParameters
fn default() -> KoalaBearParameters
Source§impl FieldParameters for KoalaBearParameters
impl FieldParameters for KoalaBearParameters
const MONTY_GEN: KoalaBear
const MONTY_ZERO: MontyField31<Self> = _
const MONTY_ONE: MontyField31<Self> = _
const MONTY_TWO: MontyField31<Self> = _
const MONTY_NEG_ONE: MontyField31<Self> = _
const HALF_P_PLUS_1: u32 = _
Source§impl Hash for KoalaBearParameters
impl Hash for KoalaBearParameters
Source§impl InternalLayerBaseParameters<KoalaBearParameters, 16> for KoalaBearInternalLayerParameters
impl InternalLayerBaseParameters<KoalaBearParameters, 16> for KoalaBearInternalLayerParameters
Source§fn internal_layer_mat_mul<R: PrimeCharacteristicRing>(
state: &mut [R; 16],
sum: R,
)
fn internal_layer_mat_mul<R: PrimeCharacteristicRing>( state: &mut [R; 16], sum: R, )
Perform the internal matrix multiplication: s -> (1 + Diag(V))s.
We ignore state[0] as it is handled separately.
Source§fn generic_internal_linear_layer<R>(state: &mut [R; WIDTH])where
R: PrimeCharacteristicRing,
fn generic_internal_linear_layer<R>(state: &mut [R; WIDTH])where
R: PrimeCharacteristicRing,
Source§impl InternalLayerBaseParameters<KoalaBearParameters, 24> for KoalaBearInternalLayerParameters
impl InternalLayerBaseParameters<KoalaBearParameters, 24> for KoalaBearInternalLayerParameters
Source§fn internal_layer_mat_mul<R: PrimeCharacteristicRing>(
state: &mut [R; 24],
sum: R,
)
fn internal_layer_mat_mul<R: PrimeCharacteristicRing>( state: &mut [R; 24], sum: R, )
Perform the internal matrix multiplication: s -> (1 + Diag(V))s.
We ignore state[0] as it is handled separately.
Source§fn generic_internal_linear_layer<R>(state: &mut [R; WIDTH])where
R: PrimeCharacteristicRing,
fn generic_internal_linear_layer<R>(state: &mut [R; WIDTH])where
R: PrimeCharacteristicRing,
Source§impl MontyParameters for KoalaBearParameters
impl MontyParameters for KoalaBearParameters
Source§const PRIME: u32 = 2_130_706_433u32
const PRIME: u32 = 2_130_706_433u32
The KoalaBear prime: 2^31 - 2^24 + 1 This is a 31-bit prime with the highest possible two adicity if we additionally demand that the cube map (x -> x^3) is an automorphism of the multiplicative group. It’s not unique, as there is one other option with equal 2 adicity: 2^30 + 2^27 + 2^24 + 1. There is also one 29-bit prime with higher two adicity which might be appropriate for some applications: 2^29 - 2^26 + 1.
const MONTY_BITS: u32 = 32u32
const MONTY_MU: u32 = 2_164_260_865u32
const MONTY_MASK: u32 = _
Source§impl PartialEq for KoalaBearParameters
impl PartialEq for KoalaBearParameters
Source§impl RelativelyPrimePower<3> for KoalaBearParameters
impl RelativelyPrimePower<3> for KoalaBearParameters
Source§fn exp_root_d<R: PrimeCharacteristicRing>(val: R) -> R
fn exp_root_d<R: PrimeCharacteristicRing>(val: R) -> R
In the field KoalaBear, a^{1/3} is equal to a^{1420470955}.
This follows from the calculation 3 * 1420470955 = 2*(2^31 - 2^24) + 1 = 1 mod (p - 1).
Source§impl TwoAdicData for KoalaBearParameters
impl TwoAdicData for KoalaBearParameters
Source§const TWO_ADICITY: usize = 24usize
const TWO_ADICITY: usize = 24usize
Source§const TWO_ADIC_GENERATORS: Self::ArrayLike
const TWO_ADIC_GENERATORS: Self::ArrayLike
Source§const INV_ROOTS_8: Self::ArrayLike
const INV_ROOTS_8: Self::ArrayLike
Source§const INV_ROOTS_16: Self::ArrayLike
const INV_ROOTS_16: Self::ArrayLike
Source§type ArrayLike = &'static [MontyField31<KoalaBearParameters>]
type ArrayLike = &'static [MontyField31<KoalaBearParameters>]
&'static [MontyField31].Source§const ODD_FACTOR: i32 = _
const ODD_FACTOR: i32 = _
impl Copy for KoalaBearParameters
impl Eq for KoalaBearParameters
impl InternalLayerParameters<KoalaBearParameters, 16> for KoalaBearInternalLayerParameters
impl InternalLayerParameters<KoalaBearParameters, 24> for KoalaBearInternalLayerParameters
impl PackedMontyParameters for KoalaBearParameters
impl StructuralPartialEq for KoalaBearParameters
Auto Trait Implementations§
impl Freeze for KoalaBearParameters
impl RefUnwindSafe for KoalaBearParameters
impl Send for KoalaBearParameters
impl Sync for KoalaBearParameters
impl Unpin for KoalaBearParameters
impl UnwindSafe for KoalaBearParameters
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more