/[MITgcm]/MITgcm/pkg/mom_fluxform/mom_u_del2u.F
ViewVC logotype

Contents of /MITgcm/pkg/mom_fluxform/mom_u_del2u.F

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


Revision 1.2 - (show annotations) (download)
Tue May 29 14:01:38 2001 UTC (23 years ago) by adcroft
Branch: MAIN
CVS Tags: checkpoint40pre3, checkpoint40pre1, checkpoint40pre7, checkpoint40pre6, checkpoint40pre9, checkpoint40pre8, checkpoint40pre2, checkpoint40pre4, checkpoint40pre5, checkpoint40
Changes since 1.1: +92 -0 lines
Merge from branch pre38:
 o essential mods for cubed sphere
 o debugged atmosphere, dynamcis + physics (aim)
 o new packages (mom_vecinv, mom_fluxform, ...)

1 C $Header: /u/gcmpack/models/MITgcmUV/pkg/mom_fluxform/Attic/mom_u_del2u.F,v 1.1.2.1 2001/03/28 19:51:14 adcroft Exp $
2 C $Name: pre38-close $
3
4 #include "CPP_OPTIONS.h"
5
6 SUBROUTINE MOM_U_DEL2U(
7 I bi,bj,k,
8 I uFld, hFacZ,
9 O del2u,
10 I myThid)
11 IMPLICIT NONE
12 C
13 C Calculate horizontal del^2 of uFld
14 C - is not vector invariant ...
15 C
16
17 C == Global variables ==
18 #include "SIZE.h"
19 #include "EEPARAMS.h"
20 #include "PARAMS.h"
21 #include "GRID.h"
22 #include "DYNVARS.h"
23
24 C == Routine arguments ==
25 INTEGER bi,bj,k
26 _RL uFld(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
27 _RS hFacZ(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
28 _RL del2u(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
29 INTEGER myThid
30
31 C == Local variables ==
32 INTEGER I,J
33 _RL fZon(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
34 _RL fMer(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
35 _RS hFacZClosedS,hFacZClosedN
36
37 C Zonal flux d/dx U
38 DO j=1-Oly,sNy+Oly
39 DO i=1-Olx,sNx+Olx-1
40 fZon(i,j) = drF(k)*_hFacC(i,j,k,bi,bj)
41 & *_dyF(i,j,bi,bj)
42 & *_recip_dxF(i,j,bi,bj)
43 & *(uFld(i+1,j)-uFld(i,j))
44 #ifdef COSINEMETH_III
45 & *sqcosFacU(J,bi,bj)
46 #endif
47 ENDDO
48 ENDDO
49
50 C Meridional flux d/dy U
51 DO j=1-Oly+1,sNy+Oly
52 DO i=1-Olx,sNx+Olx
53 fMer(i,j) = drF(k)*hFacZ(i,j)
54 & *_dxV(i,j,bi,bj)
55 & *_recip_dyU(i,j,bi,bj)
56 & *(uFld(i,j)-uFld(i,j-1))
57 ENDDO
58 ENDDO
59
60 C del^2 U
61 DO j=0,sNy+1
62 DO i=0,sNx+2
63 del2u(i,j) =
64 & recip_drF(k)*_recip_hFacW(i,j,k,bi,bj)
65 & *recip_rAw(i,j,bi,bj)
66 & *( fZon(i,j ) - fZon(i-1,j)
67 & +fMer(i,j+1) - fMer(i ,j)
68 & )*_maskW(i,j,k,bi,bj)
69 ENDDO
70 ENDDO
71
72 IF (no_slip_sides) THEN
73 C-- No-slip BCs impose a drag at walls...
74 DO j=0,sNy+1
75 DO i=0,sNx+2
76 hFacZClosedS = _hFacW(i,j,k,bi,bj) - hFacZ(i,j)
77 hFacZClosedN = _hFacW(i,j,k,bi,bj) - hFacZ(i,j+1)
78 del2u(i,j) = del2u(i,j)
79 & - _recip_hFacW(i,j,k,bi,bj)*recip_drF(k)
80 & *recip_rAw(i,j,bi,bj)
81 & *( hFacZClosedS*dxV(i, j ,bi,bj)
82 & *_recip_dyU(i, j ,bi,bj)
83 & +hFacZClosedN*dxV(i,j+1,bi,bj)
84 & *_recip_dyU(i,j+1,bi,bj)
85 & )*drF(k)*2.*uFld(i,j)
86 & *_maskW(i,j,k,bi,bj)
87 ENDDO
88 ENDDO
89 ENDIF
90
91 RETURN
92 END

  ViewVC Help
Powered by ViewVC 1.1.22