Changes between Version 6 and Version 7 of ImplementAnalysislseik


Ignore:
Timestamp:
Sep 1, 2010, 4:45:37 PM (10 years ago)
Author:
lnerger
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ImplementAnalysislseik

    v6 v7  
    5050with the following arguments:
    5151 * `U_collect_state`: The name of the user-supplied routine that initializes a state vector from the array holding the ensembel of model states from the model fields. This is basically the inverse operation to `U_distribute_state` used in `PDAF_get_state`
    52  * `U_init_dim_obs_f`: The name of the user-supplied routine that provides the size of observation vector
    53  * `U_obs_op_f`: The name of the user-supplied routine that acts as the observation operator on some state vector
    54  * `U_init_obs_f`: The name of the user-supplied routine that initializes the vector of observations
     52 * `U_init_dim_obs_full`: The name of the user-supplied routine that provides the size of observation vector
     53 * `U_obs_op_full`: The name of the user-supplied routine that acts as the observation operator on some state vector
     54 * `U_init_obs_full`: The name of the user-supplied routine that initializes the vector of observations
    5555 * `U_init_obs_l`: The name of the user-supplied routine that initializes the vector of observations for a local analysis domain
    5656 * `U_prepoststep`: The name of the pre/poststep routine as in `PDAF_get_state`
     
    8383The interface for this routine is:
    8484{{{
    85 SUBROUTINE init_dim_obs_f(step, dim_obs_f)
     85SUBROUTINE init_dim_obs_full(step, dim_obs_f)
    8686
    8787  INTEGER, INTENT(in)  :: step       ! Current time step
     
    9090
    9191The routine is called at the beginning of each analysis step, before the loop over all local analysis domains is entered.  It has to initialize the size `dim_obs_f` of the full observation vector according to the current time step. For simplicity, `dim_obs_f` can be the size for the global model domain.
    92 When a domain-decomposed model is used, `dim_obs_f` will be the size of the observation vector for the sub-domain of the calling process plus .
    9392
    9493Some hints:
    95  * It can be useful if not only the size of the observation vector is determined at this point. One can also already gather information about the location of the observations, which will be used later, e.g. to implement the observation operator. An array for the locations can be defined in a module like `mod_assimilation`.
     94 * It can be useful to not only determine the size of the observation vector at this point. One can also already gather information about the location of the observations, which will be used later, e.g. to implement the observation operator. An array for the locations can be defined in a module like `mod_assimilation`.
     95 * The routine is similar to `init_dim_obs` used in the global filters. However, if the global filter is used with a domain-decomposed model, it only initializes the size of the observation vector for the local model sub-domain. This is different for the local filters, as the local analysis also requires observational data from neighboring model sub-domains. Anyway, one can base on an implemented routine `init_dim_obs` to implement `init_dim_obs_full`.
    9696
    97 == `U_obs_op` (obs_op.F90) ==
     97== `U_obs_op_full` (obs_op_full.F90) ==
    9898
    99 This routine is used by all global filter algorithms (SEEK, SEIK, EnKF, ETKF).
     99This routine is used by all local filter algorithms (LSEIK, LETKF).
    100100
    101101The interface for this routine is:
    102102{{{
    103 SUBROUTINE obs_op(step, dim_p, dim_obs_p, state_p, m_state_p)
    104 
     103SUBROUTINE obs_op_full(step, dim_p, dim_obs_f, state_p, m_state_f)
    105104  INTEGER, INTENT(in) :: step               ! Currrent time step
    106105  INTEGER, INTENT(in) :: dim_p              ! PE-local dimension of state
    107   INTEGER, INTENT(in) :: dim_obs_p          ! Dimension of observed state
     106  INTEGER, INTENT(in) :: dim_obs_f          ! Dimension of the full observed state
    108107  REAL, INTENT(in)    :: state_p(dim_p)     ! PE-local model state
    109   REAL, INTENT(out) :: m_state_p(dim_obs_p) ! PE-local observed state
     108  REAL, INTENT(out) :: m_state_f(dim_obs_f) ! Full observed state
    110109}}}
    111110
    112 The routine is called during the analysis step. It has to perform the operation of the observation operator acting on a state vector that is provided as `state_p`. The observed state has to be returned in `m_state_p`.
    113 
    114 For a model using domain decomposition, the operation is on the PE-local sub-domain of the model and has to provide the observed sub-state for the PE-local domain.
     111The routine is called during the analysis step, before the loop over the local analysis domain is entered. It has to perform the operation of the observation operator acting on a state vector that is provided as `state_p`. The observed state has to be returned in `m_state_f`. It is the observed state corresponding to the 'full' observation vector.
    115112
    116113Hint:
    117114 * If the observation operator involves a global operation, e.g. some global integration, while using domain-decompostion one has to gather the information from the other model domains using MPI communication.
     115 * Analogously to the situation with `init_dim_obs_full`, the routine is similar to `init_dim_obs` used for the global filters. However, with a domain-decompoared model also here `m_state_f` will contain parts of the state vector from neighboring model sub-domains. To make these parts accessible, some parallel communication will be necessary (The state information for a neighboring model sub-domain, will be in the memory of the process that handles that sub-domain). The example implementation in `testsuite/dummymodel_1d` uses the function `MPI_AllGatherV` for this communication.
    118116
    119 == `U_init_obs` (init_obs.F90) ==
     117== `U_init_obs_full` (init_obs_full.F90) ==
    120118
    121 This routine is used by all global filter algorithms (SEEK, SEIK, EnKF, ETKF).
     119This routine is used by all local filter algorithms (LSEIK, LETKF).
    122120
    123121The interface for this routine is:
    124122{{{
    125 SUBROUTINE init_obs(step, dim_obs_p, observation_p)
     123SUBROUTINE init_obs_full(step, dim_obs_f, observation_f)
    126124
    127125  INTEGER, INTENT(in) :: step             ! Current time step
    128   INTEGER, INTENT(in) :: dim_obs_p        ! PE-local dimension of obs. vector
    129   REAL, INTENT(out)   :: observation_p(dim_obs_p) ! PE-local observation vector
     126  INTEGER, INTENT(in) :: dim_obs_f        ! Dimension of full observation vector
     127  REAL, INTENT(out)   :: observation_f(dim_obs_f) ! Full observation vector
    130128}}}
    131129
    132 The routine is called during the analysis step.
    133 It has to provide the vector of observations in `observation_p` for the current time step.
     130The routine is called during the analysis step before the loop over the local analysis domains is entered.
     131It has to provide the full vector of observations in `observation_f` for the current time step.
    134132
    135 For a model using domain decomposition, the vector of observations that exist on the model sub-domain for the calling process has to be initialized.
    136 
     133Hints:
     134 * As for the other 'full' routines: While the global counterpart of this routine (`init_obs`) has to initialize the observation vector for the local model sub-domain, the 'full' routine has to include observations that spatially belong to neighboring model sub-domains. As an easy choice one can simply initialize a vector of all globally available observations.
    137135
    138136== `U_prodRinvA` (prodrinva.F90) ==