Borated Water: Function Discrepancies In OpenMC
In the realm of nuclear reactor simulations, accurate material definitions are paramount for reliable results. OpenMC, a widely used Monte Carlo particle transport code, provides users with multiple avenues for material creation. However, a recent investigation has brought to light a notable discrepancy in the creation of borated water using two distinct functions: borated_water and mix_materials. This article delves into the intricacies of this issue, presenting a comprehensive analysis of the observed differences and their potential implications for reactor modeling.
The Case of the Discrepant Borated Water
The issue came to light during the modeling of a Pressurized Water Reactor (PWR) pin-cell, a fundamental component in reactor core design. Borated water, a crucial neutron absorber, plays a significant role in reactor control and safety. The user, in this instance, sought to define borated water with a boron concentration of 500 parts per million (ppm) using two different approaches within OpenMC:
- The
borated_waterfunction, a dedicated tool designed for the direct creation of borated water. - The
mix_materialsfunction, a more general-purpose tool for mixing various materials based on specified compositions.
The expectation was that both methods should yield comparable results, with only minor variations arising from the inherent nature of numerical simulations. However, the initial findings revealed a surprising divergence in the effective neutron multiplication factor (k-eff), a key indicator of reactor criticality. The discrepancy amounted to a substantial 250 pcm (parts per million), raising concerns about the consistency and reliability of the two approaches.
Method 1: Harnessing the borated_water Function
The first approach leveraged OpenMC's built-in borated_water function, a streamlined method for creating borated water mixtures. This function simplifies the process by allowing users to directly specify parameters such as boron concentration (in ppm), temperature, and density. The code snippet below illustrates the implementation:
mat_borated_water = openmc.model.borated_water(
name='Water',
boron_ppm=500,
temperature=579.65,
density=0.71243
)
This concise code effectively defines borated water with the desired properties, offering a seemingly straightforward solution.
Method 2: Employing the mix_materials Function
The second approach adopted a more granular method, utilizing the mix_materials function. This involved first defining individual materials for water and boron, followed by mixing them according to the specified boron concentration. The code snippet below outlines the steps involved:
mat_water = openmc.Material(name="Water")
mat_water.add_element('H', 2.0, 'ao')
mat_water.add_element('O', 1.0, 'ao')
mat_boron = openmc.Material(name='Boron')
mat_boron.add_element('B', 1.0)
ppms = 500
wo = ppms * 1e-6
mat_borated_water = openmc.Material.mix_materials(
[mat_water, mat_boron],
[1-wo, wo],
'wo'
)
mat_borated_water.temperature = 579.65
mat_borated_water.set_density('g/cm3', 0.71243)
mat_borated_water.add_s_alpha_beta('c_H_in_H2O')
This method provides greater flexibility in defining material compositions but requires a more detailed understanding of the mixing process.
Unraveling the Discrepancy: A Quest for Consistency
The observed 250 pcm difference in k-eff between the two methods prompted a deeper investigation into the underlying causes. To isolate the source of the discrepancy, the user decided to compare the nuclide atom densities generated by each method. Nuclide atom density represents the number of atoms of a specific isotope per unit volume, a crucial parameter in neutron transport calculations.
The get_nuclide_atom_densities() function in OpenMC was employed to extract these values from the borated water materials created using both the borated_water and mix_materials functions. The resulting densities were then used as direct inputs for two additional calculations, effectively bypassing the material creation functions and focusing solely on the impact of nuclide composition.
Calculations 3 and 4: Isolating the Nuclide Density Effect
In the third calculation, the nuclide atom densities obtained from the borated_water function (calculation 1) were used as input to define a new borated water material. Similarly, the fourth calculation utilized the densities derived from the mix_materials function (calculation 2). These calculations aimed to determine whether the discrepancy stemmed from the material creation functions themselves or from subtle differences in the resulting nuclide compositions.
The code snippets below illustrate the material definitions used in calculations 3 and 4:
Calculation 3 (Densities from borated_water):
mat_borated_water = openmc.Material()
mat_borated_water.add_nuclide('H1', 0.047633378982465065)
mat_borated_water.add_nuclide('H2', 7.419577967801814e-06)
mat_borated_water.add_nuclide('O16', 0.02381137134888923)
mat_borated_water.add_nuclide('O17', 9.02793132720203e-06)
mat_borated_water.add_nuclide('B10', 3.934458340058397e-06)
mat_borated_water.add_nuclide('B11', 1.5916491912506678e-05)
mat_borated_water.temperature = 579.65
mat_borated_water.set_density('sum')
mat_borated_water.add_s_alpha_beta('c_H_in_H2O')
Calculation 4 (Densities from mix_materials):
mat_borated_water = openmc.Material()
mat_borated_water.add_nuclide('H1', 0.047609562292973834)
mat_borated_water.add_nuclide('H2', 7.415868178817913e-06)
mat_borated_water.add_nuclide('O16', 0.023799465663214784)
mat_borated_water.add_nuclide('O17', 9.023417361538426e-06)
mat_borated_water.add_nuclide('B10', 3.932491110888369e-06)
mat_borated_water.add_nuclide('B11', 1.590853366655043e-05)
mat_borated_water.temperature = 579.65
mat_borated_water.set_density('sum')
mat_borated_water.add_s_alpha_beta('c_H_in_H2O')
The Revelation: borated_water as the Culprit
The results of calculations 3 and 4 provided a crucial insight into the discrepancy. These calculations, which utilized the nuclide atom densities derived from calculations 1 and 2, respectively, yielded very similar k-eff values. This key finding indicated that the differences observed in the initial calculations were not due to the nuclide densities themselves but rather to the way the borated_water function was constructing the material.
Calculations 2, 3, and 4 exhibited a high degree of consistency, while calculation 1, which employed the borated_water function, produced significantly different results. This evidence strongly suggested an issue within the borated_water function's implementation.
Summary of Results: A Clear Pattern Emerges
The following table summarizes the k-eff results obtained from the four calculations, highlighting the discrepancy associated with the borated_water function:
| Calculation | k-eff | Difference (pcm) | Borated water was created using ... |
|---|---|---|---|
| 1 | 1.27748 | -259.77 | ... borated_water function |
| 2 | 1.27417 | Reference | ... mix_materials function |
| 3 | 1.27414 | 2.354 | ... nuclide densities from calculation 1 |
| 4 | 1.27416 | 0.784 | ... nuclide densities from calculation 2 |
The data clearly demonstrates that the borated_water function (calculation 1) deviates significantly from the other methods, which show excellent agreement. This pattern reinforces the conclusion that the discrepancy lies within the borated_water function itself.
Implications and Recommendations
The observed discrepancy in borated water creation has significant implications for reactor modeling. Inaccurate material definitions can lead to erroneous predictions of reactor behavior, potentially compromising safety and performance assessments. Therefore, it is crucial to address this issue and ensure the reliability of OpenMC's material creation functions.
Based on the findings of this investigation, the following recommendations are warranted:
- Further investigation of the
borated_waterfunction: A thorough review of theborated_waterfunction's implementation is necessary to identify and rectify the source of the discrepancy. This should involve a detailed examination of the function's algorithms and data handling procedures. - Transparency in material creation: OpenMC users should be made aware of the potential discrepancy between the
borated_waterandmix_materialsfunctions. Clear documentation and warnings should be provided to guide users in selecting the appropriate method for their specific needs. - Validation and verification: Rigorous validation and verification efforts are essential to ensure the accuracy and consistency of OpenMC's material creation capabilities. This should involve comparing results obtained using different methods and against experimental data.
Conclusion: Ensuring Accuracy in Reactor Simulations
This investigation has shed light on a significant discrepancy in borated water creation within OpenMC. The findings highlight the importance of thorough validation and verification in computational modeling, particularly in safety-critical applications such as nuclear reactor simulations. By addressing the identified issue and implementing the recommendations outlined above, we can enhance the reliability and accuracy of OpenMC, ensuring its continued value as a leading tool for reactor analysis and design.
For further information on OpenMC and its capabilities, please visit the official OpenMC website: OpenMC Website.