Module liba.complex

complex number

Functions

new ([real[, imag]]) constructor for complex number from real and imaginary parts
rect ([real[, imag]]) constructor for complex number from rectangular Cartesian components
polar ([rho[, theta]]) constructor for complex number from polar form
eq (x, y) complex number x is equal to complex number y
ne (x, y) complex number x is not equal to complex number y
logabs (z) computes the natural logarithm of magnitude of a complex number
abs2 (z) computes the squared magnitude of a complex number
abs (z) computes the magnitude of a complex number
arg (z) computes the phase angle of a complex number
proj (z) computes the projection on Riemann sphere
conj (z) computes the complex conjugate
unm (z) computes the complex negative
inv (z) inverse of a complex number
add (x, y) addition of complex numbers
sub (x, y) subtraction of complex numbers
mul (x, y) multiplication of complex numbers
div (x, y) division of complex numbers
pow (z, a) complex number z raised to complex power a
logb (z, b) computes the complex base-b logarithm
exp (z) computes the complex base-e exponential
log (z) computes the complex natural logarithm
sqrt (z) computes the complex square root
log2 (z) computes the complex base-2 logarithm
log10 (z) computes the complex base-10 logarithm
sin (z) computes the complex sine
cos (z) computes the complex cosine
tan (z) computes the complex tangent
sec (z) computes the complex secant
csc (z) computes the complex cosecant
cot (z) computes the complex cotangent
asin (z) computes the complex arc sine
acos (z) computes the complex arc cosine
atan (z) computes the complex arc tangent
asec (z) computes the complex arc secant
acsc (z) computes the complex arc cosecant
acot (z) computes the complex arc cotangent
sinh (z) computes the complex hyperbolic sine
cosh (z) computes the complex hyperbolic cosine
tanh (z) computes the complex hyperbolic tangent
sech (z) computes the complex hyperbolic secant
csch (z) computes the complex hyperbolic cosecant
coth (z) computes the complex hyperbolic cotangent
asinh (z) computes the complex arc hyperbolic sine
acosh (z) computes the complex arc hyperbolic cosine
atanh (z) computes the complex arc hyperbolic tangent
asech (z) computes the complex arc hyperbolic secant
acsch (z) computes the complex arc hyperbolic cosecant
acoth (z) computes the complex arc hyperbolic cotangent


Functions

new ([real[, imag]])
constructor for complex number from real and imaginary parts

Parameters:

  • real number, string or a.complex real part of complex number (optional)
  • imag number imaginary part of complex number (optional)

Returns:

    a.complex complex number userdata
rect ([real[, imag]])
constructor for complex number from rectangular Cartesian components

Parameters:

  • real number real part of complex number (optional)
  • imag number imaginary part of complex number (optional)

Returns:

    a.complex complex number userdata
polar ([rho[, theta]])
constructor for complex number from polar form

Parameters:

  • rho number a distance from a reference point (optional)
  • theta number an angle from a reference direction (optional)

Returns:

    a.complex complex number userdata
eq (x, y)
complex number x is equal to complex number y

Parameters:

Returns:

    bool result of comparison
ne (x, y)
complex number x is not equal to complex number y

Parameters:

Returns:

    bool result of comparison
logabs (z)
computes the natural logarithm of magnitude of a complex number

Parameters:

Returns:

    number log|z|
abs2 (z)
computes the squared magnitude of a complex number

Parameters:

Returns:

    number a^2+b^2
abs (z)
computes the magnitude of a complex number

Parameters:

Returns:

    number sqrt{a^2+b^2}
arg (z)
computes the phase angle of a complex number

Parameters:

Returns:

    number arctan(b/a)
proj (z)
computes the projection on Riemann sphere

Parameters:

Returns:

    a.complex complex number userdata
conj (z)
computes the complex conjugate

Parameters:

Returns:

    a.complex complex number userdata
unm (z)
computes the complex negative

Parameters:

Returns:

    a.complex complex number userdata
inv (z)
inverse of a complex number

Parameters:

Returns:

    a.complex complex number userdata
add (x, y)
addition of complex numbers

Parameters:

Returns:

    a.complex complex number userdata
sub (x, y)
subtraction of complex numbers

Parameters:

Returns:

    a.complex complex number userdata
mul (x, y)
multiplication of complex numbers

Parameters:

Returns:

    a.complex complex number userdata
div (x, y)
division of complex numbers

Parameters:

Returns:

    a.complex complex number userdata
pow (z, a)
complex number z raised to complex power a

Parameters:

Returns:

    a.complex complex number userdata
logb (z, b)
computes the complex base-b logarithm

Parameters:

Returns:

    a.complex complex number userdata
exp (z)
computes the complex base-e exponential

Parameters:

Returns:

    a.complex complex number userdata
log (z)
computes the complex natural logarithm

Parameters:

Returns:

    a.complex complex number userdata
sqrt (z)
computes the complex square root

Parameters:

Returns:

    a.complex complex number userdata
log2 (z)
computes the complex base-2 logarithm

Parameters:

Returns:

    a.complex complex number userdata
log10 (z)
computes the complex base-10 logarithm

Parameters:

Returns:

    a.complex complex number userdata
sin (z)
computes the complex sine

Parameters:

Returns:

    a.complex complex number userdata
cos (z)
computes the complex cosine

Parameters:

Returns:

    a.complex complex number userdata
tan (z)
computes the complex tangent

Parameters:

Returns:

    a.complex complex number userdata
sec (z)
computes the complex secant

Parameters:

Returns:

    a.complex complex number userdata
csc (z)
computes the complex cosecant

Parameters:

Returns:

    a.complex complex number userdata
cot (z)
computes the complex cotangent

Parameters:

Returns:

    a.complex complex number userdata
asin (z)
computes the complex arc sine

Parameters:

Returns:

    a.complex complex number userdata
acos (z)
computes the complex arc cosine

Parameters:

Returns:

    a.complex complex number userdata
atan (z)
computes the complex arc tangent

Parameters:

Returns:

    a.complex complex number userdata
asec (z)
computes the complex arc secant

Parameters:

Returns:

    a.complex complex number userdata
acsc (z)
computes the complex arc cosecant

Parameters:

Returns:

    a.complex complex number userdata
acot (z)
computes the complex arc cotangent

Parameters:

Returns:

    a.complex complex number userdata
sinh (z)
computes the complex hyperbolic sine

Parameters:

Returns:

    a.complex complex number userdata
cosh (z)
computes the complex hyperbolic cosine

Parameters:

Returns:

    a.complex complex number userdata
tanh (z)
computes the complex hyperbolic tangent

Parameters:

Returns:

    a.complex complex number userdata
sech (z)
computes the complex hyperbolic secant

Parameters:

Returns:

    a.complex complex number userdata
csch (z)
computes the complex hyperbolic cosecant

Parameters:

Returns:

    a.complex complex number userdata
coth (z)
computes the complex hyperbolic cotangent

Parameters:

Returns:

    a.complex complex number userdata
asinh (z)
computes the complex arc hyperbolic sine

Parameters:

Returns:

    a.complex complex number userdata
acosh (z)
computes the complex arc hyperbolic cosine

Parameters:

Returns:

    a.complex complex number userdata
atanh (z)
computes the complex arc hyperbolic tangent

Parameters:

Returns:

    a.complex complex number userdata
asech (z)
computes the complex arc hyperbolic secant

Parameters:

Returns:

    a.complex complex number userdata
acsch (z)
computes the complex arc hyperbolic cosecant

Parameters:

Returns:

    a.complex complex number userdata
acoth (z)
computes the complex arc hyperbolic cotangent

Parameters:

Returns:

    a.complex complex number userdata
generated by LDoc 1.5.0 Last updated 2024-05-11 16:29:31