Struct arithmetic::rational::RationalInfinite[][src]

pub struct RationalInfinite(_, _);

A wrapper for any rational number with infinitely large numerator and denominator.

This type exists to facilitate cmp operation on values like a/b < c/d where a, b, c, d are all BigUint.

Implementations

impl RationalInfinite[src]

pub fn n(&self) -> &BigUint[src]

Return the numerator reference.

pub fn d(&self) -> &BigUint[src]

Return the denominator reference.

pub fn from(n: BigUint, d: BigUint) -> Self[src]

Build from a raw n/d.

pub fn zero() -> Self[src]

Zero.

pub fn one() -> Self[src]

One.

Trait Implementations

impl Clone for RationalInfinite[src]

impl Default for RationalInfinite[src]

impl Eq for RationalInfinite[src]

impl From<Rational128> for RationalInfinite[src]

impl Ord for RationalInfinite[src]

impl PartialEq<RationalInfinite> for RationalInfinite[src]

impl PartialOrd<RationalInfinite> for RationalInfinite[src]

impl StructuralEq for RationalInfinite[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> SaturatedConversion for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T, S> UniqueSaturatedInto<T> for S where
    T: Bounded,
    S: TryInto<T>, 
[src]