/[MITgcm]/MITgcm_contrib/dgoldberg/shelfice/shelfice_init_varia.F
ViewVC logotype

Annotation of /MITgcm_contrib/dgoldberg/shelfice/shelfice_init_varia.F

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


Revision 1.1 - (hide annotations) (download)
Wed Aug 27 19:26:17 2014 UTC (10 years, 10 months ago) by dgoldberg
Branch: MAIN
CVS Tags: HEAD
contrib repo for changes to shelfice files for coupling

1 dgoldberg 1.1 C $Header: /u/gcmpack/MITgcm/pkg/shelfice/shelfice_init_varia.F,v 1.10 2013/04/11 18:59:12 jmc Exp $
2     C $Name: $
3    
4     #include "SHELFICE_OPTIONS.h"
5    
6    
7     CBOP
8     SUBROUTINE SHELFICE_INIT_VARIA( myThid )
9     C *============================================================*
10     C | SUBROUTINE SHELFICE_INIT_VARIA
11     C | o Routine to initialize SHELFICE variables.
12     C *============================================================*
13     C | Initialize SHELFICE parameters and variables.
14     C *============================================================*
15     IMPLICIT NONE
16    
17     C === Global variables ===
18     #include "SIZE.h"
19     #include "EEPARAMS.h"
20     #include "PARAMS.h"
21     #include "GRID.h"
22     #include "SHELFICE.h"
23     #ifdef ALLOW_COST
24     # include "SHELFICE_COST.h"
25     #endif /* ALLOW_COST */
26    
27     C === Routine arguments ===
28     C myThid - Number of this instance of SHELFICE_INIT_VARIA
29     INTEGER myThid
30     CEndOfInterface
31    
32     #ifdef ALLOW_SHELFICE
33     C === Local variables ===
34     C i,j,bi,bj - Loop counters
35     INTEGER i, j, bi, bj
36     CEOP
37    
38     DO bj = myByLo(myThid), myByHi(myThid)
39     DO bi = myBxLo(myThid), myBxHi(myThid)
40     DO j = 1-OLy, sNy+OLy
41     DO i = 1-OLx, sNx+OLx
42     c shelficeLoadAnomaly (i,j,bi,bj) = 0. _d 0
43     shelficeForcingT (i,j,bi,bj) = 0. _d 0
44     shelficeForcingS (i,j,bi,bj) = 0. _d 0
45     shelficeHeatFlux (i,j,bi,bj) = 0. _d 0
46     shelficeFreshWaterFlux(i,j,bi,bj) = 0. _d 0
47     shiTransCoeffT (i,j,bi,bj) = 0. _d 0
48     shiTransCoeffS (i,j,bi,bj) = 0. _d 0
49     shelficemass (i,j,bi,bj) = 0. _d 0
50     ENDDO
51     ENDDO
52     ENDDO
53     ENDDO
54     IF ( .NOT. SHELFICEuseGammaFrict ) THEN
55     C set coefficients to constant values
56     DO bj = myByLo(myThid), myByHi(myThid)
57     DO bi = myBxLo(myThid), myBxHi(myThid)
58     DO j = 1-OLy, sNy+OLy
59     DO i = 1-OLx, sNx+OLx
60     shiTransCoeffT(i,j,bi,bj) = SHELFICEheatTransCoeff
61     shiTransCoeffS(i,j,bi,bj) = SHELFICEsaltTransCoeff
62     ENDDO
63     ENDDO
64     ENDDO
65     ENDDO
66     ENDIF
67    
68     print *, "GOT HERE SHELFICE"
69    
70     ! IF ( SHELFICEallowThinIceMass ) THEN
71     DO bj = myByLo(myThid), myByHi(myThid)
72     DO bi = myBxLo(myThid), myBxHi(myThid)
73     DO j = 1-OLy, sNy+OLy
74     DO i = 1-OLx, sNx+OLx
75     shelficemass(i,j,bi,bj) = shelficemassinit(i,j,bi,bj)
76     ! shelficeLoadAnomalyDyn(i,j,bi,bj) =
77     ! & shelficeLoadAnomaly(i,j,bi,bj)
78     ENDDO
79     ENDDO
80     ENDDO
81     ENDDO
82     ! ENDIF
83    
84     #ifdef ALLOW_COST
85     DO bj = myByLo(myThid), myByHi(myThid)
86     DO bi = myBxLo(myThid), myBxHi(myThid)
87     DO j = 1-OLy, sNy+OLy
88     DO i = 1-OLx, sNx+OLx
89     cMeanSHIforT (i,j,bi,bj) = 0. _d 0
90     cMeanSHIforS (i,j,bi,bj) = 0. _d 0
91     ENDDO
92     ENDDO
93     ENDDO
94     ENDDO
95     c--
96     DO bj = myByLo(myThid), myByHi(myThid)
97     DO bi = myBxLo(myThid), myBxHi(myThid)
98     objf_shelfice(bi,bj) = 0. _d 0
99     objf_shifwflx(bi,bj) = 0. _d 0
100     num_shifwflx(bi,bj) = 0. _d 0
101     ENDDO
102     ENDDO
103     #endif /* ALLOW_COST */
104    
105     C Might be a problem here in case we need shelficeLoadAnomaly in phi0surf
106     C for initial pressure calculation when useDynP_inEos_Zc,
107     C since ini_pressure is called before this S/R.
108     c IF ( SHELFICEloadAnomalyFile .NE. ' ' ) THEN
109     c CALL READ_FLD_XY_RS( SHELFICEloadAnomalyFile, ' ',
110     c & shelficeLoadAnomaly, 0, myThid )
111     c _EXCH_XY_RS( shelficeLoadAnomaly, myThid )
112     c ENDIF
113    
114     #endif /* ALLOW_SHELFICE */
115    
116     RETURN
117     END

  ViewVC Help
Powered by ViewVC 1.1.22