1 |
C $Header: /u/gcmpack/MITgcm/pkg/aim_compon_interf/atm_store_seaice.F,v 1.1 2004/05/21 19:59:38 jmc Exp $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "PACKAGES_CONFIG.h" |
5 |
#include "CPP_OPTIONS.h" |
6 |
|
7 |
CStartOfInterface |
8 |
SUBROUTINE ATM_STORE_SEAICE( bi,bj, |
9 |
I myTime, |
10 |
I myIter, |
11 |
I myThid ) |
12 |
C /==========================================================\ |
13 |
C | SUBROUTINE ATM_STORE_SEAICE | |
14 |
C | o Routine for saving atmos. Sea-Ice Mass from thSIce pkg | |
15 |
C | for export to coupling layer. | |
16 |
C |==========================================================| |
17 |
C | This version interfaces to the LAND package. | |
18 |
C \==========================================================/ |
19 |
IMPLICIT NONE |
20 |
|
21 |
C == Global variables == |
22 |
#include "SIZE.h" |
23 |
|
24 |
#include "EEPARAMS.h" |
25 |
#include "PARAMS.h" |
26 |
#include "CPL_PARAMS.h" |
27 |
#ifdef ALLOW_THSICE |
28 |
#include "THSICE_PARAMS.h" |
29 |
#include "THSICE_VARS.h" |
30 |
#endif |
31 |
C == Global variables for coupling interface == |
32 |
#include "ATMCPL.h" |
33 |
|
34 |
|
35 |
C == Routine arguments == |
36 |
C bi,bj - Tile index |
37 |
C myThid - Thread number for this instance of the routine |
38 |
C myIter - Current timestep number |
39 |
C myTime - Current model time |
40 |
INTEGER bi, bj |
41 |
_RL myTime |
42 |
INTEGER myIter |
43 |
INTEGER myThid |
44 |
CEndOfInterface |
45 |
|
46 |
#ifdef ALLOW_THSICE |
47 |
C == Local variables == |
48 |
C i,j - Loop counters |
49 |
INTEGER i,j |
50 |
_RL cplTimeFraction |
51 |
|
52 |
C o Accumulate Sea-Ice Mass from thSIce pkg that will be exported |
53 |
C to the coupling layer. seaIceMass is per surface unit, in kg/m2. |
54 |
cplTimeFraction = 1. _d 0 / DFLOAT(cplSendFrq_iter) |
55 |
seaIceTime(bi,bj) = seaIceTime(bi,bj) + cplTimeFraction |
56 |
C- Needs really to store the last time-step value and not the average |
57 |
cplTimeFraction = 1. _d 0 |
58 |
seaIceTime(bi,bj) = cplTimeFraction |
59 |
DO j=1,sNy |
60 |
DO i=1,sNx |
61 |
c seaIceMass(i,j,bi,bj) = seaIceMass(i,j,bi,bj) + |
62 |
seaIceMass(i,j,bi,bj) = |
63 |
& ( snowHeight(i,j,bi,bj)*rhos |
64 |
& + iceHeight(i,j,bi,bj)*rhoi |
65 |
& )*iceMask(i,j,bi,bj)*cplTimeFraction |
66 |
ENDDO |
67 |
ENDDO |
68 |
|
69 |
#endif /* ALLOW_THSICE */ |
70 |
|
71 |
RETURN |
72 |
END |