BetaFn


BetaFn(a, b)

The complete beta function, defined as:

[math]\displaystyle{ BetaFn(a,b) = \int_0^1 x^{a-1} (1-x)^{b-1} dx }[/math]

The following relationship exists between the BetaFn and the GammaFn:

BetaFn(a,b) = GammaFn(a) * GammaFn(b) / GammaFn(a+b)

Numeric considerations

For very large values of a and b, the result underflow, so that you might find it better to use Ln(BetaFn(a,b)). However, when computing the log-beta function, you should compute it using:

LGamma(a) + LGamma(b) - LGamma(a+b)

See Also

Comments


You are not allowed to post comments.