nag_scaled_log_gamma (s14ahc) calculates an approximate value for
, where
. This is a variant of the
function (see also
nag_log_gamma (s14abc)), which avoids rounding problems for very large arguments by computing
with the Stirling approximation factored out.
For
, the value
is undefined; nag_scaled_log_gamma (s14ahc) returns zero and exits with
NE_REAL_ARG_LE.
nag_scaled_log_gamma (s14ahc) has been designed to produce full relative accuracy for all input arguments. Empirical results obtained by comparing with multiprecision software confirm this.
nag_scaled_log_gamma (s14ahc) is not threaded in any implementation.
None.