Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: Initial population fraction distribution for bExFullRxn #27

Open
hannahberg opened this issue Apr 19, 2021 · 8 comments
Open
Labels
question Further information is requested

Comments

@hannahberg
Copy link

When generating the input population files through TALYS, I am still struggling with some of the simulations coming up empty. For the total population, should that be equal to 100, and for the population of the spin/parity states be the percentage (so sum up to 1). Or should the population be 100, then the individual spin/parities sum up to 100?

Attached is the settings.h, the two different versions of Ni71Pop.dat and the mylevels file for recreation.

Thanks :)

@fzeiser fzeiser added the question Further information is requested label Apr 21, 2021
@fzeiser
Copy link
Owner

fzeiser commented Apr 21, 2021

Could you please send the attachment and specify the version (commit) of RAINIER that you use?

Some background on the ExFullRxn population method:
A 2d histogram is built from the populations you specify as a table (Ex vs J) or (Ex vs J-pi). The initial population is then drawn randomly from the distribution given by this histogram. The entries of the initial table are read directly into the histogram and the normalization is taken care of internally. Therefore, the Popul (total population) column is irrelevant, but only the relative numbers in the table matter.

Did you check what levels are populated during the simulations? There is also some histogram to check this visually, it might be h2ExI0PopI_0 or something like this.

@hannahberg
Copy link
Author

hannahberg commented Apr 21, 2021

Version of RAINIER: 2e4dfbb

rainier.zip
Sorry, did not realize the file types were not supported. Attached is a .zip with all the aforementioned files.

Yes, I checked the h2ExI0PopI_0 for the different files, this is where I have seen that it sometimes shows up empty. So when it comes to the relative numbers in the table, what should they sum up to?

@fzeiser
Copy link
Owner

fzeiser commented Apr 21, 2021

Yes, I checked the h2ExI0PopI_0 for the different files, this is where I have seen that it sometimes shows up empty. So when it comes to the relative numbers in the table, what should they sum up to?

That's what I mean with the relative numbers - it doesn't matter what they sum up to.
An easy example: If you fill a histogram with weights = [1, 10] or weights = [10, 100] and randomly draw either label_bin0 or label_bin1 according to the weights, both will have the same results.

@fzeiser
Copy link
Owner

fzeiser commented Apr 21, 2021

@hannahberg: The zipfile doesn't contain a levels file yet.

@hannahberg
Copy link
Author

@hannahberg: The zipfile doesn't contain a levels file yet.

rainier2.zip

@fzeiser
Copy link
Owner

fzeiser commented Apr 23, 2021

I realized that have problem running RAINIER since I updated my OS and my current version of root is compiled with a compiler version that I don't seem to have any longer :/. I'm not sure if/ when I will fix this, but I would recommend you to put in some cout statements in the code to check what Ex, J, pi states are to be populated. So probably you want to look into this loop here:

RAINIER/RAINIER.C

Lines 1172 to 1229 in 94ca2ff

///// decay to constructed scheme? /////
for(int spb=nSpb-2; spb<=nSpb+2; spb++) { // dipole and quadrapole
for(int par=0; par<2; par++) {
int nTransType = GetTransType(nSpb,nPar,spb,par);
if(nTransType != 0) {
for(int ex=0; ex<nConEx; ex++) {
double dConWid = adConWid[EJP(ex,spb,par)];
dWidCumulative += dConWid;
if(dWidCumulative >= dRanWid) {// once adds up to dRanWid, it decays
if(!bFoundLvl) { // possibly already decayed to discrete
bFoundLvl = true;
nToConEx = ex;
nToDisEx = g_nDisLvlMax;
nToSpb = spb;
nToPar = par;
nTransMade = nTransType;
// need to backtrack width sum and find out which individual
// level in EJP bin it decayed to since many levels in a bin
// each with random width according to PT distribution
dWidCumulative -= dConWid;
bool bFoundLvlInBin = false;
double dLvlSpac = 1.0 / GetDensity(dExI,dSp,nPar);
int nLvlTrans = g_anConLvl[EJP(ex,spb,par)];
if(nLvlTrans) {
double dExF = g_adConExCen[ex];
double dEg = dExI - dExF;
TRandom2 ranStr = arConState[EJP(ex,spb,par)];
for(int outlvl=0; outlvl<nLvlTrans; outlvl++) {
double dMixDelta2Tmp;
double dStrTmp = // need to get delta2
GetStr(dExI, dEg, nTransType, dMixDelta2Tmp, ranStr);
double dStr = dStrTmp * (1.0 +
GetICC(dEg,nTransType,dMixDelta2Tmp));
dWidCumulative += dStr * dLvlSpac;
if(dWidCumulative >= dRanWid) {
if(!bFoundLvlInBin) { // possibly decayed prev inbin lvl
bFoundLvlInBin = true;
nToLvlInBin = outlvl;
dToMixDelta2 = dMixDelta2Tmp;
outlvl = nLvlTrans; // break loop for speed
} // found lvl in bin
} // Cumulative >= Rand
} // outlvl
ex = nConEx; // break out of loops, for speed
spb = g_nConSpbMax;
par = 2;
} // final bin has lvls
} // found lvl
} // Cumulative >= Rand
} // ex
} // possible
} // par
} // sp bin
} ///// in constructed scheme /////

Just for curiosity, I was also trying to see whether there are levels in the current level scheme you generated at the Ex energy and J, pi, states you want to populate. It's rather thin there, I think. But still, there should be enough levels to populated at least something close to 5.05 MeV.

root [2] PrintConLvl()
****** Constructed ******
More levels exist at higher spins
Parity   - - - - - - - - - -  + + + + + + + + + + 
Spin Bin 9 8 7 6 5 4 3 2 1 0  0 1 2 3 4 5 6 7 8 9 
E(MeV) 
[...]
5.015    0|0|0|0|0|0|1|0|1|0| 1|0|0|0|0|1|0|0|0|0|
5.032    0|0|0|0|1|0|2|0|0|0| 1|1|0|2|2|0|0|0|0|0|
5.049    0|0|1|1|1|0|1|2|1|0| 0|0|0|2|1|1|0|0|0|1|
5.066    0|0|0|0|0|1|0|0|2|0| 0|1|1|0|1|0|0|0|1|1|

@hannahberg
Copy link
Author

I will try with the print out statement, thank you. Sometimes it will populate, sometimes not depending on how I set the relative weights. This is actually true for all initial population levels I have tried, I just picked 5050 keV as an example.

@hannahberg
Copy link
Author

hannahberg commented May 3, 2021

Follow up: It seems if I do not delete previous Run0001.root file and rerun (even with deleting all temporary RAINIER_copy files, it will still end up non populating. From the nested for loop, I added a print statement after line 1214. If it actually populates anything in the simulation, it should go here, which it doesn't when there is a root file there.

Additionally, I updated to the latest release. Now, when I manage to produce non-empty files, I end up getting errors about the mylevels file, which I haven't seen. Now I get the error:
err: JP: from 0-, Discrete Lvl: 2 To -7+, Discrete Lvl: 6 Likely branching ratios from file don't add to 1.000000 Check level 2 in zFile manually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants