thepeg
is hosted by
Hepforge
,
IPPP Durham
ThePEG
2.2.1
Vectors
SpinHalfLorentzRotation.h
1
// -*- C++ -*-
2
//
3
// SpinHalfLorentzRotation.h is a part of ThePEG - Toolkit for HEP Event Generation
4
// Copyright (C) 1999-2019 Leif Lonnblad
5
//
6
// ThePEG is licenced under version 3 of the GPL, see COPYING for details.
7
// Please respect the MCnet academic guidelines, see GUIDELINES for details.
8
//
9
#ifndef THEPEG_SpinHalfLorentzRotation_H
10
#define THEPEG_SpinHalfLorentzRotation_H
11
//
12
// This is the declaration of the SpinHalfLorentzRotation class.
13
//
14
#include "
ThePEG/Helicity/HelicityDefinitions.h
"
15
#include "
ThreeVector.h
"
16
17
namespace
ThePEG
{
18
31
class
SpinHalfLorentzRotation
{
32
36
friend
SpinHalfLorentzRotation
inverseOf
(
const
SpinHalfLorentzRotation
& lt );
37
38
public
:
39
42
46
SpinHalfLorentzRotation
();
47
55
SpinHalfLorentzRotation
(
double
bx,
double
by,
double
bz,
double
gamma=-1.);
56
62
SpinHalfLorentzRotation
(
const
Boost
& b,
double
gamma=-1.);
64
68
bool
isIdentity
()
const
;
69
73
SpinHalfLorentzRotation
inverse
()
const
;
74
78
SpinHalfLorentzRotation
&
invert
() {
return
*
this
=
inverse
(); }
79
83
std::ostream &
print
( std::ostream & os )
const
;
84
87
95
SpinHalfLorentzRotation
&
setBoost
(
double
bx,
double
by,
double
bz,
double
gamma=-1.);
96
102
SpinHalfLorentzRotation
&
setBoost
(
const
Boost
& b,
double
gamma=-1.);
103
108
SpinHalfLorentzRotation
&
setBoostX
(
double
&
boost
);
109
114
SpinHalfLorentzRotation
&
setBoostY
(
double
& boost);
115
120
SpinHalfLorentzRotation
&
setBoostZ
(
double
& boost);
121
127
SpinHalfLorentzRotation
&
setRotate
(
double
delta,
const
Axis
& axis);
128
133
SpinHalfLorentzRotation
&
setRotateX
(
double
& angle);
134
139
SpinHalfLorentzRotation
&
setRotateY
(
double
& angle);
140
145
SpinHalfLorentzRotation
&
setRotateZ
(
double
& angle);
146
148
149
155
Complex
s1s1
()
const
{
return
_mx
[0][0]; }
156
160
Complex
s1s2
()
const
{
return
_mx
[0][1]; }
161
165
Complex
s1s3
()
const
{
return
_mx
[0][2]; }
166
170
Complex
s1s4
()
const
{
return
_mx
[0][3]; }
171
175
Complex
s2s1
()
const
{
return
_mx
[1][0]; }
176
180
Complex
s2s2
()
const
{
return
_mx
[1][1]; }
181
185
Complex
s2s3
()
const
{
return
_mx
[1][2]; }
186
190
Complex
s2s4
()
const
{
return
_mx
[1][3]; }
191
195
Complex
s3s1
()
const
{
return
_mx
[2][0]; }
196
200
Complex
s3s2
()
const
{
return
_mx
[2][1]; }
201
205
Complex
s3s3
()
const
{
return
_mx
[2][2]; }
206
210
Complex
s3s4
()
const
{
return
_mx
[2][3]; }
211
215
Complex
s4s1
()
const
{
return
_mx
[3][0]; }
216
220
Complex
s4s2
()
const
{
return
_mx
[3][1]; }
221
225
Complex
s4s3
()
const
{
return
_mx
[3][2]; }
226
230
Complex
s4s4
()
const
{
return
_mx
[3][3]; }
231
235
Complex
operator()
(
unsigned
int
i,
unsigned
int
j)
const
{
236
assert(i<=3 && j<=3);
237
return
_mx
[i][j];
238
}
240
241
244
249
SpinHalfLorentzRotation
operator *
(
const
SpinHalfLorentzRotation
& lt)
const
;
250
254
SpinHalfLorentzRotation
&
operator *=
(
const
SpinHalfLorentzRotation
& );
255
259
SpinHalfLorentzRotation
&
transform
(
const
SpinHalfLorentzRotation
& );
260
264
SpinHalfLorentzRotation
&
rotateX
(
double
delta);
265
269
SpinHalfLorentzRotation
&
rotateY
(
double
delta);
270
274
SpinHalfLorentzRotation
&
rotateZ
(
double
delta);
275
279
SpinHalfLorentzRotation
&
rotate
(
double
delta,
const
Axis
& axis);
280
284
SpinHalfLorentzRotation
&
boostX
(
double
beta);
285
289
SpinHalfLorentzRotation
&
boostY
(
double
beta);
290
294
SpinHalfLorentzRotation
&
boostZ
(
double
beta);
295
303
SpinHalfLorentzRotation
&
boost
(
double
bx,
double
by,
double
bz,
double
gamma=-1.);
304
310
SpinHalfLorentzRotation
&
boost
(
const
Boost
& bv,
double
gamma=-1.);
312
313
protected
:
314
319
SpinHalfLorentzRotation
(
Complex
s1s1
,
Complex
s1s2
,
Complex
s1s3
,
Complex
s1s4
,
320
Complex
s2s1
,
Complex
s2s2
,
Complex
s2s3
,
Complex
s2s4
,
321
Complex
s3s1
,
Complex
s3s2
,
Complex
s3s3
,
Complex
s3s4
,
322
Complex
s4s1
,
Complex
s4s2
,
Complex
s4s3
,
Complex
s4s4
);
323
324
private
:
325
326
using
MatrixT = array<array<Complex,4>,4>;
327
328
SpinHalfLorentzRotation
(
const
MatrixT & m) :
_mx
(m) {}
329
333
MatrixT
_mx
;
334
};
335
339
inline
SpinHalfLorentzRotation
inverseOf
(
const
SpinHalfLorentzRotation
& lt ) {
340
return
lt.
inverse
();
341
}
342
346
inline
std::ostream &
operator<<
( std::ostream & os,
347
const
SpinHalfLorentzRotation
& lt ) {
348
return
lt.
print
(os);
349
}
350
351
}
352
353
#endif
/* THEPEG_SpinHalfLorentzRotation_H */
ThePEG::SpinHalfLorentzRotation::s4s4
Complex s4s4() const
The component.
Definition:
SpinHalfLorentzRotation.h:230
ThePEG::SpinHalfLorentzRotation::s1s1
Complex s1s1() const
The component.
Definition:
SpinHalfLorentzRotation.h:155
ThePEG::SpinHalfLorentzRotation::boostY
SpinHalfLorentzRotation & boostY(double beta)
Pure boost along the y-axis; equivalent to LT = BoostX(beta) * LT.
ThePEG::Complex
std::complex< double > Complex
ThePEG code should use Complex for all complex scalars.
Definition:
Complex.h:23
ThePEG::SpinHalfLorentzRotation::setBoostZ
SpinHalfLorentzRotation & setBoostZ(double &boost)
Specify a boost by the given factor along the z-axis.
ThePEG::SpinHalfLorentzRotation::isIdentity
bool isIdentity() const
Returns true if the Identity matrix.
ThePEG::SpinHalfLorentzRotation::rotateY
SpinHalfLorentzRotation & rotateY(double delta)
Rotation around the y-axis; equivalent to LT = RotationY(delta) * LT.
ThePEG::SpinHalfLorentzRotation::s1s4
Complex s1s4() const
The component.
Definition:
SpinHalfLorentzRotation.h:170
ThePEG::SpinHalfLorentzRotation::setBoostY
SpinHalfLorentzRotation & setBoostY(double &boost)
Specify a boost by the given factor along the y-axis.
ThePEG::SpinHalfLorentzRotation::s4s1
Complex s4s1() const
The component.
Definition:
SpinHalfLorentzRotation.h:215
HelicityDefinitions.h
This file contains enumerations used by LorentzSpinor and LorentzSpinorBar classes.
ThePEG::SpinHalfLorentzRotation::s3s1
Complex s3s1() const
The component.
Definition:
SpinHalfLorentzRotation.h:195
ThePEG::ThreeVector
A 3-component vector.
Definition:
ThreeVector.h:34
ThePEG::SpinHalfLorentzRotation::inverse
SpinHalfLorentzRotation inverse() const
Return the inverse.
ThePEG::SpinHalfLorentzRotation::rotateX
SpinHalfLorentzRotation & rotateX(double delta)
Rotation around the x-axis; equivalent to LT = RotationX(delta) * LT.
ThePEG
This is the main namespace within which all identifiers in ThePEG are declared.
Definition:
FactoryBase.h:28
ThePEG::SpinHalfLorentzRotation::s2s3
Complex s2s3() const
The component.
Definition:
SpinHalfLorentzRotation.h:185
ThePEG::SpinHalfLorentzRotation::_mx
MatrixT _mx
The members of the transformation matrix.
Definition:
SpinHalfLorentzRotation.h:333
ThePEG::SpinHalfLorentzRotation::inverseOf
friend SpinHalfLorentzRotation inverseOf(const SpinHalfLorentzRotation <)
The external inverseOf needs to be a friend.
Definition:
SpinHalfLorentzRotation.h:339
ThePEG::SpinHalfLorentzRotation::s3s3
Complex s3s3() const
The component.
Definition:
SpinHalfLorentzRotation.h:205
ThePEG::SpinHalfLorentzRotation::transform
SpinHalfLorentzRotation & transform(const SpinHalfLorentzRotation &)
Transform (similar to *= but a.transform(b) becomes a = b*a.
ThePEG::SpinHalfLorentzRotation::setBoostX
SpinHalfLorentzRotation & setBoostX(double &boost)
Specify a boost by the given factor along the x-axis.
ThePEG::SpinHalfLorentzRotation::s4s2
Complex s4s2() const
The component.
Definition:
SpinHalfLorentzRotation.h:220
ThePEG::SpinHalfLorentzRotation::SpinHalfLorentzRotation
SpinHalfLorentzRotation()
Default constructor.
ThePEG::SpinHalfLorentzRotation::s4s3
Complex s4s3() const
The component.
Definition:
SpinHalfLorentzRotation.h:225
ThreeVector.h
contains the ThreeVector class.
ThePEG::SpinHalfLorentzRotation::s2s4
Complex s2s4() const
The component.
Definition:
SpinHalfLorentzRotation.h:190
ThePEG::SpinHalfLorentzRotation::s3s4
Complex s3s4() const
The component.
Definition:
SpinHalfLorentzRotation.h:210
ThePEG::SpinHalfLorentzRotation::setRotateZ
SpinHalfLorentzRotation & setRotateZ(double &angle)
Specify a rotation by the given angle about the z-axis.
ThePEG::SpinHalfLorentzRotation::setRotate
SpinHalfLorentzRotation & setRotate(double delta, const Axis &axis)
Specify a rotation about a general axis by the angle given.
ThePEG::SpinHalfLorentzRotation::invert
SpinHalfLorentzRotation & invert()
Inverts the SpinHalfLorentzRotation matrix.
Definition:
SpinHalfLorentzRotation.h:78
ThePEG::SpinHalfLorentzRotation::s1s2
Complex s1s2() const
The component.
Definition:
SpinHalfLorentzRotation.h:160
ThePEG::SpinHalfLorentzRotation::boostX
SpinHalfLorentzRotation & boostX(double beta)
Pure boost along the x-axis; equivalent to LT = BoostX(beta) * LT.
ThePEG::SpinHalfLorentzRotation::setRotateX
SpinHalfLorentzRotation & setRotateX(double &angle)
Specify a rotation by the given angle about the x-axis.
ThePEG::SpinHalfLorentzRotation::operator*
SpinHalfLorentzRotation operator*(const SpinHalfLorentzRotation <) const
Product of two SpinHalfLorentzRotations (this) * lt - matrix multiplication.
ThePEG::SpinHalfLorentzRotation::boostZ
SpinHalfLorentzRotation & boostZ(double beta)
Pure boost along the z-axis; equivalent to LT = BoostX(beta) * LT.
ThePEG::SpinHalfLorentzRotation::operator()
Complex operator()(unsigned int i, unsigned int j) const
Fortran style subscript operator.
Definition:
SpinHalfLorentzRotation.h:235
ThePEG::SpinHalfLorentzRotation::s2s1
Complex s2s1() const
The component.
Definition:
SpinHalfLorentzRotation.h:175
ThePEG::SpinHalfLorentzRotation::boost
SpinHalfLorentzRotation & boost(double bx, double by, double bz, double gamma=-1.)
General boost equivalent to LT = Boost(bx,by,bz) * LT.
ThePEG::SpinHalfLorentzRotation::setRotateY
SpinHalfLorentzRotation & setRotateY(double &angle)
Specify a rotation by the given angle about the y-axis.
ThePEG::SpinHalfLorentzRotation::rotateZ
SpinHalfLorentzRotation & rotateZ(double delta)
Rotation around the z-axis; equivalent to LT = RotationZ(delta) * LT.
ThePEG::operator<<
vector< T > & operator<<(vector< T > &tv, const U &u)
Overload the left shift operator for vector to push_back objects to a vector.
Definition:
Containers.h:179
ThePEG::SpinHalfLorentzRotation
The SpinHalfLorentzRotation class is designed to offer the same features as the HepLorentzRotation cl...
Definition:
SpinHalfLorentzRotation.h:31
ThePEG::SpinHalfLorentzRotation::s3s2
Complex s3s2() const
The component.
Definition:
SpinHalfLorentzRotation.h:200
ThePEG::SpinHalfLorentzRotation::print
std::ostream & print(std::ostream &os) const
output operator
ThePEG::SpinHalfLorentzRotation::s2s2
Complex s2s2() const
The component.
Definition:
SpinHalfLorentzRotation.h:180
ThePEG::SpinHalfLorentzRotation::operator*=
SpinHalfLorentzRotation & operator*=(const SpinHalfLorentzRotation &)
Multiply by and assign a*=b becomes a= a*b.
ThePEG::SpinHalfLorentzRotation::rotate
SpinHalfLorentzRotation & rotate(double delta, const Axis &axis)
Rotation around specified vector - LT = Rotation(delta,axis)*LT.
ThePEG::SpinHalfLorentzRotation::setBoost
SpinHalfLorentzRotation & setBoost(double bx, double by, double bz, double gamma=-1.)
Specify the components of a Lorentz Boost.
ThePEG::SpinHalfLorentzRotation::s1s3
Complex s1s3() const
The component.
Definition:
SpinHalfLorentzRotation.h:165
Generated on Sat Apr 11 2020 14:31:17 for ThePEG by
1.8.13