- #1
Alexander Camargo
- 34
- 10
I know that "mcnpx n=filename" I run the file, but how do I run the entire folder with the entries inside?
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.
To run an entire folder in MCNPX, you will need to use the "mcrun" command. This command will execute all the input files in the specified folder.
Yes, you can specify the order of execution by using the "mcrun -f" command. This will allow you to specify the order of the input files in a text file.
If you want to run only specific input files in the folder, you can use the "mcrun -i" command. This will allow you to specify the input files you want to run by listing their names in a text file.
To view the output from all the input files in the folder, you can use the "mcrun -o" command. This will generate a single output file containing the results from all the input files.
Yes, you can use the "mcrun -s" command to save the results from each input file separately. This will generate individual output files for each input file in the folder.