1 |
C $Header: /u/gcmpack/MITgcm/pkg/atm_compon_interf/atm_store_land.F,v 1.1 2013/09/11 20:17:27 jmc Exp $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "ATM_CPL_OPTIONS.h" |
5 |
|
6 |
CBOP |
7 |
C !ROUTINE: ATM_STORE_LAND |
8 |
C !INTERFACE: |
9 |
SUBROUTINE ATM_STORE_LAND( |
10 |
I bi, bj, |
11 |
I myTime, myIter, myThid ) |
12 |
|
13 |
C !DESCRIPTION: \bv |
14 |
C *==========================================================* |
15 |
C | SUBROUTINE ATM_STORE_LAND |
16 |
C | o Routine for saving Land fluxes from LAND pkg |
17 |
C | for export to coupling layer. |
18 |
C *==========================================================* |
19 |
C | This version interfaces to the LAND package. |
20 |
C *==========================================================* |
21 |
C \ev |
22 |
|
23 |
C !USES: |
24 |
IMPLICIT NONE |
25 |
|
26 |
C == Global variables == |
27 |
#ifdef ALLOW_LAND |
28 |
# include "LAND_SIZE.h" |
29 |
#else |
30 |
# include "SIZE.h" |
31 |
#endif |
32 |
|
33 |
#include "EEPARAMS.h" |
34 |
#include "PARAMS.h" |
35 |
#include "CPL_PARAMS.h" |
36 |
#ifdef ALLOW_LAND |
37 |
c #include "LAND_PARAMS.h" |
38 |
# include "LAND_VARS.h" |
39 |
#endif |
40 |
C == Global variables for coupling interface == |
41 |
#include "ATMCPL.h" |
42 |
|
43 |
C !INPUT/OUTPUT PARAMETERS: |
44 |
C bi, bj :: Tile indices |
45 |
C myTime :: Current model time |
46 |
C myIter :: Current timestep number |
47 |
C myThid :: my Thread Id number |
48 |
INTEGER bi, bj |
49 |
_RL myTime |
50 |
INTEGER myIter |
51 |
INTEGER myThid |
52 |
CEOP |
53 |
|
54 |
#ifdef ALLOW_LAND |
55 |
C !LOCAL VARIABLES: |
56 |
C i, j :: Loop counters |
57 |
INTEGER i, j |
58 |
_RL cplTimeFraction |
59 |
|
60 |
C o Accumulate RunOff from land bucket that will be exported to the |
61 |
C coupling layer. RunOff is per surface unit, in kg/m2/s |
62 |
cplTimeFraction = 1. _d 0 / DFLOAT(cplSendFrq_iter) |
63 |
RunOffTime(bi,bj) = RunOffTime(bi,bj) + cplTimeFraction |
64 |
DO j=1,sNy |
65 |
DO i=1,sNx |
66 |
RunOffFlux(i,j,bi,bj) = RunOffFlux(i,j,bi,bj) |
67 |
& + land_runOff(i,j,bi,bj)*cplTimeFraction |
68 |
ENDDO |
69 |
ENDDO |
70 |
|
71 |
C o Accumulate RunOff Energy from land bucket that will be exported |
72 |
C to the coupling layer. RunOff Energy is per surface unit, in W/m2. |
73 |
cplTimeFraction = 1. _d 0 / DFLOAT(cplSendFrq_iter) |
74 |
ROEnFxTime(bi,bj) = ROEnFxTime(bi,bj) + cplTimeFraction |
75 |
DO j=1,sNy |
76 |
DO i=1,sNx |
77 |
RunOffEnFx(i,j,bi,bj) = RunOffEnFx(i,j,bi,bj) |
78 |
& + land_enRnOf(i,j,bi,bj)*cplTimeFraction |
79 |
ENDDO |
80 |
ENDDO |
81 |
|
82 |
#endif /* ALLOW_LAND */ |
83 |
|
84 |
RETURN |
85 |
END |