File indexing completed on 2025-01-18 09:58:21
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029
0030
0031
0032
0033
0034
0035
0036
0037
0038 #ifndef G4GeometrySampler_hh
0039 #define G4GeometrySampler_hh G4GeometrySampler_hh
0040
0041 #include "G4Types.hh"
0042 #include "G4String.hh"
0043 #include "G4VSampler.hh"
0044 #include "G4VSamplerConfigurator.hh"
0045
0046 class G4ImportanceConfigurator;
0047 class G4WeightWindowConfigurator;
0048
0049 class G4WeightCutOffConfigurator;
0050
0051
0052 class G4GeometrySampler : public G4VSampler
0053 {
0054
0055 public:
0056
0057 explicit G4GeometrySampler(G4VPhysicalVolume *worldvolume, const G4String &particlename);
0058 explicit G4GeometrySampler(G4String worldvolumeName, const G4String &particlename);
0059 virtual ~G4GeometrySampler();
0060
0061
0062 virtual void PrepareImportanceSampling(G4VIStore* istore,
0063 const G4VImportanceAlgorithm
0064 *ialg);
0065 virtual void PrepareWeightRoulett(G4double wsurvive,
0066 G4double wlimit,
0067 G4double isource);
0068
0069 virtual void PrepareWeightWindow(G4VWeightWindowStore *wwstore,
0070 G4VWeightWindowAlgorithm *wwAlg,
0071 G4PlaceOfAction placeOfAction);
0072
0073 virtual void Configure();
0074 virtual void AddProcess();
0075
0076 virtual void ClearSampling();
0077 virtual G4bool IsConfigured() const;
0078
0079 void SetParallel(G4bool paraflag);
0080 void SetWorld(const G4VPhysicalVolume* world);
0081 void SetParticle(const G4String &particlename);
0082
0083 inline G4String GetParticleName(){return fParticleName;};
0084
0085 private:
0086
0087 G4GeometrySampler(const G4GeometrySampler &);
0088 G4GeometrySampler &
0089 operator=(const G4GeometrySampler &);
0090
0091 private:
0092
0093 G4String fParticleName;
0094 const G4VPhysicalVolume* fWorld;
0095 G4String fWorldName;
0096 G4ImportanceConfigurator *fImportanceConfigurator;
0097
0098
0099 G4WeightCutOffConfigurator *fWeightCutOffConfigurator;
0100 G4VIStore* fIStore;
0101 G4WeightWindowConfigurator *fWeightWindowConfigurator;
0102 G4VWeightWindowStore *fWWStore;
0103 G4bool fIsConfigured;
0104 G4Configurators fConfigurators;
0105
0106 G4bool paraflag;
0107
0108 };
0109
0110 #endif
0111