Doxygen Source Code Documentation
Main Page Alphabetical List Data Structures File List Data Fields Globals Search
cdf_43.c
Go to the documentation of this file.00001 #include "cdflib.h"
00002 double dlanor(double *x)
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038 {
00039 #define dlsqpi 0.91893853320467274177e0
00040 static double coef[12] = {
00041 -1.0e0,3.0e0,-15.0e0,105.0e0,-945.0e0,10395.0e0,-135135.0e0,2027025.0e0,
00042 -34459425.0e0,654729075.0e0,-13749310575.e0,316234143225.0e0
00043 };
00044 static int K1 = 12;
00045 static double dlanor,approx,correc,xx,xx2,T2;
00046
00047
00048
00049
00050 xx = fabs(*x);
00051 if(xx < 5.0e0) ftnstop(" Argument too small in DLANOR");
00052 approx = -dlsqpi-0.5e0*xx*xx-log(xx);
00053 xx2 = xx*xx;
00054 T2 = 1.0e0/xx2;
00055 correc = devlpl(coef,&K1,&T2)/xx2;
00056 correc = dln1px(&correc);
00057 dlanor = approx+correc;
00058 return dlanor;
00059 #undef dlsqpi
00060 }