1 |
C $Header: /u/gcmpack/MITgcm/pkg/flt/flt_readparms.F,v 1.6 2011/01/12 19:00:52 jmc Exp $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "FLT_OPTIONS.h" |
5 |
|
6 |
SUBROUTINE FLT_READPARMS( myThid ) |
7 |
|
8 |
C ================================================================== |
9 |
C SUBROUTINE FLT_READPARMS |
10 |
C ================================================================== |
11 |
C o read float-pkg parameters from file "data.flt" |
12 |
C ================================================================== |
13 |
|
14 |
C !USES: |
15 |
IMPLICIT NONE |
16 |
|
17 |
#include "SIZE.h" |
18 |
#include "EEPARAMS.h" |
19 |
#include "PARAMS.h" |
20 |
#include "FLT_SIZE.h" |
21 |
#include "FLT.h" |
22 |
|
23 |
C == routine arguments == |
24 |
C myThid - thread number for this instance of the routine. |
25 |
INTEGER myThid |
26 |
|
27 |
C == local variables == |
28 |
CHARACTER*(MAX_LEN_MBUF) msgBuf |
29 |
INTEGER iUnit |
30 |
|
31 |
NAMELIST /FLT_NML/ flt_int_traj, flt_int_prof, |
32 |
& flt_selectTrajOutp, flt_selectProfOutp, |
33 |
& flt_noise, flt_deltaT, |
34 |
& flt_file, mapIniPos2Index |
35 |
|
36 |
C == end of interface == |
37 |
|
38 |
_BEGIN_MASTER(myThid) |
39 |
|
40 |
C Set default values. |
41 |
flt_deltaT = deltaTClock |
42 |
flt_int_traj = 3600. |
43 |
flt_int_prof = 43200. |
44 |
flt_noise = 0.0 |
45 |
flt_file = 'float_pos' |
46 |
mapIniPos2Index = .TRUE. |
47 |
flt_selectTrajOutp = 2 |
48 |
flt_selectProfOutp = 2 |
49 |
|
50 |
WRITE(msgBuf,'(A)') ' FLT_READPARMS: opening data.flt' |
51 |
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit, |
52 |
& SQUEEZE_RIGHT, myThid ) |
53 |
CALL OPEN_COPY_DATA_FILE( |
54 |
I 'data.flt', 'FLT_READPARMS', |
55 |
O iUnit, |
56 |
I myThid ) |
57 |
|
58 |
C Read parameters from open data file |
59 |
READ(UNIT=iUnit,NML=FLT_NML) |
60 |
WRITE(msgBuf,'(A)') ' FLT_READPARMS: finished reading data.flt' |
61 |
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit, |
62 |
& SQUEEZE_RIGHT, myThid ) |
63 |
C Close the open data file |
64 |
CLOSE(iUnit) |
65 |
|
66 |
C Do some checks |
67 |
c IF ( useFLT .AND. useOBCS ) THEN |
68 |
c WRITE(msgBuf,'(A,A)') |
69 |
c & 'S/R FLT_READPARMS: floats currently not implemented', |
70 |
c & ' with open boundaries' |
71 |
c CALL PRINT_ERROR( msgBuf , myThid) |
72 |
c STOP 'ABNORMAL END: S/R FLT_READPARMS' |
73 |
c ENDIF |
74 |
|
75 |
_END_MASTER(myThid) |
76 |
_BARRIER |
77 |
|
78 |
RETURN |
79 |
END |