1 |
C $Header: /u/gcmpack/MITgcm/pkg/fizhi/fizhi_readparms.F,v 1.4 2004/07/22 22:33:55 molod Exp $ |
2 |
C $Name: $ |
3 |
|
4 |
#include "FIZHI_OPTIONS.h" |
5 |
subroutine fizhi_readparms (myThid) |
6 |
C*********************************************************************** |
7 |
C Purpose |
8 |
C ------- |
9 |
C Read Fizhi Namelist and Get the Model Date and Time from File |
10 |
C |
11 |
C Arguments Description |
12 |
C ---------------------- |
13 |
C myThid ... Process(or) number |
14 |
C*********************************************************************** |
15 |
implicit none |
16 |
|
17 |
#include "chronos.h" |
18 |
#include "EEPARAMS.h" |
19 |
|
20 |
integer myThid |
21 |
|
22 |
c Declare Local Variables |
23 |
c ----------------------- |
24 |
character*(MAX_LEN_MBUF) msgBuf |
25 |
integer ku |
26 |
integer nymdbegin, nhmsbegin |
27 |
integer nymdcurrent, nhmscurrent |
28 |
|
29 |
namelist / fizhi_list / nymdbegin, nhmsbegin |
30 |
|
31 |
C ********************************************************************** |
32 |
C **** Initialize and Read Fizhi Namelist **** |
33 |
C ********************************************************************** |
34 |
|
35 |
WRITE(msgBuf,'(A)') ' FIZHI_READPARMS: opening data.fizhi' |
36 |
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit,SQUEEZE_RIGHT,1) |
37 |
|
38 |
CALL OPEN_COPY_DATA_FILE('data.fizhi', 'FIZHI_READPARMS', |
39 |
. ku,myThid ) |
40 |
read (ku,NML=fizhi_list) |
41 |
close (ku) |
42 |
|
43 |
C ********************************************************************** |
44 |
C **** Read Supplemental Ascii File with Current Time Info **** |
45 |
C ********************************************************************** |
46 |
|
47 |
open(10,file='datetime',form='formatted') |
48 |
read(10,1000)nymdcurrent,nhmscurrent |
49 |
close (10) |
50 |
1000 format(i8,2x,i6) |
51 |
|
52 |
C ********************************************************************** |
53 |
C **** Fill chronos Common Block with Namelist and Other File Info **** |
54 |
C ********************************************************************** |
55 |
|
56 |
nymd0 = nymdbegin |
57 |
nhms0 = nhmsbegin |
58 |
nymd = nymdcurrent |
59 |
nhms = nhmscurrent |
60 |
|
61 |
C ********************************************************************** |
62 |
C **** Echo Date and Time Info **** |
63 |
C ********************************************************************** |
64 |
|
65 |
_BEGIN_MASTER(myThid) |
66 |
print *, ' Begin Date ',nymd0,' Begin Time ',nhms0 |
67 |
print *, 'Current Date ',nymd,' Current Time ',nhms |
68 |
_END_MASTER(myThid) |
69 |
|
70 |
return |
71 |
end |