Computes the elliptic integrals of the first kind : \(\mathbf{F}(\phi, k) = \int_0^{\phi} \frac{\mathrm{d}t}{\sqrt{1-k^2\sin^2 t}}\) and \(\mathbf{K}(k) = \int_0^{\pi/2} \frac{\mathrm{d}t}{\sqrt{1-k^2\sin^2 t}}\).
Be aware that as \(\pi/2\) is not exactly represented by floating point values the result of the incomplete function with a \(\phi\) floating point value representing \(\pi/2\) can differ a lot with the result of the complete call.
{
template< eve::floating_ordered_value T >
template< eve::floating_ordered_value T, eve::floating_ordered_value U >
}
constexpr callable_ellint_1_ ellint_1
Computes the elliptic integrals of the first kind : and .
Definition: ellint_1.hpp:66
constexpr callable_phi_ phi
Callable object computing the golden ratio : .
Definition: phi.hpp:49
typename eve::detail::common_value_impl< void, Ts... >::type common_value_t
Computes the SIMD-compatible common type between all Ts.
Definition: common_value.hpp:50
#include <eve/module/elliptic.hpp>
#include <eve/wide.hpp>
#include <iostream>
int
main()
{
wide_ft pf = {1.0f, 0.0f, 0.75f, 0.5f};
std::cout << "---- simd" << '\n'
<< "<- pf = " << pf << '\n'
float xf = 0.1f;
std::cout << "---- scalar" << '\n'
<< "<- xf = " << xf << '\n'
wide_ft
phi = {0.2f, 1.0e-30f, 0.5f, 0.0f};
std::cout << "---- simd" << '\n'
<<
"<- phi = " <<
phi <<
'\n'
return 0;
}
constexpr callable_pio_2_ pio_2
Callable object computing the constant .
Definition: pio_2.hpp:49
Lightweight type-wrapper.
Definition: as.hpp:29
Wrapper for SIMD registers.
Definition: wide.hpp:65