CMath is a library that provides trigonometric and transcendental functions for complex numbers.
To start using this library, simply:
require
"cmath"
Square root of a negative number is a complex number.
CMath.sqrt(-
9
)
#=> 0+3.0i
log!(*args) Class Public methods Alias for:
atan!(z) Class Public methods Alias for:
sqrt!(z) Class Public methods Alias for:
asinh!(z) Class Public methods Alias for:
cosh!(z) Class Public methods Alias for:
tanh!(z) Class Public methods Alias for:
log2(z) Class Public methods returns the base 2 logarithm of z
cos(z) Class Public methods returns the cosine of z, where z
sinh(z) Class Public methods returns the hyperbolic sine of z,
atan(z) Class Public methods returns the arc tangent of z
Page 1 of 4