Flowdock
module
Importance_1
Ruby latest stable (v1_9_3_392) - 0 notes

CMath

CMath is a library that provides trigonometric and transcendental functions for complex numbers.

Usage

To start using this library, simply:

require "cmath"

Square root of a negative number is a complex number.

CMath.sqrt(-9)  #=> 0+3.0i
Show files where this module is defined (1 file)
Register or log in to add new notes.