00001
00002
00003
00004
00005
00006
00007
00008
00009 #ifndef THEPEG_SpinHalfLorentzRotation_H
00010 #define THEPEG_SpinHalfLorentzRotation_H
00011
00012
00013
00014 #include "ThePEG/Helicity/HelicityDefinitions.h"
00015 #include "ThreeVector.h"
00016
00017 namespace ThePEG {
00018
00031 class SpinHalfLorentzRotation {
00032
00036 friend SpinHalfLorentzRotation inverseOf ( const SpinHalfLorentzRotation & lt );
00037
00038 public:
00039
00042
00046 SpinHalfLorentzRotation();
00047
00055 SpinHalfLorentzRotation (double bx, double by, double bz, double gamma=-1.);
00056
00062 SpinHalfLorentzRotation (const Boost & b,double gamma=-1.);
00064
00068 bool isIdentity() const;
00069
00073 SpinHalfLorentzRotation inverse() const;
00074
00078 SpinHalfLorentzRotation & invert() { return *this = inverse(); }
00079
00083 std::ostream & print( std::ostream & os ) const;
00084
00087
00095 SpinHalfLorentzRotation & setBoost (double bx, double by, double bz,double gamma=-1.);
00096
00102 SpinHalfLorentzRotation & setBoost (const Boost & b,double gamma=-1.);
00103
00108 SpinHalfLorentzRotation & setBoostX (double & boost);
00109
00114 SpinHalfLorentzRotation & setBoostY (double & boost);
00115
00120 SpinHalfLorentzRotation & setBoostZ (double & boost);
00121
00127 SpinHalfLorentzRotation & setRotate(double delta, const Axis & axis);
00128
00133 SpinHalfLorentzRotation & setRotateX (double & angle);
00134
00139 SpinHalfLorentzRotation & setRotateY (double & angle);
00140
00145 SpinHalfLorentzRotation & setRotateZ (double & angle);
00146
00148
00149
00155 Complex s1s1() const { return _mx[0][0]; }
00156
00160 Complex s1s2() const { return _mx[0][1]; }
00161
00165 Complex s1s3() const { return _mx[0][2]; }
00166
00170 Complex s1s4() const { return _mx[0][3]; }
00171
00175 Complex s2s1() const { return _mx[1][0]; }
00176
00180 Complex s2s2() const { return _mx[1][1]; }
00181
00185 Complex s2s3() const { return _mx[1][2]; }
00186
00190 Complex s2s4() const { return _mx[1][3]; }
00191
00195 Complex s3s1() const { return _mx[2][0]; }
00196
00200 Complex s3s2() const { return _mx[2][1]; }
00201
00205 Complex s3s3() const { return _mx[2][2]; }
00206
00210 Complex s3s4() const { return _mx[2][3]; }
00211
00215 Complex s4s1() const { return _mx[3][0]; }
00216
00220 Complex s4s2() const { return _mx[3][1]; }
00221
00225 Complex s4s3() const { return _mx[3][2]; }
00226
00230 Complex s4s4() const { return _mx[3][3]; }
00231
00235 Complex operator()(unsigned int i, unsigned int j) const {
00236 assert(i<=3 && j<=3);
00237 return _mx[i][j];
00238 }
00240
00241
00244
00249 SpinHalfLorentzRotation operator * (const SpinHalfLorentzRotation & lt) const;
00250
00254 SpinHalfLorentzRotation & operator *= (const SpinHalfLorentzRotation & );
00255
00259 SpinHalfLorentzRotation & transform (const SpinHalfLorentzRotation & );
00260
00264 SpinHalfLorentzRotation & rotateX(double delta);
00265
00269 SpinHalfLorentzRotation & rotateY(double delta);
00270
00274 SpinHalfLorentzRotation & rotateZ(double delta);
00275
00279 SpinHalfLorentzRotation & rotate(double delta, const Axis & axis);
00280
00284 SpinHalfLorentzRotation & boostX(double beta);
00285
00289 SpinHalfLorentzRotation & boostY(double beta);
00290
00294 SpinHalfLorentzRotation & boostZ(double beta);
00295
00303 SpinHalfLorentzRotation & boost(double bx, double by, double bz, double gamma=-1.);
00304
00310 SpinHalfLorentzRotation & boost(const Boost & bv, double gamma=-1.);
00312
00313 protected:
00314
00319 SpinHalfLorentzRotation(Complex s1s1,Complex s1s2,Complex s1s3,Complex s1s4,
00320 Complex s2s1,Complex s2s2,Complex s2s3,Complex s2s4,
00321 Complex s3s1,Complex s3s2,Complex s3s3,Complex s3s4,
00322 Complex s4s1,Complex s4s2,Complex s4s3,Complex s4s4);
00323
00324 private:
00325
00326
00330 vector<vector<Complex> > _mx;
00331 };
00332
00336 inline SpinHalfLorentzRotation inverseOf ( const SpinHalfLorentzRotation & lt ) {
00337 return lt.inverse();
00338 }
00339
00343 inline std::ostream & operator<< ( std::ostream & os,
00344 const SpinHalfLorentzRotation& lt ) {
00345 return lt.print(os);
00346 }
00347
00348 }
00349
00350 #endif