Computes the Bessel function of the first kind, \( J_0(x)=\frac1{\pi }\int _{0}^{\pi}\cos(x\sin \tau)
\,\mathrm {d} \tau \) extended to the complex plane and cayley_dickson algebras.
It is the solution of \( x^{2}y''+xy'+x^2y=0\) for which \( y(0) = 1\).
#include <kyosu/kyosu.hpp>
#include <eve/wide.hpp>
#include <iostream>
int main()
{
std::cout.precision(16);
eve::wide<double, eve::fixed<4>> z(1.0, 15.0, 40.0, 60.0);
eve::wide<double, eve::fixed<4>> z1(1.0, 2.0, 40.0, 0.0), z2(36.0, 0.5, 0.0, 40.0);
eve::wide<double, eve::fixed<8>> l(1.0, 15.0, 40.0, 60.0, eve::inf(eve::as<double>()),eve::minf(eve::as<double>()), eve::nan(eve::as<double>()), 0.0);
auto nanan =
kyosu::complex(eve::nan(eve::as<double>()), eve::nan(eve::as<double>()));
std::cout << nanan <<
" -> \n" <<
cyl_bessel_j0(nanan) << std::endl;
return 0;
}
constexpr tags::callable_complex complex
Constructs a kyosu::complex.
Definition: to_complex.hpp:70
constexpr tags::callable_quaternion quaternion
Constructs a kyosu::quaternion.
Definition: to_quaternion.hpp:72