Ignore:
Timestamp:
Dec 22, 2010, 3:52:27 PM (15 years ago)
Author:
garnier
Message:

geant4 tag 9.4

Location:
trunk/source/event/include
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/event/include/G4GeneralParticleSourceMessenger.hh

    r816 r1347  
    212212  G4UIcmdWithADouble         *gradientCmd1;
    213213  G4UIcmdWithADouble         *interceptCmd1;
     214  G4UIcmdWithADouble         *arbeintCmd1;
    214215  G4UIcmdWithoutParameter    *calculateCmd1;
    215216  G4UIcmdWithABool           *energyspecCmd1;
     
    237238  // old ones, will be removed soon
    238239  G4UIcmdWith3Vector         *histpointCmd1;
     240  G4UIcmdWithAString         *histfileCmd1;
    239241  G4UIcmdWithAString         *histnameCmd1;
    240242  G4UIcmdWithAString         *arbintCmd1;
  • trunk/source/event/include/G4SPSEneDistribution.hh

    r1315 r1347  
    144144#include "G4SPSRandomGenerator.hh"
    145145
    146 class G4SPSEneDistribution
    147 {
     146class G4SPSEneDistribution {
    148147public:
    149   G4SPSEneDistribution ();
    150   ~G4SPSEneDistribution ();
    151 
    152   void SetEnergyDisType(G4String);
    153   inline G4String GetEnergyDisType() {return EnergyDisType;};
    154   void SetEmin(G4double);
    155   inline G4double GetEmin() {return Emin;} ;
    156   inline G4double GetArbEmin() {return ArbEmin;} ;
    157   void SetEmax(G4double);
    158   inline G4double GetEmax() {return Emax;} ;
    159   inline G4double GetArbEmax() {return ArbEmax;};
    160   void SetMonoEnergy(G4double);
    161   void SetAlpha(G4double);
    162   void SetTemp(G4double);
    163   void SetBeamSigmaInE(G4double);
    164   void SetEzero(G4double);
    165   void SetGradient(G4double);
    166   void SetInterCept(G4double);
    167   void UserEnergyHisto(G4ThreeVector);
    168   void ArbEnergyHisto(G4ThreeVector);
    169   void EpnEnergyHisto(G4ThreeVector);
    170 
    171   void InputEnergySpectra(G4bool);
    172   void InputDifferentialSpectra(G4bool);
    173   void ArbInterpolate(G4String);
    174   inline G4String GetIntType() {return IntType;};
    175   void Calculate();
    176   //
    177   void SetBiasRndm(G4SPSRandomGenerator* a) {eneRndm = a; };
    178   // method to re-set the histograms
    179   void ReSetHist(G4String);
    180   // Set the verbosity level.
    181   void SetVerbosity(G4int a) {verbosityLevel = a; } ;
    182   //x
    183 
    184   G4double GetMonoEnergy () {return MonoEnergy; }; //Mono-energteic energy
    185   G4double GetSE() {return SE;}; // Standard deviation for Gaussion distrbution in energy
    186   G4double Getalpha () {return alpha;}; // alpha (pow)
    187   G4double GetEzero() {return Ezero;}; // E0 (exp)
    188   G4double GetTemp() {return Temp;}; // Temp (bbody,brem)
    189   G4double Getgrad() {return grad;}; // gradient and intercept for linear spectra
    190   G4double Getcept() {return cept;};
    191 
    192   inline G4PhysicsOrderedFreeVector  GetUserDefinedEnergyHisto(){return UDefEnergyH;};
    193   inline G4PhysicsOrderedFreeVector  GetArbEnergyHisto(){return ArbEnergyH;};
    194 
    195   G4double GenerateOne(G4ParticleDefinition*);
    196  
     148        G4SPSEneDistribution();
     149        ~G4SPSEneDistribution();
     150
     151        void SetEnergyDisType(G4String);
     152        inline G4String GetEnergyDisType() {
     153                return EnergyDisType;
     154        }
     155        ;
     156        void SetEmin(G4double);
     157        inline G4double GetEmin() {
     158                return Emin;
     159        }
     160        ;
     161        inline G4double GetArbEmin() {
     162                return ArbEmin;
     163        }
     164        ;
     165        void SetEmax(G4double);
     166        inline G4double GetEmax() {
     167                return Emax;
     168        }
     169        ;
     170        inline G4double GetArbEmax() {
     171                return ArbEmax;
     172        }
     173        ;
     174        void SetMonoEnergy(G4double);
     175        void SetAlpha(G4double);
     176        void SetBiasAlpha(G4double);
     177        void SetTemp(G4double);
     178        void SetBeamSigmaInE(G4double);
     179        void SetEzero(G4double);
     180        void SetGradient(G4double);
     181        void SetInterCept(G4double);
     182        void UserEnergyHisto(G4ThreeVector);
     183        void ArbEnergyHisto(G4ThreeVector);
     184        void ArbEnergyHistoFile(G4String);
     185        void EpnEnergyHisto(G4ThreeVector);
     186
     187        void InputEnergySpectra(G4bool);
     188        void InputDifferentialSpectra(G4bool);
     189        void ArbInterpolate(G4String);
     190        inline G4String GetIntType() {
     191                return IntType;
     192        }
     193        ;
     194        void Calculate();
     195        //
     196        void SetBiasRndm(G4SPSRandomGenerator* a) {
     197                eneRndm = a;
     198        }
     199        ;
     200        // method to re-set the histograms
     201        void ReSetHist(G4String);
     202        // Set the verbosity level.
     203        void SetVerbosity(G4int a) {
     204                verbosityLevel = a;
     205        }
     206        ;
     207        //x
     208        G4double GetWeight() {
     209                return weight;
     210        }
     211
     212        G4double GetMonoEnergy() {
     213                return MonoEnergy;
     214        }
     215        ; //Mono-energteic energy
     216        G4double GetSE() {
     217                return SE;
     218        }
     219        ; // Standard deviation for Gaussion distrbution in energy
     220        G4double Getalpha() {
     221                return alpha;
     222        }
     223        ; // alpha (pow)
     224        G4double GetEzero() {
     225                return Ezero;
     226        }
     227        ; // E0 (exp)
     228        G4double GetTemp() {
     229                return Temp;
     230        }
     231        ; // Temp (bbody,brem)
     232        G4double Getgrad() {
     233                return grad;
     234        }
     235        ; // gradient and intercept for linear spectra
     236        G4double Getcept() {
     237                return cept;
     238        }
     239        ;
     240
     241        inline G4PhysicsOrderedFreeVector GetUserDefinedEnergyHisto() {
     242                return UDefEnergyH;
     243        }
     244        ;
     245        inline G4PhysicsOrderedFreeVector GetArbEnergyHisto() {
     246                return ArbEnergyH;
     247        }
     248        ;
     249
     250        G4double GenerateOne(G4ParticleDefinition*);
     251        G4double GetProbability (G4double);
     252
     253
    197254private:
    198   void LinearInterpolation();
    199   void LogInterpolation();
    200   void ExpInterpolation();
    201   void SplineInterpolation();
    202   void CalculateCdgSpectrum();
    203   void CalculateBbodySpectrum();
    204 
    205   // The following methods generate energies according to the spectral
    206   // parameters defined above.
    207   void GenerateMonoEnergetic();
    208   void GenerateLinearEnergies(G4bool);
    209   void GeneratePowEnergies(G4bool);
    210   void GenerateExpEnergies(G4bool );
    211   void GenerateGaussEnergies();
    212   void GenerateBremEnergies();
    213   void GenerateBbodyEnergies();
    214   void GenerateCdgEnergies();
    215   void GenUserHistEnergies();
    216   void GenEpnHistEnergies();
    217   void GenArbPointEnergies();
    218   // converts energy per nucleon to energy.
    219   void ConvertEPNToEnergy();
     255        void LinearInterpolation();
     256        void LogInterpolation();
     257        void ExpInterpolation();
     258        void SplineInterpolation();
     259        void CalculateCdgSpectrum();
     260        void CalculateBbodySpectrum();
     261
     262        // The following methods generate energies according to the spectral
     263        // parameters defined above.
     264        void GenerateMonoEnergetic();
     265        void GenerateLinearEnergies(G4bool);
     266        void GeneratePowEnergies(G4bool);
     267        void GenerateBiasPowEnergies();
     268        void GenerateExpEnergies(G4bool);
     269        void GenerateGaussEnergies();
     270        void GenerateBremEnergies();
     271        void GenerateBbodyEnergies();
     272        void GenerateCdgEnergies();
     273        void GenUserHistEnergies();
     274        void GenEpnHistEnergies();
     275        void GenArbPointEnergies();
     276        // converts energy per nucleon to energy.
     277        void ConvertEPNToEnergy();
     278
    220279
    221280private:
    222281
    223   G4String EnergyDisType; // energy dis type Variable  - Mono,Lin,Exp,etc
    224   G4double MonoEnergy; //Mono-energteic energy
    225   G4double SE ; // Standard deviation for Gaussion distrbution in energy
    226   G4double Emin, Emax; // emin and emax
    227   G4double alpha, Ezero, Temp; // alpha (pow), E0 (exp) and Temp (bbody,brem)
    228   G4double grad, cept; // gradient and intercept for linear spectra
    229   G4bool EnergySpec; // true - energy spectra, false - momentum spectra
    230   G4bool DiffSpec;  // true - differential spec, false integral spec
    231   G4bool ApplyRig; // false no rigidity cutoff, true then apply one
    232   G4double ERig; // energy of rigidity cutoff
    233   G4PhysicsOrderedFreeVector UDefEnergyH; // energy hist data
    234   G4PhysicsOrderedFreeVector IPDFEnergyH; 
    235   G4bool IPDFEnergyExist, IPDFArbExist, Epnflag;
    236   G4PhysicsOrderedFreeVector ArbEnergyH; // Arb x,y histogram
    237   G4PhysicsOrderedFreeVector IPDFArbEnergyH; // IPDF for Arb
    238   G4PhysicsOrderedFreeVector EpnEnergyH;
    239   G4double CDGhist[3]; // cumulative histo for cdg
    240   G4double BBHist[10001], Bbody_x[10001];
    241   G4String IntType; // Interpolation type
    242   G4double Arb_grad[1024], Arb_cept[1024]; // grad and cept for 1024 segments
    243   G4double Arb_alpha[1024], Arb_Const[1024]; // alpha and constants
    244   G4double Arb_ezero[1024]; // ezero
    245   G4double ArbEmin, ArbEmax; // Emin and Emax for the whole arb distribution used primarily for debug.
    246 
    247   G4double               particle_energy;
    248   G4ParticleDefinition*  particle_definition;
    249 
    250   G4SPSRandomGenerator* eneRndm;
    251 
    252   // Verbosity
    253   G4int verbosityLevel;
    254 
    255   G4PhysicsOrderedFreeVector ZeroPhysVector ; // for re-set only
    256 
    257   G4DataInterpolation *SplineInt; // holds Spline stuff
     282        G4String EnergyDisType; // energy dis type Variable  - Mono,Lin,Exp,etc
     283        G4double weight; // particle weight
     284        G4double MonoEnergy; //Mono-energteic energy
     285        G4double SE; // Standard deviation for Gaussion distrbution in energy
     286        G4double Emin, Emax; // emin and emax
     287        G4double alpha, Ezero, Temp; // alpha (pow), E0 (exp) and Temp (bbody,brem)
     288        G4double biasalpha; // biased power index
     289        G4double grad, cept; // gradient and intercept for linear spectra
     290        G4double prob_norm; // normalisation factor use in calculate the probability
     291        G4bool Biased; // true - biased to power-law
     292        G4bool EnergySpec; // true - energy spectra, false - momentum spectra
     293        G4bool DiffSpec; // true - differential spec, false integral spec
     294        G4bool ApplyRig; // false no rigidity cutoff, true then apply one
     295        G4double ERig; // energy of rigidity cutoff
     296        G4PhysicsOrderedFreeVector UDefEnergyH; // energy hist data
     297        G4PhysicsOrderedFreeVector IPDFEnergyH;
     298        G4bool IPDFEnergyExist, IPDFArbExist, Epnflag;
     299        G4PhysicsOrderedFreeVector ArbEnergyH; // Arb x,y histogram
     300        G4PhysicsOrderedFreeVector IPDFArbEnergyH; // IPDF for Arb
     301        G4PhysicsOrderedFreeVector EpnEnergyH;
     302        G4double CDGhist[3]; // cumulative histo for cdg
     303        G4double BBHist[10001], Bbody_x[10001];
     304        G4String IntType; // Interpolation type
     305        G4double Arb_grad[1024], Arb_cept[1024]; // grad and cept for 1024 segments
     306        G4double Arb_alpha[1024], Arb_Const[1024]; // alpha and constants
     307        G4double Arb_ezero[1024]; // ezero
     308        G4double ArbEmin, ArbEmax; // Emin and Emax for the whole arb distribution used primarily for debug.
     309
     310        G4double particle_energy;
     311        G4ParticleDefinition* particle_definition;
     312
     313        G4SPSRandomGenerator* eneRndm;
     314
     315        // Verbosity
     316        G4int verbosityLevel;
     317
     318        G4PhysicsOrderedFreeVector ZeroPhysVector; // for re-set only
     319
     320        G4DataInterpolation *SplineInt[1024]; // holds Spline stuff required for sampling
     321        G4DataInterpolation *Splinetemp; // holds a temp Spline used for calculating area
    258322
    259323};
    260324
    261 
    262325#endif
    263326
    264 
    265 
    266 
  • trunk/source/event/include/G4SPSRandomGenerator.hh

    r816 r1347  
    136136#include "G4DataInterpolation.hh"
    137137
    138 class G4SPSRandomGenerator
    139 {
     138class G4SPSRandomGenerator {
    140139public:
    141   G4SPSRandomGenerator ();
    142   ~G4SPSRandomGenerator ();
    143 
    144   //  static G4SPSRandomGenerator* getInstance ();
    145 
    146   // Biasing Methods
    147   void SetXBias(G4ThreeVector);
    148   void SetYBias(G4ThreeVector);
    149   void SetZBias(G4ThreeVector);
    150   void SetThetaBias(G4ThreeVector);
    151   void SetPhiBias(G4ThreeVector);
    152   void SetEnergyBias(G4ThreeVector);
    153   void SetPosThetaBias(G4ThreeVector);
    154   void SetPosPhiBias(G4ThreeVector);
    155   G4double GenRandX();
    156   G4double GenRandY();
    157   G4double GenRandZ();
    158   G4double GenRandTheta();
    159   G4double GenRandPhi();
    160   G4double GenRandEnergy();
    161   G4double GenRandPosTheta();
    162   G4double GenRandPosPhi();
    163 
    164   inline void SetIntensityWeight(G4double weight) {bweights[8]=weight;};
    165 
    166   inline G4double GetBiasWeight()
    167   { return bweights[0]*bweights[1]*bweights[2]*bweights[3]*bweights[4]*bweights[5]*bweights[6]*bweights[7]*bweights[8];};
    168  
    169  // method to re-set the histograms
    170   void ReSetHist(G4String);
    171 
    172   // Set the verbosity level.
    173    void SetVerbosity(G4int a) {verbosityLevel = a; } ;
     140        G4SPSRandomGenerator();
     141        ~G4SPSRandomGenerator();
     142
     143        //  static G4SPSRandomGenerator* getInstance ();
     144
     145        // Biasing Methods
     146        void SetXBias(G4ThreeVector);
     147        void SetYBias(G4ThreeVector);
     148        void SetZBias(G4ThreeVector);
     149        void SetThetaBias(G4ThreeVector);
     150        void SetPhiBias(G4ThreeVector);
     151        void SetEnergyBias(G4ThreeVector);
     152        void SetPosThetaBias(G4ThreeVector);
     153        void SetPosPhiBias(G4ThreeVector);
     154        G4double GenRandX();
     155        G4double GenRandY();
     156        G4double GenRandZ();
     157        G4double GenRandTheta();
     158        G4double GenRandPhi();
     159        G4double GenRandEnergy();
     160        G4double GenRandPosTheta();
     161        G4double GenRandPosPhi();
     162
     163        inline void SetIntensityWeight(G4double weight) {
     164                bweights[8] = weight;
     165        }
     166        ;
     167
     168        inline G4double GetBiasWeight() {
     169                return bweights[0] * bweights[1] * bweights[2] * bweights[3]
     170                                * bweights[4] * bweights[5] * bweights[6] * bweights[7]
     171                                * bweights[8];
     172        }
     173        ;
     174
     175        // method to re-set the histograms
     176        void ReSetHist(G4String);
     177
     178        // Set the verbosity level.
     179        void SetVerbosity(G4int a) {
     180                verbosityLevel = a;
     181        }
     182        ;
    174183
    175184private:
    176185
    177   //  static G4SPSRandomGenerator  *instance;
    178 
    179   G4bool XBias, IPDFXBias;
    180   G4PhysicsOrderedFreeVector XBiasH;
    181   G4PhysicsOrderedFreeVector IPDFXBiasH;
    182   G4bool YBias, IPDFYBias;
    183   G4PhysicsOrderedFreeVector YBiasH;
    184   G4PhysicsOrderedFreeVector IPDFYBiasH;
    185   G4bool ZBias, IPDFZBias;
    186   G4PhysicsOrderedFreeVector ZBiasH;
    187   G4PhysicsOrderedFreeVector IPDFZBiasH;
    188   G4bool ThetaBias, IPDFThetaBias;
    189   G4PhysicsOrderedFreeVector ThetaBiasH;
    190   G4PhysicsOrderedFreeVector IPDFThetaBiasH;
    191   G4bool PhiBias, IPDFPhiBias;
    192   G4PhysicsOrderedFreeVector PhiBiasH;
    193   G4PhysicsOrderedFreeVector IPDFPhiBiasH;
    194   G4bool EnergyBias, IPDFEnergyBias;
    195   G4PhysicsOrderedFreeVector EnergyBiasH;
    196   G4PhysicsOrderedFreeVector IPDFEnergyBiasH;
    197   G4bool PosThetaBias, IPDFPosThetaBias;
    198   G4PhysicsOrderedFreeVector PosThetaBiasH;
    199   G4PhysicsOrderedFreeVector IPDFPosThetaBiasH;
    200   G4bool PosPhiBias, IPDFPosPhiBias;
    201   G4PhysicsOrderedFreeVector PosPhiBiasH;
    202   G4PhysicsOrderedFreeVector IPDFPosPhiBiasH;
    203 
    204   G4double bweights[9]; //record x,y,z,theta,phi,energy,posThet,posPhi,intensity weights
    205 
    206   // Verbosity
    207   G4int verbosityLevel;
    208 
    209   G4PhysicsOrderedFreeVector ZeroPhysVector ; // for re-set only
    210  
     186        //  static G4SPSRandomGenerator  *instance;
     187
     188        G4bool XBias, IPDFXBias;
     189        G4PhysicsOrderedFreeVector XBiasH;
     190        G4PhysicsOrderedFreeVector IPDFXBiasH;
     191        G4bool YBias, IPDFYBias;
     192        G4PhysicsOrderedFreeVector YBiasH;
     193        G4PhysicsOrderedFreeVector IPDFYBiasH;
     194        G4bool ZBias, IPDFZBias;
     195        G4PhysicsOrderedFreeVector ZBiasH;
     196        G4PhysicsOrderedFreeVector IPDFZBiasH;
     197        G4bool ThetaBias, IPDFThetaBias;
     198        G4PhysicsOrderedFreeVector ThetaBiasH;
     199        G4PhysicsOrderedFreeVector IPDFThetaBiasH;
     200        G4bool PhiBias, IPDFPhiBias;
     201        G4PhysicsOrderedFreeVector PhiBiasH;
     202        G4PhysicsOrderedFreeVector IPDFPhiBiasH;
     203        G4bool EnergyBias, IPDFEnergyBias;
     204        G4PhysicsOrderedFreeVector EnergyBiasH;
     205        G4PhysicsOrderedFreeVector IPDFEnergyBiasH;
     206        G4bool PosThetaBias, IPDFPosThetaBias;
     207        G4PhysicsOrderedFreeVector PosThetaBiasH;
     208        G4PhysicsOrderedFreeVector IPDFPosThetaBiasH;
     209        G4bool PosPhiBias, IPDFPosPhiBias;
     210        G4PhysicsOrderedFreeVector PosPhiBiasH;
     211        G4PhysicsOrderedFreeVector IPDFPosPhiBiasH;
     212
     213        G4double alpha;   // for biasing energy
     214
     215        G4double bweights[9]; //record x,y,z,theta,phi,energy,posThet,posPhi,intensity weights
     216
     217        // Verbosity
     218        G4int verbosityLevel;
     219
     220        G4PhysicsOrderedFreeVector ZeroPhysVector; // for re-set only
     221
    211222};
    212223
    213 
    214224#endif
    215225
    216 
    217 
    218 
  • trunk/source/event/include/G4SingleParticleSource.hh

    r816 r1347  
    121121#include "G4SPSRandomGenerator.hh"
    122122
    123 class G4SingleParticleSource : public G4VPrimaryGenerator
    124 {
     123class G4SingleParticleSource: public G4VPrimaryGenerator {
    125124public:
    126   G4SingleParticleSource ();
    127   ~G4SingleParticleSource ();
    128   void GeneratePrimaryVertex(G4Event *evt);
    129   //
    130   G4SPSPosDistribution* GetPosDist() {return posGenerator;};
    131   G4SPSAngDistribution* GetAngDist() {return angGenerator;};
    132   G4SPSEneDistribution* GetEneDist() {return eneGenerator;};
    133   G4SPSRandomGenerator* GetBiasRndm() {return biasRndm;};
    134 
    135   // Set the verbosity level.
    136   void SetVerbosity(G4int);
    137 
    138   // Set the particle species
    139   void SetParticleDefinition (G4ParticleDefinition * aParticleDefinition);
    140   inline G4ParticleDefinition * GetParticleDefinition () { return particle_definition;} ;
    141 
    142   inline void SetParticleCharge(G4double aCharge) { particle_charge = aCharge; } ;
    143 
    144   // Set polarization
    145   inline void SetParticlePolarization (G4ThreeVector aVal) {particle_polarization = aVal;};
    146   inline G4ThreeVector GetParticlePolarization ()  {return particle_polarization;};
    147 
    148   // Set Time.
    149   inline void SetParticleTime(G4double aTime)  { particle_time = aTime; };
    150   inline G4double GetParticleTime()  { return particle_time; };
    151 
    152   inline void SetNumberOfParticles(G4int i)  { NumberOfParticlesToBeGenerated = i; };
    153   //
    154   inline G4int GetNumberOfParticles() { return NumberOfParticlesToBeGenerated; };
    155   inline G4ThreeVector GetParticlePosition()  { return particle_position;};
    156   inline G4ThreeVector GetParticleMomentumDirection()  { return particle_momentum_direction;};
    157   inline G4double GetParticleEnergy()  {return particle_energy;};
     125        G4SingleParticleSource();
     126        ~G4SingleParticleSource();
     127        void GeneratePrimaryVertex(G4Event *evt);
     128        //
     129        G4SPSPosDistribution* GetPosDist() {
     130                return posGenerator;
     131        }
     132        ;
     133        G4SPSAngDistribution* GetAngDist() {
     134                return angGenerator;
     135        }
     136        ;
     137        G4SPSEneDistribution* GetEneDist() {
     138                return eneGenerator;
     139        }
     140        ;
     141        G4SPSRandomGenerator* GetBiasRndm() {
     142                return biasRndm;
     143        }
     144        ;
     145
     146        // Set the verbosity level.
     147        void SetVerbosity(G4int);
     148
     149        // Set the particle species
     150        void SetParticleDefinition(G4ParticleDefinition * aParticleDefinition);
     151        inline G4ParticleDefinition * GetParticleDefinition() {
     152                return particle_definition;
     153        }
     154        ;
     155
     156        inline void SetParticleCharge(G4double aCharge) {
     157                particle_charge = aCharge;
     158        }
     159        ;
     160
     161        // Set polarization
     162        inline void SetParticlePolarization(G4ThreeVector aVal) {
     163                particle_polarization = aVal;
     164        }
     165        ;
     166        inline G4ThreeVector GetParticlePolarization() {
     167                return particle_polarization;
     168        }
     169        ;
     170
     171        // Set Time.
     172        inline void SetParticleTime(G4double aTime) {
     173                particle_time = aTime;
     174        }
     175        ;
     176        inline G4double GetParticleTime() {
     177                return particle_time;
     178        }
     179        ;
     180
     181        inline void SetNumberOfParticles(G4int i) {
     182                NumberOfParticlesToBeGenerated = i;
     183        }
     184        ;
     185        //
     186        inline G4int GetNumberOfParticles() {
     187                return NumberOfParticlesToBeGenerated;
     188        }
     189        ;
     190        inline G4ThreeVector GetParticlePosition() {
     191                return particle_position;
     192        }
     193        ;
     194        inline G4ThreeVector GetParticleMomentumDirection() {
     195                return particle_momentum_direction;
     196        }
     197        ;
     198        inline G4double GetParticleEnergy() {
     199                return particle_energy;
     200        }
     201        ;
    158202
    159203private:
    160204
    161   G4SPSPosDistribution* posGenerator;
    162   G4SPSAngDistribution* angGenerator;
    163   G4SPSEneDistribution* eneGenerator;
    164   G4SPSRandomGenerator* biasRndm;
    165   //
    166   // Other particle properties
    167   G4int                  NumberOfParticlesToBeGenerated;
    168   G4ParticleDefinition * particle_definition;
    169   G4ParticleMomentum    particle_momentum_direction;
    170   G4double              particle_energy;
    171   G4double              particle_charge;
    172   G4ThreeVector          particle_position;
    173   G4double              particle_time;
    174   G4ThreeVector          particle_polarization;
    175   G4double              particle_weight;
    176 
    177   // Verbosity
    178   G4int verbosityLevel;
     205        G4SPSPosDistribution* posGenerator;
     206        G4SPSAngDistribution* angGenerator;
     207        G4SPSEneDistribution* eneGenerator;
     208        G4SPSRandomGenerator* biasRndm;
     209        //
     210        // Other particle properties
     211        G4int NumberOfParticlesToBeGenerated;
     212        G4ParticleDefinition * particle_definition;
     213        G4ParticleMomentum particle_momentum_direction;
     214        G4double particle_energy;
     215        G4double particle_charge;
     216        G4ThreeVector particle_position;
     217        G4double particle_time;
     218        G4ThreeVector particle_polarization;
     219        G4double particle_weight;
     220
     221        // Verbosity
     222        G4int verbosityLevel;
    179223
    180224};
    181225
    182 
    183226#endif
    184227
    185 
    186 
    187 
Note: See TracChangeset for help on using the changeset viewer.