E.V.E
v2023.02.15
Loading...
Searching...
No Matches

◆ jacobi_elliptic

auto eve::jacobi_elliptic = functor<jacobi_elliptic_t>
inlineconstexpr

Header file

#include <eve/module/elliptic.hpp>

Callable Signatures

namespace eve
{
// Regular overload
constexpr auto jacobi_elliptic(floating_value auto u, floating_value auto x) noexcept; // 1
//Semantic modifiers
constexpr auto jacobi_elliptic[modular](floating_value auto u, floating_value auto alpha) noexcept; // 1
constexpr auto jacobi_elliptic[eccentric(floating_value auto u, floating_value auto k) noexcept; // 1
constexpr auto jacobi_elliptic[threshold = tol](floating_value auto u, floating_value auto x) noexcept; // 1
// Lanes masking
constexpr auto jacobi_elliptic[conditional_expr auto c](/*any of the above overloads*/) noexcept; // 2
constexpr auto jacobi_elliptic[logical_value autolm](/*any of the above overloads*/) noexcept; // 2
}
Specifies that a type is a Conditional Expression.
Definition conditional.hpp:28
The concept floating_value<T> is satisfied if and only if T satisfies eve::value and the element type...
Definition value.hpp:116
The concept logical_value<T> is satisfied if and only if T satisfies eve::value and the element type ...
Definition value.hpp:134
constexpr auto jacobi_elliptic
elementwise_callable object computing the Jacobi's sn, cn and dn function simultaneously.
Definition jacobi_elliptic.hpp:85
EVE Main Namespace.
Definition abi.hpp:19

Parameters

Return value

  1. return a kumi::tuple containing sn``cn and dn values. Take care that the meaning of the second parameters depends on the option used (see note below).
  2. The operation is performed conditionally

External references

Example

// revision 1
#include <eve/module/elliptic.hpp>
#include <iostream>
eve::wide wf{1.0, 0.0, 0.75, 0.5};
eve::wide wphi{1.0, 1.0e-30, 0.5, 0.0};
int main(){
std::cout << "<- wf = " << wf << "\n";
std::cout << "<- wphi = " << wphi << "\n";
auto [sn, cn, dn] = eve::jacobi_elliptic(wphi, wf);
std::cout << "-> sn = " << sn << std::endl;
std::cout << "-> cn = " << cn << std::endl;
std::cout << "-> dn = " << dn << std::endl;
std::cout << "-> jacobi_elliptic(pio_2[lower], wf) = " << eve::jacobi_elliptic(eve::pio_2[eve::lower](eve::as(wphi)), wf) << '\n';
std::cout << "-> jacobi_elliptic(pio_2[upper], wf) = " << eve::jacobi_elliptic(eve::pio_2[eve::upper](eve::as(wphi)), wf) << '\n';
}
constexpr auto pio_2
Callable object computing the constant .
Definition pio_2.hpp:77
Lightweight type-wrapper.
Definition as.hpp:29
Wrapper for SIMD registers.
Definition wide.hpp:94