# add_obs_error_pdaf

The page document the user-supplied call-back routine `add_obs_error_pdaf`

.

The routine `add_obs_error_pdaf`

(called `U_add_obs_err`

inside the PDAF core routines) is a call-back routine that has to be provided by the user.
The routine is used by the EnKF and called during the filter analysis step. The purpose of the routine is to add the observation error covariance matrix to the input/output matrix `C`

. This matrix is the projection of the ensemble covariance matrix onto the observation space that is computed during the analysis step of the EnKF.

The interface is the following:

SUBROUTINE add_obs_error_pdaf(step, dim_obs, C)

with

`step`

:`integer, intent(in)`

Current time step`dim_obs`

:`integer, intent(in)`

Size of observation vector`C`

:`real, intent(inout), dimension(dim_obs,dim_obs)`

Matrix to which the observation error covariance matrix is added

The routine is called during the analysis step.

The operation is for the global observation space. Thus, it is independent of whether the filter is executed with or without parallelization.

Hints:

- The routine does not require that the observation error covariance matrix is added as a full matrix. If the matrix is diagonal, only the diagonal elements have to be added.