Version 1 (modified by 3 weeks ago) (diff) | ,
---|

# PDAFlocal_set_increment_weights

This page documents the routine `PDAFlocal_set_increment_weights`

of PDAF, which is used with the PDAFlocal? interface. This routine was introduced with PDAF V2.3.

This routine provides the optional functionality to prescribe the assimilation increment of each element of the local state vector a different weight. This can be used, e.g. to implement a vertical localization in the case that the local state vector is a full vertical column of the model grid. In this case, one can make the increment weight depending on the height (or depth) of a grid point. Another application is to implement weakly-coupled assimilation in which the local state vector contains all variables, but only a subset of them is updated. This is achieved by givening those element that should not be updated the weight 0.

The routine can be called in `init_dim_l_pdaf`

when the dimension of the local state vector has to be determined. In addition to this dimension, the implementation guide recommends to also initialize the coordinates of the local analysis domain and the indices of the elements ofthe local state vector in the non-localized (global or domain-decomposed) state vector `state_p`

. In addition one can initialize a vector of increment weights and provide it to PDAFlocal by calling this routine.

The interface is:

SUBROUTINE PDAFlocal_set_increment_weights(dim_l, weights) INTEGER, INTENT(in) :: dim_l ! Dimension of local state vector REAL, INTENT(in) :: weights(dim_l) ! Weights array

Hints:

- The loop to initialize
`weights`

can be analogous to the loop that initialize the index array for mapping between the global and local state vector (see PDAFlocal_set_indices. - It is possible to clear the weights array by calling PDAFlocal_clear_increment_weights. Afterwards, unit weights are used.