X-Git-Url: http://mmka.chem.univ.gda.pl/gitweb/?a=blobdiff_plain;f=source%2Funres%2Fsrc_MD-M%2Fgeomout.F;h=4673c4e434759a518e60893e3c8a570106f1aca7;hb=0bb81c1c3180a2079d70af7dd534295e1e0b1e4c;hp=c6a3944cbb74cb0bde09d92dcd169d6bd116a223;hpb=2ec03757b68a8fb1a604a7f84f83086291fc75db;p=unres.git diff --git a/source/unres/src_MD-M/geomout.F b/source/unres/src_MD-M/geomout.F index c6a3944..4673c4e 100644 --- a/source/unres/src_MD-M/geomout.F +++ b/source/unres/src_MD-M/geomout.F @@ -91,7 +91,7 @@ cmodel write (iunit,'(a5,i6)') 'MODEL',1 ires=0 do i=nnt,nct iti=itype(i) - if (iti.eq.ntyp1) then + if ((iti.eq.ntyp1).and.((itype(i+1)).eq.ntyp1)) then ichain=ichain+1 ires=0 write (iunit,'(a)') 'TER' @@ -99,6 +99,7 @@ cmodel write (iunit,'(a5,i6)') 'MODEL',1 ires=ires+1 iatom=iatom+1 ica(i)=iatom + if (iti.ne.ntyp1) then write (iunit,10) iatom,restyp(iti),chainid(ichain), & ires,(c(j,i),j=1,3),vtot(i) if (iti.ne.10) then @@ -106,6 +107,7 @@ cmodel write (iunit,'(a5,i6)') 'MODEL',1 write (iunit,20) iatom,restyp(iti),chainid(ichain), & ires,(c(j,nres+i),j=1,3), & vtot(i+nres) + endif endif endif enddo