summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2018-03-09 23:10:41 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2018-03-09 23:10:41 +0000
commit959d69ed7099e265e701dbf26fcbd5c513285bde (patch)
tree942d17a8321ddb69358ff1cc4c770964a296ce2c
parent264570b7ab3d696fd72daffbb6a5c57ae3478c47 (diff)
downloadmpfr-959d69ed7099e265e701dbf26fcbd5c513285bde.tar.gz
Fixed spelling mistakes found by codespell 1.12.0.
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@12474 280ebfd0-de03-0410-8827-d642c229c3f4
-rw-r--r--TODO2
-rw-r--r--doc/mpfr.texi2
-rw-r--r--src/atan.c16
-rw-r--r--src/cache.c2
-rw-r--r--src/fpif.c4
-rw-r--r--src/get_flt.c2
-rw-r--r--src/mpfr.h2
-rw-r--r--src/sum.c2
-rw-r--r--tests/terandom_chisq.c2
-rw-r--r--tests/tnrandom_chisq.c2
10 files changed, 18 insertions, 18 deletions
diff --git a/TODO b/TODO
index 3379a9a2c..a72628bc5 100644
--- a/TODO
+++ b/TODO
@@ -59,7 +59,7 @@ Table of contents:
- export mpfr_overflow and mpfr_underflow as public functions
- many functions currently taking into account the precision of the *input*
- variable to set the initial working precison (acosh, asinh, cosh, ...).
+ variable to set the initial working precision (acosh, asinh, cosh, ...).
This is nonsense since the "average" working precision should only depend
on the precision of the *output* variable (and maybe on the *value* of
the input in case of cancellation).
diff --git a/doc/mpfr.texi b/doc/mpfr.texi
index 856159224..e2d1977ed 100644
--- a/doc/mpfr.texi
+++ b/doc/mpfr.texi
@@ -2375,7 +2375,7 @@ use @code{mpfr_free_cache} or @code{mpfr_free_cache2}.
@end deftypefun
@deftypefun void mpfr_free_cache (void)
-Free all caches and pools used by MPFR internally (thoses local to the
+Free all caches and pools used by MPFR internally (those local to the
current thread and those shared by all threads).
You should call this function before terminating a thread, even if you did
not call @code{mpfr_const_*} functions directly (they could have been called
diff --git a/src/atan.c b/src/atan.c
index e98a4328f..310e4d464 100644
--- a/src/atan.c
+++ b/src/atan.c
@@ -177,7 +177,7 @@ mpfr_atan_aux (mpfr_ptr y, mpz_ptr p, unsigned long r, int m, mpz_t *tab)
/* main loop */
n = 1UL << m;
MPFR_ASSERTN (n != 0); /* no overflow */
- /* the ith term being X^i/(2i+1) with X=p/2^r, we can stop when
+ /* the i-th term being X^i/(2i+1) with X=p/2^r, we can stop when
p^i/2^(r*i) < 2^(-precy), i.e. r*i > precy + log2(p^i) */
for (i = k = done = 0; (i < n) && (done == 0); i += 2, k ++)
{
@@ -209,7 +209,7 @@ mpfr_atan_aux (mpfr_ptr y, mpz_ptr p, unsigned long r, int m, mpz_t *tab)
}
}
}
- else /* special case p=1: the ith term being X^i/(2i+1) with X=1/2^r,
+ else /* special case p=1: the i-th term being X^i/(2i+1) with X=1/2^r,
we can stop when r*i > precy i.e. i > precy/r */
{
n = 1UL << m;
@@ -284,7 +284,7 @@ mpfr_atan (mpfr_ptr atan, mpfr_srcptr x, mpfr_rnd_t rnd_mode)
mpfr_exp_t exptol;
mpfr_prec_t prec, realprec, est_lost, lost;
unsigned long twopoweri, log2p, red;
- int comparaison, inexact;
+ int comparison, inexact;
int i, n0, oldn0;
MPFR_GROUP_DECL (group);
MPFR_SAVE_EXPO_DECL (expo);
@@ -339,8 +339,8 @@ mpfr_atan (mpfr_ptr atan, mpfr_srcptr x, mpfr_rnd_t rnd_mode)
MPFR_SAVE_EXPO_MARK (expo);
/* Other simple case arctan(-+1)=-+pi/4 */
- comparaison = mpfr_cmp_ui (xp, 1);
- if (MPFR_UNLIKELY (comparaison == 0))
+ comparison = mpfr_cmp_ui (xp, 1);
+ if (MPFR_UNLIKELY (comparison == 0))
{
int neg = MPFR_IS_NEG (x);
inexact = mpfr_const_pi (atan, MPFR_IS_POS (x) ? rnd_mode
@@ -401,7 +401,7 @@ mpfr_atan (mpfr_ptr atan, mpfr_srcptr x, mpfr_rnd_t rnd_mode)
MPFR_SAVE_EXPO_MARK, but let's check that for maintainability. */
MPFR_ASSERTD (__gmpfr_emax <= 1 - __gmpfr_emin);
- if (comparaison > 0) /* use atan(xp) = Pi/2 - atan(1/xp) */
+ if (comparison > 0) /* use atan(xp) = Pi/2 - atan(1/xp) */
mpfr_ui_div (sk, 1, xp, MPFR_RNDN);
else
mpfr_set (sk, xp, MPFR_RNDN);
@@ -418,7 +418,7 @@ mpfr_atan (mpfr_ptr atan, mpfr_srcptr x, mpfr_rnd_t rnd_mode)
mpfr_add_ui (tmp, tmp, 1, MPFR_RNDN);
mpfr_sqrt (tmp, tmp, MPFR_RNDN);
mpfr_sub_ui (tmp, tmp, 1, MPFR_RNDN);
- if (red == 0 && comparaison > 0)
+ if (red == 0 && comparison > 0)
/* use xp = 1/sk */
mpfr_mul (sk, tmp, xp, MPFR_RNDN);
else
@@ -488,7 +488,7 @@ mpfr_atan (mpfr_ptr atan, mpfr_srcptr x, mpfr_rnd_t rnd_mode)
/* argument reduction */
mpfr_mul_2exp (arctgt, arctgt, red, MPFR_RNDN);
- if (comparaison > 0)
+ if (comparison > 0)
{ /* atan(x) = Pi/2-atan(1/x) for x > 0 */
mpfr_const_pi (tmp, MPFR_RNDN);
mpfr_div_2ui (tmp, tmp, 1, MPFR_RNDN);
diff --git a/src/cache.c b/src/cache.c
index bc50fe554..f6676a872 100644
--- a/src/cache.c
+++ b/src/cache.c
@@ -144,7 +144,7 @@ mpfr_cache (mpfr_ptr dest, mpfr_cache_t cache, mpfr_rnd_t rnd)
mpfr_overflow (dest, rnd, sign);
);
- /* Rather a likely, this is a 100% succes rate for
+ /* Rather a likely, this is a 100% success rate for
all constants of MPFR */
if (MPFR_LIKELY (cache->inexact != 0))
{
diff --git a/src/fpif.c b/src/fpif.c
index 64bfa39d8..4a282e2a6 100644
--- a/src/fpif.c
+++ b/src/fpif.c
@@ -522,7 +522,7 @@ mpfr_fpif_read_limbs (mpfr_t x, unsigned char *buffer, size_t *buffer_size)
/* External Function */
/*
- * fh : IN : file hander
+ * fh : IN : file handler
* x : IN : MPFR number to put in the file
* return 0 if successful
*/
@@ -587,7 +587,7 @@ mpfr_fpif_export (FILE *fh, mpfr_t x)
/*
* x : IN/OUT : MPFR number extracted from the file, its precision is reset to
* be able to hold the number
- * fh : IN : file hander
+ * fh : IN : file handler
* Return 0 if the import was successful.
*/
int
diff --git a/src/get_flt.c b/src/get_flt.c
index f6a761ca9..82c02e86e 100644
--- a/src/get_flt.c
+++ b/src/get_flt.c
@@ -124,7 +124,7 @@ mpfr_get_flt (mpfr_srcptr src, mpfr_rnd_t rnd_mode)
if (negative)
dd = -dd;
- /* convert (exacly) to float */
+ /* convert (exactly) to float */
d = (float) dd;
}
diff --git a/src/mpfr.h b/src/mpfr.h
index ee907d1e4..77ed1d4ea 100644
--- a/src/mpfr.h
+++ b/src/mpfr.h
@@ -1024,7 +1024,7 @@ __MPFR_DECLSPEC int mpfr_custom_get_kind (mpfr_srcptr);
/* Check if <stdint.h> / <inttypes.h> is included or if the user
- explicitly wants intmax_t. Automatical detection is done by
+ explicitly wants intmax_t. Automatic detection is done by
checking:
- INTMAX_C and UINTMAX_C, but not if the compiler is a C++ one
(as suggested by Patrick Pelissier) because the test does not
diff --git a/src/sum.c b/src/sum.c
index 9123e7363..ac6711062 100644
--- a/src/sum.c
+++ b/src/sum.c
@@ -67,7 +67,7 @@ VL: This is very different:
arbitrary precision fixed precision
correct rounding just reproducible rounding
integer operations floating-point operations
- sequencial parallel (& sequential)
+ sequential parallel (& sequential)
*/
#ifdef MPFR_COV_CHECK
diff --git a/tests/terandom_chisq.c b/tests/terandom_chisq.c
index 66de5469d..5d4e5109a 100644
--- a/tests/terandom_chisq.c
+++ b/tests/terandom_chisq.c
@@ -167,7 +167,7 @@ test_erandom_chisq_cont (long num, mpfr_prec_t prec, int nu,
}
/* Return a sequential number for a positive low-precision x. x is altered by
- * this fuction. low precision means prec = 2, 3, or 4. High values of
+ * this function. low precision means prec = 2, 3, or 4. High values of
* precision will result in integer overflow. */
static long
sequential (mpfr_t x)
diff --git a/tests/tnrandom_chisq.c b/tests/tnrandom_chisq.c
index 176a83c99..59a688c79 100644
--- a/tests/tnrandom_chisq.c
+++ b/tests/tnrandom_chisq.c
@@ -163,7 +163,7 @@ test_nrandom_chisq_cont (long num, mpfr_prec_t prec, int nu,
}
/* Return a sequential number for a positive low-precision x. x is altered by
- * this fuction. low precision means prec = 2, 3, or 4. High values of
+ * this function. low precision means prec = 2, 3, or 4. High values of
* precision will result in integer overflow. */
static long
sequential (mpfr_t x)