log_gamma(x) computes the natural logarithm of the absolute value of the Gamma function ().
Fortran 2008 and later
x = log_gamma(x)
x - Shall be of type real and neither zero nor a negative integer.The return value is of type real of the same kind as x.
program test_log_gamma real :: x = 1.0 x = log_gamma(x) ! returns 0.0 end program test_log_gamma Gamma function: gamma