mdp_complex Class Reference

portable complex numbers More...

#include <mdp_complex.h>

List of all members.

Public Member Functions

mdp_realreal ()
mdp_realimag ()
const mdp_realreal () const
const mdp_realimag () const
 mdp_complex (const mdp_real a=0.0, const mdp_real b=0.0)
 mdp_complex (const mdp_complex &c)
bool operator== (const mdp_complex &c)
bool operator!= (const mdp_complex &c)
void operator+= (const mdp_complex &c)
void operator-= (const mdp_complex &c)
void operator*= (const mdp_complex &c)
void operator/= (const mdp_complex &c)
void operator+= (const mdp_real c)
void operator-= (const mdp_real c)
void operator*= (const mdp_real c)
void operator/= (const mdp_real c)

Public Attributes

mdp_real re
mdp_real im


mdp_real real (const mdp_complex &c)
mdp_real imag (const mdp_complex &c)
mdp_real abs (const mdp_complex &c)
mdp_real arg (const mdp_complex &c)
mdp_complex pow (const mdp_complex &c, mdp_real z)
mdp_complex sqrt (const mdp_complex &c)
mdp_complex exp (const mdp_complex &c)
mdp_complex sin (const mdp_complex &c)
mdp_complex cos (const mdp_complex &c)
mdp_complex times_i (const mdp_complex &c)
mdp_complex times_minus_i (const mdp_complex &c)
mdp_complex operator- (const mdp_complex &c)
mdp_complex operator+ (const mdp_complex &c)
mdp_real phase (const mdp_complex &c)
mdp_complex conj (const mdp_complex &a)

Detailed Description

portable complex numbers


///    mdp_complex x=3+5*I;
///    cout << << "," << x.imag() << endl;
///    cout << sin(x) << endl;

Constructor & Destructor Documentation

mdp_complex::mdp_complex ( const mdp_real  a = 0.0,
const mdp_real  b = 0.0 
) [inline]
mdp_complex::mdp_complex ( const mdp_complex c  )  [inline]

Member Function Documentation

const mdp_real& mdp_complex::imag (  )  const [inline]
mdp_real& mdp_complex::imag (  )  [inline]
bool mdp_complex::operator!= ( const mdp_complex c  )  [inline]
void mdp_complex::operator*= ( const mdp_real  c  )  [inline]
void mdp_complex::operator*= ( const mdp_complex c  )  [inline]
void mdp_complex::operator+= ( const mdp_real  c  )  [inline]
void mdp_complex::operator+= ( const mdp_complex c  )  [inline]
void mdp_complex::operator-= ( const mdp_real  c  )  [inline]
void mdp_complex::operator-= ( const mdp_complex c  )  [inline]
void mdp_complex::operator/= ( const mdp_real  c  )  [inline]
void mdp_complex::operator/= ( const mdp_complex c  )  [inline]
bool mdp_complex::operator== ( const mdp_complex c  )  [inline]
const mdp_real& mdp_complex::real (  )  const [inline]
mdp_real& mdp_complex::real (  )  [inline]

Friends And Related Function Documentation

mdp_real abs ( const mdp_complex c  )  [friend]
mdp_real arg ( const mdp_complex c  )  [friend]
mdp_complex conj ( const mdp_complex a  )  [friend]
mdp_complex cos ( const mdp_complex c  )  [friend]
mdp_complex exp ( const mdp_complex c  )  [friend]
mdp_real imag ( const mdp_complex c  )  [friend]
mdp_complex operator+ ( const mdp_complex c  )  [friend]
mdp_complex operator- ( const mdp_complex c  )  [friend]
mdp_real phase ( const mdp_complex c  )  [friend]
mdp_complex pow ( const mdp_complex c,
mdp_real  z 
) [friend]
mdp_real real ( const mdp_complex c  )  [friend]
mdp_complex sin ( const mdp_complex c  )  [friend]
mdp_complex sqrt ( const mdp_complex c  )  [friend]
mdp_complex times_i ( const mdp_complex c  )  [friend]
mdp_complex times_minus_i ( const mdp_complex c  )  [friend]

Member Data Documentation

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerator Friends Defines

Generated on Wed Dec 23 14:03:15 2009 for fermiqcd by  doxygen 1.6.1