/[MITgcm]/MITgcm_contrib/bbl/code/ini_dynvars.F
ViewVC logotype

Annotation of /MITgcm_contrib/bbl/code/ini_dynvars.F

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


Revision 1.1 - (hide annotations) (download)
Sun Mar 6 02:11:05 2011 UTC (14 years, 4 months ago) by dimitri
Branch: MAIN
changing density comparisons from potential to in situ
code contributed by Madeline Miller

1 dimitri 1.1 C $Header: /u/gcmpack/MITgcm/model/src/ini_dynvars.F,v 1.23 2010/02/17 23:39:32 gforget Exp $
2     C $Name: $
3    
4     #include "CPP_OPTIONS.h"
5    
6     CBOP
7     C !ROUTINE: INI_DYNVARS
8     C !INTERFACE:
9     SUBROUTINE INI_DYNVARS( myThid )
10     C !DESCRIPTION: \bv
11     C *==========================================================*
12     C | SUBROUTINE INI_DYNVARS
13     C | o Initialise to zero all DYNVARS.h arrays
14     C *==========================================================*
15     C | Sets all the State variables to zero.
16     C | Sets all the Gs (arrays used for multi-level time-stepping)
17     C | to zero.
18     C *==========================================================*
19     C \ev
20    
21     C !USES:
22     IMPLICIT NONE
23     C === Global variables ===
24     #include "SIZE.h"
25     #include "EEPARAMS.h"
26     #include "PARAMS.h"
27     #include "DYNVARS.h"
28    
29     C !INPUT/OUTPUT PARAMETERS:
30     C == Routine arguments ==
31     C myThid :: my Thread Id. number
32     INTEGER myThid
33    
34     C !LOCAL VARIABLES:
35     C == Local variables ==
36     C bi,bj :: tile indices
37     C I,J,K :: loop index
38     INTEGER bi, bj
39     INTEGER I, J, K
40     CEOP
41    
42     C-- Over all tiles
43     DO bj = myByLo(myThid), myByHi(myThid)
44     DO bi = myBxLo(myThid), myBxHi(myThid)
45    
46     C- 3D arrays
47     DO K=1,Nr
48     DO J=1-Oly,sNy+Oly
49     DO I=1-Olx,sNx+Olx
50    
51     uVel(I,J,K,bi,bj)=0. _d 0
52     vVel(I,J,K,bi,bj)=0. _d 0
53     wVel(I,J,K,bi,bj)=0. _d 0
54     theta(I,J,K,bi,bj)=0. _d 0
55     salt(I,J,K,bi,bj)=0. _d 0
56    
57     gU(I,J,K,bi,bj)=0. _d 0
58     gV(I,J,K,bi,bj)=0. _d 0
59     gT(I,J,K,bi,bj)=0. _d 0
60     gS(I,J,K,bi,bj)=0. _d 0
61     #ifdef ALLOW_ADAMSBASHFORTH_3
62     guNm(I,J,K,bi,bj,1)=0. _d 0
63     gvNm(I,J,K,bi,bj,1)=0. _d 0
64     gtNm(I,J,K,bi,bj,1)=0. _d 0
65     gsNm(I,J,K,bi,bj,1)=0. _d 0
66     guNm(I,J,K,bi,bj,2)=0. _d 0
67     gvNm(I,J,K,bi,bj,2)=0. _d 0
68     gtNm(I,J,K,bi,bj,2)=0. _d 0
69     gsNm(I,J,K,bi,bj,2)=0. _d 0
70     #else
71     guNm1(I,J,K,bi,bj) =0. _d 0
72     gvNm1(I,J,K,bi,bj) =0. _d 0
73     gtNm1(I,J,K,bi,bj) =0. _d 0
74     gsNm1(I,J,K,bi,bj) =0. _d 0
75     #endif
76     totPhiHyd(I,J,K,bi,bj)=0. _d 0
77     rhoInSitu(I,J,K,bi,bj)=0. _d 0
78     IVDConvCount(i,j,k,bi,bj) = 0. _d 0
79     #ifdef ALLOW_ADDFLUID
80     addMass(I,J,K,bi,bj) = 0. _d 0
81     #endif
82     ENDDO
83     ENDDO
84     ENDDO
85    
86     C- initialize Nr+1 rhoInSitu level for BBL package
87     #ifdef ALLOW_BBL
88     K=Nr+1
89     DO J=1-Oly,sNy+Oly
90     DO I=1-Olx,sNx+Olx
91     rhoInSitu(I,J,K,bi,bj)=0. _d 0
92     ENDDO
93     ENDDO
94     #endif
95    
96     C- 2D arrays
97     DO J=1-Oly,sNy+Oly
98     DO I=1-Olx,sNx+Olx
99     etaN(I,J,bi,bj)=0. _d 0
100     etaH(I,J,bi,bj)=0. _d 0
101     phiHydLow(I,J,bi,bj)=0. _d 0
102     hMixLayer(I,J,bi,bj)=0. _d 0
103     ENDDO
104     ENDDO
105    
106     ENDDO
107     ENDDO
108    
109     RETURN
110     END

  ViewVC Help
Powered by ViewVC 1.1.22