Author: Dave Case Date: 9/25/91 PROBLEM: The documentation states that constraints read in the PARM program must be terminated with a blank card, but the program actually requires a card with 4 zero integers and two zero floats SYMPTOM: PARM exits with an error message; no incorrect results would be obtained, but users would be confused. FIX: Use the RFREE routines to read the constraints, since these interpret blanks as zeroes. rconst.f: + added line - deleted ! changed *** old rconst.f --- new rconst.f *************** *** 54,59 **** --- 54,61 ---- c Rev A mod: use double temps c also use doubles for arithmetic on parameters double precision conv, req1, conk + dimension ifld(7),ihol(1),ivar(4),fvar(2) + data ifld /4*2,2*3,0/ c c --- get PI / 180. --- CONV = 4.0d0*ATAN(1.0d0)/180.0d0 *************** *** 74,85 **** i = 0 51 continue i = i + 1 - * DO 51 I = 1,7500 ! this is supposed to be a do while (i1 .ne. 0) c ! c ---dac change 7/90: allow free format for constraint input c ! c READ(IN,52,end=1000) I1,J1,K1,L1,REQ1,CONK ! READ(IN,*,end=1000) I1,J1,K1,L1,REQ1,CONK IF(I1.LE.0) GO TO 53 IF(J1.LE.0) then WRITE(IOUT,54) I --- 76,94 ---- i = 0 51 continue i = i + 1 c ! c --- call to rfree mimics the following free-format read, ! c but interprets blanks as zero: c ! c READ(IN,*) I1,J1,K1,L1,REQ1,CONK ! c ! call rfree(ifld,ihol,ivar,fvar,IN,6) ! i1 = ivar(1) ! j1 = ivar(2) ! k1 = ivar(3) ! l1 = ivar(4) ! req1 = fvar(1) ! conk = fvar(2) IF(I1.LE.0) GO TO 53 IF(J1.LE.0) then WRITE(IOUT,54) I *************** *** 160,173 **** C ----- ADD 180. TO CONVVERT 1+COS TO 1-COS IN DIHEDRAL SECTION ---- C PHASE(MPTRA) = CONV*(REQ1+180.0d0) - * 51 CONTINUE go to 51 53 CONTINUE RETURN - 1000 continue - write(iout,'(/2x,a,a)') 'FATAL: End of file reached while', - + ' reading constraints. Needs blank card at end.' - call mexit(iout, 1) 52 FORMAT(4I5,2F10.2) 54 FORMAT(/2X,'FATAL: Constraint card number ',i5,' is bungled.') 9000 format(/5x,'Internal Coordinate Constraints:',/5x,'Type',5x, --- 169,177 ----