Changes between Version 11 and Version 12 of InsertAnalysisStep
- Timestamp:
- Nov 30, 2020, 11:18:52 AM (4 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
InsertAnalysisStep
v11 v12 57 57 One has to ensure that `PDAF_assimilate_X` is called at each time step, so that PDAF can count the time steps until the next analysis time. 58 58 59 == `PDAF _assimilate_X` ==59 == `PDAFomi_assimilate_X` == 60 60 61 There is a separate routine `PDAF_assimilate_X` for each of the filter algorithms. The name of the routine includes the name of the filter at its end (instead of `X`). The purpose of the `PDAF_assimilate_X` routines is to count the time steps. When the forecast phase is complete the routine writes back the forecast model fields into the array holding the ensemble of model state vectors and executes the analysis step of the chosen filter algorithm. The interface to each 'assimilate' routine is specific for each filter algorithm, because the names of several user-supplied routines have to be specified, which are specific for each filter algorithm. However, at the stage of implementing the ensemble integration only the first and last arguments of the routines are relevant.61 There are a separate routines `PDAFomi_assimilate_global` and `PDAFomi_assimilate_local` for global and local filter algorithms, respectively. The purpose of the `PDAFomi_assimilate_X` routines is to count the time steps. When the forecast phase is complete the routine writes back the forecast model fields into the array holding the ensemble of model state vectors and executes the analysis step of the chosen filter algorithm. The interface to each 'assimilate' routine is specific for each filter algorithm, because the names of several user-supplied routines have to be specified, which are specific for each filter algorithm. However, at the stage of implementing the ensemble integration only the first and last arguments of the routines are relevant. 62 62 63 For example, the interface when using the ESTKFfilter is the following:63 For example, the interface when using the global filter is the following: 64 64 {{{ 65 SUBROUTINE PDAF_assimilate_estkf(U_distribute_state, U_collect_state, & 66 U_init_dim_obs, U_obs_op, & 67 U_init_obs, U_prepoststep, U_prodRinvA, & 68 U_init_obsvar, next_observation_pdaf, status) 65 SUBROUTINE PDAFomi_assimilate_global(U_distribute_state, U_collect_state, U_init_dim_obs, U_obs_op, & 66 U_prepoststep, U_next_observation, status) 69 67 }}} 70 68 At this state of the implementation only these arguments are relevant: 71 69 * [#U_distribute_statedistribute_state_pdaf.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. (This routine is also used in `PDAF_get_state`) 72 70 * [#U_collect_statecollect_state_pdaf.F90 U_collect_state]: The name of the user-supplied routine that initializes a state vector from the array holding the ensemble of model states from the model fields. This is basically the inverse operation to `U_dist_state`. 71 * [#U_prepoststepprepoststep_ens_pdaf.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. 73 72 * [#U_next_observationnext_observation_pdaf.F90 U_next_observation]: The name of a user supplied routine that initializes the variables `nsteps`, `timenow`, and `doexit`. (This routine is also used in `PDAF_get_state`) 74 73 * `status`: The integer status flag. It is zero, if PDAF_get_state is exited without errors. … … 76 75 The other arguments are names of user-supplied subroutines that are only executed if the analysis step is executed (See the section [#Compilationandtesting 'Compilation and testing'] for how to provide these routines for compilation at this stage). These routines are explained in the next section of the implementation guide ([ImplementationofAnalysisStep Implementation of the Analysis step]) separately for each available filter algorithm. 77 76 78 PDAF also has a [PdafSimplifiedInterface Simplified Interface] providing the routine `PDAF_assimilate_X_si`. In the simplified interface, the names of all user-supplied call back routines are predefined such that they not appear in the call to `PDAF_assimilate_X_si`. More information on the pre-defined names is provided in the [PdafSimplifiedInterface documentation of PDAF's simplified interface].79 77 80 78 == User-supplied routines ==