Geant4-11
Public Member Functions | Protected Attributes | Private Attributes
G4MSSteppingAction Class Reference

#include <G4MSSteppingAction.hh>

Inheritance diagram for G4MSSteppingAction:
G4UserSteppingAction

Public Member Functions

 G4MSSteppingAction ()
 
G4double GetLambda0 () const
 
G4double GetTotalStepLength () const
 
G4double GetX0 () const
 
void Initialize (G4bool rSens, G4Region *reg)
 
virtual void SetSteppingManagerPointer (G4SteppingManager *pValue)
 
virtual void UserSteppingAction (const G4Step *)
 
virtual ~G4MSSteppingAction ()
 

Protected Attributes

G4SteppingManagerfpSteppingManager = nullptr
 

Private Attributes

G4double lambda = 0.0
 
G4double length = 0.0
 
G4bool regionSensitive = false
 
G4RegiontheRegion = nullptr
 
G4double x0 = 0.0
 

Detailed Description

Definition at line 42 of file G4MSSteppingAction.hh.

Constructor & Destructor Documentation

◆ G4MSSteppingAction()

G4MSSteppingAction::G4MSSteppingAction ( )

Definition at line 39 of file G4MSSteppingAction.cc.

39{}

◆ ~G4MSSteppingAction()

G4MSSteppingAction::~G4MSSteppingAction ( )
virtual

Definition at line 42 of file G4MSSteppingAction.cc.

42{}

Member Function Documentation

◆ GetLambda0()

G4double G4MSSteppingAction::GetLambda0 ( ) const
inline

Definition at line 54 of file G4MSSteppingAction.hh.

54{ return lambda; }

References lambda.

Referenced by G4MaterialScanner::DoScan().

◆ GetTotalStepLength()

G4double G4MSSteppingAction::GetTotalStepLength ( ) const
inline

Definition at line 52 of file G4MSSteppingAction.hh.

52{ return length; }

References length.

Referenced by G4MaterialScanner::DoScan().

◆ GetX0()

G4double G4MSSteppingAction::GetX0 ( ) const
inline

Definition at line 53 of file G4MSSteppingAction.hh.

53{ return x0; }

References x0.

Referenced by G4MaterialScanner::DoScan().

◆ Initialize()

void G4MSSteppingAction::Initialize ( G4bool  rSens,
G4Region reg 
)

Definition at line 45 of file G4MSSteppingAction.cc.

46{
47 regionSensitive = rSens;
48 theRegion = reg;
49 length = 0.;
50 x0 = 0.;
51 lambda = 0.;
52}
static const G4double reg

References lambda, length, reg, regionSensitive, theRegion, and x0.

Referenced by G4MaterialScanner::DoScan().

◆ SetSteppingManagerPointer()

void G4UserSteppingAction::SetSteppingManagerPointer ( G4SteppingManager pValue)
virtualinherited

Reimplemented in G4MultiSteppingAction.

Definition at line 63 of file G4UserSteppingAction.cc.

65{
66 fpSteppingManager = pValue;
67}
G4SteppingManager * fpSteppingManager

References G4UserSteppingAction::fpSteppingManager.

Referenced by G4TrackingManager::SetUserAction().

◆ UserSteppingAction()

void G4MSSteppingAction::UserSteppingAction ( const G4Step aStep)
virtual

Reimplemented from G4UserSteppingAction.

Definition at line 55 of file G4MSSteppingAction.cc.

56{
57 G4StepPoint* preStepPoint = aStep->GetPreStepPoint();
58 G4Region* region =
59 preStepPoint->GetPhysicalVolume()->GetLogicalVolume()->GetRegion();
60
61 if(regionSensitive && (region != theRegion))
62 return;
63
64 G4double stlen = aStep->GetStepLength();
65 G4Material* material = preStepPoint->GetMaterial();
66 length += stlen;
67 x0 += stlen / (material->GetRadlen());
68 lambda += stlen / (material->GetNuclearInterLength());
69}
double G4double
Definition: G4Types.hh:83
G4Region * GetRegion() const
G4Material * GetMaterial() const
G4VPhysicalVolume * GetPhysicalVolume() const
G4StepPoint * GetPreStepPoint() const
G4double GetStepLength() const
G4LogicalVolume * GetLogicalVolume() const
string material
Definition: eplot.py:19

References G4VPhysicalVolume::GetLogicalVolume(), G4StepPoint::GetMaterial(), G4StepPoint::GetPhysicalVolume(), G4Step::GetPreStepPoint(), G4LogicalVolume::GetRegion(), G4Step::GetStepLength(), lambda, length, eplot::material, regionSensitive, theRegion, and x0.

Field Documentation

◆ fpSteppingManager

G4SteppingManager* G4UserSteppingAction::fpSteppingManager = nullptr
protectedinherited

◆ lambda

G4double G4MSSteppingAction::lambda = 0.0
private

Definition at line 62 of file G4MSSteppingAction.hh.

Referenced by GetLambda0(), Initialize(), and UserSteppingAction().

◆ length

G4double G4MSSteppingAction::length = 0.0
private

Definition at line 60 of file G4MSSteppingAction.hh.

Referenced by GetTotalStepLength(), Initialize(), and UserSteppingAction().

◆ regionSensitive

G4bool G4MSSteppingAction::regionSensitive = false
private

Definition at line 58 of file G4MSSteppingAction.hh.

Referenced by Initialize(), and UserSteppingAction().

◆ theRegion

G4Region* G4MSSteppingAction::theRegion = nullptr
private

Definition at line 59 of file G4MSSteppingAction.hh.

Referenced by Initialize(), and UserSteppingAction().

◆ x0

G4double G4MSSteppingAction::x0 = 0.0
private

Definition at line 61 of file G4MSSteppingAction.hh.

Referenced by GetX0(), Initialize(), and UserSteppingAction().


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