Created
March 12, 2012 23:30
-
-
Save benanne/2025406 to your computer and use it in GitHub Desktop.
lngamma in theano, windschitl
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import numpy as np | |
| import theano | |
| import theano.tensor as T | |
| def log_gamma_windschitl(z): | |
| return 0.5 * (T.log(2*np.pi) - T.log(z) + z * (2 * T.log(z) - 2 + T.log(z * T.sinh(1/z) + 1 / (810*(z**6))))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment