summaryrefslogtreecommitdiff
path: root/libm/e_j1.c
diff options
context:
space:
mode:
Diffstat (limited to 'libm/e_j1.c')
-rw-r--r--libm/e_j1.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/libm/e_j1.c b/libm/e_j1.c
index 5eb81ee73..e57049e84 100644
--- a/libm/e_j1.c
+++ b/libm/e_j1.c
@@ -5,7 +5,7 @@
*
* Developed at SunPro, a Sun Microsystems, Inc. business.
* Permission to use, copy, modify, and distribute this
- * software is freely granted, provided that this notice
+ * software is freely granted, provided that this notice
* is preserved.
* ====================================================
*/
@@ -34,16 +34,16 @@ static char rcsid[] = "$NetBSD: e_j1.c,v 1.8 1995/05/10 20:45:27 jtc Exp $";
* (To avoid cancellation, use
* sin(x) +- cos(x) = -cos(2x)/(sin(x) -+ cos(x))
* to compute the worse one.)
- *
+ *
* 3 Special cases
* j1(nan)= nan
* j1(0) = 0
* j1(inf) = 0
- *
+ *
* Method -- y1(x):
- * 1. screen out x<=0 cases: y1(0)=-inf, y1(x<0)=NaN
+ * 1. screen out x<=0 cases: y1(0)=-inf, y1(x<0)=NaN
* 2. For x<2.
- * Since
+ * Since
* y1(x) = 2/pi*(j1(x)*(ln(x/2)+Euler)-1/x-x/2+5/64*x^3-...)
* therefore y1(x)-2/pi*j1(x)*ln(x)-1/x is an odd function.
* We use the following function to approximate y1,
@@ -69,9 +69,9 @@ static double pone(), qone();
#endif
#ifdef __STDC__
-static const double
+static const double
#else
-static double
+static double
#endif
huge = 1e300,
one = 1.0,
@@ -95,9 +95,9 @@ static double zero = 0.0;
#endif
#ifdef __STDC__
- double __ieee754_j1(double x)
+ double __ieee754_j1(double x)
#else
- double __ieee754_j1(x)
+ double __ieee754_j1(x)
double x;
#endif
{
@@ -164,9 +164,9 @@ static double V0[5] = {
};
#ifdef __STDC__
- double __ieee754_y1(double x)
+ double __ieee754_y1(double x)
#else
- double __ieee754_y1(x)
+ double __ieee754_y1(x)
double x;
#endif
{
@@ -176,7 +176,7 @@ static double V0[5] = {
EXTRACT_WORDS(hx,lx,x);
ix = 0x7fffffff&hx;
/* if Y1(NaN) is NaN, Y1(-inf) is NaN, Y1(inf) is 0 */
- if(ix>=0x7ff00000) return one/(x+x*x);
+ if(ix>=0x7ff00000) return one/(x+x*x);
if((ix|lx)==0) return -one/zero;
if(hx<0) return zero/zero;
if(ix >= 0x40000000) { /* |x| >= 2.0 */
@@ -206,10 +206,10 @@ static double V0[5] = {
z = invsqrtpi*(u*ss+v*cc)/sqrt(x);
}
return z;
- }
+ }
if(ix<=0x3c900000) { /* x < 2**-54 */
return(-tpi/x);
- }
+ }
z = x*x;
u = U0[0]+z*(U0[1]+z*(U0[2]+z*(U0[3]+z*U0[4])));
v = one+z*(V0[0]+z*(V0[1]+z*(V0[2]+z*(V0[3]+z*V0[4]))));
@@ -347,7 +347,7 @@ static double ps2[5] = {
s = one+z*(q[0]+z*(q[1]+z*(q[2]+z*(q[3]+z*q[4]))));
return one+ r/s;
}
-
+
/* For x >= 8, the asymptotic expansions of qone is
* 3/8 s - 105/1024 s^3 - ..., where s = 1/x.