Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4CellScoreComposer Class Reference

#include <G4CellScoreComposer.hh>

Public Member Functions

 G4CellScoreComposer ()
 
 ~G4CellScoreComposer ()
 
void EstimatorCalculation (const G4Step &step)
 
void TrackEnters ()
 
void NewTrackPopedUp ()
 
void SetCollisionWeight (G4double weight)
 
void SetImportnace (G4double importance)
 
const G4CellScoreValuesGetStandardCellScoreValues () const
 

Detailed Description

Definition at line 51 of file G4CellScoreComposer.hh.

Constructor & Destructor Documentation

◆ G4CellScoreComposer()

G4CellScoreComposer::G4CellScoreComposer ( )

Definition at line 39 of file G4CellScoreComposer.cc.

39 :
40 fSCScoreValues()
41{}

◆ ~G4CellScoreComposer()

G4CellScoreComposer::~G4CellScoreComposer ( )

Definition at line 43 of file G4CellScoreComposer.cc.

44{}

Member Function Documentation

◆ EstimatorCalculation()

void G4CellScoreComposer::EstimatorCalculation ( const G4Step step)

Definition at line 46 of file G4CellScoreComposer.cc.

46 {
47
48 G4StepPoint *p = 0;
49 p = aStep.GetPreStepPoint();
50 if (!p) {
51 G4Exception("G4CellScoreComposer::EstimatorCalculation","Det0191",FatalException," no pointer to pre PreStepPoint!");
52 }
53 G4double sl = aStep.GetStepLength();
54 G4double slw = sl * p->GetWeight();
55 G4double slwe = slw * p->GetKineticEnergy();
56
57 G4double v = p->GetVelocity();
58 if (!(v>0.)) {
59 v = 10e-9;
60 }
61
62 fSCScoreValues.fSumSL += sl;
63 fSCScoreValues.fSumSLW += slw;
64 fSCScoreValues.fSumSLW_v += slw / v;
65 fSCScoreValues.fSumSLWE += slwe;
66 fSCScoreValues.fSumSLWE_v += slwe / v;
67
68}
@ FatalException
double G4double
Definition: G4Types.hh:64
G4double GetVelocity() const
G4double GetKineticEnergy() const
G4double GetWeight() const
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
Definition: G4Exception.cc:41

Referenced by G4CellScorer::ScoreAnExitingStep(), and G4CellScorer::ScoreAnInVolumeStep().

◆ GetStandardCellScoreValues()

const G4CellScoreValues & G4CellScoreComposer::GetStandardCellScoreValues ( ) const

Definition at line 82 of file G4CellScoreComposer.cc.

83 {
84 if (fSCScoreValues.fSumSLW > 0.) {
85 //divide by SumSLW or SumSLW_v ?
86 fSCScoreValues.fNumberWeightedEnergy =
87 fSCScoreValues.fSumSLWE_v / fSCScoreValues.fSumSLW_v;
88
89 fSCScoreValues.fFluxWeightedEnergy =
90 fSCScoreValues.fSumSLWE / fSCScoreValues.fSumSLW;
91
92 fSCScoreValues.fAverageTrackWeight =
93 fSCScoreValues.fSumSLW / fSCScoreValues.fSumSL;
94 }
95 return fSCScoreValues;
96}
G4double fNumberWeightedEnergy

Referenced by G4CellScorer::GetCellScoreValues(), and operator<<().

◆ NewTrackPopedUp()

void G4CellScoreComposer::NewTrackPopedUp ( )

Definition at line 72 of file G4CellScoreComposer.cc.

72 {
73 fSCScoreValues.fSumPopulation++;
74}

◆ SetCollisionWeight()

void G4CellScoreComposer::SetCollisionWeight ( G4double  weight)

Definition at line 76 of file G4CellScoreComposer.cc.

76 {
77 fSCScoreValues.fSumCollisions++;
78 fSCScoreValues.fSumCollisionsWeight+=weight;
79}

Referenced by G4CellScorer::ScoreAnInVolumeStep().

◆ SetImportnace()

void G4CellScoreComposer::SetImportnace ( G4double  importance)

Definition at line 98 of file G4CellScoreComposer.cc.

98 {
99 fSCScoreValues.fImportance = importance;
100}

◆ TrackEnters()

void G4CellScoreComposer::TrackEnters ( )

Definition at line 69 of file G4CellScoreComposer.cc.

69 {
70 fSCScoreValues.fSumTracksEntering++;
71}

Referenced by G4CellScorer::ScoreAnEnteringStep().


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