diff options
author | zimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4> | 2004-01-22 22:30:52 +0000 |
---|---|---|
committer | zimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4> | 2004-01-22 22:30:52 +0000 |
commit | 031deac645662aea8a72a5ed0c0bf148e609e681 (patch) | |
tree | 07c68b885a0c39a228ca4b0f7f901a9117f85a9f /tests/thyperbolic.c | |
parent | 039c1c0135bac8353d17020543fe8b27f3b1937e (diff) | |
download | mpfr-031deac645662aea8a72a5ed0c0bf148e609e681.tar.gz |
added several hard-coded tests (and fixed bugs found)
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@2644 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'tests/thyperbolic.c')
-rw-r--r-- | tests/thyperbolic.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/tests/thyperbolic.c b/tests/thyperbolic.c index 12c9f9585..45080f0bd 100644 --- a/tests/thyperbolic.c +++ b/tests/thyperbolic.c @@ -1,6 +1,6 @@ /* Test file for hyperbolic function : mpfr_cosh, mpfr_sinh, mpfr_tanh, mpfr_acosh, mpfr_asinh, mpfr_atanh. -Copyright 2001, 2002, 2003 Free Software Foundation, Inc. +Copyright 2001, 2002, 2003, 2004 Free Software Foundation, Inc. This file is part of the MPFR Library. @@ -204,17 +204,17 @@ check_zero (void) static int check_INF (void) { - mpfr_t t, ch,sh,th,ach,ash,ath; + mpfr_t t, ch, sh, th, ach, ash, ath; int tester; int fail = 0; - mpfr_init2(t,200); - mpfr_init2(ch,200); - mpfr_init2(sh,200); - mpfr_init2(th,200); - mpfr_init2(ach,200); - mpfr_init2(ash,200); - mpfr_init2(ath,200); + mpfr_init2 (t, 200); + mpfr_init2 (ch, 200); + mpfr_init2 (sh, 200); + mpfr_init2 (th, 200); + mpfr_init2 (ach, 200); + mpfr_init2 (ash, 200); + mpfr_init2 (ath, 200); MPFR_SET_INF(t); @@ -273,8 +273,8 @@ check_INF (void) /******atanh********/ - tester=mpfr_atanh(ath,t,GMP_RNDD); - if (!MPFR_IS_INF(ath) || tester != 0) + tester = mpfr_atanh (ath, t, GMP_RNDD); + if (!MPFR_IS_NAN(ath) || tester != 0) { printf("atanh(INF) \n"); fail = 1; @@ -335,8 +335,8 @@ check_INF (void) /******atanh********/ - tester=mpfr_atanh(ath,t,GMP_RNDD); - if (!MPFR_IS_INF(ath) || MPFR_SIGN(ath) > 0 || tester != 0) + tester = mpfr_atanh (ath, t, GMP_RNDD); + if (!MPFR_IS_NAN(ath) || tester != 0) { printf("atanh(-INF) \n"); fail = 1; |