Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Zortech C++ 3.0r4 - <b>complex::function</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
complex::function

Usage

   #include <complex.hpp>

   double& real ();
   double& imag ();
   friend double real(const complex&);
   friend double imag(const complex&);
   friend complex conj(const complex&);
   friend double norm(const complex&);
   friend double modulus(const complex&);
   friend double arg(const complex&);
   friend complex polar(double range, double theta);

Description

   The functions described in this section are unique to complex type and do
   not overload the names of the C math library. In the following z is
   treated as a variable of type complex with a real part x and an imaginary
   part y both of type double. The variables a, z1 and z2 are of type
   complex while the variables u, r and t are of type double.

   x = real(z)         Returns the real portion of z.
   y = imag(z)         Returns the imaginary portion of z.
   z1 = conj(z)        Returns the complex conjugate of z. If z
                       is x+iy, then conj(z) is x-iy.
   u = arg(z)          Returns the argument of the complex
                       number z in radians.
   u = norm(z)         Returns the square of the absolute value
                       or modulus of z. norm(z) = x. + y.
   u = modulus         Returns the absolute value z.
                       modulus(z) = abs(z) = .(x.+y.)
   a = polar(r,theta)  Returns the complex that is the result of

                       converting polar coordinates r and theta
                       to x and y coordinates.

See Also

   Hyperbolic functions, complex functions, math functions





Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson