Strange behaviours by plotting a typical PWR spectrum of a pin cell

Hi all,

I am writing here in relations to some problems that I encountered by plotting the spectrum of a typical PWR pin cell case, with the parameters taken by the VERA benchmark.
At the beginning, I wanted to plot the spectrum in the fuel, cladding and coolant by using the following filter:

cellSpectFilter=openmc.CellFilter([cFuel, cClad, cCool])

I employed the ECCO1968 energy group structure, normalized in lethargic scale. What I’ve noticed, it is that the spectrum in the fuel had a peak in the thermal regions with a shape that is not typical of a PWR spectrum.

After that, I decided to tally the spectrum only for the pin cell, by commenting, in the code, the cell filter line.
I obtained the spectrum shape that I expected, with higher values in the epithermal/fast regions. Here, the plot of the spectrum:

(zoomed)
immagine

(not zoomed)

immagine

As I see, also in this case, there is a strange behaviour since there are 3 not physical spikes in the epithermal and fast regions.
In the past, I used the same energy groups with Serpent and I never found these unphysical energy points. Here below, a spectrum that I obtained in Serpent for a PWR cell case with similar parameters:

1e-2
immagine

In addition, I observed that, in the OpenMC results, the fast part is much higher (than the Serpent results) in proportion with respect to the thermal part. Also, the enrichments is low, at 2.1 %, for which we expect a softer spectrum.

By checking the literature, the spectrum from OpenMC still looks too hard and I didn’t find these unphysical spikes.

Considering the issues presented, i.e. the strange behaviour by using the cell filters, unphysical spikes and the hard spectrum, anyone has suggestions, please?

Thanks in advance for your time.
Best regards,

Christian

1 Like

@byba90 How are you normalizing the flux for the plot? Are you dividing by the energy width of each bin? or something else?

Dear @paulromano ,

thank you very much for your answer.

I attach the file with the definition of the energy group.
ECCO1968_eneGroup.py (38.6 KB)

Here below the tally that I defined:

ECCO1968=np.array(ECCO1968_groupEne)*1e6

tally_ecco1968=openmc.Tally(name="ecco1968")
eneFilter = openmc.EnergyFilter(ECCO1968)
#cellSpectFilter=openmc.CellFilter([cFuel, cClad, cCool])
tally_ecco1968.filters.append(eneFilter)
#tally_ecco1968.filters.append(cellSpectFilter)
tally_ecco1968.scores=['flux'] 

tallies=openmc.Tallies([tally_ecco1968])

Here below, the part of the code where I read the tally and I normalized. I plot in lethargic scale by dividing by the energy width in log scale and I normalized with the square root.

ene_group=ECCO1968

tally_spect=tallies.get_tally(name='ecco1968')
tally_spect_mean=tally_spect.mean.ravel()
tally_spect_cell=tally_spect_mean/(np.log(ene_group[1:])-np.log(ene_group[:-1]))
norm_fact=np.sqrt(np.sum(np.power(tally_spect_cell,2)))

tally_spect_cell_norm=tally_spect_cell/norm_fact
ene_group_av=(ene_group[1:]+ene_group[:-1])/2
plt.semilogx(ene_group_av, tally_spect_cell_norm)

Thanks again for your time!
Best regards,

Christian

Hi @byba90 I just wanted to mention this lethargy_bin_width feature that was recently added to OpenMC.

It is similar to the normalization you are applying but it doesn’t have the square root part.

If the square root is important to have in the normalisation then perhaps we can add another method to the EnergyFilter to make it convenient?

Also I notice you are using a group structure that we don’t have in OpenMC, we could perhaps add that to the existing collection

Dear @Shimwell ,

thanks for your reply. Unfortunately, the spikes come from the division by np.log(ene_group[1:])-np.log(ene_group[:-1]) and not from the square root normalization.
About adding ECCO1968 to the existing collection, I think it’s a good idea.

Thanks for your time.
Best regards,

Christian

EDIT: I checked also without dividing by np.log(ene_group[1:])-np.log(ene_group[:-1]) and I still have the spikes.

plotECCO1968

Christian

Are you by chance running a coupled neutron–photon simulation? If so, you’ll want to make sure that you use a ParticleFilter on your tally to only get the flux from the desired particle.

2 Likes

Hi @byba90

Hopefully adding the particle filter solved the issue by removing photons from the tally.

Paul has just reviewed and merged in the additional energy group is merged in. Your energy filter can now be made with one line when using the latest version of OpenMC (0.13.1) which has also just been released. I think this might be the fastest user request to feature in released version that I’ve seen :zap:

energy_filter = openmc.EnergyFilter.from_group_structure('ECCO-1968')
2 Likes

Dear @paulromano ,

thank you very much for your answer. I added the particle filter and now the spectrum is correct!
@Shimwell thanks for your support.
Thanks both for your help and the efficiency into updating OpenMC with this energy group.
Regards,

Christian

1 Like