SpecFuncCephes.h

Go to the documentation of this file.
00001 // special functions taken from Cephes library 
00002 //  see:  http://www.netlib.org/cephes
00003 // 
00004 // Copyright 1985, 1987, 2000 by Stephen L. Moshier
00005 // 
00006 //  granted permission from the author to be used in MathCore
00007 //  
00008 
00009 
00010 
00011 
00012 #ifndef ROOT_Math_SpecFunCephes
00013 #define ROOT_Math_SpecFunCephes
00014 
00015 namespace ROOT { 
00016    namespace Math { 
00017 
00018       namespace Cephes { 
00019 
00020 
00021 //---
00022 /* the machine roundoff error */
00023 #define kMACHEP  1.11022302462515654042363166809e-16
00024 
00025 /* largest argument for TMath::Exp() */
00026 #define kMAXLOG  709.782712893383973096206318587
00027 
00028 /* smallest argument for TMath::Exp() without underflow */
00029 #define kMINLOG  -708.396418532264078748994506896
00030 
00031 /* the maximal number that pow(x,x-0.5) has no overflow */
00032 /* we use a (very) conservative portable bound          */
00033 #define kMAXSTIR  108.116855767857671821730036754
00034 
00035 #define kMAXLGM 2.556348e305
00036 
00037 
00038 /** 
00039     incomplete complementary gamma function
00040  *  igamc(a, x) = 1 - igam(a, x)
00041 */
00042 double igamc( double a, double x );
00043 
00044 /* incomplete gamma function*/
00045 double  igam( double a, double x );
00046 
00047 /* Logarithm of gamma function */
00048 double lgam( double x );
00049 
00050 /* gamma function*/
00051 double gamma( double x );
00052 
00053 /* beta function*/
00054 double beta(double z, double w);
00055 
00056 /* evaluation of incomplete beta */
00057 double incbet( double aa, double bb, double xx );
00058 
00059 /* Continued fraction expansion #1
00060  * for incomplete beta integral
00061  * used when xx < (aa-1)/(aa+bb-2)
00062  * (and bb*xx > 1 or xx > 0.95) 
00063 */
00064 double incbcf( double a, double b, double x );
00065 
00066 
00067 /* Continued fraction expansion #2
00068  * for incomplete beta integral
00069  * used when xx > (aa-1)/(aa+bb-2)
00070  * (and bb*xx > 1 or xx > 0.95) 
00071  */
00072 double incbd( double a, double b, double x );
00073 
00074 
00075 /* Power series for incomplete beta integral.
00076    Use when b*x is small and x not too close to 1.  */
00077 
00078 double pseries( double a, double b, double x );
00079 
00080 
00081 /* error function */
00082 double erf( double a );
00083 
00084 /* complementary error function */
00085 double erfc( double a );
00086 
00087 
00088 // inverse function
00089 
00090 /* normal quantile */ 
00091 double ndtri (double y); 
00092 
00093 /* normal quantile */ 
00094 double ndtri (double y); 
00095 
00096 /* inverse of incomplete gamma */ 
00097 double igami (double a, double y); 
00098 
00099 /* inverse of incomplete beta */ 
00100 double incbi (double a, double b, double y); 
00101 
00102 
00103 } // end namespace Cephes
00104 
00105 /* routines for efficient polynomial evaluation*/
00106 double Polynomialeval(double x, double* a, unsigned int N);
00107 double Polynomial1eval(double x, double* a, unsigned int N);
00108 
00109 
00110 } // end namespace Math
00111 } // end namespace ROOT
00112 
00113 
00114 #endif /* SpecFun */
00115 

Generated on Tue Jul 5 14:34:26 2011 for ROOT_528-00b_version by  doxygen 1.5.1