/[MITgcm]/MITgcm/pkg/atm_compon_interf/atm_apply_import.F
ViewVC logotype

Diff of /MITgcm/pkg/atm_compon_interf/atm_apply_import.F

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

revision 1.1 by jmc, Fri May 21 19:59:38 2004 UTC revision 1.2 by jmc, Tue Sep 24 19:28:34 2013 UTC
# Line 7  C $Name$ Line 7  C $Name$
7  CBOP  CBOP
8  C     !ROUTINE: ATM_APPLY_IMPORT  C     !ROUTINE: ATM_APPLY_IMPORT
9  C     !INTERFACE:  C     !INTERFACE:
10        SUBROUTINE ATM_APPLY_IMPORT(        SUBROUTINE ATM_APPLY_IMPORT(
11       I               land_frc,       I               land_frc,
12       U               aimTsoce, aimSIfrc,       U               atmSST, atmSIfrc,
13       I               myTime, myIter, bi, bj, myThid )       I               myTime, myIter, bi, bj, myThid )
14    
15  C     !DESCRIPTION: \bv  C     !DESCRIPTION: \bv
16  C     *================================================================*  C     *================================================================*
17  C     | S/R ATM_APPLY_IMPORT  C     | S/R ATM_APPLY_IMPORT
18  C     | o Apply imported coupling data to AIM surface BC over ocean  C     | o Apply imported coupling data to ATM surface BC over ocean
19  C     *================================================================*  C     *================================================================*
20  C     | Note: when using sea-ice, fill in Mixed layer fields instead  C     | Note: when using sea-ice, fill in Mixed layer fields instead
21  C     |      to be used later as Atmos. + Sea-Ice surface oceanic BC.  C     |      to be used later as SST by Atmos. + Sea-Ice
22  C     *================================================================*  C     *================================================================*
23  C     \ev  C     \ev
24    
# Line 41  C-- Coupled to the Ocean : Line 41  C-- Coupled to the Ocean :
41  C     !INPUT/OUTPUT PARAMETERS:  C     !INPUT/OUTPUT PARAMETERS:
42  C     == Routine arguments ==  C     == Routine arguments ==
43  C     land_frc :: land fraction [0-1]  C     land_frc :: land fraction [0-1]
44  C     aimTsoce :: sea surface temp [K], used in AIM  C     atmSST   :: sea surface temp [K], used in ATM component
45  C     aimSIfrc :: sea-ice fraction [0-1]  C     atmSIfrc :: sea-ice fraction [0-1], used in ATM component
46  C     myTime   :: Current time of simulation ( s )  C     myTime   :: Current time of simulation ( s )
47  C     myIter   :: Current iteration number in simulation  C     myIter   :: Current iteration number in simulation
48  C     bi,bj    :: Tile index  C     bi,bj    :: Tile index
49  C     myThid   :: Number of this instance of the routine  C     myThid   :: Number of this instance of the routine
50        _RS  land_frc(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)        _RS  land_frc(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
51        _RL  aimTsoce(sNx,sNy)        _RL  atmSST  (sNx,sNy)
52        _RL  aimSIfrc(sNx,sNy)        _RL  atmSIfrc(sNx,sNy)
53        _RL myTime        _RL myTime
54        INTEGER myIter, bi, bj, myThid        INTEGER myIter, bi, bj, myThid
55  CEOP  CEOP
# Line 66  C     i,j    :: Loop counters Line 66  C     i,j    :: Loop counters
66  C--   Put fields from the ocean component in Mixed-layer arrays:  C--   Put fields from the ocean component in Mixed-layer arrays:
67    
68  C-    fill in hOceMxL with Mixed-layer Depth from the ocean component  C-    fill in hOceMxL with Mixed-layer Depth from the ocean component
69        IF ( useImportMxlD ) THEN         IF ( useImportMxlD ) THEN
70          DO j=1,sNy          DO j=1,sNy
71           DO i=1,sNx           DO i=1,sNx
72            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN
# Line 77  C-    fill in hOceMxL with Mixed-layer D Line 77  C-    fill in hOceMxL with Mixed-layer D
77         ENDIF         ENDIF
78    
79  C-    fill in tOceMxL with Sea-Surface Temp. from the ocean component  C-    fill in tOceMxL with Sea-Surface Temp. from the ocean component
80        IF ( useImportSST ) THEN         IF ( useImportSST ) THEN
81          DO j=1,sNy          DO j=1,sNy
82           DO i=1,sNx           DO i=1,sNx
83            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN
# Line 88  C-    fill in tOceMxL with Sea-Surface T Line 88  C-    fill in tOceMxL with Sea-Surface T
88         ENDIF         ENDIF
89    
90  C-    fill in sOceMxL with Sea-Surf Salinity from the ocean component  C-    fill in sOceMxL with Sea-Surf Salinity from the ocean component
91        IF ( useImportSSS ) THEN         IF ( useImportSSS ) THEN
92          DO j=1,sNy          DO j=1,sNy
93           DO i=1,sNx           DO i=1,sNx
94            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN
# Line 99  C-    fill in sOceMxL with Sea-Surf Sali Line 99  C-    fill in sOceMxL with Sea-Surf Sali
99         ENDIF         ENDIF
100    
101  C-    fill in v2ocMxL with surf. velocity^2  from the ocean component  C-    fill in v2ocMxL with surf. velocity^2  from the ocean component
102        IF ( useImportVsq ) THEN         IF ( useImportVsq ) THEN
103          DO j=1,sNy          DO j=1,sNy
104           DO i=1,sNx           DO i=1,sNx
105            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN
# Line 109  C-    fill in v2ocMxL with surf. velocit Line 109  C-    fill in v2ocMxL with surf. velocit
109          ENDDO          ENDDO
110         ENDIF         ENDIF
111    
112        ELSE        ELSEIF ( useAtm_Phys ) THEN
113  #else  #else
114        IF (.TRUE.) THEN        IF ( useAtm_Phys ) THEN
115  #endif /* ALLOW_THSICE */  #endif /* ALLOW_THSICE */
116    C--   supply imported fields to Atm_Phys pkg:
117    
118           IF ( useImportSST ) THEN
119            DO j=1,sNy
120             DO i=1,sNx
121                atmSST(i,j) = SSTocn(i,j,bi,bj)+celsius2K
122             ENDDO
123            ENDDO
124           ENDIF
125    
126          ELSE
127    C--   supply imported fields to AIM (Phys) pkg:
128    
129         IF ( useImportSST ) THEN         IF ( useImportSST ) THEN
130          DO j=1,sNy          DO j=1,sNy
# Line 120  C-    fill in v2ocMxL with surf. velocit Line 132  C-    fill in v2ocMxL with surf. velocit
132            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN            IF ( land_frc(i,j,bi,bj) .LT. 1. ) THEN
133    
134  C--   take SST from the ocean compon where Sea-Ice fraction is zero  C--   take SST from the ocean compon where Sea-Ice fraction is zero
135             IF ( aimSIfrc(i,j).EQ.0. ) THEN             IF ( atmSIfrc(i,j).EQ.0. ) THEN
136              aimTsoce(i,j) = SSTocn(i,j,bi,bj)+celsius2K              atmSST(i,j) = SSTocn(i,j,bi,bj)+celsius2K
137             ELSEIF ( SSTocn(i,j,bi,bj).GE. -1. _d 0)  THEN             ELSEIF ( SSTocn(i,j,bi,bj).GE. -1. _d 0)  THEN
138  C--   take SST from the ocean compon if clearly warmer than freezing  C--   take SST from the ocean compon if clearly warmer than freezing
139  C       then reset sea-ice fraction  C       then reset sea-ice fraction
140              aimTsoce(i,j) = SSTocn(i,j,bi,bj)+celsius2K              atmSST(i,j) = SSTocn(i,j,bi,bj)+celsius2K
141              aimSIfrc(i,j) = 0.              atmSIfrc(i,j) = 0.
142             ENDIF             ENDIF
143    
144            ENDIF            ENDIF

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

  ViewVC Help
Powered by ViewVC 1.1.22