Geant4  10.03.p01
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
G4fissionEvent Class Reference

#include <G4fissionEvent.hh>

Public Member Functions

 G4fissionEvent (G4int isotope, G4double time, G4double nubar, G4double eng)
 
 ~G4fissionEvent ()
 
G4int getNeutronNu ()
 
G4int getPhotonNu ()
 
G4double getNeutronEnergy (G4int index)
 
G4double getNeutronVelocity (G4int index)
 
G4double getNeutronDircosu (G4int index)
 
G4double getNeutronDircosv (G4int index)
 
G4double getNeutronDircosw (G4int index)
 
G4double getPhotonEnergy (G4int index)
 
G4double getPhotonVelocity (G4int index)
 
G4double getPhotonDircosu (G4int index)
 
G4double getPhotonDircosv (G4int index)
 
G4double getPhotonDircosw (G4int index)
 
G4double getNeutronAge (G4int index)
 
G4double getPhotonAge (G4int index)
 

Static Public Member Functions

static void setDelayOption (G4int delay)
 
static void setCorrelationOption (G4int correlation)
 
static void setNudistOption (G4int nudist)
 
static void setCf252Option (G4int ndist, G4int neng)
 
static void setRNGf (float(*funcptr)(void))
 
static void setRNGd (G4double(*funcptr)(void))
 

Detailed Description

Definition at line 61 of file G4fissionEvent.hh.

Constructor & Destructor Documentation

G4fissionEvent::G4fissionEvent ( G4int  isotope,
G4double  time,
G4double  nubar,
G4double  eng 
)

Definition at line 66 of file G4fissionEvent.cc.

68  :neutronNu(0), neutronEnergies(0), neutronVelocities(0), neutronDircosu(0),
69  neutronDircosv(), neutronDircosw(), neutronAges(0),
70  photonNu(0), photonEnergies(0), photonVelocities(0), photonDircosu(0),
71  photonDircosv(0), photonDircosw(0), photonAges(0)
72 {
73  /*
74  * Constructs a fission event with neutronNu neutrons and photonNu
75  * photons.
76  */
77  G4int i;
78 
79  if (nubar == -1.) {
80  /* spontaneous fission */
81  neutronNu = G4SmpSpNuDistData(isotope, Cf252ndistoption);
82  photonNu = G4SmpSpNugDistData(isotope);
83  } else {
84  /* induced fission */
85  if (nudistoption == 0 || nudistoption == 1) {
86  switch (isotope) {
87  case 92235:
88  neutronNu = G4SmpNuDistDataU235(eng,nudistoption);
89  break;
90  case 92238:
91  neutronNu = G4SmpNuDistDataU238(eng);
92  break;
93  case 94239:
94  neutronNu = G4SmpNuDistDataPu239(eng);
95  break;
96  default:
97  neutronNu = (G4int) G4SmpTerrell(nubar);
98  break;
99  }
100  } else if (nudistoption == 2) {
101  switch (isotope) {
102  case 92232:
103  case 92234:
104  case 92236:
105  case 92238:
106  neutronNu = G4SmpNuDistDataU232_234_236_238(nubar);
107  break;
108  case 92233:
109  case 92235:
110  neutronNu = (G4int) G4SmpNuDistDataU233_235(nubar);
111  break;
112  case 94239:
113  case 94241:
114  neutronNu = G4SmpNuDistDataPu239_241(nubar);
115  break;
116  default:
117  neutronNu = (G4int) G4SmpTerrell(nubar);
118  break;
119  }
120  } else if (nudistoption == 3) {
121  switch (isotope) {
122  case 92232:
123  case 92234:
124  case 92236:
125  case 92238:
126  neutronNu = G4SmpNuDistDataU232_234_236_238_MC(nubar);
127  break;
128  case 92233:
129  case 92235:
130  neutronNu = (G4int) G4SmpNuDistDataU233_235_MC(nubar);
131  break;
132  case 94239:
133  case 94241:
134  neutronNu = G4SmpNuDistDataPu239_241_MC(nubar);
135  break;
136  default:
137  neutronNu = (G4int) G4SmpTerrell(nubar);
138  break;
139  }
140  }
141  photonNu = G4SmpNugDist(isotope, nubar);
142  }
143  if (neutronNu > 0) {
144  neutronEnergies = new G4double[ neutronNu ];
145  neutronVelocities = new G4double[ neutronNu ];
146  neutronDircosu = new G4double[ neutronNu ];
147  neutronDircosv = new G4double[ neutronNu ];
148  neutronDircosw = new G4double[ neutronNu ];
149  neutronAges = new G4double[neutronNu];
150  for (i=0; i<neutronNu; i++) {
151  if (isotope == 98252) neutronEnergies[i] = G4SmpNEngCf252(Cf252nengoption);
152  else neutronEnergies[i] = G4SmpWatt(eng, isotope);
153  neutronVelocities[i] = G4SmpNVel(
154  neutronEnergies[i],
155  &(neutronDircosu[i]),
156  &(neutronDircosv[i]),
157  &(neutronDircosw[i])
158  );
159  neutronAges[i] = time;
160  }
161  }
162  if (photonNu > 0) {
163  photonEnergies = new G4double[photonNu];
164  photonVelocities = new G4double[photonNu];
165  photonDircosu = new G4double[photonNu];
166  photonDircosv = new G4double[photonNu];
167  photonDircosw = new G4double[photonNu];
168  photonAges = new G4double[photonNu];
169  for (i=0; i<photonNu; i++) {
170  photonEnergies[i] = G4SmpGEng();
171  photonVelocities[i] = G4SmpPVel(
172  photonEnergies[i],
173  &(photonDircosu[i]),
174  &(photonDircosv[i]),
175  &(photonDircosw[i])
176  );
177  photonAges[i] = time;
178  }
179  }
180 }
int G4int
Definition: G4Types.hh:78
double G4double
Definition: G4Types.hh:76
G4fissionEvent::~G4fissionEvent ( )

Definition at line 182 of file G4fissionEvent.cc.

182  {
183  if (neutronNu > 0) {
184  delete [] neutronEnergies;
185  delete [] neutronVelocities;
186  delete [] neutronDircosu;
187  delete [] neutronDircosv;
188  delete [] neutronDircosw;
189  delete [] neutronAges;
190  }
191 
192  if (photonNu > 0) {
193  delete [] photonEnergies;
194  delete [] photonVelocities;
195  delete [] photonDircosu;
196  delete [] photonDircosv;
197  delete [] photonDircosw;
198  delete [] photonAges;
199  }
200 }

Member Function Documentation

G4double G4fissionEvent::getNeutronAge ( G4int  index)
inline

Definition at line 138 of file G4fissionEvent.hh.

138  {
139  if (index >= 0 && index < neutronNu) return neutronAges[index];
140  else return -1;
141  }
G4double G4fissionEvent::getNeutronDircosu ( G4int  index)
inline

Definition at line 106 of file G4fissionEvent.hh.

106  {
107  if (index >= 0 && index < neutronNu) return neutronDircosu[index];
108  else return -1;
109  }

Here is the caller graph for this function:

G4double G4fissionEvent::getNeutronDircosv ( G4int  index)
inline

Definition at line 110 of file G4fissionEvent.hh.

110  {
111  if (index >= 0 && index < neutronNu) return neutronDircosv[index];
112  else return -1;
113  }

Here is the caller graph for this function:

G4double G4fissionEvent::getNeutronDircosw ( G4int  index)
inline

Definition at line 114 of file G4fissionEvent.hh.

114  {
115  if (index >= 0 && index < neutronNu) return neutronDircosw[index];
116  else return -1;
117  }

Here is the caller graph for this function:

G4double G4fissionEvent::getNeutronEnergy ( G4int  index)
inline

Definition at line 98 of file G4fissionEvent.hh.

98  {
99  if (index >= 0 && index < neutronNu) return neutronEnergies[index];
100  else return -1;
101  }

Here is the caller graph for this function:

G4int G4fissionEvent::getNeutronNu ( )
inline

Definition at line 92 of file G4fissionEvent.hh.

92  {
93  return neutronNu;
94  }
G4double G4fissionEvent::getNeutronVelocity ( G4int  index)
inline

Definition at line 102 of file G4fissionEvent.hh.

102  {
103  if (index >= 0 && index < neutronNu) return neutronVelocities[index];
104  else return -1;
105  }
G4double G4fissionEvent::getPhotonAge ( G4int  index)
inline

Definition at line 142 of file G4fissionEvent.hh.

142  {
143  if (index >= 0 && index < photonNu) return photonAges[index];
144  else return -1;
145  }
G4double G4fissionEvent::getPhotonDircosu ( G4int  index)
inline

Definition at line 126 of file G4fissionEvent.hh.

126  {
127  if (index >= 0 && index < photonNu) return photonDircosu[index];
128  else return -1;
129  }

Here is the caller graph for this function:

G4double G4fissionEvent::getPhotonDircosv ( G4int  index)
inline

Definition at line 130 of file G4fissionEvent.hh.

130  {
131  if (index >= 0 && index < photonNu) return photonDircosv[index];
132  else return -1;
133  }

Here is the caller graph for this function:

G4double G4fissionEvent::getPhotonDircosw ( G4int  index)
inline

Definition at line 134 of file G4fissionEvent.hh.

134  {
135  if (index >= 0 && index < photonNu) return photonDircosw[index];
136  else return -1;
137  }

Here is the caller graph for this function:

G4double G4fissionEvent::getPhotonEnergy ( G4int  index)
inline

Definition at line 118 of file G4fissionEvent.hh.

118  {
119  if (index >= 0 && index < photonNu) return photonEnergies[index];
120  else return -1;
121  }

Here is the caller graph for this function:

G4int G4fissionEvent::getPhotonNu ( )
inline

Definition at line 95 of file G4fissionEvent.hh.

95  {
96  return photonNu;
97  }
G4double G4fissionEvent::getPhotonVelocity ( G4int  index)
inline

Definition at line 122 of file G4fissionEvent.hh.

122  {
123  if (index >= 0 && index < photonNu) return photonVelocities[index];
124  else return -1;
125  }
static void G4fissionEvent::setCf252Option ( G4int  ndist,
G4int  neng 
)
inlinestatic

Definition at line 155 of file G4fissionEvent.hh.

155  {
156  Cf252ndistoption = ndist;
157  Cf252nengoption = neng;
158  };
static void G4fissionEvent::setCorrelationOption ( G4int  correlation)
inlinestatic

Definition at line 149 of file G4fissionEvent.hh.

149  {
150  correlationoption = correlation;
151  };
static void G4fissionEvent::setDelayOption ( G4int  delay)
inlinestatic

Definition at line 146 of file G4fissionEvent.hh.

146  {
147  delayoption = delay;
148  };
static void G4fissionEvent::setNudistOption ( G4int  nudist)
inlinestatic

Definition at line 152 of file G4fissionEvent.hh.

152  {
153  nudistoption = nudist;
154  };
static void G4fissionEvent::setRNGd ( G4double(*)(void funcptr)
inlinestatic

Definition at line 163 of file G4fissionEvent.hh.

163  {
164  rngdptr = funcptr;
165  }

Here is the caller graph for this function:

static void G4fissionEvent::setRNGf ( float(*)(void funcptr)
inlinestatic

Definition at line 159 of file G4fissionEvent.hh.

159  {
160  rngfptr = funcptr;
161  rngdptr = rngf2d;
162  }

Here is the caller graph for this function:


The documentation for this class was generated from the following files: