struct Complex

Superclass hierarchy

Object
Value
Struct
Complex

Defined in:

Class Method Summary

Instance Method Summary

Class Method Detail

def self.zero

def self.new(real : Number, imag : Number)

Instance Method Detail

def *(other : Complex)

def *(other : Number)

def +(other : Complex)

def +(other : Number)

def -

def -(other : Complex)

def -(other : Number)

def /(other : Number)

def /(other : Complex)

def ==(other : Number)

def ==(other : Complex)

def ==(other)

def abs

def abs2

def conj

def exp

def imag

def inv

def log

def log10

def log2

def phase

def polar

def real

def sign

def sqrt

Complex.sqrt was inspired by the following blog post of Pavel Panchekha on floating point precision: https://pavpanchekha.com/casio/index.html


def to_s(io : IO)