/[MITgcm]/MITgcm/pkg/ocn_compon_interf/ocn_store_my_data.F
ViewVC logotype

Contents of /MITgcm/pkg/ocn_compon_interf/ocn_store_my_data.F

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


Revision 1.6 - (show annotations) (download)
Thu Jul 18 20:02:08 2013 UTC (10 years, 11 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint64y, checkpoint64x, checkpoint64z, checkpoint64q, checkpoint64p, checkpoint64s, checkpoint64r, checkpoint64u, checkpoint64t, checkpoint64w, checkpoint64v, checkpoint64k, checkpoint64m, checkpoint64l, checkpoint64o, checkpoint64n, checkpoint65, checkpoint65p, checkpoint65j, checkpoint65k, checkpoint65h, checkpoint65i, checkpoint65n, checkpoint65o, checkpoint65l, checkpoint65m, checkpoint65b, checkpoint65c, checkpoint65a, checkpoint65f, checkpoint65g, checkpoint65d, checkpoint65e
Changes since 1.5: +27 -28 lines
remove cpl_earlyExpImpCall=F option (was mainly a hack added for the old
 staggerTimeStep implementation) and disable (retired) corresponding
 parameter.

1 C $Header: /u/gcmpack/MITgcm/pkg/ocn_compon_interf/ocn_store_my_data.F,v 1.5 2009/01/05 15:21:36 dfer Exp $
2 C $Name: $
3 #include "PACKAGES_CONFIG.h"
4 #include "CPP_OPTIONS.h"
5
6 C !ROUTINE: OCN_STORE_MY_DATA
7 C !INTERFACE:
8 SUBROUTINE OCN_STORE_MY_DATA(
9 I myTime, myIter, bi,bj, myThid )
10
11 C !DESCRIPTION: \bv
12 C *==========================================================*
13 C | SUBROUTINE OCN_STORE_MY_DATA |
14 C | o Routine for controlling storage of coupling data to |
15 C | to the coupling layer. |
16 C *==========================================================*
17 C | This version talks to the MIT Coupler. It uses the MIT |
18 C | Coupler "checkpoint1" library calls. |
19 C *==========================================================*
20 C \ev
21
22 C !USES:
23 IMPLICIT NONE
24
25 C == Global variables ==
26 #include "SIZE.h"
27 #include "EEPARAMS.h"
28 #include "PARAMS.h"
29 #include "CPL_PARAMS.h"
30 #include "GRID.h"
31 #include "SURFACE.h"
32 #include "DYNVARS.h"
33 #include "OCNIDS.h"
34 #include "OCNCPL.h"
35 c#ifdef ALLOW_DIC
36 c# include "DIC_VARS.h"
37 c#endif
38
39 C !INPUT/OUTPUT PARAMETERS:
40 C == Routine Arguments ==
41 C myTime :: Current time in simulation
42 C myIter :: Current timestep number
43 C bi,bj :: Current tile indices
44 C myThid :: my Thread Id. number
45 _RL myTime
46 INTEGER myIter
47 INTEGER bi,bj
48 INTEGER myThid
49 CEOP
50
51 C !FUNCTIONS:
52 c INTEGER ILNBLNK
53
54 C !LOCAL VARIABLES:
55 C == Local variables ==
56 C i,j :: Loop variables
57 INTEGER i,j
58
59 DO j=1,sNy
60 DO i=1,sNx
61 SSTocn2cpl(i,j,bi,bj) = theta(i,j,1,bi,bj)
62 SSSocn2cpl(i,j,bi,bj) = salt (i,j,1,bi,bj)
63 ENDDO
64 ENDDO
65 #ifdef NONLIN_FRSURF
66 IF ( nonlinFreeSurf.GT.0 .AND. staggerTimeStep ) THEN
67 IF ( select_rStar.GT.0 ) THEN
68 DO j=1,sNy
69 DO i=1,sNx
70 ocMxlD2cpl(i,j,bi,bj) =
71 & h0FacC(i,j,1,bi,bj)*rStarFacC(i,j,bi,bj)*drF(1)
72 ENDDO
73 ENDDO
74 ELSE
75 DO j=1,sNy
76 DO i=1,sNx
77 ocMxlD2cpl(i,j,bi,bj) = hFac_surfC(i,j,bi,bj)*drF(1)
78 ENDDO
79 ENDDO
80 ENDIF
81 ELSE
82 #else /* NONLIN_FRSURF */
83 IF (.TRUE.) THEN
84 #endif /* NONLIN_FRSURF */
85 DO j=1,sNy
86 DO i=1,sNx
87 ocMxlD2cpl(i,j,bi,bj) = hFacC(i,j,1,bi,bj)*drF(1)
88 ENDDO
89 ENDDO
90 ENDIF
91
92 DO j=1,sNy
93 DO i=1,sNx
94 vSqocn2cpl(i,j,bi,bj) =
95 & ( uVel(i , j,1,bi,bj)*uVel(i , j,1,bi,bj)
96 & + uVel(i+1,j,1,bi,bj)*uVel(i+1,j,1,bi,bj)
97 & + vVel(i,j+1,1,bi,bj)*vVel(i,j+1,1,bi,bj)
98 & + vVel(i,j , 1,bi,bj)*vVel(i,j , 1,bi,bj)
99 & )*0.5 _d 0
100 ENDDO
101 ENDDO
102
103 c#ifdef ALLOW_DIC
104 c IF ( ocnCpl_exchange_DIC ) THEN
105 c DO j=1,sNy
106 c DO i=1,sNx
107 c fluxCO2cpl(i,j,bi,bj) = fluxCO2(i,j,bi,bj)
108 c ENDDO
109 c ENDDO
110 c ENDIF
111 c#endif
112
113 RETURN
114 END

  ViewVC Help
Powered by ViewVC 1.1.22