New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
find_obs_proc.h90 in NEMO/branches/2019/dev_ASINTER-01-05_merged/src/OCE/OBS – NEMO

source: NEMO/branches/2019/dev_ASINTER-01-05_merged/src/OCE/OBS/find_obs_proc.h90 @ 12165

Last change on this file since 12165 was 10068, checked in by nicolasmartin, 6 years ago

First part of modifications to have a common default header : fix typos and SVN keywords properties

  • Property svn:keywords set to Id
  • Property svn:mime-type set to text/x-fortran
File size: 2.4 KB
Line 
1   !!----------------------------------------------------------------------
2   !! NEMO/OCE 4.0 , NEMO Consortium (2018)
3   !! $Id$
4   !! Software governed by the CeCILL license (see ./LICENSE)
5   !!----------------------------------------------------------------------
6
7   SUBROUTINE find_obs_proc(kldi,klei,kldj,klej,kmyproc,kobsp,kobsi,kobsj,kno)
8      !!----------------------------------------------------------------------
9      !!               ***  ROUTINE find_obs_proc ***
10      !!         
11      !! ** Purpose : From the array kobsp containing the results of the grid
12      !!              grid search on each processor the processor return a
13      !!              decision of which processors should hold the observation.
14      !!
15      !! ** Method : Use i and j and halo regions to decide which processor to
16      !!             put ob in. Intended to avoid the mpp calls required by
17      !!             obs_mpp_find_obs_proc
18      !!
19      !! History :
20      !!! 03-08  (D. Lea)  Original code
21      !!-----------------------------------------------------------------------
22
23      !! * Arguments
24
25      INTEGER, INTENT(IN) :: kldi               ! Start of inner domain in i
26      INTEGER, INTENT(IN) :: klei               ! End of inner domain in i
27      INTEGER, INTENT(IN) :: kldj               ! Start of inner domain in j
28      INTEGER, INTENT(IN) :: klej               ! End of inner domain in j
29
30      INTEGER, INTENT(IN) :: kmyproc
31      INTEGER, INTENT(IN) :: kno
32
33      INTEGER, DIMENSION(kno), INTENT(IN) :: kobsi
34      INTEGER, DIMENSION(kno), INTENT(IN) :: kobsj
35      INTEGER, DIMENSION(kno), INTENT(INOUT) :: kobsp
36     
37      !! * local variables
38      INTEGER :: &
39         & ji
40         
41      ! first and last indoor i- and j-indexes      kldi, klei,   kldj, klej
42      ! exclude any obs in the bottom-left overlap region
43      ! also any obs outside to whole region (defined by nlci and nlcj)
44      ! I am assuming that kobsp does not need to be the correct processor
45      ! number
46     
47      DO ji = 1, kno
48         IF (kobsi(ji) < kldi .OR. kobsj(ji) < kldj &
49            .OR. kobsi(ji) > klei  .OR. kobsj(ji) > klej) THEN
50            IF (lwp .AND. kobsp(ji) /= -1) WRITE(numout,*) &
51               & 'kobs: ',kobsi(ji), kobsj(ji), kobsp(ji)
52            kobsp(ji)=1000000
53         ENDIF
54      END DO
55
56      ! Ensure that observations not in processor are masked
57
58      WHERE(kobsp(:) /= kmyproc) kobsp(:)=1000000
59
60   END SUBROUTINE find_obs_proc
Note: See TracBrowser for help on using the repository browser.