JPL Spatial
Sound spatialization and propagation library
Loading...
Searching...
No Matches
JPL::Math::Detail Namespace Reference

Square Root. More...

Functions

template<std::floating_point T>
constexprQNan () noexcept
 constexpr-friendly quiet NaN (IEEE-754 only)
 
template<std::floating_point T>
constexprInvSqrtInitialGuess (T x) noexcept
 
template<std::floating_point T, int NR>
constexprInvSqrtNewtonRefine (T x, T y) noexcept
 Scalar NR on inverse sqrt.
 
template<std::floating_point T, int NR>
constexprSqrtConstevalFallback (T x) noexcept
 Pure constexpr fallback sqrt using inverse-sqrt NR.
 

Detailed Description

Square Root.

Function Documentation

◆ InvSqrtInitialGuess()

template<std::floating_point T>
constexpr T JPL::Math::Detail::InvSqrtInitialGuess ( x)
constexprnoexcept

Initial guess for invsqrt (constexpr-friendly):

  • float: use the classic "Quake" bit trick.

◆ InvSqrtNewtonRefine()

template<std::floating_point T, int NR>
constexpr T JPL::Math::Detail::InvSqrtNewtonRefine ( x,
y 
)
constexprnoexcept

Scalar NR on inverse sqrt.

◆ QNan()

template<std::floating_point T>
constexpr T JPL::Math::Detail::QNan ( )
constexprnoexcept

constexpr-friendly quiet NaN (IEEE-754 only)

◆ SqrtConstevalFallback()

template<std::floating_point T, int NR>
constexpr T JPL::Math::Detail::SqrtConstevalFallback ( x)
constexprnoexcept

Pure constexpr fallback sqrt using inverse-sqrt NR.