XLPack 7.0
XLPack Numerical Library (Excel VBA) Reference Manual
Loading...
Searching...
No Matches

◆ Lngams_sub()

Sub Lngams_sub ( Ret As  Double,
X As  Double,
Sign As  Long,
Optional Info As  Long 
)

Logarithm of gamma function ln|Γ(x)| and sign of gamma function (Subroutine version)

Purpose
Computes the logarithm of the gamma function ln|Γ(x)| at x, where x is not 0, -1, -2, ..., and the sign of the gamma function Γ(x).
Parameters
[out]RetLogarithm of the gamma function ln|Γ(x)|.
[in]XArgument x (X <> 0 and X <> negative integer)
(If X < 0, computes the real part = ln(|Γ(X)|))
[out]SignSign of gamma function.
= -1: Negative.
= 1: Positive.
[out]info= 0: Successful exit.
= -1: The argument X had an illegal value. (X = 0 or negative integer)
= 1: Floating point range error.
Reference
boost/math/special_functions