#include <MyHeSource.hh>
Public Methods | |
| MyHeSource (int newIsotope=k.Isotope, int newRmaxgen=k.Rmaxgen) | |
| MyHeSource constructor. More... | |
| ~MyHeSource () | |
| MyHeSource destructor. | |
| MyHeSource (const MyHeSource &HeSource) | |
| MyHeSource copy constructor. | |
| MyHeSource & | operator= (const MyHeSource &rhs) |
| MyHeSource overloaded = operator. | |
| double | GetHeNeutronEnergy () const |
| Returns the energy of the neutrons produced by each He decay. | |
| double | GetHeBetaEnergy () const |
| Returns the energy of the betas produced by each He decay. | |
| double | GetHeGammaEnergy () const |
| Returns the energy of the photons produced by each He decay. | |
| double | GetHeWeight () const |
| Returns the branching ratio weight for each He decay. | |
| double | GetHeDecayTime () const |
| Returns the decay time for each He decay. | |
Static Public Methods | |
| float | BetaHighQ (const float &x) |
| float | BetaMiddleQ (const float &x) |
| float | BetaLowQ (const float &x) |
| double | Fermi (const int &Z, const int &A, const float &x) |
The supported isotope is 8. The neutrons are generated by the He8NeutronSpectrum function, which the probability density of the produced neutrons as a function of neutron energy.
Definition at line 18 of file MyHeSource.hh.
|
||||||||||||
|
MyHeSource constructor. Called with the desired He isotope: 8 and the maximum allowed radius for generating particles in the simulation, Rmaxgen (default = 200 cm). Definition at line 17 of file MyHeSource.cpp.
00018 {
00019
00020 Isotope = newIsotope;
00021 Rmaxgen = newRmaxgen;
00022
00023 //cout << "MyHeSource::MyHeSource(" << Isotope << "," << Rmaxgen
00024 // << ")" << endl;
00025
00026 // 8He
00027 if(Isotope == 8){
00028
00029 // setup the decay parameters (from Jon Link)
00030 // Nneutron is always 1 and Ngamma always 0
00031 Nneutron = 1;
00032 Ngamma = 0;
00033
00034 // branching fraction (the 1.0000 bin contains all decays
00035 // which do nothing: neutron E = 0, beta Q = 0)
00036 float static br[4] = {0.080,0.160,0.169,1.0000};
00037
00038 // Q-value for beta decay
00039 float static betaQ[4] = {7.442,5.252,1.852,0.000};
00040
00041 // Q-value for the total decay chain
00042 float static totQ = 8.619;
00043
00044 // neutron energy
00045 float static neuE[4] = {0.697,2.887,6.727,0.000};
00046
00047 // prepare the beta decay functions
00048 bool static first=1;
00049 float static fspace[3][200];
00050
00051 if(first){
00052 float xlo = 0.;
00053 funlxp_(BetaHighQ,fspace[0],xlo,betaQ[0]);
00054 funlxp_(BetaMiddleQ,fspace[1],xlo,betaQ[1]);
00055 funlxp_(BetaLowQ,fspace[2],xlo,betaQ[2]);
00056
00057 first = 0;
00058 }
00059 //
00060 // let the 8He decay
00061 //
00062 int ntrial = 0;
00063 bool passed = false;
00064 while(!passed){
00065 int len=1;
00066 float rv[len];
00067 ranlux_(rv,len);
00068 //
00069 rv[0] = 0.167;
00070 for(int i=0;i<4; i++){
00071 if(rv[0] < br[i] && !passed){
00072
00073 // pick an energy for each neutron
00074 neutronE = neuE[i];
00075
00076 if(neutronE){
00077
00078 // get the energy of the beta
00079 len = 1;
00080 funlux_(fspace[i],betaE,len);
00081 passed = true;
00082 }
00083 }
00084 }
00085 ntrial++;
00086 }
00087 Weight = 1./float(ntrial);
00088
00089 //cout << " 8He neutron energy = " << neutronE << " MeV" << endl;
00090 //cout << " 8He beta energy = " << betaE << " MeV" << endl;
00091 //cout << " 8He weight = " << Weight << endl;
00092
00093 // pick a decay time in ns
00094 double HalfLife = 1.2e8;
00095
00096 int len=1;
00097 float rv[len];
00098 ranlux_(rv,len);
00099 DecayTime = HalfLife*log(1/rv[0]);
00100
00101 } // done with 8He
00102 }
|
1.2.14 written by Dimitri van Heesch,
© 1997-2002