Track plotter

This category replaces the missing input manual

Track plotter

Postby Jaakko Leppänen » Wed May 09, 2012 2:02 pm

The geometry plotter can be used to visualize neutron tracks starting from the source distribution. The track output is produced when the code is run with command line option:

Code: Select all
sss2 -tracks <n> input

Paramater <n> is the number of sampled source points, from which the tracks start. The tracks are plotted in all geometry plots defined in the input file.

The feature is available from version 2.1.5 on.
- Jaakko
User avatar
Jaakko Leppänen
Site Admin
 
Posts: 1822
Joined: Thu Mar 18, 2010 10:43 pm
Location: Espoo, Finland

Re: Track plotter

Postby Jaakko Leppänen » Fri Jul 10, 2015 11:56 am

The more recent updates also have an option to split the track plot into separate time frames, which can be composed into an animation. This requires a few additional parameters in the input: (syntax corresponds to version 2.1.24)

Code: Select all
set tpa 
<tmin> <tmax>
<l>
<nf>
<max_events>

where <tmin> and <tmax> are the starting and end time of the simulation, <l> is the lenght of the plotted particle tracks in each frame (in cm) and <nf> is the number of frames. The last parameter <max_events> defines the lenght of a buffer used to store collision events, and it must be sufficiently large to cover all events occuring within the given time interval. The track plotter is called with the same command line option.

The simulation produces a number of track plots named "<input>_trck<n>_frame<m>.png". I've used Imagemagick to compose the frames into a gif animation:

Code: Select all
convert *.png anim.gif

Here's an example input of a prompt super-critical system with track point animation:

Code: Select all
pin 1
fuel 2.82306E+01
air

surf 1 sqc 0.0 0.0 3.10537E+01
cell 1 0 fill 1  -1
cell 2 0 outside  1

mat fuel -19.4 rgb 100 200 100
92235.03c 0.375
92238.03c 0.625

mat air -1E-9 rgb 200 250 250
2004.03c 1.0

set nps 1 1
src 1 sp 0.0 0.0 0.0

plot 3 500 500
set nbuf 50000000

set tcut 6E-7
set tpa
0.0 5.5E-7  % minimum and maximum time
1.0         % tail length (cm)
500         % number of frames
200000000

The resulting track plot animation can be downloaded here (file size about 5.5 MB).

Note that simulating super-critical systems requires setting a time cut-off with the "set tcut" option, to terminate the infinite prompt fission chains. Getting the simulation running may also require some adjustments to the "set nbuf" parameter and the last value in the "set tpa" card.

The plotter still has a few bugs, which I'm hoping to correct in future updates.
- Jaakko
User avatar
Jaakko Leppänen
Site Admin
 
Posts: 1822
Joined: Thu Mar 18, 2010 10:43 pm
Location: Espoo, Finland

Re: Track plotter

Postby sprogg77 » Tue Jan 10, 2017 3:19 pm

Jaakko, how much memory is required to run this simulation? As is, during allocation of memory for particle structures, Serpent's memory consumption swells to 30 or 40GB on my machine, many times what is available. If I reduce the tmax and tcut by several orders of magnitude I still get the same behaviour. I have tried reducing max_events and nbuf but to no avail.
sprogg77
 
Posts: 2
Joined: Tue Oct 27, 2015 2:36 pm

Re: Track plotter

Postby Jaakko Leppänen » Wed Jan 11, 2017 12:14 am

Unfortunately I haven't come up with easy answers. Running track plot animations always takes trial error.

Memory consumption depends on the <nbuf> parameter, <max_events>, and possibly the number of histories defined by "set nps" (not sure about the last one). The number of OpenMP threads also affects the allocated memory size, at least to some extent, so try running the simulation without any parallelization.

If you have a high-multiplying system, <nbuf> is probably more important than <max_events>. If you have a system with long neutron histories, <max_events> is more important.

Start with a very short time interval (not only <tmax> but also time cut-off using "set tcut"). Try setting the memory allocation options in such way that the transport simulation is run (no more memory is allocated after that point). Then gradually increase the simulated time interval.

The population grows exponentially in super-critical systems, so the number of events can be very sensitive to time cut-off. It's also a random process, so the time the rapid growth starts cannot really predicted.
- Jaakko
User avatar
Jaakko Leppänen
Site Admin
 
Posts: 1822
Joined: Thu Mar 18, 2010 10:43 pm
Location: Espoo, Finland

Re: Track plotter

Postby jblokker » Wed Aug 02, 2017 1:41 pm

Hi Jaakko, I want to use the track plotter to see if my neutron sources are distributed correctly in the geometry, but when I try to run my code with the command line to do this I get the following error in my output:

''Fatal error in function EventFromBank:

Event bank is empty

Simulation aborted.''

which I don't understand because I have used it before and it worked fine then. Do you have an idea what might be wrong?
jblokker
 
Posts: 7
Joined: Tue Jun 06, 2017 3:40 pm

Re: Track plotter

Postby Jaakko Leppänen » Wed Aug 02, 2017 4:29 pm

Try adjusting the last parameter in the "set tpa" card. That increases the size of the event buffer. The production of new fission chains is a random process, and sometimes you get more particles that can fit into the memory.
- Jaakko
User avatar
Jaakko Leppänen
Site Admin
 
Posts: 1822
Joined: Thu Mar 18, 2010 10:43 pm
Location: Espoo, Finland

Re: Track plotter

Postby jblokker » Fri Aug 04, 2017 2:31 pm

Thank you, it is working now. The only strange thing is that I didn't use the ''set tpa'' card until you recommended it and the track plotter worked fine without it in the past.
jblokker
 
Posts: 7
Joined: Tue Jun 06, 2017 3:40 pm


Return to Input

Who is online

Users browsing this forum: No registered users and 1 guest

cron