Changes between Version 3 and Version 4 of ExternalModelLoop
- Timestamp:
- Feb 22, 2023, 2:17:20 PM (21 months ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
ExternalModelLoop
v3 v4 35 35 36 36 ! Check whether forecast has to be performed 37 ifcontrol: IF (doexit /= 1) THEN37 checkforeast: IF (doexit /= 1 .AND. status_pdaf == 0) THEN 38 38 39 39 IF (nsteps > 0) THEN … … 45 45 CALL PDAFomi_put_state_global(...) 46 46 47 ELSE ifcontrol47 ELSE checkforecast 48 48 49 49 ! No more assimilation work; exit loop 50 50 EXIT pdaf_modelloop 51 51 52 END IF ifcontrol52 END IF checkforecast 53 53 54 54 END DO pdaf_modelloop 55 55 }}} 56 In this example, which is taken from the example implementation in `te stsuite/src/dummymodel_1D`, we use an unconditional DO loop (while loop). The exit flag `doexit` for this loop is set within `PDAF_get_state`. In addition, the variable `nsteps` is initialized, which defines the number of time steps to be performed during the current forecast phase. Thus, we only execute the time stepping code if `nsteps>0`. (If this has to be implemented using an IF-clause as in the example should be checked for the particular code).56 In this example, which is taken from the example implementation in `templates/online_omi_flexible/`, we use an unconditional DO loop (while loop). The exit flag `doexit` for this loop is set within `PDAF_get_state`. In addition, the variable `nsteps` is initialized, which defines the number of time steps to be performed during the current forecast phase. Thus, we only execute the time stepping code if `nsteps>0`. (If this has to be implemented using an IF-clause as in the example should be checked for the particular code). 57 57 58 58 == `PDAF_get_state` == … … 96 96 Here, only the user-supplied routines are discussed that are required at this stage of the implementation (that is, the ensemble integration). For testing (see [#Compilationandtesting 'Compilation and testing']), all routines need to exist, but only those described here in detail need to be implemented with functionality. 97 97 98 To indicate user-supplied routines we use the prefix `U_`. In the t emplate directory `templates/` as well as in the example implementation in `testsuite/src/dummymodel_1D` these routines exist without the prefix, but with the extension `_pdaf.F90`. In the section titles below we provide the name of the template file in parentheses.98 To indicate user-supplied routines we use the prefix `U_`. In the tutorials in `tutorial/` and in the template directory `templates/` these routines exist without the prefix, but with the extension `_pdaf`. The files are named correspondingly. In the section titles below we provide the name of the template file in parentheses. 99 99 100 100 === `U_next_observation` (next_observation_pdaf.F90) ===