doc.rust-lang.org
pub fn tanh(self) -> f32
Hyperbolic tangent function.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn tan(self) -> f32
Computes the tangent of a number (in radians).
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn sqrt(self) -> f32
Returns the square root of a number.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn sinh(self) -> f32
Hyperbolic sine function.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn sin_cos(self) -> (f32, f32)
Simultaneously computes the sine and cosine of the number, x. Returns (sin(x), cos(x)).
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn sin(self) -> f32
Computes the sine of a number (in radians).
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn round_ties_even(self) -> f32
Returns the nearest integer to a number. Rounds half-way cases to the number with an even least significant digit.
method
std
Stable since 1.77.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn round(self) -> f32
Returns the nearest integer to self. If a value is half-way between two integers, round away from 0.0.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn rem_euclid(self, rhs: f32) -> f32
Calculates the least nonnegative remainder of self when divided by rhs.
method
std
Stable since 1.38.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn powi(self, n: i32) -> f32
Raises a number to an integer power.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn powf(self, n: f32) -> f32
Raises a number to a floating point power.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn mul_add(self, a: f32, b: f32) -> f32
Fused multiply-add. Computes (self * a) + b with only one rounding error, yielding a more accurate result than an unfused multiply-add.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn log2(self) -> f32
Returns the base 2 logarithm of the number.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn log10(self) -> f32
Returns the base 10 logarithm of the number.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn log(self, base: f32) -> f32
Returns the logarithm of the number with respect to an arbitrary base.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn ln_1p(self) -> f32
Returns ln(1+n) (natural logarithm) more accurately than if the operations were performed separately.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn ln(self) -> f32
Returns the natural logarithm of the number.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub fn hypot(self, other: f32) -> f32
Compute the distance between the origin and a point (x, y) on the Euclidean plane. Equivalently, compute the length of the hypotenuse of a right-angle triangle with other sides having length x.abs() and y.abs().
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn fract(self) -> f32
Returns the fractional part of self.
method
std
Stable since 1.0.0
Version 1.100.0-nightly
doc.rust-lang.org
pub const fn floor(self) -> f32
Returns the largest integer that is less than or equal to self.
method
std
Stable since 1.0.0
Version 1.100.0-nightly