Public Member Functions | Private Attributes | List of all members
EDepSim::VertexInfo Class Reference

#include <EDepSimVertexInfo.hh>

Inheritance diagram for EDepSim::VertexInfo:

Public Member Functions

 VertexInfo ()
 
virtual ~VertexInfo ()
 
void SetName (const G4String &name)
 
G4String GetName () const
 
void SetReaction (const G4String &r)
 
const G4String & GetReaction () const
 Get the reaction code that created this vertex. More...
 
void SetFilename (const G4String &f)
 Set the file that this vertex came from. More...
 
const G4String & GetFilename ()
 Get the file that this vertex came from. More...
 
void SetInteractionNumber (int i)
 Set the index of the interaction within the input interaction file. More...
 
int GetInteractionNumber () const
 Get the index of the interaction within the input interaction file. More...
 
void SetCrossSection (double xs)
 
double GetCrossSection () const
 Get the cross section for the reaction that created this vertex. More...
 
void SetDiffCrossSection (double xs)
 
double GetDiffCrossSection () const
 
void SetWeight (double w)
 
double GetWeight () const
 Get the weight of the vertex. This will be one if it's not filled. More...
 
void SetProbability (double p)
 
double GetProbability () const
 Get the probability of the interaction. More...
 
virtual const G4PrimaryVertex * GetInformationalVertex (int i=0) const
 
virtual void AddInformationalVertex (G4PrimaryVertex *vtx)
 Add an informational vertex to this event. More...
 
virtual int GetNumberOfInformationalVertex () const
 Return the number of informational vertices. More...
 
void Print () const
 Required by G4UserPrimaryVertexInformation. More...
 

Private Attributes

G4String fName
 The generator name. More...
 
G4String fReaction
 The reaction code as defined by the kinematics generator. More...
 
G4PrimaryVertex * fInformationalVertex
 
G4String fFilename
 The file that this vertex came from. More...
 
int fInteractionNumber
 The index of the interaction in the input neutrino file. More...
 
double fCrossSection
 
double fDiffCrossSection
 
double fWeight
 
double fProbability
 

Detailed Description

Definition at line 14 of file EDepSimVertexInfo.hh.

Constructor & Destructor Documentation

EDepSim::VertexInfo::VertexInfo ( )
explicit

Definition at line 5 of file EDepSimVertexInfo.cc.

6  : fInformationalVertex(NULL),
8  fWeight(1.0), fProbability(1.0) {}
int fInteractionNumber
The index of the interaction in the input neutrino file.
G4PrimaryVertex * fInformationalVertex
EDepSim::VertexInfo::~VertexInfo ( )
virtual

Definition at line 10 of file EDepSimVertexInfo.cc.

10  {
11  if (fInformationalVertex != NULL) delete fInformationalVertex;
12 }
G4PrimaryVertex * fInformationalVertex

Member Function Documentation

void EDepSim::VertexInfo::AddInformationalVertex ( G4PrimaryVertex *  vtx)
virtual

Add an informational vertex to this event.

Definition at line 27 of file EDepSimVertexInfo.cc.

27  {
28  if (!fInformationalVertex) {
29  fInformationalVertex = vtx;
30  }
31  else {
32  fInformationalVertex->SetNext(vtx);
33  }
34 }
G4PrimaryVertex * fInformationalVertex
double EDepSim::VertexInfo::GetCrossSection ( ) const
inline

Get the cross section for the reaction that created this vertex.

Definition at line 55 of file EDepSimVertexInfo.hh.

55 {return fCrossSection;}
double EDepSim::VertexInfo::GetDiffCrossSection ( ) const
inline

Get the differential cross section for the kinematics of the reaction that created this vertex.

Definition at line 63 of file EDepSimVertexInfo.hh.

const G4String& EDepSim::VertexInfo::GetFilename ( void  )
inline

Get the file that this vertex came from.

Definition at line 42 of file EDepSimVertexInfo.hh.

42 {return fFilename;}
G4String fFilename
The file that this vertex came from.
const G4PrimaryVertex * EDepSim::VertexInfo::GetInformationalVertex ( int  i = 0) const
virtual

Return the informational vertices that are associated with this event. These vertices usually contain information associated with the primary interaction, such as the incoming neutrino and nucleon.

Definition at line 14 of file EDepSimVertexInfo.cc.

14  {
15  if (i == 0) {
16  return fInformationalVertex;
17  }
18  if (i<0) return NULL;
19  const G4PrimaryVertex* infoVertex = fInformationalVertex;
20  for (int j=0; j < i; j++) {
21  if (infoVertex == NULL) return NULL;
22  infoVertex = infoVertex->GetNext();
23  }
24  return infoVertex;
25 }
G4PrimaryVertex * fInformationalVertex
int EDepSim::VertexInfo::GetInteractionNumber ( ) const
inline

Get the index of the interaction within the input interaction file.

Definition at line 48 of file EDepSimVertexInfo.hh.

48 {return fInteractionNumber;}
int fInteractionNumber
The index of the interaction in the input neutrino file.
G4String EDepSim::VertexInfo::GetName ( void  ) const
inline

Get the generator name. The name has the format of <kine>:<count><pos>-<time> where <kine> is the kinematics generator, <count> is the count generator, <pos> is the position generator, and <time> is the time generator.

Definition at line 28 of file EDepSimVertexInfo.hh.

28 {return fName;}
G4String fName
The generator name.
int EDepSim::VertexInfo::GetNumberOfInformationalVertex ( ) const
virtual

Return the number of informational vertices.

Definition at line 36 of file EDepSimVertexInfo.cc.

36  {
37  int number = 0;
38  const G4PrimaryVertex* infoVertex = fInformationalVertex;
39  for (int j=0; j < 1000; j++) {
40  if (infoVertex == NULL) return number;
41  ++number;
42  infoVertex = infoVertex->GetNext();
43  }
44  return number;
45 }
G4PrimaryVertex * fInformationalVertex
double EDepSim::VertexInfo::GetProbability ( ) const
inline

Get the probability of the interaction.

Definition at line 79 of file EDepSimVertexInfo.hh.

79 {return fProbability;}
const G4String& EDepSim::VertexInfo::GetReaction ( ) const
inline

Get the reaction code that created this vertex.

Definition at line 36 of file EDepSimVertexInfo.hh.

36 {return fReaction;}
G4String fReaction
The reaction code as defined by the kinematics generator.
double EDepSim::VertexInfo::GetWeight ( ) const
inline

Get the weight of the vertex. This will be one if it's not filled.

Definition at line 71 of file EDepSimVertexInfo.hh.

71 {return fWeight;}
void EDepSim::VertexInfo::Print ( void  ) const
inline

Required by G4UserPrimaryVertexInformation.

Definition at line 93 of file EDepSimVertexInfo.hh.

93 {};
void EDepSim::VertexInfo::SetCrossSection ( double  xs)
inline

Set the cross section for the reaction that created this vertex. This should be in normal HEP units.

Definition at line 52 of file EDepSimVertexInfo.hh.

void EDepSim::VertexInfo::SetDiffCrossSection ( double  xs)
inline

Set the differential cross section for the kinematics that created this vertex. This should be in normal HEP units.

Definition at line 59 of file EDepSimVertexInfo.hh.

void EDepSim::VertexInfo::SetFilename ( const G4String &  f)
inline

Set the file that this vertex came from.

Definition at line 39 of file EDepSimVertexInfo.hh.

39 {fFilename = f;}
G4String fFilename
The file that this vertex came from.
void EDepSim::VertexInfo::SetInteractionNumber ( int  i)
inline

Set the index of the interaction within the input interaction file.

Definition at line 45 of file EDepSimVertexInfo.hh.

45 {fInteractionNumber = i;}
int fInteractionNumber
The index of the interaction in the input neutrino file.
void EDepSim::VertexInfo::SetName ( const G4String &  name)
inline

Set the generator name. This is set in EDepSim::PrimaryGenerator after the vertex is generated so it should not be set when the vertex is created in a kinematics generator.

Definition at line 22 of file EDepSimVertexInfo.hh.

22 {fName = name;}
static QCString name
Definition: declinfo.cpp:673
G4String fName
The generator name.
void EDepSim::VertexInfo::SetProbability ( double  p)
inline

Set the probability of the interaction that created this vertex. This includes the effect of the cross section, path length through the material, etc.

Definition at line 76 of file EDepSimVertexInfo.hh.

void EDepSim::VertexInfo::SetReaction ( const G4String &  r)
inline

Set reaction that created this vertex. This is defined by each kinematics generator.

Todo:
We need to define a standard format for the reaction names.

Definition at line 33 of file EDepSimVertexInfo.hh.

33 {fReaction = r;}
G4String fReaction
The reaction code as defined by the kinematics generator.
void EDepSim::VertexInfo::SetWeight ( double  w)
inline

Set the weight for the vertex. This is used if the generator is using a weighted sample (e.g. over sampling the high energy part of the neutrino spectrum smooth out the distributions).

Definition at line 68 of file EDepSimVertexInfo.hh.

Member Data Documentation

double EDepSim::VertexInfo::fCrossSection
private

The total cross section of the interaction creating this vertex. This is zero if it's not filled.

Definition at line 114 of file EDepSimVertexInfo.hh.

double EDepSim::VertexInfo::fDiffCrossSection
private

The differential cross section of the interaction kinematics creating this vertex. This is zero if it's not filled.

Definition at line 118 of file EDepSimVertexInfo.hh.

G4String EDepSim::VertexInfo::fFilename
private

The file that this vertex came from.

Definition at line 107 of file EDepSimVertexInfo.hh.

G4PrimaryVertex* EDepSim::VertexInfo::fInformationalVertex
private

The list of informational vertices associated with this primary vertex.

Definition at line 104 of file EDepSimVertexInfo.hh.

int EDepSim::VertexInfo::fInteractionNumber
private

The index of the interaction in the input neutrino file.

Definition at line 110 of file EDepSimVertexInfo.hh.

G4String EDepSim::VertexInfo::fName
private

The generator name.

Definition at line 93 of file EDepSimVertexInfo.hh.

double EDepSim::VertexInfo::fProbability
private

The overall probability of this interaction given the cross sections, path lengths through materials, &c). This is one if it is not filled.

Definition at line 126 of file EDepSimVertexInfo.hh.

G4String EDepSim::VertexInfo::fReaction
private

The reaction code as defined by the kinematics generator.

Definition at line 100 of file EDepSimVertexInfo.hh.

double EDepSim::VertexInfo::fWeight
private

The weight for the interaction creating this vertex. This is one if it's not filled.

Definition at line 122 of file EDepSimVertexInfo.hh.


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