I am trying to compare the results for a fixed source photon transport problem between OpenMC, MCNP, and Serpent.
Geometry:
Bare 7cm-radius sphere of U-235.
Source:
The source should emit photons with energies uniformly distributed between 9 and 10 MeV.
Results: (Energies expressed in MeV)
The integral fluxes are:
Serpent: 0.0018058876355745788
MCNP: 0.0022937391129849998
Integral OpenMC: 0.0020443844006718622
And the ratios are:
MCNP/OpenMC: 1.121970561031081
Serpent/OpenMC: 0.8833405473946562
Notes:
OpenMC is the only one that shows photons below 1keV, which surprises me. The simulation energy cutoff default value is 1keV. Why am I seeing photons below those energies? Serpent and MCNP have the same cutoff and their tallies don’t show photons below the cutoff.
I tried defining a cutoff for OpenMC as
settings.cutoff = {'energy': 1000.0}
and
settings.cutoff = {'energy_photon': 1000.0}
with no effect on the results.
Any ideas why there are discrepancies in the integral fluxes? If I reduce the energy of the source, the results improve considerably. So, I am tempted to think that there might be some discrepancies in the physics models at high energies.
Update: I was able to match Serpent and MCNP spectra, I made a mistake with the sampling of the source position.
What would be the proper way to sample the source position uniformly within a cell in OpenMC?
I still don’t know why I see photons below 1 keV and above 100 keV in the second Figure.
@froberto Are you using a particle filter in your tally? If not, you may be seeing contributions from electrons/positrons that are generated due to photon interactions. Are you able to share your full model so that I can try to reproduce?
Regarding sampling the source position uniformly, you can use:
This will result in source sites being generated outside your sphere, but those points will be rejected, leaving only points inside the sphere. In our upcoming release of OpenMC, you can properly sample points uniformly in a sphere with:
Thanks, @paulromano for your response.
I added your suggestions to my input file, but I still see undesired peaks below the energy cutoff.
I am probably doing something wrong here.
Thanks for sharing your model @froberto. After investigating, it looks like the photons below 1 keV are the result of atomic relaxation (i.e., they are X-rays resulting from electrons being kicked out of the atom). Our cutoffs are not catching these photons right now, and so they end up going on to have a single collision before being killed. I’ll submit a bug fix to remedy this behavior. The spectrum above 1 keV should be OK though – are you seeing agreement above 1 keV for OpenMC vs MCNP vs Serpent?
Thanks @paulromano for looking into this.
Yes, I see agreement between the OpenMC, MCNP, and Serpent.
One small caveat is that MCNP doesn’t resolve well the peaks around 10 keV, but OpenMC and Serpent do.
I have another question about sampling the source position.
Can I use the method described above if my geometry consists of two concentric spheres and the source is in one of them only?
Is there a way to choose the cell where the particles are born?
I’ve seen this other post.
I think I need something along those lines.
Glad to hear you’re seeing good agreement. Regarding the source question, yes, if we had a general source filtering capability, that would make it easy as you could just ask it to filter on the cell you want the source to be in. In the absence of that, if you wanted to sample a source uniformly over a spherical shell (one of your concentric spheres), you’d have to either write a C++ custom source routine (described here) or use the new PowerLaw distribution as follows: