E.V.E
v2022.03.00

◆ airy_ai

eve::airy_ai = {}
inlineconstexpr

Computes the airy function \( Ai(x)\).

It is the solution of the differential equation \(y''-xy = 0\) satisfying \(Ai(0) = \frac1{3^{2/3}\Gamma(2/3)}\) and \(Ai'(0) =\frac1{3^{1/3}\Gamma(1/3)}\).

Defined in header

#include <eve/module/bessel.hpp>

Callable Signatures

namespace eve
{
template< eve::floating_real_value T >
T airy_ai(T x) noexcept;
}
constexpr callable_airy_ai_ airy_ai
Computes the airy function .
Definition: airy_ai.hpp:53
Definition: all_of.hpp:22

Parameters

  • x : real floating argument.

Return value

The value of \( \displaystyle Ai(x)=\frac1{\pi} \int_{0}^{\infty}\cos \left( \frac{t^3}{3}+xt \right) \,dt\) is returned.

Example

#include <eve/module/bessel.hpp>
#include <eve/wide.hpp>
#include <iostream>
int main()
{
wide_ft pf = {0.5, -1.5, 0.1, -1.0, 19.0, 25.0, 21.5, 10000.0};
std::cout << "---- simd" << '\n'
<< "<- pf = " << pf << '\n'
<< "-> airy_ai(pf) = " << eve::airy_ai(pf) << '\n'
;
double xd = -1.0;
std::cout << "---- scalar" << '\n'
<< "<- xd = " << xd << '\n'
<< "-> airy_ai(xd) = " << eve::airy_ai(xd) << '\n';
return 0;
}
Wrapper for SIMD registers.
Definition: wide.hpp:65