Math_Complex
[ class tree: Math_Complex ] [ index: Math_Complex ] [ all elements ]

Class: Math_ComplexOp

Source Location: /Math_Complex-0.8.6/Math/ComplexOp.php

Class Overview


Math_ComplexOp: static class to operate on Math_Complex objects


Author(s):

Version:

  • 0.8

Methods


Inherited Variables

Inherited Methods


Class Details

[line 46]
Math_ComplexOp: static class to operate on Math_Complex objects

Originally this class was part of NumPHP (Numeric PHP package)



[ Top ]


Method Detail

acos   [line 485]

Math_Complex|PEAR_Error &acos( &$c1, Math_Complex $c1)

Calculates the inverse cosine of a complex number: z = acos(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

acosh   [line 737]

Math_Complex|PEAR_Error &acosh( &$c1, Math_Complex $c1)

Calculates the inverse hyperbolic cosine of a complex number: z = acosh(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

acot   [line 574]

Math_Complex|PEAR_Error &acot( &$c1, Math_Complex $c1)

Calculates the inverse cotangent of a complex number: z = acot(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

acoth   [line 823]

Math_Complex|PEAR_Error &acoth( &$c1, Math_Complex $c1)

Calculates the inverse hyperbolic cotangent of a complex number: z = acoth(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

acsc   [line 553]

Math_Complex|PEAR_Error &acsc( &$c1, Math_Complex $c1)

Calculates the inverse cosecant of a complex number: z = acsc(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

acsch   [line 805]

Math_Complex|PEAR_Error &acsch( &$c1, Math_Complex $c1)

Calculates the inverse hyperbolic cosecant of a complex number: z = acsch(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

add   [line 867]

Math_Complex|PEAR_Error &add( &$c1, &$c2, Math_Complex $c1, Math_Complex $c2)

Returns the sum of two complex numbers: z = c1 + c2
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
Math_Complex   $c2     
   &$c1     
   &$c2     

[ Top ]

areEqual   [line 844]

boolean|PEAR_Error &areEqual( &$c1, &$c2, Math_Complex $c1, Math_Complex $c2)

Determines if is c1 == c2:
  • Return: True if $c1 == $c2, False if $c1 != $c2, PEAR_Error object on error
  • Access: public

Parameters:

Math_Complex   $c1     
Math_Complex   $c2     
   &$c1     
   &$c2     

[ Top ]

asec   [line 532]

Math_Complex|PEAR_Error &asec( &$c1, Math_Complex $c1)

Calculates the inverse secant of a complex number: z = asec(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

asech   [line 787]

Math_Complex|PEAR_Error &asech( &$c1, Math_Complex $c1)

Calculates the inverse hyperbolic secant of a complex number: z = asech(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

asin   [line 384]

Math_Complex|PEAR_Error &asin( &$c1, Math_Complex $c1)

Calculates the inverse sine of a complex number: z = asin(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

asinAlt   [line 408]

Math_Complex|PEAR_Error &asinAlt( &$c1, Math_Complex $c1)

Calculates the inverse sine of a complex number: z = asinAlt(c1) Uses an alternative algorithm
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

asinh   [line 714]

Math_Complex|PEAR_Error &asinh( &$c1, Math_Complex $c1)

Calculates the inverse hyperbolic sine of a complex number: z = asinh(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

asinReal   [line 462]

Math_Complex &asinReal( float $r)

Calculates the complex inverse sine of a real number: z = asinReal(r):
  • Access: public

Parameters:

float   $r     

[ Top ]

atan   [line 507]

Math_Complex|PEAR_Error &atan( &$c1, Math_Complex $c1)

Calculates the inverse tangent of a complex number: z = atan(c1):
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

atanh   [line 759]

Math_Complex|PEAR_Error &atanh( &$c1, Math_Complex $c1)

Calculates the inverse hyperbolic tangent of a complex number: z = atanh(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

conjugate   [line 211]

Math_Complex|PEAR_Error &conjugate( &$c1, Math_Complex $c1)

Calculates the conjugate of a complex number: z = conj(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

cos   [line 288]

Math_Complex|PEAR_Error &cos( &$c1, Math_Complex $c1)

Calculates the cosine of a complex number: z = cos(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

cosh   [line 616]

Math_Complex|PEAR_Error &cosh( &$c1, Math_Complex $c1)

Calculates the hyperbolic cosine of a complex number: z = cosh(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

cot   [line 363]

Math_Complex|PEAR_Error &cot( &$c1, Math_Complex $c1)

Calculates the cotangent of a complex number: z = cot(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

coth   [line 693]

Math_Complex|PEAR_Error &coth( &$c1, Math_Complex $c1)

Calculates the hyperbolic cotangent of a complex number: z = coth(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

createFromPolar   [line 76]

Math_Complex &createFromPolar( float $r, float $theta)

Converts a polar complex z = r*exp(theta*i) to z = a + b*i
  • Access: public

Parameters:

float   $r     
float   $theta     

[ Top ]

csc   [line 346]

Math_Complex|PEAR_Error &csc( &$c1, Math_Complex $c1)

Calculates the cosecant of a complex number: z = csc(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

csch   [line 674]

Math_Complex|PEAR_Error &csch( &$c1, Math_Complex $c1)

Calculates the hyperbolic cosecant of a complex number: z = csch(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

div   [line 929]

Math_Complex|PEAR_Error &div( &$c1, &$c2, Math_Complex $c1, Math_Complex $c2)

Returns the division of two complex numbers: z = c1 * c2
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
Math_Complex   $c2     
   &$c1     
   &$c2     

[ Top ]

exp   [line 155]

Math_Complex|PEAR_Error &exp( &$c1, Math_Complex $c1)

Calculates the exponential of a complex number: z = exp(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

inverse   [line 245]

Math_Complex|PEAR_Error &inverse( &$c1, Math_Complex $c1)

Calculates the inverse of a complex number: z = 1/c1
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

isComplex   [line 56]

boolean isComplex( &$c1)

Checks if a given object is an instance of PEAR::Math_Complex
  • Access: public

Parameters:

   &$c1     

[ Top ]

log   [line 176]

Math_Complex|PEAR_Error &log( &$c1, Math_Complex $c1)

Calculates the logarithm (base 2) of a complex number: z = log(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

log10   [line 194]

Math_Complex|PEAR_Error &log10( &$c1, Math_Complex $c1)

Calculates the logarithm (base 10) of a complex number: z = log10(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

logBase   [line 991]

Math_Complex|PEAR_Error &logBase( &$c1, &$c2, Math_Complex $c1, Math_Complex $c2)

Returns the logarithm of base c2 of the complex number c1
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
Math_Complex   $c2     
   &$c1     
   &$c2     

[ Top ]

mult   [line 907]

Math_Complex|PEAR_Error &mult( &$c1, &$c2, Math_Complex $c1, Math_Complex $c2)

Returns the product of two complex numbers: z = c1 * c2
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
Math_Complex   $c2     
   &$c1     
   &$c2     

[ Top ]

multIm   [line 1037]

Math_Complex|PEAR_Error &multIm( Math_Complex $c1, float $im)

Returns the product of a complex number and an imaginary number if: x = b + c*i, y = a*i; then: z = x * y = multIm(x, a)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
float   $im     

[ Top ]

multReal   [line 1013]

Math_Complex|PEAR_Error &multReal( &$c1, float $real, Math_Complex $c1)

Multiplies a complex number by a real number: z = realnumber * c1
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
float   $real     
   &$c1     

[ Top ]

negative   [line 227]

Math_Complex|PEAR_Error &negative( &$c1, Math_Complex $c1)

Calculates the negative of a complex number: z = -c1
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

pow   [line 958]

Math_Complex|PEAR_Error &pow( &$c1, &$c2, Math_Complex $c1, Math_Complex $c2)

Returns the complex power of two complex numbers: z = c1^c2
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
Math_Complex   $c2     
   &$c1     
   &$c2     

[ Top ]

powReal   [line 1060]

Math_Complex|PEAR_Error &powReal( Math_Complex $c1, float $real)

Returns the exponentiation of a complex numbers to a real power: z = c1^(real)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
float   $real     

[ Top ]

sec   [line 329]

Math_Complex|PEAR_Error &sec( &$c1, Math_Complex $c1)

Calculates the secant of a complex number: z = sec(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

sech   [line 655]

Math_Complex|PEAR_Error &sech( &$c1, Math_Complex $c1)

Calculates the hyperbolic secant of a complex number: z = sech(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

sin   [line 269]

Math_Complex|PEAR_Error &sin( &$c1, Math_Complex $c1)

Calculates the sine of a complex number: z = sin(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

sinh   [line 597]

Math_Complex|PEAR_Error &sinh( &$c1, Math_Complex $c1)

Calculates the hyperbolic sine of a complex number: z = sinh(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

sqrt   [line 96]

Math_Complex|PEAR_Error &sqrt( &$c1, Math_Complex $c1)

Calculates the complex square root of a complex number: z = sqrt(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

sqrtReal   [line 134]

Math_Complex &sqrtReal( float $realnum)

Calculates the complex square root of a real number: z = sqrt(realnumber)
  • Access: public

Parameters:

float   $realnum     A float

[ Top ]

sub   [line 887]

Math_Complex|PEAR_Error &sub( &$c1, &$c2, Math_Complex $c1, Math_Complex $c2)

Returns the difference of two complex numbers: z = c1 - c2
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
Math_Complex   $c2     
   &$c1     
   &$c2     

[ Top ]

tan   [line 307]

Math_Complex|PEAR_Error &tan( &$c1, Math_Complex $c1)

Calculates the tangent of a complex number: z = tan(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]

tanh   [line 635]

Math_Complex|PEAR_Error &tanh( &$c1, Math_Complex $c1)

Calculates the hyperbolic tangent of a complex number: z = tanh(c1)
  • Return: A valid Math_Complex number on success, PEAR_Error otherwise
  • Access: public

Parameters:

Math_Complex   $c1     
   &$c1     

[ Top ]


Documentation generated on Tue, 05 Oct 2010 02:00:07 +0000 by phpDocumentor 1.4.3. PEAR Logo Copyright © PHP Group 2004.