[−][src]Trait reed_solomon_erasure::Field
A finite field to perform encoding over.
Associated Types
Loading content...Associated Constants
Loading content...Required methods
fn add(a: Self::Elem, b: Self::Elem) -> Self::Elem
Add two elements together.
fn mul(a: Self::Elem, b: Self::Elem) -> Self::Elem
Multiply two elements together.
fn div(a: Self::Elem, b: Self::Elem) -> Self::Elem
Divide a by b. Panics is b is zero.
fn exp(a: Self::Elem, n: usize) -> Self::Elem
Raise a
to the n'th power.
fn zero() -> Self::Elem
The "zero" element or additive identity.
fn one() -> Self::Elem
The "one" element or multiplicative identity.
fn nth_internal(n: usize) -> Self::Elem
Provided methods
fn nth(n: usize) -> Self::Elem
Yield the nth element of the field. Panics if n >= ORDER.
Assignment is arbitrary but must be unique to n
.
fn mul_slice(elem: Self::Elem, input: &[Self::Elem], out: &mut [Self::Elem])
Multiply a slice of elements by another. Writes into the output slice.
Panics
Panics if the output slice does not have equal length to the input.
fn mul_slice_add(elem: Self::Elem, input: &[Self::Elem], out: &mut [Self::Elem])
Multiply a slice of elements by another, adding each result to the corresponding value in
out
.
Panics
Panics if the output slice does not have equal length to the input.