32double kSqrt2 = 1.4142135623730950488016887242097;
33double kPi = 3.14159265358979323846;
34double kEulerGamma = 0.577215664901532860606512090082402431042;
77 double sum, factorial = 1,
n = 1;
78 double term = 1, x_factor =
x *
x *
x *
x * 0.0625;
83 factorial = 4 *
n *
n * (2 *
n - 1) * (2 *
n - 1);
84 term *= (-1) / factorial * x_factor;
136 double sum, factorial = 1,
n = 1;
137 double term =
x *
x * 0.25, x_factor = term * term;
142 factorial = 4 *
n *
n * (2 *
n + 1) * (2 *
n + 1);
143 term *= (-1) / factorial * x_factor;
200 double term = 1, x_factor =
x *
x *
x *
x * 0.0625;
201 double factorial = 1, harmonic = 0,
n = 1,
sum;
203 if(
x < 0) delta =
kPi;
208 factorial = 4 *
n *
n * (2 *
n - 1) * (2 *
n - 1);
209 term *= (-1) / factorial * x_factor;
210 harmonic += 1 / (2 *
n - 1 ) + 1 / (2 *
n);
211 sum += term * harmonic;
267 double term =
x *
x * 0.25, x_factor = term * term;
268 double factorial = 1, harmonic = 1,
n = 1,
sum;
270 if(
x < 0) delta =
kPi;
275 factorial = 4 *
n *
n * (2 *
n + 1) * (2 *
n + 1);
276 term *= (-1) / factorial * x_factor;
277 harmonic += 1 / (2 *
n) + 1 / (2 *
n + 1);
278 sum += term * harmonic;
319 double sum, factorial = 1,
n = 1;
320 double term = -
x *
x *
x * 0.0625, x_factor = - term *
x;
325 factorial = 4 *
n * (
n + 1) * (2 *
n + 1) * (2 *
n + 1);
326 term *= (-1) / factorial * x_factor;
364 double sum, factorial = 1,
n = 1;
365 double term =
x * 0.5, x_factor =
x *
x *
x *
x * 0.0625;
370 factorial = 4 *
n *
n * (2 *
n - 1) * (2 *
n + 1);
371 term *= (-1) * x_factor / factorial;
409 double term = -
x *
x *
x * 0.0625, x_factor = - term *
x;
410 double factorial = 1, harmonic = 1.5,
n = 1,
sum;
412 if(
x < 0) delta =
kPi;
417 factorial = 4 *
n * (
n + 1) * (2 *
n + 1) * (2 *
n + 1);
418 term *= (-1) / factorial * x_factor;
419 harmonic += 1 / (2 *
n + 1 ) + 1 / (2 *
n + 2);
420 sum += term * harmonic;
457 double term = 0.5 *
x, x_factor =
x *
x *
x *
x * 0.0625;
458 double factorial = 1, harmonic = 1,
n = 1,
sum;
460 if(
x < 0) delta =
kPi;
465 factorial = 4 *
n *
n * (2 *
n - 1) * (2 *
n + 1);
466 term *= (-1) / factorial * x_factor;
467 harmonic += 1 / (2 *
n) + 1 / (2 *
n + 1);
468 sum += term * harmonic;
490 double prod = 1, x_factor = 8 *
x, factorial = 1,
n = 2;
496 prod *= (2 *
n - 1) * (2 *
n - 1);
498 term = prod / (factorial * x_factor) *
cos(0.25 *
n *
kPi);
519 double prod = 1, x_factor = 8 *
x, factorial = 1,
n = 2;
525 prod *= (2 *
n - 1) * (2 *
n - 1);
527 term = (prod / (factorial * x_factor)) *
cos(0.25 *
n *
kPi);
550 double prod = 1, x_factor = 8 *
x, factorial = 1,
n = 2;
556 prod *= (2 *
n - 1) * (2 *
n - 1);
558 term = prod / (factorial * x_factor) *
sin(0.25 *
n *
kPi);
577 double prod = 1, x_factor = 8 *
x, factorial = 1,
n = 2;
583 prod *= (2 *
n - 1) * (2 *
n - 1);
585 term = prod / (factorial * x_factor) *
sin(0.25 *
n *
kPi);
605 double value = 1 + 1 / (8 *
kSqrt2 *
x) + 1 / (256 *
x *
x) - 399 / (6144 *
kSqrt2 *
x *
x *
x);
637 double value = 1 - 1 / (8 *
kSqrt2 *
x) + 1 / (256 *
x *
x) + 399 / (6144 *
kSqrt2 *
x *
x *
x);
static double Phi(double x)
Utility function appearing in the asymptotic expansions of DKer(x) and DKei(x).
static double DBei(double x)
Calculates the first derivative of Bei(x).
static double M(double x)
Utility function appearing in the asymptotic expansions of DBer(x) and DBei(x).
static double DKer(double x)
Calculates the first derivative of Ker(x).
static double Ker(double x)
static double G1(double x)
Utility function appearing in the calculations of the Kelvin functions Bei(x) and Ber(x) (and their d...
static double DBer(double x)
Calculates the first derivative of Ber(x).
static double F2(double x)
Utility function appearing in the calculations of the Kelvin functions Kei(x) and Ker(x) (and their d...
static double Theta(double x)
Utility function appearing in the asymptotic expansions of DBer(x) and DBei(x).
static double N(double x)
Utility function appearing in the asymptotic expansions of DKer(x) and DKei(x).
static double Ber(double x)
static double F1(double x)
Utility function appearing in the calculations of the Kelvin functions Bei(x) and Ber(x) (and their d...
static double G2(double x)
Utility function appearing in the calculations of the Kelvin functions Kei(x) and Ker(x) (and their d...
static double Bei(double x)
static double DKei(double x)
Calculates the first derivative of Kei(x).
static double Kei(double x)
double beta(double x, double y)
Calculates the beta function.
Namespace for new Math classes and functions.
VecExpr< UnaryOp< Fabs< T >, VecExpr< A, T, D >, T >, T, D > fabs(const VecExpr< A, T, D > &rhs)
static const double kSqrt2
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
static uint64_t sum(uint64_t i)