Skip to content

Commit 1822b27

Browse files
authored
typo
1 parent 3ac6136 commit 1822b27

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/gamma.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@ function gamma(_x::Float64)
99
end
1010
if x > 11.5
1111
w = inv(x)
12-
s = (
12+
coefs = (1.0,
1313
8.333333333333331800504e-2, 3.472222222230075327854e-3, -2.681327161876304418288e-3, -2.294719747873185405699e-4,
1414
7.840334842744753003862e-4, 6.989332260623193171870e-5, -5.950237554056330156018e-4, -2.363848809501759061727e-5,
1515
7.147391378143610789273e-4
1616
)
17-
w = muladd(w, evalpoly(w, s), 1.0)
17+
w = evalpoly(w, coefs)
1818
# avoid overflow
1919
v = x ^ muladd(0.5, x, -0.25)
2020
res = SQ2PI(T) * v * (v / exp(x)) * w

0 commit comments

Comments
 (0)