atanh

Math.atanh(x) â float Class Public methods Computes the inverse hyperbolic tangent of x.

atan2

Math.atan2(y, x) â float Class Public methods Computes the arc tangent given y and x. Returns -PI..PI. Math.atan2(-0.0, -1.0) #=> -3.141592653589793 Math.atan2(-1.0, -1.0) #=> -2.356194490192345 Math.atan2(-1.0, 0.0) #=> -1.5707963267948966 Math.atan2(-1.0, 1.0) #=> -0.7853981633974483 Math.atan2(-0.0, 1.0) #=> -0.0 Math.atan2(0.0, 1.0) #=> 0.0 Math.atan2(1.0, 1.0) #=> 0.7853981633974483 Math.atan2(1.0, 0.0) #=> 1.5707963267948966 Math.atan2(1.0,

atan

Math.atan(x) â float Class Public methods Computes the arc tangent of x. Returns -{PI/2} .. {PI/2}.

asinh

Math.asinh(x) â float Class Public methods Computes the inverse hyperbolic sine of x.

asin

Math.asin(x) â float Class Public methods Computes the arc sine of x. Returns -{PI/2} .. {PI/2}.

acosh

Math.acosh(x) â float Class Public methods Computes the inverse hyperbolic cosine of x.

acos

Math.acos(x) â float Class Public methods Computes the arc cosine of x. Returns 0..PI.

values_at

mtch.values_at([index]*) â array Instance Public methods Uses each index to access the matching values, returning an array of the corresponding matches. m = /(.)(.)(\d+)(\d)/.match("THX1138: The Movie") m.to_a #=> ["HX1138", "H", "X", "113", "8"] m.values_at(0, 2, -2) #=> ["HX1138", "X", "113"]

to_s

mtch.to_s â str Instance Public methods Returns the entire matched string. m = /(.)(.)(\d+)(\d)/.match("THX1138.") m.to_s #=> "HX1138"

to_a

mtch.to_a â anArray Instance Public methods Returns the array of matches. m = /(.)(.)(\d+)(\d)/.match("THX1138.") m.to_a #=> ["HX1138", "H", "X", "113", "8"] Because to_a is called when expanding *variable, there's a useful assignment shortcut for extracting matched fields. This is slightly slower than accessing the fields directly (as an intermediate array is generated). all,f1,f2,f3 = *(/(.)(.)(\d+)(\d)/.match("THX1138.")) all #=> "HX1138" f1 #=> "H" f2 #=&