ATLAS Offline Software
Classes | Namespaces | Functions
AtlasPID.h File Reference
#include <vector>
#include <cmath>
#include <algorithm>
#include <array>
#include <cstdlib>
Include dependency graph for AtlasPID.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  DecodedPID
 Implementation of classification functions according to PDG2022. More...
 

Namespaces

 SUSY
 

Functions

template<class T >
bool isQuark (const T &p)
 PDG rule 2: Quarks and leptons are numbered consecutively starting from 1 and 11 respectively; to dothis they are first ordered by family and within families by weak isospin. More...
 
template<>
bool isQuark (const int &p)
 
template<>
bool isQuark (const DecodedPID &p)
 
template<class T >
bool isStrange (const T &p)
 
template<>
bool isStrange (const int &p)
 
template<class T >
bool isCharm (const T &p)
 
template<>
bool isCharm (const int &p)
 
template<class T >
bool isBottom (const T &p)
 
template<>
bool isBottom (const int &p)
 
template<class T >
bool isTop (const T &p)
 
template<>
bool isTop (const int &p)
 
template<class T >
bool isLepton (const T &p)
 APID: the fourth generation leptons are leptons. More...
 
template<>
bool isLepton (const int &p)
 
template<>
bool isLepton (const DecodedPID &p)
 
template<class T >
bool isSMLepton (const T &p)
 
template<>
bool isSMLepton (const int &p)
 
template<>
bool isSMLepton (const DecodedPID &p)
 
template<class T >
bool isChLepton (const T &p)
 APID: the fourth generation leptons are leptons. More...
 
template<>
bool isChLepton (const int &p)
 
template<class T >
bool isElectron (const T &p)
 
template<>
bool isElectron (const int &p)
 
template<class T >
bool isMuon (const T &p)
 
template<>
bool isMuon (const int &p)
 
template<class T >
bool isTau (const T &p)
 
template<>
bool isTau (const int &p)
 
template<class T >
bool isNeutrino (const T &p)
 APID: the fourth generation neutrinos are neutrinos. More...
 
template<>
bool isNeutrino (const int &p)
 
template<class T >
bool isSMNeutrino (const T &p)
 
template<>
bool isSMNeutrino (const int &p)
 
template<class T >
bool isGluon (const T &p)
 
template<>
bool isGluon (const int &p)
 
template<class T >
bool isPhoton (const T &p)
 
template<>
bool isPhoton (const int &p)
 
template<class T >
bool isZ (const T &p)
 
template<>
bool isZ (const int &p)
 
template<class T >
bool isW (const T &p)
 
template<>
bool isW (const int &p)
 
template<class T >
bool isDM (const T &p)
 PDG rule 11j: The nature of Dark Matter (DM) is not known, and therefore a definitive classificationis too early. More...
 
template<>
bool isDM (const int &p)
 
template<class T >
bool isTrajectory (const T &p)
 PDG rule 8: The pomeron and odderon trajectories and a generic reggeon trajectory of states in QCD areassigned codes 990, 9990, and 110 respectively. More...
 
template<>
bool isTrajectory (const int &p)
 
template<class T >
bool isHiggs (const T &p)
 APID: HIGGS boson is only one particle. More...
 
template<>
bool isHiggs (const int &p)
 
template<class T >
bool isResonance (const T &p)
 
template<class T >
bool isGraviton (const T &p)
 
template<>
bool isGraviton (const int &p)
 
template<class T >
bool isLeptoQuark (const T &p)
 
template<>
bool isLeptoQuark (const int &p)
 
template<class T >
bool isSUSY (const T &p)
 
template<class T >
bool isTechnicolor (const T &p)
 
template<class T >
bool isExcited (const T &p)
 
template<class T >
bool isKK (const T &p)
 
template<class T >
bool isHiddenValley (const T &p)
 
template<class T >
bool isDiquark (const T &p)
 
template<class T >
bool isHadron (const T &p)
 
template<class T >
bool isMeson (const T &p)
 
template<class T >
bool isBaryon (const T &p)
 
template<class T >
bool isTetraquark (const T &p)
 
template<class T >
bool isPentaquark (const T &p)
 
template<class T >
bool isNucleus (const T &p)
 
template<class T >
bool isBSM (const T &p)
 
template<class T >
bool isValid (const T &p)
 
template<>
bool isValid (const DecodedPID &p)
 Av: we implement here an ATLAS-sepcific convention: all particles which are 99xxxxx are fine. More...
 
template<class T >
bool isTransportable (const T &p)
 
template<class T >
bool isGenSpecific (const T &p)
 
template<class T >
bool isGeantino (const T &p)
 
template<class T >
bool isPythia8Specific (const T &p)
 
template<>
bool isPythia8Specific (const DecodedPID &p)
 
template<>
bool isGenSpecific (const int &p)
 Main Table for MC internal use 81–100,901–930,998-999,1901–1930,2901–2930, and 3901–3930. More...
 
template<>
bool isGeantino (const int &p)
 
template<>
bool isSUSY (const DecodedPID &p)
 PDG rule 11d Fundamental supersymmetric particles are identified by adding a nonzeronto the par-ticle number. More...
 
template<>
bool isTechnicolor (const DecodedPID &p)
 PDG rule 11e Technicolor states have n= 3, with technifermions treated like ordinary fermions. More...
 
template<>
bool isTechnicolor (const int &p)
 
template<>
bool isExcited (const DecodedPID &p)
 PDG rule 11f Excited (composite) quarks and leptons are identified by setting n= 4 and nr= 0. More...
 
template<>
bool isExcited (const int &p)
 
template<>
bool isKK (const DecodedPID &p)
 PDG rule 11h A black hole in models with extra dimensions has code 5000040. More...
 
template<>
bool isKK (const int &p)
 
template<>
bool isHiddenValley (const DecodedPID &p)
 PDG rule 11k Hidden Valley particles have n= 4 and nr= 9, and trailing numbers in agreement with their nearest-analog standard particles, as far as possible. More...
 
template<>
bool isHiddenValley (const int &p)
 
template<>
bool isDiquark (const DecodedPID &p)
 PDG rule 4 Diquarks have 4-digit numbers with nq1 >= nq2 and nq3 = 0 APID: the diquarks with fourth generation are not diquarks. More...
 
template<>
bool isMeson (const DecodedPID &p)
 Table 43.1 PDG rule 5a: The numbers specifying the meson’s quark content conform to the convention nq1= 0 and nq2 >= nq3. More...
 
template<>
bool isBaryon (const DecodedPID &p)
 Table 43.2. More...
 
template<>
bool isPentaquark (const DecodedPID &p)
 PDG rule 15 The 9-digit penta-quark codes are±1nrnLnq1nq2nq3nq4nq5nJ, sorted such thatnq1≥nq2≥nq3≥nq4. More...
 
template<>
bool isTetraquark (const DecodedPID &p)
 PDG rule 14 The 9-digit tetra-quark codes are±1nrnLnq1nq20nq3nq4nJ. More...
 
template<>
bool isNucleus (const DecodedPID &p)
 PDG rule 16: Nuclear codes are given as 10-digit numbers±10LZZZAAAI. More...
 
template<>
bool isBSM (const DecodedPID &p)
 APID: graviton and all Higgs extensions are BSM. More...
 
template<>
bool isSUSY (const int &p)
 
template<>
bool isDiquark (const int &p)
 
template<>
bool isMeson (const int &p)
 
template<>
bool isBaryon (const int &p)
 
template<>
bool isTetraquark (const int &p)
 
template<>
bool isPentaquark (const int &p)
 
template<>
bool isNucleus (const int &p)
 
template<>
bool isBSM (const int &p)
 
template<>
bool isHadron (const DecodedPID &p)
 
template<>
bool isHadron (const int &p)
 
template<>
bool isTransportable (const DecodedPID &p)
 
template<>
bool isTransportable (const int &p)
 
template<>
bool isValid (const int &p)
 
template<class T >
bool hasQuark (const T &p, const int &q)
 
template<>
bool hasQuark (const DecodedPID &p, const int &q)
 
template<>
bool hasQuark (const int &p, const int &q)
 
template<class T >
int leadingQuark (const T &p)
 
template<>
int leadingQuark (const DecodedPID &p)
 
template<>
int leadingQuark (const int &p)
 
template<class T >
bool hasStrange (const T &p)
 
template<class T >
bool hasCharm (const T &p)
 
template<class T >
bool hasBottom (const T &p)
 
template<class T >
bool hasTop (const T &p)
 
template<class T >
bool isLightHadron (const T &p)
 
template<class T >
bool isHeavyHadron (const T &p)
 
template<class T >
bool isStrangeHadron (const T &p)
 
template<class T >
bool isCharmHadron (const T &p)
 
template<class T >
bool isBottomHadron (const T &p)
 
template<class T >
bool isTopHadron (const T &p)
 
template<class T >
bool isLightMeson (const T &p)
 
template<class T >
bool isHeavyMeson (const T &p)
 
template<class T >
bool isStrangeMeson (const T &p)
 
template<class T >
bool isCharmMeson (const T &p)
 
template<class T >
bool isBottomMeson (const T &p)
 
template<class T >
bool isTopMeson (const T &p)
 
template<class T >
bool isCCbarMeson (const T &p)
 
template<>
bool isCCbarMeson (const DecodedPID &p)
 
template<>
bool isCCbarMeson (const int &p)
 
template<class T >
bool isBBbarMeson (const T &p)
 
template<>
bool isBBbarMeson (const DecodedPID &p)
 
template<>
bool isBBbarMeson (const int &p)
 
template<class T >
bool isLightBaryon (const T &p)
 
template<class T >
bool isHeavyBaryon (const T &p)
 
template<class T >
bool isStrangeBaryon (const T &p)
 
template<class T >
bool isCharmBaryon (const T &p)
 
template<class T >
bool isBottomBaryon (const T &p)
 
template<class T >
bool isTopBaryon (const T &p)
 
template<class T >
int charge3 (const T &p)
 
template<class T >
double charge (const T &p)
 
template<class T >
double threeCharge (const T &p)
 
template<class T >
bool isCharged (const T &p)
 
template<class T >
bool isNeutral (const T &p)
 
template<>
int charge3 (const DecodedPID &p)
 
template<>
int charge3 (const int &p)
 
template<class T >
bool isEMInteracting (const T &p)
 
template<>
bool isEMInteracting (const int &p)
 
template<class T >
bool isStrongInteracting (const T &p)
 
template<>
bool isStrongInteracting (const int &p)
 
template<class T >
bool isParton (const T &p)
 
template<class T >
bool SUSY::isRGlueball (const T &p)
 
template<>
bool SUSY::isRGlueball (const DecodedPID &p)
 
template<>
bool SUSY::isRGlueball (const int &p)
 
template<class T >
bool SUSY::isRHadron (const T &p)
 
template<>
bool SUSY::isRHadron (const DecodedPID &p)
 
template<>
bool SUSY::isRHadron (const int &p)
 
template<class T >
bool SUSY::isRMeson (const T &p)
 
template<>
bool SUSY::isRMeson (const DecodedPID &p)
 
template<>
bool SUSY::isRMeson (const int &p)
 
template<class T >
bool SUSY::isRBaryon (const T &p)
 
template<>
bool SUSY::isRBaryon (const DecodedPID &p)
 
template<>
bool SUSY::isRBaryon (const int &p)
 
template<class T >
bool SUSY::isRBottomHadron (const T &p)
 
template<>
bool SUSY::isRBottomHadron (const DecodedPID &p)
 
template<>
bool SUSY::isRBottomHadron (const int &p)
 
template<class T >
bool SUSY::isRTopHadron (const T &p)
 
template<>
bool SUSY::isRTopHadron (const DecodedPID &p)
 
template<>
bool SUSY::isRTopHadron (const int &p)
 
template<class T >
bool SUSY::isSLepton (const T &p)
 
template<>
bool SUSY::isSLepton (const DecodedPID &p)
 
template<>
bool SUSY::isSLepton (const int &p)
 
template<class T >
bool SUSY::isSTopHadron (const T &p)
 
template<>
bool SUSY::isSTopHadron (const DecodedPID &p)
 
template<>
bool SUSY::isSTopHadron (const int &p)
 
template<class T >
bool SUSY::isSBaryon (const T &p)
 
template<>
bool SUSY::isSBaryon (const DecodedPID &p)
 
template<>
bool SUSY::isSBaryon (const int &p)
 
template<class T >
bool SUSY::isSMeson (const T &p)
 
template<>
bool SUSY::isSMeson (const DecodedPID &p)
 
template<>
bool SUSY::isSMeson (const int &p)
 
template<class T >
bool SUSY::isSBottomHadron (const T &p)
 
template<>
bool SUSY::isSBottomHadron (const DecodedPID &p)
 
template<>
bool SUSY::isSBottomHadron (const int &p)
 
template<class T >
bool SUSY::isSTopMeson (const T &p)
 
template<>
bool SUSY::isSTopMeson (const DecodedPID &p)
 
template<>
bool SUSY::isSTopMeson (const int &p)
 
template<class T >
bool SUSY::isSBottomMeson (const T &p)
 
template<>
bool SUSY::isSBottomMeson (const DecodedPID &p)
 
template<>
bool SUSY::isSBottomMeson (const int &p)
 
template<class T >
bool SUSY::isSTopBaryon (const T &p)
 
template<>
bool SUSY::isSTopBaryon (const DecodedPID &p)
 
template<>
bool SUSY::isSTopBaryon (const int &p)
 
template<class T >
bool SUSY::isSBottomBaryon (const T &p)
 
template<>
bool SUSY::isSBottomBaryon (const DecodedPID &p)
 
template<>
bool SUSY::isSBottomBaryon (const int &p)
 
template<class T >
bool SUSY::spin (const T &p)
 
template<>
bool SUSY::spin (const int &p)
 
std::vector< int > SUSY::containedQuarks (int p)
 

Function Documentation

◆ charge()

template<class T >
double charge ( const T &  p)
inline

Definition at line 494 of file AtlasPID.h.

494 { return 1.0*charge3(p)/3.0;}

◆ charge3() [1/3]

template<>
int charge3 ( const DecodedPID p)
inline

Definition at line 501 of file AtlasPID.h.

501  {
502  auto ap = std::abs(p.pid());
503  if (ap < TABLESIZE ) return p.pid() > 0 ? triple_charge.at(ap) : -triple_charge.at(ap);
504  if (ap == K0) return 0;
505  if (ap == GEANTINO0) return 0;
506  if (ap == GEANTINOPLUS) return p.pid() > 0 ? 3 : -3;
507  size_t nq = 0;
508  int sign = 1;
509  int signmult = 1;
510  int result=0;
511  bool classified = false;
512  if (!classified && isMeson(p)) { classified = true; nq = 2; if ((*(p.second.rbegin()+2)) == 2||(*(p.second.rbegin()+2)) == 4 ) { sign=-1;} signmult =-1; }
513  if (!classified && isDiquark(p)) {return triple_charge.at(p(0))+triple_charge.at(p(1)); }
514  if (!classified && isBaryon(p)) { classified = true; nq = 3; }
515  if (!classified && isTetraquark(p)){ return triple_charge.at(p(3)) + triple_charge.at(p(4)) - triple_charge.at(p(6)) - triple_charge.at(p(7)); }
516  if (!classified && isPentaquark(p)){ return triple_charge.at(p(3)) + triple_charge.at(p(4)) + triple_charge.at(p(5)) + triple_charge.at(p(6)) - triple_charge.at(p(7)); }
517  if (!classified && isNucleus(p)) { classified = true; nq=0; result = 3*(p(3)*100 + p(4)*10 + p(5)) + (-1)*p(2);}
518  if (!classified && isSUSY(p)) { nq = 0;
519  auto pp = p.shift(1); if (pp.ndigits() > 2) pp = pp.shift(1);
520  return charge3(pp);
521  }
522  for (auto r = p.second.rbegin() + 1; r != p.second.rbegin() + 1 + nq; ++r) {
523  result += triple_charge.at(*r)*sign;
524  sign*=signmult;
525  }
526  return p.pid() > 0 ? result : -result;
527 }

◆ charge3() [2/3]

template<>
int charge3 ( const int &  p)
inline

Definition at line 528 of file AtlasPID.h.

528  {
529  int ap = std::abs(p);
530  if (ap < TABLESIZE) return p > 0 ? triple_charge.at(ap):-triple_charge.at(ap);
531  auto value_digits = DecodedPID(p);
532  return charge3(value_digits);
533 }

◆ charge3() [3/3]

template<class T >
int charge3 ( const T &  p)
inline

Definition at line 493 of file AtlasPID.h.

493 {return charge3(p->pdg_id());}

◆ hasBottom()

template<class T >
bool hasBottom ( const T &  p)
inline

Definition at line 459 of file AtlasPID.h.

459 { return hasQuark(p,BQUARK); }

◆ hasCharm()

template<class T >
bool hasCharm ( const T &  p)
inline

Definition at line 458 of file AtlasPID.h.

458 { return hasQuark(p,CQUARK); }

◆ hasQuark() [1/3]

template<>
bool hasQuark ( const DecodedPID p,
const int &  q 
)
inline

Definition at line 431 of file AtlasPID.h.

431  {
432  if (isQuark(p.pid())) { return (std::abs(p.pid()) == q );}
433  if (isMeson(p)) { return *(p.second.rbegin() + 1) == q ||*(p.second.rbegin()+2) ==q;}
434  if (isDiquark(p)) { auto i = std::find(p.second.rbegin() + 1,p.second.rbegin()+3,q); return (i!=p.second.rbegin()+3);}
435  if (isBaryon(p)) { auto i = std::find(p.second.rbegin() + 1,p.second.rbegin()+4,q); return (i!=p.second.rbegin()+4);}
436  if (isTetraquark(p)) { auto i = std::find(p.second.rbegin() + 1,p.second.rbegin()+5,q); return (i!=p.second.rbegin()+5);}
437  if (isPentaquark(p)) { auto i = std::find(p.second.rbegin() + 1,p.second.rbegin()+6,q); return (i!=p.second.rbegin()+6);}
438  if (isNucleus(p) && p.first != PROTON) { return q==3 && p(2) > 0;}
439  return false;
440 }

◆ hasQuark() [2/3]

template<>
bool hasQuark ( const int &  p,
const int &  q 
)
inline

Definition at line 442 of file AtlasPID.h.

442 { auto value_digits = DecodedPID(p); return hasQuark(value_digits, q);}

◆ hasQuark() [3/3]

template<class T >
bool hasQuark ( const T &  p,
const int &  q 
)
inline

◆ hasStrange()

template<class T >
bool hasStrange ( const T &  p)
inline

Definition at line 457 of file AtlasPID.h.

457 { return hasQuark(p,SQUARK); }

◆ hasTop()

template<class T >
bool hasTop ( const T &  p)
inline

Definition at line 460 of file AtlasPID.h.

460 { return hasQuark(p,TQUARK); }

◆ isBaryon() [1/3]

template<>
bool isBaryon ( const DecodedPID p)
inline

Table 43.2.

Definition at line 317 of file AtlasPID.h.

317  {
318  if (p.ndigits() < 4 ) return false;
319  if (p.max_digit(1,4) >= 6 ) return false;
320  if (p.min_digit(1,4) == 0) return false;
321  if (p.ndigits() == 4 && (p.last() == 2 || p.last() == 4|| p.last() == 6|| p.last() == 8) ) return true;
322 
323  if (p.ndigits() == 5 && p(0) == 1 && (p.last() == 2 || p.last() == 4) ) return true;
324  if (p.ndigits() == 5 && p(0) == 3 && (p.last() == 2 || p.last() == 4) ) return true;
325 
326  if (p.ndigits() == 6 ) {
327  if (p(0) == 1 && p(1) == 0 && p.last() == 2 ) return true;
328  if (p(0) == 1 && p(1) == 1 && p.last() == 2 ) return true;
329  if (p(0) == 1 && p(1) == 2 && p.last() == 4 ) return true;
330 
331  if (p(0) == 2 && p(1) == 0 && p.last() == 2 ) return true;
332  if (p(0) == 2 && p(1) == 0 && p.last() == 4 ) return true;
333  if (p(0) == 2 && p(1) == 1 && p.last() == 2 ) return true;
334 
335  if (p(0) == 1 && p(1) == 0 && p.last() == 4 ) return true;
336  if (p(0) == 1 && p(1) == 0 && p.last() == 6 ) return true;
337  if (p(0) == 2 && p(1) == 0 && p.last() == 6 ) return true;
338  if (p(0) == 2 && p(1) == 0 && p.last() == 8 ) return true;
339  }
340 
341  if (p.ndigits() == 5 ) {
342  if (p(0) == 2 && p.last() == 2 ) return true;
343  if (p(0) == 2 && p.last() == 4 ) return true;
344  if (p(0) == 2 && p.last() == 6 ) return true;
345  if (p(0) == 5 && p.last() == 2 ) return true;
346  if (p(0) == 1 && p.last() == 6 ) return true;
347  if (p(0) == 4 && p.last() == 2 ) return true;
348  }
349  return false;
350 }

◆ isBaryon() [2/3]

template<>
bool isBaryon ( const int &  p)
inline

Definition at line 406 of file AtlasPID.h.

406 { auto value_digits = DecodedPID(p); return isBaryon(value_digits);}

◆ isBaryon() [3/3]

template<class T >
bool isBaryon ( const T &  p)
inline

Definition at line 209 of file AtlasPID.h.

209 {return isBaryon(p->pdg_id());}

◆ isBBbarMeson() [1/3]

template<>
bool isBBbarMeson ( const DecodedPID p)
inline

Definition at line 481 of file AtlasPID.h.

481 { return leadingQuark(p) == BQUARK && isMeson(p) && p(1) == BQUARK && p(2) == BQUARK; }

◆ isBBbarMeson() [2/3]

template<>
bool isBBbarMeson ( const int &  p)
inline

Definition at line 482 of file AtlasPID.h.

482 { return isCCbarMeson(DecodedPID(p)); }

◆ isBBbarMeson() [3/3]

template<class T >
bool isBBbarMeson ( const T &  p)
inline

Definition at line 480 of file AtlasPID.h.

480 { return isBBbarMeson(p->pdg_id());}

◆ isBottom() [1/2]

template<>
bool isBottom ( const int &  p)
inline

Definition at line 124 of file AtlasPID.h.

124 { return std::abs(p) == 5;}

◆ isBottom() [2/2]

template<class T >
bool isBottom ( const T &  p)
inline

Definition at line 123 of file AtlasPID.h.

123 {return isBottom(p->pdg_id());}

◆ isBottomBaryon()

template<class T >
bool isBottomBaryon ( const T &  p)
inline

Definition at line 489 of file AtlasPID.h.

489 { return leadingQuark(p) == BQUARK && isBaryon(p); }

◆ isBottomHadron()

template<class T >
bool isBottomHadron ( const T &  p)
inline

Definition at line 466 of file AtlasPID.h.

466 { return leadingQuark(p) == BQUARK && isHadron(p); }

◆ isBottomMeson()

template<class T >
bool isBottomMeson ( const T &  p)
inline

Definition at line 473 of file AtlasPID.h.

473 { return leadingQuark(p) == BQUARK && isMeson(p); }

◆ isBSM() [1/3]

template<>
bool isBSM ( const DecodedPID p)
inline

APID: graviton and all Higgs extensions are BSM.

Definition at line 389 of file AtlasPID.h.

389  {
390  if (p.pid() == GRAVITON) return true;
391  if (std::abs(p.pid()) > 16 && std::abs(p.pid()) < 19) return true;
392  if (std::abs(p.pid()) > 31 && std::abs(p.pid()) < 38) return true;
393  if (std::abs(p.pid()) > 39 && std::abs(p.pid()) < 81) return true;
394  if (std::abs(p.pid()) > 6 && std::abs(p.pid()) < 9) return true;
395  if (isSUSY(p)) return true;
396  if (isTechnicolor(p)) return true;
397  if (isExcited(p)) return true;
398  if (isKK(p)) return true;
399  if (isHiddenValley(p)) return true;
400  return false;
401 }

◆ isBSM() [2/3]

template<>
bool isBSM ( const int &  p)
inline

Definition at line 410 of file AtlasPID.h.

410  {
411  if (p == GRAVITON) return true;
412  if (std::abs(p) > 16 && std::abs(p) < 19) return true;
413  if (std::abs(p) > 31 && std::abs(p) < 38) return true;
414  if (std::abs(p) > 39 && std::abs(p) < 81) return true;
415  if (std::abs(p) > 6 && std::abs(p) < 9) return true;
416  auto value_digits = DecodedPID(p); return isBSM(value_digits);
417 }

◆ isBSM() [3/3]

template<class T >
bool isBSM ( const T &  p)
inline

Definition at line 213 of file AtlasPID.h.

213 {return isBSM(p->pdg_id());}

◆ isCCbarMeson() [1/3]

template<>
bool isCCbarMeson ( const DecodedPID p)
inline

Definition at line 477 of file AtlasPID.h.

477 { return leadingQuark(p) == CQUARK && isMeson(p) && p(1) == CQUARK && p(2) == CQUARK; }

◆ isCCbarMeson() [2/3]

template<>
bool isCCbarMeson ( const int &  p)
inline

Definition at line 478 of file AtlasPID.h.

478 { return isCCbarMeson(DecodedPID(p)); }

◆ isCCbarMeson() [3/3]

template<class T >
bool isCCbarMeson ( const T &  p)
inline

Definition at line 476 of file AtlasPID.h.

476 { return isCCbarMeson(p->pdg_id());}

◆ isCharged()

template<class T >
bool isCharged ( const T &  p)
inline

Definition at line 496 of file AtlasPID.h.

496 { return charge3(p) != 0;}

◆ isCharm() [1/2]

template<>
bool isCharm ( const int &  p)
inline

Definition at line 121 of file AtlasPID.h.

121 { return std::abs(p) == 4;}

◆ isCharm() [2/2]

template<class T >
bool isCharm ( const T &  p)
inline

Definition at line 120 of file AtlasPID.h.

120 {return isCharm(p->pdg_id());}

◆ isCharmBaryon()

template<class T >
bool isCharmBaryon ( const T &  p)
inline

Definition at line 488 of file AtlasPID.h.

488 { return leadingQuark(p) == CQUARK && isBaryon(p); }

◆ isCharmHadron()

template<class T >
bool isCharmHadron ( const T &  p)
inline

Definition at line 465 of file AtlasPID.h.

465 { return leadingQuark(p) == CQUARK && isHadron(p); }

◆ isCharmMeson()

template<class T >
bool isCharmMeson ( const T &  p)
inline

Definition at line 472 of file AtlasPID.h.

472 { return leadingQuark(p) == CQUARK && isMeson(p); }

◆ isChLepton() [1/2]

template<>
bool isChLepton ( const int &  p)
inline

Definition at line 140 of file AtlasPID.h.

140 { auto sp = std::abs(p); return sp >= 11 && sp <= 18 && sp%2 == 1; }

◆ isChLepton() [2/2]

template<class T >
bool isChLepton ( const T &  p)
inline

APID: the fourth generation leptons are leptons.

Definition at line 139 of file AtlasPID.h.

139 {return isChLepton(p->pdg_id());}

◆ isDiquark() [1/3]

template<>
bool isDiquark ( const DecodedPID p)
inline

PDG rule 4 Diquarks have 4-digit numbers with nq1 >= nq2 and nq3 = 0 APID: the diquarks with fourth generation are not diquarks.

Definition at line 276 of file AtlasPID.h.

276  {
277  if ( p.ndigits() == 4 && p(0) >= p(1) && p(2) == 0 && p.last() % 2 == 1
278  && p.max_digit(1,3) <= 6
279  ) return true;
280  return false;
281 }

◆ isDiquark() [2/3]

template<>
bool isDiquark ( const int &  p)
inline

Definition at line 404 of file AtlasPID.h.

404 { auto value_digits = DecodedPID(p); return isDiquark(value_digits);}

◆ isDiquark() [3/3]

template<class T >
bool isDiquark ( const T &  p)
inline

Definition at line 206 of file AtlasPID.h.

206 {return isDiquark(p->pdg_id());}

◆ isDM() [1/2]

template<>
bool isDM ( const int &  p)
inline

Definition at line 181 of file AtlasPID.h.

181 { auto sp = std::abs(p); return sp >= 51 && sp <= 60; }

◆ isDM() [2/2]

template<class T >
bool isDM ( const T &  p)
inline

PDG rule 11j: The nature of Dark Matter (DM) is not known, and therefore a definitive classificationis too early.

Candidates within specific scenarios are classified therein, such as 1000022 for the lightest neutralino. Generic fundamental states can be given temporary codes in the range 51 - 60, with 51, 52 and 53 reserved for spin 0, 1/2 and 1 ones (this could also be an axion state). Generic mediators of s-channel DM pair creation of annihilationcan be given codes 54 and 55 for spin 0 or 1 ones. Separate antiparticles, with negativecodes, may or may not exist. More elaborate new scenarios should be constructed with n= 5 and nr = 9. APID: Only the 51-60 range is considered DM. The antiparticles are assumed to be existing.

Definition at line 180 of file AtlasPID.h.

180 {return isDM(p->pdg_id());}

◆ isElectron() [1/2]

template<>
bool isElectron ( const int &  p)
inline

Definition at line 143 of file AtlasPID.h.

143 { return std::abs(p) == ELECTRON;}

◆ isElectron() [2/2]

template<class T >
bool isElectron ( const T &  p)
inline

Definition at line 142 of file AtlasPID.h.

142 {return isElectron(p->pdg_id());}

◆ isEMInteracting() [1/2]

template<>
bool isEMInteracting ( const int &  p)
inline

Definition at line 536 of file AtlasPID.h.

536 {return (isPhoton(p) || isZ(p) || charge3(p) != 0 );}

◆ isEMInteracting() [2/2]

template<class T >
bool isEMInteracting ( const T &  p)
inline

Definition at line 535 of file AtlasPID.h.

535 {return isEMInteracting(p->pdg_id());}

◆ isExcited() [1/3]

template<>
bool isExcited ( const DecodedPID p)
inline

PDG rule 11f Excited (composite) quarks and leptons are identified by setting n= 4 and nr= 0.

Definition at line 252 of file AtlasPID.h.

252 {return (p.ndigits() == 7 && (p(0) == 4 && p(1) == 0 ) && (isLepton(p.shift(2))||isQuark(p.shift(2))) );}

◆ isExcited() [2/3]

template<>
bool isExcited ( const int &  p)
inline

Definition at line 253 of file AtlasPID.h.

253 { auto value_digits = DecodedPID(p); return isExcited(value_digits);}

◆ isExcited() [3/3]

template<class T >
bool isExcited ( const T &  p)
inline

Definition at line 203 of file AtlasPID.h.

203 {return isExcited(p->pdg_id());}

◆ isGeantino() [1/2]

template<>
bool isGeantino ( const int &  p)
inline

Definition at line 233 of file AtlasPID.h.

233 { return (std::abs(p) == GEANTINO0 || std::abs(p) == GEANTINOPLUS);}

◆ isGeantino() [2/2]

template<class T >
bool isGeantino ( const T &  p)
inline

Definition at line 218 of file AtlasPID.h.

218 {return isGeantino(p->pdg_id());}

◆ isGenSpecific() [1/2]

template<>
bool isGenSpecific ( const int &  p)
inline

Main Table for MC internal use 81–100,901–930,998-999,1901–1930,2901–2930, and 3901–3930.

Definition at line 223 of file AtlasPID.h.

223  {
224  if (p >= 81 && p <= 100) return true;
225  if (p >= 901 && p <= 930) return true;
226  if (p >= 998 && p <= 999) return true;
227  if (p >= 1901 && p <= 1930) return true;
228  if (p >= 2901 && p <= 2930) return true;
229  if (p >= 3901 && p <= 3930) return true;
230  return false;
231 }

◆ isGenSpecific() [2/2]

template<class T >
bool isGenSpecific ( const T &  p)
inline

Definition at line 217 of file AtlasPID.h.

217 {return isGenSpecific(p->pdg_id());}

◆ isGluon() [1/2]

template<>
bool isGluon ( const int &  p)
inline

Definition at line 159 of file AtlasPID.h.

159 { return p == GLUON; }

◆ isGluon() [2/2]

template<class T >
bool isGluon ( const T &  p)
inline

Definition at line 158 of file AtlasPID.h.

158 {return isGluon(p->pdg_id());}

◆ isGraviton() [1/2]

template<>
bool isGraviton ( const int &  p)
inline

Definition at line 196 of file AtlasPID.h.

196 { return p == 39; }

◆ isGraviton() [2/2]

template<class T >
bool isGraviton ( const T &  p)
inline

Definition at line 195 of file AtlasPID.h.

195 {return isGraviton(p->pdg_id());}

◆ isHadron() [1/3]

template<>
bool isHadron ( const DecodedPID p)
inline

Definition at line 419 of file AtlasPID.h.

419 { return isMeson(p)||isBaryon(p)||isTetraquark(p)||isPentaquark(p);}

◆ isHadron() [2/3]

template<>
bool isHadron ( const int &  p)
inline

Definition at line 420 of file AtlasPID.h.

420 { auto value_digits = DecodedPID(p); return isHadron(value_digits);}

◆ isHadron() [3/3]

template<class T >
bool isHadron ( const T &  p)
inline

Definition at line 207 of file AtlasPID.h.

207 {return isHadron(p->pdg_id());}

◆ isHeavyBaryon()

template<class T >
bool isHeavyBaryon ( const T &  p)
inline

Definition at line 486 of file AtlasPID.h.

486 { auto lq = leadingQuark(p); return (lq == CQUARK || lq == BQUARK || lq == TQUARK) && isBaryon(p); }

◆ isHeavyHadron()

template<class T >
bool isHeavyHadron ( const T &  p)
inline

Definition at line 463 of file AtlasPID.h.

463 { auto lq = leadingQuark(p); return (lq == CQUARK || lq == BQUARK || lq == TQUARK ) && isHadron(p); }

◆ isHeavyMeson()

template<class T >
bool isHeavyMeson ( const T &  p)
inline

Definition at line 470 of file AtlasPID.h.

470 { auto lq = leadingQuark(p); return (lq == CQUARK || lq == BQUARK || lq == TQUARK) && isMeson(p); }

◆ isHiddenValley() [1/3]

template<>
bool isHiddenValley ( const DecodedPID p)
inline

PDG rule 11k Hidden Valley particles have n= 4 and nr= 9, and trailing numbers in agreement with their nearest-analog standard particles, as far as possible.

Thus 4900021 is the gauge boson gv of a confining gauge field, 490000 nqv and 490001 nlv fundamental constituents charged or not under this, 4900022 is the γv of a non-confining field, and 4900 nqv1 nqv2 nJ a Hidden Valley meson.

Definition at line 270 of file AtlasPID.h.

270 {return (p.ndigits() == 7 && p(0) == 4 && p(1) == 9 && isValid(p.shift(2)));}

◆ isHiddenValley() [2/3]

template<>
bool isHiddenValley ( const int &  p)
inline

Definition at line 271 of file AtlasPID.h.

271 { auto value_digits = DecodedPID(p); return isHiddenValley(value_digits);}

◆ isHiddenValley() [3/3]

template<class T >
bool isHiddenValley ( const T &  p)
inline

Definition at line 205 of file AtlasPID.h.

205 {return isHiddenValley(p->pdg_id());}

◆ isHiggs() [1/2]

template<>
bool isHiggs ( const int &  p)
inline

Definition at line 191 of file AtlasPID.h.

191 { return p == HIGGSBOSON; }

◆ isHiggs() [2/2]

template<class T >
bool isHiggs ( const T &  p)
inline

APID: HIGGS boson is only one particle.

Definition at line 190 of file AtlasPID.h.

190 {return isHiggs(p->pdg_id());}

◆ isKK() [1/3]

template<>
bool isKK ( const DecodedPID p)
inline

PDG rule 11h A black hole in models with extra dimensions has code 5000040.

Kaluza-Klein excitations in models with extra dimensions have n= 5 or n= 6, to distinguish excitations of left-or right-handed fermions or, in case of mixing, the lighter or heavier state (cf. 11d). The non zero nr digit gives the radial excitation number, in scenarios where the level spacing allows these to be distinguished. Should the model also contain supersymmetry, excited SUSY states would be denoted by a nnr>0, with n= 1 or 2 as usual. Should some colored states be long-lived enough that hadrons would form around them, the coding strategy of 11g applies, with the initial two nnr digits preserved in the combined code.

Definition at line 262 of file AtlasPID.h.

262 {return (p.ndigits() == 7 && (p(0) == 5 || p(0) == 6 ) );}

◆ isKK() [2/3]

template<>
bool isKK ( const int &  p)
inline

Definition at line 263 of file AtlasPID.h.

263 { auto value_digits = DecodedPID(p); return isExcited(value_digits);}

◆ isKK() [3/3]

template<class T >
bool isKK ( const T &  p)
inline

Definition at line 204 of file AtlasPID.h.

204 {return isKK(p->pdg_id());}

◆ isLepton() [1/3]

template<>
bool isLepton ( const DecodedPID p)
inline

Definition at line 132 of file AtlasPID.h.

132 { return isLepton(p.pid()); }

◆ isLepton() [2/3]

template<>
bool isLepton ( const int &  p)
inline

Definition at line 131 of file AtlasPID.h.

131 { auto sp = std::abs(p); return sp >= 11 && sp <= 18; }

◆ isLepton() [3/3]

template<class T >
bool isLepton ( const T &  p)
inline

APID: the fourth generation leptons are leptons.

Definition at line 130 of file AtlasPID.h.

130 {return isLepton(p->pdg_id());}

◆ isLeptoQuark() [1/2]

template<>
bool isLeptoQuark ( const int &  p)
inline

Definition at line 199 of file AtlasPID.h.

199 { return std::abs(p) == LEPTOQUARK; }

◆ isLeptoQuark() [2/2]

template<class T >
bool isLeptoQuark ( const T &  p)
inline

Definition at line 198 of file AtlasPID.h.

198 {return isLeptoQuark(p->pdg_id());}

◆ isLightBaryon()

template<class T >
bool isLightBaryon ( const T &  p)
inline

Definition at line 485 of file AtlasPID.h.

485 { auto lq = leadingQuark(p); return (lq == DQUARK || lq == UQUARK||lq == SQUARK) && isBaryon(p); }

◆ isLightHadron()

template<class T >
bool isLightHadron ( const T &  p)
inline

Definition at line 462 of file AtlasPID.h.

462 { auto lq = leadingQuark(p); return (lq == DQUARK || lq == UQUARK||lq == SQUARK) && isHadron(p); }

◆ isLightMeson()

template<class T >
bool isLightMeson ( const T &  p)
inline

Definition at line 469 of file AtlasPID.h.

469 { auto lq = leadingQuark(p); return (lq == DQUARK || lq == UQUARK||lq == SQUARK) && isMeson(p); }

◆ isMeson() [1/3]

template<>
bool isMeson ( const DecodedPID p)
inline

Table 43.1 PDG rule 5a: The numbers specifying the meson’s quark content conform to the convention nq1= 0 and nq2 >= nq3.

The special case K0L is the sole exception to this rule. PDG rule 5C: The special numbers 310 and 130 are given to the K0S and K0L respectively. APID: The special code K0 is used when a generator uses K0S/K0L

Definition at line 291 of file AtlasPID.h.

291  {
292  if (p.ndigits() < 3 ) return false;
293  if (std::abs(p.pid()) == K0S) return true;
294  if (std::abs(p.pid()) == K0L) return true;
295  if (std::abs(p.pid()) == K0) return true;
296  if (p.last() % 2 != 1 ) return false;
297  if (p.max_digit(1,3) >= 6 ) return false;
298  if (p.max_digit(1,3) == 0 ) return false;
299 
300  if (p.ndigits() == 3 && p(0) == p(1) && p.pid() < 0 ) return false;
301  if (p.ndigits() == 5 && p(2) == p(3) && p.pid() < 0 ) return false;
302  if (p.ndigits() == 7 && p(4) == p(5) && p.pid() < 0 ) return false;
303 
304 
305  if (p.ndigits() == 3 && p(0) >= p(1) && p(1) != 0 ) return true;
306  if (p.ndigits() == 5 && p(2) >= p(3) && p(3) != 0 && p(0) == 1 && p(1) == 0) return true;
307  if (p.ndigits() == 5 && p(2) >= p(3) && p(3) != 0 && p(0) == 2 && p(1) == 0 && p.last() > 1 ) return true;
308  if (p.ndigits() == 5 && p(2) >= p(3) && p(3) != 0 && p(0) == 3 && p(1) == 0 && p.last() > 1 ) return true;
309 
310  if (p.ndigits() == 6 && p(3) >= p(4) && p(4) != 0 && p.last() % 2 == 1 ) return true;
311 
312  if (p.ndigits() == 7 && p(4) >= p(5) && p(5) != 0) return true;
313 
314  return false;
315 }

◆ isMeson() [2/3]

template<>
bool isMeson ( const int &  p)
inline

Definition at line 405 of file AtlasPID.h.

405 { auto value_digits = DecodedPID(p); return isMeson(value_digits);}

◆ isMeson() [3/3]

template<class T >
bool isMeson ( const T &  p)
inline

Definition at line 208 of file AtlasPID.h.

208 {return isMeson(p->pdg_id());}

◆ isMuon() [1/2]

template<>
bool isMuon ( const int &  p)
inline

Definition at line 146 of file AtlasPID.h.

146 { return std::abs(p) == MUON;}

◆ isMuon() [2/2]

template<class T >
bool isMuon ( const T &  p)
inline

Definition at line 145 of file AtlasPID.h.

145 {return isMuon(p->pdg_id());}

◆ isNeutral()

template<class T >
bool isNeutral ( const T &  p)
inline

Definition at line 497 of file AtlasPID.h.

497 { return charge3(p) == 0;}

◆ isNeutrino() [1/2]

template<>
bool isNeutrino ( const int &  p)
inline

Definition at line 153 of file AtlasPID.h.

153 { auto sp = std::abs(p); return sp == 12 || sp == 14 || sp == 16|| sp == 18; }

◆ isNeutrino() [2/2]

template<class T >
bool isNeutrino ( const T &  p)
inline

APID: the fourth generation neutrinos are neutrinos.

Definition at line 152 of file AtlasPID.h.

152 {return isNeutrino(p->pdg_id());}

◆ isNucleus() [1/3]

template<>
bool isNucleus ( const DecodedPID p)
inline

PDG rule 16: Nuclear codes are given as 10-digit numbers±10LZZZAAAI.

For a (hyper)nucleus consistingofnpprotons,nnneutrons andnΛΛ’s,A=np+nn+nΛgives the total baryon number, Z=np the total charge andL=nΛthe total number of strange quarks.Igives the isomerlevel, withI= 0corresponding to the ground state andI >0to excitations, see [2], wherestates denotedm,n,p,qtranslate toI= 1–4. As examples, the deuteron is 1000010020 and 235U is

  1. To avoid ambiguities, nuclear codes should not be applied to a singlehadron, like p,n or Λ0, where quark-contents-based codes already exist.

Definition at line 384 of file AtlasPID.h.

384  {
385  if (std::abs(p.pid()) == PROTON) return true;
386  return (p.ndigits() == 10 && p(0) == 1 && p(1) == 0 );
387 }

◆ isNucleus() [2/3]

template<>
bool isNucleus ( const int &  p)
inline

Definition at line 409 of file AtlasPID.h.

409 { auto value_digits = DecodedPID(p); return isNucleus(value_digits);}

◆ isNucleus() [3/3]

template<class T >
bool isNucleus ( const T &  p)
inline

Definition at line 212 of file AtlasPID.h.

212 {return isNucleus(p->pdg_id());}

◆ isParton()

template<class T >
bool isParton ( const T &  p)
inline

Definition at line 541 of file AtlasPID.h.

541 { return isQuark(p)||isGluon(p);}

◆ isPentaquark() [1/3]

template<>
bool isPentaquark ( const DecodedPID p)
inline

PDG rule 15 The 9-digit penta-quark codes are±1nrnLnq1nq2nq3nq4nq5nJ, sorted such thatnq1≥nq2≥nq3≥nq4.

In the particle the first four are quarks and the fifth an antiquark while t heopposite holds in the antiparticle, which is given with a negative sign. Thenr,nL, andnJnumbers have the same meaning as for ordinary hadrons.

Definition at line 357 of file AtlasPID.h.

357  {
358  return (p.ndigits() == 9 && p(0) == 1 &&
359  p.max_digit(1,6) <= 6 && p.min_digit(1,6) > 0 &&
360  ( p(3) >= p(4) && p(4) >= p(5) && p(5) >= p(6)) );
361 }

◆ isPentaquark() [2/3]

template<>
bool isPentaquark ( const int &  p)
inline

Definition at line 408 of file AtlasPID.h.

408 { auto value_digits = DecodedPID(p); return isPentaquark(value_digits);}

◆ isPentaquark() [3/3]

template<class T >
bool isPentaquark ( const T &  p)
inline

Definition at line 211 of file AtlasPID.h.

211 {return isPentaquark(p->pdg_id());}

◆ isPhoton() [1/2]

template<>
bool isPhoton ( const int &  p)
inline

Definition at line 162 of file AtlasPID.h.

162 { return p == PHOTON; }

◆ isPhoton() [2/2]

template<class T >
bool isPhoton ( const T &  p)
inline

Definition at line 161 of file AtlasPID.h.

161 {return isPhoton(p->pdg_id());}

◆ isPythia8Specific() [1/2]

template<>
bool isPythia8Specific ( const DecodedPID p)
inline

Definition at line 220 of file AtlasPID.h.

220 { return (p(0) == 9 && p(1) == 9 && p.ndigits() == 7 );}

◆ isPythia8Specific() [2/2]

template<class T >
bool isPythia8Specific ( const T &  p)
inline

Definition at line 219 of file AtlasPID.h.

219 {return isPythia8Specific(p->pdg_id());}

◆ isQuark() [1/3]

template<>
bool isQuark ( const DecodedPID p)
inline

Definition at line 115 of file AtlasPID.h.

115 { return isQuark(p.pid()); }

◆ isQuark() [2/3]

template<>
bool isQuark ( const int &  p)
inline

Definition at line 114 of file AtlasPID.h.

114 { return p != 0 && std::abs(p) <= 8;}

◆ isQuark() [3/3]

template<class T >
bool isQuark ( const T &  p)
inline

PDG rule 2: Quarks and leptons are numbered consecutively starting from 1 and 11 respectively; to dothis they are first ordered by family and within families by weak isospin.

APID: the fourth generation quarks are quarks.

Definition at line 113 of file AtlasPID.h.

113 {return isQuark(p->pdg_id());}

◆ isResonance()

template<class T >
bool isResonance ( const T &  p)
inline

Definition at line 193 of file AtlasPID.h.

193 { return isZ(p)||isW(p)||isHiggs(p)||isTop(p); }

◆ isSMLepton() [1/3]

template<>
bool isSMLepton ( const DecodedPID p)
inline

Definition at line 136 of file AtlasPID.h.

136 { return isSMLepton(p.pid()); }

◆ isSMLepton() [2/3]

template<>
bool isSMLepton ( const int &  p)
inline

Definition at line 135 of file AtlasPID.h.

135 { auto sp = std::abs(p); return sp >= 11 && sp <= 16; }

◆ isSMLepton() [3/3]

template<class T >
bool isSMLepton ( const T &  p)
inline

Definition at line 134 of file AtlasPID.h.

134 {return isSMLepton(p->pdg_id());}

◆ isSMNeutrino() [1/2]

template<>
bool isSMNeutrino ( const int &  p)
inline

Definition at line 156 of file AtlasPID.h.

156 { auto sp = std::abs(p); return sp == 12 || sp == 14 || sp == 16; }

◆ isSMNeutrino() [2/2]

template<class T >
bool isSMNeutrino ( const T &  p)
inline

Definition at line 155 of file AtlasPID.h.

155 {return isSMNeutrino(p->pdg_id());}

◆ isStrange() [1/2]

template<>
bool isStrange ( const int &  p)
inline

Definition at line 118 of file AtlasPID.h.

118 { return std::abs(p) == 3;}

◆ isStrange() [2/2]

template<class T >
bool isStrange ( const T &  p)
inline

Definition at line 117 of file AtlasPID.h.

117 {return isStrange(p->pdg_id());}

◆ isStrangeBaryon()

template<class T >
bool isStrangeBaryon ( const T &  p)
inline

Definition at line 487 of file AtlasPID.h.

487 { return leadingQuark(p) == SQUARK && isBaryon(p); }

◆ isStrangeHadron()

template<class T >
bool isStrangeHadron ( const T &  p)
inline

Definition at line 464 of file AtlasPID.h.

464 { return leadingQuark(p) == SQUARK && isHadron(p); }

◆ isStrangeMeson()

template<class T >
bool isStrangeMeson ( const T &  p)
inline

Definition at line 471 of file AtlasPID.h.

471 { return leadingQuark(p) == SQUARK && isMeson(p); }

◆ isStrongInteracting() [1/2]

template<>
bool isStrongInteracting ( const int &  p)
inline

Definition at line 539 of file AtlasPID.h.

539 { return (isGluon(p) || isQuark(p) || isDiquark(p) || isLeptoQuark(p) || isHadron(p));}

◆ isStrongInteracting() [2/2]

template<class T >
bool isStrongInteracting ( const T &  p)
inline

Definition at line 538 of file AtlasPID.h.

538 {return isStrongInteracting(p->pdg_id());}

◆ isSUSY() [1/3]

template<>
bool isSUSY ( const DecodedPID p)
inline

PDG rule 11d Fundamental supersymmetric particles are identified by adding a nonzeronto the par-ticle number.

T he superpartner of a boson or a left-handed fermion hasn= 1whilethe superpartner of a right-handed fermion hasn= 2. When mixing occurs, such asbetween the winos and charged Higgsinos to give charginos, or between left and rightsfermions, the lighter physical state is given the smaller basis state number.

Definition at line 240 of file AtlasPID.h.

240 {return (p.ndigits() == 7 && (p(0) == 1 || p(0) == 2 ) && isValid(p.shift(2)) && !isGenSpecific(p.shift(2).pid()));}

◆ isSUSY() [2/3]

template<>
bool isSUSY ( const int &  p)
inline

Definition at line 403 of file AtlasPID.h.

403 { auto value_digits = DecodedPID(p); return isSUSY(value_digits);}

◆ isSUSY() [3/3]

template<class T >
bool isSUSY ( const T &  p)
inline

Definition at line 201 of file AtlasPID.h.

201 {return isSUSY(p->pdg_id());}

◆ isTau() [1/2]

template<>
bool isTau ( const int &  p)
inline

Definition at line 149 of file AtlasPID.h.

149 { return std::abs(p) == TAU;}

◆ isTau() [2/2]

template<class T >
bool isTau ( const T &  p)
inline

Definition at line 148 of file AtlasPID.h.

148 {return isTau(p->pdg_id());}

◆ isTechnicolor() [1/3]

template<>
bool isTechnicolor ( const DecodedPID p)
inline

PDG rule 11e Technicolor states have n= 3, with technifermions treated like ordinary fermions.

States which are ordinary color singlets have nr= 0. Color octets have nr= 1. If a state has non-trivial quantum numbers under the topcolor groups SU(3)1×SU(3)2, the quantum numbers are specified by tech, ij, where i and j are 1 or 2. nLis then 2i+j. The coloron V8, is a heavy gluon color octet and thus is 3100021

Definition at line 247 of file AtlasPID.h.

247 {return (p.ndigits() == 7 && p(0) == 3 && (p(1) == 0 || p(0) == 1) && isValid(p.shift(2)) && !isGenSpecific(p.shift(2).pid()));}

◆ isTechnicolor() [2/3]

template<>
bool isTechnicolor ( const int &  p)
inline

Definition at line 248 of file AtlasPID.h.

248 { auto value_digits = DecodedPID(p); return isTechnicolor(value_digits);}

◆ isTechnicolor() [3/3]

template<class T >
bool isTechnicolor ( const T &  p)
inline

Definition at line 202 of file AtlasPID.h.

202 {return isTechnicolor(p->pdg_id());}

◆ isTetraquark() [1/3]

template<>
bool isTetraquark ( const DecodedPID p)
inline

PDG rule 14 The 9-digit tetra-quark codes are±1nrnLnq1nq20nq3nq4nJ.

For the particleq1q2is a diquarkand ̄q3 ̄q4an antidiquark, sorted such thatnq1≥nq2,nq3≥nq4,nq1≥nq3, andnq2≥nq4ifnq1=nq3. For the antiparticle, given with a negative sign, ̄q1 ̄q2is an antidiquark andq3q4a diquark, with the same sorting except that eithernq1> nq3ornq2> nq4(so thatflavour-diagonal states are particles). Thenr,nL, andnJnumbers have the same meaningas for ordinary hadrons.

Definition at line 368 of file AtlasPID.h.

368  {
369  return (p.ndigits() == 9 && p(0) == 1 && p(5) == 0 &&
370  p.max_digit(1,3) <= 6 && p.min_digit(1,3) > 0 &&
371  p.max_digit(1+3,3+3) <= 6 && p.min_digit(1+3,3+3) > 0 &&
372  ( p(3) >= p(4) && p(6) >= p(7) ) && ( ( p(3) > p(6) ) || ( p(3) == p(6) && (p(4) >= p(7))))
373  );
374 }

◆ isTetraquark() [2/3]

template<>
bool isTetraquark ( const int &  p)
inline

Definition at line 407 of file AtlasPID.h.

407 { auto value_digits = DecodedPID(p); return isTetraquark(value_digits);}

◆ isTetraquark() [3/3]

template<class T >
bool isTetraquark ( const T &  p)
inline

Definition at line 210 of file AtlasPID.h.

210 {return isTetraquark(p->pdg_id());}

◆ isTop() [1/2]

template<>
bool isTop ( const int &  p)
inline

Definition at line 127 of file AtlasPID.h.

127 { return std::abs(p) == 6;}

◆ isTop() [2/2]

template<class T >
bool isTop ( const T &  p)
inline

Definition at line 126 of file AtlasPID.h.

126 {return isTop(p->pdg_id());}

◆ isTopBaryon()

template<class T >
bool isTopBaryon ( const T &  p)
inline

Definition at line 490 of file AtlasPID.h.

490 { return leadingQuark(p) == TQUARK && isBaryon(p); }

◆ isTopHadron()

template<class T >
bool isTopHadron ( const T &  p)
inline

Definition at line 467 of file AtlasPID.h.

467 { return leadingQuark(p) == TQUARK && isHadron(p); }

◆ isTopMeson()

template<class T >
bool isTopMeson ( const T &  p)
inline

Definition at line 474 of file AtlasPID.h.

474 { return leadingQuark(p) == TQUARK && isMeson(p); }

◆ isTrajectory() [1/2]

template<>
bool isTrajectory ( const int &  p)
inline

Definition at line 187 of file AtlasPID.h.

187 { return std::abs(p) == POMERON || std::abs(p) == ODDERON || std::abs(p) == REGGEON; }

◆ isTrajectory() [2/2]

template<class T >
bool isTrajectory ( const T &  p)
inline

PDG rule 8: The pomeron and odderon trajectories and a generic reggeon trajectory of states in QCD areassigned codes 990, 9990, and 110 respectively.

Definition at line 186 of file AtlasPID.h.

186 {return isTrajectory(p->pdg_id());}

◆ isTransportable() [1/3]

template<>
bool isTransportable ( const DecodedPID p)
inline

Definition at line 421 of file AtlasPID.h.

421 { return isPhoton(p.pid()) || isGeantino(p.pid()) || isHadron(p) || isLepton(p.pid());}

◆ isTransportable() [2/3]

template<>
bool isTransportable ( const int &  p)
inline

Definition at line 422 of file AtlasPID.h.

422 { auto value_digits = DecodedPID(p); return isTransportable(value_digits);}

◆ isTransportable() [3/3]

template<class T >
bool isTransportable ( const T &  p)
inline

Definition at line 216 of file AtlasPID.h.

216 {return isTransportable(p->pdg_id());}

◆ isValid() [1/3]

template<>
bool isValid ( const DecodedPID p)
inline

Av: we implement here an ATLAS-sepcific convention: all particles which are 99xxxxx are fine.

Definition at line 424 of file AtlasPID.h.

424 { return isHadron(p) || isTrajectory(p.pid()) || isDiquark(p) || isBSM(p) || isNucleus(p) || (std::abs(p.pid()) < 42) || isGenSpecific(p.pid()) || isGeantino(p.pid()) || isPythia8Specific(p);}

◆ isValid() [2/3]

template<>
bool isValid ( const int &  p)
inline

Definition at line 425 of file AtlasPID.h.

425  { if (!p) return false; if (std::abs(p) < 42) return true;
426  if (isGenSpecific(p)) return true;
427  auto value_digits = DecodedPID(p); return isValid(value_digits);
428 }

◆ isValid() [3/3]

template<class T >
bool isValid ( const T &  p)
inline

Definition at line 214 of file AtlasPID.h.

214 {return isValid(p->pdg_id());}

◆ isW() [1/2]

template<>
bool isW ( const int &  p)
inline

Definition at line 168 of file AtlasPID.h.

168 { return std::abs(p) == WPLUSBOSON; }

◆ isW() [2/2]

template<class T >
bool isW ( const T &  p)
inline

Definition at line 167 of file AtlasPID.h.

167 {return isW(p->pdg_id());}

◆ isZ() [1/2]

template<>
bool isZ ( const int &  p)
inline

Definition at line 165 of file AtlasPID.h.

165 { return p == Z0BOSON; }

◆ isZ() [2/2]

template<class T >
bool isZ ( const T &  p)
inline

Definition at line 164 of file AtlasPID.h.

164 {return isZ(p->pdg_id());}

◆ leadingQuark() [1/3]

template<>
int leadingQuark ( const DecodedPID p)
inline

Definition at line 445 of file AtlasPID.h.

445  {
446  if (isQuark(p.pid())) { return std::abs(p.pid());}
447  if (isMeson(p)) {return p.max_digit(1,3);}
448  if (isDiquark(p)) {return p.max_digit(1,3);}
449  if (isBaryon(p)) {return p.max_digit(1,4); }
450  if (isTetraquark(p)) { return p.max_digit(1,5);}
451  if (isPentaquark(p)) { return p.max_digit(1,6);}
452  return 0;
453 }

◆ leadingQuark() [2/3]

template<>
int leadingQuark ( const int &  p)
inline

Definition at line 455 of file AtlasPID.h.

455 { auto value_digits = DecodedPID(p); return leadingQuark(value_digits);}

◆ leadingQuark() [3/3]

template<class T >
int leadingQuark ( const T &  p)
inline

Definition at line 444 of file AtlasPID.h.

444 {return leadingQuark(p->pdg_id());}

◆ threeCharge()

template<class T >
double threeCharge ( const T &  p)
inline

Definition at line 495 of file AtlasPID.h.

495 { return charge3(p);}
isStrange
bool isStrange(const T &p)
Definition: AtlasPID.h:117
beamspotman.r
def r
Definition: beamspotman.py:676
isStrongInteracting
bool isStrongInteracting(const T &p)
Definition: AtlasPID.h:538
isNucleus
bool isNucleus(const T &p)
Definition: AtlasPID.h:212
get_generator_info.result
result
Definition: get_generator_info.py:21
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
isTetraquark
bool isTetraquark(const T &p)
Definition: AtlasPID.h:210
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
isBSM
bool isBSM(const T &p)
Definition: AtlasPID.h:213
isHiddenValley
bool isHiddenValley(const T &p)
Definition: AtlasPID.h:205
isGenSpecific
bool isGenSpecific(const T &p)
Definition: AtlasPID.h:217
isMeson
bool isMeson(const T &p)
Definition: AtlasPID.h:208
hasQuark
bool hasQuark(const T &p, const int &q)
isKK
bool isKK(const T &p)
Definition: AtlasPID.h:204
isNeutrino
bool isNeutrino(const T &p)
APID: the fourth generation neutrinos are neutrinos.
Definition: AtlasPID.h:152
isValid
bool isValid(const T &p)
Definition: AtlasPID.h:214
python.AtlRunQueryParser.ap
ap
Definition: AtlRunQueryParser.py:826
xAOD::Muon_v1
Class describing a Muon.
Definition: Muon_v1.h:38
isSMLepton
bool isSMLepton(const T &p)
Definition: AtlasPID.h:134
isGluon
bool isGluon(const T &p)
Definition: AtlasPID.h:158
isHiggs
bool isHiggs(const T &p)
APID: HIGGS boson is only one particle.
Definition: AtlasPID.h:190
isQuark
bool isQuark(const T &p)
PDG rule 2: Quarks and leptons are numbered consecutively starting from 1 and 11 respectively; to dot...
Definition: AtlasPID.h:113
isCCbarMeson
bool isCCbarMeson(const T &p)
Definition: AtlasPID.h:476
isBottom
bool isBottom(const T &p)
Definition: AtlasPID.h:123
lumiFormat.i
int i
Definition: lumiFormat.py:92
leadingQuark
int leadingQuark(const T &p)
Definition: AtlasPID.h:444
isPythia8Specific
bool isPythia8Specific(const T &p)
Definition: AtlasPID.h:219
isZ
bool isZ(const T &p)
Definition: AtlasPID.h:164
isPentaquark
bool isPentaquark(const T &p)
Definition: AtlasPID.h:211
sign
int sign(int a)
Definition: TRT_StrawNeighbourSvc.h:127
isBBbarMeson
bool isBBbarMeson(const T &p)
Definition: AtlasPID.h:480
isChLepton
bool isChLepton(const T &p)
APID: the fourth generation leptons are leptons.
Definition: AtlasPID.h:139
isSUSY
bool isSUSY(const T &p)
Definition: AtlasPID.h:201
isTau
bool isTau(const T &p)
Definition: AtlasPID.h:148
isGraviton
bool isGraviton(const T &p)
Definition: AtlasPID.h:195
isDM
bool isDM(const T &p)
PDG rule 11j: The nature of Dark Matter (DM) is not known, and therefore a definitive classificationi...
Definition: AtlasPID.h:180
DecodedPID
Implementation of classification functions according to PDG2022.
Definition: AtlasPID.h:16
isExcited
bool isExcited(const T &p)
Definition: AtlasPID.h:203
isHadron
bool isHadron(const T &p)
Definition: AtlasPID.h:207
isBaryon
bool isBaryon(const T &p)
Definition: AtlasPID.h:209
isGeantino
bool isGeantino(const T &p)
Definition: AtlasPID.h:218
isW
bool isW(const T &p)
Definition: AtlasPID.h:167
isTop
bool isTop(const T &p)
Definition: AtlasPID.h:126
isTransportable
bool isTransportable(const T &p)
Definition: AtlasPID.h:216
isLepton
bool isLepton(const T &p)
APID: the fourth generation leptons are leptons.
Definition: AtlasPID.h:130
isCharm
bool isCharm(const T &p)
Definition: AtlasPID.h:120
isPhoton
bool isPhoton(const T &p)
Definition: AtlasPID.h:161
charge3
int charge3(const T &p)
Definition: AtlasPID.h:493
isSMNeutrino
bool isSMNeutrino(const T &p)
Definition: AtlasPID.h:155
extractSporadic.q
list q
Definition: extractSporadic.py:98
isTechnicolor
bool isTechnicolor(const T &p)
Definition: AtlasPID.h:202
isTrajectory
bool isTrajectory(const T &p)
PDG rule 8: The pomeron and odderon trajectories and a generic reggeon trajectory of states in QCD ar...
Definition: AtlasPID.h:186
isElectron
bool isElectron(const T &p)
Definition: AtlasPID.h:142
isDiquark
bool isDiquark(const T &p)
Definition: AtlasPID.h:206
isEMInteracting
bool isEMInteracting(const T &p)
Definition: AtlasPID.h:535
isMuon
bool isMuon(const T &p)
Definition: AtlasPID.h:145
isLeptoQuark
bool isLeptoQuark(const T &p)
Definition: AtlasPID.h:198