TBCI Numerical high perf. C++ Library 2.8.0
hyper2geom1.cpp
Go to the documentation of this file.
1
8
9#include "tbci/cplx.h"
10#include "tbci/specfun.h"
11#include <iostream>
12
23 const TBCI__ cplx<double> b,
24 const TBCI__ cplx<double> c,
25 const TBCI__ cplx<double> z)
26{
27 TBCI__ cplx<double> oldres, res, fac;
28 res = 1.0; fac = 1.0;
29 for (int n = 0; n < 120; n++) {
30 oldres = res;
31 fac *= (a+n) * (b+n) * z / ((c+n) * (n+1));
32 res += fac;
33 if (res == oldres)
34 return res;
35 }
36 STD__ cerr << "hyper2geo1: Accuracy not reached!" << STD__ endl;
37 return res;
38}
#define STD__
Definition basics.h:338
#define NAMESPACE_END
Definition basics.h:323
#define NAMESPACE_TBCI
Definition basics.h:317
#define TBCI__
Definition basics.h:332
Our own complex class.
Definition cplx.h:56
return c
Definition f_matrix.h:760
tm fac
Definition f_matrix.h:1052
F_TMatrix< T > b
Definition f_matrix.h:736
NAMESPACE_TBCI TBCI__ cplx< double > hyper2geom1(const TBCI__ cplx< double > a, const TBCI__ cplx< double > b, const TBCI__ cplx< double > c, const TBCI__ cplx< double > z)
const unsigned TMatrix< T > const Matrix< T > * a
const unsigned TMatrix< T > * res