Trait alga::general::Ring [] [src]

pub trait Ring: GroupAbelian<Additive> + Monoid<Multiplicative> {
    fn prop_mul_and_add_are_distributive(args: (Self, Self, Self)) -> bool where Self: ApproxEq { ... }
}

A ring is the combination of an abelian group and a multiplicative monoid structure.

A ring is equipped with:

  • An addition operator + that fulfills the constraints of an abelian group.
  • A multiplication operator × that fulfills the constraints of a monoid.

Provided Methods

Returns true if the multiplication and addition operators are distributive for the given argument tuple.

Implementors