Changes between Version 1 and Version 2 of OMI_Callback_obs_pdafomi


Ignore:
Timestamp:
Nov 16, 2020, 6:12:46 PM (4 years ago)
Author:
lnerger
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • OMI_Callback_obs_pdafomi

    v1 v2  
    1 = PDAF-OMI: The routine callback_obs_pdafomi.F90 =
     1= PDAF-OMI: The file callback_obs_pdafomi.F90 =
    22
     3[[PageOutline(2-3,Contents of this page)]]
     4
     5The file `callback_obs_pdafomi.F90` contains are those routines that are directly called by PDAF as call-back routines. In the example codes we use all routines with the suffix _pdafomi to distinguish them from routine from existing implementation where the suffix is typically _pdaf.
     6
     7The file `templates/omi/callback_obs_pdafomi.F90` provides a template for implementing the routines. A compact example canbe found in `tutorial/online_2D_serialmodel_omi/`.
     8
     9As mentioned in the OMI introduction, the routines are mainly pass-through routines. Thus, one typically includes the observation-specific routine with ‘use’ and then calls this routine. However, the is small additional functionality in the different routines which has to be handles when implementing the routine or adding an observation type
     10
     11== init_dim_obs_pdafomi ==
     12
     13  In this routine we declare a dimension variable `dim_obs_TYPE` for each observation type. This is initialized by the corresponding routine init_dim_obs_f_TYPE. The sum of these individual dimension yields the total number of observations, which is returned to PDAF.
     14
     15The implementation steps are:
     161. Include the observation-specific routine `init_dim_obs_TYPE` and the variable `assim_TYPE` from the observation-module with 'use'
     171. Declare a dimension variable `dim_obs_TYPE` and initialize it to 0
     181. Add a call to the observation-specific routine init_dim_obs_TYPE with the condition `IF (assim_TYPE)`
     191. add `dim_obs_TYPE` to the final sum computing `dim_obs`.
     20
     21Notes:
     22 - The variable `assim_TYPE` indicates whether a particular observation type is assimilated.
     23 - The observation-module can have either a specific name for `init_dim_obs_TYPE` or a generic name. If the generic name `init_dim_obs` is used one can apply a name conversion `init_dim_obs_TYPE => init_dim_obs`.
     24
     25
     26
     27== obs_op_pdafomi ==
     28
     29 In this routine one has to use the offset variable `offset_obs`. It is initialized to zero and then used as an argument in each call to the observation-specific obs_op_TYPE routine. This offset defines the order in which the observations are treated in the full observation vector.
     30
     31The implementation steps are:
     321. Include the observation-specific routine `obs_op_TYPE` from the observation-module with 'use'
     331. Ensure that the integer variable `offset_obs` is declared and initialized to 0
     341. Add a call to the observation-specific routine obs_op_TYPE
     35
     36Notes:
     37 - The order of the calls to `obs_op_TYPE` determine how the different observations are ordered in the full observation vector containing all observation types.
     38
     39
     40== init_dim_obs_l_pdafomi ==
     41
     42  In this routine two offset variables `offset_obs_f` and `offset_obs_l` are used to ensure a consistent order of the calls.
     43
     44The implementation steps are:
     451. Include the observation-specific routine `init_dim_obs_l_TYPE` from the observation-module with 'use'
     461. Ensure that the integer variables `offset_obs` and `offset_obs_l` are declared and initialized to 0
     471. Add a call to the observation-specific routine init_dim_obs_l_TYPE
     48
     49== deallocate_obs_pdafomi ==
     50
     51The file callback_obs_pdafomi.F90 also contains a routine deallocate_obs_pdafomi. Each obs-module allocates arrays in the observation type zobs_f` and `deallocate_obs_pdafomi` is used to deallocate the different observation-specific arrays after the analysis step.
     52
     53The implementation steps are:
     541. Include the observation-specific type `thisobs` from the observation-module with 'use' apply a name conversion like `obs_TYPE => thisobs`
     551. add a call to `PDAFomi_deallocate_obs` giving the observation-specific `obs_TYPE` as argument.
     561. To perform the deallocation, insert a call to deallocate_obs_pdafomi at the end of the routine `prepoststep_pdaf`.