|
dspp
Digital Signal Processing library for C++
|
Digital Signal Processing library for C++. More...
Namespaces | |
| FFT | |
| Fast Fourier/Cosine/Sine Transforms. | |
| window | |
| Window functions (also known as an apodization functions or tapering functions). | |
Classes | |
| struct | Mixer |
Functions | |
| template<typename T = double> | |
| constexpr T | pi () |
| 3.141592653589793238462643383279502884e+00 | |
| template<typename T = double> | |
| constexpr T | two_pi () |
| 6.283185307179586476925286766559005768e+00 | |
| template<typename T1 , typename T2 , typename T3 > | |
| typename::std::enable_if < ::std::is_same< double, decltype(T1()+T2()+T3())> ::value, decltype(T1()+T2()+T3())> ::type | fmac (T1 x, T2 y, T3 z) |
| Fast fused multiply and accumulate. Returns x * y + z. More... | |
| template<typename T1 , typename T2 , typename T3 > | |
| typename::std::enable_if < ::std::is_same< float, decltype(T1()+T2()+T3())> ::value, decltype(T1()+T2()+T3())> ::type | fmac (T1 x, T2 y, T3 z) |
| Fast fused multiply and accumulate. Returns x * y + z. | |
Digital Signal Processing library for C++.
|
inline |
Fast fused multiply and accumulate. Returns x * y + z.
A fused multiply and accumulate avoids the rounding that would normally happen after multiplication. This offers greater precision. Some microprocessors do not have an FMA instruction so ::std::fma() will be significantly slower than (x*y+z). Most DSP cases prefer speed over precision which this function ensures by using (x*y+z) on processors without an FMA instruction. If you require precision over speed, use ::std::fma() instead.
1.8.7