/[MITgcm]/MITgcm/pkg/obcs/obcs_readparms.F
ViewVC logotype

Contents of /MITgcm/pkg/obcs/obcs_readparms.F

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


Revision 1.5 - (show annotations) (download)
Mon May 14 21:36:45 2001 UTC (23 years ago) by heimbach
Branch: MAIN
CVS Tags: checkpoint46n_post, checkpoint51k_post, checkpoint47e_post, checkpoint52l_pre, checkpoint44e_post, hrcube4, hrcube5, checkpoint46l_post, checkpoint46g_pre, checkpoint47c_post, release1_p13_pre, checkpoint50c_post, checkpoint46f_post, checkpoint52d_pre, checkpoint48e_post, checkpoint50c_pre, checkpoint44f_post, checkpoint46b_post, checkpoint52j_pre, checkpoint43a-release1mods, checkpoint51o_pre, release1_p13, checkpoint40pre3, checkpoint40pre1, checkpoint51l_post, checkpoint40pre7, checkpoint40pre6, checkpoint48i_post, checkpoint40pre9, checkpoint40pre8, checkpoint46l_pre, checkpoint52l_post, checkpoint52k_post, chkpt44d_post, checkpoint54, checkpoint51, checkpoint50, checkpoint53, checkpoint52, release1_p8, release1_p9, checkpoint50d_post, release1_p1, release1_p2, release1_p3, release1_p4, release1_p5, release1_p6, release1_p7, checkpoint52f_post, checkpoint50b_pre, checkpoint44e_pre, checkpoint51f_post, release1_b1, checkpoint48b_post, checkpoint43, checkpoint51d_post, checkpoint48c_pre, checkpoint47d_pre, checkpoint51t_post, checkpoint51n_post, release1_chkpt44d_post, checkpoint52i_pre, hrcube_1, hrcube_2, hrcube_3, checkpoint51s_post, checkpoint47a_post, checkpoint48d_pre, checkpoint51j_post, checkpoint47i_post, checkpoint52e_pre, checkpoint52e_post, checkpoint51n_pre, checkpoint47d_post, checkpoint53d_post, checkpoint46d_pre, checkpoint40pre2, checkpoint48d_post, release1-branch_tutorials, checkpoint48f_post, checkpoint45d_post, checkpoint52b_pre, checkpoint46j_pre, checkpoint51l_pre, checkpoint52m_post, chkpt44a_post, checkpoint44h_pre, checkpoint48h_post, checkpoint51q_post, checkpoint40pre4, checkpoint51b_pre, checkpoint46a_post, checkpoint47g_post, checkpoint52b_post, checkpoint52c_post, checkpoint46j_post, checkpoint51h_pre, checkpoint46k_post, chkpt44c_pre, checkpoint48a_post, checkpoint45a_post, checkpoint50f_post, checkpoint50a_post, checkpoint50f_pre, checkpoint52f_pre, release1_p12, release1_p10, release1_p11, release1_p16, release1_p17, release1_p14, release1_p15, checkpoint47j_post, checkpoint54a_pre, checkpoint53c_post, branch-exfmods-tag, checkpoint44g_post, branchpoint-genmake2, checkpoint54a_post, checkpoint46e_pre, checkpoint51r_post, checkpoint48c_post, checkpoint45b_post, checkpoint46b_pre, checkpoint51i_post, release1-branch-end, release1_final_v1, checkpoint51b_post, checkpoint51c_post, checkpoint46c_pre, checkpoint53a_post, checkpoint46, checkpoint47b_post, checkpoint44b_post, checkpoint46h_pre, checkpoint52d_post, checkpoint53g_post, checkpoint46m_post, checkpoint46a_pre, checkpoint50g_post, checkpoint45c_post, checkpoint44h_post, checkpoint46g_post, release1_p12_pre, checkpoint39, checkpoint52a_pre, checkpoint50h_post, checkpoint52i_post, checkpoint50e_pre, checkpoint50i_post, checkpoint51i_pre, checkpoint52h_pre, checkpoint53f_post, checkpoint40pre5, checkpoint52j_post, checkpoint47f_post, checkpoint50e_post, chkpt44a_pre, checkpoint46i_post, checkpoint46c_post, branch-netcdf, checkpoint50d_pre, checkpoint52n_post, checkpoint53b_pre, checkpoint46e_post, release1_beta1, checkpoint51e_post, checkpoint44b_pre, checkpoint42, checkpoint40, checkpoint41, checkpoint47, checkpoint44, checkpoint45, checkpoint48, checkpoint49, checkpoint46h_post, checkpoint51o_post, checkpoint51f_pre, chkpt44c_post, checkpoint48g_post, checkpoint53b_post, checkpoint47h_post, checkpoint52a_post, checkpoint44f_pre, checkpoint51g_post, ecco_c52_e35, checkpoint46d_post, checkpoint50b_post, release1-branch_branchpoint, checkpoint51m_post, checkpoint53d_pre, checkpoint51a_post, checkpoint51p_post, checkpoint51u_post
Branch point for: branch-exfmods-curt, release1_final, release1-branch, branch-genmake2, release1, branch-nonh, tg2-branch, ecco-branch, release1_50yr, netcdf-sm0, checkpoint51n_branch, release1_coupled
Changes since 1.4: +24 -3 lines
Added runtime parameters.

1 C $Header: /u/gcmpack/models/MITgcmUV/pkg/obcs/obcs_readparms.F,v 1.4 2001/04/10 22:35:27 heimbach Exp $
2 C $Name: $
3
4 #include "OBCS_OPTIONS.h"
5
6 SUBROUTINE OBCS_READPARMS( myThid )
7 C /==========================================================\
8 C | SUBROUTINE OBCS_READPARMS |
9 C | o Routine to initialize OBCS variables and constants. |
10 C |==========================================================|
11 C \==========================================================/
12 IMPLICIT NONE
13
14 C === Global variables ===
15 #include "SIZE.h"
16 #include "EEPARAMS.h"
17 #include "PARAMS.h"
18 #include "OBCS.h"
19 #ifdef ALLOW_ORLANSKI
20 #include "ORLANSKI.h"
21 #endif
22
23 C === Routine arguments ===
24 INTEGER myThid
25
26 #ifdef ALLOW_OBCS
27
28 NAMELIST /OBCS_PARM01/
29 & OB_Jnorth,OB_Jsouth,OB_Ieast,OB_Iwest,
30 & useOrlanskiNorth,useOrlanskiSouth,
31 & useOrlanskiEast,useOrlanskiWest,
32 & OBNuFile,OBNvFile,OBNtFile,OBNsFile,
33 & OBSuFile,OBSvFile,OBStFile,OBSsFile,
34 & OBEuFile,OBEvFile,OBEtFile,OBEsFile,
35 & OBWuFile,OBWvFile,OBWtFile,OBWsFile
36
37 #ifdef ALLOW_ORLANSKI
38 NAMELIST /OBCS_PARM02/
39 & CMAX, cvelTimeScale
40 #endif
41
42 C === Local variables ===
43 C msgBuf - Informational/error meesage buffer
44 C iUnit - Work variable for IO unit number
45 CHARACTER*(MAX_LEN_MBUF) msgBuf
46 INTEGER iUnit
47 INTEGER I,J
48
49 C-- OBCS_READPARMS has been called so we know that
50 C the package is active.
51 OBCSIsOn=.TRUE.
52
53 _BEGIN_MASTER(myThid)
54
55 WRITE(msgBuf,'(A)') ' OBCS_READPARMS: opening data.obcs'
56 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
57 & SQUEEZE_RIGHT , 1)
58
59 CALL OPEN_COPY_DATA_FILE(
60 I 'data.obcs', 'OBCS_READPARMS',
61 O iUnit,
62 I myThid )
63
64 C-- Default flags and values for OBCS
65 DO I=1,Nx
66 OB_Jnorth(I)=0
67 OB_Jsouth(I)=0
68 ENDDO
69 DO J=1,Ny
70 OB_Ieast(J)=0
71 OB_Iwest(J)=0
72 ENDDO
73 useOrlanskiNorth=.FALSE.
74 useOrlanskiSouth=.FALSE.
75 useOrlanskiEast =.FALSE.
76 useOrlanskiWest =.FALSE.
77
78 OBNuFile = ' '
79 OBNvFile = ' '
80 OBNtFile = ' '
81 OBNsFile = ' '
82 OBSuFile = ' '
83 OBSvFile = ' '
84 OBStFile = ' '
85 OBSsFile = ' '
86 OBEuFile = ' '
87 OBEvFile = ' '
88 OBEtFile = ' '
89 OBEsFile = ' '
90 OBWuFile = ' '
91 OBWvFile = ' '
92 OBWtFile = ' '
93 OBWsFile = ' '
94
95 C-- Read parameters from open data file
96 READ(UNIT=iUnit,NML=OBCS_PARM01)
97
98 C Account for periodicity if negative indices were supplied
99 DO J=1,Ny
100 IF (OB_Ieast(J).lt.0) OB_Ieast(J)=OB_Ieast(J)+Nx+1
101 ENDDO
102 DO I=1,Nx
103 IF (OB_Jnorth(I).lt.0) OB_Jnorth(I)=OB_Jnorth(I)+Ny+1
104 ENDDO
105 write(*,*) 'OB Jn =',OB_Jnorth
106 write(*,*) 'OB Js =',OB_Jsouth
107 write(*,*) 'OB Ie =',OB_Ieast
108 write(*,*) 'OB Iw =',OB_Iwest
109
110 #ifdef ALLOW_ORLANSKI
111 C Default Orlanski radiation parameters
112 CMAX = 0.45 _d 0 /* maximum allowable phase speed-CFL for AB-II */
113 cvelTimeScale = 2000.0 _d 0 /* Averaging period for phase speed in sec. */
114 IF (useOrlanskiNorth.OR.
115 & useOrlanskiSouth.OR.
116 & useOrlanskiEast.OR.
117 & useOrlanskiWest)
118 & READ(UNIT=iUnit,NML=OBCS_PARM02)
119 #endif
120
121 WRITE(msgBuf,'(A)') ' OBCS_READPARMS: finished reading data.obcs'
122 CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,
123 & SQUEEZE_RIGHT , 1)
124
125 C-- Close the open data file
126 CLOSE(iUnit)
127 _END_MASTER(myThid)
128
129 C-- Everyone else must wait for the parameters to be loaded
130 _BARRIER
131
132 #endif /* ALLOW_OBCS */
133 RETURN
134 END

  ViewVC Help
Powered by ViewVC 1.1.22