Complex

Type Alias Complex 

Source
pub type Complex<FA> = BinomialExtensionField<FA, 2>;

Aliased Type§

pub struct Complex<FA> { /* private fields */ }

Implementations§

Source§

impl<FA: FieldAlgebra> Complex<FA>

Convenience methods for complex extensions

Source

pub const fn new(real: FA, imag: FA) -> Self

Source

pub const fn new_real(real: FA) -> Self

Source

pub const fn new_imag(imag: FA) -> Self

Source

pub fn real(&self) -> FA

Source

pub fn imag(&self) -> FA

Source

pub fn conjugate(&self) -> Self

Source

pub fn norm(&self) -> FA

Source

pub fn to_array(&self) -> [FA; 2]

Source

pub fn rotate<Ext: FieldExtensionAlgebra<FA>>( &self, rhs: Complex<Ext>, ) -> Complex<Ext>

Trait Implementations§

Source§

impl<F, const D: usize> BinomiallyExtendable<D> for Complex<F>

Source§

const W: Self

Source§

const DTH_ROOT: Self

Source§

const EXT_GENERATOR: [Self; D] = F::EXT_GENERATOR

Source§

impl<F, const D: usize> HasTwoAdicBinomialExtension<D> for Complex<F>

Source§

const EXT_TWO_ADICITY: usize = F::COMPLEX_EXT_TWO_ADICITY

Source§

fn ext_two_adic_generator(bits: usize) -> [Self; D]

Assumes the multiplicative group size has at least bits powers of two, otherwise the behavior is undefined.