Moodle PHP Documentation 5.1
Moodle 5.1dev (Build: 20250620) (7d9030acd6e)
Complex\Functions Class Reference

Static Public Member Functions

static abs ($complex)
 
static acos ($complex)
 Returns the inverse cosine of a complex number.
 
static acosh ($complex)
 Returns the inverse hyperbolic cosine of a complex number.
 
static acot ($complex)
 Returns the inverse cotangent of a complex number.
 
static acoth ($complex)
 Returns the inverse hyperbolic cotangent of a complex number.
 
static acsc ($complex)
 Returns the inverse cosecant of a complex number.
 
static acsch ($complex)
 Returns the inverse hyperbolic cosecant of a complex number.
 
static argument ($complex)
 Returns the argument of a complex number.
 
static asec ($complex)
 Returns the inverse secant of a complex number.
 
static asech ($complex)
 Returns the inverse hyperbolic secant of a complex number.
 
static asin ($complex)
 Returns the inverse sine of a complex number.
 
static asinh ($complex)
 Returns the inverse hyperbolic sine of a complex number.
 
static atan ($complex)
 Returns the inverse tangent of a complex number.
 
static atanh ($complex)
 Returns the inverse hyperbolic tangent of a complex number.
 
static conjugate ($complex)
 Returns the complex conjugate of a complex number.
 
static cos ($complex)
 Returns the cosine of a complex number.
 
static cosh ($complex)
 Returns the hyperbolic cosine of a complex number.
 
static cot ($complex)
 Returns the cotangent of a complex number.
 
static coth ($complex)
 Returns the hyperbolic cotangent of a complex number.
 
static csc ($complex)
 Returns the cosecant of a complex number.
 
static csch ($complex)
 Returns the hyperbolic cosecant of a complex number.
 
static exp ($complex)
 Returns the exponential of a complex number.
 
static inverse ($complex)
 Returns the inverse of a complex number.
 
static ln ($complex)
 Returns the natural logarithm of a complex number.
 
static log10 ($complex)
 Returns the common logarithm (base 10) of a complex number.
 
static log2 ($complex)
 Returns the base-2 logarithm of a complex number.
 
static negative ($complex)
 Returns the negative of a complex number.
 
static pow ($complex, $power)
 Returns a complex number raised to a power.
 
static rho ($complex)
 Returns the rho of a complex number.
 
static sec ($complex)
 Returns the secant of a complex number.
 
static sech ($complex)
 Returns the hyperbolic secant of a complex number.
 
static sin ($complex)
 Returns the sine of a complex number.
 
static sinh ($complex)
 Returns the hyperbolic sine of a complex number.
 
static sqrt ($complex)
 Returns the square root of a complex number.
 
static tan ($complex)
 Returns the tangent of a complex number.
 
static tanh ($complex)
 Returns the hyperbolic tangent of a complex number.
 
static theta ($complex)
 Returns the theta of a complex number.
 

Member Function Documentation

◆ acos()

static Complex\Functions::acos ( $complex)
static

Returns the inverse cosine of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse cosine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ acosh()

static Complex\Functions::acosh ( $complex)
static

Returns the inverse hyperbolic cosine of a complex number.

Formula from Wolfram Alpha: cosh^(-1)z = ln(z + sqrt(z + 1) sqrt(z - 1)).

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse hyperbolic cosine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ acot()

static Complex\Functions::acot ( $complex)
static

Returns the inverse cotangent of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse cotangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ acoth()

static Complex\Functions::acoth ( $complex)
static

Returns the inverse hyperbolic cotangent of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse hyperbolic cotangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ acsc()

static Complex\Functions::acsc ( $complex)
static

Returns the inverse cosecant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse cosecant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ acsch()

static Complex\Functions::acsch ( $complex)
static

Returns the inverse hyperbolic cosecant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse hyperbolic cosecant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ argument()

static Complex\Functions::argument ( $complex)
static

Returns the argument of a complex number.

Also known as the theta of the complex number, i.e. the angle in radians from the real axis to the representation of the number in polar coordinates.

This function is a synonym for theta()

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
floatThe argument (or theta) value of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
See also
theta

◆ asec()

static Complex\Functions::asec ( $complex)
static

Returns the inverse secant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse secant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ asech()

static Complex\Functions::asech ( $complex)
static

Returns the inverse hyperbolic secant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse hyperbolic secant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ asin()

static Complex\Functions::asin ( $complex)
static

Returns the inverse sine of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse sine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ asinh()

static Complex\Functions::asinh ( $complex)
static

Returns the inverse hyperbolic sine of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse hyperbolic sine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ atan()

static Complex\Functions::atan ( $complex)
static

Returns the inverse tangent of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse tangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ atanh()

static Complex\Functions::atanh ( $complex)
static

Returns the inverse hyperbolic tangent of a complex number.

Formula from Wolfram Alpha: tanh^(-1)z = 1/2 [ln(1 + z) - ln(1 - z)].

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse hyperbolic tangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ conjugate()

static Complex\Functions::conjugate ( $complex)
static

Returns the complex conjugate of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe conjugate of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ cos()

static Complex\Functions::cos ( $complex)
static

Returns the cosine of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe cosine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ cosh()

static Complex\Functions::cosh ( $complex)
static

Returns the hyperbolic cosine of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe hyperbolic cosine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ cot()

static Complex\Functions::cot ( $complex)
static

Returns the cotangent of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe cotangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ coth()

static Complex\Functions::coth ( $complex)
static

Returns the hyperbolic cotangent of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe hyperbolic cotangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ csc()

static Complex\Functions::csc ( $complex)
static

Returns the cosecant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe cosecant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ csch()

static Complex\Functions::csch ( $complex)
static

Returns the hyperbolic cosecant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe hyperbolic cosecant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ exp()

static Complex\Functions::exp ( $complex)
static

Returns the exponential of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe exponential of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ inverse()

static Complex\Functions::inverse ( $complex)
static

Returns the inverse of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe inverse of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ ln()

static Complex\Functions::ln ( $complex)
static

Returns the natural logarithm of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe natural logarithm of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf the real and the imaginary parts are both zero

◆ log10()

static Complex\Functions::log10 ( $complex)
static

Returns the common logarithm (base 10) of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe common logarithm (base 10) of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf the real and the imaginary parts are both zero

◆ log2()

static Complex\Functions::log2 ( $complex)
static

Returns the base-2 logarithm of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe base-2 logarithm of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf the real and the imaginary parts are both zero

◆ negative()

static Complex\Functions::negative ( $complex)
static

Returns the negative of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe negative value of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
See also
rho

◆ pow()

static Complex\Functions::pow ( $complex,
$power )
static

Returns a complex number raised to a power.

Parameters
Complex | mixed$complexComplex number or a numeric value.
float | integer$powerThe power to raise this value to
Return values
ComplexThe complex argument raised to the real power.
Exceptions
ExceptionIf the power argument isn't a valid real

◆ rho()

static Complex\Functions::rho ( $complex)
static

Returns the rho of a complex number.

This is the distance/radius from the centrepoint to the representation of the number in polar coordinates.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
floatThe rho value of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ sec()

static Complex\Functions::sec ( $complex)
static

Returns the secant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe secant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ sech()

static Complex\Functions::sech ( $complex)
static

Returns the hyperbolic secant of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe hyperbolic secant of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ sin()

static Complex\Functions::sin ( $complex)
static

Returns the sine of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe sine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ sinh()

static Complex\Functions::sinh ( $complex)
static

Returns the hyperbolic sine of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe hyperbolic sine of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ sqrt()

static Complex\Functions::sqrt ( $complex)
static

Returns the square root of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe Square root of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

◆ tan()

static Complex\Functions::tan ( $complex)
static

Returns the tangent of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe tangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ tanh()

static Complex\Functions::tanh ( $complex)
static

Returns the hyperbolic tangent of a complex number.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
ComplexThe hyperbolic tangent of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.
InvalidArgumentExceptionIf function would result in a division by zero

◆ theta()

static Complex\Functions::theta ( $complex)
static

Returns the theta of a complex number.

This is the angle in radians from the real axis to the representation of the number in polar coordinates.

Parameters
Complex | mixed$complexComplex number or a numeric value.
Return values
floatThe theta value of the complex argument.
Exceptions
ExceptionIf argument isn't a valid real or complex number.

The documentation for this class was generated from the following file: