/[MITgcm]/MITgcm/model/src/dynamics.F
ViewVC logotype

Diff of /MITgcm/model/src/dynamics.F

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

revision 1.25 by adcroft, Thu Jul 16 15:23:43 1998 UTC revision 1.26 by cnh, Wed Aug 19 16:20:49 1998 UTC
# Line 59  C                              o fVer: V Line 59  C                              o fVer: V
59  C                                      is "pipelined" in the vertical  C                                      is "pipelined" in the vertical
60  C                                      so we need an fVer for each  C                                      so we need an fVer for each
61  C                                      variable.  C                                      variable.
62    C     rhoK, rhoKM1   - Density at current level, level above and level below.
63    C     rhoKP1                                                                  
64    C     buoyK, buoyKM1 - Buoyancy at current level and level above.
65    C     phiHyd         - Hydrostatic part of the potential phi.
66    C                      In z coords phiHyd is the hydrostatic pressure anomaly
67    C                      In p coords phiHyd is the geopotential surface height anomaly.
68  C     iMin, iMax - Ranges and sub-block indices on which calculations  C     iMin, iMax - Ranges and sub-block indices on which calculations
69  C     jMin, jMax   are applied.  C     jMin, jMax   are applied.
70  C     bi, bj  C     bi, bj
# Line 84  C                          into fVerTerm Line 90  C                          into fVerTerm
90        _RL fVerS (1-OLx:sNx+OLx,1-OLy:sNy+OLy,2)        _RL fVerS (1-OLx:sNx+OLx,1-OLy:sNy+OLy,2)
91        _RL fVerU (1-OLx:sNx+OLx,1-OLy:sNy+OLy,2)        _RL fVerU (1-OLx:sNx+OLx,1-OLy:sNy+OLy,2)
92        _RL fVerV (1-OLx:sNx+OLx,1-OLy:sNy+OLy,2)        _RL fVerV (1-OLx:sNx+OLx,1-OLy:sNy+OLy,2)
93        _RL pH    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nz)        _RL phiHyd(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nz)
94        _RL rhokm1(1-OLx:sNx+OLx,1-OLy:sNy+OLy)        _RL rhokm1(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
95        _RL rhokp1(1-OLx:sNx+OLx,1-OLy:sNy+OLy)        _RL rhokp1(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
96        _RL rhok  (1-OLx:sNx+OLx,1-OLy:sNy+OLy)        _RL rhok  (1-OLx:sNx+OLx,1-OLy:sNy+OLy)
97          _RL buoyKM1(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
98          _RL buoyK (1-OLx:sNx+OLx,1-OLy:sNy+OLy)
99        _RL rhotmp(1-OLx:sNx+OLx,1-OLy:sNy+OLy)        _RL rhotmp(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
100        _RL pSurfX(1-OLx:sNx+OLx,1-OLy:sNy+OLy)        _RL pSurfX(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
101        _RL pSurfY(1-OLx:sNx+OLx,1-OLy:sNy+OLy)        _RL pSurfY(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
# Line 178  C     uninitialised but inert locations. Line 186  C     uninitialised but inert locations.
186          rhok  (i,j)  = 0. _d 0          rhok  (i,j)  = 0. _d 0
187          rhokp1(i,j)  = 0. _d 0          rhokp1(i,j)  = 0. _d 0
188          rhotmp(i,j)  = 0. _d 0          rhotmp(i,j)  = 0. _d 0
189            buoyKM1(i,j) = 0. _d 0
190            buoyK  (i,j) = 0. _d 0
191          maskC (i,j)  = 0. _d 0          maskC (i,j)  = 0. _d 0
192         ENDDO         ENDDO
193        ENDDO        ENDDO
# Line 230  C--      Update fields in layer below ac Line 240  C--      Update fields in layer below ac
240           CALL CORRECTION_STEP(           CALL CORRECTION_STEP(
241       I        bi,bj,iMin,iMax,jMin,jMax,K+1,pSurfX,pSurfY,myTime,myThid)       I        bi,bj,iMin,iMax,jMin,jMax,K+1,pSurfX,pSurfY,myTime,myThid)
242          ENDIF          ENDIF
   
243  C--     Density of 1st level (below W(1)) reference to level 1  C--     Density of 1st level (below W(1)) reference to level 1
244          CALL FIND_RHO(          CALL FIND_RHO(
245       I     bi, bj, iMin, iMax, jMin, jMax, K, K, eosType,       I     bi, bj, iMin, iMax, jMin, jMax, K, K, eosType,
# Line 238  C--     Density of 1st level (below W(1) Line 247  C--     Density of 1st level (below W(1)
247       I     myThid )       I     myThid )
248    
249          IF ( .NOT. BOTTOM_LAYER ) THEN          IF ( .NOT. BOTTOM_LAYER ) THEN
250    
251  C--      Check static stability with layer below  C--      Check static stability with layer below
252  C        and mix as needed.  C        and mix as needed.
253           CALL FIND_RHO(           CALL FIND_RHO(
# Line 254  C--      Recompute density after mixing Line 264  C--      Recompute density after mixing
264       I      myThid )       I      myThid )
265          ENDIF          ENDIF
266    
267    C--     Calculate buoyancy
268            CALL CALC_BUOY(
269         I      bi,bj,iMin,iMax,jMin,jMax,K,rhoKm1,
270         O      buoyKm1,
271         I      myThid )
272    
273  C--     Integrate hydrostatic balance for pH with BC of pH(z=0)=0  C--     Integrate hydrostatic balance for pH with BC of pH(z=0)=0
274          CALL CALC_PH(          CALL CALC_PHI_HYD(
275       I      bi,bj,iMin,iMax,jMin,jMax,K,rhoKm1,rhoKm1,       I      bi,bj,iMin,iMax,jMin,jMax,K,buoyKm1,buoyKm1,
276       U      pH,       U      phiHyd,
277       I      myThid )       I      myThid )
278    
279          DO K=2,Nz          DO K=2,Nz
280    
281           BOTTOM_LAYER = K .EQ. Nz           BOTTOM_LAYER = K .EQ. Nz
   
282           IF ( .NOT. BOTTOM_LAYER ) THEN           IF ( .NOT. BOTTOM_LAYER ) THEN
283  C--       Update fields in layer below according to tendency terms  C--       Update fields in layer below according to tendency terms
284            CALL CORRECTION_STEP(            CALL CORRECTION_STEP(
285       I         bi,bj,iMin,iMax,jMin,jMax,K+1,pSurfX,pSurfY,myTime,myThid)       I         bi,bj,iMin,iMax,jMin,jMax,K+1,pSurfX,pSurfY,myTime,myThid)
286           ENDIF           ENDIF
 C--      Update fields in layer below according to tendency terms  
 C        CALL CORRECTION_STEP(  
 C    I        bi,bj,iMin,iMax,jMin,jMax,K,pSurfX,pSurfY,myTime,myThid)  
   
287  C--      Density of K level (below W(K)) reference to K level  C--      Density of K level (below W(K)) reference to K level
288           CALL FIND_RHO(           CALL FIND_RHO(
289       I      bi, bj, iMin, iMax, jMin, jMax,  K, K, eosType,       I      bi, bj, iMin, iMax, jMin, jMax,  K, K, eosType,
# Line 295  C--       Recompute density after mixing Line 306  C--       Recompute density after mixing
306       O       rhoK,       O       rhoK,
307       I       myThid )       I       myThid )
308           ENDIF           ENDIF
309    
310    C--      Calculate buoyancy
311             CALL CALC_BUOY(
312         I       bi,bj,iMin,iMax,jMin,jMax,K,rhoK,
313         O       buoyK,
314         I       myThid )
315    
316  C--      Integrate hydrostatic balance for pH with BC of pH(z=0)=0  C--      Integrate hydrostatic balance for pH with BC of pH(z=0)=0
317           CALL CALC_PH(           CALL CALC_PHI_HYD(
318       I       bi,bj,iMin,iMax,jMin,jMax,K,rhoKm1,rhoK,       I       bi,bj,iMin,iMax,jMin,jMax,K,buoyKm1,buoyK,
319       U       pH,       U       phiHyd,
320       I       myThid )       I       myThid )
321  C--      Calculate iso-neutral slopes for the GM/Redi parameterisation  C--      Calculate iso-neutral slopes for the GM/Redi parameterisation
322           CALL FIND_RHO(           CALL FIND_RHO(
# Line 312  C--      Calculate iso-neutral slopes fo Line 330  C--      Calculate iso-neutral slopes fo
330       I             myThid )       I             myThid )
331           DO J=jMin,jMax           DO J=jMin,jMax
332            DO I=iMin,iMax            DO I=iMin,iMax
333             rhoKm1(I,J)=rhoK(I,J)             rhoKm1(I,J) =rhoK(I,J)
334               buoyKm1(I,J)=buoyK(I,J)
335            ENDDO            ENDDO
336           ENDDO           ENDDO
337    
# Line 345  C--      Calculate accelerations in the Line 364  C--      Calculate accelerations in the
364            CALL CALC_MOM_RHS(            CALL CALC_MOM_RHS(
365       I         bi,bj,iMin,iMax,jMin,jMax,k,kM1,kUp,kDown,       I         bi,bj,iMin,iMax,jMin,jMax,k,kM1,kUp,kDown,
366       I         xA,yA,uTrans,vTrans,wTrans,wVel,maskC,       I         xA,yA,uTrans,vTrans,wTrans,wVel,maskC,
367       I         pH,       I         phiHyd,
368       U         aTerm,xTerm,cTerm,mTerm,pTerm,       U         aTerm,xTerm,cTerm,mTerm,pTerm,
369       U         fZon, fMer, fVerU, fVerV,       U         fZon, fMer, fVerU, fVerV,
370       I         myThid)       I         myThid)

Legend:
Removed from v.1.25  
changed lines
  Added in v.1.26

  ViewVC Help
Powered by ViewVC 1.1.22