1 |
C $Header: $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "OPPS_OPTIONS.h" |
5 |
|
6 |
CBOP |
7 |
C !ROUTINE: OPPS_READPARMS |
8 |
|
9 |
C !INTERFACE: ========================================================== |
10 |
SUBROUTINE OPPS_READPARMS( myThid ) |
11 |
|
12 |
C !DESCRIPTION: |
13 |
C Initialize OPPS parameters, read in data.opps |
14 |
|
15 |
C !USES: =============================================================== |
16 |
IMPLICIT NONE |
17 |
#include "SIZE.h" |
18 |
#include "EEPARAMS.h" |
19 |
#include "OPPS.h" |
20 |
#include "PARAMS.h" |
21 |
|
22 |
C !INPUT PARAMETERS: =================================================== |
23 |
C myThid :: thread number |
24 |
INTEGER myThid |
25 |
|
26 |
C !OUTPUT PARAMETERS: ================================================== |
27 |
C none |
28 |
|
29 |
#ifdef ALLOW_OPPS |
30 |
|
31 |
C !LOCAL VARIABLES: ==================================================== |
32 |
C iUnit :: unit number for I/O |
33 |
C msgBuf :: message buffer |
34 |
INTEGER iUnit |
35 |
CHARACTER*(MAX_LEN_MBUF) msgBuf |
36 |
CEOP |
37 |
|
38 |
NAMELIST /OPPS_PARM01/ |
39 |
& MAX_ABE_ITERATIONS, |
40 |
& OPPSdebugLevel, |
41 |
& PlumeRadius, |
42 |
& STABILITY_THRESHOLD, |
43 |
& FRACTIONAL_AREA, |
44 |
& MAX_FRACTIONAL_AREA, |
45 |
& VERTICAL_VELOCITY, |
46 |
& ENTRAINMENT_RATE, |
47 |
& useGCMwVel, |
48 |
& OPPSdumpFreq, |
49 |
& OPPStaveFreq, |
50 |
& OPPSwriteState |
51 |
|
52 |
C This routine has been called by the main model so we set our |
53 |
C internal flag to indicate we are in business |
54 |
OPPSisON=.TRUE. |
55 |
|
56 |
C Set defaults values for parameters in OPPS.h |
57 |
MAX_ABE_ITERATIONS = 1 |
58 |
OPPSdebugLevel = 0 |
59 |
PlumeRadius = 100. _d 0 |
60 |
STABILITY_THRESHOLD = -1. _d -4 |
61 |
FRACTIONAL_AREA = .1 _d 0 |
62 |
MAX_FRACTIONAL_AREA = .8 _d 0 |
63 |
VERTICAL_VELOCITY = .03 _d 0 |
64 |
ENTRAINMENT_RATE = -.05 _d 0 |
65 |
OPPSdumpFreq = dumpFreq |
66 |
OPPStaveFreq = taveFreq |
67 |
OPPSwriteState = .FALSE. |
68 |
useGCMwVel = .FALSE. |
69 |
|
70 |
C Open and read the data.opps file |
71 |
_BEGIN_MASTER(myThid) |
72 |
WRITE(msgBuf,'(A)') ' OPPS_READPARMS: opening data.opps' |
73 |
CALL PRINT_MESSAGE(msgBuf, standardMessageUnit, |
74 |
& SQUEEZE_RIGHT , 1) |
75 |
CALL OPEN_COPY_DATA_FILE( |
76 |
I 'data.opps', 'OPPS_READPARMS', |
77 |
O iUnit, |
78 |
I myThid ) |
79 |
READ(UNIT=iUnit,NML=OPPS_PARM01) |
80 |
WRITE(msgBuf,'(A)') |
81 |
& ' OPPS_READPARMS: finished reading data.opps' |
82 |
CALL PRINT_MESSAGE(msgBuf, standardMessageUnit, |
83 |
& SQUEEZE_RIGHT , 1) |
84 |
|
85 |
C Close the open data file |
86 |
CLOSE(iUnit) |
87 |
_END_MASTER(myThid) |
88 |
|
89 |
C Everyone else must wait for the parameters to be loaded |
90 |
_BARRIER |
91 |
|
92 |
C Now set-up any remaining parameters that result from the input parameters |
93 |
e2 = 2.*ENTRAINMENT_RATE |
94 |
#endif /* ALLOW_OPPS */ |
95 |
|
96 |
RETURN |
97 |
END |