Alexander Camargo
- 37
- 10
I know that "mcnpx n=filename" I run the file, but how do I run the entire folder with the entries inside?
To run an entire folder of MCNP input files, users must create a batch file for either Windows or Linux, as MCNP programs do not support this functionality natively. For large-scale simulations, such as those involving over 12,000 entries, automation is essential. The WORM tool is mentioned as a method for generating input files but does not execute MCNP or extract results. Python scripts can also be utilized to edit input files, execute MCNP 6, and extract results efficiently.
PREREQUISITESThis discussion is beneficial for computational physicists, researchers conducting large-scale MCNP simulations, and developers looking to automate simulation workflows.
Alex A said:I don't *think* any of the mcnp programs will do that. It's fairly trivial to write a batch file, either for windows or linux to do the job and clean up the run files. Which OS?
Thanks a lot for the help. I automate my entries with notepad++ using macros and "advanced renamer" for the different names of each file. I already put the 12k input to simulate, now just wait about 100 hours. hahahaAlex A said:That is the kind of use case WORM was created for, but it doesn't run mcnp/x or extract the results, it just creates the input files. I found some example stuff in python that will edit an input file, run mcnp, in this case 6 and extract the result here - https://www.justanswer.com/computer-programming/gfgmq-again-thank-again-excellent-help-think.html
If you have 12k problems, maybe this is worth automating at this level.