E.V.E  0.1-beta

◆ erfc_inv

eve::erfc_inv = {}
inlineconstexpr

Callable object computing the inverse of the \(\mbox{erfc}\) function.

Required header: #include <eve/function/erfc_inv.hpp>

Members Functions

Member Effect
operator() the erfc_inv operation
operator[] Construct a conditional version of current function object

auto operator()( floating_real_value auto x) const noexcept;
Definition: value.hpp:103

Parameters

x: floating real value.

Return value

Returns elementwise y such that erfc(y)==x

The result type is of the same type as the parameter. The function returns Nan outside of the interval \([0,2]\).


auto operator[]( conditional_expression auto cond ) const noexcept;

Higher-order function generating a masked version of eve::erfc_inv

Parameters

cond : conditional expression

Return value

A Callable object so that the expression erfc_inv[cond](x, ...) is equivalent to if_else(cond,erfc_inv(x, ...),x)


Supported decorators

  • eve::diff, eve::diff_1st, eve::diff_nth

    Required header: #include <eve/function/diff/erfc_inv.hpp>

    The expression diff(erfc_inv)(x) computes the derivative of the function at x.

Example

See it live on Compiler Explorer

#include <eve/function/erfc_inv.hpp>
#include <eve/wide.hpp>
#include <iostream>
int main()
{
wide_ft pf = { 0.0f, 1.0f, 1.5f, 1.75f};
std::cout
<< "---- simd" << '\n'
<< "<- pf = " << pf << '\n'
<< "-> eve::erfc_inv(pf) = " << eve::erfc_inv(pf) << '\n';
float xf = 1.0f;
float yf = 2.0f;
std::cout
<< "---- scalar" << '\n'
<< "<- xf = " << xf << '\n'
<< "-> eve::erfc_inv(xf) = " << eve::erfc_inv(xf) << '\n'
<< "<- yf = " << yf << '\n'
<< "-> eve::erfc_inv(yf) = " << eve::erfc_inv(yf) << '\n';
return 0;
}
constexpr callable_erfc_inv_ erfc_inv
Callable object computing the inverse of the function.
Definition: erfc_inv.hpp:79
Wrapper for SIMD registers.
Definition: wide.hpp:65