CGEM BOSS 6.6.5.h
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtRaritaSchwinger.cc
Go to the documentation of this file.
1//--------------------------------------------------------------------------
2//
3// Environment:
4// This software is part of the EvtGen package developed jointly
5// for the BaBar and CLEO collaborations. If you use all or part
6// of it, please give an appropriate acknowledgement.
7//
8// Copyright Information: See EvtGen/COPYRIGHT
9// Copyright (C) 2000 Caltech, UCSB
10//
11// Module: EvtGen/EvtRaritaSchwing.hh
12//
13// Description:Class to handle spin 3/2
14//
15// Modification history:
16//
17// RYD April 23, 2000 Module created
18//
19//------------------------------------------------------------------------
21
22
24using std::endl;
25using std::ostream;
26
29
30
32 double alpha,double beta,double gamma){
33
34 EvtRaritaSchwinger tmp(rs);
35 tmp.applyRotateEuler(alpha,beta,gamma);
36 return tmp;
37
38}
39
41 const EvtVector4R p4){
42
43 EvtRaritaSchwinger tmp(rs);
44 tmp.applyBoostTo(p4);
45 return tmp;
46
47}
48
50 const EvtVector3R boost){
52 EvtRaritaSchwinger tmp(rs);
53 tmp.applyBoostTo(boost);
54 return tmp;
55
58
59void EvtRaritaSchwinger::set(int i,int j,const EvtComplex& sp){_rs[i][j]=sp;}
60
61EvtComplex EvtRaritaSchwinger::get(int i,int j) const {return _rs[i][j];}
62
64 double gamma){
65
66 //inefficient but simple to code...
71 v0.applyRotateEuler(alpha,beta,gamma);
72 v1.applyRotateEuler(alpha,beta,gamma);
73 v2.applyRotateEuler(alpha,beta,gamma);
74 v3.applyRotateEuler(alpha,beta,gamma);
75 setVector(0,v0);
76 setVector(1,v1);
77 setVector(2,v2);
78 setVector(3,v3);
83 sp0.applyRotateEuler(alpha,beta,gamma);
84 sp1.applyRotateEuler(alpha,beta,gamma);
85 sp2.applyRotateEuler(alpha,beta,gamma);
86 sp3.applyRotateEuler(alpha,beta,gamma);
87 setSpinor(0,sp0);
88 setSpinor(1,sp1);
89 setSpinor(2,sp2);
90 setSpinor(3,sp3);
91
92}
93
94
96
97 double e=p4.get(0);
98
99 EvtVector3R boost(p4.get(1)/e,p4.get(2)/e,p4.get(3)/e);
100
101 applyBoostTo(boost);
102
103 return;
104
105}
106
107
109
110 //inefficient but simple to code...
115 v0.applyBoostTo(boost);
116 v1.applyBoostTo(boost);
117 v2.applyBoostTo(boost);
118 v3.applyBoostTo(boost);
119 setVector(0,v0);
120 setVector(1,v1);
121 setVector(2,v2);
122 setVector(3,v3);
127 sp0.applyBoostTo(boost);
128 sp1.applyBoostTo(boost);
129 sp2.applyBoostTo(boost);
130 sp3.applyBoostTo(boost);
131 setSpinor(0,sp0);
132 setSpinor(1,sp1);
133 setSpinor(2,sp2);
134 setSpinor(3,sp3);
135
136
137}
138
139
140ostream& operator<<(ostream& s, const EvtRaritaSchwinger& rs){
141
142 int i,j;
143 s<< endl;
144 for(i=0;i<4;i++){
145 for(j=0;j<4;j++){
146 s << rs._rs[i][j];
147 }
148 s << endl;
149 }
150 return s;
151
152}
153
154
155
157
158 EvtVector4C tmp(_rs[i][0],_rs[i][1],_rs[i][2],_rs[i][3]);
159 return tmp;
160
161}
162
164
165 EvtDiracSpinor tmp;
166 tmp.set(_rs[0][i],_rs[1][i],_rs[2][i],_rs[3][i]);
167 return tmp;
168
169}
170
172
173 _rs[i][0]=v.get(0);
174 _rs[i][1]=v.get(1);
175 _rs[i][2]=v.get(2);
176 _rs[i][3]=v.get(3);
177
178}
179
181
182 _rs[0][i]=sp.get_spinor(0);
183 _rs[1][i]=sp.get_spinor(1);
184 _rs[2][i]=sp.get_spinor(2);
185 _rs[3][i]=sp.get_spinor(3);
186
187}
188
189
191
192 int i,j;
193
195
196 for(i=0;i<4;i++){
197 for(j=0;j<4;j++){
198 tmp._rs[i][j]=u.get_spinor(i)*v.get(j);
199 }
200 }
201
202 return tmp;
203
204}
205
206
208
209 int i,j;
210
212
213 for(i=0;i<4;i++){
214 for(j=0;j<4;j++){
215 tmp._rs[i][j]=u.get_spinor(i)*v.get(j);
216 }
217 }
218
219 return tmp;
220
221}
222
223
225 const EvtRaritaSchwinger& u2){
226
227 int i,j;
228 EvtComplex tmp=0.0;
229
230 for(i=0;i<4;i++){
231 for(j=0;j<4;j++){
232 tmp+=conj(u1._rs[i][j])*u2._rs[i][j];
233 }
234 }
235
236 return tmp;
237
238}
239
240
241
243
244 int i,j;
245
246 for(i=0;i<4;i++){
247 for(j=0;j<4;j++){
248 _rs[i][j]+=u2._rs[i][j];
249 }
250 }
251
252 return *this;
253}
254
256 const EvtRaritaSchwinger& u2){
257
258 return EvtRaritaSchwinger(u1)+=u2;
259
260}
261
263
264 int i,j;
265
266 for(i=0;i<4;i++){
267 for(j=0;j<4;j++){
268 _rs[i][j]+=u2._rs[i][j];
269 }
270 }
271
272 return *this;
273}
274
276 const EvtRaritaSchwinger& u2){
277
278 return EvtRaritaSchwinger(u1)-=u2;
279
280}
281
282
283
Evt3Rank3C conj(const Evt3Rank3C &t2)
EvtRaritaSchwinger operator+(const EvtRaritaSchwinger &u1, const EvtRaritaSchwinger &u2)
EvtRaritaSchwinger boostTo(const EvtRaritaSchwinger &rs, const EvtVector4R p4)
EvtRaritaSchwinger rotateEuler(const EvtRaritaSchwinger &rs, double alpha, double beta, double gamma)
EvtRaritaSchwinger operator-(const EvtRaritaSchwinger &u1, const EvtRaritaSchwinger &u2)
EvtComplex operator*(const EvtRaritaSchwinger &u1, const EvtRaritaSchwinger &u2)
ostream & operator<<(ostream &s, const EvtRaritaSchwinger &rs)
EvtRaritaSchwinger dirProd(EvtVector4R v, EvtDiracSpinor u)
const double alpha
XmlRpcServer s
**********Class see also m_nmax DOUBLE PRECISION m_amel DOUBLE PRECISION m_x2 DOUBLE PRECISION m_alfinv DOUBLE PRECISION m_Xenph INTEGER m_KeyWtm INTEGER m_idyfs DOUBLE PRECISION m_zini DOUBLE PRECISION m_q2 DOUBLE PRECISION m_Wt_KF DOUBLE PRECISION m_WtCut INTEGER m_KFfin *COMMON c_KarLud $ !Input CMS energy[GeV] $ !CMS energy after beam spread beam strahlung[GeV] $ !Beam energy spread[GeV] $ !z boost due to beam spread $ !electron beam mass *ff pair spectrum $ !minimum v
Definition KarLud.h:35
const EvtComplex & get_spinor(int i) const
void set(const EvtComplex &sp0, const EvtComplex &sp1, const EvtComplex &sp2, const EvtComplex &sp3)
void applyRotateEuler(double alpha, double beta, double gamma)
void applyBoostTo(const EvtVector4R &p4)
EvtDiracSpinor getSpinor(int i) const
void applyRotateEuler(double alpha, double beta, double gamma)
void setSpinor(int i, const EvtDiracSpinor &sp)
void set(int i, int j, const EvtComplex &sp)
EvtComplex get(int i, int j) const
EvtRaritaSchwinger & operator+=(const EvtRaritaSchwinger &u2)
EvtRaritaSchwinger & operator-=(const EvtRaritaSchwinger &u2)
void setVector(int i, const EvtVector4C &v)
void applyBoostTo(const EvtVector4R p4)
EvtVector4C getVector(int i) const
void applyRotateEuler(double alpha, double beta, double gamma)
void applyBoostTo(const EvtVector4R &p4)
double get(int i) const