5 |
|
|
6 |
CStartOfInterface |
CStartOfInterface |
7 |
SUBROUTINE SEAICE_TRACER_PHYS( myTime, myIter, myThid ) |
SUBROUTINE SEAICE_TRACER_PHYS( myTime, myIter, myThid ) |
8 |
C /=======================================================\ |
C *=======================================================* |
9 |
C | SUBROUTINE seaice_tracer_phys | |
C | SUBROUTINE seaice_tracer_phys |
10 |
C | o Time step SItr/SItrEFF as a result of | |
C | o Time step SItr/SItrEFF as a result of |
11 |
C | seaice thermodynamics and specific tracer physics | |
C | seaice thermodynamics and specific tracer physics |
12 |
C \=======================================================/ |
C *=======================================================* |
13 |
IMPLICIT NONE |
IMPLICIT NONE |
14 |
|
|
15 |
C === Global variables === |
C === Global variables === |
16 |
#include "SIZE.h" |
#include "SIZE.h" |
17 |
#include "EEPARAMS.h" |
#include "EEPARAMS.h" |
18 |
|
#include "PARAMS.h" |
19 |
#include "FFIELDS.h" |
#include "FFIELDS.h" |
20 |
#include "DYNVARS.h" |
#include "DYNVARS.h" |
21 |
#include "SEAICE_SIZE.h" |
#include "SEAICE_SIZE.h" |
22 |
#include "SEAICE.h" |
#include "SEAICE.h" |
23 |
#include "SEAICE_PARAMS.h" |
#include "SEAICE_PARAMS.h" |
24 |
#include "SEAICE_TRACER.h" |
#include "SEAICE_TRACER.h" |
25 |
|
#ifdef ALLOW_SALT_PLUME |
26 |
|
# include "SALT_PLUME.h" |
27 |
|
#endif |
28 |
|
|
29 |
C === Routine arguments === |
C === Routine arguments === |
30 |
C INPUT: |
C INPUT: |
59 |
|
|
60 |
DO bj=myByLo(myThid),myByHi(myThid) |
DO bj=myByLo(myThid),myByHi(myThid) |
61 |
DO bi=myBxLo(myThid),myBxHi(myThid) |
DO bi=myBxLo(myThid),myBxHi(myThid) |
62 |
DO iTr=1,SItrMaxNum |
DO iTr=1,SItrNumInUse |
63 |
|
|
64 |
c 0) set ice-ocean and ice-snow exchange values |
c 0) set ice-ocean and ice-snow exchange values |
65 |
c ============================================= |
c ============================================= |
66 |
DO J=1,sNy |
DO J=1,sNy |
67 |
DO I=1,sNx |
DO I=1,sNx |
68 |
SItrFromOcean(i,j)=0. _d 0 |
SItrFromOcean(i,j)=SItrFromOcean0(iTr) |
69 |
SItrFromFlood(i,j)=0. _d 0 |
SItrFromFlood(i,j)=SItrFromFlood0(iTr) |
70 |
SItrExpand(i,j)=0. _d 0 |
SItrExpand(i,j)=SItrExpand0(iTr) |
71 |
ENDDO |
ENDDO |
72 |
ENDDO |
ENDDO |
73 |
if (SItrName(iTr).EQ.'age') then |
c salinity tracer: |
74 |
c age tracer: no age in ocean, or effect from ice cover changes |
if ( (SItrName(iTr).EQ.'salinity').AND. |
75 |
elseif (SItrName(iTr).EQ.'salinity') then |
& (SItrFromOceanFrac(iTr).GT.ZERO) ) then |
|
c salinity tracer: |
|
|
DO J=1,sNy |
|
|
DO I=1,sNx |
|
|
SItrFromOcean(i,j)=SIsal0 |
|
|
#ifdef SEAICE_VARIABLE_SALINITY |
|
|
if (SIsalFRAC.GT.0.) |
|
|
& SItrFromOcean(i,j)=SIsalFRAC*salt(I,j,ks,bi,bj) |
|
|
#endif |
|
|
c as of now, flooding implies no salt extraction from ocean |
|
|
ENDDO |
|
|
ENDDO |
|
|
elseif (SItrName(iTr).EQ.'one') then |
|
|
c "ice concentration" tracer that should remain .EQ.1. |
|
76 |
DO J=1,sNy |
DO J=1,sNy |
77 |
DO I=1,sNx |
DO I=1,sNx |
78 |
SItrFromOcean(i,j)=1. _d 0 |
SItrFromOcean(i,j)=SItrFromOceanFrac(iTr)*salt(I,j,ks,bi,bj) |
79 |
SItrFromFlood(i,j)=1. _d 0 |
SItrFromFlood(i,j)=SItrFromFloodFrac(iTr)*salt(I,j,ks,bi,bj) |
80 |
ENDDO |
ENDDO |
81 |
ENDDO |
ENDDO |
82 |
endif |
endif |
87 |
DO I=1,sNx |
DO I=1,sNx |
88 |
HEFFprev=SItrHEFF(i,j,bi,bj,1) |
HEFFprev=SItrHEFF(i,j,bi,bj,1) |
89 |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
90 |
DIAGarray(I,J,5+(iTr-1)*5) = |
DIAGarray(I,J,5+(iTr-1)*5) = |
91 |
& HEFFprev*SItracer(i,j,bi,bj,iTr) + SItrBucket(i,j,bi,bj,iTr) |
& HEFFprev*SItracer(i,j,bi,bj,iTr) + SItrBucket(i,j,bi,bj,iTr) |
92 |
#endif |
#endif |
93 |
c apply the sequence of thermodynamics increments to actual traceur |
c apply the sequence of thermodynamics increments to actual tracer |
94 |
c (see seaice_growth.F) |
c (see seaice_growth.F) |
95 |
c (jTh=1 tendency due to ice-ocean interaction) |
c (jTh=1 tendency due to ice-ocean interaction) |
96 |
c (jTh=2 tendency due to the atmosphere, over ice covered part) |
c (jTh=2 tendency due to the atmosphere, over ice covered part) |
124 |
SItrBucket(i,j,bi,bj,iTr)=SItrBucket(i,j,bi,bj,iTr) |
SItrBucket(i,j,bi,bj,iTr)=SItrBucket(i,j,bi,bj,iTr) |
125 |
& -HEFFpost*SItrFromFlood(i,j)*(1. _d 0 - growFact) |
& -HEFFpost*SItrFromFlood(i,j)*(1. _d 0 - growFact) |
126 |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
127 |
DIAGarray(I,J,5+(iTr-1)*5) = HEFFpost*SItracer(i,j,bi,bj,iTr) |
DIAGarray(I,J,5+(iTr-1)*5) = HEFFpost*SItracer(i,j,bi,bj,iTr) |
128 |
& +SItrBucket(i,j,bi,bj,iTr)-DIAGarray(I,J,5+(iTr-1)*5) |
& +SItrBucket(i,j,bi,bj,iTr)-DIAGarray(I,J,5+(iTr-1)*5) |
129 |
#endif |
#endif |
130 |
ENDDO |
ENDDO |
133 |
else |
else |
134 |
c 1) or seaice cover expansion |
c 1) or seaice cover expansion |
135 |
c ============================ |
c ============================ |
136 |
c this is much simpler than for ice volume/mass tracers, because |
c this is much simpler than for ice volume/mass tracers, because |
137 |
c properties of the ice surface are not be conserved across the |
c properties of the ice surface are not be conserved across the |
138 |
c ocean-ice system, the contraction/expansion terms are all |
c ocean-ice system, the contraction/expansion terms are all |
139 |
c simultaneous (which is sane), and the only generic effect |
c simultaneous (which is sane), and the only generic effect |
140 |
c is due to expansion (new cover). |
c is due to expansion (new cover). |
141 |
DO J=1,sNy |
DO J=1,sNy |
142 |
DO I=1,sNx |
DO I=1,sNx |
174 |
c "ice concentration" tracer: no specific process |
c "ice concentration" tracer: no specific process |
175 |
elseif (SItrName(iTr).EQ.'ridge') then |
elseif (SItrName(iTr).EQ.'ridge') then |
176 |
c simple, made up, ice surface roughness index prototype |
c simple, made up, ice surface roughness index prototype |
|
#ifndef SEAICE_GROWTH_LEGACY |
|
177 |
DO J=1,sNy |
DO J=1,sNy |
178 |
DO I=1,sNx |
DO I=1,sNx |
179 |
c ridging increases roughness |
c ridging increases roughness |
187 |
SItracer(i,j,bi,bj,iTr)=SItracer(i,j,bi,bj,iTr)*tmpscal1 |
SItracer(i,j,bi,bj,iTr)=SItracer(i,j,bi,bj,iTr)*tmpscal1 |
188 |
ENDDO |
ENDDO |
189 |
ENDDO |
ENDDO |
|
#endif |
|
190 |
endif |
endif |
191 |
c 3) ice-ocean tracer exchange/mapping to external variables |
c 3) ice-ocean tracer exchange/mapping to external variables |
192 |
c ========================================================== |
c ========================================================== |
193 |
#ifdef ALLOW_DIAGNOSTICS |
#ifdef ALLOW_DIAGNOSTICS |
194 |
if (SItrMate(iTr).EQ.'HEFF') then |
IF ( useDiagnostics .AND. SItrMate(iTr).EQ.'HEFF') THEN |
195 |
WRITE(diagName,'(A4,I2.2,A2)') 'SItr',iTr,'FX' |
WRITE(diagName,'(A4,I2.2,A2)') 'SItr',iTr,'Fx' |
196 |
tmpscal1=-ONE/SEAICE_deltaTtherm*SEAICE_rhoIce |
tmpscal1=-ONE/SEAICE_deltaTtherm*SEAICE_rhoIce |
197 |
CALL DIAGNOSTICS_SCALE_FILL(SItrBucket(1-oLx,1-oLy,bi,bj,iTr), |
CALL DIAGNOSTICS_SCALE_FILL(SItrBucket(1-OLx,1-OLy,bi,bj,iTr), |
198 |
& tmpscal1, 1, diagName,0,1,2,bi,bj,myThid) |
& tmpscal1, 1, diagName,0,1,2,bi,bj,myThid) |
199 |
endif |
ENDIF |
200 |
#endif |
#endif |
201 |
if (SItrName(iTr).EQ.'age') then |
|
202 |
c age tracer: not passed to ocean |
if ( (SItrName(iTr).EQ.'salinity').AND. |
203 |
elseif (SItrName(iTr).EQ.'salinity') then |
& (SEAICE_salinityTracer) ) then |
204 |
c salinity tracer: salt flux |
c salinity tracer: salt flux |
205 |
c DO J=1,sNy |
DO J=1,sNy |
206 |
c DO I=1,sNx |
DO I=1,sNx |
207 |
c saltFlux(I,J,bi,bj) = - SItrBucket(i,j,bi,bj,iTr) |
saltFlux(I,J,bi,bj) = - SItrBucket(i,j,bi,bj,iTr) |
208 |
c & *HEFFM(I,J,bi,bj)/SEAICE_deltaTtherm*SEAICE_rhoIce |
& *HEFFM(I,J,bi,bj)/SEAICE_deltaTtherm*SEAICE_rhoIce |
209 |
c note: at this point of the time step, that is the correct sign |
c note: at this point of the time step, that is the correct sign |
210 |
c saltPlumeFlux(I,J,bi,bj) = ... |
#ifdef ALLOW_SALT_PLUME |
211 |
c ENDDO |
c should work for both constant and variable ice salinity -- to be tested |
212 |
c ENDDO |
saltPlumeFlux(I,J,bi,bj) = MAX(ZERO,saltFlux(I,J,bi,bj)) |
213 |
elseif (SItrName(iTr).EQ.'one') then |
& *SPsalFRAC*(salt(I,j,ks,bi,bj)-SItrFromOcean(i,j)) |
214 |
c "ice concentration" tracer: not passed to ocean |
#endif |
215 |
|
ENDDO |
216 |
|
ENDDO |
217 |
endif |
endif |
218 |
|
|
219 |
DO J=1,sNy |
DO J=1,sNy |
220 |
DO I=1,sNx |
DO I=1,sNx |
221 |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
223 |
& *HEFFM(I,J,bi,bj)/SEAICE_deltaTtherm*SEAICE_rhoIce |
& *HEFFM(I,J,bi,bj)/SEAICE_deltaTtherm*SEAICE_rhoIce |
224 |
#endif |
#endif |
225 |
c empty bucket |
c empty bucket |
226 |
SItrBucket(i,j,bi,bj,iTr)=0. _d 0 |
c but not for 'grease' (see seaice_growth.F) |
227 |
|
if (SItrName(iTr).NE.'grease') |
228 |
|
& SItrBucket(i,j,bi,bj,iTr)=0. _d 0 |
229 |
ENDDO |
ENDDO |
230 |
ENDDO |
ENDDO |
231 |
|
|
232 |
c TAF? elseif (SItrMate(iTr).EQ.'AREA') then |
c TAF? elseif (SItrMate(iTr).EQ.'AREA') then |
233 |
|
|
234 |
c 4) diagnostics |
c 4) diagnostics |
235 |
c ============== |
c ============== |
236 |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
241 |
DIAGarray(I,J,1+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr) |
DIAGarray(I,J,1+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr) |
242 |
DIAGarray(I,J,2+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr)*HEFFpost |
DIAGarray(I,J,2+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr)*HEFFpost |
243 |
c DIAGarray(:,:,3) is the term of comparison for DIAGarray(:,:,2) |
c DIAGarray(:,:,3) is the term of comparison for DIAGarray(:,:,2) |
244 |
if (SItrName(iTr).EQ.'age') then |
if (SItrName(iTr).EQ.'salinity') then |
|
DIAGarray(I,J,3+(iTr-1)*5) = IceAgeTr(i,j,bi,bj,2) |
|
|
elseif (SItrName(iTr).EQ.'salinity') then |
|
245 |
DIAGarray(I,J,3+(iTr-1)*5) = HSALT(i,j,bi,bj)/SEAICE_rhoIce |
DIAGarray(I,J,3+(iTr-1)*5) = HSALT(i,j,bi,bj)/SEAICE_rhoIce |
246 |
elseif (SItrName(iTr).EQ.'one') then |
elseif (SItrName(iTr).EQ.'one') then |
247 |
DIAGarray(I,J,3+(iTr-1)*5) = HEFFpost |
DIAGarray(I,J,3+(iTr-1)*5) = HEFFpost |
256 |
AREApost=SItrAREA(i,j,bi,bj,3) |
AREApost=SItrAREA(i,j,bi,bj,3) |
257 |
DIAGarray(I,J,1+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr) |
DIAGarray(I,J,1+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr) |
258 |
DIAGarray(I,J,2+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr)*AREApost |
DIAGarray(I,J,2+(iTr-1)*5) = SItracer(i,j,bi,bj,iTr)*AREApost |
|
c DIAGarray(:,:,3) is the term of comparison for DIAGarray(:,:,2) |
|
|
if (SItrName(iTr).EQ.'age') then |
|
|
DIAGarray(I,J,3+(iTr-1)*5) = IceAgeTr(i,j,bi,bj,1) |
|
|
endif |
|
259 |
ENDDO |
ENDDO |
260 |
ENDDO |
ENDDO |
261 |
endif |
endif |
262 |
#endif |
#endif |
263 |
ENDDO |
ENDDO |
264 |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
#ifdef ALLOW_SITRACER_DEBUG_DIAG |
265 |
CALL DIAGNOSTICS_FILL(DIAGarray,'UDIAG1 ',0,Nr,3,bi,bj,myThid) |
c CALL DIAGNOSTICS_FILL(DIAGarray,'UDIAG1 ',0,Nr,3,bi,bj,myThid) |
266 |
#endif |
#endif |
267 |
ENDDO |
ENDDO |
268 |
ENDDO |
ENDDO |