Geant4 11.4.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4VImportanceAlgorithm Class Referenceabstract

G4VImportanceAlgorithm is an interface used by importance sampling to get the number of copies and weight a mother particle should be split into when crossing a boundary of "importance cells". The interface defines the input to be the ratio of the pre over the post importance and the weight of the mother track. It returns a struct containing the number of copies (including the mother track) to be produced and the weight of each track. A user defined algorithm deriving from this interface may be used by the importance sampling. More...

#include <G4VImportanceAlgorithm.hh>

Inheritance diagram for G4VImportanceAlgorithm:

Public Member Functions

 G4VImportanceAlgorithm ()=default
virtual ~G4VImportanceAlgorithm ()=default
virtual G4Nsplit_Weight Calculate (G4double ipre, G4double ipost, G4double init_w) const =0

Detailed Description

G4VImportanceAlgorithm is an interface used by importance sampling to get the number of copies and weight a mother particle should be split into when crossing a boundary of "importance cells". The interface defines the input to be the ratio of the pre over the post importance and the weight of the mother track. It returns a struct containing the number of copies (including the mother track) to be produced and the weight of each track. A user defined algorithm deriving from this interface may be used by the importance sampling.

Definition at line 59 of file G4VImportanceAlgorithm.hh.

Constructor & Destructor Documentation

◆ G4VImportanceAlgorithm()

G4VImportanceAlgorithm::G4VImportanceAlgorithm ( )
default

Default Constructor and Destructor.

◆ ~G4VImportanceAlgorithm()

virtual G4VImportanceAlgorithm::~G4VImportanceAlgorithm ( )
virtualdefault

Member Function Documentation

◆ Calculate()

virtual G4Nsplit_Weight G4VImportanceAlgorithm::Calculate ( G4double ipre,
G4double ipost,
G4double init_w ) const
pure virtual

Calculates the number of tracks and their weight according to the pre and post importance value and the weight of the mother track.

Parameters
[in]ipre"pre" importance value.
[in]ipost"post" importance value.
[in]init_wInitial weight value.
Returns
A struct containing the number of copies (including the mother track) to be produced and the weight of each track.

Implemented in G4ImportanceAlgorithm.


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