32 |
|
|
33 |
#ifdef ALLOW_STREAMICE |
#ifdef ALLOW_STREAMICE |
34 |
|
|
35 |
INTEGER i, j, bi, bj, k, iter_count |
INTEGER i, j, bi, bj, k, iter_count, iter_rpt |
36 |
INTEGER Gi, Gj |
INTEGER Gi, Gj |
37 |
INTEGER new_partial(4) |
INTEGER new_partial(4) |
38 |
INTEGER ikey_front, ikey_1 |
INTEGER ikey_front, ikey_1 |
39 |
_RL iter_flag |
_RL iter_flag |
40 |
_RL n_flux_1, n_flux_2 |
_RL n_flux_1, n_flux_2 |
41 |
_RL href, rho, partial_vol, tot_flux, hpot |
_RL href, rho, partial_vol, tot_flux, hpot |
42 |
|
CHARACTER*(MAX_LEN_MBUF) msgBuf |
43 |
|
|
44 |
rho = streamice_density |
rho = streamice_density |
45 |
cph iter_count = 0 |
cph iter_count = 0 |
46 |
iter_flag = 1. _d 0 |
iter_flag = 1. _d 0 |
47 |
|
iter_rpt = 0 |
48 |
|
|
49 |
DO iter_count = 0, 3 |
DO iter_count = 0, 3 |
50 |
|
|
88 |
ENDIF |
ENDIF |
89 |
|
|
90 |
! iter_count = iter_count + 1 |
! iter_count = iter_count + 1 |
91 |
|
iter_rpt = iter_rpt + 1 |
92 |
|
|
93 |
DO bj=myByLo(myThid),myByHi(myThid) |
DO bj=myByLo(myThid),myByHi(myThid) |
94 |
DO bi=myBxLo(myThid),myBxHi(myThid) |
DO bi=myBxLo(myThid),myBxHi(myThid) |
107 |
act3 = myThid - 1 |
act3 = myThid - 1 |
108 |
max3 = nTx*nTy |
max3 = nTx*nTy |
109 |
act4 = ikey_front - 1 |
act4 = ikey_front - 1 |
110 |
ikey_1 = i |
ikey_1 = i + 2 |
111 |
& + sNx*(j-1) |
& + (sNx+2)*(j-1) |
112 |
& + sNx*sNy*act1 |
& + (sNx+2)*(sNy+2)*act1 |
113 |
& + sNx*sNy*max1*act2 |
& + (sNx+2)*(sNy+2)*max1*act2 |
114 |
& + sNx*sNy*max1*max2*act3 |
& + (sNx+2)*(sNy+2)*max1*max2*act3 |
115 |
& + sNx*sNy*max1*max2*max3*act4 |
& + (sNx+2)*(sNy+2)*max1*max2*max3*act4 |
116 |
CADJ STORE area_shelf_streamice(i,j,bi,bj) |
CADJ STORE area_shelf_streamice(i,j,bi,bj) |
117 |
CADJ & = comlev1_stream_ij, key = ikey_1 |
CADJ & = comlev1_stream_ij, key = ikey_1 |
118 |
CADJ STORE h_streamice(i,j,bi,bj) |
CADJ STORE h_streamice(i,j,bi,bj) |
194 |
& rA(i,j,bi,bj) |
& rA(i,j,bi,bj) |
195 |
ELSEIF (hpot .lt. href) THEN ! cell still unfilled |
ELSEIF (hpot .lt. href) THEN ! cell still unfilled |
196 |
|
|
197 |
! PRINT *, "PARTIAL CELL INCREASED", tot_flux, i, |
|
|
! & area_shelf_streamice (i,j,bi,bj), |
|
|
! & H_streamice (i,j,bi,bj) |
|
198 |
|
|
199 |
STREAMICE_hmask (i,j,bi,bj) = 2.0 |
STREAMICE_hmask (i,j,bi,bj) = 2.0 |
200 |
area_shelf_streamice (i,j,bi,bj) = partial_vol / href |
area_shelf_streamice (i,j,bi,bj) = partial_vol / href |
201 |
H_streamice (i,j,bi,bj) = href |
H_streamice (i,j,bi,bj) = href |
202 |
ELSE ! cell is filled - do overflow |
ELSE ! cell is filled - do overflow |
203 |
|
|
|
! PRINT *, "CELL FILLED" |
|
204 |
|
|
205 |
STREAMICE_hmask (i,j,bi,bj) = 1.0 |
STREAMICE_hmask (i,j,bi,bj) = 1.0 |
206 |
area_shelf_streamice(i,j,bi,bj) = |
area_shelf_streamice(i,j,bi,bj) = |
270 |
ENDIF |
ENDIF |
271 |
ENDDO |
ENDDO |
272 |
|
|
273 |
cph IF (iter_count.gt.1) THEN |
IF (iter_rpt.gt.1) THEN |
274 |
cph PRINT *, "FRONT ADVANCE: ", iter_count, " ITERATIONS" |
WRITE(msgBuf,'(A,I5,A)') 'FRONT ADVANCE: ',iter_rpt, |
275 |
cph ENDIF |
& ' ITERATIONS' |
276 |
|
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit, |
277 |
|
& SQUEEZE_RIGHT , 1) |
278 |
|
ENDIF |
279 |
|
|
280 |
|
|
281 |
|
|