/* deint.c -- integration of function by double exponential transform * from Applied Numerical Methods with Software, by Nakamura. * * (C) 2001, C. Bond. All rights reserved. */ #include #include #include /*'gaus_integrate' function comes from: http://finance.bi.no/~bernt/gcc_prog/recipes/recipes/node23.html*/ double gaus_integrate_old(double z) { double ret=1.; if (z>6.0) { cout <<"OVERFLOW!"<=0.) { if (z<=3) { ret=value[int(500.*z)]; } else { ret=1.; } } else { if (z>=-3) { ret=1.-value[int(-500.*z)]; } // else { // ret=0.; //} } // for cross check: //if (fabs(ret-gaus_integrate_old(z))>0.002) { // cout<<"z: "<