LDMX Software
TargetBremFilter.h
1#ifndef BIASING_TARGETBREMFILTER_H
2#define BIASING_TARGETBREMFILTER_H
3
4//----------------//
5// C++ StdLib //
6//----------------//
7#include <algorithm>
8
9/*~~~~~~~~~~~~~*/
10/* SimCore */
11/*~~~~~~~~~~~~~*/
12#include "SimCore/UserAction.h"
13
14/*~~~~~~~~~~~~~~~*/
15/* Framework */
16/*~~~~~~~~~~~~~~~*/
17#include "Framework/Configure/Parameters.h"
18#include "Framework/Logger.h"
19
20namespace biasing {
21
27 public:
29 TargetBremFilter(const std::string& name,
31
34
39 void stepping(const G4Step* step) override;
40
46 void EndOfEventAction(const G4Event*) override;
47
54 G4ClassificationOfNewTrack ClassifyNewTrack(
55 const G4Track* aTrack,
56 const G4ClassificationOfNewTrack& currentTrackClass) override;
57
59 std::vector<simcore::TYPE> getTypes() override {
60 return {simcore::TYPE::EVENT, simcore::TYPE::STACKING,
61 simcore::TYPE::STEPPING};
62 }
63
64 private:
66 double recoilMaxPThreshold_{1500}; // MeV
67
70
72 bool killRecoil_{false};
73
74}; // TargetBremFilter
75} // namespace biasing
76
77#endif // BIASING_TARGETBREMFILTER_H
User action that allows a user to filter out events that don't result in a brem within the target.
bool killRecoil_
Flag indicating if the recoil electron track should be killed.
std::vector< simcore::TYPE > getTypes() override
Retrieve the type of actions this class defines.
void EndOfEventAction(const G4Event *) override
Method called at the end of every event.
TargetBremFilter(const std::string &name, framework::config::Parameters &parameters)
Constructor.
void stepping(const G4Step *step) override
Implement the stepping action which performs the target volume biasing.
G4ClassificationOfNewTrack ClassifyNewTrack(const G4Track *aTrack, const G4ClassificationOfNewTrack &currentTrackClass) override
Classify a new track which postpones track processing.
double recoilMaxPThreshold_
Recoil electron threshold.
double bremEnergyThreshold_
Brem gamma energy treshold.
Class encapsulating parameters for configuring a processor.
Definition Parameters.h:29
Interface that defines a user action.
Definition UserAction.h:43