include 'COMMON.VAR'
include 'COMMON.LOCAL'
include 'COMMON.MD'
+ include 'COMMON.CONTROL'
c write(iout,'(a,i2)')'Calling etotal_long ipot=',ipot
if (modecalc.eq.12.or.modecalc.eq.14) then
#ifdef MPI
C
107 continue
call vec_and_deriv
+ if (shield_mode.gt.0) then
+ call set_shield_fac
+ endif
+
if (ipot.lt.6) then
#ifdef SPLITELE
if (welec.gt.0d0.or.wvdwpp.gt.0d0.or.wel_loc.gt.0d0.or.
include 'COMMON.CHAIN'
include 'COMMON.VAR'
include 'COMMON.LOCAL'
+ include 'COMMON.CONTROL'
c write(iout,'(a,i2)')'Calling etotal_short ipot=',ipot
c call flush(iout)
C Calculate electrostatic (H-bonding) energy of the main chain.
C
107 continue
+ call vec_and_deriv
+ if (shield_mode.gt.0) then
+ call set_shield_fac
+ endif
+
+ if (ipot.lt.6) then
+#ifdef SPLITELE
+ if (welec.gt.0d0.or.wvdwpp.gt.0d0.or.wel_loc.gt.0d0.or.
+ & wturn3.gt.0d0.or.wturn4.gt.0d0 .or. wcorr.gt.0.0d0
+ & .or. wcorr4.gt.0.0d0 .or. wcorr5.gt.0.d0
+ & .or. wcorr6.gt.0.0d0 .or. wturn6.gt.0.0d0 ) then
+#else
+ if (welec.gt.0d0.or.wel_loc.gt.0d0.or.
+ & wturn3.gt.0d0.or.wturn4.gt.0d0 .or. wcorr.gt.0.0d0
+ & .or. wcorr4.gt.0.0d0 .or. wcorr5.gt.0.d0
+ & .or. wcorr6.gt.0.0d0 .or. wturn6.gt.0.0d0 ) then
+#endif
+ call eelec_scale(ees,evdw1,eel_loc,eello_turn3,eello_turn4)
+ else
+ ees=0
+ evdw1=0
+ eel_loc=0
+ eello_turn3=0
+ eello_turn4=0
+ endif
+ else
+c write (iout,*) "Soft-spheer ELEC potential"
+ call eelec_soft_sphere(ees,evdw1,eel_loc,eello_turn3,
+ & eello_turn4)
+ endif
+
c
c Calculate the short-range part of Evdwpp
c
C
C Calculate the virtual-bond-angle energy.
C
- call ebend(ebe)
+ call ebend(ebe,ethetcnstr)
C
C Calculate the SC local energy.
C
energia(18)=0.0d0
#endif
#ifdef SPLITELE
+ energia(3)=ees
energia(16)=evdw1
#else
- energia(3)=evdw1
+ energia(3)=ees+evdw1
+ energia(16)=0.0d0
#endif
+ energia(4)=ecorr
+ energia(5)=ecorr5
+ energia(6)=ecorr6
+ energia(7)=eel_loc
+ energia(8)=eello_turn3
+ energia(9)=eello_turn4
+
energia(11)=ebe
energia(12)=escloc
energia(13)=etors