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

Allow single-step backward Euler integrator #1773

Next Next commit
allow single-step backward Euler
chongchonghe committed Mar 5, 2025
commit 4eb51f47bc9d08b80faf7a89c3ad1f8c2ea55b65
9 changes: 9 additions & 0 deletions integration/BackwardEuler/be_integrator.H
Original file line number Diff line number Diff line change
@@ -181,6 +181,15 @@ int be_integrator (BurnT& state, BeT& be)

int ierr;

if (be.atol_enuc < 0.0_rt) {
// Do a single step to the final time
const amrex::Real dt_single_step = be.tout - be.t;
ierr = single_step(state, be, dt_single_step);
be.t = be.tout;
++be.n_step;
return ierr;
}

// estimate the timestep

amrex::Array1D<amrex::Real, 1, int_neqs> ydot;