Geant4  10.03.p01
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
G4LLNLFission.cc
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 //
27 // This software was developed by Lawrence Livermore National Laboratory.
28 //
29 // Redistribution and use in source and binary forms, with or without
30 // modification, are permitted provided that the following conditions are met:
31 //
32 // 1. Redistributions of source code must retain the above copyright notice,
33 // this list of conditions and the following disclaimer.
34 // 2. Redistributions in binary form must reproduce the above copyright notice,
35 // this list of conditions and the following disclaimer in the documentation
36 // and/or other materials provided with the distribution.
37 // 3. The name of the author may not be used to endorse or promote products
38 // derived from this software without specific prior written permission.
39 //
40 // THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
41 // WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
42 // MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
43 // EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
44 // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
45 // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
46 // OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
47 // WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
48 // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
49 // ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
50 //
51 // Copyright (c) 2006 The Regents of the University of California.
52 // All rights reserved.
53 // UCRL-CODE-224807
54 //
55 //
56 // $Id: G4LLNLFission.cc 68799 2013-04-05 13:29:46Z gcosmo $
57 //
58 // This class is a copy of Fission.cc, made for use with Geant4.
59 //
60 
61 #include "G4fissionEvent.hh"
62 
64 
65  extern G4float (*rngfptr) (void);
66 
67  extern G4double (*rngdptr) (void);
68 
69  extern G4double rngf2d(void);
70 
71  void genspfissevt_(G4int *isotope, G4double *time) {
72  if (fe != 0) delete fe;
73  fe = new G4fissionEvent(*isotope, *time, -1., 0.);
74  }
75 
76  void genfissevt_(G4int *isotope, G4double *time, G4double *nubar, G4double *eng) {
77  if (fe != 0) delete fe;
78  fe = new G4fissionEvent(*isotope, *time, *nubar, *eng);
79  }
80 
82  return (*fe).getNeutronNu();
83  }
84 
86  return (*fe).getPhotonNu();
87  }
88 
90  return (*fe).getNeutronEnergy(*index);
91  }
92 
94  return (*fe).getNeutronVelocity(*index);
95  }
96 
98  return (*fe).getNeutronDircosu(*index);
99  }
100 
102  return (*fe).getNeutronDircosv(*index);
103  }
104 
106  return (*fe).getNeutronDircosw(*index);
107  }
108 
110  return (*fe).getPhotonEnergy(*index);
111  }
112 
114  return (*fe).getPhotonVelocity(*index);
115  }
116 
118  return (*fe).getPhotonDircosu(*index);
119  }
120 
122  return (*fe).getPhotonDircosv(*index);
123  }
124 
126  return (*fe).getPhotonDircosw(*index);
127  }
128 
130  return (*fe).getNeutronAge(*index);
131  }
132 
134  return (*fe).getPhotonAge(*index);
135  }
136 
137  void setdelay_(G4int *delay) {
138  (*fe).setDelayOption(*delay);
139  }
140 
141  void setcorrel_(G4int *correlation) {
142  (*fe).setCorrelationOption(*correlation);
143  }
144 
145  void setnudist_(G4int *nudist) {
146 /*
147  where the argument *nudist affects induced fissions only, it
148  is set to
149  0 for sampling Zucker and Holden probability distributions
150  for U-235,238 and Pu-239. Terrell for other isotopes.
151  1 same as above, but using Gwin, Spencer and Ingle
152  tabulated distributions for thermal energies for U-235.
153  Terrell for other isotopes.
154  2 for sampling fission-induced neutron multiplicity in
155  (a) U-232, U-234, U-236 and U-238 using Zucker and
156  Holden's tabulated data for U-238
157  (b) U-233 and U-235 using Zucker and Holden's tabulated
158  data for U-235
159  (c) Pu-239 and Pu-241 using Zucker and Holden's tabulated
160  data for Pu-239
161  The P(nu) distributions for *nudist=2 are given as a
162  function of the average number of neutrons from fission,
163  based on interpolation of the data from Zucker and Holden.
164  Terrell for other isotopes.
165  3 for sampling fission-induced neutron multiplicity in
166  (a) U-232, U-234, U-236 and U-238 using Zucker and
167  Holden's tabulated data for U-238
168  (b) U-233 and U-235 using Zucker and Holden's tabulated
169  data for U-235
170  (c) Pu-239 and Pu-241 using Zucker and Holden's tabulated
171  data for Pu-239
172  The Z&H tables have P(nu) distributions for 11 energies
173  (0 MeV through 10 MeV), along with their nubars. For
174  *nudist=3, we select the P(nu) distribution that has
175  a nubar closest either from above, or from below, to the
176  to the nubar entered for the induced fission, based on a
177  random number and fractional distances to the end of the
178  nubar interval thus formed.
179  Terrell for other isotopes.
180 */
181 
182  (*fe).setNudistOption(*nudist);
183  }
184 
185  void setcf252_(G4int *ndist, G4int *neng) {
186 /*
187  where the argument
188  *ndist is set to
189  0 to sample the spontaneous fission neutron multiplicity
190  using tabulated data from Spencer
191  1 to sample the spontaneous fission neutron multiplicity
192  using tabulated data from Boldeman
193  *neng is set to
194  0 to sample the Mannhart corrected Maxwellian spectrum
195  1 to sample the Madland-Nix theoretical spectrum
196  2 to sample the Froehner Watt spectrum
197 */
198  (*fe).setCf252Option(*ndist, *neng);
199  }
200 
201  void setrngf_(G4float (*funcptr) (void)) {
202  G4fissionEvent::setRNGf(funcptr);
203  }
204 
205  void setrngd_(G4double (*funcptr) (void)) {
206  G4fissionEvent::setRNGd(funcptr);
207  }
208 // }
G4double getnvel_(G4int *index)
G4double getndircosu_(G4int *index)
void setcf252_(G4int *ndist, G4int *neng)
G4double getneng_(G4int *index)
G4double rngf2d(void)
G4double(* rngdptr)(void)
void setrngf_(G4float(*funcptr)(void))
float G4float
Definition: G4Types.hh:77
void setnudist_(G4int *nudist)
G4double getpvel_(G4int *index)
int G4int
Definition: G4Types.hh:78
void setrngd_(G4double(*funcptr)(void))
void setdelay_(G4int *delay)
void genspfissevt_(G4int *isotope, G4double *time)
void setcorrel_(G4int *correlation)
G4int getnnu_()
G4double getpage_(G4int *index)
G4double getnage_(G4int *index)
G4double getpdircosw_(G4int *index)
G4double getpeng_(G4int *index)
G4double getpdircosu_(G4int *index)
void genfissevt_(G4int *isotope, G4double *time, G4double *nubar, G4double *eng)
static void setRNGd(G4double(*funcptr)(void))
G4float(* rngfptr)(void)
G4double getpdircosv_(G4int *index)
static void setRNGf(float(*funcptr)(void))
G4double getndircosv_(G4int *index)
G4int getpnu_()
double G4double
Definition: G4Types.hh:76
G4double getndircosw_(G4int *index)
typedef void(XMLCALL *XML_ElementDeclHandler)(void *userData
G4fissionEvent * fe