Version 38 (modified by 12 days ago) ( diff ) | ,
---|
Online Mode: Implementation Guide
Online Mode: Implementation Guide
We recommend to check first the PDAF Tutorials, which provide an easy step-by-step description for assimilation program in the offline and oneline modes utilizing example tutorial codes. The Implementation Guide provides more details, e.g. descriptions of the defined interfaces, but is less applied. |
This page contains the implementation guide for the online mode of PDAF in which PDAF is attached to the numerical model. For the offline mode, in which separate programs for model integrations and assimilation step are executed, see the Implementation Guide for the Offline Mode. The differences between the online and offline modes is described on the page on the Implementation concept of PDAF.
Note: This Implementation Guide explains the implementation as of PDAF V3. The recommendations differ from those for PDAF 2. For reference, for implementations that were done for PDAF 2, the Implementation Guide for PDAF 2 is still available. |
The implementation of PDAF with an existing model
For the online-mode of data assimilation, the numerical model has to be combined with PDAF into a single program to generate the assimilation system. This is done by adding several function calls into the model code. The implementation of PDAF with an existing model can be performed in a few steps. A possible sequence is the following:
- Adaptation of the parallelization
- Initialization of PDAF and the ensemble by PDAF_init
- Modification of the model code for the ensemble integration
- Implementation of the analysis step
- Adding memory and timing information
In Steps 1 to 3, PDAF is attached to the numerical model to allow it to perform ensemble integrations. Step 4 completes the data assimilation program with the analysis step. Finally, step 5 is optional to obtain information on the computing time and required memory.
The implementation steps are described on the pages linked above. Examples of the implementation are given in tutorial code provided with PDAF in tutorial/online_2D_serialmodel/
and tutorial/online_2D_parallelmodel/
. (The tutorial also provides detail explanations of the implementation steps).
Several subroutines that contain specific operations for the model and observations are called as call-back routines by PDAF. For this, PDAF defines interfaces for all routines. These routines need to be implemented by the user. The operations in all these routines are rather elementary like the initialization of the model's physical fields from a state vector provided by PDAF and the initialization of the vector of observations. The examples mentioned above also include example implementations for these routines. In addition, the directory templates/
contains template implementations of the routines that can be used as a basis for new implementations.
An overview of the available options for each filter that can be specified when PDAF is initialized is given on the overview page on options.
Generating initial ensembles
To perform ensemble data assimilation one has to create an initial ensemble which is then used in the data assimilation process. There are various different ways to generate an ensemble (like random picking of model states, breeding, short-term integrations of perturbed model fields, second-order exact sampling from EOFs). PDAF provides routines to use snapshots from a model integration to first compute EOFs (empirical orthogonal functions) and then to use the EOFs to perform a constrained random transformation to obtain ensemble perturbations to which a central state (i.e. ensemble mean) is added. This second-order exact sampling (Pham, 2001) showed good performance in our own data assimilation applications.
The ensemble generation is described on the separate page: