1 |
C $Header: /u/gcmpack/MITgcm/pkg/ptracers/ptracers_fields_blocking_exchanges.F,v 1.11 2011/04/28 23:19:59 jmc Exp $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "PTRACERS_OPTIONS.h" |
5 |
#include "GAD_OPTIONS.h" |
6 |
|
7 |
CBOP |
8 |
C !ROUTINE: PTRACERS_FIELDS_BLOCKING_EXCH |
9 |
|
10 |
C !INTERFACE: ========================================================== |
11 |
SUBROUTINE PTRACERS_FIELDS_BLOCKING_EXCH( myThid ) |
12 |
|
13 |
C !DESCRIPTION: |
14 |
C Exchange data to update overlaps for passive tracers |
15 |
|
16 |
C !USES: =============================================================== |
17 |
#include "PTRACERS_MOD.h" |
18 |
IMPLICIT NONE |
19 |
#include "SIZE.h" |
20 |
#include "EEPARAMS.h" |
21 |
#include "PARAMS.h" |
22 |
#include "PTRACERS_SIZE.h" |
23 |
#include "PTRACERS_PARAMS.h" |
24 |
#include "PTRACERS_START.h" |
25 |
#include "PTRACERS_FIELDS.h" |
26 |
|
27 |
C !INPUT PARAMETERS: =================================================== |
28 |
C myThid :: thread number |
29 |
INTEGER myThid |
30 |
|
31 |
C !OUTPUT PARAMETERS: ================================================== |
32 |
C none |
33 |
|
34 |
#ifdef ALLOW_PTRACERS |
35 |
|
36 |
C !LOCAL VARIABLES: ==================================================== |
37 |
C iTracer :: loop indices |
38 |
C bi, bj :: tile indices |
39 |
INTEGER iTracer |
40 |
#ifdef ALLOW_OBCS |
41 |
c INTEGER bi, bj |
42 |
#endif /* ALLOW_OBCS */ |
43 |
CEOP |
44 |
|
45 |
C Loop over passive tracers |
46 |
DO iTracer=1,PTRACERS_numInUse |
47 |
IF ( PTRACERS_StepFwd(iTracer) ) THEN |
48 |
|
49 |
C Exchange overlaps |
50 |
CALL EXCH_3D_RL( pTracer(1-OLx,1-OLy,1,1,1,iTracer), |
51 |
& Nr, myThid ) |
52 |
#ifdef PTRACERS_ALLOW_DYN_STATE |
53 |
IF ( PTRACERS_SOM_Advection(iTracer) ) THEN |
54 |
CALL GAD_EXCH_SOM( _Ptracers_som(:,:,:,:,:,:,iTracer), |
55 |
& Nr, myThid ) |
56 |
ENDIF |
57 |
#endif /* PTRACERS_ALLOW_DYN_STATE */ |
58 |
|
59 |
C End of tracer loop |
60 |
ENDIF |
61 |
ENDDO |
62 |
|
63 |
#endif /* ALLOW_PTRACERS */ |
64 |
|
65 |
RETURN |
66 |
END |