Changes between Version 2 and Version 3 of OMI_search_local_observations
- Timestamp:
- Sep 8, 2024, 7:39:41 PM (5 weeks ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
OMI_search_local_observations
v2 v3 44 44 ... Initialize local observation arrays ... 45 45 46 thisobs_l%id_obs_l(cnt_ obs_l) = i ! index of local obs. in full obs. vector47 thisobs_l%distance_l(cnt_ obs_l) = SQRT(distance2) ! distance48 thisobs_l%cradius_l(cnt_ obs_l) = thisobs_l%cradius(1) ! cut-off radius49 thisobs_l%sradius_l(cnt_ obs_l) = thisobs_l%sradius(1) ! support radius46 thisobs_l%id_obs_l(cnt_l) = i ! index of local obs. in full obs. vector 47 thisobs_l%distance_l(cnt_l) = SQRT(distance2) ! distance 48 thisobs_l%cradius_l(cnt_l) = thisobs_l%cradius(1) ! cut-off radius 49 thisobs_l%sradius_l(cnt_l) = thisobs_l%sradius(1) ! support radius 50 50 51 51 ENDIF … … 54 54 **Notes:** 55 55 * The check `thisobs%doassim==1` is mandatory because init_dim_obs_l_OBSTYPE is called for all observations. 56 * `cnt_ obs_l` is the counter of the valid local observations inside the loop, while `i` is the index of a local observation on the full observation vector56 * `cnt_l` is the counter of the valid local observations inside the loop, while `i` is the index of a local observation on the full observation vector 57 57 * The initialization of the local observation arrays of `thisobs_l` can be done by the routine `PDAFomi_store_obs_l_index` provided by PDAF-OMI (see below). However, in our tests this always led to a slower program. Thus, for performance reasons we recommend to use the direct initialization if possible. 58 58 * In the tutorial example routine we use a module to enclose the user routine. This allows for syntax checking, but is not mandatory. … … 108 108 === PDAFomi_store_obs_l_index === 109 109 110 This routine takes the index 'cnt_ obs_l' in the example above (`idx` below), the distance as well as the local cut-off radius (`cradius_l`) and support radius (`sradius_l`) and stores the values in the vectors of `thisobs_l`.110 This routine takes the index 'cnt_l' in the example above, the distance as well as the local cut-off radius (`cradius_l`) and support radius (`sradius_l`) and stores the values in the vectors of `thisobs_l`. 111 111 112 112 {{{ 113 SUBROUTINE PDAFomi_store_obs_l_index(thisobs_l, idx, id_obs_l, distance, &113 SUBROUTINE PDAFomi_store_obs_l_index(thisobs_l, cnt_l, id_obs_l, distance, & 114 114 cradius_l, sradius_l) 115 115 116 116 TYPE(obs_l), INTENT(inout) :: thisobs_l ! Data type with local observation 117 INTEGER, INTENT(in) :: idx! Element of local observation array to be filled117 INTEGER, INTENT(in) :: cnt_l ! Element of local observation array to be filled 118 118 INTEGER, INTENT(in) :: id_obs_l ! Index of local observation in full observation array 119 119 REAL, INTENT(in) :: distance ! Distance between local analysis domain and observation … … 129 129 130 130 {{{ 131 SUBROUTINE PDAFomi_store_obs_l_index_vdist(thisobs_l, idx, id_obs_l, distance, &131 SUBROUTINE PDAFomi_store_obs_l_index_vdist(thisobs_l, cnt_l, id_obs_l, distance, & 132 132 cradius_l, sradius_l, vdist) 133 133 134 134 TYPE(obs_l), INTENT(inout) :: thisobs_l ! Data type with local observation 135 INTEGER, INTENT(in) :: idx! Element of local observation array to be filled135 INTEGER, INTENT(in) :: cnt_l ! Element of local observation array to be filled 136 136 INTEGER, INTENT(in) :: id_obs_l ! Index of local observation in full observation array 137 137 REAL, INTENT(in) :: distance ! Distance between local analysis domain and observation