static public Method

Math.atan(p1)

Math.atan(x)     float

Computes the arc tangent of x. Returns -{PI/2} .. {PI/2}.

Source Code

/*
*  call-seq:
*     Math.atan(x)    => float
*  
*  Computes the arc tangent of <i>x</i>. Returns -{PI/2} .. {PI/2}.
*/

static VALUE
math_atan(obj, x)
   VALUE obj, x;
{
   Need_Float(x);
   return rb_float_new(atan(RFLOAT(x)->value));
}
Comments

Have your say
Please use Textile formatting (click here for a cheat sheet). Use <code/> and <pre/> for code samples.
Click here to login with OpenID to to post comments.