[pypy-svn] r76101 - pypy/branch/fast-forward/pypy/module/math
benjamin at codespeak.net
benjamin at codespeak.net
Sat Jul 10 20:39:06 CEST 2010
Author: benjamin
Date: Sat Jul 10 20:39:05 2010
New Revision: 76101
Modified:
pypy/branch/fast-forward/pypy/module/math/interp_math.py
Log:
must go backwards here
Modified: pypy/branch/fast-forward/pypy/module/math/interp_math.py
==============================================================================
--- pypy/branch/fast-forward/pypy/module/math/interp_math.py (original)
+++ pypy/branch/fast-forward/pypy/module/math/interp_math.py Sat Jul 10 20:39:05 2010
@@ -559,6 +559,7 @@
13339535.0, 2637558.0, 357423.0, 32670.0, 1925.0, 66.0, 1.0]
LANCZOS_N = len(_lanczos_den_coeffs)
_lanczos_n_iter = unroll.unrolling_iterable(range(LANCZOS_N))
+_lanczos_n_iter_back = unroll.unrolling_iterable(range(LANCZOS_N - 1, -1, -1))
_gamma_integrals = [
1.0, 1.0, 2.0, 6.0, 24.0, 120.0, 720.0, 5040.0, 40320.0, 362880.0,
3628800.0, 39916800.0, 479001600.0, 6227020800.0, 87178291200.0,
@@ -571,7 +572,7 @@
den = 0.
assert x > 0.
if x < 5.:
- for i in _lanczos_n_iter:
+ for i in _lanczos_n_iter_back:
num = num * x + _lanczos_num_coeffs[i]
den = den * x + _lanczos_den_coeffs[i]
else:
More information about the Pypy-commit
mailing list