Math Library Routines#

The following mathematical functions are available:

  • acosq: arc cosine function

  • acoshq: inverse hyperbolic cosine function

  • asinq: arc sine function

  • asinhq: inverse hyperbolic sine function

  • atanq: arc tangent function

  • atanhq: inverse hyperbolic tangent function

  • atan2q: arc tangent function

  • cbrtq: cube root function

  • ceilq: ceiling value function

  • copysignq: copy sign of a number

  • coshq: hyperbolic cosine function

  • cosq: cosine function

  • erfq: error function

  • erfcq: complementary error function

  • exp2q: base 2 exponential function

  • expq: exponential function

  • expm1q: exponential minus 1 function

  • fabsq: absolute value function

  • fdimq: positive difference function

  • finiteq: check finiteness of value

  • floorq: floor value function

  • fmaq: fused multiply and add

  • fmaxq: determine maximum of two values

  • fminq: determine minimum of two values

  • fmodq: remainder value function

  • frexpq: extract mantissa and exponent

  • hypotq: Eucledian distance function

  • ilogbq: get exponent of the value

  • isinfq: check for infinity

  • isnanq: check for not a number

  • issignalingq: check for signaling not a number

  • j0q: Bessel function of the first kind, first order

  • j1q: Bessel function of the first kind, second order

  • jnq: Bessel function of the first kind, {n}-th order

  • ldexpq: load exponent of the value

  • lgammaq: logarithmic gamma function

  • llrintq: round to nearest integer value

  • llroundq: round to nearest integer value away from zero

  • logbq: get exponent of the value

  • logq: natural logarithm function

  • log10q: base 10 logarithm function

  • log1pq: compute natural logarithm of the value plus one

  • log2q: base 2 logarithm function

  • lrintq: round to nearest integer value

  • lroundq: round to nearest integer value away from zero

  • modfq: decompose the floating-point number

  • nanq: return quiet NaN

  • nearbyintq: round to nearest integer

  • nextafterq: next representable floating-point number

  • powq: power function

  • remainderq: remainder function

  • remquoq: remainder and part of quotient

  • rintq: round-to-nearest integral value

  • roundq: round-to-nearest integral value, return {__float128}

  • scalblnq: compute exponent using {FLT_RADIX}

  • scalbnq: compute exponent using {FLT_RADIX}

  • signbitq: return sign bit

  • sincosq: calculate sine and cosine simultaneously

  • sinhq: hyperbolic sine function

  • sinq: sine function

  • sqrtq: square root function

  • tanq: tangent function

  • tanhq: hyperbolic tangent function

  • tgammaq: true gamma function

  • truncq: round to integer, towards zero

  • y0q: Bessel function of the second kind, first order

  • y1q: Bessel function of the second kind, second order

  • ynq: Bessel function of the second kind, {n}-th order

  • cabsq: complex absolute value function

  • cargq: calculate the argument

  • cimagq: imaginary part of complex number

  • crealq: real part of complex number

  • cacoshq: complex arc hyperbolic cosine function

  • cacosq: complex arc cosine function

  • casinhq: complex arc hyperbolic sine function

  • casinq: complex arc sine function

  • catanhq: complex arc hyperbolic tangent function

  • catanq: complex arc tangent function

  • ccosq: complex cosine function

  • ccoshq: complex hyperbolic cosine function

  • cexpq: complex exponential function

  • cexpiq: computes the exponential function of ā€˜iā€™ times a real value

  • clogq: complex natural logarithm

  • clog10q: complex base 10 logarithm

  • conjq: complex conjugate function

  • cpowq: complex power function

  • cprojq: project into Riemann Sphere

  • csinq: complex sine function

  • csinhq: complex hyperbolic sine function

  • csqrtq: complex square root

  • ctanq: complex tangent function

  • ctanhq: complex hyperbolic tangent function