********> bugfix.50 Author: James Caldwell Date: 10/27/92 Programs: MINMD Severity: Serious affect on runtime - other problems possible Problem: iftres=0 with belly causes huge nonbonded list Cause: Variables iptres and iptatm were set wrong in mdread.f Fix: Make the following changes to mdread.f ---------------------------------- *** OLD mdread.f --- NEW mdread.f *************** *** 319,364 **** 8888 format(t2,'%MINMD-F-VALUES, NTB = ',i3,' and ifbox = ',i3) call mexit(6, 1) endif ! if(iptres.eq.0) iptres = nres ! C ! C ----- LOAD THE SUBMOLECULE INDEX IF ASKED ----- ! C ! c IF(IFTRES.EQ.2) CALL GETSPM(NSPM,NRES,IX(I02),IX(I70)) ! C ! C ----- SET THE DEFAULT VALUES FOR SOME VARIABLES ----- ! C ! if(ntt.eq.2.and.iptres.eq.0) iptres=nres ! if(iptres.eq.0.and.ntt.eq.1) iptres = nres if(JPTRES.gt.0) then iptres = jptRES iptatm = ix(i02+jptres)-1 ! write(6,'(''pointers reset: iptres = '',i5,'' iptatm = '', ! $ i6)')iptres,iptatm else iptatm = ix(i02+iptres)-1 ! write(6,'(''pointers: iptres = '',i5,'' iptatm = '', ! $ i6)')iptres,iptatm endif ! c if(ifbox .eq. 0) then ! NPM = 1 ! NRP = NATOM ! NSM = 0 ! NRAM = 0 ! nsolrs = 0 ! c else c nrp = # "protein atoms" c nram = # "solvent atoms" NSM = 1 ! NRAM = natom - ix(i02 + iptres) + 1 NPM = 1 NRP = NATOM - nram ! c write(6,'(t2,''#solute atoms= '',i5,'' #solvent = '',i5)') ! c $ nrp,nram ! nsolrs = nres - iptres ! c write(6,'(t2,''#solvent res = '',i5)')nsolrs ! c endif c ! IF(IFTRES.LE.1) IPTSOL = IPTRES IF(IFTRES.EQ.1) IPTRES = 0 IF(IFTRES.EQ.1) IPTATM = 0 c --- 319,352 ---- 8888 format(t2,'%MINMD-F-VALUES, NTB = ',i3,' and ifbox = ',i3) call mexit(6, 1) endif ! kptres = iptres ! if(iptres.eq.0) kptres = nres if(JPTRES.gt.0) then + kptres = jptRES iptres = jptRES iptatm = ix(i02+jptres)-1 ! write(6,'(''pointers reset: iptres = '', ! $ i5,'' iptatm = '', i6)')iptres,iptatm else iptatm = ix(i02+iptres)-1 ! write(6,'(//t2,''pointers: iptres = '', ! $ i5,'' iptatm = '',i6)')iptres,iptatm endif ! c c nrp = # "protein atoms" c nram = # "solvent atoms" + c NSM = 1 ! NRAM = natom - ix(i02 + kptres) + 1 NPM = 1 NRP = NATOM - nram ! nsolrs = nres - kptres ! c write(6,'(//t2,''%MINMD-I-#solute atoms= '', ! c $ i5,'' #solvent atoms= '',i5)') nrp,nram ! nsolrs = nres - kptres ! c write(6,'(t2,''%MINMD-I-#solvent residues = '',i5)')nsolrs c ! IF(IFTRES.LE.1) IPTSOL = KPTRES IF(IFTRES.EQ.1) IPTRES = 0 IF(IFTRES.EQ.1) IPTATM = 0 c ----------- Temporary workarounds: None, other than avoiding iftres=0 with belly. ---