diff options
author | zimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4> | 2007-07-18 12:19:22 +0000 |
---|---|---|
committer | zimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4> | 2007-07-18 12:19:22 +0000 |
commit | 17adbb9252c7cf03a822235405b4e0d1c4778740 (patch) | |
tree | a1f449d17b62faf4ae705bf4443cd8d6aa096c73 /tests/tatan.c | |
parent | 38aaaa9aeee21064caf89eb37df8332e4fb14ac2 (diff) | |
download | mpfr-17adbb9252c7cf03a822235405b4e0d1c4778740.tar.gz |
added test from Ch. Creutzig
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@4645 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'tests/tatan.c')
-rw-r--r-- | tests/tatan.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/tatan.c b/tests/tatan.c index 0bdc87d58..16d48c0db 100644 --- a/tests/tatan.c +++ b/tests/tatan.c @@ -352,6 +352,24 @@ special_atan2 (void) mpfr_clears (x, y, z, (void *) 0); } +/* from Christopher Creutzig, 18 Jul 2007 */ +static void +smallvals_atan2 (void) +{ + mpfr_t a, x, y; + + mpfr_inits (a, x, y, NULL); + mpfr_set_ui (x, 0, GMP_RNDN); + mpfr_nextbelow (x); + mpfr_set_ui (y, 1, GMP_RNDN); + + mpfr_atan2 (a, x, y, GMP_RNDD); + + mpfr_atan2 (a, x, y, GMP_RNDU); + + mpfr_clears (a, x, y, NULL); +} + int main (int argc, char *argv[]) { @@ -360,6 +378,7 @@ main (int argc, char *argv[]) special_overflow (); special (); special_atan2 (); + smallvals_atan2 (); test_generic_atan (2, 200, 17); test_generic_atan2 (2, 200, 17); |