My Project
Loading...
Searching...
No Matches
Public Member Functions | Data Fields
ap::complex Class Reference

#include <ap.h>

Public Member Functions

 complex ()
 
 complex (const double &_x)
 
 complex (const double &_x, const double &_y)
 
 complex (const complex &z)
 
complexoperator= (const double &v)
 
complexoperator+= (const double &v)
 
complexoperator-= (const double &v)
 
complexoperator*= (const double &v)
 
complexoperator/= (const double &v)
 
complexoperator= (const complex &z)
 
complexoperator+= (const complex &z)
 
complexoperator-= (const complex &z)
 
complexoperator*= (const complex &z)
 
complexoperator/= (const complex &z)
 
 complex ()
 
 complex (const double &_x)
 
 complex (const double &_x, const double &_y)
 
 complex (const complex &z)
 
complexoperator= (const double &v)
 
complexoperator+= (const double &v)
 
complexoperator-= (const double &v)
 
complexoperator*= (const double &v)
 
complexoperator/= (const double &v)
 
complexoperator= (const complex &z)
 
complexoperator+= (const complex &z)
 
complexoperator-= (const complex &z)
 
complexoperator*= (const complex &z)
 
complexoperator/= (const complex &z)
 

Data Fields

double x
 
double y
 

Detailed Description

Definition at line 59 of file ap.h.

Constructor & Destructor Documentation

◆ complex() [1/8]

ap::complex::complex ( )
inline

Definition at line 62 of file ap.h.

62:x(0.0),y(0.0){};
double x
Definition: ap.h:100
double y
Definition: ap.h:100

◆ complex() [2/8]

ap::complex::complex ( const double &  _x)
inline

Definition at line 63 of file ap.h.

63:x(_x),y(0.0){};

◆ complex() [3/8]

ap::complex::complex ( const double &  _x,
const double &  _y 
)
inline

Definition at line 64 of file ap.h.

64:x(_x),y(_y){};

◆ complex() [4/8]

ap::complex::complex ( const complex z)
inline

Definition at line 65 of file ap.h.

65:x(z.x),y(z.y){};

◆ complex() [5/8]

ap::complex::complex ( )
inline

Definition at line 71 of file svd_si.h.

71:x(0.0),y(0.0){};

◆ complex() [6/8]

ap::complex::complex ( const double &  _x)
inline

Definition at line 72 of file svd_si.h.

72:x(_x),y(0.0){};

◆ complex() [7/8]

ap::complex::complex ( const double &  _x,
const double &  _y 
)
inline

Definition at line 73 of file svd_si.h.

73:x(_x),y(_y){};

◆ complex() [8/8]

ap::complex::complex ( const complex z)
inline

Definition at line 74 of file svd_si.h.

74:x(z.x),y(z.y){};

Member Function Documentation

◆ operator*=() [1/4]

complex & ap::complex::operator*= ( const complex z)
inline

Definition at line 76 of file ap.h.

76{ double t = x*z.x-y*z.y; y = x*z.y+y*z.x; x = t; return *this; };

◆ operator*=() [2/4]

complex & ap::complex::operator*= ( const complex z)
inline

Definition at line 85 of file svd_si.h.

85{ double t = x*z.x-y*z.y; y = x*z.y+y*z.x; x = t; return *this; };

◆ operator*=() [3/4]

complex & ap::complex::operator*= ( const double &  v)
inline

Definition at line 70 of file ap.h.

70{ x *= v; y *= v; return *this; };
const Variable & v
< [in] a sqrfree bivariate poly
Definition: facBivar.h:39

◆ operator*=() [4/4]

complex & ap::complex::operator*= ( const double &  v)
inline

Definition at line 79 of file svd_si.h.

79{ x *= v; y *= v; return *this; };

◆ operator+=() [1/4]

complex & ap::complex::operator+= ( const complex z)
inline

Definition at line 74 of file ap.h.

74{ x += z.x; y += z.y; return *this; };

◆ operator+=() [2/4]

complex & ap::complex::operator+= ( const complex z)
inline

Definition at line 83 of file svd_si.h.

83{ x += z.x; y += z.y; return *this; };

◆ operator+=() [3/4]

complex & ap::complex::operator+= ( const double &  v)
inline

Definition at line 68 of file ap.h.

68{ x += v; return *this; };

◆ operator+=() [4/4]

complex & ap::complex::operator+= ( const double &  v)
inline

Definition at line 77 of file svd_si.h.

77{ x += v; return *this; };

◆ operator-=() [1/4]

complex & ap::complex::operator-= ( const complex z)
inline

Definition at line 75 of file ap.h.

75{ x -= z.x; y -= z.y; return *this; };

◆ operator-=() [2/4]

complex & ap::complex::operator-= ( const complex z)
inline

Definition at line 84 of file svd_si.h.

84{ x -= z.x; y -= z.y; return *this; };

◆ operator-=() [3/4]

complex & ap::complex::operator-= ( const double &  v)
inline

Definition at line 69 of file ap.h.

69{ x -= v; return *this; };

◆ operator-=() [4/4]

complex & ap::complex::operator-= ( const double &  v)
inline

Definition at line 78 of file svd_si.h.

78{ x -= v; return *this; };

◆ operator/=() [1/4]

complex & ap::complex::operator/= ( const complex z)
inline

Definition at line 77 of file ap.h.

78 {
80 double e;
81 double f;
82 if( fabs(z.y)<fabs(z.x) )
83 {
84 e = z.y/z.x;
85 f = z.x+z.y*e;
86 result.x = (z.x+z.y*e)/f;
87 result.y = (z.y-z.x*e)/f;
88 }
89 else
90 {
91 e = z.x/z.y;
92 f = z.y+z.x*e;
93 result.x = (z.y+z.x*e)/f;
94 result.y = (-z.x+z.y*e)/f;
95 }
96 *this = result;
97 return *this;
98 };
FILE * f
Definition: checklibs.c:9
Definition: ap.h:60
return result
Definition: facAbsBiFact.cc:75

◆ operator/=() [2/4]

complex & ap::complex::operator/= ( const complex z)
inline

Definition at line 86 of file svd_si.h.

87 {
89 double e;
90 double f;
91 if( fabs(z.y)<fabs(z.x) )
92 {
93 e = z.y/z.x;
94 f = z.x+z.y*e;
95 result.x = (z.x+z.y*e)/f;
96 result.y = (z.y-z.x*e)/f;
97 }
98 else
99 {
100 e = z.x/z.y;
101 f = z.y+z.x*e;
102 result.x = (z.y+z.x*e)/f;
103 result.y = (-z.x+z.y*e)/f;
104 }
105 *this = result;
106 return *this;
107 };

◆ operator/=() [3/4]

complex & ap::complex::operator/= ( const double &  v)
inline

Definition at line 71 of file ap.h.

71{ x /= v; y /= v; return *this; };

◆ operator/=() [4/4]

complex & ap::complex::operator/= ( const double &  v)
inline

Definition at line 80 of file svd_si.h.

80{ x /= v; y /= v; return *this; };

◆ operator=() [1/4]

complex & ap::complex::operator= ( const complex z)
inline

Definition at line 73 of file ap.h.

73{ x = z.x; y = z.y; return *this; };

◆ operator=() [2/4]

complex & ap::complex::operator= ( const complex z)
inline

Definition at line 82 of file svd_si.h.

82{ x = z.x; y = z.y; return *this; };

◆ operator=() [3/4]

complex & ap::complex::operator= ( const double &  v)
inline

Definition at line 67 of file ap.h.

67{ x = v; y = 0.0; return *this; };

◆ operator=() [4/4]

complex & ap::complex::operator= ( const double &  v)
inline

Definition at line 76 of file svd_si.h.

76{ x = v; y = 0.0; return *this; };

Field Documentation

◆ x

double ap::complex::x

Definition at line 100 of file ap.h.

◆ y

double ap::complex::y

Definition at line 100 of file ap.h.


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