summaryrefslogtreecommitdiff
path: root/src/zeta.c
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2017-02-17 12:54:47 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2017-02-17 12:54:47 +0000
commit342e2a04e9a144061acc7f5b3aa526a74c0d89d5 (patch)
tree55f0eb088b309f682f9bc15227041f5e6ff6c66e /src/zeta.c
parentd5f51c36caf26d144806c3ea7dfd89171e35aad1 (diff)
downloadmpfr-342e2a04e9a144061acc7f5b3aa526a74c0d89d5.tar.gz
[src/zeta.c] mpfr_reflection_overflow: reverted r11322 as the rounding
direction was correct; it was a comment that was incorrect, now fixed. git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@11323 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'src/zeta.c')
-rw-r--r--src/zeta.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/zeta.c b/src/zeta.c
index 55479a0c5..950ab718f 100644
--- a/src/zeta.c
+++ b/src/zeta.c
@@ -352,8 +352,8 @@ mpfr_reflection_overflow (mpfr_t z, mpfr_t s1, const mpfr_t s, mpfr_t y,
MPFR_ASSERTD (rnd == MPFR_RNDD || rnd == MPFR_RNDU);
- /* Since log(|sin(Pi*s/2)|) <= 0, we want to round zeta(1-s) upward
- and log(|sin(Pi*s/2)|) downward. */
+ /* Since log is increasing, we want lower bounds on |sin(Pi*s/2)| and
+ zeta(1-s). */
mpz_init (sint);
mpfr_get_z (sint, s, MPFR_RNDD); /* sint = floor(s) */
/* We first compute a lower bound of |sin(Pi*s/2)|, which is a periodic
@@ -402,7 +402,7 @@ mpfr_reflection_overflow (mpfr_t z, mpfr_t s1, const mpfr_t s, mpfr_t y,
}
mpz_clear (sint);
/* now y <= |sin(Pi*s/2)| when rnd=RNDD, y >= |sin(Pi*s/2)| when rnd=RNDU */
- mpfr_zeta_pos (z, s1, MPFR_INVERT_RND(rnd)); /* zeta(1-s) rounded upward */
+ mpfr_zeta_pos (z, s1, rnd); /* zeta(1-s) */
mpfr_mul (z, z, y, rnd);
/* now z <= |sin(Pi*s/2)|*zeta(1-s) */
mpfr_log (z, z, rnd);