From 2b3cefdc801aa2631cf91587124e1d65e8eda3c3 Mon Sep 17 00:00:00 2001 From: Pawel Krupa Date: Sun, 15 May 2016 00:20:05 +0200 Subject: [PATCH 01/16] Memory overflow correction. --- source/wham/src/DIMENSIONS.FREE | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/wham/src/DIMENSIONS.FREE b/source/wham/src/DIMENSIONS.FREE index 6533b33..8df70f5 100644 --- a/source/wham/src/DIMENSIONS.FREE +++ b/source/wham/src/DIMENSIONS.FREE @@ -4,8 +4,8 @@ integer MaxSlice parameter (Max_Parm=32) parameter (MaxQ=4,MaxQ1=MaxQ+2) - parameter(MaxR=12,MaxT_h=36) - parameter(MaxSlice=40) + parameter(MaxR=10,MaxT_h=36) + parameter(MaxSlice=20) integer MaxN parameter (MaxN=100) integer MaxPrintConf -- 1.7.9.5 From fbba9531eb48c2430a6d9eb1687b0459506fdd86 Mon Sep 17 00:00:00 2001 From: Pawel Krupa Date: Sun, 15 May 2016 14:37:37 -0400 Subject: [PATCH 02/16] Extended maximum residue number and number of temperatures. --- source/unres/src_MD-M/DIMENSIONS | 2 +- source/wham/src-M/DIMENSIONS | 2 +- source/wham/src-M/DIMENSIONS.FREE | 4 ++-- source/wham/src-M/DIMENSIONS.ZSCOPT | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/source/unres/src_MD-M/DIMENSIONS b/source/unres/src_MD-M/DIMENSIONS index 2b93b81..1e3f361 100644 --- a/source/unres/src_MD-M/DIMENSIONS +++ b/source/unres/src_MD-M/DIMENSIONS @@ -16,7 +16,7 @@ C Max. number of coarse-grain processors parameter (max_cg_procs=maxprocs) C Max. number of AA residues integer maxres - parameter (maxres=1200) + parameter (maxres=1300) C Appr. max. number of interaction sites integer maxres2,maxres6,mmaxres2 parameter (maxres2=2*maxres,maxres6=6*maxres) diff --git a/source/wham/src-M/DIMENSIONS b/source/wham/src-M/DIMENSIONS index 00fa77f..67afa13 100644 --- a/source/wham/src-M/DIMENSIONS +++ b/source/wham/src-M/DIMENSIONS @@ -14,7 +14,7 @@ c parameter (max_cg_procs=maxprocs) C Max. number of AA residues integer maxres c parameter (maxres=250) - parameter (maxres=100) + parameter (maxres=1150) C Appr. max. number of interaction sites integer maxres2 parameter (maxres2=2*maxres) diff --git a/source/wham/src-M/DIMENSIONS.FREE b/source/wham/src-M/DIMENSIONS.FREE index 691d9b2..2684687 100644 --- a/source/wham/src-M/DIMENSIONS.FREE +++ b/source/wham/src-M/DIMENSIONS.FREE @@ -4,8 +4,8 @@ integer MaxSlice parameter (Max_Parm=1) parameter (MaxQ=1,MaxQ1=MaxQ+2) - parameter(MaxR=1,MaxT_h=32) - parameter(MaxSlice=40) + parameter(MaxR=1,MaxT_h=36) + parameter(MaxSlice=20) integer MaxN parameter (MaxN=100) integer MaxPrintConf diff --git a/source/wham/src-M/DIMENSIONS.ZSCOPT b/source/wham/src-M/DIMENSIONS.ZSCOPT index 2f5ee76..cfc74a4 100644 --- a/source/wham/src-M/DIMENSIONS.ZSCOPT +++ b/source/wham/src-M/DIMENSIONS.ZSCOPT @@ -25,7 +25,7 @@ c Maximum number of grid points in energy map evaluation parameter (max_x=200,max_y=200,max_minim=1000) c Maximum number of processors integer MaxProcs - parameter (MaxProcs = 2048) + parameter (MaxProcs = 128) c Maximum number of optimizable parameters integer max_paropt parameter (max_paropt=500) -- 1.7.9.5 From ebef713fd07a933b04b11cfa6535dc3ff186ddea Mon Sep 17 00:00:00 2001 From: Pawel Krupa Date: Sun, 15 May 2016 16:00:46 -0400 Subject: [PATCH 03/16] Cluster-M structure and maximum residue changes. --- source/cluster/wham/src-M/DIMENSIONS | 4 ++-- source/cluster/wham/src-M/sizesclu.dat | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/cluster/wham/src-M/DIMENSIONS b/source/cluster/wham/src-M/DIMENSIONS index 1bcdf79..ae11439 100644 --- a/source/cluster/wham/src-M/DIMENSIONS +++ b/source/cluster/wham/src-M/DIMENSIONS @@ -6,10 +6,10 @@ ******************************************************************************** C Max. number of processors. integer maxprocs - parameter (maxprocs=16) + parameter (maxprocs=24) C Max. number of AA residues integer maxres,maxres2 - parameter (maxres=650) + parameter (maxres=1150) C Appr. max. number of interaction sites parameter (maxres2=2*maxres) C Max. number of variables diff --git a/source/cluster/wham/src-M/sizesclu.dat b/source/cluster/wham/src-M/sizesclu.dat index 1810f0c..30ac675 100644 --- a/source/cluster/wham/src-M/sizesclu.dat +++ b/source/cluster/wham/src-M/sizesclu.dat @@ -5,8 +5,8 @@ * Max. number of conformations in the data set. * integer maxconf,maxstr_proc - PARAMETER (MAXCONF=13000) - parameter (maxstr_proc=maxconf/2) + PARAMETER (MAXCONF=7500) + parameter (maxstr_proc=maxconf/4) * * Max. number of "distances" between conformations. * -- 1.7.9.5 From 31146507a3ad2292fb050be760c7b636ba90e472 Mon Sep 17 00:00:00 2001 From: Pawel Krupa Date: Sun, 15 May 2016 22:07:33 +0200 Subject: [PATCH 04/16] Small fixes in dimensions for memory in piasek. --- source/cluster/wham/src-M/DIMENSIONS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/cluster/wham/src-M/DIMENSIONS b/source/cluster/wham/src-M/DIMENSIONS index ae11439..699ed52 100644 --- a/source/cluster/wham/src-M/DIMENSIONS +++ b/source/cluster/wham/src-M/DIMENSIONS @@ -9,7 +9,7 @@ C Max. number of processors. parameter (maxprocs=24) C Max. number of AA residues integer maxres,maxres2 - parameter (maxres=1150) + parameter (maxres=1140) C Appr. max. number of interaction sites parameter (maxres2=2*maxres) C Max. number of variables -- 1.7.9.5 From 9855ca262c6824c506fbe5025ed63cfa6df4ae81 Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Wed, 18 May 2016 01:44:29 +0200 Subject: [PATCH 05/16] cmake changes for pgf90 isnand() used instead of isnan() for pgf90 cleaning of double common files in cluster_wham include_unres --- source/cluster/wham/src-M/CMakeLists.txt | 4 ++ .../wham/src-M/include_unres/COMMON.CONTACTS | 68 -------------------- .../cluster/wham/src-M/include_unres/COMMON.FFIELD | 28 -------- .../cluster/wham/src-M/include_unres/COMMON.NAMES | 7 -- .../wham/src-M/include_unres/COMMON.SBRIDGE | 9 --- .../cluster/wham/src-M/include_unres/COMMON.SCCOR | 6 -- source/cluster/wham/src/CMakeLists.txt | 7 ++ .../cluster/wham/src/include_unres/COMMON.CONTACTS | 68 -------------------- .../cluster/wham/src/include_unres/COMMON.FFIELD | 28 -------- source/cluster/wham/src/include_unres/COMMON.NAMES | 7 -- source/cluster/wham/src/include_unres/COMMON.SCCOR | 6 -- source/lib/isnan_pgi.f | 7 ++ source/unres/src_CSA/CMakeLists.txt | 4 ++ source/unres/src_MD-M/CMakeLists.txt | 4 ++ source/unres/src_MD/CMakeLists.txt | 6 +- source/unres/src_MIN/CMakeLists.txt | 4 ++ source/wham/src-M/CMakeLists.txt | 5 ++ source/wham/src/CMakeLists.txt | 7 ++ source/wham/src/include_unres/COMMON.VAR | 21 ------ 19 files changed, 47 insertions(+), 249 deletions(-) delete mode 100644 source/cluster/wham/src-M/include_unres/COMMON.CONTACTS delete mode 100644 source/cluster/wham/src-M/include_unres/COMMON.FFIELD delete mode 100644 source/cluster/wham/src-M/include_unres/COMMON.NAMES delete mode 100644 source/cluster/wham/src-M/include_unres/COMMON.SBRIDGE delete mode 100644 source/cluster/wham/src-M/include_unres/COMMON.SCCOR delete mode 100644 source/cluster/wham/src/include_unres/COMMON.CONTACTS delete mode 100644 source/cluster/wham/src/include_unres/COMMON.FFIELD delete mode 100644 source/cluster/wham/src/include_unres/COMMON.NAMES delete mode 100644 source/cluster/wham/src/include_unres/COMMON.SCCOR create mode 100644 source/lib/isnan_pgi.f delete mode 100644 source/wham/src/include_unres/COMMON.VAR diff --git a/source/cluster/wham/src-M/CMakeLists.txt b/source/cluster/wham/src-M/CMakeLists.txt index 5dd1379..83b1382 100644 --- a/source/cluster/wham/src-M/CMakeLists.txt +++ b/source/cluster/wham/src-M/CMakeLists.txt @@ -112,6 +112,10 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_CLUSTER_WHAM_M_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) endif (Fortran_COMPILER_NAME STREQUAL "ifort") diff --git a/source/cluster/wham/src-M/include_unres/COMMON.CONTACTS b/source/cluster/wham/src-M/include_unres/COMMON.CONTACTS deleted file mode 100644 index d07a0f0..0000000 --- a/source/cluster/wham/src-M/include_unres/COMMON.CONTACTS +++ /dev/null @@ -1,68 +0,0 @@ -C Change 12/1/95 - common block CONTACTS1 included. - integer ncont,ncont_ref,icont,icont_ref,num_cont,jcont - double precision facont,gacont - common /contacts/ ncont,ncont_ref,icont(2,maxcont), - & icont_ref(2,maxcont) - common /contacts1/ facont(maxconts,maxres), - & gacont(3,maxconts,maxres), - & num_cont(maxres),jcont(maxconts,maxres) -C 12/26/95 - H-bonding contacts - common /contacts_hb/ - & gacontp_hb1(3,maxconts,maxres),gacontp_hb2(3,maxconts,maxres), - & gacontp_hb3(3,maxconts,maxres), - & gacontm_hb1(3,maxconts,maxres),gacontm_hb2(3,maxconts,maxres), - & gacontm_hb3(3,maxconts,maxres), - & gacont_hbr(3,maxconts,maxres), - & grij_hb_cont(3,maxconts,maxres), - & facont_hb(maxconts,maxres),ees0p(maxconts,maxres), - & ees0m(maxconts,maxres),d_cont(maxconts,maxres), - & num_cont_hb(maxres),jcont_hb(maxconts,maxres) -C 9/23/99 Added improper rotation matrices and matrices of dipole-dipole -C interactions -C Interactions of pseudo-dipoles generated by loc-el interactions. - double precision dip,dipderg,dipderx - common /dipint/ dip(4,maxconts,maxres),dipderg(4,maxconts,maxres), - & dipderx(3,5,4,maxconts,maxres) -C 10/30/99 Added other pre-computed vectors and matrices needed -C to calculate three - six-order el-loc correlation terms - double precision Ug,Ugder,Ug2,Ug2der,obrot,obrot2,obrot_der, - & obrot2_der,Ub2,Ub2der,mu,muder,EUg,EUgder,CUg,CUgder, - & DUg,DUgder,DtUg2,DtUg2der,Ctobr,Ctobrder,Dtobr2,Dtobr2der - common /rotat/ Ug(2,2,maxres),Ugder(2,2,maxres),Ug2(2,2,maxres), - & Ug2der(2,2,maxres),obrot(2,maxres),obrot2(2,maxres), - & obrot_der(2,maxres),obrot2_der(2,maxres) -C This common block contains vectors and matrices dependent on a single -C amino-acid residue. - common /precomp1/ Ub2(2,maxres),Ub2der(2,maxres),mu(2,maxres), - & EUg(2,2,maxres),EUgder(2,2,maxres),CUg(2,2,maxres), - & CUgder(2,2,maxres),DUg(2,2,maxres),Dugder(2,2,maxres), - & DtUg2(2,2,maxres),DtUg2der(2,2,maxres),Ctobr(2,maxres), - & Ctobrder(2,maxres),Dtobr2(2,maxres),Dtobr2der(2,maxres) -C This common block contains vectors and matrices dependent on two -C consecutive amino-acid residues. - double precision Ug2Db1t,Ug2Db1tder,CUgb2,CUgb2der,EUgC, - & EUgCder,EUgD,EUgDder,DtUg2EUg,DtUg2EUgder - common /precomp2/ Ug2Db1t(2,maxres),Ug2Db1tder(2,maxres), - & CUgb2(2,maxres),CUgb2der(2,maxres),EUgC(2,2,maxres), - & EUgCder(2,2,maxres),EUgD(2,2,maxres),EUgDder(2,2,maxres), - & DtUg2EUg(2,2,maxres),DtUg2EUgder(2,2,2,maxres), - & Ug2DtEUg(2,2,maxres),Ug2DtEUgder(2,2,2,maxres) - double precision costab,sintab,costab2,sintab2 - common /rotat_old/ costab(maxres),sintab(maxres), - & costab2(maxres),sintab2(maxres),muder(2,maxres) -C This common block contains dipole-interaction matrices and their -C Cartesian derivatives. - double precision a_chuj,a_chuj_der - common /dipmat/ a_chuj(2,2,maxconts,maxres), - & a_chuj_der(2,2,3,5,maxconts,maxres) - double precision AEA,AEAderg,AEAderx,AECA,AECAderg,AECAderx, - & ADtEA,ADtEAderg,ADtEAderx,AEAb1,AEAb1derg,AEAb1derx, - & AEAb2,AEAb2derg,AEAb2derx - common /diploc/ AEA(2,2,2),AEAderg(2,2,2),AEAderx(2,2,3,5,2,2), - & EAEA(2,2,2), EAEAderg(2,2,2,2), EAEAderx(2,2,3,5,2,2), - & AECA(2,2,2),AECAderg(2,2,2),AECAderx(2,2,3,5,2,2), - & ADtEA(2,2,2),ADtEAderg(2,2,2,2),ADtEAderx(2,2,3,5,2,2), - & ADtEA1(2,2,2),ADtEA1derg(2,2,2,2),ADtEA1derx(2,2,3,5,2,2), - & AEAb1(2,2,2),AEAb1derg(2,2,2),AEAb1derx(2,3,5,2,2,2), - & AEAb2(2,2,2),AEAb2derg(2,2,2,2),AEAb2derx(2,3,5,2,2,2), - & g_contij(3,2),ekont diff --git a/source/cluster/wham/src-M/include_unres/COMMON.FFIELD b/source/cluster/wham/src-M/include_unres/COMMON.FFIELD deleted file mode 100644 index 0c169f7..0000000 --- a/source/cluster/wham/src-M/include_unres/COMMON.FFIELD +++ /dev/null @@ -1,28 +0,0 @@ -C----------------------------------------------------------------------- -C The following COMMON block selects the type of the force field used in -C calculations and defines weights of various energy terms. -C 12/1/95 wcorr added -C----------------------------------------------------------------------- - double precision wsc,wscp,welec,wstrain,wtor,wtor_d,wang,wscloc, - & wcorr,wcorr4,wcorr5,wcorr6,wsccor,wel_loc,wturn3,wturn4, - & wturn6,wvdwpp,wbond,weights,scal14,cutoff_corr,delt_corr, - & r0_corr - integer ipot,n_ene_comp - common /ffield/ wsc,wscp,welec,wstrain,wtor,wtor_d,wang,wscloc, - & wcorr,wcorr4,wcorr5,wcorr6,wsccor,wel_loc,wturn3,wturn4, - & wturn6,wvdwpp,wbond,weights(max_ene), - & scal14,cutoff_corr,delt_corr,r0_corr,ipot,n_ene_comp - common /potentials/ potname(5) - character*3 potname -C----------------------------------------------------------------------- -C wlong,welec,wtor,wang,wscloc are the weight of the energy terms -C corresponding to side-chain, electrostatic, torsional, valence-angle, -C and local side-chain terms. -C -C IPOT determines which SC...SC interaction potential will be used: -C 1 - LJ: 2n-n Lennard-Jones -C 2 - LJK: 2n-n Kihara type (shifted Lennard-Jones) -C 3 - BP; Berne-Pechukas (angular dependence) -C 4 - GB; Gay-Berne (angular dependence) -C 5 - GBV; Gay-Berne-Vorobjev; angularly-dependent Kihara potential -C------------------------------------------------------------------------ diff --git a/source/cluster/wham/src-M/include_unres/COMMON.NAMES b/source/cluster/wham/src-M/include_unres/COMMON.NAMES deleted file mode 100644 index a266339..0000000 --- a/source/cluster/wham/src-M/include_unres/COMMON.NAMES +++ /dev/null @@ -1,7 +0,0 @@ - character*3 restyp - character*1 onelet - common /names/ restyp(ntyp+1),onelet(ntyp+1) - character*10 ename,wname - integer nprint_ene,print_order - common /namterm/ ename(max_ene),wname(max_ene),nprint_ene, - & print_order(max_ene) diff --git a/source/cluster/wham/src-M/include_unres/COMMON.SBRIDGE b/source/cluster/wham/src-M/include_unres/COMMON.SBRIDGE deleted file mode 100644 index 5c87412..0000000 --- a/source/cluster/wham/src-M/include_unres/COMMON.SBRIDGE +++ /dev/null @@ -1,9 +0,0 @@ - double precision ebr,d0cm,akcm,akth,akct,v1ss,v2ss,v3ss,dhpb, - & forcon,weidis - integer ns,nss,nfree,iss,ihpb,jhpb,nhpb,link_start,link_end - common /sbridge/ ebr,d0cm,akcm,akth,akct,v1ss,v2ss,v3ss,ns,nss, - & nfree,iss(maxss) - common /links/ dhpb(maxdim),forcon(maxdim),ihpb(maxdim), - & jhpb(maxdim),nhpb - common /restraints/ weidis - common /links_split/ link_start,link_end diff --git a/source/cluster/wham/src-M/include_unres/COMMON.SCCOR b/source/cluster/wham/src-M/include_unres/COMMON.SCCOR deleted file mode 100644 index 5217de7..0000000 --- a/source/cluster/wham/src-M/include_unres/COMMON.SCCOR +++ /dev/null @@ -1,6 +0,0 @@ -C Parameters of the SCCOR term - double precision v1sccor,v2sccor - integer nterm_sccor - common/torsion/v1sccor(maxterm_sccor,20,20), - & v2sccor(maxterm_sccor,20,20), - & nterm_sccor diff --git a/source/cluster/wham/src/CMakeLists.txt b/source/cluster/wham/src/CMakeLists.txt index 758582d..e20baf4 100644 --- a/source/cluster/wham/src/CMakeLists.txt +++ b/source/cluster/wham/src/CMakeLists.txt @@ -66,6 +66,8 @@ if (Fortran_COMPILER_NAME STREQUAL "ifort") set(FFLAGS0 "-mcmodel=medium -shared-intel -ip -w -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " ) elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") set(FFLAGS0 "-std=legacy -mcmodel=medium -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " ) +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(FFLAGS0 "-mcmodel=medium -Mlarge_arrays -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) else () set(FFLAGS0 "-mcmodel=medium -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " ) endif (Fortran_COMPILER_NAME STREQUAL "ifort") @@ -113,6 +115,11 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_CLUSTER_WHAM_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) + set(CMAKE_EXE_LINKER_FLAGS "-Bdynamic") endif (Fortran_COMPILER_NAME STREQUAL "ifort") diff --git a/source/cluster/wham/src/include_unres/COMMON.CONTACTS b/source/cluster/wham/src/include_unres/COMMON.CONTACTS deleted file mode 100644 index d07a0f0..0000000 --- a/source/cluster/wham/src/include_unres/COMMON.CONTACTS +++ /dev/null @@ -1,68 +0,0 @@ -C Change 12/1/95 - common block CONTACTS1 included. - integer ncont,ncont_ref,icont,icont_ref,num_cont,jcont - double precision facont,gacont - common /contacts/ ncont,ncont_ref,icont(2,maxcont), - & icont_ref(2,maxcont) - common /contacts1/ facont(maxconts,maxres), - & gacont(3,maxconts,maxres), - & num_cont(maxres),jcont(maxconts,maxres) -C 12/26/95 - H-bonding contacts - common /contacts_hb/ - & gacontp_hb1(3,maxconts,maxres),gacontp_hb2(3,maxconts,maxres), - & gacontp_hb3(3,maxconts,maxres), - & gacontm_hb1(3,maxconts,maxres),gacontm_hb2(3,maxconts,maxres), - & gacontm_hb3(3,maxconts,maxres), - & gacont_hbr(3,maxconts,maxres), - & grij_hb_cont(3,maxconts,maxres), - & facont_hb(maxconts,maxres),ees0p(maxconts,maxres), - & ees0m(maxconts,maxres),d_cont(maxconts,maxres), - & num_cont_hb(maxres),jcont_hb(maxconts,maxres) -C 9/23/99 Added improper rotation matrices and matrices of dipole-dipole -C interactions -C Interactions of pseudo-dipoles generated by loc-el interactions. - double precision dip,dipderg,dipderx - common /dipint/ dip(4,maxconts,maxres),dipderg(4,maxconts,maxres), - & dipderx(3,5,4,maxconts,maxres) -C 10/30/99 Added other pre-computed vectors and matrices needed -C to calculate three - six-order el-loc correlation terms - double precision Ug,Ugder,Ug2,Ug2der,obrot,obrot2,obrot_der, - & obrot2_der,Ub2,Ub2der,mu,muder,EUg,EUgder,CUg,CUgder, - & DUg,DUgder,DtUg2,DtUg2der,Ctobr,Ctobrder,Dtobr2,Dtobr2der - common /rotat/ Ug(2,2,maxres),Ugder(2,2,maxres),Ug2(2,2,maxres), - & Ug2der(2,2,maxres),obrot(2,maxres),obrot2(2,maxres), - & obrot_der(2,maxres),obrot2_der(2,maxres) -C This common block contains vectors and matrices dependent on a single -C amino-acid residue. - common /precomp1/ Ub2(2,maxres),Ub2der(2,maxres),mu(2,maxres), - & EUg(2,2,maxres),EUgder(2,2,maxres),CUg(2,2,maxres), - & CUgder(2,2,maxres),DUg(2,2,maxres),Dugder(2,2,maxres), - & DtUg2(2,2,maxres),DtUg2der(2,2,maxres),Ctobr(2,maxres), - & Ctobrder(2,maxres),Dtobr2(2,maxres),Dtobr2der(2,maxres) -C This common block contains vectors and matrices dependent on two -C consecutive amino-acid residues. - double precision Ug2Db1t,Ug2Db1tder,CUgb2,CUgb2der,EUgC, - & EUgCder,EUgD,EUgDder,DtUg2EUg,DtUg2EUgder - common /precomp2/ Ug2Db1t(2,maxres),Ug2Db1tder(2,maxres), - & CUgb2(2,maxres),CUgb2der(2,maxres),EUgC(2,2,maxres), - & EUgCder(2,2,maxres),EUgD(2,2,maxres),EUgDder(2,2,maxres), - & DtUg2EUg(2,2,maxres),DtUg2EUgder(2,2,2,maxres), - & Ug2DtEUg(2,2,maxres),Ug2DtEUgder(2,2,2,maxres) - double precision costab,sintab,costab2,sintab2 - common /rotat_old/ costab(maxres),sintab(maxres), - & costab2(maxres),sintab2(maxres),muder(2,maxres) -C This common block contains dipole-interaction matrices and their -C Cartesian derivatives. - double precision a_chuj,a_chuj_der - common /dipmat/ a_chuj(2,2,maxconts,maxres), - & a_chuj_der(2,2,3,5,maxconts,maxres) - double precision AEA,AEAderg,AEAderx,AECA,AECAderg,AECAderx, - & ADtEA,ADtEAderg,ADtEAderx,AEAb1,AEAb1derg,AEAb1derx, - & AEAb2,AEAb2derg,AEAb2derx - common /diploc/ AEA(2,2,2),AEAderg(2,2,2),AEAderx(2,2,3,5,2,2), - & EAEA(2,2,2), EAEAderg(2,2,2,2), EAEAderx(2,2,3,5,2,2), - & AECA(2,2,2),AECAderg(2,2,2),AECAderx(2,2,3,5,2,2), - & ADtEA(2,2,2),ADtEAderg(2,2,2,2),ADtEAderx(2,2,3,5,2,2), - & ADtEA1(2,2,2),ADtEA1derg(2,2,2,2),ADtEA1derx(2,2,3,5,2,2), - & AEAb1(2,2,2),AEAb1derg(2,2,2),AEAb1derx(2,3,5,2,2,2), - & AEAb2(2,2,2),AEAb2derg(2,2,2,2),AEAb2derx(2,3,5,2,2,2), - & g_contij(3,2),ekont diff --git a/source/cluster/wham/src/include_unres/COMMON.FFIELD b/source/cluster/wham/src/include_unres/COMMON.FFIELD deleted file mode 100644 index 0c169f7..0000000 --- a/source/cluster/wham/src/include_unres/COMMON.FFIELD +++ /dev/null @@ -1,28 +0,0 @@ -C----------------------------------------------------------------------- -C The following COMMON block selects the type of the force field used in -C calculations and defines weights of various energy terms. -C 12/1/95 wcorr added -C----------------------------------------------------------------------- - double precision wsc,wscp,welec,wstrain,wtor,wtor_d,wang,wscloc, - & wcorr,wcorr4,wcorr5,wcorr6,wsccor,wel_loc,wturn3,wturn4, - & wturn6,wvdwpp,wbond,weights,scal14,cutoff_corr,delt_corr, - & r0_corr - integer ipot,n_ene_comp - common /ffield/ wsc,wscp,welec,wstrain,wtor,wtor_d,wang,wscloc, - & wcorr,wcorr4,wcorr5,wcorr6,wsccor,wel_loc,wturn3,wturn4, - & wturn6,wvdwpp,wbond,weights(max_ene), - & scal14,cutoff_corr,delt_corr,r0_corr,ipot,n_ene_comp - common /potentials/ potname(5) - character*3 potname -C----------------------------------------------------------------------- -C wlong,welec,wtor,wang,wscloc are the weight of the energy terms -C corresponding to side-chain, electrostatic, torsional, valence-angle, -C and local side-chain terms. -C -C IPOT determines which SC...SC interaction potential will be used: -C 1 - LJ: 2n-n Lennard-Jones -C 2 - LJK: 2n-n Kihara type (shifted Lennard-Jones) -C 3 - BP; Berne-Pechukas (angular dependence) -C 4 - GB; Gay-Berne (angular dependence) -C 5 - GBV; Gay-Berne-Vorobjev; angularly-dependent Kihara potential -C------------------------------------------------------------------------ diff --git a/source/cluster/wham/src/include_unres/COMMON.NAMES b/source/cluster/wham/src/include_unres/COMMON.NAMES deleted file mode 100644 index a266339..0000000 --- a/source/cluster/wham/src/include_unres/COMMON.NAMES +++ /dev/null @@ -1,7 +0,0 @@ - character*3 restyp - character*1 onelet - common /names/ restyp(ntyp+1),onelet(ntyp+1) - character*10 ename,wname - integer nprint_ene,print_order - common /namterm/ ename(max_ene),wname(max_ene),nprint_ene, - & print_order(max_ene) diff --git a/source/cluster/wham/src/include_unres/COMMON.SCCOR b/source/cluster/wham/src/include_unres/COMMON.SCCOR deleted file mode 100644 index 5217de7..0000000 --- a/source/cluster/wham/src/include_unres/COMMON.SCCOR +++ /dev/null @@ -1,6 +0,0 @@ -C Parameters of the SCCOR term - double precision v1sccor,v2sccor - integer nterm_sccor - common/torsion/v1sccor(maxterm_sccor,20,20), - & v2sccor(maxterm_sccor,20,20), - & nterm_sccor diff --git a/source/lib/isnan_pgi.f b/source/lib/isnan_pgi.f new file mode 100644 index 0000000..19e6816 --- /dev/null +++ b/source/lib/isnan_pgi.f @@ -0,0 +1,7 @@ + logical function isnan(a) + logical isnand + double precision a + isnan=isnand(a) + return + end + \ No newline at end of file diff --git a/source/unres/src_CSA/CMakeLists.txt b/source/unres/src_CSA/CMakeLists.txt index c0a3592..3caa356 100644 --- a/source/unres/src_CSA/CMakeLists.txt +++ b/source/unres/src_CSA/CMakeLists.txt @@ -176,6 +176,10 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_CSA_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) endif (Fortran_COMPILER_NAME STREQUAL "ifort") #========================================= diff --git a/source/unres/src_MD-M/CMakeLists.txt b/source/unres/src_MD-M/CMakeLists.txt index 9c3491b..fdcdd4f 100644 --- a/source/unres/src_MD-M/CMakeLists.txt +++ b/source/unres/src_MD-M/CMakeLists.txt @@ -226,6 +226,10 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_MDM_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) endif (Fortran_COMPILER_NAME STREQUAL "ifort") diff --git a/source/unres/src_MD/CMakeLists.txt b/source/unres/src_MD/CMakeLists.txt index 499cfcb..a3d755f 100644 --- a/source/unres/src_MD/CMakeLists.txt +++ b/source/unres/src_MD/CMakeLists.txt @@ -197,7 +197,11 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") set(CPPFLAGS "${CPPFLAGS} -DG77") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags - set(CPPFLAGS "${CPPFLAGS} -DG77") + set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_MD_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) endif (Fortran_COMPILER_NAME STREQUAL "ifort") #========================================= diff --git a/source/unres/src_MIN/CMakeLists.txt b/source/unres/src_MIN/CMakeLists.txt index 9c26942..6ba42de 100644 --- a/source/unres/src_MIN/CMakeLists.txt +++ b/source/unres/src_MIN/CMakeLists.txt @@ -172,6 +172,10 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_MIN_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) endif (Fortran_COMPILER_NAME STREQUAL "ifort") diff --git a/source/wham/src-M/CMakeLists.txt b/source/wham/src-M/CMakeLists.txt index a2dbc43..dddb2b1 100644 --- a/source/wham/src-M/CMakeLists.txt +++ b/source/wham/src-M/CMakeLists.txt @@ -155,6 +155,11 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_WHAM_M_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) + set(CMAKE_EXE_LINKER_FLAGS "-Bdynamic") endif (Fortran_COMPILER_NAME STREQUAL "ifort") #========================================= diff --git a/source/wham/src/CMakeLists.txt b/source/wham/src/CMakeLists.txt index f17a4b4..51ed5be 100644 --- a/source/wham/src/CMakeLists.txt +++ b/source/wham/src/CMakeLists.txt @@ -97,6 +97,8 @@ if (Fortran_COMPILER_NAME STREQUAL "ifort") set(FFLAGS0 "-mcmodel=medium -shared-intel -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") set(FFLAGS0 "-std=legacy -mcmodel=medium -g -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(FFLAGS0 "-mcmodel=medium -Mlarge_arrays -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) else () set(FFLAGS0 "-g -mcmodel=medium -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) endif (Fortran_COMPILER_NAME STREQUAL "ifort") @@ -156,6 +158,11 @@ elseif (Fortran_COMPILER_NAME STREQUAL "f95") elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") # Add old gfortran flags set(CPPFLAGS "${CPPFLAGS} -DG77") +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(CPPFLAGS "${CPPFLAGS} -DPGI") + FILE(COPY ${CMAKE_SOURCE_DIR}/source/lib/isnan_pgi.f DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + list(APPEND UNRES_WHAM_SRC0 ${CMAKE_CURRENT_BINARY_DIR}/isnan_pgi.f) + set(CMAKE_EXE_LINKER_FLAGS "-Bdynamic") endif (Fortran_COMPILER_NAME STREQUAL "ifort") #========================================= diff --git a/source/wham/src/include_unres/COMMON.VAR b/source/wham/src/include_unres/COMMON.VAR deleted file mode 100644 index d560c87..0000000 --- a/source/wham/src/include_unres/COMMON.VAR +++ /dev/null @@ -1,21 +0,0 @@ -C Store the geometric variables in the following COMMON block. - integer ntheta,nphi,nside,nvar,Origin,nstore,ialph,ivar, - & mask_theta,mask_phi,mask_side - double precision theta,phi,alph,omeg,varsave,esave,varall,vbld, - & thetaref,phiref,costtab,sinttab,cost2tab,sint2tab, - & xxtab,yytab,zztab,xxref,yyref,zzref - common /var/ theta(maxres),phi(maxres),alph(maxres),omeg(maxres), - & omicron(2,maxres),tauangle(3,maxres), - & vbld(2*maxres),thetaref(maxres),phiref(maxres), - & costtab(maxres), sinttab(maxres), cost2tab(maxres), - & sint2tab(maxres),xxtab(maxres),yytab(maxres), - & zztab(maxres),xxref(maxres),yyref(maxres),zzref(maxres), - & ialph(maxres,2),ivar(4*maxres2),ntheta,nphi,nside,nvar -C Store the angles and variables corresponding to old conformations (for use -C in MCM). - common /oldgeo/ varsave(maxvar,maxsave),esave(maxsave), - & Origin(maxsave),nstore -C freeze some variables - logical mask_r - common /restr/ varall(maxvar),mask_r,mask_theta(maxres), - & mask_phi(maxres),mask_side(maxres) -- 1.7.9.5 From fa22bb4430d0caf273ffda38359811313ad40f88 Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Thu, 26 May 2016 10:44:16 +0200 Subject: [PATCH 06/16] cmake and ctest corrections for mpi and srun --- CMakeLists.txt | 5 +++++ source/xdrfpdb/src/CMakeLists.txt | 19 +++++++++++++------ 2 files changed, 18 insertions(+), 6 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3022b58..2ee17e3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -144,7 +144,12 @@ find_package(MPI QUIET) if (MPI_Fortran_FOUND) message("MPI found") FIX_DBL_INCLUDE(MPI_Fortran_INCLUDE_PATH) + message(MPI_Fortran_INCLUDE_PATH) + message(${MPI_Fortran_INCLUDE_PATH}) + message(MPI_Fortran_LIBRARIES) + message(${MPI_Fortran_LIBRARIES}) option(UNRES_SRUN "Use srun instead of mpiexec ?" OFF ) + option(UNRES_MPIRUN "Use mpirun instead of mpiexec ?" OFF ) else() message("MPI not found - disabling MPI compile flags ") set ( UNRES_WITH_MPI "OFF") diff --git a/source/xdrfpdb/src/CMakeLists.txt b/source/xdrfpdb/src/CMakeLists.txt index dabac2e..e7b6907 100644 --- a/source/xdrfpdb/src/CMakeLists.txt +++ b/source/xdrfpdb/src/CMakeLists.txt @@ -103,6 +103,13 @@ install(TARGETS xdrf2ang DESTINATION ${CMAKE_INSTALL_PREFIX}/xdrfpdb) # TESTS #========================================= + if (UNRES_SRUN) + set (SRUN "srun") + else() + set (SRUN "") + endif() + + # Create files needed for tests @@ -126,16 +133,16 @@ file( COPY ${CMAKE_SOURCE_DIR}/ctest/1L2Y_MREMD_MD000.cx # Test xdrf2pdb -add_test(NAME XDRF2PDB-one COMMAND ${CMAKE_BINARY_DIR}/bin/xdrf2pdb one ala10one.seq ala10MD.cx ) -add_test(NAME XDRF2PDB-three COMMAND ${CMAKE_BINARY_DIR}/bin/xdrf2pdb three ala10three.seq ala10MD.cx ) +add_test(NAME XDRF2PDB-one COMMAND ${SRUN} ${CMAKE_BINARY_DIR}/bin/xdrf2pdb one ala10one.seq ala10MD.cx ) +add_test(NAME XDRF2PDB-three COMMAND ${SRUN} ${CMAKE_BINARY_DIR}/bin/xdrf2pdb three ala10three.seq ala10MD.cx ) # Test xdrf2pdb-m -add_test(NAME XDRF2PDB-M-one COMMAND ${CMAKE_BINARY_DIR}/bin/xdrf2pdb-m one 1L2Yone.seq 1L2Y_MREMD_MD000.cx 32 30 ) -add_test(NAME XDRF2PDB-M-three COMMAND ${CMAKE_BINARY_DIR}/bin/xdrf2pdb-m three 1L2Ythree.seq 1L2Y_MREMD_MD000.cx 32 30 ) +add_test(NAME XDRF2PDB-M-one COMMAND ${SRUN} ${CMAKE_BINARY_DIR}/bin/xdrf2pdb-m one 1L2Yone.seq 1L2Y_MREMD_MD000.cx 32 30 ) +add_test(NAME XDRF2PDB-M-three COMMAND ${SRUN} ${CMAKE_BINARY_DIR}/bin/xdrf2pdb-m three 1L2Ythree.seq 1L2Y_MREMD_MD000.cx 32 30 ) # Test xdrf2ang -add_test(NAME XDRF2ANG-one COMMAND ${CMAKE_BINARY_DIR}/bin/xdrf2ang one ala10one.seq ala10MD.cx ) -add_test(NAME XDRF2ANG-three COMMAND ${CMAKE_BINARY_DIR}/bin/xdrf2ang three ala10three.seq ala10MD.cx ) +add_test(NAME XDRF2ANG-one COMMAND ${SRUN} ${CMAKE_BINARY_DIR}/bin/xdrf2ang one ala10one.seq ala10MD.cx ) +add_test(NAME XDRF2ANG-three COMMAND ${SRUN} ${CMAKE_BINARY_DIR}/bin/xdrf2ang three ala10three.seq ala10MD.cx ) -- 1.7.9.5 From 6258e725d4fd8a78b6716e96c62184a8e347bfa2 Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 20 Jun 2016 13:23:07 +0200 Subject: [PATCH 07/16] cmake multichain wham cluster_wham -mcmodel=medium --- source/cluster/wham/src-M/CMakeLists.txt | 8 +++++--- source/wham/src-M/CMakeLists.txt | 8 +++++--- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/source/cluster/wham/src-M/CMakeLists.txt b/source/cluster/wham/src-M/CMakeLists.txt index 83b1382..57a946b 100644 --- a/source/cluster/wham/src-M/CMakeLists.txt +++ b/source/cluster/wham/src-M/CMakeLists.txt @@ -62,11 +62,13 @@ set(UNRES_CLUSTER_WHAM_M_PP_SRC # Set comipiler flags for different sourcefiles #================================================ if (Fortran_COMPILER_NAME STREQUAL "ifort") - set(FFLAGS0 "-ip -w -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-mcmodel=medium -shared-intel -ip -w -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " ) elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") - set(FFLAGS0 "-std=legacy -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-std=legacy -mcmodel=medium -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " ) +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(FFLAGS0 "-mcmodel=medium -Mlarge_arrays -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) else () - set(FFLAGS0 "-I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-mcmodel=medium -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres " ) endif (Fortran_COMPILER_NAME STREQUAL "ifort") #========================================= diff --git a/source/wham/src-M/CMakeLists.txt b/source/wham/src-M/CMakeLists.txt index dddb2b1..4b3eb49 100644 --- a/source/wham/src-M/CMakeLists.txt +++ b/source/wham/src-M/CMakeLists.txt @@ -96,11 +96,13 @@ set(UNRES_WHAM_M_PP_SRC # Set comipiler flags for different sourcefiles #================================================ if (Fortran_COMPILER_NAME STREQUAL "ifort") - set(FFLAGS0 "-g -CB -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-mcmodel=medium -shared-intel -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) elseif (Fortran_COMPILER_NAME STREQUAL "gfortran") - set(FFLAGS0 "-std=legacy -g -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-std=legacy -mcmodel=medium -g -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) +elseif (Fortran_COMPILER_NAME STREQUAL "pgf90") + set(FFLAGS0 "-mcmodel=medium -Mlarge_arrays -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) else () - set(FFLAGS0 "-g -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) + set(FFLAGS0 "-g -mcmodel=medium -I. -I${CMAKE_CURRENT_SOURCE_DIR}/include_unres" ) endif (Fortran_COMPILER_NAME STREQUAL "ifort") -- 1.7.9.5 From a1953980c122f82fd806f581a2283088396f8bff Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Wed, 22 Feb 2017 05:43:56 +0100 Subject: [PATCH 08/16] numerical gradient delta 10e-4 --- source/unres/src_MD-M/energy_p_new_barrier.F | 10 ++++++++-- source/unres/src_MD/checkder_p.F | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/source/unres/src_MD-M/energy_p_new_barrier.F b/source/unres/src_MD-M/energy_p_new_barrier.F index dc71297..eef70b5 100644 --- a/source/unres/src_MD-M/energy_p_new_barrier.F +++ b/source/unres/src_MD-M/energy_p_new_barrier.F @@ -2395,7 +2395,11 @@ c if (i.gt. iatel_s+1 .and. i.lt.iatel_e+4) then do k=1,2 mu(k,i-2)=Ub2(k,i-2)+b1(k,iti1) enddo -cd write (iout,*) 'mu ',mu(:,i-2) +cd write (iout,*) 'mu ',mu(:,i-2),i-2 +cd write (iout,*) 'b1 ',b1(:,iti1),i-2 +cd write (iout,*) 'Ub2 ',Ub2(:,i-2),i-2 +cd write (iout,*) 'Ug ',Ug(:,:,i-2),i-2 +cd write (iout,*) 'b2 ',b2(:,itortyp(itype(i))),i-2 cd write (iout,*) 'mu1',mu1(:,i-2) cd write (iout,*) 'mu2',mu2(:,i-2) if (wcorr4.gt.0.0d0 .or. wcorr5.gt.0.0d0 .or.wcorr6.gt.0.0d0) @@ -4245,7 +4249,7 @@ c & "estr1",i,gnmr1(vbld(i),-1.0d0,distchainmax) else diff = vbld(i)-vbldp0 - if (energy_dec) write (iout,*) + if (energy_dec) write (iout,'(a7,i5,4f7.3)') & "estr bb",i,vbld(i),vbldp0,diff,AKP*diff*diff estr=estr+diff*diff do j=1,3 @@ -5146,6 +5150,8 @@ c & sumene4, c & dscp1,dscp2,sumene c sumene = enesc(x,xx,yy,zz,cost2tab(i+1),sint2tab(i+1)) escloc = escloc + sumene + if (energy_dec) write (iout,'(a6,i5,0pf7.3)') + & 'escloc',i,sumene c write (2,*) "i",i," escloc",sumene,escloc #ifdef DEBUG C diff --git a/source/unres/src_MD/checkder_p.F b/source/unres/src_MD/checkder_p.F index 08b7a32..fc11c2e 100644 --- a/source/unres/src_MD/checkder_p.F +++ b/source/unres/src_MD/checkder_p.F @@ -284,7 +284,7 @@ C Check the gradient of the energy in Cartesian coordinates. c call intcartderiv c call checkintcartgrad call zerograd - aincr=1.0D-6 + aincr=1.0D-4 write(iout,*) 'Calling CHECK_ECARTINT.' nf=0 icall=0 -- 1.7.9.5 From 538ec5fd1c7ca9ed864b4e561e8845ff4e1c0d92 Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 27 Feb 2017 02:24:09 +0100 Subject: [PATCH 09/16] checkgrad added to ctest --- ctest/checkgrad.awk | 45 ++++++++++++++++++++++++++++++++++++ ctest/prota_CHECKGRAD.inp | 12 ++++++++++ ctest/prota_unres_energy_check.sh | 12 ++++++++++ source/unres/src_MD/CMakeLists.txt | 9 ++++++++ 4 files changed, 78 insertions(+) create mode 100644 ctest/checkgrad.awk create mode 100644 ctest/prota_CHECKGRAD.inp diff --git a/ctest/checkgrad.awk b/ctest/checkgrad.awk new file mode 100644 index 0000000..c8968f6 --- /dev/null +++ b/ctest/checkgrad.awk @@ -0,0 +1,45 @@ +BEGIN{ +i=0 +k=1 +kk=0 +}{ +if ($0=="Gradient in virtual-bond and SC vectors") found=1 +if (found==1 && NF==0) found=2 +if (found==2 && NF>0) { + i=i+1 + if (i>3) { + i=1 + k=k+6 + } +# print "###",i +# print + if (i==1) { +# print "TTT",substr($0,0,3) + if (!(substr($0,0,3) ~ /^[[:blank:]]*[0-9]*$/)) exit + } + if (found==2) { + for (j=0;j<6;j++){ + a[i,k+j]=strtonum(substr($0,4+j*12,12)) +# print "OOO",i,j,k,k+j,a[i,k+j] +# print "AAA",i,a[2,k+j] + if(i==3 && a[2,k+j]!=0) { + kk++ + d[kk]=a[i,k+j] +# print "III",i,j,k,kk,d[kk] + } + }} +} +}END{ +diffmax=0 +for (x in d){ + diff=d[x]-1 + if (diff<0)diff=-diff + if (diff>diffmax) diffmax=diff +} + +print "Largest abs(numerical/analytical)= ",diffmax +print "Sorted:" +n = asort(d,sorted) +for (i = 1; i <= n; i++) + printf "%4d %12.5E\n",i,sorted[i] +} \ No newline at end of file diff --git a/ctest/prota_CHECKGRAD.inp b/ctest/prota_CHECKGRAD.inp new file mode 100644 index 0000000..bf5813e --- /dev/null +++ b/ctest/prota_CHECKGRAD.inp @@ -0,0 +1,12 @@ +Test of cartesian gradient - 1bdd - pdbstart unres_pdb +SEED=-3059743 pdbstart pdbref refstr rescale_mode=2 unres_pdb checkgrad cart +WLONG=1.00000 WSCP=1.23315 WELEC=0.84476 WBOND=1.00000 WANG=0.62954 & +WSCLOC=0.10554 WTOR=1.34316 WTORD=1.26571 WCORRH=0.19212 WCORR5=0.00000 & +WCORR6=0.00000 WEL_LOC=0.37357 WTURN3=1.40323 WTURN4=0.64673 WTURN6=0.00000 & +WVDWPP=0.23173 WHPB=1.00000 WSCCOR=0.25 & +CUTOFF=7.00000 WCORR4=0.00000 +prota_unres.pdb + 0 + 0 +0 0 0 0 +300.0 diff --git a/ctest/prota_unres_energy_check.sh b/ctest/prota_unres_energy_check.sh index 8497f9d..c6e52b3 100755 --- a/ctest/prota_unres_energy_check.sh +++ b/ctest/prota_unres_energy_check.sh @@ -203,6 +203,18 @@ elif [ "$1" == "1ei0_min" ]; then # exit 1 fi +elif [ "$1" == "prota_CHECKGRAD" ]; then + diff=`awk -f checkgrad.awk $file |grep 'Largest abs(numerical/analytical)='|awk '{printf "%15.10f",$3}'` + awk -f checkgrad.awk $file + + if [ `echo "a=${diff};a>0.0001"|bc -l` != "0" ]; then + echo 'ERROR largest abs(numerical/analytical)' ${diff} + echo ' greater than 0.0001' + exit 1 + else + exit 0 + fi + else exit 1 diff --git a/source/unres/src_MD/CMakeLists.txt b/source/unres/src_MD/CMakeLists.txt index a3d755f..21e07a2 100644 --- a/source/unres/src_MD/CMakeLists.txt +++ b/source/unres/src_MD/CMakeLists.txt @@ -444,6 +444,13 @@ FILE(COPY ${CMAKE_SOURCE_DIR}/ctest/matplotlib_hist.py FILE_PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE ) +FILE(COPY ${CMAKE_SOURCE_DIR}/ctest/checkgrad.awk + DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + +FILE(COPY ${CMAKE_SOURCE_DIR}/ctest/prota_CHECKGRAD.inp + DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + + #========================================= @@ -557,6 +564,7 @@ if(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_ENE_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) + add_test(NAME UNRES_CHECKGRAD_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_MIN_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 1 ) add_test(NAME UNRES_MIN_INT COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) add_test(NAME UNRES_REGULAR COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_REGULAR_INT 1 ) @@ -577,6 +585,7 @@ else(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_ENE_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 2 ) add_test(NAME UNRES_ENE1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) + add_test(NAME UNRES_CHECKGRAD_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_MIN_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 2 ) add_test(NAME UNRES_MIN_INT COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) add_test(NAME UNRES_REGULAR COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_REGULAR_INT 1 ) -- 1.7.9.5 From f6e614df5123948de841053f55ddb6eb40d73a08 Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 27 Feb 2017 04:32:18 +0100 Subject: [PATCH 10/16] ctest - more checkgrad tests added --- ctest/1DKZcut-checkgrad.inp | 12 ++++++++++++ ctest/checkgrad.awk | 2 +- ctest/prota_unres_energy_check.sh | 10 +++++----- source/unres/src_MD-M/CMakeLists.txt | 14 ++++++++++++++ source/unres/src_MD/CMakeLists.txt | 3 ++- 5 files changed, 34 insertions(+), 7 deletions(-) create mode 100644 ctest/1DKZcut-checkgrad.inp diff --git a/ctest/1DKZcut-checkgrad.inp b/ctest/1DKZcut-checkgrad.inp new file mode 100644 index 0000000..80e7a46 --- /dev/null +++ b/ctest/1DKZcut-checkgrad.inp @@ -0,0 +1,12 @@ +multichain energy test +SEED=-3059743 PDBSTART REFSTR PDBREF PDBOUT DISTCHAINMAX=100 checkgrad cart +WLONG=1.00000 WSCP=1.23315 WELEC=0.84476 WBOND=1.00000 WANG=0.62954 & +WSCLOC=0.10554 WTOR=1.34316 WTORD=1.26571 WCORRH=0.19212 WCORR5=0.00000 & +WCORR6=0.00000 WEL_LOC=0.37357 WTURN3=1.40323 WTURN4=0.64673 WTURN6=0.00000 & +WVDWPP=0.23173 WHPB=1.00000 WSCCOR=0.25 & +CUTOFF=7.00000 WCORR4=0.00000 +./1dkz_cut.pdb +0 +0 +0 0 0 0 +300.0 diff --git a/ctest/checkgrad.awk b/ctest/checkgrad.awk index c8968f6..1280b1c 100644 --- a/ctest/checkgrad.awk +++ b/ctest/checkgrad.awk @@ -37,7 +37,7 @@ for (x in d){ if (diff>diffmax) diffmax=diff } -print "Largest abs(numerical/analytical)= ",diffmax +print "Largest abs(1-numerical/analytical)= ",diffmax print "Sorted:" n = asort(d,sorted) for (i = 1; i <= n; i++) diff --git a/ctest/prota_unres_energy_check.sh b/ctest/prota_unres_energy_check.sh index c6e52b3..a4185c5 100755 --- a/ctest/prota_unres_energy_check.sh +++ b/ctest/prota_unres_energy_check.sh @@ -203,13 +203,13 @@ elif [ "$1" == "1ei0_min" ]; then # exit 1 fi -elif [ "$1" == "prota_CHECKGRAD" ]; then - diff=`awk -f checkgrad.awk $file |grep 'Largest abs(numerical/analytical)='|awk '{printf "%15.10f",$3}'` - awk -f checkgrad.awk $file +elif [ "$1" == "prota_CHECKGRAD" ] || [ "$1" == "1DKZcut-checkgrad" ]; then + diff=`gawk -f checkgrad.awk $file |grep 'Largest abs(1-numerical/analytical)='|awk '{printf "%15.10f",$3}'` + gawk -f checkgrad.awk $file - if [ `echo "a=${diff};a>0.0001"|bc -l` != "0" ]; then + if [ `echo "a=${diff};a>0.0002"|bc -l` != "0" ]; then echo 'ERROR largest abs(numerical/analytical)' ${diff} - echo ' greater than 0.0001' + echo ' greater than 0.0002' exit 1 else exit 0 diff --git a/source/unres/src_MD-M/CMakeLists.txt b/source/unres/src_MD-M/CMakeLists.txt index fdcdd4f..fb7a7af 100644 --- a/source/unres/src_MD-M/CMakeLists.txt +++ b/source/unres/src_MD-M/CMakeLists.txt @@ -475,6 +475,14 @@ FILE(COPY ${CMAKE_SOURCE_DIR}/ctest/matplotlib_hist.py FILE_PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE ) +FILE(COPY ${CMAKE_SOURCE_DIR}/ctest/checkgrad.awk + DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + +FILE(COPY ${CMAKE_SOURCE_DIR}/ctest/prota_CHECKGRAD.inp + DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + +FILE(COPY ${CMAKE_SOURCE_DIR}/ctest/1DKZcut-checkgrad.inp + DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) #========================================= @@ -588,6 +596,7 @@ if(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_M_ENE_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) + add_test(NAME UNRES_M_CHECKGRAD_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_M_MIN_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 1 ) add_test(NAME UNRES_M_MIN_INT COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) add_test(NAME UNRES_M_REGULAR COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_REGULAR_INT 1 ) @@ -597,6 +606,7 @@ if(NOT UNRES_WITH_MPI) # add_test(NAME UNRES_M_NoseHoover COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1L2Y_NH 1 ) add_test(NAME UNRES_M_Berendsen COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1L2Y_B 1 ) add_test(NAME UNRES_M_multi_ene COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1DKZcut-ene 1 ) + add_test(NAME UNRES_M_multi_checkgrad COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1DKZcut-checkgrad 1 ) add_test(NAME UNRES_M_multi_min COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1DKZcut-min 1 ) add_test(NAME UNRES_M_multi_microcanonical COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1DKZcut-micro 1 ) add_test(NAME UNRES_M_multi_Berendsen COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1DKZcut-ber 1 ) @@ -613,6 +623,8 @@ else(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_M_ENE_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 2 ) add_test(NAME UNRES_M_ENE1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) + add_test(NAME UNRES_M_CHECKGRAD_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 2 ) + add_test(NAME UNRES_M_CHECKGRAD1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_M_MIN_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 2 ) add_test(NAME UNRES_M_MIN_INT COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) add_test(NAME UNRES_M_REGULAR COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_REGULAR_INT 1 ) @@ -624,6 +636,8 @@ else(NOT UNRES_WITH_MPI) add_test(NAME UNRES_M_remd COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1L2Y_remd 1 8 ) add_test(NAME UNRES_M_multi_ene COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1DKZcut-ene 2 2 ) add_test(NAME UNRES_M_multi_ene1 COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1DKZcut-ene 1 1 ) + add_test(NAME UNRES_M_multi_checkgrad COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1DKZcut-checkgrad 2 2 ) + add_test(NAME UNRES_M_multi_checkgrad1 COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1DKZcut-checkgrad 1 1 ) add_test(NAME UNRES_M_multi_min COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1DKZcut-min 2 2 ) add_test(NAME UNRES_M_multi_microcanonical COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1DKZcut-micro 2 2 ) add_test(NAME UNRES_M_multi_Berendsen COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh 1DKZcut-ber 2 2 ) diff --git a/source/unres/src_MD/CMakeLists.txt b/source/unres/src_MD/CMakeLists.txt index 21e07a2..0ce0b03 100644 --- a/source/unres/src_MD/CMakeLists.txt +++ b/source/unres/src_MD/CMakeLists.txt @@ -585,7 +585,8 @@ else(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_ENE_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 2 ) add_test(NAME UNRES_ENE1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) - add_test(NAME UNRES_CHECKGRAD_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) + add_test(NAME UNRES_CHECKGRAD_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 2 ) + add_test(NAME UNRES_CHECKGRAD1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_MIN_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 2 ) add_test(NAME UNRES_MIN_INT COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) add_test(NAME UNRES_REGULAR COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_REGULAR_INT 1 ) -- 1.7.9.5 From 40e454a6c29a6a92ad6a89574088b7c4bd950a7d Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 27 Feb 2017 06:03:28 +0100 Subject: [PATCH 11/16] ctest gfortran mpi correction --- source/unres/src_MD-M/CMakeLists.txt | 2 +- source/unres/src_MD/CMakeLists.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/source/unres/src_MD-M/CMakeLists.txt b/source/unres/src_MD-M/CMakeLists.txt index fb7a7af..12df374 100644 --- a/source/unres/src_MD-M/CMakeLists.txt +++ b/source/unres/src_MD-M/CMakeLists.txt @@ -623,7 +623,7 @@ else(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_M_ENE_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 2 ) add_test(NAME UNRES_M_ENE1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) - add_test(NAME UNRES_M_CHECKGRAD_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 2 ) + add_test(NAME UNRES_M_CHECKGRAD_prota COMMAND ${mpiexec} sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh prota_CHECKGRAD 2 2 ) add_test(NAME UNRES_M_CHECKGRAD1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_M_MIN_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 2 ) add_test(NAME UNRES_M_MIN_INT COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) diff --git a/source/unres/src_MD/CMakeLists.txt b/source/unres/src_MD/CMakeLists.txt index 0ce0b03..c310760 100644 --- a/source/unres/src_MD/CMakeLists.txt +++ b/source/unres/src_MD/CMakeLists.txt @@ -585,7 +585,7 @@ else(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_ENE_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 2 ) add_test(NAME UNRES_ENE1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) - add_test(NAME UNRES_CHECKGRAD_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 2 ) + add_test(NAME UNRES_CHECKGRAD_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh prota_CHECKGRAD 2 2 ) add_test(NAME UNRES_CHECKGRAD1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_MIN_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 2 ) add_test(NAME UNRES_MIN_INT COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) -- 1.7.9.5 From f64ea92987109fd8b9f62b2ec160f47229d4e5a6 Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 27 Feb 2017 06:38:39 +0100 Subject: [PATCH 12/16] ctest correction to the last commit --- source/unres/src_MD-M/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/unres/src_MD-M/CMakeLists.txt b/source/unres/src_MD-M/CMakeLists.txt index 12df374..68d75e1 100644 --- a/source/unres/src_MD-M/CMakeLists.txt +++ b/source/unres/src_MD-M/CMakeLists.txt @@ -623,7 +623,7 @@ else(NOT UNRES_WITH_MPI) if(UNRES_MD_FF STREQUAL "E0LL2Y") add_test(NAME UNRES_M_ENE_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 2 ) add_test(NAME UNRES_M_ENE1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_ENE 1 ) - add_test(NAME UNRES_M_CHECKGRAD_prota COMMAND ${mpiexec} sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh prota_CHECKGRAD 2 2 ) + add_test(NAME UNRES_M_CHECKGRAD_prota COMMAND sh ${CMAKE_CURRENT_BINARY_DIR}/test_mpi_E0LL2Y.sh prota_CHECKGRAD 2 2 ) add_test(NAME UNRES_M_CHECKGRAD1_prota COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_CHECKGRAD 1 ) add_test(NAME UNRES_M_MIN_prota COMMAND ${mpiexec} ${boot_lam} ${np} 2 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh prota_MIN_CART 2 ) add_test(NAME UNRES_M_MIN_INT COMMAND ${mpiexec} ${boot_lam} ${np} 1 ${CMAKE_CURRENT_BINARY_DIR}/test_prota_E0LL2Y.sh 1l2y_MIN_INT 1 ) -- 1.7.9.5 From 73a9b42665f9cc91c77b5de547f6c216180b9c3a Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 27 Feb 2017 13:46:08 +0100 Subject: [PATCH 13/16] gfortran segmentation fault checkgrad cart --- source/unres/src_MD/Makefile_MPICH_gfortran | 8 +++++--- source/unres/src_MD/cinfo.f | 12 ++++++------ source/unres/src_MD/unres.F | 4 ++-- 3 files changed, 13 insertions(+), 11 deletions(-) diff --git a/source/unres/src_MD/Makefile_MPICH_gfortran b/source/unres/src_MD/Makefile_MPICH_gfortran index dd0ca5a..dfe9bcc 100644 --- a/source/unres/src_MD/Makefile_MPICH_gfortran +++ b/source/unres/src_MD/Makefile_MPICH_gfortran @@ -1,7 +1,9 @@ ################################################################### -INSTALL_DIR = /users/software/mpich2-1.0.7 +#INSTALL_DIR = /users/software/mpich2-1.0.7 +INSTALL_DIR = /users/local/mpich2-1.4.1p1_gnu + +FC= gfortran -g -FC= gfortran OPT = -O @@ -11,7 +13,7 @@ FFLAGS2 = -c -O0 -I$(INSTALL_DIR)/include FFLAGS3 = -c -O -I$(INSTALL_DIR)/include FFLAGSE = -c -O3 -I$(INSTALL_DIR)/include -LIBS = -L$(INSTALL_DIR)/lib -lmpich -lpthread xdrf/libxdrf.a +LIBS = -L$(INSTALL_DIR)/lib -lmpich -lmpl xdrf/libxdrf.a ARCH = LINUX PP = /lib/cpp -P diff --git a/source/unres/src_MD/cinfo.f b/source/unres/src_MD/cinfo.f index 429d011..f73e66c 100644 --- a/source/unres/src_MD/cinfo.f +++ b/source/unres/src_MD/cinfo.f @@ -1,15 +1,15 @@ C DO NOT EDIT THIS FILE - IT HAS BEEN GENERATED BY COMPINFO.C -C 3 2 164 +C 3 2 187 subroutine cinfo include 'COMMON.IOUNITS' write(iout,*)'++++ Compile info ++++' - write(iout,*)'Version 3.2 build 164' - write(iout,*)'compiled Tue Sep 15 14:50:23 2015' - write(iout,*)'compiled by adam@piasek4' + write(iout,*)'Version 3.2 build 187' + write(iout,*)'compiled Mon Feb 27 13:39:47 2017' + write(iout,*)'compiled by czarek@piasek4' write(iout,*)'OS name: Linux ' - write(iout,*)'OS release: 3.2.0-70-generic ' + write(iout,*)'OS release: 3.2.0-111-generic ' write(iout,*)'OS version:', - & ' #105-Ubuntu SMP Wed Sep 24 19:49:16 UTC 2014 ' + & ' #153-Ubuntu SMP Wed Sep 21 21:23:31 UTC 2016 ' write(iout,*)'flags:' write(iout,*)'INSTALL_DIR = /users/software/mpich-1.2.7p1_int...' write(iout,*)'FC= ifort' diff --git a/source/unres/src_MD/unres.F b/source/unres/src_MD/unres.F index 722a3aa..b8dd5ec 100644 --- a/source/unres/src_MD/unres.F +++ b/source/unres/src_MD/unres.F @@ -698,7 +698,7 @@ c--------------------------------------------------------------------------- include 'COMMON.MD' include 'COMMON.SBRIDGE' common /srutu/ icall - double precision energy(0:max_ene) + double precision energy(0:n_ene) c do i=2,nres c vbld(i)=vbld(i)+ran_number(-0.1d0,0.1d0) c if (itype(i).ne.10) @@ -775,7 +775,7 @@ c--------------------------------------------------------------------------- include 'DIMENSIONS' include 'COMMON.IOUNITS' include 'COMMON.CONTROL' - double precision energy(0:max_ene) + double precision energy(0:n_ene) logical debug /.false./ call chainbuild call etotal(energy(0)) -- 1.7.9.5 From b009c0d2776fae7fc882e7a93508998fa61a34cc Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 27 Feb 2017 14:11:06 +0100 Subject: [PATCH 14/16] gfortran segmentation fault checkgrad cart src_MD-M --- source/unres/src_MD-M/unres.F | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/unres/src_MD-M/unres.F b/source/unres/src_MD-M/unres.F index 2df2658..fab67a1 100644 --- a/source/unres/src_MD-M/unres.F +++ b/source/unres/src_MD-M/unres.F @@ -408,7 +408,7 @@ c--------------------------------------------------------------------------- include 'COMMON.SBRIDGE' double precision varia(maxvar) dimension ind(6) - double precision energy(0:max_ene) + double precision energy(0:n_ene) logical eof eof=.false. #ifdef MPI @@ -703,7 +703,7 @@ c--------------------------------------------------------------------------- include 'COMMON.MD' include 'COMMON.SBRIDGE' common /srutu/ icall - double precision energy(0:max_ene) + double precision energy(0:n_ene) c do i=2,nres c vbld(i)=vbld(i)+ran_number(-0.1d0,0.1d0) c if (itype(i).ne.10) @@ -776,7 +776,7 @@ c--------------------------------------------------------------------------- include 'DIMENSIONS' include 'COMMON.IOUNITS' include 'COMMON.CONTROL' - double precision energy(0:max_ene) + double precision energy(0:n_ene) call chainbuild call etotal(energy(0)) call enerprint(energy(0)) -- 1.7.9.5 From e8b426b1a1fe5365f769f04efd4dc7c333926057 Mon Sep 17 00:00:00 2001 From: Cezary Czaplewski Date: Mon, 25 Sep 2017 10:38:10 +0200 Subject: [PATCH 15/16] changelog --- Changelog | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Changelog b/Changelog index b84d319..534d475 100644 --- a/Changelog +++ b/Changelog @@ -4,3 +4,5 @@ 2012-04-03: hotfixes and examples added 2014-12-11: Version 3.2.1 released. Sidecain-backbone torsionals introduced for the GAB and E0L2Y force fields. A number of bugs fixed, manuals revised. Minimization alone added (directory src_MIN and MINIM in the bin subdirectory) + +2017-09-25: merge with prerelease 3.2.1 \ No newline at end of file -- 1.7.9.5