Evaluate a function in binary64 with correctly rounded result.
Parameter 1 is the function’s name in GNU Octave, Parameter 2 is the rounding direction (0: towards zero, 0.5: towards nearest and ties to even, +inf: towards positive infinity, -inf: towards negative infinity). Parameters 3 and (possibly) 4 and 5 are operands to the function.
Evaluated on arrays, the function will be applied element-wise. For binary functions broadcasting is performed where needed. For ternary functions no broadcasting is performed.
The result is guaranteed to be correctly rounded. That is, the function is evaluated with (virtually) infinite precision and the exact result is approximated with a binary64 number using the desired rounding direction.
mpfr_function_d ('plus', -inf, 1, eps / 2) == 1 ⇒ 1 mpfr_function_d ('plus', +inf, 1, eps / 2) == 1 + eps ⇒ 1
See also: crlibm_function.
Package: interval