Any tips for debugging MCNP geometry errors?

Click For Summary
SUMMARY

This discussion focuses on effective strategies for debugging geometry errors in MCNP (Monte Carlo N-Particle Transport Code). Users recommend utilizing X-server tools like X-ming to visualize geometry in multiple planes (XY, XZ, YZ) and employing the MCNPX Visual Editor for complex geometries. A specific debugging technique involves changing all cells to void material with non-zero neutron/photon importance, surrounding the geometry with a void sphere, and creating a generic point source to identify lost particles, which indicates geometry errors. The discussion emphasizes the importance of running simulations with a sufficient number of histories to accurately pinpoint issues.

PREREQUISITES
  • Familiarity with MCNP (Monte Carlo N-Particle Transport Code)
  • Understanding of X-server tools, specifically X-ming
  • Knowledge of MCNPX Visual Editor for geometry visualization
  • Basic concepts of neutron/photon importance in particle transport simulations
NEXT STEPS
  • Research advanced debugging techniques in MCNP geometry
  • Learn how to effectively use the MCNPX Visual Editor for complex geometries
  • Explore the implications of particle importance settings in MCNP simulations
  • Investigate best practices for optimizing simulation runs with high particle histories
USEFUL FOR

Intermediate users of MCNP, computational physicists, and anyone involved in debugging complex geometries in particle transport simulations.

Kirk Truax
Messages
9
Reaction score
2
Hey all,

I was wondering if anyone had any good tips on debugging mcnp geometry? I'm an intermediate user working on better understanding the program. Does anyone have any tips or tricks that go beyond simply reading the manual?
 
Engineering news on Phys.org
Hi
I think there are no easy answers or ready-made solutions. For my part I use a X-server (X-ming for me) and look at the geometry in XY, XZ AND YZ. But it is true that for complex geometry you can not see everything. With x-ming you can also see the cookie-cutter.
PSR
 
or you can try using MCNPX Visual Editor
 
If you have a tiny or non-obvious geometry error (caused by rounding off errors, overlaps, skewed lattice etc) that you can't find with the MCNP plotter or Visual Editor, the following technique can help you pinpoint the error:
- Change all cells to having a void material, but a non-zero neutron/photon importance.
- Surround the entire geometry with a void sphere, again non-zero particle importance
- Surround the sphere with a zero importance void as usual.
- Create a generic point source somewhere within the geometry.
Run MCNP for a very high number of histories. If there are any geometry errors, the run will terminate because of lost particles. You can find the coordinates of the lost particles in the output and file and use those to pinpoint the error.
 
I did what quarkle said and strangely without material the error disappeared, Is that mean losing particles are not caused by geometry error ?
 
Show us the input file, or a simplified input file that still shows the issue. The trick is to make things fast for large numbers of particles. If it's fixed the issue, you may have an obvious undefined area around your problem. Or you didn't set the importance correctly.
 
No sorry, I found the geometrical error , maybe number of particles were not large enough in the previous run (without material) to reach the erroneous parts of geometry.
 
  • Like
Likes   Reactions: Alex A

Similar threads

  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 1 ·
Replies
1
Views
4K
  • · Replies 23 ·
Replies
23
Views
3K
  • · Replies 3 ·
Replies
3
Views
4K
  • · Replies 19 ·
Replies
19
Views
1K
  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 16 ·
Replies
16
Views
2K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 17 ·
Replies
17
Views
4K