1 |
heimbach |
1.2 |
C $Header: /u/gcmpack/MITgcm/pkg/ctrl/optim_readparms.F,v 1.1 2001/07/13 13:40:17 heimbach Exp $ |
2 |
heimbach |
1.1 |
|
3 |
|
|
#include "CTRL_CPPOPTIONS.h" |
4 |
|
|
|
5 |
|
|
|
6 |
|
|
subroutine optim_readparms( |
7 |
|
|
I mythid |
8 |
|
|
& ) |
9 |
|
|
|
10 |
|
|
c ================================================================== |
11 |
|
|
c SUBROUTINE optim_readparms |
12 |
|
|
c ================================================================== |
13 |
|
|
c |
14 |
|
|
c o Initialise the optimization part of the ECCO release. |
15 |
|
|
c |
16 |
|
|
c started: Christian Eckert eckert@mit.edu 03-Mar-2000 |
17 |
|
|
c |
18 |
|
|
c changed: |
19 |
|
|
c |
20 |
|
|
c ================================================================== |
21 |
|
|
c SUBROUTINE optim_readparms |
22 |
|
|
c ================================================================== |
23 |
|
|
|
24 |
|
|
implicit none |
25 |
|
|
|
26 |
|
|
c == global variables == |
27 |
|
|
|
28 |
|
|
#include "EEPARAMS.h" |
29 |
|
|
|
30 |
|
|
#include "optim.h" |
31 |
|
|
|
32 |
|
|
c == routine arguments == |
33 |
|
|
|
34 |
|
|
integer mythid |
35 |
|
|
|
36 |
|
|
c == local variables == |
37 |
|
|
|
38 |
|
|
integer errio |
39 |
|
|
integer il |
40 |
heimbach |
1.2 |
integer iUnit |
41 |
heimbach |
1.1 |
|
42 |
|
|
character*(max_len_prec) record |
43 |
heimbach |
1.2 |
character*(max_len_mbuf) msgbuf |
44 |
heimbach |
1.1 |
|
45 |
|
|
c == external == |
46 |
|
|
|
47 |
|
|
integer ilnblnk |
48 |
|
|
external ilnblnk |
49 |
|
|
|
50 |
|
|
c == end of interface == |
51 |
|
|
|
52 |
|
|
c-- Optimization parameters. |
53 |
|
|
namelist /optim/ |
54 |
|
|
& optimcycle, nvars, |
55 |
|
|
& nondimcontrol, |
56 |
|
|
& numiter, nfunc, fmin, iprint, |
57 |
|
|
& epsf, epsx, epsg, |
58 |
|
|
& nupdate, eps |
59 |
|
|
|
60 |
|
|
_BEGIN_MASTER( mythid ) |
61 |
|
|
|
62 |
|
|
c-- Set default values. |
63 |
|
|
optimcycle = 0 |
64 |
|
|
nvars = 10 |
65 |
|
|
nondimcontrol = .false. |
66 |
|
|
numiter = 0 |
67 |
|
|
nfunc = 1 |
68 |
|
|
fmin = 0.0 _d 0 |
69 |
|
|
iprint = 10 |
70 |
|
|
epsx = 1.e-6 |
71 |
|
|
epsg = 1.e-6 |
72 |
|
|
eps = -1.e-6 |
73 |
|
|
nupdate = 0 |
74 |
|
|
|
75 |
heimbach |
1.2 |
WRITE(msgBuf,'(A)') 'OPTIM_READPARMS: opening data.optim' |
76 |
|
|
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit, |
77 |
|
|
& SQUEEZE_RIGHT , 1) |
78 |
|
|
|
79 |
|
|
CALL OPEN_COPY_DATA_FILE( |
80 |
|
|
I 'data.optim', 'OPTIM_READPARMS', |
81 |
|
|
O iUnit, |
82 |
|
|
I myThid ) |
83 |
|
|
|
84 |
|
|
READ(unit = iUnit, nml = optim) |
85 |
|
|
|
86 |
|
|
WRITE(msgBuf,'(A)') |
87 |
|
|
& 'OPTIM_READPARMS: finished reading data.optim' |
88 |
|
|
CALL PRINT_MESSAGE( msgBuf, standardMessageUnit, |
89 |
|
|
& SQUEEZE_RIGHT , 1) |
90 |
heimbach |
1.1 |
|
91 |
heimbach |
1.2 |
CLOSE( iUnit ) |
92 |
heimbach |
1.1 |
|
93 |
|
|
_END_MASTER( mythid ) |
94 |
|
|
|
95 |
|
|
_BARRIER |
96 |
|
|
|
97 |
|
|
return |
98 |
|
|
end |
99 |
|
|
|