AMReX-Astro / AMReX-Astro/Microphysics
SDC temperature cutoff discards advective sources as well as reactions
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 43
- Forks
- 46
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 15
Description
Suggested priority: High
Reviewed revision: 3ac0bda4f00da3eed0446beadfc1cd5c51b99a40
Problem and impact
At either temperature bound, the SDC RHS zeros every derivative and returns before rhs_to_int() adds state.ydot_a.
The SDC system includes nonreacting sources for species partial densities and internal energy. Disabling reactions at a temperature limit must not disable those sources. Density continues to be reconstructed from its advective source separately, so this early return can also make density and partial densities inconsistent. Advective heating that should move a cold cell back into the burning temperature range is lost.
Affected code
Reproduction and observed behavior
From the repository root, run:
python3 agent-notes/integration-review-2026-09-06/reproduce.py
Run sdc_cutoff. Use zero nuclear rates and nonreacting derivatives (0.1, -0.1, 2) for the two species and energy.
T=1 rhs=0,0,0 expected=.1,-.1,2
T=10 rhs=0.1,-0.1,2 expected=.1,-.1,2
T=1e+11 rhs=0,0,0 expected=.1,-.1,2
The bounds here are mintemp = 1 and MAX_TEMP = 1e11. The test includes the actual SDC state-conversion and RHS headers.
The companion script and captured output are part of this review. These are focused CPU tests with minimal AMReX/physics substitutes, not full network or GPU integration tests. Attach the script when submitting this issue.
Suggested fix and regression coverage
Zero only the reaction contribution at the temperature limits, then execute the ordinary conversion/addition of advective sources and energy scaling. Add source-only SDC tests at both bounds, with and without scale_system, and a case where advective heating crosses the lower bound.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with integration/integrator_rhs_sdc.H:44 and integration/integrator_type_sdc.H:167, then run agent-notes/integration-review-2026-09-06/reproduce.py to observe the cutoff behavior. Preserve the nonreacting advective sources at both temperature bounds, including scale_system cases and lower-bound advective heating, and confirm the source-only SDC cases produce the expected RHS values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 76/100