ln_gamma
Versione 1.0.2 (2,21 KB) da
Alexey_Kuznetsov
Computes the logarithm of the Gamma function in the entire complex plane.
This function computes the logarithm of the gamma function in the entire complex plane. The algorithm is based on approximating the log(Gamma(z)) in the half-plane Re(z)>1.5 by an algorithm from [1] (with improved coefficients obtained in [2]). This approximation is correct to 10^{-16} (though round-off errors may decrease the accuracy). The approximation in the half-plane Re(z)>1.5 is then used to compute ln(Gamma(z)) in the entire complex plane by the use of reflection formula and the functional equation.
References:
[1] A. Kuznetsov, "Computing the Barnes G-function and the gamma function in the entire complex plane," Journal of Computational and Applied Mathematics, Vol. 411, 2022, 114270. https://doi.org/10.1016/j.cam.2022.114270
[2] A. Kuznetsov, A. Mohammadioroojeh, "Approximating functions on R^+ by exponential sums", 2025, preprint, https://arxiv.org/abs/2508.19095
Cita come
Alexey_Kuznetsov (2026). ln_gamma (https://it.mathworks.com/matlabcentral/fileexchange/182573-ln_gamma), MATLAB Central File Exchange. Recuperato .
Compatibilità della release di MATLAB
Creato con
R2025b
Compatibile con qualsiasi release
Compatibilità della piattaforma
Windows macOS LinuxTag
Riconoscimenti
Ispirato: Riemann_zeta
Scopri Live Editor
Crea script con codice, output e testo formattato in un unico documento eseguibile.
