cdiv - chung-leong/qb GitHub Wiki

cdiv - Divide one complex number by another

float[2] cdiv( float[2] $a, float[2] $b )

cdiv() divide a by b and results the result.

Parameters:

a - The dividend. It can be one two-element array or an array of two-element arrays. a[0] should contain the real part and a[1] should contain the imaginary part.

b - The divisor. It can be one two-element array or an array of two-element arrays. b[0] should contain the real part and b[1] should contain the imaginary part.

Return Value:

The quotient of a and b. The size of the return value will match that of the larger of a and b.

Version

1.0 and above.