Changes between Version 1 and Version 2 of OMI_observation_operators


Ignore:
Timestamp:
Nov 23, 2020, 4:57:08 PM (3 years ago)
Author:
lnerger
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • OMI_observation_operators

    v1 v2  
    3232An example of initializing interpolation coefficients with PDAFomi_get_interp_coeff_lin and of using PDAFomi_obs_op_interp_lin is provided in `tutorial/online_2D_serialmodel_omi/obs_C_pdafomi.F90`.
    3333
     34
    3435=== PDAFomi_get_interp_coeff_lin ===
    35  
     36
     37This routine computes interpolation coefficients for a rectangular grid in 1, 2, or 3 dimensions.
    3638
    3739The call to this routine is
     
    3941  CALL PDAFomi_get_interp_coeff_lin(num_gp, n_dim, gcoords, ocoord, icoeff)
    4042
    41     INTEGER, INTENT(in) :: num_gp         !< Length of thisobs%icoeff_p(:,i)
    42     INTEGER, INTENT(in) :: n_dim          !< Number of dimensions in interpolation
    43     REAL, INTENT(in)    :: gcoords(:,:)   !< Coordinates of grid points
    44     REAL, INTENT(in)    :: ocoord(:)      !< Coordinates of observation (one column ocoord_p(:,i))
    45     REAL, INTENT(inout) :: icoeff(:)      !< Interpolation coefficients (one column thisobs%icoeff_p(:,i))
     43    INTEGER, INTENT(in) :: num_gp         ! Length of thisobs%icoeff_p(:,i)
     44    INTEGER, INTENT(in) :: n_dim          ! Number of dimensions in interpolation
     45    REAL, INTENT(in)    :: gcoords(:,:)   ! Coordinates of grid points
     46    REAL, INTENT(in)    :: ocoord(:)      ! Coordinates of observation (one column ocoord_p(:,i))
     47    REAL, INTENT(inout) :: icoeff(:)      ! Interpolation coefficients (one column thisobs%icoeff_p(:,i))
    4648
    4749}}}
    4850Here it is required that num_gp=2 for n_dim=1; num_gp=4 for n_dim=2; num_gp=8 for n_dim=3.
    4951
    50 In the array `gcoords` in init_dim_obs_TYPE, the first index specifies the grid point while the second specifies the coordinate, thus gcoords(j,:) is the list of coordinates for grid point j. The coordinates need to be consistent with the indices specified in `thisobs%id_obs_p` since these specify the elements of the state vector that are interpolated. Only the first `n_dim` entries of ocoord will be used for the interpolation.
     52In the array `gcoords`, the first index specifies the grid point while the second specifies the coordinate, thus `gcoords(j,:)` is the list of coordinates for grid point j. The coordinates need to be consistent with the indices specified in `thisobs%id_obs_p` since these specify the elements of the state vector that are interpolated. Only the first `n_dim` entries of ocoord will be used for the interpolation.
    5153
    52 `ocoord_p(:,i)` holds the list of the coordinates for the observation with index i.
     54`ocoord_p(:,i)` holds the list of the coordinates for the observation with index i
    5355
    5456The order of the coordinates and coefficients is the following:
     
    7375
    7476
     77=== PDAFomi_get_interp_coeff_lin1D ===
     78
     79This routine is a simplified variant of `PDAFomi_get_interp_coeff_lin`. It computes interpolation coefficients in 1 dimension only
     80
     81The call to this routine is
     82{{{
     83  CALL PDAFomi_get_interp_coeff_lin1D(gcoords, ocoord, icoeff)
     84
     85    REAL, INTENT(in)    :: gcoords(:)  ! Coordinates of grid points; dim=2
     86    REAL, INTENT(in)    :: ocoord      ! Coordinates of observation
     87    REAL, INTENT(inout) :: icoeff(:)   ! Interpolation coefficients; dim=2
     88}}}
     89
     90
     91
     92=== PDAFomi_get_interp_coeff_tri ===
     93
     94For triangular model grid interpolation coefficients are determined as barycentric coordinates. This is performed in this routine.
     95
     96The call to this routine is
     97{{{
     98  CALL PDAFomi_get_interp_coeff_tri(gcoords, ocoord, icoeff)
     99
     100    REAL, INTENT(in)    :: gcoords(:)      ! Coordinates of grid points; dim=(3,2)
     101    REAL, INTENT(in)    :: ocoord(:)       ! Coordinates of observation; dim=2
     102    REAL, INTENT(inout) :: icoeff(:)       ! Interpolation coefficients; dim=3
     103}}}
     104
     105'''Notes:'''
     106 - In the array `gcoords`, the first index specifies the grid point while the second specifies the coordinate, thus `gcoords(j,:)` is the list of coordinates for grid point j.
     107 - The order of the grid points in `gcoords` has to be consistent with the order of the indices specified in `thisobs%id_obs_p`
     108
     109I