Page 1 of 1

pbuf, nbuf, and population control

Posted: Fri Oct 13, 2017 12:00 am
by terryphi
Hello,

What is it that the numerical argument to 'set nbuf' and 'set pbuf' is indicating?

Is this gigs of memory allocated?

Also, are there any mechanisms in place for population control of the neutrons?

Re: pbuf, nbuf, and population control

Posted: Fri Oct 13, 2017 8:58 am
by Ville Valtavirta
It is best to think of the nbuf, pbuf and gbuf as being the relative size of the buffers compared to the number of neutrons (or photons) to be simulated per batch: I.e. setting nbuf to 1 and population to "set pop 10000 100 100" would allocate memory for just 10000 neutrons. In reality, with OpenMP parallelization slightly larger buffers are allocated.

As for population control of neutrons, if you are asking about transient simulations, the neutron population is automatically controlled to the requested batch size at time-interval boundaries so if you keep running out of nbuf (and/or pbuf) you can also try to run the simulation using shorter time-intervals.

-Ville

Re: pbuf, nbuf, and population control

Posted: Fri Oct 13, 2017 8:12 pm
by terryphi
Ville Valtavirta wrote:It is best to think of the nbuf, pbuf and gbuf as being the relative size of the buffers compared to the number of neutrons (or photons) to be simulated per batch: I.e. setting nbuf to 1 and population to "set pop 10000 100 100" would allocate memory for just 10000 neutrons. In reality, with OpenMP parallelization slightly larger buffers are allocated.

As for population control of neutrons, if you are asking about transient simulations, the neutron population is automatically controlled to the requested batch size at time-interval boundaries so if you keep running out of nbuf (and/or pbuf) you can also try to run the simulation using shorter time-intervals.

-Ville
Thanks!