gambit is hosted by Hepforge, IPPP Durham
GAMBIT  v1.5.0-2191-ga4742ac
a Global And Modular Bsm Inference Tool
Gambit::DarkBit::TH_Channel Struct Reference

All data on a single annihilation or decay channel, e.g. More...

#include <ProcessCatalog.hpp>

Collaboration diagram for Gambit::DarkBit::TH_Channel:

Public Member Functions

 TH_Channel (std::vector< str > finalStateIDs, daFunk::Funk genRate)
 Constructor. More...
 
void printChannel () const
 Print information about this channel. More...
 
bool channelContains (str p) const
 Indicate whether or not the final states of this channel contain a specific particle. More...
 
bool isChannel (str, str, str="", str="") const
 Indicate whether or not this channel is the one defined by some specific final states. Particle name version. More...
 
bool isChannel (std::vector< str >) const
 Indicate whether or not this channel is the one defined by some specific final states. Particle vector version. More...
 

Public Attributes

std::vector< std::string > finalStateIDs
 Final state identifiers. More...
 
unsigned int nFinalStates
 Number of final state particles in this channel. More...
 
daFunk::Funk genRate = daFunk::zero("dummyArgument")
 Energy dependence of final state particles. Includes v_rel ("v") as last argument in case of annihilation. More...
 

Detailed Description

All data on a single annihilation or decay channel, e.g.

chi –> gamma gamma, chi chi –> mu+ mu-

Definition at line 84 of file ProcessCatalog.hpp.

Constructor & Destructor Documentation

◆ TH_Channel()

Gambit::DarkBit::TH_Channel::TH_Channel ( std::vector< str finalStateIDs,
daFunk::Funk  genRate 
)

Constructor.

Definition at line 37 of file ProcessCatalog.cpp.

References Gambit::DarkBit::DarkBit_error(), LOCAL_INFO, and nFinalStates.

38  : finalStateIDs(finalStateIDs), nFinalStates(finalStateIDs.size()),
40  {
41  if ( nFinalStates < 2 )
42  {
43  DarkBit_error().raise(LOCAL_INFO, "Need at least two final state particles.");
44  }
45  }
error & DarkBit_error()
#define LOCAL_INFO
Definition: local_info.hpp:34
unsigned int nFinalStates
Number of final state particles in this channel.
daFunk::Funk genRate
Energy dependence of final state particles. Includes v_rel ("v") as last argument in case of annihila...
std::vector< std::string > finalStateIDs
Final state identifiers.
Here is the call graph for this function:

Member Function Documentation

◆ channelContains()

bool Gambit::DarkBit::TH_Channel::channelContains ( str  p) const

Indicate whether or not the final states of this channel contain a specific particle.

Definition at line 61 of file ProcessCatalog.cpp.

References finalStateIDs.

62  {
63  return std::find(finalStateIDs.begin(),
64  finalStateIDs.end(), p) != finalStateIDs.end();
65  }
std::vector< std::string > finalStateIDs
Final state identifiers.

◆ isChannel() [1/2]

bool Gambit::DarkBit::TH_Channel::isChannel ( str  p0,
str  p1,
str  p2 = "",
str  p3 = "" 
) const

Indicate whether or not this channel is the one defined by some specific final states. Particle name version.

Definition at line 70 of file ProcessCatalog.cpp.

71  {
72  str vals[] = {p0, p1};
73  std::vector<str> inIDs(std::begin(vals), std::end(vals));
74  if (p2 != "") inIDs.push_back(p2);
75  if (p3 != "") inIDs.push_back(p3);
76  return isChannel(inIDs);
77  }
bool isChannel(str, str, str="", str="") const
Indicate whether or not this channel is the one defined by some specific final states. Particle name version.
std::string str
Shorthand for a standard string.
Definition: Analysis.hpp:35

◆ isChannel() [2/2]

bool Gambit::DarkBit::TH_Channel::isChannel ( std::vector< str particles) const

Indicate whether or not this channel is the one defined by some specific final states. Particle vector version.

Definition at line 82 of file ProcessCatalog.cpp.

References finalStateIDs.

83  {
84  if (particles.size() != finalStateIDs.size()) return false;
85  return std::is_permutation(
86  finalStateIDs.begin(), finalStateIDs.end(), particles.begin());
87  }
std::vector< std::string > finalStateIDs
Final state identifiers.

◆ printChannel()

void Gambit::DarkBit::TH_Channel::printChannel ( ) const

Print information about this channel.

Definition at line 48 of file ProcessCatalog.cpp.

References Gambit::EOM, finalStateIDs, and Gambit::logger().

49  {
50  logger() << "Channel: ";
51  for ( auto it = finalStateIDs.begin(); it != finalStateIDs.end(); it++ )
52  {
53  logger() << *it << " ";
54  }
55  logger() << EOM;
56  }
const Logging::endofmessage EOM
Explicit const instance of the end of message struct in Gambit namespace.
Definition: logger.hpp:100
EXPORT_SYMBOLS Logging::LogMaster & logger()
Function to retrieve a reference to the Gambit global log object.
Definition: logger.cpp:95
std::vector< std::string > finalStateIDs
Final state identifiers.
Here is the call graph for this function:

Member Data Documentation

◆ finalStateIDs

std::vector<std::string> Gambit::DarkBit::TH_Channel::finalStateIDs

◆ genRate

daFunk::Funk Gambit::DarkBit::TH_Channel::genRate = daFunk::zero("dummyArgument")

Energy dependence of final state particles. Includes v_rel ("v") as last argument in case of annihilation.

Definition at line 113 of file ProcessCatalog.hpp.

Referenced by Gambit::DarkBit::DecayChain::DecayTable::getWidth(), and Gambit::DarkBit::nuyield_from_DS().

◆ nFinalStates

unsigned int Gambit::DarkBit::TH_Channel::nFinalStates

The documentation for this struct was generated from the following files: