include 'COMMON.IOUNITS'
include 'COMMON.FFIELD'
include 'COMMON.SBRIDGE'
+ include 'COMMON.CONTROL'
double precision kfac /2.4d0/
double precision x,x2,x3,x4,x5,licznik /1.12692801104297249644/
c facT=temp0/t_bath
#endif
stop 555
endif
+ if (shield_mode.gt.0) then
+ wscp=weights(2)*fact
+ wsc=weights(1)*fact
+ wvdwpp=weights(16)*fact
+ endif
welec=weights(3)*fact
wcorr=weights(4)*fact3
wcorr5=weights(5)*fact4
& escloc,wscloc,etors,wtor,etors_d,wtor_d,ehpb,wstrain,
& ecorr,wcorr,
& ecorr5,wcorr5,ecorr6,wcorr6,eel_loc,wel_loc,eello_turn3,wturn3,
- & eello_turn4,wturn4,eello_turn6,wturn6,esccor,wsccro,edihcnstr,
+ & eello_turn4,wturn4,eello_turn6,wturn6,esccor,wsccor,edihcnstr,
& ethetacnstr,ebr*nss,Uconst,eliptran,wliptran,Eafmforc,
& etot
10 format (/'Virtual-chain energies:'//
c & ,' fcont ',ekl,' eeskl',ees0pkl,ees0mkl,' energy=',ekont*ees,
c & 'gradcorr_long'
C Calculate the multi-body contribution to energy.
-c ecorr=ecorr+ekont*ees
+C ecorr=ecorr+ekont*ees
C Calculate multi-body contributions to the gradient.
coeffpees0pij=coeffp*ees0pij
coeffmees0mij=coeffm*ees0mij
C print *,sinphi,sinthet
VofOverlap=VSolvSphere/2.0d0*(1.0d0-dsqrt(1.0d0-sinphi*sinthet))
& /VSolvSphere_div
- & *wshield
+C & *wshield
C now the gradient...
do j=1,3
grad_shield(j,i)=grad_shield(j,i)
&(1.0d0/(-dsqrt(1.0d0-sinphi*sinthet))*(
& sinphi/sinthet*costhet*costhet_grad(j)
& +sinthet/sinphi*cosphi*cosphi_grad_long(j)))
- & )*div77_81
+ & )*wshield
C grad_shield_side is Cbeta sidechain gradient
grad_shield_side(j,ishield_list(i),i)=
& (sh_frac_dist_grad(j)*-2.0d0
&(1.0d0/(-dsqrt(1.0d0-sinphi*sinthet))*(
& sinphi/sinthet*costhet*costhet_grad(j)
& +sinthet/sinphi*cosphi*cosphi_grad_long(j)))
- & )*div77_81
+ & )*wshield
grad_shield_loc(j,ishield_list(i),i)=
& scale_fac_dist*VSolvSphere/VSolvSphere_div/2.0d0*
&(1.0d0/(dsqrt(1.0d0-sinphi*sinthet))*(
& sinthet/sinphi*cosphi*cosphi_grad_loc(j)
& ))
- & *div77_81
+ & *wshield
enddo
VolumeTotal=VolumeTotal+VofOverlap*scale_fac_dist
enddo
- fac_shield(i)=VolumeTotal*div77_81+div4_81
+ fac_shield(i)=VolumeTotal*wshield+(1.0d0-wshield)
C write(2,*) "TOTAL VOLUME",i,VolumeTotal,fac_shield(i)
enddo
return