acos(z)
returns the arc cosine of z
CMath.acos(1 + 1i) #=> (0.9045568943023813-1.0612750619050357i)
# File lib/cmath.rb, line 288 def acos(z) begin if z.real? and z >= -1 and z <= 1 acos!(z) else (-1.0).i * log(z + 1.0.i * sqrt(1.0 - z * z)) end rescue NoMethodError handle_no_method_error end end