X-Git-Url: http://mmka.chem.univ.gda.pl/gitweb/?a=blobdiff_plain;f=source%2Funres%2Fsrc_MD-M%2Fenergy_split-sep.F;h=0f67d199d650de1fccd5ff9faf39f42895a7f83a;hb=77b296ec3d17cc44962973df59ea699d5f6dd9b6;hp=24ab8dd8389a159e6747f75c1c46cf03df56e4c7;hpb=a45ce81aae2c857c30b821e39e45a7a08356de4d;p=unres.git diff --git a/source/unres/src_MD-M/energy_split-sep.F b/source/unres/src_MD-M/energy_split-sep.F index 24ab8dd..0f67d19 100644 --- a/source/unres/src_MD-M/energy_split-sep.F +++ b/source/unres/src_MD-M/energy_split-sep.F @@ -15,6 +15,7 @@ cMS$ATTRIBUTES C :: proc_proc double precision weights_(n_ene) #endif include 'COMMON.SETUP' + include 'COMMON.CONTROL' include 'COMMON.IOUNITS' double precision energia(0:n_ene) include 'COMMON.FFIELD' @@ -65,6 +66,7 @@ C FG slaves as WEIGHTS array. weights_(17)=wbond weights_(18)=scal14 weights_(21)=wsccor + weights_(25)=wsaxs C FG Master broadcasts the WEIGHTS_ array call MPI_Bcast(weights_(1),n_ene, & MPI_DOUBLE_PRECISION,king,FG_COMM,IERROR) @@ -91,6 +93,7 @@ C FG slaves receive the WEIGHTS array wbond=weights(17) scal14=weights(18) wsccor=weights(21) + wsaxs=weights(25) endif call MPI_Bcast(dc(1,1),6*nres,MPI_DOUBLE_PRECISION, & king,FG_COMM,IERR) @@ -252,6 +255,7 @@ cMS$ATTRIBUTES C :: proc_proc double precision weights_(n_ene) #endif include 'COMMON.SETUP' + include 'COMMON.CONTROL' include 'COMMON.IOUNITS' double precision energia(0:n_ene) include 'COMMON.FFIELD' @@ -303,6 +307,7 @@ C FG slaves as WEIGHTS array. weights_(17)=wbond weights_(18)=scal14 weights_(21)=wsccor + weights_(25)=wsaxs C FG Master broadcasts the WEIGHTS_ array call MPI_Bcast(weights_(1),n_ene, & MPI_DOUBLE_PRECISION,king,FG_COMM,IERROR) @@ -329,6 +334,7 @@ C FG slaves receive the WEIGHTS array wbond=weights(17) scal14=weights(18) wsccor=weights(21) + wsaxs=weights(25) endif c write (iout,*),"Processor",myrank," BROADCAST weights" call MPI_Bcast(c(1,1),maxres6,MPI_DOUBLE_PRECISION, @@ -436,6 +442,17 @@ C else esccor=0.0d0 endif + +c write (iout,*) "nsaxs",nsaxs," saxs_mode",saxs_mode + if (nsaxs.gt.0 .and. saxs_mode.eq.0) then + call e_saxs(Esaxs_constr) +c write (iout,*) "From Esaxs: Esaxs_constr",Esaxs_constr + else if (nsaxs.gt.0 .and. saxs_mode.gt.0) then + call e_saxsC(Esaxs_constr) +c write (iout,*) "From EsaxsC: Esaxs_constr",Esaxs_constr + else + Esaxs_constr = 0.0d0 + endif C C Put energy components into an array C @@ -463,6 +480,7 @@ C energia(17)=estr energia(19)=edihcnstr energia(21)=esccor + energia(25)=Esaxs_constr c write (iout,*) "ETOTAL_SHORT before SUM_ENERGY" call flush(iout) call sum_energy(energia,.true.)