From 84b0162882783114ebc67d060b7c7a8224a227c6 Mon Sep 17 00:00:00 2001 From: cmgraff Date: Fri, 27 Jul 2018 21:43:01 -0500 Subject: [PATCH] Fix various ancient typos in Sun fdlibm's comments. --- src/math/__rem_pio2_large.c | 4 ++-- src/math/cbrt.c | 2 +- src/math/pow.c | 2 +- src/math/powl.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/math/__rem_pio2_large.c b/src/math/__rem_pio2_large.c index 958f28c..f712268 100644 --- a/src/math/__rem_pio2_large.c +++ b/src/math/__rem_pio2_large.c @@ -47,7 +47,7 @@ * 64-bit precision 2 * 113-bit precision 3 * The actual value is the sum of them. Thus for 113-bit - * precison, one may have to do something like: + * precision, one may have to do something like: * * long double t,w,r_head, r_tail; * t = (long double)y[2] + (long double)y[1]; @@ -78,7 +78,7 @@ * jk+1 must be 2 larger than you might expect so that our * recomputation test works. (Up to 24 bits in the integer * part (the 24 bits of it that we compute) and 23 bits in - * the fraction part may be lost to cancelation before we + * the fraction part may be lost to cancellation before we * recompute.) * * jz local integer variable indicating the number of diff --git a/src/math/cbrt.c b/src/math/cbrt.c index 7599d3e..b51da62 100644 --- a/src/math/cbrt.c +++ b/src/math/cbrt.c @@ -48,7 +48,7 @@ double cbrt(double x) * error of about 1 in 16. Adding a bias of -0.03306235651 to the * (e%3+m)/3 term reduces the error to about 1 in 32. With the IEEE * floating point representation, for finite positive normal values, - * ordinary integer divison of the value in bits magically gives + * ordinary integer division of the value in bits magically gives * almost exactly the RHS of the above provided we first subtract the * exponent bias (1023 for doubles) and later add it back. We do the * subtraction virtually to keep e >= 0 so that ordinary integer diff --git a/src/math/pow.c b/src/math/pow.c index 3ddc1b6..ab5d573 100644 --- a/src/math/pow.c +++ b/src/math/pow.c @@ -15,7 +15,7 @@ * 1. Compute and return log2(x) in two pieces: * log2(x) = w1 + w2, * where w1 has 53-24 = 29 bit trailing zeros. - * 2. Perform y*log2(x) = n+y' by simulating muti-precision + * 2. Perform y*log2(x) = n+y' by simulating multi-precision * arithmetic, where |y'|<=0.5. * 3. Return x**y = 2**n*exp(y'*log2) * diff --git a/src/math/powl.c b/src/math/powl.c index 5b6da07..e4595d5 100644 --- a/src/math/powl.c +++ b/src/math/powl.c @@ -199,7 +199,7 @@ long double powl(long double x, long double y) volatile long double z=0; long double w=0, W=0, Wa=0, Wb=0, ya=0, yb=0, u=0; - /* make sure no invalid exception is raised by nan comparision */ + /* make sure no invalid exception is raised by nan comparison */ if (isnan(x)) { if (!isnan(y) && y == 0.0) return 1.0; -- 2.7.4