#[repr(transparent)]pub struct P32E2(_);
Implementations§
source§impl P32E2
impl P32E2
pub const fn from_i8(a: i8) -> Self
pub const fn to_i8(self) -> i8
pub const fn from_i16(a: i16) -> Self
pub const fn to_i16(self) -> i16
pub const fn from_isize(a: isize) -> Self
pub const fn to_isize(self) -> isize
pub const fn from_u8(a: u8) -> Self
pub const fn to_u8(self) -> u8
pub const fn from_u16(a: u16) -> Self
pub const fn to_u16(self) -> u16
pub const fn from_usize(a: usize) -> Self
pub const fn to_usize(self) -> usize
source§impl P32E2
impl P32E2
pub const fn from_f32(float: f32) -> Self
pub const fn from_f64(float: f64) -> Self
pub const fn to_f32(self) -> f32
pub const fn to_f64(self) -> f64
pub const fn to_i32(self) -> i32
pub const fn to_u32(self) -> u32
pub const fn to_i64(self) -> i64
pub const fn to_u64(self) -> u64
pub const fn from_i32(i_a: i32) -> Self
pub const fn from_u32(i_a: u32) -> Self
pub const fn from_i64(i_a: i64) -> Self
pub const fn from_u64(a: u64) -> Self
source§impl P32E2
impl P32E2
pub const fn trunc(self) -> Self
pub const fn fract(self) -> Self
pub const fn div_euclid(self, rhs: Self) -> Self
pub const fn rem_euclid(self, rhs: Self) -> Self
pub fn powi(self, _n: i32) -> Self
pub fn powf(self, other: Self) -> Self
pub fn exp(self) -> Self
pub fn exp2(self) -> Self
pub fn exp10(self) -> Self
pub fn ln(self) -> Self
pub fn log(self, _base: Self) -> Self
pub fn log2(self) -> Self
pub fn log10(self) -> Self
pub fn cbrt(self) -> Self
pub fn hypot(self, other: Self) -> Self
pub fn sin(self) -> Self
pub fn cos(self) -> Self
pub fn tan(self) -> Self
pub fn asin(self) -> Self
pub fn acos(self) -> Self
pub fn atan(self) -> Self
pub fn atan2(self, other: Self) -> Self
pub fn sin_cos(self) -> (Self, Self)
pub fn exp_m1(self) -> Self
pub const fn ln_1p(self) -> Self
pub fn sinh(self) -> Self
pub fn cosh(self) -> Self
pub fn tanh(self) -> Self
pub fn asinh(self) -> Self
pub fn acosh(self) -> Self
pub const fn atanh(self) -> Self
source§impl P32E2
impl P32E2
pub const SIZE: usize = 32usize
pub const ES: usize = 2usize
pub const USEED: usize = 16usize
sourcepub const MIN_POSITIVE: Self = _
pub const MIN_POSITIVE: Self = _
Smallest positive normal value (7.523163845_e-37).
pub const fn new(i: i32) -> Self
pub const fn from_bits(v: u32) -> Self
pub const fn to_bits(self) -> u32
pub const fn recip(self) -> Self
pub const fn to_degrees(self) -> Self
pub const fn to_radians(self) -> Self
source§impl P32E2
impl P32E2
pub const fn abs(self) -> Self
pub const fn is_zero(self) -> bool
pub const fn is_nar(self) -> bool
pub const fn is_nan(self) -> bool
pub const fn is_infinite(self) -> bool
pub const fn is_finite(self) -> bool
pub const fn is_normal(self) -> bool
pub const fn clamp(self, min: Self, max: Self) -> Self
pub const fn min(self, other: Self) -> Self
pub const fn max(self, other: Self) -> Self
pub const fn classify(self) -> FpCategory
pub const fn is_sign_positive(self) -> bool
pub const fn is_sign_negative(self) -> bool
pub const fn signum(self) -> Self
pub const fn copysign(self, other: Self) -> Self
pub const fn eq(self, other: Self) -> bool
pub const fn cmp(self, other: Self) -> Ordering
pub const fn lt(&self, other: Self) -> bool
pub const fn le(&self, other: Self) -> bool
pub const fn ge(&self, other: Self) -> bool
pub const fn gt(&self, other: Self) -> bool
source§impl P32E2
impl P32E2
pub const fn from_p16e1(p_a: P16E1) -> Self
pub const fn to_p16e1(self) -> P16E1
pub const fn from_p8e0(p_a: P8E0) -> Self
pub const fn to_p8e0(self) -> P8E0
pub const fn to_pxe2<const N: u32>(self) -> PxE2<{ N }>
pub const fn to_pxe1<const N: u32>(self) -> PxE1<{ N }>
pub const fn from_pxe2<const N: u32>(p_a: PxE2<{ N }>) -> Self
pub const fn from_pxe1<const N: u32>(p_a: PxE1<{ N }>) -> Self
Trait Implementations§
source§impl AddAssign<P32E2> for P32E2
impl AddAssign<P32E2> for P32E2
source§fn add_assign(&mut self, other: Self)
fn add_assign(&mut self, other: Self)
Performs the
+=
operation. Read moresource§impl AddAssign<P32E2> for Q32E2
impl AddAssign<P32E2> for Q32E2
source§fn add_assign(&mut self, rhs: P32E2)
fn add_assign(&mut self, rhs: P32E2)
Performs the
+=
operation. Read moresource§impl DivAssign<P32E2> for P32E2
impl DivAssign<P32E2> for P32E2
source§fn div_assign(&mut self, other: Self)
fn div_assign(&mut self, other: Self)
Performs the
/=
operation. Read moresource§impl Float for P32E2
impl Float for P32E2
source§fn neg_infinity() -> Self
fn neg_infinity() -> Self
Returns the negative infinite value. Read more
source§fn min_value() -> Self
fn min_value() -> Self
Returns the smallest finite value that this type can represent. Read more
source§fn min_positive_value() -> Self
fn min_positive_value() -> Self
Returns the smallest positive, normalized value that this type can represent. Read more
source§fn max_value() -> Self
fn max_value() -> Self
Returns the largest finite value that this type can represent. Read more
source§fn is_infinite(self) -> bool
fn is_infinite(self) -> bool
Returns
true
if this value is positive infinity or negative infinity and
false otherwise. Read moresource§fn classify(self) -> FpCategory
fn classify(self) -> FpCategory
Returns the floating point category of the number. If only one property
is going to be tested, it is generally faster to use the specific
predicate instead. Read more
source§fn ceil(self) -> Self
fn ceil(self) -> Self
Returns the smallest integer greater than or equal to a number. Read more
source§fn round(self) -> Self
fn round(self) -> Self
Returns the nearest integer to a number. Round half-way cases away from
0.0
. Read moresource§fn is_sign_positive(self) -> bool
fn is_sign_positive(self) -> bool
Returns
true
if self
is positive, including +0.0
,
Float::infinity()
, and since Rust 1.20 also Float::nan()
. Read moresource§fn is_sign_negative(self) -> bool
fn is_sign_negative(self) -> bool
Returns
true
if self
is negative, including -0.0
,
Float::neg_infinity()
, and since Rust 1.20 also -Float::nan()
. Read moresource§fn mul_add(self, a: Self, b: Self) -> Self
fn mul_add(self, a: Self, b: Self) -> Self
Fused multiply-add. Computes
(self * a) + b
with only one rounding
error, yielding a more accurate result than an unfused multiply-add. Read moresource§fn log(self, base: Self) -> Self
fn log(self, base: Self) -> Self
Returns the logarithm of the number with respect to an arbitrary base. Read more
source§fn hypot(self, other: Self) -> Self
fn hypot(self, other: Self) -> Self
Calculate the length of the hypotenuse of a right-angle triangle given
legs of length
x
and y
. Read moresource§fn asin(self) -> Self
fn asin(self) -> Self
Computes the arcsine of a number. Return value is in radians in
the range [-pi/2, pi/2] or NaN if the number is outside the range
[-1, 1]. Read more
source§fn acos(self) -> Self
fn acos(self) -> Self
Computes the arccosine of a number. Return value is in radians in
the range [0, pi] or NaN if the number is outside the range
[-1, 1]. Read more
source§fn atan(self) -> Self
fn atan(self) -> Self
Computes the arctangent of a number. Return value is in radians in the
range [-pi/2, pi/2]; Read more
source§fn sin_cos(self) -> (Self, Self)
fn sin_cos(self) -> (Self, Self)
source§fn exp_m1(self) -> Self
fn exp_m1(self) -> Self
Returns
e^(self) - 1
in a way that is accurate even if the
number is close to zero. Read moresource§fn ln_1p(self) -> Self
fn ln_1p(self) -> Self
Returns
ln(1+n)
(natural logarithm) more accurately than if
the operations were performed separately. Read moresource§fn integer_decode(self) -> (u64, i16, i8)
fn integer_decode(self) -> (u64, i16, i8)
Returns the mantissa, base 2 exponent, and sign as integers, respectively.
The original number can be recovered by
sign * mantissa * 2 ^ exponent
. Read moresource§fn to_degrees(self) -> Self
fn to_degrees(self) -> Self
Converts radians to degrees. Read more
source§fn to_radians(self) -> Self
fn to_radians(self) -> Self
Converts degrees to radians. Read more
source§impl FloatConst for P32E2
impl FloatConst for P32E2
source§impl FromPrimitive for P32E2
impl FromPrimitive for P32E2
source§fn from_i8(n: i8) -> Option<P32E2>
fn from_i8(n: i8) -> Option<P32E2>
Converts an
i8
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_i16(n: i16) -> Option<P32E2>
fn from_i16(n: i16) -> Option<P32E2>
Converts an
i16
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_i32(n: i32) -> Option<P32E2>
fn from_i32(n: i32) -> Option<P32E2>
Converts an
i32
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_i64(n: i64) -> Option<P32E2>
fn from_i64(n: i64) -> Option<P32E2>
Converts an
i64
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_u8(n: u8) -> Option<P32E2>
fn from_u8(n: u8) -> Option<P32E2>
Converts an
u8
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_u16(n: u16) -> Option<P32E2>
fn from_u16(n: u16) -> Option<P32E2>
Converts an
u16
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_u32(n: u32) -> Option<P32E2>
fn from_u32(n: u32) -> Option<P32E2>
Converts an
u32
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_u64(n: u64) -> Option<P32E2>
fn from_u64(n: u64) -> Option<P32E2>
Converts an
u64
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_f32(f: f32) -> Option<P32E2>
fn from_f32(f: f32) -> Option<P32E2>
Converts a
f32
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_f64(f: f64) -> Option<P32E2>
fn from_f64(f: f64) -> Option<P32E2>
Converts a
f64
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_isize(n: isize) -> Option<Self>
fn from_isize(n: isize) -> Option<Self>
Converts an
isize
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§fn from_i128(n: i128) -> Option<Self>
fn from_i128(n: i128) -> Option<Self>
Converts an
i128
to return an optional value of this type. If the
value cannot be represented by this type, then None
is returned. Read moresource§impl FromStr for P32E2
impl FromStr for P32E2
§type Err = ParseFloatError
type Err = ParseFloatError
The associated error which can be returned from parsing.
source§impl MathConsts for P32E2
impl MathConsts for P32E2
source§const FRAC_1_SQRT_2: Self = _
const FRAC_1_SQRT_2: Self = _
1/sqrt(2) = 0.707106781186547524400844362104849039
source§const FRAC_2_SQRT_PI: Self = _
const FRAC_2_SQRT_PI: Self = _
2/sqrt(π) = 1.12837916709551257389615890312154517
source§impl MulAssign<P32E2> for P32E2
impl MulAssign<P32E2> for P32E2
source§fn mul_assign(&mut self, other: Self)
fn mul_assign(&mut self, other: Self)
Performs the
*=
operation. Read moresource§impl Num for P32E2
impl Num for P32E2
type FromStrRadixErr = ParseFloatError
source§fn from_str_radix(src: &str, radix: u32) -> Result<Self, Self::FromStrRadixErr>
fn from_str_radix(src: &str, radix: u32) -> Result<Self, Self::FromStrRadixErr>
Convert from a string and radix (typically
2..=36
). Read moresource§impl Ord for P32E2
impl Ord for P32E2
source§impl PartialOrd<P32E2> for P32E2
impl PartialOrd<P32E2> for P32E2
1.0.0 · source§fn 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 moresource§impl Polynom<[P32E2; 1]> for P32E2
impl Polynom<[P32E2; 1]> for P32E2
fn poly1(self, c: &[T; 2]) -> Self
fn poly2(self, c: &[T; 3]) -> Self
fn poly3(self, c: &[T; 4]) -> Self
fn poly4(self, c: &[T; 5]) -> Self
fn poly5(self, c: &[T; 6]) -> Self
fn poly6(self, c: &[T; 7]) -> Self
fn poly7(self, c: &[T; 8]) -> Self
fn poly8(self, c: &[T; 9]) -> Self
fn poly9(self, c: &[T; 10]) -> Self
fn poly10(self, c: &[T; 11]) -> Self
fn poly11(self, c: &[T; 12]) -> Self
fn poly12(self, c: &[T; 13]) -> Self
fn poly13(self, c: &[T; 14]) -> Self
fn poly14(self, c: &[T; 15]) -> Self
fn poly15(self, c: &[T; 16]) -> Self
fn poly16(self, c: &[T; 17]) -> Self
fn poly17(self, c: &[T; 18]) -> Self
fn poly18(self, c: &[T; 19]) -> Self
fn poly3a(self, c: &[T; 4]) -> Self
fn poly4a(self, c: &[T; 5]) -> Self
source§impl Polynom<[P32E2; 2]> for P32E2
impl Polynom<[P32E2; 2]> for P32E2
fn poly1(self, c: &[T; 2]) -> Self
fn poly2(self, c: &[T; 3]) -> Self
fn poly3(self, c: &[T; 4]) -> Self
fn poly4(self, c: &[T; 5]) -> Self
fn poly5(self, c: &[T; 6]) -> Self
fn poly6(self, c: &[T; 7]) -> Self
fn poly7(self, c: &[T; 8]) -> Self
fn poly8(self, c: &[T; 9]) -> Self
fn poly9(self, c: &[T; 10]) -> Self
fn poly10(self, c: &[T; 11]) -> Self
fn poly11(self, c: &[T; 12]) -> Self
fn poly12(self, c: &[T; 13]) -> Self
fn poly13(self, c: &[T; 14]) -> Self
fn poly14(self, c: &[T; 15]) -> Self
fn poly15(self, c: &[T; 16]) -> Self
fn poly16(self, c: &[T; 17]) -> Self
fn poly17(self, c: &[T; 18]) -> Self
fn poly18(self, c: &[T; 19]) -> Self
fn poly3a(self, c: &[T; 4]) -> Self
fn poly4a(self, c: &[T; 5]) -> Self
source§impl Polynom<[P32E2; 3]> for P32E2
impl Polynom<[P32E2; 3]> for P32E2
fn poly1(self, c: &[T; 2]) -> Self
fn poly2(self, c: &[T; 3]) -> Self
fn poly3(self, c: &[T; 4]) -> Self
fn poly4(self, c: &[T; 5]) -> Self
fn poly5(self, c: &[T; 6]) -> Self
fn poly6(self, c: &[T; 7]) -> Self
fn poly7(self, c: &[T; 8]) -> Self
fn poly8(self, c: &[T; 9]) -> Self
fn poly9(self, c: &[T; 10]) -> Self
fn poly10(self, c: &[T; 11]) -> Self
fn poly11(self, c: &[T; 12]) -> Self
fn poly12(self, c: &[T; 13]) -> Self
fn poly13(self, c: &[T; 14]) -> Self
fn poly14(self, c: &[T; 15]) -> Self
fn poly15(self, c: &[T; 16]) -> Self
fn poly16(self, c: &[T; 17]) -> Self
fn poly17(self, c: &[T; 18]) -> Self
fn poly18(self, c: &[T; 19]) -> Self
fn poly3a(self, c: &[T; 4]) -> Self
fn poly4a(self, c: &[T; 5]) -> Self
source§impl Polynom<[P32E2; 4]> for P32E2
impl Polynom<[P32E2; 4]> for P32E2
fn poly1(self, c: &[T; 2]) -> Self
fn poly2(self, c: &[T; 3]) -> Self
fn poly3(self, c: &[T; 4]) -> Self
fn poly4(self, c: &[T; 5]) -> Self
fn poly5(self, c: &[T; 6]) -> Self
fn poly6(self, c: &[T; 7]) -> Self
fn poly7(self, c: &[T; 8]) -> Self
fn poly8(self, c: &[T; 9]) -> Self
fn poly9(self, c: &[T; 10]) -> Self
fn poly10(self, c: &[T; 11]) -> Self
fn poly11(self, c: &[T; 12]) -> Self
fn poly12(self, c: &[T; 13]) -> Self
fn poly13(self, c: &[T; 14]) -> Self
fn poly14(self, c: &[T; 15]) -> Self
fn poly15(self, c: &[T; 16]) -> Self
fn poly16(self, c: &[T; 17]) -> Self
fn poly17(self, c: &[T; 18]) -> Self
fn poly18(self, c: &[T; 19]) -> Self
fn poly3a(self, c: &[T; 4]) -> Self
fn poly4a(self, c: &[T; 5]) -> Self
source§impl Polynom<P32E2> for P32E2
impl Polynom<P32E2> for P32E2
fn poly1(self, c: &[T; 2]) -> Self
fn poly2(self, c: &[T; 3]) -> Self
fn poly3(self, c: &[T; 4]) -> Self
fn poly4(self, c: &[T; 5]) -> Self
fn poly5(self, c: &[T; 6]) -> Self
fn poly6(self, c: &[T; 7]) -> Self
fn poly7(self, c: &[T; 8]) -> Self
fn poly8(self, c: &[T; 9]) -> Self
fn poly9(self, c: &[T; 10]) -> Self
fn poly10(self, c: &[T; 11]) -> Self
fn poly11(self, c: &[T; 12]) -> Self
fn poly12(self, c: &[T; 13]) -> Self
fn poly13(self, c: &[T; 14]) -> Self
fn poly14(self, c: &[T; 15]) -> Self
fn poly15(self, c: &[T; 16]) -> Self
fn poly16(self, c: &[T; 17]) -> Self
fn poly17(self, c: &[T; 18]) -> Self
fn poly18(self, c: &[T; 19]) -> Self
fn poly3a(self, c: &[T; 4]) -> Self
fn poly4a(self, c: &[T; 5]) -> Self
source§impl Quire<P32E2> for Q32E2
impl Quire<P32E2> for Q32E2
type Bits = [u64; 8]
fn init() -> Self
fn from_posit(p: P32E2) -> Self
fn to_posit(&self) -> P32E2
fn from_bits(v: Self::Bits) -> Self
fn to_bits(&self) -> Self::Bits
fn is_zero(&self) -> bool
fn is_nar(&self) -> bool
fn add_product(&mut self, p_a: P32E2, p_b: P32E2)
fn sub_product(&mut self, p_a: P32E2, p_b: P32E2)
fn clear(&mut self)
fn neg(&mut self)
source§impl RemAssign<P32E2> for P32E2
impl RemAssign<P32E2> for P32E2
source§fn rem_assign(&mut self, other: Self)
fn rem_assign(&mut self, other: Self)
Performs the
%=
operation. Read moresource§impl Signed for P32E2
impl Signed for P32E2
source§fn is_positive(&self) -> bool
fn is_positive(&self) -> bool
Returns true if the number is positive and false if the number is zero or negative.
source§fn is_negative(&self) -> bool
fn is_negative(&self) -> bool
Returns true if the number is negative and false if the number is zero or positive.
source§impl SubAssign<P32E2> for P32E2
impl SubAssign<P32E2> for P32E2
source§fn sub_assign(&mut self, other: Self)
fn sub_assign(&mut self, other: Self)
Performs the
-=
operation. Read moresource§impl SubAssign<P32E2> for Q32E2
impl SubAssign<P32E2> for Q32E2
source§fn sub_assign(&mut self, rhs: P32E2)
fn sub_assign(&mut self, rhs: P32E2)
Performs the
-=
operation. Read moresource§impl ToPrimitive for P32E2
impl ToPrimitive for P32E2
source§fn to_i64(&self) -> Option<i64>
fn to_i64(&self) -> Option<i64>
Converts the value of
self
to an i64
. If the value cannot be
represented by an i64
, then None
is returned. Read moresource§fn to_u64(&self) -> Option<u64>
fn to_u64(&self) -> Option<u64>
Converts the value of
self
to a u64
. If the value cannot be
represented by a u64
, then None
is returned. Read moresource§fn to_f64(&self) -> Option<f64>
fn to_f64(&self) -> Option<f64>
Converts the value of
self
to an f64
. Overflows may map to positive
or negative inifinity, otherwise None
is returned if the value cannot
be represented by an f64
. Read moresource§fn to_isize(&self) -> Option<isize>
fn to_isize(&self) -> Option<isize>
Converts the value of
self
to an isize
. If the value cannot be
represented by an isize
, then None
is returned. Read moresource§fn to_i8(&self) -> Option<i8>
fn to_i8(&self) -> Option<i8>
Converts the value of
self
to an i8
. If the value cannot be
represented by an i8
, then None
is returned. Read moresource§fn to_i16(&self) -> Option<i16>
fn to_i16(&self) -> Option<i16>
Converts the value of
self
to an i16
. If the value cannot be
represented by an i16
, then None
is returned. Read moresource§fn to_i32(&self) -> Option<i32>
fn to_i32(&self) -> Option<i32>
Converts the value of
self
to an i32
. If the value cannot be
represented by an i32
, then None
is returned. Read moresource§fn to_i128(&self) -> Option<i128>
fn to_i128(&self) -> Option<i128>
Converts the value of
self
to an i128
. If the value cannot be
represented by an i128
(i64
under the default implementation), then
None
is returned. Read moresource§fn to_usize(&self) -> Option<usize>
fn to_usize(&self) -> Option<usize>
Converts the value of
self
to a usize
. If the value cannot be
represented by a usize
, then None
is returned. Read moresource§fn to_u8(&self) -> Option<u8>
fn to_u8(&self) -> Option<u8>
Converts the value of
self
to a u8
. If the value cannot be
represented by a u8
, then None
is returned. Read moresource§fn to_u16(&self) -> Option<u16>
fn to_u16(&self) -> Option<u16>
Converts the value of
self
to a u16
. If the value cannot be
represented by a u16
, then None
is returned. Read moresource§fn to_u32(&self) -> Option<u32>
fn to_u32(&self) -> Option<u32>
Converts the value of
self
to a u32
. If the value cannot be
represented by a u32
, then None
is returned. Read moreimpl Copy for P32E2
impl Eq for P32E2
impl StructuralEq for P32E2
impl StructuralPartialEq for P32E2
Auto Trait Implementations§
impl RefUnwindSafe for P32E2
impl Send for P32E2
impl Sync for P32E2
impl Unpin for P32E2
impl UnwindSafe for P32E2
Blanket Implementations§
source§impl<T> LowerBounded for Twhere
T: Bounded,
impl<T> LowerBounded for Twhere
T: Bounded,
source§impl<T> Real for Twhere
T: Float,
impl<T> Real for Twhere
T: Float,
source§fn min_positive_value() -> T
fn min_positive_value() -> T
Returns the smallest positive, normalized value that this type can represent. Read more
source§fn round(self) -> T
fn round(self) -> T
Returns the nearest integer to a number. Round half-way cases away from
0.0
. Read moresource§fn is_sign_positive(self) -> bool
fn is_sign_positive(self) -> bool
Returns
true
if self
is positive, including +0.0
,
Float::infinity()
, and with newer versions of Rust f64::NAN
. Read moresource§fn is_sign_negative(self) -> bool
fn is_sign_negative(self) -> bool
Returns
true
if self
is negative, including -0.0
,
Float::neg_infinity()
, and with newer versions of Rust -f64::NAN
. Read moresource§fn mul_add(self, a: T, b: T) -> T
fn mul_add(self, a: T, b: T) -> T
Fused multiply-add. Computes
(self * a) + b
with only one rounding
error, yielding a more accurate result than an unfused multiply-add. Read moresource§fn log(self, base: T) -> T
fn log(self, base: T) -> T
Returns the logarithm of the number with respect to an arbitrary base. Read more
source§fn to_degrees(self) -> T
fn to_degrees(self) -> T
Converts radians to degrees. Read more
source§fn to_radians(self) -> T
fn to_radians(self) -> T
Converts degrees to radians. Read more
source§fn hypot(self, other: T) -> T
fn hypot(self, other: T) -> T
Calculate the length of the hypotenuse of a right-angle triangle given
legs of length
x
and y
. Read moresource§fn asin(self) -> T
fn asin(self) -> T
Computes the arcsine of a number. Return value is in radians in
the range [-pi/2, pi/2] or NaN if the number is outside the range
[-1, 1]. Read more
source§fn acos(self) -> T
fn acos(self) -> T
Computes the arccosine of a number. Return value is in radians in
the range [0, pi] or NaN if the number is outside the range
[-1, 1]. Read more
source§fn atan(self) -> T
fn atan(self) -> T
Computes the arctangent of a number. Return value is in radians in the
range [-pi/2, pi/2]; Read more
source§fn exp_m1(self) -> T
fn exp_m1(self) -> T
Returns
e^(self) - 1
in a way that is accurate even if the
number is close to zero. Read more