1 |
|
C $Header$ |
2 |
|
C !DESCRIPTION: \bv |
3 |
|
C $Name$ |
4 |
|
|
5 |
|
#include "PACKAGES_CONFIG.h" |
6 |
#include "CPP_OPTIONS.h" |
#include "CPP_OPTIONS.h" |
7 |
|
|
8 |
|
CBOP |
9 |
|
C !ROUTINE: CALC_GW |
10 |
|
C !INTERFACE: |
11 |
SUBROUTINE CALC_GW( |
SUBROUTINE CALC_GW( |
12 |
I myThid) |
I myThid) |
13 |
C /==========================================================\ |
C !DESCRIPTION: \bv |
14 |
C | S/R CALC_GW | |
C *==========================================================* |
15 |
C \==========================================================/ |
C | S/R CALC_GW |
16 |
IMPLICIT NONE |
C | o Calculate vert. velocity tendency terms ( NH, QH only ) |
17 |
|
C *==========================================================* |
18 |
|
C | In NH and QH, the vertical momentum tendency must be |
19 |
|
C | calculated explicitly and included as a source term |
20 |
|
C | for a 3d pressure eqn. Calculate that term here. |
21 |
|
C | This routine is not used in HYD calculations. |
22 |
|
C *==========================================================* |
23 |
|
C \ev |
24 |
|
|
25 |
|
C !USES: |
26 |
|
IMPLICIT NONE |
27 |
C == Global variables == |
C == Global variables == |
28 |
#include "SIZE.h" |
#include "SIZE.h" |
29 |
#include "DYNVARS.h" |
#include "DYNVARS.h" |
31 |
#include "EEPARAMS.h" |
#include "EEPARAMS.h" |
32 |
#include "PARAMS.h" |
#include "PARAMS.h" |
33 |
#include "GRID.h" |
#include "GRID.h" |
|
#include "CG2D.h" |
|
34 |
#include "GW.h" |
#include "GW.h" |
35 |
#include "CG3D.h" |
#include "CG3D.h" |
36 |
|
|
37 |
|
C !INPUT/OUTPUT PARAMETERS: |
38 |
C == Routine arguments == |
C == Routine arguments == |
39 |
C myThid - Instance number for this innvocation of CALC_GW |
C myThid - Instance number for this innvocation of CALC_GW |
40 |
INTEGER myThid |
INTEGER myThid |
41 |
|
|
42 |
#ifdef ALLOW_NONHYDROSTATIC |
#ifdef ALLOW_NONHYDROSTATIC |
43 |
|
|
44 |
|
C !LOCAL VARIABLES: |
45 |
C == Local variables == |
C == Local variables == |
46 |
|
C bi, bj, :: Loop counters |
47 |
|
C iMin, iMax, |
48 |
|
C jMin, jMax |
49 |
|
C flx_NS :: Temp. used for fVol meridional terms. |
50 |
|
C flx_EW :: Temp. used for fVol zonal terms. |
51 |
|
C flx_Up :: Temp. used for fVol vertical terms. |
52 |
|
C flx_Dn :: Temp. used for fVol vertical terms. |
53 |
INTEGER bi,bj,iMin,iMax,jMin,jMax |
INTEGER bi,bj,iMin,iMax,jMin,jMax |
|
_RL aF (1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
_RL vF (1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
_RL v4F(1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
_RL cF (1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
_RL mT (1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
_RL pF (1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
_RL fZon (1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
_RL fMer (1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
|
|
|
|
54 |
_RL flx_NS(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) |
_RL flx_NS(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) |
55 |
_RL flx_EW(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) |
_RL flx_EW(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) |
56 |
_RL flx_Dn(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) |
_RL flx_Dn(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy) |
70 |
#define In sNx |
#define In sNx |
71 |
#define J0 1 |
#define J0 1 |
72 |
#define Jn sNy |
#define Jn sNy |
73 |
|
CEOP |
74 |
|
|
75 |
|
ceh3 needs an IF ( useNONHYDROSTATIC ) THEN |
76 |
|
|
77 |
C Adams-Bashforth timestepping weights |
C Adams-Bashforth timestepping weights |
78 |
ab15=1.5+abeps |
ab15=1.5+abeps |
83 |
DO K=1,Nr |
DO K=1,Nr |
84 |
DO j=1-OLy,sNy+OLy |
DO j=1-OLy,sNy+OLy |
85 |
DO i=1-OLx,sNx+OLx |
DO i=1-OLx,sNx+OLx |
86 |
|
gWNM1(i,j,k,bi,bj) = gW(i,j,k,bi,bj) |
87 |
gW(i,j,k,bi,bj) = 0. |
gW(i,j,k,bi,bj) = 0. |
88 |
ENDDO |
ENDDO |
89 |
ENDDO |
ENDDO |
183 |
ENDDO |
ENDDO |
184 |
ENDDO |
ENDDO |
185 |
ENDDO |
ENDDO |
|
ENDDO |
|
|
ENDDO |
|
|
DO bj=myByLo(myThid),myByHi(myThid) |
|
|
DO bi=myBxLo(myThid),myBxHi(myThid) |
|
|
DO K=1,Nr |
|
|
DO j=J0,Jn |
|
|
DO i=I0,In |
|
|
gWNM1(i,j,k,bi,bj) = gW(i,j,k,bi,bj) |
|
|
ENDDO |
|
|
ENDDO |
|
|
ENDDO |
|
186 |
ENDDO |
ENDDO |
187 |
ENDDO |
ENDDO |
188 |
|
|