pub struct Cost(/* private fields */);Expand description
Implementation of the Cost/Tropical semiring (N U Inf, min, +, inf, 0)
Implementations§
Trait Implementations§
Source§impl Multiplication<Cost> for Cost
Implementation of the multiplication trait for Cost semiring.
impl Multiplication<Cost> for Cost
Implementation of the multiplication trait for Cost semiring.
Source§impl One<U32WithInfinity> for Cost
Implementation of Identity for multiplication.
impl One<U32WithInfinity> for Cost
Implementation of Identity for multiplication.
Source§fn one(&self) -> U32WithInfinity
fn one(&self) -> U32WithInfinity
0 is the one element of the semiring.
Source§impl Zero<U32WithInfinity> for Cost
Implementation of Identity for addition.
impl Zero<U32WithInfinity> for Cost
Implementation of Identity for addition.
Source§fn zero(&self) -> U32WithInfinity
fn zero(&self) -> U32WithInfinity
Infinity is the identity element for addition operation.