make cp src-HCD-5D
[unres.git] / source / unres / src-HCD-5D / econstrq-PMF.F
index 58d89b4..a5d1d78 100644 (file)
@@ -1,6 +1,6 @@
       subroutine EconstrQ
 c     MD with umbrella_sampling using Wolyne's distance measure as a constraint
-      implicit real*8 (a-h,o-z)
+      implicit none
       include 'DIMENSIONS'
 #ifdef MPI
        include 'mpif.h'
@@ -8,12 +8,17 @@ c     MD with umbrella_sampling using Wolyne's distance measure as a constraint
 #endif
       include 'COMMON.CONTROL'
       include 'COMMON.VAR'
-      include 'COMMON.MD'
+c      include 'COMMON.MD'
+      include 'COMMON.QRESTR'
 #ifndef LANG0
       include 'COMMON.LANGEVIN'
 #else
+#ifdef FIVEDIAG
+      include 'COMMON.LANGEVIN.lang0.5diag'
+#else
       include 'COMMON.LANGEVIN.lang0'
 #endif
+#endif
       include 'COMMON.CHAIN'
       include 'COMMON.DERIV'
       include 'COMMON.GEO'
@@ -28,6 +33,9 @@ c     MD with umbrella_sampling using Wolyne's distance measure as a constraint
      &  duconst(3,0:MAXRES),duxconst(3,0:MAXRES)
       integer kstart,kend,lstart,lend,idummy
       double precision delta /1.0d-7/
+      integer i,ii,j,k
+      double precision qwolynes,harmonic,harmonicprim
+      double precision ePMF,ePMF_q
       do i=0,nres
          do j=1,3
             duconst(j,i)=0.0d0
@@ -83,9 +91,6 @@ c Calculating the derivatives of Q with respect to cartesian coordinates
            write(iout,'(i5,3e15.5)') ii,(dxqwol(j,ii),j=1,3)
          enddo
 #endif
-c Calculating numerical gradients of dU/dQi and dQi/dxi
-c        call qwol_num(ifrag(1,i,iset),ifrag(2,i,iset),.true.
-c     &  ,idummy,idummy)
 c  The gradients of Uconst in Cs
          do ii=0,nres
             do j=1,3
@@ -120,9 +125,6 @@ c         write(iout,*) "dxqwol "
 c         do ii=1,nres
 c          write(iout,'(i5,3e15.5)') ii,(dxqwol(j,ii),j=1,3)
 c        enddo
-c Calculating numerical gradients
-c        call qwol_num(kstart,kend,.false.
-c     &  ,lstart,lend)
 c The gradients of Uconst in Cs
          do ii=0,nres
             do j=1,3
@@ -156,7 +158,5 @@ c  Transforming the gradients from Cs to dCs for the side chains
             write(iout,'(i5,3e15.5)') ii,(duxconst(j,ii),j=1,3)
       enddo
 #endif
-c Calculating numerical gradients of dUconst/ddc and dUconst/ddx
-c      call dEconstrQ_num      
       return
       end