Geant4  10.03.p01
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
G4VCollision Class Referenceabstract

#include <G4VCollision.hh>

Inheritance diagram for G4VCollision:

Public Member Functions

 G4VCollision ()
 
void establish_G4MT_TLS_G4VCollision ()
 
 G4VCollision (void *s1, void *s2, void *s3, void *s4, void *s5, void *s6, void *s7)
 
virtual ~G4VCollision ()
 
G4bool operator== (const G4VCollision &right) const
 
G4bool operator!= (const G4VCollision &right) const
 
virtual G4double CrossSection (const G4KineticTrack &trk1, const G4KineticTrack &trk2) const
 
virtual G4KineticTrackVectorFinalState (const G4KineticTrack &trk1, const G4KineticTrack &trk2) const =0
 
virtual G4bool IsInCharge (const G4KineticTrack &trk1, const G4KineticTrack &trk2) const =0
 
virtual G4String GetName () const =0
 
virtual void Print () const
 
virtual void Print (const G4KineticTrack &trk1, const G4KineticTrack &trk2) const
 

Protected Member Functions

G4int GetNumberOfPartons (const G4ParticleDefinition *aP) const
 
virtual const G4CollisionVectorGetComponents () const
 
virtual const
G4VCrossSectionSource
GetCrossSectionSource () const =0
 
virtual const
G4VAngularDistribution
GetAngularDistribution () const =0
 
virtual const std::vector
< G4String > & 
GetListOfColliders (G4int whichOne) const =0
 

Detailed Description

Definition at line 40 of file G4VCollision.hh.

Constructor & Destructor Documentation

G4VCollision::G4VCollision ( )

Definition at line 35 of file G4VCollision.cc.

36 { }
G4VCollision::G4VCollision ( void s1,
void s2,
void s3,
void s4,
void s5,
void s6,
void s7 
)

Definition at line 143 of file G4VCollision.cc.

143 {}
G4VCollision::~G4VCollision ( )
virtual

Definition at line 38 of file G4VCollision.cc.

39 {
40 }

Member Function Documentation

G4double G4VCollision::CrossSection ( const G4KineticTrack trk1,
const G4KineticTrack trk2 
) const
virtual

Reimplemented in G4CollisionComposite, and G4CollisionNN.

Definition at line 55 of file G4VCollision.cc.

57 {
58  G4double sigma = 0.;
59 
61 
62  if (xSource != 0)
63  {
64  // There is a cross section for this Collision
65  sigma = xSource->CrossSection(aTrk1,aTrk2);
66  }
67  return sigma;
68 }
virtual const G4VCrossSectionSource * GetCrossSectionSource() const =0
double G4double
Definition: G4Types.hh:76
virtual G4double CrossSection(const G4KineticTrack &trk1, const G4KineticTrack &trk2) const =0

Here is the call graph for this function:

Here is the caller graph for this function:

void G4VCollision::establish_G4MT_TLS_G4VCollision ( )

Definition at line 144 of file G4VCollision.cc.

144 { }

Here is the caller graph for this function:

virtual G4KineticTrackVector* G4VCollision::FinalState ( const G4KineticTrack trk1,
const G4KineticTrack trk2 
) const
pure virtual

Implemented in G4CollisionComposite, G4VAnnihilationCollision, G4VScatteringCollision, and G4VElasticCollision.

Here is the caller graph for this function:

virtual const G4VAngularDistribution* G4VCollision::GetAngularDistribution ( ) const
protectedpure virtual
virtual const G4VCrossSectionSource* G4VCollision::GetCrossSectionSource ( ) const
protectedpure virtual
G4int G4VCollision::GetNumberOfPartons ( const G4ParticleDefinition aP) const
inlineprotected

Definition at line 69 of file G4VCollision.hh.

70  {
71  G4int result = 0;
72  for(G4int i=0; i<6; i++)
73  {
74  result += aP->GetQuarkContent(i+1);
75  result += aP->GetAntiQuarkContent(i+1);
76  }
77  return result;
78  }
G4double G4ParticleHPJENDLHEData::G4double result
G4int GetAntiQuarkContent(G4int flavor) const
int G4int
Definition: G4Types.hh:78
G4int GetQuarkContent(G4int flavor) const

Here is the call graph for this function:

Here is the caller graph for this function:

virtual G4bool G4VCollision::IsInCharge ( const G4KineticTrack trk1,
const G4KineticTrack trk2 
) const
pure virtual
G4bool G4VCollision::operator!= ( const G4VCollision right) const

Definition at line 49 of file G4VCollision.cc.

50 {
51  return (this != (G4VCollision *) &right);
52 }
G4bool G4VCollision::operator== ( const G4VCollision right) const

Definition at line 43 of file G4VCollision.cc.

44 {
45  return (this == (G4VCollision *) &right);
46 }
void G4VCollision::Print ( ) const
virtual

Definition at line 71 of file G4VCollision.cc.

72 {
73  G4String name = GetName();
74 
75  G4cout << "---- " << name << "---- Cross section" << G4endl;
76 
78  if (xSource) xSource->Print();
79 
80  G4int nComponents = 0;
81  const G4CollisionVector* components = GetComponents();
82  if (components)
83  {
84  nComponents = components->size();
85  }
86  G4cout << "---- " << name << "---- has " << nComponents << " components" <<G4endl;
87  G4int i = 0;
88  G4CollisionVector::const_iterator iter;
89  if (components)
90  {
91  for (iter = components->begin(); iter != components->end(); ++iter)
92  {
93  G4cout << "---- " << name << " ---- Component " << i << G4endl;
94  ((*iter))->Print();
95  i++;
96  }
97  }
98 
99 }
const XML_Char * name
Definition: expat.h:151
int G4int
Definition: G4Types.hh:78
virtual void Print() const
Definition: G4VCollision.cc:71
G4GLOB_DLL std::ostream G4cout
std::vector< G4VCollision * > G4CollisionVector
virtual const G4VCrossSectionSource * GetCrossSectionSource() const =0
virtual G4String GetName() const =0
virtual void Print() const
#define G4endl
Definition: G4ios.hh:61
virtual const G4CollisionVector * GetComponents() const
Definition: G4VCollision.hh:80

Here is the call graph for this function:

Here is the caller graph for this function:

void G4VCollision::Print ( const G4KineticTrack trk1,
const G4KineticTrack trk2 
) const
virtual

Definition at line 102 of file G4VCollision.cc.

104 {
105  G4String name = GetName();
106 
107  if (IsInCharge(trk1,trk2))
108  {
109  G4cout << "---- " << name << "is in charge ---- " << G4endl;
110  }
111  else
112  {
113  G4cout << "---- " << name << "is not in charge ---- " << G4endl;
114  }
115 
116  G4cout << "---- " << name << "---- Cross section" << G4endl;
117 
118  const G4VCrossSectionSource* xSource = GetCrossSectionSource();
119  if (xSource) xSource->Print();
120  G4cout << "Cross section = " << CrossSection(trk1,trk2) << G4endl;
121 
122  G4int nComponents = 0;
123  const G4CollisionVector* components = GetComponents();
124  if (components)
125  {
126  nComponents = components->size();
127  }
128  G4cout << "---- " << name << "has " << nComponents << " components" <<G4endl;
129 
130  G4int i = 0;
131  G4CollisionVector::const_iterator iter;
132  if (components)
133  {
134  for (iter = components->begin(); iter != components->end(); ++iter)
135  {
136  G4cout << "Component " << i << G4endl;
137  ((*iter))->Print();
138  i++;
139  }
140  }
141 }
const XML_Char * name
Definition: expat.h:151
virtual G4bool IsInCharge(const G4KineticTrack &trk1, const G4KineticTrack &trk2) const =0
int G4int
Definition: G4Types.hh:78
virtual void Print() const
Definition: G4VCollision.cc:71
G4GLOB_DLL std::ostream G4cout
virtual G4double CrossSection(const G4KineticTrack &trk1, const G4KineticTrack &trk2) const
Definition: G4VCollision.cc:55
std::vector< G4VCollision * > G4CollisionVector
virtual const G4VCrossSectionSource * GetCrossSectionSource() const =0
virtual G4String GetName() const =0
virtual void Print() const
#define G4endl
Definition: G4ios.hh:61
virtual const G4CollisionVector * GetComponents() const
Definition: G4VCollision.hh:80

Here is the call graph for this function:


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