Complex

Type Alias Complex 

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

Aliased Type§

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

Implementations§

Source§

impl<R: PrimeCharacteristicRing> Complex<R>

Convenience methods for complex extensions

Source

pub const fn new_complex(real: R, imag: R) -> Self

Source

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

Source

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

Source

pub fn real(&self) -> R

Source

pub fn imag(&self) -> R

Source

pub fn conjugate(&self) -> Self

Source

pub fn norm(&self) -> R

Source

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

Source

pub fn rotate<Ext: Algebra<R>>(&self, rhs: &Complex<Ext>) -> Complex<Ext>

Trait Implementations§

Source§

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

Source§

const W: Self

The constant coefficient W in the binomial X^D - W.
Source§

const DTH_ROOT: Self

A D-th root of unity derived from W. Read more
Source§

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

A generator for the extension field, expressed as a degree-D polynomial. Read more
Source§

impl<F, const D: usize> BinomiallyExtendableAlgebra<BinomialExtensionField<F, 2>, D> for Complex<F>

Source§

fn binomial_mul(a: &[Self; D], b: &[Self; D], res: &mut [Self; D], w: F)

Multiplication in the algebra extension ring A<X> / (X^D - W). Read more
Source§

fn binomial_add(a: &[Self; D], b: &[Self; D]) -> [Self; D]

Addition of elements in the algebra extension ring A<X> / (X^D - W). Read more
Source§

fn binomial_sub(a: &[Self; D], b: &[Self; D]) -> [Self; D]

Subtraction of elements in the algebra extension ring A<X> / (X^D - W). Read more
Source§

fn binomial_base_mul(lhs: [Self; D], rhs: Self) -> [Self; D]

Source§

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

Source§

const EXT_TWO_ADICITY: usize = F::COMPLEX_EXT_TWO_ADICITY

Two-adicity of the multiplicative group of the extension field. Read more
Source§

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

Returns a two-adic generator for the extension field. Read more