[mpfi] 04/39: mpfr_random has been removed in MPFR 3.0.
Jerome Benoit
calculus-guest at moszumanska.debian.org
Sat May 23 02:12:09 UTC 2015
This is an automated email from the git hooks/post-receive script.
calculus-guest pushed a commit to branch master
in repository mpfi.
commit 1b01b5767e4889981d2de86e69f3075e21826ff1
Author: Laurent Fousse <laurent at komite.net>
Date: Wed Jun 23 22:29:47 2010 +0200
mpfr_random has been removed in MPFR 3.0.
---
doc/mpfi.info | 2 +-
doc/mpfi.texi | 2 +-
src/mpfi.c | 4 ++--
src/mpfi.h | 2 +-
4 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/doc/mpfi.info b/doc/mpfi.info
index f61be48..465fb3e 100644
--- a/doc/mpfi.info
+++ b/doc/mpfi.info
@@ -592,7 +592,7 @@ center or the width, also called diameter, of an interval.
positive value if ROP > the middle of OP and a negative value if
ROP < the middle of OP.
- -- Function: void mpfi_alea (mpfr_t rop, mpfi_t op)
+ -- Function: void mpfi_alea (mpfr_t rop, mpfi_t op, gmp_randstate_t state)
Sets ROP to a floating-point number picked up at random in OP,
according to a uniform distribution.
diff --git a/doc/mpfi.texi b/doc/mpfi.texi
index 07d21f5..04f1627 100644
--- a/doc/mpfi.texi
+++ b/doc/mpfi.texi
@@ -759,7 +759,7 @@ Returns 0 if the result is exact, a positive value if @var{rop} > the
middle of @var{op} and a negative value if @var{rop} < the middle of @var{op}.
@end deftypefun
- at deftypefun void mpfi_alea (mpfr_t rop, mpfi_t op)
+ at deftypefun void mpfi_alea (mpfr_t rop, mpfi_t op, gmp_randstate_t state)
Sets @var{rop} to a floating-point number
picked up at random in @var{op}, according to a uniform distribution.
@end deftypefun
diff --git a/src/mpfi.c b/src/mpfi.c
index ceb4593..ed8bf1d 100644
--- a/src/mpfi.c
+++ b/src/mpfi.c
@@ -687,7 +687,7 @@ int mpfi_mid (mpfr_ptr m, mpfi_srcptr y)
}
/* Picks randomly a point m in y */
-void mpfi_alea (mpfr_ptr m, mpfi_srcptr y)
+void mpfi_alea (mpfr_ptr m, mpfi_srcptr y, gmp_randstate_t state)
{
mp_prec_t prec;
mpfr_t diam, fact;
@@ -702,7 +702,7 @@ void mpfi_alea (mpfr_ptr m, mpfi_srcptr y)
mpfr_init2(fact, prec);
dummy = mpfi_diam_abs(diam, y);
- mpfr_random(fact);
+ mpfr_urandomb(fact, state);
/* fact lies between 0 and 1, the picked point lies at a relative
distance "fact" of the left endpoint: m = inf + (sup - inf)*fact */
diff --git a/src/mpfi.h b/src/mpfi.h
index 2535ee9..f221c67 100644
--- a/src/mpfi.h
+++ b/src/mpfi.h
@@ -108,7 +108,7 @@ int mpfi_mig(mpfr_ptr, mpfi_srcptr);
/* middle of y */
int mpfi_mid (mpfr_ptr, mpfi_srcptr);
/* picks randomly a point m in y */
-void mpfi_alea (mpfr_ptr, mpfi_srcptr);
+void mpfi_alea (mpfr_ptr, mpfi_srcptr, gmp_randstate_t state);
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/mpfi.git
More information about the debian-science-commits
mailing list