summaryrefslogtreecommitdiff
path: root/math.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-22 01:00:18 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-10-22 01:00:18 +0000
commit3f0d0b9398b5af9311f8e570c0a8966ed9944d25 (patch)
tree22ed07f9cf180380f56d3767725522ef6feecb70 /math.c
parent69743fbd85b659601174bff9fb61abc8c662c13b (diff)
* *.[chy]: removed trailing spaces.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@25430 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'math.c')
-rw-r--r--math.c54
1 files changed, 27 insertions, 27 deletions
diff --git a/math.c b/math.c
index d8a0230fc5..abe5f6c164 100644
--- a/math.c
+++ b/math.c
@@ -46,10 +46,10 @@ domain_check(x, msg)
/*
* call-seq:
* Math.atan2(y, x) => float
- *
+ *
* Computes the arc tangent given <i>y</i> and <i>x</i>. Returns
* -PI..PI.
- *
+ *
*/
static VALUE
@@ -64,7 +64,7 @@ math_atan2(obj, y, x)
/*
* call-seq:
* Math.cos(x) => float
- *
+ *
* Computes the cosine of <i>x</i> (expressed in radians). Returns
* -1..1.
*/
@@ -80,7 +80,7 @@ math_cos(obj, x)
/*
* call-seq:
* Math.sin(x) => float
- *
+ *
* Computes the sine of <i>x</i> (expressed in radians). Returns
* -1..1.
*/
@@ -98,7 +98,7 @@ math_sin(obj, x)
/*
* call-seq:
* Math.tan(x) => float
- *
+ *
* Returns the tangent of <i>x</i> (expressed in radians).
*/
@@ -114,7 +114,7 @@ math_tan(obj, x)
/*
* call-seq:
* Math.acos(x) => float
- *
+ *
* Computes the arc cosine of <i>x</i>. Returns 0..PI.
*/
@@ -134,7 +134,7 @@ math_acos(obj, x)
/*
* call-seq:
* Math.asin(x) => float
- *
+ *
* Computes the arc sine of <i>x</i>. Returns -{PI/2} .. {PI/2}.
*/
@@ -154,7 +154,7 @@ math_asin(obj, x)
/*
* call-seq:
* Math.atan(x) => float
- *
+ *
* Computes the arc tangent of <i>x</i>. Returns -{PI/2} .. {PI/2}.
*/
@@ -178,7 +178,7 @@ cosh(x)
/*
* call-seq:
* Math.cosh(x) => float
- *
+ *
* Computes the hyperbolic cosine of <i>x</i> (expressed in radians).
*/
@@ -187,7 +187,7 @@ math_cosh(obj, x)
VALUE obj, x;
{
Need_Float(x);
-
+
return rb_float_new(cosh(RFLOAT(x)->value));
}
@@ -203,7 +203,7 @@ sinh(x)
/*
* call-seq:
* Math.sinh(x) => float
- *
+ *
* Computes the hyperbolic sine of <i>x</i> (expressed in
* radians).
*/
@@ -228,7 +228,7 @@ tanh(x)
/*
* call-seq:
* Math.tanh() => float
- *
+ *
* Computes the hyperbolic tangent of <i>x</i> (expressed in
* radians).
*/
@@ -244,7 +244,7 @@ math_tanh(obj, x)
/*
* call-seq:
* Math.acosh(x) => float
- *
+ *
* Computes the inverse hyperbolic cosine of <i>x</i>.
*/
@@ -264,7 +264,7 @@ math_acosh(obj, x)
/*
* call-seq:
* Math.asinh(x) => float
- *
+ *
* Computes the inverse hyperbolic sine of <i>x</i>.
*/
@@ -279,7 +279,7 @@ math_asinh(obj, x)
/*
* call-seq:
* Math.atanh(x) => float
- *
+ *
* Computes the inverse hyperbolic tangent of <i>x</i>.
*/
@@ -299,7 +299,7 @@ math_atanh(obj, x)
/*
* call-seq:
* Math.exp(x) => float
- *
+ *
* Returns e**x.
*/
@@ -323,7 +323,7 @@ math_exp(obj, x)
/*
* call-seq:
* Math.log(numeric) => float
- *
+ *
* Returns the natural logarithm of <i>numeric</i>.
*/
@@ -343,7 +343,7 @@ math_log(obj, x)
/*
* call-seq:
* Math.log10(numeric) => float
- *
+ *
* Returns the base 10 logarithm of <i>numeric</i>.
*/
@@ -363,7 +363,7 @@ math_log10(obj, x)
/*
* call-seq:
* Math.sqrt(numeric) => float
- *
+ *
* Returns the non-negative square root of <i>numeric</i>.
*/
@@ -383,11 +383,11 @@ math_sqrt(obj, x)
/*
* call-seq:
* Math.frexp(numeric) => [ fraction, exponent ]
- *
+ *
* Returns a two-element array containing the normalized fraction (a
* <code>Float</code>) and exponent (a <code>Fixnum</code>) of
* <i>numeric</i>.
- *
+ *
* fraction, exponent = Math.frexp(1234) #=> [0.6025390625, 11]
* fraction * 2**exponent #=> 1234.0
*/
@@ -400,7 +400,7 @@ math_frexp(obj, x)
int exp;
Need_Float(x);
-
+
d = frexp(RFLOAT(x)->value, &exp);
return rb_assoc_new(rb_float_new(d), INT2NUM(exp));
}
@@ -408,9 +408,9 @@ math_frexp(obj, x)
/*
* call-seq:
* Math.ldexp(flt, int) -> float
- *
+ *
* Returns the value of <i>flt</i>*(2**<i>int</i>).
- *
+ *
* fraction, exponent = Math.frexp(1234)
* Math.ldexp(fraction, exponent) #=> 1234.0
*/
@@ -426,10 +426,10 @@ math_ldexp(obj, x, n)
/*
* call-seq:
* Math.hypot(x, y) => float
- *
+ *
* Returns sqrt(x**2 + y**2), the hypotenuse of a right-angled triangle
* with sides <i>x</i> and <i>y</i>.
- *
+ *
* Math.hypot(3, 4) #=> 5.0
*/
@@ -476,7 +476,7 @@ math_erfc(obj, x)
* trigonometric and transcendental functions. See class
* <code>Float</code> for a list of constants that
* define Ruby's floating point accuracy.
- */
+ */
void