1 |
C $Header: /u/gcmpack/MITgcm/pkg/aim_compon_interf/atm_store_runoff.F,v 1.1 2003/12/15 02:44:48 jmc Exp $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "PACKAGES_CONFIG.h" |
5 |
#include "CPP_OPTIONS.h" |
6 |
|
7 |
CStartOfInterface |
8 |
SUBROUTINE ATM_STORE_RUNOFF( bi,bj, |
9 |
I myTime, |
10 |
I myIter, |
11 |
I myThid ) |
12 |
C /==========================================================\ |
13 |
C | SUBROUTINE ATM_STORE_RUNOFF | |
14 |
C | o Routine for saving atmos. RunOff from land bucket | |
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 |
#ifdef ALLOW_LAND |
23 |
#include "LAND_SIZE.h" |
24 |
#else |
25 |
#include "SIZE.h" |
26 |
#endif |
27 |
|
28 |
#include "EEPARAMS.h" |
29 |
#include "PARAMS.h" |
30 |
#include "CPL_PARAMS.h" |
31 |
|
32 |
#ifdef ALLOW_LAND |
33 |
c #include "LAND_PARAMS.h" |
34 |
#include "LAND_VARS.h" |
35 |
#endif |
36 |
C == Global variables for coupling interface == |
37 |
#include "ATMCPL.h" |
38 |
|
39 |
|
40 |
C == Routine arguments == |
41 |
C bi,bj - Tile index |
42 |
C myThid - Thread number for this instance of the routine |
43 |
C myIter - Current timestep number |
44 |
C myTime - Current model time |
45 |
INTEGER bi, bj |
46 |
_RL myTime |
47 |
INTEGER myIter |
48 |
INTEGER myThid |
49 |
CEndOfInterface |
50 |
|
51 |
#ifdef ALLOW_LAND |
52 |
C == Local variables == |
53 |
C I,J,K,II - Loop counters |
54 |
C conv_precip :: conversion factor for precip: from g.m-2.s-1 to m/s |
55 |
INTEGER I,J,K |
56 |
_RL cplTimeFraction |
57 |
|
58 |
C o Accumulate RunOff from land bucket that will be exported to the |
59 |
C coupling layer. RunOff is per surface unit, in m/s. |
60 |
cplTimeFraction = 1. _d 0 / DFLOAT(cplSendFrq_iter) |
61 |
RunOffTime(bi,bj) = RunOffTime(bi,bj) + cplTimeFraction |
62 |
DO J=1,sNy |
63 |
DO I=1,sNx |
64 |
RunOffFlux(I,J,bi,bj) = RunOffFlux(I,J,bi,bj) |
65 |
& + land_runOff(I,J,bi,bj)*cplTimeFraction |
66 |
ENDDO |
67 |
ENDDO |
68 |
|
69 |
#endif /* ALLOW_LAND */ |
70 |
|
71 |
RETURN |
72 |
END |