Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members | File Members | Related Pages

math_util.hpp File Reference

contains prototypes of math utilities. More...

Include dependency graph for math_util.hpp:

Include dependency graph

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Go to the source code of this file.

Classes

class  Param
 The parameters of a probability function. More...

struct  quad_link
 Link for the list used by quadrature class quad_list. More...

class  quad_list
 The linked list used to hold the quadrature routine Simp_quad.


Functions

double Lin_Lin (double x_mid, double x_0, double y_0, double x_1, double y_1)
 Interpolates between two points as lin-lin.

double Lin_Log (double x_mid, double x_0, double y_0, double x_1, double y_1)
 Interpolates between two points as lin-log.

double Log_Lin (double x_mid, double x_0, double y_0, double x_1, double y_1)
 Interpolates between two points as log-lin.

double Log_Log (double x_mid, double x_0, double y_0, double x_1, double y_1)
 Interpolates between two points as log-log.

double maxE_loglog (double xi, double alpha)
 Determine maximum error in lin-lin interpolation of log-log data.

double c_dgamit (double a, double x)
 Incomplete gamma function.

double c_dgamma (double x)
 Gamma function.

double expint (int n, double x)
 Exponential integral function.


Variables

const double EPS = 1.0e-14


Detailed Description

Definition in file math_util.hpp.


Function Documentation

double c_dgamit double  a,
double  x
 

Parameters:
a 
x This code was translated from the Slatec library. Generalizing Euler's form of the gamma function with variable limit integrals is the definintion of the incomplete gamma function,

\[ \gamma (a,x) = \frac{ \int^x_0 t^{a-1} e^{-t} dt}{\Gamma (a) x^a } \,\,\, . \]

Definition at line 509 of file math_util.cpp.

References c_d1mach(), c_d9gmit(), c_d9lgic(), c_d9lgit(), c_dgamr(), c_dlgams(), c_dlngam(), and c_xermsg().

Referenced by one_d_Madland::g().

double c_dgamma double  x  ) 
 

Parameters:
x This is the definite integral definition of the gamma function (Euler's form),

\[ \Gamma(a) = \int_0^{\infty} t^{a-1} e^{-t} dt \,\,\,. \]

Definition at line 606 of file math_util.cpp.

References c_d1mach(), c_d9lgmc(), c_dcsevl(), c_dgamlm(), c_initds(), and c_xermsg().

Referenced by c_dgamr(), c_dlngam(), and one_d_Madland::one_d_Madland().

double expint int  n,
double  x
 

Parameters:
n 
x Function to return the exponential integral function,

\[ E_n (x) = \int_1^{\infty} e^{-xt} t^{-n} dt \,\,\, ( x > 0 ) \,\,\,. \]

Definition at line 896 of file math_util.cpp.

References EPS, EULER, FPMIN, MAXIT, and SevereError().

Referenced by one_d_Madland::g().

double Lin_Lin double  x_mid,
double  x_0,
double  y_0,
double  x_1,
double  y_1
 

Parameters:
x_mid the "x" position at which the interpolated "y" value is calculated
x_0 the "x" value of the left point used in the extrapolation
y_0 the "y" value of the left point used in the extrapolation
x_1 the "x" value of the right point used in the extrapolation
y_1 the "y" value of the right point used in the extrapolation
Returns the lin-lin interpolated "y" value corresponding to "x_mid" between the two points (x_0,y_0) and (x_1,y_1).

Definition at line 99 of file math_util.cpp.

References SevereError().

Referenced by one_d_Legendre::list_interp(), one_d_Madland::list_interp(), one_d_Watt::list_interp(), one_d_Maxwell::list_interp(), and one_d_evap::list_interp().

double Lin_Log double  x_mid,
double  x_0,
double  y_0,
double  x_1,
double  y_1
 

Parameters:
x_mid the "x" position at which the interpolated "y" value is calculated
x_0 the "x" value of the left point used in the extrapolation
y_0 the "y" value of the left point used in the extrapolation
x_1 the "x" value of the right point used in the extrapolation
y_1 the "y" value of the right point used in the extrapolation
Returns the lin-log interpolated "y" value corresponding to "x_mid" between the two points (x_0,y_0) and (x_1,y_1).

Definition at line 132 of file math_util.cpp.

References pastenum(), and SevereError().

Referenced by one_d_Legendre::list_interp(), one_d_Madland::list_interp(), one_d_Watt::list_interp(), one_d_Maxwell::list_interp(), one_d_evap::list_interp(), and one_d_table::list_interp().

double Log_Lin double  x_mid,
double  x_0,
double  y_0,
double  x_1,
double  y_1
 

Parameters:
x_mid the "x" position at which the interpolated "y" value is calculated
x_0 the "x" value of the left point used in the extrapolation
y_0 the "y" value of the left point used in the extrapolation
x_1 the "x" value of the right point used in the extrapolation
y_1 the "y" value of the right point used in the extrapolation
Returns the log-lin interpolated "y" value corresponding to "x_mid" between the two points (x_0,y_0) and (x_1,y_1).

Definition at line 110 of file math_util.cpp.

References pastenum(), and SevereError().

Referenced by one_d_Legendre::list_interp(), one_d_Madland::list_interp(), one_d_Watt::list_interp(), one_d_Maxwell::list_interp(), one_d_evap::list_interp(), and one_d_table::list_interp().

double Log_Log double  x_mid,
double  x_0,
double  y_0,
double  x_1,
double  y_1
 

Parameters:
x_mid the "x" position at which the interpolated "y" value is calculated
x_0 the "x" value of the left point used in the extrapolation
y_0 the "y" value of the left point used in the extrapolation
x_1 the "x" value of the right point used in the extrapolation
y_1 the "y" value of the right point used in the extrapolation
Returns the log-log interpolated "y" value corresponding to "x_mid" between the two points (x_0,y_0) and (x_1,y_1).

Definition at line 162 of file math_util.cpp.

References SevereError().

Referenced by one_d_Legendre::list_interp(), one_d_Madland::list_interp(), one_d_Watt::list_interp(), one_d_Maxwell::list_interp(), and one_d_evap::list_interp().

double maxE_loglog double  xi,
double  alpha
 

This routine is used in linear interpolation of loglog data. It determines the maximum error for linear interpolation of $ x^\alpha $ on the interval $ 1 < x < x_i $.

Definition at line 188 of file math_util.cpp.

References SevereError().

Referenced by dd_list::LogLog_2_LinLin().


Variable Documentation

const double EPS = 1.0e-14
 

Definition at line 46 of file math_util.hpp.


Generated on Thu Sep 7 10:34:58 2006 for fete -- From ENDFB6 To ENDL by doxygen 1.3.4