28 subroutine srchc( line )
43 integer i,itmp,bflag,jx,jx1,jx2,lth,lu
44 double precision ax,bx,cx,fa,fb,fc,fmin,fval,pmin
45 character token*30,prmID*9,tagtmp*9
50 integer ipfind,indtkn,itrim
51 double precision l1pfun,brent,getprm,gammq,residx,corrl,wtdres
52 logical ftoken,tcheck,spcpar
53 external l1pfun,brent,ftoken,spcpar,tcheck,
54 # ipfind,indtkn,itrim,getprm,residx,corrl,wtdres
56 character*8 keywrd(nkeywd)
57 data keywrd /
'XTOL',
'FTOL',
'STEP',
'BOUND',
'MAXFUN',
'SRANGE'/
64 call gettkn(line,token,lth)
68 ixp1p=ipfind(token,lth)
74 write(
luttyo,1002) token(:lth)
79 write(
luttyo,1011) token(:lth)
83 if (
ixp1p.lt.-100)
then
85 else if (
ixp1p.lt.0)
then
105 write (
luout,1004) prmid(:itrim(prmid))
107 #
write (
luttyo,1004) prmid(:itrim(prmid))
118 write (prmid(itrim(prmid)+1:),1005)
ixs1p
136 13
call gettkn(line,token,lth)
181 write (
luout,1009) prmid(:itrim(prmid))
195 else if (bflag.eq.
nomin)
then
196 write (
luttyo,1012) prmid(:itrim(prmid)),cx
206 write (
luout,1010) ax,cx
211 fmin=brent(ax,bx,cx,fb,l1pfun,
ptol,
pftol,pmin,bflag)
218 write (
luttyo,1008) prmid,pmin
225 write (
luttyo,1006) prmid,pmin
270 if (token(:lth).eq.keywrd(i)(:lth))
goto 16
273 write (
luttyo,1000) token(:lth)
280 16
call gettkn(line,token,lth)
283 write(
luttyo,1003) keywrd(i)
287 if (ftoken(token,lth,fval))
then
292 else if (i.eq.2)
then
295 else if (i.eq.3)
then
298 else if (i.eq.4)
then
301 else if (i.eq.5)
then
304 else if (i.eq.6)
then
309 write(
luttyo,1001) token(:lth)
315 1000
format(
'*** Unrecognized SEARCH keyword: ''',a,
''' ***')
316 1001
format(
'*** Numeric value expected: ''',a,
''' ***')
317 1002
format(
'*** ''',a,
''' is not a variable parameter ***')
318 1003
format(
'*** No value given for ''',a,
''' ***')
319 1004
format(
'*** ',a,
' is not the same for all currently defined',
321 1005
format(
'(',i1,
')')
322 1006
format(/2
x,
'Minimum found at ',a,
'= ',g12.6/)
323 1007
format(
'*** Terminated by user during bracketing of minimum ***')
324 1008
format(
'*** Terminated by user ***'/
'Best point is ',a,
'= ',f9.5/)
325 1009
format(/2
x,
'Bracketing the minimum in ',a)
326 1010
format(/2
x,
'Minimum is between ',f9.5,
' and ',f9.5/)
327 1011
format(
'*** ',a,
' is series parameter: cannot be searched ***')
328 1012
format(
'*** Minimum is at step bound ***'/2
x,a,
'=',f9.5/)
329 2036
format(10
x,
'Residual norm= ',g13.6/
330 # 10
x,
'Chi-squared=',g13.6,5
x,
'Reduced Chi-sq=',g13.6/
331 # 10
x,
'Correlation = ',f8.5,5
x,
'Residual index =',f8.5/)
332 2038
format(12
x,
'Goodness of fit from chi-squared (Q)=',g13.6)
integer, dimension(mxvar), save ixst
double precision, save srange
integer, dimension(mxspc), save ixsp
void FORTRAN() uncatchc(int *flag)
character *6, dimension(nalias), save alias1
double precision, save fnmin
double precision, save qfit
double precision, save pstep
double precision, save rdchsq
double precision, dimension(nfprm, mxsite), target, save fparm
double precision, save pftol
subroutine touppr(string, lth)
double precision, save fnorm
subroutine gettkn(line, token, lth)
Written for free-form input of parameters for slow-motional calculations. Returns a token consisting ...
integer, dimension(mxvar), save ixpr
integer, parameter mxsite
double precision, dimension(mxpt), save fvec
void FORTRAN() catchc(int *flag)
integer, parameter luttyo
double precision, save pbound
double precision, save ptol
double precision, dimension(mxspc), save rmsn
subroutine mnbrak(ax, bx, cx, fa, fb, fc, func, iflag, bound)
integer, dimension(mxspc), save npts
subroutine setprm(ixparm, ixsite, fval)
This file contains two routines that set a given parameter, specified by an index into the fparm or i...
character *6, dimension(nfprm), save parnam
character *9, dimension(mxjcol), save tag
double precision, save chisqr
double precision, dimension(mxjcol), save x
character *6, dimension(nalias), save alias2