Struct acap::cos::AngularDistance [−][src]
pub struct AngularDistance<T>(_);
Expand description
An angular distance.
This type stores the cosine of the angle, to avoid computing the expensive trancendental
acos()
function until absolutely necessary.
let zero = AngularDistance::from_cos(1.0);
let pi_2 = AngularDistance::from_cos(0.0);
let pi = AngularDistance::from_cos(-1.0);
assert!(zero < pi_2 && pi_2 < pi);
Implementations
Trait Implementations
Performs the conversion.
Performs the conversion.
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
Auto Trait Implementations
impl<T> RefUnwindSafe for AngularDistance<T> where
T: RefUnwindSafe,
impl<T> Send for AngularDistance<T> where
T: Send,
impl<T> Sync for AngularDistance<T> where
T: Sync,
impl<T> Unpin for AngularDistance<T> where
T: Unpin,
impl<T> UnwindSafe for AngularDistance<T> where
T: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more