BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtVector3C Class Reference

#include <EvtVector3C.hh>

Public Member Functions

 EvtVector3C ()
 EvtVector3C (const EvtComplex &, const EvtComplex &, const EvtComplex &)
virtual ~EvtVector3C ()
void set (const int, const EvtComplex &)
void set (const EvtComplex &, const EvtComplex &, const EvtComplex &)
void set (double, double, double)
EvtVector3Coperator*= (const EvtComplex &c)
EvtVector3Coperator/= (const EvtComplex &c)
EvtVector3Coperator+= (const EvtVector3C &v2)
EvtVector3Coperator-= (const EvtVector3C &v2)
 EvtVector3C (const EvtVector3R &v1)
void applyRotateEuler (double phi, double theta, double ksi)
const EvtComplexget (int) const
EvtVector3C conj () const
EvtVector3C cross (const EvtVector3C &v2)
double dot (const EvtVector3C &p2)

Friends

EvtVector3C rotateEuler (const EvtVector3C &v, double phi, double theta, double ksi)
EvtVector3C operator* (const EvtComplex &c, const EvtVector3C &v2)
EvtVector3C operator* (const EvtComplex &c, const EvtVector3R &v2)
EvtComplex operator* (const EvtVector3R &v1, const EvtVector3C &v2)
EvtComplex operator* (const EvtVector3C &v1, const EvtVector3R &v2)
EvtComplex operator* (const EvtVector3C &v1, const EvtVector3C &v2)
EvtVector3C operator+ (const EvtVector3C &v1, const EvtVector3C &v2)
EvtVector3C operator- (const EvtVector3C &v1, const EvtVector3C &v2)
EvtVector3C operator* (const EvtVector3C &v1, const EvtComplex &c)
std::ostream & operator<< (std::ostream &c, const EvtVector3C &v)

Detailed Description

Definition at line 29 of file EvtVector3C.hh.

Constructor & Destructor Documentation

◆ EvtVector3C() [1/3]

EvtVector3C::EvtVector3C ( )

Definition at line 28 of file EvtVector3C.cc.

28 {
29
30 v[0] = EvtComplex( 0.0 );
31 v[1] = EvtComplex( 0.0 );
32 v[2] = EvtComplex( 0.0 );
33}

Referenced by conj(), cross(), dot(), operator*, operator*, operator*, operator*, operator*, operator*, operator*=(), operator+, operator+=(), operator-, operator-=(), operator/=(), operator<<, and rotateEuler.

◆ EvtVector3C() [2/3]

EvtVector3C::EvtVector3C ( const EvtComplex & e1,
const EvtComplex & e2,
const EvtComplex & e3 )

Definition at line 37 of file EvtVector3C.cc.

37 {
38
39 v[0] = e1;
40 v[1] = e2;
41 v[2] = e3;
42}
Double_t e1
Double_t e2

◆ ~EvtVector3C()

EvtVector3C::~EvtVector3C ( )
virtual

Definition at line 35 of file EvtVector3C.cc.

35{ return; }

◆ EvtVector3C() [3/3]

EvtVector3C::EvtVector3C ( const EvtVector3R & v1)
inline

Definition at line 65 of file EvtVector3C.hh.

65 {
66
67 v[0] = EvtComplex( v1.get( 0 ), 0.0 );
68 v[1] = EvtComplex( v1.get( 1 ), 0.0 );
69 v[2] = EvtComplex( v1.get( 2 ), 0.0 );
70}
double get(int i) const

Member Function Documentation

◆ applyRotateEuler()

void EvtVector3C::applyRotateEuler ( double phi,
double theta,
double ksi )

Definition at line 64 of file EvtVector3C.cc.

64 {
65
66 EvtComplex temp[3];
67 double sp, st, sk, cp, ct, ck;
68
69 sp = sin( phi );
70 st = sin( theta );
71 sk = sin( ksi );
72 cp = cos( phi );
73 ct = cos( theta );
74 ck = cos( ksi );
75
76 temp[0] =
77 ( ck * ct * cp - sk * sp ) * v[0] + ( -sk * ct * cp - ck * sp ) * v[1] + st * cp * v[2];
78 temp[1] =
79 ( ck * ct * sp + sk * cp ) * v[0] + ( -sk * ct * sp + ck * cp ) * v[1] + st * sp * v[2];
80 temp[2] = -ck * st * v[0] + sk * st * v[1] + ct * v[2];
81
82 v[0] = temp[0];
83 v[1] = temp[1];
84 v[2] = temp[2];
85}

Referenced by rotateEuler.

◆ conj()

EvtVector3C EvtVector3C::conj ( ) const
inline

Definition at line 162 of file EvtVector3C.hh.

162 {
163
164 return EvtVector3C( ::conj( v[0] ), ::conj( v[1] ), ::conj( v[2] ) );
165}
EvtVector3C conj() const

Referenced by conj(), EvtVVP::decay(), EvtVVSPwave::decay(), and EvtSVVHelAmp::SVVHel().

◆ cross()

EvtVector3C EvtVector3C::cross ( const EvtVector3C & v2)

Definition at line 44 of file EvtVector3C.cc.

44 {
45
46 // Calcs the cross product. Added by djl on July 27, 1995.
47
48 EvtVector3C temp;
49
50 temp.v[0] = v[1] * p2.v[2] - v[2] * p2.v[1];
51 temp.v[1] = v[2] * p2.v[0] - v[0] * p2.v[2];
52 temp.v[2] = v[0] * p2.v[1] - v[1] * p2.v[0];
53
54 return temp;
55}
double p2[4]

◆ dot()

double EvtVector3C::dot ( const EvtVector3C & p2)

◆ get()

const EvtComplex & EvtVector3C::get ( int i) const
inline

Definition at line 88 of file EvtVector3C.hh.

88{ return v[i]; }

Referenced by EvtTensor3C::directProd, and EvtTensor3C::directProd.

◆ operator*=()

EvtVector3C & EvtVector3C::operator*= ( const EvtComplex & c)
inline

Definition at line 90 of file EvtVector3C.hh.

90 {
91
92 v[0] *= c;
93 v[1] *= c;
94 v[2] *= c;
95 return *this;
96}

◆ operator+=()

EvtVector3C & EvtVector3C::operator+= ( const EvtVector3C & v2)
inline

Definition at line 106 of file EvtVector3C.hh.

106 {
107
108 v[0] += v2.v[0];
109 v[1] += v2.v[1];
110 v[2] += v2.v[2];
111 return *this;
112}

◆ operator-=()

EvtVector3C & EvtVector3C::operator-= ( const EvtVector3C & v2)
inline

Definition at line 114 of file EvtVector3C.hh.

114 {
115
116 v[0] -= v2.v[0];
117 v[1] -= v2.v[1];
118 v[2] -= v2.v[2];
119 return *this;
120}

◆ operator/=()

EvtVector3C & EvtVector3C::operator/= ( const EvtComplex & c)
inline

Definition at line 98 of file EvtVector3C.hh.

98 {
99
100 v[0] /= c;
101 v[1] /= c;
102 v[2] /= c;
103 return *this;
104}

◆ set() [1/3]

void EvtVector3C::set ( const EvtComplex & x,
const EvtComplex & y,
const EvtComplex & z )
inline

Definition at line 74 of file EvtVector3C.hh.

74 {
75
76 v[0] = x;
77 v[1] = y;
78 v[2] = z;
79}
Double_t x[10]

◆ set() [2/3]

void EvtVector3C::set ( const int i,
const EvtComplex & c )
inline

Definition at line 72 of file EvtVector3C.hh.

72{ v[i] = c; }

Referenced by EvtTensor3C::cont1(), EvtTensor3C::cont1(), EvtTensor3C::cont2(), and EvtTensor3C::cont2().

◆ set() [3/3]

void EvtVector3C::set ( double x,
double y,
double z )
inline

Definition at line 81 of file EvtVector3C.hh.

81 {
82
83 v[0] = EvtComplex( x );
84 v[1] = EvtComplex( y );
85 v[2] = EvtComplex( z );
86}

◆ operator* [1/6]

EvtVector3C operator* ( const EvtComplex & c,
const EvtVector3C & v2 )
friend

Definition at line 137 of file EvtVector3C.hh.

137 {
138
139 return EvtVector3C( v2 ) *= c;
140}

◆ operator* [2/6]

EvtVector3C operator* ( const EvtComplex & c,
const EvtVector3R & v2 )
friend

Definition at line 142 of file EvtVector3C.hh.

142 {
143
144 return EvtVector3C( v2 ) *= c;
145}

◆ operator* [3/6]

EvtVector3C operator* ( const EvtVector3C & v1,
const EvtComplex & c )
friend

Definition at line 132 of file EvtVector3C.hh.

132 {
133
134 return EvtVector3C( v1 ) *= c;
135}

◆ operator* [4/6]

EvtComplex operator* ( const EvtVector3C & v1,
const EvtVector3C & v2 )
friend

Definition at line 157 of file EvtVector3C.hh.

157 {
158
159 return v1.v[0] * v2.v[0] + v1.v[1] * v2.v[1] + v1.v[2] * v2.v[2];
160}

◆ operator* [5/6]

EvtComplex operator* ( const EvtVector3C & v1,
const EvtVector3R & v2 )
friend

Definition at line 152 of file EvtVector3C.hh.

152 {
153
154 return v1.v[0] * v2.get( 0 ) + v1.v[1] * v2.get( 1 ) + v1.v[2] * v2.get( 2 );
155}

◆ operator* [6/6]

EvtComplex operator* ( const EvtVector3R & v1,
const EvtVector3C & v2 )
friend

Definition at line 147 of file EvtVector3C.hh.

147 {
148
149 return v1.get( 0 ) * v2.v[0] + v1.get( 1 ) * v2.v[1] + v1.get( 2 ) * v2.v[2];
150}

◆ operator+

EvtVector3C operator+ ( const EvtVector3C & v1,
const EvtVector3C & v2 )
friend

Definition at line 122 of file EvtVector3C.hh.

122 {
123
124 return EvtVector3C( v1 ) += v2;
125}

◆ operator-

EvtVector3C operator- ( const EvtVector3C & v1,
const EvtVector3C & v2 )
friend

Definition at line 127 of file EvtVector3C.hh.

127 {
128
129 return EvtVector3C( v1 ) -= v2;
130}

◆ operator<<

std::ostream & operator<< ( std::ostream & c,
const EvtVector3C & v )
friend

◆ rotateEuler

EvtVector3C rotateEuler ( const EvtVector3C & v,
double phi,
double theta,
double ksi )
friend

Definition at line 57 of file EvtVector3C.cc.

57 {
58
59 EvtVector3C tmp( v );
60 tmp.applyRotateEuler( alpha, beta, gamma );
61 return tmp;
62}
double alpha

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