-
Couldn't load subscription status.
- Fork 576
Implement Virtual Lattice Method for Efficient Simulation of Dispersed Fuels #3516
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
|
Hi @paulromano , As requested, I've opened the pull request for the new virtual lattice feature, based on the work in our recent CPC paper. I've run into a few points where I could use your guidance and help to get this PR ready for review:
Thanks for your time. Let me know what the best next steps are. |
|
@liangjg Hi |
Updates the documentation for the geometry format to include new attributes for TRISO particle and virtual lattice handling. These attributes specify whether a cell contains a TRISO particle, whether a virtual lattice is used, and the lattice's shape if applicable.
Introduces functionality to calculate distances and locate cells within virtual lattice geometries. Refactors existing geometry handling logic to reduce code duplication and improve maintainability. Key updates include: - Addition of `distance_in_virtual_lattice` and `find_cell_in_virtual_lattice` methods for specialized handling. - Integration of virtual lattice checks in standard cell distance computations. - Refactoring of repetitive code in surface crossing handlers for improved clarity. Enhances support for TRISO particle geometries within virtual lattices, ensuring accurate material and cell identification during particle transport.
Virtual lattice 0.15.2
|
@cn-skywalker Thank you so much for the help |
Description
This PR introduces a "virtual lattice" method, an acceleration technique designed to improve the performance and reduce the memory footprint of MC simulations for systems containing a large number of randomly dispersed particles.
Background
Simulating explicit, randomly distributed particles is computationally prohibitive due to the geometric complexity. Locating a neutron among hundreds of thousands of spheres is a major performance bottleneck.
The existing
create_triso_latticefunction implements a "physical lattice" approach. While this provides acceleration, it has several drawbacks:Implementation
The virtual lattice method decouples the acceleration structure from the actual CSG model. Instead of physically dividing the geometry, it works as follows:
This approach retains the acceleration benefits of a lattice structure while avoiding the overhead of a physical one.
As demonstrated in the associated paper, the virtual lattice method provides substantial advantages over the physical lattice method.
Usage
The feature is exposed to the user via a simple boolean flag in the Python API. To use the new method, a user simply sets
virtual=True:This implementation is based on the methodology and results presented in the following paper. For a detailed theoretical background, performance analysis, and validation, please refer to:
Liang, J., Li, R., & Liu, Z. (2024). Virtual lattice method for efficient Monte Carlo transport simulation of dispersion nuclear fuels. Computer Physics Communications, 295, 108985. [https://doi.org/10.1016/j.cpc.2023.108985]Checklist