Woolz Image Processing  Version 1.8.3
AlgGamma

Files

file  AlgGamma.c
 Functions for computing gamma and incomplete gamma functions.
 

Functions

double AlgGammaLog (double x, AlgError *dstErr)
 Computes the log gamma function log(Gamma(x)), ie exp(AlgGammaLog(n + 1)) = n!. This function is based on the function gammln(): Press W. H., Teukolsky S. A., Vetterling W. T. and Flannery B. P, Numerical Recipies in C, 1992, CUP. More...
 
double AlgGammaP (double a, double x, AlgError *dstErr)
 Computes the incomplete gamma function P(a,x), which has the limiting values P(a,0) = 0, P(a, oo) = 1.. This function is based on the function gammp(): Press W. H., Teukolsky S. A., Vetterling W. T. and Flannery B. P, Numerical Recipies in C, 1992, CUP. More...
 

Detailed Description

Function Documentation

◆ AlgGammaLog()

double AlgGammaLog ( double  x,
AlgError dstErr 
)

Computes the log gamma function log(Gamma(x)), ie exp(AlgGammaLog(n + 1)) = n!. This function is based on the function gammln(): Press W. H., Teukolsky S. A., Vetterling W. T. and Flannery B. P, Numerical Recipies in C, 1992, CUP.

Returns
Log of gamma function value.
Parameters
xGiven value.
dstErrDestination ptr for error code, may be NULL.

References ALG_ERR_FUNC, and ALG_ERR_NONE.

◆ AlgGammaP()

double AlgGammaP ( double  a,
double  x,
AlgError dstErr 
)

Computes the incomplete gamma function P(a,x), which has the limiting values P(a,0) = 0, P(a, oo) = 1.. This function is based on the function gammp(): Press W. H., Teukolsky S. A., Vetterling W. T. and Flannery B. P, Numerical Recipies in C, 1992, CUP.

Returns
Incomplete gamma function value.
Parameters
aIncomplete gamma fn parameter.
xIncomplete gamma fn parameter.
dstErrDestination ptr for error code, may be NULL.

References ALG_ERR_FUNC, and ALG_ERR_NONE.

Referenced by AlgLinearFit1D(), and AlgLinearFitIdx1D().