From 22a1a3a1d4b0aaa81d3deaa0320e4a4aebb2d99d Mon Sep 17 00:00:00 2001 From: Miren Radia <32646026+mirenradia@users.noreply.github.com> Date: Sat, 1 Jul 2023 20:40:01 +0100 Subject: [PATCH] Amr: Add printing of simulation time (#3392) A very small PR to add the printing of simulation time in `Amr::timeStep` (for `Amr::verbose > 0`). Though the time is already printed out every coarse timestep [here](https://github.com/AMReX-Codes/amrex/blob/9c256b12b89f86b30fe1a6f03dd79db351d56fb3/Src/Amr/AMReX_Amr.cpp#L2174), with deep AMR hierarchies, it can be a long amount of [wall]time between these printouts, hence I would find it useful to see the current simulation time more often. --- Src/Amr/AMReX_Amr.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Src/Amr/AMReX_Amr.cpp b/Src/Amr/AMReX_Amr.cpp index 7ebe9ce28dc..56e253b6ece 100644 --- a/Src/Amr/AMReX_Amr.cpp +++ b/Src/Amr/AMReX_Amr.cpp @@ -1993,7 +1993,8 @@ Amr::timeStep (int level, if (verbose > 0) { amrex::Print() << "[Level " << level << " step " << level_steps[level]+1 << "] " - << "ADVANCE with dt = " << dt_level[level] << "\n"; + << "ADVANCE at time " << time + << " with dt = " << dt_level[level] << "\n"; } Real dt_new = amr_level[level]->advance(time,dt_level[level],iteration,niter);