thepeg
is hosted by
Hepforge
,
IPPP Durham
ThePEG
2.2.1
Vectors
SpinOneLorentzRotation.h
1
// -*- C++ -*-
2
//
3
// SpinOneLorentzRotation.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_SpinOneLorentzRotation_H
10
#define ThePEG_SpinOneLorentzRotation_H
11
12
#include "
ThePEG/Helicity/HelicityDefinitions.h
"
13
#include "ThePEG/Helicity/LorentzTensor.fh"
14
#include "ThePEG/Helicity/LorentzRSSpinor.fh"
15
#include "ThePEG/Helicity/LorentzRSSpinorBar.fh"
16
#include "
ThreeVector.h
"
17
#include <vector>
18
19
namespace
ThePEG
{
20
24
class
SpinOneLorentzRotation
{
25
public
:
26
29
33
SpinOneLorentzRotation
() {
34
xx_() = yy_() = zz_() = tt_() = 1.0;
35
}
36
44
SpinOneLorentzRotation
(
double
bx,
double
by,
double
bz,
double
gamma=-1.)
45
{
46
setBoost
(bx,by,bz,gamma);
47
}
48
54
explicit
SpinOneLorentzRotation
(
const
Boost
& b,
double
gamma=-1.)
55
{
56
setBoost
(b.x(), b.y(), b.z(),gamma);
57
}
59
63
bool
isIdentity
()
const
;
64
68
SpinOneLorentzRotation
inverse
()
const
;
69
73
SpinOneLorentzRotation
&
invert
() {
return
*
this
=
inverse
(); }
74
78
std::ostream &
print
( std::ostream & os )
const
;
79
82
90
SpinOneLorentzRotation
&
setBoost
(
double
bx,
double
by,
double
bz,
double
gamma=-1.);
91
97
SpinOneLorentzRotation
&
setBoost
(
const
Boost
& b,
double
gamma=-1.) {
98
return
setBoost
(b.x(), b.y(), b.z(),gamma);
99
}
100
106
SpinOneLorentzRotation
&
setRotate
(
double
delta,
const
Axis
& axis);
107
112
SpinOneLorentzRotation
&
setRotateX
(
double
angle);
113
118
SpinOneLorentzRotation
&
setRotateY
(
double
angle);
119
124
SpinOneLorentzRotation
&
setRotateZ
(
double
angle);
125
127
130
134
double
xx
()
const
{
return
matrix_
[ 0]; }
135
139
double
xy
()
const
{
return
matrix_
[ 1]; }
140
144
double
xz
()
const
{
return
matrix_
[ 2]; }
145
149
double
xt
()
const
{
return
matrix_
[ 3]; }
150
154
double
yx
()
const
{
return
matrix_
[ 4]; }
155
159
double
yy
()
const
{
return
matrix_
[ 5]; }
160
164
double
yz
()
const
{
return
matrix_
[ 6]; }
165
169
double
yt
()
const
{
return
matrix_
[ 7]; }
170
174
double
zx
()
const
{
return
matrix_
[ 8]; }
175
179
double
zy
()
const
{
return
matrix_
[ 9]; }
180
184
double
zz
()
const
{
return
matrix_
[10]; }
185
189
double
zt
()
const
{
return
matrix_
[11]; }
190
194
double
tx
()
const
{
return
matrix_
[12]; }
195
199
double
ty
()
const
{
return
matrix_
[13]; }
200
204
double
tz
()
const
{
return
matrix_
[14]; }
205
209
double
tt
()
const
{
return
matrix_
[15]; }
211
214
218
template
<
typename
Value>
219
LorentzVector<Value>
220
operator*
(
const
LorentzVector<Value>
& v)
const
{
221
return
LorentzVector<Value>
222
(
xx
()*v.x() +
xy
()*v.y() +
xz
()*v.z() +
xt
()*v.t(),
223
yx
()*v.x() +
yy
()*v.y() +
yz
()*v.z() +
yt
()*v.t(),
224
zx
()*v.x() +
zy
()*v.y() +
zz
()*v.z() +
zt
()*v.t(),
225
tx
()*v.x() +
ty
()*v.y() +
tz
()*v.z() +
tt
()*v.t());
226
}
227
231
template
<
typename
Value>
232
Lorentz5Vector<Value>
233
operator*
(
const
Lorentz5Vector<Value>
& v)
const
{
234
return
Lorentz5Vector<Value>
235
(
xx
()*v.
x
() +
xy
()*v.y() +
xz
()*v.z() +
xt
()*v.t(),
236
yx
()*v.
x
() +
yy
()*v.y() +
yz
()*v.z() +
yt
()*v.t(),
237
zx
()*v.
x
() +
zy
()*v.y() +
zz
()*v.z() +
zt
()*v.t(),
238
tx
()*v.
x
() +
ty
()*v.y() +
tz
()*v.z() +
tt
()*v.t());
239
}
240
245
SpinOneLorentzRotation
operator *
(
const
SpinOneLorentzRotation
& lt)
const
;
246
250
SpinOneLorentzRotation
&
operator *=
(
const
SpinOneLorentzRotation
& lt) {
251
return
*
this
= *
this
* lt;
252
}
253
257
SpinOneLorentzRotation
&
transform
(
const
SpinOneLorentzRotation
& lt) {
258
return
*
this
= lt * *
this
;
259
}
260
264
SpinOneLorentzRotation
&
rotateX
(
double
delta) {
265
SpinOneLorentzRotation
tmp;
266
tmp.
setRotateX
(delta);
267
return
*
this
= tmp * *
this
;
268
}
269
273
SpinOneLorentzRotation
&
rotateY
(
double
delta) {
274
SpinOneLorentzRotation
tmp;
275
tmp.
setRotateY
(delta);
276
return
*
this
= tmp * *
this
;
277
}
278
282
SpinOneLorentzRotation
&
rotateZ
(
double
delta) {
283
SpinOneLorentzRotation
tmp;
284
tmp.
setRotateZ
(delta);
285
return
*
this
= tmp * *
this
;
286
}
287
291
SpinOneLorentzRotation
&
rotate
(
double
delta,
const
Axis
& axis) {
292
SpinOneLorentzRotation
tmp;
293
tmp.
setRotate
(delta, axis);
294
return
*
this
= tmp * *
this
;
295
}
296
300
SpinOneLorentzRotation
&
boostX
(
double
beta) {
301
return
*
this
=
SpinOneLorentzRotation
(beta,0,0) * *
this
;
302
}
303
307
SpinOneLorentzRotation
&
boostY
(
double
beta) {
308
return
*
this
=
SpinOneLorentzRotation
(0,beta,0) * *
this
;
309
}
310
314
SpinOneLorentzRotation
&
boostZ
(
double
beta) {
315
return
*
this
=
SpinOneLorentzRotation
(0,0,beta) * *
this
;
316
}
317
325
SpinOneLorentzRotation
&
boost
(
double
bx,
double
by,
double
bz,
326
double
gamma=-1.) {
327
return
*
this
=
SpinOneLorentzRotation
(bx,by,bz,gamma) * *
this
;
328
}
329
335
SpinOneLorentzRotation
&
boost
(
const
Boost
& b,
double
gamma=-1.) {
336
return
*
this
=
SpinOneLorentzRotation
(b.x(),b.y(),b.z(),gamma) * *
this
;
337
}
339
340
private
:
341
342
template
<
typename
Value>
friend
class
Helicity::LorentzTensor
;
343
template
<
typename
Value>
friend
class
Helicity::LorentzRSSpinor
;
344
template
<
typename
Value>
friend
class
Helicity::LorentzRSSpinorBar
;
345
347
array<double,16>
matrix_
= {};
348
350
SpinOneLorentzRotation
(
double
xx
,
double
xy
,
double
xz
,
double
xt
,
351
double
yx
,
double
yy
,
double
yz
,
double
yt
,
352
double
zx
,
double
zy
,
double
zz
,
double
zt
,
353
double
tx
,
double
ty
,
double
tz
,
double
tt
);
354
356
double
operator()
(
unsigned
int
i,
unsigned
int
j)
const
{
357
return
matrix_[4*i + j];
358
}
359
361
362
double
& xx_() {
return
matrix_[ 0]; }
363
double
& xy_() {
return
matrix_[ 1]; }
364
double
& xz_() {
return
matrix_[ 2]; }
365
double
& xt_() {
return
matrix_[ 3]; }
366
367
double
& yx_() {
return
matrix_[ 4]; }
368
double
& yy_() {
return
matrix_[ 5]; }
369
double
& yz_() {
return
matrix_[ 6]; }
370
double
& yt_() {
return
matrix_[ 7]; }
371
372
double
& zx_() {
return
matrix_[ 8]; }
373
double
& zy_() {
return
matrix_[ 9]; }
374
double
& zz_() {
return
matrix_[10]; }
375
double
& zt_() {
return
matrix_[11]; }
376
377
double
& tx_() {
return
matrix_[12]; }
378
double
& ty_() {
return
matrix_[13]; }
379
double
& tz_() {
return
matrix_[14]; }
380
double
& tt_() {
return
matrix_[15]; }
382
};
383
387
inline
std::ostream &
operator<<
( std::ostream & os,
388
const
SpinOneLorentzRotation
& lt ) {
389
return
lt.
print
(os);
390
}
391
392
}
393
394
#endif
/* ThePEG_SpinOneLorentzRotation_H */
ThePEG::SpinOneLorentzRotation::yy
double yy() const
The yy component.
Definition:
SpinOneLorentzRotation.h:159
ThePEG::SpinOneLorentzRotation::boostZ
SpinOneLorentzRotation & boostZ(double beta)
Pure boost along the z-axis; equivalent to LT = BoostX(beta) * LT.
Definition:
SpinOneLorentzRotation.h:314
ThePEG::LorentzVector
A 4-component Lorentz vector.
Definition:
LorentzVector.h:35
ThePEG::SpinOneLorentzRotation::isIdentity
bool isIdentity() const
Returns true if the Identity matrix.
ThePEG::SpinOneLorentzRotation::boost
SpinOneLorentzRotation & boost(const Boost &b, double gamma=-1.)
boost equivalent to LT = Boost(bv) * LT
Definition:
SpinOneLorentzRotation.h:335
ThePEG::SpinOneLorentzRotation::xy
double xy() const
The xy component.
Definition:
SpinOneLorentzRotation.h:139
ThePEG::SpinOneLorentzRotation::zt
double zt() const
The zt component.
Definition:
SpinOneLorentzRotation.h:189
ThePEG::SpinOneLorentzRotation::rotateZ
SpinOneLorentzRotation & rotateZ(double delta)
Rotation around the z-axis; equivalent to LT = RotationZ(delta) * LT.
Definition:
SpinOneLorentzRotation.h:282
HelicityDefinitions.h
This file contains enumerations used by LorentzSpinor and LorentzSpinorBar classes.
ThePEG::ThreeVector
A 3-component vector.
Definition:
ThreeVector.h:34
ThePEG::SpinOneLorentzRotation::operator*
LorentzVector< Value > operator*(const LorentzVector< Value > &v) const
Product with a LorentzVector simply returns the rotated vector.
Definition:
SpinOneLorentzRotation.h:220
ThePEG::SpinOneLorentzRotation::setRotateX
SpinOneLorentzRotation & setRotateX(double angle)
Specify a rotation by the given angle about the x-axis.
ThePEG::SpinOneLorentzRotation::operator*=
SpinOneLorentzRotation & operator*=(const SpinOneLorentzRotation <)
Multiply by and assign a*=b becomes a= a*b.
Definition:
SpinOneLorentzRotation.h:250
ThePEG::SpinOneLorentzRotation::rotateX
SpinOneLorentzRotation & rotateX(double delta)
Rotation around the x-axis; equivalent to LT = RotationX(delta) * LT.
Definition:
SpinOneLorentzRotation.h:264
ThePEG
This is the main namespace within which all identifiers in ThePEG are declared.
Definition:
FactoryBase.h:28
ThePEG::SpinOneLorentzRotation::SpinOneLorentzRotation
SpinOneLorentzRotation(double bx, double by, double bz, double gamma=-1.)
Constructor giving the components of a Lorentz boost.
Definition:
SpinOneLorentzRotation.h:44
ThePEG::SpinOneLorentzRotation::transform
SpinOneLorentzRotation & transform(const SpinOneLorentzRotation <)
Transform (similar to *= but a.transform(b) becomes a = b*a.
Definition:
SpinOneLorentzRotation.h:257
ThePEG::SpinOneLorentzRotation::invert
SpinOneLorentzRotation & invert()
Inverts the SpinOneLorentzRotation matrix.
Definition:
SpinOneLorentzRotation.h:73
ThePEG::SpinOneLorentzRotation::operator()
double operator()(unsigned int i, unsigned int j) const
Component access by index: x=0, t=3.
Definition:
SpinOneLorentzRotation.h:356
ThePEG::SpinOneLorentzRotation::SpinOneLorentzRotation
SpinOneLorentzRotation()
Default constructor.
Definition:
SpinOneLorentzRotation.h:33
ThePEG::SpinOneLorentzRotation::boostX
SpinOneLorentzRotation & boostX(double beta)
Pure boost along the x-axis; equivalent to LT = BoostX(beta) * LT.
Definition:
SpinOneLorentzRotation.h:300
ThePEG::Helicity::LorentzRSSpinor
The LorentzRSSpinor class is designed to store a Rarita-Schwinger spinor for a spin-3/2 particle...
Definition:
LorentzRSSpinor.h:73
ThePEG::SpinOneLorentzRotation::setRotate
SpinOneLorentzRotation & setRotate(double delta, const Axis &axis)
Specify a rotation about a general axis by the angle given.
ThePEG::SpinOneLorentzRotation::operator*
Lorentz5Vector< Value > operator*(const Lorentz5Vector< Value > &v) const
Product with a Lorentz5Vector simply returns the rotated vector.
Definition:
SpinOneLorentzRotation.h:233
ThePEG::SpinOneLorentzRotation::zy
double zy() const
The zy component.
Definition:
SpinOneLorentzRotation.h:179
ThePEG::SpinOneLorentzRotation::print
std::ostream & print(std::ostream &os) const
output operator
ThreeVector.h
contains the ThreeVector class.
ThePEG::SpinOneLorentzRotation::boost
SpinOneLorentzRotation & boost(double bx, double by, double bz, double gamma=-1.)
boost equivalent to LT = Boost(bx,by,bz) * LT
Definition:
SpinOneLorentzRotation.h:325
ThePEG::SpinOneLorentzRotation::rotateY
SpinOneLorentzRotation & rotateY(double delta)
Rotation around the y-axis; equivalent to LT = RotationY(delta) * LT.
Definition:
SpinOneLorentzRotation.h:273
ThePEG::SpinOneLorentzRotation::boostY
SpinOneLorentzRotation & boostY(double beta)
Pure boost along the y-axis; equivalent to LT = BoostX(beta) * LT.
Definition:
SpinOneLorentzRotation.h:307
ThePEG::SpinOneLorentzRotation
The SpinOneLorentzRotation class is ...
Definition:
SpinOneLorentzRotation.h:24
ThePEG::SpinOneLorentzRotation::xt
double xt() const
The xt component.
Definition:
SpinOneLorentzRotation.h:149
ThePEG::SpinOneLorentzRotation::rotate
SpinOneLorentzRotation & rotate(double delta, const Axis &axis)
Rotation around specified vector - LT = Rotation(delta,axis)*LT.
Definition:
SpinOneLorentzRotation.h:291
ThePEG::SpinOneLorentzRotation::matrix_
array< double, 16 > matrix_
Matrix components, order: .
Definition:
SpinOneLorentzRotation.h:347
ThePEG::SpinOneLorentzRotation::xz
double xz() const
The xz component.
Definition:
SpinOneLorentzRotation.h:144
ThePEG::SpinOneLorentzRotation::yt
double yt() const
The yt component.
Definition:
SpinOneLorentzRotation.h:169
ThePEG::SpinOneLorentzRotation::yx
double yx() const
The yx component.
Definition:
SpinOneLorentzRotation.h:154
ThePEG::SpinOneLorentzRotation::tz
double tz() const
The tz component.
Definition:
SpinOneLorentzRotation.h:204
ThePEG::Lorentz5Vector::x
Value x() const
Component access.
Definition:
Lorentz5Vector.h:52
ThePEG::Lorentz5Vector
The Lorentz5Vector inherits from the LorentzVector class.
Definition:
Lorentz5Vector.h:42
ThePEG::SpinOneLorentzRotation::setBoost
SpinOneLorentzRotation & setBoost(const Boost &b, double gamma=-1.)
Specify a Lorentz Boost as a vector.
Definition:
SpinOneLorentzRotation.h:97
ThePEG::SpinOneLorentzRotation::tx
double tx() const
The tx component.
Definition:
SpinOneLorentzRotation.h:194
ThePEG::Helicity::LorentzRSSpinorBar
The LorentzRSSpinorBar class implements the storage of a barred Lorentz Rarita-Schwinger Spinor for a...
Definition:
LorentzRSSpinorBar.h:38
ThePEG::SpinOneLorentzRotation::ty
double ty() const
The ty component.
Definition:
SpinOneLorentzRotation.h:199
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::Helicity::LorentzTensor
The LorentzTensor class is designed to implement the storage of a complex tensor to be used to repres...
Definition:
LorentzTensor.h:21
ThePEG::SpinOneLorentzRotation::zz
double zz() const
The zz component.
Definition:
SpinOneLorentzRotation.h:184
ThePEG::SpinOneLorentzRotation::inverse
SpinOneLorentzRotation inverse() const
Return the inverse.
ThePEG::SpinOneLorentzRotation::xx
double xx() const
The xx component.
Definition:
SpinOneLorentzRotation.h:134
ThePEG::SpinOneLorentzRotation::yz
double yz() const
The yz component.
Definition:
SpinOneLorentzRotation.h:164
ThePEG::SpinOneLorentzRotation::tt
double tt() const
The tt component.
Definition:
SpinOneLorentzRotation.h:209
ThePEG::SpinOneLorentzRotation::SpinOneLorentzRotation
SpinOneLorentzRotation(const Boost &b, double gamma=-1.)
Constructor giving the vector for a Lorentz boost.
Definition:
SpinOneLorentzRotation.h:54
ThePEG::SpinOneLorentzRotation::setRotateZ
SpinOneLorentzRotation & setRotateZ(double angle)
Specify a rotation by the given angle about the z-axis.
ThePEG::SpinOneLorentzRotation::setRotateY
SpinOneLorentzRotation & setRotateY(double angle)
Specify a rotation by the given angle about the y-axis.
ThePEG::SpinOneLorentzRotation::setBoost
SpinOneLorentzRotation & setBoost(double bx, double by, double bz, double gamma=-1.)
Specify the components of a Lorentz Boost.
ThePEG::SpinOneLorentzRotation::zx
double zx() const
The zx component.
Definition:
SpinOneLorentzRotation.h:174
Generated on Sat Apr 11 2020 14:31:17 for ThePEG by
1.8.13