Changes between Version 18 and Version 19 of ImplementAnalysisetkf
- Timestamp:
- May 5, 2014, 1:24:16 PM (11 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
ImplementAnalysisetkf
v18 v19 11 11 <li><a href="ImplementationofAnalysisStep">Implementation of the analysis step</a></li> 12 12 <ol> 13 <li><a href="ImplementAnalysisestkf">Implementation for ESTKF</a></li> 14 <li><a href="ImplementAnalysislestkf">Implementation for LESTKF</a></li> 15 <li>Implementation for ETKF</li> 16 <li><a href="ImplementAnalysisletkf">Implementation for LETKF</a></li> 13 17 <li><a href="ImplementAnalysisseik">Implementation for SEIK</a></li> 14 18 <li><a href="ImplementAnalysislseik">Implementation for LSEIK</a></li> 15 <li>Implementation for ETKF</li>16 <li><a href="ImplementAnalysisletkf">Implementation for LETKF</a></li>17 19 <li><a href="ImplementAnalysisseek">Implementation for SEEK</a></li> 18 20 <li><a href="ImplementAnalysisenkf">Implementation for EnKF</a></li> 19 <li><a href="ImplementAnalysisestkf">Implementation for ESTKF</a></li>20 <li><a href="ImplementAnalysislestkf">Implementation for LESTKF</a></li>21 21 </ol> 22 22 <li><a href="AddingMemoryandTimingInformation">Memory and timing information</a></li> … … 29 29 == Overview == 30 30 31 For the analysis step of the ETKF, different operations related to the observations are needed. These operations are requested by PDAF by calling user-supplied routines. Intentionally, the operations are split into separate routines in order to keep the operations rather elementary. This procedure should simplify the implementation. The names of the required routines are specified in the call to the routine `PDAF_ put_state_etkf`that was discussed before. With regard to the parallelization, all these routines are executed by the filter processes (`filterpe=.true.`) only.32 33 For completeness we discuss here all user-supplied routines that are specified in the interface to PDAF_ put_state_etkf. Thus, some of the user-supplied routines that are explained on the page explaining the modification of the model code for the ensemble integration are repeated here.31 For the analysis step of the ETKF, different operations related to the observations are needed. These operations are requested by PDAF by calling user-supplied routines. Intentionally, the operations are split into separate routines in order to keep the operations rather elementary. This procedure should simplify the implementation. The names of the required routines are specified in the call to the routine `PDAF_assimilate_etkf` (or `PDAF_put_state_etkf`) that was discussed before. With regard to the parallelization, all these routines are executed by the filter processes (`filterpe=.true.`) only. 32 33 For completeness we discuss here all user-supplied routines that are specified in the interface to PDAF_assimilate_etkf. Thus, some of the user-supplied routines that are explained on the page explaining the modification of the model code for the ensemble integration are repeated here. 34 34 35 35 The SEIK filter and the ETKF (Ensemble Transform Kalman Filter) are very similar. For this reason, the interface to the user-supplied routines is almost identical. Depending on the implementation it can be possible to use identical routines for the SEIK filter and the ETKF. Differences are marked in the text below. 36 36 37 == `PDAF_ put_state_etkf` ==38 39 The general espects of the filter specific routines `PDAF_ put_state_*` have been described on the page [ModifyModelforEnsembleIntegration Modification of the model code for the ensemble integration]. Here, we list once more the full interface. Subsequently, the full set of user-supplied routines specified in the call to `PDAF_put_state_etkf` is explained.37 == `PDAF_assimilate_etkf` == 38 39 The general espects of the filter specific routines `PDAF_assimilate_*` have been described on the page [ModifyModelforEnsembleIntegration Modification of the model code for the ensemble integration] and its sub-page on [InsertAnalysisStep inserting the analysis step]. The routine is used in the fully-parallel implementation variant of the data assimilation system. When the 'flexible' implementation variant is used, the routines `PDAF_put_state_*' is used as described further below. Here, we list once more the full interface. Subsequently, the full set of user-supplied routines specified in the call to `PDAF_assimilate_etkf` is explained. 40 40 41 41 The interface when using the ETKF method is the following: 42 42 {{{ 43 SUBROUTINE PDAF_put_state_etkf(U_collect_state, U_init_dim_obs, U_obs_op, & 44 U_init_obs, U_prepoststep, U_prodRinvA, U_init_obsvar, status) 43 SUBROUTINE PDAF_assimilate_etkf(U_collect_state, U_distribute_state, U_init_dim_obs, & 44 U_obs_op, U_init_obs, U_prepoststep, U_prodRinvA, & 45 U_init_obsvar, U_next_observation, status) 45 46 }}} 46 47 with the following arguments: 47 * [#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_distribute_state` used in `PDAF_get_state` 48 * [#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_distribute_state` used in `PDAF_get_state` as well as here. 49 * [#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. 48 50 * [#U_init_dim_obsinit_dim_obs_pdaf.F90 U_init_dim_obs]: The name of the user-supplied routine that provides the size of observation vector 49 51 * [#U_obs_opobs_op_pdaf.F90 U_obs_op]: The name of the user-supplied routine that acts as the observation operator on some state vector … … 52 54 * [#U_prodRinvAprodrinva_pdaf.F90 U_prodRinvA]: The name of the user-supplied routine that computes the product of the inverse of the observation error covariance matrix with some matrix provided to the routine by PDAF. This operation occurs during the analysis step of the ETKF. 53 55 * [#U_init_obsvarinit_obsvar_pdaf.F90 U_init_obsvar]: The name of the user-supplied routine that provides a mean observation error variance to PDAF (This routine will only be executed, if an adaptive forgetting factor is used) 54 * `status`: The integer status flag. It is zero, if `PDAF_put_state_etkf` is exited without errors. 56 * [#U_next_observationnext_observation.F90 U_next_observation]: The name of a user supplied routine that initializes the variables `nsteps`, `timenow`, and `doexit`. The same routine is also used in `PDAF_get_state`. 57 * `status`: The integer status flag. It is zero, if `PDAF_assimilate_etkf` is exited without errors. 58 59 60 == `PDAF_put_state_etkf` == 61 62 When the 'flexible' implementation variant is chosen for the assimilation system, the routine `PDAF_put_state_etkf` has to be used instead of `PDAF_assimilate_etkf`. The general aspects of the filter specific routines `PDAF_put_state_*` have been described on the page [ModifyModelforEnsembleIntegration Modification of the model code for the ensemble integration]. The interface of the routine is identical with that of `PDAF_assimilate_etkf` with the exception the specification of the user-supplied routines `U_distribute_state` and `U_next_observation` are missing. 63 64 The interface when using the ETKF method is the following: 65 {{{ 66 SUBROUTINE PDAF_put_state_etkf(U_collect_state, U_init_dim_obs, U_obs_op, & 67 U_init_obs, U_prepoststep, U_prodRinvA, U_init_obsvar, status) 68 }}} 55 69 56 70 57 71 == User-supplied routines == 58 72 59 Here, all user-supplied routines are described that are required in the call to `PDAF_ put_state_etkf`. For some of the generic routines, we link to the page on [ModifyModelforEnsembleIntegration modifying the model code for the ensemble integration].73 Here, all user-supplied routines are described that are required in the call to `PDAF_assimilate_etkf`. For some of the generic routines, we link to the page on [ModifyModelforEnsembleIntegration modifying the model code for the ensemble integration]. 60 74 61 75 To indicate user-supplied routines we use the prefix `U_`. In the template 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. … … 67 81 68 82 This routine is independent of the filter algorithm used. 69 See the page [ModifyModelforEnsembleIntegration#U_collect_statecollect_state.F90 modifying the model code for the ensemble integration] for the description of this routine. 83 See the page on [InsertAnalysisStep#U_collect_statecollect_state_pdaf.F90 inserting the analysis step] for the description of this routine. 84 85 86 === `U_distribute_state` (distribute_state_pdaf.F90) === 87 88 This routine is independent of the filter algorithm used. 89 See the page on [InsertAnalysisStep#U_distribute_statedistribute_state_pdaf.F90 inserting the analysis step] for the description of this routine. 70 90 71 91 … … 214 234 215 235 236 === `U_next_observation` (next_observation_pdaf.F90) === 237 238 This routine is independent of the filter algorithm used. 239 See the page on [InsertAnalysisStep#U_next_observationnext_observation_pdaf.F90 inserting the analysis step] for the description of this routine. 240 241 216 242 == Execution order of user-supplied routines == 217 243 218 For the ETKF, the user-supplied routines are essentially executed in the order they are listed in the interface to `PDAF_ put_state_etkf`. The order can be important as some routines can perform preparatory work for later routines. For example, `U_init_dim_obs` can prepare an index array that provides the information for executing the observation operator in `U_obs_op`.244 For the ETKF, the user-supplied routines are essentially executed in the order they are listed in the interface to `PDAF_assimilate_etkf`. The order can be important as some routines can perform preparatory work for later routines. For example, `U_init_dim_obs` can prepare an index array that provides the information for executing the observation operator in `U_obs_op`. 219 245 220 246 Before the analysis step is called, the following routine is executed: