/[MITgcm]/MITgcm/eesupp/src/exch_uv_bgrid_3d_rx.template
ViewVC logotype

Annotation of /MITgcm/eesupp/src/exch_uv_bgrid_3d_rx.template

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Sat Feb 14 23:29:50 2009 UTC (15 years, 4 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint62, checkpoint62c, checkpoint62b, checkpoint62a, checkpoint62f, checkpoint62e, checkpoint62d, checkpoint61n, checkpoint61o, checkpoint61l, checkpoint61m, checkpoint61j, checkpoint61k, checkpoint61v, checkpoint61w, checkpoint61t, checkpoint61u, checkpoint61r, checkpoint61s, checkpoint61p, checkpoint61q, checkpoint61z, checkpoint61x, checkpoint61y
add a non-MPI Cube EXCH for B-grid vector (similar to EXCH_Z_CUBE for scalar)

1 jmc 1.1 C $Header: /u/gcmpack/MITgcm/eesupp/src/exch_uv_dgrid_3d_rx.template,v 1.1 2007/08/17 18:34:40 jmc Exp $
2     C $Name: $
3    
4     #include "PACKAGES_CONFIG.h"
5     #include "CPP_EEOPTIONS.h"
6    
7     CBOP
8     C !ROUTINE: EXCH_UV_BGRID_3D_RX
9    
10     C !INTERFACE:
11     SUBROUTINE EXCH_UV_BGRID_3D_RX(
12     U uPhi, vPhi,
13     I withSigns, myNz, myThid )
14    
15     C !DESCRIPTION:
16     C*=====================================================================*
17     C Purpose: SUBROUTINE EXCH_UV_BGRID_3D_RX
18     C handle exchanges for a 3D vector field on an B-grid.
19     C
20     C Input:
21     C uPhi(lon,lat,levs,bi,bj) :: first component of vector
22     C vPhi(lon,lat,levs,bi,bj) :: second component of vector
23     C withSigns (logical) :: true to use sign of components
24     C myNz :: 3rd dimension of input arrays uPhi,vPhi
25     C myThid :: my Thread Id number
26     C
27     C Output: uPhi and vPhi are updated (halo regions filled)
28     C
29     C Branch to appropriate exchange routine for B-grid vector field
30     C*=====================================================================*
31    
32     C !USES:
33     IMPLICIT NONE
34    
35     #include "SIZE.h"
36     #include "EEPARAMS.h"
37    
38     C !INPUT/OUTPUT PARAMETERS:
39     C == Argument list variables ==
40     INTEGER myNz
41     _RX uPhi(1-OLx:sNx+OLx,1-OLy:sNy+OLy,myNz,nSx,nSy)
42     _RX vPhi(1-OLx:sNx+OLx,1-OLy:sNy+OLy,myNz,nSx,nSy)
43     LOGICAL withSigns
44     INTEGER myThid
45    
46     C !LOCAL VARIABLES:
47     #ifndef ALLOW_EXCH2
48     C == Local variables ==
49     C OL[wens] :: Overlap extents in west, east, north, south.
50     C exchWidth[XY] :: Extent of regions that will be exchanged.
51    
52     INTEGER OLw, OLe, OLn, OLs, exchWidthX, exchWidthY
53     #endif
54     CEOP
55    
56     #ifdef ALLOW_EXCH2
57     CALL EXCH2_UV_BGRID_3D_RX(
58     U uPhi, vPhi,
59     I withSigns, myNz, myThid )
60     RETURN
61     #else /* ALLOW_EXCH2 */
62     OLw = OLx
63     OLe = OLx
64     OLn = OLy
65     OLs = OLy
66     exchWidthX = OLx
67     exchWidthY = OLy
68    
69     IF ( useCubedSphereExchange ) THEN
70     C--- using CubedSphereExchange:
71    
72     CALL EXCH_BG_RX_CUBE(
73     U uPhi, vPhi,
74     I withSigns,
75     I OLw, OLe, OLs, OLn, myNz,
76     I exchWidthX, exchWidthY,
77     I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid )
78    
79     ELSE
80     C--- not using CubedSphereExchange:
81    
82     CALL EXCH_RX( uPhi,
83     I OLw, OLe, OLs, OLn, myNz,
84     I exchWidthX, exchWidthY,
85     I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid )
86     CALL EXCH_RX( vPhi,
87     I OLw, OLe, OLs, OLn, myNz,
88     I exchWidthX, exchWidthY,
89     I FORWARD_SIMULATION, EXCH_UPDATE_CORNERS, myThid )
90    
91     C--- using or not using CubedSphereExchange: end
92     ENDIF
93    
94     RETURN
95     #endif /* ALLOW_EXCH2 */
96     END
97    
98     C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
99    
100     CEH3 ;;; Local Variables: ***
101     CEH3 ;;; mode:fortran ***
102     CEH3 ;;; End: ***

  ViewVC Help
Powered by ViewVC 1.1.22