-
Notifications
You must be signed in to change notification settings - Fork 12
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
add tracer particles #490
add tracer particles #490
Conversation
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
There were too many comments to post at once. Showing the first 10 out of 13. Check the log or trigger a new build to see more.
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
/azp run |
Azure Pipelines successfully started running 4 pipeline(s). |
/azp run |
Azure Pipelines successfully started running 4 pipeline(s). |
There is a weird ROCm build issue:
|
for more information, see https://pre-commit.ci
…/quokka into BenWibking/tracer-particles
/azp run |
Azure Pipelines successfully started running 4 pipeline(s). |
unrelated macOS CI failure. |
Fixed. Needs at least 2 ghost cells for the face velocity. |
/azp run |
Azure Pipelines successfully started running 4 pipeline(s). |
@markkrumholz There are a lot of code infrastructure changes in this PR, unfortunately. Let me know whether I should split this up into multiple PRs, and if so, what splitting would be easiest to review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've left a few comments on individual files, but overall this looks fine. Once those comments are addressed I can approve.
for more information, see https://pre-commit.ci
/azp run |
Azure Pipelines successfully started running 4 pipeline(s). |
…/quokka into BenWibking/tracer-particles
/azp run |
Azure Pipelines successfully started running 4 pipeline(s). |
@markkrumholz Can you re-review? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, looks good now.
Description
This adds tracer particles. Particles are created one-per-cell in the initial conditions, then they advect with the fluid using the face-centered velocities returned from the Riemann solver. Particles are included in plotfiles and checkpoints. (Particles will be added to openPMD outputs in a subsequent PR.)
The method adopted here for particle advection with face-centered velocities is the "marker-and-cell method" (Harlow & Welch 1965).
Tracer particles are turned on for the
HydroBlast3D
andSphericalCollapse
problems, so tracer particle functionality is included in the test suite.Significant code infrastructure changes:
state_new_fc_
andstate_old_fc_
. Some changes to the machinery for face-centered variables was necessary to get this to work, such as implementing AMR interpolation for face-centered variables using theamrex::FaceLinear
interpolator (caution: this interpolator does NOT preserve the divergence of the field!). This is necessary because ghost faces are needed in order to handle particles that cross coarse-fine boundaries during a timestep. (In the future, this machinery can be modified so that it creates alias MultiFabs for separate face-centered components and then uses a different AMR interpolator for each component.)setInitialConditionsOnGrid
(cell-centered variables) andsetInitialConditionsOnGridFaceVars
(face-centered variables). This only affects theFCQuantities
test problem.Related issues
Closes #489 and #498.
Checklist
Before this pull request can be reviewed, all of these tasks should be completed. Denote completed tasks with an
x
inside the square brackets[ ]
in the Markdown source below:/azp run
.