Trait cryptix_field::field::Field
source · pub trait Field: Ring + CommunicativeMul + MulIdentity + MulInverse {
// Required methods
fn hlv(self) -> Self;
fn is_zero(&self) -> bool;
}Expand description
This is a trait for field, a field is constructed from
- A Abelian Group over add
- A ring over multiplication and addition
- Multiplication should be communicative
- There must exists multiplicative inverse
- There must exists multiplicative identity (and different from additive identity)
TODO: find a way to constraint a field has different multiplicative identity and addition identity via type system.