|
The Rivet MC analysis system
1.8.2
|
Specialisation of VectorN to a general (non-momentum) Lorentz 4-vector.
More...
#include <Vector4.hh>
List of all members.
Public Member Functions |
| FourVector () |
template<typename V4 > |
| FourVector (const V4 &other) |
| FourVector (const Vector< 4 > &other) |
| FourVector (const double t, const double x, const double y, const double z) |
virtual | ~FourVector () |
double | t () const |
double | x () const |
double | y () const |
double | z () const |
FourVector & | setT (const double t) |
FourVector & | setX (const double x) |
FourVector & | setY (const double y) |
FourVector & | setZ (const double z) |
double | invariant () const |
double | angle (const FourVector &v) const |
| Angle between this vector and another.
|
double | angle (const Vector3 &v3) const |
| Angle between this vector and another (3-vector)
|
double | polarRadius2 () const |
| Square of the projection of the 3-vector on to the plane This is a more efficient function than polarRadius , as it avoids the square root. Use it if you only need the squared value, or e.g. an ordering by magnitude.
|
double | perp2 () const |
| Synonym for polarRadius2.
|
double | rho2 () const |
| Synonym for polarRadius2.
|
double | polarRadius () const |
| Projection of 3-vector on to the plane.
|
double | perp () const |
| Synonym for polarRadius.
|
double | rho () const |
| Synonym for polarRadius.
|
double | azimuthalAngle (const PhiMapping mapping=ZERO_2PI) const |
| Angle subtended by the 3-vector's projection in x-y and the x-axis.
|
double | phi (const PhiMapping mapping=ZERO_2PI) const |
| Synonym for azimuthalAngle.
|
double | polarAngle () const |
| Angle subtended by the 3-vector and the z-axis.
|
double | theta () const |
| Synonym for polarAngle.
|
double | pseudorapidity () const |
| Pseudorapidity (defined purely by the 3-vector components)
|
double | eta () const |
| Synonym for pseudorapidity.
|
Vector3 | vector3 () const |
| Get the spatial part of the 4-vector as a 3-vector.
|
double | contract (const FourVector &v) const |
| Contract two 4-vectors, with metric signature (+ - - -).
|
double | dot (const FourVector &v) const |
| Contract two 4-vectors, with metric signature (+ - - -).
|
double | operator* (const FourVector &v) const |
| Contract two 4-vectors, with metric signature (+ - - -).
|
FourVector & | operator*= (double a) |
| Multiply by a scalar.
|
FourVector & | operator/= (double a) |
| Divide by a scalar.
|
FourVector & | operator+= (const FourVector &v) |
FourVector & | operator-= (const FourVector &v) |
FourVector | operator- () const |
| Invert the vector.
|
const double & | get (const size_t index) const |
const double & | operator[] (const size_t index) const |
| Direct access to vector elements by index.
|
double & | operator[] (const size_t index) |
| Direct access to vector elements by index.
|
Vector< N > & | set (const size_t index, const double value) |
| Set indexed value.
|
size_t | size () const |
| Vector dimensionality.
|
bool | isZero (double tolerance=1E-5) const |
| Check for nullness, allowing for numerical precision.
|
double | mod2 () const |
| Calculate the modulus-squared of a vector. .
|
double | mod () const |
| Calculate the modulus of a vector. .
|
bool | operator== (const Vector< N > &a) const |
bool | operator!= (const Vector< N > &a) const |
bool | operator< (const Vector< N > &a) const |
bool | operator<= (const Vector< N > &a) const |
bool | operator> (const Vector< N > &a) const |
bool | operator>= (const Vector< N > &a) const |
Protected Member Functions |
double & | get (const size_t index) |
Protected Attributes |
Eigen::Vector< double, N > | _vec |
| Vector.
|
Friends |
FourVector | multiply (const double a, const FourVector &v) |
FourVector | multiply (const FourVector &v, const double a) |
FourVector | add (const FourVector &a, const FourVector &b) |
FourVector | transform (const LorentzTransform <, const FourVector &v4) |
Detailed Description
Specialisation of VectorN to a general (non-momentum) Lorentz 4-vector.
Definition at line 20 of file Vector4.hh.
Constructor & Destructor Documentation
FourVector |
( |
const double |
t, |
|
|
const double |
x, |
|
|
const double |
y, |
|
|
const double |
z |
|
) |
| [inline] |
Member Function Documentation
Angle subtended by the 3-vector's projection in x-y and the x-axis.
Definition at line 109 of file Vector4.hh.
References Vector3::azimuthalAngle(), and FourVector::vector3().
Referenced by CDF_2004_S5839831::_calcTransCones(), H1_1994_S2919893::analyze(), CDF_2008_S7540469::analyze(), MC_DIJET::analyze(), MC_LEADJETUE::analyze(), D0_2006_S6438750::analyze(), CDF_2008_S8095620::analyze(), CDF_2006_S6653332::analyze(), D0_2008_S7719523::analyze(), ATLAS_2012_I1112263::analyze(), ATLAS_2012_I1095236::analyze(), ATLAS_2012_CONF_2012_001::analyze(), ATLAS_2012_I943401::analyze(), CDF_2004_S5839831::analyze(), Rivet::azimuthalAngle(), Rivet::deltaR(), DISKinematics::project(), and ClusteredPhotons::project().
double eta |
( |
| ) |
const [inline] |
Synonym for pseudorapidity.
Definition at line 134 of file Vector4.hh.
References Vector3::eta(), and FourVector::vector3().
Referenced by FinalState::accept(), ATLAS_2011_I894867::analyze(), CMS_2012_I1087342::analyze(), CMS_2011_S9088458::analyze(), TOTEM_2012_I1115294::analyze(), CMS_2010_S8656010::analyze(), ATLAS_2010_S8591806::analyze(), CMS_2011_S8941262::analyze(), STAR_2008_S7993412::analyze(), CMS_2011_S8957746::analyze(), MC_DIPHOTON::analyze(), ATLAS_2011_S9002537::analyze(), CDF_2005_S6080774::analyze(), CMS_2010_S8547297::analyze(), ATLAS_2011_S8994773::analyze(), D0_1996_S3324664::analyze(), CDF_2000_S4266730::analyze(), CDF_2001_S4563131::analyze(), ATLAS_2010_CONF_2010_049::analyze(), D0_2008_S6879055::analyze(), CDF_1993_S2742446::analyze(), CDF_2001_S4517016::analyze(), CDF_2009_S8436959::analyze(), CMS_2011_S8973270::analyze(), CMS_2011_S9215166::analyze(), MC_HJETS::analyze(), MC_ZJETS::analyze(), MC_IDENTIFIED::analyze(), CDF_1996_S3418421::analyze(), CDF_1997_S3541940::analyze(), CDF_1994_S2952106::analyze(), D0_2010_S8570965::analyze(), D0_2008_S7837160::analyze(), MC_PHOTONJETS::analyze(), CMS_2011_S8884919::analyze(), MC_WJETS::analyze(), D0_2010_S8821313::analyze(), ATLAS_2012_I946427::analyze(), STAR_2009_UE_HELEN::analyze(), UA1_1990_S2044935::analyze(), MC_PHOTONJETUE::analyze(), CDF_2008_S7541902::analyze(), ATLAS_2012_I1183818::analyze(), D0_1996_S3214044::analyze(), CDF_2010_S8591881_DY::analyze(), ATLAS_2012_CONF_2012_104::analyze(), D0_2008_S7719523::analyze(), MC_GENERIC::analyze(), ATLAS_2012_I1190891::analyze(), ATLAS_2012_I1126136::analyze(), ATLAS_2012_I1186556::analyze(), CDF_2008_NOTE_9351::analyze(), ATLAS_2011_S9212183::analyze(), ATLAS_2011_S9120807::analyze(), MC_TTBAR::analyze(), ATLAS_2012_CONF_2012_105::analyze(), ATLAS_2010_S8914702::analyze(), ATLAS_2011_CONF_2011_098::analyze(), ATLAS_2012_CONF_2012_103::analyze(), ATLAS_2012_I1112263::analyze(), ATLAS_2011_S9128077::analyze(), ATLAS_2012_I1125961::analyze(), MC_ZZJETS::analyze(), ATLAS_2012_I1095236::analyze(), ATLAS_2012_I1117704::analyze(), MC_WWJETS::analyze(), ATLAS_2012_CONF_2012_001::analyze(), ATLAS_2012_I1180197::analyze(), ATLAS_2012_CONF_2012_109::analyze(), ATLAS_2011_S8983313::analyze(), ATLAS_2011_CONF_2011_090::analyze(), ATLAS_2011_S9019561::analyze(), ATLAS_2010_S8894728::analyze(), ATLAS_2012_CONF_2012_153::analyze(), MC_SUSY::analyze(), ATLAS_2011_S9212353::analyze(), ATLAS_2012_I943401::analyze(), ATLAS_2011_S9225137::analyze(), MC_VH2BB::analyze(), ATLAS_2011_S9041966::analyze(), ATLAS_2012_I1093738::analyze(), CDF_2004_S5839831::analyze(), JetShape::calc(), Jet::eta(), Rivet::eta(), ATLAS_2012_I1084540::fillMap(), ATLAS_2010_S8918562::fillPtEtaNch(), ATLAS_2012_I1091481::getSeta(), JetAlg::jets(), and NeutralFinalState::project().
const double& get |
( |
const size_t |
index | ) |
const [inline, inherited] |
Definition at line 33 of file VectorN.hh.
References Vector< N >::_vec.
{
if (index >= N) {
throw std::runtime_error("Tried to access an invalid vector index.");
} else {
return _vec(index);
}
}
double& get |
( |
const size_t |
index | ) |
[inline, protected, inherited] |
Definition at line 126 of file VectorN.hh.
References Vector< N >::_vec.
{
if (index >= N) {
throw std::runtime_error("Tried to access an invalid vector index.");
} else {
return _vec(index);
}
}
bool isZero |
( |
double |
tolerance = 1E-5 | ) |
const [inline, inherited] |
double mod |
( |
| ) |
const [inline, inherited] |
Calculate the modulus of a vector. .
Definition at line 87 of file VectorN.hh.
References Vector< N >::mod2().
{
const double norm = mod2();
assert(norm >= 0);
return sqrt(norm);
}
double mod2 |
( |
| ) |
const [inline, inherited] |
bool operator!= |
( |
const Vector< N > & |
a | ) |
const [inline, inherited] |
double operator* |
( |
const FourVector & |
v | ) |
const [inline] |
bool operator< |
( |
const Vector< N > & |
a | ) |
const [inline, inherited] |
bool operator<= |
( |
const Vector< N > & |
a | ) |
const [inline, inherited] |
bool operator== |
( |
const Vector< N > & |
a | ) |
const [inline, inherited] |
bool operator> |
( |
const Vector< N > & |
a | ) |
const [inline, inherited] |
bool operator>= |
( |
const Vector< N > & |
a | ) |
const [inline, inherited] |
const double& operator[] |
( |
const size_t |
index | ) |
const [inline, inherited] |
Direct access to vector elements by index.
Definition at line 42 of file VectorN.hh.
double& operator[] |
( |
const size_t |
index | ) |
[inline, inherited] |
Direct access to vector elements by index.
Definition at line 47 of file VectorN.hh.
double perp |
( |
| ) |
const [inline] |
Synonym for polarRadius.
Definition at line 99 of file Vector4.hh.
References Vector3::perp(), and FourVector::vector3().
Referenced by LHCB_2011_I919315::analyze(), ATLAS_2012_I1082009::analyze(), ATLAS_2011_S9108483::analyze(), ATLAS_2012_CONF_2012_104::analyze(), ATLAS_2012_I1190891::analyze(), ATLAS_2012_I1126136::analyze(), ATLAS_2012_I1186556::analyze(), ATLAS_2012_CONF_2012_105::analyze(), ATLAS_2011_CONF_2011_098::analyze(), ATLAS_2012_I1112263::analyze(), ATLAS_2012_I1095236::analyze(), ATLAS_2012_CONF_2012_001::analyze(), ATLAS_2012_I1180197::analyze(), ATLAS_2010_S8894728::analyze(), ATLAS_2012_CONF_2012_153::analyze(), ATLAS_2012_I943401::analyze(), and Rivet::perp().
double perp2 |
( |
| ) |
const [inline] |
Synonym for azimuthalAngle.
Definition at line 114 of file Vector4.hh.
References Vector3::phi(), and FourVector::vector3().
Referenced by STAR_2008_S7993412::analyze(), MC_DIPHOTON::analyze(), ATLAS_2011_S9002537::analyze(), CDF_2005_S6080774::analyze(), ATLAS_2011_S8994773::analyze(), D0_1996_S3324664::analyze(), D0_2008_S6879055::analyze(), CDF_1993_S2742446::analyze(), CDF_2009_S8436959::analyze(), CDF_2012_NOTE10874::analyze(), CMS_2011_S8973270::analyze(), MC_LEADJETUE::analyze(), CDF_1994_S2952106::analyze(), ATLAS_2011_I954993::analyze(), D0_2010_S8570965::analyze(), MC_PHOTONJETS::analyze(), CMS_2012_I1107658::analyze(), D0_2010_S8821313::analyze(), CMS_2011_S9120041::analyze(), D0_2009_S8349509::analyze(), ATLAS_2012_I946427::analyze(), STAR_2009_UE_HELEN::analyze(), MC_PHOTONJETUE::analyze(), CDF_2010_S8591881_QCD::analyze(), CDF_2008_LEADINGJETS::analyze(), D0_2008_S7719523::analyze(), MC_GENERIC::analyze(), ATLAS_2011_S9212183::analyze(), ATLAS_2011_S9120807::analyze(), ATLAS_2011_CONF_2011_098::analyze(), ATLAS_2010_S8914702::analyze(), CDF_2001_S4751469::analyze(), ATLAS_2012_I1125961::analyze(), MC_ZZJETS::analyze(), ATLAS_2012_I1095236::analyze(), MC_WWJETS::analyze(), ATLAS_2012_CONF_2012_109::analyze(), ATLAS_2011_S8983313::analyze(), ATLAS_2012_I1083318::analyze(), ATLAS_2011_CONF_2011_090::analyze(), ATLAS_2010_S8894728::analyze(), ATLAS_2010_S8919674::analyze(), MC_SUSY::analyze(), ATLAS_2011_S9212353::analyze(), MC_VH2BB::analyze(), ATLAS_2011_S9041966::analyze(), ATLAS_2012_I1093738::analyze(), ATLAS_2012_I1091481::getSeta(), Jet::phi(), and Rivet::phi().
Pseudorapidity (defined purely by the 3-vector components)
Definition at line 129 of file Vector4.hh.
References Vector3::pseudorapidity(), and FourVector::vector3().
Referenced by CDF_2004_S5839831::_calcTransCones(), H1_2000_S4129130::analyze(), H1_1994_S2919893::analyze(), UA5_1982_S875503::analyze(), CMS_QCD_10_024::analyze(), CDF_1990_S2089246::analyze(), CDF_2008_S7540469::analyze(), MC_DIJET::analyze(), SFM_1984_S1178091::analyze(), D0_2006_S6438750::analyze(), ALICE_2010_S8625980::analyze(), UA5_1986_S1583476::analyze(), D0_2008_S7863608::analyze(), D0_2009_S8349509::analyze(), D0_2009_S8202443::analyze(), D0_2008_S7719523::analyze(), CDF_2004_S5839831::analyze(), Rivet::cmpJetsByAscAbsPseudorapidity(), Rivet::cmpJetsByAscPseudorapidity(), Rivet::cmpJetsByDescAbsPseudorapidity(), Rivet::cmpJetsByDescPseudorapidity(), Rivet::cmpMomByAscAbsPseudorapidity(), Rivet::cmpMomByAscPseudorapidity(), Rivet::cmpMomByDescAbsPseudorapidity(), Rivet::cmpMomByDescPseudorapidity(), Rivet::cmpParticleByAscAbsPseudorapidity(), Rivet::cmpParticleByAscPseudorapidity(), Rivet::cmpParticleByDescAbsPseudorapidity(), Rivet::cmpParticleByDescPseudorapidity(), TriggerCDFRun0Run1::project(), TriggerCDFRun2::project(), ClusteredPhotons::project(), TriggerUA5::project(), and Rivet::pseudorapidity().
double rho |
( |
| ) |
const [inline] |
double rho2 |
( |
| ) |
const [inline] |
Vector<N>& set |
( |
const size_t |
index, |
|
|
const double |
value |
|
) |
| [inline, inherited] |
Set indexed value.
Definition at line 52 of file VectorN.hh.
References Vector< N >::_vec.
{
if (index >= N) {
throw std::runtime_error("Tried to access an invalid vector index.");
} else {
_vec[index] = value;
}
return *this;
}
size_t size |
( |
| ) |
const [inline, inherited] |
Vector dimensionality.
Definition at line 62 of file VectorN.hh.
double t |
( |
| ) |
const [inline] |
Definition at line 52 of file Vector4.hh.
Referenced by ARGUS_1993_S2789213::analyze(), ARGUS_1993_S2669951::analyze(), OPAL_1997_S3608263::analyze(), OPAL_2000_S4418603::analyze(), OPAL_1998_S3749908::analyze(), ATLAS_2011_S9108483::analyze(), FourVector::contract(), FourMomentum::E(), FourVector::invariant(), FourVector::setT(), and Rivet::toString().
double theta |
( |
| ) |
const [inline] |
Get the spatial part of the 4-vector as a 3-vector.
Definition at line 139 of file Vector4.hh.
Referenced by CDF_1996_S3349578::_fiveJetAnalysis(), D0_1996_S3214044::_fourJetAnalysis(), CDF_1996_S3349578::_fourJetAnalysis(), CDF_1997_S3541940::_psi(), CDF_1996_S3349578::_psi(), CDF_1996_S3349578::_threeJetAnalysis(), D0_1996_S3214044::_threeJetAnalysis(), CLEO_2004_S5809304::analyze(), BELLE_2001_S4598261::analyze(), ARGUS_1993_S2653028::analyze(), BABAR_2007_S7266081::analyze(), OPAL_1994_S2927284::analyze(), ARGUS_1993_S2789213::analyze(), ARGUS_1993_S2669951::analyze(), OPAL_1993_S2692198::analyze(), SLD_2004_S5693039::analyze(), OPAL_1998_S3780481::analyze(), SLD_1999_S3743934::analyze(), OPAL_1995_S3198391::analyze(), CMS_2011_S8957746::analyze(), ALEPH_2002_S4823664::analyze(), OPAL_1996_S3257789::analyze(), OPAL_1998_S3702294::analyze(), DELPHI_1999_S3960137::analyze(), DELPHI_1995_S3137023::analyze(), OPAL_1998_S3749908::analyze(), OPAL_1997_S3396100::analyze(), CDF_1997_S3541940::analyze(), ATLAS_2012_I1082009::analyze(), TASSO_1990_S2148048::analyze(), MC_ZZJETS::analyze(), MC_WWJETS::analyze(), ALEPH_1996_S3486095::analyze(), ALEPH_2004_S5765862::analyze(), DELPHI_1996_S3430090::analyze(), FourVector::angle(), Rivet::angle(), FourVector::azimuthalAngle(), FParameter::calc(), Spherocity::calc(), Thrust::calc(), Sphericity::calc(), Rivet::cmpJetsByAscP(), Rivet::cmpJetsByP(), Rivet::cmpMomByAscP(), Rivet::cmpMomByP(), Rivet::cmpParticleByAscP(), Rivet::cmpParticleByP(), Rivet::deltaEta(), Rivet::deltaPhi(), Rivet::deltaR(), FourVector::eta(), ATLAS_2012_I1091481::getPionEnergy(), FourMomentum::p(), FourVector::perp(), FourVector::perp2(), FourVector::phi(), FourVector::polarAngle(), FourVector::polarRadius(), FourVector::polarRadius2(), DISKinematics::project(), MissingMomentum::project(), FoxWolframMoments::project(), Hemispheres::project(), FourVector::pseudorapidity(), FourMomentum::pT2(), FourVector::rho(), FourVector::rho2(), and FourVector::theta().
{
return Vector3(get(1), get(2), get(3));
}
double x |
( |
| ) |
const [inline] |
Definition at line 53 of file Vector4.hh.
Referenced by ATLAS_2012_CONF_2012_104::analyze(), ATLAS_2012_I1126136::analyze(), ATLAS_2012_I1095236::analyze(), ATLAS_2012_I1180197::analyze(), FourVector::contract(), FourVector::invariant(), Rivet::mT2::mT2(), ALEPH_1996_S3196992::particleInJet(), FourMomentum::px(), FourVector::setX(), and Rivet::toString().
double y |
( |
| ) |
const [inline] |
Definition at line 54 of file Vector4.hh.
Referenced by ATLAS_2012_CONF_2012_104::analyze(), ATLAS_2012_I1126136::analyze(), ATLAS_2012_I1095236::analyze(), ATLAS_2012_I1180197::analyze(), FourVector::contract(), FourVector::invariant(), Rivet::mT2::mT2(), ALEPH_1996_S3196992::particleInJet(), FourMomentum::py(), FourVector::setY(), and Rivet::toString().
double z |
( |
| ) |
const [inline] |
Friends And Related Function Documentation
Member Data Documentation
Eigen::Vector<double,N> _vec [protected, inherited] |
The documentation for this class was generated from the following file:
|