summaryrefslogtreecommitdiff
path: root/sin_cos.c
diff options
context:
space:
mode:
authorzimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4>2000-12-18 09:02:00 +0000
committerzimmerma <zimmerma@280ebfd0-de03-0410-8827-d642c229c3f4>2000-12-18 09:02:00 +0000
commit9c94b291ca1c5929ce7ca2927f7506045278cdc0 (patch)
treecb2b32a4711bcfd793f8a30fc60de441bc47ee6c /sin_cos.c
parent177371d41c4d432af5863e7c053d3e6439e6283d (diff)
downloadmpfr-9c94b291ca1c5929ce7ca2927f7506045278cdc0.tar.gz
changed name of mpfr struct fields: _mp_d -> _mpfr_d
(to detect conflicts with mpf) fixed a few problems in non-STDC headers moved definitions of mpfr-impl.h to mpfr-test.h and created a real mpfr-impl.h git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@897 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'sin_cos.c')
-rw-r--r--sin_cos.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/sin_cos.c b/sin_cos.c
index 686b95c8b..0fa9ee505 100644
--- a/sin_cos.c
+++ b/sin_cos.c
@@ -23,8 +23,9 @@ MA 02111-1307, USA. */
#include <stdio.h>
#include <stdlib.h>
#include "gmp.h"
-#include "mpfr.h"
#include "gmp-impl.h"
+#include "mpfr.h"
+#include "mpfr-impl.h"
int mpfr_sin_aux (mpfr_ptr, mpz_srcptr, int, int);
int mpfr_cos_aux (mpfr_ptr, mpz_srcptr, int, int);
@@ -100,7 +101,7 @@ mp_rnd_t rnd_mode;
((double) (MPFR_PREC(x)) / (double) BITS_PER_MP_LIMB)
/LOG2);
ttt = MPFR_EXP(x);
- mpfr_init2(x_copy,MPFR_PREC(x));
+ mpfr_init2(x_copy, MPFR_PREC(x));
mpfr_set(x_copy,x,GMP_RNDD);
mpz_init(square);
/* on fait le shift pour que le nombre soit inferieur a 1 */
@@ -217,8 +218,8 @@ mp_rnd_t rnd_mode;
goto try_again;
}
}
- if (mpfr_can_round(tmp_sin, realprec, GMP_RNDD, rnd_mode, PREC(sinus)) &&
- mpfr_can_round(tmp_cos, realprec, GMP_RNDD, rnd_mode, PREC(cosinus))) {
+ if (mpfr_can_round(tmp_sin, realprec, GMP_RNDD, rnd_mode, MPFR_PREC(sinus)) &&
+ mpfr_can_round(tmp_cos, realprec, GMP_RNDD, rnd_mode, MPFR_PREC(cosinus))) {
mpfr_set(sinus, tmp_sin, rnd_mode);
mpfr_set(cosinus, tmp_cos, rnd_mode);
good = 1;