Efficiently Running Multiple MCNP Simulations with Variable Source Positions

  • Thread starter Thread starter jamez_302
  • Start date Start date
  • Tags Tags
    Mcnp Modelling
Click For Summary
SUMMARY

This discussion focuses on efficiently running multiple MCNP simulations with variable source positions for a HPGe detector using a Co-60 source. The user seeks a method to incorporate 50 different source positions into a single input file to avoid repetitive edits and executions. Suggestions include utilizing scripting languages such as Bash or Python to automate the process, allowing for parallel execution across multiple machines. The conversation also touches on alternative approaches using Fortran or C++ for more complex interactions.

PREREQUISITES
  • Familiarity with MCNP (Monte Carlo N-Particle Transport Code)
  • Basic understanding of scripting in Bash or Python
  • Knowledge of parallel computing concepts
  • Experience with input file structures in simulation software
NEXT STEPS
  • Learn how to automate MCNP input file generation using Python scripts
  • Explore parallel execution techniques in Bash for simulation tasks
  • Investigate the use of Fortran or C++ for advanced simulation interactions
  • Study MCNP documentation on handling multiple source positions in simulations
USEFUL FOR

Researchers, physicists, and engineers working with MCNP simulations, particularly those involved in radiation detection and modeling with variable source positions.

jamez_302
Messages
3
Reaction score
0
I'm currently working on a project using mcnp to model a HPGe detector with a Co-60 source. I have defined my cells and got my geometry spot on but the project requires me to move the source around about 50 different positions relative to the detector. I was wondering if there was any way to basically incorporate this into one input file to save me having to edit it 50 times and run it on 50 separate occasions? Thanks
 
Engineering news on Phys.org
Don't know about mcnp in particular but 50 input files and a scripting language like bash or python would make short work of it. You could even run the jobs in parallel if multiple machines are to be had.
 
Paul Colby said:
Don't know about mcnp in particular but 50 input files and a scripting language like bash or python would make short work of it. You could even run the jobs in parallel if multiple machines are to be had.
I had the same thought this morning, but didn't respond. That's pretty much how folks do a series of computations, if not using Fortran or C++ with an interaction loop and 50 line input file.
 

Similar threads

  • · Replies 1 ·
Replies
1
Views
3K
Replies
5
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 2 ·
Replies
2
Views
4K
  • · Replies 4 ·
Replies
4
Views
3K
Replies
1
Views
3K
Replies
2
Views
3K
  • · Replies 15 ·
Replies
15
Views
4K