forked from altMITgcm/MITgcm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ocn_export_ocnconfig.F
68 lines (55 loc) · 1.78 KB
/
ocn_export_ocnconfig.F
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
C $Header: /u/gcmpack/MITgcm/pkg/ocn_compon_interf/ocn_export_ocnconfig.F,v 1.5 2015/11/12 00:53:46 jmc Exp $
C $Name: $
#include "OCN_CPL_OPTIONS.h"
CBOP 0
C !ROUTINE: OCN_EXPORT_OCNCONFIG
C !INTERFACE:
SUBROUTINE OCN_EXPORT_OCNCONFIG( myThid )
C !DESCRIPTION:
C *==========================================================*
C | SUBROUTINE OCN_EXPORT_OCNCONFIG
C | o Routine for exporting ocean config to coupling level.
C *==========================================================*
C | This version talks to the MIT Coupler. It uses the MIT
C | Coupler "checkpoint1" library calls.
C *==========================================================*
C !USES:
IMPLICIT NONE
C == Global variables ==
#include "SIZE.h"
#include "EEPARAMS.h"
#include "PARAMS.h"
#include "GRID.h"
#include "OCNIDS.h"
#include "OCNCPL.h"
C !INPUT/OUTPUT PARAMETERS:
C == Routine arguments ==
C myThid :: Thread number for this instance of the routine
INTEGER myThid
C !LOCAL VARIABLES:
INTEGER i,j,bi,bj
INTEGER tmpFld(1)
CEOP
DO bj = myByLo(myThid), myByHi(myThid)
DO bi = myBxLo(myThid), myBxHi(myThid)
DO j=1-OLy,sNy+OLy
DO i=1-OLx,sNx+OLx
ocMxlD2cpl(i,j,bi,bj) = hFacC(i,j,1,bi,bj)*drF(1)
ENDDO
ENDDO
ENDDO
ENDDO
C Send my configuration information to the coupler
_BARRIER
_BEGIN_MASTER( myThid )
C o Send number of coupler time-steps to do for this run
tmpFld(1) = nTimeSteps
CALL COMPSEND_I4VEC( 'nCouplingSteps', 1, tmpFld )
C o Send ocean model bathymetry map
CALL COMPSEND_R8TILES(
I ocnMxlDName, sNx, OLx, sNy, OLy, 1, nSx, nSy,
I ocMxlD2cpl )
_END_MASTER( myThid )
_BARRIER
RETURN
END