log_gamma(3f) - [FORTRAN:INTRINSIC:MATHEMATICS] Logarithm of the Gamma function
x = log_gamma(x)
log_gamma(x) computes the natural logarithm of the absolute value of the [[Gamma function]].
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.
Sample program:
program demo_log_gamma implicit none real :: x = 1.0 x = log_gamma(x) ! returns 0.0 end program demo_log_gamma
[[Fortran 2008]] and later
[[Elemental function]]
Gamma function: gamma(3)
log_gamma (3) | March 11, 2021 |