Struct amplify_apfloat::ppc::DoubleFloat
source · [−]pub struct DoubleFloat<F>(_, _);
Trait Implementations
sourceimpl<F> Add<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> Add<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourceimpl<F> AddAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> AddAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourcefn add_assign(&mut self, rhs: Self)
fn add_assign(&mut self, rhs: Self)
Performs the +=
operation. Read more
sourceimpl<F: Clone> Clone for DoubleFloat<F>
impl<F: Clone> Clone for DoubleFloat<F>
sourcefn clone(&self) -> DoubleFloat<F>
fn clone(&self) -> DoubleFloat<F>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<F: Debug> Debug for DoubleFloat<F>
impl<F: Debug> Debug for DoubleFloat<F>
sourceimpl<F> Default for DoubleFloat<F> where
Self: Float,
impl<F> Default for DoubleFloat<F> where
Self: Float,
sourceimpl<F: FloatConvert<IeeeFloat<FallbackS<F>>>> Display for DoubleFloat<F>
impl<F: FloatConvert<IeeeFloat<FallbackS<F>>>> Display for DoubleFloat<F>
sourceimpl<F> Div<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> Div<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourceimpl<F> DivAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> DivAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourcefn div_assign(&mut self, rhs: Self)
fn div_assign(&mut self, rhs: Self)
Performs the /=
operation. Read more
sourceimpl<F: FloatConvert<IeeeFloat<FallbackS<F>>>> Float for DoubleFloat<F> where
Self: From<IeeeFloat<FallbackS<F>>>,
impl<F: FloatConvert<IeeeFloat<FallbackS<F>>>> Float for DoubleFloat<F> where
Self: From<IeeeFloat<FallbackS<F>>>,
sourceconst PRECISION: usize = Fallback::::PRECISION
const PRECISION: usize = Fallback::::PRECISION
Number of bits in the significand. This includes the integer bit.
sourceconst MAX_EXP: ExpInt = Fallback::::MAX_EXP
const MAX_EXP: ExpInt = Fallback::::MAX_EXP
The largest E such that 2E is representable; this matches the definition of IEEE 754. Read more
sourceconst MIN_EXP: ExpInt = Fallback::::MIN_EXP
const MIN_EXP: ExpInt = Fallback::::MIN_EXP
The smallest E such that 2E is a normalized number; this matches the definition of IEEE 754. Read more
sourceconst SMALLEST: Self = DoubleFloat(F::SMALLEST, F::ZERO)
const SMALLEST: Self = DoubleFloat(F::SMALLEST, F::ZERO)
Smallest (by magnitude) finite number. Might be denormalized, which implies a relative loss of precision. Read more
sourcefn smallest_normalized() -> Self
fn smallest_normalized() -> Self
Smallest (by magnitude) normalized finite number.
fn add_r(self, rhs: Self, round: Round) -> StatusAnd<Self>
fn mul_r(self, rhs: Self, round: Round) -> StatusAnd<Self>
fn mul_add_r(
self,
multiplicand: Self,
addend: Self,
round: Round
) -> StatusAnd<Self>
fn div_r(self, rhs: Self, round: Round) -> StatusAnd<Self>
fn round_to_integral(self, round: Round) -> StatusAnd<Self>
fn from_bits(input: u256) -> Self
fn from_u256_r(input: u256, round: Round) -> StatusAnd<Self>
fn from_str_r(s: &str, round: Round) -> Result<StatusAnd<Self>, ParseError>
fn to_bits(self) -> u256
fn to_u256_r(
self,
width: usize,
round: Round,
is_exact: &mut bool
) -> StatusAnd<u256>
fn cmp_abs_normal(self, rhs: Self) -> Ordering
sourcefn bitwise_eq(self, rhs: Self) -> bool
fn bitwise_eq(self, rhs: Self) -> bool
Bitwise comparison for equality (QNaNs compare equal, 0!=-0).
sourcefn is_negative(self) -> bool
fn is_negative(self) -> bool
IEEE-754R isSignMinus: Returns true if and only if the current value is negative. Read more
sourcefn is_denormal(self) -> bool
fn is_denormal(self) -> bool
IEEE-754R isSubnormal(): Returns true if and only if the float is a denormal. Read more
sourcefn is_signaling(self) -> bool
fn is_signaling(self) -> bool
Returns true if and only if the float is a signaling NaN.
fn category(self) -> Category
sourcefn get_exact_inverse(self) -> Option<Self>
fn get_exact_inverse(self) -> Option<Self>
If this value has an exact multiplicative inverse, return it.
sourcefn ilogb(self) -> ExpInt
fn ilogb(self) -> ExpInt
Returns the exponent of the internal representation of the Float. Read more
sourcefn scalbn_r(self, exp: ExpInt, round: Round) -> Self
fn scalbn_r(self, exp: ExpInt, round: Round) -> Self
Returns: self * 2exp for integral exponents.
sourcefn frexp_r(self, exp: &mut ExpInt, round: Round) -> Self
fn frexp_r(self, exp: &mut ExpInt, round: Round) -> Self
Equivalent of C standard library function. Read more
fn sub_r(self, rhs: Self, round: Round) -> StatusAnd<Self>
fn mul_add(self, multiplicand: Self, addend: Self) -> StatusAnd<Self>
fn abs(self) -> Self
fn copy_sign(self, rhs: Self) -> Self
fn from_i256_r(input: i256, round: Round) -> StatusAnd<Self>
fn from_i256(input: i256) -> StatusAnd<Self>
fn from_u256(input: u256) -> StatusAnd<Self>
sourcefn to_i256_r(
self,
width: usize,
round: Round,
is_exact: &mut bool
) -> StatusAnd<i256>
fn to_i256_r(
self,
width: usize,
round: Round,
is_exact: &mut bool
) -> StatusAnd<i256>
Convert a floating point number to an integer according to the rounding mode. In case of an invalid operation exception, deterministic values are returned, namely zero for NaNs and the minimal or maximal value respectively for underflow or overflow. If the rounded value is in range but the floating point number is not the exact integer, the C standard doesn’t require an inexact exception to be raised. IEEE-854 does require it so we do that. Read more
fn to_i256(self, width: usize) -> StatusAnd<i256>
fn to_u256(self, width: usize) -> StatusAnd<u256>
sourcefn min(self, other: Self) -> Self
fn min(self, other: Self) -> Self
Implements IEEE minNum semantics. Returns the smaller of the 2 arguments if both are not NaN. If either argument is a NaN, returns the other argument. Read more
sourcefn max(self, other: Self) -> Self
fn max(self, other: Self) -> Self
Implements IEEE maxNum semantics. Returns the larger of the 2 arguments if both are not NaN. If either argument is a NaN, returns the other argument. Read more
sourcefn is_normal(self) -> bool
fn is_normal(self) -> bool
IEEE-754R isNormal: Returns true if and only if the current value is normal. Read more
sourcefn is_finite(self) -> bool
fn is_finite(self) -> bool
Returns true if and only if the current value is zero, subnormal, or normal. Read more
sourcefn is_infinite(self) -> bool
fn is_infinite(self) -> bool
IEEE-754R isInfinite(): Returns true if and only if the float is infinity.
fn is_non_zero(self) -> bool
fn is_finite_non_zero(self) -> bool
fn is_pos_zero(self) -> bool
fn is_neg_zero(self) -> bool
sourcefn is_smallest(self) -> bool
fn is_smallest(self) -> bool
Returns true if and only if the number has the smallest possible non-zero magnitude in the current semantics. Read more
sourcefn is_largest(self) -> bool
fn is_largest(self) -> bool
Returns true if and only if the number has the largest possible finite magnitude in the current semantics. Read more
sourcefn is_integer(self) -> bool
fn is_integer(self) -> bool
Returns true if and only if the number is an exact integer.
fn scalbn(self, exp: ExpInt) -> Self
fn frexp(self, exp: &mut ExpInt) -> Self
sourceimpl<F: FloatConvert<Self>> From<DoubleFloat<F>> for IeeeFloat<FallbackS<F>>
impl<F: FloatConvert<Self>> From<DoubleFloat<F>> for IeeeFloat<FallbackS<F>>
sourcefn from(DoubleFloat: DoubleFloat<F>) -> Self
fn from(DoubleFloat: DoubleFloat<F>) -> Self
Converts to this type from the input type.
sourceimpl<F: Float> From<IeeeFloat<FallbackS<F>>> for DoubleFloat<F> where
F: FloatConvert<IeeeFloat<FallbackExtendedS<F>>>,
IeeeFloat<FallbackExtendedS<F>>: FloatConvert<F>,
impl<F: Float> From<IeeeFloat<FallbackS<F>>> for DoubleFloat<F> where
F: FloatConvert<IeeeFloat<FallbackExtendedS<F>>>,
IeeeFloat<FallbackExtendedS<F>>: FloatConvert<F>,
sourceimpl<F> FromStr for DoubleFloat<F> where
Self: Float,
impl<F> FromStr for DoubleFloat<F> where
Self: Float,
type Err = ParseError
type Err = ParseError
The associated error which can be returned from parsing.
sourceimpl<F> Mul<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> Mul<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourceimpl<F> MulAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> MulAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourcefn mul_assign(&mut self, rhs: Self)
fn mul_assign(&mut self, rhs: Self)
Performs the *=
operation. Read more
sourceimpl<F: Float> Neg for DoubleFloat<F>
impl<F: Float> Neg for DoubleFloat<F>
type Output = DoubleFloat<F>
type Output = DoubleFloat<F>
The resulting type after applying the -
operator.
sourceimpl<F: PartialEq> PartialEq<DoubleFloat<F>> for DoubleFloat<F>
impl<F: PartialEq> PartialEq<DoubleFloat<F>> for DoubleFloat<F>
sourcefn eq(&self, other: &DoubleFloat<F>) -> bool
fn eq(&self, other: &DoubleFloat<F>) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &DoubleFloat<F>) -> bool
fn ne(&self, other: &DoubleFloat<F>) -> bool
This method tests for !=
.
sourceimpl<F: PartialOrd> PartialOrd<DoubleFloat<F>> for DoubleFloat<F>
impl<F: PartialOrd> PartialOrd<DoubleFloat<F>> for DoubleFloat<F>
sourcefn partial_cmp(&self, other: &DoubleFloat<F>) -> Option<Ordering>
fn partial_cmp(&self, other: &DoubleFloat<F>) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
sourceimpl<F> Rem<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> Rem<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourceimpl<F> RemAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> RemAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourcefn rem_assign(&mut self, rhs: Self)
fn rem_assign(&mut self, rhs: Self)
Performs the %=
operation. Read more
sourceimpl<F> Sub<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> Sub<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourceimpl<F> SubAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
impl<F> SubAssign<DoubleFloat<F>> for DoubleFloat<F> where
Self: Float,
sourcefn sub_assign(&mut self, rhs: Self)
fn sub_assign(&mut self, rhs: Self)
Performs the -=
operation. Read more
impl<F: Copy> Copy for DoubleFloat<F>
impl<F> StructuralPartialEq for DoubleFloat<F>
Auto Trait Implementations
impl<F> RefUnwindSafe for DoubleFloat<F> where
F: RefUnwindSafe,
impl<F> Send for DoubleFloat<F> where
F: Send,
impl<F> Sync for DoubleFloat<F> where
F: Sync,
impl<F> Unpin for DoubleFloat<F> where
F: Unpin,
impl<F> UnwindSafe for DoubleFloat<F> where
F: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more