c & (zmedi.lt.((-0.5d0)*boxzsize))) then
c go to 196
c endif
- xmedi=mod(xmedi,boxxsize)
+ xmedi=dmod(xmedi,boxxsize)
if (xmedi.lt.0) xmedi=xmedi+boxxsize
- ymedi=mod(ymedi,boxysize)
+ ymedi=dmod(ymedi,boxysize)
if (ymedi.lt.0) ymedi=ymedi+boxysize
- zmedi=mod(zmedi,boxzsize)
+ zmedi=dmod(zmedi,boxzsize)
if (zmedi.lt.0) zmedi=zmedi+boxzsize
- zmedi2=mod(zmedi,boxzsize)
+ zmedi2=dmod(zmedi,boxzsize)
if (zmedi2.lt.0) zmedi2=zmedi2+boxzsize
if ((zmedi2.gt.bordlipbot)
&.and.(zmedi2.lt.bordliptop)) then
xmedi=c(1,i)+0.5d0*dxi
ymedi=c(2,i)+0.5d0*dyi
zmedi=c(3,i)+0.5d0*dzi
- xmedi=mod(xmedi,boxxsize)
+ xmedi=dmod(xmedi,boxxsize)
if (xmedi.lt.0) xmedi=xmedi+boxxsize
- ymedi=mod(ymedi,boxysize)
+ ymedi=dmod(ymedi,boxysize)
if (ymedi.lt.0) ymedi=ymedi+boxysize
- zmedi=mod(zmedi,boxzsize)
+ zmedi=dmod(zmedi,boxzsize)
if (zmedi.lt.0) zmedi=zmedi+boxzsize
if ((zmedi.gt.bordlipbot)
&.and.(zmedi.lt.bordliptop)) then
enddo
enddo
if (isubchap.eq.1) then
+C print *,i,j
xj=xj_temp-xmedi
yj=yj_temp-ymedi
zj=zj_temp-zmedi
C Lipidic part for lipscale
gelc_long(3,j)=gelc_long(3,j)+
& ssgradlipj*eesij/2.0d0*lipscale**2
-
+C if ((ssgradlipj*eesij/2.0d0*lipscale**2).ne.0.0 )
+C & write(iout,*) "WTF",j
gelc_long(3,i)=gelc_long(3,i)+
& ssgradlipi*eesij/2.0d0*lipscale**2
+C if ((ssgradlipi*eesij/2.0d0*lipscale**2).ne.0.0 )
+C & write(iout,*) "WTF",i
+
*
* Loop over residues i+1 thru j-1.
*
C print *,mod(c(3,i+nres),boxzsize),bordlipbot,bordliptop
c for each residue check if it is in lipid or lipid water border area
C respos=mod(c(3,i+nres),boxzsize)
- print *,positi,bordtubebot,buftubebot,bordtubetop
+C print *,positi,bordtubebot,buftubebot,bordtubetop
if ((positi.gt.bordtubebot)
& .and.(positi.lt.bordtubetop)) then
C the energy transfer exist
C lipbufthick is thickenes of lipid buffore
sstube=sscalelip(fracinbuf)
ssgradtube=-sscagradlip(fracinbuf)/tubebufthick
- print *,ssgradtube, sstube,tubetranene(itype(i))
+C print *,ssgradtube, sstube,tubetranene(itype(i))
enetube(i)=enetube(i)+sstube*tubetranenepep
C gg_tube_SC(3,i)=gg_tube_SC(3,i)
C &+ssgradtube*tubetranene(itype(i))
C print *,mod(c(3,i+nres),boxzsize),bordlipbot,bordliptop
c for each residue check if it is in lipid or lipid water border area
C respos=mod(c(3,i+nres),boxzsize)
- print *,positi,bordtubebot,buftubebot,bordtubetop
+C print *,positi,bordtubebot,buftubebot,bordtubetop
+
if ((positi.gt.bordtubebot)
& .and.(positi.lt.bordtubetop)) then
C the energy transfer exist
C lipbufthick is thickenes of lipid buffore
sstube=sscalelip(fracinbuf)
ssgradtube=-sscagradlip(fracinbuf)/tubebufthick
- print *,ssgradtube, sstube,tubetranene(itype(i))
+C print *,ssgradtube, sstube,tubetranene(itype(i))
enetube(i+nres)=enetube(i+nres)+sstube*tubetranene(itype(i))
C gg_tube_SC(3,i)=gg_tube_SC(3,i)
C &+ssgradtube*tubetranene(itype(i))