[−][src]Struct twofloat::TwoFloat
Represents a two-word floating point type, represented as the sum of two non-overlapping f64 values.
Methods
impl TwoFloat
[src]
pub fn new_add(x: f64, y: f64) -> TwoFloat
[src]
Creates a new TwoFloat
by adding two f64
values using Algorithm 2
from Joldes et al. (2017).
pub fn new_sub(x: f64, y: f64) -> TwoFloat
[src]
Creates a new TwoFloat
by subtracting two f64
values using
Algorithm 2 from Joldes et al. (2017) modified for negative right-hand
side.
pub fn new_mul(x: f64, y: f64) -> TwoFloat
[src]
Creates a new TwoFloat
by multiplying two f64
values using
Algorithm 3 from Joldes et al. (2017).
pub fn new_div(x: f64, y: f64) -> TwoFloat
[src]
Creates a new TwoFloat
by dividing two f64
values using Algorithm
15 from Joldes et al. (2017) modified for the left-hand-side having a
zero value in the low word.
impl TwoFloat
[src]
pub fn try_new(a: f64, b: f64) -> Result<TwoFloat, ()>
[src]
Attempts to construct a new TwoFloat
from two f64
values. This can
be used to reconstitute a TwoFloat
from the values returned by the
data
method.
Errors
An error will be returned if the supplied f64
values overlap.
Examples
let a = 1.0; let b = 1.0e-200; let result1 = TwoFloat::try_new(a, b)?; let result2 = TwoFloat::try_new(1.0, 2.0); assert_eq!(result1.data(), (a, b)); assert!(result2.is_err());
pub fn data(&self) -> (f64, f64)
[src]
Returns the high and low words of self
as a tuple.
Examples
let value = TwoFloat::new_add(1.0, 1.0e-200); assert_eq!(value.data(), (1.0, 1.0e-200));
pub fn is_valid(&self) -> bool
[src]
Returns true
if self
is a valid value, where both components are
finite (not infinity or NaN).
Examples
let a = TwoFloat::new_add(1.0, 1.0e-300).is_valid(); let b = TwoFloat::new_mul(1.0e300, 1.0e300).is_valid(); assert!(a); assert!(!b);
pub fn min(&self, other: &TwoFloat) -> TwoFloat
[src]
Returns the minimum of two numbers. If one of the arguments is NAN, the other is returned.
Examples
let a = TwoFloat::new_add(35.2, 1e-84); let b = TwoFloat::new_add(35.2, -1e-93); assert_eq!(a.min(&b), b);
pub fn max(&self, other: &TwoFloat) -> TwoFloat
[src]
Returns the maximum of two numbers. If one of the arguments is NAN, the other is returned.
Examples
let a = TwoFloat::new_add(35.2, 1e-84); let b = TwoFloat::new_add(35.2, -1e-93); assert_eq!(a.max(&b), a);
impl TwoFloat
[src]
pub fn exp(&self) -> TwoFloat
[src]
Returns e^(self)
, (the exponential function).
Note that this function returns an approximate value, in particular the low word of the core polynomial approximation is not guaranteed.
Examples
let a = TwoFloat::from(2.0); let b = a.exp(); let e2 = twofloat::consts::E * twofloat::consts::E; assert!((b - e2).abs() / e2 < 1e-16);
pub fn exp2(&self) -> TwoFloat
[src]
Returns 2^(self)
.
This is a convenience method that computes (self * LN_2).exp()
, no
additional accuracy is provided.
Examples
let a = TwoFloat::from(6.0).exp2(); assert!((a - 64.0).abs() < 1e-15);
pub fn ln(&self) -> TwoFloat
[src]
Returns the natural logarithm of the value.
Uses Newton–Raphson iteration which depends on the exp
function, so
may not be fully accurate to the full precision of a TwoFloat
.
Example
let a = twofloat::consts::E.ln(); assert!((a - 1.0).abs() < 1e-11);
pub fn log(&self, base: &TwoFloat) -> TwoFloat
[src]
Returns the logarithm of the number with respect to an arbitrary base.
This is a convenience method that computes self.ln() / base.ln()
, no
additional accuracy is provided.
Examples
let a = TwoFloat::from(81.0); let b = TwoFloat::from(3.0); let c = a.log(&b);
assert!((c - 4.0).abs() < 1e-12);
pub fn log2(&self) -> TwoFloat
[src]
Returns the base 2 logarithm of the number.
This is a convenience method that computes self.ln() / LN_2
, no
additional accuracy is provided.
Examples
let a = TwoFloat::from(64.0).log2(); assert!((a - 6.0).abs() < 1e-12, "{}", a);
pub fn log10(&self) -> TwoFloat
[src]
Returns the base 10 logarithm of the number.
This is a convenience method that computes self.ln() / LN_10
, no
additional accuracy is provided.
Examples
let a = TwoFloat::from(100.0).log10(); assert!((a - 2.0).abs() < 1e-12);
impl TwoFloat
[src]
pub fn fract(&self) -> TwoFloat
[src]
Returns the fractional part of the number.
Examples
let a = TwoFloat::new_add(1.0, 1e-200).fract(); let b = TwoFloat::new_add(-1.0, 1e-200).fract(); assert_eq!(a, TwoFloat::from(1e-200)); assert_eq!(b, TwoFloat::new_add(-1.0, 1e-200));
pub fn trunc(&self) -> TwoFloat
[src]
Returns the integer part of the number.
Examples
let a = TwoFloat::new_add(1.0, 1e-200).trunc(); let b = TwoFloat::new_add(1.0, -1e-200).trunc(); assert_eq!(a, TwoFloat::from(1.0)); assert_eq!(b, TwoFloat::from(0.0));
pub fn ceil(&self) -> TwoFloat
[src]
Returns the smallest integer greater than or equal to the number.
Examples
let a = TwoFloat::new_add(1.0, 1e-200).ceil(); let b = TwoFloat::new_add(1.0, -1e-200).ceil(); let c = TwoFloat::new_add(-1.0, 1e-200).ceil(); assert_eq!(a, TwoFloat::from(2.0)); assert_eq!(b, TwoFloat::from(1.0)); assert_eq!(c, TwoFloat::from(0.0));
pub fn floor(&self) -> TwoFloat
[src]
Returns the smallest integer less than or equal to the number.
Examples
let a = TwoFloat::new_add(1.0, 1e-200).floor(); let b = TwoFloat::new_add(1.0, -1e-200).floor(); let c = TwoFloat::new_add(-1.0, 1e-200).floor(); assert_eq!(a, TwoFloat::from(1.0)); assert_eq!(b, TwoFloat::from(0.0)); assert_eq!(c, TwoFloat::from(-1.0));
impl TwoFloat
[src]
pub fn recip(&self) -> TwoFloat
[src]
Takes the reciprocal (inverse) of the number, 1/x
.
Examples
let a = TwoFloat::new_add(67.2, 5.7e-53); let b = a.recip(); let difference = b.recip() - a; assert!(difference.abs() < 1e-16);
pub fn sqrt(&self) -> TwoFloat
[src]
Returns the square root of the number, using equation 4 from Karp & Markstein (1997).
Examples
let a = TwoFloat::from(2.0); let b = a.sqrt(); assert!(b * b - a < 1e-16);
pub fn cbrt(&self) -> TwoFloat
[src]
Returns the cube root of the number, using Newton-Raphson iteration.
Examples
let a = TwoFloat::new_add(1.4e53, 0.21515); let b = a.cbrt(); assert!(b.powi(3) - a < 1e-16);
pub fn powi(&self, n: i32) -> TwoFloat
[src]
Raises the number to an integer power. Returns a NAN value for 0^0.
Examples
let a = TwoFloat::from(2.0).powi(3); let b = TwoFloat::from(0.0).powi(0); assert!(a - TwoFloat::from(8.0) <= 1e-16); assert!(!b.is_valid());
pub fn powf(&self, y: &TwoFloat) -> TwoFloat
[src]
Returns the value raised to the power y
.
This method is quite inaccurate, where possible powi
, sqrt
or
cbrt
should be preferred.
Examples
let a = TwoFloat::from(-5.0); let b = TwoFloat::from(3.0); let c = a.powf(&b); assert!((c + 125.0).abs() < 1e-9, "{}", c);
impl TwoFloat
[src]
pub fn abs(&self) -> TwoFloat
[src]
Returns the absolute value root of self
.
Examples
let a = TwoFloat::new_add(1.0, 1.0e-300).abs(); let b = TwoFloat::new_add(-1.0, 1.0e-300).abs(); assert_eq!(a, TwoFloat::new_add(1.0, 1.0e-300)); assert_eq!(b, TwoFloat::new_add(1.0, -1.0e-300));
pub fn is_sign_positive(&self) -> bool
[src]
Returns true
if self
has a positive sign, including +0.0
.
Examples
let a = TwoFloat::new_add(0.0, 0.0).is_sign_positive(); let b = TwoFloat::new_add(1.0, 1.0e-300).is_sign_positive(); let c = TwoFloat::new_add(-1.0, 1.0e-300).is_sign_positive(); assert!(a); assert!(b); assert!(!c);
pub fn is_sign_negative(&self) -> bool
[src]
Returns true
if self
has a negative sign, including -0.0
.
Examples
let a = TwoFloat::new_add(-1.0, 1.0e-300).is_sign_negative(); let b = TwoFloat::new_add(0.0, 0.0).is_sign_negative(); let c = TwoFloat::new_add(1.0, 1.0e-300).is_sign_negative(); assert!(a); assert!(!b); assert!(!c);
Trait Implementations
impl<'a> Add<&'a TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, lhs: &'a TwoFloat) -> Self::Output
[src]
Implements addition of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4.
impl<'a> Add<&'a TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, rhs: &'a TwoFloat) -> Self::Output
[src]
Implements addition of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6.
impl<'a, 'b> Add<&'b TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, rhs: &'b TwoFloat) -> Self::Output
[src]
Implements addition of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6.
impl Add<TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, lhs: TwoFloat) -> Self::Output
[src]
Implements addition of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4.
impl Add<TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, rhs: TwoFloat) -> Self::Output
[src]
Implements addition of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6.
impl<'a> Add<TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, rhs: TwoFloat) -> Self::Output
[src]
Implements addition of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6.
impl Add<f64> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, rhs: f64) -> Self::Output
[src]
Implements addition of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4.
impl<'a> Add<f64> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the +
operator.
fn add(self, rhs: f64) -> Self::Output
[src]
Implements addition of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4.
impl<'a> AddAssign<&'a TwoFloat> for TwoFloat
[src]
fn add_assign(&mut self, rhs: &'a TwoFloat)
[src]
Implements addition of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6.
impl AddAssign<TwoFloat> for TwoFloat
[src]
fn add_assign(&mut self, rhs: TwoFloat)
[src]
Implements addition of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6.
impl AddAssign<f64> for TwoFloat
[src]
fn add_assign(&mut self, rhs: f64)
[src]
Implements addition of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4.
impl Clone for TwoFloat
[src]
impl Copy for TwoFloat
[src]
impl Debug for TwoFloat
[src]
impl Display for TwoFloat
[src]
impl<'a> Div<&'a TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: &'a TwoFloat) -> Self::Output
[src]
Implements division of f64
and TwoFloat
using Joldes et al. (2017)
Algorithm 18 modified for the left-hand side having a zero value in
the low word.
impl<'a> Div<&'a TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: &'a TwoFloat) -> Self::Output
[src]
Implements division of two TwoFloat
values using Joldes et al.
(2017) Algorithm 18.
impl<'a, 'b> Div<&'b TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: &'b TwoFloat) -> Self::Output
[src]
Implements division of two TwoFloat
values using Joldes et al.
(2017) Algorithm 18.
impl Div<TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: TwoFloat) -> Self::Output
[src]
Implements division of f64
and TwoFloat
using Joldes et al. (2017)
Algorithm 18 modified for the left-hand side having a zero value in
the low word.
impl Div<TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: TwoFloat) -> Self::Output
[src]
Implements division of two TwoFloat
values using Joldes et al.
(2017) Algorithm 18.
impl<'a> Div<TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: TwoFloat) -> Self::Output
[src]
Implements division of two TwoFloat
values using Joldes et al.
(2017) Algorithm 18.
impl Div<f64> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: f64) -> Self::Output
[src]
Implements division of TwoFloat
and f64
using Joldes et al. (2017)
Algorithm 15
impl<'a> Div<f64> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the /
operator.
fn div(self, rhs: f64) -> Self::Output
[src]
Implements division of TwoFloat
and f64
using Joldes et al. (2017)
Algorithm 15
impl<'a> DivAssign<&'a TwoFloat> for TwoFloat
[src]
fn div_assign(&mut self, rhs: &'a TwoFloat)
[src]
Implements division of two TwoFloat
values using Joldes et al.
(2017) Algorithm 18.
impl DivAssign<TwoFloat> for TwoFloat
[src]
fn div_assign(&mut self, rhs: TwoFloat)
[src]
Implements division of two TwoFloat
values using Joldes et al.
(2017) Algorithm 18.
impl DivAssign<f64> for TwoFloat
[src]
fn div_assign(&mut self, rhs: f64)
[src]
Implements division of TwoFloat
and f64
using Joldes et al. (2017)
Algorithm 15
impl<'a> From<&'a TwoFloat> for f64
[src]
impl<'a> From<&'a TwoFloat> for f32
[src]
impl From<TwoFloat> for f64
[src]
impl From<TwoFloat> for f32
[src]
impl From<f32> for TwoFloat
[src]
impl From<f64> for TwoFloat
[src]
impl From<i16> for TwoFloat
[src]
impl From<i32> for TwoFloat
[src]
impl From<i64> for TwoFloat
[src]
impl From<i8> for TwoFloat
[src]
impl From<u16> for TwoFloat
[src]
impl From<u32> for TwoFloat
[src]
impl From<u64> for TwoFloat
[src]
impl From<u8> for TwoFloat
[src]
impl<'a> Mul<&'a TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, lhs: &'a TwoFloat) -> Self::Output
[src]
Implements multiplication of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 9.
impl<'a> Mul<&'a TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, rhs: &'a TwoFloat) -> Self::Output
[src]
Implements multiplication of two TwoFloat
values using Joldes et al.
(2017) Algorithm 12.
impl<'a, 'b> Mul<&'b TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, rhs: &'b TwoFloat) -> Self::Output
[src]
Implements multiplication of two TwoFloat
values using Joldes et al.
(2017) Algorithm 12.
impl Mul<TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, lhs: TwoFloat) -> Self::Output
[src]
Implements multiplication of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 9.
impl Mul<TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, rhs: TwoFloat) -> Self::Output
[src]
Implements multiplication of two TwoFloat
values using Joldes et al.
(2017) Algorithm 12.
impl<'a> Mul<TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, rhs: TwoFloat) -> Self::Output
[src]
Implements multiplication of two TwoFloat
values using Joldes et al.
(2017) Algorithm 12.
impl Mul<f64> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, rhs: f64) -> Self::Output
[src]
Implements multiplication of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 9.
impl<'a> Mul<f64> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the *
operator.
fn mul(self, rhs: f64) -> Self::Output
[src]
Implements multiplication of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 9.
impl<'a> MulAssign<&'a TwoFloat> for TwoFloat
[src]
fn mul_assign(&mut self, rhs: &'a TwoFloat)
[src]
Implements multiplication of two TwoFloat
values using Joldes et al.
(2017) Algorithm 12.
impl MulAssign<TwoFloat> for TwoFloat
[src]
fn mul_assign(&mut self, rhs: TwoFloat)
[src]
Implements multiplication of two TwoFloat
values using Joldes et al.
(2017) Algorithm 12.
impl MulAssign<f64> for TwoFloat
[src]
fn mul_assign(&mut self, rhs: f64)
[src]
Implements multiplication of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 9.
impl Neg for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn neg(self) -> Self::Output
[src]
Returns a new TwoFloat
with the negated value of self
.
impl<'a> Neg for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn neg(self) -> Self::Output
[src]
Returns a new TwoFloat
with the negated value of self
.
impl PartialEq<TwoFloat> for TwoFloat
[src]
impl PartialEq<TwoFloat> for f64
[src]
impl PartialEq<f64> for TwoFloat
[src]
impl PartialOrd<TwoFloat> for TwoFloat
[src]
fn partial_cmp(&self, other: &TwoFloat) -> Option<Ordering>
[src]
fn lt(&self, other: &TwoFloat) -> bool
[src]
fn le(&self, other: &TwoFloat) -> bool
[src]
fn gt(&self, other: &TwoFloat) -> bool
[src]
fn ge(&self, other: &TwoFloat) -> bool
[src]
impl PartialOrd<TwoFloat> for f64
[src]
fn partial_cmp(&self, other: &TwoFloat) -> Option<Ordering>
[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
impl PartialOrd<f64> for TwoFloat
[src]
fn partial_cmp(&self, other: &f64) -> Option<Ordering>
[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
impl<'a> Rem<&'a TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: &'a TwoFloat) -> Self::Output
[src]
impl<'a> Rem<&'a TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: &'a TwoFloat) -> Self::Output
[src]
impl<'a, 'b> Rem<&'b TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: &'b TwoFloat) -> Self::Output
[src]
impl Rem<TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: TwoFloat) -> Self::Output
[src]
impl Rem<TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: TwoFloat) -> Self::Output
[src]
impl<'a> Rem<TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: TwoFloat) -> Self::Output
[src]
impl Rem<f64> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: f64) -> Self::Output
[src]
impl<'a> Rem<f64> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the %
operator.
fn rem(self, rhs: f64) -> Self::Output
[src]
impl<'a> RemAssign<&'a TwoFloat> for TwoFloat
[src]
fn rem_assign(&mut self, rhs: &'a TwoFloat)
[src]
impl RemAssign<TwoFloat> for TwoFloat
[src]
fn rem_assign(&mut self, rhs: TwoFloat)
[src]
impl RemAssign<f64> for TwoFloat
[src]
fn rem_assign(&mut self, rhs: f64)
[src]
impl StructuralPartialEq for TwoFloat
[src]
impl<'a> Sub<&'a TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: &'a TwoFloat) -> Self::Output
[src]
Implements subtraction of f64
and TwoFloat
using Joldes et al.
(2017) Algorithm 4 modified for negative left-hand side.
impl<'a> Sub<&'a TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: &'a TwoFloat) -> Self::Output
[src]
Implements subtraction of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6 modified for a negative right-hand side.
impl<'a, 'b> Sub<&'b TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: &'b TwoFloat) -> Self::Output
[src]
Implements subtraction of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6 modified for a negative right-hand side.
impl Sub<TwoFloat> for f64
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: TwoFloat) -> Self::Output
[src]
Implements subtraction of f64
and TwoFloat
using Joldes et al.
(2017) Algorithm 4 modified for negative left-hand side.
impl Sub<TwoFloat> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: TwoFloat) -> Self::Output
[src]
Implements subtraction of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6 modified for a negative right-hand side.
impl<'a> Sub<TwoFloat> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: TwoFloat) -> Self::Output
[src]
Implements subtraction of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6 modified for a negative right-hand side.
impl Sub<f64> for TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: f64) -> Self::Output
[src]
Implements subtraction of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4 modified for negative right-hand side.
impl<'a> Sub<f64> for &'a TwoFloat
[src]
type Output = TwoFloat
The resulting type after applying the -
operator.
fn sub(self, rhs: f64) -> Self::Output
[src]
Implements subtraction of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4 modified for negative right-hand side.
impl<'a> SubAssign<&'a TwoFloat> for TwoFloat
[src]
fn sub_assign(&mut self, rhs: &'a TwoFloat)
[src]
Implements subtraction of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6 modified for a negative right-hand side.
impl SubAssign<TwoFloat> for TwoFloat
[src]
fn sub_assign(&mut self, rhs: TwoFloat)
[src]
Implements subtraction of two TwoFloat
values using Joldes et al.
(2017) Algorithm 6 modified for a negative right-hand side.
impl SubAssign<f64> for TwoFloat
[src]
fn sub_assign(&mut self, rhs: f64)
[src]
Implements subtraction of TwoFloat
and f64
using Joldes et al.
(2017) Algorithm 4 modified for negative right-hand side.
impl<'a> TryFrom<&'a TwoFloat> for i32
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl<'a> TryFrom<&'a TwoFloat> for i16
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl<'a> TryFrom<&'a TwoFloat> for i8
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl<'a> TryFrom<&'a TwoFloat> for u32
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl<'a> TryFrom<&'a TwoFloat> for u16
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl<'a> TryFrom<&'a TwoFloat> for u8
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl<'a> TryFrom<&'a TwoFloat> for i64
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl<'a> TryFrom<&'a TwoFloat> for u64
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: &'a TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for i32
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for i16
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for i8
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for u32
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for u16
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for u8
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for i64
[src]
type Error = ()
The type returned in the event of a conversion error.
fn try_from(value: TwoFloat) -> Result<Self, Self::Error>
[src]
impl TryFrom<TwoFloat> for u64
[src]
Auto Trait Implementations
impl RefUnwindSafe for TwoFloat
impl Send for TwoFloat
impl Sync for TwoFloat
impl Unpin for TwoFloat
impl UnwindSafe for TwoFloat
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,