Trait num_traits::ops::mul_add::MulAdd   
                   
                       [−]
                   
               [src]
The fused multiply-add operation. Computes (self * a) + b with only one rounding error. This produces a more accurate result with better performance than a separate multiplication operation followed by an add.
Note that A and B are Self by default, but this is not mandatory.
Example
use std::f32; let m = 10.0_f32; let x = 4.0_f32; let b = 60.0_f32; // 100.0 let abs_difference = (m.mul_add(x, b) - (m*x + b)).abs(); assert!(abs_difference <= f32::EPSILON);
Associated Types
type Output
The resulting type after applying the fused multiply-add.
Required Methods
Implementations on Foreign Types
impl MulAdd<f32, f32> for f32[src] 
impl MulAdd<f32, f32> for f32impl MulAdd<f64, f64> for f64[src] 
impl MulAdd<f64, f64> for f64impl MulAdd for isize[src] 
impl MulAdd for isizeimpl MulAdd for usize[src] 
impl MulAdd for usizeimpl MulAdd for i8[src] 
impl MulAdd for i8impl MulAdd for u8[src] 
impl MulAdd for u8impl MulAdd for i16[src] 
impl MulAdd for i16impl MulAdd for u16[src] 
impl MulAdd for u16impl MulAdd for i32[src] 
impl MulAdd for i32impl MulAdd for u32[src] 
impl MulAdd for u32impl MulAdd for i64[src] 
impl MulAdd for i64impl MulAdd for u64[src] 
impl MulAdd for u64impl MulAdd for i128[src] 
impl MulAdd for i128impl MulAdd for u128[src] 
        impl MulAdd for u128