125 |
_RL KappaRU (1-Olx:sNx+Olx,1-Oly:sNy+Oly,Nr) |
_RL KappaRU (1-Olx:sNx+Olx,1-Oly:sNy+Oly,Nr) |
126 |
_RL KappaRV (1-Olx:sNx+Olx,1-Oly:sNy+Oly,Nr) |
_RL KappaRV (1-Olx:sNx+Olx,1-Oly:sNy+Oly,Nr) |
127 |
|
|
128 |
|
#ifdef INCLUDE_CONVECT_CALL |
129 |
|
_RL ConvectCount (1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr) |
130 |
|
#endif |
131 |
|
|
132 |
INTEGER iMin, iMax |
INTEGER iMin, iMax |
133 |
INTEGER jMin, jMax |
INTEGER jMin, jMax |
134 |
INTEGER bi, bj |
INTEGER bi, bj |
204 |
K13(i,j,k) = 0. _d 0 |
K13(i,j,k) = 0. _d 0 |
205 |
K23(i,j,k) = 0. _d 0 |
K23(i,j,k) = 0. _d 0 |
206 |
K33(i,j,k) = 0. _d 0 |
K33(i,j,k) = 0. _d 0 |
207 |
KappaRT(i,j,k) = 0. _d 0 |
KappaRU(i,j,k) = 0. _d 0 |
208 |
KappaRS(i,j,k) = 0. _d 0 |
KappaRV(i,j,k) = 0. _d 0 |
209 |
ENDDO |
ENDDO |
210 |
rhoKM1 (i,j) = 0. _d 0 |
rhoKM1 (i,j) = 0. _d 0 |
211 |
rhok (i,j) = 0. _d 0 |
rhok (i,j) = 0. _d 0 |
243 |
ENDDO |
ENDDO |
244 |
ENDDO |
ENDDO |
245 |
|
|
246 |
|
DO k=1,Nr |
247 |
|
DO j=1-OLy,sNy+OLy |
248 |
|
DO i=1-OLx,sNx+OLx |
249 |
|
#ifdef INCLUDE_CONVECT_CALL |
250 |
|
ConvectCount(i,j,k) = 0. |
251 |
|
#endif |
252 |
|
KappaRT(i,j,k) = 0. _d 0 |
253 |
|
KappaRS(i,j,k) = 0. _d 0 |
254 |
|
ENDDO |
255 |
|
ENDDO |
256 |
|
ENDDO |
257 |
|
|
258 |
iMin = 1-OLx+1 |
iMin = 1-OLx+1 |
259 |
iMax = sNx+OLx |
iMax = sNx+OLx |
260 |
jMin = 1-OLy+1 |
jMin = 1-OLy+1 |
311 |
#ifdef INCLUDE_CONVECT_CALL |
#ifdef INCLUDE_CONVECT_CALL |
312 |
CALL CONVECT( |
CALL CONVECT( |
313 |
I bi,bj,iMin,iMax,jMin,jMax,K+1,rhoKm1,rhoKp1, |
I bi,bj,iMin,iMax,jMin,jMax,K+1,rhoKm1,rhoKp1, |
314 |
|
U ConvectCount, |
315 |
I myTime,myIter,myThid) |
I myTime,myIter,myThid) |
316 |
#endif |
#endif |
317 |
|
C-- Implicit Vertical Diffusion for Convection |
318 |
|
IF (ivdc_kappa.NE.0.) CALL CALC_IVDC( |
319 |
|
I bi,bj,iMin,iMax,jMin,jMax,K+1,rhoKm1,rhoKp1, |
320 |
|
U ConvectCount, KappaRT, KappaRS, |
321 |
|
I myTime,myIter,myThid) |
322 |
C-- Recompute density after mixing |
C-- Recompute density after mixing |
323 |
#ifdef INCLUDE_FIND_RHO_CALL |
#ifdef INCLUDE_FIND_RHO_CALL |
324 |
CALL FIND_RHO( |
CALL FIND_RHO( |
375 |
#ifdef INCLUDE_CONVECT_CALL |
#ifdef INCLUDE_CONVECT_CALL |
376 |
CALL CONVECT( |
CALL CONVECT( |
377 |
I bi,bj,iMin,iMax,jMin,jMax,K+1,rhoK,rhoKp1, |
I bi,bj,iMin,iMax,jMin,jMax,K+1,rhoK,rhoKp1, |
378 |
|
U ConvectCount, |
379 |
I myTime,myIter,myThid) |
I myTime,myIter,myThid) |
380 |
#endif |
#endif |
381 |
|
C-- Implicit Vertical Diffusion for Convection |
382 |
|
IF (ivdc_kappa.NE.0.) CALL CALC_IVDC( |
383 |
|
I bi,bj,iMin,iMax,jMin,jMax,K+1,rhoKm1,rhoKp1, |
384 |
|
U ConvectCount, KappaRT, KappaRS, |
385 |
|
I myTime,myIter,myThid) |
386 |
C-- Recompute density after mixing |
C-- Recompute density after mixing |
387 |
#ifdef INCLUDE_FIND_RHO_CALL |
#ifdef INCLUDE_FIND_RHO_CALL |
388 |
CALL FIND_RHO( |
CALL FIND_RHO( |
491 |
C-- Prediction step (step forward all model variables) |
C-- Prediction step (step forward all model variables) |
492 |
CALL TIMESTEP( |
CALL TIMESTEP( |
493 |
I bi,bj,iMin,iMax,jMin,jMax,K, |
I bi,bj,iMin,iMax,jMin,jMax,K, |
494 |
I myThid) |
I myIter, myThid) |
495 |
#ifdef ALLOW_OBCS |
#ifdef ALLOW_OBCS |
496 |
C-- Apply open boundary conditions |
C-- Apply open boundary conditions |
497 |
IF (openBoundaries) CALL APPLY_OBCS2( bi, bj, K, myThid ) |
IF (openBoundaries) CALL APPLY_OBCS2( bi, bj, K, myThid ) |
510 |
IF (taveFreq.GT.0.) THEN |
IF (taveFreq.GT.0.) THEN |
511 |
CALL DO_TIME_AVERAGES( |
CALL DO_TIME_AVERAGES( |
512 |
I myTime, myIter, bi, bj, K, kUp, kDown, |
I myTime, myIter, bi, bj, K, kUp, kDown, |
513 |
I K13, K23, rVel, KapGM, |
I K13, K23, rVel, KapGM, ConvectCount, |
514 |
I myThid ) |
I myThid ) |
515 |
ENDIF |
ENDIF |
516 |
#endif |
#endif |
517 |
|
|
518 |
|
|
519 |
ENDDO ! K |
ENDDO ! K |
520 |
|
|
521 |
C-- Implicit diffusion |
C-- Implicit diffusion |