Trait dimensioned::traits::Recip
[−]
[src]
pub trait Recip { type Output; fn recip(self) -> Self::Output; }
Recip
is used for implementing a recip()
member for types that are not preserved under
reciprocal.
Example
extern crate dimensioned as dim; use dim::si; fn main() { let t = 2.0 * si::S; let f = 0.5 * si::HZ; use dim::Recip; assert_eq!(t.recip(), f); }
Associated Types
type Output
The resulting type after taking the reciprocal
Required Methods
Implementors
impl<V, U> Recip for SI<V, U> where
V: Recip,
U: Neg,impl<V, U> Recip for UCUM<V, U> where
V: Recip,
U: Neg,impl<V, U> Recip for MKS<V, U> where
V: Recip,
U: Neg,impl<V, U> Recip for CGS<V, U> where
V: Recip,
U: Neg,impl<V, U> Recip for FPS<V, U> where
V: Recip,
U: Neg,impl Recip for f32
impl Recip for f64