1#ifndef BIASING_UTILITY_PARTIALENERGYSORTER_H
2#define BIASING_UTILITY_PARTIALENERGYSORTER_H
12#include "SimCore/UserAction.h"
85 const G4Track* aTrack,
86 const G4ClassificationOfNewTrack& currentTrackClass)
override;
98 void stepping(
const G4Step* step)
override;
102 return {simcore::TYPE::STEPPING, simcore::TYPE::STACKING,
103 simcore::TYPE::EVENT};
A simulation action that makes sure that all particles above a certain threshold are processed first.
bool below_threshold_
Are we simulating below the threshold yet?
virtual ~PartialEnergySorter()
Destructor.
void NewStage() override
Flag that we are now going below threshold.
std::vector< simcore::TYPE > getTypes() override
Retrieve the type of actions this class defines.
double threshold_
Minimum Kinetic Energy [MeV] we want to simulate first.
G4ClassificationOfNewTrack ClassifyNewTrack(const G4Track *aTrack, const G4ClassificationOfNewTrack ¤tTrackClass) override
Classify a "new" track.
void stepping(const G4Step *step) override
Checks if a particle steps from above the threshold to below it.
void BeginOfEventAction(const G4Event *event) override
At the beginning of a new event, we reset the counter for the number of particles above the energy th...
Class encapsulating parameters for configuring a processor.
Interface that defines a user action.