| 170 | == Calling `PDAF_init_forecast` == |
| 171 | |
| 172 | The routine `PDAF_init_forecast` initializes the information, whether further model integrations have to be performed and how many time steps have to be computed in the next forecast aphse. In addition, the ensemble state vectors are written into the model fields so that they can be propagates. In the tutorial codes and the template, the call to `PDAF_init_forecast` is fully implemented. Here, we provide an overview of its arguments. |
| 173 | |
| 174 | The interface of `PDAF_init_forecast` is: |
| 175 | {{{ |
| 176 | SUBROUTINE PDAF_init_forecast(nsteps, timenow, doexit, & |
| 177 | U_next_observation, U_distribute_state, & |
| 178 | U_prepoststep, status) |
| 179 | }}} |
| 180 | with the following arguments: |
| 181 | * `nsteps`, `integer, intent(inout)`: An integer specifying upon exit the number of time steps to be performed |
| 182 | * `timenow`, `real, intent(out)`: A real specifying upon exit the current model time. |
| 183 | * `doexit`, `integer, intent(inout)`: An integer variable defining whether the assimilation process is completed and the program should exit the while loop. For compatibility 1 should be used for exit, 0 for continuing in the loop. |
| 184 | * [#U_next_observationnext_observation.F90 U_next_observation]: The name of a user supplied routine that initializes the variables `nsteps`, `timenow`, and `doexit` |
| 185 | * [#U_distribute_statedistribute_state.F90 U_distribute_state]: The name of a user supplied routine that initializes the model fields from the array holding the ensemble of model state vectors |
| 186 | * [#U_prepoststepprepoststep_seik.F90 U_prepoststep]: The name of a user supplied routine that is called before and after the analysis step. Here the user has the possibility to access the state ensemble and can e.g. compute estimated variances or can write the ensemble states the state estimate into files. |
| 187 | * `status`, `integer, intent(inout)`: The integer status flag. It is zero, if `PDAF_init_forecast` is exited without errors. |
| 188 | |
| 189 | |
| 190 | |