WRF icon indicating copy to clipboard operation
WRF copied to clipboard

Fix the source of the dt=0 error when using adaptive time step in em_b_wave ideal test case

Open JeroBnd opened this issue 1 year ago • 9 comments

Fixed the source of the dt=0 error when using adaptive time step in ideal cases in em_b_wave ideal test case Restrict the remaining time until the next boundary control to be greater than 0 in order to correct the dtInterval.

TYPE: choose one of [bug fix, enhancement, new feature, feature removed, no impact, text only]

KEYWORDS: adaptative, timestep, ideal

SOURCE: Jeronimo Bande (IDING SAS)

DESCRIPTION OF CHANGES: Problem: The adapt_timestep module is not prepared to handle this kind of idealized case. The algorithm uses the remaining time until the boundary condition is applied, with a counter that resets when the boundary condition is used.

In this idealized case, the counter starts with a value of 10800 (equivalent to 3 hours), but when the supposed boundary condition should occur, it doesn’t, and the counter continues decreasing into negative values, causing the simulation to terminate prematurely.

Solution: Restrict the remaining time until the next boundary control to be greater than 0 in order to correct the dtInterval.

ISSUE: Fixes #1560 Fixes #2103 Fixes #2036 LIST OF MODIFIED FILES: /dyn_em/adapt_timestep_em.F

TESTS CONDUCTED:

RELEASE NOTE: Fix adaptative time step for ideal cases.

JeroBnd avatar Sep 12 '24 13:09 JeroBnd