projects
/
unres.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
small corrections
[unres.git]
/
source
/
wham
/
src-HCD-5D
/
readpdb.F
diff --git
a/source/wham/src-HCD-5D/readpdb.F
b/source/wham/src-HCD-5D/readpdb.F
index
5993291
..
9efc6db
100644
(file)
--- a/
source/wham/src-HCD-5D/readpdb.F
+++ b/
source/wham/src-HCD-5D/readpdb.F
@@
-20,11
+20,13
@@
C geometry.
integer i,j,iii,ibeg,ishift,ishift1,ity,ires,ires_old
double precision dcj
integer rescode,kkk,lll,icha,cou,kupa,iprzes
integer i,j,iii,ibeg,ishift,ishift1,ity,ires,ires_old
double precision dcj
integer rescode,kkk,lll,icha,cou,kupa,iprzes
- logical lsecondary
+ logical lsecondary,sccalc
integer iterter(maxres)
double precision efree_temp
integer iterter(maxres)
double precision efree_temp
+ iii=0
ibeg=1
ishift1=0
ibeg=1
ishift1=0
+ sccalc=.false.
do
read (ipdbin,'(a80)',end=10) card
! write (iout,'(a)') card
do
read (ipdbin,'(a80)',end=10) card
! write (iout,'(a)') card
@@
-53,6
+55,7
@@
C geometry.
itype(ires_old-1)=ntyp1
iterter(ires_old-1)=1
itype(ires_old)=ntyp1
itype(ires_old-1)=ntyp1
iterter(ires_old-1)=1
itype(ires_old)=ntyp1
+ iterter(ires_old)=1
ishift1=ishift1+1
ibeg=2
! write (iout,*) "Chain ended",ires,ishift,ires_old
ishift1=ishift1+1
ibeg=2
! write (iout,*) "Chain ended",ires,ishift,ires_old
@@
-63,12
+66,14
@@
C geometry.
else
call sccenter(ires,iii,sccor)
endif
else
call sccenter(ires,iii,sccor)
endif
-c iii=0
+ iii=0
+ sccalc=.true.
endif
! Read free energy
endif
! Read free energy
- if (index(card,"FREE ENERGY").gt.0) read(card(35:),*) efree_temp
+c if (index(card,"FREE ENERGY").gt.0) read(card(35:),*) efree_temp
! Fish out the ATOM cards.
if (index(card(1:4),'ATOM').gt.0) then
! Fish out the ATOM cards.
if (index(card(1:4),'ATOM').gt.0) then
+ sccalc=.false.
read (card(12:16),*) atom
c write (2,'(a)') card
! write (iout,*) "! ",atom," !",ires
read (card(12:16),*) atom
c write (2,'(a)') card
! write (iout,*) "! ",atom," !",ires
@@
-86,12
+91,13
@@
c write (2,'(a)') card
! write (iout,*) "Calculating sidechain center iii",iii
if (unres_pdb) then
do j=1,3
! write (iout,*) "Calculating sidechain center iii",iii
if (unres_pdb) then
do j=1,3
- dc(j,ires+nres)=sccor(j,iii)
+ dc(j,ires_old)=sccor(j,iii)
enddo
else
call sccenter(ires_old,iii,sccor)
endif
iii=0
enddo
else
call sccenter(ires_old,iii,sccor)
endif
iii=0
+ sccalc=.true.
endif
! Start new residue.
if (res.eq.'Cl-' .or. res.eq.'Na+') then
endif
! Start new residue.
if (res.eq.'Cl-' .or. res.eq.'Na+') then
@@
-212,7
+218,7
@@
C endif !unres_pdb
endif !itype.eq.ntyp1
enddo
C Calculate the CM of the last side chain.
endif !itype.eq.ntyp1
enddo
C Calculate the CM of the last side chain.
- call sccenter(ires,iii,sccor)
+ if (.not. sccalc) call sccenter(ires,iii,sccor)
nsup=nres
nstart_sup=1
if (itype(nres).ne.10) then
nsup=nres
nstart_sup=1
if (itype(nres).ne.10) then
@@
-319,7
+325,7
@@
c write (iout,*) i,i-1,(c(j,i),j=1,3),(c(j,i-1),j=1,3),dist(i,i-1)
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
- stop
+c stop
endif
vbld(i)=dist(i-1,i)
vbld_inv(i)=1.0d0/vbld(i)
endif
vbld(i)=dist(i-1,i)
vbld_inv(i)=1.0d0/vbld(i)
@@
-798,8
+804,8
@@
C Calculate internal coordinates.
endif
C Calculate internal coordinates.
c call int_from_cart1(.false.)
endif
C Calculate internal coordinates.
c call int_from_cart1(.false.)
- call int_from_cart(.true.,.true.)
- call sc_loc_geom(.true.)
+ call int_from_cart(.true.,out_template_coord)
+ call sc_loc_geom(.false.)
do i=1,nres
thetaref(i)=theta(i)
phiref(i)=phi(i)
do i=1,nres
thetaref(i)=theta(i)
phiref(i)=phi(i)