This is an automated email from the git hooks/post-receive script. ppm-guest pushed a commit to annotated tag v0.11 in repository libmath-prime-util-perl.
commit f440ed15d071cdfc844fce29be344c347aac62dc Author: Dana Jacobsen <d...@acm.org> Date: Wed Jul 18 09:33:21 2012 -0500 Change exp2 to pow, and incorporate inverse into exponent --- util.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/util.c b/util.c index a5d923a..1e8a152 100644 --- a/util.c +++ b/util.c @@ -768,14 +768,11 @@ static double evaluate_zeta(double x) { */ /* term = 1.0; y = term-c; t = sum+y; c = (t-sum)-y; sum = t; */ - term = 1.0/exp2(x); y = term-c; t = sum+y; c = (t-sum)-y; sum = t; + term = pow(2, -x); y = term-c; t = sum+y; c = (t-sum)-y; sum = t; for (k = 3; k <= 100000; k++) { if (fabs(term) < tol) break; - if (k == 4) term = 1.0 / exp2(2*x); - else if (k == 8) term = 1.0 / exp2(4*x); - else if (k == 16) term = 1.0 / exp2(8*x); - else term = 1.0 / pow(k, x); + term = pow(k, -x); y = term-c; t = sum+y; c = (t-sum)-y; sum = t; } return sum; -- Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libmath-prime-util-perl.git _______________________________________________ Pkg-perl-cvs-commits mailing list Pkg-perl-cvs-commits@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-perl-cvs-commits