Skip to content
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

Compute the shock flag once -- at the start of the timestep #2728

Merged
merged 18 commits into from
Apr 30, 2024

Conversation

zingale
Copy link
Member

@zingale zingale commented Jan 23, 2024

PR summary

This changes the way the shock flag is computed for disabling burning in shocks. Now we compute it
at the top of the timestep, before the first Strang burn, using the time-level n state and sources.
There is some redundancy here (we need to compute the old sources before the burn now),
and there is a FillPatch needed. But this should be minimal and only in effect if we compile with SHOCK_VAR.

Note: this does not change how we compute the shock flag for hydro at the moment
when doing the hybrid Riemann solve (although we can easily change that in a future PR).

PR motivation

PR checklist

  • test suite needs to be run on this PR
  • this PR will change answers in the test suite to more than roundoff level
  • all newly-added functions have docstrings as per the coding conventions
  • the CHANGES file has been updated, if appropriate
  • if appropriate, this change is described in the docs

it should not matter which comes first, since reactions don't
change density, but this swap will allow us to precompute the
shock flag with sources before the first burn.
@zingale zingale changed the base branch from main to development January 23, 2024 16:04
@zingale
Copy link
Member Author

zingale commented Jan 23, 2024

depends on #2726
fixes #2724

@zingale zingale changed the title [WIP] Compute the shock flag once -- at the start of the timestep Compute the shock flag once -- at the start of the timestep Apr 7, 2024
@zingale
Copy link
Member Author

zingale commented Apr 7, 2024

this is ready for review now

@zingale zingale mentioned this pull request Apr 8, 2024
5 tasks
@zingale zingale merged commit 45f9560 into AMReX-Astro:development Apr 30, 2024
25 checks passed
@zingale zingale deleted the new_shock_flag_call branch April 30, 2024 00:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants