bugfix for pdbchain and for vdwpp weigth reading
authorAdam Sieradzan <adasko@piasek4.chem.univ.gda.pl>
Mon, 19 Aug 2019 13:18:11 +0000 (15:18 +0200)
committerAdam Sieradzan <adasko@piasek4.chem.univ.gda.pl>
Mon, 19 Aug 2019 13:18:11 +0000 (15:18 +0200)
source/wham/io_wham.F90

index 2e12a82..0fb9954 100644 (file)
@@ -478,7 +478,7 @@ allocate(ww(max_eneW))
       welpsb=ww(29)
       wvdwpsb=ww(28)
       welpp=ww(27)
-      wvdwpp=ww(26)
+      wvdwpp_nucl=ww(26)
       wscbase=ww(46)
       wpepbase=ww(47)
       wscpho=ww(48)
@@ -513,7 +513,7 @@ allocate(ww(max_eneW))
       weights(13)=wtor
       weights(14)=wtor_d
       weights(15)=0 !wstrain !
-      weights(16)=0 !wvdwpp !
+      weights(16)=wvdwpp !
       weights(17)=wbond
       weights(18)=0 !scal14 !
       weights(21)=wsccor
@@ -3745,9 +3745,11 @@ allocate(ww(max_eneW))
         mnum=molnum(i)
         iti=itype(i,mnum)
         if (iti.eq.ntyp1) then
+          if (itype(i-1,molnum(i-1)).eq.ntyp1) then
           ichain=ichain+1
           ires=0
           write (ipdb,'(a)') 'TER'
+          endif
         else
         ires=ires+1
         iatom=iatom+1