/[MITgcm]/MITgcm/pkg/thsice/thsice_impl_temp.F
ViewVC logotype

Annotation of /MITgcm/pkg/thsice/thsice_impl_temp.F

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


Revision 1.1 - (hide annotations) (download)
Wed Apr 7 23:40:34 2004 UTC (20 years, 1 month ago) by jmc
Branch: MAIN
CVS Tags: checkpoint52n_post, checkpoint52m_post, checkpoint53
major changes in pkg/thsice: allows atmospheric model (AIM) to use thsice.
- split thsice_therm.F in 2 S/R: thsice_solve4temp.F & thsice_calc_thickn.F
- move most of the ocean & bulk_force interface in thsice_main.F
- add a "slab ocean" component to be used with atmospheric model

1 jmc 1.1 C $Header: $
2     C $Name: $
3    
4     #include "THSICE_OPTIONS.h"
5    
6     C !ROUTINE: THSICE_IMPL_TEMP
7     C !INTERFACE:
8     SUBROUTINE THSICE_IMPL_TEMP(
9     I netSW, sFlx,
10     O dTsurf,
11     I bi, bj, myTime, myIter, myThid)
12     C *==========================================================*
13     C | S/R THSICE_IMPL_TEMP
14     C | o Calculate sea-ice and surface temp. implicitly
15     C *==========================================================*
16     C | o return surface fluxes for atmosphere boundary layer
17     C | physics (and therefore called within atmospheric physics)
18     C *==========================================================*
19    
20     C !USES:
21     IMPLICIT NONE
22     C === Global variables ===
23     #include "SIZE.h"
24     #include "EEPARAMS.h"
25     #include "PARAMS.h"
26     #include "FFIELDS.h"
27     #include "THSICE_SIZE.h"
28     #include "THSICE_PARAMS.h"
29     #include "THSICE_VARS.h"
30    
31     C !INPUT/OUTPUT PARAMETERS:
32     C === Routine arguments ===
33     C netSW :: net Short Wave surf. flux (+=down) [W/m2]
34     C sFlx :: surf. heat flux (+=down) except SW, function of surf. temp Ts:
35     C 0: Flx(Ts=0) ; 1: Flx(Ts=Ts^n) ; 2: d.Flx/dTs(Ts=Ts^n)
36     C dTsurf :: surf. temp adjusment: Ts^n+1 - Ts^n
37     C bi,bj :: Tile index
38     C myIter :: iteration counter for this thread
39     C myTime :: time counter for this thread
40     C myThid :: thread number for this instance of the routine.
41     _RL netSW (sNx,sNy)
42     _RL sFlx (sNx,sNy,0:2)
43     _RL dTsurf (sNx,sNy)
44     INTEGER bi,bj
45     _RL myTime
46     INTEGER myIter
47     INTEGER myThid
48    
49     #ifdef ALLOW_THSICE
50     C !LOCAL VARIABLES:
51     C === Local variables ===
52     C flxSW :: net Short-Wave (+=down) at surface [W/m2]
53     C flxExcSw :: surf. heat flux (+=down) except SW, function of surf. temp Ts:
54     C 0: Flx(Ts=0) ; 1: Flx(Ts=Ts^n) ; 2: d.Flx/dTs(Ts=Ts^n)
55     C sHeating :: surf heating left to melt snow or ice (= Atmos-conduction)
56     C flxCnB :: heat flux conducted through the ice to bottom surface
57     C flxtmp :: net heat flux from the atmosphere ( >0 downward)
58     C evptmp :: evaporation to the atmosphere [kg/m2/s] (>0 if evaporate)
59     INTEGER i,j
60     INTEGER iMin, iMax
61     INTEGER jMin, jMax
62     _RL flxSW
63     _RL Tf
64     _RL flxtmp, evptmp
65     _RL flxExcSw(0:2)
66     _RL hIce, hSnow, Tsf, Tice(nlyr), qicen(nlyr)
67    
68     LOGICAL dBug
69    
70     iMin = 1
71     iMax = sNx
72     jMin = 1
73     jMax = sNy
74     dBug = .FALSE.
75     1010 FORMAT(A,1P4E11.3)
76    
77     DO j = jMin, jMax
78     DO i = iMin, iMax
79     c dBug = ( bi.EQ.3 .AND. i.EQ.13 .AND. j.EQ.13 )
80    
81     C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
82     C part.1 : ice-covered fraction ;
83     C Solve for surface and ice temperature (implicitly) ; compute surf. fluxes
84     C-------
85     IF (iceMask(i,j,bi,bj).GT.0. _d 0) THEN
86     Tf = -mu_Tf*sOceMxL(i,j,bi,bj)
87     hIce = iceHeight(i,j,bi,bj)
88     hSnow = snowHeight(i,j,bi,bj)
89     flxExcSw(0) = sFlx(i,j,0)
90     flxExcSw(1) = sFlx(i,j,1)
91     flxExcSw(2) = sFlx(i,j,2)
92     flxSW = netSW(i,j)
93     Tsf = Tsrf(i,j,bi,bj)
94     qicen(1)= Qice1(i,j,bi,bj)
95     qicen(2)= Qice2(i,j,bi,bj)
96     CALL THSICE_SOLVE4TEMP(
97     I useBulkforce, flxExcSw, Tf, hIce, hSnow,
98     U flxSW, Tsf, qicen,
99     O Tice, sHeating(i,j,bi,bj), flxCndBt(i,j,bi,bj),
100     O dTsurf(i,j), flxtmp, evptmp,
101     I i,j, bi,bj, myThid)
102     C-- Update Fluxes :
103     Qsw(i,j,bi,bj) = -flxSW
104     C-- Update Sea-Ice state :
105     Tsrf(i,j,bi,bj) =Tsf
106     Tice1(i,j,bi,bj)=Tice(1)
107     Tice2(i,j,bi,bj)=Tice(2)
108     Qice1(i,j,bi,bj)=qicen(1)
109     Qice2(i,j,bi,bj)=qicen(2)
110     ELSE
111     dTsurf(i,j) = 0. _d 0
112     Qsw(i,j,bi,bj) = 0. _d 0
113     ENDIF
114     ENDDO
115     ENDDO
116    
117     C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----|
118     #endif /* ALLOW_THSICE */
119    
120     RETURN
121     END

  ViewVC Help
Powered by ViewVC 1.1.22