Trait p25::coding::galois::GaloisField [] [src]

pub trait GaloisField {
    fn size() -> usize;
fn valid_codeword(bits: u8) -> bool;
fn codeword(pow: usize) -> u8;
fn power(codeword: usize) -> usize; fn codeword_modded(pow: usize) -> u8 { ... } }

A GF(2r) Galois field.

Required Methods

Number of unique codewords in the field: 2r - 1.

Check if the given bit pattern is a valid codeword in the field.

Map the given power i to codeword αi.

Map the given codeword ai to its power i.

Provided Methods

Map the given power i to codeword αm ≡ αi (modulo the size of the field.)

Implementors