37 |
|
|
38 |
#include "SIZE.h" |
#include "SIZE.h" |
39 |
#include "EEPARAMS.h" |
#include "EEPARAMS.h" |
40 |
#include "EESUPPORT.h" |
c#include "EESUPPORT.h" |
41 |
#include "EXCH.h" |
c#include "EXCH.h" |
42 |
|
|
43 |
C !INPUT/OUTPUT PARAMETERS: |
C !INPUT/OUTPUT PARAMETERS: |
44 |
C == Argument list variables == |
C == Argument list variables == |
49 |
INTEGER myThid |
INTEGER myThid |
50 |
|
|
51 |
C !LOCAL VARIABLES: |
C !LOCAL VARIABLES: |
52 |
|
#ifndef ALLOW_EXCH2 |
53 |
C == Local variables == |
C == Local variables == |
54 |
C i,j,k,bi,bj :: are DO indices. |
C i,j,k,bi,bj :: are DO indices. |
55 |
C OL[wens] :: Overlap extents in west, east, north, south. |
C OL[wens] :: Overlap extents in west, east, north, south. |
61 |
_RX dummy1(1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
_RX dummy1(1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
62 |
_RX dummy2(1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
_RX dummy2(1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
63 |
_RX negOne |
_RX negOne |
64 |
|
#endif |
65 |
|
CEOP |
66 |
|
|
67 |
#ifdef ALLOW_EXCH2 |
#ifdef ALLOW_EXCH2 |
68 |
CALL EXCH2_UV_AGRID_3D_RX( |
CALL EXCH2_UV_AGRID_3D_RX( |
69 |
U Uphi, Vphi, |
U Uphi, Vphi, |
70 |
I withSigns, myNz, myThid ) |
I withSigns, myNz, myThid ) |
71 |
RETURN |
RETURN |
72 |
#endif |
#else /* ALLOW_EXCH2 */ |
73 |
|
|
74 |
OLw = OLx |
OLw = OLx |
75 |
OLe = OLx |
OLe = OLx |
86 |
|
|
87 |
C First call the exchanges for the two components |
C First call the exchanges for the two components |
88 |
|
|
|
#ifndef AUTODIFF_EXCH2 |
|
89 |
CALL EXCH_RX_CUBE( Uphi, |
CALL EXCH_RX_CUBE( Uphi, |
90 |
I OLw, OLe, OLs, OLn, myNz, |
I OLw, OLe, OLs, OLn, myNz, |
91 |
I exchWidthX, exchWidthY, |
I exchWidthX, exchWidthY, |
94 |
I OLw, OLe, OLs, OLn, myNz, |
I OLw, OLe, OLs, OLn, myNz, |
95 |
I exchWidthX, exchWidthY, |
I exchWidthX, exchWidthY, |
96 |
I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid ) |
I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid ) |
|
#endif |
|
97 |
|
|
98 |
C Then if we are on the sphere we may need to switch u and v components |
C Then if we are on the sphere we may need to switch u and v components |
99 |
C and/or the signs depending on which cube face we are located. |
C and/or the signs depending on which cube face we are located. |
173 |
ELSE |
ELSE |
174 |
C--- not using CubedSphereExchange: |
C--- not using CubedSphereExchange: |
175 |
|
|
|
#ifndef AUTODIFF_EXCH2 |
|
176 |
CALL EXCH_RX( Uphi, |
CALL EXCH_RX( Uphi, |
177 |
I OLw, OLe, OLs, OLn, myNz, |
I OLw, OLe, OLs, OLn, myNz, |
178 |
I exchWidthX, exchWidthY, |
I exchWidthX, exchWidthY, |
181 |
I OLw, OLe, OLs, OLn, myNz, |
I OLw, OLe, OLs, OLn, myNz, |
182 |
I exchWidthX, exchWidthY, |
I exchWidthX, exchWidthY, |
183 |
I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid ) |
I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid ) |
|
#endif |
|
184 |
|
|
185 |
C--- using or not using CubedSphereExchange: end |
C--- using or not using CubedSphereExchange: end |
186 |
ENDIF |
ENDIF |
187 |
|
|
|
|
|
188 |
RETURN |
RETURN |
189 |
|
#endif /* ALLOW_EXCH2 */ |
190 |
END |
END |
191 |
|
|
192 |
C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| |
C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| |