Geant4 VMC Version 6.6
Loading...
Searching...
No Matches
TG4G3CutVector.h
Go to the documentation of this file.
1#ifndef TG4_G3_CUT_VECTOR_H
2#define TG4_G3_CUT_VECTOR_H
3
4//------------------------------------------------
5// The Geant4 Virtual Monte Carlo package
6// Copyright (C) 2007 - 2014 Ivana Hrivnacova
7// All rights reserved.
8//
9// For the licensing terms see geant4_vmc/LICENSE.
10// Contact: root-vmc@cern.ch
11//-------------------------------------------------
12
17
18#include "TG4G3Cut.h"
19#include "TG4Globals.h"
20
21#include <array>
22
23class G4Track;
24
30
32{
33 public:
35 TG4G3CutVector(const TG4G3CutVector& right);
37
38 // operators
40 G4double operator[](G4int index) const;
41
42 // static methods
43 static G4double Tolerance();
44 static TG4G3Cut GetCut(const G4String& cutName);
45 static G4bool CheckCutValue(TG4G3Cut cut, G4double value);
46 static const G4String& GetCutName(TG4G3Cut cut);
47
48 // set methods
49 void SetCut(TG4G3Cut cut, G4double cutValue);
50 void SetG3Defaults();
51 void SetDeltaRaysOn(G4bool value);
52
53 // methods
54 G4String Format() const;
55 void Print() const;
56
57 // get methods
58 G4double GetMinEkineForGamma(const G4Track& track) const;
59 G4double GetMinEkineForElectron(const G4Track& track) const;
60 G4double GetMinEkineForChargedHadron(const G4Track& track) const;
61 G4double GetMinEkineForNeutralHadron(const G4Track& track) const;
62 G4double GetMinEkineForMuon(const G4Track& track) const;
63 G4double GetMinEtotPair() const;
64 G4bool IsCut() const;
65
66 private:
67 // static methods
68 static void FillCutNameVector();
69
70 //
71 // static data members
72
74 static const G4double fgkDCUTEOff;
75
77 static const G4double fgkDCUTMOff;
78
80 static const G4double fgkTolerance;
81
84
85 //
86 // data members
87
90
92 G4bool fDeltaRaysOn = true;
93
95 G4bool fIsCut = false;
96
101
103 std::array<G4bool, 4> fIsBDCut = { false, false, false, false};
104
109
111 std::array<G4bool, 4> fApplyBDCut = { false, false, false, false};
112};
113
114// inline methods
115
117{
119 return fgkTolerance;
120}
121
122inline void TG4G3CutVector::SetDeltaRaysOn(G4bool value)
123{
125 fDeltaRaysOn = value;
126}
127
128inline G4bool TG4G3CutVector::IsCut() const
129{
131 return fIsCut;
132}
133
134#endif // TG4_CUT_VECTOR_H
Definition of the enumeration TG4G3Cut.
Definition of the TG4Globals class and basic container types.
Vector of kinetic energy cut values with convenient set/get methods.
std::array< G4bool, 4 > fApplyBDCut
flag set if [B/D]CUT[E/M] cut is different from CUT[ELE/GAM]
IsBDCutIndex
local enumeration for the indices in the flags arrays
G4bool fIsCut
flag if any value is set
G4double GetMinEkineForChargedHadron(const G4Track &track) const
static TG4G3Cut GetCut(const G4String &cutName)
TG4doubleVector fCutVector
vector of kinetic energy cut values
ApplyBDCutIndex
local enumeration for the indices in the flags arrays
G4double GetMinEtotPair() const
static G4double Tolerance()
static TG4StringVector fgCutNameVector
vector of cut parameters names
static const G4double fgkDCUTMOff
cut for delta rays by mu (if off)
static G4bool CheckCutValue(TG4G3Cut cut, G4double value)
std::array< G4bool, 4 > fIsBDCut
flag to prevent overwiting [B/D]CUT[E/M] cut if set by user
G4double operator[](G4int index) const
G4double GetMinEkineForGamma(const G4Track &track) const
static const G4String & GetCutName(TG4G3Cut cut)
G4String Format() const
G4double GetMinEkineForMuon(const G4Track &track) const
G4double GetMinEkineForNeutralHadron(const G4Track &track) const
static const G4double fgkDCUTEOff
cut for delta rays by e- (if off)
void Print() const
G4bool fDeltaRaysOn
delta rays process control
G4bool IsCut() const
TG4G3CutVector & operator=(const TG4G3CutVector &right)
G4double GetMinEkineForElectron(const G4Track &track) const
static void FillCutNameVector()
void SetDeltaRaysOn(G4bool value)
void SetCut(TG4G3Cut cut, G4double cutValue)
static const G4double fgkTolerance
tolerance for comparing cuts
std::vector< G4String > TG4StringVector
Definition TG4Globals.h:49
std::vector< G4double > TG4doubleVector
Definition TG4Globals.h:45
TG4G3Cut
Enumeration for G3 types of kinetic energy cuts.
Definition TG4G3Cut.h:22