if (itype(i-1).ne.ntyp1 .and. itype(i).ne.ntyp1 .and.
& (dist(i,i-1).lt.1.0D0 .or. dist(i,i-1).gt.6.0D0)) then
write (iout,'(a,i4)') 'Bad Cartesians for residue',i
if (itype(i-1).ne.ntyp1 .and. itype(i).ne.ntyp1 .and.
& (dist(i,i-1).lt.1.0D0 .or. dist(i,i-1).gt.6.0D0)) then
write (iout,'(a,i4)') 'Bad Cartesians for residue',i