diff -Nru gromacs-4.5.4/admin/programs.txt gromacs-4.5.5/admin/programs.txt --- gromacs-4.5.4/admin/programs.txt 2011-03-04 11:10:43.000000000 +0000 +++ gromacs-4.5.5/admin/programs.txt 2011-09-21 12:34:10.000000000 +0000 @@ -1,163 +1,164 @@ HEAD|Generating topologies and coordinates -pdb2gmx|converts pdb files to topology and coordinate files -g_x2top|generates a primitive topology from coordinates editconf|edits the box and writes subgroups +g_protonate|protonates structures +g_x2top|generates a primitive topology from coordinates genbox|solvates a system -genion|generates mono atomic ions on energetically favorable positions genconf|multiplies a conformation in 'random' orientations +genion|generates mono atomic ions on energetically favorable positions genrestr|generates position restraints or distance restraints for index groups -g_protonate|protonates structures +pdb2gmx|converts coordinate files to topology and FF-compliant coordinate files END HEAD|Running a simulation grompp|makes a run input file -tpbconv|makes a run input file for restarting a crashed run mdrun|performs a simulation, do a normal mode analysis or an energy minimization +tpbconv|makes a run input file for restarting a crashed run END HEAD|Viewing trajectories -ngmx|displays a trajectory g_nmtraj|generate a virtual trajectory from an eigenvector +ngmx|displays a trajectory END HEAD|Processing energies -g_energy|writes energies to xvg files and displays averages g_enemat|extracts an energy matrix from an energy file +g_energy|writes energies to xvg files and displays averages mdrun|with -rerun (re)calculates energies for trajectory frames END HEAD|Converting files editconf|converts and manipulates structure files -trjconv|converts and manipulates trajectory files -trjcat|concatenates trajectory files eneconv|converts energy files -xpm2ps|converts XPM matrices to encapsulated postscript (or XPM) g_sigeps|convert c6/12 or c6/cn combinations to and from sigma/epsilon +trjcat|concatenates trajectory files +trjconv|converts and manipulates trajectory files +xpm2ps|converts XPM matrices to encapsulated postscript (or XPM) END HEAD|Tools -make_ndx|makes index files -mk_angndx|generates index files for g_angle -gmxcheck|checks and compares files -gmxdump|makes binary files human readable -g_traj|plots x, v and f of selected atoms/groups (and more) from a trajectory g_analyze|analyzes data sets -trjorder|orders molecules according to their distance to a group +g_dyndom|interpolate and extrapolate structure rotations g_filter|frequency filters trajectories, useful for making smooth movies g_lie|free energy estimate from linear combinations -g_dyndom|interpolate and extrapolate structure rotations g_morph|linear interpolation of conformations -g_wham|weighted histogram analysis after umbrella sampling -xpm2ps|convert XPM (XPixelMap) file to postscript +g_pme_error|estimates the error of using PME with a given input file +g_select|selects groups of atoms based on flexible textual selections g_sham|read/write xmgr and xvgr data sets g_spatial|calculates the spatial distribution function -g_select|selects groups of atoms based on flexible textual selections -g_pme_error|estimates the error of using PME with a given input file +g_traj|plots x, v and f of selected atoms/groups (and more) from a trajectory g_tune_pme|time mdrun as a function of PME nodes to optimize settings +g_wham|weighted histogram analysis after umbrella sampling +gmxcheck|checks and compares files +gmxdump|makes binary files human readable +make_ndx|makes index files +mk_angndx|generates index files for g_angle +trjorder|orders molecules according to their distance to a group +xpm2ps|convert XPM (XPixelMap) file to postscript END HEAD|Distances between structures -g_rms|calculates rmsd's with a reference structure and rmsd matrices -g_confrms|fits two structures and calculates the rmsd g_cluster|clusters structures +g_confrms|fits two structures and calculates the rmsd +g_rms|calculates rmsd's with a reference structure and rmsd matrices g_rmsf|calculates atomic fluctuations END HEAD|Distances in structures over time -g_mindist|calculates the minimum distance between two groups -g_dist|calculates the distances between the centers of mass of two groups g_bond|calculates distances between atoms +g_dist|calculates the distances between the centers of mass of two groups +g_mindist|calculates the minimum distance between two groups g_mdmat|calculates residue contact maps g_polystat|calculates static properties of polymers g_rmsdist|calculates atom pair distances averaged with power -2, -3 or -6 END HEAD|Mass distribution properties over time -g_traj|plots x, v, f, box, temperature and rotational energy g_gyrate|calculates the radius of gyration g_msd|calculates mean square displacements g_polystat|calculates static properties of polymers -g_rotacf|calculates the rotational correlation function for molecules g_rdf|calculates radial distribution functions +g_rotacf|calculates the rotational correlation function for molecules g_rotmat|plots the rotation matrix for fitting to a reference structure +g_traj|plots x, v, f, box, temperature and rotational energy g_vanhove|calculates Van Hove displacement functions END HEAD|Analyzing bonded interactions -g_bond|calculates bond length distributions -mk_angndx|generates index files for g_angle g_angle|calculates distributions and correlations for angles and dihedrals +g_bond|calculates bond length distributions g_dih|analyzes dihedral transitions +mk_angndx|generates index files for g_angle END HEAD|Structural properties +g_anadock|cluster structures from Autodock runs +g_bundle|analyzes bundles of axes, e.g. helices +g_clustsize|calculate size distributions of atomic clusters +g_disre|analyzes distance restraints g_hbond|computes and analyzes hydrogen bonds -g_saltbr|computes salt bridges -g_sas|computes solvent accessible surface area g_order|computes the order parameter per atom for carbon tails g_principal|calculates axes of inertia for a group of atoms g_rdf|calculates radial distribution functions +g_saltbr|computes salt bridges +g_sas|computes solvent accessible surface area g_sgangle|computes the angle and distance between two groups g_sorient|analyzes solvent orientation around solutes g_spol|analyzes solvent dipole orientation and polarization around solutes -g_bundle|analyzes bundles of axes, e.g. helices -g_disre|analyzes distance restraints -g_clustsize|calculate size distributions of atomic clusters -g_anadock|cluster structures from Autodock runs END HEAD|Kinetic properties -g_traj|plots x, v, f, box, temperature and rotational energy -g_velacc|calculates velocity autocorrelation functions -g_tcaf|calculates viscosities of liquids g_bar|calculates free energy difference estimates through Bennett's acceptance ratio g_current|calculate current autocorrelation function of system -g_vanhove|compute Van Hove correlation function g_principal|calculate principal axes of inertion for a group of atoms +g_tcaf|calculates viscosities of liquids +g_traj|plots x, v, f, box, temperature and rotational energy +g_vanhove|compute Van Hove correlation function +g_velacc|calculates velocity autocorrelation functions END HEAD|Electrostatic properties -genion|generates mono atomic ions on energetically favorable positions -g_potential|calculates the electrostatic potential across the box -g_dipoles|computes the total dipole plus fluctuations -g_dielectric|calculates frequency dependent dielectric constants g_current|calculates dielectric constants for charged systems +g_dielectric|calculates frequency dependent dielectric constants +g_dipoles|computes the total dipole plus fluctuations +g_potential|calculates the electrostatic potential across the box g_spol|analyze dipoles around a solute +genion|generates mono atomic ions on energetically favorable positions END -HEAD|Protein specific analysis +HEAD|Protein-specific analysis do_dssp|assigns secondary structure and calculates solvent accessible surface area g_chi|calculates everything you want to know about chi and other dihedrals g_helix|calculates basic properties of alpha helices g_helixorient|calculates local pitch/bending/rotation/orientation inside helices g_rama|computes Ramachandran plots -g_xrama|shows animated Ramachandran plots g_wheel|plots helical wheels +g_xrama|shows animated Ramachandran plots END HEAD|Interfaces -g_potential|calculates the electrostatic potential across the box +g_bundle|analyzes bundles of axes, e.g. transmembrane helices g_density|calculates the density of the system g_densmap|calculates 2D planar or axial-radial density maps -g_order|computes the order parameter per atom for carbon tails +g_densorder|calculate surface fluctuations g_h2order|computes the orientation of water molecules -g_bundle|analyzes bundles of axes, e.g. transmembrane helices +g_hydorder|computes tetrahedrality parameters around a given atom +g_order|computes the order parameter per atom for carbon tails g_membed|embeds a protein into a lipid bilayer +g_potential|calculates the electrostatic potential across the box END HEAD|Covariance analysis -g_covar|calculates and diagonalizes the covariance matrix g_anaeig|analyzes the eigenvectors +g_covar|calculates and diagonalizes the covariance matrix make_edi|generate input files for essential dynamics sampling END HEAD|Normal modes -grompp|makes a run input file -mdrun|finds a potential energy minimum -mdrun|calculates the Hessian +g_anaeig|analyzes the normal modes g_nmeig|diagonalizes the Hessian g_nmtraj|generate oscillating trajectory of an eigenmode -g_anaeig|analyzes the normal modes g_nmens|generates an ensemble of structures from the normal modes +grompp|makes a run input file +mdrun|finds a potential energy minimum and calculates the Hessian END diff -Nru gromacs-4.5.4/cmake/FindLAPACK.cmake gromacs-4.5.5/cmake/FindLAPACK.cmake --- gromacs-4.5.4/cmake/FindLAPACK.cmake 2011-03-04 11:10:43.000000000 +0000 +++ gromacs-4.5.5/cmake/FindLAPACK.cmake 2011-09-21 12:34:32.000000000 +0000 @@ -107,7 +107,7 @@ if(_libraries_work) # Test this combination of libraries. if(UNIX AND BLA_STATIC) - set(CMAKE_REQUIRED_LIBRARIES ${_flags} "-Wl,--start-group ${${LIBRARIES}} ${_blas};-Wl,--end-group" ${_threads}) + set(CMAKE_REQUIRED_LIBRARIES ${_flags} "-Wl,--start-group ${${LIBRARIES}} ${_blas} -Wl,--end-group" ${_threads}) else(UNIX AND BLA_STATIC) set(CMAKE_REQUIRED_LIBRARIES ${_flags} ${${LIBRARIES}} ${_blas} ${_threads}) endif(UNIX AND BLA_STATIC) diff -Nru gromacs-4.5.4/cmake/ThreadMPI.cmake gromacs-4.5.5/cmake/ThreadMPI.cmake --- gromacs-4.5.4/cmake/ThreadMPI.cmake 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/cmake/ThreadMPI.cmake 2011-09-21 12:34:32.000000000 +0000 @@ -37,10 +37,9 @@ thread_mpi/event.c thread_mpi/reduce_fast.c thread_mpi/gather.c thread_mpi/scatter.c thread_mpi/group.c thread_mpi/tmpi_init.c - thread_mpi/hwinfo.c thread_mpi/topology.c - thread_mpi/list.c thread_mpi/type.c - thread_mpi/lock.c - thread_mpi/once.c) + thread_mpi/topology.c thread_mpi/list.c + thread_mpi/type.c thread_mpi/lock.c + thread_mpi/numa_malloc.c thread_mpi/once.c) set(THREAD_LIB ${CMAKE_THREAD_LIBS_INIT}) else (CMAKE_USE_PTHREADS_INIT) if (CMAKE_USE_WIN32_THREADS_INIT) @@ -56,10 +55,10 @@ thread_mpi/event.c thread_mpi/reduce_fast.c thread_mpi/gather.c thread_mpi/scatter.c thread_mpi/group.c thread_mpi/tmpi_init.c - thread_mpi/hwinfo.c thread_mpi/topology.c - thread_mpi/list.c thread_mpi/type.c - thread_mpi/lock.c thread_mpi/winthreads.c - thread_mpi/once.c) + thread_mpi/topology.c thread_mpi/list.c + thread_mpi/type.c thread_mpi/lock.c + thread_mpi/winthreads.c thread_mpi/once.c + thread_mpi/numa_malloc.c) set(THREAD_LIBRARY ) endif (CMAKE_USE_WIN32_THREADS_INIT) endif (CMAKE_USE_PTHREADS_INIT) @@ -93,6 +92,45 @@ add_definitions() endif (THREAD_MPI_PROFILING) +include(CheckCSourceCompiles) + +# Windows NUMA allocator +if (THREAD_WINDOWS) + check_c_source_compiles( + "#include + int main(void) { PROCESSOR_NUMBER a; return 0; }" + HAVE_PROCESSOR_NUMBER) + if(HAVE_PROCESSOR_NUMBER) + #add_definitions(-DTMPI_WINDOWS_NUMA_API) + set(TMPI_WINDOWS_NUMA_API 1) + endif(HAVE_PROCESSOR_NUMBER) +endif(THREAD_WINDOWS) + + + +include(CheckFunctionExists) +if (THREAD_PTHREADS) + set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_THREAD_LIBS_INIT}) + # check for sched_setaffinity + check_c_source_compiles( + "#define _GNU_SOURCE +#include +#include +#include +#include +int main(void) { cpu_set_t set; + CPU_ZERO(&set); + CPU_SET(0, &set); + pthread_setaffinity_np(pthread_self(), sizeof(set), &set); + return 0; +}" + PTHREAD_SETAFFINITY + ) + if (PTHREAD_SETAFFINITY) + set(HAVE_PTHREAD_SETAFFINITY 1) + endif (PTHREAD_SETAFFINITY) +endif (THREAD_PTHREADS) + # this runs on POSIX systems check_include_files(unistd.h HAVE_UNISTD_H) diff -Nru gromacs-4.5.4/CMakeLists.txt gromacs-4.5.5/CMakeLists.txt --- gromacs-4.5.4/CMakeLists.txt 2011-03-21 15:13:04.000000000 +0000 +++ gromacs-4.5.5/CMakeLists.txt 2011-09-21 12:37:46.000000000 +0000 @@ -12,7 +12,7 @@ # machine with no git. # # NOTE: when releasing the "-dev" suffix needs to be stripped off! -set(PROJECT_VERSION "4.5.4") +set(PROJECT_VERSION "4.5.5") set(CUSTOM_VERSION_STRING "" CACHE STRING "Custom version string (if empty, use hard-coded default)") mark_as_advanced(CUSTOM_VERSION_STRING) @@ -23,7 +23,7 @@ # It is a bit irritating, but this has to be set separately for now! SET(CPACK_PACKAGE_VERSION_MAJOR "4") SET(CPACK_PACKAGE_VERSION_MINOR "5") -SET(CPACK_PACKAGE_VERSION_PATCH "4") +SET(CPACK_PACKAGE_VERSION_PATCH "5") # Cmake modules/macros are in a subdirectory to keep this file cleaner @@ -444,6 +444,10 @@ list(APPEND GMX_EXTRA_LIBRARIES ${ACCELERATE_FRAMEWORK}) endif(APPLE) +if(CYGWIN) + set(GMX_CYGWIN 1) +endif(CYGWIN) + # only bother with finding git and using version.h if the source is a git repo if(EXISTS "${CMAKE_SOURCE_DIR}/.git") if(USE_VERSION_H) @@ -462,6 +466,9 @@ if (GMX_DLOPEN) list(APPEND GMX_EXTRA_LIBRARIES ${CMAKE_DL_LIBS}) + set(PKG_DL_LIBS "-l${CMAKE_DL_LIBS}") +else(GMX_DLOPEN) + set(PKG_DL_LIBS) endif (GMX_DLOPEN) ######################################################################## @@ -629,13 +636,24 @@ if(prefix) set(prefix "${prefix} ##") endif(prefix) + if(suffix) + set(suffix "## ${suffix}") + if(extrasuffix) + set(extrasuffix "${suffix}${extrasuffix}") + endif(extrasuffix) + else(suffix) + if(extrasuffix) + # Don't know if this is needed, but it can't hurt + set(extrasuffix "## ${extrasuffix}") + endif(extrasuffix) + endif(suffix) if(isupper) - set(F77_FUNCDEF "${prefix} NAME ## ${suffix}") - set(F77_FUNCDEF_ "${prefix} NAME ## ${suffix}${extrasuffix}") + set(F77_FUNCDEF "${prefix} NAME ${suffix}") + set(F77_FUNCDEF_ "${prefix} NAME ${extrasuffix}") else(isupper) - set(F77_FUNCDEF "${prefix} name ## ${suffix}") - set(F77_FUNCDEF_ "${prefix} name ## ${suffix}${extrasuffix}") + set(F77_FUNCDEF "${prefix} name ${suffix}") + set(F77_FUNCDEF_ "${prefix} name ${extrasuffix}") endif(isupper) else(GMX_FORTRAN OR GMX_POWER6) set(F77_FUNCDEF "name ## _") @@ -731,19 +749,27 @@ set(GMX_EXTERNAL_BLAS TRUE CACHE BOOL "Use external BLAS instead of built-in") set(GMX_EXTERNAL_LAPACK TRUE CACHE BOOL "Use external LAPACK instead of built-in") else(HAVE_MKL OR ACCELERATE_FRAMEWORK) - set(GMX_EXTERNAL_BLAS FALSE CACHE BOOL "Use external LAPACK instead of built-in") + set(GMX_EXTERNAL_BLAS FALSE CACHE BOOL "Use external BLAS instead of built-in") set(GMX_EXTERNAL_LAPACK FALSE CACHE BOOL "Use external LAPACK instead of built-in") if(GMX_EXTERNAL_BLAS) #FindBLAS needs Fortran enable_language(Fortran) - find_package(BLAS REQUIRED) - list(APPEND GMX_EXTRA_LIBRARIES ${BLAS_LIBRARIES}) + if (GMX_BLAS_USER) + list(APPEND GMX_EXTRA_LIBRARIES ${GMX_BLAS_USER}) + else(GMX_BLAS_USER) + find_package(BLAS REQUIRED) + list(APPEND GMX_EXTRA_LIBRARIES ${BLAS_LIBRARIES}) + endif(GMX_BLAS_USER) endif(GMX_EXTERNAL_BLAS) if(GMX_EXTERNAL_LAPACK) #FindLAPACK needs Fortran enable_language(Fortran) - find_package(LAPACK REQUIRED) - list(APPEND GMX_EXTRA_LIBRARIES ${LAPACK_LIBRARIES}) + if (GMX_LAPACK_USER) + list(APPEND GMX_EXTRA_LIBRARIES ${GMX_LAPACK_USER}) + else(GMX_LAPACK_USER) + find_package(LAPACK REQUIRED) + list(APPEND GMX_EXTRA_LIBRARIES ${LAPACK_LIBRARIES}) + endif(GMX_LAPACK_USER) endif(GMX_EXTERNAL_LAPACK) endif(HAVE_MKL OR ACCELERATE_FRAMEWORK) mark_as_advanced(GMX_EXTERNAL_LAPACK) @@ -777,8 +803,8 @@ ######################################################################## # Specify install locations and which subdirectories to process # ######################################################################## -if ( DEFINED LIB ) - set(LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/${LIB}") +if ( DEFINED GMXLIB ) + set(LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/${GMXLIB}") else() set(LIB_INSTALL_DIR ${CMAKE_INSTALL_PREFIX}/lib) endif() diff -Nru gromacs-4.5.4/configure gromacs-4.5.5/configure --- gromacs-4.5.4/configure 2011-03-21 15:13:40.000000000 +0000 +++ gromacs-4.5.5/configure 2011-09-21 12:38:35.000000000 +0000 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.64 for gromacs 4.5.4. +# Generated by GNU Autoconf 2.64 for gromacs 4.5.5. # # Report bugs to . # @@ -703,8 +703,8 @@ # Identity of this package. PACKAGE_NAME='gromacs' PACKAGE_TARNAME='gromacs' -PACKAGE_VERSION='4.5.4' -PACKAGE_STRING='gromacs 4.5.4' +PACKAGE_VERSION='4.5.5' +PACKAGE_STRING='gromacs 4.5.5' PACKAGE_BUGREPORT='gmx-users@gromacs.org' PACKAGE_URL='' @@ -1532,7 +1532,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures gromacs 4.5.4 to adapt to many kinds of systems. +\`configure' configures gromacs 4.5.5 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1606,7 +1606,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of gromacs 4.5.4:";; + short | recursive ) echo "Configuration of gromacs 4.5.5:";; esac cat <<\_ACEOF @@ -1770,7 +1770,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -gromacs configure 4.5.4 +gromacs configure 4.5.5 generated by GNU Autoconf 2.64 Copyright (C) 2009 Free Software Foundation, Inc. @@ -2650,7 +2650,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by gromacs $as_me 4.5.4, which was +It was created by gromacs $as_me 4.5.5, which was generated by GNU Autoconf 2.64. Invocation command line was $ $0 $@ @@ -3531,7 +3531,7 @@ # Define the identity of the package. PACKAGE='gromacs' - VERSION='4.5.4' + VERSION='4.5.5' cat >>confdefs.h <<_ACEOF @@ -8051,6 +8051,42 @@ " >&2;}; tmpi_atomics=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + + # pthread_setaffinity + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pthread_setaffinity_np is available" >&5 +$as_echo_n "checking if pthread_setaffinity_np is available... " >&6; } + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#define _GNU_SOURCE +#include +#include +#include +#include +int main(void) +{ + cpu_set_t set; + CPU_ZERO(&set); + CPU_SET(0, &set); + pthread_setaffinity_np(pthread_self(), sizeof(set), &set); + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; }; pthread_setaffinity=yes +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; }; pthread_setaffinity=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + + if test "x$pthread_setaffinity" = "xyes"; then + +$as_echo "#define HAVE_PTHREAD_SETAFFINITY 1" >>confdefs.h + + fi + CFLAGS="$CFLAGS_RET" CXXFLAGS="$CXXFLAGS_RET" @@ -9149,7 +9185,7 @@ ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 9152 "configure"' > conftest.$ac_ext + echo '#line 9188 "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? @@ -11116,11 +11152,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:11119: $lt_compile\"" >&5) + (eval echo "\"\$as_me:11155: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:11123: \$? = $ac_status" >&5 + echo "$as_me:11159: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -11384,11 +11420,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:11387: $lt_compile\"" >&5) + (eval echo "\"\$as_me:11423: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:11391: \$? = $ac_status" >&5 + echo "$as_me:11427: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -11488,11 +11524,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:11491: $lt_compile\"" >&5) + (eval echo "\"\$as_me:11527: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:11495: \$? = $ac_status" >&5 + echo "$as_me:11531: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -13513,7 +13549,7 @@ lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < conftest.$ac_ext <&5) + (eval echo "\"\$as_me:15949: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:15917: \$? = $ac_status" >&5 + echo "$as_me:15953: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -16014,11 +16050,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:16017: $lt_compile\"" >&5) + (eval echo "\"\$as_me:16053: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:16021: \$? = $ac_status" >&5 + echo "$as_me:16057: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -17584,11 +17620,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17587: $lt_compile\"" >&5) + (eval echo "\"\$as_me:17623: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:17591: \$? = $ac_status" >&5 + echo "$as_me:17627: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -17688,11 +17724,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:17691: $lt_compile\"" >&5) + (eval echo "\"\$as_me:17727: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:17695: \$? = $ac_status" >&5 + echo "$as_me:17731: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -19844,11 +19880,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:19847: $lt_compile\"" >&5) + (eval echo "\"\$as_me:19883: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:19851: \$? = $ac_status" >&5 + echo "$as_me:19887: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -20112,11 +20148,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:20115: $lt_compile\"" >&5) + (eval echo "\"\$as_me:20151: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:20119: \$? = $ac_status" >&5 + echo "$as_me:20155: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. @@ -20216,11 +20252,11 @@ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:20219: $lt_compile\"" >&5) + (eval echo "\"\$as_me:20255: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:20223: \$? = $ac_status" >&5 + echo "$as_me:20259: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized @@ -28134,7 +28170,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by gromacs $as_me 4.5.4, which was +This file was extended by gromacs $as_me 4.5.5, which was generated by GNU Autoconf 2.64. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -28198,7 +28234,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_version="\\ -gromacs config.status 4.5.4 +gromacs config.status 4.5.5 configured by $0, generated by GNU Autoconf 2.64, with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" diff -Nru gromacs-4.5.4/configure.ac gromacs-4.5.5/configure.ac --- gromacs-4.5.4/configure.ac 2011-03-21 15:13:20.000000000 +0000 +++ gromacs-4.5.5/configure.ac 2011-09-21 12:38:22.000000000 +0000 @@ -9,7 +9,7 @@ # machine with no git. # # NOTE: when releasing the "-dev" suffix needs to be stripped off! -AC_INIT(gromacs, 4.5.4, [gmx-users@gromacs.org]) +AC_INIT(gromacs, 4.5.5, [gmx-users@gromacs.org]) AC_CONFIG_SRCDIR(src/gmxlib/3dview.c) AC_CONFIG_AUX_DIR(config) AC_CANONICAL_HOST @@ -518,6 +518,30 @@ if your system is not obscure -- like, for example, x86 with gcc -- please contact the developers. ]); tmpi_atomics=no]) + + + # pthread_setaffinity + AC_MSG_CHECKING(if pthread_setaffinity_np is available) + AC_COMPILE_IFELSE([#define _GNU_SOURCE +#include +#include +#include +#include +int main(void) +{ + cpu_set_t set; + CPU_ZERO(&set); + CPU_SET(0, &set); + pthread_setaffinity_np(pthread_self(), sizeof(set), &set); + return 0; +}], + [AC_MSG_RESULT(yes); pthread_setaffinity=yes], + [AC_MSG_RESULT(no); pthread_setaffinity=no] ) + + if test "x$pthread_setaffinity" = "xyes"; then + AC_DEFINE(HAVE_PTHREAD_SETAFFINITY,1,[pthread_setaffinity_np is available]) + fi + CFLAGS="$CFLAGS_RET" CXXFLAGS="$CXXFLAGS_RET" diff -Nru gromacs-4.5.4/debian/changelog gromacs-4.5.5/debian/changelog --- gromacs-4.5.4/debian/changelog 2011-10-17 12:02:05.000000000 +0000 +++ gromacs-4.5.5/debian/changelog 2011-10-17 12:02:09.000000000 +0000 @@ -1,3 +1,14 @@ +gromacs (4.5.5-1) unstable; urgency=low + + * New upstream release. + - Remove patches/30_git_release-4.5-patches.dpatch. + - man/g_dos.1: Create man page for new binary. + * rules: Add build-arch/build-indep targets. Add preliminary support for + building GPU-accelerated binaries: set DEB_BUILD_OPTIONS=gpu to try it. + * patches/31_manpages.dpatch: Update. + + -- Nicholas Breen Wed, 21 Sep 2011 19:10:08 -0700 + gromacs (4.5.4-2) unstable; urgency=low * control: remove obsolete Build-Depends and Suggests on libice-dev, diff -Nru gromacs-4.5.4/debian/man/g_dos.1 gromacs-4.5.5/debian/man/g_dos.1 --- gromacs-4.5.4/debian/man/g_dos.1 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/debian/man/g_dos.1 2011-10-17 12:02:09.000000000 +0000 @@ -0,0 +1,137 @@ +.TH g_dos 1 "Wed 21 Sep 2011" "" "GROMACS suite, VERSION 4.5.5" +.SH NAME +g_dos \- compute density of states from a simulation trajectory +.B VERSION 4.5.5 +.SH SYNOPSIS +\f3g_dos\fP +.BI "\-f" " traj.trr " +.BI "\-s" " topol.tpr " +.BI "\-n" " index.ndx " +.BI "\-vacf" " vacf.xvg " +.BI "\-mvacf" " mvacf.xvg " +.BI "\-dos" " dos.xvg " +.BI "\-g" " dos.log " +.BI "\-[no]h" "" +.BI "\-[no]version" "" +.BI "\-nice" " int " +.BI "\-b" " time " +.BI "\-e" " time " +.BI "\-dt" " time " +.BI "\-[no]w" "" +.BI "\-xvg" " enum " +.BI "\-[no]v" "" +.BI "\-[no]recip" "" +.BI "\-[no]abs" "" +.BI "\-[no]normdos" "" +.BI "\-T" " real " +.BI "\-acflen" " int " +.BI "\-[no]normalize" "" +.BI "\-P" " enum " +.BI "\-fitfn" " enum " +.BI "\-ncskip" " int " +.BI "\-beginfit" " real " +.BI "\-endfit" " real " +.SH DESCRIPTION +\&\fB g_dos\fR computes the Density of States from a simulation. +\&In order for this to be meaningful the velocities must be saved +\&in the trajectory with sufficiently high frequency such as to cover +\&all vibrations. For flexible systems that would be around a few fs +\&between saving. Properties based on the DoS are printed on the +\&standard output. +.SH FILES +.BI "\-f" " traj.trr" +.B Input + Full precision trajectory: trr trj cpt + +.BI "\-s" " topol.tpr" +.B Input + Run input file: tpr tpb tpa + +.BI "\-n" " index.ndx" +.B Input, Opt. + Index file + +.BI "\-vacf" " vacf.xvg" +.B Output + xvgr/xmgr file + +.BI "\-mvacf" " mvacf.xvg" +.B Output + xvgr/xmgr file + +.BI "\-dos" " dos.xvg" +.B Output + xvgr/xmgr file + +.BI "\-g" " dos.log" +.B Output + Log file + +.SH OTHER OPTIONS +.BI "\-[no]h" "no " + Print help info and quit + +.BI "\-[no]version" "no " + Print version info and quit + +.BI "\-nice" " int" " 19" + Set the nicelevel + +.BI "\-b" " time" " 0 " + First frame (ps) to read from trajectory + +.BI "\-e" " time" " 0 " + Last frame (ps) to read from trajectory + +.BI "\-dt" " time" " 0 " + Only use frame when t MOD dt = first time (ps) + +.BI "\-[no]w" "no " + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files + +.BI "\-xvg" " enum" " xmgrace" + xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR + +.BI "\-[no]v" "yes " + Be loud and noisy. + +.BI "\-[no]recip" "no " + Use cm\-1 on X\-axis instead of 1/ps for DoS plots. + +.BI "\-[no]abs" "no " + Use the absolute value of the Fourier transform of the VACF as the Density of States. Default is to use the real component only + +.BI "\-[no]normdos" "no " + Normalize the DoS such that it adds up to 3N. This is a hack that should not be necessary. + +.BI "\-T" " real" " 298.15" + Temperature in the simulation + +.BI "\-acflen" " int" " \-1" + Length of the ACF, default is half the number of frames + +.BI "\-[no]normalize" "yes " + Normalize ACF + +.BI "\-P" " enum" " 0" + Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR + +.BI "\-fitfn" " enum" " none" + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR + +.BI "\-ncskip" " int" " 0" + Skip N points in the output file of correlation functions + +.BI "\-beginfit" " real" " 0 " + Time where to begin the exponential fit of the correlation function + +.BI "\-endfit" " real" " \-1 " + Time where to end the exponential fit of the correlation function, \-1 is until the end + +.SH KNOWN PROBLEMS +\- This program needs a lot of memory: total usage equals the number of atoms times 3 times number of frames times 4 (or 8 when run in double precision). + +.SH SEE ALSO +.BR gromacs(7) + +More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. diff -Nru gromacs-4.5.4/debian/patches/00list gromacs-4.5.5/debian/patches/00list --- gromacs-4.5.4/debian/patches/00list 2011-10-17 12:02:05.000000000 +0000 +++ gromacs-4.5.5/debian/patches/00list 2011-10-17 12:02:09.000000000 +0000 @@ -1,3 +1,2 @@ 11_readme.dpatch -30_git_release-4.5-patches.dpatch 31_manpages.dpatch diff -Nru gromacs-4.5.4/debian/patches/30_git_release-4.5-patches.dpatch gromacs-4.5.5/debian/patches/30_git_release-4.5-patches.dpatch --- gromacs-4.5.4/debian/patches/30_git_release-4.5-patches.dpatch 2011-10-17 12:02:05.000000000 +0000 +++ gromacs-4.5.5/debian/patches/30_git_release-4.5-patches.dpatch 1970-01-01 00:00:00.000000000 +0000 @@ -1,22975 +0,0 @@ -#! /bin/sh /usr/share/dpatch/dpatch-run -## 30_git_release-4.5-patches.dpatch by Nicholas Breen -## -## All lines beginning with `## DP:' are a description of the patch. -## DP: Routine update from upstream git 'release-4.5-patches' branch. -## Current to commit 873563ef, 22 April 2011. - -@DPATCH@ - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 011efe9..aacbf39 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -444,6 +444,10 @@ if(APPLE) - list(APPEND GMX_EXTRA_LIBRARIES ${ACCELERATE_FRAMEWORK}) - endif(APPLE) - -+if(CYGWIN) -+ set(GMX_CYGWIN 1) -+endif(CYGWIN) -+ - # only bother with finding git and using version.h if the source is a git repo - if(EXISTS "${CMAKE_SOURCE_DIR}/.git") - if(USE_VERSION_H) -diff --git a/admin/programs.txt b/admin/programs.txt -index 23d1d94..049c549 100644 ---- a/admin/programs.txt -+++ b/admin/programs.txt -@@ -1,163 +1,164 @@ - HEAD|Generating topologies and coordinates --pdb2gmx|converts pdb files to topology and coordinate files --g_x2top|generates a primitive topology from coordinates - editconf|edits the box and writes subgroups -+g_protonate|protonates structures -+g_x2top|generates a primitive topology from coordinates - genbox|solvates a system --genion|generates mono atomic ions on energetically favorable positions - genconf|multiplies a conformation in 'random' orientations -+genion|generates mono atomic ions on energetically favorable positions - genrestr|generates position restraints or distance restraints for index groups --g_protonate|protonates structures -+pdb2gmx|converts coordinate files to topology and FF-compliant coordinate files - END - - HEAD|Running a simulation - grompp|makes a run input file --tpbconv|makes a run input file for restarting a crashed run - mdrun|performs a simulation, do a normal mode analysis or an energy minimization -+tpbconv|makes a run input file for restarting a crashed run - END - - HEAD|Viewing trajectories --ngmx|displays a trajectory - g_nmtraj|generate a virtual trajectory from an eigenvector -+ngmx|displays a trajectory - END - - HEAD|Processing energies --g_energy|writes energies to xvg files and displays averages - g_enemat|extracts an energy matrix from an energy file -+g_energy|writes energies to xvg files and displays averages - mdrun|with -rerun (re)calculates energies for trajectory frames - END - - HEAD|Converting files - editconf|converts and manipulates structure files --trjconv|converts and manipulates trajectory files --trjcat|concatenates trajectory files - eneconv|converts energy files --xpm2ps|converts XPM matrices to encapsulated postscript (or XPM) - g_sigeps|convert c6/12 or c6/cn combinations to and from sigma/epsilon -+trjcat|concatenates trajectory files -+trjconv|converts and manipulates trajectory files -+xpm2ps|converts XPM matrices to encapsulated postscript (or XPM) - END - - HEAD|Tools --make_ndx|makes index files --mk_angndx|generates index files for g_angle --gmxcheck|checks and compares files --gmxdump|makes binary files human readable --g_traj|plots x, v and f of selected atoms/groups (and more) from a trajectory - g_analyze|analyzes data sets --trjorder|orders molecules according to their distance to a group -+g_dyndom|interpolate and extrapolate structure rotations - g_filter|frequency filters trajectories, useful for making smooth movies - g_lie|free energy estimate from linear combinations --g_dyndom|interpolate and extrapolate structure rotations - g_morph|linear interpolation of conformations --g_wham|weighted histogram analysis after umbrella sampling --xpm2ps|convert XPM (XPixelMap) file to postscript -+g_pme_error|estimates the error of using PME with a given input file -+g_select|selects groups of atoms based on flexible textual selections - g_sham|read/write xmgr and xvgr data sets - g_spatial|calculates the spatial distribution function --g_select|selects groups of atoms based on flexible textual selections --g_pme_error|estimates the error of using PME with a given input file -+g_traj|plots x, v and f of selected atoms/groups (and more) from a trajectory - g_tune_pme|time mdrun as a function of PME nodes to optimize settings -+g_wham|weighted histogram analysis after umbrella sampling -+gmxcheck|checks and compares files -+gmxdump|makes binary files human readable -+make_ndx|makes index files -+mk_angndx|generates index files for g_angle -+trjorder|orders molecules according to their distance to a group -+xpm2ps|convert XPM (XPixelMap) file to postscript - END - - HEAD|Distances between structures --g_rms|calculates rmsd's with a reference structure and rmsd matrices --g_confrms|fits two structures and calculates the rmsd - g_cluster|clusters structures -+g_confrms|fits two structures and calculates the rmsd -+g_rms|calculates rmsd's with a reference structure and rmsd matrices - g_rmsf|calculates atomic fluctuations - END - - HEAD|Distances in structures over time --g_mindist|calculates the minimum distance between two groups --g_dist|calculates the distances between the centers of mass of two groups - g_bond|calculates distances between atoms -+g_dist|calculates the distances between the centers of mass of two groups -+g_mindist|calculates the minimum distance between two groups - g_mdmat|calculates residue contact maps - g_polystat|calculates static properties of polymers - g_rmsdist|calculates atom pair distances averaged with power -2, -3 or -6 - END - - HEAD|Mass distribution properties over time --g_traj|plots x, v, f, box, temperature and rotational energy - g_gyrate|calculates the radius of gyration - g_msd|calculates mean square displacements - g_polystat|calculates static properties of polymers --g_rotacf|calculates the rotational correlation function for molecules - g_rdf|calculates radial distribution functions -+g_rotacf|calculates the rotational correlation function for molecules - g_rotmat|plots the rotation matrix for fitting to a reference structure -+g_traj|plots x, v, f, box, temperature and rotational energy - g_vanhove|calculates Van Hove displacement functions - END - - HEAD|Analyzing bonded interactions --g_bond|calculates bond length distributions --mk_angndx|generates index files for g_angle - g_angle|calculates distributions and correlations for angles and dihedrals -+g_bond|calculates bond length distributions - g_dih|analyzes dihedral transitions -+mk_angndx|generates index files for g_angle - END - - HEAD|Structural properties -+g_anadock|cluster structures from Autodock runs -+g_bundle|analyzes bundles of axes, e.g. helices -+g_clustsize|calculate size distributions of atomic clusters -+g_disre|analyzes distance restraints - g_hbond|computes and analyzes hydrogen bonds --g_saltbr|computes salt bridges --g_sas|computes solvent accessible surface area - g_order|computes the order parameter per atom for carbon tails - g_principal|calculates axes of inertia for a group of atoms - g_rdf|calculates radial distribution functions -+g_saltbr|computes salt bridges -+g_sas|computes solvent accessible surface area - g_sgangle|computes the angle and distance between two groups - g_sorient|analyzes solvent orientation around solutes - g_spol|analyzes solvent dipole orientation and polarization around solutes --g_bundle|analyzes bundles of axes, e.g. helices --g_disre|analyzes distance restraints --g_clustsize|calculate size distributions of atomic clusters --g_anadock|cluster structures from Autodock runs - END - - HEAD|Kinetic properties --g_traj|plots x, v, f, box, temperature and rotational energy --g_velacc|calculates velocity autocorrelation functions --g_tcaf|calculates viscosities of liquids - g_bar|calculates free energy difference estimates through Bennett's acceptance ratio - g_current|calculate current autocorrelation function of system --g_vanhove|compute Van Hove correlation function - g_principal|calculate principal axes of inertion for a group of atoms -+g_tcaf|calculates viscosities of liquids -+g_traj|plots x, v, f, box, temperature and rotational energy -+g_vanhove|compute Van Hove correlation function -+g_velacc|calculates velocity autocorrelation functions - END - - HEAD|Electrostatic properties --genion|generates mono atomic ions on energetically favorable positions --g_potential|calculates the electrostatic potential across the box --g_dipoles|computes the total dipole plus fluctuations --g_dielectric|calculates frequency dependent dielectric constants - g_current|calculates dielectric constants for charged systems -+g_dielectric|calculates frequency dependent dielectric constants -+g_dipoles|computes the total dipole plus fluctuations -+g_potential|calculates the electrostatic potential across the box - g_spol|analyze dipoles around a solute -+genion|generates mono atomic ions on energetically favorable positions - END - --HEAD|Protein specific analysis -+HEAD|Protein-specific analysis - do_dssp|assigns secondary structure and calculates solvent accessible surface area - g_chi|calculates everything you want to know about chi and other dihedrals - g_helix|calculates basic properties of alpha helices - g_helixorient|calculates local pitch/bending/rotation/orientation inside helices - g_rama|computes Ramachandran plots --g_xrama|shows animated Ramachandran plots - g_wheel|plots helical wheels -+g_xrama|shows animated Ramachandran plots - END - - HEAD|Interfaces --g_potential|calculates the electrostatic potential across the box -+g_bundle|analyzes bundles of axes, e.g. transmembrane helices - g_density|calculates the density of the system - g_densmap|calculates 2D planar or axial-radial density maps --g_order|computes the order parameter per atom for carbon tails -+g_densorder|calculate surface fluctuations - g_h2order|computes the orientation of water molecules --g_bundle|analyzes bundles of axes, e.g. transmembrane helices -+g_hydorder|computes tetrahedrality parameters around a given atom -+g_order|computes the order parameter per atom for carbon tails - g_membed|embeds a protein into a lipid bilayer -+g_potential|calculates the electrostatic potential across the box - END - - - HEAD|Covariance analysis --g_covar|calculates and diagonalizes the covariance matrix - g_anaeig|analyzes the eigenvectors -+g_covar|calculates and diagonalizes the covariance matrix - make_edi|generate input files for essential dynamics sampling - END - - HEAD|Normal modes --grompp|makes a run input file --mdrun|finds a potential energy minimum --mdrun|calculates the Hessian -+g_anaeig|analyzes the normal modes - g_nmeig|diagonalizes the Hessian - g_nmtraj|generate oscillating trajectory of an eigenmode --g_anaeig|analyzes the normal modes - g_nmens|generates an ensemble of structures from the normal modes -+grompp|makes a run input file -+mdrun|finds a potential energy minimum and calculates the Hessian - END -diff --git a/cmake/ThreadMPI.cmake b/cmake/ThreadMPI.cmake -index 8533727..19e90c1 100644 ---- a/cmake/ThreadMPI.cmake -+++ b/cmake/ThreadMPI.cmake -@@ -37,10 +37,9 @@ if (CMAKE_USE_PTHREADS_INIT) - thread_mpi/event.c thread_mpi/reduce_fast.c - thread_mpi/gather.c thread_mpi/scatter.c - thread_mpi/group.c thread_mpi/tmpi_init.c -- thread_mpi/hwinfo.c thread_mpi/topology.c -- thread_mpi/list.c thread_mpi/type.c -- thread_mpi/lock.c -- thread_mpi/once.c) -+ thread_mpi/topology.c thread_mpi/list.c -+ thread_mpi/type.c thread_mpi/lock.c -+ thread_mpi/numa_malloc.c thread_mpi/once.c) - set(THREAD_LIB ${CMAKE_THREAD_LIBS_INIT}) - else (CMAKE_USE_PTHREADS_INIT) - if (CMAKE_USE_WIN32_THREADS_INIT) -@@ -56,10 +55,10 @@ else (CMAKE_USE_PTHREADS_INIT) - thread_mpi/event.c thread_mpi/reduce_fast.c - thread_mpi/gather.c thread_mpi/scatter.c - thread_mpi/group.c thread_mpi/tmpi_init.c -- thread_mpi/hwinfo.c thread_mpi/topology.c -- thread_mpi/list.c thread_mpi/type.c -- thread_mpi/lock.c thread_mpi/winthreads.c -- thread_mpi/once.c) -+ thread_mpi/topology.c thread_mpi/list.c -+ thread_mpi/type.c thread_mpi/lock.c -+ thread_mpi/winthreads.c thread_mpi/once.c -+ thread_mpi/numa_malloc.c) - set(THREAD_LIBRARY ) - endif (CMAKE_USE_WIN32_THREADS_INIT) - endif (CMAKE_USE_PTHREADS_INIT) -@@ -93,6 +92,45 @@ else (THREAD_MPI_PROFILING) - add_definitions() - endif (THREAD_MPI_PROFILING) - -+include(CheckCSourceCompiles) -+ -+# Windows NUMA allocator -+if (THREAD_WINDOWS) -+ check_c_source_compiles( -+ "#include -+ int main(void) { PROCESSOR_NUMBER a; return 0; }" -+ HAVE_PROCESSOR_NUMBER) -+ if(HAVE_PROCESSOR_NUMBER) -+ #add_definitions(-DTMPI_WINDOWS_NUMA_API) -+ set(TMPI_WINDOWS_NUMA_API 1) -+ endif(HAVE_PROCESSOR_NUMBER) -+endif(THREAD_WINDOWS) -+ -+ -+ -+include(CheckFunctionExists) -+if (THREAD_PTHREADS) -+ set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_THREAD_LIBS_INIT}) -+ # check for sched_setaffinity -+ check_c_source_compiles( -+ "#define _GNU_SOURCE -+#include -+#include -+#include -+#include -+int main(void) { cpu_set_t set; -+ CPU_ZERO(&set); -+ CPU_SET(0, &set); -+ pthread_setaffinity_np(pthread_self(), sizeof(set), &set); -+ return 0; -+}" -+ PTHREAD_SETAFFINITY -+ ) -+ if (PTHREAD_SETAFFINITY) -+ set(HAVE_PTHREAD_SETAFFINITY 1) -+ endif (PTHREAD_SETAFFINITY) -+endif (THREAD_PTHREADS) -+ - - # this runs on POSIX systems - check_include_files(unistd.h HAVE_UNISTD_H) -diff --git a/configure.ac b/configure.ac -index df26544..878fb5d 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -518,6 +518,30 @@ Atomics should work on all but the most obscure CPU+compiler combinations; - if your system is not obscure -- like, for example, x86 with gcc -- please - contact the developers. - ]); tmpi_atomics=no]) -+ -+ -+ # pthread_setaffinity -+ AC_MSG_CHECKING(if pthread_setaffinity_np is available) -+ AC_COMPILE_IFELSE([#define _GNU_SOURCE -+#include -+#include -+#include -+#include -+int main(void) -+{ -+ cpu_set_t set; -+ CPU_ZERO(&set); -+ CPU_SET(0, &set); -+ pthread_setaffinity_np(pthread_self(), sizeof(set), &set); -+ return 0; -+}], -+ [AC_MSG_RESULT(yes); pthread_setaffinity=yes], -+ [AC_MSG_RESULT(no); pthread_setaffinity=no] ) -+ -+ if test "x$pthread_setaffinity" = "xyes"; then -+ AC_DEFINE(HAVE_PTHREAD_SETAFFINITY,1,[pthread_setaffinity_np is available]) -+ fi -+ - CFLAGS="$CFLAGS_RET" - CXXFLAGS="$CXXFLAGS_RET" - -diff --git a/include/gmx_blas.h b/include/gmx_blas.h -index f36d4d8..8bd6b42 100644 ---- a/include/gmx_blas.h -+++ b/include/gmx_blas.h -@@ -37,6 +37,12 @@ - - #include "types/simple.h" - -+/* Suppress Cygwin compiler warnings from using newlib version of -+ * ctype.h */ -+#ifdef GMX_CYGWIN -+#undef toupper -+#endif -+ - - /** @file - * -diff --git a/include/gmx_lapack.h b/include/gmx_lapack.h -index 0a39c03..6ce5138 100644 ---- a/include/gmx_lapack.h -+++ b/include/gmx_lapack.h -@@ -72,6 +72,11 @@ extern "C" { - - #include "types/simple.h" - -+/* Suppress Cygwin compiler warnings from using newlib version of -+ * ctype.h */ -+#ifdef GMX_CYGWIN -+#undef toupper -+#endif - - #ifndef F77_FUNC - #define F77_FUNC(name,NAME) name ## _ -diff --git a/include/gmxcomplex.h b/include/gmxcomplex.h -index 0f70f0c..902f93f 100644 ---- a/include/gmxcomplex.h -+++ b/include/gmxcomplex.h -@@ -1,4 +1,5 @@ - /* -+ * $Id: gmxcomplex.h,v 1.5 2009/03/07 13:30:36 lindahl Exp $ - * - * This source code is part of - * -@@ -32,8 +33,8 @@ - * And Hey: - * Gromacs Runs On Most of All Computer Systems - */ --#ifndef _complex_h --#define _complex_h -+#ifndef _gmxcomplex_h -+#define _gmxcomplex_h - - #include - #include "typedefs.h" -@@ -107,6 +108,16 @@ static t_complex conjugate(t_complex c) - return d; - } - -+static real cabs2(t_complex c) -+{ -+real abs2; -+abs2=(c.re*c.re)+(c.im*c.im); -+ -+return abs2; -+} -+ -+ -+ - static t_complex cdiv(t_complex teller,t_complex noemer) - { - t_complex res,anoemer; -diff --git a/include/gstat.h b/include/gstat.h -index a9ac497..574892e 100644 ---- a/include/gstat.h -+++ b/include/gstat.h -@@ -66,7 +66,7 @@ real LegendreP(real x,unsigned long m); - - enum { - effnNONE, effnEXP1, effnEXP2, effnEXP3, effnVAC, -- effnEXP5, effnEXP7, effnEXP9, effnERREST, effnNR -+ effnEXP5, effnEXP7, effnEXP9, effnERF, effnERREST, effnNR - }; - - /* must correspond with 'leg' g_chi.c:727 */ -@@ -96,7 +96,7 @@ typedef struct { - - } t_dlist; - --extern int nfp_ffn[effnNR]; -+extern const int nfp_ffn[effnNR]; - - extern const char *s_ffn[effnNR+2]; - -diff --git a/include/mdrun.h b/include/mdrun.h -index 7bf4434..d30fb0c 100644 ---- a/include/mdrun.h -+++ b/include/mdrun.h -@@ -176,6 +176,8 @@ gmx_integrator_t do_md; - - gmx_integrator_t do_md_openmm; - -+ -+ - /* ROUTINES from minimize.c */ - - gmx_integrator_t do_steep; -@@ -196,6 +198,39 @@ gmx_integrator_t do_tpi; - /* Do test particle insertion */ - - -+/* ROUTINES from md_support.c */ -+ -+/* return the number of steps between global communcations */ -+int check_nstglobalcomm(FILE *fplog,t_commrec *cr, -+ int nstglobalcomm,t_inputrec *ir); -+ -+/* check whether an 'nst'-style parameter p is a multiple of nst, and -+ set it to be one if not, with a warning. */ -+void check_nst_param(FILE *fplog,t_commrec *cr, -+ const char *desc_nst,int nst, -+ const char *desc_p,int *p); -+ -+/* check which of the multisim simulations has the shortest number of -+ steps and return that number of nsteps */ -+gmx_large_int_t get_multisim_nsteps(const t_commrec *cr, -+ gmx_large_int_t nsteps); -+ -+void rerun_parallel_comm(t_commrec *cr,t_trxframe *fr, -+ gmx_bool *bNotLastFrame); -+ -+/* get the conserved energy associated with the ensemble type*/ -+real compute_conserved_from_auxiliary(t_inputrec *ir, t_state *state, -+ t_extmass *MassQ); -+ -+/* reset all cycle and time counters. */ -+void reset_all_counters(FILE *fplog,t_commrec *cr, -+ gmx_large_int_t step, -+ gmx_large_int_t *step_rel,t_inputrec *ir, -+ gmx_wallcycle_t wcycle,t_nrnb *nrnb, -+ gmx_runtime_t *runtime); -+ -+ -+ - /* ROUTINES from sim_util.c */ - void do_pbc_first(FILE *log,matrix box,t_forcerec *fr, - t_graph *graph,rvec x[]); -@@ -206,6 +241,7 @@ void do_pbc_first_mtop(FILE *fplog,int ePBC,matrix box, - void do_pbc_mtop(FILE *fplog,int ePBC,matrix box, - gmx_mtop_t *mtop,rvec x[]); - -+ - - /* ROUTINES from stat.c */ - gmx_global_stat_t global_stat_init(t_inputrec *ir); -@@ -333,7 +369,33 @@ void dynamic_load_balancing(gmx_bool bVerbose,t_commrec *cr,real capacity[], - /* Perform load balancing, i.e. split the particles over processors - * based on their coordinates in the "dimension" direction. - */ -+ -+int multisim_min(const gmx_multisim_t *ms,int nmin,int n); -+/* Set an appropriate value for n across the whole multi-simulation */ -+ -+int multisim_nstsimsync(const t_commrec *cr, -+ const t_inputrec *ir,int repl_ex_nst); -+/* Determine the interval for inter-simulation communication */ - -+void init_global_signals(globsig_t *gs,const t_commrec *cr, -+ const t_inputrec *ir,int repl_ex_nst); -+/* Constructor for globsig_t */ -+ -+void copy_coupling_state(t_state *statea,t_state *stateb, -+ gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts); -+/* Copy stuff from state A to state B */ -+ -+void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, -+ t_forcerec *fr, gmx_ekindata_t *ekind, -+ t_state *state, t_state *state_global, t_mdatoms *mdatoms, -+ t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, -+ gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, -+ tensor pres, rvec mu_tot, gmx_constr_t constr, -+ globsig_t *gs,gmx_bool bInterSimGS, -+ matrix box, gmx_mtop_t *top_global, real *pcurr, -+ int natoms, gmx_bool *bSumEkinhOld, int flags); -+/* Compute global variables during integration */ -+ - int mdrunner(int nthreads_requested, FILE *fplog,t_commrec *cr,int nfile, - const t_filenm fnm[], const output_env_t oenv, gmx_bool bVerbose, - gmx_bool bCompact, int nstglobalcomm, ivec ddxyz,int dd_node_order, -diff --git a/include/pbc.h b/include/pbc.h -index bf92c8d..03bf49b 100644 ---- a/include/pbc.h -+++ b/include/pbc.h -@@ -33,8 +33,8 @@ - * Gromacs Runs On Most of All Computer Systems - */ - --#ifndef _pbc_h --#define _pbc_h -+#ifndef _types_pbc_h -+#define _types_pbc_h - - #include "sysstuff.h" - #include "typedefs.h" -diff --git a/include/pdbio.h b/include/pdbio.h -index 77aa6c0..0924518 100644 ---- a/include/pdbio.h -+++ b/include/pdbio.h -@@ -136,7 +136,7 @@ void gmx_conect_add(gmx_conect conect,int ai,int aj); - gmx_conect gmx_conect_generate(t_topology *top); - /* Generate a conect structure from a topology */ - --gmx_conect gmx_conect_init(); -+gmx_conect gmx_conect_init(void); - /* Initiate data structure */ - - void gmx_conect_done(gmx_conect gc); -diff --git a/include/string2.h b/include/string2.h -index 184c822..4f1f49a 100644 ---- a/include/string2.h -+++ b/include/string2.h -@@ -56,6 +56,21 @@ - /*#include "typedefs.h"*/ - #include "types/simple.h" - -+/* Suppress Cygwin compiler warnings from using newlib version of -+ * ctype.h */ -+#ifdef GMX_CYGWIN -+#undef isdigit -+#undef isstring -+#undef isspace -+#undef isalnum -+#undef isalpha -+#undef ispunct -+#undef isxdigit -+#undef isupper -+#undef islower -+#undef toupper -+#undef tolower -+#endif - - #ifdef __cplusplus - extern "C" { -diff --git a/include/thread_mpi.h b/include/thread_mpi.h -index ab38d4f..7f95362 100644 ---- a/include/thread_mpi.h -+++ b/include/thread_mpi.h -@@ -96,11 +96,11 @@ files. - - #include "thread_mpi/atomic.h" - #include "thread_mpi/threads.h" -+#include "thread_mpi/numa_malloc.h" - #include "thread_mpi/barrier.h" - #include "thread_mpi/event.h" - #include "thread_mpi/lock.h" - #include "thread_mpi/tmpi.h" - #include "thread_mpi/collective.h" --#include "thread_mpi/hwinfo.h" - - -diff --git a/include/thread_mpi/Makefile.am b/include/thread_mpi/Makefile.am -index bd95011..2064502 100644 ---- a/include/thread_mpi/Makefile.am -+++ b/include/thread_mpi/Makefile.am -@@ -9,7 +9,7 @@ pkgincludethread_mpidir = ${pkgincludedir}/thread_mpi - - pkgincludethread_mpi_HEADERS = \ - atomic.h event.h lock.h tmpi.h \ -- barrier.h hwinfo.h mpi_bindings.h wait.h \ -- collective.h list.h threads.h -+ barrier.h mpi_bindings.h wait.h \ -+ collective.h list.h threads.h numa_malloc.h - - -diff --git a/include/thread_mpi/atomic.h b/include/thread_mpi/atomic.h -index fe8b0a4..deb5a60 100644 ---- a/include/thread_mpi/atomic.h -+++ b/include/thread_mpi/atomic.h -@@ -630,6 +630,7 @@ static inline void tMPI_Spinlock_wait(tMPI_Spinlock_t *x) - /** Atomic swap operation. - - Atomically swaps the data in the tMPI_Atomic_t operand with the value of b. -+ NOTE: DON'T USE YET! (This has no good asm counterparts on many architectures). - - \param a Pointer to atomic type - \param b Value to swap -@@ -648,6 +649,7 @@ static inline int tMPI_Atomic_swap(tMPI_Atomic_t *a, int b) - - Atomically swaps the pointer in the tMPI_Atomic_ptr_t operand with the - value of b. -+ NOTE: DON'T USE YET! (This has no good asm counterparts on many architectures). - - \param a Pointer to atomic type - \param b Value to swap -diff --git a/include/thread_mpi/numa_malloc.h b/include/thread_mpi/numa_malloc.h -new file mode 100644 -index 0000000..7b0edc1 ---- /dev/null -+++ b/include/thread_mpi/numa_malloc.h -@@ -0,0 +1,130 @@ -+/* -+This source code file is part of thread_mpi. -+Written by Sander Pronk, Erik Lindahl, and possibly others. -+ -+Copyright (c) 2009, Sander Pronk, Erik Lindahl. -+All rights reserved. -+ -+Redistribution and use in source and binary forms, with or without -+modification, are permitted provided that the following conditions are met: -+1) Redistributions of source code must retain the above copyright -+ notice, this list of conditions and the following disclaimer. -+2) Redistributions in binary form must reproduce the above copyright -+ notice, this list of conditions and the following disclaimer in the -+ documentation and/or other materials provided with the distribution. -+3) Neither the name of the copyright holders nor the -+ names of its contributors may be used to endorse or promote products -+ derived from this software without specific prior written permission. -+ -+THIS SOFTWARE IS PROVIDED BY US ''AS IS'' AND ANY -+EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -+DISCLAIMED. IN NO EVENT SHALL WE BE LIABLE FOR ANY -+DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND -+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -+ -+If you want to redistribute modifications, please consider that -+scientific software is very special. Version control is crucial - -+bugs must be traceable. We will be happy to consider code for -+inclusion in the official distribution, but derived work should not -+be called official thread_mpi. Details are found in the README & COPYING -+files. -+*/ -+ -+ -+#ifndef _TMPI_NUMA_MALLOC_H_ -+#define _TMPI_NUMA_MALLOC_H_ -+ -+/*! \file numa_alloc.h -+ -+ \brief NUMA aware memory allocators. -+ -+ This file provides a NUMA aware version of malloc() and friends to -+ force local allocation, preventing expensive 'remote' memory access. -+ -+ Note that memory allocated with tMPI_Malloc_local(), etc. MUST be -+ freed with tMPI_Free_numa(). -+ -+ Currently this is only implemented on Windows. Check for the presence -+ of these functions with -+ #ifdef TMPI_NUMA_MALLOC -+ .... -+ #endif -+ */ -+ -+ -+ -+#ifdef __cplusplus -+extern "C" -+{ -+#endif -+#if 0 -+} /* Avoids screwing up auto-indentation */ -+#endif -+ -+ -+#if (defined(WIN32) || defined( _WIN32 ) || defined(WIN64) || defined( _WIN64 ) || defined (__CYGWIN__)) -+ -+#define TMPI_NUMA_MALLOC -+ -+#endif -+ -+ -+/*! \brief Allocate local memory by size in bytes. -+ -+ \see malloc() -+ -+ \param[in] size = size in units of sizeof() of the memory to be allocated -+ -+ \return Pointer to allocated memory, or NULL in case of failure -+ */ -+void *tMPI_Malloc_local(size_t size); -+ -+ -+/*! \brief Allocate local memory by array and element size. -+ -+ \see calloc() -+ -+ \param[in] nmemb = number of array members -+ \param[in] size = size in units of sizeof() of a single array element -+ -+ \return Pointer to allocated memory, or NULL in case of failure -+ */ -+void *tMPI_Calloc_local(size_t nmemb, size_t size); -+ -+ -+/*! \brief Re-allocate to local memory. -+ -+ \see realloc() -+ -+ \param[in] ptr = input pointer of originally allocated memory (can -+ be allocated with NUMA or non-NUMA malloc()) -+ \param[in] size = new size in units of sizeof(). -+ -+ \return Pointer to allocated memory, or NULL in case of failure -+ */ -+void *tMPI_Realloc_local(void *ptr, size_t size); -+ -+ -+/*! \brief Free memory allocate with any of the NUMA-aware allocators -+ -+ \see calloc() -+ -+ \param[in] ptr = pointer to block of memory allocated with a NUMA allocator -+ -+ \return Returns debug info: 0 if the memory was allocated with a NUMA -+ allocator, 1 if it was allocated by another allocator. -+ */ -+int tMPI_Free_numa(void *ptr); -+ -+ -+#ifdef __cplusplus -+} -+#endif -+ -+#endif /* _TMPI_NUMA_MALLOC_H_ */ -+ -diff --git a/include/thread_mpi/threads.h b/include/thread_mpi/threads.h -index 143b3cb..d8dfe70 100644 ---- a/include/thread_mpi/threads.h -+++ b/include/thread_mpi/threads.h -@@ -256,10 +256,20 @@ void tMPI_Fatal_error(const char *file, int line, const char *message, ...); - enum tMPI_Thread_support tMPI_Thread_support(void); - - -+/** Get the number of hardware threads that can be run simultaneously. -+ -+ Returns the total number of cores and SMT threads that can run. -+ -+ \ret The maximum number of threads that can run simulataneously. If this -+ number cannot be determined for the current architecture, 0 is -+ returned. */ -+int tMPI_Thread_get_hw_number(void); -+ - - /** Create a new thread - * - * The new thread will call start_routine() with the argument arg. -+ * - * Please be careful not to change arg after calling this function. - * - * \param thread Pointer to opaque thread datatype -@@ -268,9 +278,34 @@ enum tMPI_Thread_support tMPI_Thread_support(void); - * - * \return Status - 0 on success, or an error code. - */ --int tMPI_Thread_create (tMPI_Thread_t * thread, -- void * (*start_routine)(void *), -- void * arg); -+int tMPI_Thread_create(tMPI_Thread_t *thread, -+ void* (*start_routine)(void *), -+ void* arg); -+ -+/** Create a new thread with processor affinity -+ * -+ * The new thread will call start_routine() with the argument arg. -+ * -+ * The new thread will have processor affinity assigned in a -+ * round-robin way, starting at processor 1. The first thread to call -+ * this function will be assigned to processor 0. -+ * -+ * This means that this funtion should ONLY be called when starting a -+ * thread on each processor: in any other case, this will lead to -+ * imbalances because processors 0 and 1 will be oversubscribed. -+ * -+ * Please be careful not to change arg after calling this function. -+ * -+ * \param thread Pointer to opaque thread datatype -+ * \param start_routine The function to call in the new thread -+ * \param arg Argument to call with -+ * -+ * \return Status - 0 on success, or an error code. -+ */ -+int tMPI_Thread_create_aff(tMPI_Thread_t *thread, -+ void *(*start_routine)(void *), -+ void *arg); -+ - - - -@@ -285,8 +320,7 @@ int tMPI_Thread_create (tMPI_Thread_t * thread, - * - * \return 0 if the join went ok, or a non-zero error code. - */ --int tMPI_Thread_join (tMPI_Thread_t thread, -- void ** value_ptr); -+int tMPI_Thread_join(tMPI_Thread_t thread, void **value_ptr); - - - -@@ -430,7 +464,7 @@ int tMPI_Thread_once(tMPI_Thread_once_t *once_data, - * \param cond Pointer to previously allocated condition variable - * \return 0 or a non-zero error message. - */ --int tMPI_Thread_cond_init(tMPI_Thread_cond_t * cond); -+int tMPI_Thread_cond_init(tMPI_Thread_cond_t *cond); - - - -@@ -443,7 +477,7 @@ int tMPI_Thread_cond_init(tMPI_Thread_cond_t * cond); - * \param cond Pointer to condition variable. - * \return 0 or a non-zero error message. - */ --int tMPI_Thread_cond_destroy(tMPI_Thread_cond_t * cond); -+int tMPI_Thread_cond_destroy(tMPI_Thread_cond_t *cond); - - - -@@ -462,8 +496,8 @@ int tMPI_Thread_cond_destroy(tMPI_Thread_cond_t * cond); - * - * \return 0 or a non-zero error message. - */ --int tMPI_Thread_cond_wait(tMPI_Thread_cond_t * cond, -- tMPI_Thread_mutex_t * mtx); -+int tMPI_Thread_cond_wait(tMPI_Thread_cond_t *cond, -+ tMPI_Thread_mutex_t *mtx); - - - -@@ -478,7 +512,7 @@ int tMPI_Thread_cond_wait(tMPI_Thread_cond_t * cond, - * - * \return 0 or a non-zero error message. - */ --int tMPI_Thread_cond_signal(tMPI_Thread_cond_t * cond); -+int tMPI_Thread_cond_signal(tMPI_Thread_cond_t *cond); - - - /** Unblock all waiting threads -@@ -491,7 +525,7 @@ int tMPI_Thread_cond_signal(tMPI_Thread_cond_t * cond); - * - * \return 0 or a non-zero error message. - */ --int tMPI_Thread_cond_broadcast(tMPI_Thread_cond_t * cond); -+int tMPI_Thread_cond_broadcast(tMPI_Thread_cond_t *cond); - - - -@@ -504,7 +538,7 @@ int tMPI_Thread_cond_broadcast(tMPI_Thread_cond_t * cond); - * join them can read this value if they try. - * \return - */ --void tMPI_Thread_exit(void * value_ptr); -+void tMPI_Thread_exit(void *value_ptr); - - - -@@ -516,7 +550,7 @@ void tMPI_Thread_exit(void * value_ptr); - * \param thread Handle to thread we want to see dead. - * \return 0 or a non-zero error message. - */ --int tMPI_Thread_cancel(tMPI_Thread_t thread); -+int tMPI_Thread_cancel(tMPI_Thread_t thread); - - - -diff --git a/include/tmpi.h b/include/tmpi.h -index 1a660bc..9d90f07 100644 ---- a/include/tmpi.h -+++ b/include/tmpi.h -@@ -118,13 +118,13 @@ files. - - - #include "thread_mpi/atomic.h" -+#include "thread_mpi/numa_malloc.h" - #include "thread_mpi/threads.h" - #include "thread_mpi/barrier.h" - #include "thread_mpi/event.h" - #include "thread_mpi/lock.h" - #include "thread_mpi/tmpi.h" - #include "thread_mpi/collective.h" --#include "thread_mpi/hwinfo.h" - - #include "thread_mpi/mpi_bindings.h" - -diff --git a/include/typedefs.h b/include/typedefs.h -index 4d0e39c..7c766b7 100644 ---- a/include/typedefs.h -+++ b/include/typedefs.h -@@ -71,6 +71,9 @@ - #include "types/constr.h" - #include "types/matrix.h" - #include "types/oenv.h" -+#include "types/globsig.h" -+#include "types/nlistheuristics.h" -+#include "types/iteratedconstraints.h" - - #ifdef __cplusplus - extern "C" { -diff --git a/include/types/atoms.h b/include/types/atoms.h -index 8c73a84..ea31d9d 100644 ---- a/include/types/atoms.h -+++ b/include/types/atoms.h -@@ -48,12 +48,12 @@ enum { - /* The particle type */ - - typedef struct { -- real m,q; /* Mass and charge */ -- real mB,qB; /* Mass and charge for Free Energy calc */ -- unsigned short type; /* Atom type */ -- unsigned short typeB; /* Atom type for Free Energy calc */ -- int ptype; /* Particle type */ -- int resind; /* Index into resinfo in t_atoms) */ -+ real m,q; /* Mass and charge */ -+ real mB,qB; /* Mass and charge for Free Energy calc */ -+ unsigned short type; /* Atom type */ -+ unsigned short typeB; /* Atom type for Free Energy calc */ -+ int ptype; /* Particle type */ -+ int resind; /* Index into resinfo (in t_atoms) */ - int atomnumber; /* Atomic Number or NOTSET */ - char elem[4]; /* Element name */ - } t_atom; -@@ -74,40 +74,39 @@ typedef struct { - char atomnm[6]; /* True atom name including spaces */ - real occup; /* Occupancy */ - real bfac; /* B-factor */ -- gmx_bool bAnisotropic; /* (an)isotropic switch */ -+ gmx_bool bAnisotropic; /* (an)isotropic switch */ - int uij[6]; /* Anisotropic B-factor */ - } t_pdbinfo; - - typedef struct { -- int nr; /* Number of different groups */ -+ int nr; /* Number of different groups */ - int *nm_ind; /* Index in the group names */ - } t_grps; - - typedef struct { - int nr; /* Nr of atoms */ -- t_atom *atom; /* Array of atoms (dim: nr) */ -- /* The following entries will not */ -- /* allways be used (nres==0) */ -- char ***atomname; /* Array of pointers to atom name */ -- /* use: (*(atomname[i])) */ -- char ***atomtype; /* Array of pointers to atom types */ -- /* use: (*(atomtype[i])) */ -- char ***atomtypeB; /* Array of pointers to B atom types */ -- /* use: (*(atomtypeB[i])) */ -- int nres; /* The number of resinfo entries */ -+ t_atom *atom; /* Array of atoms (dim: nr) */ -+ /* The following entries will not */ -+ /* always be used (nres==0) */ -+ char ***atomname; /* Array of pointers to atom name */ -+ /* use: (*(atomname[i])) */ -+ char ***atomtype; /* Array of pointers to atom types */ -+ /* use: (*(atomtype[i])) */ -+ char ***atomtypeB; /* Array of pointers to B atom types */ -+ /* use: (*(atomtypeB[i])) */ -+ int nres; /* The number of resinfo entries */ - t_resinfo *resinfo; /* Array of residue names and numbers */ - t_pdbinfo *pdbinfo; /* PDB Information, such as aniso. Bfac */ - } t_atoms; - - typedef struct { -- int nr; /* number of atomtypes */ -- real *radius; /* GBSA radius for each atomtype */ -- real *vol; /* GBSA efective volume for each atomtype */ -- real *surftens; /* implicit solvent surftens for each atomtype */ -- real *gb_radius; /* GB radius for each atom type */ -- real *S_hct; /* Overlap factors for HCT/OBC GB models */ -- -- int *atomnumber; /* Atomic number, used for QM/MM */ -+ int nr; /* number of atomtypes */ -+ real *radius; /* GBSA radius for each atomtype */ -+ real *vol; /* GBSA efective volume for each atomtype */ -+ real *surftens; /* implicit solvent surftens for each atomtype */ -+ real *gb_radius; /* GB radius for each atom type */ -+ real *S_hct; /* Overlap factors for HCT/OBC GB models */ -+ int *atomnumber; /* Atomic number, used for QM/MM */ - } t_atomtypes; - - -diff --git a/include/types/globsig.h b/include/types/globsig.h -new file mode 100644 -index 0000000..29c634c ---- /dev/null -+++ b/include/types/globsig.h -@@ -0,0 +1,64 @@ -+/* -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * GRoups of Organic Molecules in ACtion for Science -+ */ -+#ifndef _globsig_h -+#define _globsig_h -+ -+#ifdef __cplusplus -+extern "C" { -+#endif -+ -+#if 0 -+} -+/* Hack to make automatic indenting work */ -+#endif -+ -+/* simulation conditions to transmit. Keep in mind that they are -+ transmitted to other nodes through an MPI_Reduce after -+ casting them to a real (so the signals can be sent together with other -+ data). This means that the only meaningful values are positive, -+ negative or zero. */ -+enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; -+ -+typedef struct { -+ int nstms; /* The frequency for intersimulation communication */ -+ int sig[eglsNR]; /* The signal set by one process in do_md */ -+ int set[eglsNR]; /* The communicated signal, equal for all processes */ -+} globsig_t; -+ -+#ifdef __cplusplus -+} -+#endif -+ -+#endif -diff --git a/include/types/iteratedconstraints.h b/include/types/iteratedconstraints.h -new file mode 100644 -index 0000000..501c274 ---- /dev/null -+++ b/include/types/iteratedconstraints.h -@@ -0,0 +1,70 @@ -+/* -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * GRoups of Organic Molecules in ACtion for Science -+ */ -+#ifndef _iteratedconstraints_h -+#define _iteratedconstraints_h -+ -+#ifdef __cplusplus -+extern "C" { -+#endif -+ -+#if 0 -+} -+/* Hack to make automatic indenting work */ -+#endif -+ -+/* Definitions for convergence of iterated constraints */ -+ -+/* iterate constraints up to 50 times */ -+#define MAXITERCONST 50 -+ -+/* data type */ -+typedef struct -+{ -+ real f,fprev,x,xprev; -+ int iter_i; -+ gmx_bool bIterate; -+ real allrelerr[MAXITERCONST+2]; -+ int num_close; /* number of "close" violations, caused by limited precision. */ -+} gmx_iterate_t; -+ -+void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate); -+ -+gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf); -+ -+#ifdef __cplusplus -+} -+#endif -+ -+#endif -diff --git a/include/types/nlistheuristics.h b/include/types/nlistheuristics.h -new file mode 100644 -index 0000000..b240bac ---- /dev/null -+++ b/include/types/nlistheuristics.h -@@ -0,0 +1,74 @@ -+/* -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * GRoups of Organic Molecules in ACtion for Science -+ */ -+#ifndef _nlistheuristics_h -+#define _nlistheuristics_h -+ -+#ifdef __cplusplus -+extern "C" { -+#endif -+ -+#if 0 -+} -+/* Hack to make automatic indenting work */ -+#endif -+ -+typedef struct { -+ gmx_bool bGStatEveryStep; -+ gmx_large_int_t step_ns; -+ gmx_large_int_t step_nscheck; -+ gmx_large_int_t nns; -+ matrix scale_tot; -+ int nabnsb; -+ double s1; -+ double s2; -+ double ab; -+ double lt_runav; -+ double lt_runav2; -+} gmx_nlheur_t; -+ -+void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step); -+ -+void init_nlistheuristics(gmx_nlheur_t *nlh, -+ gmx_bool bGStatEveryStep,gmx_large_int_t step); -+ -+void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step); -+ -+void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step); -+ -+#ifdef __cplusplus -+} -+#endif -+ -+#endif -diff --git a/include/types/pbc.h b/include/types/pbc.h -index a58e9ac..b94f77d 100644 ---- a/include/types/pbc.h -+++ b/include/types/pbc.h -@@ -32,8 +32,8 @@ - * And Hey: - * GRoups of Organic Molecules in ACtion for Science - */ --#ifndef _matrix_h --#define _matrix_h -+#ifndef _pbc_h -+#define _pbc_h - - - #include "simple.h" -diff --git a/include/types/topology.h b/include/types/topology.h -index 5fa9dee..cf8be0e 100644 ---- a/include/types/topology.h -+++ b/include/types/topology.h -@@ -52,7 +52,7 @@ enum { - - typedef struct { - char **name; /* Name of the molecule type */ -- t_atoms atoms; /* The atoms */ -+ t_atoms atoms; /* The atoms */ - t_ilist ilist[F_NRE]; - t_block cgs; /* The charge groups */ - t_blocka excls; /* The exclusions */ -@@ -71,9 +71,9 @@ typedef struct { - typedef struct { - t_grps grps[egcNR]; /* Groups of things */ - int ngrpname; /* Number of groupnames */ -- char ***grpname; /* Names of the groups */ -+ char ***grpname; /* Names of the groups */ - int ngrpnr[egcNR]; -- unsigned char *grpnr[egcNR]; /* Group numbers or NULL */ -+ unsigned char *grpnr[egcNR]; /* Group numbers or NULL */ - } gmx_groups_t; - - /* This macro gives the group number of group type egc for atom i. -@@ -85,7 +85,7 @@ typedef struct { - /* The global, complete system topology struct, based on molecule types. - This structure should contain no data that is O(natoms) in memory. */ - typedef struct { -- char **name; /* Name of the topology */ -+ char **name; /* Name of the topology */ - gmx_ffparams_t ffparams; - int nmoltype; - gmx_moltype_t *moltype; -@@ -97,12 +97,12 @@ typedef struct { - t_atomtypes atomtypes; /* Atomtype properties */ - t_block mols; /* The molecules */ - gmx_groups_t groups; -- t_symtab symtab; /* The symbol table */ -+ t_symtab symtab; /* The symbol table */ - } gmx_mtop_t; - - /* The mdrun node-local topology struct, completely written out */ - typedef struct { -- t_idef idef; /* The interaction function definition */ -+ t_idef idef; /* The interaction function definition */ - t_atomtypes atomtypes; /* Atomtype properties */ - t_block cgs; /* The charge groups */ - t_blocka excls; /* The exclusions */ -@@ -110,14 +110,14 @@ typedef struct { - - /* The old topology struct, completely written out, used in analysis tools */ - typedef struct { -- char **name; /* Name of the topology */ -- t_idef idef; /* The interaction function definition */ -- t_atoms atoms; /* The atoms */ -+ char **name; /* Name of the topology */ -+ t_idef idef; /* The interaction function definition */ -+ t_atoms atoms; /* The atoms */ - t_atomtypes atomtypes; /* Atomtype properties */ - t_block cgs; /* The charge groups */ - t_block mols; /* The molecules */ - t_blocka excls; /* The exclusions */ -- t_symtab symtab; /* The symbol table */ -+ t_symtab symtab; /* The symbol table */ - } t_topology; - - #ifdef __cplusplus -diff --git a/man/man1/Makefile.am b/man/man1/Makefile.am -index 3ad3d4a..813dd9f 100644 ---- a/man/man1/Makefile.am -+++ b/man/man1/Makefile.am -@@ -18,6 +18,7 @@ man_MANS = \ - g_current.1 \ - g_density.1 \ - g_densmap.1 \ -+ g_densorder.1 \ - g_dielectric.1 \ - g_dih.1 \ - g_dipoles.1 \ -@@ -32,6 +33,7 @@ man_MANS = \ - g_hbond.1 \ - g_helix.1 \ - g_helixorient.1 \ -+ g_hydorder.1 \ - g_lie.1 \ - g_mdmat.1 \ - g_membed.1 \ -@@ -41,7 +43,9 @@ man_MANS = \ - g_nmeig.1 \ - g_nmens.1 \ - g_nmtraj.1 \ -+ g_options.1 \ - g_order.1 \ -+ g_pme_error.1 \ - g_polystat.1 \ - g_potential.1 \ - g_principal.1 \ -diff --git a/man/man1/do_dssp.1 b/man/man1/do_dssp.1 -index 92b9b7a..8d7f0d3 100644 ---- a/man/man1/do_dssp.1 -+++ b/man/man1/do_dssp.1 -@@ -1,8 +1,8 @@ --.TH do_dssp 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH do_dssp 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - do_dssp - assigns secondary structure and calculates solvent accessible surface area - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3do_dssp\fP - .BI "\-f" " traj.xtc " -@@ -26,12 +26,13 @@ do_dssp - assigns secondary structure and calculates solvent accessible surface - .BI "\-xvg" " enum " - .BI "\-sss" " string " - .SH DESCRIPTION --\&do_dssp -+\&\fB do_dssp\fR - \&reads a trajectory file and computes the secondary structure for - \&each time frame - \&calling the dssp program. If you do not have the dssp program, --\&get it. do_dssp assumes that the dssp executable is --\&/usr/local/bin/dssp. If this is not the case, then you should -+\&get it from http://swift.cmbi.ru.nl/gv/dssp. \fB do_dssp\fR assumes -+\&that the dssp executable is located in -+\&\fB /usr/local/bin/dssp\fR. If this is not the case, then you should - \&set an environment variable \fB DSSP\fR pointing to the dssp - \&executable, e.g.: - -@@ -42,7 +43,7 @@ do_dssp - assigns secondary structure and calculates solvent accessible surface - \&The structure assignment for each residue and time is written to an - \&\fB .xpm\fR matrix file. This file can be visualized with for instance - \&\fB xv\fR and can be converted to postscript with \fB xpm2ps\fR. --\&Individual chains are separated by light grey lines in the xpm and -+\&Individual chains are separated by light grey lines in the \fB .xpm\fR and - \&postscript files. - \&The number of residues with each secondary structure type and the - \&total secondary structure (\fB \-sss\fR) count as a function of -@@ -125,7 +126,7 @@ do_dssp - assigns secondary structure and calculates solvent accessible surface - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/editconf.1 b/man/man1/editconf.1 -index 402147a..8806884 100644 ---- a/man/man1/editconf.1 -+++ b/man/man1/editconf.1 -@@ -1,8 +1,8 @@ --.TH editconf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH editconf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - editconf - edits the box and writes subgroups - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3editconf\fP - .BI "\-f" " conf.gro " -@@ -29,6 +29,7 @@ editconf - edits the box and writes subgroups - .BI "\-scale" " vector " - .BI "\-density" " real " - .BI "\-[no]pbc" "" -+.BI "\-resnr" " int " - .BI "\-[no]grasp" "" - .BI "\-rvdw" " real " - .BI "\-sig56" " real " -@@ -38,7 +39,7 @@ editconf - edits the box and writes subgroups - .BI "\-label" " string " - .BI "\-[no]conect" "" - .SH DESCRIPTION --\&editconf converts generic structure format to \fB .gro\fR, \fB .g96\fR -+\&\fB editconf\fR converts generic structure format to \fB .gro\fR, \fB .g96\fR - \&or \fB .pdb\fR. - \& - -@@ -56,18 +57,19 @@ editconf - edits the box and writes subgroups - \&The last two are special cases of a triclinic box. - \&The length of the three box vectors of the truncated octahedron is the - \&shortest distance between two opposite hexagons. --\&The volume of a dodecahedron is 0.71 and that of a truncated octahedron --\&is 0.77 of that of a cubic box with the same periodic image distance. -+\&Relative to a cubic box with some periodic image distance, the volume of a -+\&dodecahedron with this same periodic distance is 0.71 times that of the cube, -+\&and that of a truncated octahedron is 0.77 times. - \& - - - \&Option \fB \-box\fR requires only --\&one value for a cubic box, dodecahedron and a truncated octahedron. -+\&one value for a cubic, rhombic dodecahedral, or truncated octahedral box. - \& - - --\&With \fB \-d\fR and a \fB triclinic\fR box the size of the system in the x, y --\&and z directions is used. With \fB \-d\fR and \fB cubic\fR, -+\&With \fB \-d\fR and a \fB triclinic\fR box the size of the system in the \fI x\fR\-, \fI y\fR\-, -+\&and \fI z\fR\-directions is used. With \fB \-d\fR and \fB cubic\fR, - \&\fB dodecahedron\fR or \fB octahedron\fR boxes, the dimensions are set - \&to the diameter of the system (largest distance between atoms) plus twice - \&the specified distance. -@@ -75,7 +77,7 @@ editconf - edits the box and writes subgroups - - - \&Option \fB \-angles\fR is only meaningful with option \fB \-box\fR and --\&a triclinic box and can not be used with option \fB \-d\fR. -+\&a triclinic box and cannot be used with option \fB \-d\fR. - \& - - -@@ -90,17 +92,18 @@ editconf - edits the box and writes subgroups - - - \&\fB \-princ\fR aligns the principal axes of the system along the --\&coordinate axes, this may allow you to decrease the box volume, -+\&coordinate axes, with the longest axis aligned with the \fI x\fR\-axis. -+\&This may allow you to decrease the box volume, - \&but beware that molecules can rotate significantly in a nanosecond. - \& - - - \&Scaling is applied before any of the other operations are - \&performed. Boxes and coordinates can be scaled to give a certain density (option --\&\fB \-density\fR). Note that this may be inaccurate in case a gro --\&file is given as input. A special feature of the scaling option, when the -+\&\fB \-density\fR). Note that this may be inaccurate in case a \fB .gro\fR -+\&file is given as input. A special feature of the scaling option is that when the - \&factor \-1 is given in one dimension, one obtains a mirror image, --\&mirrored in one of the plains, when one uses \-1 in three dimensions -+\&mirrored in one of the planes. When one uses \-1 in three dimensions, - \&a point\-mirror image is obtained. - - -@@ -108,7 +111,7 @@ editconf - edits the box and writes subgroups - - - \&Periodicity can be removed in a crude manner. --\&It is important that the box sizes at the bottom of your input file -+\&It is important that the box vectors at the bottom of your input file - \&are correct when the periodicity is to be removed. - \& - -@@ -126,7 +129,8 @@ editconf - edits the box and writes subgroups - \& - - --\&With the option \-mead a special pdb (pqr) file for the MEAD electrostatics -+\&With the option \fB \-mead\fR a special \fB .pdb\fR (\fB .pqr\fR) -+\&file for the MEAD electrostatics - \&program (Poisson\-Boltzmann solver) can be made. A further prerequisite - \&is that the input file is a run input file. - \&The B\-factor field is then filled with the Van der Waals radius -@@ -134,7 +138,7 @@ editconf - edits the box and writes subgroups - \& - - --\&The option \-grasp is similar, but it puts the charges in the B\-factor -+\&The option \fB \-grasp\fR is similar, but it puts the charges in the B\-factor - \&and the radius in the occupancy. - \& - -@@ -145,13 +149,13 @@ editconf - edits the box and writes subgroups - \& - - --\&Finally with option \fB \-label\fR editconf can add a chain identifier --\&to a pdb file, which can be useful for analysis with e.g. rasmol. -+\&Finally, with option \fB \-label\fR, \fB editconf\fR can add a chain identifier -+\&to a \fB .pdb\fR file, which can be useful for analysis with e.g. Rasmol. - \& - - - \&To convert a truncated octrahedron file produced by a package which uses --\&a cubic box with the corners cut off (such as Gromos) use: -+\&a cubic box with the corners cut off (such as GROMOS), use: - - \&\fB editconf \-f in \-rotate 0 45 35.264 \-bt o \-box veclen \-o out\fR - -@@ -188,7 +192,7 @@ editconf - edits the box and writes subgroups - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-[no]ndef" "no " - Choose output from default index groups -@@ -230,11 +234,14 @@ editconf - edits the box and writes subgroups - Scaling factor - - .BI "\-density" " real" " 1000 " -- Density (g/l) of the output box achieved by scaling -+ Density (g/L) of the output box achieved by scaling - - .BI "\-[no]pbc" "no " - Remove the periodicity (make molecule whole again) - -+.BI "\-resnr" " int" " \-1" -+ Renumber residues starting from resnr -+ - .BI "\-[no]grasp" "no " - Store the charge of the atom in the B\-factor field and the radius of the atom in the occupancy field - -@@ -257,12 +264,10 @@ editconf - edits the box and writes subgroups - Add chain label for all residues - - .BI "\-[no]conect" "no " -- Add CONECT records to a pdb file when written. Can only be done when a topology is present -+ Add CONECT records to a \fB .pdb\fR file when written. Can only be done when a topology is present - - .SH KNOWN PROBLEMS --\- For complex molecules, the periodicity removal routine may break down, -- --\- in that case you can use trjconv. -+\- For complex molecules, the periodicity removal routine may break down, in that case you can use \fB trjconv\fR. - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/eneconv.1 b/man/man1/eneconv.1 -index 6dc846c..703abce 100644 ---- a/man/man1/eneconv.1 -+++ b/man/man1/eneconv.1 -@@ -1,8 +1,8 @@ --.TH eneconv 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH eneconv 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - eneconv - converts energy files - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3eneconv\fP - .BI "\-f" " ener.edr " -@@ -16,17 +16,18 @@ eneconv - converts energy files - .BI "\-offset" " real " - .BI "\-[no]settime" "" - .BI "\-[no]sort" "" -+.BI "\-[no]rmdh" "" - .BI "\-scalefac" " real " - .BI "\-[no]error" "" - .SH DESCRIPTION - \&With \fI multiple files\fR specified for the \fB \-f\fR option: - - \&Concatenates several energy files in sorted order. --\&In case of double time frames the one -+\&In the case of double time frames, the one - \&in the later file is used. By specifying \fB \-settime\fR you will be - \&asked for the start time of each file. The input files are taken - \&from the command line, --\&such that the command \fB eneconv \-o fixed.edr *.edr\fR should do -+\&such that the command \fB eneconv \-f *.edr \-o fixed.edr\fR should do - \&the trick. - - -@@ -69,7 +70,7 @@ eneconv - converts energy files - Only write out frame when t MOD dt = offset - - .BI "\-offset" " real" " 0 " -- Time offset for \-dt option -+ Time offset for \fB \-dt\fR option - - .BI "\-[no]settime" "no " - Change starting time interactively -@@ -77,6 +78,9 @@ eneconv - converts energy files - .BI "\-[no]sort" "yes " - Sort energy files (not frames) - -+.BI "\-[no]rmdh" "no " -+ Remove free energy block data -+ - .BI "\-scalefac" " real" " 1 " - Multiply energy component by this factor - -diff --git a/man/man1/g_anadock.1 b/man/man1/g_anadock.1 -index d32edf5..fc8b6c2 100644 ---- a/man/man1/g_anadock.1 -+++ b/man/man1/g_anadock.1 -@@ -1,8 +1,8 @@ --.TH g_anadock 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_anadock 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_anadock - cluster structures from Autodock runs - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_anadock\fP - .BI "\-f" " eiwit.pdb " -@@ -18,14 +18,14 @@ g_anadock - cluster structures from Autodock runs - .BI "\-[no]rms" "" - .BI "\-cutoff" " real " - .SH DESCRIPTION --\&anadock analyses the results of an Autodock run and clusters the -+\&\fB g_anadock\fR analyses the results of an Autodock run and clusters the - \&structures together, based on distance or RMSD. The docked energy - \&and free energy estimates are analysed, and for each cluster the - \&energy statistics are printed. - - - \&An alternative approach to this is to cluster the structures first --\&(using \fB g_cluster\fR and then sort the clusters on either lowest -+\&using \fB g_cluster\fR and then sort the clusters on either lowest - \&energy or average energy. - .SH FILES - .BI "\-f" " eiwit.pdb" -diff --git a/man/man1/g_anaeig.1 b/man/man1/g_anaeig.1 -index f34e4ed..b23c3d0 100644 ---- a/man/man1/g_anaeig.1 -+++ b/man/man1/g_anaeig.1 -@@ -1,8 +1,8 @@ --.TH g_anaeig 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_anaeig 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_anaeig - analyzes the eigenvectors - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_anaeig\fP - .BI "\-v" " eigenvec.trr " -@@ -91,12 +91,12 @@ g_anaeig - analyzes the eigenvectors - \&\fB \-last\fR have been set explicitly, in which case all eigenvectors - \&will be written to separate files. Chain identifiers will be added - \&when writing a \fB .pdb\fR file with two or three structures (you --\&can use \fB rasmol \-nmrpdb\fR to view such a pdb file). -+\&can use \fB rasmol \-nmrpdb\fR to view such a \fB .pdb\fR file). - - - \& Overlap calculations between covariance analysis: - --\& NOTE: the analysis should use the same fitting structure -+\& \fB Note:\fR the analysis should use the same fitting structure - - - \&\fB \-over\fR: calculate the subspace overlap of the eigenvectors in -@@ -218,7 +218,7 @@ g_anaeig - analyzes the eigenvectors - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_analyze.1 b/man/man1/g_analyze.1 -index a9d90fe..7237823 100644 ---- a/man/man1/g_analyze.1 -+++ b/man/man1/g_analyze.1 -@@ -1,8 +1,8 @@ --.TH g_analyze 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_analyze 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_analyze - analyzes data sets - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_analyze\fP - .BI "\-f" " graph.xvg " -@@ -47,23 +47,23 @@ g_analyze - analyzes data sets - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_analyze reads an ascii file and analyzes data sets. -+\&\fB g_analyze\fR reads an ASCII file and analyzes data sets. - \&A line in the input file may start with a time --\&(see option \fB \-time\fR) and any number of y values may follow. -+\&(see option \fB \-time\fR) and any number of \fI y\fR\-values may follow. - \&Multiple sets can also be --\&read when they are separated by & (option \fB \-n\fR), --\&in this case only one y value is read from each line. -+\&read when they are separated by & (option \fB \-n\fR); -+\&in this case only one \fI y\fR\-value is read from each line. - \&All lines starting with and @ are skipped. - \&All analyses can also be done for the derivative of a set - \&(option \fB \-d\fR). - - --\&All options, except for \fB \-av\fR and \fB \-power\fR assume that the -+\&All options, except for \fB \-av\fR and \fB \-power\fR, assume that the - \&points are equidistant in time. - - --\&g_analyze always shows the average and standard deviation of each --\&set. For each set it also shows the relative deviation of the third -+\&\fB g_analyze\fR always shows the average and standard deviation of each -+\&set, as well as the relative deviation of the third - \&and fourth cumulant from those of a Gaussian distribution with the same - \&standard deviation. - -@@ -104,13 +104,13 @@ g_analyze - analyzes data sets - \&that the autocorrelation is a sum of two exponentials. - \&The analytical curve for the block average is: - --\&f(t) = sigma sqrt(2/T ( a (tau1 ((exp(\-t/tau1) \- 1) tau1/t + 1)) + -+\&f(t) = sigma\fB *\fRsqrt(2/T ( alpha (tau1 ((exp(\-t/tau1) \- 1) tau1/t + 1)) + - --\& (1\-a) (tau2 ((exp(\-t/tau2) \- 1) tau2/t + 1)))), -+\& (1\-alpha) (tau2 ((exp(\-t/tau2) \- 1) tau2/t + 1)))), - where T is the total time. --\&a, tau1 and tau2 are obtained by fitting f2(t) to error2. -+\&alpha, tau1 and tau2 are obtained by fitting f2(t) to error2. - \&When the actual block average is very close to the analytical curve, --\&the error is sigma*sqrt(2/T (a tau1 + (1\-a) tau2)). -+\&the error is sigma\fB *\fRsqrt(2/T (a tau1 + (1\-a) tau2)). - \&The complete derivation is given in - \&B. Hess, J. Chem. Phys. 116:209\-217, 2002. - -@@ -145,7 +145,7 @@ where T is the total time. - - \&Option \fB \-power\fR fits the data to b ta, which is accomplished - \&by fitting to a t + b on log\-log scale. All points after the first --\&zero or negative value are ignored. -+\&zero or with a negative value are ignored. - - Option \fB \-luzar\fR performs a Luzar & Chandler kinetics analysis - \&on output from \fB g_hbond\fR. The input file can be taken directly -@@ -198,7 +198,7 @@ Option \fB \-luzar\fR performs a Luzar & Chandler kinetics analysis - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -222,7 +222,7 @@ Option \fB \-luzar\fR performs a Luzar & Chandler kinetics analysis - Binwidth for the distribution - - .BI "\-errbar" " enum" " none" -- Error bars for \-av: \fB none\fR, \fB stddev\fR, \fB error\fR or \fB 90\fR -+ Error bars for \fB \-av\fR: \fB none\fR, \fB stddev\fR, \fB error\fR or \fB 90\fR - - .BI "\-[no]integrate" "no " - Integrate data function(s) numerically using trapezium rule -@@ -234,10 +234,10 @@ Option \fB \-luzar\fR performs a Luzar & Chandler kinetics analysis - Interpret second data set as error in the y values for integrating - - .BI "\-[no]regression" "no " -- Perform a linear regression analysis on the data. If \-xydy is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize chi2 = (y \- A0 x0 \- A1 x1 \- ... \- AN xN)2 where now Y is the first data set in the input file and xi the others. Do read the information at the option \fB \-time\fR. -+ Perform a linear regression analysis on the data. If \fB \-xydy\fR is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize chi2 = (y \- A0 x0 \- A1 x1 \- ... \- AN xN)2 where now Y is the first data set in the input file and xi the others. Do read the information at the option \fB \-time\fR. - - .BI "\-[no]luzar" "no " -- Do a Luzar and Chandler analysis on a correlation function and related as produced by g_hbond. When in addition the \-xydy flag is given the second and fourth column will be interpreted as errors in c(t) and n(t). -+ Do a Luzar and Chandler analysis on a correlation function and related as produced by \fB g_hbond\fR. When in addition the \fB \-xydy\fR flag is given the second and fourth column will be interpreted as errors in c(t) and n(t). - - .BI "\-temp" " real" " 298.15" - Temperature for the Luzar hydrogen bonding kinetics analysis -@@ -246,7 +246,7 @@ Option \fB \-luzar\fR performs a Luzar & Chandler kinetics analysis - Time (ps) from which to start fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation - - .BI "\-fitend" " real" " 60 " -- Time (ps) where to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. Only with \-gem -+ Time (ps) where to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. Only with \fB \-gem\fR - - .BI "\-smooth" " real" " \-1 " - If = 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(\-x/tau) -@@ -273,7 +273,7 @@ Option \fB \-luzar\fR performs a Luzar & Chandler kinetics analysis - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_angle.1 b/man/man1/g_angle.1 -index f69617d..be7c954 100644 ---- a/man/man1/g_angle.1 -+++ b/man/man1/g_angle.1 -@@ -1,8 +1,8 @@ --.TH g_angle 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_angle 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_angle - calculates distributions and correlations for angles and dihedrals - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_angle\fP - .BI "\-f" " traj.xtc " -@@ -36,22 +36,22 @@ g_angle - calculates distributions and correlations for angles and dihedrals - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_angle computes the angle distribution for a number of angles -+\&\fB g_angle\fR computes the angle distribution for a number of angles - \&or dihedrals. This way you can check whether your simulation --\&is correct. With option \-ov you can plot the average angle of --\&a group of angles as a function of time. With the \-all option -+\&is correct. With option \fB \-ov\fR you can plot the average angle of -+\&a group of angles as a function of time. With the \fB \-all\fR option - \&the first graph is the average, the rest are the individual angles. - - --\&With the \-of option g_angle also calculates the fraction of trans -+\&With the \fB \-of\fR option, \fB g_angle\fR also calculates the fraction of trans - \&dihedrals (only for dihedrals) as function of time, but this is - \&probably only fun for a selected few. - - --\&With option \-oc a dihedral correlation function is calculated. -+\&With option \fB \-oc\fR a dihedral correlation function is calculated. - - --\&It should be noted that the indexfile should contain -+\&It should be noted that the index file should contain - \&atom\-triples for angles or atom\-quadruplets for dihedrals. - \&If this is not the case, the program will crash. - -@@ -116,7 +116,7 @@ g_angle - calculates distributions and correlations for angles and dihedrals - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -134,7 +134,7 @@ g_angle - calculates distributions and correlations for angles and dihedrals - Print dihedral angles modulo 360 degrees - - .BI "\-[no]chandler" "no " -- Use Chandler correlation function (N[trans] = 1, N[gauche] = 0) rather than cosine correlation function. Trans is defined as phi \-60 || phi 60. -+ Use Chandler correlation function (N[trans] = 1, N[gauche] = 0) rather than cosine correlation function. Trans is defined as phi \-60 or phi 60. - - .BI "\-[no]avercorr" "no " - Average the correlation functions for the individual angles/dihedrals -@@ -149,7 +149,7 @@ g_angle - calculates distributions and correlations for angles and dihedrals - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_bar.1 b/man/man1/g_bar.1 -index dd4a4f4..3ecfe5b 100644 ---- a/man/man1/g_bar.1 -+++ b/man/man1/g_bar.1 -@@ -1,15 +1,15 @@ --.TH g_bar 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_bar 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_bar - calculates free energy difference estimates through Bennett's acceptance ratio - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_bar\fP - .BI "\-f" " dhdl.xvg " -+.BI "\-g" " ener.edr " - .BI "\-o" " bar.xvg " - .BI "\-oi" " barint.xvg " - .BI "\-oh" " histogram.xvg " --.BI "\-g" " energy.edr " - .BI "\-[no]h" "" - .BI "\-[no]version" "" - .BI "\-nice" " int " -@@ -23,42 +23,73 @@ g_bar - calculates free energy difference estimates through Bennett's acceptance - .BI "\-nbmax" " int " - .BI "\-nbin" " int " - .SH DESCRIPTION --\&g_bar calculates free energy difference estimates through --\&Bennett's acceptance ratio method. --\&Input option \fB \-f\fR expects multiple dhdl files. -+\&\fB g_bar\fR calculates free energy difference estimates through -+\&Bennett's acceptance ratio method (BAR). It also automatically -+\&adds series of individual free energies obtained with BAR into -+\&a combined free energy estimate. -+ -+ -+\&Every individual BAR free energy difference relies on two -+\&simulations at different states: say state A and state B, as -+\&controlled by a parameter, lambda (see the \fB .mdp\fR parameter -+\&\fB init_lambda\fR). The BAR method calculates a ratio of weighted -+\&average of the Hamiltonian difference of state B given state A and -+\&vice versa. If the Hamiltonian does not depend linearly on lambda -+\&(in which case we can extrapolate the derivative of the Hamiltonian -+\&with respect to lambda, as is the default when \fB free_energy\fR is on), -+\&the energy differences to the other state need to be calculated -+\&explicitly during the simulation. This can be controlled with -+\&the \fB .mdp\fR option \fB foreign_lambda\fR. -+ -+ -+\&Input option \fB \-f\fR expects multiple \fB dhdl.xvg\fR files. - \&Two types of input files are supported: - --\&* Files with only one y\-value, for such files it is assumed --\&that the y\-value is dH/dlambda and that the Hamiltonian depends --\&linearly on lambda. The lambda value of the simulation is inferred --\&from the subtitle if present, otherwise from a number in the --\&subdirectory in the file name. -+\&\fB *\fR Files with only one \fI y\fR\-value, for such files it is assumed -+\& that the \fI y\fR\-value is dH/dlambda and that the Hamiltonian depends -+\& linearly on lambda. The lambda value of the simulation is inferred -+\& from the subtitle (if present), otherwise from a number in the -+\& subdirectory in the file name. - \& - --\&* Files with more than one y\-value. The files should have columns --\&with dH/dlambda and Delta lambda. The lambda values are inferred --\&from the legends: --\&lambda of the simulation from the legend of dH/dlambda --\&and the foreign lambda's from the legends of Delta H. -+\&\fB *\fR Files with more than one \fI y\fR\-value. The files should have columns -+\& with dH/dlambda and Deltalambda. The lambda values are inferred -+\& from the legends: lambda of the simulation from the legend of dH/dlambda -+\& and the foreign lambda values from the legends of Delta H. - - --\&The lambda of the simulation is parsed from dhdl.xvg file's legend --\&containing the string 'dH', the foreign lambda's from the legend -+\&The lambda of the simulation is parsed from \fB dhdl.xvg\fR file's legend -+\&containing the string 'dH', the foreign lambda values from the legend - \&containing the capitalized letters 'D' and 'H'. The temperature - \&is parsed from the legend line containing 'T ='. - - --\&The free energy estimates are determined using BAR with bisection, --\&the precision of the output is set with \fB \-prec\fR. -+\&The input option \fB \-g\fR expects multiple \fB .edr\fR files. -+\&These can contain either lists of energy differences (see the -+\&\fB .mdp\fR option \fB separate_dhdl_file\fR), or a series of histograms -+\&(see the \fB .mdp\fR options \fB dh_hist_size\fR and \fB dh_hist_spacing\fR). -+\&The temperature and lambda values are automatically deduced from -+\&the \fB ener.edr\fR file. -+ -+The free energy estimates are determined using BAR with bisection, -+\&with the precision of the output set with \fB \-prec\fR. - \&An error estimate taking into account time correlations - \&is made by splitting the data into blocks and determining - \&the free energy differences over those blocks and assuming - \&the blocks are independent. - \&The final error estimate is determined from the average variance --\&over 5 blocks. A range of blocks numbers for error estimation can -+\&over 5 blocks. A range of block numbers for error estimation can - \&be provided with the options \fB \-nbmin\fR and \fB \-nbmax\fR. - - -+\&\fB g_bar\fR tries to aggregate samples with the same 'native' and 'foreign' -+\&lambda values, but always assumes independent samples. \fB Note\fR that -+\&when aggregating energy differences/derivatives with different -+\&sampling intervals, this is almost certainly not correct. Usually -+\&subsequent energies are correlated and different time intervals mean -+\&different degrees of correlation between samples. -+ -+ - \&The results are split in two parts: the last part contains the final - \&results in kJ/mol, together with the error estimate for each part - \&and the total. The first part contains detailed free energy -@@ -66,17 +97,17 @@ g_bar - calculates free energy difference estimates through Bennett's acceptance - \&kT (together with their computed error estimate). The printed - \&values are: - --\&* lam_A: the lambda values for point A. -+\&\fB *\fR lam_A: the lambda values for point A. - --\&* lam_B: the lambda values for point B. -+\&\fB *\fR lam_B: the lambda values for point B. - --\&* DG: the free energy estimate. -+\&\fB *\fR DG: the free energy estimate. - --\&* s_A: an estimate of the relative entropy of B in A. -+\&\fB *\fR s_A: an estimate of the relative entropy of B in A. - --\&* s_A: an estimate of the relative entropy of A in B. -+\&\fB *\fR s_A: an estimate of the relative entropy of A in B. - --\&* stdev: an estimate expected per\-sample standard deviation. -+\&\fB *\fR stdev: an estimate expected per\-sample standard deviation. - - - \&The relative entropy of both states in each other's ensemble can be -@@ -85,15 +116,19 @@ g_bar - calculates free energy difference estimates through Bennett's acceptance - \&ensemble of lambda_A (and vice versa for s_B), is a - \&measure of the 'distance' between Boltzmann distributions of - \&the two states, that goes to zero for identical distributions. See --\&Wu & Kofke, J. Chem. Phys. 123 084109 (2009) for more information. -+\&Wu & Kofke, J. Chem. Phys. 123 084109 (2005) for more information. - \& - - - \&The estimate of the expected per\-sample standard deviation, as given --\&in Bennett's original BAR paper: --\&Bennett, J. Comp. Phys. 22, p 245 (1976), Eq. 10 gives an estimate --\&of the quality of sampling (not directly of the actual statistical --\&error, because it assumes independent samples). -+\&in Bennett's original BAR paper: Bennett, J. Comp. Phys. 22, p 245 (1976). -+\&Eq. 10 therein gives an estimate of the quality of sampling (not directly -+\&of the actual statistical error, because it assumes independent samples). -+ -+ -+\&To get a visual estimate of the phase space overlap, use the -+\&\fB \-oh\fR option to write series of histograms, together with the -+\&\fB \-nbin\fR option. - - - .SH FILES -@@ -101,6 +136,10 @@ g_bar - calculates free energy difference estimates through Bennett's acceptance - .B Input, Opt., Mult. - xvgr/xmgr file - -+.BI "\-g" " ener.edr" -+.B Input, Opt., Mult. -+ Energy file -+ - .BI "\-o" " bar.xvg" - .B Output, Opt. - xvgr/xmgr file -@@ -113,10 +152,6 @@ g_bar - calculates free energy difference estimates through Bennett's acceptance - .B Output, Opt. - xvgr/xmgr file - --.BI "\-g" " energy.edr" --.B Input, Opt., Mult. -- Energy file -- - .SH OTHER OPTIONS - .BI "\-[no]h" "no " - Print help info and quit -@@ -128,7 +163,7 @@ g_bar - calculates free energy difference estimates through Bennett's acceptance - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_bond.1 b/man/man1/g_bond.1 -index ec92658..8944075 100644 ---- a/man/man1/g_bond.1 -+++ b/man/man1/g_bond.1 -@@ -1,8 +1,8 @@ --.TH g_bond 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_bond 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_bond - calculates distances between atoms - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_bond\fP - .BI "\-f" " traj.xtc " -@@ -24,8 +24,8 @@ g_bond - calculates distances between atoms - .BI "\-[no]aver" "" - .BI "\-[no]averdist" "" - .SH DESCRIPTION --\&g_bond makes a distribution of bond lengths. If all is well a --\&gaussian distribution should be made when using a harmonic potential. -+\&\fB g_bond\fR makes a distribution of bond lengths. If all is well a -+\&Gaussian distribution should be made when using a harmonic potential. - \&Bonds are read from a single group in the index file in order i1\-j1 - \&i2\-j2 through in\-jn. - -@@ -84,7 +84,7 @@ g_bond - calculates distances between atoms - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -99,7 +99,7 @@ g_bond - calculates distances between atoms - Average bond length distributions - - .BI "\-[no]averdist" "yes " -- Average distances (turns on \-d) -+ Average distances (turns on \fB \-d\fR) - - .SH KNOWN PROBLEMS - \- It should be possible to get bond information from the topology. -diff --git a/man/man1/g_bundle.1 b/man/man1/g_bundle.1 -index ad82758..a80d361 100644 ---- a/man/man1/g_bundle.1 -+++ b/man/man1/g_bundle.1 -@@ -1,8 +1,8 @@ --.TH g_bundle 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_bundle 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_bundle - analyzes bundles of axes, e.g. helices - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_bundle\fP - .BI "\-f" " traj.xtc " -@@ -29,7 +29,7 @@ g_bundle - analyzes bundles of axes, e.g. helices - .BI "\-na" " int " - .BI "\-[no]z" "" - .SH DESCRIPTION --\&g_bundle analyzes bundles of axes. The axes can be for instance -+\&\fB g_bundle\fR analyzes bundles of axes. The axes can be for instance - \&helix axes. The program reads two index groups and divides both - \&of them in \fB \-na\fR parts. The centers of mass of these parts - \&define the tops and bottoms of the axes. -@@ -50,8 +50,8 @@ g_bundle - analyzes bundles of axes, e.g. helices - - \&With option \fB \-oa\fR the top, mid (or kink when \fB \-ok\fR is set) - \&and bottom points of each axis --\&are written to a pdb file each frame. The residue numbers correspond --\&to the axis numbers. When viewing this file with \fB rasmol\fR, use the -+\&are written to a \fB .pdb\fR file each frame. The residue numbers correspond -+\&to the axis numbers. When viewing this file with Rasmol, use the - \&command line option \fB \-nmrpdb\fR, and type \fB set axis true\fR to - \&display the reference axis. - .SH FILES -@@ -136,7 +136,7 @@ g_bundle - analyzes bundles of axes, e.g. helices - Number of axes - - .BI "\-[no]z" "no " -- Use the Z\-axis as reference iso the average axis -+ Use the \fI z\fR\-axis as reference instead of the average axis - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_chi.1 b/man/man1/g_chi.1 -index d43c71c..5625ba2 100644 ---- a/man/man1/g_chi.1 -+++ b/man/man1/g_chi.1 -@@ -1,8 +1,8 @@ --.TH g_chi 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_chi 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_chi - calculates everything you want to know about chi and other dihedrals - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_chi\fP - .BI "\-s" " conf.gro " -@@ -52,25 +52,25 @@ g_chi - calculates everything you want to know about chi and other dihedrals - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_chi computes phi, psi, omega and chi dihedrals for all your -+\&\fB g_chi\fR computes phi, psi, omega, and chi dihedrals for all your - \&amino acid backbone and sidechains. - \&It can compute dihedral angle as a function of time, and as - \&histogram distributions. --\&The distributions (histo\-(dihedral)(RESIDUE).xvg) are cumulative over all residues of each type. -+\&The distributions \fB (histo\-(dihedral)(RESIDUE).xvg\fR) are cumulative over all residues of each type. - - - \&If option \fB \-corr\fR is given, the program will - \&calculate dihedral autocorrelation functions. The function used - \&is C(t) = cos(chi(tau)) cos(chi(tau+t)) . The use of cosines - \&rather than angles themselves, resolves the problem of periodicity. --\&(Van der Spoel & Berendsen (1997), \fB Biophys. J. 72\fR, 2032\-2041). -+\&(Van der Spoel & Berendsen (1997), Biophys. J. 72, 2032\-2041). - \&Separate files for each dihedral of each residue --\&(corr(dihedral)(RESIDUE)(nresnr).xvg) are output, as well as a -+\&\fB (corr(dihedral)(RESIDUE)(nresnr).xvg\fR) are output, as well as a - \&file containing the information for all residues (argument of \fB \-corr\fR). - - - \&With option \fB \-all\fR, the angles themselves as a function of time for --\&each residue are printed to separate files (dihedral)(RESIDUE)(nresnr).xvg. -+\&each residue are printed to separate files \fB (dihedral)(RESIDUE)(nresnr).xvg\fR. - \&These can be in radians or degrees. - - -@@ -85,32 +85,33 @@ g_chi - calculates everything you want to know about chi and other dihedrals - - \&(d) a table for each residue of the rotamer occupancy. - --\&All rotamers are taken as 3\-fold, except for omegas and chi\-dihedrals --\&to planar groups (i.e. chi2 of aromatics asp and asn, chi3 of glu --\&and gln, and chi4 of arg), which are 2\-fold. "rotamer 0" means -+ -+\&All rotamers are taken as 3\-fold, except for omega and chi dihedrals -+\&to planar groups (i.e. chi2 of aromatics, Asp and Asn; chi3 of Glu -+\&and Gln; and chi4 of Arg), which are 2\-fold. "rotamer 0" means - \&that the dihedral was not in the core region of each rotamer. - \&The width of the core region can be set with \fB \-core_rotamer\fR - - --\&The S2 order parameters are also output to an xvg file --\&(argument \fB \-o\fR ) and optionally as a pdb file with -+\&The S2 order parameters are also output to an \fB .xvg\fR file -+\&(argument \fB \-o\fR ) and optionally as a \fB .pdb\fR file with - \&the S2 values as B\-factor (argument \fB \-p\fR). - \&The total number of rotamer transitions per timestep - \&(argument \fB \-ot\fR), the number of transitions per rotamer - \&(argument \fB \-rt\fR), and the 3J couplings (argument \fB \-jc\fR), --\&can also be written to .xvg files. -+\&can also be written to \fB .xvg\fR files. - - --\&If \fB \-chi_prod\fR is set (and maxchi 0), cumulative rotamers, e.g. -+\&If \fB \-chi_prod\fR is set (and \fB \-maxchi\fR 0), cumulative rotamers, e.g. - \&1+9(chi1\-1)+3(chi2\-1)+(chi3\-1) (if the residue has three 3\-fold --\&dihedrals and maxchi = 3) -+\&dihedrals and \fB \-maxchi\fR = 3) - \&are calculated. As before, if any dihedral is not in the core region, - \&the rotamer is taken to be 0. The occupancies of these cumulative - \&rotamers (starting with rotamer 0) are written to the file - \&that is the argument of \fB \-cp\fR, and if the \fB \-all\fR flag - \&is given, the rotamers as functions of time --\&are written to chiproduct(RESIDUE)(nresnr).xvg --\&and their occupancies to histo\-chiproduct(RESIDUE)(nresnr).xvg. -+\&are written to \fB chiproduct(RESIDUE)(nresnr).xvg\fR -+\&and their occupancies to \fB histo\-chiproduct(RESIDUE)(nresnr).xvg\fR. - - - \&The option \fB \-r\fR generates a contour plot of the average omega angle -@@ -185,7 +186,7 @@ g_chi - calculates everything you want to know about chi and other dihedrals - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -194,16 +195,16 @@ g_chi - calculates everything you want to know about chi and other dihedrals - starting residue - - .BI "\-[no]phi" "no " -- Output for Phi dihedral angles -+ Output for phi dihedral angles - - .BI "\-[no]psi" "no " -- Output for Psi dihedral angles -+ Output for psi dihedral angles - - .BI "\-[no]omega" "no " -- Output for Omega dihedrals (peptide bonds) -+ Output for omega dihedrals (peptide bonds) - - .BI "\-[no]rama" "no " -- Generate Phi/Psi and Chi1/Chi2 ramachandran plots -+ Generate phi/psi and chi1/chi2 Ramachandran plots - - .BI "\-[no]viol" "no " - Write a file that gives 0 or 1 for violated Ramachandran angles -@@ -218,25 +219,25 @@ g_chi - calculates everything you want to know about chi and other dihedrals - in angle vs time files, use radians rather than degrees. - - .BI "\-[no]shift" "no " -- Compute chemical shifts from Phi/Psi angles -+ Compute chemical shifts from phi/psi angles - - .BI "\-binwidth" " int" " 1" - bin width for histograms (degrees) - - .BI "\-core_rotamer" " real" " 0.5 " -- only the central \-core_rotamer*(360/multiplicity) belongs to each rotamer (the rest is assigned to rotamer 0) -+ only the central \fB \-core_rotamer\fR*(360/multiplicity) belongs to each rotamer (the rest is assigned to rotamer 0) - - .BI "\-maxchi" " enum" " 0" -- calculate first ndih Chi dihedrals: \fB 0\fR, \fB 1\fR, \fB 2\fR, \fB 3\fR, \fB 4\fR, \fB 5\fR or \fB 6\fR -+ calculate first ndih chi dihedrals: \fB 0\fR, \fB 1\fR, \fB 2\fR, \fB 3\fR, \fB 4\fR, \fB 5\fR or \fB 6\fR - - .BI "\-[no]normhisto" "yes " - Normalize histograms - - .BI "\-[no]ramomega" "no " -- compute average omega as a function of phi/psi and plot it in an xpm plot -+ compute average omega as a function of phi/psi and plot it in an \fB .xpm\fR plot - - .BI "\-bfact" " real" " \-1 " -- B\-factor value for pdb file for atoms with no calculated dihedral order parameter -+ B\-factor value for \fB .pdb\fR file for atoms with no calculated dihedral order parameter - - .BI "\-[no]chi_prod" "no " - compute a single cumulative rotamer for each residue -@@ -245,7 +246,7 @@ g_chi - calculates everything you want to know about chi and other dihedrals - Include dihedrals to sidechain hydrogens - - .BI "\-bmax" " real" " 0 " -- Maximum B\-factor on any of the atoms that make up a dihedral, for the dihedral angle to be considere in the statistics. Applies to database work where a number of X\-Ray structures is analyzed. \-bmax = 0 means no limit. -+ Maximum B\-factor on any of the atoms that make up a dihedral, for the dihedral angle to be considere in the statistics. Applies to database work where a number of X\-Ray structures is analyzed. \fB \-bmax\fR = 0 means no limit. - - .BI "\-acflen" " int" " \-1" - Length of the ACF, default is half the number of frames -@@ -257,7 +258,7 @@ g_chi - calculates everything you want to know about chi and other dihedrals - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -@@ -271,11 +272,11 @@ g_chi - calculates everything you want to know about chi and other dihedrals - .SH KNOWN PROBLEMS - \- Produces MANY output files (up to about 4 times the number of residues in the protein, twice that if autocorrelation functions are calculated). Typically several hundred files are output. - --\- Phi and psi dihedrals are calculated in a non\-standard way, using H\-N\-CA\-C for phi instead of C(\-)\-N\-CA\-C, and N\-CA\-C\-O for psi instead of N\-CA\-C\-N(+). This causes (usually small) discrepancies with the output of other tools like g_rama. -+\- phi and psi dihedrals are calculated in a non\-standard way, using H\-N\-CA\-C for phi instead of C(\-)\-N\-CA\-C, and N\-CA\-C\-O for psi instead of N\-CA\-C\-N(+). This causes (usually small) discrepancies with the output of other tools like \fB g_rama\fR. - --\- \-r0 option does not work properly -+\- \fB \-r0\fR option does not work properly - --\- Rotamers with multiplicity 2 are printed in chi.log as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0 -+\- Rotamers with multiplicity 2 are printed in \fB chi.log\fR as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0 - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_cluster.1 b/man/man1/g_cluster.1 -index d18de12..774aa6d 100644 ---- a/man/man1/g_cluster.1 -+++ b/man/man1/g_cluster.1 -@@ -1,8 +1,8 @@ --.TH g_cluster 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_cluster 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_cluster - clusters structures - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_cluster\fP - .BI "\-f" " traj.xtc " -@@ -45,10 +45,11 @@ g_cluster - clusters structures - .BI "\-seed" " int " - .BI "\-niter" " int " - .BI "\-kT" " real " -+.BI "\-[no]pbc" "" - .SH DESCRIPTION --\&g_cluster can cluster structures with several different methods. -+\&\fB g_cluster\fR can cluster structures using several different methods. - \&Distances between structures can be determined from a trajectory --\&or read from an XPM matrix file with the \fB \-dm\fR option. -+\&or read from an \fB .xpm\fR matrix file with the \fB \-dm\fR option. - \&RMS deviation after fitting or RMS deviation of atom\-pair distances - \&can be used to define the distance between structures. - -@@ -74,7 +75,7 @@ g_cluster - clusters structures - \&(\fI Angew. Chem. Int. Ed.\fR \fB 1999\fR, \fI 38\fR, pp 236\-240). - \&Count number of neighbors using cut\-off, take structure with - \&largest number of neighbors with all its neighbors as cluster --\&and eleminate it from the pool of clusters. Repeat for remaining -+\&and eliminate it from the pool of clusters. Repeat for remaining - \&structures in pool. - - -@@ -198,7 +199,7 @@ g_cluster - clusters structures - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -237,10 +238,10 @@ g_cluster - clusters structures - Method for cluster determination: \fB linkage\fR, \fB jarvis\-patrick\fR, \fB monte\-carlo\fR, \fB diagonalization\fR or \fB gromos\fR - - .BI "\-minstruct" " int" " 1" -- Minimum number of structures in cluster for coloring in the xpm file -+ Minimum number of structures in cluster for coloring in the \fB .xpm\fR file - - .BI "\-[no]binary" "no " -- Treat the RMSD matrix as consisting of 0 and 1, where the cut\-off is given by \-cutoff -+ Treat the RMSD matrix as consisting of 0 and 1, where the cut\-off is given by \fB \-cutoff\fR - - .BI "\-M" " int" " 10" - Number of nearest neighbors considered for Jarvis\-Patrick algorithm, 0 is use cutoff -@@ -257,6 +258,9 @@ g_cluster - clusters structures - .BI "\-kT" " real" " 0.001 " - Boltzmann weighting factor for Monte Carlo optimization (zero turns off uphill steps) - -+.BI "\-[no]pbc" "yes " -+ PBC check -+ - .SH SEE ALSO - .BR gromacs(7) - -diff --git a/man/man1/g_clustsize.1 b/man/man1/g_clustsize.1 -index 07e2885..ddbfcf4 100644 ---- a/man/man1/g_clustsize.1 -+++ b/man/man1/g_clustsize.1 -@@ -1,8 +1,8 @@ --.TH g_clustsize 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_clustsize 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_clustsize - calculate size distributions of atomic clusters - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_clustsize\fP - .BI "\-f" " traj.xtc " -@@ -35,8 +35,8 @@ g_clustsize - calculate size distributions of atomic clusters - .BI "\-rgbhi" " vector " - .SH DESCRIPTION - \&This program computes the size distributions of molecular/atomic clusters in --\&the gas phase. The output is given in the form of a XPM file. --\&The total number of clusters is written to a XVG file. -+\&the gas phase. The output is given in the form of an \fB .xpm\fR file. -+\&The total number of clusters is written to an \fB .xvg\fR file. - - - \&When the \fB \-mol\fR option is given clusters will be made out of -@@ -46,11 +46,11 @@ g_clustsize - calculate size distributions of atomic clusters - - - \&When velocities are present in your trajectory, the temperature of --\&the largest cluster will be printed in a separate xvg file assuming -+\&the largest cluster will be printed in a separate \fB .xvg\fR file assuming - \&that the particles are free to move. If you are using constraints, - \&please correct the temperature. For instance water simulated with SHAKE - \&or SETTLE will yield a temperature that is 1.5 times too low. You can --\&compensate for this with the \-ndf option. Remember to take the removal -+\&compensate for this with the \fB \-ndf\fR option. Remember to take the removal - \&of center of mass motion into account. - - -@@ -124,7 +124,7 @@ g_clustsize - calculate size distributions of atomic clusters - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -133,7 +133,7 @@ g_clustsize - calculate size distributions of atomic clusters - Largest distance (nm) to be considered in a cluster - - .BI "\-[no]mol" "no " -- Cluster molecules rather than atoms (needs tpr file) -+ Cluster molecules rather than atoms (needs \fB .tpr\fR file) - - .BI "\-[no]pbc" "yes " - Use periodic boundary conditions -@@ -142,7 +142,7 @@ g_clustsize - calculate size distributions of atomic clusters - Number of frames to skip between writing - - .BI "\-nlevels" " int" " 20" -- Number of levels of grey in xpm output -+ Number of levels of grey in \fB .xpm\fR output - - .BI "\-ndf" " int" " \-1" - Number of degrees of freedom of the entire system for temperature calculation. If not set, the number of atoms times three is used. -diff --git a/man/man1/g_confrms.1 b/man/man1/g_confrms.1 -index 4c31798..af439a0 100644 ---- a/man/man1/g_confrms.1 -+++ b/man/man1/g_confrms.1 -@@ -1,8 +1,8 @@ --.TH g_confrms 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_confrms 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_confrms - fits two structures and calculates the rmsd - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_confrms\fP - .BI "\-f1" " conf1.gro " -@@ -23,8 +23,8 @@ g_confrms - fits two structures and calculates the rmsd - .BI "\-[no]label" "" - .BI "\-[no]bfac" "" - .SH DESCRIPTION --\&g_confrms computes the root mean square deviation (RMSD) of two --\&structures after LSQ fitting the second structure on the first one. -+\&\fB g_confrms\fR computes the root mean square deviation (RMSD) of two -+\&structures after least\-squares fitting the second structure on the first one. - \&The two structures do NOT need to have the same number of atoms, - \&only the two index groups used for the fit need to be identical. - \&With \fB \-name\fR only matching atom names from the selected groups -@@ -73,7 +73,7 @@ g_confrms - fits two structures and calculates the rmsd - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-[no]one" "no " - Only write the fitted structure to file -diff --git a/man/man1/g_covar.1 b/man/man1/g_covar.1 -index 39cedbc..4d90b2b 100644 ---- a/man/man1/g_covar.1 -+++ b/man/man1/g_covar.1 -@@ -1,8 +1,8 @@ --.TH g_covar 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_covar 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_covar - calculates and diagonalizes the covariance matrix - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_covar\fP - .BI "\-f" " traj.xtc " -@@ -56,13 +56,22 @@ g_covar - calculates and diagonalizes the covariance matrix - \& - - --\&Option \fB \-xpm\fR writes the whole covariance matrix to an xpm file. -+\&Option \fB \-xpm\fR writes the whole covariance matrix to an \fB .xpm\fR file. - \& - - --\&Option \fB \-xpma\fR writes the atomic covariance matrix to an xpm file, -+\&Option \fB \-xpma\fR writes the atomic covariance matrix to an \fB .xpm\fR file, - \&i.e. for each atom pair the sum of the xx, yy and zz covariances is - \&written. -+\& -+ -+ -+\&Note that the diagonalization of a matrix requires memory and time -+\&that will increase at least as fast as than the square of the number -+\&of atoms involved. It is easy to run out of memory, in which -+\&case this tool will probably exit with a 'Segmentation fault'. You -+\&should consider carefully whether a reduced set of atoms will meet -+\&your needs for lower costs. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -diff --git a/man/man1/g_current.1 b/man/man1/g_current.1 -index 8a02558..a69fc08 100644 ---- a/man/man1/g_current.1 -+++ b/man/man1/g_current.1 -@@ -1,8 +1,8 @@ --.TH g_current 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_current 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_current - calculate current autocorrelation function of system - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_current\fP - .BI "\-s" " topol.tpr " -@@ -32,17 +32,17 @@ g_current - calculate current autocorrelation function of system - .BI "\-tr" " real " - .BI "\-temp" " real " - .SH DESCRIPTION --\&This is a tool for calculating the current autocorrelation function, the correlation -+\&\fB g_current\fR is a tool for calculating the current autocorrelation function, the correlation - \&of the rotational and translational dipole moment of the system, and the resulting static --\&dielectric constant. To obtain a reasonable result the index group has to be neutral. --\&Furthermore the routine is capable of extracting the static conductivity from the current --\&autocorrelation function, if velocities are given. Additionally an Einstein\-Helfand fit also --\&allows to get the static conductivity. -+\&dielectric constant. To obtain a reasonable result, the index group has to be neutral. -+\&Furthermore, the routine is capable of extracting the static conductivity from the current -+\&autocorrelation function, if velocities are given. Additionally, an Einstein\-Helfand fit -+\&can be used to obtain the static conductivity. - - - \&The flag \fB \-caf\fR is for the output of the current autocorrelation function and \fB \-mc\fR writes the - \&correlation of the rotational and translational part of the dipole moment in the corresponding --\&file. However this option is only available for trajectories containing velocities. -+\&file. However, this option is only available for trajectories containing velocities. - \&Options \fB \-sh\fR and \fB \-tr\fR are responsible for the averaging and integration of the - \&autocorrelation functions. Since averaging proceeds by shifting the starting point - \&through the trajectory, the shift can be modified with \fB \-sh\fR to enable the choice of uncorrelated -@@ -64,10 +64,10 @@ g_current - calculate current autocorrelation function of system - - - \&\fB \-[no]nojump\fR unfolds the coordinates to allow free diffusion. This is required to get a continuous --\&translational dipole moment, required for the Einstein\-Helfand fit. The resuls from the fit allow to --\&determine the dielectric constant for system of charged molecules. However it is also possible to extract -+\&translational dipole moment, required for the Einstein\-Helfand fit. The results from the fit allow -+\&the determination of the dielectric constant for system of charged molecules. However, it is also possible to extract - \&the dielectric constant from the fluctuations of the total dipole moment in folded coordinates. But this --\&options has to be used with care, since only very short time spans fulfill the approximation, that the density -+\&option has to be used with care, since only very short time spans fulfill the approximation that the density - \&of the molecules is approximately constant and the averages are already converged. To be on the safe side, - \&the dielectric constant should be calculated with the help of the Einstein\-Helfand method for - \&the translational part of the dielectric constant. -@@ -128,7 +128,7 @@ g_current - calculate current autocorrelation function of system - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -140,7 +140,7 @@ g_current - calculate current autocorrelation function of system - Removes jumps of atoms across the box. - - .BI "\-eps" " real" " 0 " -- Dielectric constant of the surrounding medium. eps=0.0 corresponds to eps=infinity (thinfoil boundary conditions). -+ Dielectric constant of the surrounding medium. eps=0.0 corresponds to eps=infinity (tin\-foil boundary conditions). - - .BI "\-bfit" " real" " 100 " - Begin of the fit of the straight line to the MSD of the translational fraction of the dipole moment. -diff --git a/man/man1/g_density.1 b/man/man1/g_density.1 -index e4334a3..ec2ac27 100644 ---- a/man/man1/g_density.1 -+++ b/man/man1/g_density.1 -@@ -1,8 +1,8 @@ --.TH g_density 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_density 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_density - calculates the density of the system - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_density\fP - .BI "\-f" " traj.xtc " -@@ -25,17 +25,23 @@ g_density - calculates the density of the system - .BI "\-[no]symm" "" - .BI "\-[no]center" "" - .SH DESCRIPTION --\&Compute partial densities across the box, using an index file. Densities --\&in kg/m3, number densities or electron densities can be -+\&Compute partial densities across the box, using an index file. -+ -+ -+\&For the total density of NPT simulations, use \fB g_energy\fR instead. -+\& -+ -+ -+\&Densities are in kg/m3, and number densities or electron densities can also be - \&calculated. For electron densities, a file describing the number of - \&electrons for each type of atom should be provided using \fB \-ei\fR. - \&It should look like: - --\& 2 -+\& \fB 2\fR - --\& atomname = nrelectrons -+\& \fB atomname = nrelectrons\fR - --\& atomname = nrelectrons -+\& \fB atomname = nrelectrons\fR - - \&The first line contains the number of lines to read from the file. - \&There should be one line for each unique atom name in your system. -@@ -82,7 +88,7 @@ g_density - calculates the density of the system - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_densmap.1 b/man/man1/g_densmap.1 -index 7683711..d2ba3ea 100644 ---- a/man/man1/g_densmap.1 -+++ b/man/man1/g_densmap.1 -@@ -1,8 +1,8 @@ --.TH g_densmap 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_densmap 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_densmap - calculates 2D planar or axial-radial density maps - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_densmap\fP - .BI "\-f" " traj.xtc " -@@ -31,11 +31,11 @@ g_densmap - calculates 2D planar or axial-radial density maps - .BI "\-dmin" " real " - .BI "\-dmax" " real " - .SH DESCRIPTION --\&g_densmap computes 2D number\-density maps. -+\&\fB g_densmap\fR computes 2D number\-density maps. - \&It can make planar and axial\-radial density maps. - \&The output \fB .xpm\fR file can be visualized with for instance xv --\&and can be converted to postscript with xpm2ps. --\&Optionally, output can be in text form to a .dat file. -+\&and can be converted to postscript with \fB xpm2ps\fR. -+\&Optionally, output can be in text form to a \fB .dat\fR file with \fB \-od\fR, instead of the usual \fB .xpm\fR file with \fB \-o\fR. - \& - - -@@ -110,7 +110,7 @@ g_densmap - calculates 2D planar or axial-radial density maps - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-bin" " real" " 0.02 " - Grid size (nm) -diff --git a/man/man1/g_densorder.1 b/man/man1/g_densorder.1 -new file mode 100644 -index 0000000..af70bc4 ---- /dev/null -+++ b/man/man1/g_densorder.1 -@@ -0,0 +1,123 @@ -+.TH g_densorder 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" -+.SH NAME -+g_densorder - calculate surface fluctuations -+ -+.B VERSION 4.5.4-dev-20110404-bc5695c -+.SH SYNOPSIS -+\f3g_densorder\fP -+.BI "\-s" " topol.tpr " -+.BI "\-f" " traj.xtc " -+.BI "\-n" " index.ndx " -+.BI "\-o" " Density4D.dat " -+.BI "\-or" " hello.out " -+.BI "\-og" " interface.xpm " -+.BI "\-Spect" " intfspect.out " -+.BI "\-[no]h" "" -+.BI "\-[no]version" "" -+.BI "\-nice" " int " -+.BI "\-b" " time " -+.BI "\-e" " time " -+.BI "\-dt" " time " -+.BI "\-[no]w" "" -+.BI "\-[no]1d" "" -+.BI "\-bw" " real " -+.BI "\-bwn" " real " -+.BI "\-order" " int " -+.BI "\-axis" " string " -+.BI "\-method" " enum " -+.BI "\-d1" " real " -+.BI "\-d2" " real " -+.BI "\-tblock" " int " -+.BI "\-nlevel" " int " -+.SH DESCRIPTION -+\&A small program to reduce a two\-phase density distribution -+\&along an axis, computed over a MD trajectory -+\&to 2D surfaces fluctuating in time, by a fit to -+\&a functional profile for interfacial densities -+\&A time\-averaged spatial representation of the -+\&interfaces can be output with the option \-tavg -+.SH FILES -+.BI "\-s" " topol.tpr" -+.B Input -+ Run input file: tpr tpb tpa -+ -+.BI "\-f" " traj.xtc" -+.B Input -+ Trajectory: xtc trr trj gro g96 pdb cpt -+ -+.BI "\-n" " index.ndx" -+.B Input -+ Index file -+ -+.BI "\-o" " Density4D.dat" -+.B Output, Opt. -+ Generic data file -+ -+.BI "\-or" " hello.out" -+.B Output, Opt., Mult. -+ Generic output file -+ -+.BI "\-og" " interface.xpm" -+.B Output, Opt., Mult. -+ X PixMap compatible matrix file -+ -+.BI "\-Spect" " intfspect.out" -+.B Output, Opt., Mult. -+ Generic output file -+ -+.SH OTHER OPTIONS -+.BI "\-[no]h" "no " -+ Print help info and quit -+ -+.BI "\-[no]version" "no " -+ Print version info and quit -+ -+.BI "\-nice" " int" " 0" -+ Set the nicelevel -+ -+.BI "\-b" " time" " 0 " -+ First frame (ps) to read from trajectory -+ -+.BI "\-e" " time" " 0 " -+ Last frame (ps) to read from trajectory -+ -+.BI "\-dt" " time" " 0 " -+ Only use frame when t MOD dt = first time (ps) -+ -+.BI "\-[no]w" "no " -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files -+ -+.BI "\-[no]1d" "no " -+ Pseudo\-1d interface geometry -+ -+.BI "\-bw" " real" " 0.2 " -+ Binwidth of density distribution tangential to interface -+ -+.BI "\-bwn" " real" " 0.05 " -+ Binwidth of density distribution normal to interface -+ -+.BI "\-order" " int" " 0" -+ Order of Gaussian filter, order 0 equates to NO filtering -+ -+.BI "\-axis" " string" " Z" -+ Axis Direction \- X, Y or Z -+ -+.BI "\-method" " enum" " bisect" -+ Interface location method: \fB bisect\fR or \fB functional\fR -+ -+.BI "\-d1" " real" " 0 " -+ Bulk density phase 1 (at small z) -+ -+.BI "\-d2" " real" " 1000 " -+ Bulk density phase 2 (at large z) -+ -+.BI "\-tblock" " int" " 100" -+ Number of frames in one time\-block average -+ -+.BI "\-nlevel" " int" " 100" -+ Number of Height levels in 2D \- XPixMaps -+ -+.SH SEE ALSO -+.BR gromacs(7) -+ -+More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. -diff --git a/man/man1/g_dielectric.1 b/man/man1/g_dielectric.1 -index a10fee1..b14a35c 100644 ---- a/man/man1/g_dielectric.1 -+++ b/man/man1/g_dielectric.1 -@@ -1,8 +1,8 @@ --.TH g_dielectric 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_dielectric 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_dielectric - calculates frequency dependent dielectric constants - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_dielectric\fP - .BI "\-f" " dipcorr.xvg " -@@ -32,19 +32,22 @@ g_dielectric - calculates frequency dependent dielectric constants - .BI "\-ffn" " enum " - .BI "\-nsmooth" " int " - .SH DESCRIPTION --\&dielectric calculates frequency dependent dielectric constants -+\&\fB g_dielectric\fR calculates frequency dependent dielectric constants - \&from the autocorrelation function of the total dipole moment in --\&your simulation. This ACF can be generated by g_dipoles. -+\&your simulation. This ACF can be generated by \fB g_dipoles\fR. - \&For an estimate of the error you can run g_statistics on the - \&ACF, and use the output thus generated for this program. - \&The functional forms of the available functions are: - - --\&One parameter : y = Exp[\-a1 x], --\&Two parameters : y = a2 Exp[\-a1 x], -+\&One parameter: y = Exp[\-a1 x], -+ -+\&Two parameters: y = a2 Exp[\-a1 x], -+ - \&Three parameters: y = a2 Exp[\-a1 x] + (1 \- a2) Exp[\-a3 x]. -+ - \&Start values for the fit procedure can be given on the command line. --\&It is also possible to fix parameters at their start value, use \-fix -+\&It is also possible to fix parameters at their start value, use \fB \-fix\fR - \&with the number of the parameter you want to fix. - \& - -@@ -95,7 +98,7 @@ g_dielectric - calculates frequency dependent dielectric constants - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -104,10 +107,10 @@ g_dielectric - calculates frequency dependent dielectric constants - use fast fourier transform for correlation function - - .BI "\-[no]x1" "yes " -- use first column as X axis rather than first data set -+ use first column as \fI x\fR\-axis rather than first data set - - .BI "\-eint" " real" " 5 " -- Time were to end the integration of the data and start to use the fit -+ Time to end the integration of the data and start to use the fit - - .BI "\-bfit" " real" " 5 " - Begin time of fit -@@ -128,16 +131,16 @@ g_dielectric - calculates frequency dependent dielectric constants - Start value for fit parameter tau2 - - .BI "\-eps0" " real" " 80 " -- Epsilon 0 of your liquid -+ epsilon0 of your liquid - - .BI "\-epsRF" " real" " 78.5 " -- Epsilon of the reaction field used in your simulation. A value of 0 means infinity. -+ epsilon of the reaction field used in your simulation. A value of 0 means infinity. - - .BI "\-fix" " int" " 0" - Fix parameters at their start values, A (2), tau1 (1), or tau2 (4) - - .BI "\-ffn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-nsmooth" " int" " 3" - Number of points for smoothing -diff --git a/man/man1/g_dih.1 b/man/man1/g_dih.1 -index aa6624a..7ab738a 100644 ---- a/man/man1/g_dih.1 -+++ b/man/man1/g_dih.1 -@@ -1,8 +1,8 @@ --.TH g_dih 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_dih 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_dih - analyzes dihedral transitions - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_dih\fP - .BI "\-f" " traj.xtc " -@@ -18,7 +18,7 @@ g_dih - analyzes dihedral transitions - .BI "\-[no]sa" "" - .BI "\-mult" " int " - .SH DESCRIPTION --\&g_dih can do two things. The default is to analyze dihedral transitions -+\&\fB g_dih\fR can do two things. The default is to analyze dihedral transitions - \&by merely computing all the dihedral angles defined in your topology - \&for the whole trajectory. When a dihedral flips over to another minimum - \&an angle/time plot is made. -@@ -61,7 +61,7 @@ g_dih - analyzes dihedral transitions - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-[no]sa" "no " - Perform cluster analysis in dihedral space instead of analysing dihedral transitions. -diff --git a/man/man1/g_dipoles.1 b/man/man1/g_dipoles.1 -index ea960c9..3e0721f 100644 ---- a/man/man1/g_dipoles.1 -+++ b/man/man1/g_dipoles.1 -@@ -1,8 +1,8 @@ --.TH g_dipoles 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_dipoles 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_dipoles - computes the total dipole plus fluctuations - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_dipoles\fP - .BI "\-en" " ener.edr " -@@ -53,24 +53,24 @@ g_dipoles - computes the total dipole plus fluctuations - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_dipoles computes the total dipole plus fluctuations of a simulation -+\&\fB g_dipoles\fR computes the total dipole plus fluctuations of a simulation - \&system. From this you can compute e.g. the dielectric constant for --\&low dielectric media. -+\&low\-dielectric media. - \&For molecules with a net charge, the net charge is subtracted at - \¢er of mass of the molecule. - - --\&The file Mtot.xvg contains the total dipole moment of a frame, the -+\&The file \fB Mtot.xvg\fR contains the total dipole moment of a frame, the - \&components as well as the norm of the vector. --\&The file aver.xvg contains |Mu|2 and | Mu |2 during the -+\&The file \fB aver.xvg\fR contains |Mu|2 and | Mu |2 during the - \&simulation. --\&The file dipdist.xvg contains the distribution of dipole moments during -+\&The file \fB dipdist.xvg\fR contains the distribution of dipole moments during - \&the simulation --\&The mu_max is used as the highest value in the distribution graph. -+\&The value of \fB \-mumax\fR is used as the highest value in the distribution graph. - - --\&Furthermore the dipole autocorrelation function will be computed when --\&option \-corr is used. The output file name is given with the \fB \-c\fR -+\&Furthermore, the dipole autocorrelation function will be computed when -+\&option \fB \-corr\fR is used. The output file name is given with the \fB \-c\fR - \&option. - \&The correlation functions can be averaged over all molecules - \&(\fB mol\fR), plotted per molecule separately (\fB molsep\fR) -@@ -81,7 +81,7 @@ g_dipoles - computes the total dipole plus fluctuations - \&Option \fB \-g\fR produces a plot of the distance dependent Kirkwood - \&G\-factor, as well as the average cosine of the angle between the dipoles - \&as a function of the distance. The plot also includes gOO and hOO --\&according to Nymand & Linse, JCP 112 (2000) pp 6386\-6395. In the same plot -+\&according to Nymand & Linse, J. Chem. Phys. 112 (2000) pp 6386\-6395. In the same plot, - \&we also include the energy per scale computed by taking the inner product of - \&the dipoles divided by the distance to the third power. - -@@ -92,13 +92,13 @@ g_dipoles - computes the total dipole plus fluctuations - \&EXAMPLES - - --\&g_dipoles \-corr mol \-P1 \-o dip_sqr \-mu 2.273 \-mumax 5.0 \-nofft -+\&\fB g_dipoles \-corr mol \-P1 \-o dip_sqr \-mu 2.273 \-mumax 5.0 \-nofft\fR - - - \&This will calculate the autocorrelation function of the molecular - \&dipoles using a first order Legendre polynomial of the angle of the - \&dipole vector and itself a time t later. For this calculation 1001 --\&frames will be used. Further the dielectric constant will be calculated -+\&frames will be used. Further, the dielectric constant will be calculated - \&using an epsilonRF of infinity (default), temperature of 300 K (default) and - \&an average dipole moment of the molecule of 2.273 (SPC). For the - \&distribution function a maximum of 5.0 will be used. -@@ -187,7 +187,7 @@ g_dipoles - computes the total dipole plus fluctuations - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -214,7 +214,7 @@ g_dipoles - computes the total dipole plus fluctuations - Calculate |cos theta| between all pairs of molecules. May be slow - - .BI "\-ncos" " int" " 1" -- Must be 1 or 2. Determines whether the cos is computed between all mole cules in one group, or between molecules in two different groups. This turns on the \-gkr flag. -+ Must be 1 or 2. Determines whether the cos is computed between all molecules in one group, or between molecules in two different groups. This turns on the \fB \-gkr\fR flag. - - .BI "\-axis" " string" " Z" - Take the normal on the computational box in direction X, Y or Z. -@@ -229,16 +229,16 @@ g_dipoles - computes the total dipole plus fluctuations - Same as previous option in case ncos = 2, i.e. dipole interaction between two groups of molecules - - .BI "\-rcmax" " real" " 0 " -- Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterium based on the box length will be used. -+ Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterion based on the box length will be used. - - .BI "\-[no]phi" "no " -- Plot the 'torsion angle' defined as the rotation of the two dipole vectors around the distance vector between the two molecules in the xpm file from the \-cmap option. By default the cosine of the angle between the dipoles is plotted. -+ Plot the 'torsion angle' defined as the rotation of the two dipole vectors around the distance vector between the two molecules in the \fB .xpm\fR file from the \fB \-cmap\fR option. By default the cosine of the angle between the dipoles is plotted. - - .BI "\-nlevels" " int" " 20" - Number of colors in the cmap output - - .BI "\-ndegrees" " int" " 90" -- Number of divisions on the y\-axis in the camp output (for 180 degrees) -+ Number of divisions on the \fI y\fR\-axis in the cmap output (for 180 degrees) - - .BI "\-acflen" " int" " \-1" - Length of the ACF, default is half the number of frames -@@ -250,7 +250,7 @@ g_dipoles - computes the total dipole plus fluctuations - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_disre.1 b/man/man1/g_disre.1 -index 820456e..c384783 100644 ---- a/man/man1/g_disre.1 -+++ b/man/man1/g_disre.1 -@@ -1,8 +1,8 @@ --.TH g_disre 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_disre 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_disre - analyzes distance restraints - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_disre\fP - .BI "\-s" " topol.tpr " -@@ -30,9 +30,9 @@ g_disre - analyzes distance restraints - .BI "\-nlevels" " int " - .BI "\-[no]third" "" - .SH DESCRIPTION --\&g_disre computes violations of distance restraints. --\&If necessary all protons can be added to a protein molecule --\&using the protonate program. -+\&\fB g_disre\fR computes violations of distance restraints. -+\&If necessary, all protons can be added to a protein molecule -+\&using the \fB g_protonate\fR program. - - - \&The program always -@@ -46,7 +46,7 @@ g_disre - analyzes distance restraints - \&printing. - - --\&When the optional\fB \-q\fR flag is given a pdb file coloured by the -+\&When the optional \fB \-q\fR flag is given a \fB .pdb\fR file coloured by the - \&amount of average violations. - - -@@ -124,7 +124,7 @@ g_disre - analyzes distance restraints - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_dist.1 b/man/man1/g_dist.1 -index f39ad40..eb14147 100644 ---- a/man/man1/g_dist.1 -+++ b/man/man1/g_dist.1 -@@ -1,8 +1,8 @@ --.TH g_dist 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_dist 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_dist - calculates the distances between the centers of mass of two groups - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_dist\fP - .BI "\-f" " traj.xtc " -@@ -19,9 +19,9 @@ g_dist - calculates the distances between the centers of mass of two groups - .BI "\-xvg" " enum " - .BI "\-dist" " real " - .SH DESCRIPTION --\&g_dist can calculate the distance between the centers of mass of two -+\&\fB g_dist\fR can calculate the distance between the centers of mass of two - \&groups of atoms as a function of time. The total distance and its --\&x, y and z components are plotted. -+\&\fI x\fR\-, \fI y\fR\-, and \fI z\fR\-components are plotted. - - - \&Or when \fB \-dist\fR is set, print all the atoms in group 2 that are -diff --git a/man/man1/g_dyndom.1 b/man/man1/g_dyndom.1 -index 1b0668c..e66b5b2 100644 ---- a/man/man1/g_dyndom.1 -+++ b/man/man1/g_dyndom.1 -@@ -1,8 +1,8 @@ --.TH g_dyndom 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_dyndom 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_dyndom - interpolate and extrapolate structure rotations - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_dyndom\fP - .BI "\-f" " dyndom.pdb " -@@ -19,11 +19,11 @@ g_dyndom - interpolate and extrapolate structure rotations - .BI "\-head" " vector " - .BI "\-tail" " vector " - .SH DESCRIPTION --\&g_dyndom reads a pdb file output from DynDom --\&http://www.cmp.uea.ac.uk/dyndom/ --\&It reads the coordinates, and the coordinates of the rotation axis --\&furthermore it reads an index file containing the domains. --\&Furthermore it takes the first and last atom of the arrow file -+\&\fB g_dyndom\fR reads a \fB .pdb\fR file output from DynDom -+\&(http://www.cmp.uea.ac.uk/dyndom/). -+\&It reads the coordinates, the coordinates of the rotation axis, -+\&and an index file containing the domains. -+\&Furthermore, it takes the first and last atom of the arrow file - \&as command line arguments (head and tail) and - \&finally it takes the translation vector (given in DynDom info file) - \&and the angle of rotation (also as command line arguments). If the angle -@@ -75,7 +75,7 @@ g_dyndom - interpolate and extrapolate structure rotations - DymDom dtermined angle of rotation about rotation vector - - .BI "\-trans" " real" " 0 " -- Translation (Aangstroem) along rotation vector (see DynDom info file) -+ Translation (Angstrom) along rotation vector (see DynDom info file) - - .BI "\-head" " vector" " 0 0 0" - First atom of the arrow vector -diff --git a/man/man1/g_enemat.1 b/man/man1/g_enemat.1 -index 2d03501..0243604 100644 ---- a/man/man1/g_enemat.1 -+++ b/man/man1/g_enemat.1 -@@ -1,8 +1,8 @@ --.TH g_enemat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_enemat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_enemat - extracts an energy matrix from an energy file - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_enemat\fP - .BI "\-f" " ener.edr " -@@ -35,12 +35,12 @@ g_enemat - extracts an energy matrix from an energy file - .BI "\-[no]free" "" - .BI "\-temp" " real " - .SH DESCRIPTION --\&g_enemat extracts an energy matrix from the energy file (\fB \-f\fR). -+\&\fB g_enemat\fR extracts an energy matrix from the energy file (\fB \-f\fR). - \&With \fB \-groups\fR a file must be supplied with on each - \&line a group of atoms to be used. For these groups matrix of - \&interaction energies will be extracted from the energy file - \&by looking for energy groups with names corresponding to pairs --\&of groups of atoms. E.g. if your \fB \-groups\fR file contains: -+\&of groups of atoms, e.g. if your \fB \-groups\fR file contains: - - \&\fB 2\fR - -@@ -110,7 +110,7 @@ g_enemat - extracts an energy matrix from an energy file - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -122,7 +122,7 @@ g_enemat - extracts an energy matrix from an energy file - Skip number of frames between data points - - .BI "\-[no]mean" "yes " -- with \-groups extracts matrix of mean energies instead of matrix for each timestep -+ with \fB \-groups\fR extracts matrix of mean energies instead of matrix for each timestep - - .BI "\-nlevels" " int" " 20" - number of levels for matrix colors -diff --git a/man/man1/g_energy.1 b/man/man1/g_energy.1 -index dcec1de..3d05b1b 100644 ---- a/man/man1/g_energy.1 -+++ b/man/man1/g_energy.1 -@@ -1,8 +1,8 @@ --.TH g_energy 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_energy 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_energy - writes energies to xvg files and displays averages - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_energy\fP - .BI "\-f" " ener.edr " -@@ -20,6 +20,7 @@ g_energy - writes energies to xvg files and displays averages - .BI "\-corr" " enecorr.xvg " - .BI "\-vis" " visco.xvg " - .BI "\-ravg" " runavgdf.xvg " -+.BI "\-odh" " dhdl.xvg " - .BI "\-[no]h" "" - .BI "\-[no]version" "" - .BI "\-nice" " int " -@@ -38,7 +39,6 @@ g_energy - writes energies to xvg files and displays averages - .BI "\-skip" " int " - .BI "\-[no]aver" "" - .BI "\-nmol" " int " --.BI "\-nconstr" " int " - .BI "\-[no]fluc" "" - .BI "\-[no]orinst" "" - .BI "\-[no]ovec" "" -@@ -50,56 +50,28 @@ g_energy - writes energies to xvg files and displays averages - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_energy extracts energy components or distance restraint -+\&\fB g_energy\fR extracts energy components or distance restraint - \&data from an energy file. The user is prompted to interactively --\&select the energy terms she wants. -+\&select the desired energy terms. - - --\&Average, RMSD and drift are calculated with full precision from the -+\&Average, RMSD, and drift are calculated with full precision from the - \&simulation (see printed manual). Drift is calculated by performing --\&a LSQ fit of the data to a straight line. The reported total drift -+\&a least\-squares fit of the data to a straight line. The reported total drift - \&is the difference of the fit at the first and last point. - \&An error estimate of the average is given based on a block averages --\&over 5 blocks using the full precision averages. The error estimate -+\&over 5 blocks using the full\-precision averages. The error estimate - \&can be performed over multiple block lengths with the options - \&\fB \-nbmin\fR and \fB \-nbmax\fR. --\&Note that in most cases the energy files contains averages over all -+\&\fB Note\fR that in most cases the energy files contains averages over all - \&MD steps, or over many more points than the number of frames in --\&energy file. This makes the g_energy statistics output more accurate --\&than the xvg output. When exact averages are not present in the energy --\&file the statistics mentioned above is simply over the single, per\-frame -+\&energy file. This makes the \fB g_energy\fR statistics output more accurate -+\&than the \fB .xvg\fR output. When exact averages are not present in the energy -+\&file, the statistics mentioned above are simply over the single, per\-frame - \&energy values. - - --\&The term fluctuation gives the RMSD around the LSQ fit. -- -- --\&Some fluctuation\-dependent properties can be calculated provided --\&the correct energy terms are selected. The following properties --\&will be computed: -- --\&Property Energy terms needed -- --\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- -- --\&Heat capacity Cp (NPT sims): Enthalpy, Temp -- --\&Heat capacity Cv (NVT sims): Etot, Temp -- --\&Thermal expansion coeff. (NPT): Enthalpy, Vol, Temp -- --\&Isothermal compressibility: Vol, Temp -- --\&Adiabatic bulk modulus: Vol, Temp -- --\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- -- --\&You always need to set the number of molecules \fB \-nmol\fR, and, --\&if you used constraints in your simulations you will need to give --\&the number of constraints per molecule \fB \-nconstr\fR in order to --\&correct for this: (nconstr/2) kB is subtracted from the heat --\&capacity in this case. For instance in the case of rigid water --\&you need to give the value 3 to this option. -+\&The term fluctuation gives the RMSD around the least\-squares fit. - - - \&When the \fB \-viol\fR option is set, the time averaged -@@ -129,6 +101,11 @@ g_energy - writes energies to xvg files and displays averages - \&\fB \-ovec\fR also the eigenvectors are plotted. - - -+\&Option \fB \-odh\fR extracts and plots the free energy data -+\&(Hamiltoian differences and/or the Hamiltonian derivative dhdl) -+\&from the \fB ener.edr\fR file. -+ -+ - \&With \fB \-fee\fR an estimate is calculated for the free\-energy - \&difference with an ideal gas state: - -@@ -152,8 +129,9 @@ g_energy - writes energies to xvg files and displays averages - \&When a second energy file is specified (\fB \-f2\fR), a free energy - \&difference is calculated dF = \-kT ln e \-(EB\-EA)/kT A , - \&where EA and EB are the energies from the first and second energy --\&files, and the average is over the ensemble A. \fB NOTE\fR that --\&the energies must both be calculated from the same trajectory. -+\&files, and the average is over the ensemble A. The running average -+\&of the free energy difference is printed to a file specified by \fB \-ravg\fR. -+\&\fB Note\fR that the energies must both be calculated from the same trajectory. - .SH FILES - .BI "\-f" " ener.edr" - .B Input -@@ -215,6 +193,10 @@ g_energy - writes energies to xvg files and displays averages - .B Output, Opt. - xvgr/xmgr file - -+.BI "\-odh" " dhdl.xvg" -+.B Output, Opt. -+ xvgr/xmgr file -+ - .SH OTHER OPTIONS - .BI "\-[no]h" "no " - Print help info and quit -@@ -232,7 +214,7 @@ g_energy - writes energies to xvg files and displays averages - Last frame (ps) to read from trajectory - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -270,9 +252,6 @@ g_energy - writes energies to xvg files and displays averages - .BI "\-nmol" " int" " 1" - Number of molecules in your sample: the energies are divided by this number - --.BI "\-nconstr" " int" " 0" -- Number of constraints per molecule. Necessary for calculating the heat capacity -- - .BI "\-[no]fluc" "no " - Calculate autocorrelation of energy fluctuations rather than energy itself - -@@ -280,7 +259,7 @@ g_energy - writes energies to xvg files and displays averages - Analyse instantaneous orientation data - - .BI "\-[no]ovec" "no " -- Also plot the eigenvectors with \-oten -+ Also plot the eigenvectors with \fB \-oten\fR - - .BI "\-acflen" " int" " \-1" - Length of the ACF, default is half the number of frames -@@ -292,7 +271,7 @@ g_energy - writes energies to xvg files and displays averages - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_filter.1 b/man/man1/g_filter.1 -index 02ebe01..1945b9f 100644 ---- a/man/man1/g_filter.1 -+++ b/man/man1/g_filter.1 -@@ -1,8 +1,8 @@ --.TH g_filter 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_filter 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_filter - frequency filters trajectories, useful for making smooth movies - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_filter\fP - .BI "\-f" " traj.xtc " -@@ -22,7 +22,7 @@ g_filter - frequency filters trajectories, useful for making smooth movies - .BI "\-[no]nojump" "" - .BI "\-[no]fit" "" - .SH DESCRIPTION --\&g_filter performs frequency filtering on a trajectory. -+\&\fB g_filter\fR performs frequency filtering on a trajectory. - \&The filter shape is cos(pi t/A) + 1 from \-A to +A, where A is given - \&by the option \fB \-nf\fR times the time step in the input trajectory. - \&This filter reduces fluctuations with period A by 85%, with period -@@ -31,7 +31,7 @@ g_filter - frequency filters trajectories, useful for making smooth movies - - - \&Option \fB \-ol\fR writes a low\-pass filtered trajectory. --\&A frame is written every \fB nf\fR input frames. -+\&A frame is written every \fB \-nf\fR input frames. - \&This ratio of filter length and output interval ensures a good - \&suppression of aliasing of high\-frequency motion, which is useful for - \&making smooth movies. Also averages of properties which are linear -@@ -43,7 +43,7 @@ g_filter - frequency filters trajectories, useful for making smooth movies - \&Option \fB \-oh\fR writes a high\-pass filtered trajectory. - \&The high\-pass filtered coordinates are added to the coordinates - \&from the structure file. When using high\-pass filtering use \fB \-fit\fR --\&or make sure you use a trajectory which has been fitted on -+\&or make sure you use a trajectory that has been fitted on - \&the coordinates in the structure file. - .SH FILES - .BI "\-f" " traj.xtc" -@@ -86,7 +86,7 @@ g_filter - frequency filters trajectories, useful for making smooth movies - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-nf" " int" " 10" - Sets the filter length as well as the output interval for low\-pass filtering -diff --git a/man/man1/g_gyrate.1 b/man/man1/g_gyrate.1 -index 20dbf17..bc10125 100644 ---- a/man/man1/g_gyrate.1 -+++ b/man/man1/g_gyrate.1 -@@ -1,8 +1,8 @@ --.TH g_gyrate 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_gyrate 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_gyrate - calculates the radius of gyration - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_gyrate\fP - .BI "\-f" " traj.xtc " -@@ -31,8 +31,8 @@ g_gyrate - calculates the radius of gyration - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_gyrate computes the radius of gyration of a group of atoms --\&and the radii of gyration about the x, y and z axes, -+\&\fB g_gyrate\fR computes the radius of gyration of a group of atoms -+\&and the radii of gyration about the \fI x\fR\-, \fI y\fR\- and \fI z\fR\-axes, - \&as a function of time. The atoms are explicitly mass weighted. - - -@@ -41,8 +41,8 @@ g_gyrate - calculates the radius of gyration - \&sized parts. - - --\&With the option \fB \-nz\fR 2D radii of gyration in the x\-y plane --\&of slices along the z\-axis are calculated. -+\&With the option \fB \-nz\fR 2D radii of gyration in the \fI x\-y\fR plane -+\&of slices along the \fI z\fR\-axis are calculated. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -@@ -84,7 +84,7 @@ g_gyrate - calculates the radius of gyration - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -114,7 +114,7 @@ g_gyrate - calculates the radius of gyration - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_h2order.1 b/man/man1/g_h2order.1 -index 2349dae..e3f2820 100644 ---- a/man/man1/g_h2order.1 -+++ b/man/man1/g_h2order.1 -@@ -1,8 +1,8 @@ --.TH g_h2order 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_h2order 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_h2order - computes the orientation of water molecules - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_h2order\fP - .BI "\-f" " traj.xtc " -@@ -21,12 +21,12 @@ g_h2order - computes the orientation of water molecules - .BI "\-d" " string " - .BI "\-sl" " int " - .SH DESCRIPTION --\&Compute the orientation of water molecules with respect to the normal -+\&\fB g_h2order\fR computes the orientation of water molecules with respect to the normal - \&of the box. The program determines the average cosine of the angle --\&between de dipole moment of water and an axis of the box. The box is -+\&between the dipole moment of water and an axis of the box. The box is - \÷d in slices and the average orientation per slice is printed. - \&Each water molecule is assigned to a slice, per time frame, based on the --\&position of the oxygen. When \-nm is used the angle between the water -+\&position of the oxygen. When \fB \-nm\fR is used, the angle between the water - \&dipole and the axis from the center of mass to the oxygen is calculated - \&instead of the angle between the dipole and a box axis. - .SH FILES -@@ -70,7 +70,7 @@ g_h2order - computes the orientation of water molecules - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -82,7 +82,7 @@ g_h2order - computes the orientation of water molecules - Calculate order parameter as function of boxlength, dividing the box in nr slices. - - .SH KNOWN PROBLEMS --\- The program assigns whole water molecules to a slice, based on the firstatom of three in the index file group. It assumes an order O,H,H.Name is not important, but the order is. If this demand is not met,assigning molecules to slices is different. -+\- The program assigns whole water molecules to a slice, based on the first atom of three in the index file group. It assumes an order O,H,H. Name is not important, but the order is. If this demand is not met, assigning molecules to slices is different. - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_hbond.1 b/man/man1/g_hbond.1 -index 049b54d..9d2e3eb 100644 ---- a/man/man1/g_hbond.1 -+++ b/man/man1/g_hbond.1 -@@ -1,8 +1,8 @@ --.TH g_hbond 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_hbond 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_hbond - computes and analyzes hydrogen bonds - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_hbond\fP - .BI "\-f" " traj.xtc " -@@ -26,6 +26,7 @@ g_hbond - computes and analyzes hydrogen bonds - .BI "\-b" " time " - .BI "\-e" " time " - .BI "\-dt" " time " -+.BI "\-tu" " enum " - .BI "\-xvg" " enum " - .BI "\-a" " real " - .BI "\-r" " real " -@@ -53,7 +54,7 @@ g_hbond - computes and analyzes hydrogen bonds - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_hbond computes and analyzes hydrogen bonds. Hydrogen bonds are -+\&\fB g_hbond\fR computes and analyzes hydrogen bonds. Hydrogen bonds are - \&determined based on cutoffs for the angle Acceptor \- Donor \- Hydrogen - \&(zero is extended) and the distance Hydrogen \- Acceptor. - \&OH and NH groups are regarded as donors, O is an acceptor always, -@@ -67,7 +68,7 @@ g_hbond - computes and analyzes hydrogen bonds - \&groups are analyzed. - - --\&If you set \-shell, you will be asked for an additional index group -+\&If you set \fB \-shell\fR, you will be asked for an additional index group - \&which should contain exactly one atom. In this case, only hydrogen - \&bonds between atoms within the shell distance from the one atom are - \&considered. -@@ -205,6 +206,9 @@ g_hbond - computes and analyzes hydrogen bonds - .BI "\-dt" " time" " 0 " - Only use frame when t MOD dt = first time (ps) - -+.BI "\-tu" " enum" " ps" -+ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR -+ - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR - -@@ -218,7 +222,7 @@ g_hbond - computes and analyzes hydrogen bonds - Use distance Donor\-Acceptor (if TRUE) or Hydrogen\-Acceptor (FALSE) - - .BI "\-r2" " real" " 0 " -- Second cutoff radius. Mainly useful with \-contact and \-ac -+ Second cutoff radius. Mainly useful with \fB \-contact\fR and \fB \-ac\fR - - .BI "\-abin" " real" " 1 " - Binwidth angle distribution (degrees) -@@ -236,10 +240,10 @@ g_hbond - computes and analyzes hydrogen bonds - when 0, only calculate hydrogen bonds within nm shell around one particle - - .BI "\-fitstart" " real" " 1 " -- Time (ps) from which to start fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. With \-gemfit we suggest \-fitstart 0 -+ Time (ps) from which to start fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. With \fB \-gemfit\fR we suggest \fB \-fitstart 0\fR - - .BI "\-fitstart" " real" " 1 " -- Time (ps) to which to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation (only with \-gemfit) -+ Time (ps) to which to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation (only with \fB \-gemfit\fR) - - .BI "\-temp" " real" " 298.15" - Temperature (K) for computing the Gibbs energy corresponding to HB breaking and reforming -@@ -248,7 +252,7 @@ g_hbond - computes and analyzes hydrogen bonds - If = 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(\-x/tau) - - .BI "\-dump" " int" " 0" -- Dump the first N hydrogen bond ACFs in a single xvg file for debugging -+ Dump the first N hydrogen bond ACFs in a single \fB .xvg\fR file for debugging - - .BI "\-max_hb" " real" " 0 " - Theoretical maximum number of hydrogen bonds used for normalizing HB autocorrelation function. Can be useful in case the program estimates it wrongly -@@ -260,7 +264,7 @@ g_hbond - computes and analyzes hydrogen bonds - Use reversible geminate recombination for the kinetics/thermodynamics calclations. See Markovitch et al., J. Chem. Phys 129, 084505 (2008) for details.: \fB none\fR, \fB dd\fR, \fB ad\fR, \fB aa\fR or \fB a4\fR - - .BI "\-diff" " real" " \-1 " -- Dffusion coefficient to use in the rev. gem. recomb. kinetic model. If non\-positive, then it will be fitted to the ACF along with ka and kd. -+ Dffusion coefficient to use in the reversible geminate recombination kinetic model. If negative, then it will be fitted to the ACF along with ka and kd. - - .BI "\-acflen" " int" " \-1" - Length of the ACF, default is half the number of frames -@@ -272,7 +276,7 @@ g_hbond - computes and analyzes hydrogen bonds - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_helix.1 b/man/man1/g_helix.1 -index cfdd05e..0151fc0 100644 ---- a/man/man1/g_helix.1 -+++ b/man/man1/g_helix.1 -@@ -1,8 +1,8 @@ --.TH g_helix 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_helix 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_helix - calculates basic properties of alpha helices - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_helix\fP - .BI "\-s" " topol.tpr " -@@ -27,46 +27,46 @@ g_helix - calculates basic properties of alpha helices - .BI "\-ahxstart" " int " - .BI "\-ahxend" " int " - .SH DESCRIPTION --\&g_helix computes all kind of helix properties. First, the peptide --\&is checked to find the longest helical part. This is determined by --\&Hydrogen bonds and Phi/Psi angles. -+\&\fB g_helix\fR computes all kinds of helix properties. First, the peptide -+\&is checked to find the longest helical part, as determined by -+\&hydrogen bonds and phi/psi angles. - \&That bit is fitted --\&to an ideal helix around the Z\-axis and centered around the origin. -+\&to an ideal helix around the \fI z\fR\-axis and centered around the origin. - \&Then the following properties are computed: - - --\&\fB 1.\fR Helix radius (file radius.xvg). This is merely the -+\&\fB 1.\fR Helix radius (file \fB radius.xvg\fR). This is merely the - \&RMS deviation in two dimensions for all Calpha atoms. - \&it is calced as sqrt((SUM i(x2(i)+y2(i)))/N), where N is the number - \&of backbone atoms. For an ideal helix the radius is 0.23 nm - --\&\fB 2.\fR Twist (file twist.xvg). The average helical angle per --\&residue is calculated. For alpha helix it is 100 degrees, --\&for 3\-10 helices it will be smaller, -+\&\fB 2.\fR Twist (file \fB twist.xvg\fR). The average helical angle per -+\&residue is calculated. For an alpha\-helix it is 100 degrees, -+\&for 3\-10 helices it will be smaller, and - \&for 5\-helices it will be larger. - --\&\fB 3.\fR Rise per residue (file rise.xvg). The helical rise per --\&residue is plotted as the difference in Z\-coordinate between Ca --\&atoms. For an ideal helix this is 0.15 nm -+\&\fB 3.\fR Rise per residue (file \fB rise.xvg\fR). The helical rise per -+\&residue is plotted as the difference in \fI z\fR\-coordinate between Calpha -+\&atoms. For an ideal helix, this is 0.15 nm - --\&\fB 4.\fR Total helix length (file len\-ahx.xvg). The total length -+\&\fB 4.\fR Total helix length (file \fB len\-ahx.xvg\fR). The total length - \&of the - \&helix in nm. This is simply the average rise (see above) times the - \&number of helical residues (see below). - --\&\fB 5.\fR Number of helical residues (file n\-ahx.xvg). The title says -+\&\fB 5.\fR Number of helical residues (file \fB n\-ahx.xvg\fR). The title says - \&it all. - --\&\fB 6.\fR Helix Dipole, backbone only (file dip\-ahx.xvg). -+\&\fB 6.\fR Helix dipole, backbone only (file \fB dip\-ahx.xvg\fR). - - \&\fB 7.\fR RMS deviation from ideal helix, calculated for the Calpha --\&atoms only (file rms\-ahx.xvg). -+\&atoms only (file \fB rms\-ahx.xvg\fR). - --\&\fB 8.\fR Average Calpha\-Calpha dihedral angle (file phi\-ahx.xvg). -+\&\fB 8.\fR Average Calpha \- Calpha dihedral angle (file \fB phi\-ahx.xvg\fR). - --\&\fB 9.\fR Average Phi and Psi angles (file phipsi.xvg). -+\&\fB 9.\fR Average phi and psi angles (file \fB phipsi.xvg\fR). - --\&\fB 10.\fR Ellipticity at 222 nm according to \fI Hirst and Brooks\fR -+\&\fB 10.\fR Ellipticity at 222 nm according to Hirst and Brooks. - \& - - -@@ -115,7 +115,7 @@ g_helix - calculates basic properties of alpha helices - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-r0" " int" " 1" - The first residue number in the sequence -diff --git a/man/man1/g_helixorient.1 b/man/man1/g_helixorient.1 -index c6a1429..11d6320 100644 ---- a/man/man1/g_helixorient.1 -+++ b/man/man1/g_helixorient.1 -@@ -1,8 +1,8 @@ --.TH g_helixorient 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_helixorient 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_helixorient - calculates local pitch/bending/rotation/orientation inside helices - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_helixorient\fP - .BI "\-s" " topol.tpr " -@@ -26,18 +26,18 @@ g_helixorient - calculates local pitch/bending/rotation/orientation inside helic - .BI "\-[no]sidechain" "" - .BI "\-[no]incremental" "" - .SH DESCRIPTION --\&g_helixorient calculates the coordinates and direction of the average -+\&\fB g_helixorient\fR calculates the coordinates and direction of the average - \&axis inside an alpha helix, and the direction/vectors of both the --\&alpha carbon and (optionally) a sidechain atom relative to the axis. -+\&Calpha and (optionally) a sidechain atom relative to the axis. - - --\&As input, you need to specify an index group with alpha carbon atoms --\&corresponding to an alpha helix of continuous residues. Sidechain -+\&As input, you need to specify an index group with Calpha atoms -+\&corresponding to an alpha\-helix of continuous residues. Sidechain - \&directions require a second index group of the same size, containing - \&the heavy atom in each residue that should represent the sidechain. - - --\&Note that this program does not do any fitting of structures. -+\&\fB Note\fR that this program does not do any fitting of structures. - - - \&We need four Calpha coordinates to define the local direction of the helix -@@ -45,11 +45,11 @@ g_helixorient - calculates local pitch/bending/rotation/orientation inside helic - - - \&The tilt/rotation is calculated from Euler rotations, where we define --\&the helix axis as the local X axis, the residues/CA\-vector as Y, and the --\&Z axis from their cross product. We use the Euler Y\-Z\-X rotation, meaning -+\&the helix axis as the local \fI x\fR\-axis, the residues/Calpha vector as \fI y\fR, and the -+\&\fI z\fR\-axis from their cross product. We use the Euler Y\-Z\-X rotation, meaning - \&we first tilt the helix axis (1) around and (2) orthogonal to the residues - \&vector, and finally apply the (3) rotation around it. For debugging or other --\&purposes, we also write out the actual Euler rotation angles as theta1\-3.xvg -+\&purposes, we also write out the actual Euler rotation angles as \fB theta[1\-3].xvg\fR - .SH FILES - .BI "\-s" " topol.tpr" - .B Input -diff --git a/man/man1/g_hydorder.1 b/man/man1/g_hydorder.1 -new file mode 100644 -index 0000000..2322d10 ---- /dev/null -+++ b/man/man1/g_hydorder.1 -@@ -0,0 +1,103 @@ -+.TH g_hydorder 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" -+.SH NAME -+g_hydorder -+.B VERSION 4.5.4-dev-20110404-bc5695c -+.SH SYNOPSIS -+\f3g_hydorder\fP -+.BI "\-f" " traj.xtc " -+.BI "\-n" " index.ndx " -+.BI "\-s" " topol.tpr " -+.BI "\-o" " intf.xpm " -+.BI "\-or" " raw.out " -+.BI "\-Spect" " intfspect.out " -+.BI "\-[no]h" "" -+.BI "\-[no]version" "" -+.BI "\-nice" " int " -+.BI "\-b" " time " -+.BI "\-e" " time " -+.BI "\-dt" " time " -+.BI "\-[no]w" "" -+.BI "\-d" " enum " -+.BI "\-bw" " real " -+.BI "\-sgang1" " real " -+.BI "\-sgang2" " real " -+.BI "\-tblock" " int " -+.BI "\-nlevel" " int " -+.SH DESCRIPTION -+\&The tetrahedrality order parameters can be determined -+\&around an atom. Both angle an distance order parameters are calculated. See -+\&P.\-L. Chau and A.J. Hardwick, Mol. Phys., 93, (1998), 511\-518. -+\&for more details. -+This application calculates the orderparameter in a 3d\-mesh in the box, and -+\&with 2 phases in the box gives the user the option to define a 2D interface in time -+\&separating the faces by specifying parameters \-sgang1 and \-sgang2 (It is important -+\&to select these judiciously) -+.SH FILES -+.BI "\-f" " traj.xtc" -+.B Input -+ Trajectory: xtc trr trj gro g96 pdb cpt -+ -+.BI "\-n" " index.ndx" -+.B Input -+ Index file -+ -+.BI "\-s" " topol.tpr" -+.B Input -+ Run input file: tpr tpb tpa -+ -+.BI "\-o" " intf.xpm" -+.B Output, Mult. -+ X PixMap compatible matrix file -+ -+.BI "\-or" " raw.out" -+.B Output, Opt., Mult. -+ Generic output file -+ -+.BI "\-Spect" " intfspect.out" -+.B Output, Opt., Mult. -+ Generic output file -+ -+.SH OTHER OPTIONS -+.BI "\-[no]h" "no " -+ Print help info and quit -+ -+.BI "\-[no]version" "no " -+ Print version info and quit -+ -+.BI "\-nice" " int" " 19" -+ Set the nicelevel -+ -+.BI "\-b" " time" " 0 " -+ First frame (ps) to read from trajectory -+ -+.BI "\-e" " time" " 0 " -+ Last frame (ps) to read from trajectory -+ -+.BI "\-dt" " time" " 0 " -+ Only use frame when t MOD dt = first time (ps) -+ -+.BI "\-[no]w" "no " -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files -+ -+.BI "\-d" " enum" " z" -+ Direction of the normal on the membrane: \fB z\fR, \fB x\fR or \fB y\fR -+ -+.BI "\-bw" " real" " 1 " -+ Binwidth of box mesh -+ -+.BI "\-sgang1" " real" " 1 " -+ tetrahedral angle parameter in Phase 1 (bulk) -+ -+.BI "\-sgang2" " real" " 1 " -+ tetrahedral angle parameter in Phase 2 (bulk) -+ -+.BI "\-tblock" " int" " 1" -+ Number of frames in one time\-block average -+ -+.BI "\-nlevel" " int" " 100" -+ Number of Height levels in 2D \- XPixMaps -+ -+.SH SEE ALSO -+.BR gromacs(7) -+ -+More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. -diff --git a/man/man1/g_lie.1 b/man/man1/g_lie.1 -index 8596ace..7dddb0e 100644 ---- a/man/man1/g_lie.1 -+++ b/man/man1/g_lie.1 -@@ -1,8 +1,8 @@ --.TH g_lie 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_lie 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_lie - free energy estimate from linear combinations - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_lie\fP - .BI "\-f" " ener.edr " -@@ -21,7 +21,7 @@ g_lie - free energy estimate from linear combinations - .BI "\-Cqq" " real " - .BI "\-ligand" " string " - .SH DESCRIPTION --\&g_lie computes a free energy estimate based on an energy analysis -+\&\fB g_lie\fR computes a free energy estimate based on an energy analysis - \&from. One needs an energy file with the following components: - \&Coul (A\-B) LJ\-SR (A\-B) etc. - .SH FILES -@@ -53,7 +53,7 @@ g_lie - free energy estimate from linear combinations - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_mdmat.1 b/man/man1/g_mdmat.1 -index 5ecc49f..c4b84e9 100644 ---- a/man/man1/g_mdmat.1 -+++ b/man/man1/g_mdmat.1 -@@ -1,8 +1,8 @@ --.TH g_mdmat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_mdmat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_mdmat - calculates residue contact maps - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_mdmat\fP - .BI "\-f" " traj.xtc " -@@ -21,16 +21,15 @@ g_mdmat - calculates residue contact maps - .BI "\-t" " real " - .BI "\-nlevels" " int " - .SH DESCRIPTION --\&g_mdmat makes distance matrices consisting of the smallest distance --\&between residue pairs. With \-frames these distance matrices can be --\&stored as a function --\&of time, to be able to see differences in tertiary structure as a --\&funcion of time. If you choose your options unwise, this may generate --\&a large output file. Default only an averaged matrix over the whole -+\&\fB g_mdmat\fR makes distance matrices consisting of the smallest distance -+\&between residue pairs. With \fB \-frames\fR, these distance matrices can be -+\&stored in order to see differences in tertiary structure as a -+\&function of time. If you choose your options unwisely, this may generate -+\&a large output file. By default, only an averaged matrix over the whole - \&trajectory is output. - \&Also a count of the number of different atomic contacts between - \&residues over the whole trajectory can be made. --\&The output can be processed with xpm2ps to make a PostScript (tm) plot. -+\&The output can be processed with \fB xpm2ps\fR to make a PostScript (tm) plot. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -diff --git a/man/man1/g_membed.1 b/man/man1/g_membed.1 -index 659033e..0070258 100644 ---- a/man/man1/g_membed.1 -+++ b/man/man1/g_membed.1 -@@ -1,8 +1,8 @@ --.TH g_membed 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_membed 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_membed - embeds a protein into a lipid bilayer - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_membed\fP - .BI "\-f" " into_mem.tpr " -@@ -39,6 +39,7 @@ g_membed - embeds a protein into a lipid bilayer - .BI "\-pf" " pullf.xvg " - .BI "\-mtx" " nm.mtx " - .BI "\-dn" " dipole.ndx " -+.BI "\-multidir" " rundir " - .BI "\-[no]h" "" - .BI "\-[no]version" "" - .BI "\-nice" " int " -@@ -58,28 +59,27 @@ g_membed - embeds a protein into a lipid bilayer - .BI "\-[no]compact" "" - .BI "\-[no]v" "" - .SH DESCRIPTION --\&g_membed embeds a membrane protein into an equilibrated lipid bilayer at the position -+\&\fB g_membed\fR embeds a membrane protein into an equilibrated lipid bilayer at the position - \&and orientation specified by the user. - --\& - - \&SHORT MANUAL - \-\-\-\-\-\-\-\-\-\-\-\- - - \&The user should merge the structure files of the protein and membrane (+solvent), creating a - \&single structure file with the protein overlapping the membrane at the desired position and --\&orientation. Box size should be taken from the membrane structure file. The corresponding topology --\&files should also be merged. Consecutively, create a tpr file (input for g_membed) from these files,with the following options included in the mdp file. -+\&orientation. The box size is taken from the membrane structure file. The corresponding topology -+\&files should also be merged. Consecutively, create a \fB .tpr\fR file (input for \fB g_membed\fR) from these files,with the following options included in the \fB .mdp\fR file. - --\& \- integrator = md -+\& \- \fB integrator = md\fR - --\& \- energygrp = Protein (or other group that you want to insert) -+\& \- \fB energygrp = Protein\fR (or other group that you want to insert) - --\& \- freezegrps = Protein -+\& \- \fB freezegrps = Protein\fR - --\& \- freezedim = Y Y Y -+\& \- \fB freezedim = Y Y Y\fR - --\& \- energygrp_excl = Protein Protein -+\& \- \fB energygrp_excl = Protein Protein\fR - - \&The output is a structure file containing the protein embedded in the membrane. If a topology - \&file is provided, the number of lipid and -@@ -87,33 +87,31 @@ g_membed - embeds a protein into a lipid bilayer - - \&For a more extensive manual see Wolf et al, J Comp Chem 31 (2010) 2169\-2174, Appendix. - --\& - - \&SHORT METHOD DESCRIPTION - - \&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- - --\&1. The protein is resized around its center of mass by a factor \-xy in the xy\-plane --\&(the membrane plane) and a factor \-z in the z\-direction (if the size of the -+\&1. The protein is resized around its center of mass by a factor \fB \-xy\fR in the xy\-plane -+\&(the membrane plane) and a factor \fB \-z\fR in the \fI z\fR\-direction (if the size of the - \&protein in the z\-direction is the same or smaller than the width of the membrane, a --\&\-z value larger than 1 can prevent that the protein will be enveloped by the lipids). -+\&\fB \-z\fR value larger than 1 can prevent that the protein will be enveloped by the lipids). - - \&2. All lipid and solvent molecules overlapping with the resized protein are removed. All --\&intraprotein interactions are turned off to prevent numerical issues for small values of \-xy --\& or \-z -+\&intraprotein interactions are turned off to prevent numerical issues for small values of \fB \-xy\fR -+\& or \fB \-z\fR - - \&3. One md step is performed. - --\&4. The resize factor (\-xy or \-z) is incremented by a small amount ((1\-xy)/nxy or (1\-z)/nz) and the -+\&4. The resize factor (\fB \-xy\fR or \fB \-z\fR) is incremented by a small amount ((1\-xy)/nxy or (1\-z)/nz) and the - \&protein is resized again around its center of mass. The resize factor for the xy\-plane --\&is incremented first. The resize factor for the z\-direction is not changed until the \-xy factor --\&is 1 (thus after \-nxy iteration). -+\&is incremented first. The resize factor for the z\-direction is not changed until the \fB \-xy\fR factor -+\&is 1 (thus after \fB \-nxy\fR iterations). - --\&5. Repeat step 3 and 4 until the protein reaches its original size (\-nxy + \-nz iterations). -+\&5. Repeat step 3 and 4 until the protein reaches its original size (\fB \-nxy\fR + \fB \-nz\fR iterations). - --\&For a more extensive method descrition see Wolf et al, J Comp Chem, 31 (2010) 2169\-2174. -+\&For a more extensive method description see Wolf et al, J Comp Chem, 31 (2010) 2169\-2174. - --\& - - \&NOTE - \-\-\-\- -@@ -121,10 +119,9 @@ g_membed - embeds a protein into a lipid bilayer - \& \- Protein can be any molecule you want to insert in the membrane. - - \& \- It is recommended to perform a short equilibration run after the embedding --\&(see Wolf et al, J Comp Chem 31 (2010) 2169\-2174, to re\-equilibrate the membrane. Clearly -+\&(see Wolf et al, J Comp Chem 31 (2010) 2169\-2174), to re\-equilibrate the membrane. Clearly - \&protein equilibration might require longer. - --\& - - .SH FILES - .BI "\-f" " into_mem.tpr" -@@ -263,6 +260,10 @@ g_membed - embeds a protein into a lipid bilayer - .B Output, Opt. - Index file - -+.BI "\-multidir" " rundir" -+.B Input, Opt., Mult. -+ Run directory -+ - .SH OTHER OPTIONS - .BI "\-[no]h" "no " - Print help info and quit -diff --git a/man/man1/g_mindist.1 b/man/man1/g_mindist.1 -index 67428bd..a07a6f0 100644 ---- a/man/man1/g_mindist.1 -+++ b/man/man1/g_mindist.1 -@@ -1,8 +1,8 @@ --.TH g_mindist 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_mindist 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_mindist - calculates the minimum distance between two groups - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_mindist\fP - .BI "\-f" " traj.xtc " -@@ -33,7 +33,7 @@ g_mindist - calculates the minimum distance between two groups - .BI "\-[no]respertime" "" - .BI "\-[no]printresname" "" - .SH DESCRIPTION --\&g_mindist computes the distance between one group and a number of -+\&\fB g_mindist\fR computes the distance between one group and a number of - \&other groups. Both the minimum distance - \&(between any pair of atoms from the respective groups) - \&and the number of contacts within a given -@@ -111,7 +111,7 @@ g_mindist - calculates the minimum distance between two groups - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_morph.1 b/man/man1/g_morph.1 -index e55da0d..31c44c2 100644 ---- a/man/man1/g_morph.1 -+++ b/man/man1/g_morph.1 -@@ -1,8 +1,8 @@ --.TH g_morph 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_morph 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_morph - linear interpolation of conformations - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_morph\fP - .BI "\-f1" " conf1.gro " -@@ -20,15 +20,15 @@ g_morph - linear interpolation of conformations - .BI "\-last" " real " - .BI "\-[no]fit" "" - .SH DESCRIPTION --\&g_morph does a linear interpolation of conformations in order to -+\&\fB g_morph\fR does a linear interpolation of conformations in order to - \&create intermediates. Of course these are completely unphysical, but - \&that you may try to justify yourself. Output is in the form of a - \&generic trajectory. The number of intermediates can be controlled with --\&the \-ninterm flag. The first and last flag correspond to the way of -+\&the \fB \-ninterm\fR flag. The first and last flag correspond to the way of - \&interpolating: 0 corresponds to input structure 1 while - \&1 corresponds to input structure 2. --\&If you specify first 0 or last 1 extrapolation will be --\&on the path from input structure x1 to x2. In general the coordinates -+\&If you specify \fB \-first\fR 0 or \fB \-last\fR 1 extrapolation will be -+\&on the path from input structure x1 to x2. In general, the coordinates - \&of the intermediate x(i) out of N total intermidates correspond to: - - -@@ -36,8 +36,8 @@ g_morph - linear interpolation of conformations - - - \&Finally the RMSD with respect to both input structures can be computed --\&if explicitly selected (\-or option). In that case an index file may be --\&read to select what group RMS is computed from. -+\&if explicitly selected (\fB \-or\fR option). In that case, an index file may be -+\&read to select the group from which the RMS is computed. - .SH FILES - .BI "\-f1" " conf1.gro" - .B Input -@@ -70,7 +70,7 @@ g_morph - linear interpolation of conformations - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_msd.1 b/man/man1/g_msd.1 -index 838ba4c..95cdad0 100644 ---- a/man/man1/g_msd.1 -+++ b/man/man1/g_msd.1 -@@ -1,8 +1,8 @@ --.TH g_msd 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_msd 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_msd - calculates mean square displacements - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_msd\fP - .BI "\-f" " traj.xtc " -@@ -30,7 +30,7 @@ g_msd - calculates mean square displacements - .BI "\-beginfit" " time " - .BI "\-endfit" " time " - .SH DESCRIPTION --\&g_msd computes the mean square displacement (MSD) of atoms from -+\&\fB g_msd\fR computes the mean square displacement (MSD) of atoms from - \&a set of initial positions. This provides an easy way to compute - \&the diffusion constant using the Einstein relation. - \&The time between the reference points for the MSD calculation -@@ -49,7 +49,8 @@ g_msd - calculates mean square displacements - \&each group, the order in the output is: trace xx yy zz yx zx zy. - - --\&If \fB \-mol\fR is set, g_msd plots the MSD for individual molecules: -+\&If \fB \-mol\fR is set, \fB g_msd\fR plots the MSD for individual molecules -+\&(including making molecules whole across periodic boundaries): - \&for each individual molecule a diffusion constant is computed for - \&its center of mass. The chosen index group will be split into - \&molecules. -@@ -62,7 +63,7 @@ g_msd - calculates mean square displacements - \&With the option \fB \-rmcomm\fR, the center of mass motion of a - \&specific group can be removed. For trajectories produced with - \&GROMACS this is usually not necessary, --\&as mdrun usually already removes the center of mass motion. -+\&as \fB mdrun\fR usually already removes the center of mass motion. - \&When you use this option be sure that the whole system is stored - \&in the trajectory file. - -@@ -79,7 +80,7 @@ g_msd - calculates mean square displacements - \&\fB \-beginfit\fR and \fB \-endfit\fR. - - --\&Option \fB \-pdb\fR writes a pdb file with the coordinates of the frame -+\&Option \fB \-pdb\fR writes a \fB .pdb\fR file with the coordinates of the frame - \&at time \fB \-tpdb\fR with in the B\-factor field the square root of - \&the diffusion coefficient of the molecule. - \&This option implies option \fB \-mol\fR. -@@ -128,7 +129,7 @@ g_msd - calculates mean square displacements - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -152,7 +153,7 @@ g_msd - calculates mean square displacements - Remove center of mass motion - - .BI "\-tpdb" " time" " 0 " -- The frame to use for option \-pdb (ps) -+ The frame to use for option \fB \-pdb\fR (ps) - - .BI "\-trestart" " time" " 10 " - Time between restarting points in trajectory (ps) -diff --git a/man/man1/g_nmeig.1 b/man/man1/g_nmeig.1 -index 16a72bb..4bca624 100644 ---- a/man/man1/g_nmeig.1 -+++ b/man/man1/g_nmeig.1 -@@ -1,14 +1,15 @@ --.TH g_nmeig 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_nmeig 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_nmeig - diagonalizes the Hessian - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_nmeig\fP - .BI "\-f" " hessian.mtx " - .BI "\-s" " topol.tpr " - .BI "\-of" " eigenfreq.xvg " - .BI "\-ol" " eigenval.xvg " -+.BI "\-qc" " quant_corr.xvg " - .BI "\-v" " eigenvec.trr " - .BI "\-[no]h" "" - .BI "\-[no]version" "" -@@ -17,8 +18,10 @@ g_nmeig - diagonalizes the Hessian - .BI "\-[no]m" "" - .BI "\-first" " int " - .BI "\-last" " int " -+.BI "\-T" " real " -+.BI "\-[no]constr" "" - .SH DESCRIPTION --\&g_nmeig calculates the eigenvectors/values of a (Hessian) matrix, -+\&\fB g_nmeig\fR calculates the eigenvectors/values of a (Hessian) matrix, - \&which can be calculated with \fB mdrun\fR. - \&The eigenvectors are written to a trajectory file (\fB \-v\fR). - \&The structure is written first with t=0. The eigenvectors -@@ -26,9 +29,32 @@ g_nmeig - diagonalizes the Hessian - \&The eigenvectors can be analyzed with \fB g_anaeig\fR. - \&An ensemble of structures can be generated from the eigenvectors with - \&\fB g_nmens\fR. When mass weighting is used, the generated eigenvectors --\&will be scaled back to plain cartesian coordinates before generating the --\&output \- in this case they will no longer be exactly orthogonal in the --\&standard cartesian norm (But in the mass weighted norm they would be). -+\&will be scaled back to plain Cartesian coordinates before generating the -+\&output. In this case, they will no longer be exactly orthogonal in the -+\&standard Cartesian norm, but in the mass\-weighted norm they would be. -+ -+ -+\&This program can be optionally used to compute quantum corrections to heat capacity -+\&and enthalpy by providing an extra file argument \fB \-qcorr\fR. See the GROMACS -+\&manual, Chapter 1, for details. The result includes subtracting a harmonic -+\°ree of freedom at the given temperature. -+\&The total correction is printed on the terminal screen. -+\&The recommended way of getting the corrections out is: -+ -+ -+\&\fB g_nmeig \-s topol.tpr \-f nm.mtx \-first 7 \-last 10000 \-T 300 \-qc [\-constr]\fR -+ -+ -+\&The \fB \-constr\fR option should be used when bond constraints were used during the -+\&simulation \fB for all the covalent bonds\fR. If this is not the case, -+\&you need to analyze the \fB quant_corr.xvg\fR file yourself. -+ -+ -+\&To make things more flexible, the program can also take virtual sites into account -+\&when computing quantum corrections. When selecting \fB \-constr\fR and -+\&\fB \-qc\fR, the \fB \-begin\fR and \fB \-end\fR options will be set automatically as well. -+\&Again, if you think you know it better, please check the \fB eigenfreq.xvg\fR -+\&output. - .SH FILES - .BI "\-f" " hessian.mtx" - .B Input -@@ -36,7 +62,7 @@ g_nmeig - diagonalizes the Hessian - - .BI "\-s" " topol.tpr" - .B Input -- Structure+mass(db): tpr tpb tpa gro g96 pdb -+ Run input file: tpr tpb tpa - - .BI "\-of" " eigenfreq.xvg" - .B Output -@@ -46,6 +72,10 @@ g_nmeig - diagonalizes the Hessian - .B Output - xvgr/xmgr file - -+.BI "\-qc" " quant_corr.xvg" -+.B Output, Opt. -+ xvgr/xmgr file -+ - .BI "\-v" " eigenvec.trr" - .B Output - Full precision trajectory: trr trj cpt -@@ -72,6 +102,12 @@ g_nmeig - diagonalizes the Hessian - .BI "\-last" " int" " 50" - Last eigenvector to write away - -+.BI "\-T" " real" " 298.15" -+ Temperature for computing quantum heat capacity and enthalpy when using normal mode calculations to correct classical simulations -+ -+.BI "\-[no]constr" "no " -+ If constraints were used in the simulation but not in the normal mode analysis (this is the recommended way of doing it) you will need to set this for computing the quantum corrections. -+ - .SH SEE ALSO - .BR gromacs(7) - -diff --git a/man/man1/g_nmens.1 b/man/man1/g_nmens.1 -index 85d3f98..88f72fd 100644 ---- a/man/man1/g_nmens.1 -+++ b/man/man1/g_nmens.1 -@@ -1,8 +1,8 @@ --.TH g_nmens 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_nmens 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_nmens - generates an ensemble of structures from the normal modes - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_nmens\fP - .BI "\-v" " eigenvec.trr " -@@ -21,7 +21,7 @@ g_nmens - generates an ensemble of structures from the normal modes - .BI "\-last" " int " - .SH DESCRIPTION - \&\fB g_nmens\fR generates an ensemble around an average structure --\&in a subspace which is defined by a set of normal modes (eigenvectors). -+\&in a subspace that is defined by a set of normal modes (eigenvectors). - \&The eigenvectors are assumed to be mass\-weighted. - \&The position along each eigenvector is randomly taken from a Gaussian - \&distribution with variance kT/eigenvalue. -diff --git a/man/man1/g_nmtraj.1 b/man/man1/g_nmtraj.1 -index 173fa32..b4fe86b 100644 ---- a/man/man1/g_nmtraj.1 -+++ b/man/man1/g_nmtraj.1 -@@ -1,8 +1,8 @@ --.TH g_nmtraj 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_nmtraj 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_nmtraj - generate a virtual trajectory from an eigenvector - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_nmtraj\fP - .BI "\-s" " topol.tpr " -@@ -18,7 +18,7 @@ g_nmtraj - generate a virtual trajectory from an eigenvector - .BI "\-nframes" " int " - .SH DESCRIPTION - \&\fB g_nmtraj\fR generates an virtual trajectory from an eigenvector, --\&corresponding to a harmonic cartesian oscillation around the average -+\&corresponding to a harmonic Cartesian oscillation around the average - \&structure. The eigenvectors should normally be mass\-weighted, but you can - \&use non\-weighted eigenvectors to generate orthogonal motions. - \&The output frames are written as a trajectory file covering an entire period, and -@@ -26,10 +26,10 @@ g_nmtraj - generate a virtual trajectory from an eigenvector - \&PDB format you can view it directly in PyMol and also render a photorealistic movie. - \&Motion amplitudes are calculated from the eigenvalues and a preset temperature, - \&assuming equipartition of the energy over all modes. To make the motion clearly visible --\&in PyMol you might want to amplify it by setting an unrealistic high temperature. --\&However, be aware that both the linear cartesian displacements and mass weighting will -+\&in PyMol you might want to amplify it by setting an unrealistically high temperature. -+\&However, be aware that both the linear Cartesian displacements and mass weighting will - \&lead to serious structure deformation for high amplitudes \- this is is simply a limitation --\&of the cartesian normal mode model. By default the selected eigenvector is set to 7, since -+\&of the Cartesian normal mode model. By default the selected eigenvector is set to 7, since - \& the first six normal modes are the translational and rotational degrees of freedom. - .SH FILES - .BI "\-s" " topol.tpr" -diff --git a/man/man1/g_options.1 b/man/man1/g_options.1 -new file mode 100644 -index 0000000..5c0a41c ---- /dev/null -+++ b/man/man1/g_options.1 -@@ -0,0 +1,49 @@ -+.TH g_options 1 "Sun 10 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110410-e5eb052-dirty" -+.SH NAME -+g_options -+.B VERSION 4.5.4-dev-20110410-e5eb052-dirty -+.SH SYNOPSIS -+\f3g_options\fP -+.BI "\-[no]h" "" -+.BI "\-[no]version" "" -+.BI "\-nice" " int " -+.SH DESCRIPTION -+\&GROMACS programs have some standard options, -+\&of which some are hidden by default: -+.SH OTHER OPTIONS -+.BI "\-[no]h" "no " -+ Print help info and quit -+ -+.BI "\-[no]version" "no " -+ Print version info and quit -+ -+.BI "\-nice" " int" " 0" -+ Set the nicelevel -+ -+.SH KNOWN PROBLEMS -+\- If the configuration script found Motif or Lesstif on your system, you can use the graphical interface (if not, you will get an error): -+\fB \-X\fR gmx_bool \fB no\fR Use dialog box GUI to edit command line options -+ -+\- When compiled on an SGI\-IRIX system, all GROMACS programs have an additional option: -+\fB \-npri\fR int \fB 0\fR Set non blocking priority (try 128) -+ -+\- Optional files are not used unless the option is set, in contrast to non\-optional files, where the default file name is used when the option is not set. -+ -+\- All GROMACS programs will accept file options without a file extension or filename being specified. In such cases the default filenames will be used. With multiple input file types, such as generic structure format, the directory will be searched for files of each type with the supplied or default name. When no such file is found, or with output files the first file type will be used. -+ -+\- All GROMACS programs with the exception of \fB mdrun\fR and \fB eneconv\fR check if the command line options are valid. If this is not the case, the program will be halted. -+ -+\- Enumerated options (enum) should be used with one of the arguments listed in the option description, the argument may be abbreviated. The first match to the shortest argument in the list will be selected. -+ -+\- Vector options can be used with 1 or 3 parameters. When only one parameter is supplied the two others are also set to this value. -+ -+\- All GROMACS programs can read compressed or g\-zipped files. There might be a problem with reading compressed \fB .xtc\fR, \fB .trr\fR and \fB .trj\fR files, but these will not compress very well anyway. -+ -+\- Most GROMACS programs can process a trajectory with fewer atoms than the run input or structure file, but only if the trajectory consists of the first n atoms of the run input or structure file. -+ -+\- Many GROMACS programs will accept the \fB \-tu\fR option to set the time units to use in output files (e.g. for \fB xmgr\fR graphs or \fB xpm\fR matrices) and in all time options. -+ -+.SH SEE ALSO -+.BR gromacs(7) -+ -+More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. -diff --git a/man/man1/g_order.1 b/man/man1/g_order.1 -index 8ff7a0d..e29acbd 100644 ---- a/man/man1/g_order.1 -+++ b/man/man1/g_order.1 -@@ -1,8 +1,8 @@ --.TH g_order 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_order 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_order - computes the order parameter per atom for carbon tails - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_order\fP - .BI "\-f" " traj.xtc " -@@ -44,9 +44,9 @@ g_order - computes the order parameter per atom for carbon tails - - \&The program can also give all - \&diagonal elements of the order tensor and even calculate the deuterium --\&order parameter Scd (default). If the option \-szonly is given, only one --\&order tensor component (specified by the \-d option) is given and the --\&order parameter per slice is calculated as well. If \-szonly is not -+\&order parameter Scd (default). If the option \fB \-szonly\fR is given, only one -+\&order tensor component (specified by the \fB \-d\fR option) is given and the -+\&order parameter per slice is calculated as well. If \fB \-szonly\fR is not - \&selected, all diagonal elements and the deuterium order parameter is - \&given. - -@@ -125,7 +125,7 @@ The tetrahedrality order parameters can be determined - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -134,10 +134,10 @@ The tetrahedrality order parameters can be determined - Direction of the normal on the membrane: \fB z\fR, \fB x\fR or \fB y\fR - - .BI "\-sl" " int" " 1" -- Calculate order parameter as function of boxlength, dividing the box in nr slices. -+ Calculate order parameter as function of box length, dividing the box in nr slices. - - .BI "\-[no]szonly" "no " -- Only give Sz element of order tensor. (axis can be specified with \-d) -+ Only give Sz element of order tensor. (axis can be specified with \fB \-d\fR) - - .BI "\-[no]unsat" "no " - Calculate order parameters for unsaturated carbons. Note that this cannot be mixed with normal order parameters. -diff --git a/man/man1/g_pme_error.1 b/man/man1/g_pme_error.1 -new file mode 100644 -index 0000000..a3c313e ---- /dev/null -+++ b/man/man1/g_pme_error.1 -@@ -0,0 +1,70 @@ -+.TH g_pme_error 1 "Sun 10 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110410-e5eb052-dirty" -+.SH NAME -+g_pme_error - estimates the error of using PME with a given input file -+ -+.B VERSION 4.5.4-dev-20110410-e5eb052-dirty -+.SH SYNOPSIS -+\f3g_pme_error\fP -+.BI "\-s" " topol.tpr " -+.BI "\-o" " error.out " -+.BI "\-so" " tuned.tpr " -+.BI "\-[no]h" "" -+.BI "\-[no]version" "" -+.BI "\-nice" " int " -+.BI "\-beta" " real " -+.BI "\-[no]tune" "" -+.BI "\-self" " real " -+.BI "\-seed" " int " -+.BI "\-[no]v" "" -+.SH DESCRIPTION -+\&\fB g_pme_error\fR estimates the error of the electrostatic forces -+\&if using the sPME algorithm. The flag \fB \-tune\fR will determine -+\&the splitting parameter such that the error is equally -+\&distributed over the real and reciprocal space part. -+\&The part of the error that stems from self interaction of the particles is computationally demanding. However, a good a approximation is to -+\&just use a fraction of the particles for this term which can be -+\&indicated by the flag \fB \-self\fR. -+ -+ -+.SH FILES -+.BI "\-s" " topol.tpr" -+.B Input -+ Run input file: tpr tpb tpa -+ -+.BI "\-o" " error.out" -+.B Output -+ Generic output file -+ -+.BI "\-so" " tuned.tpr" -+.B Output, Opt. -+ Run input file: tpr tpb tpa -+ -+.SH OTHER OPTIONS -+.BI "\-[no]h" "no " -+ Print help info and quit -+ -+.BI "\-[no]version" "no " -+ Print version info and quit -+ -+.BI "\-nice" " int" " 0" -+ Set the nicelevel -+ -+.BI "\-beta" " real" " \-1 " -+ If positive, overwrite ewald_beta from \fB .tpr\fR file with this value -+ -+.BI "\-[no]tune" "no " -+ Tune the splitting parameter such that the error is equally distributed between real and reciprocal space -+ -+.BI "\-self" " real" " 1 " -+ If between 0.0 and 1.0, determine self interaction error from just this fraction of the charged particles -+ -+.BI "\-seed" " int" " 0" -+ Random number seed used for Monte Carlo algorithm when \fB \-self\fR is set to a value between 0.0 and 1.0 -+ -+.BI "\-[no]v" "no " -+ Be loud and noisy -+ -+.SH SEE ALSO -+.BR gromacs(7) -+ -+More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. -diff --git a/man/man1/g_polystat.1 b/man/man1/g_polystat.1 -index 08e6ffe..cebc497 100644 ---- a/man/man1/g_polystat.1 -+++ b/man/man1/g_polystat.1 -@@ -1,8 +1,8 @@ --.TH g_polystat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_polystat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_polystat - calculates static properties of polymers - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_polystat\fP - .BI "\-s" " topol.tpr " -@@ -24,7 +24,7 @@ g_polystat - calculates static properties of polymers - .BI "\-[no]mw" "" - .BI "\-[no]pc" "" - .SH DESCRIPTION --\&g_polystat plots static properties of polymers as a function of time -+\&\fB g_polystat\fR plots static properties of polymers as a function of time - \&and prints the average. - - -@@ -103,7 +103,7 @@ g_polystat - calculates static properties of polymers - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_potential.1 b/man/man1/g_potential.1 -index 124063e..aee31ae 100644 ---- a/man/man1/g_potential.1 -+++ b/man/man1/g_potential.1 -@@ -1,8 +1,8 @@ --.TH g_potential 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_potential 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_potential - calculates the electrostatic potential across the box - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_potential\fP - .BI "\-f" " traj.xtc " -@@ -28,14 +28,14 @@ g_potential - calculates the electrostatic potential across the box - .BI "\-ng" " int " - .BI "\-[no]correct" "" - .SH DESCRIPTION --\&Compute the electrostatical potential across the box. The potential is -+\&\fB g_potential\fR computes the electrostatical potential across the box. The potential is - \&calculated by first summing the charges per slice and then integrating - \&twice of this charge distribution. Periodic boundaries are not taken - \&into account. Reference of potential is taken to be the left side of --\&the box. It's also possible to calculate the potential in spherical -+\&the box. It is also possible to calculate the potential in spherical - \&coordinates as function of r by calculating a charge distribution in - \&spherical slices and twice integrating them. epsilon_r is taken as 1, --\&2 is more appropriate in many cases. -+\&but 2 is more appropriate in many cases. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -@@ -81,7 +81,7 @@ g_potential - calculates the electrostatic potential across the box - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_principal.1 b/man/man1/g_principal.1 -index eb19599..5f353e1 100644 ---- a/man/man1/g_principal.1 -+++ b/man/man1/g_principal.1 -@@ -1,8 +1,8 @@ --.TH g_principal 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_principal 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_principal - calculates axes of inertia for a group of atoms - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_principal\fP - .BI "\-f" " traj.xtc " -@@ -22,7 +22,7 @@ g_principal - calculates axes of inertia for a group of atoms - .BI "\-[no]w" "" - .BI "\-[no]foo" "" - .SH DESCRIPTION --\&g_principal calculates the three principal axes of inertia for a group -+\&\fB g_principal\fR calculates the three principal axes of inertia for a group - \&of atoms. - .SH FILES - .BI "\-f" " traj.xtc" -@@ -76,7 +76,7 @@ g_principal - calculates axes of inertia for a group of atoms - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-[no]foo" "no " - Dummy option to avoid empty array -diff --git a/man/man1/g_protonate.1 b/man/man1/g_protonate.1 -index 5f8d79d..c18fa87 100644 ---- a/man/man1/g_protonate.1 -+++ b/man/man1/g_protonate.1 -@@ -1,8 +1,8 @@ --.TH g_protonate 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_protonate 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_protonate - protonates structures - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_protonate\fP - .BI "\-s" " topol.tpr " -@@ -16,15 +16,15 @@ g_protonate - protonates structures - .BI "\-e" " time " - .BI "\-dt" " time " - .SH DESCRIPTION --\&\fB protonate\fR reads (a) conformation(s) and adds all missing --\&hydrogens as defined in \fB ffgmx2.hdb\fR. If only \fB \-s\fR is -+\&\fB g_protonate\fR reads (a) conformation(s) and adds all missing -+\&hydrogens as defined in \fB gmx2.ff/aminoacids.hdb\fR. If only \fB \-s\fR is - \&specified, this conformation will be protonated, if also \fB \-f\fR --\&is specified, the conformation(s) will be read from this file -+\&is specified, the conformation(s) will be read from this file, - \&which can be either a single conformation or a trajectory. - \& - - --\&If a pdb file is supplied, residue names might not correspond to -+\&If a \fB .pdb\fR file is supplied, residue names might not correspond to - \&to the GROMACS naming conventions, in which case these residues will - \&probably not be properly protonated. - \& -diff --git a/man/man1/g_rama.1 b/man/man1/g_rama.1 -index 4cc33ad..df19aaf 100644 ---- a/man/man1/g_rama.1 -+++ b/man/man1/g_rama.1 -@@ -1,8 +1,8 @@ --.TH g_rama 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_rama 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_rama - computes Ramachandran plots - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_rama\fP - .BI "\-f" " traj.xtc " -@@ -17,7 +17,7 @@ g_rama - computes Ramachandran plots - .BI "\-[no]w" "" - .BI "\-xvg" " enum " - .SH DESCRIPTION --\&g_rama selects the Phi/Psi dihedral combinations from your topology file -+\&\fB g_rama\fR selects the phi/psi dihedral combinations from your topology file - \&and computes these as a function of time. - \&Using simple Unix tools such as \fI grep\fR you can select out - \&specific residues. -@@ -54,7 +54,7 @@ g_rama - computes Ramachandran plots - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_rdf.1 b/man/man1/g_rdf.1 -index 9e15a5c..4f19f52 100644 ---- a/man/man1/g_rdf.1 -+++ b/man/man1/g_rdf.1 -@@ -1,8 +1,8 @@ --.TH g_rdf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_rdf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_rdf - calculates radial distribution functions - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_rdf\fP - .BI "\-f" " traj.xtc " -@@ -42,22 +42,22 @@ g_rdf - calculates radial distribution functions - \&a scattering experiment. - - --\&g_rdf calculates radial distribution functions in different ways. -+\&\fB g_rdf\fR calculates radial distribution functions in different ways. - \&The normal method is around a (set of) particle(s), the other methods - \&are around the center of mass of a set of particles (\fB \-com\fR) - \&or to the closest particle in a set (\fB \-surf\fR). --\&With all methods rdf's can also be calculated around axes parallel --\&to the z\-axis with option \fB \-xy\fR. -+\&With all methods, the RDF can also be calculated around axes parallel -+\&to the \fI z\fR\-axis with option \fB \-xy\fR. - \&With option \fB \-surf\fR normalization can not be used. - - --\&The option \fB \-rdf\fR sets the type of rdf to be computed. -+\&The option \fB \-rdf\fR sets the type of RDF to be computed. - \&Default is for atoms or particles, but one can also select center --\&of mass or geometry of molecules or residues. In all cases only -+\&of mass or geometry of molecules or residues. In all cases, only - \&the atoms in the index groups are taken into account. --\&For molecules and/or the center of mass option a run input file -+\&For molecules and/or the center of mass option, a run input file - \&is required. --\&Other weighting than COM or COG can currently only be achieved -+\&Weighting other than COM or COG can currently only be achieved - \&by providing a run input file with different masses. - \&Options \fB \-com\fR and \fB \-surf\fR also work in conjunction - \&with \fB \-rdf\fR. -@@ -65,17 +65,17 @@ g_rdf - calculates radial distribution functions - - \&If a run input file is supplied (\fB \-s\fR) and \fB \-rdf\fR is set - \&to \fB atom\fR, exclusions defined --\&in that file are taken into account when calculating the rdf. -+\&in that file are taken into account when calculating the RDF. - \&The option \fB \-cut\fR is meant as an alternative way to avoid --\&intramolecular peaks in the rdf plot. -+\&intramolecular peaks in the RDF plot. - \&It is however better to supply a run input file with a higher number of --\&exclusions. For eg. benzene a topology with nrexcl set to 5 --\&would eliminate all intramolecular contributions to the rdf. -+\&exclusions. For e.g. benzene a topology, setting nrexcl to 5 -+\&would eliminate all intramolecular contributions to the RDF. - \&Note that all atoms in the selected groups are used, also the ones - \&that don't have Lennard\-Jones interactions. - - --\&Option \fB \-cn\fR produces the cumulative number rdf, -+\&Option \fB \-cn\fR produces the cumulative number RDF, - \&i.e. the average number of particles within a distance r. - - -@@ -135,7 +135,7 @@ g_rdf - calculates radial distribution functions - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_rms.1 b/man/man1/g_rms.1 -index 1cb58ec..4ae7172 100644 ---- a/man/man1/g_rms.1 -+++ b/man/man1/g_rms.1 -@@ -1,8 +1,8 @@ --.TH g_rms 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_rms 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_rms - calculates rmsd's with a reference structure and rmsd matrices - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_rms\fP - .BI "\-s" " topol.tpr " -@@ -40,10 +40,10 @@ g_rms - calculates rmsd's with a reference structure and rmsd matrices - .BI "\-nlevels" " int " - .BI "\-ng" " int " - .SH DESCRIPTION --\&g_rms compares two structures by computing the root mean square --\&deviation (RMSD), the size\-independent 'rho' similarity parameter --\&(rho) or the scaled rho (rhosc), --\&see Maiorov & Crippen, PROTEINS \fB 22\fR, 273 (1995). -+\&\fB g_rms\fR compares two structures by computing the root mean square -+\&deviation (RMSD), the size\-independent rho similarity parameter -+\&(\fB rho\fR) or the scaled rho (\fB rhosc\fR), -+\&see Maiorov & Crippen, Proteins \fB 22\fR, 273 (1995). - \&This is selected by \fB \-what\fR. - - Each structure from a trajectory (\fB \-f\fR) is compared to a -@@ -54,7 +54,7 @@ Each structure from a trajectory (\fB \-f\fR) is compared to a - \&With option \fB \-mir\fR also a comparison with the mirror image of - \&the reference structure is calculated. - \&This is useful as a reference for 'significant' values, see --\&Maiorov & Crippen, PROTEINS \fB 22\fR, 273 (1995). -+\&Maiorov & Crippen, Proteins \fB 22\fR, 273 (1995). - - - \&Option \fB \-prev\fR produces the comparison with a previous frame -@@ -74,10 +74,10 @@ Each structure from a trajectory (\fB \-f\fR) is compared to a - - \&Option \fB \-mw\fR controls whether mass weighting is done or not. - \&If you select the option (default) and --\&supply a valid tpr file masses will be taken from there, --\&otherwise the masses will be deduced from the atommass.dat file in --\&the GROMACS library directory. This is fine for proteins but not --\&necessarily for other molecules. A default mass of 12.011 amu (Carbon) -+\&supply a valid \fB .tpr\fR file masses will be taken from there, -+\&otherwise the masses will be deduced from the \fB atommass.dat\fR file in -+\&\fB GMXLIB\fR. This is fine for proteins, but not -+\&necessarily for other molecules. A default mass of 12.011 amu (carbon) - \&is assigned to unknown atoms. You can check whether this happend by - \&turning on the \fB \-debug\fR flag and inspecting the log file. - -@@ -161,7 +161,7 @@ Each structure from a trajectory (\fB \-f\fR) is compared to a - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_rmsdist.1 b/man/man1/g_rmsdist.1 -index 07721cc..a04194a 100644 ---- a/man/man1/g_rmsdist.1 -+++ b/man/man1/g_rmsdist.1 -@@ -1,8 +1,8 @@ --.TH g_rmsdist 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty" -+.TH g_rmsdist 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_rmsdist - calculates atom pair distances averaged with power \-2, \-3 or \-6 - --.B VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_rmsdist\fP - .BI "\-f" " traj.xtc " -@@ -29,16 +29,16 @@ g_rmsdist - calculates atom pair distances averaged with power \-2, \-3 or \-6 - .BI "\-[no]sumh" "" - .BI "\-[no]pbc" "" - .SH DESCRIPTION --\&g_rmsdist computes the root mean square deviation of atom distances, -+\&\fB g_rmsdist\fR computes the root mean square deviation of atom distances, - \&which has the advantage that no fit is needed like in standard RMS --\&deviation as computed by g_rms. -+\&deviation as computed by \fB g_rms\fR. - \&The reference structure is taken from the structure file. --\&The rmsd at time t is calculated as the rms -+\&The RMSD at time t is calculated as the RMS - \&of the differences in distance between atom\-pairs in the reference - \&structure and the structure at time t. - - --\&g_rmsdist can also produce matrices of the rms distances, rms distances -+\&\fB g_rmsdist\fR can also produce matrices of the rms distances, rms distances - \&scaled with the mean distance and the mean distances and matrices with - \&NMR averaged distances (1/r3 and 1/r6 averaging). Finally, lists - \&of atom pairs with 1/r3 and 1/r6 averaged distance below the -@@ -120,7 +120,7 @@ g_rmsdist - calculates atom pair distances averaged with power \-2, \-3 or \-6 - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_rmsf.1 b/man/man1/g_rmsf.1 -index d29a510..943f195 100644 ---- a/man/man1/g_rmsf.1 -+++ b/man/man1/g_rmsf.1 -@@ -1,8 +1,8 @@ --.TH g_rmsf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_rmsf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_rmsf - calculates atomic fluctuations - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_rmsf\fP - .BI "\-f" " traj.xtc " -@@ -27,14 +27,14 @@ g_rmsf - calculates atomic fluctuations - .BI "\-[no]aniso" "" - .BI "\-[no]fit" "" - .SH DESCRIPTION --\&g_rmsf computes the root mean square fluctuation (RMSF, i.e. standard --\&deviation) of atomic positions --\&after (optionally) fitting to a reference frame. -+\&\fB g_rmsf\fR computes the root mean square fluctuation (RMSF, i.e. standard -+\&deviation) of atomic positions in the trajectory (supplied with \fB \-f\fR) -+\&after (optionally) fitting to a reference frame (supplied with \fB \-s\fR). - - - \&With option \fB \-oq\fR the RMSF values are converted to B\-factor --\&values, which are written to a pdb file with the coordinates, of the --\&structure file, or of a pdb file when \fB \-q\fR is specified. -+\&values, which are written to a \fB .pdb\fR file with the coordinates, of the -+\&structure file, or of a \fB .pdb\fR file when \fB \-q\fR is specified. - \&Option \fB \-ox\fR writes the B\-factors to a file with the average - \&coordinates. - -@@ -43,18 +43,18 @@ g_rmsf - calculates atomic fluctuations - \&respect to the reference structure is calculated. - - --\&With the option \fB aniso\fR g_rmsf will compute anisotropic -+\&With the option \fB \-aniso\fR, \fB g_rmsf\fR will compute anisotropic - \&temperature factors and then it will also output average coordinates --\&and a pdb file with ANISOU records (corresonding to the \fB \-oq\fR -+\&and a \fB .pdb\fR file with ANISOU records (corresonding to the \fB \-oq\fR - \&or \fB \-ox\fR option). Please note that the U values --\&are orientation dependent, so before comparison with experimental data -+\&are orientation\-dependent, so before comparison with experimental data - \&you should verify that you fit to the experimental coordinates. - - --\&When a pdb input file is passed to the program and the \fB \-aniso\fR -+\&When a \fB .pdb\fR input file is passed to the program and the \fB \-aniso\fR - \&flag is set - \&a correlation plot of the Uij will be created, if any anisotropic --\&temperature factors are present in the pdb file. -+\&temperature factors are present in the \fB .pdb\fR file. - - - \&With option \fB \-dir\fR the average MSF (3x3) matrix is diagonalized. -@@ -121,7 +121,7 @@ g_rmsf - calculates atomic fluctuations - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_rotacf.1 b/man/man1/g_rotacf.1 -index 3a42027..0285ff0 100644 ---- a/man/man1/g_rotacf.1 -+++ b/man/man1/g_rotacf.1 -@@ -1,8 +1,8 @@ --.TH g_rotacf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_rotacf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_rotacf - calculates the rotational correlation function for molecules - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_rotacf\fP - .BI "\-f" " traj.xtc " -@@ -27,13 +27,13 @@ g_rotacf - calculates the rotational correlation function for molecules - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_rotacf calculates the rotational correlation function -+\&\fB g_rotacf\fR calculates the rotational correlation function - \&for molecules. Three atoms (i,j,k) must be given in the index --\&file, defining two vectors ij and jk. The rotational acf -+\&file, defining two vectors ij and jk. The rotational ACF - \&is calculated as the autocorrelation function of the vector - \&n = ij x jk, i.e. the cross product of the two vectors. - \&Since three atoms span a plane, the order of the three atoms --\&does not matter. Optionally, controlled by the \-d switch, you can -+\&does not matter. Optionally, controlled by the \fB \-d\fR switch, you can - \&calculate the rotational correlation function for linear molecules - \&by specifying two atoms (i,j) in the index file. - \& -@@ -42,15 +42,14 @@ g_rotacf - calculates the rotational correlation function for molecules - \&EXAMPLES - - --\&g_rotacf \-P 1 \-nparm 2 \-fft \-n index \-o rotacf\-x\-P1 --\&\-fa expfit\-x\-P1 \-beginfit 2.5 \-endfit 20.0 -+\&\fB g_rotacf \-P 1 \-nparm 2 \-fft \-n index \-o rotacf\-x\-P1 -+\&\-fa expfit\-x\-P1 \-beginfit 2.5 \-endfit 20.0\fR - - - \&This will calculate the rotational correlation function using a first - \&order Legendre polynomial of the angle of a vector defined by the index --\&file. The correlation function will be fitted from 2.5 ps till 20.0 ps --\&to a two parameter exponential. --\& -+\&file. The correlation function will be fitted from 2.5 ps until 20.0 ps -+\&to a two\-parameter exponential. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -@@ -88,7 +87,7 @@ g_rotacf - calculates the rotational correlation function for molecules - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -109,7 +108,7 @@ g_rotacf - calculates the rotational correlation function for molecules - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_rotmat.1 b/man/man1/g_rotmat.1 -index cf26c4f..36b3282 100644 ---- a/man/man1/g_rotmat.1 -+++ b/man/man1/g_rotmat.1 -@@ -1,8 +1,8 @@ --.TH g_rotmat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty" -+.TH g_rotmat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_rotmat - plots the rotation matrix for fitting to a reference structure - --.B VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_rotmat\fP - .BI "\-f" " traj.xtc " -@@ -22,7 +22,7 @@ g_rotmat - plots the rotation matrix for fitting to a reference structure - .BI "\-[no]fitxy" "" - .BI "\-[no]mw" "" - .SH DESCRIPTION --\&g_rotmat plots the rotation matrix required for least squares fitting -+\&\fB g_rotmat\fR plots the rotation matrix required for least squares fitting - \&a conformation onto the reference conformation provided with - \&\fB \-s\fR. Translation is removed before fitting. - \&The output are the three vectors that give the new directions -@@ -36,7 +36,7 @@ g_rotmat - plots the rotation matrix for fitting to a reference structure - \&determining the orientation of a molecule - \&at an interface, possibly on a trajectory produced with - \&\fB trjconv \-fit rotxy+transxy\fR to remove the rotation --\&in the xy\-plane. -+\&in the \fI x\-y\fR plane. - \& - - -@@ -45,12 +45,12 @@ g_rotmat - plots the rotation matrix for fitting to a reference structure - \&the lowest sum of RMSD's to all other structures is used. - \&Since the computational cost of this procedure grows with - \&the square of the number of frames, the \fB \-skip\fR option --\&can be useful. A full fit or only a fit in the x/y plane can -+\&can be useful. A full fit or only a fit in the \fI x\-y\fR plane can - \&be performed. - \& - - --\&Option \fB \-fitxy\fR fits in the x/y plane before determining -+\&Option \fB \-fitxy\fR fits in the \fI x\-y\fR plane before determining - \&the rotation matrix. - .SH FILES - .BI "\-f" " traj.xtc" -@@ -89,7 +89,7 @@ g_rotmat - plots the rotation matrix for fitting to a reference structure - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -98,7 +98,7 @@ g_rotmat - plots the rotation matrix for fitting to a reference structure - Determine the optimal reference structure: \fB none\fR, \fB xyz\fR or \fB xy\fR - - .BI "\-skip" " int" " 1" -- Use every nr\-th frame for \-ref -+ Use every nr\-th frame for \fB \-ref\fR - - .BI "\-[no]fitxy" "no " - Fit the x/y rotation before determining the rotation -diff --git a/man/man1/g_saltbr.1 b/man/man1/g_saltbr.1 -index 7b845e4..505774f 100644 ---- a/man/man1/g_saltbr.1 -+++ b/man/man1/g_saltbr.1 -@@ -1,8 +1,8 @@ --.TH g_saltbr 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_saltbr 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_saltbr - computes salt bridges - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_saltbr\fP - .BI "\-f" " traj.xtc " -@@ -16,15 +16,16 @@ g_saltbr - computes salt bridges - .BI "\-t" " real " - .BI "\-[no]sep" "" - .SH DESCRIPTION --\&g_saltbr plots the distance between all combination of charged groups -+\&\fB g_saltbr\fR plots the distance between all combination of charged groups - \&as a function of time. The groups are combined in different ways. --\&A minimum distance can be given, (eg. the cut\-off), then groups -+\&A minimum distance can be given (i.e. a cut\-off), such that groups - \&that are never closer than that distance will not be plotted. - --\&Output will be in a number of fixed filenames, min\-min.xvg, plus\-min.xvg --\&and plus\-plus.xvg, or files for every individual ion\-pair if the \fB \-sep\fR --\&option is selected. In this case files are named as \fB sb\-ResnameResnr\-Atomnr\fR. --\&There may be many such files. -+ -+\&Output will be in a number of fixed filenames, \fB min\-min.xvg\fR, \fB plus\-min.xvg\fR -+\&and \fB plus\-plus.xvg\fR, or files for every individual ion pair if the \fB \-sep\fR -+\&option is selected. In this case, files are named as \fB sb\-(Resname)(Resnr)\-(Atomnr)\fR. -+\&There may be \fB many\fR such files. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -diff --git a/man/man1/g_sas.1 b/man/man1/g_sas.1 -index abfca19..3f5e400 100644 ---- a/man/man1/g_sas.1 -+++ b/man/man1/g_sas.1 -@@ -1,8 +1,8 @@ --.TH g_sas 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_sas 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_sas - computes solvent accessible surface area - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_sas\fP - .BI "\-f" " traj.xtc " -@@ -31,17 +31,17 @@ g_sas - computes solvent accessible surface area - .BI "\-[no]prot" "" - .BI "\-dgs" " real " - .SH DESCRIPTION --\&g_sas computes hydrophobic, hydrophilic and total solvent accessible surface area. --\&As a side effect the Connolly surface can be generated as well in --\&a pdb file where the nodes are represented as atoms and the vertices -+\&\fB g_sas\fR computes hydrophobic, hydrophilic and total solvent accessible surface area. -+\&As a side effect, the Connolly surface can be generated as well in -+\&a \fB .pdb\fR file where the nodes are represented as atoms and the vertices - \&connecting the nearest nodes as CONECT records. - \&The program will ask for a group for the surface calculation - \&and a group for the output. The calculation group should always - \&consists of all the non\-solvent atoms in the system. - \&The output group can be the whole or part of the calculation group. --\&The area can be plotted -+\&The average and standard deviation of the area over the trajectory can be plotted - \&per residue and atom as well (options \fB \-or\fR and \fB \-oa\fR). --\&In combination with the latter option an \fB itp\fR file can be -+\&In combination with the latter option an \fB .itp\fR file can be - \&generated (option \fB \-i\fR) - \&which can be used to restrain surface atoms. - -@@ -55,9 +55,9 @@ g_sas - computes solvent accessible surface area - \&Please consider whether the normal probe radius is appropriate - \&in this case or whether you would rather use e.g. 0. It is good - \&to keep in mind that the results for volume and density are very --\&approximate, in e.g. ice Ih one can easily fit water molecules in the --\&pores which would yield too low volume, too high surface area and too --\&high density. -+\&approximate. For example, in ice Ih, one can easily fit water molecules in the -+\&pores which would yield a volume that is too low, and surface area and density -+\&that are both too high. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -@@ -115,7 +115,7 @@ g_sas - computes solvent accessible surface area - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -139,10 +139,10 @@ g_sas - computes solvent accessible surface area - Take periodicity into account - - .BI "\-[no]prot" "yes " -- Output the protein to the connelly pdb file too -+ Output the protein to the Connelly \fB .pdb\fR file too - - .BI "\-dgs" " real" " 0 " -- default value for solvation free energy per area (kJ/mol/nm2) -+ Default value for solvation free energy per area (kJ/mol/nm2) - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_select.1 b/man/man1/g_select.1 -index ed8ce52..5be4198 100644 ---- a/man/man1/g_select.1 -+++ b/man/man1/g_select.1 -@@ -1,8 +1,8 @@ --.TH g_select 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_select 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_select - selects groups of atoms based on flexible textual selections - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_select\fP - .BI "\-f" " traj.xtc " -@@ -31,7 +31,7 @@ g_select - selects groups of atoms based on flexible textual selections - .BI "\-[no]cfnorm" "" - .BI "\-resnr" " enum " - .SH DESCRIPTION --\&g_select writes out basic data about dynamic selections. -+\&\fB g_select\fR writes out basic data about dynamic selections. - \&It can be used for some simple analyses, or the output can - \&be combined with output from other programs and/or external - \&analysis programs to calculate more complex things. -@@ -66,7 +66,7 @@ g_select - selects groups of atoms based on flexible textual selections - - - \&With \fB \-on\fR, the selected atoms are written as a index file --\&compatible with make_ndx and the analyzing tools. Each selection -+\&compatible with \fB make_ndx\fR and the analyzing tools. Each selection - \&is written as a selection group and for dynamic selections a - \&group is written for each frame. - -diff --git a/man/man1/g_sgangle.1 b/man/man1/g_sgangle.1 -index c7d48d2..d4f551e 100644 ---- a/man/man1/g_sgangle.1 -+++ b/man/man1/g_sgangle.1 -@@ -1,8 +1,8 @@ --.TH g_sgangle 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_sgangle 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_sgangle - computes the angle and distance between two groups - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_sgangle\fP - .BI "\-f" " traj.xtc " -@@ -26,10 +26,10 @@ g_sgangle - computes the angle and distance between two groups - \&Compute the angle and distance between two groups. - \&The groups are defined by a number of atoms given in an index file and - \&may be two or three atoms in size. --\&If \-one is set, only one group should be specified in the index -+\&If \fB \-one\fR is set, only one group should be specified in the index - \&file and the angle between this group at time 0 and t will be computed. - \&The angles calculated depend on the order in which the atoms are --\&given. Giving for instance 5 6 will rotate the vector 5\-6 with -+\&given. Giving, for instance, 5 6 will rotate the vector 5\-6 with - \&180 degrees compared to giving 6 5. - - If three atoms are given, -@@ -41,13 +41,13 @@ If three atoms are given, - - \&Here is what some of the file options do: - --\&\-oa: Angle between the two groups specified in the index file. If a group contains three atoms the normal to the plane defined by those three atoms will be used. If a group contains two atoms, the vector defined by those two atoms will be used. -+\&\fB \-oa\fR: Angle between the two groups specified in the index file. If a group contains three atoms the normal to the plane defined by those three atoms will be used. If a group contains two atoms, the vector defined by those two atoms will be used. - --\&\-od: Distance between two groups. Distance is taken from the center of one group to the center of the other group. -+\&\fB \-od\fR: Distance between two groups. Distance is taken from the center of one group to the center of the other group. - --\&\-od1: If one plane and one vector is given, the distances for each of the atoms from the center of the plane is given separately. -+\&\fB \-od1\fR: If one plane and one vector is given, the distances for each of the atoms from the center of the plane is given separately. - --\&\-od2: For two planes this option has no meaning. -+\&\fB \-od2\fR: For two planes this option has no meaning. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -@@ -97,7 +97,7 @@ If three atoms are given, - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -106,7 +106,7 @@ If three atoms are given, - Only one group compute angle between vector at time zero and time t - - .BI "\-[no]z" "no " -- Use the Z\-axis as reference -+ Use the \fI z\fR\-axis as reference - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_sham.1 b/man/man1/g_sham.1 -index 30d01a1..168cf7b 100644 ---- a/man/man1/g_sham.1 -+++ b/man/man1/g_sham.1 -@@ -1,8 +1,8 @@ --.TH g_sham 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_sham 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_sham - read/write xmgr and xvgr data sets - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_sham\fP - .BI "\-f" " graph.xvg " -@@ -45,19 +45,19 @@ g_sham - read/write xmgr and xvgr data sets - .BI "\-nlevels" " int " - .BI "\-mname" " string " - .SH DESCRIPTION --\&g_sham makes multi\-dimensional free\-energy, enthalpy and entropy plots. --\&g_sham reads one or more xvg files and analyzes data sets. --\&g_sham basic purpose is plotting Gibbs free energy landscapes -+\&\fB g_sham\fR makes multi\-dimensional free\-energy, enthalpy and entropy plots. -+\&\fB g_sham\fR reads one or more \fB .xvg\fR files and analyzes data sets. -+\&The basic purpose of \fB g_sham\fR is to plot Gibbs free energy landscapes - \&(option \fB \-ls\fR) --\&by Bolzmann inverting multi\-dimensional histograms (option \fB \-lp\fR) -+\&by Bolzmann inverting multi\-dimensional histograms (option \fB \-lp\fR), - \&but it can also - \&make enthalpy (option \fB \-lsh\fR) and entropy (option \fB \-lss\fR) - \&plots. The histograms can be made for any quantities the user supplies. - \&A line in the input file may start with a time --\&(see option \fB \-time\fR) and any number of y values may follow. -+\&(see option \fB \-time\fR) and any number of \fI y\fR\-values may follow. - \&Multiple sets can also be - \&read when they are separated by & (option \fB \-n\fR), --\&in this case only one y value is read from each line. -+\&in this case only one \fI y\fR\-value is read from each line. - \&All lines starting with and @ are skipped. - \& - -@@ -71,23 +71,23 @@ g_sham - read/write xmgr and xvgr data sets - - \&Option \fB \-ene\fR can be used to supply a file with energies. - \&These energies are used as a weighting function in the single --\&histogram analysis method due to Kumar et. al. When also temperatures --\&are supplied (as a second column in the file) an experimental -+\&histogram analysis method by Kumar et al. When temperatures -+\&are supplied (as a second column in the file), an experimental - \&weighting scheme is applied. In addition the vales - \&are used for making enthalpy and entropy plots. - \& - - --\&With option \fB \-dim\fR dimensions can be gives for distances. -+\&With option \fB \-dim\fR, dimensions can be gives for distances. - \&When a distance is 2\- or 3\-dimensional, the circumference or surface - \&sampled by two particles increases with increasing distance. - \&Depending on what one would like to show, one can choose to correct - \&the histogram and free\-energy for this volume effect. --\&The probability is normalized by r and r2 for a dimension of 2 and 3 -+\&The probability is normalized by r and r2 for dimensions of 2 and 3, - \&respectively. - \&A value of \-1 is used to indicate an angle in degrees between two - \&vectors: a sin(angle) normalization will be applied. --\&Note that for angles between vectors the inner\-product or cosine -+\&\fB Note\fR that for angles between vectors the inner\-product or cosine - \&is the natural quantity to use, as it will produce bins of the same - \&volume. - .SH FILES -@@ -158,7 +158,7 @@ g_sham - read/write xmgr and xvgr data sets - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_sigeps.1 b/man/man1/g_sigeps.1 -index 24bf17d..7934223 100644 ---- a/man/man1/g_sigeps.1 -+++ b/man/man1/g_sigeps.1 -@@ -1,8 +1,8 @@ --.TH g_sigeps 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_sigeps 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_sigeps - convert c6/12 or c6/cn combinations to and from sigma/epsilon - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_sigeps\fP - .BI "\-o" " potje.xvg " -@@ -23,10 +23,10 @@ g_sigeps - convert c6/12 or c6/cn combinations to and from sigma/epsilon - .BI "\-qj" " real " - .BI "\-sigfac" " real " - .SH DESCRIPTION --\&Sigeps is a simple utility that converts c6/c12 or c6/cn combinations -+\&\fB g_sigeps\fR is a simple utility that converts C6/C12 or C6/Cn combinations - \&to sigma and epsilon, or vice versa. It can also plot the potential --\&in file. In addition it makes an approximation of a Buckingham potential --\&to a Lennard Jones potential. -+\&in file. In addition, it makes an approximation of a Buckingham potential -+\&to a Lennard\-Jones potential. - .SH FILES - .BI "\-o" " potje.xvg" - .B Output -@@ -43,7 +43,7 @@ g_sigeps - convert c6/12 or c6/cn combinations to and from sigma/epsilon - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_sorient.1 b/man/man1/g_sorient.1 -index 9289f26..8bd1cd8 100644 ---- a/man/man1/g_sorient.1 -+++ b/man/man1/g_sorient.1 -@@ -1,8 +1,8 @@ --.TH g_sorient 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_sorient 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_sorient - analyzes solvent orientation around solutes - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_sorient\fP - .BI "\-f" " traj.xtc " -@@ -29,17 +29,19 @@ g_sorient - analyzes solvent orientation around solutes - .BI "\-rbin" " real " - .BI "\-[no]pbc" "" - .SH DESCRIPTION --\&g_sorient analyzes solvent orientation around solutes. -+\&\fB g_sorient\fR analyzes solvent orientation around solutes. - \&It calculates two angles between the vector from one or more - \&reference positions to the first atom of each solvent molecule: - -+ - \&theta1: the angle with the vector from the first atom of the solvent - \&molecule to the midpoint between atoms 2 and 3. - - \&theta2: the angle with the normal of the solvent plane, defined by the --\&same three atoms, or when the option \fB \-v23\fR is set -+\&same three atoms, or, when the option \fB \-v23\fR is set, - \&the angle with the vector between atoms 2 and 3. - -+ - \&The reference can be a set of atoms or - \&the center of mass of a set of atoms. The group of solvent atoms should - \&consist of 3 atoms per solvent molecule. -@@ -115,7 +117,7 @@ g_sorient - analyzes solvent orientation around solutes - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_spatial.1 b/man/man1/g_spatial.1 -index cab6fbc..46439a6 100644 ---- a/man/man1/g_spatial.1 -+++ b/man/man1/g_spatial.1 -@@ -1,8 +1,8 @@ --.TH g_spatial 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_spatial 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME --g_spatial - calculates the spatial distribution function (more control than g_sdf) -+g_spatial - calculates the spatial distribution function - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_spatial\fP - .BI "\-s" " topol.tpr " -@@ -21,57 +21,57 @@ g_spatial - calculates the spatial distribution function (more control than g_sd - .BI "\-bin" " real " - .BI "\-nab" " int " - .SH DESCRIPTION --\&g_spatial calculates the spatial distribution function and -+\&\fB g_spatial\fR calculates the spatial distribution function and - \&outputs it in a form that can be read by VMD as Gaussian98 cube format. --\&This was developed from template.c (gromacs\-3.3). --\&For a system of 32K atoms and a 50ns trajectory, the SDF can be generated -+\&This was developed from template.c (GROMACS\-3.3). -+\&For a system of 32,000 atoms and a 50 ns trajectory, the SDF can be generated - \&in about 30 minutes, with most of the time dedicated to the two runs through --\&trjconv that are required to center everything properly. --\&This also takes a whole bunch of space (3 copies of the xtc file). -+\&\fB trjconv\fR that are required to center everything properly. -+\&This also takes a whole bunch of space (3 copies of the \fB .xtc\fR file). - \&Still, the pictures are pretty and very informative when the fitted selection is properly made. --\&3\-4 atoms in a widely mobile group like a free amino acid in solution works -+\&3\-4 atoms in a widely mobile group (like a free amino acid in solution) works - \&well, or select the protein backbone in a stable folded structure to get the SDF - \&of solvent and look at the time\-averaged solvation shell. --\&It is also possible using this program to generate the SDF based on some arbitrarty --\&Cartesian coordinate. To do that, simply omit the preliminary trjconv steps. -+\&It is also possible using this program to generate the SDF based on some arbitrary -+\&Cartesian coordinate. To do that, simply omit the preliminary \fB trjconv\fR steps. - - \&USAGE: - --\&1. Use make_ndx to create a group containing the atoms around which you want the SDF -+\&1. Use \fB make_ndx\fR to create a group containing the atoms around which you want the SDF - --\&2. trjconv \-s a.tpr \-f a.xtc \-o b.xtc \-center tric \-ur compact \-pbc none -+\&2. \fB trjconv \-s a.tpr \-f a.xtc \-o b.xtc \-center tric \-ur compact \-pbc none\fR - --\&3. trjconv \-s a.tpr \-f b.xtc \-o c.xtc \-fit rot+trans -+\&3. \fB trjconv \-s a.tpr \-f b.xtc \-o c.xtc \-fit rot+trans\fR - --\&4. run g_spatial on the xtc output of step 3. -+\&4. run \fB g_spatial\fR on the \fB .xtc\fR output of step 3. - --\&5. Load grid.cube into VMD and view as an isosurface. -+\&5. Load \fB grid.cube\fR into VMD and view as an isosurface. - --\&*** Systems such as micelles will require trjconv \-pbc cluster between steps 1 and 2 -+\&\fB Note\fR that systems such as micelles will require \fB trjconv \-pbc cluster\fR between steps 1 and 2 - --\&WARNINGS: -+\&WARNINGS: - - \&The SDF will be generated for a cube that contains all bins that have some non\-zero occupancy. --\&However, the preparatory \-fit rot+trans option to trjconv implies that your system will be rotating -+\&However, the preparatory \fB \-fit rot+trans\fR option to \fB trjconv\fR implies that your system will be rotating - \&and translating in space (in order that the selected group does not). Therefore the values that are - \&returned will only be valid for some region around your central group/coordinate that has full overlap - \&with system volume throughout the entire translated/rotated system over the course of the trajectory. - \&It is up to the user to ensure that this is the case. - --\&BUGS: -+\&BUGS: - - \&When the allocated memory is not large enough, a segmentation fault may occur. This is usually detected --\&and the program is halted prior to the fault while displaying a warning message suggesting the use of the \-nab -+\&and the program is halted prior to the fault while displaying a warning message suggesting the use of the \fB \-nab\fR (Number of Additional Bins) - \&option. However, the program does not detect all such events. If you encounter a segmentation fault, run it again --\&with an increased \-nab value. -+\&with an increased \fB \-nab\fR value. - --\&RISKY OPTIONS: -+\&RISKY OPTIONS: - - \&To reduce the amount of space and time required, you can output only the coords --\&that are going to be used in the first and subsequent run through trjconv. --\&However, be sure to set the \-nab option to a sufficiently high value since --\&memory is allocated for cube bins based on the initial coords and the \-nab --\&(Number of Additional Bins) option value. -+\&that are going to be used in the first and subsequent run through \fB trjconv\fR. -+\&However, be sure to set the \fB \-nab\fR option to a sufficiently high value since -+\&memory is allocated for cube bins based on the initial coordinates and the \fB \-nab\fR -+\&option value. - - .SH FILES - .BI "\-s" " topol.tpr" -@@ -106,13 +106,13 @@ g_spatial - calculates the spatial distribution function (more control than g_sd - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-[no]pbc" "no " - Use periodic boundary conditions for computing distances - - .BI "\-[no]div" "yes " -- Calculate and apply the divisor for bin occupancies based on atoms/minimal cube size. Set as TRUE for visualization and as FALSE (\-nodiv) to get accurate counts per frame -+ Calculate and apply the divisor for bin occupancies based on atoms/minimal cube size. Set as TRUE for visualization and as FALSE (\fB \-nodiv\fR) to get accurate counts per frame - - .BI "\-ign" " int" " \-1" - Do not display this number of outer cubes (positive values may reduce boundary speckles; \-1 ensures outer surface is visible) -diff --git a/man/man1/g_spol.1 b/man/man1/g_spol.1 -index 9670024..4aca26b 100644 ---- a/man/man1/g_spol.1 -+++ b/man/man1/g_spol.1 -@@ -1,8 +1,8 @@ --.TH g_spol 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_spol 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_spol - analyzes solvent dipole orientation and polarization around solutes - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_spol\fP - .BI "\-f" " traj.xtc " -@@ -24,7 +24,7 @@ g_spol - analyzes solvent dipole orientation and polarization around solutes - .BI "\-dip" " real " - .BI "\-bw" " real " - .SH DESCRIPTION --\&g_spol analyzes dipoles around a solute; it is especially useful -+\&\fB g_spol\fR analyzes dipoles around a solute; it is especially useful - \&for polarizable water. A group of reference atoms, or a center - \&of mass reference (option \fB \-com\fR) and a group of solvent - \&atoms is required. The program splits the group of solvent atoms -@@ -35,7 +35,7 @@ g_spol - analyzes solvent dipole orientation and polarization around solutes - \&the inner product of the distance vector - \&and the dipole of the solvent molecule is determined. - \&For solvent molecules with net charge (ions), the net charge of the ion --\&is subtracted evenly at all atoms in the selection of each ion. -+\&is subtracted evenly from all atoms in the selection of each ion. - \&The average of these dipole components is printed. - \&The same is done for the polarization, where the average dipole is - \&subtracted from the instantaneous dipole. The magnitude of the average -@@ -79,7 +79,7 @@ g_spol - analyzes solvent dipole orientation and polarization around solutes - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -diff --git a/man/man1/g_tcaf.1 b/man/man1/g_tcaf.1 -index 84bb83f..c208f14 100644 ---- a/man/man1/g_tcaf.1 -+++ b/man/man1/g_tcaf.1 -@@ -1,8 +1,8 @@ --.TH g_tcaf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_tcaf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_tcaf - calculates viscosities of liquids - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_tcaf\fP - .BI "\-f" " traj.trr " -@@ -33,36 +33,36 @@ g_tcaf - calculates viscosities of liquids - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_tcaf computes tranverse current autocorrelations. --\&These are used to estimate the shear viscosity eta. --\&For details see: Palmer, JCP 49 (1994) pp 359\-366. -+\&\fB g_tcaf\fR computes tranverse current autocorrelations. -+\&These are used to estimate the shear viscosity, eta. -+\&For details see: Palmer, Phys. Rev. E 49 (1994) pp 359\-366. - - - \&Transverse currents are calculated using the --\&k\-vectors (1,0,0) and (2,0,0) each also in the y\- and z\-direction, -+\&k\-vectors (1,0,0) and (2,0,0) each also in the \fI y\fR\- and \fI z\fR\-direction, - \&(1,1,0) and (1,\-1,0) each also in the 2 other planes (these vectors - \&are not independent) and (1,1,1) and the 3 other box diagonals (also - \¬ independent). For each k\-vector the sine and cosine are used, in - \&combination with the velocity in 2 perpendicular directions. This gives - \&a total of 16*2*2=64 transverse currents. One autocorrelation is --\&calculated fitted for each k\-vector, which gives 16 tcaf's. Each of --\&these tcaf's is fitted to f(t) = exp(\-v)(cosh(Wv) + 1/W sinh(Wv)), --\&v = \-t/(2 tau), W = sqrt(1 \- 4 tau eta/rho k2), which gives 16 tau's --\&and eta's. The fit weights decay with time as exp(\-t/wt), the tcaf and -+\&calculated fitted for each k\-vector, which gives 16 TCAF's. Each of -+\&these TCAF's is fitted to f(t) = exp(\-v)(cosh(Wv) + 1/W sinh(Wv)), -+\&v = \-t/(2 tau), W = sqrt(1 \- 4 tau eta/rho k2), which gives 16 values of tau -+\&and eta. The fit weights decay with time as exp(\-t/wt), and the TCAF and - \&fit are calculated up to time 5*wt. --\&The eta's should be fitted to 1 \- a eta(k) k2, from which -+\&The eta values should be fitted to 1 \- a eta(k) k2, from which - \&one can estimate the shear viscosity at k=0. - - - \&When the box is cubic, one can use the option \fB \-oc\fR, which --\&averages the tcaf's over all k\-vectors with the same length. -+\&averages the TCAF's over all k\-vectors with the same length. - \&This results in more accurate tcaf's. --\&Both the cubic tcaf's and fits are written to \fB \-oc\fR -+\&Both the cubic TCAF's and fits are written to \fB \-oc\fR - \&The cubic eta estimates are also written to \fB \-ov\fR. - - --\&With option \fB \-mol\fR the transverse current is determined of --\&molecules instead of atoms. In this case the index group should -+\&With option \fB \-mol\fR, the transverse current is determined of -+\&molecules instead of atoms. In this case, the index group should - \&consist of molecule numbers instead of atom numbers. - - -@@ -71,7 +71,7 @@ g_tcaf - calculates viscosities of liquids - \&infinite wavelength. - - --\&NOTE: make sure you write coordinates and velocities often enough. -+\&\fB Note:\fR make sure you write coordinates and velocities often enough. - \&The initial, non\-exponential, part of the autocorrelation function - \&is very important for obtaining a good fit. - .SH FILES -@@ -131,7 +131,7 @@ g_tcaf - calculates viscosities of liquids - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -155,7 +155,7 @@ g_tcaf - calculates viscosities of liquids - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_traj.1 b/man/man1/g_traj.1 -index b1d0f99..3b1d73b 100644 ---- a/man/man1/g_traj.1 -+++ b/man/man1/g_traj.1 -@@ -1,8 +1,8 @@ --.TH g_traj 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_traj 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_traj - plots x, v and f of selected atoms/groups (and more) from a trajectory - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_traj\fP - .BI "\-f" " traj.xtc " -@@ -41,9 +41,10 @@ g_traj - plots x, v and f of selected atoms/groups (and more) from a trajectory - .BI "\-[no]len" "" - .BI "\-[no]fp" "" - .BI "\-bin" " real " -+.BI "\-ctime" " real " - .BI "\-scale" " real " - .SH DESCRIPTION --\&g_traj plots coordinates, velocities, forces and/or the box. -+\&\fB g_traj\fR plots coordinates, velocities, forces and/or the box. - \&With \fB \-com\fR the coordinates, velocities and forces are - \&calculated for the center of mass of each group. - \&When \fB \-mol\fR is set, the numbers in the index file are -@@ -64,15 +65,16 @@ g_traj - plots x, v and f of selected atoms/groups (and more) from a trajectory - - - \&Options \fB \-cv\fR and \fB \-cf\fR write the average velocities --\&and average forces as temperature factors to a pdb file with --\&the average coordinates. The temperature factors are scaled such --\&that the maximum is 10. The scaling can be changed with the option --\&\fB \-scale\fR. To get the velocities or forces of one -+\&and average forces as temperature factors to a \fB .pdb\fR file with -+\&the average coordinates or the coordinates at \fB \-ctime\fR. -+\&The temperature factors are scaled such that the maximum is 10. -+\&The scaling can be changed with the option \fB \-scale\fR. -+\&To get the velocities or forces of one - \&frame set both \fB \-b\fR and \fB \-e\fR to the time of - \&desired frame. When averaging over frames you might need to use - \&the \fB \-nojump\fR option to obtain the correct average coordinates. - \&If you select either of these option the average force and velocity --\&for each atom are written to an xvg file as well -+\&for each atom are written to an \fB .xvg\fR file as well - \&(specified with \fB \-av\fR or \fB \-af\fR). - - -@@ -167,7 +169,7 @@ g_traj - plots x, v and f of selected atoms/groups (and more) from a trajectory - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -205,8 +207,11 @@ g_traj - plots x, v and f of selected atoms/groups (and more) from a trajectory - .BI "\-bin" " real" " 1 " - Binwidth for velocity histogram (nm/ps) - -+.BI "\-ctime" " real" " \-1 " -+ Use frame at this time for x in \fB \-cv\fR and \fB \-cf\fR instead of the average x -+ - .BI "\-scale" " real" " 0 " -- Scale factor for pdb output, 0 is autoscale -+ Scale factor for \fB .pdb\fR output, 0 is autoscale - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_tune_pme.1 b/man/man1/g_tune_pme.1 -index 6601032..fe62f5a 100644 ---- a/man/man1/g_tune_pme.1 -+++ b/man/man1/g_tune_pme.1 -@@ -1,8 +1,8 @@ --.TH g_tune_pme 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_tune_pme 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_tune_pme - time mdrun as a function of PME nodes to optimize settings - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_tune_pme\fP - .BI "\-p" " perf.out " -@@ -65,6 +65,7 @@ g_tune_pme - time mdrun as a function of PME nodes to optimize settings - .BI "\-max" " real " - .BI "\-min" " real " - .BI "\-npme" " enum " -+.BI "\-fix" " int " - .BI "\-upfac" " real " - .BI "\-downfac" " real " - .BI "\-ntpr" " int " -@@ -96,12 +97,12 @@ g_tune_pme - time mdrun as a function of PME nodes to optimize settings - .BI "\-[no]ionize" "" - .SH DESCRIPTION - \&For a given number \fB \-np\fR or \fB \-nt\fR of processors/threads, this program systematically --\× mdrun with various numbers of PME\-only nodes and determines -+\× \fB mdrun\fR with various numbers of PME\-only nodes and determines - \&which setting is fastest. It will also test whether performance can - \&be enhanced by shifting load from the reciprocal to the real space - \&part of the Ewald sum. --\&Simply pass your \fB .tpr\fR file to g_tune_pme together with other options --\&for mdrun as needed. -+\&Simply pass your \fB .tpr\fR file to \fB g_tune_pme\fR together with other options -+\&for \fB mdrun\fR as needed. - - - \&Which executables are used can be set in the environment variables -@@ -109,23 +110,25 @@ g_tune_pme - time mdrun as a function of PME nodes to optimize settings - \&will be used as defaults. Note that for certain MPI frameworks you - \&need to provide a machine\- or hostfile. This can also be passed - \&via the MPIRUN variable, e.g. --\&'export MPIRUN="/usr/local/mpirun \-machinefile hosts"' - - --\&Please call g_tune_pme with the normal options you would pass to --\&mdrun and add \fB \-np\fR for the number of processors to perform the -+\&\fB export MPIRUN="/usr/local/mpirun \-machinefile hosts"\fR -+ -+ -+\&Please call \fB g_tune_pme\fR with the normal options you would pass to -+\&\fB mdrun\fR and add \fB \-np\fR for the number of processors to perform the - \&tests on, or \fB \-nt\fR for the number of threads. You can also add \fB \-r\fR - \&to repeat each test several times to get better statistics. - - --\&g_tune_pme can test various real space / reciprocal space workloads -+\&\fB g_tune_pme\fR can test various real space / reciprocal space workloads - \&for you. With \fB \-ntpr\fR you control how many extra \fB .tpr\fR files will be - \&written with enlarged cutoffs and smaller fourier grids respectively. --\&Typically, the first test (no. 0) will be with the settings from the input --\&\fB .tpr\fR file; the last test (no. \fB ntpr\fR) will have cutoffs multiplied -+\&Typically, the first test (number 0) will be with the settings from the input -+\&\fB .tpr\fR file; the last test (number \fB ntpr\fR) will have cutoffs multiplied - \&by (and at the same time fourier grid dimensions divided by) the scaling --\&factor \fB \-fac\fR (default 1.2). The remaining \fB .tpr\fR files will have equally --\&spaced values inbetween these extremes. Note that you can set \fB \-ntpr\fR to 1 -+\&factor \fB \-fac\fR (default 1.2). The remaining \fB .tpr\fR files will have about -+\&equally\-spaced values in between these extremes. \fB Note\fR that you can set \fB \-ntpr\fR to 1 - \&if you just want to find the optimal number of PME\-only nodes; in that case - \&your input \fB .tpr\fR file will remain unchanged. - -@@ -136,15 +139,15 @@ g_tune_pme - time mdrun as a function of PME nodes to optimize settings - \&are by default reset after 100 steps. For large systems - \&(1M atoms) you may have to set \fB \-resetstep\fR to a higher value. - \&From the 'DD' load imbalance entries in the md.log output file you --\&can tell after how many steps the load is sufficiently balanced. -+\&can tell after how many steps the load is sufficiently balanced. Example call: - --Example call: \fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR -+\fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR - - --\&After calling mdrun several times, detailed performance information --\&is available in the output file perf.out. --\&Note that during the benchmarks a couple of temporary files are written --\&(options \-b*), these will be automatically deleted after each test. -+\&After calling \fB mdrun\fR several times, detailed performance information -+\&is available in the output file \fB perf.out.\fR -+\&\fB Note\fR that during the benchmarks, a couple of temporary files are written -+\&(options \fB \-b\fR*), these will be automatically deleted after each test. - - - \&If you want the simulation to be started automatically with the -@@ -365,7 +368,7 @@ Example call: \fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR - Number of nodes to run the tests on (must be 2 for separate PME nodes) - - .BI "\-npstring" " enum" " \-np" -- Specify the number of processors to $MPIRUN using this string: \fB \-np\fR, \fB \-n\fR or \fB none\fR -+ Specify the number of processors to \fB $MPIRUN\fR using this string: \fB \-np\fR, \fB \-n\fR or \fB none\fR - - .BI "\-nt" " int" " 1" - Number of threads to run the tests on (turns MPI & mpirun off) -@@ -380,7 +383,10 @@ Example call: \fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR - Min fraction of PME nodes to test with - - .BI "\-npme" " enum" " auto" -- Benchmark all possible values for \-npme or just the subset that is expected to perform well: \fB auto\fR, \fB all\fR or \fB subset\fR -+ Benchmark all possible values for \fB \-npme\fR or just the subset that is expected to perform well: \fB auto\fR, \fB all\fR or \fB subset\fR -+ -+.BI "\-fix" " int" " \-2" -+ If = \-1, do not vary the number of PME\-only nodes, instead use this fixed value and only vary rcoulomb and the PME grid spacing. - - .BI "\-upfac" " real" " 1.2 " - Upper limit for rcoulomb scaling factor (Note that rcoulomb upscaling results in fourier grid downscaling) -@@ -389,19 +395,19 @@ Example call: \fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR - Lower limit for rcoulomb scaling factor - - .BI "\-ntpr" " int" " 0" -- Number of tpr files to benchmark. Create these many files with scaling factors ranging from 1.0 to fac. If 1, automatically choose the number of tpr files to test -+ Number of \fB .tpr\fR files to benchmark. Create this many files with scaling factors ranging from 1.0 to fac. If 1, automatically choose the number of \fB .tpr\fR files to test - - .BI "\-four" " real" " 0 " -- Use this fourierspacing value instead of the grid found in the tpr input file. (Spacing applies to a scaling factor of 1.0 if multiple tpr files are written) -+ Use this fourierspacing value instead of the grid found in the \fB .tpr\fR input file. (Spacing applies to a scaling factor of 1.0 if multiple \fB .tpr\fR files are written) - - .BI "\-steps" " step" " 1000" -- Take timings for these many steps in the benchmark runs -+ Take timings for this many steps in the benchmark runs - - .BI "\-resetstep" " int" " 100" -- Let dlb equilibrate these many steps before timings are taken (reset cycle counters after these many steps) -+ Let dlb equilibrate this many steps before timings are taken (reset cycle counters after this many steps) - - .BI "\-simsteps" " step" " \-1" -- If non\-negative, perform these many steps in the real run (overwrite nsteps from tpr, add cpt steps) -+ If non\-negative, perform this many steps in the real run (overwrites nsteps from \fB .tpr\fR, add \fB .cpt\fR steps) - - .BI "\-[no]launch" "no " - Lauch the real simulation after optimization -@@ -467,7 +473,7 @@ Example call: \fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR - Seed for replica exchange, \-1 is generate a seed - - .BI "\-[no]ionize" "no " -- Do a simulation including the effect of an X\-Ray bombardment on your system -+ Do a simulation including the effect of an X\-ray bombardment on your system - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_vanhove.1 b/man/man1/g_vanhove.1 -index 66df424..4008a1a 100644 ---- a/man/man1/g_vanhove.1 -+++ b/man/man1/g_vanhove.1 -@@ -1,8 +1,8 @@ --.TH g_vanhove 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_vanhove 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_vanhove - calculates Van Hove displacement functions - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_vanhove\fP - .BI "\-f" " traj.xtc " -@@ -30,10 +30,10 @@ g_vanhove - calculates Van Hove displacement functions - .BI "\-rt" " real " - .BI "\-ft" " int " - .SH DESCRIPTION --\&g_vanhove computes the Van Hove correlation function. -+\&\fB g_vanhove\fR computes the Van Hove correlation function. - \&The Van Hove G(r,t) is the probability that a particle that is at r0 - \&at time zero can be found at position r0+r at time t. --\&g_vanhove determines G not for a vector r, but for the length of r. -+\&\fB g_vanhove\fR determines G not for a vector r, but for the length of r. - \&Thus it gives the probability that a particle moves a distance of r - \&in time t. - \&Jumps across the periodic boundaries are removed. -@@ -112,7 +112,7 @@ g_vanhove - calculates Van Hove displacement functions - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -127,7 +127,7 @@ g_vanhove - calculates Van Hove displacement functions - Maximum r in the matrix (nm) - - .BI "\-rbin" " real" " 0.01 " -- Binwidth in the matrix and for \-or (nm) -+ Binwidth in the matrix and for \fB \-or\fR (nm) - - .BI "\-mmax" " real" " 0 " - Maximum density in the matrix, 0 is calculate (1/nm) -@@ -136,16 +136,16 @@ g_vanhove - calculates Van Hove displacement functions - Number of levels in the matrix - - .BI "\-nr" " int" " 1" -- Number of curves for the \-or output -+ Number of curves for the \fB \-or\fR output - - .BI "\-fr" " int" " 0" -- Frame spacing for the \-or output -+ Frame spacing for the \fB \-or\fR output - - .BI "\-rt" " real" " 0 " -- Integration limit for the \-ot output (nm) -+ Integration limit for the \fB \-ot\fR output (nm) - - .BI "\-ft" " int" " 0" -- Number of frames in the \-ot output, 0 is plot all -+ Number of frames in the \fB \-ot\fR output, 0 is plot all - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_velacc.1 b/man/man1/g_velacc.1 -index 86c4ab8..6a25e52 100644 ---- a/man/man1/g_velacc.1 -+++ b/man/man1/g_velacc.1 -@@ -1,8 +1,8 @@ --.TH g_velacc 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_velacc 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_velacc - calculates velocity autocorrelation functions - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_velacc\fP - .BI "\-f" " traj.trr " -@@ -27,7 +27,7 @@ g_velacc - calculates velocity autocorrelation functions - .BI "\-beginfit" " real " - .BI "\-endfit" " real " - .SH DESCRIPTION --\&g_velacc computes the velocity autocorrelation function. -+\&\fB g_velacc\fR computes the velocity autocorrelation function. - \&When the \fB \-m\fR option is used, the momentum autocorrelation - \&function is calculated. - -@@ -72,7 +72,7 @@ g_velacc - calculates velocity autocorrelation functions - Only use frame when t MOD dt = first time (ps) - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -93,7 +93,7 @@ g_velacc - calculates velocity autocorrelation functions - Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR - - .BI "\-fitfn" " enum" " none" -- Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR -+ Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR - - .BI "\-ncskip" " int" " 0" - Skip N points in the output file of correlation functions -diff --git a/man/man1/g_wham.1 b/man/man1/g_wham.1 -index 98c591e..ffb9ae4 100644 ---- a/man/man1/g_wham.1 -+++ b/man/man1/g_wham.1 -@@ -1,8 +1,8 @@ --.TH g_wham 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_wham 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_wham - weighted histogram analysis after umbrella sampling - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_wham\fP - .BI "\-ix" " pullx\-files.dat " -@@ -11,10 +11,11 @@ g_wham - weighted histogram analysis after umbrella sampling - .BI "\-ip" " pdo\-files.dat " - .BI "\-o" " profile.xvg " - .BI "\-hist" " histo.xvg " -+.BI "\-oiact" " iact.xvg " -+.BI "\-iiact" " iact\-in.dat " - .BI "\-bsres" " bsResult.xvg " - .BI "\-bsprof" " bsProfs.xvg " - .BI "\-tab" " umb\-pot.dat " --.BI "\-wcorr" " cycl\-corr.xvg " - .BI "\-[no]h" "" - .BI "\-[no]version" "" - .BI "\-nice" " int " -@@ -34,14 +35,15 @@ g_wham - weighted histogram analysis after umbrella sampling - .BI "\-[no]log" "" - .BI "\-unit" " enum " - .BI "\-zprof0" " real " --.BI "\-cycl" " enum " --.BI "\-alpha" " real " --.BI "\-[no]flip" "" --.BI "\-[no]hist\-eq" "" -+.BI "\-[no]cycl" "" -+.BI "\-[no]sym" "" -+.BI "\-[no]ac" "" -+.BI "\-acsig" " real " -+.BI "\-ac\-trestart" " real " - .BI "\-nBootstrap" " int " --.BI "\-bs\-dt" " real " -+.BI "\-bs\-method" " enum " -+.BI "\-bs\-tau" " real " - .BI "\-bs\-seed" " int " --.BI "\-[no]histbs" "" - .BI "\-histbs\-block" " int " - .BI "\-[no]vbs" "" - .SH DESCRIPTION -@@ -51,24 +53,24 @@ g_wham - weighted histogram analysis after umbrella sampling - \&compute a potential of mean force (PMF). - - --\&At present, three input modes are supported: -+\&At present, three input modes are supported. - - \&\fB *\fR With option \fB \-it\fR, the user provides a file which contains the --\& filenames of the umbrella simulation run\-input files (tpr files), --\& AND, with option \-ix, a file which contains filenames of --\& the pullx mdrun output files. The tpr and pullx files must --\& be in corresponding order, i.e. the first tpr created the --\& first pullx, etc. -+\& file names of the umbrella simulation run\-input files (\fB .tpr\fR files), -+\& AND, with option \fB \-ix\fR, a file which contains file names of -+\& the pullx \fB mdrun\fR output files. The \fB .tpr\fR and pullx files must -+\& be in corresponding order, i.e. the first \fB .tpr\fR created the -+\& first pullx, etc. - - \&\fB *\fR Same as the previous input mode, except that the the user --\& provides the pull force ouput file names (pullf.xvg) with option \-if. --\& From the pull force the position in the ubrella potential is --\& computed. This does not work with tabulated umbrella potentials. --\&\fB *\fR With option \fB \-ip\fR, the user provides filenames of (gzipped) pdo files, i.e. --\& the gromacs 3.3 umbrella output files. If you have some unusual --\& reaction coordinate you may also generate your own pdo files and --\& feed them with the \-ip option into to g_wham. The pdo file header --\& must be similar to the folowing: -+\& provides the pull force output file names (\fB pullf.xvg\fR) with option \fB \-if\fR. -+\& From the pull force the position in the umbrella potential is -+\& computed. This does not work with tabulated umbrella potentials. -+\fB *\fR With option \fB \-ip\fR, the user provides file names of (gzipped) \fB .pdo\fR files, i.e. -+\& the GROMACS 3.3 umbrella output files. If you have some unusual reaction coordinate you may also generate your own \fB .pdo\fR files and -+\& feed them with the \fB \-ip\fR option into to \fB g_wham\fR. The \fB .pdo\fR file header -+\& must be similar to the following: -+ - - \&\fB UMBRELLA 3.0 - -@@ -86,95 +88,134 @@ g_wham - weighted histogram analysis after umbrella sampling - - \&\fR - --\& Nr of pull groups, umbrella positions, force constants, and names --\& may (of course) differ. Following the header, a time column and --\& a data columns for each pull group follow (i.e. the displacement --\& with respect to the umbrella center). Up to four pull groups are possible --\& at present. -+ -+\&The number of pull groups, umbrella positions, force constants, and names -+\&may (of course) differ. Following the header, a time column and -+\&a data column for each pull group follows (i.e. the displacement -+\&with respect to the umbrella center). Up to four pull groups are possible -+\&per \fB .pdo\fR file at present. - - - \&By default, the output files are - - \& \fB \-o\fR PMF output file - --\& \fB \-hist\fR histograms output file -+\& \fB \-hist\fR Histograms output file -+ -+\&Always check whether the histograms sufficiently overlap. - - - \&The umbrella potential is assumed to be harmonic and the force constants are --\&read from the tpr or pdo files. If a non\-harmonic umbrella force was applied --\&a tabulated potential can be provied with \-tab. -+\&read from the \fB .tpr\fR or \fB .pdo\fR files. If a non\-harmonic umbrella force was applied -+\&a tabulated potential can be provided with \fB \-tab\fR. - - - \&WHAM OPTIONS -+\-\-\-\-\-\-\-\-\-\-\-\- - -- --\& \fB \-bins\fR Nr of bins used in analysis -+\& \fB \-bins\fR Number of bins used in analysis - - \& \fB \-temp\fR Temperature in the simulations - - \& \fB \-tol\fR Stop iteration if profile (probability) changed less than tolerance - --\& \fB \-auto\fR Automatic determination of boudndaries -+\& \fB \-auto\fR Automatic determination of boundaries - - \& \fB \-min,\-max\fR Boundaries of the profile - --\&The data points which are used --\&to compute the profile can be restricted with options \-b, \-e, and \-dt. --\&Play particularly with \-b to ensure sufficient equilibration in each --\&umbrella window! -- -- --\&With \-log (default) the profile is written in energy units, otherwise (\-nolog) as --\&probability. The unit can be specified with \-unit. With energy output, --\&the energy in the first bin is defined to be zero. If you want the free energy at a different --\&position to be zero, choose with \-zprof0 (useful with bootstrapping, see below). -+\&The data points that are used to compute the profile -+\&can be restricted with options \fB \-b\fR, \fB \-e\fR, and \fB \-dt\fR. -+\&Adjust \fB \-b\fR to ensure sufficient equilibration in each -+\&umbrella window. - - --\&For cyclic (or periodic) reaction coordinates (dihedral angle, channel PMF --\&without osmotic gradient), \-cycl is useful. -+\&With \fB \-log\fR (default) the profile is written in energy units, otherwise -+\&(with \fB \-nolog\fR) as probability. The unit can be specified with \fB \-unit\fR. -+\&With energy output, the energy in the first bin is defined to be zero. -+\&If you want the free energy at a different -+\&position to be zero, set \fB \-zprof0\fR (useful with bootstrapping, see below). - --\&\fB \-cycl yes\fR min and max are assumed to --\&be neighboring points and histogram points outside min and max are mapped into --\&the interval [min,max] (compare histogram output). - --\&\fB \-cycl weighted\fR First, a non\-cyclic profile is computed. Subsequently, --\&periodicity is enforced by adding corrections dG(i) between neighboring bins --\&i and i+1. The correction is chosen proportional to 1/[n(i)*n(i+1)]alpha, where --\&n(i) denotes the total nr of data points in bin i as collected from all histograms. --\&alpha is defined with \-alpha. The corrections are written to the file defined by \-wcorr. --\& (Compare Hub and de Groot, PNAS 105:1198 (2008)) -+\&For cyclic or periodic reaction coordinates (dihedral angle, channel PMF -+\&without osmotic gradient), the option \fB \-cycl\fR is useful. \fB g_wham\fR will make use of the -+\&periodicity of the system and generate a periodic PMF. The first and the last bin of the -+\&reaction coordinate will assumed be be neighbors. - - --\&ERROR ANALYSIS -- --\&Statistical errors may be estimated with bootstrap analysis. Use it with care, --\&otherwise the statistical error may be substantially undererstimated !! -+\&Option \fB \-sym\fR symmetrizes the profile around z=0 before output, -+\&which may be useful for, e.g. membranes. - --\&\fB \-nBootstrap\fR defines the nr of bootstraps. Two bootstrapping modes are supported. - --\&\fB \-histbs\fR Complete histograms are considered as independent data points (default). For each --\&bootstrap, N histograms are randomly chosen from the N given histograms (allowing duplication). --\&To avoid gaps without data along the reaction coordinate blocks of histograms (\-histbs\-block) --\&may be defined. In that case, the given histograms are divided into blocks and --\&only histograms within each block are mixed. Note that the histograms --\&within each block must be representative for all possible histograms, otherwise the --\&statistical error is undererstimated! -+\&AUTOCORRELATIONS -+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- - --\&\fB \-nohistbs\fR The given histograms are used to generate new random histograms, --\&such that the generated data points are distributed according the given histograms. The number --\&of points generated for each bootstrap histogram can be controlled with \-bs\-dt. --\&Note that one data point should be generated for each *independent* point in the given --\&histograms. With the long autocorrelations in MD simulations, this procedure may --\&easily understimate the error! -+\&With \fB \-ac\fR, \fB g_wham\fR estimates the integrated autocorrelation -+\&time (IACT) tau for each umbrella window and weights the respective -+\&window with 1/[1+2*tau/dt]. The IACTs are written -+\&to the file defined with \fB \-oiact\fR. In verbose mode, all -+\&autocorrelation functions (ACFs) are written to \fB hist_autocorr.xvg\fR. -+\&Because the IACTs can be severely underestimated in case of limited -+\&sampling, option \fB \-acsig\fR allows to smooth the IACTs along the -+\&reaction coordinate with a Gaussian (sigma provided with \fB \-acsig\fR, -+\&see output in \fB iact.xvg\fR). Note that the IACTs are estimated by simple -+\&integration of the ACFs while the ACFs are larger 0.05. -+\&If you prefer to compute the IACTs by a more sophisticated (but possibly -+\&less robust) method such as fitting to a double exponential, you can -+\&compute the IACTs with \fB g_analyze\fR and provide them to \fB g_wham\fR with the file -+\&\fB iact\-in.dat\fR (option \fB \-iiact\fR), which should contain one line per -+\&input file (\fB .pdo\fR or pullx/f file) and one column per pull group in the respective file. - --\&Bootstrapping output: - --\&\fB \-bsres\fR Average profile and standard deviations -- --\&\fB \-bsprof\fR All bootstrapping profiles -+\&ERROR ANALYSIS -+\-\-\-\-\-\-\-\-\-\-\-\-\-\- - --\&With \fB \-vbs\fR (verbose bootstrapping), the histograms of each bootstrap are written, and, --\&with \fB \-nohistBS\fR, the cummulants of the histogram. -+\&Statistical errors may be estimated with bootstrap analysis. Use it with care, -+\&otherwise the statistical error may be substantially underestimated. -+\&More background and examples for the bootstrap technique can be found in -+\&Hub, de Groot and Van der Spoel, JCTC (2010) 6: 3713\-3720. -+ -+\&\fB \-nBootstrap\fR defines the number of bootstraps (use, e.g., 100). -+\&Four bootstrapping methods are supported and -+\&selected with \fB \-bs\-method\fR. -+ -+\& (1) \fB b\-hist\fR Default: complete histograms are considered as independent -+\&data points, and the bootstrap is carried out by assigning random weights to the -+\&histograms ("Bayesian bootstrap"). Note that each point along the reaction coordinate -+\&must be covered by multiple independent histograms (e.g. 10 histograms), otherwise the -+\&statistical error is underestimated. -+ -+\& (2) \fB hist\fR Complete histograms are considered as independent data points. -+\&For each bootstrap, N histograms are randomly chosen from the N given histograms -+\&(allowing duplication, i.e. sampling with replacement). -+\&To avoid gaps without data along the reaction coordinate blocks of histograms -+\&(\fB \-histbs\-block\fR) may be defined. In that case, the given histograms are -+\÷d into blocks and only histograms within each block are mixed. Note that -+\&the histograms within each block must be representative for all possible histograms, -+\&otherwise the statistical error is underestimated. -+ -+\& (3) \fB traj\fR The given histograms are used to generate new random trajectories, -+\&such that the generated data points are distributed according the given histograms -+\&and properly autocorrelated. The autocorrelation time (ACT) for each window must be -+\&known, so use \fB \-ac\fR or provide the ACT with \fB \-iiact\fR. If the ACT of all -+\&windows are identical (and known), you can also provide them with \fB \-bs\-tau\fR. -+\&Note that this method may severely underestimate the error in case of limited sampling, -+\&that is if individual histograms do not represent the complete phase space at -+\&the respective positions. -+ -+\& (4) \fB traj\-gauss\fR The same as method \fB traj\fR, but the trajectories are -+\¬ bootstrapped from the umbrella histograms but from Gaussians with the average -+\&and width of the umbrella histograms. That method yields similar error estimates -+\&like method \fB traj\fR. -+ -+Bootstrapping output: -+ -+\& \fB \-bsres\fR Average profile and standard deviations -+ -+\& \fB \-bsprof\fR All bootstrapping profiles -+ -+\&With \fB \-vbs\fR (verbose bootstrapping), the histograms of each bootstrap are written, -+\&and, with bootstrap method \fB traj\fR, the cumulative distribution functions of -+\&the histograms. - .SH FILES - .BI "\-ix" " pullx\-files.dat" - .B Input, Opt. -@@ -200,6 +241,14 @@ g_wham - weighted histogram analysis after umbrella sampling - .B Output - xvgr/xmgr file - -+.BI "\-oiact" " iact.xvg" -+.B Output, Opt. -+ xvgr/xmgr file -+ -+.BI "\-iiact" " iact\-in.dat" -+.B Input, Opt. -+ Generic data file -+ - .BI "\-bsres" " bsResult.xvg" - .B Output, Opt. - xvgr/xmgr file -@@ -212,10 +261,6 @@ g_wham - weighted histogram analysis after umbrella sampling - .B Input, Opt. - Generic data file - --.BI "\-wcorr" " cycl\-corr.xvg" --.B Input, Opt. -- xvgr/xmgr file -- - .SH OTHER OPTIONS - .BI "\-[no]h" "no " - Print help info and quit -@@ -236,7 +281,7 @@ g_wham - weighted histogram analysis after umbrella sampling - Maximum coordinate in profile - - .BI "\-[no]auto" "yes " -- determine min and max automatically -+ Determine min and max automatically - - .BI "\-bins" " int" " 200" - Number of bins in profile -@@ -248,13 +293,13 @@ g_wham - weighted histogram analysis after umbrella sampling - Tolerance - - .BI "\-[no]v" "no " -- verbose mode -+ Verbose mode - - .BI "\-b" " real" " 50 " -- first time to analyse (ps) -+ First time to analyse (ps) - - .BI "\-e" " real" " 1e+20 " -- last time to analyse (ps) -+ Last time to analyse (ps) - - .BI "\-dt" " real" " 0 " - Analyse only every dt ps -@@ -263,46 +308,49 @@ g_wham - weighted histogram analysis after umbrella sampling - Write histograms and exit - - .BI "\-[no]boundsonly" "no " -- Determine min and max and exit (with \-auto) -+ Determine min and max and exit (with \fB \-auto\fR) - - .BI "\-[no]log" "yes " - Calculate the log of the profile before printing - - .BI "\-unit" " enum" " kJ" -- energy unit in case of log output: \fB kJ\fR, \fB kCal\fR or \fB kT\fR -+ Energy unit in case of log output: \fB kJ\fR, \fB kCal\fR or \fB kT\fR - - .BI "\-zprof0" " real" " 0 " -- Define profile to 0.0 at this position (with \-log) -+ Define profile to 0.0 at this position (with \fB \-log\fR) - --.BI "\-cycl" " enum" " no" -- Create cyclic/periodic profile. Assumes min and max are the same point.: \fB no\fR, \fB yes\fR or \fB weighted\fR -+.BI "\-[no]cycl" "no " -+ Create cyclic/periodic profile. Assumes min and max are the same point. - --.BI "\-alpha" " real" " 2 " -- for '\-cycl weighted', set parameter alpha -+.BI "\-[no]sym" "no " -+ Symmetrize profile around z=0 - --.BI "\-[no]flip" "no " -- Combine halves of profile (not supported) -+.BI "\-[no]ac" "no " -+ Calculate integrated autocorrelation times and use in wham - --.BI "\-[no]hist\-eq" "no " -- Enforce equal weight for all histograms. (Non\-Weighed\-HAM) -+.BI "\-acsig" " real" " 0 " -+ Smooth autocorrelation times along reaction coordinate with Gaussian of this sigma -+ -+.BI "\-ac\-trestart" " real" " 1 " -+ When computing autocorrelation functions, restart computing every .. (ps) - - .BI "\-nBootstrap" " int" " 0" -- nr of bootstraps to estimate statistical uncertainty -+ nr of bootstraps to estimate statistical uncertainty (e.g., 200) - --.BI "\-bs\-dt" " real" " 0 " -- timestep for synthetic bootstrap histograms (ps). Ensure independent data points! -+.BI "\-bs\-method" " enum" " b\-hist" -+ Bootstrap method: \fB b\-hist\fR, \fB hist\fR, \fB traj\fR or \fB traj\-gauss\fR - --.BI "\-bs\-seed" " int" " \-1" -- seed for bootstrapping. (\-1 = use time) -+.BI "\-bs\-tau" " real" " 0 " -+ Autocorrelation time (ACT) assumed for all histograms. Use option \fB \-ac\fR if ACT is unknown. - --.BI "\-[no]histbs" "yes " -- In bootstrapping, consider complete histograms as one data point. Accounts better for long autocorrelations. -+.BI "\-bs\-seed" " int" " \-1" -+ Seed for bootstrapping. (\-1 = use time) - - .BI "\-histbs\-block" " int" " 8" -- when mixin histograms only mix within blocks of \-histBS_block. -+ When mixing histograms only mix within blocks of \fB \-histbs\-block\fR. - - .BI "\-[no]vbs" "no " -- verbose bootstrapping. Print the cummulants and a histogram file for each bootstrap. -+ Verbose bootstrapping. Print the CDFs and a histogram file for each bootstrap. - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_wheel.1 b/man/man1/g_wheel.1 -index 7d90b5c..4f9a6ec 100644 ---- a/man/man1/g_wheel.1 -+++ b/man/man1/g_wheel.1 -@@ -1,8 +1,8 @@ --.TH g_wheel 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_wheel 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_wheel - plots helical wheels - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_wheel\fP - .BI "\-f" " nnnice.dat " -@@ -15,9 +15,9 @@ g_wheel - plots helical wheels - .BI "\-T" " string " - .BI "\-[no]nn" "" - .SH DESCRIPTION --\&wheel plots a helical wheel representation of your sequence. --\&The input sequence is in the .dat file where the first line contains --\&the number of residues and each consecutive line contains a residuename. -+\&\fB g_wheel\fR plots a helical wheel representation of your sequence. -+\&The input sequence is in the \fB .dat\fR file where the first line contains -+\&the number of residues and each consecutive line contains a residue name. - .SH FILES - .BI "\-f" " nnnice.dat" - .B Input -diff --git a/man/man1/g_x2top.1 b/man/man1/g_x2top.1 -index 321bb87..b99fc16 100644 ---- a/man/man1/g_x2top.1 -+++ b/man/man1/g_x2top.1 -@@ -1,8 +1,8 @@ --.TH g_x2top 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_x2top 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_x2top - generates a primitive topology from coordinates - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_x2top\fP - .BI "\-f" " conf.gro " -@@ -27,11 +27,11 @@ g_x2top - generates a primitive topology from coordinates - .BI "\-kt" " real " - .BI "\-kp" " real " - .SH DESCRIPTION --\&x2top generates a primitive topology from a coordinate file. -+\&\fB g_x2top\fR generates a primitive topology from a coordinate file. - \&The program assumes all hydrogens are present when defining - \&the hybridization from the atom name and the number of bonds. --\&The program can also make an rtp entry, which you can then add --\&to the rtp database. -+\&The program can also make an \fB .rtp\fR entry, which you can then add -+\&to the \fB .rtp\fR database. - - - \&When \fB \-param\fR is set, equilibrium distances and angles -@@ -49,11 +49,11 @@ g_x2top - generates a primitive topology from coordinates - - - \&The corresponding data files can be found in the library directory --\&with name atomname2type.n2t. Check chapter 5 of the manual for more --\&information about file formats. By default the forcefield selection -+\&with name \fB atomname2type.n2t\fR. Check Chapter 5 of the manual for more -+\&information about file formats. By default, the force field selection - \&is interactive, but you can use the \fB \-ff\fR option to specify - \&one of the short names above on the command line instead. In that --\&case pdb2gmx just looks for the corresponding file. -+\&case \fB g_x2top\fR just looks for the corresponding file. - - - .SH FILES -@@ -107,7 +107,7 @@ g_x2top - generates a primitive topology from coordinates - Use periodic boundary conditions. - - .BI "\-[no]pdbq" "no " -- Use the B\-factor supplied in a pdb file for the atomic charges -+ Use the B\-factor supplied in a \fB .pdb\fR file for the atomic charges - - .BI "\-[no]param" "yes " - Print parameters in the output -@@ -131,7 +131,7 @@ g_x2top - generates a primitive topology from coordinates - - \- No improper dihedrals are generated - --\- The atoms to atomtype translation table is incomplete (atomname2type.n2t files in the data directory). Please extend it and send the results back to the GROMACS crew. -+\- The atoms to atomtype translation table is incomplete (\fB atomname2type.n2t\fR file in the data directory). Please extend it and send the results back to the GROMACS crew. - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/g_xrama.1 b/man/man1/g_xrama.1 -index c0c0efc..6f741e9 100644 ---- a/man/man1/g_xrama.1 -+++ b/man/man1/g_xrama.1 -@@ -1,8 +1,8 @@ --.TH g_xrama 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH g_xrama 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - g_xrama - shows animated Ramachandran plots - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3g_xrama\fP - .BI "\-f" " traj.xtc " -@@ -14,15 +14,15 @@ g_xrama - shows animated Ramachandran plots - .BI "\-e" " time " - .BI "\-dt" " time " - .SH DESCRIPTION --\&xrama shows a Ramachandran movie, that is, it shows -+\&\fB g_xrama\fR shows a Ramachandran movie, that is, it shows - \&the Phi/Psi angles as a function of time in an X\-Window. - --Static Phi/Psi plots for printing can be made with g_rama. -+Static Phi/Psi plots for printing can be made with \fB g_rama\fR. - - - \&Some of the more common X command line options can be used: - --\&\-bg, \-fg change colors, \-font fontname, changes the font. -+\&\fB \-bg\fR, \fB \-fg\fR change colors, \fB \-font fontname\fR, changes the font. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -diff --git a/man/man1/genbox.1 b/man/man1/genbox.1 -index d374404..c573dbf 100644 ---- a/man/man1/genbox.1 -+++ b/man/man1/genbox.1 -@@ -1,8 +1,8 @@ --.TH genbox 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH genbox 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - genbox - solvates a system - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3genbox\fP - .BI "\-cp" " protein.gro " -@@ -22,14 +22,14 @@ genbox - solvates a system - .BI "\-maxsol" " int " - .BI "\-[no]vel" "" - .SH DESCRIPTION --\&Genbox can do one of 3 things: -+\&\fB genbox\fR can do one of 3 things: - - --\&1) Generate a box of solvent. Specify \-cs and \-box. Or specify \-cs and --\&\-cp with a structure file with a box, but without atoms. -+\&1) Generate a box of solvent. Specify \fB \-cs\fR and \fB \-box\fR. Or specify \fB \-cs\fR and -+\&\fB \-cp\fR with a structure file with a box, but without atoms. - - --\&2) Solvate a solute configuration, eg. a protein, in a bath of solvent -+\&2) Solvate a solute configuration, e.g. a protein, in a bath of solvent - \&molecules. Specify \fB \-cp\fR (solute) and \fB \-cs\fR (solvent). - \&The box specified in the solute coordinate file (\fB \-cp\fR) is used, - \&unless \fB \-box\fR is set. -@@ -38,9 +38,9 @@ genbox - solvates a system - \&to change the box dimensions and center the solute. - \&Solvent molecules are removed from the box where the - \&distance between any atom of the solute molecule(s) and any atom of --\&the solvent molecule is less than the sum of the VanderWaals radii of --\&both atoms. A database (\fB vdwradii.dat\fR) of VanderWaals radii is --\&read by the program, atoms not in the database are -+\&the solvent molecule is less than the sum of the van der Waals radii of -+\&both atoms. A database (\fB vdwradii.dat\fR) of van der Waals radii is -+\&read by the program, and atoms not in the database are - \&assigned a default distance \fB \-vdwd\fR. - \&Note that this option will also influence the distances between - \&solvent molecules if they contain atoms that are not in the database. -@@ -51,11 +51,16 @@ genbox - solvates a system - \&at random positions. - \&The program iterates until \fB nmol\fR molecules - \&have been inserted in the box. To test whether an insertion is --\&successful the same VanderWaals criterium is used as for removal of --\&solvent molecules. When no appropriately --\&sized holes (holes that can hold an extra molecule) are available the -+\&successful the same van der Waals criterium is used as for removal of -+\&solvent molecules. When no appropriately\-sized -+\&holes (holes that can hold an extra molecule) are available, the - \&program tries for \fB \-nmol\fR * \fB \-try\fR times before giving up. --\&Increase \-try if you have several small holes to fill. -+\&Increase \fB \-try\fR if you have several small holes to fill. -+ -+ -+\&If you need to do more than one of the above operations, it can be -+\&best to call \fB genbox\fR separately for each operation, so that -+\&you are sure of the order in which the operations occur. - - - \&The default solvent is Simple Point Charge water (SPC), with coordinates -@@ -81,18 +86,18 @@ genbox - solvates a system - \&longest molecule axis along a box edge. This way the amount of solvent - \&molecules necessary is reduced. - \&It should be kept in mind that this only works for --\&short simulations, as eg. an alpha\-helical peptide in solution can -+\&short simulations, as e.g. an alpha\-helical peptide in solution can - \&rotate over 90 degrees, within 500 ps. In general it is therefore - \&better to make a more or less cubic box. - - --\&Setting \-shell larger than zero will place a layer of water of -+\&Setting \fB \-shell\fR larger than zero will place a layer of water of - \&the specified thickness (nm) around the solute. Hint: it is a good --\&idea to put the protein in the center of a box first (using editconf). -+\&idea to put the protein in the center of a box first (using \fB editconf\fR). - \& - - --\&Finally, genbox will optionally remove lines from your topology file in -+\&Finally, \fB genbox\fR will optionally remove lines from your topology file in - \&which a number of solvent molecules is already added, and adds a - \&line with the total number of solvent molecules in your coordinate file. - .SH FILES -@@ -133,7 +138,7 @@ genbox - solvates a system - no of extra molecules to insert - - .BI "\-try" " int" " 10" -- try inserting \-nmol*\-try times -+ try inserting \fB \-nmol\fR times \fB \-try\fR times - - .BI "\-seed" " int" " 1997" - random generator seed -diff --git a/man/man1/genconf.1 b/man/man1/genconf.1 -index 9757dbc..280008f 100644 ---- a/man/man1/genconf.1 -+++ b/man/man1/genconf.1 -@@ -1,8 +1,8 @@ --.TH genconf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH genconf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - genconf - multiplies a conformation in 'random' orientations - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3genconf\fP - .BI "\-f" " conf.gro " -@@ -22,9 +22,9 @@ genconf - multiplies a conformation in 'random' orientations - .BI "\-maxrot" " vector " - .BI "\-[no]renumber" "" - .SH DESCRIPTION --\&genconf multiplies a given coordinate file by simply stacking them -+\&\fB genconf\fR multiplies a given coordinate file by simply stacking them - \&on top of each other, like a small child playing with wooden blocks. --\&The program makes a grid of \fI user defined\fR -+\&The program makes a grid of \fI user\-defined\fR - \&proportions (\fB \-nbox\fR), - \&and interspaces the grid point with an extra space \fB \-dist\fR. - -@@ -32,7 +32,7 @@ genconf - multiplies a conformation in 'random' orientations - \&When option \fB \-rot\fR is used the program does not check for overlap - \&between molecules on grid points. It is recommended to make the box in - \&the input file at least as big as the coordinates + --\&Van der Waals radius. -+\&van der Waals radius. - - - \&If the optional trajectory file is given, conformations are not -diff --git a/man/man1/genion.1 b/man/man1/genion.1 -index bc535a2..748b7d1 100644 ---- a/man/man1/genion.1 -+++ b/man/man1/genion.1 -@@ -1,8 +1,8 @@ --.TH genion 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH genion 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - genion - generates mono atomic ions on energetically favorable positions - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3genion\fP - .BI "\-s" " topol.tpr " -@@ -29,10 +29,10 @@ genion - generates mono atomic ions on energetically favorable positions - .BI "\-conc" " real " - .BI "\-[no]neutral" "" - .SH DESCRIPTION --\&genion replaces solvent molecules by monoatomic ions at -+\&\fB genion\fR replaces solvent molecules by monoatomic ions at - \&the position of the first atoms with the most favorable electrostatic - \&potential or at random. The potential is calculated on all atoms, using --\&normal GROMACS particle based methods (in contrast to other methods -+\&normal GROMACS particle\-based methods (in contrast to other methods - \&based on solving the Poisson\-Boltzmann equation). - \&The potential is recalculated after every ion insertion. - \&If specified in the run input file, a reaction field, shift function -@@ -45,18 +45,23 @@ genion - generates mono atomic ions on energetically favorable positions - - - \&The ion molecule type, residue and atom names in all force fields --\&are the capitalized element names without sign. Ions which can have --\&multiple charge states get the multiplicilty added, without sign, --\&for the uncommon states only. -+\&are the capitalized element names without sign. This molecule name -+\&should be given with \fB \-pname\fR or \fB \-nname\fR, and the -+\&\fB [molecules]\fR section of your topology updated accordingly, -+\&either by hand or with \fB \-p\fR. Do not use an atom name instead! -+\& -+ -+Ions which can have multiple charge states get the multiplicity -+\&added, without sign, for the uncommon states only. - - - \&With the option \fB \-pot\fR the potential can be written as B\-factors --\&in a pdb file (for visualisation using e.g. rasmol). -+\&in a \fB .pdb\fR file (for visualisation using e.g. Rasmol). - \&The unit of the potential is 1000 kJ/(mol e), the scaling be changed - \&with the \fB \-scale\fR option. - - --\&For larger ions, e.g. sulfate we recommended to use genbox. -+\&For larger ions, e.g. sulfate we recommended using \fB genbox\fR. - .SH FILES - .BI "\-s" " topol.tpr" - .B Input -@@ -127,10 +132,10 @@ genion - generates mono atomic ions on energetically favorable positions - Seed for random number generator - - .BI "\-scale" " real" " 0.001 " -- Scaling factor for the potential for \-pot -+ Scaling factor for the potential for \fB \-pot\fR - - .BI "\-conc" " real" " 0 " -- Specify salt concentration (mol/liter). This will add sufficient ions to reach up to the specified concentration as computed from the volume of the cell in the input tpr file. Overrides the \-np and nn options. -+ Specify salt concentration (mol/liter). This will add sufficient ions to reach up to the specified concentration as computed from the volume of the cell in the input \fB .tpr\fR file. Overrides the \fB \-np\fR and \fB \-nn\fR options. - - .BI "\-[no]neutral" "no " - This option will add enough ions to neutralize the system. In combination with the concentration option a neutral system at a given salt concentration will be generated. -diff --git a/man/man1/genrestr.1 b/man/man1/genrestr.1 -index 68cc920..fde0d40 100644 ---- a/man/man1/genrestr.1 -+++ b/man/man1/genrestr.1 -@@ -1,8 +1,8 @@ --.TH genrestr 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH genrestr 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - genrestr - generates position restraints or distance restraints for index groups - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3genrestr\fP - .BI "\-f" " conf.gro " -@@ -21,9 +21,9 @@ genrestr - generates position restraints or distance restraints for index groups - .BI "\-cutoff" " real " - .BI "\-[no]constr" "" - .SH DESCRIPTION --\&genrestr produces an include file for a topology containing -+\&\fB genrestr\fR produces an include file for a topology containing - \&a list of atom numbers and three force constants for the --\&X, Y and Z direction. A single isotropic force constant may -+\&\fI x\fR\-, \fI y\fR\-, and \fI z\fR\-direction. A single isotropic force constant may - \&be given on the command line instead of three components. - - -@@ -32,17 +32,17 @@ genrestr - generates position restraints or distance restraints for index groups - \&they should be included within the correct \fB [ moleculetype ]\fR - \&block in the topology. Since the atom numbers in every moleculetype - \&in the topology start at 1 and the numbers in the input file for --\&genpr number consecutively from 1, genpr will only produce a useful --\&file for the first molecule. -+\&\fB genrestr\fR number consecutively from 1, \fB genrestr\fR will only -+\&produce a useful file for the first molecule. - - --\&The \-of option produces an index file that can be used for --\&freezing atoms. In this case the input file must be a pdb file. -+\&The \fB \-of\fR option produces an index file that can be used for -+\&freezing atoms. In this case, the input file must be a \fB .pdb\fR file. - - --\&With the \fB \-disre\fR option half a matrix of distance restraints -+\&With the \fB \-disre\fR option, half a matrix of distance restraints - \&is generated instead of position restraints. With this matrix, that --\&one typically would apply to C\-alpha atoms in a protein, one can -+\&one typically would apply to Calpha atoms in a protein, one can - \&maintain the overall conformation of a protein without tieing it to - \&a specific position (as with position restraints). - .SH FILES -@@ -73,10 +73,10 @@ genrestr - generates position restraints or distance restraints for index groups - Set the nicelevel - - .BI "\-fc" " vector" " 1000 1000 1000" -- force constants (kJ mol\-1 nm\-2) -+ force constants (kJ/mol nm2) - - .BI "\-freeze" " real" " 0 " -- if the \-of option or this one is given an index file will be written containing atom numbers of all atoms that have a B\-factor less than the level given here -+ if the \fB \-of\fR option or this one is given an index file will be written containing atom numbers of all atoms that have a B\-factor less than the level given here - - .BI "\-[no]disre" "no " - Generate a distance restraint matrix for all the atoms in index -diff --git a/man/man1/gmxcheck.1 b/man/man1/gmxcheck.1 -index 157080f..08bc3a0 100644 ---- a/man/man1/gmxcheck.1 -+++ b/man/man1/gmxcheck.1 -@@ -1,8 +1,8 @@ --.TH gmxcheck 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH gmxcheck 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - gmxcheck - checks and compares files - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3gmxcheck\fP - .BI "\-f" " traj.xtc " -@@ -26,7 +26,7 @@ gmxcheck - checks and compares files - .BI "\-[no]ab" "" - .BI "\-lastener" " string " - .SH DESCRIPTION --\&gmxcheck reads a trajectory (\fB .trj\fR, \fB .trr\fR or -+\&\fB gmxcheck\fR reads a trajectory (\fB .trj\fR, \fB .trr\fR or - \&\fB .xtc\fR), an energy file (\fB .ene\fR or \fB .edr\fR) - \&or an index file (\fB .ndx\fR) - \&and prints out useful information about them. -@@ -44,11 +44,11 @@ gmxcheck - checks and compares files - \&If an index file, is given its contents will be summarized. - - --\&If both a trajectory and a tpr file are given (with \fB \-s1\fR) -+\&If both a trajectory and a \fB .tpr\fR file are given (with \fB \-s1\fR) - \&the program will check whether the bond lengths defined in the tpr - \&file are indeed correct in the trajectory. If not you may have - \&non\-matching files due to e.g. deshuffling or due to problems with --\&virtual sites. With these flags, gmxcheck provides a quick check for such problems. -+\&virtual sites. With these flags, \fB gmxcheck\fR provides a quick check for such problems. - - - \&The program can compare two run input (\fB .tpr\fR, \fB .tpb\fR or -diff --git a/man/man1/gmxdump.1 b/man/man1/gmxdump.1 -index a1d4442..70daa77 100644 ---- a/man/man1/gmxdump.1 -+++ b/man/man1/gmxdump.1 -@@ -1,8 +1,8 @@ --.TH gmxdump 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH gmxdump 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - gmxdump - makes binary files human readable - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3gmxdump\fP - .BI "\-s" " topol.tpr " -@@ -18,7 +18,7 @@ gmxdump - makes binary files human readable - .BI "\-[no]nr" "" - .BI "\-[no]sys" "" - .SH DESCRIPTION --\&gmxdump reads a run input file (\fB .tpa\fR/\fB .tpr\fR/\fB .tpb\fR), -+\&\fB gmxdump\fR reads a run input file (\fB .tpa\fR/\fB .tpr\fR/\fB .tpb\fR), - \&a trajectory (\fB .trj\fR/\fB .trr\fR/\fB .xtc\fR), an energy - \&file (\fB .ene\fR/\fB .edr\fR), or a checkpoint file (\fB .cpt\fR) - \&and prints that to standard output in a readable format. -@@ -27,7 +27,7 @@ gmxdump - makes binary files human readable - - - \&The program can also preprocess a topology to help finding problems. --\&Note that currently setting GMXLIB is the only way to customize -+\&Note that currently setting \fB GMXLIB\fR is the only way to customize - \&directories used for searching include files. - .SH FILES - .BI "\-s" " topol.tpr" -diff --git a/man/man1/grompp.1 b/man/man1/grompp.1 -index 016ce3e..ff1b121 100644 ---- a/man/man1/grompp.1 -+++ b/man/man1/grompp.1 -@@ -1,8 +1,8 @@ --.TH grompp 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH grompp 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - grompp - makes a run input file - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3grompp\fP - .BI "\-f" " grompp.mdp " -@@ -37,7 +37,7 @@ grompp - makes a run input file - \&for hydrogens and heavy atoms. - \&Then a coordinate file is read and velocities can be generated - \&from a Maxwellian distribution if requested. --\&grompp also reads parameters for the mdrun -+\&\fB grompp\fR also reads parameters for the \fB mdrun\fR - \&(eg. number of MD steps, time step, cut\-off), and others such as - \&NEMD parameters, which are corrected so that the net acceleration - \&is zero. -@@ -45,15 +45,16 @@ grompp - makes a run input file - \&file for the MD program. - - --\&grompp uses the atom names from the topology file. The atom names -+\&\fB grompp\fR uses the atom names from the topology file. The atom names - \&in the coordinate file (option \fB \-c\fR) are only read to generate - \&warnings when they do not match the atom names in the topology. - \&Note that the atom names are irrelevant for the simulation as - \&only the atom types are used for generating interaction parameters. - - --\&grompp uses a built\-in preprocessor to resolve includes, macros --\&etcetera. The preprocessor supports the following keywords: -+\&\fB grompp\fR uses a built\-in preprocessor to resolve includes, macros, -+\&etc. The preprocessor supports the following keywords: -+ - - \&ifdef VARIABLE - -@@ -70,24 +71,20 @@ include "filename" - - \&include filename - -+ - \&The functioning of these statements in your topology may be modulated by --\&using the following two flags in your \fB mdp\fR file: -+\&using the following two flags in your \fB .mdp\fR file: - --\&define = \-DVARIABLE1 \-DVARIABLE2 - --\&include = /home/john/doe -+\&\fB define = \-DVARIABLE1 \-DVARIABLE2 -+ -+\&include = \-I/home/john/doe\fR - - \&For further information a C\-programming textbook may help you out. - \&Specifying the \fB \-pp\fR flag will get the pre\-processed - \&topology file written out so that you can verify its contents. - - --\&If your system does not have a c\-preprocessor, you can still --\&use grompp, but you do not have access to the features --\&from the cpp. Command line options to the c\-preprocessor can be given --\&in the \fB .mdp\fR file. See your local manual (man cpp). -- -- - \&When using position restraints a file with restraint coordinates - \&can be supplied with \fB \-r\fR, otherwise restraining will be done - \&with respect to the conformation from the \fB \-c\fR option. -@@ -98,26 +95,26 @@ include "filename" - - \&Starting coordinates can be read from trajectory with \fB \-t\fR. - \&The last frame with coordinates and velocities will be read, --\&unless the \fB \-time\fR option is used. -+\&unless the \fB \-time\fR option is used. Only if this information -+\&is absent will the coordinates in the \fB \-c\fR file be used. - \&Note that these velocities will not be used when \fB gen_vel = yes\fR - \&in your \fB .mdp\fR file. An energy file can be supplied with - \&\fB \-e\fR to read Nose\-Hoover and/or Parrinello\-Rahman coupling --\&variables. Note that for continuation it is better and easier to supply --\&a checkpoint file directly to mdrun, since that always contains --\&the complete state of the system and you don't need to generate --\&a new run input file. Note that if you only want to change the number --\&of run steps tpbconv is more convenient than grompp. -+\&variables. - - --\&Using the \fB \-morse\fR option grompp can convert the harmonic bonds --\&in your topology to morse potentials. This makes it possible to break --\&bonds. For this option to work you need an extra file in your $GMXLIB --\&with dissociation energy. Use the \-debug option to get more information --\&on the workings of this option (look for MORSE in the grompp.log file --\&using less or something like that). -+\&\fB grompp\fR can be used to restart simulations (preserving -+\&continuity) by supplying just a checkpoint file with \fB \-t\fR. -+\&However, for simply changing the number of run steps to extend -+\&a run, using \fB tpbconv\fR is more convenient than \fB grompp\fR. -+\&You then supply the old checkpoint file directly to \fB mdrun\fR -+\&with \fB \-cpi\fR. If you wish to change the ensemble or things -+\&like output frequency, then supplying the checkpoint file to -+\&\fB grompp\fR with \fB \-t\fR along with a new \fB .mdp\fR file -+\&with \fB \-f\fR is the recommended procedure. - - --\&By default all bonded interactions which have constant energy due to -+\&By default, all bonded interactions which have constant energy due to - \&virtual site constructions will be removed. If this constant energy is - \¬ zero, this will result in a shift in the total energy. All bonded - \&interactions can be kept by turning off \fB \-rmvsbds\fR. Additionally, -@@ -125,17 +122,24 @@ include "filename" - \&of virtual site constructions will be removed. If any constraints remain - \&which involve virtual sites, a fatal error will result. - --To verify your run input file, please make notice of all warnings -+To verify your run input file, please take note of all warnings - \&on the screen, and correct where necessary. Do also look at the contents --\&of the \fB mdout.mdp\fR file, this contains comment lines, as well as --\&the input that \fB grompp\fR has read. If in doubt you can start grompp -+\&of the \fB mdout.mdp\fR file; this contains comment lines, as well as -+\&the input that \fB grompp\fR has read. If in doubt, you can start \fB grompp\fR - \&with the \fB \-debug\fR option which will give you more information --\&in a file called grompp.log (along with real debug info). Finally, you -+\&in a file called \fB grompp.log\fR (along with real debug info). You - \&can see the contents of the run input file with the \fB gmxdump\fR --\&program. -+\&program. \fB gmxcheck\fR can be used to compare the contents of two -+\&run input files. -+ -+The \fB \-maxwarn\fR option can be used to override warnings printed -+\&by \fB grompp\fR that otherwise halt output. In some cases, warnings are -+\&harmless, but usually they are not. The user is advised to carefully -+\&interpret the output messages before attempting to bypass them with -+\&this option. - .SH FILES - .BI "\-f" " grompp.mdp" --.B Input, Opt. -+.B Input - grompp input file with MD parameters - - .BI "\-po" " mdout.mdp" -@@ -198,7 +202,7 @@ To verify your run input file, please make notice of all warnings - Remove constant bonded interactions with virtual sites - - .BI "\-maxwarn" " int" " 0" -- Number of allowed warnings during input processing -+ Number of allowed warnings during input processing. Not for normal use and may generate unstable systems - - .BI "\-[no]zero" "no " - Set parameters for bonded interactions without defaults to zero instead of generating an error -diff --git a/man/man1/make_edi.1 b/man/man1/make_edi.1 -index 3000608..28c40cf 100644 ---- a/man/man1/make_edi.1 -+++ b/man/man1/make_edi.1 -@@ -1,8 +1,8 @@ --.TH make_edi 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH make_edi 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - make_edi - generate input files for essential dynamics sampling - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3make_edi\fP - .BI "\-f" " eigenvec.trr " -@@ -19,28 +19,29 @@ make_edi - generate input files for essential dynamics sampling - .BI "\-mon" " string " - .BI "\-linfix" " string " - .BI "\-linacc" " string " --.BI "\-flood" " string " - .BI "\-radfix" " string " - .BI "\-radacc" " string " - .BI "\-radcon" " string " -+.BI "\-flood" " string " - .BI "\-outfrq" " int " - .BI "\-slope" " real " -+.BI "\-linstep" " string " -+.BI "\-accdir" " string " -+.BI "\-radstep" " real " - .BI "\-maxedsteps" " int " -+.BI "\-eqsteps" " int " - .BI "\-deltaF0" " real " - .BI "\-deltaF" " real " - .BI "\-tau" " real " --.BI "\-eqsteps" " int " - .BI "\-Eflnull" " real " - .BI "\-T" " real " - .BI "\-alpha" " real " --.BI "\-linstep" " string " --.BI "\-accdir" " string " --.BI "\-radstep" " real " - .BI "\-[no]restrain" "" - .BI "\-[no]hessian" "" - .BI "\-[no]harmonic" "" -+.BI "\-constF" " string " - .SH DESCRIPTION --\&\fB make_edi\fR generates an essential dynamics (ED) sampling input file to be used with mdrun -+\&\fB make_edi\fR generates an essential dynamics (ED) sampling input file to be used with \fB mdrun\fR - \&based on eigenvectors of a covariance matrix (\fB g_covar\fR) or from a - \&normal modes anaysis (\fB g_nmeig\fR). - \&ED sampling can be used to manipulate the position along collective coordinates -@@ -67,7 +68,7 @@ make_edi - generate input files for essential dynamics sampling - - \&B.L. de Groot, A.Amadei, R.M. Scheek, N.A.J. van Nuland and H.J.C. Berendsen; - \&An extended sampling of the configurational space of HPr from E. coli --\&PROTEINS: Struct. Funct. Gen. 26: 314\-322 (1996) -+\&Proteins: Struct. Funct. Gen. 26: 314\-322 (1996) - \& - - You will be prompted for one or more index groups that correspond to the eigenvectors, -@@ -89,7 +90,7 @@ You will be prompted for one or more index groups that correspond to the eigenve - - \&\fB \-radacc\fR: perform acceptance radius expansion along selected eigenvectors. - \&(steps in the desired direction will be accepted, others will be rejected). --\&Note: by default the starting MD structure will be taken as origin of the first -+\&\fB Note:\fR by default the starting MD structure will be taken as origin of the first - \&expansion cycle for radius expansion. If \fB \-ori\fR is specified, you will be able - \&to read in a structure file that defines an external origin. - -@@ -101,7 +102,7 @@ You will be prompted for one or more index groups that correspond to the eigenve - \&NOTE: each eigenvector can be selected only once. - - --\&\fB \-outfrq\fR: frequency (in steps) of writing out projections etc. to .edo file -+\&\fB \-outfrq\fR: frequency (in steps) of writing out projections etc. to \fB .edo\fR file - - - \&\fB \-slope\fR: minimal slope in acceptance radius expansion. A new expansion -@@ -116,21 +117,21 @@ You will be prompted for one or more index groups that correspond to the eigenve - \&Note on the parallel implementation: since ED sampling is a 'global' thing - \&(collective coordinates etc.), at least on the 'protein' side, ED sampling - \&is not very parallel\-friendly from an implentation point of view. Because --\¶llel ED requires much extra communication, expect the performance to be -+\¶llel ED requires some extra communication, expect the performance to be - \&lower as in a free MD simulation, especially on a large number of nodes. - - --\&All output of mdrun (specify with \-eo) is written to a .edo file. In the output -+\&All output of \fB mdrun\fR (specify with \fB \-eo\fR) is written to a .edo file. In the output - \&file, per OUTFRQ step the following information is present: - - --\&* the step number -+\&\fB *\fR the step number - --\&* the number of the ED dataset. (Note that you can impose multiple ED constraints in --\&a single simulation \- on different molecules e.g. \- if several .edi files were concatenated --\&first. The constraints are applied in the order they appear in the .edi file.) -+\&\fB *\fR the number of the ED dataset. (\fB Note\fR that you can impose multiple ED constraints in -+\&a single simulation (on different molecules) if several \fB .edi\fR files were concatenated -+\&first. The constraints are applied in the order they appear in the \fB .edi\fR file.) - --\&* RMSD (for atoms involved in fitting prior to calculating the ED constraints) -+\&\fB *\fR RMSD (for atoms involved in fitting prior to calculating the ED constraints) - - \&* projections of the positions onto selected eigenvectors - -@@ -142,34 +143,34 @@ You will be prompted for one or more index groups that correspond to the eigenve - \&FLOODING: - - --\&with \-flood you can specify which eigenvectors are used to compute a flooding potential, -+\&with \fB \-flood\fR, you can specify which eigenvectors are used to compute a flooding potential, - \&which will lead to extra forces expelling the structure out of the region described - \&by the covariance matrix. If you switch \-restrain the potential is inverted and the structure - \&is kept in that region. - \& - - --\&The origin is normally the average structure stored in the eigvec.trr file. --\&It can be changed with \-ori to an arbitrary position in configurational space. --\&With \-tau, \-deltaF0 and \-Eflnull you control the flooding behaviour. -+\&The origin is normally the average structure stored in the \fB eigvec.trr\fR file. -+\&It can be changed with \fB \-ori\fR to an arbitrary position in configurational space. -+\&With \fB \-tau\fR, \fB \-deltaF0\fR, and \fB \-Eflnull\fR you control the flooding behaviour. - \&Efl is the flooding strength, it is updated according to the rule of adaptive flooding. - \&Tau is the time constant of adaptive flooding, high tau means slow adaption (i.e. growth). - \&DeltaF0 is the flooding strength you want to reach after tau ps of simulation. --\&To use constant Efl set \-tau to zero. -+\&To use constant Efl set \fB \-tau\fR to zero. - \& - - --\&\-alpha is a fudge parameter to control the width of the flooding potential. A value of 2 has been found -+\&\fB \-alpha\fR is a fudge parameter to control the width of the flooding potential. A value of 2 has been found - \&to give good results for most standard cases in flooding of proteins. --\&Alpha basically accounts for incomplete sampling, if you sampled further the width of the ensemble would --\&increase, this is mimicked by alpha1. --\&For restraining alpha1 can give you smaller width in the restraining potential. -+\&alpha basically accounts for incomplete sampling, if you sampled further the width of the ensemble would -+\&increase, this is mimicked by alpha 1. -+\&For restraining, alpha 1 can give you smaller width in the restraining potential. - \& - - - \&RESTART and FLOODING: - \&If you want to restart a crashed flooding simulation please find the values deltaF and Efl in --\&the output file and manually put them into the .edi file under DELTA_F0 and EFL_NULL. -+\&the output file and manually put them into the \fB .edi\fR file under DELTA_F0 and EFL_NULL. - .SH FILES - .BI "\-f" " eigenvec.trr" - .B Input -@@ -221,9 +222,6 @@ You will be prompted for one or more index groups that correspond to the eigenve - .BI "\-linacc" " string" " " - Indices of eigenvectors for acceptance linear sampling - --.BI "\-flood" " string" " " -- Indices of eigenvectors for flooding -- - .BI "\-radfix" " string" " " - Indices of eigenvectors for fixed increment radius expansion - -@@ -233,29 +231,41 @@ You will be prompted for one or more index groups that correspond to the eigenve - .BI "\-radcon" " string" " " - Indices of eigenvectors for acceptance radius contraction - -+.BI "\-flood" " string" " " -+ Indices of eigenvectors for flooding -+ - .BI "\-outfrq" " int" " 100" -- Freqency (in steps) of writing output in .edo file -+ Freqency (in steps) of writing output in \fB .edo\fR file - - .BI "\-slope" " real" " 0 " - Minimal slope in acceptance radius expansion - -+.BI "\-linstep" " string" " " -+ Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! "1.0 2.3 5.1 \-3.1") -+ -+.BI "\-accdir" " string" " " -+ Directions for acceptance linear sampling \- only sign counts! (put in quotes! "\-1 +1 \-1.1") -+ -+.BI "\-radstep" " real" " 0 " -+ Stepsize (nm/step) for fixed increment radius expansion -+ - .BI "\-maxedsteps" " int" " 0" -- Max nr of steps per cycle -+ Maximum number of steps per cycle -+ -+.BI "\-eqsteps" " int" " 0" -+ Number of steps to run without any perturbations - - .BI "\-deltaF0" " real" " 150 " -- Target destabilization energy \- used for flooding -+ Target destabilization energy for flooding - - .BI "\-deltaF" " real" " 0 " -- Start deltaF with this parameter \- default 0, i.e. nonzero values only needed for restart -+ Start deltaF with this parameter \- default 0, nonzero values only needed for restart - - .BI "\-tau" " real" " 0.1 " - Coupling constant for adaption of flooding strength according to deltaF0, 0 = infinity i.e. constant flooding strength - --.BI "\-eqsteps" " int" " 0" -- Number of steps to run without any perturbations -- - .BI "\-Eflnull" " real" " 0 " -- This is the starting value of the flooding strength. The flooding strength is updated according to the adaptive flooding scheme. To use a constant flooding strength use \-tau 0. -+ The starting value of the flooding strength. The flooding strength is updated according to the adaptive flooding scheme. For a constant flooding strength use \fB \-tau\fR 0. - - .BI "\-T" " real" " 300 " - T is temperature, the value is needed if you want to do flooding -@@ -263,15 +273,6 @@ You will be prompted for one or more index groups that correspond to the eigenve - .BI "\-alpha" " real" " 1 " - Scale width of gaussian flooding potential with alpha2 - --.BI "\-linstep" " string" " " -- Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! "1.0 2.3 5.1 \-3.1") -- --.BI "\-accdir" " string" " " -- Directions for acceptance linear sampling \- only sign counts! (put in quotes! "\-1 +1 \-1.1") -- --.BI "\-radstep" " real" " 0 " -- Stepsize (nm/step) for fixed increment radius expansion -- - .BI "\-[no]restrain" "no " - Use the flooding potential with inverted sign \- effects as quasiharmonic restraining potential - -@@ -281,6 +282,9 @@ You will be prompted for one or more index groups that correspond to the eigenve - .BI "\-[no]harmonic" "no " - The eigenvalues are interpreted as spring constant - -+.BI "\-constF" " string" " " -+ Constant force flooding: manually set the forces for the eigenvectors selected with \-flood (put in quotes! "1.0 2.3 5.1 \-3.1"). No other flooding parameters are needed when specifying the forces directly. -+ - .SH SEE ALSO - .BR gromacs(7) - -diff --git a/man/man1/make_ndx.1 b/man/man1/make_ndx.1 -index eb856a3..fca4200 100644 ---- a/man/man1/make_ndx.1 -+++ b/man/man1/make_ndx.1 -@@ -1,8 +1,8 @@ --.TH make_ndx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH make_ndx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - make_ndx - makes index files - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3make_ndx\fP - .BI "\-f" " conf.gro " -@@ -15,13 +15,13 @@ make_ndx - makes index files - .SH DESCRIPTION - \&Index groups are necessary for almost every gromacs program. - \&All these programs can generate default index groups. You ONLY --\&have to use make_ndx when you need SPECIAL index groups. -+\&have to use \fB make_ndx\fR when you need SPECIAL index groups. - \&There is a default index group for the whole system, 9 default --\&index groups are generated for proteins, a default index group -+\&index groups for proteins, and a default index group - \&is generated for every other residue name. - - --\&When no index file is supplied, also make_ndx will generate the -+\&When no index file is supplied, also \fB make_ndx\fR will generate the - \&default groups. - \&With the index editor you can select on atom, residue and chain names - \&and numbers. -diff --git a/man/man1/mdrun.1 b/man/man1/mdrun.1 -index 191bffd..8aaf75d 100644 ---- a/man/man1/mdrun.1 -+++ b/man/man1/mdrun.1 -@@ -1,8 +1,8 @@ --.TH mdrun 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH mdrun 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - mdrun - performs a simulation, do a normal mode analysis or an energy minimization - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3mdrun\fP - .BI "\-s" " topol.tpr " -@@ -32,6 +32,7 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - .BI "\-pf" " pullf.xvg " - .BI "\-mtx" " nm.mtx " - .BI "\-dn" " dipole.ndx " -+.BI "\-multidir" " rundir " - .BI "\-[no]h" "" - .BI "\-[no]version" "" - .BI "\-nice" " int " -@@ -39,7 +40,6 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - .BI "\-xvg" " enum " - .BI "\-[no]pd" "" - .BI "\-dd" " vector " --.BI "\-nt" " int " - .BI "\-npme" " int " - .BI "\-ddorder" " enum " - .BI "\-[no]ddcheck" "" -@@ -62,20 +62,20 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - .BI "\-reseed" " int " - .BI "\-[no]ionize" "" - .SH DESCRIPTION --\&The mdrun program is the main computational chemistry engine -+\&The \fB mdrun\fR program is the main computational chemistry engine - \&within GROMACS. Obviously, it performs Molecular Dynamics simulations, - \&but it can also perform Stochastic Dynamics, Energy Minimization, - \&test particle insertion or (re)calculation of energies. --\&Normal mode analysis is another option. In this case mdrun -+\&Normal mode analysis is another option. In this case \fB mdrun\fR - \&builds a Hessian matrix from single conformation. - \&For usual Normal Modes\-like calculations, make sure that - \&the structure provided is properly energy\-minimized. --\&The generated matrix can be diagonalized by g_nmeig. -+\&The generated matrix can be diagonalized by \fB g_nmeig\fR. - - --\&The mdrun program reads the run input file (\fB \-s\fR) -+\&The \fB mdrun\fR program reads the run input file (\fB \-s\fR) - \&and distributes the topology over nodes if needed. --\&mdrun produces at least four output files. -+\&\fB mdrun\fR produces at least four output files. - \&A single log file (\fB \-g\fR) is written, unless the option - \&\fB \-seppot\fR is used, in which case each node writes a log file. - \&The trajectory file (\fB \-o\fR), contains coordinates, velocities and -@@ -92,13 +92,13 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&turned on. - - --\&When mdrun is started using MPI with more than 1 node, parallelization -+\&When \fB mdrun\fR is started using MPI with more than 1 node, parallelization - \&is used. By default domain decomposition is used, unless the \fB \-pd\fR - \&option is set, which selects particle decomposition. - - - \&With domain decomposition, the spatial decomposition can be set --\&with option \fB \-dd\fR. By default mdrun selects a good decomposition. -+\&with option \fB \-dd\fR. By default \fB mdrun\fR selects a good decomposition. - \&The user only needs to change this when the system is very inhomogeneous. - \&Dynamic load balancing is set with the option \fB \-dlb\fR, - \&which can give a significant performance improvement, -@@ -119,7 +119,7 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&this is computationally more efficient starting at about 12 nodes. - \&The number of PME nodes is set with option \fB \-npme\fR, - \&this can not be more than half of the nodes. --\&By default mdrun makes a guess for the number of PME -+\&By default \fB mdrun\fR makes a guess for the number of PME - \&nodes when the number of nodes is larger than 11 or performance wise - \¬ compatible with the PME grid x dimension. - \&But the user should optimize npme. Performance statistics on this issue -@@ -133,6 +133,7 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&This section lists all options that affect the domain decomposition. - \& - -+ - \&Option \fB \-rdd\fR can be used to set the required maximum distance - \&for inter charge\-group bonded interactions. - \&Communication for two\-body bonded interactions below the non\-bonded -@@ -142,31 +143,34 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&and nearly indepedent of the value of \fB \-rdd\fR. - \&With dynamic load balancing option \fB \-rdd\fR also sets - \&the lower limit for the domain decomposition cell sizes. --\&By default \fB \-rdd\fR is determined by mdrun based on -+\&By default \fB \-rdd\fR is determined by \fB mdrun\fR based on - \&the initial coordinates. The chosen value will be a balance - \&between interaction range and communication cost. - \& - -+ - \&When inter charge\-group bonded interactions are beyond --\&the bonded cut\-off distance, mdrun terminates with an error message. -+\&the bonded cut\-off distance, \fB mdrun\fR terminates with an error message. - \&For pair interactions and tabulated bonds - \&that do not generate exclusions, this check can be turned off - \&with the option \fB \-noddcheck\fR. - \& - -+ - \&When constraints are present, option \fB \-rcon\fR influences - \&the cell size limit as well. - \&Atoms connected by NC constraints, where NC is the LINCS order plus 1, - \&should not be beyond the smallest cell size. A error message is - \&generated when this happens and the user should change the decomposition - \&or decrease the LINCS order and increase the number of LINCS iterations. --\&By default mdrun estimates the minimum cell size required for P\-LINCS -+\&By default \fB mdrun\fR estimates the minimum cell size required for P\-LINCS - \&in a conservative fashion. For high parallelization it can be useful - \&to set the distance required for P\-LINCS with the option \fB \-rcon\fR. - \& - -+ - \&The \fB \-dds\fR option sets the minimum allowed x, y and/or z scaling --\&of the cells with dynamic load balancing. mdrun will ensure that -+\&of the cells with dynamic load balancing. \fB mdrun\fR will ensure that - \&the cells can scale down by at least this factor. This option is used - \&for the automated spatial decomposition (when not using \fB \-dd\fR) - \&as well as for determining the number of grid pulses, which in turn -@@ -181,7 +185,7 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&This can improve performance for highly parallel simulations - \&where this global communication step becomes the bottleneck. - \&For a global thermostat and/or barostat the temperature --\&and/or pressure will also only be updated every \-gcom steps. -+\&and/or pressure will also only be updated every \fB \-gcom\fR steps. - \&By default it is set to the minimum of nstcalcenergy and nstlist. - - -@@ -194,19 +198,19 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&ED (essential dynamics) sampling is switched on by using the \fB \-ei\fR - \&flag followed by an \fB .edi\fR file. - \&The \fB .edi\fR file can be produced using options in the essdyn --\&menu of the WHAT IF program. mdrun produces a \fB .edo\fR file that -+\&menu of the WHAT IF program. \fB mdrun\fR produces a \fB .edo\fR file that - \&contains projections of positions, velocities and forces onto selected - \&eigenvectors. - - - \&When user\-defined potential functions have been selected in the --\&\fB .mdp\fR file the \fB \-table\fR option is used to pass mdrun -+\&\fB .mdp\fR file the \fB \-table\fR option is used to pass \fB mdrun\fR - \&a formatted table with potential functions. The file is read from --\&either the current directory or from the GMXLIB directory. --\&A number of pre\-formatted tables are presented in the GMXLIB dir, --\&for 6\-8, 6\-9, 6\-10, 6\-11, 6\-12 Lennard Jones potentials with -+\&either the current directory or from the \fB GMXLIB\fR directory. -+\&A number of pre\-formatted tables are presented in the \fB GMXLIB\fR dir, -+\&for 6\-8, 6\-9, 6\-10, 6\-11, 6\-12 Lennard\-Jones potentials with - \&normal Coulomb. --\&When pair interactions are present a separate table for pair interaction -+\&When pair interactions are present, a separate table for pair interaction - \&functions is read using the \fB \-tablep\fR option. - - -@@ -214,7 +218,7 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&interaction functions are read using the \fB \-tableb\fR option. - \&For each different tabulated interaction type the table file name is - \&modified in a different way: before the file extension an underscore is --\&appended, then a b for bonds, an a for angles or a d for dihedrals -+\&appended, then a 'b' for bonds, an 'a' for angles or a 'd' for dihedrals - \&and finally the table number of the interaction type. - - -@@ -223,10 +227,16 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&in the \fB .mdp\fR file. - - --\&With \fB \-multi\fR multiple systems are simulated in parallel. --\&As many input files are required as the number of systems. --\&The system number is appended to the run input and each output filename, --\&for instance topol.tpr becomes topol0.tpr, topol1.tpr etc. -+\&With \fB \-multi\fR or \fB \-multidir\fR, multiple systems can be -+\&simulated in parallel. -+\&As many input files/directories are required as the number of systems. -+\&The \fB \-multidir\fR option takes a list of directories (one for each -+\&system) and runs in each of them, using the input/output file names, -+\&such as specified by e.g. the \fB \-s\fR option, relative to these -+\&directories. -+\&With \fB \-multi\fR, the system number is appended to the run input -+\&and each output filename, for instance \fB topol.tpr\fR becomes -+\&\fB topol0.tpr\fR, \fB topol1.tpr\fR etc. - \&The number of nodes per system is the total number of nodes - \÷d by the number of systems. - \&One use of this option is for NMR refinement: when distance -@@ -235,8 +245,8 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - - - \&With \fB \-replex\fR replica exchange is attempted every given number --\&of steps. The number of replicas is set with the \fB \-multi\fR option, --\&see above. -+\&of steps. The number of replicas is set with the \fB \-multi\fR or -+\&\fB \-multidir\fR option, described above. - \&All run input files should use a different coupling temperature, - \&the order of the files is not important. The random seed is set with - \&\fB \-reseed\fR. The velocities are scaled and neighbor searching -@@ -245,7 +255,7 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - - \&Finally some experimental algorithms can be tested when the - \&appropriate options have been given. Currently under --\&investigation are: polarizability, and X\-Ray bombardments. -+\&investigation are: polarizability and X\-ray bombardments. - \& - - -@@ -267,18 +277,22 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \&A simulation can be continued by reading the full state from file - \&with option \fB \-cpi\fR. This option is intelligent in the way that - \&if no checkpoint file is found, Gromacs just assumes a normal run and --\&starts from the first step of the tpr file. By default the output -+\&starts from the first step of the \fB .tpr\fR file. By default the output - \&will be appending to the existing output files. The checkpoint file - \&contains checksums of all output files, such that you will never - \&loose data when some output files are modified, corrupt or removed. - \&There are three scenarios with \fB \-cpi\fR: - --\&* no files with matching names are present: new output files are written - --\&* all files are present with names and checksums matching those stored -+\&\fB *\fR no files with matching names are present: new output files are written -+ -+ -+\&\fB *\fR all files are present with names and checksums matching those stored - \&in the checkpoint file: files are appended - --\&* otherwise no files are modified and a fatal error is generated -+ -+\&\fB *\fR otherwise no files are modified and a fatal error is generated -+ - - \&With \fB \-noappend\fR new output files are opened and the simulation - \&part number is added to all output file names. -@@ -309,18 +323,18 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - \& - - --\&When mdrun receives a TERM signal, it will set nsteps to the current --\&step plus one. When mdrun receives an INT signal (e.g. when ctrl+C is -+\&When \fB mdrun\fR receives a TERM signal, it will set nsteps to the current -+\&step plus one. When \fB mdrun\fR receives an INT signal (e.g. when ctrl+C is - \&pressed), it will stop after the next neighbor search step - \&(with nstlist=0 at the next step). - \&In both cases all the usual output will be written to file. --\&When running with MPI, a signal to one of the mdrun processes -+\&When running with MPI, a signal to one of the \fB mdrun\fR processes - \&is sufficient, this signal should not be sent to mpirun or --\&the mdrun process that is the parent of the others. -+\&the \fB mdrun\fR process that is the parent of the others. - \& - - --\&When mdrun is started with MPI, it does not run niced by default. -+\&When \fB mdrun\fR is started with MPI, it does not run niced by default. - .SH FILES - .BI "\-s" " topol.tpr" - .B Input -@@ -430,6 +444,10 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - .B Output, Opt. - Index file - -+.BI "\-multidir" " rundir" -+.B Input, Opt., Mult. -+ Run directory -+ - .SH OTHER OPTIONS - .BI "\-[no]h" "no " - Print help info and quit -@@ -452,9 +470,6 @@ mdrun - performs a simulation, do a normal mode analysis or an energy minimizati - .BI "\-dd" " vector" " 0 0 0" - Domain decomposition grid, 0 is optimize - --.BI "\-nt" " int" " 0" -- Number of threads to start (0 is guess) -- - .BI "\-npme" " int" " \-1" - Number of separate nodes to be used for PME, \-1 is guess - -diff --git a/man/man1/mk_angndx.1 b/man/man1/mk_angndx.1 -index aad17d3..e9bce82 100644 ---- a/man/man1/mk_angndx.1 -+++ b/man/man1/mk_angndx.1 -@@ -1,8 +1,8 @@ --.TH mk_angndx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH mk_angndx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - mk_angndx - generates index files for g_angle - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3mk_angndx\fP - .BI "\-s" " topol.tpr " -@@ -14,7 +14,7 @@ mk_angndx - generates index files for g_angle - .BI "\-[no]hyd" "" - .BI "\-hq" " real " - .SH DESCRIPTION --\&mk_angndx makes an index file for calculation of -+\&\fB mk_angndx\fR makes an index file for calculation of - \&angle distributions etc. It uses a run input file (\fB .tpx\fR) for the - \&definitions of the angles, dihedrals etc. - .SH FILES -diff --git a/man/man1/ngmx.1 b/man/man1/ngmx.1 -index dfa2e9d..0a4affc 100644 ---- a/man/man1/ngmx.1 -+++ b/man/man1/ngmx.1 -@@ -1,8 +1,8 @@ --.TH ngmx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH ngmx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - ngmx - displays a trajectory - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3ngmx\fP - .BI "\-f" " traj.xtc " -@@ -15,7 +15,7 @@ ngmx - displays a trajectory - .BI "\-e" " time " - .BI "\-dt" " time " - .SH DESCRIPTION --\&ngmx is the Gromacs trajectory viewer. This program reads a -+\&\fB ngmx\fR is the GROMACS trajectory viewer. This program reads a - \&trajectory file, a run input file and an index file and plots a - \&3D structure of your molecule on your standard X Window - \&screen. No need for a high end graphics workstation, it even -@@ -31,9 +31,8 @@ ngmx - displays a trajectory - \&show computational box. - - --\&Some of the more common X command line options can be used: -- --\&\-bg, \-fg change colors, \-font fontname, changes the font. -+\&Some of the more common X command line options can be used: -+\&\fB \-bg\fR, \fB \-fg\fR change colors, \fB \-font fontname\fR changes the font. - .SH FILES - .BI "\-f" " traj.xtc" - .B Input -diff --git a/man/man1/pdb2gmx.1 b/man/man1/pdb2gmx.1 -index 6e0e76d..dfa5d22 100644 ---- a/man/man1/pdb2gmx.1 -+++ b/man/man1/pdb2gmx.1 -@@ -1,8 +1,8 @@ --.TH pdb2gmx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH pdb2gmx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - pdb2gmx - converts pdb files to topology and coordinate files - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3pdb2gmx\fP - .BI "\-f" " eiwit.pdb " -@@ -41,22 +41,22 @@ pdb2gmx - converts pdb files to topology and coordinate files - .BI "\-[no]renum" "" - .BI "\-[no]rtpres" "" - .SH DESCRIPTION --\&This program reads a pdb (or gro) file, reads -+\&This program reads a \fB .pdb\fR (or \fB .gro\fR) file, reads - \&some database files, adds hydrogens to the molecules and generates --\&coordinates in Gromacs (Gromos), or optionally pdb, format --\&and a topology in Gromacs format. -+\&coordinates in GROMACS (GROMOS), or optionally \fB .pdb\fR, format -+\&and a topology in GROMACS format. - \&These files can subsequently be processed to generate a run input file. - \& - - --\&pdb2gmx will search for force fields by looking for -+\&\fB pdb2gmx\fR will search for force fields by looking for - \&a \fB forcefield.itp\fR file in subdirectories \fB forcefield.ff\fR --\&of the current working directory and of the Gomracs library directory -+\&of the current working directory and of the Gromacs library directory - \&as inferred from the path of the binary or the \fB GMXLIB\fR environment - \&variable. - \&By default the forcefield selection is interactive, - \&but you can use the \fB \-ff\fR option to specify one of the short names --\&in the list on the command line instead. In that case pdb2gmx just looks -+\&in the list on the command line instead. In that case \fB pdb2gmx\fR just looks - \&for the corresponding \fB forcefield.ff\fR directory. - \& - -@@ -66,14 +66,14 @@ pdb2gmx - converts pdb files to topology and coordinate files - \&If you want to modify or add a residue types, you can copy the force - \&field directory from the Gromacs library directory to your current - \&working directory. If you want to add new protein residue types, --\&you will need to modify residuetypes.dat in the libary directory -+\&you will need to modify \fB residuetypes.dat\fR in the library directory - \&or copy the whole library directory to a local directory and set - \&the environment variable \fB GMXLIB\fR to the name of that directory. --\&Check chapter 5 of the manual for more information about file formats. -+\&Check Chapter 5 of the manual for more information about file formats. - \& - - --\&Note that a pdb file is nothing more than a file format, and it -+\&Note that a \fB .pdb\fR file is nothing more than a file format, and it - \&need not necessarily contain a protein structure. Every kind of - \&molecule for which there is support in the database can be converted. - \&If there is no support in the database, you can add it yourself. -@@ -89,7 +89,7 @@ pdb2gmx - converts pdb files to topology and coordinate files - \&on NE2 or on both. By default these selections are done automatically. - \&For His, this is based on an optimal hydrogen bonding - \&conformation. Hydrogen bonds are defined based on a simple geometric --\&criterium, specified by the maximum hydrogen\-donor\-acceptor angle -+\&criterion, specified by the maximum hydrogen\-donor\-acceptor angle - \&and donor\-acceptor distance, which are set by \fB \-angle\fR and - \&\fB \-dist\fR respectively. - -@@ -100,33 +100,33 @@ pdb2gmx - converts pdb files to topology and coordinate files - \&if you want a disulfide bridge or distance restraints between - \&two protein chains or if you have a HEME group bound to a protein. - \&In such cases multiple chains should be contained in a single --\&\fB molecule_type\fR definition. --\&To handle this, pdb2gmx has an option \fB \-chainsep\fR so you can -+\&\fB moleculetype\fR definition. -+\&To handle this, \fB pdb2gmx\fR has an option \fB \-chainsep\fR so you can - \&choose whether a new chain should start when we find a TER record, - \&when the chain id changes, combinations of either or both of these - \&or fully interactively. - - --\&pdb2gmx will also check the occupancy field of the pdb file. -+\&\fB pdb2gmx\fR will also check the occupancy field of the \fB .pdb\fR file. - \&If any of the occupancies are not one, indicating that the atom is - \¬ resolved well in the structure, a warning message is issued. --\&When a pdb file does not originate from an X\-Ray structure determination -+\&When a \fB .pdb\fR file does not originate from an X\-ray structure determination - \&all occupancy fields may be zero. Either way, it is up to the user - \&to verify the correctness of the input data (read the article!). - - --\&During processing the atoms will be reordered according to Gromacs -+\&During processing the atoms will be reordered according to GROMACS - \&conventions. With \fB \-n\fR an index file can be generated that - \&contains one group reordered in the same way. This allows you to --\&convert a Gromos trajectory and coordinate file to Gromos. There is -+\&convert a GROMOS trajectory and coordinate file to GROMOS. There is - \&one limitation: reordering is done after the hydrogens are stripped - \&from the input and before new hydrogens are added. This means that - \&you should not use \fB \-ignh\fR. - - - \&The \fB .gro\fR and \fB .g96\fR file formats do not support chain --\&identifiers. Therefore it is useful to enter a pdb file name at --\&the \fB \-o\fR option when you want to convert a multichain pdb file. -+\&identifiers. Therefore it is useful to enter a \fB .pdb\fR file name at -+\&the \fB \-o\fR option when you want to convert a multi\-chain \fB .pdb\fR file. - \& - - -@@ -135,8 +135,8 @@ pdb2gmx - converts pdb files to topology and coordinate files - \&hydrogens into virtual sites and fixing angles, which fixes their - \&position relative to neighboring atoms. Additionally, all atoms in the - \&aromatic rings of the standard amino acids (i.e. PHE, TRP, TYR and HIS) --\&can be converted into virtual sites, elminating the fast improper dihedral --\&fluctuations in these rings. Note that in this case all other hydrogen -+\&can be converted into virtual sites, eliminating the fast improper dihedral -+\&fluctuations in these rings. \fB Note\fR that in this case all other hydrogen - \&atoms are also converted to virtual sites. The mass of all atoms that are - \&converted into virtual sites, is added to the heavy atoms. - -@@ -185,7 +185,7 @@ pdb2gmx - converts pdb files to topology and coordinate files - Condition in PDB files when a new chain and molecule_type should be started: \fB id_or_ter\fR, \fB id_and_ter\fR, \fB ter\fR, \fB id\fR or \fB interactive\fR - - .BI "\-ff" " string" " select" -- Force field, interactive by default. Use \-h for information. -+ Force field, interactive by default. Use \fB \-h\fR for information. - - .BI "\-water" " enum" " select" - Water model to use: \fB select\fR, \fB none\fR, \fB spc\fR, \fB spce\fR, \fB tip3p\fR, \fB tip4p\fR or \fB tip5p\fR -@@ -200,22 +200,22 @@ pdb2gmx - converts pdb files to topology and coordinate files - Interactive termini selection, iso charged - - .BI "\-[no]lys" "no " -- Interactive Lysine selection, iso charged -+ Interactive lysine selection, iso charged - - .BI "\-[no]arg" "no " -- Interactive Arganine selection, iso charged -+ Interactive arginine selection, iso charged - - .BI "\-[no]asp" "no " -- Interactive Aspartic Acid selection, iso charged -+ Interactive aspartic Acid selection, iso charged - - .BI "\-[no]glu" "no " -- Interactive Glutamic Acid selection, iso charged -+ Interactive glutamic Acid selection, iso charged - - .BI "\-[no]gln" "no " -- Interactive Glutamine selection, iso neutral -+ Interactive glutamine selection, iso neutral - - .BI "\-[no]his" "no " -- Interactive Histidine selection, iso checking H\-bonds -+ Interactive histidine selection, iso checking H\-bonds - - .BI "\-angle" " real" " 135 " - Minimum hydrogen\-donor\-acceptor angle for a H\-bond (degrees) -@@ -224,10 +224,10 @@ pdb2gmx - converts pdb files to topology and coordinate files - Maximum donor\-acceptor distance for a H\-bond (nm) - - .BI "\-[no]una" "no " -- Select aromatic rings with united CH atoms on Phenylalanine, Tryptophane and Tyrosine -+ Select aromatic rings with united CH atoms on phenylalanine, tryptophane and tyrosine - - .BI "\-[no]ignh" "no " -- Ignore hydrogen atoms that are in the pdb file -+ Ignore hydrogen atoms that are in the coordinate file - - .BI "\-[no]missing" "no " - Continue when atoms are missing, dangerous -@@ -248,16 +248,16 @@ pdb2gmx - converts pdb files to topology and coordinate files - Change the mass of hydrogens to 2 amu - - .BI "\-[no]chargegrp" "yes " -- Use charge groups in the rtp file -+ Use charge groups in the \fB .rtp\fR file - - .BI "\-[no]cmap" "yes " -- Use cmap torsions (if enabled in the rtp file) -+ Use cmap torsions (if enabled in the \fB .rtp\fR file) - - .BI "\-[no]renum" "no " - Renumber the residues consecutively in the output - - .BI "\-[no]rtpres" "no " -- Use rtp entry names as residue names -+ Use \fB .rtp\fR entry names as residue names - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/tpbconv.1 b/man/man1/tpbconv.1 -index 2f0db8a..4515836 100644 ---- a/man/man1/tpbconv.1 -+++ b/man/man1/tpbconv.1 -@@ -1,8 +1,8 @@ --.TH tpbconv 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH tpbconv 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - tpbconv - makes a run input file for restarting a crashed run - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3tpbconv\fP - .BI "\-s" " topol.tpr " -@@ -24,27 +24,31 @@ tpbconv - makes a run input file for restarting a crashed run - \&tpbconv can edit run input files in four ways. - - --\&\fB 1st.\fR by modifying the number of steps in a run input file -+\&\fB 1.\fR by modifying the number of steps in a run input file - \&with options \fB \-extend\fR, \fB \-until\fR or \fB \-nsteps\fR - \&(nsteps=\-1 means unlimited number of steps) - - --\&\fB 2nd.\fR (OBSOLETE) by creating a run input file -+\&\fB 2.\fR (OBSOLETE) by creating a run input file - \&for a continuation run when your simulation has crashed due to e.g. - \&a full disk, or by making a continuation run input file. - \&This option is obsolete, since mdrun now writes and reads - \&checkpoint files. --\&Note that a frame with coordinates and velocities is needed. -+\&\fB Note\fR that a frame with coordinates and velocities is needed. - \&When pressure and/or Nose\-Hoover temperature coupling is used - \&an energy file can be supplied to get an exact continuation - \&of the original run. - - --\&\fB 3rd.\fR by creating a tpx file for a subset of your original -+\&\fB 3.\fR by creating a \fB .tpx\fR file for a subset of your original - \&tpx file, which is useful when you want to remove the solvent from --\&your tpx file, or when you want to make e.g. a pure Ca tpx file. --\&\fB WARNING: this tpx file is not fully functional\fR. --\&\fB 4th.\fR by setting the charges of a specified group -+\&your \fB .tpx\fR file, or when you want to make e.g. a pure Calpha \fB .tpx\fR file. -+\&Note that you may need to use \fB \-nsteps \-1\fR (or similar) to get -+\&this to work. -+\&\fB WARNING: this \fB .tpx\fR file is not fully functional\fR. -+ -+ -+\&\fB 4.\fR by setting the charges of a specified group - \&to zero. This is useful when doing free energy estimates - \&using the LIE (Linear Interaction Energy) method. - .SH FILES -diff --git a/man/man1/trjcat.1 b/man/man1/trjcat.1 -index 56ab69a..105282d 100644 ---- a/man/man1/trjcat.1 -+++ b/man/man1/trjcat.1 -@@ -1,8 +1,8 @@ --.TH trjcat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH trjcat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - trjcat - concatenates trajectory files - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3trjcat\fP - .BI "\-f" " traj.xtc " -@@ -25,12 +25,12 @@ trjcat - concatenates trajectory files - .BI "\-[no]overwrite" "" - .BI "\-[no]cat" "" - .SH DESCRIPTION --\&trjcat concatenates several input trajectory files in sorted order. -+\&\fB trjcat\fR concatenates several input trajectory files in sorted order. - \&In case of double time frames the one in the later file is used. - \&By specifying \fB \-settime\fR you will be asked for the start time - \&of each file. The input files are taken from the command line, --\&such that a command like \fB trjcat \-o fixed.trr *.trr\fR should do --\&the trick. Using \fB \-cat\fR you can simply paste several files -+\&such that a command like \fB trjcat \-f *.trr \-o fixed.trr\fR should do -+\&the trick. Using \fB \-cat\fR, you can simply paste several files - \&together without removal of frames with identical time stamps. - - -@@ -42,19 +42,19 @@ trjcat - concatenates trajectory files - - - \&If the \fB \-demux\fR option is given, the N trajectories that are --\&read, are written in another order as specified in the xvg file. --\&The xvg file should contain something like: -+\&read, are written in another order as specified in the \fB .xvg\fR file. -+\&The \fB .xvg\fR file should contain something like: - - --\&0 0 1 2 3 4 5 -+\&\fB 0 0 1 2 3 4 5 - --\&2 1 0 2 3 5 4 -+\&2 1 0 2 3 5 4\fR - - \&Where the first number is the time, and subsequent numbers point to - \&trajectory indices. - \&The frames corresponding to the numbers present at the first line - \&are collected into the output trajectory. If the number of frames in --\&the trajectory does not match that in the xvg file then the program -+\&the trajectory does not match that in the \fB .xvg\fR file then the program - \&tries to be smart. Beware. - .SH FILES - .BI "\-f" " traj.xtc" -@@ -99,7 +99,7 @@ trjcat - concatenates trajectory files - Only write frame when t MOD dt = first time (ps) - - .BI "\-prec" " int" " 3" -- Precision for .xtc and .gro writing in number of decimal places -+ Precision for \fB .xtc\fR and \fB .gro\fR writing in number of decimal places - - .BI "\-[no]vel" "yes " - Read and write velocities if possible -@@ -111,13 +111,13 @@ trjcat - concatenates trajectory files - Sort trajectory files (not frames) - - .BI "\-[no]keeplast" "no " -- keep overlapping frames at end of trajectory -+ Keep overlapping frames at end of trajectory - - .BI "\-[no]overwrite" "no " -- overwrite overlapping frames during appending -+ Overwrite overlapping frames during appending - - .BI "\-[no]cat" "no " -- do not discard double time frames -+ Do not discard double time frames - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/trjconv.1 b/man/man1/trjconv.1 -index fbb082e..637edc2 100644 ---- a/man/man1/trjconv.1 -+++ b/man/man1/trjconv.1 -@@ -1,8 +1,8 @@ --.TH trjconv 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH trjconv 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - trjconv - converts and manipulates trajectory files - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3trjconv\fP - .BI "\-f" " traj.xtc " -@@ -31,6 +31,7 @@ trjconv - converts and manipulates trajectory files - .BI "\-[no]center" "" - .BI "\-boxcenter" " enum " - .BI "\-box" " vector " -+.BI "\-clustercenter" " vector " - .BI "\-trans" " vector " - .BI "\-shift" " vector " - .BI "\-fit" " enum " -@@ -47,7 +48,7 @@ trjconv - converts and manipulates trajectory files - .BI "\-dropover" " real " - .BI "\-[no]conect" "" - .SH DESCRIPTION --\&trjconv can convert trajectory files in many ways: -+\&\fB trjconv\fR can convert trajectory files in many ways: - - \&\fB 1.\fR from one format to another - -@@ -68,7 +69,7 @@ trjconv - converts and manipulates trajectory files - - \&\fB 9.\fR cut the trajectory in small subtrajectories according - \&to information in an index file. This allows subsequent analysis of --\&the subtrajectories that could, for example be the result of a -+\&the subtrajectories that could, for example, be the result of a - \&cluster analysis. Use option \fB \-sub\fR. - \&This assumes that the entries in the index file are frame numbers and - \&dumps each group in the index file to a separate trajectory file. -@@ -77,7 +78,7 @@ trjconv - converts and manipulates trajectory files - \&in an \fB .xvg\fR file. - - --\&The program \fB trjcat\fR can concatenate multiple trajectory files. -+\&The program \fB trjcat\fR is better suited for concatenating multiple trajectory files. - \& - - -@@ -91,7 +92,7 @@ trjconv - converts and manipulates trajectory files - \&is always taken from \fB \-ndec\fR, when this option is set. - \&All other formats have fixed precision. \fB .trr\fR and \fB .trj\fR - \&output can be single or double precision, depending on the precision --\&of the trjconv binary. -+\&of the \fB trjconv\fR binary. - \&Note that velocities are only supported in - \&\fB .trr\fR, \fB .trj\fR, \fB .gro\fR and \fB .g96\fR files. - -@@ -103,7 +104,7 @@ trjconv - converts and manipulates trajectory files - - - \&Option \fB \-sep\fR can be used to write every frame to a separate --\&.gro, .g96 or .pdb file, default all frames all written to one file. -+\&\fB .gro, .g96\fR or \fB .pdb\fR file. By default, all frames all written to one file. - \&\fB .pdb\fR files with all frames concatenated can be viewed with - \&\fB rasmol \-nmrpdb\fR. - -@@ -117,9 +118,9 @@ trjconv - converts and manipulates trajectory files - - - \&There are two options for fitting the trajectory to a reference --\&either for essential dynamics analysis or for whatever. -+\&either for essential dynamics analysis, etc. - \&The first option is just plain fitting to a reference structure --\&in the structure file, the second option is a progressive fit -+\&in the structure file. The second option is a progressive fit - \&in which the first timeframe is fitted to the reference structure - \&in the structure file to obtain and each subsequent timeframe is - \&fitted to the previously fitted structure. This way a continuous -@@ -131,28 +132,32 @@ trjconv - converts and manipulates trajectory files - \&Option \fB \-pbc\fR sets the type of periodic boundary condition - \&treatment: - --\&* \fB mol\fR puts the center of mass of molecules in the box. -+\&\fB * mol\fR puts the center of mass of molecules in the box. - --\&* \fB res\fR puts the center of mass of residues in the box. -+\&\fB * res\fR puts the center of mass of residues in the box. - --\&* \fB atom\fR puts all the atoms in the box. -+\&\fB * atom\fR puts all the atoms in the box. - --\&* \fB nojump\fR checks if atoms jump across the box and then puts -+\&\fB * nojump\fR checks if atoms jump across the box and then puts - \&them back. This has the effect that all molecules - \&will remain whole (provided they were whole in the initial --\&conformation), note that this ensures a continuous trajectory but -+\&conformation). \fB Note\fR that this ensures a continuous trajectory but - \&molecules may diffuse out of the box. The starting configuration - \&for this procedure is taken from the structure file, if one is - \&supplied, otherwise it is the first frame. - --\&* \fB cluster\fR clusters all the atoms in the selected index --\&such that they are all closest to the center of mass of the cluster --\&which is iteratively updated. Note that this will only give meaningful -+\&\fB * cluster\fR clusters all the atoms in the selected index -+\&such that they are all closest to the center of mass of the cluster, -+\&which is iteratively updated. \fB Note\fR that this will only give meaningful - \&results if you in fact have a cluster. Luckily that can be checked - \&afterwards using a trajectory viewer. Note also that if your molecules - \&are broken this will not work either. - --\&* \fB whole\fR only makes broken molecules whole. -+\&The separate option \fB \-clustercenter\fR can be used to specify an -+\&approximate center for the cluster. This is useful e.g. if you have -+\&two big vesicles, and you want to maintain their relative positions. -+ -+\&\fB * whole\fR only makes broken molecules whole. - - - \&Option \fB \-ur\fR sets the unit cell representation for options -@@ -163,7 +168,7 @@ trjconv - converts and manipulates trajectory files - \&\fB tric\fR is the triclinic unit cell. - \&\fB compact\fR puts all atoms at the closest distance from the center - \&of the box. This can be useful for visualizing e.g. truncated --\&octahedrons. The center for options \fB tric\fR and \fB compact\fR -+\&octahedra. The center for options \fB tric\fR and \fB compact\fR - \&is \fB tric\fR (see below), unless the option \fB \-boxcenter\fR - \&is set differently. - -@@ -179,22 +184,19 @@ trjconv - converts and manipulates trajectory files - \&want all molecules in the box after the centering. - - --\&With \fB \-dt\fR it is possible to reduce the number of -+\&With \fB \-dt\fR, it is possible to reduce the number of - \&frames in the output. This option relies on the accuracy of the times - \&in your input trajectory, so if these are inaccurate use the - \&\fB \-timestep\fR option to modify the time (this can be done --\&simultaneously). For making smooth movies the program \fB g_filter\fR -+\&simultaneously). For making smooth movies, the program \fB g_filter\fR - \&can reduce the number of frames while using low\-pass frequency - \&filtering, this reduces aliasing of high frequency motions. - - --\&Using \fB \-trunc\fR trjconv can truncate \fB .trj\fR in place, i.e. -+\&Using \fB \-trunc\fR \fB trjconv\fR can truncate \fB .trj\fR in place, i.e. - \&without copying the file. This is useful when a run has crashed --\&during disk I/O (one more disk full), or when two contiguous --\&trajectories must be concatenated without have double frames. -- -- --\&\fB trjcat\fR is more suitable for concatenating trajectory files. -+\&during disk I/O (i.e. full disk), or when two contiguous -+\&trajectories must be concatenated without having double frames. - - - \&Option \fB \-dump\fR can be used to extract a frame at or near -@@ -254,7 +256,7 @@ trjconv - converts and manipulates trajectory files - Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-xvg" " enum" " xmgrace" - xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR -@@ -292,6 +294,9 @@ trjconv - converts and manipulates trajectory files - .BI "\-box" " vector" " 0 0 0" - Size for new cubic box (default: read from input) - -+.BI "\-clustercenter" " vector" " 0 0 0" -+ Optional starting point for pbc cluster option -+ - .BI "\-trans" " vector" " 0 0 0" - All coordinates will be translated by trans. This can advantageously be combined with \-pbc mol \-ur compact. - -@@ -311,7 +316,7 @@ trjconv - converts and manipulates trajectory files - Read and write forces if possible - - .BI "\-trunc" " time" " \-1 " -- Truncate input trj file after this time (ps) -+ Truncate input trajectory file after this time (ps) - - .BI "\-exec" " string" " " - Execute command for every output frame with the frame number as argument -@@ -326,7 +331,7 @@ trjconv - converts and manipulates trajectory files - Write each frame to a separate .gro, .g96 or .pdb file - - .BI "\-nzero" " int" " 0" -- Prepend file number in case you use the \-sep flag with this number of zeroes -+ If the \-sep flag is set, use these many digits for the file numbers and prepend zeros as needed - - .BI "\-dropunder" " real" " 0 " - Drop all frames below this value -@@ -335,7 +340,7 @@ trjconv - converts and manipulates trajectory files - Drop all frames above this value - - .BI "\-[no]conect" "no " -- Add conect records when writing pdb files. Useful for visualization of non\-standard molecules, e.g. coarse grained ones -+ Add conect records when writing \fB .pdb\fR files. Useful for visualization of non\-standard molecules, e.g. coarse grained ones - - .SH SEE ALSO - .BR gromacs(7) -diff --git a/man/man1/trjorder.1 b/man/man1/trjorder.1 -index c882706..40a18cd 100644 ---- a/man/man1/trjorder.1 -+++ b/man/man1/trjorder.1 -@@ -1,8 +1,8 @@ --.TH trjorder 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH trjorder 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - trjorder - orders molecules according to their distance to a group - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3trjorder\fP - .BI "\-f" " traj.xtc " -@@ -23,7 +23,7 @@ trjorder - orders molecules according to their distance to a group - .BI "\-r" " real " - .BI "\-[no]z" "" - .SH DESCRIPTION --\&trjorder orders molecules according to the smallest distance -+\&\fB trjorder\fR orders molecules according to the smallest distance - \&to atoms in a reference group - \&or on z\-coordinate (with option \fB \-z\fR). - \&With distance ordering, it will ask for a group of reference -@@ -36,7 +36,7 @@ trjorder - orders molecules according to their distance to a group - \&to the output trajectory. - - --\&trjorder can be useful for e.g. analyzing the n waters closest to a -+\&\fB trjorder\fR can be useful for e.g. analyzing the n waters closest to a - \&protein. - \&In that case the reference group would be the protein and the group - \&of molecules would consist of all the water atoms. When an index group -@@ -45,8 +45,8 @@ trjorder - orders molecules according to their distance to a group - \& - - --\&If the output file is a pdb file, the distance to the reference target --\&will be stored in the B\-factor field in order to color with e.g. rasmol. -+\&If the output file is a \fB .pdb\fR file, the distance to the reference target -+\&will be stored in the B\-factor field in order to color with e.g. Rasmol. - \& - - -diff --git a/man/man1/xpm2ps.1 b/man/man1/xpm2ps.1 -index 4b46844..216d97f 100644 ---- a/man/man1/xpm2ps.1 -+++ b/man/man1/xpm2ps.1 -@@ -1,8 +1,8 @@ --.TH xpm2ps 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" -+.TH xpm2ps 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" - .SH NAME - xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) - --.B VERSION 4.5 -+.B VERSION 4.5.4-dev-20110404-bc5695c - .SH SYNOPSIS - \f3xpm2ps\fP - .BI "\-f" " root.xpm " -@@ -32,30 +32,30 @@ xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) - .BI "\-cmin" " real " - .BI "\-cmax" " real " - .SH DESCRIPTION --\&xpm2ps makes a beautiful color plot of an XPixelMap file. -+\&\fB xpm2ps\fR makes a beautiful color plot of an XPixelMap file. - \&Labels and axis can be displayed, when they are supplied - \&in the correct matrix format. --\&Matrix data may be generated by programs such as do_dssp, g_rms or --\&g_mdmat. -+\&Matrix data may be generated by programs such as \fB do_dssp\fR, \fB g_rms\fR or -+\&\fB g_mdmat\fR. - - --\&Parameters are set in the \fB m2p\fR file optionally supplied with --\&\fB \-di\fR. Reasonable defaults are provided. Settings for the y\-axis --\&default to those for the x\-axis. Font names have a defaulting hierarchy: -+\&Parameters are set in the \fB .m2p\fR file optionally supplied with -+\&\fB \-di\fR. Reasonable defaults are provided. Settings for the \fI y\fR\-axis -+\&default to those for the \fI x\fR\-axis. Font names have a defaulting hierarchy: - \&titlefont \- legendfont; titlefont \- (xfont \- yfont \- ytickfont) - \&\- xtickfont, e.g. setting titlefont sets all fonts, setting xfont - \&sets yfont, ytickfont and xtickfont. - - --\&When no \fB m2p\fR file is supplied, many setting are set by --\&command line options. The most important option is \fB \-size\fR -+\&When no \fB .m2p\fR file is supplied, many settings are taken from -+\&command line options. The most important option is \fB \-size\fR, - \&which sets the size of the whole matrix in postscript units. - \&This option can be overridden with the \fB \-bx\fR and \fB \-by\fR --\&options (and the corresponding parameters in the \fB m2p\fR file), -+\&options (and the corresponding parameters in the \fB .m2p\fR file), - \&which set the size of a single matrix element. - - --\&With \fB \-f2\fR a 2nd matrix file can be supplied, both matrix -+\&With \fB \-f2\fR a second matrix file can be supplied. Both matrix - \&files will be read simultaneously and the upper left half of the - \&first one (\fB \-f\fR) is plotted together with the lower right - \&half of the second one (\fB \-f2\fR). The diagonal will contain -@@ -67,7 +67,7 @@ xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) - \&If the color coding and legend labels of both matrices are identical, - \&only one legend will be displayed, else two separate legends are - \&displayed. --\&With \fB \-combine\fR an alternative operation can be selected -+\&With \fB \-combine\fR, an alternative operation can be selected - \&to combine the matrices. The output range is automatically set - \&to the actual range of the combined matrix. This can be overridden - \&with \fB \-cmin\fR and \fB \-cmax\fR. -@@ -75,10 +75,10 @@ xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) - - \&\fB \-title\fR can be set to \fB none\fR to suppress the title, or to - \&\fB ylabel\fR to show the title in the Y\-label position (alongside --\&the Y\-axis). -+\&the \fI y\fR\-axis). - - --\&With the \fB \-rainbow\fR option dull grey\-scale matrices can be turned -+\&With the \fB \-rainbow\fR option, dull grayscale matrices can be turned - \&into attractive color pictures. - - -@@ -120,7 +120,7 @@ xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) - Set the nicelevel - - .BI "\-[no]w" "no " -- View output xvg, xpm, eps and pdb files -+ View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files - - .BI "\-[no]frame" "yes " - Display frame, ticks, labels, title and legend -@@ -141,7 +141,7 @@ xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) - Horizontal size of the matrix in ps units - - .BI "\-bx" " real" " 0 " -- Element x\-size, overrides \-size (also y\-size when \-by is not set) -+ Element x\-size, overrides \fB \-size\fR (also y\-size when \fB \-by\fR is not set) - - .BI "\-by" " real" " 0 " - Element y\-size -@@ -156,10 +156,10 @@ xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) - only write out every nr\-th row and column - - .BI "\-[no]zeroline" "no " -- insert line in xpm matrix where axis label is zero -+ insert line in \fB .xpm\fR matrix where axis label is zero - - .BI "\-legoffset" " int" " 0" -- Skip first N colors from xpm file for the legend -+ Skip first N colors from \fB .xpm\fR file for the legend - - .BI "\-combine" " enum" " halves" - Combine two matrices: \fB halves\fR, \fB add\fR, \fB sub\fR, \fB mult\fR or \fB div\fR -diff --git a/share/html/online/Makefile.am b/share/html/online/Makefile.am -index 8e0bcff..37d5fc5 100644 ---- a/share/html/online/Makefile.am -+++ b/share/html/online/Makefile.am -@@ -35,7 +35,7 @@ online_DATA = \ - g_dielectric.html g_saltbr.html mdrun.html xrama.html \ - g_dih.html g_sas.html mk_angndx.html xtc.html \ - g_dipoles.html g_sgangle.html mtx.html xvg.html \ -- g_densmap.html g_sham.html make_edi.html \ -+ g_densmap.html g_sham.html make_edi.html g_densorder.html \ - style.css \ - water.html gmxdemo.html speptide.html yourown.html \ - methanol.html mixed.html protunf.html -diff --git a/share/html/online/g_densorder.html b/share/html/online/g_densorder.html -new file mode 100644 -index 0000000..6df73d5 ---- /dev/null -+++ b/share/html/online/g_densorder.html -@@ -0,0 +1,63 @@ -+ -+ -+g_densorder -+ -+ -+ -+
-+ -+ -+ -+
-+

g_densorder

Main Table of Contents

VERSION 4.5.4-dev-20110404-3c0e5ec
-+Mon 4 Apr 2011

-+
-+

Description

-+

-+A small program to reduce a two-phase density distribution -+along an axis, computed over a MD trajectory -+to 2D surfaces fluctuating in time, by a fit to -+a functional profile for interfacial densities -+A time-averaged spatial representation of the -+interfaces can be output with the option -tavg -+

-+

Files

-+ -+ -+ -+ -+ -+ -+ -+ -+ -+
optionfilenametypedescription
-s topol.tpr Input Run input file: tpr tpb tpa
-f traj.xtc Input Trajectory: xtc trr trj gro g96 pdb cpt
-n index.ndx Input Index file
-o Density4D.dat Output, Opt. Generic data file
-or hello.out Output, Opt., Mult. Generic output file
-og interface.xpm Output, Opt., Mult. X PixMap compatible matrix file
-Spect intfspect.out Output, Opt., Mult. Generic output file
-+

-+

Other options

-+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+
optiontypedefaultdescription
-[no]h bool no Print help info and quit
-[no]version bool no Print version info and quit
-nice int 0 Set the nicelevel
-b time 0 First frame (ps) to read from trajectory
-e time 0 Last frame (ps) to read from trajectory
-dt time 0 Only use frame when t MOD dt = first time (ps)
-[no]w bool no View output .xvg, .xpm, .eps and .pdb files
-[no]1d bool no Pseudo-1d interface geometry
-bw real 0.2 Binwidth of density distribution tangential to interface
-bwn real 0.05 Binwidth of density distribution normal to interface
-order int 0 Order of Gaussian filter, order 0 equates to NO filtering
-axis string Z Axis Direction - X, Y or Z
-method enum bisect Interface location method: bisect or functional
-d1 real 0 Bulk density phase 1 (at small z)
-d2 real 1000 Bulk density phase 2 (at large z)
-tblock int 100 Number of frames in one time-block average
-nlevel int 100 Number of Height levels in 2D - XPixMaps
-+

-+


-+ -+ -diff --git a/share/top/amber03.ff/ions.itp b/share/top/amber03.ff/ions.itp -index 0ab05f9..fe13ab6 100644 ---- a/share/top/amber03.ff/ions.itp -+++ b/share/top/amber03.ff/ions.itp -@@ -4,7 +4,7 @@ IB+ 1 ; big positive ion - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 IB 1 IB+ IB 1 1.00000 -+1 IB 1 IB+ IB 1 1.00000 - - - [ moleculetype ] -@@ -13,7 +13,7 @@ CA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 C0 1 CA CA 1 2.00000 -+1 C0 1 CA CA 1 2.00000 - - - [ moleculetype ] -@@ -22,7 +22,7 @@ CL 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cl 1 CL CL 1 -1.00000 -+1 Cl 1 CL CL 1 -1.00000 - - - [ moleculetype ] -@@ -31,7 +31,7 @@ NA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Na 1 NA NA 1 1.00000 -+1 Na 1 NA NA 1 1.00000 - - - [ moleculetype ] -@@ -40,7 +40,7 @@ MG 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 MG 1 MG MG 1 2.00000 -+1 MG 1 MG MG 1 2.00000 - - - [ moleculetype ] -@@ -49,7 +49,7 @@ K 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 K 1 K K 1 1.00000 -+1 K 1 K K 1 1.00000 - - - [ moleculetype ] -@@ -58,7 +58,7 @@ RB 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Rb 1 RB RB 1 1.00000 -+1 Rb 1 RB RB 1 1.00000 - - - [ moleculetype ] -@@ -67,7 +67,7 @@ CS 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cs 1 CS CS 1 1.00000 -+1 Cs 1 CS CS 1 1.00000 - - - [ moleculetype ] -@@ -76,7 +76,7 @@ LI 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Li 1 LI LI 1 1.00000 -+1 Li 1 LI LI 1 1.00000 - - - [ moleculetype ] -@@ -85,4 +85,4 @@ ZN 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Zn 1 ZN ZN 1 2.00000 -+1 Zn 1 ZN ZN 1 2.00000 -diff --git a/share/top/amber94.ff/ions.itp b/share/top/amber94.ff/ions.itp -index 0ab05f9..fe13ab6 100644 ---- a/share/top/amber94.ff/ions.itp -+++ b/share/top/amber94.ff/ions.itp -@@ -4,7 +4,7 @@ IB+ 1 ; big positive ion - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 IB 1 IB+ IB 1 1.00000 -+1 IB 1 IB+ IB 1 1.00000 - - - [ moleculetype ] -@@ -13,7 +13,7 @@ CA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 C0 1 CA CA 1 2.00000 -+1 C0 1 CA CA 1 2.00000 - - - [ moleculetype ] -@@ -22,7 +22,7 @@ CL 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cl 1 CL CL 1 -1.00000 -+1 Cl 1 CL CL 1 -1.00000 - - - [ moleculetype ] -@@ -31,7 +31,7 @@ NA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Na 1 NA NA 1 1.00000 -+1 Na 1 NA NA 1 1.00000 - - - [ moleculetype ] -@@ -40,7 +40,7 @@ MG 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 MG 1 MG MG 1 2.00000 -+1 MG 1 MG MG 1 2.00000 - - - [ moleculetype ] -@@ -49,7 +49,7 @@ K 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 K 1 K K 1 1.00000 -+1 K 1 K K 1 1.00000 - - - [ moleculetype ] -@@ -58,7 +58,7 @@ RB 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Rb 1 RB RB 1 1.00000 -+1 Rb 1 RB RB 1 1.00000 - - - [ moleculetype ] -@@ -67,7 +67,7 @@ CS 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cs 1 CS CS 1 1.00000 -+1 Cs 1 CS CS 1 1.00000 - - - [ moleculetype ] -@@ -76,7 +76,7 @@ LI 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Li 1 LI LI 1 1.00000 -+1 Li 1 LI LI 1 1.00000 - - - [ moleculetype ] -@@ -85,4 +85,4 @@ ZN 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Zn 1 ZN ZN 1 2.00000 -+1 Zn 1 ZN ZN 1 2.00000 -diff --git a/share/top/amber99.ff/ions.itp b/share/top/amber99.ff/ions.itp -index 0ab05f9..fe13ab6 100644 ---- a/share/top/amber99.ff/ions.itp -+++ b/share/top/amber99.ff/ions.itp -@@ -4,7 +4,7 @@ IB+ 1 ; big positive ion - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 IB 1 IB+ IB 1 1.00000 -+1 IB 1 IB+ IB 1 1.00000 - - - [ moleculetype ] -@@ -13,7 +13,7 @@ CA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 C0 1 CA CA 1 2.00000 -+1 C0 1 CA CA 1 2.00000 - - - [ moleculetype ] -@@ -22,7 +22,7 @@ CL 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cl 1 CL CL 1 -1.00000 -+1 Cl 1 CL CL 1 -1.00000 - - - [ moleculetype ] -@@ -31,7 +31,7 @@ NA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Na 1 NA NA 1 1.00000 -+1 Na 1 NA NA 1 1.00000 - - - [ moleculetype ] -@@ -40,7 +40,7 @@ MG 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 MG 1 MG MG 1 2.00000 -+1 MG 1 MG MG 1 2.00000 - - - [ moleculetype ] -@@ -49,7 +49,7 @@ K 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 K 1 K K 1 1.00000 -+1 K 1 K K 1 1.00000 - - - [ moleculetype ] -@@ -58,7 +58,7 @@ RB 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Rb 1 RB RB 1 1.00000 -+1 Rb 1 RB RB 1 1.00000 - - - [ moleculetype ] -@@ -67,7 +67,7 @@ CS 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cs 1 CS CS 1 1.00000 -+1 Cs 1 CS CS 1 1.00000 - - - [ moleculetype ] -@@ -76,7 +76,7 @@ LI 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Li 1 LI LI 1 1.00000 -+1 Li 1 LI LI 1 1.00000 - - - [ moleculetype ] -@@ -85,4 +85,4 @@ ZN 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Zn 1 ZN ZN 1 2.00000 -+1 Zn 1 ZN ZN 1 2.00000 -diff --git a/share/top/amber99sb-ildn.ff/ions.itp b/share/top/amber99sb-ildn.ff/ions.itp -index 0ab05f9..fe13ab6 100644 ---- a/share/top/amber99sb-ildn.ff/ions.itp -+++ b/share/top/amber99sb-ildn.ff/ions.itp -@@ -4,7 +4,7 @@ IB+ 1 ; big positive ion - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 IB 1 IB+ IB 1 1.00000 -+1 IB 1 IB+ IB 1 1.00000 - - - [ moleculetype ] -@@ -13,7 +13,7 @@ CA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 C0 1 CA CA 1 2.00000 -+1 C0 1 CA CA 1 2.00000 - - - [ moleculetype ] -@@ -22,7 +22,7 @@ CL 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cl 1 CL CL 1 -1.00000 -+1 Cl 1 CL CL 1 -1.00000 - - - [ moleculetype ] -@@ -31,7 +31,7 @@ NA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Na 1 NA NA 1 1.00000 -+1 Na 1 NA NA 1 1.00000 - - - [ moleculetype ] -@@ -40,7 +40,7 @@ MG 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 MG 1 MG MG 1 2.00000 -+1 MG 1 MG MG 1 2.00000 - - - [ moleculetype ] -@@ -49,7 +49,7 @@ K 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 K 1 K K 1 1.00000 -+1 K 1 K K 1 1.00000 - - - [ moleculetype ] -@@ -58,7 +58,7 @@ RB 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Rb 1 RB RB 1 1.00000 -+1 Rb 1 RB RB 1 1.00000 - - - [ moleculetype ] -@@ -67,7 +67,7 @@ CS 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cs 1 CS CS 1 1.00000 -+1 Cs 1 CS CS 1 1.00000 - - - [ moleculetype ] -@@ -76,7 +76,7 @@ LI 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Li 1 LI LI 1 1.00000 -+1 Li 1 LI LI 1 1.00000 - - - [ moleculetype ] -@@ -85,4 +85,4 @@ ZN 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Zn 1 ZN ZN 1 2.00000 -+1 Zn 1 ZN ZN 1 2.00000 -diff --git a/share/top/amber99sb.ff/ions.itp b/share/top/amber99sb.ff/ions.itp -index 0ab05f9..fe13ab6 100644 ---- a/share/top/amber99sb.ff/ions.itp -+++ b/share/top/amber99sb.ff/ions.itp -@@ -4,7 +4,7 @@ IB+ 1 ; big positive ion - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 IB 1 IB+ IB 1 1.00000 -+1 IB 1 IB+ IB 1 1.00000 - - - [ moleculetype ] -@@ -13,7 +13,7 @@ CA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 C0 1 CA CA 1 2.00000 -+1 C0 1 CA CA 1 2.00000 - - - [ moleculetype ] -@@ -22,7 +22,7 @@ CL 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cl 1 CL CL 1 -1.00000 -+1 Cl 1 CL CL 1 -1.00000 - - - [ moleculetype ] -@@ -31,7 +31,7 @@ NA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Na 1 NA NA 1 1.00000 -+1 Na 1 NA NA 1 1.00000 - - - [ moleculetype ] -@@ -40,7 +40,7 @@ MG 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 MG 1 MG MG 1 2.00000 -+1 MG 1 MG MG 1 2.00000 - - - [ moleculetype ] -@@ -49,7 +49,7 @@ K 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 K 1 K K 1 1.00000 -+1 K 1 K K 1 1.00000 - - - [ moleculetype ] -@@ -58,7 +58,7 @@ RB 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Rb 1 RB RB 1 1.00000 -+1 Rb 1 RB RB 1 1.00000 - - - [ moleculetype ] -@@ -67,7 +67,7 @@ CS 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cs 1 CS CS 1 1.00000 -+1 Cs 1 CS CS 1 1.00000 - - - [ moleculetype ] -@@ -76,7 +76,7 @@ LI 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Li 1 LI LI 1 1.00000 -+1 Li 1 LI LI 1 1.00000 - - - [ moleculetype ] -@@ -85,4 +85,4 @@ ZN 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Zn 1 ZN ZN 1 2.00000 -+1 Zn 1 ZN ZN 1 2.00000 -diff --git a/share/top/amberGS.ff/ions.itp b/share/top/amberGS.ff/ions.itp -index 0ab05f9..fe13ab6 100644 ---- a/share/top/amberGS.ff/ions.itp -+++ b/share/top/amberGS.ff/ions.itp -@@ -4,7 +4,7 @@ IB+ 1 ; big positive ion - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 IB 1 IB+ IB 1 1.00000 -+1 IB 1 IB+ IB 1 1.00000 - - - [ moleculetype ] -@@ -13,7 +13,7 @@ CA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 C0 1 CA CA 1 2.00000 -+1 C0 1 CA CA 1 2.00000 - - - [ moleculetype ] -@@ -22,7 +22,7 @@ CL 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cl 1 CL CL 1 -1.00000 -+1 Cl 1 CL CL 1 -1.00000 - - - [ moleculetype ] -@@ -31,7 +31,7 @@ NA 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Na 1 NA NA 1 1.00000 -+1 Na 1 NA NA 1 1.00000 - - - [ moleculetype ] -@@ -40,7 +40,7 @@ MG 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 MG 1 MG MG 1 2.00000 -+1 MG 1 MG MG 1 2.00000 - - - [ moleculetype ] -@@ -49,7 +49,7 @@ K 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 K 1 K K 1 1.00000 -+1 K 1 K K 1 1.00000 - - - [ moleculetype ] -@@ -58,7 +58,7 @@ RB 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Rb 1 RB RB 1 1.00000 -+1 Rb 1 RB RB 1 1.00000 - - - [ moleculetype ] -@@ -67,7 +67,7 @@ CS 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Cs 1 CS CS 1 1.00000 -+1 Cs 1 CS CS 1 1.00000 - - - [ moleculetype ] -@@ -76,7 +76,7 @@ LI 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Li 1 LI LI 1 1.00000 -+1 Li 1 LI LI 1 1.00000 - - - [ moleculetype ] -@@ -85,4 +85,4 @@ ZN 1 - - [ atoms ] - ; id at type res nr residu name at name cg nr charge -- 1 Zn 1 ZN ZN 1 2.00000 -+1 Zn 1 ZN ZN 1 2.00000 -diff --git a/share/top/charmm27.ff/ions.itp b/share/top/charmm27.ff/ions.itp -index d900cb0..38e71c3 100644 ---- a/share/top/charmm27.ff/ions.itp -+++ b/share/top/charmm27.ff/ions.itp -@@ -1,68 +1,68 @@ - [ moleculetype ] ; added by Bjelkmar Jan 2010, from c32b1/toppar/stream/toppar_water_ions.str --; molname nrexcl --OH 1 -+; molname nrexcl -+OH 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 OC 1 OH O1 1 -1.32 --2 H 1 OH H1 1 0.32 -+; id at type res nr residu name at name cg nr charge mass -+1 OC 1 OH O1 1 -1.32 -+2 H 1 OH H1 1 0.32 - - [ bonds ] --;i j funct length force.c. --1 2 1 0.09700 456056 ; hydroxyl bond -+;i j funct length force.c. -+1 2 1 0.09700 456056 ; hydroxyl bond - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 SOD 1 NA NA 1 1 -+; id at type res nr residu name at name cg nr charge -+1 SOD 1 NA NA 1 1 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 MG 1 MG MG 1 2 -+; id at type res nr residu name at name cg nr charge -+1 MG 1 MG MG 1 2 - - [ moleculetype ] --; molname nrexcl --K 1 -+; molname nrexcl -+K 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 POT 1 K K 1 1 -+; id at type res nr residu name at name cg nr charge -+1 POT 1 K K 1 1 - - [ moleculetype ] --; molname nrexcl --Ces 1 -+; molname nrexcl -+CS 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 CES 1 Ces Ces 1 1 -+; id at type res nr residu name at name cg nr charge -+1 CES 1 CS CS 1 1 - - [ moleculetype ] --; molname nrexcl --Cal 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 CAL 1 Cal Cal 1 2 -+; id at type res nr residu name at name cg nr charge -+1 CAL 1 CA CA 1 2 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 CLA 1 CL CL 1 -1 -+; id at type res nr residu name at name cg nr charge -+1 CLA 1 CL CL 1 -1 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 ZN 1 ZN ZN 1 -2 -+; id at type res nr residu name at name cg nr charge -+1 ZN 1 ZN ZN 1 -2 -diff --git a/share/top/gmx.ff/ions.itp b/share/top/gmx.ff/ions.itp -index 8099fe7..530d309 100644 ---- a/share/top/gmx.ff/ions.itp -+++ b/share/top/gmx.ff/ions.itp -@@ -7,41 +7,41 @@ K 1 - 1 K 1 K K 1 1 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 NA 1 NA NA 1 1 -+; id at type res nr residu name at name cg nr charge -+1 NA 1 NA NA 1 1 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 CA 1 CA CA 1 2 -+; id at type res nr residu name at name cg nr charge -+1 CA 1 CA CA 1 2 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 MG 1 MG MG 1 2 -+; id at type res nr residu name at name cg nr charge -+1 MG 1 MG MG 1 2 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 CL 1 CL CL 1 -1 -+; id at type res nr residu name at name cg nr charge -+1 CL 1 CL CL 1 -1 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 ZN 1 ZN ZN 1 2 -+; id at type res nr residu name at name cg nr charge -+1 ZN 1 ZN ZN 1 2 -diff --git a/share/top/gmx2.ff/ions.itp b/share/top/gmx2.ff/ions.itp -index 8099fe7..530d309 100644 ---- a/share/top/gmx2.ff/ions.itp -+++ b/share/top/gmx2.ff/ions.itp -@@ -7,41 +7,41 @@ K 1 - 1 K 1 K K 1 1 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 NA 1 NA NA 1 1 -+; id at type res nr residu name at name cg nr charge -+1 NA 1 NA NA 1 1 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 CA 1 CA CA 1 2 -+; id at type res nr residu name at name cg nr charge -+1 CA 1 CA CA 1 2 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 MG 1 MG MG 1 2 -+; id at type res nr residu name at name cg nr charge -+1 MG 1 MG MG 1 2 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 CL 1 CL CL 1 -1 -+; id at type res nr residu name at name cg nr charge -+1 CL 1 CL CL 1 -1 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge --1 ZN 1 ZN ZN 1 2 -+; id at type res nr residu name at name cg nr charge -+1 ZN 1 ZN ZN 1 2 -diff --git a/share/top/gromos43a1.ff/ions.itp b/share/top/gromos43a1.ff/ions.itp -index 07c3d06..ed76e0d 100644 ---- a/share/top/gromos43a1.ff/ions.itp -+++ b/share/top/gromos43a1.ff/ions.itp -@@ -1,55 +1,55 @@ - [ moleculetype ] --; molname nrexcl --CU1 1 -+; molname nrexcl -+CU1 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU1+ 1 CU1 CU 1 1 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU1+ 1 CU1 CU 1 1 63.54600 - - [ moleculetype ] --; molname nrexcl --CU 1 -+; molname nrexcl -+CU 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU2+ 1 CU CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU2+ 1 CU CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 ZN2+ 1 ZN ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 ZN2+ 1 ZN ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 MG2+ 1 MG MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 MG2+ 1 MG MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CA2+ 1 CA CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 CA2+ 1 CA CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 NA+ 1 NA NA 1 1 22.9898 -+; id at type res nr residu name at name cg nr charge mass -+1 NA+ 1 NA NA 1 1 22.9898 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CL- 1 CL CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 CL- 1 CL CL 1 -1 35.45300 -diff --git a/share/top/gromos43a2.ff/ions.itp b/share/top/gromos43a2.ff/ions.itp -index 07c3d06..ed76e0d 100644 ---- a/share/top/gromos43a2.ff/ions.itp -+++ b/share/top/gromos43a2.ff/ions.itp -@@ -1,55 +1,55 @@ - [ moleculetype ] --; molname nrexcl --CU1 1 -+; molname nrexcl -+CU1 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU1+ 1 CU1 CU 1 1 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU1+ 1 CU1 CU 1 1 63.54600 - - [ moleculetype ] --; molname nrexcl --CU 1 -+; molname nrexcl -+CU 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU2+ 1 CU CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU2+ 1 CU CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 ZN2+ 1 ZN ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 ZN2+ 1 ZN ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 MG2+ 1 MG MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 MG2+ 1 MG MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CA2+ 1 CA CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 CA2+ 1 CA CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 NA+ 1 NA NA 1 1 22.9898 -+; id at type res nr residu name at name cg nr charge mass -+1 NA+ 1 NA NA 1 1 22.9898 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CL- 1 CL CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 CL- 1 CL CL 1 -1 35.45300 -diff --git a/share/top/gromos45a3.ff/ions.itp b/share/top/gromos45a3.ff/ions.itp -index 07c3d06..c0d70db 100644 ---- a/share/top/gromos45a3.ff/ions.itp -+++ b/share/top/gromos45a3.ff/ions.itp -@@ -1,55 +1,55 @@ - [ moleculetype ] --; molname nrexcl --CU1 1 -+; molname nrexcl -+CU1 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU1+ 1 CU1 CU 1 1 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU1+ 1 CU1 CU 1 1 63.54600 - - [ moleculetype ] --; molname nrexcl --CU 1 -+; molname nrexcl -+CU 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU2+ 1 CU CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU2+ 1 CU CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 ZN2+ 1 ZN ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 ZN2+ 1 ZN ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 MG2+ 1 MG MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 MG2+ 1 MG MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CA2+ 1 CA CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 CA2+ 1 CA CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 NA+ 1 NA NA 1 1 22.9898 -+; id at type res nr residu name at name cg nr charge mass -+1 NA+ 1 NA NA 1 1 22.9898 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CL- 1 CL CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 CL- 1 CL CL 1 -1 35.45300 -diff --git a/share/top/gromos53a5.ff/ions.itp b/share/top/gromos53a5.ff/ions.itp -index 07c3d06..c0d70db 100644 ---- a/share/top/gromos53a5.ff/ions.itp -+++ b/share/top/gromos53a5.ff/ions.itp -@@ -1,55 +1,55 @@ - [ moleculetype ] --; molname nrexcl --CU1 1 -+; molname nrexcl -+CU1 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU1+ 1 CU1 CU 1 1 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU1+ 1 CU1 CU 1 1 63.54600 - - [ moleculetype ] --; molname nrexcl --CU 1 -+; molname nrexcl -+CU 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU2+ 1 CU CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU2+ 1 CU CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 ZN2+ 1 ZN ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 ZN2+ 1 ZN ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 MG2+ 1 MG MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 MG2+ 1 MG MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CA2+ 1 CA CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 CA2+ 1 CA CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 NA+ 1 NA NA 1 1 22.9898 -+; id at type res nr residu name at name cg nr charge mass -+1 NA+ 1 NA NA 1 1 22.9898 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CL- 1 CL CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 CL- 1 CL CL 1 -1 35.45300 -diff --git a/share/top/gromos53a6.ff/ions.itp b/share/top/gromos53a6.ff/ions.itp -index 07c3d06..c0d70db 100644 ---- a/share/top/gromos53a6.ff/ions.itp -+++ b/share/top/gromos53a6.ff/ions.itp -@@ -1,55 +1,55 @@ - [ moleculetype ] --; molname nrexcl --CU1 1 -+; molname nrexcl -+CU1 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU1+ 1 CU1 CU 1 1 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU1+ 1 CU1 CU 1 1 63.54600 - - [ moleculetype ] --; molname nrexcl --CU 1 -+; molname nrexcl -+CU 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU2+ 1 CU CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU2+ 1 CU CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 ZN2+ 1 ZN ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 ZN2+ 1 ZN ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 MG2+ 1 MG MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 MG2+ 1 MG MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CA2+ 1 CA CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 CA2+ 1 CA CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 NA+ 1 NA NA 1 1 22.9898 -+; id at type res nr residu name at name cg nr charge mass -+1 NA+ 1 NA NA 1 1 22.9898 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CL- 1 CL CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 CL- 1 CL CL 1 -1 35.45300 -diff --git a/share/top/ions.itp b/share/top/ions.itp -index 48c3d7a..7bf7bad 100644 ---- a/share/top/ions.itp -+++ b/share/top/ions.itp -@@ -13,60 +13,60 @@ - ; do not have the signs of the ions in the molecule name. - - [ moleculetype ] --; molname nrexcl --CU1+ 1 -+; molname nrexcl -+CU1+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU1+ 1 CU1+ CU1+ 1 1 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU1+ 1 CU1+ CU1+ 1 1 63.54600 - - [ moleculetype ] --; molname nrexcl --CU2+ 1 -+; molname nrexcl -+CU2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CU2+ 1 CU2+ CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 CU2+ 1 CU2+ CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN2+ 1 -+; molname nrexcl -+ZN2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 ZN2+ 1 ZN2+ ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 ZN2+ 1 ZN2+ ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG2+ 1 -+; molname nrexcl -+MG2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 MG2+ 1 MG2+ MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 MG2+ 1 MG2+ MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA2+ 1 -+; molname nrexcl -+CA2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CA2+ 1 CA2+ CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 CA2+ 1 CA2+ CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --NA+ 1 -+; molname nrexcl -+NA+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 NA+ 1 NA+ NA 1 1 22.9898 -+; id at type res nr residu name at name cg nr charge mass -+1 NA+ 1 NA+ NA 1 1 22.9898 - - [ moleculetype ] --; molname nrexcl --CL- 1 -+; molname nrexcl -+CL- 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 CL- 1 CL- CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 CL- 1 CL- CL 1 -1 35.45300 - - - #include "gromos43a1.ff/ions.itp" -@@ -79,107 +79,107 @@ CL- 1 - ; do not have the signs of the ions in the molecule name. - - [ moleculetype ] --; molname nrexcl --CU2+ 1 -+; molname nrexcl -+CU2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 Cu2+ 1 CU2+ CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 Cu2+ 1 CU2+ CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN2+ 1 -+; molname nrexcl -+ZN2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 Zn2+ 1 ZN2+ ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 Zn2+ 1 ZN2+ ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG2+ 1 -+; molname nrexcl -+MG2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_411 1 MG2+ MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_411 1 MG2+ MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA2+ 1 -+; molname nrexcl -+CA2+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_412 1 CA2+ CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_412 1 CA2+ CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --LI+ 1 -+; molname nrexcl -+LI+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_406 1 LI+ NA 1 1 6.941 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_406 1 LI+ LI 1 1 6.941 - - [ moleculetype ] --; molname nrexcl --NA+ 1 -+; molname nrexcl -+NA+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_407 1 NA+ NA 1 1 22.98977 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_407 1 NA+ NA 1 1 22.98977 - - [ moleculetype ] --; molname nrexcl --K+ 1 -+; molname nrexcl -+K+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_408 1 K+ K 1 1 39.0983 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_408 1 K+ K 1 1 39.0983 - - [ moleculetype ] --; molname nrexcl --Rb+ 1 -+; molname nrexcl -+Rb+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_409 1 Rb+ Rb 1 1 85.4678 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_409 1 Rb+ Rb 1 1 85.4678 - - [ moleculetype ] --; molname nrexcl --Cs+ 1 -+; molname nrexcl -+Cs+ 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_410 1 Cs+ Cs 1 1 132.9054 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_410 1 Cs+ Cs 1 1 132.9054 - - [ moleculetype ] --; molname nrexcl --F- 1 -+; molname nrexcl -+F- 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_400 1 F- F 1 -1 18.9984 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_400 1 F- F 1 -1 18.9984 - - [ moleculetype ] --; molname nrexcl --CL- 1 -+; molname nrexcl -+CL- 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_401 1 CL- CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_401 1 CL- CL 1 -1 35.45300 - - [ moleculetype ] --; molname nrexcl --BR- 1 -+; molname nrexcl -+BR- 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_402 1 BR- BR 1 -1 79.904 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_402 1 BR- BR 1 -1 79.904 - - [ moleculetype ] --; molname nrexcl --I- 1 -+; molname nrexcl -+I- 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_403 1 I- I 1 -1 126.9045 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_403 1 I- I 1 -1 126.9045 - - #endif -diff --git a/share/top/oplsaa.ff/ions.itp b/share/top/oplsaa.ff/ions.itp -index e831a92..9e82720 100644 ---- a/share/top/oplsaa.ff/ions.itp -+++ b/share/top/oplsaa.ff/ions.itp -@@ -3,105 +3,105 @@ - ; - - [ moleculetype ] --; molname nrexcl --CU 1 -+; molname nrexcl -+CU 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 Cu2+ 1 CU CU 1 2 63.54600 -+; id at type res nr residu name at name cg nr charge mass -+1 Cu2+ 1 CU CU 1 2 63.54600 - - [ moleculetype ] --; molname nrexcl --ZN 1 -+; molname nrexcl -+ZN 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 Zn2+ 1 ZN ZN 1 2 65.37000 -+; id at type res nr residu name at name cg nr charge mass -+1 Zn2+ 1 ZN ZN 1 2 65.37000 - - [ moleculetype ] --; molname nrexcl --MG 1 -+; molname nrexcl -+MG 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_411 1 MG MG 1 2 24.30500 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_411 1 MG MG 1 2 24.30500 - - [ moleculetype ] --; molname nrexcl --CA 1 -+; molname nrexcl -+CA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_412 1 CA CA 1 2 40.08000 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_412 1 CA CA 1 2 40.08000 - - [ moleculetype ] --; molname nrexcl --LI 1 -+; molname nrexcl -+LI 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_406 1 LI NA 1 1 6.941 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_406 1 LI LI 1 1 6.941 - - [ moleculetype ] --; molname nrexcl --NA 1 -+; molname nrexcl -+NA 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_407 1 NA NA 1 1 22.98977 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_407 1 NA NA 1 1 22.98977 - - [ moleculetype ] --; molname nrexcl --K 1 -+; molname nrexcl -+K 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_408 1 K K 1 1 39.0983 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_408 1 K K 1 1 39.0983 - - [ moleculetype ] --; molname nrexcl --RB 1 -+; molname nrexcl -+RB 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_409 1 RB RB 1 1 85.4678 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_409 1 RB RB 1 1 85.4678 - - [ moleculetype ] --; molname nrexcl --CS 1 -+; molname nrexcl -+CS 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_410 1 CS CS 1 1 132.9054 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_410 1 CS CS 1 1 132.9054 - - [ moleculetype ] --; molname nrexcl --F 1 -+; molname nrexcl -+F 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_400 1 F F 1 -1 18.9984 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_400 1 F F 1 -1 18.9984 - - [ moleculetype ] --; molname nrexcl --CL 1 -+; molname nrexcl -+CL 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_401 1 CL- CL 1 -1 35.45300 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_401 1 CL CL 1 -1 35.45300 - - [ moleculetype ] --; molname nrexcl --BR 1 -+; molname nrexcl -+BR 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_402 1 BR BR 1 -1 79.904 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_402 1 BR BR 1 -1 79.904 - - [ moleculetype ] --; molname nrexcl --I 1 -+; molname nrexcl -+I 1 - - [ atoms ] --; id at type res nr residu name at name cg nr charge mass --1 opls_403 1 I I 1 -1 126.9045 -+; id at type res nr residu name at name cg nr charge mass -+1 opls_403 1 I I 1 -1 126.9045 -diff --git a/src/config.h.cmakein b/src/config.h.cmakein -index 1e3c542..89c9c8a 100644 ---- a/src/config.h.cmakein -+++ b/src/config.h.cmakein -@@ -61,6 +61,9 @@ - */ - #cmakedefine GMX_FLOAT_FORMAT_IEEE754 - -+/* Detect Cygwin */ -+#cmakedefine GMX_CYGWIN -+ - /* Use assembly intrinsics kernels for BlueGene */ - #cmakedefine GMX_BLUEGENE - -@@ -167,6 +170,12 @@ - /* Define for profiling option */ - #cmakedefine TMPI_PROFILE - -+/* Define for Linux pthread_setaffinity */ -+#cmakedefine HAVE_PTHREAD_SETAFFINITY -+ -+/* Define for Windows NUMA-aware allocator functions*/ -+#cmakedefine TMPI_WINDOWS_NUMA_API -+ - /* Define for sysconf() */ - #cmakedefine HAVE_SYSCONF - -diff --git a/src/gmxlib/gmx_system_xdr.c b/src/gmxlib/gmx_system_xdr.c -index 184faac..e66a599 100644 ---- a/src/gmxlib/gmx_system_xdr.c -+++ b/src/gmxlib/gmx_system_xdr.c -@@ -95,7 +95,7 @@ - /* - * for unit alignment - */ --const static char xdr_zero[BYTES_PER_XDR_UNIT] = {0, 0, 0, 0}; -+static char xdr_zero[BYTES_PER_XDR_UNIT] = {0, 0, 0, 0}; - - static xdr_uint32_t xdr_swapbytes(xdr_uint32_t x) - { -diff --git a/src/gmxlib/index.c b/src/gmxlib/index.c -index 0cb96f6..725b98f 100644 ---- a/src/gmxlib/index.c -+++ b/src/gmxlib/index.c -@@ -148,7 +148,7 @@ static gmx_bool grp_cmp(t_blocka *b, int nra, atom_id a[], int index) - } - - static void --p_status(const char **restype, int nres, const char **typenames, int ntypes, gmx_bool bVerb) -+p_status(const char **restype, int nres, const char **typenames, int ntypes) - { - int i,j; - int found; -@@ -172,16 +172,15 @@ p_status(const char **restype, int nres, const char **typenames, int ntypes, gmx - } - } - -- if (bVerb) -+ for(i=0; (i 0) - { -- if(counter[i]>0) -- { -- printf("There are: %5d %10s residues\n",counter[i],typenames[i]); -- } -+ printf("There are: %5d %10s residues\n",counter[i],typenames[i]); - } - } -+ -+ sfree(counter); - } - - -@@ -741,30 +740,25 @@ void analyse(t_atoms *atoms,t_blocka *gb,char ***gn,gmx_bool bASK,gmx_bool bVerb - resnm = *atoms->resinfo[i].name; - gmx_residuetype_get_type(rt,resnm,&(restype[i])); - -- if(i==0) -+ /* Note that this does not lead to a N*N loop, but N*K, where -+ * K is the number of residue _types_, which is small and independent of N. -+ */ -+ found = 0; -+ for(k=0;knres,p_typename,ntypes,bVerb); -+ if (bVerb) -+ { -+ p_status(restype,atoms->nres,p_typename,ntypes); -+ } - - for(k=0;k=0) - gmx_incons("Not enough rows in the matrix"); - -- /* This code makes me cry. DvdS 2010-07-08 */ -- /*sfree(line);*/ -+ sfree(line_buf); - } - - int read_xpm_matrix(const char *fnm,t_matrix **matrix) -diff --git a/src/gmxlib/rmpbc.c b/src/gmxlib/rmpbc.c -index 0f7d005..86b7139 100644 ---- a/src/gmxlib/rmpbc.c -+++ b/src/gmxlib/rmpbc.c -@@ -64,7 +64,10 @@ static t_graph *gmx_rmpbc_get_graph(gmx_rmpbc_t gpbc,int ePBC,int natoms) - int i; - rmpbc_graph_t *gr; - -- if (ePBC == epbcNONE || gpbc->idef->ntypes <= 0) -+ if (ePBC == epbcNONE -+ || NULL == gpbc -+ || NULL == gpbc->idef -+ || gpbc->idef->ntypes <= 0) - { - return NULL; - } -@@ -128,19 +131,22 @@ void gmx_rmpbc_done(gmx_rmpbc_t gpbc) - { - int i; - -- for(i=0; ingraph; i++) -- { -- done_graph(gpbc->graph[i].gr); -- } -- if (gpbc->graph != NULL) -+ if (NULL != gpbc) - { -- sfree(gpbc->graph); -+ for(i=0; ingraph; i++) -+ { -+ done_graph(gpbc->graph[i].gr); -+ } -+ if (gpbc->graph != NULL) -+ { -+ sfree(gpbc->graph); -+ } - } - } - - static int gmx_rmpbc_ePBC(gmx_rmpbc_t gpbc,matrix box) - { -- if (gpbc->ePBC >= 0) -+ if (NULL != gpbc && gpbc->ePBC >= 0) - { - return gpbc->ePBC; - } -diff --git a/src/gmxlib/thread_mpi/CMakeLists.txt b/src/gmxlib/thread_mpi/CMakeLists.txt -index b753b69..5aba9ed 100644 ---- a/src/gmxlib/thread_mpi/CMakeLists.txt -+++ b/src/gmxlib/thread_mpi/CMakeLists.txt -@@ -2,7 +2,7 @@ - # Note that not all .c files are compiled directly: some of them - # are #included (some multiple times) from other source files. - set(THREAD_MPI_LIB_SOURCE -- alltoall.c hwinfo.c reduce.c -+ alltoall.c reduce.c - barrier.c list.c reduce_fast.c - bcast.c lock.c scatter.c - collective.c once.c tmpi_init.c -@@ -10,7 +10,7 @@ set(THREAD_MPI_LIB_SOURCE - errhandler.c p2p_send_recv.c type.c - event.c p2p_wait.c - gather.c profile.c -- group.c ) -+ group.c numa_malloc.c) - - - if (THREAD_PTHREADS) -diff --git a/src/gmxlib/thread_mpi/Makefile.am b/src/gmxlib/thread_mpi/Makefile.am -index 51a7cac..e70c43c 100644 ---- a/src/gmxlib/thread_mpi/Makefile.am -+++ b/src/gmxlib/thread_mpi/Makefile.am -@@ -20,7 +20,7 @@ libthread_mpi_la_SOURCES = alltoall.c impl.h pthreads.h \ - event.c p2p_wait.c topology.c \ - gather.c profile.c type.c \ - group.c profile.h winthreads.c \ -- hwinfo.c pthreads.c winthreads.h -+ pthreads.c winthreads.h numa_malloc.c - - - CLEANFILES = *.la *~ \\\#* -diff --git a/src/gmxlib/thread_mpi/hwinfo.c b/src/gmxlib/thread_mpi/hwinfo.c -deleted file mode 100644 -index 1a2a050..0000000 ---- a/src/gmxlib/thread_mpi/hwinfo.c -+++ /dev/null -@@ -1,103 +0,0 @@ --/* --This source code file is part of thread_mpi. --Written by Sander Pronk, Erik Lindahl, and possibly others. -- --Copyright (c) 2009, Sander Pronk, Erik Lindahl. --All rights reserved. -- --Redistribution and use in source and binary forms, with or without --modification, are permitted provided that the following conditions are met: --1) Redistributions of source code must retain the above copyright -- notice, this list of conditions and the following disclaimer. --2) Redistributions in binary form must reproduce the above copyright -- notice, this list of conditions and the following disclaimer in the -- documentation and/or other materials provided with the distribution. --3) Neither the name of the copyright holders nor the -- names of its contributors may be used to endorse or promote products -- derived from this software without specific prior written permission. -- --THIS SOFTWARE IS PROVIDED BY US ''AS IS'' AND ANY --EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED --WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE --DISCLAIMED. IN NO EVENT SHALL WE BE LIABLE FOR ANY --DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES --(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; --LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND --ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT --(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS --SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- --If you want to redistribute modifications, please consider that --scientific software is very special. Version control is crucial - --bugs must be traceable. We will be happy to consider code for --inclusion in the official distribution, but derived work should not --be called official thread_mpi. Details are found in the README & COPYING --files. --*/ -- -- --#ifdef HAVE_TMPI_CONFIG_H --#include "tmpi_config.h" --#else --#ifdef HAVE_CONFIG_H --#include "config.h" --#endif --#endif -- --#ifdef HAVE_UNISTD_H --#include --#endif --#ifdef THREAD_WINDOWS --#include --#endif -- --#include --#include --#include --#include -- --#include "impl.h" --#include "thread_mpi/hwinfo.h" -- --#ifdef TMPI_TRACE --#include --#endif -- -- --int tMPI_Get_hw_nthreads(void) --{ -- int ret=-1; --#ifdef HAVE_SYSCONF --#if defined(_SC_NPROCESSORS_ONLN) -- ret=sysconf(_SC_NPROCESSORS_ONLN); --#elif defined(_SC_NPROC_ONLN) -- ret=sysconf(_SC_NPROC_ONLN); --#elif defined(_SC_NPROCESSORS_CONF) -- ret=sysconf(_SC_NPROCESSORS_CONF); --#elif defined(_SC_NPROC_CONF) -- ret=sysconf(_SC_NPROC_CONF); --#endif --#endif -- --#ifdef THREAD_WINDOWS -- SYSTEM_INFO sysinfo; -- GetSystemInfo( &sysinfo ); -- -- ret=sysinfo.dwNumberOfProcessors; --#endif -- return ret; --} -- -- --int tMPI_Get_recommended_nthreads(void) --{ -- int N=1; /* the default is 1 */ -- --#ifndef TMPI_NO_ATOMICS -- N=tMPI_Get_hw_nthreads(); -- if (N<1) -- N=1; --#endif -- return N; --} -- -diff --git a/src/gmxlib/thread_mpi/impl.h b/src/gmxlib/thread_mpi/impl.h -index 609b15b..cb39f26 100644 ---- a/src/gmxlib/thread_mpi/impl.h -+++ b/src/gmxlib/thread_mpi/impl.h -@@ -62,7 +62,6 @@ files. - #include "thread_mpi/tmpi.h" - #include "thread_mpi/collective.h" - #include "thread_mpi/barrier.h" --#include "thread_mpi/hwinfo.h" - #include "thread_mpi/lock.h" - #ifdef TMPI_PROFILE - #include "profile.h" -@@ -687,17 +686,11 @@ extern struct tmpi_global *tmpi_global; - void tMPI_Trace_print(const char *fmt, ...); - #endif - --/* error-checking malloc/realloc/free: */ -+/* error-checking malloc/realloc: */ - void *tMPI_Malloc(size_t size); - void *tMPI_Realloc(void *p, size_t size); - void tMPI_Free(void *p); - --/* --//use the following instead of the above function definition for debugging mis- matched allocate/free calls. --#include --#define tMPI_Free(a) sfree(a) --*/ -- - - /* get the current thread structure pointer */ - #define tMPI_Get_current() ((struct tmpi_thread*) \ -diff --git a/src/gmxlib/thread_mpi/numa_malloc.c b/src/gmxlib/thread_mpi/numa_malloc.c -new file mode 100644 -index 0000000..bcfd879 ---- /dev/null -+++ b/src/gmxlib/thread_mpi/numa_malloc.c -@@ -0,0 +1,530 @@ -+ -+ -+#ifdef HAVE_TMPI_CONFIG_H -+#include "tmpi_config.h" -+#endif -+ -+ -+#ifdef HAVE_CONFIG_H -+#include "config.h" -+#endif -+ -+ -+#ifdef HAVE_UNISTD_H -+#include -+#endif -+ -+ -+#include -+#include -+#include -+#ifdef WITH_DMALLOC -+#include "dmalloc.h" -+#endif -+ -+ -+#if ! (defined(WIN32) || defined( _WIN32 ) || defined(WIN64) || defined( _WIN64 ) || defined (__CYGWIN__)) -+ -+ -+/* We don't have specific NUMA aware allocators: */ -+ -+void *tMPI_Malloc_local(size_t size) -+{ -+ return malloc(size); -+} -+ -+void *tMPI_Calloc_local(size_t nmemb, size_t size) -+{ -+ return calloc(nmemb, size); -+} -+ -+void *tMPI_Realloc_local(void *ptr, size_t size) -+{ -+ return realloc(ptr, size); -+} -+ -+int tMPI_Free_numa(void *ptr) -+{ -+ free(ptr); -+ return 0; /* we don't detect errors here */ -+} -+ -+#else -+ -+#define TMPI_NUMA_MALLOC -+ -+/* -+ Windows NUMA memory allocation support. -+ -+ NUMA support is implemented to maximize the chance that memory access -+ patterns remain Local to the NUMA node. This avoids penalties accessing -+ "remote" memory. -+ An important assumption here is that code paths which allocate and -+ reallocate heap blocks are likely to be accessing that allocated memory -+ on the same NUMA node. -+ Testing has shown the above criteria to be met, yielding gains of > 15% -+ when on Windows with NUMA hardware. -+ -+ The high level approach is: -+ 1. Use a separate heap per NUMA node. This reduces heap contention, steers -+ allocations to the local NUMA node, and avoids re-use of freed heap -+ blocks across (remote) NUMA nodes. -+ 2. Allocate each heap locally to each NUMA node, such that heap control -+ structures are on the NUMA node accessing the heap. -+ 3. During realloc operations, transfer the new block to the local NUMA -+ node, if appropriate. This is a rare case when thread affinity and -+ access patterns are correct. -+ 4. Use GetProcAddress() to obtain function pointers to functions that are -+ operating system version dependent, to allow maximum binary -+ compatibility. -+ -+ Scott Field (sfield@microsoft.com) Jan-2011 -+ */ -+ -+//#define _WIN32_WINNT 0x0601 -+#include -+ -+ -+ -+/* -+ __declspec(align()) may not be supported by all compilers, so define the -+ size of the structure manually to force alignment -+ note that HeapAlloc() already returns aligned blocks. -+ typedef __declspec(align(32)) struct ... -+*/ -+typedef struct { -+ DWORD dwMagic; -+ HANDLE hHeap; /* 8 */ -+ size_t cbAllocationSize; /* 8 */ -+ ULONG ProcessorNumber; /* processor number at time of allocation -+ (development/testing) */ -+ USHORT NodeNumber; /* NUMA node number at time of allocation -+ (development/testing) */ -+} HEAPHEADER, *PHEAPHEADER; -+ -+#define HEAP_NUMA_MAGIC 0x05AF0777 -+#define HEAPHEADER_SIZE (32) -+ -+#ifdef C_ASSERT -+/* fail compile if size of HEAPHEADER exceeds pre-defined value */ -+C_ASSERT(sizeof(HEAPHEADER) <= HEAPHEADER_SIZE); -+#endif -+ -+/* function prototypes and variables to support obtaining function -+ addresses dynamically -- supports down-level operating systems */ -+ -+typedef BOOL (WINAPI *func_GetNumaHighestNodeNumber_t)( PULONG HighestNodeNumber ); -+typedef BOOL (WINAPI *func_GetNumaProcessorNodeEx_t)( PPROCESSOR_NUMBER Processor, PUSHORT NodeNumber ); -+typedef VOID (WINAPI *func_GetCurrentProcessorNumberEx_t)( PPROCESSOR_NUMBER ProcNumber ); -+ -+func_GetNumaHighestNodeNumber_t smalloc_GetNumaHighestNodeNumber; /* WinXP SP2, WinXP64, WinSrv 2003 */ -+func_GetNumaProcessorNodeEx_t smalloc_GetNumaProcessorNodeEx; /* Windows 7, WinSrv 2008R2 */ -+func_GetCurrentProcessorNumberEx_t smalloc_GetCurrentProcessorNumberEx; /* Windows 7, WinSrv 2008R2 */ -+ -+#define NUMA_STATUS_UNKNOWN (0) -+#define NUMA_STATUS_NOT_NUMA (1) -+#define NUMA_STATUS_NUMA (2) -+ -+DWORD g_dwTlsHeap; /* TLS slot used for preferred heap handle */ -+HANDLE *g_hHeap; /* array of heap handles */ -+ULONG g_ulNumaStatus; /* 0 = unknown, 1 = not NUMA, 2 = NUMA */ -+ -+VOID -+InitNumaHeapSupport( -+ VOID -+ ) -+{ -+ HMODULE hModKernel32; /* module handle to kernel32.dll -- we already -+ reference it, so it's already loaded */ -+ ULONG ulNumaHighestNodeNumber; -+ -+ /* grab the addresses for the NUMA functions. -+ It's fine if there is a race condition reaching this routine */ -+ hModKernel32 = GetModuleHandleA("kernel32.dll"); -+ if(hModKernel32 == NULL) -+ { -+ g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; -+ return; -+ } -+ -+ smalloc_GetNumaHighestNodeNumber = (func_GetNumaHighestNodeNumber_t)GetProcAddress( hModKernel32, "GetNumaHighestNodeNumber" ); -+ smalloc_GetCurrentProcessorNumberEx = (func_GetCurrentProcessorNumberEx_t)GetProcAddress( hModKernel32, "GetCurrentProcessorNumberEx" ); -+ smalloc_GetNumaProcessorNodeEx = (func_GetNumaProcessorNodeEx_t)GetProcAddress( hModKernel32, "GetNumaProcessorNodeEx" ); -+ -+ if( (smalloc_GetNumaHighestNodeNumber == NULL) || -+ (smalloc_GetCurrentProcessorNumberEx == NULL) || -+ (smalloc_GetNumaProcessorNodeEx == NULL) ) -+ { -+ g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; -+ return; -+ } -+ -+ /* determine how many NUMA nodes are present */ -+ -+ if(!smalloc_GetNumaHighestNodeNumber(&ulNumaHighestNodeNumber) || -+ (ulNumaHighestNodeNumber == 0) ) -+ { -+ g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; -+ return; -+ } -+ -+ /* handle deferred creation of TLS slot. -+ note: this could be moved to one-time init path. -+ failures here result in assuming the system is not NUMA. -+ */ -+ -+ if( g_dwTlsHeap == 0 ) -+ { -+ DWORD dwTlsHeap = TlsAlloc(); -+ DWORD dwPriorValue; -+ -+ if( dwTlsHeap == TLS_OUT_OF_INDEXES ) -+ { -+ g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; -+ return; -+ } -+ -+ dwPriorValue = (DWORD)InterlockedCompareExchange( -+ (LONG volatile *)&g_dwTlsHeap, -+ (LONG) dwTlsHeap, -+ 0 -+ ); -+ -+ if( dwPriorValue != 0 ) -+ { -+ TlsFree( dwTlsHeap ); -+ } -+ } -+ -+ /* handle deferred creation of heap handle array. -+ note: this could be moved to one-time init path. -+ */ -+ -+ if( g_hHeap == NULL ) -+ { -+ HANDLE *hHeapNew; -+ HANDLE *hPriorValue; -+ -+ /* allocate an array to contain a heap handle for each NUMA node */ -+ hHeapNew = (HANDLE*)HeapAlloc( -+ GetProcessHeap(), -+ HEAP_ZERO_MEMORY, -+ sizeof(HANDLE) * (ulNumaHighestNodeNumber+1) -+ ); -+ -+ if( hHeapNew == NULL ) -+ { -+ g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; -+ return; -+ } -+ -+ hPriorValue = (HANDLE *)InterlockedCompareExchange( -+ (LONG volatile *)&g_hHeap, -+ (LONG) hHeapNew, -+ 0 -+ ); -+ -+ if( hPriorValue != NULL ) -+ { -+ HeapFree(GetProcessHeap(), 0, hHeapNew); -+ } -+ } -+ -+ /* indicate system is NUMA */ -+ g_ulNumaStatus = NUMA_STATUS_NUMA; -+ -+ return; -+} -+ -+HANDLE -+ReturnHeapHandle( -+ VOID -+ ) -+{ -+ HANDLE hHeap; /* preferred heap handle to -+ return to caller */ -+ PROCESSOR_NUMBER CurrentProcessorNumber; /* processor number associated -+ with calling thread */ -+ USHORT CurrentNumaNodeNumber; /* NUMA node number assocaited -+ with calling thread */ -+ -+ /* determine NUMA status of system. */ -+ -+ if( g_ulNumaStatus == NUMA_STATUS_UNKNOWN ) -+ { -+ InitNumaHeapSupport(); -+ if( g_ulNumaStatus == NUMA_STATUS_NOT_NUMA ) -+ { -+ return GetProcessHeap(); -+ } -+ } else if( g_ulNumaStatus == NUMA_STATUS_NOT_NUMA ) -+ { -+ /* not NUMA, return the process heap handle */ -+ return GetProcessHeap(); -+ } -+ -+ -+ /* return the preferred heap handle from the TLS slot, if set. -+ This is the commonly taken path. */ -+ -+ hHeap = (HANDLE)TlsGetValue( g_dwTlsHeap ); -+ -+ if( hHeap != NULL ) -+ { -+ return hHeap; -+ } -+ -+ -+ /* preferred heap handle not yet set. -+ determine the numa node we're executing on, and create a heap which -+ is assigned to this node. -+ one (soft) assumption that is made here is that thread affinity has -+ been set such that threads do not move between NUMA nodes. -+ */ -+ -+ smalloc_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); -+ -+ if(!smalloc_GetNumaProcessorNodeEx(&CurrentProcessorNumber, &CurrentNumaNodeNumber)) -+ { -+ /* GetNumaProcessorNodeEx() can fail on WOW64/32bit if invoked -+ against processor numbers > 32. -+ this should never be reached for 64bit builds. -+ */ -+ CurrentNumaNodeNumber = 0; -+ } -+ -+ -+ /* check if the NUMA node array slot already contains a heap */ -+ /* CurrentNumaNodeNumber cannot execeed count of heaps, as NUMA nodes -+ cannot be added. */ -+ -+ hHeap = g_hHeap[ CurrentNumaNodeNumber ]; -+ -+ if( hHeap == NULL ) -+ { -+ HANDLE hHeapPrior = NULL; -+ ULONG ulOption = 2; /* HEAP_LFH */ -+ -+ /* create a heap for this numa node -+ defer creating the heap - while running on each node - to ensure -+ the heap control structures get created on the local NUMA node. -+ */ -+ -+ hHeap = HeapCreate(0, 0, 0); -+ -+ if( hHeap == NULL ) -+ { -+ /* just return the process heap. We'll try to create a heap -+ again next time */ -+ return GetProcessHeap(); -+ } -+ -+ /* make the new heap a low-fragmentation heap */ -+ -+ HeapSetInformation( -+ hHeap, -+ 0, /* HeapCompatibilityInformation */ -+ &ulOption, -+ sizeof(ulOption) -+ ); -+ -+ /* set the array slot entry for this NUMA node to contain the newly -+ allocated heap */ -+ -+ hHeapPrior = (HANDLE)InterlockedCompareExchangePointer(&(g_hHeap[CurrentNumaNodeNumber]), hHeap, NULL); -+ if( hHeapPrior != NULL ) -+ { -+ HeapDestroy( hHeap ); -+ hHeap = hHeapPrior; -+ } -+ } -+ -+ /* we reached here since there was no heap assigned to the TLS slot. -+ Assign it. */ -+ TlsSetValue(g_dwTlsHeap, hHeap); -+ -+ return hHeap; -+} -+ -+ -+ -+ -+void *tMPI_Malloc_local(size_t size) -+{ -+ HANDLE hHeap; -+ unsigned char *ptr; -+ size_t new_size; -+ HEAPHEADER *phdr; -+ -+ hHeap = ReturnHeapHandle(); -+ -+ new_size = size + HEAPHEADER_SIZE; -+ -+ ptr = (unsigned char *)HeapAlloc( hHeap, 0, new_size ); -+ -+ if( ptr == NULL ) -+ { -+ return NULL; -+ } -+ -+ phdr = (HEAPHEADER*)ptr; -+ -+ phdr->dwMagic = HEAP_NUMA_MAGIC; -+ phdr->hHeap = hHeap; /* track the heap handle for realloc -+ and free */ -+ phdr->cbAllocationSize = new_size; /* track the allocation size for -+ realloc and debugging */ -+ -+ return ( ptr + HEAPHEADER_SIZE ); -+} -+ -+ -+void *tMPI_Calloc_local(size_t nelem, size_t elsize) -+{ -+ void *ptr; -+ size_t size = nelem * elsize; -+ -+ ptr = tMPI_Malloc_local(size); -+ -+ if(ptr != NULL) -+ { -+ memset(ptr, 0, size); -+ } -+ -+ return ptr; -+} -+ -+ -+void *tMPI_Realloc_local(void *ptr, size_t size) -+{ -+ HANDLE hHeap; -+ HEAPHEADER *phdr; -+ unsigned char *new_ptr; -+ size_t new_size; -+ -+ /* calculate the allocation address and check for presence of the hint -+ which indicates this was allocated by our allocator. -+ */ -+ -+ phdr = (HEAPHEADER*)((unsigned char*)ptr - HEAPHEADER_SIZE); -+ -+ if( phdr->dwMagic != HEAP_NUMA_MAGIC ) -+ { -+ /* TODO: call tMPI_Error() */ -+ /*gmx_fatal(errno,__FILE__,__LINE__, -+ "Invalid Heap header during realloc. %p", ptr);*/ -+ -+ return NULL; -+ } -+ -+ /* calculate size of new/realloc'd block. -+ */ -+ -+ new_size = size + HEAPHEADER_SIZE; -+ -+ /* if the NUMA Node changed between the initial allocation and the -+ reallocation, copy the memory to an allocation on the new local node: -+ we assume the new realloc'd block is more likely to be manipulated by -+ the current thread which is calling realloc. -+ the simple way to detect this condition is to compare the preferred heap -+ handle with the heap handle stored in the current memory block. -+ */ -+ -+ hHeap = ReturnHeapHandle(); -+ -+ if( hHeap != phdr->hHeap ) -+ { -+ new_ptr = HeapAlloc( hHeap, 0, new_size ); -+ -+ /* if the new allocation succeeded, copy the buffer and free the -+ original buffer. -+ */ -+ -+ if( new_ptr != NULL ) -+ { -+ size_t copy_size; -+ -+ /* the realloc can be larger or smaller than the original -+ allocation size. -+ */ -+ -+ if( new_size > phdr->cbAllocationSize ) -+ { -+ copy_size = phdr->cbAllocationSize; -+ } else { -+ copy_size = new_size; -+ } -+ -+ /* copy the current memory block contents into the newly allocated -+ buffer, and then free the original buffer. -+ */ -+ -+ memcpy( new_ptr, phdr, copy_size ); -+ -+ HeapFree( phdr->hHeap, 0, phdr ); -+ } -+ -+ } else { -+ -+ /* NodeNumber of existing allocation matches current node number. -+ realloc from the heap associated with the existing allocation. -+ */ -+ -+ hHeap = phdr->hHeap; -+ -+ new_ptr = HeapReAlloc( -+ hHeap, -+ 0, -+ phdr, -+ new_size -+ ); -+ } -+ -+ if( new_ptr == NULL ) -+ { -+ return NULL; -+ } -+ -+ phdr = (HEAPHEADER*)new_ptr; -+ phdr->cbAllocationSize = new_size; /* update allocation size to match -+ realloc */ -+ phdr->hHeap = hHeap; -+ -+ return ( new_ptr + HEAPHEADER_SIZE ); -+} -+ -+ -+int tMPI_Free_numa(void *ptr) -+{ -+ HEAPHEADER *phdr; -+ -+ /* caller doesn't call us on ptr == NULL case, so we don't need to -+ check that here. */ -+ -+ phdr = (HEAPHEADER*)((unsigned char*)ptr - HEAPHEADER_SIZE); -+ -+ /* this check should happen in __try / __except block until the -+ mis-matched free/sfree calls are fixed, but this is here primarilly -+ for debugging and catching mis-matched memory alloc and free references. -+ */ -+ -+ if(phdr->dwMagic != HEAP_NUMA_MAGIC) -+ { -+ /* ptr is leaked here, rather than faulting in the allocator. -+ this is done in order to track mis-matched alloc/free calls. -+ */ -+ return 1; -+ } -+ -+ phdr->dwMagic = 0; -+ -+ HeapFree( phdr->hHeap, 0, phdr ); -+ -+ return 0; -+} -+ -+#endif /* NUMA allocation functions for (_WIN32 || _WIN64) */ -+ -+ -+ -+ -diff --git a/src/gmxlib/thread_mpi/p2p_buffer.c b/src/gmxlib/thread_mpi/p2p_buffer.c -new file mode 100644 -index 0000000..f6ad352 ---- /dev/null -+++ b/src/gmxlib/thread_mpi/p2p_buffer.c -@@ -0,0 +1,71 @@ -+/* -+This source code file is part of thread_mpi. -+Written by Sander Pronk, Erik Lindahl, and possibly others. -+ -+Copyright (c) 2009, Sander Pronk, Erik Lindahl. -+All rights reserved. -+ -+Redistribution and use in source and binary forms, with or without -+modification, are permitted provided that the following conditions are met: -+1) Redistributions of source code must retain the above copyright -+ notice, this list of conditions and the following disclaimer. -+2) Redistributions in binary form must reproduce the above copyright -+ notice, this list of conditions and the following disclaimer in the -+ documentation and/or other materials provided with the distribution. -+3) Neither the name of the copyright holders nor the -+ names of its contributors may be used to endorse or promote products -+ derived from this software without specific prior written permission. -+ -+THIS SOFTWARE IS PROVIDED BY US ''AS IS'' AND ANY -+EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -+DISCLAIMED. IN NO EVENT SHALL WE BE LIABLE FOR ANY -+DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND -+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -+ -+If you want to redistribute modifications, please consider that -+scientific software is very special. Version control is crucial - -+bugs must be traceable. We will be happy to consider code for -+inclusion in the official distribution, but derived work should not -+be called official thread_mpi. Details are found in the README & COPYING -+files. -+*/ -+ -+#ifdef HAVE_TMPI_CONFIG_H -+#include "tmpi_config.h" -+#endif -+ -+#ifdef HAVE_CONFIG_H -+#include "config.h" -+#endif -+ -+ -+#ifdef HAVE_UNISTD_H -+#include -+#endif -+ -+#include -+#include -+#include -+#include -+#include -+ -+ -+#include "impl.h" -+#include "p2p.h" -+ -+/* point-to-point buffered mode transfer functions */ -+ -+int MPI_Buffer_attach(void* buffer, int size) -+{ -+} -+ -+ -+int MPI_Buffer_detach(void* buffer_addr, int* size) -+{ -+} -+ -diff --git a/src/gmxlib/thread_mpi/pthreads.c b/src/gmxlib/thread_mpi/pthreads.c -index 22a3dd3..378a796 100644 ---- a/src/gmxlib/thread_mpi/pthreads.c -+++ b/src/gmxlib/thread_mpi/pthreads.c -@@ -52,6 +52,10 @@ files. - - #ifdef THREAD_PTHREADS - -+#ifdef HAVE_PTHREAD_SETAFFINITY -+#define _GNU_SOURCE -+#endif -+ - /* pthread.h must be the first header, apart from the defines in config.h */ - #include - -@@ -65,6 +69,7 @@ files. - #include - #include - -+ - #include "thread_mpi/atomic.h" - #include "thread_mpi/threads.h" - #include "impl.h" -@@ -83,9 +88,16 @@ static pthread_mutex_t cond_init=PTHREAD_MUTEX_INITIALIZER; - static pthread_mutex_t barrier_init=PTHREAD_MUTEX_INITIALIZER; - - -+/* lock & variable for setting main thread affinity */ -+static tMPI_Spinlock_t main_thread_aff_lock=TMPI_SPINLOCK_INITIALIZER; -+static tMPI_Atomic_t main_thread_aff_set={ 0 }; -+static tMPI_Atomic_t aff_thread_number; -+ - - - -+/* TODO: this needs to go away! (there's another one in winthreads.c) -+ fatal errors are thankfully really rare*/ - void tMPI_Fatal_error(const char *file, int line, const char *message, ...) - { - va_list ap; -@@ -104,6 +116,25 @@ enum tMPI_Thread_support tMPI_Thread_support(void) - return TMPI_THREAD_SUPPORT_YES; - } - -+ -+int tMPI_Thread_get_hw_number(void) -+{ -+ int ret=0; -+#ifdef HAVE_SYSCONF -+#if defined(_SC_NPROCESSORS_ONLN) -+ ret=sysconf(_SC_NPROCESSORS_ONLN); -+#elif defined(_SC_NPROC_ONLN) -+ ret=sysconf(_SC_NPROC_ONLN); -+#elif defined(_SC_NPROCESSORS_CONF) -+ ret=sysconf(_SC_NPROCESSORS_CONF); -+#elif defined(_SC_NPROC_CONF) -+ ret=sysconf(_SC_NPROC_CONF); -+#endif -+#endif -+ -+ return ret; -+} -+ - int tMPI_Thread_create(tMPI_Thread_t *thread, void *(*start_routine)(void *), - void *arg) - { -@@ -130,6 +161,80 @@ int tMPI_Thread_create(tMPI_Thread_t *thread, void *(*start_routine)(void *), - } - - -+/* set thread's own affinity to a processor number n */ -+static int tMPI_Set_affinity(int n) -+{ -+#ifdef HAVE_PTHREAD_SETAFFINITY -+ cpu_set_t set; -+ -+ CPU_ZERO(&set); -+ CPU_SET(n, &set); -+ return pthread_setaffinity_np(pthread_self(), sizeof(set), &set); -+#endif -+ return 0; -+} -+ -+int tMPI_Thread_create_aff(tMPI_Thread_t *thread, -+ void *(*start_routine)(void *), -+ void *arg) -+{ -+ int ret; -+ -+ /* set the calling thread's affinity mask */ -+ if (tMPI_Atomic_get(&main_thread_aff_set) == 0) -+ { -+#ifdef HAVE_PTHREAD_SETAFFINITY -+ cpu_set_t set; -+#endif -+ /* this can be a spinlock because the chances of collision are low. */ -+ tMPI_Spinlock_lock( &main_thread_aff_lock ); -+ tMPI_Atomic_set( &aff_thread_number, 0); -+#ifdef HAVE_PTHREAD_SETAFFINITY -+ CPU_ZERO(&set); -+ CPU_SET(0, &set); -+ pthread_setaffinity_np(pthread_self(), sizeof(set), &set); -+ /*fprintf(stderr, "Setting affinity.\n");*/ -+#endif -+ tMPI_Atomic_set( &main_thread_aff_set, 1); -+ tMPI_Spinlock_unlock( &main_thread_aff_lock ); -+ } -+ -+ -+ if(thread==NULL) -+ { -+ tMPI_Fatal_error(TMPI_FARGS,"Invalid thread pointer."); -+ return EINVAL; -+ } -+ -+ *thread=(struct tMPI_Thread*)malloc(sizeof(struct tMPI_Thread)*1); -+ ret=pthread_create(&((*thread)->th),NULL,start_routine,arg); -+ -+ if(ret!=0) -+ { -+ /* Cannot use tMPI_error() since messages use threads for locking */ -+ tMPI_Fatal_error(TMPI_FARGS,"Failed to create POSIX thread, rc=%d",ret); -+ /* Use system memory allocation routines */ -+ return -1; -+ } -+ else -+ { -+#ifdef HAVE_PTHREAD_SETAFFINITY -+ int n; -+ cpu_set_t set; -+ -+ n=tMPI_Atomic_add_return(&aff_thread_number, 1); -+ CPU_ZERO(&set); -+ CPU_SET(n, &set); -+ return pthread_setaffinity_np((*thread)->th, sizeof(set), &set); -+#else -+ return 0; -+#endif -+ } -+} -+ -+ -+ -+ - - int tMPI_Thread_join(tMPI_Thread_t thread, void **value_ptr) - { -diff --git a/src/gmxlib/thread_mpi/settings.h b/src/gmxlib/thread_mpi/settings.h -index f36cdaa..a8a8724 100644 ---- a/src/gmxlib/thread_mpi/settings.h -+++ b/src/gmxlib/thread_mpi/settings.h -@@ -122,3 +122,8 @@ files. - /*#define TMPI_PROFILE*/ - - -+/* whether to turn on thread affinity (required for NUMA optimizations) -+ if the number of threads to spawn is equal to the number of processors. */ -+#define TMPI_THREAD_AFFINITY -+ -+ -diff --git a/src/gmxlib/thread_mpi/tmpi_init.c b/src/gmxlib/thread_mpi/tmpi_init.c -index 01dd676..a0dea19 100644 ---- a/src/gmxlib/thread_mpi/tmpi_init.c -+++ b/src/gmxlib/thread_mpi/tmpi_init.c -@@ -249,7 +249,10 @@ int tMPI_Get_N(int *argc, char ***argv, const char *optname, int *nthreads) - } - if (*nthreads<1) - { -- *nthreads=tMPI_Get_recommended_nthreads(); -+ int nth=tMPI_Thread_get_hw_number(); -+ -+ if (nth<1) nth=1; /* make sure it's at least 1 */ -+ *nthreads=nth; - } - - return ret; -@@ -392,6 +395,7 @@ void tMPI_Start_threads(tmpi_bool main_returns, int N, int *argc, char ***argv, - if (N>0) - { - int i; -+ int set_affinity=FALSE; - - tmpi_finalized=FALSE; - Nthreads=N; -@@ -439,11 +443,36 @@ void tMPI_Start_threads(tmpi_bool main_returns, int N, int *argc, char ***argv, - threads[i].start_fn_main=start_fn_main; - threads[i].start_arg=start_arg; - } -+ -+ /* now check whether to set affinity */ -+#ifdef TMPI_THREAD_AFFINITY -+ { -+ int nhw=tMPI_Thread_get_hw_number(); -+ if ((nhw > 1) && (nhw == N)) -+ { -+ set_affinity=TRUE; -+ } -+ } -+#endif -+ - for(i=1;i=1) /* we're the main process */ -diff --git a/src/gmxlib/thread_mpi/winthreads.c b/src/gmxlib/thread_mpi/winthreads.c -index 64993ae..98b89a9 100644 ---- a/src/gmxlib/thread_mpi/winthreads.c -+++ b/src/gmxlib/thread_mpi/winthreads.c -@@ -86,9 +86,444 @@ static CRITICAL_SECTION barrier_init; /* mutex for initializing barriers */ - static tMPI_Spinlock_t init_init=TMPI_SPINLOCK_INITIALIZER; - - /* whether tMPI_Thread_create has initialized these mutexes */ --tMPI_Atomic_t init_inited={ 0 }; -+static tMPI_Atomic_t init_inited={ 0 }; - -+/* whether the main thread affinity has been set */ -+static tMPI_Spinlock_t main_thread_aff_lock=TMPI_SPINLOCK_INITIALIZER; -+static tMPI_Atomic_t main_thread_aff_set={ 0 }; - -+/* -+ NUMA and Processor Group awareness support. -+ -+ NUMA support is implemented to maximize the chance that memory access -+ patterns remain Local to the NUMA node. -+ NUMA node processor affinity is utilized to prevent scheduler associated -+ drift across NUMA nodes. -+ Process Group support is implemented to enable > 64 processors to be -+ utilized. This is only supported when building 64bit. -+ -+ The high level approach is: -+ 1. Build a description of CPU topology, including processor numbers, NUMA -+ node numbers, and affinity masks. -+ 2. For processor intensive worker threads, create threads such that -+ the processor affinity and thread stack is kept local within a NUMA node. -+ 3. Employ simple round-robin affinity and node assignment approach when -+ creating threads. -+ 4. Use GetProcAddress() to obtain function pointers to functions that -+ are operating system version dependent, to allow maximum binary -+ compatibility. -+ -+ Scott Field (sfield@microsoft.com) Jan-2011 -+*/ -+ -+ -+typedef struct { -+ PROCESSOR_NUMBER ProcessorNumber; -+ GROUP_AFFINITY GroupAffinity; -+ USHORT NumaNodeNumber; -+} MPI_NUMA_PROCESSOR_INFO; -+ -+ -+/* thread/processor index, to allow setting round-robin affinity. */ -+volatile ULONG g_ulThreadIndex; -+/* a value of zero implies the system is not NUMA */ -+ULONG g_ulHighestNumaNodeNumber=0; -+/* total number of processors in g_MPI_ProcessInfo array */ -+ULONG g_ulTotalProcessors; -+/* array describing available processors, affinity masks, and NUMA node */ -+MPI_NUMA_PROCESSOR_INFO *g_MPI_ProcessorInfo; -+ -+/* function prototypes and variables to support obtaining function addresses -+ dynamically -- supports down-level operating systems */ -+ -+typedef BOOL (WINAPI *func_GetNumaHighestNodeNumber_t)( PULONG -+ HighestNodeNumber ); -+typedef BOOL (WINAPI *func_SetThreadGroupAffinity_t)( HANDLE hThread, -+ const GROUP_AFFINITY *GroupAffinity, -+ PGROUP_AFFINITY PreviousGroupAffinity ); -+typedef BOOL (WINAPI *func_SetThreadIdealProcessorEx_t)( HANDLE hThread, -+ PPROCESSOR_NUMBER lpIdealProcessor, -+ PPROCESSOR_NUMBER lpPreviousIdealProcessor ); -+typedef BOOL (WINAPI *func_GetNumaNodeProcessorMaskEx_t)( USHORT Node, -+ PGROUP_AFFINITY ProcessorMask ); -+typedef BOOL (WINAPI *func_GetNumaProcessorNodeEx_t)( -+ PPROCESSOR_NUMBER Processor, -+ PUSHORT NodeNumber ); -+typedef VOID (WINAPI *func_GetCurrentProcessorNumberEx_t)( -+ PPROCESSOR_NUMBER ProcNumber ); -+ -+typedef HANDLE (WINAPI *func_CreateRemoteThreadEx_t)( -+ HANDLE hProcess, -+ LPSECURITY_ATTRIBUTES lpThreadAttributes, -+ SIZE_T dwStackSize, -+ LPTHREAD_START_ROUTINE lpStartAddress, -+ LPVOID lpParameter, -+ DWORD dwCreationFlags, -+ LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList, -+ LPDWORD lpThreadId); -+ -+typedef BOOL (WINAPI *func_InitializeProcThreadAttributeList_t)( -+ LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList, -+ DWORD dwAttributeCount, -+ DWORD dwFlags, -+ PSIZE_T lpSize); -+typedef BOOL (WINAPI *func_UpdateProcThreadAttribute_t)( -+ LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList, -+ DWORD dwFlags, -+ DWORD_PTR Attribute, -+ PVOID lpValue, -+ SIZE_T cbSize, -+ PVOID lpPreviousValue, -+ PSIZE_T lpReturnSize); -+typedef VOID (WINAPI *func_DeleteProcThreadAttributeList_t)( -+ LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList); -+typedef DWORD (WINAPI *func_GetActiveProcessorCount_t)(WORD GroupNumber); -+typedef WORD (WINAPI *func_GetActiveProcessorGroupCount_t)(void); -+ -+ -+/* WinXP SP2, WinXP64, WinSrv 2003 */ -+func_GetNumaHighestNodeNumber_t func_GetNumaHighestNodeNumber; -+/* Windows 7, WinSrv 2008R2 */ -+func_SetThreadGroupAffinity_t func_SetThreadGroupAffinity; -+func_SetThreadIdealProcessorEx_t func_SetThreadIdealProcessorEx; -+func_GetNumaNodeProcessorMaskEx_t func_GetNumaNodeProcessorMaskEx; -+func_GetNumaProcessorNodeEx_t func_GetNumaProcessorNodeEx; -+func_GetCurrentProcessorNumberEx_t func_GetCurrentProcessorNumberEx; -+func_GetActiveProcessorCount_t func_GetActiveProcessorCount; -+func_GetActiveProcessorGroupCount_t func_GetActiveProcessorGroupCount; -+func_CreateRemoteThreadEx_t func_CreateRemoteThreadEx; -+/* Windows Vista, WinSrv 2008 */ -+func_InitializeProcThreadAttributeList_t func_InitializeProcThreadAttributeList; -+func_UpdateProcThreadAttribute_t func_UpdateProcThreadAttribute; -+func_DeleteProcThreadAttributeList_t func_DeleteProcThreadAttributeList; -+ -+ -+/* Set the main thread's affinity */ -+static int tMPI_Set_main_thread_affinity(void) -+{ -+ /* calling thread PROCESSOR_NUMBER */ -+ PROCESSOR_NUMBER CurrentProcessorNumber; -+ /* calling thread GROUP_AFFINITY */ -+ GROUP_AFFINITY CurrentThreadGroupAffinity; -+ /* calling thread NUMA node */ -+ USHORT CurrentNumaNodeNumber; -+ -+ -+ /* we can pre-check because it's atomic */ -+ if (tMPI_Atomic_get(&main_thread_aff_set) == 0) -+ { -+ /* this can be a spinlock because the chances of collision are low. */ -+ tMPI_Spinlock_lock( &main_thread_aff_lock ); -+ if( g_ulHighestNumaNodeNumber != 0 ) -+ { -+ func_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); -+ -+ -+ /* set the NUMA node affinity for the current thread -+ failures to set the current thread affinity are ignored, -+ as a fringe case can arise on >32 processor systems with a 32bit -+ build/code. -+ */ -+ func_SetThreadIdealProcessorEx(GetCurrentThread(), -+ &CurrentProcessorNumber, -+ NULL); -+ -+ if(func_GetNumaProcessorNodeEx(&CurrentProcessorNumber, -+ &CurrentNumaNodeNumber)) -+ { -+ /* for the NUMA node number associated with the current processor -+ number, get the group affinity mask */ -+ if(func_GetNumaNodeProcessorMaskEx(CurrentNumaNodeNumber, -+ &CurrentThreadGroupAffinity)) -+ { -+ /* set the current thread affinity to prevent it from running on -+ other NUMA nodes */ -+ func_SetThreadGroupAffinity(GetCurrentThread(), -+ &CurrentThreadGroupAffinity, -+ NULL); -+ } -+ } -+ } -+ else -+ { -+ /* No NUMA. For now, we just do a similar thing. */ -+ if ( (func_GetCurrentProcessorNumberEx != NULL) && -+ (func_SetThreadIdealProcessorEx)) -+ { -+ func_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); -+ func_SetThreadIdealProcessorEx(GetCurrentThread(), -+ &CurrentProcessorNumber, -+ NULL); -+ } -+ } -+ tMPI_Atomic_set( &main_thread_aff_set, 1); -+ tMPI_Spinlock_unlock( &main_thread_aff_lock ); -+ } -+ return 0; -+} -+ -+/* returns 0 on success. -+ Success is returned if the system is non-NUMA, OR the system doesn't -+ support appropriate NUMA APIs, OR the system is NUMA and we successfully -+ initialized support. -+ -+ returns -1 on error. -+ This can happen if an API returned an error, a memory allocation failed, or -+ we failed to initialize affinity mapping information. -+*/ -+int tMPI_Init_NUMA(void) -+{ -+ /* module handle to kernel32.dll -- we already reference it, so it's already loaded */ -+ HMODULE hModKernel32 = NULL; -+ /* 0-based NUMA node count -- does not imply all nodes have available (eg: hot-plug) processors */ -+ ULONG ulHighestNumaNodeNumber; -+ /* total number of processors available per affinity masks */ -+ DWORD dwTotalProcessors = 0; -+ ULONG i = 0; -+ -+ /* calling thread PROCESSOR_NUMBER */ -+ PROCESSOR_NUMBER CurrentProcessorNumber; -+ /* calling thread GROUP_AFFINITY */ -+ GROUP_AFFINITY CurrentThreadGroupAffinity; -+ /* calling thread NUMA node */ -+ USHORT CurrentNumaNodeNumber; -+ -+ WORD wActiveGroupCount; -+ WORD GroupIndex; -+ -+ /* array of processor information structures */ -+ MPI_NUMA_PROCESSOR_INFO *pMPI_ProcessorInfo = NULL; -+ -+ /* assume an error condition */ -+ int iRet = -1; -+ -+ hModKernel32 = GetModuleHandleA("kernel32.dll"); -+ -+ if( hModKernel32 == NULL ) -+ { -+ return 0; -+ } -+ -+ /* obtain addresses of relevant NUMA functions, most of which are -+ Windows 7 / Windows Server 2008R2 only functions -+ this is done using GetProcAddress to enable the binary to run on older -+ Windows versions. -+ */ -+ -+ func_GetNumaHighestNodeNumber = (func_GetNumaHighestNodeNumber_t) GetProcAddress( hModKernel32, "GetNumaHighestNodeNumber" ); -+ -+ if( func_GetNumaHighestNodeNumber == NULL ) -+ { -+ return 0; -+ } -+ -+ /* determine if we're on a NUMA system and if so, determine the number of -+ (potential) nodes */ -+ -+ if(!func_GetNumaHighestNodeNumber( &ulHighestNumaNodeNumber )) -+ { -+ return -1; -+ } -+ -+ if( ulHighestNumaNodeNumber == 0 ) -+ { -+ /* system is not NUMA */ -+ return 0; -+ } -+ -+ func_SetThreadGroupAffinity = (func_SetThreadGroupAffinity_t)GetProcAddress( hModKernel32, "SetThreadGroupAffinity" ); -+ func_SetThreadIdealProcessorEx = (func_SetThreadIdealProcessorEx_t)GetProcAddress( hModKernel32, "SetThreadIdealProcessorEx" ); -+ func_CreateRemoteThreadEx = (func_CreateRemoteThreadEx_t)GetProcAddress( hModKernel32, "CreateRemoteThreadEx" ); -+ func_GetNumaNodeProcessorMaskEx = (func_GetNumaNodeProcessorMaskEx_t)GetProcAddress( hModKernel32, "GetNumaNodeProcessorMaskEx" ); -+ func_GetNumaProcessorNodeEx = (func_GetNumaProcessorNodeEx_t)GetProcAddress( hModKernel32, "GetNumaProcessorNodeEx" ); -+ func_GetCurrentProcessorNumberEx = (func_GetCurrentProcessorNumberEx_t)GetProcAddress( hModKernel32, "GetCurrentProcessorNumberEx" ); -+ func_GetActiveProcessorCount = (func_GetActiveProcessorCount_t)GetProcAddress( hModKernel32, "GetActiveProcessorCount" ); -+ func_GetActiveProcessorGroupCount = (func_GetActiveProcessorGroupCount_t)GetProcAddress( hModKernel32, "GetActiveProcessorGroupCount" ); -+ func_InitializeProcThreadAttributeList = (func_InitializeProcThreadAttributeList_t)GetProcAddress( hModKernel32, "InitializeProcThreadAttributeList" ); -+ func_UpdateProcThreadAttribute = (func_UpdateProcThreadAttribute_t)GetProcAddress( hModKernel32, "UpdateProcThreadAttribute" ); -+ func_DeleteProcThreadAttributeList = (func_DeleteProcThreadAttributeList_t)GetProcAddress( hModKernel32, "DeleteProcThreadAttributeList" ); -+ -+ if( (func_SetThreadGroupAffinity == NULL) || -+ (func_SetThreadIdealProcessorEx == NULL) || -+ (func_CreateRemoteThreadEx == NULL) || -+ (func_GetNumaNodeProcessorMaskEx == NULL) || -+ (func_GetNumaProcessorNodeEx == NULL) || -+ (func_GetCurrentProcessorNumberEx == NULL) || -+ (func_GetActiveProcessorCount == NULL) || -+ (func_GetActiveProcessorGroupCount == NULL) || -+ (func_InitializeProcThreadAttributeList == NULL) || -+ (func_UpdateProcThreadAttribute == NULL) || -+ (func_DeleteProcThreadAttributeList == NULL) ) -+ { -+ /* if any addresses couldn't be located, assume NUMA functionality -+ isn't supported */ -+ return 0; -+ } -+ -+ /* count the active processors across the groups */ -+ -+ func_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); -+ -+ wActiveGroupCount = func_GetActiveProcessorGroupCount(); -+ -+ dwTotalProcessors = func_GetActiveProcessorCount( ALL_PROCESSOR_GROUPS ); -+ -+#if !((defined WIN64 || defined _WIN64)) -+ /* WOW64 doesn't allow setting the affinity correctly beyond 32 -+ processors -- the KAFFINITY mask is only 32 bits wide -+ This check is only here for completeness -- large systems should be -+ running 64bit Gromacs code, where the processor quantity is not -+ constrained. -+ By failing here, the WOW64 32bit client will use normal CreateThread(), -+ which can schedule up to 64 un-affinitized threads -+ */ -+ -+ if( dwTotalProcessors > 32 ) -+ { -+ return 0; -+ } -+#endif -+ -+ /* allocate array of processor info blocks */ -+ -+ pMPI_ProcessorInfo = tMPI_Malloc( sizeof(MPI_NUMA_PROCESSOR_INFO) * -+ dwTotalProcessors ); -+ if(pMPI_ProcessorInfo == NULL) -+ { -+ tMPI_Fatal_error(TMPI_FARGS,"tMPI_Malloc failed for processor information"); -+ goto cleanup; -+ } -+ -+ /* zero fill to cover reserved must be-zero fields */ -+ memset(pMPI_ProcessorInfo, 0, sizeof(MPI_NUMA_PROCESSOR_INFO) * dwTotalProcessors); -+ -+ /* loop through each processor group, and for each group, capture the -+ processor numbers and NUMA node information. */ -+ -+ for(GroupIndex = 0 ; GroupIndex < wActiveGroupCount ; GroupIndex++) -+ { -+ DWORD dwGroupProcessorCount; -+ BYTE ProcessorIndex; -+ -+ dwGroupProcessorCount = func_GetActiveProcessorCount( GroupIndex ); -+ -+ for(ProcessorIndex = 0 ; ProcessorIndex < dwGroupProcessorCount ; -+ ProcessorIndex++) -+ { -+ PROCESSOR_NUMBER *pProcessorNumber = &(pMPI_ProcessorInfo[i].ProcessorNumber); -+ GROUP_AFFINITY *pGroupAffinity = &(pMPI_ProcessorInfo[i].GroupAffinity); -+ USHORT *pNodeNumber = &(pMPI_ProcessorInfo[i].NumaNodeNumber); -+ -+ pProcessorNumber->Group = GroupIndex; -+ pProcessorNumber->Number = ProcessorIndex; -+ -+ /* save an index to the processor array entry for the current processor -+ this is used to enable subsequent threads to be created in a round -+ robin fashion starting at the next array entry -+ */ -+ -+ if( (CurrentProcessorNumber.Group == pProcessorNumber->Group ) && -+ (CurrentProcessorNumber.Number == pProcessorNumber->Number) ) -+ { -+ /* set global: current thread index into processor array */ -+ g_ulThreadIndex = i; -+ } -+ -+ /* capture the node number and group affinity associated with processor entry -+ any failures here are assumed to be catastrophic and disable -+ the group & NUMA aware thread support -+ */ -+ -+ if(!func_GetNumaProcessorNodeEx(pProcessorNumber, pNodeNumber)) -+ { -+ tMPI_Fatal_error(TMPI_FARGS, -+ "Processor enumeration, GetNumaProcessorNodeEx failed, error code=%d", -+ GetLastError()); -+ goto cleanup; -+ } -+ -+ if(!func_GetNumaNodeProcessorMaskEx(*pNodeNumber, pGroupAffinity)) -+ { -+ tMPI_Fatal_error(TMPI_FARGS, -+ "Processor enumeration, GetNumaNodeProcessorMaskEx failed, error code=%d", -+ GetLastError()); -+ goto cleanup; -+ } -+ -+ /* future enhancement: construct GroupAffinity (single) processor -+ mask within NUMA node for this processor entry */ -+ -+ /* increment processor array index */ -+ i++; -+ -+ /* sanity check, should never happen */ -+ -+ if(i > dwTotalProcessors) -+ { -+ tMPI_Fatal_error(TMPI_FARGS,"Processor enumeration exceeds allocated memory!"); -+ goto cleanup; -+ } -+ } -+ } -+ -+#if 0 -+ /* set the NUMA node affinity for the current thread -+ failures to set the current thread affinity are ignored, -+ as a fringe case can arise on >32 processor systems with a 32bit -+ build/code. -+ */ -+ func_SetThreadIdealProcessorEx(GetCurrentThread(), -+ &CurrentProcessorNumber, -+ NULL); -+ -+ if(func_GetNumaProcessorNodeEx(&CurrentProcessorNumber, -+ &CurrentNumaNodeNumber)) -+ { -+ /* for the NUMA node number associated with the current processor -+ number, get the group affinity mask */ -+ if(func_GetNumaNodeProcessorMaskEx(CurrentNumaNodeNumber, -+ &CurrentThreadGroupAffinity)) -+ { -+ /* set the current thread affinity to prevent it from running on -+ other NUMA nodes */ -+ func_SetThreadGroupAffinity(GetCurrentThread(), -+ &CurrentThreadGroupAffinity, -+ NULL); -+ } -+ } -+#endif -+ -+ /* capture number of processors, highest NUMA node number, and processor -+ array */ -+ g_ulTotalProcessors = dwTotalProcessors; -+ g_ulHighestNumaNodeNumber = ulHighestNumaNodeNumber; -+ g_MPI_ProcessorInfo = pMPI_ProcessorInfo; -+ -+ iRet = 0 ; -+ -+#if 0 -+ // TODO: debug DISCARD -+ printf("primary thread tid=%lu group=%lu mask=0x%I64x group=%lu number=%lu ulThreadIndex=%lu\n", -+ GetCurrentThreadId(), -+ CurrentThreadGroupAffinity.Group, -+ (ULONGLONG)CurrentThreadGroupAffinity.Mask, -+ (ULONG)CurrentProcessorNumber.Group, -+ (ULONG)CurrentProcessorNumber.Number, -+ g_ulThreadIndex); -+#endif -+ -+cleanup: -+ -+ if( iRet != 0 ) -+ { -+ if( pMPI_ProcessorInfo ) -+ { -+ tMPI_Free( pMPI_ProcessorInfo ); -+ } -+ } -+ -+ return 0; -+} - - static void tMPI_Init_initers(void) - { -@@ -108,6 +543,9 @@ static void tMPI_Init_initers(void) - InitializeCriticalSection(&cond_init); - InitializeCriticalSection(&barrier_init); - -+ /* fatal errors are handled by the routine by calling tMPI_Fatal_error() */ -+ tMPI_Init_NUMA(); -+ - tMPI_Atomic_memory_barrier_rel(); - tMPI_Atomic_set(&init_inited, 1); - } -@@ -116,7 +554,8 @@ static void tMPI_Init_initers(void) - } - } - -- -+/* TODO: this needs to go away! (there's another one in pthreads.c) -+ fatal errors are thankfully really rare*/ - void tMPI_Fatal_error(const char *file, int line, const char *message, ...) - { - va_list ap; -@@ -151,6 +590,159 @@ static DWORD WINAPI tMPI_Win32_thread_starter( LPVOID lpParam ) - return 0; - } - -+HANDLE tMPI_Thread_create_NUMA(LPSECURITY_ATTRIBUTES lpThreadAttributes, -+ SIZE_T dwStackSize, -+ LPTHREAD_START_ROUTINE lpStartAddress, -+ LPVOID lpParameter, -+ DWORD dwCreationFlags, -+ LPDWORD lpThreadId) -+{ -+ LPPROC_THREAD_ATTRIBUTE_LIST pAttributeList = NULL; -+ HANDLE hThread = NULL; -+ SIZE_T cbAttributeList = 0; -+ GROUP_AFFINITY GroupAffinity; -+ PROCESSOR_NUMBER IdealProcessorNumber; -+ ULONG CurrentProcessorIndex; -+ -+ /* for each thread created, round-robin through the set of valid -+ processors and affinity masks. -+ the assumption is that callers of tMPI_Thread_create_NUMA are creating -+ threads that saturate a given processor. -+ for cases where threads are being created that rarely do work, standard -+ thread creation (eg: CreateThread) should be invoked instead. -+ */ -+ -+ CurrentProcessorIndex = (ULONG)InterlockedIncrement((volatile LONG *)&g_ulThreadIndex); -+ CurrentProcessorIndex = CurrentProcessorIndex % g_ulTotalProcessors; -+ -+ /* group, mask. */ -+ -+ memcpy(&GroupAffinity, -+ &(g_MPI_ProcessorInfo[CurrentProcessorIndex].GroupAffinity), -+ sizeof(GROUP_AFFINITY)); -+ -+ /* group, processor number */ -+ -+ memcpy(&IdealProcessorNumber, -+ &(g_MPI_ProcessorInfo[CurrentProcessorIndex].ProcessorNumber), -+ sizeof(PROCESSOR_NUMBER)); -+ -+ /* determine size of allocation for AttributeList */ -+ -+ if(!func_InitializeProcThreadAttributeList(pAttributeList, -+ 2, -+ 0, -+ &cbAttributeList)) -+ { -+ DWORD dwLastError = GetLastError(); -+ if( dwLastError != ERROR_INSUFFICIENT_BUFFER ) -+ { -+ tMPI_Fatal_error(TMPI_FARGS, -+ "InitializeProcThreadAttributeList, error code=%d", -+ dwLastError); -+ goto cleanup; -+ } -+ } -+ -+ pAttributeList = (LPPROC_THREAD_ATTRIBUTE_LIST)tMPI_Malloc( cbAttributeList ); -+ if( pAttributeList == NULL ) -+ { -+ tMPI_Fatal_error(TMPI_FARGS,"Failed to allocate pAttributeList"); -+ goto cleanup; -+ } -+ -+ memset( pAttributeList, 0, cbAttributeList ); -+ -+ if(!func_InitializeProcThreadAttributeList(pAttributeList, -+ 2, -+ 0, -+ &cbAttributeList)) -+ { -+ tMPI_Fatal_error(TMPI_FARGS, -+ "InitializeProcThreadAttributeList, error code=%d", -+ GetLastError()); -+ goto cleanup; -+ } -+ -+ if(!func_UpdateProcThreadAttribute(pAttributeList, -+ 0, -+ PROC_THREAD_ATTRIBUTE_GROUP_AFFINITY, -+ &GroupAffinity, -+ sizeof(GroupAffinity), -+ NULL, -+ NULL)) -+ { -+ tMPI_Fatal_error(TMPI_FARGS,"UpdateProcThreadAttribute, error code=%d", -+ GetLastError()); -+ goto cleanup; -+ } -+ -+ if(!func_UpdateProcThreadAttribute(pAttributeList, -+ 0, -+ PROC_THREAD_ATTRIBUTE_IDEAL_PROCESSOR, -+ &IdealProcessorNumber, -+ sizeof(IdealProcessorNumber), -+ NULL, -+ NULL)) -+ { -+ tMPI_Fatal_error(TMPI_FARGS,"UpdateProcThreadAttribute, error code=%d", -+ GetLastError()); -+ goto cleanup; -+ } -+ -+ -+ hThread = func_CreateRemoteThreadEx( GetCurrentProcess(), -+ lpThreadAttributes, -+ dwStackSize, -+ lpStartAddress, -+ lpParameter, -+ dwCreationFlags, -+ pAttributeList, -+ lpThreadId); -+ -+ func_DeleteProcThreadAttributeList( pAttributeList ); -+ -+#if 0 -+ // TODO: debug only or DISCARD -+ if( hThread ) -+ { -+ PROCESSOR_NUMBER ProcNumber; -+ USHORT NodeNumber; -+ -+ GetThreadIdealProcessorEx(hThread, &ProcNumber); -+ GetNumaProcessorNodeEx(&ProcNumber, &NodeNumber); -+ -+ printf("started thread tid=%lu group=%lu mask=0x%I64x number=%lu numanode=%lu\n", -+ *lpThreadId, -+ GroupAffinity.Group, -+ (ULONGLONG)GroupAffinity.Mask, -+ ProcNumber.Number, -+ NodeNumber -+ ); -+ } -+#endif -+ -+cleanup: -+ -+ if( pAttributeList ) -+ { -+ tMPI_Free( pAttributeList ); -+ } -+ -+ return hThread; -+} -+ -+int tMPI_Thread_get_hw_number(void) -+{ -+ int ret; -+ -+ SYSTEM_INFO sysinfo; -+ GetSystemInfo( &sysinfo ); -+ -+ ret=sysinfo.dwNumberOfProcessors; -+ return ret; -+} -+ - - int tMPI_Thread_create(tMPI_Thread_t *thread, - void *(*start_routine)(void *), void *arg) -@@ -161,30 +753,104 @@ int tMPI_Thread_create(tMPI_Thread_t *thread, - tMPI_Init_initers(); - - /* a small memory leak to be sure that it doesn't get deallocated -- once this function ends */ -+ once this function ends, before the newly created thread uses it. */ - prm=(struct tMPI_Thread_starter_param*) -- malloc(sizeof(struct tMPI_Thread_starter_param)); -+ tMPI_Malloc(sizeof(struct tMPI_Thread_starter_param)); - prm->start_routine= start_routine; - prm->param=arg; - -- *thread=(struct tMPI_Thread*)malloc(sizeof(struct tMPI_Thread)*1); -+ *thread=(struct tMPI_Thread*)tMPI_Malloc(sizeof(struct tMPI_Thread)*1); - - if(thread==NULL) - { - tMPI_Fatal_error(TMPI_FARGS,"Invalid thread pointer."); - return EINVAL; - } -- -- (*thread)->th = CreateThread(NULL, 0, tMPI_Win32_thread_starter, prm, 0, -+ /* just create a plain thread. */ -+ (*thread)->th = CreateThread(NULL, -+ 0, -+ tMPI_Win32_thread_starter, -+ prm, -+ 0, - &thread_id); - - if((*thread)->th==NULL) - { -+ tMPI_Free(thread); - tMPI_Fatal_error(TMPI_FARGS,"Failed to create thread, error code=%d", - GetLastError()); - return -1; - } -- /* inherit the thread priority from the paren thread. */ -+ -+ /* inherit the thread priority from the parent thread. */ -+ /* TODO: is there value in setting this, vs. just allowing it to default -+ from the process? currently, this limits the effectivenes of changing -+ the priority in eg: TaskManager. */ -+ SetThreadPriority(((*thread)->th), GetThreadPriority(GetCurrentThread())); -+ -+ return 0; -+} -+ -+ -+ -+ -+ -+int tMPI_Thread_create_aff(tMPI_Thread_t *thread, -+ void *(*start_routine)(void *), void *arg) -+{ -+ DWORD thread_id; -+ struct tMPI_Thread_starter_param *prm; -+ -+ tMPI_Init_initers(); -+ tMPI_Set_main_thread_affinity(); -+ -+ /* a small memory leak to be sure that it doesn't get deallocated -+ once this function ends, before the newly created thread uses it. */ -+ prm=(struct tMPI_Thread_starter_param*) -+ tMPI_Malloc(sizeof(struct tMPI_Thread_starter_param)); -+ prm->start_routine= start_routine; -+ prm->param=arg; -+ -+ *thread=(struct tMPI_Thread*)tMPI_Malloc(sizeof(struct tMPI_Thread)*1); -+ -+ if(thread==NULL) -+ { -+ tMPI_Fatal_error(TMPI_FARGS,"Invalid thread pointer."); -+ return EINVAL; -+ } -+ -+ if( g_ulHighestNumaNodeNumber != 0 ) -+ { -+ /* if running on a NUMA system, use the group and NUMA aware thread -+ creation logic */ -+ (*thread)->th = tMPI_Thread_create_NUMA(NULL, -+ 0, -+ tMPI_Win32_thread_starter, -+ prm, -+ 0, -+ &thread_id); -+ } else { -+ /* TODO: for now, non-NUMA systems don't set thread affinity. */ -+ (*thread)->th = CreateThread(NULL, -+ 0, -+ tMPI_Win32_thread_starter, -+ prm, -+ 0, -+ &thread_id); -+ } -+ -+ if((*thread)->th==NULL) -+ { -+ tMPI_Free(thread); -+ tMPI_Fatal_error(TMPI_FARGS,"Failed to create thread, error code=%d", -+ GetLastError()); -+ return -1; -+ } -+ -+ /* inherit the thread priority from the parent thread. */ -+ /* TODO: is there value in setting this, vs. just allowing it to default -+ from the process? currently, this limits the effectivenes of changing -+ the priority in eg: TaskManager. */ - SetThreadPriority(((*thread)->th), GetThreadPriority(GetCurrentThread())); - - return 0; -@@ -217,7 +883,7 @@ int tMPI_Thread_join(tMPI_Thread_t thread, void **value_ptr) - } - } - CloseHandle(thread->th); -- free(thread); -+ tMPI_Free(thread); - - return 0; - } -@@ -269,7 +935,7 @@ int tMPI_Thread_mutex_destroy(tMPI_Thread_mutex_t *mtx) - } - - DeleteCriticalSection(&(mtx->mutex->cs)); -- free(mtx->mutex); -+ tMPI_Free(mtx->mutex); - - return 0; - } -@@ -383,7 +1049,7 @@ int tMPI_Thread_key_create(tMPI_Thread_key_t *key, void (*destructor)(void *)) - int tMPI_Thread_key_delete(tMPI_Thread_key_t key) - { - TlsFree(key.key->wkey); -- free(key.key); -+ tMPI_Free(key.key); - - return 0; - } -@@ -490,7 +1156,7 @@ int tMPI_Thread_cond_destroy(tMPI_Thread_cond_t *cond) - /* windows doesnt have this function */ - #else - DeleteCriticalSection(&(cond->condp->wtr_lock)); -- free(cond->condp); -+ tMPI_Free(cond->condp); - #endif - return 0; - } -@@ -732,7 +1398,7 @@ int tMPI_Thread_barrier_destroy(tMPI_Thread_barrier_t *barrier) - - tMPI_Thread_cond_destroy(&(barrier->barrierp->cv)); - -- free(barrier->barrierp); -+ tMPI_Free(barrier->barrierp); - - return 0; - } -diff --git a/src/gmxlib/typedefs.c b/src/gmxlib/typedefs.c -index a0029be..15fcbdc 100644 ---- a/src/gmxlib/typedefs.c -+++ b/src/gmxlib/typedefs.c -@@ -468,7 +468,6 @@ void done_energyhistory(energyhistory_t * enerhist) - sfree(enerhist->ener_ave); - sfree(enerhist->ener_sum); - sfree(enerhist->ener_sum_sim); -- sfree(enerhist->dht); - - if (enerhist->dht != NULL) - { -diff --git a/src/gmxlib/wman.c b/src/gmxlib/wman.c -index c569583..4b42bb1 100644 ---- a/src/gmxlib/wman.c -+++ b/src/gmxlib/wman.c -@@ -90,6 +90,10 @@ const t_sandr_const sandrTeX[] = { - { "[BR]", "\\\\" }, - { "%", "\\%" }, - { "&", "\\&" }, -+ /* The next couple of lines allow true Greek symbols to be written to the -+ manual, which makes it look pretty */ -+ { "[GRK]", "$\\" }, -+ { "[grk]", "$" }, - /* The next two lines used to substitute "|" and "||" to "or", but only - * g_angle used that functionality, so that was changed to a textual - * "or" there, so that other places could use those symbols to indicate -@@ -107,7 +111,9 @@ const t_sandr_const sandrTty[] = { - { "[IT]", "" }, - { "[it]", "" }, - { "[PAR]","\n\n" }, -- { "[BR]", "\n"} -+ { "[BR]", "\n"}, -+ { "[GRK]", "" }, -+ { "[grk]", "" } - }; - #define NSRTTY asize(sandrTty) - -@@ -122,7 +128,9 @@ const t_sandr_const sandrWiki[] = { - { "[IT]", "''" }, - { "[it]", "''" }, - { "[PAR]","\n\n" }, -- { "[BR]", "\n"} -+ { "[BR]", "\n" }, -+ { "[GRK]", "&" }, -+ { "[grk]", ";" } - }; - #define NSRWIKI asize(sandrWiki) - -@@ -140,7 +148,9 @@ const t_sandr_const sandrNROFF[] = { - { "^", "" }, - { "#", "" }, - { "[BR]", "\n"}, -- { "-", "\\-"} -+ { "-", "\\-"}, -+ { "[GRK]", "" }, -+ { "[grk]", "" } - }; - #define NSRNROFF asize(sandrNROFF) - -@@ -154,7 +164,9 @@ const t_sandr_const sandrHTML[] = { - { "[IT]", "" }, - { "[it]", "" }, - { "[PAR]","

" }, -- { "[BR]", "
" } -+ { "[BR]", "
" }, -+ { "[GRK]", "&" }, -+ { "[grk]", ";" } - }; - #define NSRHTML asize(sandrHTML) - -@@ -168,7 +180,9 @@ const t_sandr_const sandrXML[] = { - { "[IT]", "" }, - { "[it]", "" }, - { "[PAR]","\n" }, -- { "[BR]", "
" } -+ { "[BR]", "
" }, -+ { "[GRK]", "" }, -+ { "[grk]", "" } - }; - #define NSRXML asize(sandrXML) - -diff --git a/src/kernel/g_protonate.c b/src/kernel/g_protonate.c -index 01ee6d1..6ccd59a 100644 ---- a/src/kernel/g_protonate.c -+++ b/src/kernel/g_protonate.c -@@ -37,6 +37,7 @@ - #endif - - #include -+#include "string2.h" - #include "typedefs.h" - #include "macros.h" - #include "copyrite.h" -@@ -55,7 +56,7 @@ int main (int argc,char *argv[]) - "[TT]g_protonate[tt] reads (a) conformation(s) and adds all missing", - "hydrogens as defined in [TT]gmx2.ff/aminoacids.hdb[tt]. If only [TT]-s[tt] is", - "specified, this conformation will be protonated, if also [TT]-f[tt]", -- "is specified, the conformation(s) will be read from this file", -+ "is specified, the conformation(s) will be read from this file, ", - "which can be either a single conformation or a trajectory.", - "[PAR]", - "If a [TT].pdb[tt] file is supplied, residue names might not correspond to", -@@ -65,7 +66,7 @@ int main (int argc,char *argv[]) - "If an index file is specified, please note that the atom numbers", - "should correspond to the [BB]protonated[bb] state." - }; -- -+ - char title[STRLEN+1]; - const char *infile; - char *grpnm; -@@ -84,6 +85,10 @@ int main (int argc,char *argv[]) - gmx_bool bReadMultiple; - output_env_t oenv; - -+ const char *bugs[] = { -+ "For the moment, only .pdb files are accepted to the -s flag" -+ }; -+ - t_filenm fnm[] = { - { efTPS, NULL, NULL, ffREAD }, - { efTRX, "-f", NULL, ffOPTRD }, -@@ -94,7 +99,7 @@ int main (int argc,char *argv[]) - - CopyRight(stderr,argv[0]); - parse_common_args(&argc,argv,PCA_CAN_TIME, -- NFILE,fnm,0,NULL,asize(desc),desc,0,NULL,&oenv); -+ NFILE,fnm,0,NULL,asize(desc),desc,asize(bugs),bugs,&oenv); - - infile=opt2fn("-s",NFILE,fnm); - read_tps_conf(infile,title,&top,&ePBC,&x,NULL,box,FALSE); -@@ -104,8 +109,9 @@ int main (int argc,char *argv[]) - bReadMultiple = opt2bSet("-f",NFILE,fnm); - if (bReadMultiple) { - infile = opt2fn("-f",NFILE,fnm); -- if ( !read_first_frame(oenv,&status, infile, &fr, TRX_NEED_X ) ) -+ if ( !read_first_frame(oenv,&status, infile, &fr, TRX_NEED_X ) ) { - gmx_fatal(FARGS,"cannot read coordinate file %s",infile); -+ } - natoms = fr.natoms; - } else { - clear_trxframe(&fr,TRUE); -@@ -120,16 +126,22 @@ int main (int argc,char *argv[]) - } - - /* check input */ -- if ( natoms == 0 ) -+ if ( natoms == 0 ) { - gmx_fatal(FARGS,"no atoms in coordinate file %s",infile); -- if ( natoms > atoms->nr ) -+ } -+ -+ if ( natoms > atoms->nr ) { - gmx_fatal(FARGS,"topology with %d atoms does not match " - "coordinates with %d atoms",atoms->nr,natoms); -- for(i=0; i natoms) -+ } -+ -+ for(i=0; i natoms) { - gmx_fatal(FARGS,"An atom number in group %s is larger than the number of " - "atoms (%d) in the coordinate file %s",grpnm,natoms,infile); -- -+ } -+ } -+ - /* get indexed copy of atoms */ - snew(iatoms,1); - init_t_atoms(iatoms,nidx,FALSE); -@@ -138,10 +150,15 @@ int main (int argc,char *argv[]) - for(i=0; iatom[i] = atoms->atom[index[i]]; - iatoms->atomname[i] = atoms->atomname[index[i]]; -- if ( i>0 && (atoms->atom[index[i]].resind!=atoms->atom[index[i-1]].resind) ) -+ if ( i>0 && (atoms->atom[index[i]].resind!=atoms->atom[index[i-1]].resind) ) { - resind++; -+ } - iatoms->atom[i].resind = resind; - iatoms->resinfo[resind] = atoms->resinfo[atoms->atom[index[i]].resind]; -+ /* allocate some space for the rtp name and copy from name */ -+ snew(iatoms->resinfo[resind].rtp,1); -+ iatoms->resinfo[resind].rtp = gmx_strdup(atoms->resinfo[resind].name); -+ - iatoms->nres = max(iatoms->nres, iatoms->atom[i].resind+1); - } - -@@ -151,10 +168,13 @@ int main (int argc,char *argv[]) - snew(ix, nidx); - frame=0; - do { -- if (debug) fprintf(debug,"FRAME %d (%d %g)\n",frame,fr.step,fr.time); -+ if (debug) { -+ fprintf(debug,"FRAME %d (%d %g)\n",frame,fr.step,fr.time); -+ } - /* get indexed copy of x */ -- for(i=0; inres; rnr++) { - ahptr=search_h_db(nah,ah,*pdba->resinfo[rnr].rtp); - if ( ahptr ) { -- if (hb[rnr].name==NULL) -- hb[rnr].name=strdup(ahptr->name); -+ if (hb[rnr].name==NULL) { -+ hb[rnr].name=strdup(ahptr->name); -+ } - merge_hacks(ahptr, &hb[rnr]); - } - } -@@ -166,17 +167,22 @@ static void expand_hackblocks_one(t_hackblock *hbr, char *atomname, - all hacks involving atoms from resp. previous or next residue - (i.e. which name begins with '-' (N) or '+' (C) */ - bIgnore = FALSE; -- if ( bN ) /* N-terminus: ignore '-' */ -- for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) -- bIgnore = hbr->hack[j].a[k][0]=='-'; -- if ( bC ) /* C-terminus: ignore '+' */ -- for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) -- bIgnore = hbr->hack[j].a[k][0]=='+'; -+ if ( bN ) { /* N-terminus: ignore '-' */ -+ for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) { -+ bIgnore = hbr->hack[j].a[k][0]=='-'; -+ } -+ } -+ if ( bC ) { /* C-terminus: ignore '+' */ -+ for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) { -+ bIgnore = hbr->hack[j].a[k][0]=='+'; -+ } -+ } - /* must be either hdb entry (tp>0) or add from tdb (oname==NULL) - and first control aton (AI) matches this atom or - delete/replace from tdb (oname!=NULL) and oname matches this atom */ -- if (debug) fprintf(debug," %s", -- hbr->hack[j].oname?hbr->hack[j].oname:hbr->hack[j].AI); -+ if (debug) { -+ fprintf(debug," %s",hbr->hack[j].oname?hbr->hack[j].oname:hbr->hack[j].AI); -+ } - - if ( !bIgnore && - ( ( ( hbr->hack[j].tp > 0 || hbr->hack[j].oname==NULL ) && -@@ -184,56 +190,60 @@ static void expand_hackblocks_one(t_hackblock *hbr, char *atomname, - ( hbr->hack[j].oname!=NULL && - strcmp(atomname, hbr->hack[j].oname) == 0) ) ) { - /* now expand all hacks for this atom */ -- if (debug) fprintf(debug," +%dh",hbr->hack[j].nr); -+ if (debug) { -+ fprintf(debug," +%dh",hbr->hack[j].nr); -+ } - srenew(*abi,*nabi + hbr->hack[j].nr); - for(k=0; k < hbr->hack[j].nr; k++) { -- copy_t_hack(&hbr->hack[j], &(*abi)[*nabi + k]); -- (*abi)[*nabi + k].bXSet = FALSE; -- /* if we're adding (oname==NULL) and don't have a new name (nname) -- yet, build it from atomname */ -- if ( (*abi)[*nabi + k].nname==NULL ) { -- if ( (*abi)[*nabi + k].oname==NULL ) { -- (*abi)[*nabi + k].nname=strdup(atomname); -- (*abi)[*nabi + k].nname[0]='H'; -- } -- } else { -- if (gmx_debug_at) { -- fprintf(debug,"Hack '%s' %d, replacing nname '%s' with '%s' (old name '%s')\n", -- atomname,j, -- (*abi)[*nabi + k].nname,hbr->hack[j].nname, -- (*abi)[*nabi + k].oname ? (*abi)[*nabi + k].oname : ""); -- } -- sfree((*abi)[*nabi + k].nname); -- (*abi)[*nabi + k].nname=strdup(hbr->hack[j].nname); -- } -+ copy_t_hack(&hbr->hack[j], &(*abi)[*nabi + k]); -+ (*abi)[*nabi + k].bXSet = FALSE; -+ /* if we're adding (oname==NULL) and don't have a new name (nname) -+ yet, build it from atomname */ -+ if ( (*abi)[*nabi + k].nname==NULL ) { -+ if ( (*abi)[*nabi + k].oname==NULL ) { -+ (*abi)[*nabi + k].nname=strdup(atomname); -+ (*abi)[*nabi + k].nname[0]='H'; -+ } -+ } else { -+ if (gmx_debug_at) { -+ fprintf(debug,"Hack '%s' %d, replacing nname '%s' with '%s' (old name '%s')\n", -+ atomname,j, -+ (*abi)[*nabi + k].nname,hbr->hack[j].nname, -+ (*abi)[*nabi + k].oname ? (*abi)[*nabi + k].oname : ""); -+ } -+ sfree((*abi)[*nabi + k].nname); -+ (*abi)[*nabi + k].nname=strdup(hbr->hack[j].nname); -+ } - -- if (hbr->hack[j].tp == 10 && k == 2) { -- /* This is a water virtual site, not a hydrogen */ -- /* Ugly hardcoded name hack */ -- (*abi)[*nabi + k].nname[0] = 'M'; -- } else if (hbr->hack[j].tp == 11 && k >= 2) { -- /* This is a water lone pair, not a hydrogen */ -- /* Ugly hardcoded name hack */ -- srenew((*abi)[*nabi + k].nname,4); -- (*abi)[*nabi + k].nname[0] = 'L'; -- (*abi)[*nabi + k].nname[1] = 'P'; -- (*abi)[*nabi + k].nname[2] = '1' + k - 2; -- (*abi)[*nabi + k].nname[3] = '\0'; -- } else if ( hbr->hack[j].nr > 1 ) { -- /* adding more than one atom, number them */ -- l = strlen((*abi)[*nabi + k].nname); -- srenew((*abi)[*nabi + k].nname, l+2); -- (*abi)[*nabi + k].nname[l] = '1' + k; -- (*abi)[*nabi + k].nname[l+1] = '\0'; -- } -+ if (hbr->hack[j].tp == 10 && k == 2) { -+ /* This is a water virtual site, not a hydrogen */ -+ /* Ugly hardcoded name hack */ -+ (*abi)[*nabi + k].nname[0] = 'M'; -+ } else if (hbr->hack[j].tp == 11 && k >= 2) { -+ /* This is a water lone pair, not a hydrogen */ -+ /* Ugly hardcoded name hack */ -+ srenew((*abi)[*nabi + k].nname,4); -+ (*abi)[*nabi + k].nname[0] = 'L'; -+ (*abi)[*nabi + k].nname[1] = 'P'; -+ (*abi)[*nabi + k].nname[2] = '1' + k - 2; -+ (*abi)[*nabi + k].nname[3] = '\0'; -+ } else if ( hbr->hack[j].nr > 1 ) { -+ /* adding more than one atom, number them */ -+ l = strlen((*abi)[*nabi + k].nname); -+ srenew((*abi)[*nabi + k].nname, l+2); -+ (*abi)[*nabi + k].nname[l] = '1' + k; -+ (*abi)[*nabi + k].nname[l+1] = '\0'; -+ } - } - (*nabi) += hbr->hack[j].nr; - - /* add hacks to atoms we've just added */ -- if ( hbr->hack[j].tp > 0 || hbr->hack[j].oname==NULL ) -- for(k=0; k < hbr->hack[j].nr; k++) -- expand_hackblocks_one(hbr, (*abi)[*nabi-hbr->hack[j].nr+k].nname, -+ if ( hbr->hack[j].tp > 0 || hbr->hack[j].oname==NULL ) { -+ for(k=0; k < hbr->hack[j].nr; k++) { -+ expand_hackblocks_one(hbr, (*abi)[*nabi-hbr->hack[j].nr+k].nname, - nabi, abi, bN, bC); -+ } -+ } - } - } - } -@@ -313,30 +323,31 @@ static void calc_all_pos(t_atoms *pdba, rvec x[], int nab[], t_hack *ab[], - for(j=0; j < nab[i]; j+=ab[i][j].nr) { - /* check if we're adding: */ - if (ab[i][j].oname==NULL && ab[i][j].tp > 0) { -- bFoundAll = TRUE; -- for(m=0; (m= 0) { -- copy_rvec(ab[ii][jj].newx, xa[m]); -- } else { -- bFoundAll = FALSE; -- if (bCheckMissing) { -- gmx_fatal(FARGS,"Atom %s not found in residue %s %d" -- ", rtp entry %s" -- " while adding hydrogens", -- ab[i][j].a[m], -- *pdba->resinfo[rnr].name, -- pdba->resinfo[rnr].nr, -- *pdba->resinfo[rnr].rtp); -- } -- } -- } else -+ if (ia < 0) { -+ /* not found in original atoms, might still be in t_hack (ab) */ -+ hacksearch_atom(&ii, &jj, ab[i][j].a[m], nab, ab, rnr, pdba); -+ if (ii >= 0) { -+ copy_rvec(ab[ii][jj].newx, xa[m]); -+ } else { -+ bFoundAll = FALSE; -+ if (bCheckMissing) { -+ gmx_fatal(FARGS,"Atom %s not found in residue %s %d" -+ ", rtp entry %s" -+ " while adding hydrogens", -+ ab[i][j].a[m], -+ *pdba->resinfo[rnr].name, -+ pdba->resinfo[rnr].nr, -+ *pdba->resinfo[rnr].rtp); -+ } -+ } -+ } else { - copy_rvec(x[ia], xa[m]); -+ } - } - if (bFoundAll) { - for(m=0; (mbInit ) { -- if (debug) fprintf(debug,"protonate: Initializing protdata\n"); -+ if (debug) { -+ fprintf(debug,"protonate: Initializing protdata\n"); -+ } -+ - /* set forcefield to use: */ -- strcpy(protdata->FF,"ffgmx2"); -+ strcpy(protdata->FF,"gmx2.ff"); -+ - /* get the databases: */ - protdata->nah = read_h_db(protdata->FF,&protdata->ah); - open_symtab(&protdata->tab); - protdata->atype = read_atype(protdata->FF,&protdata->tab); - nntdb = read_ter_db(protdata->FF,'n',&protdata->ntdb,protdata->atype); -- if (nntdb < 1) -- gmx_fatal(FARGS,"no n-terminus db"); -+ if (nntdb < 1) { -+ gmx_fatal(FARGS,"no N-terminus database"); -+ } - nctdb = read_ter_db(protdata->FF,'c',&protdata->ctdb,protdata->atype); -- if (nctdb < 1) -- gmx_fatal(FARGS,"no c-terminus db"); -+ if (nctdb < 1) { -+ gmx_fatal(FARGS,"no C-terminus database"); -+ } - - /* set terminus types: -NH3+ (different for Proline) and -COO- */ - atoms=*atomsptr; -@@ -656,15 +673,16 @@ int protonate(t_atoms **atomsptr,rvec **xptr,t_protonate *protdata) - snew(protdata->sel_ctdb, NTERPAIRS); - - if (nntdb>=4 && nctdb>=2) { -- /* Yuk, yuk, hardcoded default termini selections !!! */ -- if (strncmp(*atoms->resinfo[atoms->atom[atoms->nr-1].resind].name,"PRO",3)==0) -- nt = 3; -- else -- nt = 1; -- ct = 1; -+ /* Yuk, yuk, hardcoded default termini selections !!! */ -+ if (strncmp(*atoms->resinfo[atoms->atom[atoms->nr-1].resind].name,"PRO",3)==0) { -+ nt = 3; -+ } else { -+ nt = 1; -+ } -+ ct = 1; - } else { -- nt = 0; -- ct = 0; -+ nt = 0; -+ ct = 0; - } - protdata->sel_ntdb[0]=&(protdata->ntdb[nt]); - protdata->sel_ctdb[0]=&(protdata->ctdb[ct]); -@@ -689,8 +707,10 @@ int protonate(t_atoms **atomsptr,rvec **xptr,t_protonate *protdata) - /* set flag to show we're initialized: */ - protdata->bInit=TRUE; - } else { -- if (debug) fprintf(debug,"protonate: using available protdata\n"); -- /* add_h will need the unprotonated topoloy again: */ -+ if (debug) { -+ fprintf(debug,"protonate: using available protdata\n"); -+ } -+ /* add_h will need the unprotonated topology again: */ - atoms = protdata->upatoms; - bUpdate_pdba=FALSE; - bKeep_old_pdba=FALSE; -@@ -701,12 +721,15 @@ int protonate(t_atoms **atomsptr,rvec **xptr,t_protonate *protdata) - NTERPAIRS, protdata->sel_ntdb, protdata->sel_ctdb, - protdata->rN, protdata->rC, TRUE, - &protdata->nab, &protdata->ab, bUpdate_pdba, bKeep_old_pdba); -- if ( ! protdata->patoms ) -+ if ( ! protdata->patoms ) { - /* store protonated topology */ - protdata->patoms = atoms; -+ } - *atomsptr = protdata->patoms; -- if (debug) fprintf(debug,"natoms: %d -> %d (nadd=%d)\n", -- protdata->upatoms->nr, protdata->patoms->nr, nadd); -+ if (debug) { -+ fprintf(debug,"natoms: %d -> %d (nadd=%d)\n", -+ protdata->upatoms->nr, protdata->patoms->nr, nadd); -+ } - return nadd; - #undef NTERPAIRS - } -diff --git a/src/kernel/genhydro.h b/src/kernel/genhydro.h -index fb20ab0..ba90543 100644 ---- a/src/kernel/genhydro.h -+++ b/src/kernel/genhydro.h -@@ -51,7 +51,7 @@ extern int add_h(t_atoms **pdbaptr, rvec *xptr[], - * ntdb[i] and ctdb[i] may be NULL, no replacement will be done then. - * rN[i] is the residue number of the N-terminus of chain i, - * rC[i] is the residue number of the C-terminus of chain i -- * if bMissing==TRUE, conitue when atoms are not found -+ * if bMissing==TRUE, continue when atoms are not found - * if nabptr && abptrb, the hack array will be returned in them to be used - * a second time - * if bUpdate_pdba, hydrogens are added to *pdbaptr, else it is unchanged -@@ -59,10 +59,10 @@ extern int add_h(t_atoms **pdbaptr, rvec *xptr[], - */ - - extern int protonate(t_atoms **atoms, rvec **x, t_protonate *protdata); --/* Protonate molecule according to ffgmx2 -+/* Protonate molecule according to gmx2.ff/aminoacids.hdb - * when called the first time, new atoms are added to atoms, - * second time only coordinates are generated -- * return the New total number of atoms -+ * return the new total number of atoms - */ - - extern void deprotonate(t_atoms *atoms,rvec *x); -diff --git a/src/kernel/gmxdump.c b/src/kernel/gmxdump.c -index 7cda183..4e99088 100644 ---- a/src/kernel/gmxdump.c -+++ b/src/kernel/gmxdump.c -@@ -466,7 +466,7 @@ int main(int argc,char *argv[]) - "This program is essential for checking your run input file in case of", - "problems.[PAR]", - "The program can also preprocess a topology to help finding problems.", -- "Note that currently setting GMXLIB is the only way to customize", -+ "Note that currently setting [TT]GMXLIB[tt] is the only way to customize", - "directories used for searching include files.", - }; - t_filenm fnm[] = { -diff --git a/src/kernel/grompp.c b/src/kernel/grompp.c -index a987b50..2d3b716 100644 ---- a/src/kernel/grompp.c -+++ b/src/kernel/grompp.c -@@ -1152,8 +1152,8 @@ int main (int argc, char *argv[]) - "Note that the atom names are irrelevant for the simulation as", - "only the atom types are used for generating interaction parameters.[PAR]", - -- "[TT]grompp[tt] uses a built-in preprocessor to resolve includes, macros ", -- "etcetera. The preprocessor supports the following keywords:[BR]", -+ "[TT]grompp[tt] uses a built-in preprocessor to resolve includes, macros, ", -+ "etc. The preprocessor supports the following keywords:[PAR]", - "#ifdef VARIABLE[BR]", - "#ifndef VARIABLE[BR]", - "#else[BR]", -@@ -1161,19 +1161,21 @@ int main (int argc, char *argv[]) - "#define VARIABLE[BR]", - "#undef VARIABLE[BR]" - "#include \"filename\"[BR]", -- "#include [BR]", -+ "#include [PAR]", - "The functioning of these statements in your topology may be modulated by", -- "using the following two flags in your [TT]mdp[tt] file:[BR]", -- "define = -DVARIABLE1 -DVARIABLE2[BR]", -- "include = -I/home/john/doe[BR]", -+ "using the following two flags in your [TT].mdp[tt] file:[PAR]", -+ "[TT]define = -DVARIABLE1 -DVARIABLE2[BR]", -+ "include = -I/home/john/doe[tt][BR]", - "For further information a C-programming textbook may help you out.", - "Specifying the [TT]-pp[tt] flag will get the pre-processed", - "topology file written out so that you can verify its contents.[PAR]", -- -- "If your system does not have a c-preprocessor, you can still", -- "use [TT]grompp[tt], but you do not have access to the features ", -- "from the cpp. Command line options to the c-preprocessor can be given", -- "in the [TT].mdp[tt] file. See your local manual (man cpp).[PAR]", -+ -+ /* cpp has been unnecessary for some time, hasn't it? -+ "If your system does not have a C-preprocessor, you can still", -+ "use [TT]grompp[tt], but you do not have access to the features ", -+ "from the cpp. Command line options to the C-preprocessor can be given", -+ "in the [TT].mdp[tt] file. See your local manual (man cpp).[PAR]", -+ */ - - "When using position restraints a file with restraint coordinates", - "can be supplied with [TT]-r[tt], otherwise restraining will be done", -@@ -1191,8 +1193,8 @@ int main (int argc, char *argv[]) - "[TT]-e[tt] to read Nose-Hoover and/or Parrinello-Rahman coupling", - "variables.[PAR]", - -- "[TT]grompp[tt] can be used to restart simulations preserving", -- "continuity by supplying just a checkpoint file with [TT]-t[tt].", -+ "[TT]grompp[tt] can be used to restart simulations (preserving", -+ "continuity) by supplying just a checkpoint file with [TT]-t[tt].", - "However, for simply changing the number of run steps to extend", - "a run, using [TT]tpbconv[tt] is more convenient than [TT]grompp[tt].", - "You then supply the old checkpoint file directly to [TT]mdrun[tt]", -@@ -1209,10 +1211,10 @@ int main (int argc, char *argv[]) - "of virtual site constructions will be removed. If any constraints remain", - "which involve virtual sites, a fatal error will result.[PAR]" - -- "To verify your run input file, please make notice of all warnings", -+ "To verify your run input file, please take note of all warnings", - "on the screen, and correct where necessary. Do also look at the contents", -- "of the [TT]mdout.mdp[tt] file, this contains comment lines, as well as", -- "the input that [TT]grompp[tt] has read. If in doubt you can start grompp", -+ "of the [TT]mdout.mdp[tt] file; this contains comment lines, as well as", -+ "the input that [TT]grompp[tt] has read. If in doubt, you can start [TT]grompp[tt]", - "with the [TT]-debug[tt] option which will give you more information", - "in a file called [TT]grompp.log[tt] (along with real debug info). You", - "can see the contents of the run input file with the [TT]gmxdump[tt]", -diff --git a/src/kernel/md.c b/src/kernel/md.c -index 1346ef9..8ae0b4c 100644 ---- a/src/kernel/md.c -+++ b/src/kernel/md.c -@@ -37,9 +37,6 @@ - #include - #endif - --#include --#include -- - #if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) - /* _isnan() */ - #include -@@ -103,1009 +100,6 @@ - #endif - - --/* simulation conditions to transmit. Keep in mind that they are -- transmitted to other nodes through an MPI_Reduce after -- casting them to a real (so the signals can be sent together with other -- data). This means that the only meaningful values are positive, -- negative or zero. */ --enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; --/* Is the signal in one simulation independent of other simulations? */ --gmx_bool gs_simlocal[eglsNR] = { TRUE, FALSE, FALSE, TRUE }; -- --typedef struct { -- int nstms; /* The frequency for intersimulation communication */ -- int sig[eglsNR]; /* The signal set by one process in do_md */ -- int set[eglsNR]; /* The communicated signal, equal for all processes */ --} globsig_t; -- -- -- --/* check which of the multisim simulations has the shortest number of -- steps and return that number of nsteps */ --static gmx_large_int_t get_multisim_nsteps(const t_commrec *cr, -- gmx_large_int_t nsteps) --{ -- gmx_large_int_t steps_out; -- -- if MASTER(cr) -- { -- gmx_large_int_t *buf; -- int s; -- -- snew(buf,cr->ms->nsim); -- -- buf[cr->ms->sim] = nsteps; -- gmx_sumli_sim(cr->ms->nsim, buf, cr->ms); -- -- steps_out=-1; -- for(s=0; sms->nsim; s++) -- { -- /* find the smallest positive number */ -- if (buf[s]>= 0 && ((steps_out < 0) || (buf[s]=0 && steps_outms->sim, steps_out); -- } -- } -- /* broadcast to non-masters */ -- gmx_bcast(sizeof(gmx_large_int_t), &steps_out, cr); -- return steps_out; --} -- --static int multisim_min(const gmx_multisim_t *ms,int nmin,int n) --{ -- int *buf; -- gmx_bool bPos,bEqual; -- int s,d; -- -- snew(buf,ms->nsim); -- buf[ms->sim] = n; -- gmx_sumi_sim(ms->nsim,buf,ms); -- bPos = TRUE; -- bEqual = TRUE; -- for(s=0; snsim; s++) -- { -- bPos = bPos && (buf[s] > 0); -- bEqual = bEqual && (buf[s] == buf[0]); -- } -- if (bPos) -- { -- if (bEqual) -- { -- nmin = min(nmin,buf[0]); -- } -- else -- { -- /* Find the least common multiple */ -- for(d=2; dnsim && d % buf[s] == 0) -- { -- s++; -- } -- if (s == ms->nsim) -- { -- /* We found the LCM and it is less than nmin */ -- nmin = d; -- break; -- } -- } -- } -- } -- sfree(buf); -- -- return nmin; --} -- --static int multisim_nstsimsync(const t_commrec *cr, -- const t_inputrec *ir,int repl_ex_nst) --{ -- int nmin; -- -- if (MASTER(cr)) -- { -- nmin = INT_MAX; -- nmin = multisim_min(cr->ms,nmin,ir->nstlist); -- nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); -- nmin = multisim_min(cr->ms,nmin,repl_ex_nst); -- if (nmin == INT_MAX) -- { -- gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); -- } -- /* Avoid inter-simulation communication at every (second) step */ -- if (nmin <= 2) -- { -- nmin = 10; -- } -- } -- -- gmx_bcast(sizeof(int),&nmin,cr); -- -- return nmin; --} -- --static void init_global_signals(globsig_t *gs,const t_commrec *cr, -- const t_inputrec *ir,int repl_ex_nst) --{ -- int i; -- -- if (MULTISIM(cr)) -- { -- gs->nstms = multisim_nstsimsync(cr,ir,repl_ex_nst); -- if (debug) -- { -- fprintf(debug,"Syncing simulations for checkpointing and termination every %d steps\n",gs->nstms); -- } -- } -- else -- { -- gs->nstms = 1; -- } -- -- for(i=0; isig[i] = 0; -- gs->set[i] = 0; -- } --} -- --static void copy_coupling_state(t_state *statea,t_state *stateb, -- gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts) --{ -- -- /* MRS note -- might be able to get rid of some of the arguments. Look over it when it's all debugged */ -- -- int i,j,nc; -- -- /* Make sure we have enough space for x and v */ -- if (statea->nalloc > stateb->nalloc) -- { -- stateb->nalloc = statea->nalloc; -- srenew(stateb->x,stateb->nalloc); -- srenew(stateb->v,stateb->nalloc); -- } -- -- stateb->natoms = statea->natoms; -- stateb->ngtc = statea->ngtc; -- stateb->nnhpres = statea->nnhpres; -- stateb->veta = statea->veta; -- if (ekinda) -- { -- copy_mat(ekinda->ekin,ekindb->ekin); -- for (i=0; ingtc; i++) -- { -- ekindb->tcstat[i].T = ekinda->tcstat[i].T; -- ekindb->tcstat[i].Th = ekinda->tcstat[i].Th; -- copy_mat(ekinda->tcstat[i].ekinh,ekindb->tcstat[i].ekinh); -- copy_mat(ekinda->tcstat[i].ekinf,ekindb->tcstat[i].ekinf); -- ekindb->tcstat[i].ekinscalef_nhc = ekinda->tcstat[i].ekinscalef_nhc; -- ekindb->tcstat[i].ekinscaleh_nhc = ekinda->tcstat[i].ekinscaleh_nhc; -- ekindb->tcstat[i].vscale_nhc = ekinda->tcstat[i].vscale_nhc; -- } -- } -- copy_rvecn(statea->x,stateb->x,0,stateb->natoms); -- copy_rvecn(statea->v,stateb->v,0,stateb->natoms); -- copy_mat(statea->box,stateb->box); -- copy_mat(statea->box_rel,stateb->box_rel); -- copy_mat(statea->boxv,stateb->boxv); -- -- for (i = 0; ingtc; i++) -- { -- nc = i*opts->nhchainlength; -- for (j=0; jnhchainlength; j++) -- { -- stateb->nosehoover_xi[nc+j] = statea->nosehoover_xi[nc+j]; -- stateb->nosehoover_vxi[nc+j] = statea->nosehoover_vxi[nc+j]; -- } -- } -- if (stateb->nhpres_xi != NULL) -- { -- for (i = 0; innhpres; i++) -- { -- nc = i*opts->nhchainlength; -- for (j=0; jnhchainlength; j++) -- { -- stateb->nhpres_xi[nc+j] = statea->nhpres_xi[nc+j]; -- stateb->nhpres_vxi[nc+j] = statea->nhpres_vxi[nc+j]; -- } -- } -- } --} -- --static real compute_conserved_from_auxiliary(t_inputrec *ir, t_state *state, t_extmass *MassQ) --{ -- real quantity = 0; -- switch (ir->etc) -- { -- case etcNO: -- break; -- case etcBERENDSEN: -- break; -- case etcNOSEHOOVER: -- quantity = NPT_energy(ir,state,MassQ); -- break; -- case etcVRESCALE: -- quantity = vrescale_energy(&(ir->opts),state->therm_integral); -- break; -- default: -- break; -- } -- return quantity; --} -- --static void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, -- t_forcerec *fr, gmx_ekindata_t *ekind, -- t_state *state, t_state *state_global, t_mdatoms *mdatoms, -- t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, -- gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, -- tensor pres, rvec mu_tot, gmx_constr_t constr, -- globsig_t *gs,gmx_bool bInterSimGS, -- matrix box, gmx_mtop_t *top_global, real *pcurr, -- int natoms, gmx_bool *bSumEkinhOld, int flags) --{ -- int i,gsi; -- real gs_buf[eglsNR]; -- tensor corr_vir,corr_pres,shakeall_vir; -- gmx_bool bEner,bPres,bTemp, bVV; -- gmx_bool bRerunMD, bStopCM, bGStat, bIterate, -- bFirstIterate,bReadEkin,bEkinAveVel,bScaleEkin, bConstrain; -- real ekin,temp,prescorr,enercorr,dvdlcorr; -- -- /* translate CGLO flags to gmx_booleans */ -- bRerunMD = flags & CGLO_RERUNMD; -- bStopCM = flags & CGLO_STOPCM; -- bGStat = flags & CGLO_GSTAT; -- -- bReadEkin = (flags & CGLO_READEKIN); -- bScaleEkin = (flags & CGLO_SCALEEKIN); -- bEner = flags & CGLO_ENERGY; -- bTemp = flags & CGLO_TEMPERATURE; -- bPres = (flags & CGLO_PRESSURE); -- bConstrain = (flags & CGLO_CONSTRAINT); -- bIterate = (flags & CGLO_ITERATE); -- bFirstIterate = (flags & CGLO_FIRSTITERATE); -- -- /* we calculate a full state kinetic energy either with full-step velocity verlet -- or half step where we need the pressure */ -- -- bEkinAveVel = (ir->eI==eiVV || (ir->eI==eiVVAK && bPres) || bReadEkin); -- -- /* in initalization, it sums the shake virial in vv, and to -- sums ekinh_old in leapfrog (or if we are calculating ekinh_old) for other reasons */ -- -- /* ########## Kinetic energy ############## */ -- -- if (bTemp) -- { -- /* Non-equilibrium MD: this is parallellized, but only does communication -- * when there really is NEMD. -- */ -- -- if (PAR(cr) && (ekind->bNEMD)) -- { -- accumulate_u(cr,&(ir->opts),ekind); -- } -- debug_gmx(); -- if (bReadEkin) -- { -- restore_ekinstate_from_state(cr,ekind,&state_global->ekinstate); -- } -- else -- { -- -- calc_ke_part(state,&(ir->opts),mdatoms,ekind,nrnb,bEkinAveVel,bIterate); -- } -- -- debug_gmx(); -- -- /* Calculate center of mass velocity if necessary, also parallellized */ -- if (bStopCM && !bRerunMD && bEner) -- { -- calc_vcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms, -- state->x,state->v,vcm); -- } -- } -- -- if (bTemp || bPres || bEner || bConstrain) -- { -- if (!bGStat) -- { -- /* We will not sum ekinh_old, -- * so signal that we still have to do it. -- */ -- *bSumEkinhOld = TRUE; -- -- } -- else -- { -- if (gs != NULL) -- { -- for(i=0; isig[i]; -- } -- } -- if (PAR(cr)) -- { -- wallcycle_start(wcycle,ewcMoveE); -- GMX_MPE_LOG(ev_global_stat_start); -- global_stat(fplog,gstat,cr,enerd,force_vir,shake_vir,mu_tot, -- ir,ekind,constr,vcm, -- gs != NULL ? eglsNR : 0,gs_buf, -- top_global,state, -- *bSumEkinhOld,flags); -- GMX_MPE_LOG(ev_global_stat_finish); -- wallcycle_stop(wcycle,ewcMoveE); -- } -- if (gs != NULL) -- { -- if (MULTISIM(cr) && bInterSimGS) -- { -- if (MASTER(cr)) -- { -- /* Communicate the signals between the simulations */ -- gmx_sum_sim(eglsNR,gs_buf,cr->ms); -- } -- /* Communicate the signals form the master to the others */ -- gmx_bcast(eglsNR*sizeof(gs_buf[0]),gs_buf,cr); -- } -- for(i=0; i= 0 ? -- (int)(gs_buf[i] + 0.5) : -- (int)(gs_buf[i] - 0.5)); -- if (gsi != 0) -- { -- gs->set[i] = gsi; -- } -- /* Turn off the local signal */ -- gs->sig[i] = 0; -- } -- } -- } -- *bSumEkinhOld = FALSE; -- } -- } -- -- if (!ekind->bNEMD && debug && bTemp && (vcm->nr > 0)) -- { -- correct_ekin(debug, -- mdatoms->start,mdatoms->start+mdatoms->homenr, -- state->v,vcm->group_p[0], -- mdatoms->massT,mdatoms->tmass,ekind->ekin); -- } -- -- if (bEner) { -- /* Do center of mass motion removal */ -- if (bStopCM && !bRerunMD) /* is this correct? Does it get called too often with this logic? */ -- { -- check_cm_grp(fplog,vcm,ir,1); -- do_stopcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms->cVCM, -- state->x,state->v,vcm); -- inc_nrnb(nrnb,eNR_STOPCM,mdatoms->homenr); -- } -- -- /* Calculate the amplitude of the cosine velocity profile */ -- ekind->cosacc.vcos = ekind->cosacc.mvcos/mdatoms->tmass; -- } -- -- if (bTemp) -- { -- /* Sum the kinetic energies of the groups & calc temp */ -- /* compute full step kinetic energies if vv, or if vv-avek and we are computing the pressure with IR_NPT_TROTTER */ -- /* three maincase: VV with AveVel (md-vv), vv with AveEkin (md-vv-avek), leap with AveEkin (md). -- Leap with AveVel is not supported; it's not clear that it will actually work. -- bEkinAveVel: If TRUE, we simply multiply ekin by ekinscale to get a full step kinetic energy. -- If FALSE, we average ekinh_old and ekinh*ekinscale_nhc to get an averaged half step kinetic energy. -- bSaveEkinOld: If TRUE (in the case of iteration = bIterate is TRUE), we don't reset the ekinscale_nhc. -- If FALSE, we go ahead and erase over it. -- */ -- enerd->term[F_TEMP] = sum_ekin(&(ir->opts),ekind,&(enerd->term[F_DKDL]), -- bEkinAveVel,bIterate,bScaleEkin); -- -- enerd->term[F_EKIN] = trace(ekind->ekin); -- } -- -- /* ########## Long range energy information ###### */ -- -- if (bEner || bPres || bConstrain) -- { -- calc_dispcorr(fplog,ir,fr,0,top_global->natoms,box,state->lambda, -- corr_pres,corr_vir,&prescorr,&enercorr,&dvdlcorr); -- } -- -- if (bEner && bFirstIterate) -- { -- enerd->term[F_DISPCORR] = enercorr; -- enerd->term[F_EPOT] += enercorr; -- enerd->term[F_DVDL] += dvdlcorr; -- if (fr->efep != efepNO) { -- enerd->dvdl_lin += dvdlcorr; -- } -- } -- -- /* ########## Now pressure ############## */ -- if (bPres || bConstrain) -- { -- -- m_add(force_vir,shake_vir,total_vir); -- -- /* Calculate pressure and apply LR correction if PPPM is used. -- * Use the box from last timestep since we already called update(). -- */ -- -- enerd->term[F_PRES] = calc_pres(fr->ePBC,ir->nwall,box,ekind->ekin,total_vir,pres, -- (fr->eeltype==eelPPPM)?enerd->term[F_COUL_RECIP]:0.0); -- -- /* Calculate long range corrections to pressure and energy */ -- /* this adds to enerd->term[F_PRES] and enerd->term[F_ETOT], -- and computes enerd->term[F_DISPCORR]. Also modifies the -- total_vir and pres tesors */ -- -- m_add(total_vir,corr_vir,total_vir); -- m_add(pres,corr_pres,pres); -- enerd->term[F_PDISPCORR] = prescorr; -- enerd->term[F_PRES] += prescorr; -- *pcurr = enerd->term[F_PRES]; -- /* calculate temperature using virial */ -- enerd->term[F_VTEMP] = calc_temp(trace(total_vir),ir->opts.nrdf[0]); -- -- } --} -- -- --/* Definitions for convergence of iterated constraints */ -- --/* iterate constraints up to 50 times */ --#define MAXITERCONST 50 -- --/* data type */ --typedef struct --{ -- real f,fprev,x,xprev; -- int iter_i; -- gmx_bool bIterate; -- real allrelerr[MAXITERCONST+2]; -- int num_close; /* number of "close" violations, caused by limited precision. */ --} gmx_iterate_t; -- --#ifdef GMX_DOUBLE --#define CONVERGEITER 0.000000001 --#define CLOSE_ENOUGH 0.000001000 --#else --#define CONVERGEITER 0.0001 --#define CLOSE_ENOUGH 0.0050 --#endif -- --/* we want to keep track of the close calls. If there are too many, there might be some other issues. -- so we make sure that it's either less than some predetermined number, or if more than that number, -- only some small fraction of the total. */ --#define MAX_NUMBER_CLOSE 50 --#define FRACTION_CLOSE 0.001 -- --/* maximum length of cyclic traps to check, emerging from limited numerical precision */ --#define CYCLEMAX 20 -- --static void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate) --{ -- int i; -- -- iterate->iter_i = 0; -- iterate->bIterate = bIterate; -- iterate->num_close = 0; -- for (i=0;iallrelerr[i] = 0; -- } --} -- --static gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf) --{ -- /* monitor convergence, and use a secant search to propose new -- values. -- x_{i} - x_{i-1} -- The secant method computes x_{i+1} = x_{i} - f(x_{i}) * --------------------- -- f(x_{i}) - f(x_{i-1}) -- -- The function we are trying to zero is fom-x, where fom is the -- "figure of merit" which is the pressure (or the veta value) we -- would get by putting in an old value of the pressure or veta into -- the incrementor function for the step or half step. I have -- verified that this gives the same answer as self consistent -- iteration, usually in many fewer steps, especially for small tau_p. -- -- We could possibly eliminate an iteration with proper use -- of the value from the previous step, but that would take a bit -- more bookkeeping, especially for veta, since tests indicate the -- function of veta on the last step is not sufficiently close to -- guarantee convergence this step. This is -- good enough for now. On my tests, I could use tau_p down to -- 0.02, which is smaller that would ever be necessary in -- practice. Generally, 3-5 iterations will be sufficient */ -- -- real relerr,err,xmin; -- char buf[256]; -- int i; -- gmx_bool incycle; -- -- if (bFirstIterate) -- { -- iterate->x = fom; -- iterate->f = fom-iterate->x; -- iterate->xprev = 0; -- iterate->fprev = 0; -- *newf = fom; -- } -- else -- { -- iterate->f = fom-iterate->x; /* we want to zero this difference */ -- if ((iterate->iter_i > 1) && (iterate->iter_i < MAXITERCONST)) -- { -- if (iterate->f==iterate->fprev) -- { -- *newf = iterate->f; -- } -- else -- { -- *newf = iterate->x - (iterate->x-iterate->xprev)*(iterate->f)/(iterate->f-iterate->fprev); -- } -- } -- else -- { -- /* just use self-consistent iteration the first step to initialize, or -- if it's not converging (which happens occasionally -- need to investigate why) */ -- *newf = fom; -- } -- } -- /* Consider a slight shortcut allowing us to exit one sooner -- we check the -- difference between the closest of x and xprev to the new -- value. To be 100% certain, we should check the difference between -- the last result, and the previous result, or -- -- relerr = (fabs((x-xprev)/fom)); -- -- but this is pretty much never necessary under typical conditions. -- Checking numerically, it seems to lead to almost exactly the same -- trajectories, but there are small differences out a few decimal -- places in the pressure, and eventually in the v_eta, but it could -- save an interation. -- -- if (fabs(*newf-x) < fabs(*newf - xprev)) { xmin = x;} else { xmin = xprev;} -- relerr = (fabs((*newf-xmin) / *newf)); -- */ -- -- err = fabs((iterate->f-iterate->fprev)); -- relerr = fabs(err/fom); -- -- iterate->allrelerr[iterate->iter_i] = relerr; -- -- if (iterate->iter_i > 0) -- { -- if (debug) -- { -- fprintf(debug,"Iterating NPT constraints: %6i %20.12f%14.6g%20.12f\n", -- iterate->iter_i,fom,relerr,*newf); -- } -- -- if ((relerr < CONVERGEITER) || (err < CONVERGEITER) || (fom==0) || ((iterate->x == iterate->xprev) && iterate->iter_i > 1)) -- { -- iterate->bIterate = FALSE; -- if (debug) -- { -- fprintf(debug,"Iterating NPT constraints: CONVERGED\n"); -- } -- return TRUE; -- } -- if (iterate->iter_i > MAXITERCONST) -- { -- if (relerr < CLOSE_ENOUGH) -- { -- incycle = FALSE; -- for (i=1;iallrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-1]) && -- (iterate->allrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-(1+2*i)])) { -- incycle = TRUE; -- if (debug) -- { -- fprintf(debug,"Exiting from an NPT iterating cycle of length %d\n",i); -- } -- break; -- } -- } -- -- if (incycle) { -- /* step 1: trapped in a numerical attractor */ -- /* we are trapped in a numerical attractor, and can't converge any more, and are close to the final result. -- Better to give up convergence here than have the simulation die. -- */ -- iterate->num_close++; -- return TRUE; -- } -- else -- { -- /* Step #2: test if we are reasonably close for other reasons, then monitor the number. If not, die */ -- -- /* how many close calls have we had? If less than a few, we're OK */ -- if (iterate->num_close < MAX_NUMBER_CLOSE) -- { -- sprintf(buf,"Slight numerical convergence deviation with NPT at step %d, relative error only %10.5g, likely not a problem, continuing\n",nsteps,relerr); -- md_print_warning(cr,fplog,buf); -- iterate->num_close++; -- return TRUE; -- /* if more than a few, check the total fraction. If too high, die. */ -- } else if (iterate->num_close/(double)nsteps > FRACTION_CLOSE) { -- gmx_fatal(FARGS,"Could not converge NPT constraints, too many exceptions (%d%%\n",iterate->num_close/(double)nsteps); -- } -- } -- } -- else -- { -- gmx_fatal(FARGS,"Could not converge NPT constraints\n"); -- } -- } -- } -- -- iterate->xprev = iterate->x; -- iterate->x = *newf; -- iterate->fprev = iterate->f; -- iterate->iter_i++; -- -- return FALSE; --} -- --static void check_nst_param(FILE *fplog,t_commrec *cr, -- const char *desc_nst,int nst, -- const char *desc_p,int *p) --{ -- char buf[STRLEN]; -- -- if (*p > 0 && *p % nst != 0) -- { -- /* Round up to the next multiple of nst */ -- *p = ((*p)/nst + 1)*nst; -- sprintf(buf,"NOTE: %s changes %s to %d\n",desc_nst,desc_p,*p); -- md_print_warning(cr,fplog,buf); -- } --} -- --static void reset_all_counters(FILE *fplog,t_commrec *cr, -- gmx_large_int_t step, -- gmx_large_int_t *step_rel,t_inputrec *ir, -- gmx_wallcycle_t wcycle,t_nrnb *nrnb, -- gmx_runtime_t *runtime) --{ -- char buf[STRLEN],sbuf[STEPSTRSIZE]; -- -- /* Reset all the counters related to performance over the run */ -- sprintf(buf,"Step %s: resetting all time and cycle counters\n", -- gmx_step_str(step,sbuf)); -- md_print_warning(cr,fplog,buf); -- -- wallcycle_stop(wcycle,ewcRUN); -- wallcycle_reset_all(wcycle); -- if (DOMAINDECOMP(cr)) -- { -- reset_dd_statistics_counters(cr->dd); -- } -- init_nrnb(nrnb); -- ir->init_step += *step_rel; -- ir->nsteps -= *step_rel; -- *step_rel = 0; -- wallcycle_start(wcycle,ewcRUN); -- runtime_start(runtime); -- print_date_and_time(fplog,cr->nodeid,"Restarted time",runtime); --} -- --static void min_zero(int *n,int i) --{ -- if (i > 0 && (*n == 0 || i < *n)) -- { -- *n = i; -- } --} -- --static int lcd4(int i1,int i2,int i3,int i4) --{ -- int nst; -- -- nst = 0; -- min_zero(&nst,i1); -- min_zero(&nst,i2); -- min_zero(&nst,i3); -- min_zero(&nst,i4); -- if (nst == 0) -- { -- gmx_incons("All 4 inputs for determininig nstglobalcomm are <= 0"); -- } -- -- while (nst > 1 && ((i1 > 0 && i1 % nst != 0) || -- (i2 > 0 && i2 % nst != 0) || -- (i3 > 0 && i3 % nst != 0) || -- (i4 > 0 && i4 % nst != 0))) -- { -- nst--; -- } -- -- return nst; --} -- --static int check_nstglobalcomm(FILE *fplog,t_commrec *cr, -- int nstglobalcomm,t_inputrec *ir) --{ -- char buf[STRLEN]; -- -- if (!EI_DYNAMICS(ir->eI)) -- { -- nstglobalcomm = 1; -- } -- -- if (nstglobalcomm == -1) -- { -- if (!(ir->nstcalcenergy > 0 || -- ir->nstlist > 0 || -- ir->etc != etcNO || -- ir->epc != epcNO)) -- { -- nstglobalcomm = 10; -- if (ir->nstenergy > 0 && ir->nstenergy < nstglobalcomm) -- { -- nstglobalcomm = ir->nstenergy; -- } -- } -- else -- { -- /* Ensure that we do timely global communication for -- * (possibly) each of the four following options. -- */ -- nstglobalcomm = lcd4(ir->nstcalcenergy, -- ir->nstlist, -- ir->etc != etcNO ? ir->nsttcouple : 0, -- ir->epc != epcNO ? ir->nstpcouple : 0); -- } -- } -- else -- { -- if (ir->nstlist > 0 && -- nstglobalcomm > ir->nstlist && nstglobalcomm % ir->nstlist != 0) -- { -- nstglobalcomm = (nstglobalcomm / ir->nstlist)*ir->nstlist; -- sprintf(buf,"WARNING: nstglobalcomm is larger than nstlist, but not a multiple, setting it to %d\n",nstglobalcomm); -- md_print_warning(cr,fplog,buf); -- } -- if (ir->nstcalcenergy > 0) -- { -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nstcalcenergy",&ir->nstcalcenergy); -- } -- if (ir->etc != etcNO && ir->nsttcouple > 0) -- { -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nsttcouple",&ir->nsttcouple); -- } -- if (ir->epc != epcNO && ir->nstpcouple > 0) -- { -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nstpcouple",&ir->nstpcouple); -- } -- -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nstenergy",&ir->nstenergy); -- -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nstlog",&ir->nstlog); -- } -- -- if (ir->comm_mode != ecmNO && ir->nstcomm < nstglobalcomm) -- { -- sprintf(buf,"WARNING: Changing nstcomm from %d to %d\n", -- ir->nstcomm,nstglobalcomm); -- md_print_warning(cr,fplog,buf); -- ir->nstcomm = nstglobalcomm; -- } -- -- return nstglobalcomm; --} -- --void check_ir_old_tpx_versions(t_commrec *cr,FILE *fplog, -- t_inputrec *ir,gmx_mtop_t *mtop) --{ -- /* Check required for old tpx files */ -- if (IR_TWINRANGE(*ir) && ir->nstlist > 1 && -- ir->nstcalcenergy % ir->nstlist != 0) -- { -- md_print_warning(cr,fplog,"Old tpr file with twin-range settings: modifying energy calculation and/or T/P-coupling frequencies"); -- -- if (gmx_mtop_ftype_count(mtop,F_CONSTR) + -- gmx_mtop_ftype_count(mtop,F_CONSTRNC) > 0 && -- ir->eConstrAlg == econtSHAKE) -- { -- md_print_warning(cr,fplog,"With twin-range cut-off's and SHAKE the virial and pressure are incorrect"); -- if (ir->epc != epcNO) -- { -- gmx_fatal(FARGS,"Can not do pressure coupling with twin-range cut-off's and SHAKE"); -- } -- } -- check_nst_param(fplog,cr,"nstlist",ir->nstlist, -- "nstcalcenergy",&ir->nstcalcenergy); -- if (ir->epc != epcNO) -- { -- check_nst_param(fplog,cr,"nstlist",ir->nstlist, -- "nstpcouple",&ir->nstpcouple); -- } -- check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -- "nstenergy",&ir->nstenergy); -- check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -- "nstlog",&ir->nstlog); -- if (ir->efep != efepNO) -- { -- check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -- "nstdhdl",&ir->nstdhdl); -- } -- } --} -- --typedef struct { -- gmx_bool bGStatEveryStep; -- gmx_large_int_t step_ns; -- gmx_large_int_t step_nscheck; -- gmx_large_int_t nns; -- matrix scale_tot; -- int nabnsb; -- double s1; -- double s2; -- double ab; -- double lt_runav; -- double lt_runav2; --} gmx_nlheur_t; -- --static void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step) --{ -- nlh->lt_runav = 0; -- nlh->lt_runav2 = 0; -- nlh->step_nscheck = step; --} -- --static void init_nlistheuristics(gmx_nlheur_t *nlh, -- gmx_bool bGStatEveryStep,gmx_large_int_t step) --{ -- nlh->bGStatEveryStep = bGStatEveryStep; -- nlh->nns = 0; -- nlh->nabnsb = 0; -- nlh->s1 = 0; -- nlh->s2 = 0; -- nlh->ab = 0; -- -- reset_nlistheuristics(nlh,step); --} -- --static void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step) --{ -- gmx_large_int_t nl_lt; -- char sbuf[STEPSTRSIZE],sbuf2[STEPSTRSIZE]; -- -- /* Determine the neighbor list life time */ -- nl_lt = step - nlh->step_ns; -- if (debug) -- { -- fprintf(debug,"%d atoms beyond ns buffer, updating neighbor list after %s steps\n",nlh->nabnsb,gmx_step_str(nl_lt,sbuf)); -- } -- nlh->nns++; -- nlh->s1 += nl_lt; -- nlh->s2 += nl_lt*nl_lt; -- nlh->ab += nlh->nabnsb; -- if (nlh->lt_runav == 0) -- { -- nlh->lt_runav = nl_lt; -- /* Initialize the fluctuation average -- * such that at startup we check after 0 steps. -- */ -- nlh->lt_runav2 = sqr(nl_lt/2.0); -- } -- /* Running average with 0.9 gives an exp. history of 9.5 */ -- nlh->lt_runav2 = 0.9*nlh->lt_runav2 + 0.1*sqr(nlh->lt_runav - nl_lt); -- nlh->lt_runav = 0.9*nlh->lt_runav + 0.1*nl_lt; -- if (nlh->bGStatEveryStep) -- { -- /* Always check the nlist validity */ -- nlh->step_nscheck = step; -- } -- else -- { -- /* We check after: - 2*sigma -- * The factor 2 is quite conservative, -- * but we assume that with nstlist=-1 the user -- * prefers exact integration over performance. -- */ -- nlh->step_nscheck = step -- + (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2)) - 1; -- } -- if (debug) -- { -- fprintf(debug,"nlist life time %s run av. %4.1f sig %3.1f check %s check with -gcom %d\n", -- gmx_step_str(nl_lt,sbuf),nlh->lt_runav,sqrt(nlh->lt_runav2), -- gmx_step_str(nlh->step_nscheck-step+1,sbuf2), -- (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2))); -- } --} -- --static void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step) --{ -- int d; -- -- if (bReset) -- { -- reset_nlistheuristics(nlh,step); -- } -- else -- { -- update_nliststatistics(nlh,step); -- } -- -- nlh->step_ns = step; -- /* Initialize the cumulative coordinate scaling matrix */ -- clear_mat(nlh->scale_tot); -- for(d=0; dscale_tot[d][d] = 1.0; -- } --} -- --static void rerun_parallel_comm(t_commrec *cr,t_trxframe *fr, -- gmx_bool *bNotLastFrame) --{ -- gmx_bool bAlloc; -- rvec *xp,*vp; -- -- bAlloc = (fr->natoms == 0); -- -- if (MASTER(cr) && !*bNotLastFrame) -- { -- fr->natoms = -1; -- } -- xp = fr->x; -- vp = fr->v; -- gmx_bcast(sizeof(*fr),fr,cr); -- fr->x = xp; -- fr->v = vp; -- -- *bNotLastFrame = (fr->natoms >= 0); -- -- if (*bNotLastFrame && PARTDECOMP(cr)) -- { -- /* x and v are the only variable size quantities stored in trr -- * that are required for rerun (f is not needed). -- */ -- if (bAlloc) -- { -- snew(fr->x,fr->natoms); -- snew(fr->v,fr->natoms); -- } -- if (fr->bX) -- { -- gmx_bcast(fr->natoms*sizeof(fr->x[0]),fr->x[0],cr); -- } -- if (fr->bV) -- { -- gmx_bcast(fr->natoms*sizeof(fr->v[0]),fr->v[0],cr); -- } -- } --} -- - double do_md(FILE *fplog,t_commrec *cr,int nfile,const t_filenm fnm[], - const output_env_t oenv, gmx_bool bVerbose,gmx_bool bCompact, - int nstglobalcomm, -diff --git a/src/kernel/md_openmm.c b/src/kernel/md_openmm.c -index 908fd03..bbc9d1d 100644 ---- a/src/kernel/md_openmm.c -+++ b/src/kernel/md_openmm.c -@@ -98,105 +98,6 @@ - /* include even when OpenMM not used to force compilation of do_md_openmm */ - #include "openmm_wrapper.h" - --/* simulation conditions to transmit */ --enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; -- --typedef struct --{ -- int nstms; /* The frequency for intersimulation communication */ -- int sig[eglsNR]; /* The signal set by one process in do_md */ -- int set[eglsNR]; /* The communicated signal, equal for all processes */ --} globsig_t; -- -- --static int multisim_min(const gmx_multisim_t *ms,int nmin,int n) --{ -- int *buf; -- gmx_bool bPos,bEqual; -- int s,d; -- -- snew(buf,ms->nsim); -- buf[ms->sim] = n; -- gmx_sumi_sim(ms->nsim,buf,ms); -- bPos = TRUE; -- bEqual = TRUE; -- for (s=0; snsim; s++) -- { -- bPos = bPos && (buf[s] > 0); -- bEqual = bEqual && (buf[s] == buf[0]); -- } -- if (bPos) -- { -- if (bEqual) -- { -- nmin = min(nmin,buf[0]); -- } -- else -- { -- /* Find the least common multiple */ -- for (d=2; dnsim && d % buf[s] == 0) -- { -- s++; -- } -- if (s == ms->nsim) -- { -- /* We found the LCM and it is less than nmin */ -- nmin = d; -- break; -- } -- } -- } -- } -- sfree(buf); -- -- return nmin; --} -- --static int multisim_nstsimsync(const t_commrec *cr, -- const t_inputrec *ir,int repl_ex_nst) --{ -- int nmin; -- -- if (MASTER(cr)) -- { -- nmin = INT_MAX; -- nmin = multisim_min(cr->ms,nmin,ir->nstlist); -- nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); -- nmin = multisim_min(cr->ms,nmin,repl_ex_nst); -- if (nmin == INT_MAX) -- { -- gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); -- } -- /* Avoid inter-simulation communication at every (second) step */ -- if (nmin <= 2) -- { -- nmin = 10; -- } -- } -- -- gmx_bcast(sizeof(int),&nmin,cr); -- -- return nmin; --} -- --static void init_global_signals(globsig_t *gs,const t_commrec *cr, -- const t_inputrec *ir,int repl_ex_nst) --{ -- int i; -- -- gs->nstms = 1; -- -- for (i=0; isig[i] = 0; -- gs->set[i] = 0; -- } --} -- -- - double do_md_openmm(FILE *fplog,t_commrec *cr,int nfile,const t_filenm fnm[], - const output_env_t oenv, gmx_bool bVerbose,gmx_bool bCompact, - int nstglobalcomm, -diff --git a/src/kernel/mdrun.c b/src/kernel/mdrun.c -index 6379a6d..8878331 100644 ---- a/src/kernel/mdrun.c -+++ b/src/kernel/mdrun.c -@@ -189,7 +189,7 @@ int main(int argc,char *argv[]) - "(the simulation will run correctly also when this is not the case).", - "[PAR]", - "This section lists all options that affect the domain decomposition.", -- "[BR]", -+ "[PAR]", - "Option [TT]-rdd[tt] can be used to set the required maximum distance", - "for inter charge-group bonded interactions.", - "Communication for two-body bonded interactions below the non-bonded", -@@ -202,13 +202,13 @@ int main(int argc,char *argv[]) - "By default [TT]-rdd[tt] is determined by [TT]mdrun[tt] based on", - "the initial coordinates. The chosen value will be a balance", - "between interaction range and communication cost.", -- "[BR]", -+ "[PAR]", - "When inter charge-group bonded interactions are beyond", - "the bonded cut-off distance, [TT]mdrun[tt] terminates with an error message.", - "For pair interactions and tabulated bonds", - "that do not generate exclusions, this check can be turned off", - "with the option [TT]-noddcheck[tt].", -- "[BR]", -+ "[PAR]", - "When constraints are present, option [TT]-rcon[tt] influences", - "the cell size limit as well.", - "Atoms connected by NC constraints, where NC is the LINCS order plus 1,", -@@ -218,7 +218,7 @@ int main(int argc,char *argv[]) - "By default [TT]mdrun[tt] estimates the minimum cell size required for P-LINCS", - "in a conservative fashion. For high parallelization it can be useful", - "to set the distance required for P-LINCS with the option [TT]-rcon[tt].", -- "[BR]", -+ "[PAR]", - "The [TT]-dds[tt] option sets the minimum allowed x, y and/or z scaling", - "of the cells with dynamic load balancing. [TT]mdrun[tt] will ensure that", - "the cells can scale down by at least this factor. This option is used", -@@ -248,17 +248,17 @@ int main(int argc,char *argv[]) - "When user-defined potential functions have been selected in the", - "[TT].mdp[tt] file the [TT]-table[tt] option is used to pass [TT]mdrun[tt]", - "a formatted table with potential functions. The file is read from", -- "either the current directory or from the GMXLIB directory.", -- "A number of pre-formatted tables are presented in the GMXLIB dir,", -- "for 6-8, 6-9, 6-10, 6-11, 6-12 Lennard Jones potentials with", -+ "either the current directory or from the [TT]GMXLIB[tt] directory.", -+ "A number of pre-formatted tables are presented in the [TT]GMXLIB[tt] dir,", -+ "for 6-8, 6-9, 6-10, 6-11, 6-12 Lennard-Jones potentials with", - "normal Coulomb.", -- "When pair interactions are present a separate table for pair interaction", -+ "When pair interactions are present, a separate table for pair interaction", - "functions is read using the [TT]-tablep[tt] option.[PAR]", - "When tabulated bonded functions are present in the topology,", - "interaction functions are read using the [TT]-tableb[tt] option.", - "For each different tabulated interaction type the table file name is", - "modified in a different way: before the file extension an underscore is", -- "appended, then a b for bonds, an a for angles or a d for dihedrals", -+ "appended, then a 'b' for bonds, an 'a' for angles or a 'd' for dihedrals", - "and finally the table number of the interaction type.[PAR]", - "The options [TT]-px[tt] and [TT]-pf[tt] are used for writing pull COM", - "coordinates and forces when pulling is selected", -@@ -287,7 +287,7 @@ int main(int argc,char *argv[]) - "is performed after every exchange.[PAR]", - "Finally some experimental algorithms can be tested when the", - "appropriate options have been given. Currently under", -- "investigation are: polarizability, and X-Ray bombardments.", -+ "investigation are: polarizability and X-ray bombardments.", - "[PAR]", - "The option [TT]-pforce[tt] is useful when you suspect a simulation", - "crashes due to too large forces. With this option coordinates and", -@@ -309,11 +309,11 @@ int main(int argc,char *argv[]) - "will be appending to the existing output files. The checkpoint file", - "contains checksums of all output files, such that you will never", - "loose data when some output files are modified, corrupt or removed.", -- "There are three scenarios with [TT]-cpi[tt]:[BR]", -- "* no files with matching names are present: new output files are written[BR]", -- "* all files are present with names and checksums matching those stored", -- "in the checkpoint file: files are appended[BR]", -- "* otherwise no files are modified and a fatal error is generated[BR]", -+ "There are three scenarios with [TT]-cpi[tt]:[PAR]", -+ "[TT]*[tt] no files with matching names are present: new output files are written[PAR]", -+ "[TT]*[tt] all files are present with names and checksums matching those stored", -+ "in the checkpoint file: files are appended[PAR]", -+ "[TT]*[tt] otherwise no files are modified and a fatal error is generated[PAR]", - "With [TT]-noappend[tt] new output files are opened and the simulation", - "part number is added to all output file names.", - "Note that in all cases the checkpoint file itself is not renamed", -diff --git a/src/kernel/pdb2gmx.c b/src/kernel/pdb2gmx.c -index 0489572..269bcb7 100644 ---- a/src/kernel/pdb2gmx.c -+++ b/src/kernel/pdb2gmx.c -@@ -948,13 +948,13 @@ int main(int argc, char *argv[]) - const char *desc[] = { - "This program reads a [TT].pdb[tt] (or [TT].gro[tt]) file, reads", - "some database files, adds hydrogens to the molecules and generates", -- "coordinates in Gromacs (Gromos), or optionally [TT].pdb[tt], format", -- "and a topology in Gromacs format.", -+ "coordinates in GROMACS (GROMOS), or optionally [TT].pdb[tt], format", -+ "and a topology in GROMACS format.", - "These files can subsequently be processed to generate a run input file.", - "[PAR]", - "[TT]pdb2gmx[tt] will search for force fields by looking for", - "a [TT]forcefield.itp[tt] file in subdirectories [TT].ff[tt]", -- "of the current working directory and of the Gromacs library directory", -+ "of the current working directory and of the GROMACS library directory", - "as inferred from the path of the binary or the [TT]GMXLIB[tt] environment", - "variable.", - "By default the forcefield selection is interactive,", -@@ -965,12 +965,12 @@ int main(int argc, char *argv[]) - "After choosing a force field, all files will be read only from", - "the corresponding force field directory.", - "If you want to modify or add a residue types, you can copy the force", -- "field directory from the Gromacs library directory to your current", -+ "field directory from the GROMACS library directory to your current", - "working directory. If you want to add new protein residue types,", - "you will need to modify [TT]residuetypes.dat[tt] in the library directory", - "or copy the whole library directory to a local directory and set", - "the environment variable [TT]GMXLIB[tt] to the name of that directory.", -- "Check chapter 5 of the manual for more information about file formats.", -+ "Check Chapter 5 of the manual for more information about file formats.", - "[PAR]", - - "Note that a [TT].pdb[tt] file is nothing more than a file format, and it", -@@ -981,24 +981,29 @@ int main(int argc, char *argv[]) - "The program has limited intelligence, it reads a number of database", - "files, that allow it to make special bonds (Cys-Cys, Heme-His, etc.),", - "if necessary this can be done manually. The program can prompt the", -- "user to select which kind of LYS, ASP, GLU, CYS or HIS residue she", -- "wants. For LYS the choice is between neutral (two protons on NZ) or", -- "protonated (three protons, default), for ASP and GLU unprotonated", -- "(default) or protonated, for HIS the proton can be either on ND1,", -+ "user to select which kind of LYS, ASP, GLU, CYS or HIS residue is", -+ "desired. For Lys the choice is between neutral (two protons on NZ) or", -+ "protonated (three protons, default), for Asp and Glu unprotonated", -+ "(default) or protonated, for His the proton can be either on ND1,", - "on NE2 or on both. By default these selections are done automatically.", - "For His, this is based on an optimal hydrogen bonding", - "conformation. Hydrogen bonds are defined based on a simple geometric", - "criterion, specified by the maximum hydrogen-donor-acceptor angle", - "and donor-acceptor distance, which are set by [TT]-angle[tt] and", - "[TT]-dist[tt] respectively.[PAR]", -- -+ -+ "The protonation state of N- and C-termini can be chosen interactively", -+ "with the [TT]-ter[tt] flag. Default termini are ionized (NH3+ and COO-),", -+ "respectively. Some force fields support zwitterionic forms for chains of", -+ "one residue, but for polypeptides these options should NOT be selected.[PAR]", -+ - "The separation of chains is not entirely trivial since the markup", - "in user-generated PDB files frequently varies and sometimes it", - "is desirable to merge entries across a TER record, for instance", - "if you want a disulfide bridge or distance restraints between", - "two protein chains or if you have a HEME group bound to a protein.", - "In such cases multiple chains should be contained in a single", -- "[TT]molecule_type[tt] definition.", -+ "[TT]moleculetype[tt] definition.", - "To handle this, [TT]pdb2gmx[tt] has an option [TT]-chainsep[tt] so you can", - "choose whether a new chain should start when we find a TER record,", - "when the chain id changes, combinations of either or both of these", -@@ -1007,14 +1012,14 @@ int main(int argc, char *argv[]) - "[TT]pdb2gmx[tt] will also check the occupancy field of the [TT].pdb[tt] file.", - "If any of the occupancies are not one, indicating that the atom is", - "not resolved well in the structure, a warning message is issued.", -- "When a [TT].pdb[tt] file does not originate from an X-Ray structure determination", -+ "When a [TT].pdb[tt] file does not originate from an X-ray structure determination", - "all occupancy fields may be zero. Either way, it is up to the user", - "to verify the correctness of the input data (read the article!).[PAR]", - -- "During processing the atoms will be reordered according to Gromacs", -+ "During processing the atoms will be reordered according to GROMACS", - "conventions. With [TT]-n[tt] an index file can be generated that", - "contains one group reordered in the same way. This allows you to", -- "convert a Gromos trajectory and coordinate file to Gromos. There is", -+ "convert a GROMOS trajectory and coordinate file to GROMOS. There is", - "one limitation: reordering is done after the hydrogens are stripped", - "from the input and before new hydrogens are added. This means that", - "you should not use [TT]-ignh[tt].[PAR]", -@@ -1030,7 +1035,7 @@ int main(int argc, char *argv[]) - "position relative to neighboring atoms. Additionally, all atoms in the", - "aromatic rings of the standard amino acids (i.e. PHE, TRP, TYR and HIS)", - "can be converted into virtual sites, eliminating the fast improper dihedral", -- "fluctuations in these rings. Note that in this case all other hydrogen", -+ "fluctuations in these rings. [BB]Note[bb] that in this case all other hydrogen", - "atoms are also converted to virtual sites. The mass of all atoms that are", - "converted into virtual sites, is added to the heavy atoms.[PAR]", - "Also slowing down of dihedral motion can be done with [TT]-heavyh[tt]", -@@ -1157,24 +1162,24 @@ int main(int argc, char *argv[]) - { "-ter", FALSE, etBOOL, {&bTerMan}, - "Interactive termini selection, iso charged" }, - { "-lys", FALSE, etBOOL, {&bLysMan}, -- "Interactive Lysine selection, iso charged" }, -+ "Interactive lysine selection, iso charged" }, - { "-arg", FALSE, etBOOL, {&bArgMan}, -- "Interactive Arganine selection, iso charged" }, -+ "Interactive arginine selection, iso charged" }, - { "-asp", FALSE, etBOOL, {&bAspMan}, -- "Interactive Aspartic Acid selection, iso charged" }, -+ "Interactive aspartic Acid selection, iso charged" }, - { "-glu", FALSE, etBOOL, {&bGluMan}, -- "Interactive Glutamic Acid selection, iso charged" }, -+ "Interactive glutamic Acid selection, iso charged" }, - { "-gln", FALSE, etBOOL, {&bGlnMan}, -- "Interactive Glutamine selection, iso neutral" }, -+ "Interactive glutamine selection, iso neutral" }, - { "-his", FALSE, etBOOL, {&bHisMan}, -- "Interactive Histidine selection, iso checking H-bonds" }, -+ "Interactive histidine selection, iso checking H-bonds" }, - { "-angle", FALSE, etREAL, {&angle}, - "Minimum hydrogen-donor-acceptor angle for a H-bond (degrees)" }, - { "-dist", FALSE, etREAL, {&distance}, - "Maximum donor-acceptor distance for a H-bond (nm)" }, - { "-una", FALSE, etBOOL, {&bUnA}, -- "Select aromatic rings with united CH atoms on Phenylalanine, " -- "Tryptophane and Tyrosine" }, -+ "Select aromatic rings with united CH atoms on phenylalanine, " -+ "tryptophane and tyrosine" }, - { "-sort", FALSE, etBOOL, {&bSort}, - "HIDDENSort the residues according to database, turning this off is dangerous as charge groups might be broken in parts" }, - { "-ignh", FALSE, etBOOL, {&bRemoveH}, -diff --git a/src/kernel/repl_ex.c b/src/kernel/repl_ex.c -index 8bff387..e4c9089 100644 ---- a/src/kernel/repl_ex.c -+++ b/src/kernel/repl_ex.c -@@ -89,24 +89,20 @@ static void repl_quantity(FILE *fplog,const gmx_multisim_t *ms, - { - bDiff = TRUE; - } -- -- if (bDiff) -+ } -+ if (bDiff) -+ { -+ if (re->type >= 0 && re->type < ereNR) - { -- if (re->type >= 0 && re->type < ereNR) -- { -- gmx_fatal(FARGS,"For replica exchange both %s and %s differ", -- erename[re->type],erename[ere]); -- } -- else -- { -- /* Set the replica exchange type and quantities */ -- re->type = ere; -- snew(re->q,re->nrepl); -- for(s=0; snsim; s++) -- { -- re->q[s] = qall[s]; -- } -- } -+ gmx_fatal(FARGS,"For replica exchange both %s and %s differ", -+ erename[re->type],erename[ere]); -+ } -+ /* Set the replica exchange type and quantities */ -+ re->type = ere; -+ snew(re->q,re->nrepl); -+ for(s=0; snsim; s++) -+ { -+ re->q[s] = qall[s]; - } - } - -diff --git a/src/kernel/runner.c b/src/kernel/runner.c -index 888fe31..cf2fd37 100644 ---- a/src/kernel/runner.c -+++ b/src/kernel/runner.c -@@ -274,7 +274,7 @@ static int get_nthreads(int nthreads_requested, t_inputrec *inputrec, - } - else - { -- nthreads = tMPI_Get_recommended_nthreads(); -+ nthreads = tMPI_Thread_get_hw_number(); - } - } - -@@ -884,15 +884,3 @@ int mdrunner(int nthreads_requested, FILE *fplog,t_commrec *cr,int nfile, - - return rc; - } -- --void md_print_warning(const t_commrec *cr,FILE *fplog,const char *buf) --{ -- if (MASTER(cr)) -- { -- fprintf(stderr,"\n%s\n",buf); -- } -- if (fplog) -- { -- fprintf(fplog,"\n%s\n",buf); -- } --} -diff --git a/src/kernel/tpbconv.c b/src/kernel/tpbconv.c -index e5715c9..f423f9a 100644 ---- a/src/kernel/tpbconv.c -+++ b/src/kernel/tpbconv.c -@@ -307,7 +307,7 @@ int main (int argc, char *argv[]) - "of the original run.[PAR]", - "[BB]3.[bb] by creating a [TT].tpx[tt] file for a subset of your original", - "tpx file, which is useful when you want to remove the solvent from", -- "your [TT].tpx[tt] file, or when you want to make e.g. a pure Ca [TT].tpx[tt] file.", -+ "your [TT].tpx[tt] file, or when you want to make e.g. a pure C[GRK]alpha[grk] [TT].tpx[tt] file.", - "Note that you may need to use [TT]-nsteps -1[tt] (or similar) to get", - "this to work.", - "[BB]WARNING: this [TT].tpx[tt] file is not fully functional[bb].[PAR]", -diff --git a/src/mdlib/Makefile.am b/src/mdlib/Makefile.am -index a413744..6c4cd6d 100644 ---- a/src/mdlib/Makefile.am -+++ b/src/mdlib/Makefile.am -@@ -24,8 +24,9 @@ libmd@LIBSUFFIX@_la_SOURCES = \ - edsam.c ewald.c \ - force.c forcerec.c \ - ghat.c init.c \ -+ iteratedconstraints.c md_support.c \ - mdatom.c mdebin.c minimize.c \ -- mvxvf.c ns.c nsgrid.c \ -+ mvxvf.c ns.c nlistheuristics.c nsgrid.c \ - perf_est.c genborn.c \ - genborn_sse2_single.c \ - genborn_sse2_single.h \ -diff --git a/src/mdlib/edsam.c b/src/mdlib/edsam.c -index 3fbc09d..ffae4c3 100644 ---- a/src/mdlib/edsam.c -+++ b/src/mdlib/edsam.c -@@ -1,12 +1,12 @@ - /* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -- * -- * -+ * -+ * - * This source code is part of -- * -+ * - * G R O M A C S -- * -+ * - * GROningen MAchine for Chemical Simulations -- * -+ * - * VERSION 3.2.0 - * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. - * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -@@ -16,19 +16,19 @@ - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. -- * -+ * - * If you want to redistribute modifications, please consider that - * scientific software is very special. Version control is crucial - - * bugs must be traceable. We will be happy to consider code for - * inclusion in the official distribution, but derived work must not - * be called official GROMACS. Details are found in the README & COPYING - * files - if they are missing, get the official version at www.gromacs.org. -- * -+ * - * To help us fund GROMACS development, we humbly ask that you cite - * the papers on the package - you can find them in the top README file. -- * -+ * - * For more info, check our website at http://www.gromacs.org -- * -+ * - * And Hey: - * GROwing Monsters And Cloning Shrimps - */ -@@ -95,25 +95,28 @@ typedef struct - t_eigvec linfix; /* fixed linear constraints */ - t_eigvec linacc; /* acceptance linear constraints */ - t_eigvec radfix; /* fixed radial constraints (exp) */ -- t_eigvec radacc; /* acceptance radial constraints (exp) */ -+ t_eigvec radacc; /* acceptance radial constraints (exp) */ - t_eigvec radcon; /* acceptance rad. contraction constr. */ - } t_edvecs; - - - typedef struct --{ -+{ - real deltaF0; -- gmx_bool bHarmonic; /* Use flooding for harmonic restraint on eigenvector */ -+ gmx_bool bHarmonic; /* Use flooding for harmonic restraint on -+ the eigenvector */ -+ gmx_bool bConstForce; /* Do not calculate a flooding potential, -+ instead flood with a constant force */ - real tau; - real deltaF; - real Efl; -- real kT; -+ real kT; - real Vfl; - real dt; - real constEfl; -- real alpha2; -+ real alpha2; - int flood_id; -- rvec *forces_cartesian; -+ rvec *forces_cartesian; - t_eigvec vecs; /* use flooding for these */ - } t_edflood; - -@@ -126,14 +129,14 @@ typedef struct gmx_edx - int *anrs; /* atom index numbers */ - int *anrs_loc; /* local atom index numbers */ - int nalloc_loc; /* allocation size of anrs_loc */ -- int *c_ind; /* at which position of the whole anrs -- * array is a local atom?, i.e. -- * c_ind[0...nr_loc-1] gives the atom index -- * with respect to the collective -+ int *c_ind; /* at which position of the whole anrs -+ * array is a local atom?, i.e. -+ * c_ind[0...nr_loc-1] gives the atom index -+ * with respect to the collective - * anrs[0...nr-1] array */ - rvec *x; /* positions for this structure */ - rvec *x_old; /* used to keep track of the shift vectors -- such that the ED molecule can always be -+ such that the ED molecule can always be - made whole in the parallel case */ - real *m; /* masses */ - real mtot; /* total mass (only used in sref) */ -@@ -147,7 +150,7 @@ typedef struct edpar - int nini; /* total Nr of atoms */ - gmx_bool fitmas; /* true if trans fit with cm */ - gmx_bool pcamas; /* true if mass-weighted PCA */ -- int presteps; /* number of steps to run without any -+ int presteps; /* number of steps to run without any - * perturbations ... just monitoring */ - int outfrq; /* freq (in steps) of writing to edo */ - int maxedsteps; /* max nr of steps per cycle */ -@@ -189,9 +192,9 @@ struct t_do_edsam - matrix old_rotmat; - real oldrad; - rvec old_transvec,older_transvec,transvec_compact; -- rvec *xcoll; /* Positions from all nodes, this is the -+ rvec *xcoll; /* Positions from all nodes, this is the - collective set we work on. -- These are the positions of atoms with -+ These are the positions of atoms with - average structure indices */ - rvec *xc_ref; /* same but with reference structure indices */ - ivec *shifts_xcoll; /* Shifts for xcoll */ -@@ -199,7 +202,7 @@ struct t_do_edsam - ivec *shifts_xc_ref; /* Shifts for xc_ref */ - ivec *extra_shifts_xc_ref; /* xc_ref shift changes since last NS step */ - gmx_bool bUpdateShifts; /* TRUE in NS steps to indicate that the -- ED shifts for this ED dataset need to -+ ED shifts for this ED dataset need to - be updated */ - }; - -@@ -256,17 +259,17 @@ static void rad_project(t_edpar *edi, rvec *x, t_eigvec *vec, t_commrec *cr) - rad += pow((vec->refproj[i]-vec->xproj[i]),2); - } - vec->radius=sqrt(rad); -- -+ - /* Add average positions */ -- for (i = 0; i < edi->sav.nr; i++) -+ for (i = 0; i < edi->sav.nr; i++) - rvec_inc(x[i], edi->sav.x[i]); - } - - --/* Project vector x, subtract average positions prior to projection and add -+/* Project vector x, subtract average positions prior to projection and add - * them afterwards to retain the unchanged vector. Store in xproj. Mass-weighting - * is applied. */ --static void project_to_eigvectors(rvec *x, /* The positions to project to an eigenvector */ -+static void project_to_eigvectors(rvec *x, /* The positions to project to an eigenvector */ - t_eigvec *vec, /* The eigenvectors */ - t_edpar *edi) - { -@@ -276,20 +279,20 @@ static void project_to_eigvectors(rvec *x, /* The positions to project - if (!vec->neig) return; - - /* Subtract average positions */ -- for (i=0; isav.nr; i++) -+ for (i=0; isav.nr; i++) - rvec_dec(x[i], edi->sav.x[i]); - - for (i=0; ineig; i++) - vec->xproj[i] = projectx(edi, x, vec->vec[i]); - - /* Add average positions */ -- for (i=0; isav.nr; i++) -+ for (i=0; isav.nr; i++) - rvec_inc(x[i], edi->sav.x[i]); - } - - - /* Project vector x onto all edi->vecs (mon, linfix,...) */ --static void project(rvec *x, /* positions to project */ -+static void project(rvec *x, /* positions to project */ - t_edpar *edi) /* edi data set */ - { - /* It is not more work to subtract the average position in every -@@ -309,7 +312,7 @@ static real calc_radius(t_eigvec *vec) - real rad=0.0; - - -- for (i=0; ineig; i++) -+ for (i=0; ineig; i++) - rad += pow((vec->refproj[i]-vec->xproj[i]),2); - - return rad=sqrt(rad); -@@ -318,7 +321,7 @@ static real calc_radius(t_eigvec *vec) - - /* Debug helper */ - #ifdef DEBUGHELPERS --static void dump_xcoll(t_edpar *edi, struct t_do_edsam *buf, t_commrec *cr, -+static void dump_xcoll(t_edpar *edi, struct t_do_edsam *buf, t_commrec *cr, - int step) - { - int i; -@@ -327,22 +330,22 @@ static void dump_xcoll(t_edpar *edi, struct t_do_edsam *buf, t_commrec *cr, - rvec *xcoll; - ivec *shifts, *eshifts; - -- -+ - if (!MASTER(cr)) - return; -- -+ - xcoll = buf->xcoll; - shifts = buf->shifts_xcoll; - eshifts = buf->extra_shifts_xcoll; -- -+ - sprintf(fn, "xcolldump_step%d.txt", step); - fp = fopen(fn, "w"); -- -+ - for (i=0; isav.nr; i++) -- fprintf(fp, "%d %9.5f %9.5f %9.5f %d %d %d %d %d %d\n", -- edi->sav.anrs[i]+1, -+ fprintf(fp, "%d %9.5f %9.5f %9.5f %d %d %d %d %d %d\n", -+ edi->sav.anrs[i]+1, - xcoll[i][XX] , xcoll[i][YY] , xcoll[i][ZZ], -- shifts[i][XX] , shifts[i][YY] , shifts[i][ZZ], -+ shifts[i][XX] , shifts[i][YY] , shifts[i][ZZ], - eshifts[i][XX], eshifts[i][YY], eshifts[i][ZZ]); - - fclose(fp); -@@ -354,7 +357,7 @@ static void dump_edi_positions(FILE *out, struct gmx_edx *s, const char name[]) - { - int i; - -- -+ - fprintf(out, "#%s positions:\n%d\n", name, s->nr); - if (s->nr == 0) - return; -@@ -362,7 +365,7 @@ static void dump_edi_positions(FILE *out, struct gmx_edx *s, const char name[]) - fprintf(out, "#index, x, y, z"); - if (s->sqrtm) - fprintf(out, ", sqrt(m)"); -- for (i=0; inr; i++) -+ for (i=0; inr; i++) - { - fprintf(out, "\n%6d %11.6f %11.6f %11.6f",s->anrs[i], s->x[i][XX], s->x[i][YY], s->x[i][ZZ]); - if (s->sqrtm) -@@ -378,12 +381,12 @@ static void dump_edi_eigenvecs(FILE *out, t_eigvec *ev, - { - int i,j; - -- -+ - fprintf(out, "#%s eigenvectors:\n%d\n", name, ev->neig); - /* Dump the data for every eigenvector: */ - for (i=0; ineig; i++) - { -- fprintf(out, "EV %4d\ncomponents %d\nstepsize %f\nxproj %f\nfproj %f\nrefproj %f\nradius %f\nComponents:\n", -+ fprintf(out, "EV %4d\ncomponents %d\nstepsize %f\nxproj %f\nfproj %f\nrefproj %f\nradius %f\nComponents:\n", - ev->ieig[i], length, ev->stpsz[i], ev->xproj[i], ev->fproj[i], ev->refproj[i], ev->radius); - for (j=0; jvec[i][j][XX], ev->vec[i][j][YY], ev->vec[i][j][ZZ]); -@@ -445,11 +448,11 @@ static void dump_rotmat(FILE* out,matrix rotmat) - - - /* Debug helper */ --static void dump_rvec(FILE *out, int dim, rvec *x) -+static void dump_rvec(FILE *out, int dim, rvec *x) - { - int i; - -- -+ - for (i=0; ibuf->do_edfit; - -- if (bFirst) -+ if (bFirst) - { - snew(loc->omega,2*DIM); - snew(loc->om,2*DIM); -@@ -597,11 +600,11 @@ static void do_edfit(int natoms,rvec *xp,rvec *x,matrix R,t_edpar *edi) - } - - --static void rmfit(int nat, rvec *xcoll, rvec transvec, matrix rotmat) -+static void rmfit(int nat, rvec *xcoll, rvec transvec, matrix rotmat) - { - rvec vec; - matrix tmat; -- -+ - - /* Remove rotation. - * The inverse rotation is described by the transposed rotation matrix */ -@@ -619,19 +622,19 @@ static void rmfit(int nat, rvec *xcoll, rvec transvec, matrix rotmat) - /********************************************************************************** - ******************** FLOODING **************************************************** - ********************************************************************************** -- --The flooding ability was added later to edsam. Many of the edsam functionality could be reused for that purpose. --The flooding covariance matrix, i.e. the selected eigenvectors and their corresponding eigenvalues are --read as 7th Component Group. The eigenvalues are coded into the stepsize parameter (as used by -linfix or -linacc). -+ -+The flooding ability was added later to edsam. Many of the edsam functionality could be reused for that purpose. -+The flooding covariance matrix, i.e. the selected eigenvectors and their corresponding eigenvalues are -+read as 7th Component Group. The eigenvalues are coded into the stepsize parameter (as used by -linfix or -linacc). - - do_md clls right in the beginning the function init_edsam, which reads the edi file, saves all the necessary information in - the edi structure and calls init_flood, to initialise some extra fields in the edi->flood structure. - --since the flooding acts on forces do_flood is called from the function force() (force.c), while the other -+since the flooding acts on forces do_flood is called from the function force() (force.c), while the other - edsam functionality is hooked into md via the update() (update.c) function acting as constraint on positions. - - do_flood makes a copy of the positions, --fits them, projects them computes flooding_energy, and flooding forces. The forces are computed in the -+fits them, projects them computes flooding_energy, and flooding forces. The forces are computed in the - space of the eigenvectors and are then blown up to the full cartesian space and rotated back to remove the - fit. Then do_flood adds these forces to the forcefield-forces - (given as parameter) and updates the adaptive flooding parameters Efl and deltaF. -@@ -645,28 +648,28 @@ To use the flooding potential as restraint, make_edi has the option -restrain, w - signs of alpha2 and Efl, such that the sign in the exponential of Vfl is not inverted but the sign of - Vfl is inverted. Vfl = Efl * exp (- .../Efl/alpha2*x^2...) With tau>0 the negative Efl will grow slowly - so that the restraint is switched off slowly. When Efl==0 and inverted flooding is ON is reached no -- further adaption is applied, Efl will stay constant at zero. -+ further adaption is applied, Efl will stay constant at zero. - --To use restraints with harmonic potentials switch -restrain and -harmonic. Then the eigenvalues are --used as spring constants for the harmonic potential. -+To use restraints with harmonic potentials switch -restrain and -harmonic. Then the eigenvalues are -+used as spring constants for the harmonic potential. - Note that eq3 in the flooding paper (J. Comp. Chem. 2006, 27, 1693-1702) defines the parameter lambda \ - as the inverse of the spring constant, whereas the implementation uses lambda as the spring constant. - - To use more than one flooding matrix just concatenate several .edi files (cat flood1.edi flood2.edi > flood_all.edi) - the routine read_edi_file reads all of theses flooding files. --The structure t_edi is now organized as a list of t_edis and the function do_flood cycles through the list --calling the do_single_flood() routine for every single entry. Since every state variables have been kept in one --edi there is no interdependence whatsoever. The forces are added together. -+The structure t_edi is now organized as a list of t_edis and the function do_flood cycles through the list -+calling the do_single_flood() routine for every single entry. Since every state variables have been kept in one -+edi there is no interdependence whatsoever. The forces are added together. - -- To write energies into the .edr file, call the function -+ To write energies into the .edr file, call the function - get_flood_enx_names(char**, int *nnames) to get the Header (Vfl1 Vfl2... Vfln) - and call -- get_flood_energies(real Vfl[],int nnames); -+ get_flood_energies(real Vfl[],int nnames); - - TODO: - - one could program the whole thing such that Efl, Vfl and deltaF is written to the .edr file. -- i dont know how to do that, yet. - -- Maybe one should give a range of atoms for which to remove motion, so that motion is removed with -+ Maybe one should give a range of atoms for which to remove motion, so that motion is removed with - two edsam files from two peptide chains - */ - -@@ -676,7 +679,7 @@ static void write_edo_flood(t_edpar *edi, FILE *fp, gmx_large_int_t step) - char buf[22]; - gmx_bool bOutputRef=FALSE; - -- -+ - fprintf(fp,"%d.th FL: %s %12.5e %12.5e %12.5e\n", - edi->flood.flood_id, gmx_step_str(step,buf), - edi->flood.Efl, edi->flood.Vfl, edi->flood.deltaF); -@@ -703,10 +706,10 @@ static void write_edo_flood(t_edpar *edi, FILE *fp, gmx_large_int_t step) - } - } - fprintf(fp,"FL_FORCES: "); -- -+ - for (i=0; iflood.vecs.neig; i++) - fprintf(fp," %12.5e",edi->flood.vecs.fproj[i]); -- -+ - fprintf(fp,"\n"); - } - -@@ -737,12 +740,15 @@ static real flood_energy(t_edpar *edi, gmx_large_int_t step) - edi->flood.vecs.refproj[i] = edi->flood.vecs.refproj0[i] + step * edi->flood.vecs.refprojslope[i]; - } - } -- -+ - sum=0.0; - /* Compute sum which will be the exponent of the exponential */ - for (i=0; iflood.vecs.neig; i++) -+ { -+ /* stpsz stores the reciprocal eigenvalue 1/sigma_i */ - sum += edi->flood.vecs.stpsz[i]*(edi->flood.vecs.xproj[i]-edi->flood.vecs.refproj[i])*(edi->flood.vecs.xproj[i]-edi->flood.vecs.refproj[i]); -- -+ } -+ - /* Compute the Gauss function*/ - if (edi->flood.bHarmonic) - { -@@ -762,7 +768,7 @@ static void flood_forces(t_edpar *edi) - { - /* compute the forces in the subspace of the flooding eigenvectors - * by the formula F_i= V_{fl}(c) * ( \frac {kT} {E_{fl}} \lambda_i c_i */ -- -+ - int i; - real energy=edi->flood.Vfl; - -@@ -785,31 +791,31 @@ static void flood_forces(t_edpar *edi) - static void flood_blowup(t_edpar *edi, rvec *forces_cart) - { - /* this function lifts the forces from the subspace to the cartesian space -- all the values not contained in the subspace are assumed to be zero and then -- a coordinate transformation from eigenvector to cartesian vectors is performed -- The nonexistent values don't have to be set to zero explicitly, they would occur -+ all the values not contained in the subspace are assumed to be zero and then -+ a coordinate transformation from eigenvector to cartesian vectors is performed -+ The nonexistent values don't have to be set to zero explicitly, they would occur - as zero valued summands, hence we just stop to compute this part of the sum. - - for every atom we add all the contributions to this atom from all the different eigenvectors. - -- NOTE: one could add directly to the forcefield forces, would mean we wouldn't have to clear the -- field forces_cart prior the computation, but momentarily we want to compute the forces separately -+ NOTE: one could add directly to the forcefield forces, would mean we wouldn't have to clear the -+ field forces_cart prior the computation, but we compute the forces separately - to have them accessible for diagnostics - */ - int j,eig; - rvec dum; - real *forces_sub; -- -- -+ -+ - forces_sub = edi->flood.vecs.fproj; -- -- -+ -+ - /* Calculate the cartesian forces for the local atoms */ -- -+ - /* Clear forces first */ -- for (j=0; jsav.nr_loc; j++) -+ for (j=0; jsav.nr_loc; j++) - clear_rvec(forces_cart[j]); -- -+ - /* Now compute atomwise */ - for (j=0; jsav.nr_loc; j++) - { -@@ -828,8 +834,8 @@ static void flood_blowup(t_edpar *edi, rvec *forces_cart) - /* Update the values of Efl, deltaF depending on tau and Vfl */ - static void update_adaption(t_edpar *edi) - { -- /* this function updates the parameter Efl and deltaF according to the rules given in -- * 'predicting unimolecular chemical reactions: chemical flooding' M Mueller et al, -+ /* this function updates the parameter Efl and deltaF according to the rules given in -+ * 'predicting unimolecular chemical reactions: chemical flooding' M Mueller et al, - * J. chem Phys. */ - - if ((edi->flood.tau < 0 ? -edi->flood.tau : edi->flood.tau ) > 0.00000001) -@@ -852,25 +858,25 @@ static void do_single_flood( - gmx_large_int_t step, - matrix box, - t_commrec *cr) --{ -+{ - int i; - matrix rotmat; /* rotation matrix */ - matrix tmat; /* inverse rotation */ - rvec transvec; /* translation vector */ - struct t_do_edsam *buf; - -- -+ - buf=edi->buf->do_edsam; -- -+ - /* Broadcast the positions of the AVERAGE structure such that they are known on - * every processor. Each node contributes its local positions x and stores them in -- * the collective ED array buf->xcoll */ -- communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, x, -- edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); -- -+ * the collective ED array buf->xcoll */ -+ communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, x, -+ edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); -+ - /* Only assembly REFERENCE positions if their indices differ from the average ones */ - if (!edi->bRefEqAv) -- communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, x, -+ communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, x, - edi->sref.nr, edi->sref.nr_loc, edi->sref.anrs_loc, edi->sref.c_ind, edi->sref.x_old, box); - - /* If bUpdateShifts was TRUE, the shifts have just been updated in get_positions. -@@ -879,26 +885,29 @@ static void do_single_flood( - - /* Now all nodes have all of the ED/flooding positions in edi->sav->xcoll, - * as well as the indices in edi->sav.anrs */ -- -+ - /* Fit the reference indices to the reference structure */ - if (edi->bRefEqAv) - fit_to_reference(buf->xcoll , transvec, rotmat, edi); - else - fit_to_reference(buf->xc_ref, transvec, rotmat, edi); -- -+ - /* Now apply the translation and rotation to the ED structure */ - translate_and_rotate(buf->xcoll, edi->sav.nr, transvec, rotmat); - - /* Project fitted structure onto supbspace -> store in edi->flood.vecs.xproj */ -- project_to_eigvectors(buf->xcoll,&edi->flood.vecs,edi); -- -- /* Compute Vfl(x) from flood.xproj */ -- edi->flood.Vfl = flood_energy(edi, step); -- -- update_adaption(edi); -+ project_to_eigvectors(buf->xcoll,&edi->flood.vecs,edi); -+ -+ if (FALSE == edi->flood.bConstForce) -+ { -+ /* Compute Vfl(x) from flood.xproj */ -+ edi->flood.Vfl = flood_energy(edi, step); - -- /* Compute the flooding forces */ -- flood_forces(edi); -+ update_adaption(edi); -+ -+ /* Compute the flooding forces */ -+ flood_forces(edi); -+ } - - /* Translate them into cartesian positions */ - flood_blowup(edi, edi->flood.forces_cartesian); -@@ -930,10 +939,10 @@ extern void do_flood( - { - t_edpar *edi; - -- -+ - if (ed->eEDtype != eEDflood) - return; -- -+ - edi = ed->edpar; - while (edi) - { -@@ -945,10 +954,13 @@ extern void do_flood( - } - - --/* Called by init_edi, configure some flooding related variables and structures, -+/* Called by init_edi, configure some flooding related variables and structures, - * print headers to output files */ - static void init_flood(t_edpar *edi, gmx_edsam_t ed, real dt, t_commrec *cr) - { -+ int i; -+ -+ - edi->flood.Efl = edi->flood.constEfl; - edi->flood.Vfl = 0; - edi->flood.dt = dt; -@@ -957,12 +969,25 @@ static void init_flood(t_edpar *edi, gmx_edsam_t ed, real dt, t_commrec *cr) - { - /* If in any of the datasets we find a flooding vector, flooding is turned on */ - ed->eEDtype = eEDflood; -- -+ -+ fprintf(stderr,"ED: Flooding of matrix %d is switched on.\n", edi->flood.flood_id); -+ -+ if (edi->flood.bConstForce) -+ { -+ /* We have used stpsz as a vehicle to carry the fproj values for constant -+ * force flooding. Now we copy that to flood.vecs.fproj. Note that -+ * in const force flooding, fproj is never changed. */ -+ for (i=0; iflood.vecs.neig; i++) -+ { -+ edi->flood.vecs.fproj[i] = edi->flood.vecs.stpsz[i]; -+ -+ fprintf(stderr, "ED: applying on eigenvector %d a constant force of %g\n", -+ edi->flood.vecs.ieig[i], edi->flood.vecs.fproj[i]); -+ } -+ } - fprintf(ed->edo,"FL_HEADER: Flooding of matrix %d is switched on! The flooding output will have the following format:\n", - edi->flood.flood_id); -- fprintf(stderr,"ED: Flooding of matrix %d is switched on.\n", edi->flood.flood_id); -- if (edi->flood.flood_id<1) -- fprintf(ed->edo,"FL_HEADER: Step Efl Vfl deltaF\n"); -+ fprintf(ed->edo,"FL_HEADER: Step Efl Vfl deltaF\n"); - } - } - -@@ -994,7 +1019,7 @@ static void get_flood_energies(t_edpar *edi, real Vfl[],int nnames) - t_edpar *actual; - int count; - -- -+ - actual=edi; - count = 1; - while (actual) -@@ -1003,7 +1028,7 @@ static void get_flood_energies(t_edpar *edi, real Vfl[],int nnames) - actual=actual->next_edi; - count++; - } -- if (nnames!=count-1) -+ if (nnames!=count-1) - gmx_fatal(FARGS,"Number of energies is not consistent with t_edi structure"); - } - /************* END of FLOODING IMPLEMENTATION ****************************/ -@@ -1011,22 +1036,22 @@ static void get_flood_energies(t_edpar *edi, real Vfl[],int nnames) - - - gmx_edsam_t ed_open(int nfile,const t_filenm fnm[],unsigned long Flags,t_commrec *cr) --{ -+{ - gmx_edsam_t ed; -- -- -+ -+ - /* Allocate space for the ED data structure */ - snew(ed, 1); -- -+ - /* We want to perform ED (this switch might later be upgraded to eEDflood) */ - ed->eEDtype = eEDedsam; - -- if (MASTER(cr)) -+ if (MASTER(cr)) - { - /* Open .edi input file: */ - ed->edinam=ftp2fn(efEDI,nfile,fnm); - /* The master opens the .edo output file */ -- fprintf(stderr,"ED sampling will be performed!\n"); -+ fprintf(stderr,"ED sampling will be performed!\n"); - ed->edonam = ftp2fn(efEDO,nfile,fnm); - ed->edo = gmx_fio_fopen(ed->edonam,(Flags & MD_APPENDFILES)? "a+" : "w+"); - ed->bStartFromCpt = Flags & MD_STARTFROMCPT; -@@ -1049,10 +1074,10 @@ static void bc_ed_positions(t_commrec *cr, struct gmx_edx *s, int stype) - { - /* We need these additional variables in the parallel case: */ - snew(s->c_ind , s->nr ); /* Collective indices */ -- /* Local atom indices get assigned in dd_make_local_group_indices. -+ /* Local atom indices get assigned in dd_make_local_group_indices. - * There, also memory is allocated */ - s->nalloc_loc = 0; /* allocation size of s->anrs_loc */ -- snew_bc(cr, s->x_old, s->nr); /* To be able to always make the ED molecule whole, ... */ -+ snew_bc(cr, s->x_old, s->nr); /* To be able to always make the ED molecule whole, ... */ - nblock_bc(cr, s->nr, s->x_old); /* ... keep track of shift changes with the help of old coords */ - } - -@@ -1115,16 +1140,16 @@ static void broadcast_ed_data(t_commrec *cr, gmx_edsam_t ed, int numedis) - { - int nr; - t_edpar *edi; -- -+ - - /* Master lets the other nodes know if its ED only or also flooding */ - gmx_bcast(sizeof(ed->eEDtype), &(ed->eEDtype), cr); -- -+ - snew_bc(cr, ed->edpar,1); - /* Now transfer the ED data set(s) */ - edi = ed->edpar; - for (nr=0; nrvecs.radcon, edi->sav.nr, FALSE); - /* Broadcast flooding eigenvectors and, if needed, values for the moving reference */ - bc_ed_vecs(cr, &edi->flood.vecs, edi->sav.nr, edi->flood.bHarmonic); -- -+ - /* Set the pointer to the next ED dataset */ - if (edi->next_edi) - { -@@ -1156,22 +1181,22 @@ static void broadcast_ed_data(t_commrec *cr, gmx_edsam_t ed, int numedis) - - /* init-routine called for every *.edi-cycle, initialises t_edpar structure */ - static void init_edi(gmx_mtop_t *mtop,t_inputrec *ir, -- t_commrec *cr,gmx_edsam_t ed,t_edpar *edi) -+ t_commrec *cr,gmx_edsam_t ed,t_edpar *edi) - { - int i; - real totalmass = 0.0; - rvec com; - t_atom *atom; - -- /* NOTE Init_edi is executed on the master process only -+ /* NOTE Init_edi is executed on the master process only - * The initialized data sets are then transmitted to the - * other nodes in broadcast_ed_data */ - -- edi->bNeedDoEdsam = edi->vecs.mon.neig -- || edi->vecs.linfix.neig -- || edi->vecs.linacc.neig -- || edi->vecs.radfix.neig -- || edi->vecs.radacc.neig -+ edi->bNeedDoEdsam = edi->vecs.mon.neig -+ || edi->vecs.linfix.neig -+ || edi->vecs.linacc.neig -+ || edi->vecs.radfix.neig -+ || edi->vecs.radacc.neig - || edi->vecs.radcon.neig; - - /* evaluate masses (reference structure) */ -@@ -1187,11 +1212,22 @@ static void init_edi(gmx_mtop_t *mtop,t_inputrec *ir, - { - edi->sref.m[i] = 1.0; - } -+ -+ /* Check that every m > 0. Bad things will happen otherwise. */ -+ if (edi->sref.m[i] <= 0.0) -+ { -+ gmx_fatal(FARGS, "Reference structure atom %d (sam.edi index %d) has a mass of %g.\n" -+ "For a mass-weighted fit, all reference structure atoms need to have a mass >0.\n" -+ "Either make the covariance analysis non-mass-weighted, or exclude massless\n" -+ "atoms from the reference structure by creating a proper index group.\n", -+ i, edi->sref.anrs[i]+1, edi->sref.m[i]); -+ } -+ - totalmass += edi->sref.m[i]; - } - edi->sref.mtot = totalmass; - -- /* Masses m and sqrt(m) for the average structure. Note that m -+ /* Masses m and sqrt(m) for the average structure. Note that m - * is needed if forces have to be evaluated in do_edsam */ - snew(edi->sav.sqrtm, edi->sav.nr ); - snew(edi->sav.m , edi->sav.nr ); -@@ -1207,6 +1243,16 @@ static void init_edi(gmx_mtop_t *mtop,t_inputrec *ir, - { - edi->sav.sqrtm[i] = 1.0; - } -+ -+ /* Check that every m > 0. Bad things will happen otherwise. */ -+ if (edi->sav.sqrtm[i] <= 0.0) -+ { -+ gmx_fatal(FARGS, "Average structure atom %d (sam.edi index %d) has a mass of %g.\n" -+ "For ED with mass-weighting, all average structure atoms need to have a mass >0.\n" -+ "Either make the covariance analysis non-mass-weighted, or exclude massless\n" -+ "atoms from the average structure by creating a proper index group.\n", -+ i, edi->sav.anrs[i]+1, atom->m); -+ } - } - - /* put reference structure in origin */ -@@ -1223,7 +1269,7 @@ static void init_edi(gmx_mtop_t *mtop,t_inputrec *ir, - - static void check(const char *line, const char *label) - { -- if (!strstr(line,label)) -+ if (!strstr(line,label)) - gmx_fatal(FARGS,"Could not find input parameter %s at expected position in edsam input-file (.edi)\nline read instead is %s",label,line); - } - -@@ -1233,13 +1279,13 @@ static int read_checked_edint(FILE *file,const char *label) - char line[STRLEN+1]; - int idum; - -- -+ - fgets2 (line,STRLEN,file); - check(line,label); - fgets2 (line,STRLEN,file); - sscanf (line,"%d",&idum); - return idum; --} -+} - - - static int read_edint(FILE *file,gmx_bool *bEOF) -@@ -1248,14 +1294,14 @@ static int read_edint(FILE *file,gmx_bool *bEOF) - int idum; - char *eof; - -- -+ - eof=fgets2 (line,STRLEN,file); - if (eof==NULL) - { - *bEOF = TRUE; - return -1; - } -- eof=fgets2 (line,STRLEN,file); -+ eof=fgets2 (line,STRLEN,file); - if (eof==NULL) - { - *bEOF = TRUE; -@@ -1272,7 +1318,7 @@ static real read_checked_edreal(FILE *file,const char *label) - char line[STRLEN+1]; - double rdum; - -- -+ - fgets2 (line,STRLEN,file); - check(line,label); - fgets2 (line,STRLEN,file); -@@ -1287,7 +1333,7 @@ static void read_edx(FILE *file,int number,int *anrs,rvec *x) - char line[STRLEN+1]; - double d[3]; - -- -+ - for(i=0; ineig=read_checked_edint(in,"NUMBER OF EIGENVECTORS"); - if (tvec->neig >0) - { -@@ -1404,7 +1450,7 @@ static gmx_bool check_if_same(struct gmx_edx sref, struct gmx_edx sav) - { - int i; - -- -+ - /* If the number of atoms differs between the two structures, - * they cannot be identical */ - if (sref.nr != sav.nr) -@@ -1426,10 +1472,10 @@ static gmx_bool check_if_same(struct gmx_edx sref, struct gmx_edx sav) - static int read_edi(FILE* in, gmx_edsam_t ed,t_edpar *edi,int nr_mdatoms, int edi_nr, t_commrec *cr) - { - int readmagic; -- const int magic=669; -+ const int magic=670; - gmx_bool bEOF; - -- -+ - /* the edi file is not free format, so expect problems if the input is corrupt. */ - - /* check the magic number */ -@@ -1442,6 +1488,8 @@ static int read_edi(FILE* in, gmx_edsam_t ed,t_edpar *edi,int nr_mdatoms, int ed - { - if (readmagic==666 || readmagic==667 || readmagic==668) - gmx_fatal(FARGS,"Wrong magic number: Use newest version of make_edi to produce edi file"); -+ else if (readmagic == 669) -+ ; - else - gmx_fatal(FARGS,"Wrong magic number %d in %s",readmagic,ed->edinam); - } -@@ -1450,7 +1498,7 @@ static int read_edi(FILE* in, gmx_edsam_t ed,t_edpar *edi,int nr_mdatoms, int ed - edi->nini=read_edint(in,&bEOF); - if (edi->nini != nr_mdatoms) - gmx_fatal(FARGS,"Nr of atoms in %s (%d) does not match nr of md atoms (%d)", -- ed->edinam,edi->nini,nr_mdatoms); -+ ed->edinam,edi->nini,nr_mdatoms); - - /* Done checking. For the rest we blindly trust the input */ - edi->fitmas = read_checked_edint(in,"FITMAS"); -@@ -1467,6 +1515,10 @@ static int read_edi(FILE* in, gmx_edsam_t ed,t_edpar *edi,int nr_mdatoms, int ed - edi->flood.alpha2 = read_checked_edreal(in,"ALPHA2"); - edi->flood.kT = read_checked_edreal(in,"KT"); - edi->flood.bHarmonic = read_checked_edint(in,"HARMONIC"); -+ if (readmagic > 669) -+ edi->flood.bConstForce = read_checked_edint(in,"CONST_FORCE_FLOODING"); -+ else -+ edi->flood.bConstForce = FALSE; - edi->flood.flood_id = edi_nr; - edi->sref.nr = read_checked_edint(in,"NREF"); - -@@ -1512,7 +1564,7 @@ static int read_edi(FILE* in, gmx_edsam_t ed,t_edpar *edi,int nr_mdatoms, int ed - edi->sori.sqrtm =NULL; - read_edx(in,edi->sori.nr,edi->sori.anrs,edi->sori.x); - } -- -+ - /* all done */ - return 1; - } -@@ -1522,18 +1574,18 @@ static int read_edi(FILE* in, gmx_edsam_t ed,t_edpar *edi,int nr_mdatoms, int ed - /* Read in the edi input file. Note that it may contain several ED data sets which were - * achieved by concatenating multiple edi files. The standard case would be a single ED - * data set, though. */ --static void read_edi_file(gmx_edsam_t ed, t_edpar *edi, int nr_mdatoms, t_commrec *cr) -+static void read_edi_file(gmx_edsam_t ed, t_edpar *edi, int nr_mdatoms, t_commrec *cr) - { - FILE *in; - t_edpar *curr_edi,*last_edi; - t_edpar *edi_read; - int edi_nr = 0; - -- -+ - /* This routine is executed on the master only */ - - /* Open the .edi parameter input file */ -- in = gmx_fio_fopen(ed->edinam,"r"); -+ in = gmx_fio_fopen(ed->edinam,"r"); - fprintf(stderr, "ED: Reading edi file %s\n", ed->edinam); - - /* Now read a sequence of ED input parameter sets from the edi file */ -@@ -1544,7 +1596,7 @@ static void read_edi_file(gmx_edsam_t ed, t_edpar *edi, int nr_mdatoms, t_commre - edi_nr++; - /* Make shure that the number of atoms in each dataset is the same as in the tpr file */ - if (edi->nini != nr_mdatoms) -- gmx_fatal(FARGS,"edi file %s (dataset #%d) was made for %d atoms, but the simulation contains %d atoms.", -+ gmx_fatal(FARGS,"edi file %s (dataset #%d) was made for %d atoms, but the simulation contains %d atoms.", - ed->edinam, edi_nr, edi->nini, nr_mdatoms); - /* Since we arrived within this while loop we know that there is still another data set to be read in */ - /* We need to allocate space for the data: */ -@@ -1555,15 +1607,15 @@ static void read_edi_file(gmx_edsam_t ed, t_edpar *edi, int nr_mdatoms, t_commre - last_edi = curr_edi; - /* Let's prepare to read in the next edi data set: */ - curr_edi = edi_read; -- } -- if (edi_nr == 0) -+ } -+ if (edi_nr == 0) - gmx_fatal(FARGS, "No complete ED data set found in edi file %s.", ed->edinam); - - /* Terminate the edi dataset list with a NULL pointer: */ - last_edi->next_edi = NULL; - - fprintf(stderr, "ED: Found %d ED dataset%s.\n", edi_nr, edi_nr>1? "s" : ""); -- -+ - /* Close the .edi file again */ - gmx_fio_fclose(in); - } -@@ -1573,19 +1625,19 @@ struct t_fit_to_ref { - rvec *xcopy; /* Working copy of the positions in fit_to_reference */ - }; - --/* Fit the current positions to the reference positions -+/* Fit the current positions to the reference positions - * Do not actually do the fit, just return rotation and translation. -- * Note that the COM of the reference structure was already put into -+ * Note that the COM of the reference structure was already put into - * the origin by init_edi. */ - static void fit_to_reference(rvec *xcoll, /* The positions to be fitted */ -- rvec transvec, /* The translation vector */ -+ rvec transvec, /* The translation vector */ - matrix rotmat, /* The rotation matrix */ - t_edpar *edi) /* Just needed for do_edfit */ - { - rvec com; /* center of mass */ - int i; - struct t_fit_to_ref *loc; -- -+ - - GMX_MPE_LOG(ev_fit_to_reference_start); - -@@ -1596,7 +1648,7 @@ static void fit_to_reference(rvec *xcoll, /* The positions to be fitted - snew(edi->buf->fit_to_ref->xcopy, edi->sref.nr); - } - loc = edi->buf->fit_to_ref; -- -+ - /* We do not touch the original positions but work on a copy. */ - for (i=0; isref.nr; i++) - copy_rvec(xcoll[i], loc->xcopy[i]); -@@ -1620,7 +1672,7 @@ static void fit_to_reference(rvec *xcoll, /* The positions to be fitted - - static void translate_and_rotate(rvec *x, /* The positions to be translated and rotated */ - int nat, /* How many positions are there? */ -- rvec transvec, /* The translation vector */ -+ rvec transvec, /* The translation vector */ - matrix rotmat) /* The rotation matrix */ - { - /* Translation */ -@@ -1633,7 +1685,7 @@ static void translate_and_rotate(rvec *x, /* The positions to be transla - - /* Gets the rms deviation of the positions to the structure s */ - /* fit_to_structure has to be called before calling this routine! */ --static real rmsd_from_structure(rvec *x, /* The positions under consideration */ -+static real rmsd_from_structure(rvec *x, /* The positions under consideration */ - struct gmx_edx *s) /* The structure from which the rmsd shall be computed */ - { - real rmsd=0.0; -@@ -1654,7 +1706,7 @@ void dd_make_local_ed_indices(gmx_domdec_t *dd, struct gmx_edsam *ed) - { - t_edpar *edi; - -- -+ - if (ed->eEDtype != eEDnone) - { - /* Loop over ED datasets (usually there is just one dataset, though) */ -@@ -1666,15 +1718,15 @@ void dd_make_local_ed_indices(gmx_domdec_t *dd, struct gmx_edsam *ed) - if (!edi->bRefEqAv) - dd_make_local_group_indices(dd->ga2la, edi->sref.nr, edi->sref.anrs, - &edi->sref.nr_loc, &edi->sref.anrs_loc, &edi->sref.nalloc_loc, edi->sref.c_ind); -- -+ - /* Local atoms of the average structure (on these ED will be performed) */ - dd_make_local_group_indices(dd->ga2la, edi->sav.nr, edi->sav.anrs, - &edi->sav.nr_loc, &edi->sav.anrs_loc, &edi->sav.nalloc_loc, edi->sav.c_ind); - -- /* Indicate that the ED shift vectors for this structure need to be updated -+ /* Indicate that the ED shift vectors for this structure need to be updated - * at the next call to communicate_group_positions, since obviously we are in a NS step */ - edi->buf->do_edsam->bUpdateShifts = TRUE; -- -+ - /* Set the pointer to the next ED dataset (if any) */ - edi=edi->next_edi; - } -@@ -1694,7 +1746,7 @@ static inline void ed_unshift_single_coord(matrix box, const rvec x, const ivec - tz=is[ZZ]; - - if(TRICLINIC(box)) -- { -+ { - xu[XX] = x[XX]-tx*box[XX][XX]-ty*box[YY][XX]-tz*box[ZZ][XX]; - xu[YY] = x[YY]-ty*box[YY][YY]-tz*box[ZZ][YY]; - xu[ZZ] = x[ZZ]-tz*box[ZZ][ZZ]; -@@ -1783,7 +1835,7 @@ static void do_radfix(rvec *xcoll, t_edpar *edi, int step, t_commrec *cr) - rvec vec_dum; - - -- if (edi->vecs.radfix.neig == 0) -+ if (edi->vecs.radfix.neig == 0) - return; - - snew(proj, edi->vecs.radfix.neig); -@@ -1825,7 +1877,7 @@ static void do_radacc(rvec *xcoll, t_edpar *edi, t_commrec *cr) - rvec vec_dum; - - -- if (edi->vecs.radacc.neig == 0) -+ if (edi->vecs.radacc.neig == 0) - return; - - snew(proj,edi->vecs.radacc.neig); -@@ -1845,7 +1897,7 @@ static void do_radacc(rvec *xcoll, t_edpar *edi, t_commrec *cr) - ratio = edi->vecs.radacc.radius/rad - 1.0; - rad = edi->vecs.radacc.radius; - } -- else -+ else - edi->vecs.radacc.radius = rad; - - /* loop over radacc vectors */ -@@ -1861,7 +1913,7 @@ static void do_radacc(rvec *xcoll, t_edpar *edi, t_commrec *cr) - svmul(proj[i], edi->vecs.radacc.vec[i][j], vec_dum); - rvec_inc(xcoll[j], vec_dum); - } -- } -+ } - sfree(proj); - } - -@@ -1883,7 +1935,7 @@ static void do_radcon(rvec *xcoll, t_edpar *edi, t_commrec *cr) - { - bFirst = FALSE; - loc = edi->buf->do_radcon; -- } -+ } - else - { - bFirst = TRUE; -@@ -1891,7 +1943,7 @@ static void do_radcon(rvec *xcoll, t_edpar *edi, t_commrec *cr) - } - loc = edi->buf->do_radcon; - -- if (edi->vecs.radcon.neig == 0) -+ if (edi->vecs.radcon.neig == 0) - return; - - if (bFirst) -@@ -1917,7 +1969,7 @@ static void do_radcon(rvec *xcoll, t_edpar *edi, t_commrec *cr) - loc->proj[i] -= edi->vecs.radcon.refproj[i]; - loc->proj[i] /= edi->sav.sqrtm[i]; - loc->proj[i] *= ratio; -- -+ - for (j=0; jsav.nr; j++) - { - svmul(loc->proj[i], edi->vecs.radcon.vec[i][j], vec_dum); -@@ -1954,16 +2006,16 @@ static void ed_apply_constraints(rvec *xcoll, t_edpar *edi, gmx_large_int_t step - rvec_dec(xcoll[i], edi->sav.x[i]); - - /* apply the constraints */ -- if (step >= 0) -+ if (step >= 0) - do_linfix(xcoll, edi, step, cr); - do_linacc(xcoll, edi, cr); -- if (step >= 0) -+ if (step >= 0) - do_radfix(xcoll, edi, step, cr); - do_radacc(xcoll, edi, cr); - do_radcon(xcoll, edi, cr); - - /* add back the average positions */ -- for (i=0; isav.nr; i++) -+ for (i=0; isav.nr; i++) - rvec_inc(xcoll[i], edi->sav.x[i]); - - GMX_MPE_LOG(ev_ed_apply_cons_finish); -@@ -1972,11 +2024,11 @@ static void ed_apply_constraints(rvec *xcoll, t_edpar *edi, gmx_large_int_t step - - /* Write out the projections onto the eigenvectors */ - static void write_edo(int nr_edi, t_edpar *edi, gmx_edsam_t ed, gmx_large_int_t step,real rmsd) --{ -+{ - int i; - char buf[22]; - -- -+ - if (edi->bNeedDoEdsam) - { - if (step == -1) -@@ -1985,8 +2037,6 @@ static void write_edo(int nr_edi, t_edpar *edi, gmx_edsam_t ed, gmx_large_int_t - { - fprintf(ed->edo,"Step %s, ED #%d ", gmx_step_str(step, buf), nr_edi); - fprintf(ed->edo," RMSD %f nm\n",rmsd); -- if (ed->eEDtype == eEDflood) -- fprintf(ed->edo, " Efl=%f deltaF=%f Vfl=%f\n",edi->flood.Efl,edi->flood.deltaF,edi->flood.Vfl); - } - - if (edi->vecs.mon.neig) -@@ -2039,13 +2089,13 @@ static void write_edo(int nr_edi, t_edpar *edi, gmx_edsam_t ed, gmx_large_int_t - - /* Returns if any constraints are switched on */ - static int ed_constraints(gmx_bool edtype, t_edpar *edi) --{ -- if (edtype == eEDedsam || edtype == eEDflood) -+{ -+ if (edtype == eEDedsam || edtype == eEDflood) - { -- return (edi->vecs.linfix.neig || edi->vecs.linacc.neig || -- edi->vecs.radfix.neig || edi->vecs.radacc.neig || -+ return (edi->vecs.linfix.neig || edi->vecs.linacc.neig || -+ edi->vecs.radfix.neig || edi->vecs.radacc.neig || - edi->vecs.radcon.neig); -- } -+ } - return 0; - } - -@@ -2065,7 +2115,7 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - rvec *xstart = NULL; /* the positions which are subject to ED sampling */ - rvec fit_transvec; /* translation ... */ - matrix fit_rotmat; /* ... and rotation from fit to reference structure */ -- -+ - - if (!DOMAINDECOMP(cr) && PAR(cr) && MASTER(cr)) - gmx_fatal(FARGS, "Please switch on domain decomposition to use essential dynamics in parallel."); -@@ -2074,7 +2124,7 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - - if (MASTER(cr)) - fprintf(stderr, "ED: Initializing essential dynamics constraints.\n"); -- -+ - /* Needed for initializing radacc radius in do_edsam */ - ed->bFirst = 1; - -@@ -2087,15 +2137,15 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - /* Read the whole edi file at once: */ - read_edi_file(ed,ed->edpar,mtop->natoms,cr); - -- /* Initialization for every ED/flooding dataset. Flooding uses one edi dataset per -+ /* Initialization for every ED/flooding dataset. Flooding uses one edi dataset per - * flooding vector, Essential dynamics can be applied to more than one structure -- * as well, but will be done in the order given in the edi file, so -+ * as well, but will be done in the order given in the edi file, so - * expect different results for different order of edi file concatenation! */ - edi=ed->edpar; - while(edi != NULL) - { - init_edi(mtop,ir,cr,ed,edi); -- -+ - /* Init flooding parameters if needed */ - init_flood(edi,ed,ir->delta_t,cr); - -@@ -2104,7 +2154,7 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - } - } - -- /* The master does the work here. The other nodes get the positions -+ /* The master does the work here. The other nodes get the positions - * not before dd_partition_system which is called after init_edsam */ - if (MASTER(cr)) - { -@@ -2117,11 +2167,11 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - - /* Reset pointer to first ED data set which contains the actual ED data */ - edi=ed->edpar; -- -+ - /* Loop over all ED/flooding data sets (usually only one, though) */ - for (nr_edi = 1; nr_edi <= numedis; nr_edi++) - { -- /* We use srenew to allocate memory since the size of the buffers -+ /* We use srenew to allocate memory since the size of the buffers - * is likely to change with every ED dataset */ - srenew(xfit , edi->sref.nr ); - srenew(xstart, edi->sav.nr ); -@@ -2130,29 +2180,29 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - for (i=0; i < edi->sref.nr; i++) - { - copy_rvec(x_pbc[edi->sref.anrs[i]], xfit[i]); -- -- /* Save the sref positions such that in the next time step the molecule can -+ -+ /* Save the sref positions such that in the next time step the molecule can - * be made whole again (in the parallel case) */ - if (PAR(cr)) - copy_rvec(xfit[i], edi->sref.x_old[i]); - } -- -+ - /* Extract the positions of the atoms subject to ED sampling */ - for (i=0; i < edi->sav.nr; i++) - { - copy_rvec(x_pbc[edi->sav.anrs[i]], xstart[i]); - -- /* Save the sav positions such that in the next time step the molecule can -+ /* Save the sav positions such that in the next time step the molecule can - * be made whole again (in the parallel case) */ - if (PAR(cr)) - copy_rvec(xstart[i], edi->sav.x_old[i]); - } -- -+ - /* Make the fit to the REFERENCE structure, get translation and rotation */ - fit_to_reference(xfit, fit_transvec, fit_rotmat, edi); - - /* Output how well we fit to the reference at the start */ -- translate_and_rotate(xfit, edi->sref.nr, fit_transvec, fit_rotmat); -+ translate_and_rotate(xfit, edi->sref.nr, fit_transvec, fit_rotmat); - fprintf(stderr, "ED: Initial RMSD from reference after fit = %f nm (dataset #%d)\n", - rmsd_from_structure(xfit, &edi->sref), nr_edi); - -@@ -2175,7 +2225,7 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - rad_project(edi, xstart, &edi->vecs.radcon, cr); - - /* process structure that will serve as origin of expansion circle */ -- if (eEDflood == ed->eEDtype) -+ if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) - fprintf(stderr, "ED: Setting center of flooding potential (0 = average structure)\n"); - if (edi->sori.nr > 0) - { -@@ -2186,7 +2236,7 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - translate_and_rotate(edi->sori.x, edi->sav.nr, fit_transvec, fit_rotmat); - rad_project(edi, edi->sori.x, &edi->vecs.radacc, cr); - rad_project(edi, edi->sori.x, &edi->vecs.radfix, cr); -- if (ed->eEDtype == eEDflood) -+ if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) - { - fprintf(stderr, "ED: The ORIGIN structure will define the flooding potential center.\n"); - /* Set center of flooding potential to the ORIGIN structure */ -@@ -2197,7 +2247,7 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - { - rad_project(edi, xstart, &edi->vecs.radacc, cr); - rad_project(edi, xstart, &edi->vecs.radfix, cr); -- if (ed->eEDtype == eEDflood) -+ if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) - { - if (edi->flood.bHarmonic) - { -@@ -2216,12 +2266,14 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - } - } - /* For convenience, output the center of the flooding potential for the eigenvectors */ -- if (eEDflood == ed->eEDtype) -+ if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) - { - for (i=0; iflood.vecs.neig; i++) - { -- fprintf(stdout, "ED: EV %d flooding potential center: %11.4e (adding %11.4e/timestep)\n", -- i, edi->flood.vecs.refproj[i], edi->flood.vecs.refprojslope[i]); -+ fprintf(stdout, "ED: EV %d flooding potential center: %11.4e", i, edi->flood.vecs.refproj[i]); -+ if (edi->flood.bHarmonic) -+ fprintf(stdout, " (adding %11.4e/timestep)", edi->flood.vecs.refprojslope[i]); -+ fprintf(stdout, "\n"); - } - } - -@@ -2234,15 +2286,15 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - write_edo(nr_edi, edi, ed, -1, 0); - - /* Prepare for the next edi data set: */ -- edi=edi->next_edi; -+ edi=edi->next_edi; - } - /* Cleaning up on the master node: */ - sfree(x_pbc); - sfree(xfit); - sfree(xstart); -- -+ - } /* end of MASTER only section */ -- -+ - if (PAR(cr)) - { - /* First let everybody know how many ED data sets to expect */ -@@ -2252,9 +2304,9 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - } - else - { -- /* In the single-CPU case, point the local atom numbers pointers to the global -+ /* In the single-CPU case, point the local atom numbers pointers to the global - * one, so that we can use the same notation in serial and parallel case: */ -- -+ - /* Loop over all ED data sets (usually only one, though) */ - edi=ed->edpar; - for (nr_edi = 1; nr_edi <= numedis; nr_edi++) -@@ -2302,8 +2354,8 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - - /* Collective positions of atoms with the average indices */ - snew(edi->buf->do_edsam->xcoll , edi->sav.nr); -- snew(edi->buf->do_edsam->shifts_xcoll , edi->sav.nr); /* buffer for xcoll shifts */ -- snew(edi->buf->do_edsam->extra_shifts_xcoll , edi->sav.nr); -+ snew(edi->buf->do_edsam->shifts_xcoll , edi->sav.nr); /* buffer for xcoll shifts */ -+ snew(edi->buf->do_edsam->extra_shifts_xcoll , edi->sav.nr); - /* Collective positions of atoms with the reference indices */ - if (!edi->bRefEqAv) - { -@@ -2311,7 +2363,7 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - snew(edi->buf->do_edsam->shifts_xc_ref , edi->sref.nr); /* To store the shifts in */ - snew(edi->buf->do_edsam->extra_shifts_xc_ref, edi->sref.nr); - } -- -+ - /* Get memory for flooding forces */ - snew(edi->flood.forces_cartesian , edi->sav.nr); - -@@ -2323,8 +2375,8 @@ void init_edsam(gmx_mtop_t *mtop, /* global topology */ - /* An on we go to the next edi dataset */ - edi=edi->next_edi; - } -- -- /* Flush the edo file so that the user can check some things -+ -+ /* Flush the edo file so that the user can check some things - * when the simulation has started */ - if (ed->edo) - fflush(ed->edo); -@@ -2361,11 +2413,11 @@ void do_edsam(t_inputrec *ir, - * two-step sd2 integrator is used */ - if ( (ir->eI==eiSD2) && (v != NULL) ) - bSuppress = TRUE; -- -+ - dt_1 = 1.0/ir->delta_t; -- -+ - /* Loop over all ED datasets (usually one) */ -- edi = ed->edpar; -+ edi = ed->edpar; - edinr = 0; - while (edi != NULL) - { -@@ -2379,29 +2431,29 @@ void do_edsam(t_inputrec *ir, - /* initialise radacc radius for slope criterion */ - buf->oldrad=calc_radius(&edi->vecs.radacc); - -- /* Copy the positions into buf->xc* arrays and after ED -+ /* Copy the positions into buf->xc* arrays and after ED - * feed back corrections to the official positions */ - - /* Broadcast the ED positions such that every node has all of them - * Every node contributes its local positions xs and stores it in - * the collective buf->xcoll array. Note that for edinr > 1 - * xs could already have been modified by an earlier ED */ -- -- communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, xs, -- edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); -+ -+ communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, xs, -+ edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); - - #ifdef DEBUG_ED - dump_xcoll(edi, buf, cr, step); - #endif - /* Only assembly reference positions if their indices differ from the average ones */ - if (!edi->bRefEqAv) -- communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, xs, -+ communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, xs, - edi->sref.nr, edi->sref.nr_loc, edi->sref.anrs_loc, edi->sref.c_ind, edi->sref.x_old, box); -- -+ - /* If bUpdateShifts was TRUE then the shifts have just been updated in get_positions. - * We do not need to uptdate the shifts until the next NS step */ - buf->bUpdateShifts = FALSE; -- -+ - /* Now all nodes have all of the ED positions in edi->sav->xcoll, - * as well as the indices in edi->sav.anrs */ - -@@ -2410,7 +2462,7 @@ void do_edsam(t_inputrec *ir, - fit_to_reference(buf->xcoll , transvec, rotmat, edi); - else - fit_to_reference(buf->xc_ref, transvec, rotmat, edi); -- -+ - /* Now apply the translation and rotation to the ED structure */ - translate_and_rotate(buf->xcoll, edi->sav.nr, transvec, rotmat); - -@@ -2419,7 +2471,7 @@ void do_edsam(t_inputrec *ir, - { - if (edi->bRefEqAv) - { -- /* Indices of reference and average structures are identical, -+ /* Indices of reference and average structures are identical, - * thus we can calculate the rmsd to SREF using xcoll */ - rmsdev = rmsd_from_structure(buf->xcoll,&edi->sref); - } -@@ -2468,7 +2520,7 @@ void do_edsam(t_inputrec *ir, - if (MASTER(cr) && !bSuppress) - write_edo(edinr, edi, ed, step, rmsdev); - } -- -+ - /* Copy back the positions unless monitoring only */ - if (ed_constraints(ed->eEDtype, edi)) - { -@@ -2476,17 +2528,17 @@ void do_edsam(t_inputrec *ir, - rmfit(edi->sav.nr, buf->xcoll, transvec, rotmat); - - /* Copy the ED corrected positions into the coordinate array */ -- /* Each node copies its local part. In the serial case, nat_loc is the -+ /* Each node copies its local part. In the serial case, nat_loc is the - * total number of ED atoms */ - for (i=0; isav.nr_loc; i++) - { - /* Unshift local ED coordinate and store in x_unsh */ -- ed_unshift_single_coord(box, buf->xcoll[edi->sav.c_ind[i]], -+ ed_unshift_single_coord(box, buf->xcoll[edi->sav.c_ind[i]], - buf->shifts_xcoll[edi->sav.c_ind[i]], x_unsh); -- -+ - /* dx is the ED correction to the positions: */ - rvec_sub(x_unsh, xs[edi->sav.anrs_loc[i]], dx); -- -+ - if (v != NULL) - { - /* dv is the ED correction to the velocity: */ -@@ -2499,10 +2551,10 @@ void do_edsam(t_inputrec *ir, - } - } - } /* END of if (edi->bNeedDoEdsam) */ -- -+ - /* Prepare for the next ED dataset */ - edi = edi->next_edi; -- -+ - } /* END of loop over ED datasets */ - - ed->bFirst = FALSE; -diff --git a/src/mdlib/iteratedconstraints.c b/src/mdlib/iteratedconstraints.c -new file mode 100644 -index 0000000..d0cd8b4 ---- /dev/null -+++ b/src/mdlib/iteratedconstraints.c -@@ -0,0 +1,232 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * Gallium Rubidium Oxygen Manganese Argon Carbon Silicon -+ */ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) -+/* _isnan() */ -+#include -+#endif -+ -+#include "typedefs.h" -+#include "gmx_fatal.h" -+#include "mdrun.h" -+ -+#ifdef GMX_DOUBLE -+#define CONVERGEITER 0.000000001 -+#define CLOSE_ENOUGH 0.000001000 -+#else -+#define CONVERGEITER 0.0001 -+#define CLOSE_ENOUGH 0.0050 -+#endif -+ -+/* we want to keep track of the close calls. If there are too many, there might be some other issues. -+ so we make sure that it's either less than some predetermined number, or if more than that number, -+ only some small fraction of the total. */ -+#define MAX_NUMBER_CLOSE 50 -+#define FRACTION_CLOSE 0.001 -+ -+/* maximum length of cyclic traps to check, emerging from limited numerical precision */ -+#define CYCLEMAX 20 -+ -+void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate) -+{ -+ int i; -+ -+ iterate->iter_i = 0; -+ iterate->bIterate = bIterate; -+ iterate->num_close = 0; -+ for (i=0;iallrelerr[i] = 0; -+ } -+} -+ -+gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf) -+{ -+ /* monitor convergence, and use a secant search to propose new -+ values. -+ x_{i} - x_{i-1} -+ The secant method computes x_{i+1} = x_{i} - f(x_{i}) * --------------------- -+ f(x_{i}) - f(x_{i-1}) -+ -+ The function we are trying to zero is fom-x, where fom is the -+ "figure of merit" which is the pressure (or the veta value) we -+ would get by putting in an old value of the pressure or veta into -+ the incrementor function for the step or half step. I have -+ verified that this gives the same answer as self consistent -+ iteration, usually in many fewer steps, especially for small tau_p. -+ -+ We could possibly eliminate an iteration with proper use -+ of the value from the previous step, but that would take a bit -+ more bookkeeping, especially for veta, since tests indicate the -+ function of veta on the last step is not sufficiently close to -+ guarantee convergence this step. This is -+ good enough for now. On my tests, I could use tau_p down to -+ 0.02, which is smaller that would ever be necessary in -+ practice. Generally, 3-5 iterations will be sufficient */ -+ -+ real relerr,err,xmin; -+ char buf[256]; -+ int i; -+ gmx_bool incycle; -+ -+ if (bFirstIterate) -+ { -+ iterate->x = fom; -+ iterate->f = fom-iterate->x; -+ iterate->xprev = 0; -+ iterate->fprev = 0; -+ *newf = fom; -+ } -+ else -+ { -+ iterate->f = fom-iterate->x; /* we want to zero this difference */ -+ if ((iterate->iter_i > 1) && (iterate->iter_i < MAXITERCONST)) -+ { -+ if (iterate->f==iterate->fprev) -+ { -+ *newf = iterate->f; -+ } -+ else -+ { -+ *newf = iterate->x - (iterate->x-iterate->xprev)*(iterate->f)/(iterate->f-iterate->fprev); -+ } -+ } -+ else -+ { -+ /* just use self-consistent iteration the first step to initialize, or -+ if it's not converging (which happens occasionally -- need to investigate why) */ -+ *newf = fom; -+ } -+ } -+ /* Consider a slight shortcut allowing us to exit one sooner -- we check the -+ difference between the closest of x and xprev to the new -+ value. To be 100% certain, we should check the difference between -+ the last result, and the previous result, or -+ -+ relerr = (fabs((x-xprev)/fom)); -+ -+ but this is pretty much never necessary under typical conditions. -+ Checking numerically, it seems to lead to almost exactly the same -+ trajectories, but there are small differences out a few decimal -+ places in the pressure, and eventually in the v_eta, but it could -+ save an interation. -+ -+ if (fabs(*newf-x) < fabs(*newf - xprev)) { xmin = x;} else { xmin = xprev;} -+ relerr = (fabs((*newf-xmin) / *newf)); -+ */ -+ -+ err = fabs((iterate->f-iterate->fprev)); -+ relerr = fabs(err/fom); -+ -+ iterate->allrelerr[iterate->iter_i] = relerr; -+ -+ if (iterate->iter_i > 0) -+ { -+ if (debug) -+ { -+ fprintf(debug,"Iterating NPT constraints: %6i %20.12f%14.6g%20.12f\n", -+ iterate->iter_i,fom,relerr,*newf); -+ } -+ -+ if ((relerr < CONVERGEITER) || (err < CONVERGEITER) || (fom==0) || ((iterate->x == iterate->xprev) && iterate->iter_i > 1)) -+ { -+ iterate->bIterate = FALSE; -+ if (debug) -+ { -+ fprintf(debug,"Iterating NPT constraints: CONVERGED\n"); -+ } -+ return TRUE; -+ } -+ if (iterate->iter_i > MAXITERCONST) -+ { -+ if (relerr < CLOSE_ENOUGH) -+ { -+ incycle = FALSE; -+ for (i=1;iallrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-1]) && -+ (iterate->allrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-(1+2*i)])) { -+ incycle = TRUE; -+ if (debug) -+ { -+ fprintf(debug,"Exiting from an NPT iterating cycle of length %d\n",i); -+ } -+ break; -+ } -+ } -+ -+ if (incycle) { -+ /* step 1: trapped in a numerical attractor */ -+ /* we are trapped in a numerical attractor, and can't converge any more, and are close to the final result. -+ Better to give up convergence here than have the simulation die. -+ */ -+ iterate->num_close++; -+ return TRUE; -+ } -+ else -+ { -+ /* Step #2: test if we are reasonably close for other reasons, then monitor the number. If not, die */ -+ -+ /* how many close calls have we had? If less than a few, we're OK */ -+ if (iterate->num_close < MAX_NUMBER_CLOSE) -+ { -+ sprintf(buf,"Slight numerical convergence deviation with NPT at step %d, relative error only %10.5g, likely not a problem, continuing\n",nsteps,relerr); -+ md_print_warning(cr,fplog,buf); -+ iterate->num_close++; -+ return TRUE; -+ /* if more than a few, check the total fraction. If too high, die. */ -+ } else if (iterate->num_close/(double)nsteps > FRACTION_CLOSE) { -+ gmx_fatal(FARGS,"Could not converge NPT constraints, too many exceptions (%d%%\n",iterate->num_close/(double)nsteps); -+ } -+ } -+ } -+ else -+ { -+ gmx_fatal(FARGS,"Could not converge NPT constraints\n"); -+ } -+ } -+ } -+ -+ iterate->xprev = iterate->x; -+ iterate->x = *newf; -+ iterate->fprev = iterate->f; -+ iterate->iter_i++; -+ -+ return FALSE; -+} -+ -diff --git a/src/mdlib/md_support.c b/src/mdlib/md_support.c -new file mode 100644 -index 0000000..7551a76 ---- /dev/null -+++ b/src/mdlib/md_support.c -@@ -0,0 +1,748 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * Gallium Rubidium Oxygen Manganese Argon Carbon Silicon -+ */ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) -+/* _isnan() */ -+#include -+#endif -+ -+#include "typedefs.h" -+#include "string2.h" -+#include "smalloc.h" -+#include "mdrun.h" -+#include "domdec.h" -+#include "mtop_util.h" -+#include "gmx_wallcycle.h" -+#include "vcm.h" -+#include "nrnb.h" -+ -+/* Is the signal in one simulation independent of other simulations? */ -+gmx_bool gs_simlocal[eglsNR] = { TRUE, FALSE, FALSE, TRUE }; -+ -+/* check which of the multisim simulations has the shortest number of -+ steps and return that number of nsteps */ -+gmx_large_int_t get_multisim_nsteps(const t_commrec *cr, -+ gmx_large_int_t nsteps) -+{ -+ gmx_large_int_t steps_out; -+ -+ if MASTER(cr) -+ { -+ gmx_large_int_t *buf; -+ int s; -+ -+ snew(buf,cr->ms->nsim); -+ -+ buf[cr->ms->sim] = nsteps; -+ gmx_sumli_sim(cr->ms->nsim, buf, cr->ms); -+ -+ steps_out=-1; -+ for(s=0; sms->nsim; s++) -+ { -+ /* find the smallest positive number */ -+ if (buf[s]>= 0 && ((steps_out < 0) || (buf[s]=0 && steps_outms->sim, steps_out); -+ } -+ } -+ /* broadcast to non-masters */ -+ gmx_bcast(sizeof(gmx_large_int_t), &steps_out, cr); -+ return steps_out; -+} -+ -+int multisim_min(const gmx_multisim_t *ms,int nmin,int n) -+{ -+ int *buf; -+ gmx_bool bPos,bEqual; -+ int s,d; -+ -+ snew(buf,ms->nsim); -+ buf[ms->sim] = n; -+ gmx_sumi_sim(ms->nsim,buf,ms); -+ bPos = TRUE; -+ bEqual = TRUE; -+ for(s=0; snsim; s++) -+ { -+ bPos = bPos && (buf[s] > 0); -+ bEqual = bEqual && (buf[s] == buf[0]); -+ } -+ if (bPos) -+ { -+ if (bEqual) -+ { -+ nmin = min(nmin,buf[0]); -+ } -+ else -+ { -+ /* Find the least common multiple */ -+ for(d=2; dnsim && d % buf[s] == 0) -+ { -+ s++; -+ } -+ if (s == ms->nsim) -+ { -+ /* We found the LCM and it is less than nmin */ -+ nmin = d; -+ break; -+ } -+ } -+ } -+ } -+ sfree(buf); -+ -+ return nmin; -+} -+ -+int multisim_nstsimsync(const t_commrec *cr, -+ const t_inputrec *ir,int repl_ex_nst) -+{ -+ int nmin; -+ -+ if (MASTER(cr)) -+ { -+ nmin = INT_MAX; -+ nmin = multisim_min(cr->ms,nmin,ir->nstlist); -+ nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); -+ nmin = multisim_min(cr->ms,nmin,repl_ex_nst); -+ if (nmin == INT_MAX) -+ { -+ gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); -+ } -+ /* Avoid inter-simulation communication at every (second) step */ -+ if (nmin <= 2) -+ { -+ nmin = 10; -+ } -+ } -+ -+ gmx_bcast(sizeof(int),&nmin,cr); -+ -+ return nmin; -+} -+ -+void init_global_signals(globsig_t *gs,const t_commrec *cr, -+ const t_inputrec *ir,int repl_ex_nst) -+{ -+ int i; -+ -+ if (MULTISIM(cr)) -+ { -+ gs->nstms = multisim_nstsimsync(cr,ir,repl_ex_nst); -+ if (debug) -+ { -+ fprintf(debug,"Syncing simulations for checkpointing and termination every %d steps\n",gs->nstms); -+ } -+ } -+ else -+ { -+ gs->nstms = 1; -+ } -+ -+ for(i=0; isig[i] = 0; -+ gs->set[i] = 0; -+ } -+} -+ -+void copy_coupling_state(t_state *statea,t_state *stateb, -+ gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts) -+{ -+ -+ /* MRS note -- might be able to get rid of some of the arguments. Look over it when it's all debugged */ -+ -+ int i,j,nc; -+ -+ /* Make sure we have enough space for x and v */ -+ if (statea->nalloc > stateb->nalloc) -+ { -+ stateb->nalloc = statea->nalloc; -+ srenew(stateb->x,stateb->nalloc); -+ srenew(stateb->v,stateb->nalloc); -+ } -+ -+ stateb->natoms = statea->natoms; -+ stateb->ngtc = statea->ngtc; -+ stateb->nnhpres = statea->nnhpres; -+ stateb->veta = statea->veta; -+ if (ekinda) -+ { -+ copy_mat(ekinda->ekin,ekindb->ekin); -+ for (i=0; ingtc; i++) -+ { -+ ekindb->tcstat[i].T = ekinda->tcstat[i].T; -+ ekindb->tcstat[i].Th = ekinda->tcstat[i].Th; -+ copy_mat(ekinda->tcstat[i].ekinh,ekindb->tcstat[i].ekinh); -+ copy_mat(ekinda->tcstat[i].ekinf,ekindb->tcstat[i].ekinf); -+ ekindb->tcstat[i].ekinscalef_nhc = ekinda->tcstat[i].ekinscalef_nhc; -+ ekindb->tcstat[i].ekinscaleh_nhc = ekinda->tcstat[i].ekinscaleh_nhc; -+ ekindb->tcstat[i].vscale_nhc = ekinda->tcstat[i].vscale_nhc; -+ } -+ } -+ copy_rvecn(statea->x,stateb->x,0,stateb->natoms); -+ copy_rvecn(statea->v,stateb->v,0,stateb->natoms); -+ copy_mat(statea->box,stateb->box); -+ copy_mat(statea->box_rel,stateb->box_rel); -+ copy_mat(statea->boxv,stateb->boxv); -+ -+ for (i = 0; ingtc; i++) -+ { -+ nc = i*opts->nhchainlength; -+ for (j=0; jnhchainlength; j++) -+ { -+ stateb->nosehoover_xi[nc+j] = statea->nosehoover_xi[nc+j]; -+ stateb->nosehoover_vxi[nc+j] = statea->nosehoover_vxi[nc+j]; -+ } -+ } -+ if (stateb->nhpres_xi != NULL) -+ { -+ for (i = 0; innhpres; i++) -+ { -+ nc = i*opts->nhchainlength; -+ for (j=0; jnhchainlength; j++) -+ { -+ stateb->nhpres_xi[nc+j] = statea->nhpres_xi[nc+j]; -+ stateb->nhpres_vxi[nc+j] = statea->nhpres_vxi[nc+j]; -+ } -+ } -+ } -+} -+ -+real compute_conserved_from_auxiliary(t_inputrec *ir, t_state *state, t_extmass *MassQ) -+{ -+ real quantity = 0; -+ switch (ir->etc) -+ { -+ case etcNO: -+ break; -+ case etcBERENDSEN: -+ break; -+ case etcNOSEHOOVER: -+ quantity = NPT_energy(ir,state,MassQ); -+ break; -+ case etcVRESCALE: -+ quantity = vrescale_energy(&(ir->opts),state->therm_integral); -+ break; -+ default: -+ break; -+ } -+ return quantity; -+} -+ -+void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, -+ t_forcerec *fr, gmx_ekindata_t *ekind, -+ t_state *state, t_state *state_global, t_mdatoms *mdatoms, -+ t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, -+ gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, -+ tensor pres, rvec mu_tot, gmx_constr_t constr, -+ globsig_t *gs,gmx_bool bInterSimGS, -+ matrix box, gmx_mtop_t *top_global, real *pcurr, -+ int natoms, gmx_bool *bSumEkinhOld, int flags) -+{ -+ int i,gsi; -+ real gs_buf[eglsNR]; -+ tensor corr_vir,corr_pres,shakeall_vir; -+ gmx_bool bEner,bPres,bTemp, bVV; -+ gmx_bool bRerunMD, bStopCM, bGStat, bIterate, -+ bFirstIterate,bReadEkin,bEkinAveVel,bScaleEkin, bConstrain; -+ real ekin,temp,prescorr,enercorr,dvdlcorr; -+ -+ /* translate CGLO flags to gmx_booleans */ -+ bRerunMD = flags & CGLO_RERUNMD; -+ bStopCM = flags & CGLO_STOPCM; -+ bGStat = flags & CGLO_GSTAT; -+ -+ bReadEkin = (flags & CGLO_READEKIN); -+ bScaleEkin = (flags & CGLO_SCALEEKIN); -+ bEner = flags & CGLO_ENERGY; -+ bTemp = flags & CGLO_TEMPERATURE; -+ bPres = (flags & CGLO_PRESSURE); -+ bConstrain = (flags & CGLO_CONSTRAINT); -+ bIterate = (flags & CGLO_ITERATE); -+ bFirstIterate = (flags & CGLO_FIRSTITERATE); -+ -+ /* we calculate a full state kinetic energy either with full-step velocity verlet -+ or half step where we need the pressure */ -+ -+ bEkinAveVel = (ir->eI==eiVV || (ir->eI==eiVVAK && bPres) || bReadEkin); -+ -+ /* in initalization, it sums the shake virial in vv, and to -+ sums ekinh_old in leapfrog (or if we are calculating ekinh_old) for other reasons */ -+ -+ /* ########## Kinetic energy ############## */ -+ -+ if (bTemp) -+ { -+ /* Non-equilibrium MD: this is parallellized, but only does communication -+ * when there really is NEMD. -+ */ -+ -+ if (PAR(cr) && (ekind->bNEMD)) -+ { -+ accumulate_u(cr,&(ir->opts),ekind); -+ } -+ debug_gmx(); -+ if (bReadEkin) -+ { -+ restore_ekinstate_from_state(cr,ekind,&state_global->ekinstate); -+ } -+ else -+ { -+ -+ calc_ke_part(state,&(ir->opts),mdatoms,ekind,nrnb,bEkinAveVel,bIterate); -+ } -+ -+ debug_gmx(); -+ -+ /* Calculate center of mass velocity if necessary, also parallellized */ -+ if (bStopCM && !bRerunMD && bEner) -+ { -+ calc_vcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms, -+ state->x,state->v,vcm); -+ } -+ } -+ -+ if (bTemp || bPres || bEner || bConstrain) -+ { -+ if (!bGStat) -+ { -+ /* We will not sum ekinh_old, -+ * so signal that we still have to do it. -+ */ -+ *bSumEkinhOld = TRUE; -+ -+ } -+ else -+ { -+ if (gs != NULL) -+ { -+ for(i=0; isig[i]; -+ } -+ } -+ if (PAR(cr)) -+ { -+ wallcycle_start(wcycle,ewcMoveE); -+ GMX_MPE_LOG(ev_global_stat_start); -+ global_stat(fplog,gstat,cr,enerd,force_vir,shake_vir,mu_tot, -+ ir,ekind,constr,vcm, -+ gs != NULL ? eglsNR : 0,gs_buf, -+ top_global,state, -+ *bSumEkinhOld,flags); -+ GMX_MPE_LOG(ev_global_stat_finish); -+ wallcycle_stop(wcycle,ewcMoveE); -+ } -+ if (gs != NULL) -+ { -+ if (MULTISIM(cr) && bInterSimGS) -+ { -+ if (MASTER(cr)) -+ { -+ /* Communicate the signals between the simulations */ -+ gmx_sum_sim(eglsNR,gs_buf,cr->ms); -+ } -+ /* Communicate the signals form the master to the others */ -+ gmx_bcast(eglsNR*sizeof(gs_buf[0]),gs_buf,cr); -+ } -+ for(i=0; i= 0 ? -+ (int)(gs_buf[i] + 0.5) : -+ (int)(gs_buf[i] - 0.5)); -+ if (gsi != 0) -+ { -+ gs->set[i] = gsi; -+ } -+ /* Turn off the local signal */ -+ gs->sig[i] = 0; -+ } -+ } -+ } -+ *bSumEkinhOld = FALSE; -+ } -+ } -+ -+ if (!ekind->bNEMD && debug && bTemp && (vcm->nr > 0)) -+ { -+ correct_ekin(debug, -+ mdatoms->start,mdatoms->start+mdatoms->homenr, -+ state->v,vcm->group_p[0], -+ mdatoms->massT,mdatoms->tmass,ekind->ekin); -+ } -+ -+ if (bEner) { -+ /* Do center of mass motion removal */ -+ if (bStopCM && !bRerunMD) /* is this correct? Does it get called too often with this logic? */ -+ { -+ check_cm_grp(fplog,vcm,ir,1); -+ do_stopcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms->cVCM, -+ state->x,state->v,vcm); -+ inc_nrnb(nrnb,eNR_STOPCM,mdatoms->homenr); -+ } -+ -+ /* Calculate the amplitude of the cosine velocity profile */ -+ ekind->cosacc.vcos = ekind->cosacc.mvcos/mdatoms->tmass; -+ } -+ -+ if (bTemp) -+ { -+ /* Sum the kinetic energies of the groups & calc temp */ -+ /* compute full step kinetic energies if vv, or if vv-avek and we are computing the pressure with IR_NPT_TROTTER */ -+ /* three maincase: VV with AveVel (md-vv), vv with AveEkin (md-vv-avek), leap with AveEkin (md). -+ Leap with AveVel is not supported; it's not clear that it will actually work. -+ bEkinAveVel: If TRUE, we simply multiply ekin by ekinscale to get a full step kinetic energy. -+ If FALSE, we average ekinh_old and ekinh*ekinscale_nhc to get an averaged half step kinetic energy. -+ bSaveEkinOld: If TRUE (in the case of iteration = bIterate is TRUE), we don't reset the ekinscale_nhc. -+ If FALSE, we go ahead and erase over it. -+ */ -+ enerd->term[F_TEMP] = sum_ekin(&(ir->opts),ekind,&(enerd->term[F_DKDL]), -+ bEkinAveVel,bIterate,bScaleEkin); -+ -+ enerd->term[F_EKIN] = trace(ekind->ekin); -+ } -+ -+ /* ########## Long range energy information ###### */ -+ -+ if (bEner || bPres || bConstrain) -+ { -+ calc_dispcorr(fplog,ir,fr,0,top_global->natoms,box,state->lambda, -+ corr_pres,corr_vir,&prescorr,&enercorr,&dvdlcorr); -+ } -+ -+ if (bEner && bFirstIterate) -+ { -+ enerd->term[F_DISPCORR] = enercorr; -+ enerd->term[F_EPOT] += enercorr; -+ enerd->term[F_DVDL] += dvdlcorr; -+ if (fr->efep != efepNO) { -+ enerd->dvdl_lin += dvdlcorr; -+ } -+ } -+ -+ /* ########## Now pressure ############## */ -+ if (bPres || bConstrain) -+ { -+ -+ m_add(force_vir,shake_vir,total_vir); -+ -+ /* Calculate pressure and apply LR correction if PPPM is used. -+ * Use the box from last timestep since we already called update(). -+ */ -+ -+ enerd->term[F_PRES] = calc_pres(fr->ePBC,ir->nwall,box,ekind->ekin,total_vir,pres, -+ (fr->eeltype==eelPPPM)?enerd->term[F_COUL_RECIP]:0.0); -+ -+ /* Calculate long range corrections to pressure and energy */ -+ /* this adds to enerd->term[F_PRES] and enerd->term[F_ETOT], -+ and computes enerd->term[F_DISPCORR]. Also modifies the -+ total_vir and pres tesors */ -+ -+ m_add(total_vir,corr_vir,total_vir); -+ m_add(pres,corr_pres,pres); -+ enerd->term[F_PDISPCORR] = prescorr; -+ enerd->term[F_PRES] += prescorr; -+ *pcurr = enerd->term[F_PRES]; -+ /* calculate temperature using virial */ -+ enerd->term[F_VTEMP] = calc_temp(trace(total_vir),ir->opts.nrdf[0]); -+ -+ } -+} -+ -+void check_nst_param(FILE *fplog,t_commrec *cr, -+ const char *desc_nst,int nst, -+ const char *desc_p,int *p) -+{ -+ char buf[STRLEN]; -+ -+ if (*p > 0 && *p % nst != 0) -+ { -+ /* Round up to the next multiple of nst */ -+ *p = ((*p)/nst + 1)*nst; -+ sprintf(buf,"NOTE: %s changes %s to %d\n",desc_nst,desc_p,*p); -+ md_print_warning(cr,fplog,buf); -+ } -+} -+ -+void reset_all_counters(FILE *fplog,t_commrec *cr, -+ gmx_large_int_t step, -+ gmx_large_int_t *step_rel,t_inputrec *ir, -+ gmx_wallcycle_t wcycle,t_nrnb *nrnb, -+ gmx_runtime_t *runtime) -+{ -+ char buf[STRLEN],sbuf[STEPSTRSIZE]; -+ -+ /* Reset all the counters related to performance over the run */ -+ sprintf(buf,"Step %s: resetting all time and cycle counters\n", -+ gmx_step_str(step,sbuf)); -+ md_print_warning(cr,fplog,buf); -+ -+ wallcycle_stop(wcycle,ewcRUN); -+ wallcycle_reset_all(wcycle); -+ if (DOMAINDECOMP(cr)) -+ { -+ reset_dd_statistics_counters(cr->dd); -+ } -+ init_nrnb(nrnb); -+ ir->init_step += *step_rel; -+ ir->nsteps -= *step_rel; -+ *step_rel = 0; -+ wallcycle_start(wcycle,ewcRUN); -+ runtime_start(runtime); -+ print_date_and_time(fplog,cr->nodeid,"Restarted time",runtime); -+} -+ -+void min_zero(int *n,int i) -+{ -+ if (i > 0 && (*n == 0 || i < *n)) -+ { -+ *n = i; -+ } -+} -+ -+int lcd4(int i1,int i2,int i3,int i4) -+{ -+ int nst; -+ -+ nst = 0; -+ min_zero(&nst,i1); -+ min_zero(&nst,i2); -+ min_zero(&nst,i3); -+ min_zero(&nst,i4); -+ if (nst == 0) -+ { -+ gmx_incons("All 4 inputs for determininig nstglobalcomm are <= 0"); -+ } -+ -+ while (nst > 1 && ((i1 > 0 && i1 % nst != 0) || -+ (i2 > 0 && i2 % nst != 0) || -+ (i3 > 0 && i3 % nst != 0) || -+ (i4 > 0 && i4 % nst != 0))) -+ { -+ nst--; -+ } -+ -+ return nst; -+} -+ -+int check_nstglobalcomm(FILE *fplog,t_commrec *cr, -+ int nstglobalcomm,t_inputrec *ir) -+{ -+ char buf[STRLEN]; -+ -+ if (!EI_DYNAMICS(ir->eI)) -+ { -+ nstglobalcomm = 1; -+ } -+ -+ if (nstglobalcomm == -1) -+ { -+ if (!(ir->nstcalcenergy > 0 || -+ ir->nstlist > 0 || -+ ir->etc != etcNO || -+ ir->epc != epcNO)) -+ { -+ nstglobalcomm = 10; -+ if (ir->nstenergy > 0 && ir->nstenergy < nstglobalcomm) -+ { -+ nstglobalcomm = ir->nstenergy; -+ } -+ } -+ else -+ { -+ /* Ensure that we do timely global communication for -+ * (possibly) each of the four following options. -+ */ -+ nstglobalcomm = lcd4(ir->nstcalcenergy, -+ ir->nstlist, -+ ir->etc != etcNO ? ir->nsttcouple : 0, -+ ir->epc != epcNO ? ir->nstpcouple : 0); -+ } -+ } -+ else -+ { -+ if (ir->nstlist > 0 && -+ nstglobalcomm > ir->nstlist && nstglobalcomm % ir->nstlist != 0) -+ { -+ nstglobalcomm = (nstglobalcomm / ir->nstlist)*ir->nstlist; -+ sprintf(buf,"WARNING: nstglobalcomm is larger than nstlist, but not a multiple, setting it to %d\n",nstglobalcomm); -+ md_print_warning(cr,fplog,buf); -+ } -+ if (ir->nstcalcenergy > 0) -+ { -+ check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -+ "nstcalcenergy",&ir->nstcalcenergy); -+ } -+ if (ir->etc != etcNO && ir->nsttcouple > 0) -+ { -+ check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -+ "nsttcouple",&ir->nsttcouple); -+ } -+ if (ir->epc != epcNO && ir->nstpcouple > 0) -+ { -+ check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -+ "nstpcouple",&ir->nstpcouple); -+ } -+ -+ check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -+ "nstenergy",&ir->nstenergy); -+ -+ check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -+ "nstlog",&ir->nstlog); -+ } -+ -+ if (ir->comm_mode != ecmNO && ir->nstcomm < nstglobalcomm) -+ { -+ sprintf(buf,"WARNING: Changing nstcomm from %d to %d\n", -+ ir->nstcomm,nstglobalcomm); -+ md_print_warning(cr,fplog,buf); -+ ir->nstcomm = nstglobalcomm; -+ } -+ -+ return nstglobalcomm; -+} -+ -+void check_ir_old_tpx_versions(t_commrec *cr,FILE *fplog, -+ t_inputrec *ir,gmx_mtop_t *mtop) -+{ -+ /* Check required for old tpx files */ -+ if (IR_TWINRANGE(*ir) && ir->nstlist > 1 && -+ ir->nstcalcenergy % ir->nstlist != 0) -+ { -+ md_print_warning(cr,fplog,"Old tpr file with twin-range settings: modifying energy calculation and/or T/P-coupling frequencies"); -+ -+ if (gmx_mtop_ftype_count(mtop,F_CONSTR) + -+ gmx_mtop_ftype_count(mtop,F_CONSTRNC) > 0 && -+ ir->eConstrAlg == econtSHAKE) -+ { -+ md_print_warning(cr,fplog,"With twin-range cut-off's and SHAKE the virial and pressure are incorrect"); -+ if (ir->epc != epcNO) -+ { -+ gmx_fatal(FARGS,"Can not do pressure coupling with twin-range cut-off's and SHAKE"); -+ } -+ } -+ check_nst_param(fplog,cr,"nstlist",ir->nstlist, -+ "nstcalcenergy",&ir->nstcalcenergy); -+ if (ir->epc != epcNO) -+ { -+ check_nst_param(fplog,cr,"nstlist",ir->nstlist, -+ "nstpcouple",&ir->nstpcouple); -+ } -+ check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -+ "nstenergy",&ir->nstenergy); -+ check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -+ "nstlog",&ir->nstlog); -+ if (ir->efep != efepNO) -+ { -+ check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -+ "nstdhdl",&ir->nstdhdl); -+ } -+ } -+} -+ -+void rerun_parallel_comm(t_commrec *cr,t_trxframe *fr, -+ gmx_bool *bNotLastFrame) -+{ -+ gmx_bool bAlloc; -+ rvec *xp,*vp; -+ -+ bAlloc = (fr->natoms == 0); -+ -+ if (MASTER(cr) && !*bNotLastFrame) -+ { -+ fr->natoms = -1; -+ } -+ xp = fr->x; -+ vp = fr->v; -+ gmx_bcast(sizeof(*fr),fr,cr); -+ fr->x = xp; -+ fr->v = vp; -+ -+ *bNotLastFrame = (fr->natoms >= 0); -+ -+ if (*bNotLastFrame && PARTDECOMP(cr)) -+ { -+ /* x and v are the only variable size quantities stored in trr -+ * that are required for rerun (f is not needed). -+ */ -+ if (bAlloc) -+ { -+ snew(fr->x,fr->natoms); -+ snew(fr->v,fr->natoms); -+ } -+ if (fr->bX) -+ { -+ gmx_bcast(fr->natoms*sizeof(fr->x[0]),fr->x[0],cr); -+ } -+ if (fr->bV) -+ { -+ gmx_bcast(fr->natoms*sizeof(fr->v[0]),fr->v[0],cr); -+ } -+ } -+} -+ -+void md_print_warning(const t_commrec *cr,FILE *fplog,const char *buf) -+{ -+ if (MASTER(cr)) -+ { -+ fprintf(stderr,"\n%s\n",buf); -+ } -+ if (fplog) -+ { -+ fprintf(fplog,"\n%s\n",buf); -+ } -+} -diff --git a/src/mdlib/nlistheuristics.c b/src/mdlib/nlistheuristics.c -new file mode 100644 -index 0000000..0848e24 ---- /dev/null -+++ b/src/mdlib/nlistheuristics.c -@@ -0,0 +1,139 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * Gallium Rubidium Oxygen Manganese Argon Carbon Silicon -+ */ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) -+/* _isnan() */ -+#include -+#endif -+ -+#include "typedefs.h" -+#include "gmx_fatal.h" -+#include "vec.h" -+ -+void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step) -+{ -+ nlh->lt_runav = 0; -+ nlh->lt_runav2 = 0; -+ nlh->step_nscheck = step; -+} -+ -+void init_nlistheuristics(gmx_nlheur_t *nlh, -+ gmx_bool bGStatEveryStep,gmx_large_int_t step) -+{ -+ nlh->bGStatEveryStep = bGStatEveryStep; -+ nlh->nns = 0; -+ nlh->nabnsb = 0; -+ nlh->s1 = 0; -+ nlh->s2 = 0; -+ nlh->ab = 0; -+ -+ reset_nlistheuristics(nlh,step); -+} -+ -+void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step) -+{ -+ gmx_large_int_t nl_lt; -+ char sbuf[STEPSTRSIZE],sbuf2[STEPSTRSIZE]; -+ -+ /* Determine the neighbor list life time */ -+ nl_lt = step - nlh->step_ns; -+ if (debug) -+ { -+ fprintf(debug,"%d atoms beyond ns buffer, updating neighbor list after %s steps\n",nlh->nabnsb,gmx_step_str(nl_lt,sbuf)); -+ } -+ nlh->nns++; -+ nlh->s1 += nl_lt; -+ nlh->s2 += nl_lt*nl_lt; -+ nlh->ab += nlh->nabnsb; -+ if (nlh->lt_runav == 0) -+ { -+ nlh->lt_runav = nl_lt; -+ /* Initialize the fluctuation average -+ * such that at startup we check after 0 steps. -+ */ -+ nlh->lt_runav2 = sqr(nl_lt/2.0); -+ } -+ /* Running average with 0.9 gives an exp. history of 9.5 */ -+ nlh->lt_runav2 = 0.9*nlh->lt_runav2 + 0.1*sqr(nlh->lt_runav - nl_lt); -+ nlh->lt_runav = 0.9*nlh->lt_runav + 0.1*nl_lt; -+ if (nlh->bGStatEveryStep) -+ { -+ /* Always check the nlist validity */ -+ nlh->step_nscheck = step; -+ } -+ else -+ { -+ /* We check after: - 2*sigma -+ * The factor 2 is quite conservative, -+ * but we assume that with nstlist=-1 the user -+ * prefers exact integration over performance. -+ */ -+ nlh->step_nscheck = step -+ + (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2)) - 1; -+ } -+ if (debug) -+ { -+ fprintf(debug,"nlist life time %s run av. %4.1f sig %3.1f check %s check with -gcom %d\n", -+ gmx_step_str(nl_lt,sbuf),nlh->lt_runav,sqrt(nlh->lt_runav2), -+ gmx_step_str(nlh->step_nscheck-step+1,sbuf2), -+ (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2))); -+ } -+} -+ -+void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step) -+{ -+ int d; -+ -+ if (bReset) -+ { -+ reset_nlistheuristics(nlh,step); -+ } -+ else -+ { -+ update_nliststatistics(nlh,step); -+ } -+ -+ nlh->step_ns = step; -+ /* Initialize the cumulative coordinate scaling matrix */ -+ clear_mat(nlh->scale_tot); -+ for(d=0; dscale_tot[d][d] = 1.0; -+ } -+} -diff --git a/src/ngmx/ngmx.c b/src/ngmx/ngmx.c -index 39f2428..5c39957 100644 ---- a/src/ngmx/ngmx.c -+++ b/src/ngmx/ngmx.c -@@ -267,7 +267,7 @@ static gmx_bool MainCallBack(t_x11 *x11,XEvent *event, Window w, void *data) - int main(int argc, char *argv[]) - { - const char *desc[] = { -- "[TT]ngmx[tt] is the Gromacs trajectory viewer. This program reads a", -+ "[TT]ngmx[tt] is the GROMACS trajectory viewer. This program reads a", - "trajectory file, a run input file and an index file and plots a", - "3D structure of your molecule on your standard X Window", - "screen. No need for a high end graphics workstation, it even", -@@ -279,8 +279,8 @@ int main(int argc, char *argv[]) - "runs on MIT-X (real X), open windows and motif,", - "user friendly menus, option to remove periodicity, option to", - "show computational box.[PAR]", -- "Some of the more common X command line options can be used:[BR]", -- "[TT]-bg[tt], [TT]-fg[tt] change colors, [TT]-font[tt] fontname, changes the font." -+ "Some of the more common X command line options can be used: ", -+ "[TT]-bg[tt], [TT]-fg[tt] change colors, [TT]-font fontname[tt] changes the font." - }; - const char *bugs[] = { - "Balls option does not work", -diff --git a/src/tools/Makefile.am b/src/tools/Makefile.am -index bacf96f..6322b85 100644 ---- a/src/tools/Makefile.am -+++ b/src/tools/Makefile.am -@@ -43,8 +43,12 @@ libgmxana@LIBSUFFIX@_la_SOURCES = \ - gmx_trjconv.c gmx_trjcat.c gmx_trjorder.c gmx_xpm2ps.c \ - gmx_editconf.c gmx_genbox.c gmx_genion.c gmx_genconf.c \ - gmx_genpr.c gmx_eneconv.c gmx_vanhove.c gmx_wheel.c \ -- addconf.c addconf.h gmx_tune_pme.c gmx_membed.c \ -- calcpot.c calcpot.h edittop.c -+ addconf.c addconf.h gmx_tune_pme.c gmx_membed.c \ -+ calcpot.c calcpot.h edittop.c \ -+ dens_filter.c dens_filter.h \ -+ powerspect.c powerspect.h interf.h \ -+ gmx_densorder.c gmx_hydorder.c \ -+ binsearch.h binsearch.c - - bin_PROGRAMS = \ - do_dssp editconf eneconv \ -@@ -71,12 +75,8 @@ bin_PROGRAMS = \ - g_spatial g_pme_error g_options \ - g_tcaf g_traj g_tune_pme \ - g_vanhove g_velacc g_membed \ -- g_clustsize g_mdmat g_wham \ -- g_sigeps -- --# These programs are not compiled or installed by default - you will have to --# issue "make " and copy the binary to the correct location yourself! --# Add new entries in Makefile.am! -+ g_clustsize g_mdmat g_wham g_kinetics \ -+ g_sigeps g_densorder g_hydorder - - EXTRA_DIST = libgmxana.pc.cmakein - -diff --git a/src/tools/binsearch.c b/src/tools/binsearch.c -new file mode 100644 -index 0000000..1cded0c ---- /dev/null -+++ b/src/tools/binsearch.c -@@ -0,0 +1,171 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * $Id: densorder.c,v 0.9 -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.0 -+ * -+ * Copyright (c) 1991-2001 -+ * BIOSON Research Institute, Dept. of Biophysical Chemistry -+ * University of Groningen, The Netherlands -+ * -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . -+ * -+ * And Hey: -+ * Gyas ROwers Mature At Cryogenic Speed -+ */ -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+#include -+#include "types/simple.h" -+ -+/*Make range-array (Permutation identity) for sorting */ -+void rangeArray(int *ar,int size) -+{ -+ int i; -+ for (i=0;i=0){ -+ for (i = startndx; i <=endndx; i++) { -+ j = i; -+ -+ while (j > startndx && arr[j - 1] > arr[j]) { -+ Swap(&arr[j],&arr[j-1]); -+ pswap(&perm[j],&perm[j-1]); -+ j--; -+ } -+ -+ } -+ -+ } -+ -+ if(direction<0){ -+ for (i = startndx; i <=endndx; i++) { -+ j = i; -+ -+ while (j > startndx && arr[j - 1] < arr[j]) { -+ Swap(&arr[j],&arr[j-1]); -+ pswap(&perm[j],&perm[j-1]); -+ j--; -+ } -+ -+ } -+ } -+} -+ -+ -+int BinarySearch (real *array, int low, int high, real key,int direction) -+{ -+ int mid, max, min; -+ max=high+2; -+ min=low+1; -+ -+/*Iterative implementation*/ -+ -+ if (direction>=0){ -+ while (max-min>1){ -+ mid=(min+max)>>1; -+ if(key1){ -+ mid=(min+max)>>1; -+ if(key>array[mid-1]) max=mid; -+ else min=mid; -+ } -+ return min-1; -+ -+ }/*end -ifelse direction*/ -+} -+ -+ -+int start_binsearch(real *array, int *perm, int low, int high, -+ real key, int direction) -+{ -+ insertionSort(array,perm,low,high,direction); -+ return BinarySearch(array,low,high,key,direction); -+} -+ -+int LinearSearch (double *array,int startindx, int stopindx, -+ double key,int *count, int direction) -+{ -+ /*Iterative implementation - assume elements sorted*/ -+ int i; -+ int keyindex; -+ -+ if(direction>=0){ -+ keyindex=startindx; -+ for (i=startindx;i<=stopindx;i++){ -+ (*count)++; -+ if(array[i]>key) { -+ keyindex=i-1; -+ return keyindex; -+ } -+ } -+ } -+ else if(direction<0 ){ -+ keyindex=stopindx; -+ for(i=stopindx;i>=startindx;i--){ -+ (*count)++; -+ if (array[i]>key){ -+ keyindex=i+1; -+ return keyindex; -+ } -+ } -+ } -+ -+ else -+ fprintf(stderr,"Error: startindex=stopindex=%d\n",startindx); -+ -+} -+ -diff --git a/src/tools/binsearch.h b/src/tools/binsearch.h -new file mode 100644 -index 0000000..973c5f2 ---- /dev/null -+++ b/src/tools/binsearch.h -@@ -0,0 +1,54 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * $Id: densorder.c,v 0.9 -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.0 -+ * -+ * Copyright (c) 1991-2001 -+ * BIOSON Research Institute, Dept. of Biophysical Chemistry -+ * University of Groningen, The Netherlands -+ * -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . -+ * -+ * And Hey: -+ * Gyas ROwers Mature At Cryogenic Speed -+ */ -+ -+#ifndef _binsearch_h -+#define _binsearch_h -+ -+#include "types/simple.h" -+ -+extern void rangeArray(int *ar,int size); -+ -+extern void insertionSort(real *ar, int *perm, int start, int end, int direction); -+ -+extern int BinarySearch(real *ar, int start, int end, real key, int direction); -+ -+extern int start_binsearch(real *array, int *perm, int low, int high, -+ real key, int direction); -+ -+extern int LinearSearch(double *array,int startindx, int stopindx, -+ double key,int *count, int direction); -+ -+#endif -diff --git a/src/tools/dens_filter.c b/src/tools/dens_filter.c -new file mode 100644 -index 0000000..dca3192 ---- /dev/null -+++ b/src/tools/dens_filter.c -@@ -0,0 +1,131 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * $Id: densorder.c,v 0.9 -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.0 -+ * -+ * Copyright (c) 1991-2001 -+ * BIOSON Research Institute, Dept. of Biophysical Chemistry -+ * University of Groningen, The Netherlands -+ * -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . -+ * -+ * And Hey: -+ * Gyas ROwers Mature At Cryogenic Speed -+ */ -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+/* dens_filter.c -+ * Routines for Filters and convolutions -+ */ -+ -+#include -+#include "typedefs.h" -+#include "dens_filter.h" -+#include "smalloc.h" -+#include "vec.h" -+ -+#ifdef GMX_DOUBLE -+#define EXP(x) (exp(x)) -+#else -+#define EXP(x) (expf(x)) -+#endif -+ -+/* Modulo function assuming y>0 but with arbitrary INTEGER x */ -+static int MOD(int x, int y){ -+ if (x<0) x=x+y; -+ return (mod(x,y)); -+} -+ -+ -+gmx_bool convolution(int dataSize,real *x, int kernelSize, real* kernel) -+{ -+ int i, j, k; -+ real *out; -+ snew(out,dataSize); -+ /* check validity of params */ -+ if(!x || !kernel) return FALSE; -+ if(dataSize <=0 || kernelSize <= 0) return FALSE; -+ -+ /* start convolution from out[kernelSize-1] to out[dataSize-1] (last) */ -+ for(i = kernelSize-1; i < dataSize; ++i) -+ { -+ for(j = i, k = 0; k < kernelSize; --j, ++k) -+ out[i] += x[j] * kernel[k]; -+ } -+ -+ /* convolution from out[0] to out[kernelSize-2] */ -+ for(i = 0; i < kernelSize - 1; ++i) -+ { -+ for(j = i, k = 0; j >= 0; --j, ++k) -+ out[i] += x[j] * kernel[k]; -+ } -+ -+ for(i=0;i datasize) return FALSE; -+ -+ int i,j,k,nj; -+ real *filtered; -+ snew(filtered,datasize); -+ -+ for(i=0;(i 2) - fprintf(stderr," %10.5e",a[3]); -+ if (mfit > 3) -+ fprintf(stderr," %10.5e",a[4]); - fprintf(stderr,"\n"); - } - j++; -@@ -398,7 +438,7 @@ static gmx_bool lmfit_exp(int nfit,real x[],real y[],real dy[],real ftol, - - real do_lmfit(int ndata,real c1[],real sig[],real dt,real x0[], - real begintimefit,real endtimefit,const output_env_t oenv, -- gmx_bool bVerbose, int eFitFn,real fitparms[],int fix) -+ gmx_bool bVerbose, int eFitFn,real fitparms[],int fix) - { - FILE *fp; - char buf[32]; -@@ -484,7 +524,7 @@ real do_lmfit(int ndata,real c1[],real sig[],real dt,real x0[], - fprintf(fp,"%10.5e %10.5e %10.5e\n", - ttt,c1[j],fit_function(eFitFn,parm,ttt)); - } -- ffclose(fp); -+ fclose(fp); - } - } - for(i=0;(i -+#endif -+ -+#include -+ -+ -+ -+/* This is just a wrapper binary. -+* The code that used to be in g_density.c is now in gmx_density.c, -+* where the old main function is called gmx_density(). -+*/ -+ -+int main(int argc, char *argv[]) -+{ -+ gmx_densorder(argc,argv); -+ return 0; -+} -+ -+ -+ -diff --git a/src/tools/g_hydorder.c b/src/tools/g_hydorder.c -new file mode 100644 -index 0000000..91cdd5b ---- /dev/null -+++ b/src/tools/g_hydorder.c -@@ -0,0 +1,54 @@ -+/* -+ * $Id: g_hydorder.c,v 1.1 2009/05/15 12:00:17 bjornss Exp $ -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 4.0.99 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * Green Red Orange Magenta Azure Cyan Skyblue -+ */ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#include -+ -+ -+ -+/* This is just a wrapper binary. -+*/ -+int -+main(int argc, char *argv[]) -+{ -+ gmx_hydorder(argc,argv); -+ return 0; -+} -+ -+ -+ -diff --git a/src/tools/g_sigeps.c b/src/tools/g_sigeps.c -index 9737220..34f3ded 100644 ---- a/src/tools/g_sigeps.c -+++ b/src/tools/g_sigeps.c -@@ -73,10 +73,10 @@ real dpot(real x,real qq,real c6,real cn,int npow) - int main(int argc,char *argv[]) - { - const char *desc[] = { -- "[TT]g_sigeps[tt] is a simple utility that converts c6/c12 or c6/cn combinations", -- "to sigma and epsilon, or vice versa. It can also plot the potential", -- "in file. In addition it makes an approximation of a Buckingham potential", -- "to a Lennard Jones potential." -+ "[TT]g_sigeps[tt] is a simple utility that converts C6/C12 or C6/Cn combinations", -+ "to [GRK]sigma[grk] and [GRK]epsilon[grk], or vice versa. It can also plot the potential", -+ "in file. In addition, it makes an approximation of a Buckingham potential", -+ "to a Lennard-Jones potential." - }; - static real c6=1.0e-3,cn=1.0e-6,qi=0,qj=0,sig=0.3,eps=1,sigfac=0.7; - static real Abh=1e5,Bbh=32,Cbh=1e-3; -diff --git a/src/tools/gmx_anaeig.c b/src/tools/gmx_anaeig.c -index df3f0fe..81627fc 100644 ---- a/src/tools/gmx_anaeig.c -+++ b/src/tools/gmx_anaeig.c -@@ -794,7 +794,7 @@ int gmx_anaeig(int argc,char *argv[]) - "can use [TT]rasmol -nmrpdb[tt] to view such a [TT].pdb[tt] file).[PAR]", - - " Overlap calculations between covariance analysis:[BR]", -- " NOTE: the analysis should use the same fitting structure[PAR]", -+ " [BB]Note:[bb] the analysis should use the same fitting structure[PAR]", - - "[TT]-over[tt]: calculate the subspace overlap of the eigenvectors in", - "file [TT]-v2[tt] with eigenvectors [TT]-first[tt] to [TT]-last[tt]", -diff --git a/src/tools/gmx_analyze.c b/src/tools/gmx_analyze.c -index 9b9f51a..08c16d1 100644 ---- a/src/tools/gmx_analyze.c -+++ b/src/tools/gmx_analyze.c -@@ -888,21 +888,21 @@ static void do_geminate(const char *gemFile, int nData, - int gmx_analyze(int argc,char *argv[]) - { - static const char *desc[] = { -- "[TT]g_analyze[tt] reads an ascii file and analyzes data sets.", -+ "[TT]g_analyze[tt] reads an ASCII file and analyzes data sets.", - "A line in the input file may start with a time", -- "(see option [TT]-time[tt]) and any number of y values may follow.", -+ "(see option [TT]-time[tt]) and any number of [IT]y[it]-values may follow.", - "Multiple sets can also be", -- "read when they are separated by & (option [TT]-n[tt]),", -- "in this case only one y value is read from each line.", -+ "read when they are separated by & (option [TT]-n[tt]);", -+ "in this case only one [IT]y[it]-value is read from each line.", - "All lines starting with # and @ are skipped.", - "All analyses can also be done for the derivative of a set", - "(option [TT]-d[tt]).[PAR]", - -- "All options, except for [TT]-av[tt] and [TT]-power[tt] assume that the", -+ "All options, except for [TT]-av[tt] and [TT]-power[tt], assume that the", - "points are equidistant in time.[PAR]", - - "[TT]g_analyze[tt] always shows the average and standard deviation of each", -- "set. For each set it also shows the relative deviation of the third", -+ "set, as well as the relative deviation of the third", - "and fourth cumulant from those of a Gaussian distribution with the same", - "standard deviation.[PAR]", - -@@ -910,7 +910,7 @@ int gmx_analyze(int argc,char *argv[]) - - "Option [TT]-cc[tt] plots the resemblance of set i with a cosine of", - "i/2 periods. The formula is:[BR]" -- "2 (int0-T y(t) cos(i pi t) dt)^2 / int0-T y(t) y(t) dt[BR]", -+ "2 (int0-T y(t) cos(i [GRK]pi[grk] t) dt)^2 / int0-T y(t) y(t) dt[BR]", - "This is useful for principal components obtained from covariance", - "analysis, since the principal components of random diffusion are", - "pure cosines.[PAR]", -@@ -935,12 +935,12 @@ int gmx_analyze(int argc,char *argv[]) - "Also an analytical block average curve is plotted, assuming", - "that the autocorrelation is a sum of two exponentials.", - "The analytical curve for the block average is:[BR]", -- "f(t) = sigma sqrt(2/T ( a (tau1 ((exp(-t/tau1) - 1) tau1/t + 1)) +[BR]", -- " (1-a) (tau2 ((exp(-t/tau2) - 1) tau2/t + 1)))),[BR]" -+ "f(t) = [GRK]sigma[grk][TT]*[tt]sqrt(2/T ( [GRK]alpha[grk] ([GRK]tau[grk]1 ((exp(-t/[GRK]tau[grk]1) - 1) [GRK]tau[grk]1/t + 1)) +[BR]", -+ " (1-[GRK]alpha[grk]) ([GRK]tau[grk]2 ((exp(-t/[GRK]tau[grk]2) - 1) [GRK]tau[grk]2/t + 1)))),[BR]" - "where T is the total time.", -- "a, tau1 and tau2 are obtained by fitting f^2(t) to error^2.", -+ "[GRK]alpha[grk], [GRK]tau[grk]1 and [GRK]tau[grk]2 are obtained by fitting f^2(t) to error^2.", - "When the actual block average is very close to the analytical curve,", -- "the error is sigma*sqrt(2/T (a tau1 + (1-a) tau2)).", -+ "the error is [GRK]sigma[grk][TT]*[tt]sqrt(2/T (a [GRK]tau[grk]1 + (1-a) [GRK]tau[grk]2)).", - "The complete derivation is given in", - "B. Hess, J. Chem. Phys. 116:209-217, 2002.[PAR]", - -@@ -960,7 +960,7 @@ int gmx_analyze(int argc,char *argv[]) - - "Option [TT]-filter[tt] prints the RMS high-frequency fluctuation", - "of each set and over all sets with respect to a filtered average.", -- "The filter is proportional to cos(pi t/len) where t goes from -len/2", -+ "The filter is proportional to cos([GRK]pi[grk] t/len) where t goes from -len/2", - "to len/2. len is supplied with the option [TT]-filter[tt].", - "This filter reduces oscillations with period len/2 and len by a factor", - "of 0.79 and 0.33 respectively.[PAR]", -@@ -970,7 +970,7 @@ int gmx_analyze(int argc,char *argv[]) - - "Option [TT]-power[tt] fits the data to b t^a, which is accomplished", - "by fitting to a t + b on log-log scale. All points after the first", -- "zero or negative value are ignored.[PAR]" -+ "zero or with a negative value are ignored.[PAR]" - - "Option [TT]-luzar[tt] performs a Luzar & Chandler kinetics analysis", - "on output from [TT]g_hbond[tt]. The input file can be taken directly", -@@ -1012,7 +1012,7 @@ int gmx_analyze(int argc,char *argv[]) - { "-xydy", FALSE, etBOOL, {&bXYdy}, - "Interpret second data set as error in the y values for integrating" }, - { "-regression",FALSE,etBOOL,{&bRegression}, -- "Perform a linear regression analysis on the data. If [TT]-xydy[tt] is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize chi^2 = (y - A0 x0 - A1 x1 - ... - AN xN)^2 where now Y is the first data set in the input file and xi the others. Do read the information at the option [TT]-time[tt]." }, -+ "Perform a linear regression analysis on the data. If [TT]-xydy[tt] is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize [GRK]chi[grk]^2 = (y - A0 x0 - A1 x1 - ... - AN xN)^2 where now Y is the first data set in the input file and xi the others. Do read the information at the option [TT]-time[tt]." }, - { "-luzar", FALSE, etBOOL, {&bLuzar}, - "Do a Luzar and Chandler analysis on a correlation function and related as produced by [TT]g_hbond[tt]. When in addition the [TT]-xydy[tt] flag is given the second and fourth column will be interpreted as errors in c(t) and n(t)." }, - { "-temp", FALSE, etREAL, {&temp}, -@@ -1022,7 +1022,7 @@ int gmx_analyze(int argc,char *argv[]) - { "-fitend", FALSE, etREAL, {&fit_end}, - "Time (ps) where to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. Only with [TT]-gem[tt]" }, - { "-smooth",FALSE, etREAL, {&smooth_tail_start}, -- "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/tau)" }, -+ "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/[GRK]tau[grk])" }, - { "-nbmin", FALSE, etINT, {&nb_min}, - "HIDDENMinimum number of blocks for block averaging" }, - { "-resol", FALSE, etINT, {&resol}, -diff --git a/src/tools/gmx_bar.c b/src/tools/gmx_bar.c -index 4d54b38..649ea0e 100644 ---- a/src/tools/gmx_bar.c -+++ b/src/tools/gmx_bar.c -@@ -56,6 +56,11 @@ - #include "gmx_ana.h" - #include "maths.h" - -+/* Suppress Cygwin compiler warnings from using newlib version of -+ * ctype.h */ -+#ifdef GMX_CYGWIN -+#undef isdigit -+#endif - - /* the dhdl.xvg data from a simulation (actually obsolete, but still - here for reading the dhdl.xvg file*/ -@@ -2482,54 +2487,54 @@ int gmx_bar(int argc,char *argv[]) - - "Every individual BAR free energy difference relies on two ", - "simulations at different states: say state A and state B, as", -- "controlled by a parameter, lambda (see the mdp parameter", -+ "controlled by a parameter, [GRK]lambda[grk] (see the [TT].mdp[tt] parameter", - "[TT]init_lambda[tt]). The BAR method calculates a ratio of weighted", - "average of the Hamiltonian difference of state B given state A and", -- "vice versa. If the Hamiltonian does not linearly depend on lambda", -+ "vice versa. If the Hamiltonian does not depend linearly on [GRK]lambda[grk]", - "(in which case we can extrapolate the derivative of the Hamiltonian", -- "with respect to lambda, as is the default when [TT]free_energy[tt] is on),", -+ "with respect to [GRK]lambda[grk], as is the default when [TT]free_energy[tt] is on),", - "the energy differences to the other state need to be calculated", - "explicitly during the simulation. This can be controlled with", -- "the mdp option [TT]foreign_lambda[tt].[PAR]", -+ "the [TT].mdp[tt] option [TT]foreign_lambda[tt].[PAR]", - -- "Input option [TT]-f[tt] expects multiple dhdl files. ", -+ "Input option [TT]-f[tt] expects multiple [TT]dhdl.xvg[tt] files. ", - "Two types of input files are supported:[BR]", -- "[TT]*[tt] Files with only one y-value, for such files it is assumed ", -- " that the y-value is dH/dlambda and that the Hamiltonian depends ", -- " linearly on lambda. The lambda value of the simulation is inferred ", -- " from the subtitle if present, otherwise from a number in the", -+ "[TT]*[tt] Files with only one [IT]y[it]-value, for such files it is assumed ", -+ " that the [IT]y[it]-value is dH/d[GRK]lambda[grk] and that the Hamiltonian depends ", -+ " linearly on [GRK]lambda[grk]. The [GRK]lambda[grk] value of the simulation is inferred ", -+ " from the subtitle (if present), otherwise from a number in the", - " subdirectory in the file name.", - "[BR]", -- "[TT]*[tt] Files with more than one y-value. The files should have columns ", -- " with dH/dlambda and Delta lambda. The lambda values are inferred ", -- " from the legends: lambda of the simulation from the legend of dH/dlambda ", -- " and the foreign lambda's from the legends of Delta H.[PAR]", -- "The lambda of the simulation is parsed from dhdl.xvg file's legend ", -- "containing the string 'dH', the foreign lambdas from the legend ", -+ "[TT]*[tt] Files with more than one [IT]y[it]-value. The files should have columns ", -+ " with dH/d[GRK]lambda[grk] and [GRK]Delta[grk][GRK]lambda[grk]. The [GRK]lambda[grk] values are inferred ", -+ " from the legends: [GRK]lambda[grk] of the simulation from the legend of dH/d[GRK]lambda[grk] ", -+ " and the foreign [GRK]lambda[grk] values from the legends of Delta H.[PAR]", -+ "The [GRK]lambda[grk] of the simulation is parsed from [TT]dhdl.xvg[tt] file's legend ", -+ "containing the string 'dH', the foreign [GRK]lambda[grk] values from the legend ", - "containing the capitalized letters 'D' and 'H'. The temperature ", - "is parsed from the legend line containing 'T ='.[PAR]", - -- "The input option [TT]-g[tt] expects multiple .edr files. ", -+ "The input option [TT]-g[tt] expects multiple [TT].edr[tt] files. ", - "These can contain either lists of energy differences (see the", -- "mdp option separate_dhdl_file), or a series of histograms", -- "(see the mdp options [TT]dh_hist_size[tt] and [TT]dh_hist_spacing[tt]).", -- "The temperature and lambda values are automatically deduced from", -- "the ener.edr file.[PAR]" -+ "[TT].mdp[tt] option [TT]separate_dhdl_file[tt]), or a series of histograms", -+ "(see the [TT].mdp[tt] options [TT]dh_hist_size[tt] and [TT]dh_hist_spacing[tt]).", -+ "The temperature and [GRK]lambda[grk] values are automatically deduced from", -+ "the [TT]ener.edr[tt] file.[PAR]" - - "The free energy estimates are determined using BAR with bisection, ", -- "the precision of the output is set with [TT]-prec[tt]. ", -+ "with the precision of the output set with [TT]-prec[tt]. ", - "An error estimate taking into account time correlations ", - "is made by splitting the data into blocks and determining ", - "the free energy differences over those blocks and assuming ", - "the blocks are independent. ", - "The final error estimate is determined from the average variance ", -- "over 5 blocks. A range of blocks numbers for error estimation can ", -+ "over 5 blocks. A range of block numbers for error estimation can ", - "be provided with the options [TT]-nbmin[tt] and [TT]-nbmax[tt].[PAR]", - - "[TT]g_bar[tt] tries to aggregate samples with the same 'native' and 'foreign'", -- "lambda values, but always assumes independent samples: note that", -+ "[GRK]lambda[grk] values, but always assumes independent samples. [BB]Note[bb] that", - "when aggregating energy differences/derivatives with different", -- "sampling intervals, this is almost certainly not correct: usually", -+ "sampling intervals, this is almost certainly not correct. Usually", - "subsequent energies are correlated and different time intervals mean", - "different degrees of correlation between samples.[PAR]", - -@@ -2539,8 +2544,8 @@ int gmx_bar(int argc,char *argv[]) - "difference estimates and phase space overlap measures in units of ", - "kT (together with their computed error estimate). The printed ", - "values are:[BR]", -- "[TT]*[tt] lam_A: the lambda values for point A.[BR]", -- "[TT]*[tt] lam_B: the lambda values for point B.[BR]", -+ "[TT]*[tt] lam_A: the [GRK]lambda[grk] values for point A.[BR]", -+ "[TT]*[tt] lam_B: the [GRK]lambda[grk] values for point B.[BR]", - "[TT]*[tt] DG: the free energy estimate.[BR]", - "[TT]*[tt] s_A: an estimate of the relative entropy of B in A.[BR]", - "[TT]*[tt] s_A: an estimate of the relative entropy of A in B.[BR]", -diff --git a/src/tools/gmx_bundle.c b/src/tools/gmx_bundle.c -index 06810d8..a0a002c 100644 ---- a/src/tools/gmx_bundle.c -+++ b/src/tools/gmx_bundle.c -@@ -185,7 +185,7 @@ int gmx_bundle(int argc,char *argv[]) - "With option [TT]-oa[tt] the top, mid (or kink when [TT]-ok[tt] is set)", - "and bottom points of each axis", - "are written to a [TT].pdb[tt] file each frame. The residue numbers correspond", -- "to the axis numbers. When viewing this file with [TT]rasmol[tt], use the", -+ "to the axis numbers. When viewing this file with Rasmol, use the", - "command line option [TT]-nmrpdb[tt], and type [TT]set axis true[tt] to", - "display the reference axis." - }; -@@ -195,7 +195,7 @@ int gmx_bundle(int argc,char *argv[]) - { "-na", FALSE, etINT, {&n}, - "Number of axes" }, - { "-z", FALSE, etBOOL, {&bZ}, -- "Use the Z-axis as reference iso the average axis" } -+ "Use the [IT]z[it]-axis as reference instead of the average axis" } - }; - FILE *out,*flen,*fdist,*fz,*ftilt,*ftiltr,*ftiltl; - FILE *fkink=NULL,*fkinkr=NULL,*fkinkl=NULL; -diff --git a/src/tools/gmx_chi.c b/src/tools/gmx_chi.c -index ca5873a..c3971e5 100644 ---- a/src/tools/gmx_chi.c -+++ b/src/tools/gmx_chi.c -@@ -1006,14 +1006,14 @@ static void order_params(FILE *log, - int gmx_chi(int argc,char *argv[]) - { - const char *desc[] = { -- "[TT]g_chi[tt] computes phi, psi, omega and chi dihedrals for all your ", -+ "[TT]g_chi[tt] computes [GRK]phi[grk], [GRK]psi[grk], [GRK]omega[grk], and [GRK]chi[grk] dihedrals for all your ", - "amino acid backbone and sidechains.", - "It can compute dihedral angle as a function of time, and as", - "histogram distributions.", - "The distributions [TT](histo-(dihedral)(RESIDUE).xvg[tt]) are cumulative over all residues of each type.[PAR]", - "If option [TT]-corr[tt] is given, the program will", - "calculate dihedral autocorrelation functions. The function used", -- "is C(t) = < cos(chi(tau)) cos(chi(tau+t)) >. The use of cosines", -+ "is C(t) = < cos([GRK]chi[grk]([GRK]tau[grk])) cos([GRK]chi[grk]([GRK]tau[grk]+t)) >. The use of cosines", - "rather than angles themselves, resolves the problem of periodicity.", - "(Van der Spoel & Berendsen (1997), Biophys. J. 72, 2032-2041).", - "Separate files for each dihedral of each residue", -@@ -1024,27 +1024,27 @@ int gmx_chi(int argc,char *argv[]) - "These can be in radians or degrees.[PAR]", - "A log file (argument [TT]-g[tt]) is also written. This contains [BR]", - "(a) information about the number of residues of each type.[BR]", -- "(b) The NMR 3J coupling constants from the Karplus equation.[BR]", -+ "(b) The NMR ^3J coupling constants from the Karplus equation.[BR]", - "(c) a table for each residue of the number of transitions between ", -- "rotamers per nanosecond, and the order parameter S2 of each dihedral.[BR]", -- "(d) a table for each residue of the rotamer occupancy.[BR]", -- "All rotamers are taken as 3-fold, except for omegas and chi-dihedrals", -- "to planar groups (i.e. chi2 of aromatics Asp and Asn, chi3 of Glu", -- "and Gln, and chi4 of Arg), which are 2-fold. \"rotamer 0\" means ", -+ "rotamers per nanosecond, and the order parameter S^2 of each dihedral.[BR]", -+ "(d) a table for each residue of the rotamer occupancy.[PAR]", -+ "All rotamers are taken as 3-fold, except for [GRK]omega[grk] and [GRK]chi[grk] dihedrals", -+ "to planar groups (i.e. [GRK]chi[grk]2 of aromatics, Asp and Asn; [GRK]chi[grk]3 of Glu", -+ "and Gln; and [GRK]chi[grk]4 of Arg), which are 2-fold. \"rotamer 0\" means ", - "that the dihedral was not in the core region of each rotamer. ", - "The width of the core region can be set with [TT]-core_rotamer[tt][PAR]", - -- "The S2 order parameters are also output to an [TT].xvg[tt] file", -+ "The S^2 order parameters are also output to an [TT].xvg[tt] file", - "(argument [TT]-o[tt] ) and optionally as a [TT].pdb[tt] file with", -- "the S2 values as B-factor (argument [TT]-p[tt]). ", -+ "the S^2 values as B-factor (argument [TT]-p[tt]). ", - "The total number of rotamer transitions per timestep", - "(argument [TT]-ot[tt]), the number of transitions per rotamer", -- "(argument [TT]-rt[tt]), and the 3J couplings (argument [TT]-jc[tt]), ", -+ "(argument [TT]-rt[tt]), and the ^3J couplings (argument [TT]-jc[tt]), ", - "can also be written to [TT].xvg[tt] files.[PAR]", - -- "If [TT]-chi_prod[tt] is set (and maxchi > 0), cumulative rotamers, e.g.", -- "1+9(chi1-1)+3(chi2-1)+(chi3-1) (if the residue has three 3-fold ", -- "dihedrals and maxchi >= 3)", -+ "If [TT]-chi_prod[tt] is set (and [TT]-maxchi[tt] > 0), cumulative rotamers, e.g.", -+ "1+9([GRK]chi[grk]1-1)+3([GRK]chi[grk]2-1)+([GRK]chi[grk]3-1) (if the residue has three 3-fold ", -+ "dihedrals and [TT]-maxchi[tt] >= 3)", - "are calculated. As before, if any dihedral is not in the core region,", - "the rotamer is taken to be 0. The occupancies of these cumulative ", - "rotamers (starting with rotamer 0) are written to the file", -@@ -1053,17 +1053,17 @@ int gmx_chi(int argc,char *argv[]) - "are written to [TT]chiproduct(RESIDUE)(nresnr).xvg[tt] ", - "and their occupancies to [TT]histo-chiproduct(RESIDUE)(nresnr).xvg[tt].[PAR]", - -- "The option [TT]-r[tt] generates a contour plot of the average omega angle", -- "as a function of the phi and psi angles, that is, in a Ramachandran plot", -- "the average omega angle is plotted using color coding.", -+ "The option [TT]-r[tt] generates a contour plot of the average [GRK]omega[grk] angle", -+ "as a function of the [GRK]phi[grk] and [GRK]psi[grk] angles, that is, in a Ramachandran plot", -+ "the average [GRK]omega[grk] angle is plotted using color coding.", - - }; - - const char *bugs[] = { - "Produces MANY output files (up to about 4 times the number of residues in the protein, twice that if autocorrelation functions are calculated). Typically several hundred files are output.", -- "Phi and psi dihedrals are calculated in a non-standard way, using H-N-CA-C for phi instead of C(-)-N-CA-C, and N-CA-C-O for psi instead of N-CA-C-N(+). This causes (usually small) discrepancies with the output of other tools like [TT]g_rama[tt].", -+ "[GRK]phi[grk] and [GRK]psi[grk] dihedrals are calculated in a non-standard way, using H-N-CA-C for [GRK]phi[grk] instead of C(-)-N-CA-C, and N-CA-C-O for [GRK]psi[grk] instead of N-CA-C-N(+). This causes (usually small) discrepancies with the output of other tools like [TT]g_rama[tt].", - "[TT]-r0[tt] option does not work properly", -- "Rotamers with multiplicity 2 are printed in chi.log as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0" -+ "Rotamers with multiplicity 2 are printed in [TT]chi.log[tt] as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0" - }; - - /* defaults */ -@@ -1079,13 +1079,13 @@ int gmx_chi(int argc,char *argv[]) - { "-r0", FALSE, etINT, {&r0}, - "starting residue" }, - { "-phi", FALSE, etBOOL, {&bPhi}, -- "Output for Phi dihedral angles" }, -+ "Output for [GRK]phi[grk] dihedral angles" }, - { "-psi", FALSE, etBOOL, {&bPsi}, -- "Output for Psi dihedral angles" }, -+ "Output for [GRK]psi[grk] dihedral angles" }, - { "-omega",FALSE, etBOOL, {&bOmega}, -- "Output for Omega dihedrals (peptide bonds)" }, -+ "Output for [GRK]omega[grk] dihedrals (peptide bonds)" }, - { "-rama", FALSE, etBOOL, {&bRama}, -- "Generate Phi/Psi and Chi1/Chi2 ramachandran plots" }, -+ "Generate [GRK]phi[grk]/[GRK]psi[grk] and [GRK]chi[grk]1/[GRK]chi[grk]2 Ramachandran plots" }, - { "-viol", FALSE, etBOOL, {&bViol}, - "Write a file that gives 0 or 1 for violated Ramachandran angles" }, - { "-periodic", FALSE, etBOOL, {&bPBC}, -@@ -1095,13 +1095,13 @@ int gmx_chi(int argc,char *argv[]) - { "-rad", FALSE, etBOOL, {&bRAD}, - "in angle vs time files, use radians rather than degrees."}, - { "-shift", FALSE, etBOOL, {&bShift}, -- "Compute chemical shifts from Phi/Psi angles" }, -+ "Compute chemical shifts from [GRK]phi[grk]/[GRK]psi[grk] angles" }, - { "-binwidth", FALSE, etINT, {&ndeg}, - "bin width for histograms (degrees)" }, - { "-core_rotamer", FALSE, etREAL, {&core_frac}, - "only the central [TT]-core_rotamer[tt]*(360/multiplicity) belongs to each rotamer (the rest is assigned to rotamer 0)" }, - { "-maxchi", FALSE, etENUM, {maxchistr}, -- "calculate first ndih Chi dihedrals" }, -+ "calculate first ndih [GRK]chi[grk] dihedrals" }, - { "-normhisto", FALSE, etBOOL, {&bNormHisto}, - "Normalize histograms" }, - { "-ramomega",FALSE,etBOOL, {&bRamOmega}, -diff --git a/src/tools/gmx_cluster.c b/src/tools/gmx_cluster.c -index 1717052..c7652ef 100644 ---- a/src/tools/gmx_cluster.c -+++ b/src/tools/gmx_cluster.c -@@ -1256,9 +1256,10 @@ int gmx_cluster(int argc,char *argv[]) - for(i=0; i -+#endif -+#include -+#include "sysstuff.h" -+#include "string.h" -+#include "string2.h" -+#include "typedefs.h" -+#include "smalloc.h" -+#include "macros.h" -+#include "gstat.h" -+#include "vec.h" -+#include "xvgr.h" -+#include "pbc.h" -+#include "copyrite.h" -+#include "futil.h" -+#include "statutil.h" -+#include "index.h" -+#include "tpxio.h" -+#include "physics.h" -+#include "matio.h" -+#include "dens_filter.h" -+#include "binsearch.h" -+#include "powerspect.h" -+#include "gmx_ana.h" -+ -+#ifdef GMX_DOUBLE -+#define FLOOR(x) ((int) floor(x)) -+#else -+#define FLOOR(x) ((int) floorf(x)) -+#endif -+ -+enum {methSEL, methBISECT, methFUNCFIT, methNR}; -+ -+static void center_coords(t_atoms *atoms,matrix box,rvec x0[],int axis) -+{ -+ int i,m; -+ real tmass,mm; -+ rvec com,shift,box_center; -+ -+ tmass = 0; -+ clear_rvec(com); -+ for(i=0; (inr); i++) -+ { -+ mm = atoms->atom[i].m; -+ tmass += mm; -+ for(m=0; (mnr); i++) -+ rvec_dec(x0[i],shift); -+} -+ -+ -+static void density_in_time (const char *fn, atom_id **index ,int gnx[], int grpn, real bw, real bwz, int nsttblock, real *****Densdevel, int *xslices, int *yslices, int *zslices,int *tblock, t_topology *top, int ePBC, int axis,gmx_bool bCenter, gmx_bool bps1d, const output_env_t oenv) -+ -+{ -+/* -+ * *****Densdevel pointer to array of density values in slices and frame-blocks Densdevel[*nsttblock][*xslices][*yslices][*zslices] -+ * Densslice[x][y][z] -+ * nsttblock - nr of frames in each time-block -+ * bw widths of normal slices -+ * -+ * axis - axis direction (normal to slices) -+ * nndx - number ot atoms in **index -+ * grpn - group number in index -+ */ -+ t_trxstatus *status; -+ gmx_rmpbc_t gpbc=NULL; -+ matrix box; /* Box - 3x3 -each step*/ -+ rvec *x0; /* List of Coord without PBC*/ -+ int natoms,i,j,k,n, /* loop indices, checks etc*/ -+ ax1=0,ax2=0, /* tangent directions */ -+ framenr=0, /* frame number in trajectory*/ -+ slicex, slicey, slicez; /*slice # of x y z position */ -+ real ***Densslice; /* Density-slice in one frame*/ -+ real dscale; /*physical scaling factor*/ -+ real t,x,y,z; /* time and coordinates*/ -+ rvec bbww; -+ -+ *tblock=0;/* blocknr in block average - initialise to 0*/ -+ /* Axis: X=0, Y=1,Z=2 */ -+ switch(axis) -+ { -+ case 0: -+ ax1=YY; ax2=ZZ; /*Surface: YZ*/ -+ break; -+ case 1: -+ ax1=ZZ; ax2=XX; /* Surface : XZ*/ -+ break; -+ case 2: -+ ax1 = XX; ax2 = YY; /* Surface XY*/ -+ break; -+ default: -+ gmx_fatal(FARGS,"Invalid axes. Terminating\n"); -+ } -+ -+ if( (natoms= read_first_x(oenv,&status,fn,&t,&x0,box)==0)) -+ gmx_fatal(FARGS, "Could not read coordinates from file"); /* Open trajectory for read*/ -+ -+ -+ *zslices=1+FLOOR(box[axis][axis]/bwz); -+ *yslices=1+FLOOR(box[ax2][ax2]/bw); -+ *xslices=1+FLOOR(box[ax1][ax1]/bw); -+ if(bps1d) -+ { -+ if(*xslices<*yslices) *xslices=1; -+ else *yslices=1; -+ } -+ fprintf(stderr, -+ "\nDividing the box in %5d x %5d x %5d slices with binw %f along axis %d\n",*xslices,*yslices,*zslices,bw,axis ); -+ -+ -+ /****Start trajectory processing***/ -+ -+ /*Initialize Densdevel and PBC-remove*/ -+ gpbc=gmx_rmpbc_init(&top->idef,ePBC,top->atoms.nr,box); -+ -+ *Densdevel=NULL; -+ -+ do -+ { -+ bbww[XX] = box[ax1][ax1]/ *xslices; -+ bbww[YY] = box[ax2][ax2]/ *yslices; -+ bbww[ZZ] = box[axis][axis]/ *zslices; -+ gmx_rmpbc(gpbc,top->atoms.nr,box,x0); -+ /*Reset Densslice every nsttblock steps*/ -+ if ( framenr % nsttblock==0 ) -+ { -+ snew(Densslice,*xslices); -+ for (i=0;i<*xslices;i++) -+ { -+ snew(Densslice[i],*yslices); -+ for (j=0;j<*yslices;j++) -+ { -+ snew(Densslice[i][j],*zslices); -+ } -+ } -+ -+ /*Allocate Memory to extra frame in Densdevel - rather stupid approach: *A single frame each time, although only every nsttblock steps.*/ -+ srenew(*Densdevel,*tblock+1); -+ -+ } -+ -+ -+ dscale=(*xslices)*(*yslices)*(*zslices)*AMU/ (box[ax1][ax1]*box[ax2][ax2]*box[axis][axis]*nsttblock*(NANO*NANO*NANO)); -+ -+ if (bCenter) -+ center_coords(&top->atoms,box,x0,axis); -+ -+ -+ for (j=0;jbox[ax1][ax1]) -+ x-=box[ax1][ax1]; -+ -+ while (y<0) -+ y+=box[ax2][ax2]; -+ while(y>box[ax2][ax2]) -+ y-=box[ax2][ax2]; -+ -+ while (z<0) -+ z+=box[axis][axis]; -+ while(z>box[axis][axis]) -+ z-=box[axis][axis]; -+ -+ slicex=((int) (x/bbww[XX])) % *xslices; -+ slicey=((int) (y/bbww[YY])) % *yslices; -+ slicez=((int) (z/bbww[ZZ])) % *zslices; -+ Densslice[slicex][slicey][slicez]+=(top->atoms.atom[index[0][j]].m*dscale); -+ -+ -+ } -+ -+ framenr++; -+ -+ if(framenr % nsttblock == 0) -+ { -+ /*Implicit incrementation of Densdevel via renewal of Densslice*/ -+ /*only every nsttblock steps*/ -+ (*Densdevel)[*tblock]=Densslice; -+ (*tblock)++; -+ } -+ -+ } while(read_next_x(oenv,status,&t,natoms,x0,box)); -+ -+ -+ /*Free memory we no longer need and exit.*/ -+ gmx_rmpbc_done(gpbc); -+ close_trj(status); -+ -+ if (0) -+ { -+ FILE *fp; -+ fp = fopen("koko.xvg","w"); -+ for(j=0; (j<*zslices); j++) -+ { -+ fprintf(fp,"%5d",j); -+ for(i=0; (i<*tblock); i++) -+ { -+ fprintf(fp," %10g",(*Densdevel)[i][9][1][j]); -+ } -+ fprintf(fp,"\n"); -+ } -+ fclose(fp); -+ } -+ -+} -+ -+ -+ -+static void printdensavg(char *fldfn, real ****Densmap, int xslices, int yslices, int zslices, int tdim) -+{ -+/*Debug-filename and filehandle*/ -+ FILE *fldH; -+ int n,i,j,k; -+ real totdens=0; -+ fldH=ffopen(fldfn,"w"); -+ fprintf(fldH,"%i %i %i %i\n",tdim, xslices,yslices,zslices); -+ for(n=0;n1.0 || abs(deltandx)>3){ -+ pos=zperm[ndx1]; -+ spread=-1; -+ } -+ else { -+ pos=zperm[ndx1]+alpha*deltandx; -+ spread=binwidth*deltandx; -+ } -+ * For the 2nd interface can use the same formulation, since alpha should become negative ie: -+ * alpha=(densmid-Densmap[n][i][j][zperm[ndx2]])/(Densmap[n][i][j][zperm[nxd2+1]]-Densmap[n][i][j][zperm[ndx2]]); -+ * deltandx=zperm[ndx2+1]-zperm[ndx2]; -+ * pos=zperm[ndx2]+alpha*deltandx; */ -+ -+ /*After filtering we use the direct approach */ -+ int1[n][j+(i*yslices)]->Z=(zperm[ndx1]+onehalf)*binwidth; -+ int1[n][j+(i*yslices)]->t=binwidth; -+ int2[n][j+(i*yslices)]->Z=(zperm[ndx2]+onehalf)*binwidth; -+ int2[n][j+(i*yslices)]->t=binwidth; -+ } -+ } -+ } -+ } -+ -+ if(method==methFUNCFIT) -+ { -+ /*Assume a box divided in 2 along midpoint of z for starters*/ -+ startpoint=0.0; -+ endpoint = binwidth*zslices; -+ splitpoint = (startpoint+endpoint)/2.0; -+ /*Initial fit proposals*/ -+ beginfit1[0] = dens1; -+ beginfit1[1] = dens2; -+ beginfit1[2] = (splitpoint/2); -+ beginfit1[3] = 0.5; -+ -+ beginfit2[0] = dens2; -+ beginfit2[1] = dens1; -+ beginfit2[2] = (3*splitpoint/2); -+ beginfit2[3] = 0.5; -+ -+ snew(zDensavg,zslices); -+ snew(sigma1,zslices); -+ snew(sigma2,zslices); -+ -+ for(k=0;kZ=fit1[2]; -+ int1[n][j+(yslices*i)]->t=fit1[3]; -+ do_lmfit(zslices,Densmap[n][i][j],sigma2,binwidth,NULL,splitpoint,endpoint,oenv,FALSE,effnERF,fit2,2); -+ int2[n][j+(yslices*i)]->Z=fit2[2]; -+ int2[n][j+(yslices*i)]->t=fit2[3]; -+ } -+ } -+ } -+ } -+ -+ -+ *intf1=int1; -+ *intf2=int2; -+ -+} -+ -+static void writesurftoxpms(t_interf ***surf1,t_interf ***surf2, int tblocks,int xbins, int ybins, int zbins, real bw,real bwz, char **outfiles,int maplevels ) -+{ -+ char numbuf[12]; -+ int n, i, j; -+ real **profile1, **profile2; -+ real max1, max2, min1, min2, *xticks, *yticks; -+ t_rgb lo={0,0,0}; -+ t_rgb hi={1,1,1}; -+ FILE *xpmfile1, *xpmfile2; -+ -+/*Prepare xpm structures for output*/ -+ -+/*Allocate memory to tick's and matrices*/ -+ snew (xticks,xbins+1); -+ snew (yticks,ybins+1); -+ -+ profile1=mk_matrix(xbins,ybins,FALSE); -+ profile2=mk_matrix(xbins,ybins,FALSE); -+ -+ for (i=0;iZ; -+ profile2[i][j]=(surf2[n][j+ybins*i])->Z; -+ /*Finding max and min values*/ -+ if(profile1[i][j]>max1) max1=profile1[i][j]; -+ if(profile1[i][j]max2) max2=profile2[i][j]; -+ if(profile2[i][j]Z,(int1[n][j+ybins*i])->t); -+ fprintf(raw2,"%i %i %8.5f %6.4f\n",i,j,(int2[n][j+ybins*i])->Z,(int2[n][j+ybins*i])->t); -+ } -+ } -+ } -+ -+ ffclose(raw1); -+ ffclose(raw2); -+} -+ -+ -+ -+int gmx_densorder(int argc,char *argv[]) -+{ -+ static const char *desc[] = { -+ "A small program to reduce a two-phase density distribution", -+ "along an axis, computed over a MD trajectory", -+ "to 2D surfaces fluctuating in time, by a fit to", -+ "a functional profile for interfacial densities", -+ "A time-averaged spatial representation of the" , -+ "interfaces can be output with the option -tavg" -+ }; -+ -+ /* Extra arguments - but note how you always get the begin/end -+ * options when running the program, without mentioning them here! -+ */ -+ -+ output_env_t oenv; -+ t_topology *top; -+ char title[STRLEN],**grpname; -+ int ePBC, *ngx; -+ static real binw=0.2; -+ static real binwz=0.05; -+ static real dens1=0.00; -+ static real dens2=1000.00; -+ static int ftorder=0; -+ static int nsttblock=100; -+ static int axis= 2; -+ static char *axtitle="Z"; -+ static int ngrps=1; -+ atom_id **index; /* Index list for single group*/ -+ int xslices, yslices, zslices, tblock; -+ static gmx_bool bGraph=FALSE; -+ static gmx_bool bCenter = FALSE; -+ static gmx_bool bFourier=FALSE; -+ static gmx_bool bRawOut=FALSE; -+ static gmx_bool bOut=FALSE; -+ static gmx_bool b1d=FALSE; -+ static int nlevels=100; -+ /*Densitymap - Densmap[t][x][y][z]*/ -+ real ****Densmap=NULL; -+ /* Surfaces surf[t][surf_x,surf_y]*/ -+ t_interf ***surf1, ***surf2; -+ -+ static const char *meth[]={NULL,"bisect","functional",NULL}; -+ int eMeth; -+ -+ char **graphfiles, **rawfiles, **spectra; /* Filenames for xpm-surface maps, rawdata and powerspectra */ -+ int nfxpm,nfraw, nfspect; /* # files for interface maps and spectra = # interfaces */ -+ -+ t_pargs pa[] = { -+ { "-1d", FALSE, etBOOL, {&b1d}, -+ "Pseudo-1d interface geometry"}, -+ { "-bw",FALSE,etREAL,{&binw}, -+ "Binwidth of density distribution tangential to interface"}, -+ { "-bwn", FALSE, etREAL, {&binwz}, -+ "Binwidth of density distribution normal to interface"}, -+ { "-order", FALSE, etINT,{&ftorder}, -+ "Order of Gaussian filter, order 0 equates to NO filtering"}, -+ {"-axis", FALSE, etSTR,{&axtitle}, -+ "Axis Direction - X, Y or Z"}, -+ {"-method",FALSE ,etENUM,{meth}, -+ "Interface location method"}, -+ {"-d1", FALSE, etREAL,{&dens1}, -+ "Bulk density phase 1 (at small z)"}, -+ {"-d2", FALSE, etREAL,{&dens2}, -+ "Bulk density phase 2 (at large z)"}, -+ { "-tblock",FALSE,etINT,{&nsttblock}, -+ "Number of frames in one time-block average"}, -+ { "-nlevel", FALSE,etINT, {&nlevels}, -+ "Number of Height levels in 2D - XPixMaps"} -+ }; -+ -+ -+ t_filenm fnm[] = { -+ { efTPX, "-s", NULL, ffREAD }, /* this is for the topology */ -+ { efTRX, "-f", NULL, ffREAD }, /* and this for the trajectory */ -+ { efNDX, "-n", NULL, ffREAD}, /* this is to select groups */ -+ { efDAT, "-o", "Density4D",ffOPTWR}, /* This is for outputting the entire 4D densityfield in binary format */ -+ { efOUT, "-or", NULL,ffOPTWRMULT}, /* This is for writing out the entire information in the t_interf arrays */ -+ { efXPM, "-og" ,"interface",ffOPTWRMULT},/* This is for writing out the interface meshes - one xpm-file per tblock*/ -+ { efOUT, "-Spect","intfspect",ffOPTWRMULT}, /* This is for the trajectory averaged Fourier-spectra*/ -+ }; -+ -+#define NFILE asize(fnm) -+ -+ CopyRight(stderr,argv[0]); -+ -+ /* This is the routine responsible for adding default options, -+ * calling the X/motif interface, etc. */ -+ parse_common_args(&argc,argv,PCA_CAN_TIME | PCA_CAN_VIEW, -+ NFILE,fnm,asize(pa),pa,asize(desc),desc,0,NULL,&oenv); -+ -+ -+ eMeth=nenum(meth); -+ bFourier=opt2bSet("-Spect",NFILE,fnm); -+ bRawOut=opt2bSet("-or",NFILE,fnm); -+ bGraph=opt2bSet("-og",NFILE,fnm); -+ bOut=opt2bSet("-o",NFILE,fnm); -+ top=read_top(ftp2fn(efTPX,NFILE,fnm),&ePBC); -+ snew(grpname,ngrps); -+ snew(index,ngrps); -+ snew(ngx,ngrps); -+ -+/* Calculate axis */ -+ axis = toupper(axtitle[0]) - 'X'; -+ -+ get_index(&top->atoms,ftp2fn_null(efNDX,NFILE,fnm),ngrps,ngx,index,grpname); -+ -+ density_in_time(ftp2fn(efTRX,NFILE,fnm),index,ngx,ngrps,binw,binwz,nsttblock,&Densmap,&xslices,&yslices,&zslices,&tblock,top,ePBC,axis,bCenter,b1d,oenv); -+ -+ if(ftorder>0) -+ { -+ filterdensmap(Densmap,xslices,yslices,zslices,tblock,2*ftorder+1); -+ } -+ -+ if (bOut) -+ { -+ outputfield(opt2fn("-o",NFILE,fnm),Densmap,xslices,yslices,zslices,tblock); -+ } -+ -+ interfaces_txy(Densmap,xslices,yslices,zslices,tblock,binwz,eMeth,dens1,dens2,&surf1,&surf2,oenv); -+ -+ if(bGraph) -+ { -+ -+ /*Output surface-xpms*/ -+ nfxpm=opt2fns(&graphfiles,"-og",NFILE,fnm); -+ if(nfxpm!=2) -+ { -+ gmx_fatal(FARGS,"No or not correct number (2) of output-files: %d",nfxpm); -+ } -+ writesurftoxpms(surf1, surf2, tblock,xslices,yslices,zslices,binw,binwz,graphfiles,zslices); -+ } -+ -+ -+ -+ -+ -+/*Output raw-data*/ -+ if (bRawOut) -+ { -+ nfraw=opt2fns(&rawfiles,"-or",NFILE,fnm); -+ if(nfraw!=2) -+ { -+ gmx_fatal(FARGS,"No or not correct number (2) of output-files: %d",nfxpm); -+ } -+ writeraw(surf1,surf2,tblock,xslices,yslices,rawfiles); -+ } -+ -+ -+ -+ if(bFourier) -+ { -+ nfspect=opt2fns(&spectra,"-Spect",NFILE,fnm); -+ if(nfspect!=2) -+ { -+ gmx_fatal(FARGS,"No or not correct number (2) of output-file-series: %d" -+ ,nfspect); -+ } -+ powerspectavg_intf(surf1, surf2, tblock,xslices,yslices,spectra); -+ } -+ -+ sfree(Densmap); -+ if(bGraph || bFourier || bRawOut) -+ { -+ sfree(surf1); -+ sfree(surf2); -+ } -+ -+ thanx(stderr); -+ return 0; -+} -diff --git a/src/tools/gmx_dielectric.c b/src/tools/gmx_dielectric.c -index 897155e..17e0ae3 100644 ---- a/src/tools/gmx_dielectric.c -+++ b/src/tools/gmx_dielectric.c -@@ -239,9 +239,9 @@ int gmx_dielectric(int argc,char *argv[]) - { "-fft", FALSE, etBOOL, {&bFour}, - "use fast fourier transform for correlation function" }, - { "-x1", FALSE, etBOOL, {&bX}, -- "use first column as X axis rather than first data set" }, -+ "use first column as [IT]x[it]-axis rather than first data set" }, - { "-eint", FALSE, etREAL, {&tendInt}, -- "Time were to end the integration of the data and start to use the fit"}, -+ "Time to end the integration of the data and start to use the fit"}, - { "-bfit", FALSE, etREAL, {&tbegin}, - "Begin time of fit" }, - { "-efit", FALSE, etREAL, {&tend}, -@@ -251,13 +251,13 @@ int gmx_dielectric(int argc,char *argv[]) - { "-A", FALSE, etREAL, {&A}, - "Start value for fit parameter A" }, - { "-tau1", FALSE, etREAL, {&tau1}, -- "Start value for fit parameter tau1" }, -+ "Start value for fit parameter [GRK]tau[grk]1" }, - { "-tau2", FALSE, etREAL, {&tau2}, -- "Start value for fit parameter tau2" }, -+ "Start value for fit parameter [GRK]tau[grk]2" }, - { "-eps0", FALSE, etREAL, {&eps0}, -- "Epsilon 0 of your liquid" }, -+ "[GRK]epsilon[grk]0 of your liquid" }, - { "-epsRF", FALSE, etREAL, {&epsRF}, -- "Epsilon of the reaction field used in your simulation. A value of 0 means infinity." }, -+ "[GRK]epsilon[grk] of the reaction field used in your simulation. A value of 0 means infinity." }, - { "-fix", FALSE, etINT, {&fix}, - "Fix parameters at their start values, A (2), tau1 (1), or tau2 (4)" }, - { "-ffn", FALSE, etENUM, {s_ffn}, -diff --git a/src/tools/gmx_dipoles.c b/src/tools/gmx_dipoles.c -index 11f9aba..a7d0bbd 100644 ---- a/src/tools/gmx_dipoles.c -+++ b/src/tools/gmx_dipoles.c -@@ -1268,7 +1268,7 @@ int gmx_dipoles(int argc,char *argv[]) - const char *desc[] = { - "[TT]g_dipoles[tt] computes the total dipole plus fluctuations of a simulation", - "system. From this you can compute e.g. the dielectric constant for", -- "low dielectric media.", -+ "low-dielectric media.", - "For molecules with a net charge, the net charge is subtracted at", - "center of mass of the molecule.[PAR]", - "The file [TT]Mtot.xvg[tt] contains the total dipole moment of a frame, the", -@@ -1277,8 +1277,8 @@ int gmx_dipoles(int argc,char *argv[]) - "simulation.", - "The file [TT]dipdist.xvg[tt] contains the distribution of dipole moments during", - "the simulation", -- "The mu_max is used as the highest value in the distribution graph.[PAR]", -- "Furthermore the dipole autocorrelation function will be computed when", -+ "The value of [TT]-mumax[tt] is used as the highest value in the distribution graph.[PAR]", -+ "Furthermore, the dipole autocorrelation function will be computed when", - "option [TT]-corr[tt] is used. The output file name is given with the [TT]-c[tt]", - "option.", - "The correlation functions can be averaged over all molecules", -@@ -1288,7 +1288,7 @@ int gmx_dipoles(int argc,char *argv[]) - "Option [TT]-g[tt] produces a plot of the distance dependent Kirkwood", - "G-factor, as well as the average cosine of the angle between the dipoles", - "as a function of the distance. The plot also includes gOO and hOO", -- "according to Nymand & Linse, JCP 112 (2000) pp 6386-6395. In the same plot", -+ "according to Nymand & Linse, J. Chem. Phys. 112 (2000) pp 6386-6395. In the same plot, ", - "we also include the energy per scale computed by taking the inner product of", - "the dipoles divided by the distance to the third power.[PAR]", - "[PAR]", -@@ -1297,8 +1297,8 @@ int gmx_dipoles(int argc,char *argv[]) - "This will calculate the autocorrelation function of the molecular", - "dipoles using a first order Legendre polynomial of the angle of the", - "dipole vector and itself a time t later. For this calculation 1001", -- "frames will be used. Further the dielectric constant will be calculated", -- "using an epsilonRF of infinity (default), temperature of 300 K (default) and", -+ "frames will be used. Further, the dielectric constant will be calculated", -+ "using an [GRK]epsilon[grk]RF of infinity (default), temperature of 300 K (default) and", - "an average dipole moment of the molecule of 2.273 (SPC). For the", - "distribution function a maximum of 5.0 will be used." - }; -@@ -1325,7 +1325,7 @@ int gmx_dipoles(int argc,char *argv[]) - { "-corr", FALSE, etENUM, {corrtype}, - "Correlation function to calculate" }, - { "-pairs", FALSE, etBOOL, {&bPairs}, -- "Calculate |cos theta| between all pairs of molecules. May be slow" }, -+ "Calculate |cos [GRK]theta[grk]| between all pairs of molecules. May be slow" }, - { "-ncos", FALSE, etINT, {&ncos}, - "Must be 1 or 2. Determines whether the is computed between all molecules in one group, or between molecules in two different groups. This turns on the [TT]-gkr[tt] flag." }, - { "-axis", FALSE, etSTR, {&axtitle}, -@@ -1337,13 +1337,13 @@ int gmx_dipoles(int argc,char *argv[]) - { "-gkratom2", FALSE, etINT, {&nFB}, - "Same as previous option in case ncos = 2, i.e. dipole interaction between two groups of molecules" }, - { "-rcmax", FALSE, etREAL, {&rcmax}, -- "Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterium based on the box length will be used." }, -+ "Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterion based on the box length will be used." }, - { "-phi", FALSE, etBOOL, {&bPhi}, - "Plot the 'torsion angle' defined as the rotation of the two dipole vectors around the distance vector between the two molecules in the [TT].xpm[tt] file from the [TT]-cmap[tt] option. By default the cosine of the angle between the dipoles is plotted." }, - { "-nlevels", FALSE, etINT, {&nlevels}, - "Number of colors in the cmap output" }, - { "-ndegrees", FALSE, etINT, {&ndegrees}, -- "Number of divisions on the y-axis in the camp output (for 180 degrees)" } -+ "Number of divisions on the [IT]y[it]-axis in the cmap output (for 180 degrees)" } - }; - int *gnx; - int nFF[2]; -diff --git a/src/tools/gmx_dist.c b/src/tools/gmx_dist.c -index 99a9c59..eef0c91 100644 ---- a/src/tools/gmx_dist.c -+++ b/src/tools/gmx_dist.c -@@ -71,7 +71,7 @@ int gmx_dist(int argc,char *argv[]) - const char *desc[] = { - "[TT]g_dist[tt] can calculate the distance between the centers of mass of two", - "groups of atoms as a function of time. The total distance and its", -- "x, y and z components are plotted.[PAR]", -+ "[IT]x[it]-, [IT]y[it]-, and [IT]z[it]-components are plotted.[PAR]", - "Or when [TT]-dist[tt] is set, print all the atoms in group 2 that are", - "closer than a certain distance to the center of mass of group 1.[PAR]", - "With options [TT]-lt[tt] and [TT]-dist[tt] the number of contacts", -diff --git a/src/tools/gmx_dyndom.c b/src/tools/gmx_dyndom.c -index e84b12b..235a026 100644 ---- a/src/tools/gmx_dyndom.c -+++ b/src/tools/gmx_dyndom.c -@@ -131,7 +131,7 @@ int gmx_dyndom(int argc,char *argv[]) - "(http://www.cmp.uea.ac.uk/dyndom/).", - "It reads the coordinates, the coordinates of the rotation axis,", - "and an index file containing the domains.", -- "Furthermore it takes the first and last atom of the arrow file", -+ "Furthermore, it takes the first and last atom of the arrow file", - "as command line arguments (head and tail) and", - "finally it takes the translation vector (given in DynDom info file)", - "and the angle of rotation (also as command line arguments). If the angle", -@@ -161,7 +161,7 @@ int gmx_dyndom(int argc,char *argv[]) - { "-maxangle", FALSE, etREAL, {&maxangle}, - "DymDom dtermined angle of rotation about rotation vector" }, - { "-trans", FALSE, etREAL, {&trans0}, -- "Translation (Aangstroem) along rotation vector (see DynDom info file)" }, -+ "Translation (Angstrom) along rotation vector (see DynDom info file)" }, - { "-head", FALSE, etRVEC, {head}, - "First atom of the arrow vector" }, - { "-tail", FALSE, etRVEC, {tail}, -diff --git a/src/tools/gmx_editconf.c b/src/tools/gmx_editconf.c -index 89702eb..3662585 100644 ---- a/src/tools/gmx_editconf.c -+++ b/src/tools/gmx_editconf.c -@@ -485,20 +485,21 @@ int gmx_editconf(int argc, char *argv[]) - "The last two are special cases of a triclinic box.", - "The length of the three box vectors of the truncated octahedron is the", - "shortest distance between two opposite hexagons.", -- "The volume of a dodecahedron is 0.71 and that of a truncated octahedron", -- "is 0.77 of that of a cubic box with the same periodic image distance.", -+ "Relative to a cubic box with some periodic image distance, the volume of a ", -+ "dodecahedron with this same periodic distance is 0.71 times that of the cube, ", -+ "and that of a truncated octahedron is 0.77 times.", - "[PAR]", - "Option [TT]-box[tt] requires only", -- "one value for a cubic box, dodecahedron and a truncated octahedron.", -+ "one value for a cubic, rhombic dodecahedral, or truncated octahedral box.", - "[PAR]", -- "With [TT]-d[tt] and a [TT]triclinic[tt] box the size of the system in the x, y", -- "and z directions is used. With [TT]-d[tt] and [TT]cubic[tt],", -+ "With [TT]-d[tt] and a [TT]triclinic[tt] box the size of the system in the [IT]x[it]-, [IT]y[it]-,", -+ "and [IT]z[it]-directions is used. With [TT]-d[tt] and [TT]cubic[tt],", - "[TT]dodecahedron[tt] or [TT]octahedron[tt] boxes, the dimensions are set", - "to the diameter of the system (largest distance between atoms) plus twice", - "the specified distance.", - "[PAR]", - "Option [TT]-angles[tt] is only meaningful with option [TT]-box[tt] and", -- "a triclinic box and can not be used with option [TT]-d[tt].", -+ "a triclinic box and cannot be used with option [TT]-d[tt].", - "[PAR]", - "When [TT]-n[tt] or [TT]-ndef[tt] is set, a group", - "can be selected for calculating the size and the geometric center,", -@@ -507,14 +508,14 @@ int gmx_editconf(int argc, char *argv[]) - "[TT]-rotate[tt] rotates the coordinates and velocities.", - "[PAR]", - "[TT]-princ[tt] aligns the principal axes of the system along the", -- "coordinate axes, with the longest axis aligned with the x axis. ", -+ "coordinate axes, with the longest axis aligned with the [IT]x[it]-axis. ", - "This may allow you to decrease the box volume,", - "but beware that molecules can rotate significantly in a nanosecond.", - "[PAR]", - "Scaling is applied before any of the other operations are", - "performed. Boxes and coordinates can be scaled to give a certain density (option", -- "[TT]-density[tt]). Note that this may be inaccurate in case a gro", -- "file is given as input. A special feature of the scaling option, when the", -+ "[TT]-density[tt]). Note that this may be inaccurate in case a [TT].gro[tt]", -+ "file is given as input. A special feature of the scaling option is that when the", - "factor -1 is given in one dimension, one obtains a mirror image,", - "mirrored in one of the planes. When one uses -1 in three dimensions, ", - "a point-mirror image is obtained.[PAR]", -@@ -548,8 +549,8 @@ int gmx_editconf(int argc, char *argv[]) - "of the principal axis of a specified group against the given vector, ", - "with an optional center of rotation specified by [TT]-aligncenter[tt].", - "[PAR]", -- "Finally with option [TT]-label[tt], [TT]editconf[tt] can add a chain identifier", -- "to a [TT].pdb[tt] file, which can be useful for analysis with e.g. rasmol.", -+ "Finally, with option [TT]-label[tt], [TT]editconf[tt] can add a chain identifier", -+ "to a [TT].pdb[tt] file, which can be useful for analysis with e.g. Rasmol.", - "[PAR]", - "To convert a truncated octrahedron file produced by a package which uses", - "a cubic box with the corners cut off (such as GROMOS), use:[BR]", -diff --git a/src/tools/gmx_eneconv.c b/src/tools/gmx_eneconv.c -index 540ef48..0d0edab 100644 ---- a/src/tools/gmx_eneconv.c -+++ b/src/tools/gmx_eneconv.c -@@ -463,11 +463,11 @@ int gmx_eneconv(int argc,char *argv[]) - const char *desc[] = { - "With [IT]multiple files[it] specified for the [TT]-f[tt] option:[BR]", - "Concatenates several energy files in sorted order.", -- "In case of double time frames the one", -+ "In the case of double time frames, the one", - "in the later file is used. By specifying [TT]-settime[tt] you will be", - "asked for the start time of each file. The input files are taken", - "from the command line,", -- "such that the command [TT]eneconv -o fixed.edr *.edr[tt] should do", -+ "such that the command [TT]eneconv -f *.edr -o fixed.edr[tt] should do", - "the trick. [PAR]", - "With [IT]one file[it] specified for [TT]-f[tt]:[BR]", - "Reads one energy file and writes another, applying the [TT]-dt[tt],", -diff --git a/src/tools/gmx_enemat.c b/src/tools/gmx_enemat.c -index e4a4bfe..480e4de 100644 ---- a/src/tools/gmx_enemat.c -+++ b/src/tools/gmx_enemat.c -@@ -79,7 +79,7 @@ int gmx_enemat(int argc,char *argv[]) - "line a group of atoms to be used. For these groups matrix of", - "interaction energies will be extracted from the energy file", - "by looking for energy groups with names corresponding to pairs", -- "of groups of atoms. E.g. if your [TT]-groups[tt] file contains:[BR]", -+ "of groups of atoms, e.g. if your [TT]-groups[tt] file contains:[BR]", - "[TT]2[tt][BR]", - "[TT]Protein[tt][BR]", - "[TT]SOL[tt][BR]", -diff --git a/src/tools/gmx_energy.c b/src/tools/gmx_energy.c -index deaf1a3..f78590f 100644 ---- a/src/tools/gmx_energy.c -+++ b/src/tools/gmx_energy.c -@@ -1480,21 +1480,21 @@ int gmx_energy(int argc,char *argv[]) - - "[TT]g_energy[tt] extracts energy components or distance restraint", - "data from an energy file. The user is prompted to interactively", -- "select the energy terms she wants.[PAR]", -+ "select the desired energy terms.[PAR]", - -- "Average, RMSD and drift are calculated with full precision from the", -+ "Average, RMSD, and drift are calculated with full precision from the", - "simulation (see printed manual). Drift is calculated by performing", - "a least-squares fit of the data to a straight line. The reported total drift", - "is the difference of the fit at the first and last point.", - "An error estimate of the average is given based on a block averages", -- "over 5 blocks using the full precision averages. The error estimate", -+ "over 5 blocks using the full-precision averages. The error estimate", - "can be performed over multiple block lengths with the options", - "[TT]-nbmin[tt] and [TT]-nbmax[tt].", -- "Note that in most cases the energy files contains averages over all", -+ "[BB]Note[bb] that in most cases the energy files contains averages over all", - "MD steps, or over many more points than the number of frames in", - "energy file. This makes the [TT]g_energy[tt] statistics output more accurate", - "than the [TT].xvg[tt] output. When exact averages are not present in the energy", -- "file the statistics mentioned above are simply over the single, per-frame", -+ "file, the statistics mentioned above are simply over the single, per-frame", - "energy values.[PAR]", - - "The term fluctuation gives the RMSD around the least-squares fit.[PAR]", -@@ -1529,23 +1529,24 @@ int gmx_energy(int argc,char *argv[]) - - "With [TT]-fee[tt] an estimate is calculated for the free-energy", - "difference with an ideal gas state: [BR]", -- " Delta A = A(N,V,T) - A_idgas(N,V,T) = kT ln < e^(Upot/kT) >[BR]", -- " Delta G = G(N,p,T) - G_idgas(N,p,T) = kT ln < e^(Upot/kT) >[BR]", -+ " [GRK]Delta[grk] A = A(N,V,T) - A_idgas(N,V,T) = kT ln < e^(Upot/kT) >[BR]", -+ " [GRK]Delta[grk] G = G(N,p,T) - G_idgas(N,p,T) = kT ln < e^(Upot/kT) >[BR]", - "where k is Boltzmann's constant, T is set by [TT]-fetemp[tt] and", - "the average is over the ensemble (or time in a trajectory).", - "Note that this is in principle", - "only correct when averaging over the whole (Boltzmann) ensemble", - "and using the potential energy. This also allows for an entropy", - "estimate using:[BR]", -- " Delta S(N,V,T) = S(N,V,T) - S_idgas(N,V,T) = ( - Delta A)/T[BR]", -- " Delta S(N,p,T) = S(N,p,T) - S_idgas(N,p,T) = ( + pV - Delta G)/T", -+ " [GRK]Delta[grk] S(N,V,T) = S(N,V,T) - S_idgas(N,V,T) = ( - [GRK]Delta[grk] A)/T[BR]", -+ " [GRK]Delta[grk] S(N,p,T) = S(N,p,T) - S_idgas(N,p,T) = ( + pV - [GRK]Delta[grk] G)/T", - "[PAR]", - - "When a second energy file is specified ([TT]-f2[tt]), a free energy", - "difference is calculated dF = -kT ln < e ^ -(EB-EA)/kT >A ,", - "where EA and EB are the energies from the first and second energy", -- "files, and the average is over the ensemble A. [BB]NOTE[bb] that", -- "the energies must both be calculated from the same trajectory." -+ "files, and the average is over the ensemble A. The running average", -+ "of the free energy difference is printed to a file specified by [TT]-ravg[tt].", -+ "[BB]Note[bb] that the energies must both be calculated from the same trajectory." - - }; - static gmx_bool bSum=FALSE,bFee=FALSE,bPrAll=FALSE,bFluct=FALSE; -diff --git a/src/tools/gmx_filter.c b/src/tools/gmx_filter.c -index 95646e9..ba2e4d5 100644 ---- a/src/tools/gmx_filter.c -+++ b/src/tools/gmx_filter.c -@@ -58,14 +58,14 @@ int gmx_filter(int argc,char *argv[]) - { - const char *desc[] = { - "[TT]g_filter[tt] performs frequency filtering on a trajectory.", -- "The filter shape is cos(pi t/A) + 1 from -A to +A, where A is given", -+ "The filter shape is cos([GRK]pi[grk] t/A) + 1 from -A to +A, where A is given", - "by the option [TT]-nf[tt] times the time step in the input trajectory.", - "This filter reduces fluctuations with period A by 85%, with period", - "2*A by 50% and with period 3*A by 17% for low-pass filtering.", - "Both a low-pass and high-pass filtered trajectory can be written.[PAR]", - - "Option [TT]-ol[tt] writes a low-pass filtered trajectory.", -- "A frame is written every [TT]nf[tt] input frames.", -+ "A frame is written every [TT]-nf[tt] input frames.", - "This ratio of filter length and output interval ensures a good", - "suppression of aliasing of high-frequency motion, which is useful for", - "making smooth movies. Also averages of properties which are linear", -diff --git a/src/tools/gmx_genbox.c b/src/tools/gmx_genbox.c -index 223a63f..61bf59f 100644 ---- a/src/tools/gmx_genbox.c -+++ b/src/tools/gmx_genbox.c -@@ -87,7 +87,8 @@ static gmx_bool in_box(t_pbc *pbc,rvec x) - rvec box_center,dx; - int shift; - -- calc_box_center(ecenterTRIC,pbc->box,box_center); -+ /* pbc_dx_aiuc only works correctly with the rectangular box center */ -+ calc_box_center(ecenterRECT,pbc->box,box_center); - - shift = pbc_dx_aiuc(pbc,x,box_center,dx); - -@@ -627,8 +628,8 @@ int gmx_genbox(int argc,char *argv[]) - "The program iterates until [TT]nmol[tt] molecules", - "have been inserted in the box. To test whether an insertion is ", - "successful the same van der Waals criterium is used as for removal of ", -- "solvent molecules. When no appropriately ", -- "sized holes (holes that can hold an extra molecule) are available the ", -+ "solvent molecules. When no appropriately-sized ", -+ "holes (holes that can hold an extra molecule) are available, the ", - "program tries for [TT]-nmol[tt] * [TT]-try[tt] times before giving up. ", - "Increase [TT]-try[tt] if you have several small holes to fill.[PAR]", - -diff --git a/src/tools/gmx_genconf.c b/src/tools/gmx_genconf.c -index 20af7d9..69afd39 100644 ---- a/src/tools/gmx_genconf.c -+++ b/src/tools/gmx_genconf.c -@@ -111,13 +111,13 @@ int gmx_genconf(int argc, char *argv[]) - const char *desc[] = { - "[TT]genconf[tt] multiplies a given coordinate file by simply stacking them", - "on top of each other, like a small child playing with wooden blocks.", -- "The program makes a grid of [IT]user defined[it]", -+ "The program makes a grid of [IT]user-defined[it]", - "proportions ([TT]-nbox[tt]), ", - "and interspaces the grid point with an extra space [TT]-dist[tt].[PAR]", - "When option [TT]-rot[tt] is used the program does not check for overlap", - "between molecules on grid points. It is recommended to make the box in", - "the input file at least as big as the coordinates + ", -- "Van der Waals radius.[PAR]", -+ "van der Waals radius.[PAR]", - "If the optional trajectory file is given, conformations are not", - "generated, but read from this file and translated appropriately to", - "build the grid." -diff --git a/src/tools/gmx_genion.c b/src/tools/gmx_genion.c -index 5cff773..2a89cea 100644 ---- a/src/tools/gmx_genion.c -+++ b/src/tools/gmx_genion.c -@@ -341,7 +341,7 @@ int gmx_genion(int argc, char *argv[]) - "[PAR]Ions which can have multiple charge states get the multiplicity", - "added, without sign, for the uncommon states only.[PAR]", - "With the option [TT]-pot[tt] the potential can be written as B-factors", -- "in a [TT].pdb[tt] file (for visualisation using e.g. rasmol).", -+ "in a [TT].pdb[tt] file (for visualisation using e.g. Rasmol).", - "The unit of the potential is 1000 kJ/(mol e), the scaling be changed", - "with the [TT]-scale[tt] option.[PAR]", - "For larger ions, e.g. sulfate we recommended using [TT]genbox[tt]." -diff --git a/src/tools/gmx_genpr.c b/src/tools/gmx_genpr.c -index e55e961..6463fbd 100644 ---- a/src/tools/gmx_genpr.c -+++ b/src/tools/gmx_genpr.c -@@ -56,20 +56,20 @@ int gmx_genpr(int argc,char *argv[]) - const char *desc[] = { - "[TT]genrestr[tt] produces an include file for a topology containing", - "a list of atom numbers and three force constants for the", -- "X, Y and Z direction. A single isotropic force constant may", -+ "[IT]x[it]-, [IT]y[it]-, and [IT]z[it]-direction. A single isotropic force constant may", - "be given on the command line instead of three components.[PAR]", - "WARNING: position restraints only work for the one molecule at a time.", - "Position restraints are interactions within molecules, therefore", - "they should be included within the correct [TT][ moleculetype ][tt]", - "block in the topology. Since the atom numbers in every moleculetype", - "in the topology start at 1 and the numbers in the input file for", -- "genpr number consecutively from 1, genpr will only produce a useful", -- "file for the first molecule.[PAR]", -+ "[TT]genrestr[tt] number consecutively from 1, [TT]genrestr[tt] will only", -+ "produce a useful file for the first molecule.[PAR]", - "The [TT]-of[tt] option produces an index file that can be used for", - "freezing atoms. In this case, the input file must be a [TT].pdb[tt] file.[PAR]", - "With the [TT]-disre[tt] option, half a matrix of distance restraints", - "is generated instead of position restraints. With this matrix, that", -- "one typically would apply to C-alpha atoms in a protein, one can", -+ "one typically would apply to C[GRK]alpha[grk] atoms in a protein, one can", - "maintain the overall conformation of a protein without tieing it to", - "a specific position (as with position restraints)." - }; -@@ -84,7 +84,7 @@ int gmx_genpr(int argc,char *argv[]) - - t_pargs pa[] = { - { "-fc", FALSE, etRVEC, {fc}, -- "force constants (kJ mol-1 nm-2)" }, -+ "force constants (kJ/mol nm^2)" }, - { "-freeze", FALSE, etREAL, {&freeze_level}, - "if the [TT]-of[tt] option or this one is given an index file will be written containing atom numbers of all atoms that have a B-factor less than the level given here" }, - { "-disre", FALSE, etBOOL, {&bDisre}, -diff --git a/src/tools/gmx_gyrate.c b/src/tools/gmx_gyrate.c -index 1507daa..546ab2f 100644 ---- a/src/tools/gmx_gyrate.c -+++ b/src/tools/gmx_gyrate.c -@@ -152,13 +152,13 @@ int gmx_gyrate(int argc,char *argv[]) - { - const char *desc[] = { - "[TT]g_gyrate[tt] computes the radius of gyration of a group of atoms", -- "and the radii of gyration about the x, y and z axes,", -+ "and the radii of gyration about the [IT]x[it]-, [IT]y[it]- and [IT]z[it]-axes,", - "as a function of time. The atoms are explicitly mass weighted.[PAR]", - "With the [TT]-nmol[tt] option the radius of gyration will be calculated", - "for multiple molecules by splitting the analysis group in equally", - "sized parts.[PAR]", -- "With the option [TT]-nz[tt] 2D radii of gyration in the x-y plane", -- "of slices along the z-axis are calculated." -+ "With the option [TT]-nz[tt] 2D radii of gyration in the [IT]x-y[it] plane", -+ "of slices along the [IT]z[it]-axis are calculated." - }; - static int nmol=1,nz=0; - static gmx_bool bQ=FALSE,bRot=FALSE,bMOI=FALSE; -diff --git a/src/tools/gmx_hbond.c b/src/tools/gmx_hbond.c -index 99158e3..d649ecf 100644 ---- a/src/tools/gmx_hbond.c -+++ b/src/tools/gmx_hbond.c -@@ -3180,7 +3180,7 @@ int gmx_hbond(int argc,char *argv[]) - { "-temp", FALSE, etREAL, {&temp}, - "Temperature (K) for computing the Gibbs energy corresponding to HB breaking and reforming" }, - { "-smooth",FALSE, etREAL, {&smooth_tail_start}, -- "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/tau)" }, -+ "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/[GRK]tau[grk])" }, - { "-dump", FALSE, etINT, {&nDump}, - "Dump the first N hydrogen bond ACFs in a single [TT].xvg[tt] file for debugging" }, - { "-max_hb",FALSE, etREAL, {&maxnhb}, -@@ -3190,7 +3190,7 @@ int gmx_hbond(int argc,char *argv[]) - { "-geminate", FALSE, etENUM, {gemType}, - "Use reversible geminate recombination for the kinetics/thermodynamics calclations. See Markovitch et al., J. Chem. Phys 129, 084505 (2008) for details."}, - { "-diff", FALSE, etREAL, {&D}, -- "Dffusion coefficient to use in the rev. gem. recomb. kinetic model. If non-positive, then it will be fitted to the ACF along with ka and kd."}, -+ "Dffusion coefficient to use in the reversible geminate recombination kinetic model. If negative, then it will be fitted to the ACF along with ka and kd."}, - #ifdef HAVE_OPENMP - { "-nthreads", FALSE, etINT, {&nThreads}, - "Number of threads used for the parallel loop over autocorrelations. nThreads <= 0 means maximum number of threads. Requires linking with OpenMP. The number of threads is limited by the number of processors (before OpenMP v.3 ) or environment variable OMP_THREAD_LIMIT (OpenMP v.3)"}, -diff --git a/src/tools/gmx_helix.c b/src/tools/gmx_helix.c -index 45bbbc3..ca64bc5 100644 ---- a/src/tools/gmx_helix.c -+++ b/src/tools/gmx_helix.c -@@ -122,35 +122,35 @@ void dump_otrj(FILE *otrj,int natoms,atom_id all_index[],rvec x[], - int gmx_helix(int argc,char *argv[]) - { - const char *desc[] = { -- "[TT]g_helix[tt] computes all kind of helix properties. First, the peptide", -- "is checked to find the longest helical part. This is determined by", -- "Hydrogen bonds and Phi/Psi angles.", -+ "[TT]g_helix[tt] computes all kinds of helix properties. First, the peptide", -+ "is checked to find the longest helical part, as determined by", -+ "hydrogen bonds and [GRK]phi[grk]/[GRK]psi[grk] angles.", - "That bit is fitted", -- "to an ideal helix around the Z-axis and centered around the origin.", -+ "to an ideal helix around the [IT]z[it]-axis and centered around the origin.", - "Then the following properties are computed:[PAR]", - "[BB]1.[bb] Helix radius (file [TT]radius.xvg[tt]). This is merely the", -- "RMS deviation in two dimensions for all Calpha atoms.", -+ "RMS deviation in two dimensions for all C[GRK]alpha[grk] atoms.", - "it is calced as sqrt((SUM i(x^2(i)+y^2(i)))/N), where N is the number", - "of backbone atoms. For an ideal helix the radius is 0.23 nm[BR]", - "[BB]2.[bb] Twist (file [TT]twist.xvg[tt]). The average helical angle per", -- "residue is calculated. For alpha helix it is 100 degrees,", -- "for 3-10 helices it will be smaller,", -+ "residue is calculated. For an [GRK]alpha[grk]-helix it is 100 degrees,", -+ "for 3-10 helices it will be smaller, and ", - "for 5-helices it will be larger.[BR]", - "[BB]3.[bb] Rise per residue (file [TT]rise.xvg[tt]). The helical rise per", -- "residue is plotted as the difference in Z-coordinate between Ca", -- "atoms. For an ideal helix this is 0.15 nm[BR]", -+ "residue is plotted as the difference in [IT]z[it]-coordinate between C[GRK]alpha[grk]", -+ "atoms. For an ideal helix, this is 0.15 nm[BR]", - "[BB]4.[bb] Total helix length (file [TT]len-ahx.xvg[tt]). The total length", - "of the", - "helix in nm. This is simply the average rise (see above) times the", - "number of helical residues (see below).[BR]", - "[BB]5.[bb] Number of helical residues (file [TT]n-ahx.xvg[tt]). The title says", - "it all.[BR]", -- "[BB]6.[bb] Helix Dipole, backbone only (file [TT]dip-ahx.xvg[tt]).[BR]", -- "[BB]7.[bb] RMS deviation from ideal helix, calculated for the Calpha", -+ "[BB]6.[bb] Helix dipole, backbone only (file [TT]dip-ahx.xvg[tt]).[BR]", -+ "[BB]7.[bb] RMS deviation from ideal helix, calculated for the C[GRK]alpha[grk]", - "atoms only (file [TT]rms-ahx.xvg[tt]).[BR]", -- "[BB]8.[bb] Average Calpha-Calpha dihedral angle (file [TT]phi-ahx.xvg[tt]).[BR]", -- "[BB]9.[bb] Average Phi and Psi angles (file [TT]phipsi.xvg[tt]).[BR]", -- "[BB]10.[bb] Ellipticity at 222 nm according to [IT]Hirst and Brooks[it]", -+ "[BB]8.[bb] Average C[GRK]alpha[grk] - C[GRK]alpha[grk] dihedral angle (file [TT]phi-ahx.xvg[tt]).[BR]", -+ "[BB]9.[bb] Average [GRK]phi[grk] and [GRK]psi[grk] angles (file [TT]phipsi.xvg[tt]).[BR]", -+ "[BB]10.[bb] Ellipticity at 222 nm according to Hirst and Brooks.", - "[PAR]" - }; - static const char *ppp[efhNR+2] = { -diff --git a/src/tools/gmx_helixorient.c b/src/tools/gmx_helixorient.c -index 60e6636..973d9d2 100644 ---- a/src/tools/gmx_helixorient.c -+++ b/src/tools/gmx_helixorient.c -@@ -60,17 +60,17 @@ int gmx_helixorient(int argc,char *argv[]) - const char *desc[] = { - "[TT]g_helixorient[tt] calculates the coordinates and direction of the average", - "axis inside an alpha helix, and the direction/vectors of both the", -- "alpha carbon and (optionally) a sidechain atom relative to the axis.[PAR]", -- "As input, you need to specify an index group with alpha carbon atoms", -- "corresponding to an alpha helix of continuous residues. Sidechain", -+ "C[GRK]alpha[grk] and (optionally) a sidechain atom relative to the axis.[PAR]", -+ "As input, you need to specify an index group with C[GRK]alpha[grk] atoms", -+ "corresponding to an [GRK]alpha[grk]-helix of continuous residues. Sidechain", - "directions require a second index group of the same size, containing", - "the heavy atom in each residue that should represent the sidechain.[PAR]", -- "Note that this program does not do any fitting of structures.[PAR]", -- "We need four Calpha coordinates to define the local direction of the helix", -+ "[BB]Note[bb] that this program does not do any fitting of structures.[PAR]", -+ "We need four C[GRK]alpha[grk] coordinates to define the local direction of the helix", - "axis.[PAR]", - "The tilt/rotation is calculated from Euler rotations, where we define", -- "the helix axis as the local X axis, the residues/CA-vector as Y, and the", -- "Z axis from their cross product. We use the Euler Y-Z-X rotation, meaning", -+ "the helix axis as the local [IT]x[it]-axis, the residues/C[GRK]alpha[grk] vector as [IT]y[it], and the", -+ "[IT]z[it]-axis from their cross product. We use the Euler Y-Z-X rotation, meaning", - "we first tilt the helix axis (1) around and (2) orthogonal to the residues", - "vector, and finally apply the (3) rotation around it. For debugging or other", - "purposes, we also write out the actual Euler rotation angles as [TT]theta[1-3].xvg[tt]" -diff --git a/src/tools/gmx_hydorder.c b/src/tools/gmx_hydorder.c -new file mode 100644 -index 0000000..01cee67 ---- /dev/null -+++ b/src/tools/gmx_hydorder.c -@@ -0,0 +1,680 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * $Id: densorder.c,v 0.9 -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.0 -+ * -+ * Copyright (c) 1991-2001 -+ * BIOSON Research Institute, Dept. of Biophysical Chemistry -+ * University of Groningen, The Netherlands -+ * -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . -+ * -+ * And Hey: -+ * Gyas ROwers Mature At Cryogenic Speed -+ */ -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#include -+#include -+ -+#include "sysstuff.h" -+#include "string.h" -+#include "typedefs.h" -+#include "statutil.h" -+#include "smalloc.h" -+#include "macros.h" -+#include "gstat.h" -+#include "vec.h" -+#include "xvgr.h" -+#include "pbc.h" -+#include "copyrite.h" -+#include "futil.h" -+#include "statutil.h" -+#include "index.h" -+#include "tpxio.h" -+#include "matio.h" -+#include "binsearch.h" -+#include "powerspect.h" -+ -+/* Print name of first atom in all groups in index file */ -+static void print_types(atom_id index[], atom_id a[], int ngrps, -+ char *groups[], t_topology *top) -+{ -+ int i; -+ -+ fprintf(stderr,"Using following groups: \n"); -+ for(i = 0; i < ngrps; i++) -+ fprintf(stderr,"Groupname: %s First atomname: %s First atomnr %u\n", -+ groups[i], *(top->atoms.atomname[a[index[i]]]), a[index[i]]); -+ fprintf(stderr,"\n"); -+} -+ -+static void check_length(real length, int a, int b) -+{ -+ if (length > 0.3) -+ fprintf(stderr,"WARNING: distance between atoms %d and " -+ "%d > 0.3 nm (%f). Index file might be corrupt.\n", -+ a, b, length); -+} -+ -+static void find_tetra_order_grid(t_topology top, int ePBC, -+ int natoms, matrix box, -+ rvec x[],int maxidx,atom_id index[], -+ real time, real *sgmean, real *skmean, -+ int nslicex, int nslicey, int nslicez, -+ real ***sggrid,real ***skgrid) -+{ -+ int ix,jx,i,j,k,l,n,*nn[4]; -+ rvec dx,rj,rk,urk,urj; -+ real cost,cost2,*sgmol,*skmol,rmean,rmean2,r2,box2,*r_nn[4]; -+ t_pbc pbc; -+ int slindex_x,slindex_y,slindex_z; -+ int ***sl_count; -+ real onethird=1.0/3.0; -+ gmx_rmpbc_t gpbc; -+ -+ /* dmat = init_mat(maxidx, FALSE); */ -+ -+ box2 = box[XX][XX] * box[XX][XX]; -+ -+ /* Initialize expanded sl_count array */ -+ snew(sl_count,nslicex); -+ for(i=0;i 0) -+ { -+ sggrid[i][j][k] /= sl_count[i][j][k]; -+ skgrid[i][j][k] /= sl_count[i][j][k]; -+ } -+ } -+ } -+ } -+ -+ sfree(sl_count); -+ sfree(sgmol); -+ sfree(skmol); -+ for (i=0; (i<4); i++) -+ { -+ sfree(r_nn[i]); -+ sfree(nn[i]); -+ } -+} -+ -+/*Determines interface from tetrahedral order parameter in box with specified binwidth. */ -+/*Outputs interface positions(bins), the number of timeframes, and the number of surface-mesh points in xy*/ -+ -+static void calc_tetra_order_interface(const char *fnNDX,const char *fnTPS,const char *fnTRX, real binw, int tblock, -+ int *nframes, int *nslicex, int *nslicey, -+ real sgang1,real sgang2,real ****intfpos, -+ output_env_t oenv) -+{ -+ FILE *fpsg=NULL,*fpsk=NULL; -+ char *sgslfn="sg_ang_mesh"; /* Hardcoded filenames for debugging*/ -+ char *skslfn="sk_dist_mesh"; -+ t_topology top; -+ int ePBC; -+ char title[STRLEN],subtitle[STRLEN]; -+ t_trxstatus *status; -+ int natoms; -+ real t; -+ rvec *xtop,*x; -+ matrix box; -+ real sg,sk, sgintf, pos; -+ atom_id **index; -+ char **grpname; -+ int i,j,k,n,*isize,ng, nslicez, framenr; -+ real ***sg_grid,***sk_grid, ***sg_fravg, ***sk_fravg, ****sk_4d, ****sg_4d; -+ int *perm; -+ int ndx1, ndx2; -+ int bins; -+ const real onehalf=1.0/2.0; -+ /* real ***intfpos[2]; pointers to arrays of two interface positions zcoord(framenr,xbin,ybin): intfpos[interface_index][t][nslicey*x+y] -+ * i.e 1D Row-major order in (t,x,y) */ -+ -+ -+ read_tps_conf(fnTPS,title,&top,&ePBC,&xtop,NULL,box,FALSE); -+ -+ *nslicex= (int)(box[XX][XX]/binw + onehalf); /*Calculate slicenr from binwidth*/ -+ *nslicey= (int)(box[YY][YY]/binw + onehalf); -+ nslicez= (int)(box[ZZ][ZZ]/binw + onehalf); -+ -+ -+ -+ ng = 1; -+ /* get index groups */ -+ printf("Select the group that contains the atoms you want to use for the tetrahedrality order parameter calculation:\n"); -+ snew(grpname,ng); -+ snew(index,ng); -+ snew(isize,ng); -+ get_index(&top.atoms,fnNDX,ng,isize,index,grpname); -+ -+ /* Analyze trajectory */ -+ natoms=read_first_x(oenv,&status,fnTRX,&t,&x,box); -+ if ( natoms > top.atoms.nr ) -+ gmx_fatal(FARGS,"Topology (%d atoms) does not match trajectory (%d atoms)", -+ top.atoms.nr,natoms); -+ check_index(NULL,ng,index[0],NULL,natoms); -+ -+ -+ /*Prepare structures for temporary storage of frame info*/ -+ snew(sg_grid,*nslicex); -+ snew(sk_grid,*nslicex); -+ for(i=0;i<*nslicex;i++) -+ { -+ snew(sg_grid[i],*nslicey); -+ snew(sk_grid[i],*nslicey); -+ for(j=0;j<*nslicey;j++) -+ { -+ snew(sg_grid[i][j],nslicez); -+ snew(sk_grid[i][j],nslicez); -+ } -+ } -+ -+ sg_4d=NULL; -+ sk_4d=NULL; -+ *nframes = 0; -+ framenr=0; -+ -+/* Loop over frames*/ -+ do -+ { -+ /*Initialize box meshes (temporary storage for each tblock frame -reinitialise every tblock steps */ -+ if(framenr%tblock ==0) -+ { -+ srenew(sk_4d,*nframes+1); -+ srenew(sg_4d,*nframes+1); -+ snew(sg_fravg,*nslicex); -+ snew(sk_fravg,*nslicex); -+ for(i=0;i<*nslicex;i++) -+ { -+ snew(sg_fravg[i],*nslicey); -+ snew(sk_fravg[i],*nslicey); -+ for(j=0;j<*nslicey;j++) -+ { -+ snew(sg_fravg[i][j],nslicez); -+ snew(sk_fravg[i][j],nslicez); -+ } -+ } -+ } -+ -+ find_tetra_order_grid(top,ePBC,natoms,box,x,isize[0],index[0],t, -+ &sg,&sk,*nslicex,*nslicey,nslicez,sg_grid,sk_grid); -+ for(i=0;i<*nslicex;i++) -+ { -+ for(j=0;j<*nslicey;j++) -+ { -+ for(k=0;k 0.01){ -+ pos=( (sgintf-sg_4d[n][i][j][perm[ndx1]])*perm[ndx1+1]+(sg_4d[n][i][j][perm[ndx1+1]]-sgintf)*perm[ndx1 ])*/ -+ (*intfpos)[0][n][j+*nslicey*i]=(perm[ndx1]+onehalf)*binw; -+ /*right interface (1)*/ -+ /*alpha=(sgintf-sg_4d[n][i][j][perm[ndx2]])/(sg_4d[n][i][j][perm[ndx2]+1]-sg_4d[n][i][j][perm[ndx2]]);*/ -+ /*(*intfpos)[1][n][j+*nslicey*i]=((1-alpha)*perm[ndx2]+alpha*(perm[ndx2]+1)+onehalf)*box[ZZ][ZZ]/nslicez;*/ -+ (*intfpos)[1][n][j+*nslicey*i]=(perm[ndx2]+onehalf)*binw; -+ } -+ } -+ } -+ -+ -+ /*sfree(perm);*/ -+ sfree(sk_4d); -+ sfree(sg_4d); -+ /*sfree(sg_grid);*/ -+ /*sfree(sk_grid);*/ -+ -+ -+} -+ -+static void writesurftoxpms(real ***surf, int tblocks,int xbins, int ybins, real bw,char **outfiles,int maplevels ) -+{ -+ -+ char numbuf[8]; -+ int n, i, j; -+ real **profile1, **profile2; -+ real max1, max2, min1, min2, *xticks, *yticks; -+ t_rgb lo={1,1,1}; -+ t_rgb hi={0,0,0}; -+ FILE *xpmfile1, *xpmfile2; -+ -+/*Prepare xpm structures for output*/ -+ -+/*Allocate memory to tick's and matrices*/ -+ snew (xticks,xbins+1); -+ snew (yticks,ybins+1); -+ -+ profile1=mk_matrix(xbins,ybins,FALSE); -+ profile2=mk_matrix(xbins,ybins,FALSE); -+ -+ for (i=0;imax1) max1=profile1[i][j]; -+ if(profile1[i][j]max2) max2=profile2[i][j]; -+ if(profile2[i][j] U) or a continuous one" }, -+ "Use a discrete folding criterion (F <-> U) or a continuous one" }, - { "-mult", FALSE, etINT, {&nmult}, - "Factor to multiply the data with before discretization" } - }; -diff --git a/src/tools/gmx_membed.c b/src/tools/gmx_membed.c -index 2b573bd..d834478 100644 ---- a/src/tools/gmx_membed.c -+++ b/src/tools/gmx_membed.c -@@ -956,854 +956,6 @@ void md_print_warning(const t_commrec *cr,FILE *fplog,const char *buf) - } - } - --/* simulation conditions to transmit. Keep in mind that they are -- transmitted to other nodes through an MPI_Reduce after -- casting them to a real (so the signals can be sent together with other -- data). This means that the only meaningful values are positive, -- negative or zero. */ --enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; --/* Is the signal in one simulation independent of other simulations? */ --gmx_bool gs_simlocal[eglsNR] = { TRUE, FALSE, FALSE, TRUE }; -- --typedef struct { -- int nstms; /* The frequency for intersimulation communication */ -- int sig[eglsNR]; /* The signal set by one process in do_md */ -- int set[eglsNR]; /* The communicated signal, equal for all processes */ --} globsig_t; -- -- --static int multisim_min(const gmx_multisim_t *ms,int nmin,int n) --{ -- int *buf; -- gmx_bool bPos,bEqual; -- int s,d; -- -- snew(buf,ms->nsim); -- buf[ms->sim] = n; -- gmx_sumi_sim(ms->nsim,buf,ms); -- bPos = TRUE; -- bEqual = TRUE; -- for(s=0; snsim; s++) -- { -- bPos = bPos && (buf[s] > 0); -- bEqual = bEqual && (buf[s] == buf[0]); -- } -- if (bPos) -- { -- if (bEqual) -- { -- nmin = min(nmin,buf[0]); -- } -- else -- { -- /* Find the least common multiple */ -- for(d=2; dnsim && d % buf[s] == 0) -- { -- s++; -- } -- if (s == ms->nsim) -- { -- /* We found the LCM and it is less than nmin */ -- nmin = d; -- break; -- } -- } -- } -- } -- sfree(buf); -- -- return nmin; --} -- --static int multisim_nstsimsync(const t_commrec *cr, -- const t_inputrec *ir,int repl_ex_nst) --{ -- int nmin; -- -- if (MASTER(cr)) -- { -- nmin = INT_MAX; -- nmin = multisim_min(cr->ms,nmin,ir->nstlist); -- nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); -- nmin = multisim_min(cr->ms,nmin,repl_ex_nst); -- if (nmin == INT_MAX) -- { -- gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); -- } -- /* Avoid inter-simulation communication at every (second) step */ -- if (nmin <= 2) -- { -- nmin = 10; -- } -- } -- -- gmx_bcast(sizeof(int),&nmin,cr); -- -- return nmin; --} -- --static void init_global_signals(globsig_t *gs,const t_commrec *cr, -- const t_inputrec *ir,int repl_ex_nst) --{ -- int i; -- -- if (MULTISIM(cr)) -- { -- gs->nstms = multisim_nstsimsync(cr,ir,repl_ex_nst); -- if (debug) -- { -- fprintf(debug,"Syncing simulations for checkpointing and termination every %d steps\n",gs->nstms); -- } -- } -- else -- { -- gs->nstms = 1; -- } -- -- for(i=0; isig[i] = 0; -- gs->set[i] = 0; -- } --} -- --static void copy_coupling_state(t_state *statea,t_state *stateb, -- gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts) --{ -- -- /* MRS note -- might be able to get rid of some of the arguments. Look over it when it's all debugged */ -- -- int i,j,nc; -- -- /* Make sure we have enough space for x and v */ -- if (statea->nalloc > stateb->nalloc) -- { -- stateb->nalloc = statea->nalloc; -- srenew(stateb->x,stateb->nalloc); -- srenew(stateb->v,stateb->nalloc); -- } -- -- stateb->natoms = statea->natoms; -- stateb->ngtc = statea->ngtc; -- stateb->nnhpres = statea->nnhpres; -- stateb->veta = statea->veta; -- if (ekinda) -- { -- copy_mat(ekinda->ekin,ekindb->ekin); -- for (i=0; ingtc; i++) -- { -- ekindb->tcstat[i].T = ekinda->tcstat[i].T; -- ekindb->tcstat[i].Th = ekinda->tcstat[i].Th; -- copy_mat(ekinda->tcstat[i].ekinh,ekindb->tcstat[i].ekinh); -- copy_mat(ekinda->tcstat[i].ekinf,ekindb->tcstat[i].ekinf); -- ekindb->tcstat[i].ekinscalef_nhc = ekinda->tcstat[i].ekinscalef_nhc; -- ekindb->tcstat[i].ekinscaleh_nhc = ekinda->tcstat[i].ekinscaleh_nhc; -- ekindb->tcstat[i].vscale_nhc = ekinda->tcstat[i].vscale_nhc; -- } -- } -- copy_rvecn(statea->x,stateb->x,0,stateb->natoms); -- copy_rvecn(statea->v,stateb->v,0,stateb->natoms); -- copy_mat(statea->box,stateb->box); -- copy_mat(statea->box_rel,stateb->box_rel); -- copy_mat(statea->boxv,stateb->boxv); -- -- for (i = 0; ingtc; i++) -- { -- nc = i*opts->nhchainlength; -- for (j=0; jnhchainlength; j++) -- { -- stateb->nosehoover_xi[nc+j] = statea->nosehoover_xi[nc+j]; -- stateb->nosehoover_vxi[nc+j] = statea->nosehoover_vxi[nc+j]; -- } -- } -- if (stateb->nhpres_xi != NULL) -- { -- for (i = 0; innhpres; i++) -- { -- nc = i*opts->nhchainlength; -- for (j=0; jnhchainlength; j++) -- { -- stateb->nhpres_xi[nc+j] = statea->nhpres_xi[nc+j]; -- stateb->nhpres_vxi[nc+j] = statea->nhpres_vxi[nc+j]; -- } -- } -- } --} -- --static void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, -- t_forcerec *fr, gmx_ekindata_t *ekind, -- t_state *state, t_state *state_global, t_mdatoms *mdatoms, -- t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, -- gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, -- tensor pres, rvec mu_tot, gmx_constr_t constr, -- globsig_t *gs,gmx_bool bInterSimGS, -- matrix box, gmx_mtop_t *top_global, real *pcurr, -- int natoms, gmx_bool *bSumEkinhOld, int flags) --{ -- int i,gsi; -- real gs_buf[eglsNR]; -- tensor corr_vir,corr_pres; -- gmx_bool bEner,bPres,bTemp; -- gmx_bool bRerunMD, bStopCM, bGStat, bIterate, -- bFirstIterate,bReadEkin,bEkinAveVel,bScaleEkin, bConstrain; -- real prescorr,enercorr,dvdlcorr; -- -- /* translate CGLO flags to gmx_booleans */ -- bRerunMD = flags & CGLO_RERUNMD; -- bStopCM = flags & CGLO_STOPCM; -- bGStat = flags & CGLO_GSTAT; -- bReadEkin = (flags & CGLO_READEKIN); -- bScaleEkin = (flags & CGLO_SCALEEKIN); -- bEner = flags & CGLO_ENERGY; -- bTemp = flags & CGLO_TEMPERATURE; -- bPres = (flags & CGLO_PRESSURE); -- bConstrain = (flags & CGLO_CONSTRAINT); -- bIterate = (flags & CGLO_ITERATE); -- bFirstIterate = (flags & CGLO_FIRSTITERATE); -- -- /* we calculate a full state kinetic energy either with full-step velocity verlet -- or half step where we need the pressure */ -- bEkinAveVel = (ir->eI==eiVV || (ir->eI==eiVVAK && IR_NPT_TROTTER(ir) && bPres) || bReadEkin); -- -- /* in initalization, it sums the shake virial in vv, and to -- sums ekinh_old in leapfrog (or if we are calculating ekinh_old for other reasons */ -- -- /* ########## Kinetic energy ############## */ -- -- if (bTemp) -- { -- /* Non-equilibrium MD: this is parallellized, but only does communication -- * when there really is NEMD. -- */ -- -- if (PAR(cr) && (ekind->bNEMD)) -- { -- accumulate_u(cr,&(ir->opts),ekind); -- } -- debug_gmx(); -- if (bReadEkin) -- { -- restore_ekinstate_from_state(cr,ekind,&state_global->ekinstate); -- } -- else -- { -- -- calc_ke_part(state,&(ir->opts),mdatoms,ekind,nrnb,bEkinAveVel,bIterate); -- } -- -- debug_gmx(); -- -- /* Calculate center of mass velocity if necessary, also parallellized */ -- if (bStopCM && !bRerunMD && bEner) -- { -- calc_vcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms, -- state->x,state->v,vcm); -- } -- } -- -- if (bTemp || bPres || bEner || bConstrain) -- { -- if (!bGStat) -- { -- /* We will not sum ekinh_old, -- * so signal that we still have to do it. -- */ -- *bSumEkinhOld = TRUE; -- -- } -- else -- { -- if (gs != NULL) -- { -- for(i=0; isig[i]; -- } -- } -- if (PAR(cr)) -- { -- wallcycle_start(wcycle,ewcMoveE); -- GMX_MPE_LOG(ev_global_stat_start); -- global_stat(fplog,gstat,cr,enerd,force_vir,shake_vir,mu_tot, -- ir,ekind,constr,vcm, -- gs != NULL ? eglsNR : 0,gs_buf, -- top_global,state, -- *bSumEkinhOld,flags); -- GMX_MPE_LOG(ev_global_stat_finish); -- wallcycle_stop(wcycle,ewcMoveE); -- } -- if (gs != NULL) -- { -- if (MULTISIM(cr) && bInterSimGS) -- { -- if (MASTER(cr)) -- { -- /* Communicate the signals between the simulations */ -- gmx_sum_sim(eglsNR,gs_buf,cr->ms); -- } -- /* Communicate the signals form the master to the others */ -- gmx_bcast(eglsNR*sizeof(gs_buf[0]),gs_buf,cr); -- } -- for(i=0; i= 0 ? -- (int)(gs_buf[i] + 0.5) : -- (int)(gs_buf[i] - 0.5)); -- if (gsi != 0) -- { -- gs->set[i] = gsi; -- } -- /* Turn off the local signal */ -- gs->sig[i] = 0; -- } -- } -- } -- *bSumEkinhOld = FALSE; -- } -- } -- -- if (!ekind->bNEMD && debug && bTemp && (vcm->nr > 0)) -- { -- correct_ekin(debug, -- mdatoms->start,mdatoms->start+mdatoms->homenr, -- state->v,vcm->group_p[0], -- mdatoms->massT,mdatoms->tmass,ekind->ekin); -- } -- -- if (bEner) { -- /* Do center of mass motion removal */ -- if (bStopCM && !bRerunMD) /* is this correct? Does it get called too often with this logic? */ -- { -- check_cm_grp(fplog,vcm,ir,1); -- do_stopcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms->cVCM, -- state->x,state->v,vcm); -- inc_nrnb(nrnb,eNR_STOPCM,mdatoms->homenr); -- } -- } -- -- if (bTemp) -- { -- /* Sum the kinetic energies of the groups & calc temp */ -- /* compute full step kinetic energies if vv, or if vv-avek and we are computing the pressure with IR_NPT_TROTTER */ -- /* three maincase: VV with AveVel (md-vv), vv with AveEkin (md-vv-avek), leap with AveEkin (md). -- Leap with AveVel is also an option for the future but not supported now. -- bEkinAveVel: If TRUE, we simply multiply ekin by ekinscale to get a full step kinetic energy. -- If FALSE, we average ekinh_old and ekinh*ekinscale_nhc to get an averaged half step kinetic energy. -- bSaveEkinOld: If TRUE (in the case of iteration = bIterate is TRUE), we don't reset the ekinscale_nhc. -- If FALSE, we go ahead and erase over it. -- */ -- enerd->term[F_TEMP] = sum_ekin(&(ir->opts),ekind,&(enerd->term[F_DKDL]), -- bEkinAveVel,bIterate,bScaleEkin); -- -- enerd->term[F_EKIN] = trace(ekind->ekin); -- } -- -- /* ########## Long range energy information ###### */ -- -- if (bEner || bPres || bConstrain) -- { -- calc_dispcorr(fplog,ir,fr,0,top_global->natoms,box,state->lambda, -- corr_pres,corr_vir,&prescorr,&enercorr,&dvdlcorr); -- } -- -- if (bEner && bFirstIterate) -- { -- enerd->term[F_DISPCORR] = enercorr; -- enerd->term[F_EPOT] += enercorr; -- enerd->term[F_DVDL] += dvdlcorr; -- if (fr->efep != efepNO) { -- enerd->dvdl_lin += dvdlcorr; -- } -- } -- -- /* ########## Now pressure ############## */ -- if (bPres || bConstrain) -- { -- -- m_add(force_vir,shake_vir,total_vir); -- -- /* Calculate pressure and apply LR correction if PPPM is used. -- * Use the box from last timestep since we already called update(). -- */ -- -- enerd->term[F_PRES] = calc_pres(fr->ePBC,ir->nwall,box,ekind->ekin,total_vir,pres, -- (fr->eeltype==eelPPPM)?enerd->term[F_COUL_RECIP]:0.0); -- -- /* Calculate long range corrections to pressure and energy */ -- /* this adds to enerd->term[F_PRES] and enerd->term[F_ETOT], -- and computes enerd->term[F_DISPCORR]. Also modifies the -- total_vir and pres tesors */ -- -- m_add(total_vir,corr_vir,total_vir); -- m_add(pres,corr_pres,pres); -- enerd->term[F_PDISPCORR] = prescorr; -- enerd->term[F_PRES] += prescorr; -- *pcurr = enerd->term[F_PRES]; -- /* calculate temperature using virial */ -- enerd->term[F_VTEMP] = calc_temp(trace(total_vir),ir->opts.nrdf[0]); -- -- } --} -- -- --/* Definitions for convergence of iterated constraints */ -- --/* iterate constraints up to 50 times */ --#define MAXITERCONST 50 -- --/* data type */ --typedef struct --{ -- real f,fprev,x,xprev; -- int iter_i; -- gmx_bool bIterate; -- real allrelerr[MAXITERCONST+2]; -- int num_close; /* number of "close" violations, caused by limited precision. */ --} gmx_iterate_t; -- --#ifdef GMX_DOUBLE --#define CONVERGEITER 0.000000001 --#define CLOSE_ENOUGH 0.000001000 --#else --#define CONVERGEITER 0.0001 --#define CLOSE_ENOUGH 0.0050 --#endif -- --/* we want to keep track of the close calls. If there are too many, there might be some other issues. -- so we make sure that it's either less than some predetermined number, or if more than that number, -- only some small fraction of the total. */ --#define MAX_NUMBER_CLOSE 50 --#define FRACTION_CLOSE 0.001 -- --/* maximum length of cyclic traps to check, emerging from limited numerical precision */ --#define CYCLEMAX 20 -- --static void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate) --{ -- int i; -- -- iterate->iter_i = 0; -- iterate->bIterate = bIterate; -- iterate->num_close = 0; -- for (i=0;iallrelerr[i] = 0; -- } --} -- --static gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf) --{ -- /* monitor convergence, and use a secant search to propose new -- values. -- x_{i} - x_{i-1} -- The secant method computes x_{i+1} = x_{i} - f(x_{i}) * --------------------- -- f(x_{i}) - f(x_{i-1}) -- -- The function we are trying to zero is fom-x, where fom is the -- "figure of merit" which is the pressure (or the veta value) we -- would get by putting in an old value of the pressure or veta into -- the incrementor function for the step or half step. I have -- verified that this gives the same answer as self consistent -- iteration, usually in many fewer steps, especially for small tau_p. -- -- We could possibly eliminate an iteration with proper use -- of the value from the previous step, but that would take a bit -- more bookkeeping, especially for veta, since tests indicate the -- function of veta on the last step is not sufficiently close to -- guarantee convergence this step. This is -- good enough for now. On my tests, I could use tau_p down to -- 0.02, which is smaller that would ever be necessary in -- practice. Generally, 3-5 iterations will be sufficient */ -- -- real relerr,err; -- char buf[256]; -- int i; -- gmx_bool incycle; -- -- if (bFirstIterate) -- { -- iterate->x = fom; -- iterate->f = fom-iterate->x; -- iterate->xprev = 0; -- iterate->fprev = 0; -- *newf = fom; -- } -- else -- { -- iterate->f = fom-iterate->x; /* we want to zero this difference */ -- if ((iterate->iter_i > 1) && (iterate->iter_i < MAXITERCONST)) -- { -- if (iterate->f==iterate->fprev) -- { -- *newf = iterate->f; -- } -- else -- { -- *newf = iterate->x - (iterate->x-iterate->xprev)*(iterate->f)/(iterate->f-iterate->fprev); -- } -- } -- else -- { -- /* just use self-consistent iteration the first step to initialize, or -- if it's not converging (which happens occasionally -- need to investigate why) */ -- *newf = fom; -- } -- } -- /* Consider a slight shortcut allowing us to exit one sooner -- we check the -- difference between the closest of x and xprev to the new -- value. To be 100% certain, we should check the difference between -- the last result, and the previous result, or -- -- relerr = (fabs((x-xprev)/fom)); -- -- but this is pretty much never necessary under typical conditions. -- Checking numerically, it seems to lead to almost exactly the same -- trajectories, but there are small differences out a few decimal -- places in the pressure, and eventually in the v_eta, but it could -- save an interation. -- -- if (fabs(*newf-x) < fabs(*newf - xprev)) { xmin = x;} else { xmin = xprev;} -- relerr = (fabs((*newf-xmin) / *newf)); -- */ -- -- err = fabs((iterate->f-iterate->fprev)); -- relerr = fabs(err/fom); -- -- iterate->allrelerr[iterate->iter_i] = relerr; -- -- if (iterate->iter_i > 0) -- { -- if (debug) -- { -- fprintf(debug,"Iterating NPT constraints: %6i %20.12f%14.6g%20.12f\n", -- iterate->iter_i,fom,relerr,*newf); -- } -- -- if ((relerr < CONVERGEITER) || (err < CONVERGEITER) || (fom==0) || ((iterate->x == iterate->xprev) && iterate->iter_i > 1)) -- { -- iterate->bIterate = FALSE; -- if (debug) -- { -- fprintf(debug,"Iterating NPT constraints: CONVERGED\n"); -- } -- return TRUE; -- } -- if (iterate->iter_i > MAXITERCONST) -- { -- if (relerr < CLOSE_ENOUGH) -- { -- incycle = FALSE; -- for (i=1;iallrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-1]) && -- (iterate->allrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-(1+2*i)])) { -- incycle = TRUE; -- if (debug) -- { -- fprintf(debug,"Exiting from an NPT iterating cycle of length %d\n",i); -- } -- break; -- } -- } -- -- if (incycle) { -- /* step 1: trapped in a numerical attractor */ -- /* we are trapped in a numerical attractor, and can't converge any more, and are close to the final result. -- Better to give up convergence here than have the simulation die. -- */ -- iterate->num_close++; -- return TRUE; -- } -- else -- { -- /* Step #2: test if we are reasonably close for other reasons, then monitor the number. If not, die */ -- -- /* how many close calls have we had? If less than a few, we're OK */ -- if (iterate->num_close < MAX_NUMBER_CLOSE) -- { -- sprintf(buf,"Slight numerical convergence deviation with NPT at step %d, relative error only %10.5g, likely not a problem, continuing\n",nsteps,relerr); -- md_print_warning(cr,fplog,buf); -- iterate->num_close++; -- return TRUE; -- /* if more than a few, check the total fraction. If too high, die. */ -- } else if (iterate->num_close/(double)nsteps > FRACTION_CLOSE) { -- gmx_fatal(FARGS,"Could not converge NPT constraints, too many exceptions (%d%%\n",iterate->num_close/(double)nsteps); -- } -- } -- } -- else -- { -- gmx_fatal(FARGS,"Could not converge NPT constraints\n"); -- } -- } -- } -- -- iterate->xprev = iterate->x; -- iterate->x = *newf; -- iterate->fprev = iterate->f; -- iterate->iter_i++; -- -- return FALSE; --} -- --static void check_nst_param(FILE *fplog,t_commrec *cr, -- const char *desc_nst,int nst, -- const char *desc_p,int *p) --{ -- char buf[STRLEN]; -- -- if (*p > 0 && *p % nst != 0) -- { -- /* Round up to the next multiple of nst */ -- *p = ((*p)/nst + 1)*nst; -- sprintf(buf,"NOTE: %s changes %s to %d\n",desc_nst,desc_p,*p); -- md_print_warning(cr,fplog,buf); -- } --} -- --static void reset_all_counters(FILE *fplog,t_commrec *cr, -- gmx_large_int_t step, -- gmx_large_int_t *step_rel,t_inputrec *ir, -- gmx_wallcycle_t wcycle,t_nrnb *nrnb, -- gmx_runtime_t *runtime) --{ -- char buf[STRLEN],sbuf[STEPSTRSIZE]; -- -- /* Reset all the counters related to performance over the run */ -- sprintf(buf,"Step %s: resetting all time and cycle counters\n", -- gmx_step_str(step,sbuf)); -- md_print_warning(cr,fplog,buf); -- -- wallcycle_stop(wcycle,ewcRUN); -- wallcycle_reset_all(wcycle); -- if (DOMAINDECOMP(cr)) -- { -- reset_dd_statistics_counters(cr->dd); -- } -- init_nrnb(nrnb); -- ir->init_step += *step_rel; -- ir->nsteps -= *step_rel; -- *step_rel = 0; -- wallcycle_start(wcycle,ewcRUN); -- runtime_start(runtime); -- print_date_and_time(fplog,cr->nodeid,"Restarted time",runtime); --} -- --static int check_nstglobalcomm(FILE *fplog,t_commrec *cr, -- int nstglobalcomm,t_inputrec *ir) --{ -- char buf[STRLEN]; -- -- if (!EI_DYNAMICS(ir->eI)) -- { -- nstglobalcomm = 1; -- } -- -- if (nstglobalcomm == -1) -- { -- if (ir->nstcalcenergy == 0 && ir->nstlist == 0) -- { -- nstglobalcomm = 10; -- if (ir->nstenergy > 0 && ir->nstenergy < nstglobalcomm) -- { -- nstglobalcomm = ir->nstenergy; -- } -- } -- else -- { -- /* We assume that if nstcalcenergy > nstlist, -- * nstcalcenergy is a multiple of nstlist. -- */ -- if (ir->nstcalcenergy == 0 || -- (ir->nstlist > 0 && ir->nstlist < ir->nstcalcenergy)) -- { -- nstglobalcomm = ir->nstlist; -- } -- else -- { -- nstglobalcomm = ir->nstcalcenergy; -- } -- } -- } -- else -- { -- if (ir->nstlist > 0 && -- nstglobalcomm > ir->nstlist && nstglobalcomm % ir->nstlist != 0) -- { -- nstglobalcomm = (nstglobalcomm / ir->nstlist)*ir->nstlist; -- sprintf(buf,"WARNING: nstglobalcomm is larger than nstlist, but not a multiple, setting it to %d\n",nstglobalcomm); -- md_print_warning(cr,fplog,buf); -- } -- if (nstglobalcomm > ir->nstcalcenergy) -- { -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nstcalcenergy",&ir->nstcalcenergy); -- } -- -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nstenergy",&ir->nstenergy); -- -- check_nst_param(fplog,cr,"-gcom",nstglobalcomm, -- "nstlog",&ir->nstlog); -- } -- -- if (ir->comm_mode != ecmNO && ir->nstcomm < nstglobalcomm) -- { -- sprintf(buf,"WARNING: Changing nstcomm from %d to %d\n", -- ir->nstcomm,nstglobalcomm); -- md_print_warning(cr,fplog,buf); -- ir->nstcomm = nstglobalcomm; -- } -- -- return nstglobalcomm; --} -- --void check_ir_old_tpx_versions(t_commrec *cr,FILE *fplog, -- t_inputrec *ir,gmx_mtop_t *mtop) --{ -- /* Check required for old tpx files */ -- if (IR_TWINRANGE(*ir) && ir->nstlist > 1 && -- ir->nstcalcenergy % ir->nstlist != 0) -- { -- md_print_warning(cr,fplog,"Old tpr file with twin-range settings: modifying energy calculation and/or T/P-coupling frequencies"); -- -- if (gmx_mtop_ftype_count(mtop,F_CONSTR) + -- gmx_mtop_ftype_count(mtop,F_CONSTRNC) > 0 && -- ir->eConstrAlg == econtSHAKE) -- { -- md_print_warning(cr,fplog,"With twin-range cut-off's and SHAKE the virial and pressure are incorrect"); -- if (ir->epc != epcNO) -- { -- gmx_fatal(FARGS,"Can not do pressure coupling with twin-range cut-off's and SHAKE"); -- } -- } -- check_nst_param(fplog,cr,"nstlist",ir->nstlist, -- "nstcalcenergy",&ir->nstcalcenergy); -- check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -- "nstenergy",&ir->nstenergy); -- check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -- "nstlog",&ir->nstlog); -- if (ir->efep != efepNO) -- { -- check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, -- "nstdhdl",&ir->nstdhdl); -- } -- } --} -- --typedef struct { -- gmx_bool bGStatEveryStep; -- gmx_large_int_t step_ns; -- gmx_large_int_t step_nscheck; -- gmx_large_int_t nns; -- matrix scale_tot; -- int nabnsb; -- double s1; -- double s2; -- double ab; -- double lt_runav; -- double lt_runav2; --} gmx_nlheur_t; -- --static void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step) --{ -- nlh->lt_runav = 0; -- nlh->lt_runav2 = 0; -- nlh->step_nscheck = step; --} -- --static void init_nlistheuristics(gmx_nlheur_t *nlh, -- gmx_bool bGStatEveryStep,gmx_large_int_t step) --{ -- nlh->bGStatEveryStep = bGStatEveryStep; -- nlh->nns = 0; -- nlh->nabnsb = 0; -- nlh->s1 = 0; -- nlh->s2 = 0; -- nlh->ab = 0; -- -- reset_nlistheuristics(nlh,step); --} -- --static void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step) --{ -- gmx_large_int_t nl_lt; -- char sbuf[STEPSTRSIZE],sbuf2[STEPSTRSIZE]; -- -- /* Determine the neighbor list life time */ -- nl_lt = step - nlh->step_ns; -- if (debug) -- { -- fprintf(debug,"%d atoms beyond ns buffer, updating neighbor list after %s steps\n",nlh->nabnsb,gmx_step_str(nl_lt,sbuf)); -- } -- nlh->nns++; -- nlh->s1 += nl_lt; -- nlh->s2 += nl_lt*nl_lt; -- nlh->ab += nlh->nabnsb; -- if (nlh->lt_runav == 0) -- { -- nlh->lt_runav = nl_lt; -- /* Initialize the fluctuation average -- * such that at startup we check after 0 steps. -- */ -- nlh->lt_runav2 = sqr(nl_lt/2.0); -- } -- /* Running average with 0.9 gives an exp. history of 9.5 */ -- nlh->lt_runav2 = 0.9*nlh->lt_runav2 + 0.1*sqr(nlh->lt_runav - nl_lt); -- nlh->lt_runav = 0.9*nlh->lt_runav + 0.1*nl_lt; -- if (nlh->bGStatEveryStep) -- { -- /* Always check the nlist validity */ -- nlh->step_nscheck = step; -- } -- else -- { -- /* We check after: - 2*sigma -- * The factor 2 is quite conservative, -- * but we assume that with nstlist=-1 the user -- * prefers exact integration over performance. -- */ -- nlh->step_nscheck = step -- + (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2)) - 1; -- } -- if (debug) -- { -- fprintf(debug,"nlist life time %s run av. %4.1f sig %3.1f check %s check with -gcom %d\n", -- gmx_step_str(nl_lt,sbuf),nlh->lt_runav,sqrt(nlh->lt_runav2), -- gmx_step_str(nlh->step_nscheck-step+1,sbuf2), -- (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2))); -- } --} -- --static void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step) --{ -- int d; -- -- if (bReset) -- { -- reset_nlistheuristics(nlh,step); -- } -- else -- { -- update_nliststatistics(nlh,step); -- } -- -- nlh->step_ns = step; -- /* Initialize the cumulative coordinate scaling matrix */ -- clear_mat(nlh->scale_tot); -- for(d=0; dscale_tot[d][d] = 1.0; -- } --} -- - double do_md_membed(FILE *fplog,t_commrec *cr,int nfile,const t_filenm fnm[], - const output_env_t oenv, gmx_bool bVerbose,gmx_bool bCompact, - int nstglobalcomm, -@@ -4283,14 +3435,13 @@ int gmx_membed(int argc,char *argv[]) - { - const char *desc[] = { - "[TT]g_membed[tt] embeds a membrane protein into an equilibrated lipid bilayer at the position", -- "and orientation specified by the user.\n", -- "\n", -- "SHORT MANUAL\n------------\n", -+ "and orientation specified by the user.[PAR]", -+ "SHORT MANUAL[BR]------------[BR]", - "The user should merge the structure files of the protein and membrane (+solvent), creating a", - "single structure file with the protein overlapping the membrane at the desired position and", -- "orientation. Box size should be taken from the membrane structure file. The corresponding topology", -+ "orientation. The box size is taken from the membrane structure file. The corresponding topology", - "files should also be merged. Consecutively, create a [TT].tpr[tt] file (input for [TT]g_membed[tt]) from these files," -- "with the following options included in the [TT].mdp[tt] file.\n", -+ "with the following options included in the [TT].mdp[tt] file.[BR]", - " - [TT]integrator = md[tt][BR]", - " - [TT]energygrp = Protein[tt] (or other group that you want to insert)[BR]", - " - [TT]freezegrps = Protein[tt][BR]", -@@ -4298,32 +3449,29 @@ int gmx_membed(int argc,char *argv[]) - " - [TT]energygrp_excl = Protein Protein[tt][BR]", - "The output is a structure file containing the protein embedded in the membrane. If a topology", - "file is provided, the number of lipid and ", -- "solvent molecules will be updated to match the new structure file.\n", -- "For a more extensive manual see Wolf et al, J Comp Chem 31 (2010) 2169-2174, Appendix.\n", -- "\n", -- "SHORT METHOD DESCRIPTION\n", -- "------------------------\n", -- "1. The protein is resized around its center of mass by a factor -xy in the xy-plane", -- "(the membrane plane) and a factor -z in the z-direction (if the size of the", -+ "solvent molecules will be updated to match the new structure file.[BR]", -+ "For a more extensive manual see Wolf et al, J Comp Chem 31 (2010) 2169-2174, Appendix.[PAR]", -+ "SHORT METHOD DESCRIPTION[BR]", -+ "------------------------[BR]", -+ "1. The protein is resized around its center of mass by a factor [TT]-xy[tt] in the xy-plane", -+ "(the membrane plane) and a factor [TT]-z[tt] in the [IT]z[it]-direction (if the size of the", - "protein in the z-direction is the same or smaller than the width of the membrane, a", -- "-z value larger than 1 can prevent that the protein will be enveloped by the lipids).\n", -+ "[TT]-z[tt] value larger than 1 can prevent that the protein will be enveloped by the lipids).[BR]", - "2. All lipid and solvent molecules overlapping with the resized protein are removed. All", -- "intraprotein interactions are turned off to prevent numerical issues for small values of -xy", -- " or -z\n", -- "3. One md step is performed.\n", -- "4. The resize factor (-xy or -z) is incremented by a small amount ((1-xy)/nxy or (1-z)/nz) and the", -+ "intraprotein interactions are turned off to prevent numerical issues for small values of [TT]-xy[tt]", -+ " or [TT]-z[tt][BR]", -+ "3. One md step is performed.[BR]", -+ "4. The resize factor ([TT]-xy[tt] or [TT]-z[tt]) is incremented by a small amount ((1-xy)/nxy or (1-z)/nz) and the", - "protein is resized again around its center of mass. The resize factor for the xy-plane", -- "is incremented first. The resize factor for the z-direction is not changed until the -xy factor", -- "is 1 (thus after -nxy iteration).\n", -- "5. Repeat step 3 and 4 until the protein reaches its original size (-nxy + -nz iterations).\n", -- "For a more extensive method descrition see Wolf et al, J Comp Chem, 31 (2010) 2169-2174.\n", -- "\n", -- "NOTE\n----\n", -- " - Protein can be any molecule you want to insert in the membrane.\n", -+ "is incremented first. The resize factor for the z-direction is not changed until the [TT]-xy[tt] factor", -+ "is 1 (thus after [TT]-nxy[tt] iterations).[BR]", -+ "5. Repeat step 3 and 4 until the protein reaches its original size ([TT]-nxy[tt] + [TT]-nz[tt] iterations).[BR]", -+ "For a more extensive method description see Wolf et al, J Comp Chem, 31 (2010) 2169-2174.[PAR]", -+ "NOTE[BR]----[BR]", -+ " - Protein can be any molecule you want to insert in the membrane.[BR]", - " - It is recommended to perform a short equilibration run after the embedding", -- "(see Wolf et al, J Comp Chem 31 (2010) 2169-2174, to re-equilibrate the membrane. Clearly", -- "protein equilibration might require longer.\n", -- "\n" -+ "(see Wolf et al, J Comp Chem 31 (2010) 2169-2174), to re-equilibrate the membrane. Clearly", -+ "protein equilibration might require longer.[PAR]" - }; - t_commrec *cr; - t_filenm fnm[] = { -@@ -4543,7 +3691,7 @@ int gmx_membed(int argc,char *argv[]) - only started at mdrunner_threads, though. */ - if (nthreads<1) - { -- nthreads=tMPI_Get_recommended_nthreads(); -+ nthreads=tMPI_Thread_get_hw_number(); - } - #else - nthreads=1; -diff --git a/src/tools/gmx_morph.c b/src/tools/gmx_morph.c -index f7f11e2..e877e4e 100644 ---- a/src/tools/gmx_morph.c -+++ b/src/tools/gmx_morph.c -@@ -74,13 +74,13 @@ int gmx_morph(int argc,char *argv[]) - "the [TT]-ninterm[tt] flag. The first and last flag correspond to the way of", - "interpolating: 0 corresponds to input structure 1 while", - "1 corresponds to input structure 2.", -- "If you specify first < 0 or last > 1 extrapolation will be", -- "on the path from input structure x1 to x2. In general the coordinates", -+ "If you specify [TT]-first[tt] < 0 or [TT]-last[tt] > 1 extrapolation will be", -+ "on the path from input structure x1 to x2. In general, the coordinates", - "of the intermediate x(i) out of N total intermidates correspond to:[PAR]", - "x(i) = x1 + (first+(i/(N-1))*(last-first))*(x2-x1)[PAR]", - "Finally the RMSD with respect to both input structures can be computed", -- "if explicitly selected ([TT]-or[tt] option). In that case an index file may be", -- "read to select what group RMS is computed from." -+ "if explicitly selected ([TT]-or[tt] option). In that case, an index file may be", -+ "read to select the group from which the RMS is computed." - }; - t_filenm fnm[] = { - { efSTX, "-f1", "conf1", ffREAD }, -diff --git a/src/tools/gmx_nmeig.c b/src/tools/gmx_nmeig.c -index e547e04..13793d1 100644 ---- a/src/tools/gmx_nmeig.c -+++ b/src/tools/gmx_nmeig.c -@@ -267,19 +267,19 @@ int gmx_nmeig(int argc,char *argv[]) - "output. In this case, they will no longer be exactly orthogonal in the", - "standard Cartesian norm, but in the mass-weighted norm they would be.[PAR]", - "This program can be optionally used to compute quantum corrections to heat capacity", -- "and enthalpy by providing an extra file argument -qcorr. See gromacs", -- "manual chapter 1 for details. The result includes subtracting a harmonic", -+ "and enthalpy by providing an extra file argument [TT]-qcorr[tt]. See the GROMACS", -+ "manual, Chapter 1, for details. The result includes subtracting a harmonic", - "degree of freedom at the given temperature.", - "The total correction is printed on the terminal screen.", -- "The recommended way of getting the corrections out is:", -- "g_nmeig -s topol.tpr -f nm.mtx -first 7 -last 10000 -T 300 -qc [-constr]", -- "The constr should be used when bond constraints were used during the", -- "simulation [BB]for all the covalent bonds[bb]. If this is not the case", -- "you need to analyse the quant_corr.xvg file yourself.[PAR]", -- "To make things more flexible, the program can also take vsites into account", -+ "The recommended way of getting the corrections out is:[PAR]", -+ "[TT]g_nmeig -s topol.tpr -f nm.mtx -first 7 -last 10000 -T 300 -qc [-constr][tt][PAR]", -+ "The [TT]-constr[tt] option should be used when bond constraints were used during the", -+ "simulation [BB]for all the covalent bonds[bb]. If this is not the case, ", -+ "you need to analyze the [TT]quant_corr.xvg[tt] file yourself.[PAR]", -+ "To make things more flexible, the program can also take virtual sites into account", - "when computing quantum corrections. When selecting [TT]-constr[tt] and", -- "[TT]-qc[tt] the [TT]-begin[tt] and [TT]-end[tt] options will be set automatically as well.", -- "Again, if you think you know it better, please check the eigenfreq.xvg", -+ "[TT]-qc[tt], the [TT]-begin[tt] and [TT]-end[tt] options will be set automatically as well.", -+ "Again, if you think you know it better, please check the [TT]eigenfreq.xvg[tt]", - "output." - }; - -diff --git a/src/tools/gmx_order.c b/src/tools/gmx_order.c -index 7723c09..3b21564 100644 ---- a/src/tools/gmx_order.c -+++ b/src/tools/gmx_order.c -@@ -801,7 +801,7 @@ int gmx_order(int argc,char *argv[]) - { "-d", FALSE, etENUM, {normal_axis}, - "Direction of the normal on the membrane" }, - { "-sl", FALSE, etINT, {&nslices}, -- "Calculate order parameter as function of boxlength, dividing the box" -+ "Calculate order parameter as function of box length, dividing the box" - " in #nr slices." }, - { "-szonly", FALSE, etBOOL,{&bSzonly}, - "Only give Sz element of order tensor. (axis can be specified with [TT]-d[tt])" }, -diff --git a/src/tools/gmx_pme_error.c b/src/tools/gmx_pme_error.c -index 387a764..42763cf 100644 ---- a/src/tools/gmx_pme_error.c -+++ b/src/tools/gmx_pme_error.c -@@ -497,12 +497,12 @@ static real estimate_reciprocal( - x_per_core = xtot; - } - /* --#ifdef GMX_MPI -+#ifdef GMX_LIB_MPI - MPI_Barrier(MPI_COMM_WORLD); - #endif - */ - --#ifdef GMX_MPI -+#ifdef GMX_LIB_MPI - #ifdef TAKETIME - if (MASTER(cr)) - t0 = MPI_Wtime(); -@@ -728,7 +728,7 @@ static real estimate_reciprocal( - if (MASTER(cr)) - fprintf(stderr, "\n"); - -- -+#ifdef GMX_LIB_MPI - #ifdef TAKETIME - if (MASTER(cr)) - { -@@ -736,6 +736,7 @@ static real estimate_reciprocal( - fprintf(fp_out, "Recip. err. est. took : %lf s\n", t1); - } - #endif -+#endif - - #ifdef DEBUG - if (PAR(cr)) -@@ -1078,7 +1079,7 @@ int gmx_pme_error(int argc,char *argv[]) - - cr = init_par(&argc,&argv); - --#ifdef GMX_MPI -+#ifdef GMX_LIB_MPI - MPI_Barrier(MPI_COMM_WORLD); - #endif - -diff --git a/src/tools/gmx_potential.c b/src/tools/gmx_potential.c -index c674551..8b3705a 100644 ---- a/src/tools/gmx_potential.c -+++ b/src/tools/gmx_potential.c -@@ -55,6 +55,11 @@ - #include "index.h" - #include "gmx_ana.h" - -+/* Suppress Cygwin compiler warnings from using newlib version of -+ * ctype.h */ -+#ifdef GMX_CYGWIN -+#undef toupper -+#endif - - #define EPS0 8.85419E-12 - #define ELC 1.60219E-19 -diff --git a/src/tools/gmx_rama.c b/src/tools/gmx_rama.c -index 4ba79d9..4d25a35 100644 ---- a/src/tools/gmx_rama.c -+++ b/src/tools/gmx_rama.c -@@ -69,7 +69,7 @@ static void plot_rama(FILE *out,t_xrama *xr) - int gmx_rama(int argc,char *argv[]) - { - const char *desc[] = { -- "[TT]g_rama[tt] selects the Phi/Psi dihedral combinations from your topology file", -+ "[TT]g_rama[tt] selects the [GRK]phi[grk]/[GRK]psi[grk] dihedral combinations from your topology file", - "and computes these as a function of time.", - "Using simple Unix tools such as [IT]grep[it] you can select out", - "specific residues." -diff --git a/src/tools/gmx_rdf.c b/src/tools/gmx_rdf.c -index 117f493..4c0b3a7 100644 ---- a/src/tools/gmx_rdf.c -+++ b/src/tools/gmx_rdf.c -@@ -630,30 +630,30 @@ int gmx_rdf(int argc,char *argv[]) - "The normal method is around a (set of) particle(s), the other methods", - "are around the center of mass of a set of particles ([TT]-com[tt])", - "or to the closest particle in a set ([TT]-surf[tt]).", -- "With all methods rdf's can also be calculated around axes parallel", -- "to the z-axis with option [TT]-xy[tt].", -+ "With all methods, the RDF can also be calculated around axes parallel", -+ "to the [IT]z[it]-axis with option [TT]-xy[tt].", - "With option [TT]-surf[tt] normalization can not be used.[PAR]", -- "The option [TT]-rdf[tt] sets the type of rdf to be computed.", -+ "The option [TT]-rdf[tt] sets the type of RDF to be computed.", - "Default is for atoms or particles, but one can also select center", -- "of mass or geometry of molecules or residues. In all cases only", -+ "of mass or geometry of molecules or residues. In all cases, only", - "the atoms in the index groups are taken into account.", -- "For molecules and/or the center of mass option a run input file", -+ "For molecules and/or the center of mass option, a run input file", - "is required.", -- "Other weighting than COM or COG can currently only be achieved", -+ "Weighting other than COM or COG can currently only be achieved", - "by providing a run input file with different masses.", - "Options [TT]-com[tt] and [TT]-surf[tt] also work in conjunction", - "with [TT]-rdf[tt].[PAR]", - "If a run input file is supplied ([TT]-s[tt]) and [TT]-rdf[tt] is set", - "to [TT]atom[tt], exclusions defined", -- "in that file are taken into account when calculating the rdf.", -+ "in that file are taken into account when calculating the RDF.", - "The option [TT]-cut[tt] is meant as an alternative way to avoid", -- "intramolecular peaks in the rdf plot.", -+ "intramolecular peaks in the RDF plot.", - "It is however better to supply a run input file with a higher number of", -- "exclusions. For eg. benzene a topology with nrexcl set to 5", -- "would eliminate all intramolecular contributions to the rdf.", -+ "exclusions. For e.g. benzene a topology, setting nrexcl to 5", -+ "would eliminate all intramolecular contributions to the RDF.", - "Note that all atoms in the selected groups are used, also the ones", - "that don't have Lennard-Jones interactions.[PAR]", -- "Option [TT]-cn[tt] produces the cumulative number rdf,", -+ "Option [TT]-cn[tt] produces the cumulative number RDF,", - "i.e. the average number of particles within a distance r.[PAR]", - "To bridge the gap between theory and experiment structure factors can", - "be computed (option [TT]-sq[tt]). The algorithm uses FFT, the grid", -diff --git a/src/tools/gmx_rms.c b/src/tools/gmx_rms.c -index a363bb4..a848bb9 100644 ---- a/src/tools/gmx_rms.c -+++ b/src/tools/gmx_rms.c -@@ -95,19 +95,19 @@ int gmx_rms(int argc, char *argv[]) - *desc[] = - { - "[TT]g_rms[tt] compares two structures by computing the root mean square", -- "deviation (RMSD), the size-independent 'rho' similarity parameter", -- "(rho) or the scaled rho (rhosc), ", -- "see Maiorov & Crippen, PROTEINS [BB]22[bb], 273 (1995).", -+ "deviation (RMSD), the size-independent [GRK]rho[grk] similarity parameter", -+ "([TT]rho[tt]) or the scaled [GRK]rho[grk] ([TT]rhosc[tt]), ", -+ "see Maiorov & Crippen, Proteins [BB]22[bb], 273 (1995).", - "This is selected by [TT]-what[tt].[PAR]" - -- "Each structure from a trajectory ([TT]-f[tt]) is compared to a", -+ "Each structure from a trajectory ([TT]-f[tt]) is compared to a", - "reference structure. The reference structure", - "is taken from the structure file ([TT]-s[tt]).[PAR]", - - "With option [TT]-mir[tt] also a comparison with the mirror image of", - "the reference structure is calculated.", - "This is useful as a reference for 'significant' values, see", -- "Maiorov & Crippen, PROTEINS [BB]22[bb], 273 (1995).[PAR]", -+ "Maiorov & Crippen, Proteins [BB]22[bb], 273 (1995).[PAR]", - - "Option [TT]-prev[tt] produces the comparison with a previous frame", - "the specified number of frames ago.[PAR]", -@@ -124,9 +124,9 @@ int gmx_rms(int argc, char *argv[]) - "Option [TT]-mw[tt] controls whether mass weighting is done or not.", - "If you select the option (default) and ", - "supply a valid [TT].tpr[tt] file masses will be taken from there, ", -- "otherwise the masses will be deduced from the atommass.dat file in", -- "the GROMACS library directory. This is fine for proteins but not", -- "necessarily for other molecules. A default mass of 12.011 amu (Carbon)", -+ "otherwise the masses will be deduced from the [TT]atommass.dat[tt] file in", -+ "[TT]GMXLIB[tt]. This is fine for proteins, but not", -+ "necessarily for other molecules. A default mass of 12.011 amu (carbon)", - "is assigned to unknown atoms. You can check whether this happend by", - "turning on the [TT]-debug[tt] flag and inspecting the log file.[PAR]", - -diff --git a/src/tools/gmx_rmsdist.c b/src/tools/gmx_rmsdist.c -index db20963..93e0d6a 100644 ---- a/src/tools/gmx_rmsdist.c -+++ b/src/tools/gmx_rmsdist.c -@@ -513,7 +513,7 @@ int gmx_rmsdist (int argc,char *argv[]) - "which has the advantage that no fit is needed like in standard RMS", - "deviation as computed by [TT]g_rms[tt].", - "The reference structure is taken from the structure file.", -- "The rmsd at time t is calculated as the rms", -+ "The RMSD at time t is calculated as the RMS", - "of the differences in distance between atom-pairs in the reference", - "structure and the structure at time t.[PAR]", - "[TT]g_rmsdist[tt] can also produce matrices of the rms distances, rms distances", -diff --git a/src/tools/gmx_rotmat.c b/src/tools/gmx_rotmat.c -index 2adde5d..eea8137 100644 ---- a/src/tools/gmx_rotmat.c -+++ b/src/tools/gmx_rotmat.c -@@ -193,17 +193,17 @@ int gmx_rotmat(int argc,char *argv[]) - "determining the orientation of a molecule", - "at an interface, possibly on a trajectory produced with", - "[TT]trjconv -fit rotxy+transxy[tt] to remove the rotation", -- "in the xy-plane.", -+ "in the [IT]x-y[it] plane.", - "[PAR]", - "Option [TT]-ref[tt] determines a reference structure for fitting,", - "instead of using the structure from [TT]-s[tt]. The structure with", - "the lowest sum of RMSD's to all other structures is used.", - "Since the computational cost of this procedure grows with", - "the square of the number of frames, the [TT]-skip[tt] option", -- "can be useful. A full fit or only a fit in the x/y plane can", -+ "can be useful. A full fit or only a fit in the [IT]x-y[it] plane can", - "be performed.", - "[PAR]", -- "Option [TT]-fitxy[tt] fits in the x/y plane before determining", -+ "Option [TT]-fitxy[tt] fits in the [IT]x-y[it] plane before determining", - "the rotation matrix." - }; - const char *reffit[] = -diff --git a/src/tools/gmx_saltbr.c b/src/tools/gmx_saltbr.c -index 9c5ee3c..84a9247 100644 ---- a/src/tools/gmx_saltbr.c -+++ b/src/tools/gmx_saltbr.c -@@ -122,12 +122,12 @@ int gmx_saltbr(int argc,char *argv[]) - const char *desc[] = { - "[TT]g_saltbr[tt] plots the distance between all combination of charged groups", - "as a function of time. The groups are combined in different ways.", -- "A minimum distance can be given, (ie. a cut-off), then groups", -- "that are never closer than that distance will not be plotted.[BR]", -+ "A minimum distance can be given (i.e. a cut-off), such that groups", -+ "that are never closer than that distance will not be plotted.[PAR]", - "Output will be in a number of fixed filenames, [TT]min-min.xvg[tt], [TT]plus-min.xvg[tt]", -- "and [TT]plus-plus.xvg[tt], or files for every individual ion-pair if the [TT]-sep[tt]", -- "option is selected. In this case files are named as [TT]sb-ResnameResnr-Atomnr[tt].", -- "There may be many such files." -+ "and [TT]plus-plus.xvg[tt], or files for every individual ion pair if the [TT]-sep[tt]", -+ "option is selected. In this case, files are named as [TT]sb-(Resname)(Resnr)-(Atomnr)[tt].", -+ "There may be [BB]many[bb] such files." - }; - static gmx_bool bSep=FALSE; - static real truncate=1000.0; -diff --git a/src/tools/gmx_sas.c b/src/tools/gmx_sas.c -index ac50bd6..4cd049d 100644 ---- a/src/tools/gmx_sas.c -+++ b/src/tools/gmx_sas.c -@@ -566,7 +566,7 @@ int gmx_sas(int argc,char *argv[]) - { - const char *desc[] = { - "[TT]g_sas[tt] computes hydrophobic, hydrophilic and total solvent accessible surface area.", -- "As a side effect the Connolly surface can be generated as well in", -+ "As a side effect, the Connolly surface can be generated as well in", - "a [TT].pdb[tt] file where the nodes are represented as atoms and the vertices", - "connecting the nearest nodes as CONECT records.", - "The program will ask for a group for the surface calculation", -@@ -575,7 +575,7 @@ int gmx_sas(int argc,char *argv[]) - "The output group can be the whole or part of the calculation group.", - "The average and standard deviation of the area over the trajectory can be plotted", - "per residue and atom as well (options [TT]-or[tt] and [TT]-oa[tt]).", -- "In combination with the latter option an [TT]itp[tt] file can be", -+ "In combination with the latter option an [TT].itp[tt] file can be", - "generated (option [TT]-i[tt])", - "which can be used to restrain surface atoms.[PAR]", - "By default, periodic boundary conditions are taken into account,", -@@ -585,7 +585,7 @@ int gmx_sas(int argc,char *argv[]) - "Please consider whether the normal probe radius is appropriate", - "in this case or whether you would rather use e.g. 0. It is good", - "to keep in mind that the results for volume and density are very", -- "approximate, in e.g. ice Ih one can easily fit water molecules in the", -+ "approximate. For example, in ice Ih, one can easily fit water molecules in the", - "pores which would yield a volume that is too low, and surface area and density", - "that are both too high." - }; -@@ -610,9 +610,9 @@ int gmx_sas(int argc,char *argv[]) - { "-pbc", FALSE, etBOOL, {&bPBC}, - "Take periodicity into account" }, - { "-prot", FALSE, etBOOL, {&bSave}, -- "Output the protein to the connelly [TT].pdb[tt] file too" }, -+ "Output the protein to the Connelly [TT].pdb[tt] file too" }, - { "-dgs", FALSE, etREAL, {&dgs_default}, -- "default value for solvation free energy per area (kJ/mol/nm^2)" } -+ "Default value for solvation free energy per area (kJ/mol/nm^2)" } - }; - t_filenm fnm[] = { - { efTRX, "-f", NULL, ffREAD }, -diff --git a/src/tools/gmx_sgangle.c b/src/tools/gmx_sgangle.c -index 47ab299..cde0e64 100644 ---- a/src/tools/gmx_sgangle.c -+++ b/src/tools/gmx_sgangle.c -@@ -445,7 +445,7 @@ int gmx_sgangle(int argc,char *argv[]) - "If [TT]-one[tt] is set, only one group should be specified in the index", - "file and the angle between this group at time 0 and t will be computed.", - "The angles calculated depend on the order in which the atoms are ", -- "given. Giving for instance 5 6 will rotate the vector 5-6 with ", -+ "given. Giving, for instance, 5 6 will rotate the vector 5-6 with ", - "180 degrees compared to giving 6 5. [PAR]If three atoms are given, ", - "the normal on the plane spanned by those three atoms will be", - "calculated, using the formula P1P2 x P1P3.", -@@ -470,7 +470,7 @@ int gmx_sgangle(int argc,char *argv[]) - { "-one", FALSE, etBOOL, {&bOne}, - "Only one group compute angle between vector at time zero and time t"}, - { "-z", FALSE, etBOOL, {&bZ}, -- "Use the Z-axis as reference" } -+ "Use the [IT]z[it]-axis as reference" } - }; - #define NPA asize(pa) - -diff --git a/src/tools/gmx_sham.c b/src/tools/gmx_sham.c -index 91b1e35..63b8c67 100644 ---- a/src/tools/gmx_sham.c -+++ b/src/tools/gmx_sham.c -@@ -686,10 +686,10 @@ int gmx_sham(int argc,char *argv[]) - "make enthalpy (option [TT]-lsh[tt]) and entropy (option [TT]-lss[tt])", - "plots. The histograms can be made for any quantities the user supplies.", - "A line in the input file may start with a time", -- "(see option [TT]-time[tt]) and any number of y values may follow.", -+ "(see option [TT]-time[tt]) and any number of [IT]y[it]-values may follow.", - "Multiple sets can also be", - "read when they are separated by & (option [TT]-n[tt]),", -- "in this case only one y value is read from each line.", -+ "in this case only one [IT]y[it]-value is read from each line.", - "All lines starting with # and @ are skipped.", - "[PAR]", - "Option [TT]-ge[tt] can be used to supply a file with free energies", -@@ -699,7 +699,7 @@ int gmx_sham(int argc,char *argv[]) - "[PAR]", - "Option [TT]-ene[tt] can be used to supply a file with energies.", - "These energies are used as a weighting function in the single", -- "histogram analysis method by Kumar et. al. When temperatures", -+ "histogram analysis method by Kumar et al. When temperatures", - "are supplied (as a second column in the file), an experimental", - "weighting scheme is applied. In addition the vales", - "are used for making enthalpy and entropy plots.", -@@ -709,7 +709,7 @@ int gmx_sham(int argc,char *argv[]) - "sampled by two particles increases with increasing distance.", - "Depending on what one would like to show, one can choose to correct", - "the histogram and free-energy for this volume effect.", -- "The probability is normalized by r and r^2 for a dimension of 2 and 3", -+ "The probability is normalized by r and r^2 for dimensions of 2 and 3, ", - "respectively.", - "A value of -1 is used to indicate an angle in degrees between two", - "vectors: a sin(angle) normalization will be applied.", -diff --git a/src/tools/gmx_sorient.c b/src/tools/gmx_sorient.c -index 53862d6..213eb7f 100644 ---- a/src/tools/gmx_sorient.c -+++ b/src/tools/gmx_sorient.c -@@ -127,23 +127,23 @@ int gmx_sorient(int argc,char *argv[]) - const char *desc[] = { - "[TT]g_sorient[tt] analyzes solvent orientation around solutes.", - "It calculates two angles between the vector from one or more", -- "reference positions to the first atom of each solvent molecule:[BR]", -- "theta1: the angle with the vector from the first atom of the solvent", -+ "reference positions to the first atom of each solvent molecule:[PAR]", -+ "[GRK]theta[grk]1: the angle with the vector from the first atom of the solvent", - "molecule to the midpoint between atoms 2 and 3.[BR]", -- "theta2: the angle with the normal of the solvent plane, defined by the", -- "same three atoms, or when the option [TT]-v23[tt] is set", -- "the angle with the vector between atoms 2 and 3.[BR]", -+ "[GRK]theta[grk]2: the angle with the normal of the solvent plane, defined by the", -+ "same three atoms, or, when the option [TT]-v23[tt] is set, ", -+ "the angle with the vector between atoms 2 and 3.[PAR]", - "The reference can be a set of atoms or", - "the center of mass of a set of atoms. The group of solvent atoms should", - "consist of 3 atoms per solvent molecule.", - "Only solvent molecules between [TT]-rmin[tt] and [TT]-rmax[tt] are", - "considered for [TT]-o[tt] and [TT]-no[tt] each frame.[PAR]", -- "[TT]-o[tt]: distribtion of cos(theta1) for rmin<=r<=rmax.[PAR]", -- "[TT]-no[tt]: distribution of cos(theta2) for rmin<=r<=rmax.[PAR]", -- "[TT]-ro[tt]: and <3cos^2(theta2)-1> as a function of the", -+ "[TT]-o[tt]: distribtion of cos([GRK]theta[grk]1) for rmin<=r<=rmax.[PAR]", -+ "[TT]-no[tt]: distribution of cos([GRK]theta[grk]2) for rmin<=r<=rmax.[PAR]", -+ "[TT]-ro[tt]: and <3cos^2([GRK]theta[grk]2)-1> as a function of the", - "distance.[PAR]", - "[TT]-co[tt]: the sum over all solvent molecules within distance r", -- "of cos(theta1) and 3cos^2(theta2)-1 as a function of r.[PAR]", -+ "of cos([GRK]theta[grk]1) and 3cos^2([GRK]theta[grk]2)-1 as a function of r.[PAR]", - "[TT]-rc[tt]: the distribution of the solvent molecules as a function of r" - }; - -diff --git a/src/tools/gmx_spatial.c b/src/tools/gmx_spatial.c -index 9e146fe..1cb9ffb 100644 ---- a/src/tools/gmx_spatial.c -+++ b/src/tools/gmx_spatial.c -@@ -65,41 +65,41 @@ int gmx_spatial(int argc,char *argv[]) - "[TT]g_spatial[tt] calculates the spatial distribution function and ", - "outputs it in a form that can be read by VMD as Gaussian98 cube format. ", - "This was developed from template.c (GROMACS-3.3). ", -- "For a system of 32K atoms and a 50ns trajectory, the SDF can be generated ", -+ "For a system of 32,000 atoms and a 50 ns trajectory, the SDF can be generated ", - "in about 30 minutes, with most of the time dedicated to the two runs through ", - "[TT]trjconv[tt] that are required to center everything properly. ", - "This also takes a whole bunch of space (3 copies of the [TT].xtc[tt] file). ", - "Still, the pictures are pretty and very informative when the fitted selection is properly made. ", -- "3-4 atoms in a widely mobile group like a free amino acid in solution works ", -+ "3-4 atoms in a widely mobile group (like a free amino acid in solution) works ", - "well, or select the protein backbone in a stable folded structure to get the SDF ", - "of solvent and look at the time-averaged solvation shell. ", -- "It is also possible using this program to generate the SDF based on some arbitrarty ", -+ "It is also possible using this program to generate the SDF based on some arbitrary ", - "Cartesian coordinate. To do that, simply omit the preliminary [TT]trjconv[tt] steps. \n", - "USAGE: \n", - "1. Use [TT]make_ndx[tt] to create a group containing the atoms around which you want the SDF \n", - "2. [TT]trjconv -s a.tpr -f a.xtc -o b.xtc -center tric -ur compact -pbc none[tt] \n", - "3. [TT]trjconv -s a.tpr -f b.xtc -o c.xtc -fit rot+trans[tt] \n", - "4. run [TT]g_spatial[tt] on the [TT].xtc[tt] output of step #3. \n", -- "5. Load grid.cube into VMD and view as an isosurface. \n", -- "*** Systems such as micelles will require [TT]trjconv -pbc cluster[tt] between steps 1 and 2\n", -- "WARNINGS: \n", -+ "5. Load [TT]grid.cube[tt] into VMD and view as an isosurface. \n", -+ "[BB]Note[bb] that systems such as micelles will require [TT]trjconv -pbc cluster[tt] between steps 1 and 2\n", -+ "WARNINGS:[BR]", - "The SDF will be generated for a cube that contains all bins that have some non-zero occupancy. ", - "However, the preparatory [TT]-fit rot+trans[tt] option to [TT]trjconv[tt] implies that your system will be rotating ", - "and translating in space (in order that the selected group does not). Therefore the values that are ", - "returned will only be valid for some region around your central group/coordinate that has full overlap ", - "with system volume throughout the entire translated/rotated system over the course of the trajectory. ", - "It is up to the user to ensure that this is the case. \n", -- "BUGS: \n", -+ "BUGS:[BR]", - "When the allocated memory is not large enough, a segmentation fault may occur. This is usually detected ", -- "and the program is halted prior to the fault while displaying a warning message suggesting the use of the [TT]-nab[tt] ", -+ "and the program is halted prior to the fault while displaying a warning message suggesting the use of the [TT]-nab[tt] (Number of Additional Bins)", - "option. However, the program does not detect all such events. If you encounter a segmentation fault, run it again ", - "with an increased [TT]-nab[tt] value. \n", -- "RISKY OPTIONS: \n", -+ "RISKY OPTIONS:[BR]", - "To reduce the amount of space and time required, you can output only the coords ", - "that are going to be used in the first and subsequent run through [TT]trjconv[tt]. ", - "However, be sure to set the [TT]-nab[tt] option to a sufficiently high value since ", -- "memory is allocated for cube bins based on the initial coords and the [TT]-nab[tt] ", -- "(Number of Additional Bins) option value. \n" -+ "memory is allocated for cube bins based on the initial coordinates and the [TT]-nab[tt] ", -+ "option value. \n" - }; - - static gmx_bool bPBC=FALSE; -diff --git a/src/tools/gmx_spol.c b/src/tools/gmx_spol.c -index 45ce0fd..dc99082 100644 ---- a/src/tools/gmx_spol.c -+++ b/src/tools/gmx_spol.c -@@ -156,7 +156,7 @@ int gmx_spol(int argc,char *argv[]) - "the inner product of the distance vector", - "and the dipole of the solvent molecule is determined.", - "For solvent molecules with net charge (ions), the net charge of the ion", -- "is subtracted evenly at all atoms in the selection of each ion.", -+ "is subtracted evenly from all atoms in the selection of each ion.", - "The average of these dipole components is printed.", - "The same is done for the polarization, where the average dipole is", - "subtracted from the instantaneous dipole. The magnitude of the average", -diff --git a/src/tools/gmx_tcaf.c b/src/tools/gmx_tcaf.c -index cbf9586..dee6fab 100644 ---- a/src/tools/gmx_tcaf.c -+++ b/src/tools/gmx_tcaf.c -@@ -218,34 +218,34 @@ int gmx_tcaf(int argc,char *argv[]) - { - const char *desc[] = { - "[TT]g_tcaf[tt] computes tranverse current autocorrelations.", -- "These are used to estimate the shear viscosity eta.", -- "For details see: Palmer, JCP 49 (1994) pp 359-366.[PAR]", -+ "These are used to estimate the shear viscosity, [GRK]eta[grk].", -+ "For details see: Palmer, Phys. Rev. E 49 (1994) pp 359-366.[PAR]", - "Transverse currents are calculated using the", -- "k-vectors (1,0,0) and (2,0,0) each also in the y- and z-direction,", -+ "k-vectors (1,0,0) and (2,0,0) each also in the [IT]y[it]- and [IT]z[it]-direction,", - "(1,1,0) and (1,-1,0) each also in the 2 other planes (these vectors", - "are not independent) and (1,1,1) and the 3 other box diagonals (also", - "not independent). For each k-vector the sine and cosine are used, in", - "combination with the velocity in 2 perpendicular directions. This gives", - "a total of 16*2*2=64 transverse currents. One autocorrelation is", -- "calculated fitted for each k-vector, which gives 16 tcaf's. Each of", -- "these tcaf's is fitted to f(t) = exp(-v)(cosh(Wv) + 1/W sinh(Wv)),", -- "v = -t/(2 tau), W = sqrt(1 - 4 tau eta/rho k^2), which gives 16 tau's", -- "and eta's. The fit weights decay with time as exp(-t/wt), the tcaf and", -+ "calculated fitted for each k-vector, which gives 16 TCAF's. Each of", -+ "these TCAF's is fitted to f(t) = exp(-v)(cosh(Wv) + 1/W sinh(Wv)),", -+ "v = -t/(2 [GRK]tau[grk]), W = sqrt(1 - 4 [GRK]tau[grk] [GRK]eta[grk]/[GRK]rho[grk] k^2), which gives 16 values of [GRK]tau[grk]", -+ "and [GRK]eta[grk]. The fit weights decay with time as exp(-t/wt), and the TCAF and", - "fit are calculated up to time 5*wt.", -- "The eta's should be fitted to 1 - a eta(k) k^2, from which", -+ "The [GRK]eta[grk] values should be fitted to 1 - a [GRK]eta[grk](k) k^2, from which", - "one can estimate the shear viscosity at k=0.[PAR]", - "When the box is cubic, one can use the option [TT]-oc[tt], which", -- "averages the tcaf's over all k-vectors with the same length.", -+ "averages the TCAF's over all k-vectors with the same length.", - "This results in more accurate tcaf's.", -- "Both the cubic tcaf's and fits are written to [TT]-oc[tt]", -- "The cubic eta estimates are also written to [TT]-ov[tt].[PAR]", -- "With option [TT]-mol[tt] the transverse current is determined of", -- "molecules instead of atoms. In this case the index group should", -+ "Both the cubic TCAF's and fits are written to [TT]-oc[tt]", -+ "The cubic [GRK]eta[grk] estimates are also written to [TT]-ov[tt].[PAR]", -+ "With option [TT]-mol[tt], the transverse current is determined of", -+ "molecules instead of atoms. In this case, the index group should", - "consist of molecule numbers instead of atom numbers.[PAR]", - "The k-dependent viscosities in the [TT]-ov[tt] file should be", -- "fitted to eta(k) = eta0 (1 - a k^2) to obtain the viscosity at", -+ "fitted to [GRK]eta[grk](k) = [GRK]eta[grk]0 (1 - a k^2) to obtain the viscosity at", - "infinite wavelength.[PAR]", -- "NOTE: make sure you write coordinates and velocities often enough.", -+ "[BB]Note:[bb] make sure you write coordinates and velocities often enough.", - "The initial, non-exponential, part of the autocorrelation function", - "is very important for obtaining a good fit." - }; -diff --git a/src/tools/gmx_trjcat.c b/src/tools/gmx_trjcat.c -index c06c23c..2ca470d 100644 ---- a/src/tools/gmx_trjcat.c -+++ b/src/tools/gmx_trjcat.c -@@ -438,7 +438,7 @@ int gmx_trjcat(int argc, char *argv[]) - { "-dt", FALSE, etTIME, - { &dt }, "Only write frame when t MOD dt = first time (%t)" }, - { "-prec", FALSE, etINT, -- { &prec }, "Precision for .xtc and .gro writing in number of decimal places" }, -+ { &prec }, "Precision for [TT].xtc[tt] and [TT].gro[tt] writing in number of decimal places" }, - { "-vel", FALSE, etBOOL, - { &bVels }, "Read and write velocities if possible" }, - { "-settime", FALSE, etBOOL, -@@ -446,11 +446,11 @@ int gmx_trjcat(int argc, char *argv[]) - { "-sort", FALSE, etBOOL, - { &bSort }, "Sort trajectory files (not frames)" }, - { "-keeplast", FALSE, etBOOL, -- { &bKeepLast }, "keep overlapping frames at end of trajectory" }, -+ { &bKeepLast }, "Keep overlapping frames at end of trajectory" }, - { "-overwrite", FALSE, etBOOL, -- { &bOverwrite }, "overwrite overlapping frames during appending" }, -+ { &bOverwrite }, "Overwrite overlapping frames during appending" }, - { "-cat", FALSE, etBOOL, -- { &bCat }, "do not discard double time frames" } }; -+ { &bCat }, "Do not discard double time frames" } }; - #define npargs asize(pa) - int ftpin, i, frame, frame_out, step = 0, trjout = 0; - t_trxstatus *status; -diff --git a/src/tools/gmx_trjorder.c b/src/tools/gmx_trjorder.c -index fb4bc02..6c2d7c2 100644 ---- a/src/tools/gmx_trjorder.c -+++ b/src/tools/gmx_trjorder.c -@@ -99,7 +99,7 @@ int gmx_trjorder(int argc,char *argv[]) - "with any Gromacs program to analyze the n closest waters.", - "[PAR]", - "If the output file is a [TT].pdb[tt] file, the distance to the reference target", -- "will be stored in the B-factor field in order to color with e.g. rasmol.", -+ "will be stored in the B-factor field in order to color with e.g. Rasmol.", - "[PAR]", - "With option [TT]-nshell[tt] the number of molecules within a shell", - "of radius [TT]-r[tt] around the reference group are printed." -diff --git a/src/tools/gmx_tune_pme.c b/src/tools/gmx_tune_pme.c -index e70f5ea..f22d308 100644 ---- a/src/tools/gmx_tune_pme.c -+++ b/src/tools/gmx_tune_pme.c -@@ -1845,10 +1845,19 @@ static void create_command_line_snippets( - /* Skip options not meant for mdrun */ - if (!is_main_switch(opt)) - { -- /* Print it to a string buffer, strip away trailing whitespaces that pa_val also returns: */ -- sprintf(strbuf2, "%s", pa_val(&pa[i],buf,BUFLENGTH)); -- rtrim(strbuf2); -- sprintf(strbuf, "%s %s ", opt, strbuf2); -+ /* Boolean arguments need to be generated in the -[no]argname format */ -+ if (pa[i].type == etBOOL) -+ { -+ sprintf(strbuf,"-%s%s ",*pa[i].u.b ? "" : "no",opt+1); -+ } -+ else -+ { -+ /* Print it to a string buffer, strip away trailing whitespaces that pa_val also returns: */ -+ sprintf(strbuf2, "%s", pa_val(&pa[i],buf,BUFLENGTH)); -+ rtrim(strbuf2); -+ sprintf(strbuf, "%s %s ", opt, strbuf2); -+ } -+ - /* We need the -np (or -nt) switch in a separate buffer - whether or not it was set! */ - if (0 == strcmp(opt,np_or_nt)) - { -@@ -1997,7 +2006,7 @@ int gmx_tune_pme(int argc,char *argv[]) - "MPIRUN and MDRUN. If these are not present, 'mpirun' and 'mdrun'", - "will be used as defaults. Note that for certain MPI frameworks you", - "need to provide a machine- or hostfile. This can also be passed", -- "via the MPIRUN variable, e.g.", -+ "via the MPIRUN variable, e.g.[PAR]", - "[TT]export MPIRUN=\"/usr/local/mpirun -machinefile hosts\"[tt][PAR]", - "Please call [TT]g_tune_pme[tt] with the normal options you would pass to", - "[TT]mdrun[tt] and add [TT]-np[tt] for the number of processors to perform the", -@@ -2006,11 +2015,11 @@ int gmx_tune_pme(int argc,char *argv[]) - "[TT]g_tune_pme[tt] can test various real space / reciprocal space workloads", - "for you. With [TT]-ntpr[tt] you control how many extra [TT].tpr[tt] files will be", - "written with enlarged cutoffs and smaller fourier grids respectively.", -- "Typically, the first test (No. 0) will be with the settings from the input", -- "[TT].tpr[tt] file; the last test (No. [TT]ntpr[tt]) will have cutoffs multiplied", -+ "Typically, the first test (number 0) will be with the settings from the input", -+ "[TT].tpr[tt] file; the last test (number [TT]ntpr[tt]) will have cutoffs multiplied", - "by (and at the same time fourier grid dimensions divided by) the scaling", -- "factor [TT]-fac[tt] (default 1.2). The remaining [TT].tpr[tt] files will have about equally", -- "spaced values inbetween these extremes. Note that you can set [TT]-ntpr[tt] to 1", -+ "factor [TT]-fac[tt] (default 1.2). The remaining [TT].tpr[tt] files will have about ", -+ "equally-spaced values in between these extremes. [BB]Note[bb] that you can set [TT]-ntpr[tt] to 1", - "if you just want to find the optimal number of PME-only nodes; in that case", - "your input [TT].tpr[tt] file will remain unchanged.[PAR]", - "For the benchmark runs, the default of 1000 time steps should suffice for most", -@@ -2019,11 +2028,11 @@ int gmx_tune_pme(int argc,char *argv[]) - "are by default reset after 100 steps. For large systems", - "(>1M atoms) you may have to set [TT]-resetstep[tt] to a higher value.", - "From the 'DD' load imbalance entries in the md.log output file you", -- "can tell after how many steps the load is sufficiently balanced.[PAR]" -- "Example call: [TT]g_tune_pme -np 64 -s protein.tpr -launch[tt][PAR]", -+ "can tell after how many steps the load is sufficiently balanced. Example call:[PAR]" -+ "[TT]g_tune_pme -np 64 -s protein.tpr -launch[tt][PAR]", - "After calling [TT]mdrun[tt] several times, detailed performance information", -- "is available in the output file perf.out. ", -- "Note that during the benchmarks a couple of temporary files are written", -+ "is available in the output file [TT]perf.out.[tt] ", -+ "[BB]Note[bb] that during the benchmarks, a couple of temporary files are written", - "(options [TT]-b[tt]*), these will be automatically deleted after each test.[PAR]", - "If you want the simulation to be started automatically with the", - "optimized parameters, use the command line option [TT]-launch[tt].[PAR]", -@@ -2166,9 +2175,9 @@ int gmx_tune_pme(int argc,char *argv[]) - { "-np", FALSE, etINT, {&nnodes}, - "Number of nodes to run the tests on (must be > 2 for separate PME nodes)" }, - { "-npstring", FALSE, etENUM, {procstring}, -- "Specify the number of processors to $MPIRUN using this string"}, -+ "Specify the number of processors to [TT]$MPIRUN[tt] using this string"}, - { "-passall", FALSE, etBOOL, {&bPassAll}, -- "HIDDENPut arguments unknown to [TT]mdrun[tt] at the end of the command line. Can e.g. be used for debugging purposes. "}, -+ "HIDDENPut arguments unknown to [TT]mdrun[tt] at the end of the command line. Can be used for debugging purposes. "}, - { "-nt", FALSE, etINT, {&nthreads}, - "Number of threads to run the tests on (turns MPI & mpirun off)"}, - { "-r", FALSE, etINT, {&repeats}, -@@ -2186,15 +2195,15 @@ int gmx_tune_pme(int argc,char *argv[]) - { "-downfac", FALSE, etREAL, {&downfac}, - "Lower limit for rcoulomb scaling factor" }, - { "-ntpr", FALSE, etINT, {&ntprs}, -- "Number of [TT].tpr[tt] files to benchmark. Create these many files with scaling factors ranging from 1.0 to fac. If < 1, automatically choose the number of [TT].tpr[tt] files to test" }, -+ "Number of [TT].tpr[tt] files to benchmark. Create this many files with scaling factors ranging from 1.0 to fac. If < 1, automatically choose the number of [TT].tpr[tt] files to test" }, - { "-four", FALSE, etREAL, {&fs}, - "Use this fourierspacing value instead of the grid found in the [TT].tpr[tt] input file. (Spacing applies to a scaling factor of 1.0 if multiple [TT].tpr[tt] files are written)" }, - { "-steps", FALSE, etGMX_LARGE_INT, {&bench_nsteps}, -- "Take timings for these many steps in the benchmark runs" }, -+ "Take timings for this many steps in the benchmark runs" }, - { "-resetstep",FALSE, etINT, {&presteps}, -- "Let dlb equilibrate these many steps before timings are taken (reset cycle counters after these many steps)" }, -+ "Let dlb equilibrate this many steps before timings are taken (reset cycle counters after this many steps)" }, - { "-simsteps", FALSE, etGMX_LARGE_INT, {&new_sim_nsteps}, -- "If non-negative, perform these many steps in the real run (overwrite nsteps from [TT].tpr[tt], add [TT].cpt[tt] steps)" }, -+ "If non-negative, perform this many steps in the real run (overwrites nsteps from [TT].tpr[tt], add [TT].cpt[tt] steps)" }, - { "-launch", FALSE, etBOOL, {&bLaunch}, - "Lauch the real simulation after optimization" }, - /******************/ -@@ -2251,7 +2260,7 @@ int gmx_tune_pme(int argc,char *argv[]) - { "-rerunvsite", FALSE, etBOOL, {&bRerunVSite}, - "HIDDENRecalculate virtual site coordinates with [TT]-rerun[tt]" }, - { "-ionize", FALSE, etBOOL, {&bIonize}, -- "Do a simulation including the effect of an X-Ray bombardment on your system" }, -+ "Do a simulation including the effect of an X-ray bombardment on your system" }, - { "-confout", FALSE, etBOOL, {&bConfout}, - "HIDDENWrite the last configuration with [TT]-c[tt] and force checkpointing at the last step" }, - { "-stepout", FALSE, etINT, {&nstepout}, -diff --git a/src/tools/gmx_wham.c b/src/tools/gmx_wham.c -index a9b9ba0..0538bdc 100644 ---- a/src/tools/gmx_wham.c -+++ b/src/tools/gmx_wham.c -@@ -2549,13 +2549,13 @@ int gmx_wham(int argc,char *argv[]) - "which may be useful for, e.g. membranes.[PAR]", - "AUTOCORRELATIONS[BR]----------------[BR]", - "With [TT]-ac[tt], [TT]g_wham[tt] estimates the integrated autocorrelation ", -- "time (IACT) tau for each umbrella window and weights the respective ", -- "window with 1/[1+2*tau/dt]. The IACTs are written ", -+ "time (IACT) [GRK]tau[grk] for each umbrella window and weights the respective ", -+ "window with 1/[1+2*[GRK]tau[grk]/dt]. The IACTs are written ", - "to the file defined with [TT]-oiact[tt]. In verbose mode, all ", - "autocorrelation functions (ACFs) are written to [TT]hist_autocorr.xvg[tt]. ", - "Because the IACTs can be severely underestimated in case of limited ", - "sampling, option [TT]-acsig[tt] allows to smooth the IACTs along the ", -- "reaction coordinate with a Gaussian (sigma provided with [TT]-acsig[tt], ", -+ "reaction coordinate with a Gaussian ([GRK]sigma[grk] provided with [TT]-acsig[tt], ", - "see output in [TT]iact.xvg[tt]). Note that the IACTs are estimated by simple ", - "integration of the ACFs while the ACFs are larger 0.05.", - "If you prefer to compute the IACTs by a more sophisticated (but possibly ", -@@ -2616,7 +2616,7 @@ int gmx_wham(int argc,char *argv[]) - { "-max", FALSE, etREAL, {&opt.max}, - "Maximum coordinate in profile"}, - { "-auto", FALSE, etBOOL, {&opt.bAuto}, -- "determine min and max automatically"}, -+ "Determine min and max automatically"}, - { "-bins",FALSE, etINT, {&opt.bins}, - "Number of bins in profile"}, - { "-temp", FALSE, etREAL, {&opt.Temperature}, -@@ -2624,11 +2624,11 @@ int gmx_wham(int argc,char *argv[]) - { "-tol", FALSE, etREAL, {&opt.Tolerance}, - "Tolerance"}, - { "-v", FALSE, etBOOL, {&opt.verbose}, -- "verbose mode"}, -+ "Verbose mode"}, - { "-b", FALSE, etREAL, {&opt.tmin}, -- "first time to analyse (ps)"}, -+ "First time to analyse (ps)"}, - { "-e", FALSE, etREAL, {&opt.tmax}, -- "last time to analyse (ps)"}, -+ "Last time to analyse (ps)"}, - { "-dt", FALSE, etREAL, {&opt.dt}, - "Analyse only every dt ps"}, - { "-histonly", FALSE, etBOOL, {&opt.bHistOnly}, -@@ -2638,19 +2638,19 @@ int gmx_wham(int argc,char *argv[]) - { "-log", FALSE, etBOOL, {&opt.bLog}, - "Calculate the log of the profile before printing"}, - { "-unit", FALSE, etENUM, {en_unit}, -- "energy unit in case of log output" }, -+ "Energy unit in case of log output" }, - { "-zprof0", FALSE, etREAL, {&opt.zProf0}, - "Define profile to 0.0 at this position (with [TT]-log[tt])"}, - { "-cycl", FALSE, etBOOL, {&opt.bCycl}, - "Create cyclic/periodic profile. Assumes min and max are the same point."}, - { "-sym", FALSE, etBOOL, {&opt.bSym}, -- "symmetrize profile around z=0"}, -+ "Symmetrize profile around z=0"}, - { "-hist-eq", FALSE, etBOOL, {&opt.bHistEq}, - "HIDDENEnforce equal weight for all histograms. (Non-Weighed-HAM)"}, - { "-ac", FALSE, etBOOL, {&opt.bCalcTauInt}, -- "calculate integrated autocorrelation times and use in wham"}, -+ "Calculate integrated autocorrelation times and use in wham"}, - { "-acsig", FALSE, etREAL, {&opt.sigSmoothIact}, -- "Smooth autocorrelation times along reaction coordinate with Gaussian of this sigma"}, -+ "Smooth autocorrelation times along reaction coordinate with Gaussian of this [GRK]sigma[grk]"}, - { "-ac-trestart", FALSE, etREAL, {&opt.acTrestart}, - "When computing autocorrelation functions, restart computing every .. (ps)"}, - { "-acred", FALSE, etBOOL, {&opt.bAllowReduceIact}, -@@ -2659,15 +2659,15 @@ int gmx_wham(int argc,char *argv[]) - { "-nBootstrap", FALSE, etINT, {&opt.nBootStrap}, - "nr of bootstraps to estimate statistical uncertainty (e.g., 200)" }, - { "-bs-method", FALSE, etENUM, {en_bsMethod}, -- "bootstrap method" }, -+ "Bootstrap method" }, - { "-bs-tau", FALSE, etREAL, {&opt.tauBootStrap}, - "Autocorrelation time (ACT) assumed for all histograms. Use option [TT]-ac[tt] if ACT is unknown."}, - { "-bs-seed", FALSE, etINT, {&opt.bsSeed}, -- "seed for bootstrapping. (-1 = use time)"}, -+ "Seed for bootstrapping. (-1 = use time)"}, - { "-histbs-block", FALSE, etINT, {&opt.histBootStrapBlockLength}, -- "when mixing histograms only mix within blocks of [TT]-histbs-block[tt]."}, -+ "When mixing histograms only mix within blocks of [TT]-histbs-block[tt]."}, - { "-vbs", FALSE, etBOOL, {&opt.bs_verbose}, -- "verbose bootstrapping. Print the CDFs and a histogram file for each bootstrap."}, -+ "Verbose bootstrapping. Print the CDFs and a histogram file for each bootstrap."}, - { "-stepout", FALSE, etINT, {&opt.stepchange}, - "HIDDENWrite maximum change every ... (set to 1 with [TT]-v[tt])"}, - { "-updateContr", FALSE, etINT, {&opt.stepUpdateContrib}, -diff --git a/src/tools/gmx_wheel.c b/src/tools/gmx_wheel.c -index 580ec52..2a3dbd1 100644 ---- a/src/tools/gmx_wheel.c -+++ b/src/tools/gmx_wheel.c -@@ -205,7 +205,7 @@ int gmx_wheel(int argc,char *argv[]) - const char *desc[] = { - "[TT]g_wheel[tt] plots a helical wheel representation of your sequence.", - "The input sequence is in the [TT].dat[tt] file where the first line contains", -- "the number of residues and each consecutive line contains a residue" -+ "the number of residues and each consecutive line contains a residue " - "name." - }; - output_env_t oenv; -diff --git a/src/tools/gmx_xpm2ps.c b/src/tools/gmx_xpm2ps.c -index 89d803f..fb057f4 100644 ---- a/src/tools/gmx_xpm2ps.c -+++ b/src/tools/gmx_xpm2ps.c -@@ -1095,17 +1095,17 @@ int gmx_xpm2ps(int argc,char *argv[]) - "in the correct matrix format.", - "Matrix data may be generated by programs such as [TT]do_dssp[tt], [TT]g_rms[tt] or", - "[TT]g_mdmat[tt].[PAR]", -- "Parameters are set in the [TT]m2p[tt] file optionally supplied with", -- "[TT]-di[tt]. Reasonable defaults are provided. Settings for the y-axis", -- "default to those for the x-axis. Font names have a defaulting hierarchy:", -+ "Parameters are set in the [TT].m2p[tt] file optionally supplied with", -+ "[TT]-di[tt]. Reasonable defaults are provided. Settings for the [IT]y[it]-axis", -+ "default to those for the [IT]x[it]-axis. Font names have a defaulting hierarchy:", - "titlefont -> legendfont; titlefont -> (xfont -> yfont -> ytickfont)", - "-> xtickfont, e.g. setting titlefont sets all fonts, setting xfont", - "sets yfont, ytickfont and xtickfont.[PAR]", -- "When no [TT]m2p[tt] file is supplied, many settings are taken from", -+ "When no [TT].m2p[tt] file is supplied, many settings are taken from", - "command line options. The most important option is [TT]-size[tt],", - "which sets the size of the whole matrix in postscript units.", - "This option can be overridden with the [TT]-bx[tt] and [TT]-by[tt]", -- "options (and the corresponding parameters in the [TT]m2p[tt] file),", -+ "options (and the corresponding parameters in the [TT].m2p[tt] file),", - "which set the size of a single matrix element.[PAR]", - "With [TT]-f2[tt] a second matrix file can be supplied. Both matrix", - "files will be read simultaneously and the upper left half of the", -@@ -1125,7 +1125,7 @@ int gmx_xpm2ps(int argc,char *argv[]) - "with [TT]-cmin[tt] and [TT]-cmax[tt].[PAR]", - "[TT]-title[tt] can be set to [TT]none[tt] to suppress the title, or to", - "[TT]ylabel[tt] to show the title in the Y-label position (alongside", -- "the Y-axis).[PAR]", -+ "the [IT]y[it]-axis).[PAR]", - "With the [TT]-rainbow[tt] option, dull grayscale matrices can be turned", - "into attractive color pictures.[PAR]", - "Merged or rainbowed matrices can be written to an XPixelMap file with", -diff --git a/src/tools/interf.h b/src/tools/interf.h -new file mode 100644 -index 0000000..841dc2b ---- /dev/null -+++ b/src/tools/interf.h -@@ -0,0 +1,52 @@ -+/* -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * Green Red Orange Magenta Azure Cyan Skyblue -+ */ -+ -+#ifndef _interf_h -+#define _interf_h -+ -+#include "typedefs.h" -+ -+typedef struct { -+ real Z; /* Interface height-coordinate */ -+ real t; /* Interface thickness */ -+} t_interf; -+ -+static void init_interf(t_interf *surf) -+{ -+ surf->Z = 0; -+ surf->t = 0; -+} -+ -+#endif -diff --git a/src/tools/levenmar.c b/src/tools/levenmar.c -index 8bdb129..b967a40 100644 ---- a/src/tools/levenmar.c -+++ b/src/tools/levenmar.c -@@ -1,4 +1,5 @@ - /* -+ * $Id: levenmar.c,v 1.20 2004/01/23 18:11:02 lindahl Exp $ - * - * This source code is part of - * -diff --git a/src/tools/make_edi.c b/src/tools/make_edi.c -index 617f375..409fb47 100644 ---- a/src/tools/make_edi.c -+++ b/src/tools/make_edi.c -@@ -5,7 +5,7 @@ - * G R O M A C S - * - * GROningen MAchine for Chemical Simulations -- * -+ * - * VERSION 3.2.0 - * - * The make_edi program was generously contributed by Oliver Lange, based -@@ -15,7 +15,7 @@ - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. -- * -+ * - * If you want to redistribute modifications, please consider that - * scientific software is very special. Version control is crucial - - * bugs must be traceable. We will be happy to consider code for -@@ -62,18 +62,25 @@ - #include "rmpbc.h" - #include "txtdump.h" - #include "eigio.h" --#include "index.h" -+#include "index.h" - -+/* Suppress Cygwin compiler warnings from using newlib version of -+ * ctype.h */ -+#ifdef GMX_CYGWIN -+#undef isdigit -+#endif - - typedef struct --{ -+{ - real deltaF0; - gmx_bool bHarmonic; -+ gmx_bool bConstForce; /* Do constant force flooding instead of -+ evaluating a flooding potential */ - real tau; - real deltaF; -- real kT; -+ real kT; - real constEfl; -- real alpha2; -+ real alpha2; - } t_edflood; - - -@@ -93,7 +100,7 @@ typedef struct edipar - int nini; /* total Nr of atoms */ - gmx_bool fitmas; /* true if trans fit with cm */ - gmx_bool pcamas; /* true if mass-weighted PCA */ -- int presteps; /* number of steps to run without any -+ int presteps; /* number of steps to run without any - * perturbations ... just monitoring */ - int outfrq; /* freq (in steps) of writing to edo */ - int maxedsteps; /* max nr of steps per cycle */ -@@ -141,26 +148,26 @@ int sscan_list(int *list[], const char *str, const char *listname) { - - /*enums to define the different lexical stati */ - enum { sBefore, sNumber, sMinus, sRange, sZero, sSmaller, sError, sSteppedRange }; -- -+ - int status=sBefore; /*status of the deterministic automat to scan str */ - int number=0; - int end_number=0; -- -+ - char *start=NULL; /*holds the string of the number behind a ','*/ - char *end=NULL; /*holds the string of the number behind a '-' */ -- -+ - int nvecs=0; /* counts the number of vectors in the list*/ - - step=NULL; - snew(pos,n+4); - startpos=pos; - strcpy(pos,str); -- pos[n]=','; -+ pos[n]=','; - pos[n+1]='1'; - pos[n+2]='\0'; - - *list = NULL; -- -+ - while ((c=*pos)!=0) { - switch(status) { - /* expect a number */ -@@ -184,22 +191,22 @@ int sscan_list(int *list[], const char *str, const char *listname) { - else status=sError; break; - - /* have read a '-' -> expect a number */ -- case sMinus: -+ case sMinus: - if (isdigit(c)) { - end=pos; - status=sRange; break; - } else status=sError; break; -- -+ - case sSteppedRange: - if (isdigit(c)) { - if (step) { -- status=sError; break; -+ status=sError; break; - } else - step=pos; - status=sRange; - break; - } else status=sError; break; -- -+ - /* have read the number after a minus, expect ',' or ':' */ - case sRange: - if (c==',') { -@@ -228,7 +235,7 @@ int sscan_list(int *list[], const char *str, const char *listname) { - - /* format error occured */ - case sError: -- gmx_fatal(FARGS,"Error in the list of eigenvectors for %s at pos %d with char %c",listname,pos-startpos,*(pos-1)); -+ gmx_fatal(FARGS,"Error in the list of eigenvectors for %s at pos %d with char %c",listname,pos-startpos,*(pos-1)); - - /* logical error occured */ - case sZero: -@@ -246,7 +253,7 @@ int sscan_list(int *list[], const char *str, const char *listname) { - sfree(startpos); - return nvecs; - } /*sscan_list*/ -- -+ - void write_eigvec(FILE* fp, int natoms, int eig_list[], rvec** eigvecs,int nvec, const char *grouptitle,real steps[]) { - /* eig_list is a zero-terminated list of indices into the eigvecs array. - eigvecs are coordinates of eigenvectors -@@ -257,18 +264,18 @@ void write_eigvec(FILE* fp, int natoms, int eig_list[], rvec** eigvecs,int nvec, - int n=0,i; rvec x; - real sum; - while (eig_list[n++]); /*count selected eigenvecs*/ -- -+ - fprintf(fp,"# NUMBER OF EIGENVECTORS + %s\n %d\n",grouptitle,n-1); -- -+ - /* write list of eigenvector indicess */ - for(n=0;eig_list[n];n++) { - if (steps) -- fprintf(fp,"%8d %g\n",eig_list[n],steps[n]); -- else -+ fprintf(fp,"%8d %g\n",eig_list[n],steps[n]); -+ else - fprintf(fp,"%8d %g\n",eig_list[n],1.0); - } - n=0; -- -+ - /* dump coordinates of the selected eigenvectors */ - while (eig_list[n]) { - sum=0; -@@ -277,21 +284,21 @@ void write_eigvec(FILE* fp, int natoms, int eig_list[], rvec** eigvecs,int nvec, - gmx_fatal(FARGS,"Selected eigenvector %d is higher than maximum number %d of available eigenvectors",eig_list[n],nvec); - copy_rvec(eigvecs[eig_list[n]-1][i],x); - sum+=norm2(x); -- fprintf(fp,"%8.5f %8.5f %8.5f\n",x[XX],x[YY],x[ZZ]); -- } -+ fprintf(fp,"%8.5f %8.5f %8.5f\n",x[XX],x[YY],x[ZZ]); -+ } - n++; - } - } - - - /*enum referring to the different lists of eigenvectors*/ --enum { evLINFIX, evLINACC, evFLOOD, evRADFIX, evRADACC, evRADCON , evMON, evEND }; -+enum { evLINFIX, evLINACC, evFLOOD, evRADFIX, evRADACC, evRADCON , evMON, evNr }; - #define oldMAGIC 666 --#define MAGIC 669 -+#define MAGIC 670 - - --void write_the_whole_thing(FILE* fp, t_edipar *edpars, rvec** eigvecs, -- int nvec, int *eig_listen[], real* evStepList[]) -+void write_the_whole_thing(FILE* fp, t_edipar *edpars, rvec** eigvecs, -+ int nvec, int *eig_listen[], real* evStepList[]) - { - /* write edi-file */ - -@@ -300,15 +307,16 @@ void write_the_whole_thing(FILE* fp, t_edipar *edpars, rvec** eigvecs, - MAGIC,edpars->nini,edpars->fitmas,edpars->pcamas); - fprintf(fp,"#OUTFRQ\n %d\n#MAXLEN\n %d\n#SLOPECRIT\n %f\n", - edpars->outfrq,edpars->maxedsteps,edpars->slope); -- fprintf(fp,"#PRESTEPS\n %d\n#DELTA_F0\n %f\n#INIT_DELTA_F\n %f\n#TAU\n %f\n#EFL_NULL\n %f\n#ALPHA2\n %f\n#KT\n %f\n#HARMONIC\n %d\n", -- edpars->presteps,edpars->flood.deltaF0,edpars->flood.deltaF,edpars->flood.tau,edpars->flood.constEfl,edpars->flood.alpha2,edpars->flood.kT,edpars->flood.bHarmonic); -- -+ fprintf(fp,"#PRESTEPS\n %d\n#DELTA_F0\n %f\n#INIT_DELTA_F\n %f\n#TAU\n %f\n#EFL_NULL\n %f\n#ALPHA2\n %f\n#KT\n %f\n#HARMONIC\n %d\n#CONST_FORCE_FLOODING\n %d\n", -+ edpars->presteps,edpars->flood.deltaF0,edpars->flood.deltaF,edpars->flood.tau,edpars->flood.constEfl, -+ edpars->flood.alpha2,edpars->flood.kT,edpars->flood.bHarmonic,edpars->flood.bConstForce); -+ - /* Average and reference positions */ - write_t_edx(fp,edpars->sref,"NREF, XREF"); - write_t_edx(fp,edpars->sav,"NAV, XAV"); - - /*Eigenvectors */ -- -+ - write_eigvec(fp, edpars->ned, eig_listen[evMON],eigvecs,nvec,"COMPONENTS GROUP 1",NULL); - write_eigvec(fp, edpars->ned, eig_listen[evLINFIX],eigvecs,nvec,"COMPONENTS GROUP 2",evStepList[evLINFIX]); - write_eigvec(fp, edpars->ned, eig_listen[evLINACC],eigvecs,nvec,"COMPONENTS GROUP 3",evStepList[evLINACC]); -@@ -321,9 +329,9 @@ void write_the_whole_thing(FILE* fp, t_edipar *edpars, rvec** eigvecs, - /*Target and Origin positions */ - write_t_edx(fp,edpars->star,"NTARGET, XTARGET"); - write_t_edx(fp,edpars->sori,"NORIGIN, XORIGIN"); --} -+} - --int read_conffile(const char *confin,char *title,rvec *x[]) -+int read_conffile(const char *confin,char *title,rvec *x[]) - { - /* read coordinates out of STX file */ - int natoms; -@@ -342,23 +350,23 @@ int read_conffile(const char *confin,char *title,rvec *x[]) - snew(*x,natoms); - read_stx_conf(confin,title,&confat,*x,NULL,NULL,box); - return natoms; --} -+} - - --void read_eigenvalues(int vecs[],const char *eigfile, real values[], -- gmx_bool bHesse, real kT) -+void read_eigenvalues(int vecs[],const char *eigfile, real values[], -+ gmx_bool bHesse, real kT) - { - int neig,nrow,i; - double **eigval; -- -+ - neig = read_xvg(eigfile,&eigval,&nrow); -- -+ - fprintf(stderr,"Read %d eigenvalues\n",neig); -- for(i=bHesse ? 6 : 0 ; ianrs,1); - } - --void filter2edx(struct edix *edx,int nindex, atom_id index[],int ngro, -- atom_id igro[],rvec *x,const char* structure) -+void filter2edx(struct edix *edx,int nindex, atom_id index[],int ngro, -+ atom_id igro[],rvec *x,const char* structure) - { - /* filter2edx copies coordinates from x to edx which are given in index - */ -- -+ - int pos,i; - int ix=edx->nr; - edx->nr+=nindex; -@@ -433,7 +441,7 @@ void filter2edx(struct edix *edx,int nindex, atom_id index[],int ngro, - - void get_structure(t_atoms *atoms,const char *IndexFile, - const char *StructureFile,struct edix *edx,int nfit, -- atom_id ifit[],int natoms, atom_id index[]) -+ atom_id ifit[],int natoms, atom_id index[]) - { - atom_id *igro; /*index corresponding to target or origin structure*/ - int ngro; -@@ -441,7 +449,7 @@ void get_structure(t_atoms *atoms,const char *IndexFile, - rvec *xtar; - char title[STRLEN]; - char* grpname; -- -+ - - ntar=read_conffile(StructureFile,title,&xtar); - printf("Select an index group of %d elements that corresponds to the atoms in the structure file %s\n", -@@ -460,7 +468,7 @@ int main(int argc,char *argv[]) - - static const char *desc[] = { - "[TT]make_edi[tt] generates an essential dynamics (ED) sampling input file to be used with [TT]mdrun[tt]", -- "based on eigenvectors of a covariance matrix ([TT]g_covar[tt]) or from a", -+ "based on eigenvectors of a covariance matrix ([TT]g_covar[tt]) or from a", - "normal modes anaysis ([TT]g_nmeig[tt]).", - "ED sampling can be used to manipulate the position along collective coordinates", - "(eigenvectors) of (biological) macromolecules during a simulation. Particularly,", -@@ -481,10 +489,10 @@ int main(int argc,char *argv[]) - "J. Biomol. Struct. Dyn. 13 : 741-751 (1996)[BR]", - "B.L. de Groot, A.Amadei, R.M. Scheek, N.A.J. van Nuland and H.J.C. Berendsen; ", - "An extended sampling of the configurational space of HPr from E. coli", -- "PROTEINS: Struct. Funct. Gen. 26: 314-322 (1996)", -+ "Proteins: Struct. Funct. Gen. 26: 314-322 (1996)", - "[PAR]You will be prompted for one or more index groups that correspond to the eigenvectors,", - "reference structure, target positions, etc.[PAR]", -- -+ - "[TT]-mon[tt]: monitor projections of the coordinates onto selected eigenvectors.[PAR]", - "[TT]-linfix[tt]: perform fixed-step linear expansion along selected eigenvectors.[PAR]", - "[TT]-linacc[tt]: perform acceptance linear expansion along selected eigenvectors.", -@@ -492,13 +500,13 @@ int main(int argc,char *argv[]) - "[TT]-radfix[tt]: perform fixed-step radius expansion along selected eigenvectors.[PAR]", - "[TT]-radacc[tt]: perform acceptance radius expansion along selected eigenvectors.", - "(steps in the desired direction will be accepted, others will be rejected).", -- "Note: by default the starting MD structure will be taken as origin of the first", -+ "[BB]Note:[bb] by default the starting MD structure will be taken as origin of the first", - "expansion cycle for radius expansion. If [TT]-ori[tt] is specified, you will be able", - "to read in a structure file that defines an external origin.[PAR]", - "[TT]-radcon[tt]: perform acceptance radius contraction along selected eigenvectors", - "towards a target structure specified with [TT]-tar[tt].[PAR]", - "NOTE: each eigenvector can be selected only once. [PAR]", -- "[TT]-outfrq[tt]: frequency (in steps) of writing out projections etc. to .edo file[PAR]", -+ "[TT]-outfrq[tt]: frequency (in steps) of writing out projections etc. to [TT].edo[tt] file[PAR]", - "[TT]-slope[tt]: minimal slope in acceptance radius expansion. A new expansion", - "cycle will be started if the spontaneous increase of the radius (in nm/step)", - "is less than the value specified.[PAR]", -@@ -507,53 +515,54 @@ int main(int argc,char *argv[]) - "Note on the parallel implementation: since ED sampling is a 'global' thing", - "(collective coordinates etc.), at least on the 'protein' side, ED sampling", - "is not very parallel-friendly from an implentation point of view. Because", -- "parallel ED requires much extra communication, expect the performance to be", -+ "parallel ED requires some extra communication, expect the performance to be", - "lower as in a free MD simulation, especially on a large number of nodes. [PAR]", - "All output of [TT]mdrun[tt] (specify with [TT]-eo[tt]) is written to a .edo file. In the output", - "file, per OUTFRQ step the following information is present: [PAR]", -- "* the step number[BR]", -- "* the number of the ED dataset. (Note that you can impose multiple ED constraints in", -- "a single simulation - on different molecules e.g. - if several .edi files were concatenated", -- "first. The constraints are applied in the order they appear in the .edi file.) [BR]", -- "* RMSD (for atoms involved in fitting prior to calculating the ED constraints)[BR]", -+ "[TT]*[tt] the step number[BR]", -+ "[TT]*[tt] the number of the ED dataset. ([BB]Note[bb] that you can impose multiple ED constraints in", -+ "a single simulation (on different molecules) if several [TT].edi[tt] files were concatenated", -+ "first. The constraints are applied in the order they appear in the [TT].edi[tt] file.) [BR]", -+ "[TT]*[tt] RMSD (for atoms involved in fitting prior to calculating the ED constraints)[BR]", - "* projections of the positions onto selected eigenvectors[BR]", - "[PAR][PAR]", - "FLOODING:[PAR]", -- "with -flood you can specify which eigenvectors are used to compute a flooding potential,", -+ "with [TT]-flood[tt], you can specify which eigenvectors are used to compute a flooding potential,", - "which will lead to extra forces expelling the structure out of the region described", - "by the covariance matrix. If you switch -restrain the potential is inverted and the structure", - "is kept in that region.", - "[PAR]", -- "The origin is normally the average structure stored in the eigvec.trr file.", -- "It can be changed with -ori to an arbitrary position in configurational space.", -- "With -tau, -deltaF0 and -Eflnull you control the flooding behaviour.", -+ "The origin is normally the average structure stored in the [TT]eigvec.trr[tt] file.", -+ "It can be changed with [TT]-ori[tt] to an arbitrary position in configurational space.", -+ "With [TT]-tau[tt], [TT]-deltaF0[tt], and [TT]-Eflnull[tt] you control the flooding behaviour.", - "Efl is the flooding strength, it is updated according to the rule of adaptive flooding.", -- "Tau is the time constant of adaptive flooding, high tau means slow adaption (i.e. growth). ", -+ "Tau is the time constant of adaptive flooding, high [GRK]tau[grk] means slow adaption (i.e. growth). ", - "DeltaF0 is the flooding strength you want to reach after tau ps of simulation.", -- "To use constant Efl set -tau to zero.", -+ "To use constant Efl set [TT]-tau[tt] to zero.", - "[PAR]", -- "-alpha is a fudge parameter to control the width of the flooding potential. A value of 2 has been found", -+ "[TT]-alpha[tt] is a fudge parameter to control the width of the flooding potential. A value of 2 has been found", - "to give good results for most standard cases in flooding of proteins.", -- "Alpha basically accounts for incomplete sampling, if you sampled further the width of the ensemble would", -- "increase, this is mimicked by alpha>1.", -- "For restraining alpha<1 can give you smaller width in the restraining potential.", -+ "[GRK]alpha[grk] basically accounts for incomplete sampling, if you sampled further the width of the ensemble would", -+ "increase, this is mimicked by [GRK]alpha[grk] > 1.", -+ "For restraining, [GRK]alpha[grk] < 1 can give you smaller width in the restraining potential.", - "[PAR]", - "RESTART and FLOODING:", - "If you want to restart a crashed flooding simulation please find the values deltaF and Efl in", -- "the output file and manually put them into the .edi file under DELTA_F0 and EFL_NULL." -+ "the output file and manually put them into the [TT].edi[tt] file under DELTA_F0 and EFL_NULL." - }; -- -+ - /* Save all the params in this struct and then save it in an edi file. - * ignoring fields nmass,massnrs,mass,tmass,nfit,fitnrs,edo - */ -- static t_edipar edi_params; -- -- enum { evSTEPEND = evRADFIX + 1}; -- static const char* evSelections[evEND]= {NULL,NULL,NULL,NULL,NULL,NULL}; -- static const char* evOptions[evEND] = {"-linfix","-linacc","-flood","-radfix","-radacc","-radcon","-mon"}; -- static const char* evParams[evSTEPEND] ={NULL,NULL}; -- static const char* evStepOptions[evSTEPEND] = {"-linstep","-accdir","-not_used","-radstep"}; -- static real* evStepList[evSTEPEND]; -+ static t_edipar edi_params; -+ -+ enum { evStepNr = evRADFIX + 1}; -+ static const char* evSelections[evNr]= {NULL,NULL,NULL,NULL,NULL,NULL}; -+ static const char* evOptions[evNr] = {"-linfix","-linacc","-flood","-radfix","-radacc","-radcon","-mon"}; -+ static const char* evParams[evStepNr] ={NULL,NULL}; -+ static const char* evStepOptions[evStepNr] = {"-linstep","-accdir","-not_used","-radstep"}; -+ static const char* ConstForceStr; -+ static real* evStepList[evStepNr]; - static real radfix=0.0; - static real deltaF0=150; - static real deltaF=0; -@@ -561,7 +570,7 @@ int main(int argc,char *argv[]) - static real constEfl=0.0; - static real alpha=1; - static int eqSteps=0; -- static int* listen[evEND]; -+ static int* listen[evNr]; - static real T=300.0; - const real kB = 2.5 / 300.0; /* k_boltzmann in MD units */ - static gmx_bool bRestrain = FALSE; -@@ -574,49 +583,53 @@ int main(int argc,char *argv[]) - "Indices of eigenvectors for fixed increment linear sampling" }, - { "-linacc", FALSE, etSTR, {&evSelections[1]}, - "Indices of eigenvectors for acceptance linear sampling" }, -- { "-flood", FALSE, etSTR, {&evSelections[2]}, -- "Indices of eigenvectors for flooding"}, - { "-radfix", FALSE, etSTR, {&evSelections[3]}, - "Indices of eigenvectors for fixed increment radius expansion" }, - { "-radacc", FALSE, etSTR, {&evSelections[4]}, - "Indices of eigenvectors for acceptance radius expansion" }, - { "-radcon", FALSE, etSTR, {&evSelections[5]}, - "Indices of eigenvectors for acceptance radius contraction" }, -+ { "-flood", FALSE, etSTR, {&evSelections[2]}, -+ "Indices of eigenvectors for flooding"}, - { "-outfrq", FALSE, etINT, {&edi_params.outfrq}, - "Freqency (in steps) of writing output in [TT].edo[tt] file" }, - { "-slope", FALSE, etREAL, { &edi_params.slope}, - "Minimal slope in acceptance radius expansion"}, -+ { "-linstep", FALSE, etSTR, {&evParams[0]}, -+ "Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! \"1.0 2.3 5.1 -3.1\")"}, -+ { "-accdir", FALSE, etSTR, {&evParams[1]}, -+ "Directions for acceptance linear sampling - only sign counts! (put in quotes! \"-1 +1 -1.1\")"}, -+ { "-radstep", FALSE, etREAL, {&radfix}, -+ "Stepsize (nm/step) for fixed increment radius expansion"}, - { "-maxedsteps", FALSE, etINT, {&edi_params.maxedsteps}, -- "Max nr of steps per cycle" }, -+ "Maximum number of steps per cycle" }, -+ { "-eqsteps", FALSE, etINT, {&eqSteps}, -+ "Number of steps to run without any perturbations "}, - { "-deltaF0", FALSE,etREAL, {&deltaF0}, -- "Target destabilization energy - used for flooding"}, -+ "Target destabilization energy for flooding"}, - { "-deltaF", FALSE, etREAL, {&deltaF}, -- "Start deltaF with this parameter - default 0, i.e. nonzero values only needed for restart"}, -- { "-tau", FALSE, etREAL, {&tau}, -+ "Start deltaF with this parameter - default 0, nonzero values only needed for restart"}, -+ { "-tau", FALSE, etREAL, {&tau}, - "Coupling constant for adaption of flooding strength according to deltaF0, 0 = infinity i.e. constant flooding strength"}, -- { "-eqsteps", FALSE, etINT, {&eqSteps}, -- "Number of steps to run without any perturbations "}, - { "-Eflnull", FALSE, etREAL, {&constEfl}, -- "This is the starting value of the flooding strength. The flooding strength is updated according to the adaptive flooding scheme. To use a constant flooding strength use [TT]-tau[tt] 0. "}, -+ "The starting value of the flooding strength. The flooding strength is updated " -+ "according to the adaptive flooding scheme. For a constant flooding strength use [TT]-tau[tt] 0. "}, - { "-T", FALSE, etREAL, {&T}, - "T is temperature, the value is needed if you want to do flooding "}, - { "-alpha",FALSE,etREAL,{&alpha}, - "Scale width of gaussian flooding potential with alpha^2 "}, -- { "-linstep", FALSE, etSTR, {&evParams[0]}, -- "Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! \"1.0 2.3 5.1 -3.1\")"}, -- { "-accdir", FALSE, etSTR, {&evParams[1]}, -- "Directions for acceptance linear sampling - only sign counts! (put in quotes! \"-1 +1 -1.1\")"}, -- { "-radstep", FALSE, etREAL, {&radfix}, -- "Stepsize (nm/step) for fixed increment radius expansion"}, - { "-restrain",FALSE, etBOOL, {&bRestrain}, - "Use the flooding potential with inverted sign -> effects as quasiharmonic restraining potential"}, - { "-hessian",FALSE, etBOOL, {&bHesse}, - "The eigenvectors and eigenvalues are from a Hessian matrix"}, -- { "-harmonic",FALSE, etBOOL, {&bHarmonic}, -+ { "-harmonic",FALSE, etBOOL, {&bHarmonic}, - "The eigenvalues are interpreted as spring constant"}, -+ { "-constF", FALSE, etSTR, {&ConstForceStr}, -+ "Constant force flooding: manually set the forces for the eigenvectors selected with -flood " -+ "(put in quotes! \"1.0 2.3 5.1 -3.1\"). No other flooding parameters are needed when specifying the forces directly."} - }; - #define NPA asize(pa) -- -+ - rvec *xref1; - int nvec1,*eignr1=NULL; - rvec *xav1,**eigvec1=NULL; -@@ -630,14 +643,14 @@ int main(int argc,char *argv[]) - int ev_class; /* parameter _class i.e. evMON, evRADFIX etc. */ - int nvecs; - real *eigval1=NULL; /* in V3.3 this is parameter of read_eigenvectors */ -- -+ - const char *EdiFile; - const char *TargetFile; - const char *OriginFile; - const char *EigvecFile; -- -+ - output_env_t oenv; -- -+ - /*to read topology file*/ - t_topology top; - int ePBC; -@@ -645,10 +658,10 @@ int main(int argc,char *argv[]) - matrix topbox; - rvec *xtop; - gmx_bool bTop, bFit1; -- -+ - t_filenm fnm[] = { - { efTRN, "-f", "eigenvec", ffREAD }, -- { efXVG, "-eig", "eigenval", ffOPTRD }, -+ { efXVG, "-eig", "eigenval", ffOPTRD }, - { efTPS, NULL, NULL, ffREAD }, - { efNDX, NULL, NULL, ffOPTRD }, - { efSTX, "-tar", "target", ffOPTRD}, -@@ -660,64 +673,69 @@ int main(int argc,char *argv[]) - CopyRight(stderr,argv[0]); - parse_common_args(&argc,argv, 0 , - NFILE,fnm,NPA,pa,asize(desc),desc,0,NULL,&oenv); -- -+ - indexfile=ftp2fn_null(efNDX,NFILE,fnm); - EdiFile=ftp2fn(efEDI,NFILE,fnm); - TargetFile = opt2fn_null("-tar",NFILE,fnm); - OriginFile = opt2fn_null("-ori",NFILE,fnm); -- -- -- for (ev_class=0; ev_classnr; - -- -+ - /*store reference and average structure in edi_params*/ - make_t_edx(&edi_params.sref,nfit,xref1,ifit); - make_t_edx(&edi_params.sav,natoms,xav1,index); - -- -+ - /* Store target positions in edi_params */ - if (opt2bSet("-tar",NFILE,fnm)) - { -diff --git a/src/tools/make_ndx.c b/src/tools/make_ndx.c -index 308eb09..1e80df2 100644 ---- a/src/tools/make_ndx.c -+++ b/src/tools/make_ndx.c -@@ -1184,7 +1184,7 @@ int main(int argc,char *argv[]) - "All these programs can generate default index groups. You ONLY", - "have to use [TT]make_ndx[tt] when you need SPECIAL index groups.", - "There is a default index group for the whole system, 9 default", -- "index groups are generated for proteins, a default index group", -+ "index groups for proteins, and a default index group", - "is generated for every other residue name.[PAR]", - "When no index file is supplied, also [TT]make_ndx[tt] will generate the", - "default groups.", -diff --git a/src/tools/powerspect.c b/src/tools/powerspect.c -new file mode 100644 -index 0000000..3366e48 ---- /dev/null -+++ b/src/tools/powerspect.c -@@ -0,0 +1,136 @@ -+/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- -+ * $Id: densorder.c,v 0.9 -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.0 -+ * -+ * Copyright (c) 1991-2001 -+ * BIOSON Research Institute, Dept. of Biophysical Chemistry -+ * University of Groningen, The Netherlands -+ * -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . -+ * -+ * And Hey: -+ * Gyas ROwers Mature At Cryogenic Speed -+ */ -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+#include -+#include -+#include -+#include -+#include "interf.h" -+#include "powerspect.h" -+ -+void addtoavgenergy(t_complex *list, real *result, int size, int tsteps){ -+ int i; -+ for (i=0;iZ; -+ surf[1][n][i]=if2[n][i]->Z; -+ } -+ } -+ powerspectavg(surf, t,xb,yb,fnms); -+} -+ -diff --git a/src/tools/powerspect.h b/src/tools/powerspect.h -new file mode 100644 -index 0000000..62d1108 ---- /dev/null -+++ b/src/tools/powerspect.h -@@ -0,0 +1,48 @@ -+/* -+ * -+ * This source code is part of -+ * -+ * G R O M A C S -+ * -+ * GROningen MAchine for Chemical Simulations -+ * -+ * VERSION 3.2.0 -+ * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. -+ * Copyright (c) 1991-2000, University of Groningen, The Netherlands. -+ * Copyright (c) 2001-2004, The GROMACS development team, -+ * check out http://www.gromacs.org for more information. -+ -+ * This program is free software; you can redistribute it and/or -+ * modify it under the terms of the GNU General Public License -+ * as published by the Free Software Foundation; either version 2 -+ * of the License, or (at your option) any later version. -+ * -+ * If you want to redistribute modifications, please consider that -+ * scientific software is very special. Version control is crucial - -+ * bugs must be traceable. We will be happy to consider code for -+ * inclusion in the official distribution, but derived work must not -+ * be called official GROMACS. Details are found in the README & COPYING -+ * files - if they are missing, get the official version at www.gromacs.org. -+ * -+ * To help us fund GROMACS development, we humbly ask that you cite -+ * the papers on the package - you can find them in the top README file. -+ * -+ * For more info, check our website at http://www.gromacs.org -+ * -+ * And Hey: -+ * Green Red Orange Magenta Azure Cyan Skyblue -+ */ -+ -+#ifndef _powerspect_h -+#define _powerspect_h -+ -+#include "typedefs.h" -+#include "interf.h" -+ -+extern void powerspectavg(real ***interface, int t, int xbins, int ybins, -+ char **outfiles); -+ -+extern void powerspectavg_intf(t_interf ***if1,t_interf ***if2,int t, -+ int xbins, int ybins, char **outfiles); -+ -+#endif diff -Nru gromacs-4.5.4/debian/patches/31_manpages.dpatch gromacs-4.5.5/debian/patches/31_manpages.dpatch --- gromacs-4.5.4/debian/patches/31_manpages.dpatch 2011-10-17 12:02:05.000000000 +0000 +++ gromacs-4.5.5/debian/patches/31_manpages.dpatch 2011-10-17 12:02:09.000000000 +0000 @@ -77,3 +77,39 @@ \&reaction coordinate with a Gaussian (sigma provided with \fB \-acsig\fR, \&see output in \fB iact.xvg\fR). Note that the IACTs are estimated by simple \&integration of the ACFs while the ACFs are larger 0.05. +diff -Nru gromacs-4.5.5.orig//src/kernel/hizzie.c gromacs-4.5.5//src/kernel/hizzie.c +--- gromacs-4.5.5.orig//src/kernel/hizzie.c 2011-09-21 05:34:32.000000000 -0700 ++++ gromacs-4.5.5//src/kernel/hizzie.c 2011-09-21 18:49:32.291850466 -0700 +@@ -211,7 +211,7 @@ + /* A histidine residue exists that requires automated assignment, so + * doing the analysis of donors and acceptors is worthwhile. */ + fprintf(stderr, +- "Analysing hydrogen-bonding network for automated assigment of histidine\n" ++ "Analysing hydrogen-bonding network for automated assignment of histidine\n" + " protonation."); + + snew(donor,natom); +diff -Nru gromacs-4.5.5.orig//src/kernel/readir.c gromacs-4.5.5//src/kernel/readir.c +--- gromacs-4.5.5.orig//src/kernel/readir.c 2011-09-21 18:01:47.814687957 -0700 ++++ gromacs-4.5.5//src/kernel/readir.c 2011-09-21 18:49:53.900080215 -0700 +@@ -924,7 +924,7 @@ + EETYPE("DispCorr", ir->eDispCorr, edispc_names); + CTYPE ("Extension of the potential lookup tables beyond the cut-off"); + RTYPE ("table-extension", ir->tabext, 1.0); +- CTYPE ("Seperate tables between energy group pairs"); ++ CTYPE ("Separate tables between energy group pairs"); + STYPE ("energygrp_table", egptable, NULL); + CTYPE ("Spacing for the PME/PPPM FFT grid"); + RTYPE ("fourierspacing", opts->fourierspacing,0.12); +diff -Nru gromacs-4.5.5.orig//src/tools/gmx_genpr.c gromacs-4.5.5//src/tools/gmx_genpr.c +--- gromacs-4.5.5.orig//src/tools/gmx_genpr.c 2011-09-21 18:01:47.814687957 -0700 ++++ gromacs-4.5.5//src/tools/gmx_genpr.c 2011-09-21 18:49:03.063538595 -0700 +@@ -134,7 +134,7 @@ + nfn = opt2fn_null("-n",NFILE,fnm); + + if (( nfn == NULL ) && ( xfn == NULL)) +- gmx_fatal(FARGS,"no index file and no structure file suplied"); ++ gmx_fatal(FARGS,"no index file and no structure file supplied"); + + if ((disre_frac < 0) || (disre_frac >= 1)) + gmx_fatal(FARGS,"disre_frac should be between 0 and 1"); diff -Nru gromacs-4.5.4/debian/rules gromacs-4.5.5/debian/rules --- gromacs-4.5.4/debian/rules 2011-10-17 12:02:05.000000000 +0000 +++ gromacs-4.5.5/debian/rules 2011-10-17 12:02:09.000000000 +0000 @@ -4,8 +4,6 @@ # export DH_VERBOSE=1 -# debhelper compatibility version set to 5 in debian/compat - PACKAGE := gromacs include /usr/share/dpatch/dpatch.make @@ -37,6 +35,13 @@ COMMON_CONFIG_PARAMS += -DCMAKE_C_FLAGS="$(CFLAGS)" endif +# Include "gpu" in DEB_BUILD_OPTIONS to build GPU-accelerated binaries as well. +# See INSTALL-GPU. This build option is not tested, please send comments. +# You must have OpenMM development headers (not packaged) and "nvidia-cuda-dev" +# installed! +ifneq (,$(findstring gpu,$(DEB_BUILD_OPTIONS))) + COMMON_CONFIG_PARAMS += -DGMX_OPENMM=ON -DGMX_THREADS=OFF +endif MPICH_CONFIG_PARAMS = \ -DGMX_MPI=ON \ @@ -47,7 +52,7 @@ OPENMPI_CONFIG_PARAMS = \ -DGMX_MPI=ON \ -DGMX_THREADS=OFF \ - -DGMX_DEFAULT_SUFFIX=FALSE + -DGMX_DEFAULT_SUFFIX=FALSE \ -DGMX_FORTRAN=OFF \ -DGMX_X11=OFF \ -DCMAKE_EXE_LINKER_FLAGS="-L/usr/lib/openmpi/lib $(LDFLAGS)" @@ -84,6 +89,9 @@ build: patch-stamp configure-stamp build-basic build-mpich build-openmpi +build-arch: build +build-indep: build + build-basic: configure-stamp dh_testdir $(MAKE) -C build/basic @@ -172,7 +180,7 @@ $(MAKE) -C build/basic install DESTDIR=$(CURDIR)/debian/gromacs $(MAKE) -C build/basic-dp install DESTDIR=$(CURDIR)/debian/gromacs rm -f $(CURDIR)/debian/gromacs/usr/share/man/man1/*_d.1 - dh_installman -pgromacs debian/man/g_luck.1 debian/man/g_kinetics.1 debian/man/g_options.1 + dh_installman -pgromacs debian/man/g_*.1 for manpage in $(CURDIR)/debian/gromacs/usr/share/man/man1/*.1; do \ dh_link -pgromacs usr/share/man/man1/`basename $${manpage}` usr/share/man/man1/`basename $${manpage} .1`_d.1 ; \ done @@ -181,14 +189,13 @@ dh_installman -pgromacs debian/man/demux.1 debian/man/xplor2gmx.1 # this program is currently broken - keep it from shipping until fixed rm $(CURDIR)/debian/gromacs/usr/bin/g_pme_error $(CURDIR)/debian/gromacs/usr/bin/g_pme_error_d - # three lintian warnings are overridden: + # two lintian warnings are overridden: # - package-name-doesnt-match-sonames: the libraries are private to # GROMACS, and it's unlikely that any new package will start using # them; therefore, separate lib packages would just be bloat. # This is also overridden for the -mpich and -openmpi packages. # - shlib-with-executable-stack: it's a side effect of the ASM inner # loops (i386/amd64 only) - # - binary-without-manpage: shipped in gromacs-data instead. dh_lintian -pgromacs install-mpich: build diff -Nru gromacs-4.5.4/include/gmx_ana.h gromacs-4.5.5/include/gmx_ana.h --- gromacs-4.5.4/include/gmx_ana.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/gmx_ana.h 2011-09-21 12:34:32.000000000 +0000 @@ -79,6 +79,9 @@ gmx_densmap(int argc,char *argv[]); int +gmx_densorder(int argc,char *argv[]); + +int gmx_dielectric(int argc,char *argv[]); int @@ -94,6 +97,9 @@ gmx_dist(int argc,char *argv[]); int +gmx_dos(int argc,char *argv[]); + +int gmx_dyndom(int argc,char *argv[]); int @@ -141,6 +147,9 @@ int gmx_helixorient(int argc,char *argv[]); +int +gmx_hydorder(int argc,char *argv[]); + int gmx_kinetics(int argc,char *argv[]); diff -Nru gromacs-4.5.4/include/gmx_blas.h gromacs-4.5.5/include/gmx_blas.h --- gromacs-4.5.4/include/gmx_blas.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/gmx_blas.h 2011-09-21 12:34:32.000000000 +0000 @@ -37,6 +37,12 @@ #include "types/simple.h" +/* Suppress Cygwin compiler warnings from using newlib version of + * ctype.h */ +#ifdef GMX_CYGWIN +#undef toupper +#endif + /** @file * diff -Nru gromacs-4.5.4/include/gmxcomplex.h gromacs-4.5.5/include/gmxcomplex.h --- gromacs-4.5.4/include/gmxcomplex.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/gmxcomplex.h 2011-09-21 12:34:32.000000000 +0000 @@ -1,4 +1,5 @@ /* + * $Id: gmxcomplex.h,v 1.5 2009/03/07 13:30:36 lindahl Exp $ * * This source code is part of * @@ -32,8 +33,8 @@ * And Hey: * Gromacs Runs On Most of All Computer Systems */ -#ifndef _complex_h -#define _complex_h +#ifndef _gmxcomplex_h +#define _gmxcomplex_h #include #include "typedefs.h" @@ -107,6 +108,16 @@ return d; } +static real cabs2(t_complex c) +{ +real abs2; +abs2=(c.re*c.re)+(c.im*c.im); + +return abs2; +} + + + static t_complex cdiv(t_complex teller,t_complex noemer) { t_complex res,anoemer; diff -Nru gromacs-4.5.4/include/gmx_cyclecounter.h gromacs-4.5.5/include/gmx_cyclecounter.h --- gromacs-4.5.4/include/gmx_cyclecounter.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/gmx_cyclecounter.h 2011-09-21 12:34:32.000000000 +0000 @@ -137,6 +137,11 @@ typedef unsigned long long gmx_cycles_t; +#elif defined(__sun) && defined(__sparcv9) + +typedef unsigned long +gmx_cycles_t; + #else /*! \brief Integer-like datatype for cycle counter values * @@ -273,6 +278,13 @@ /* Metrowerks on macintosh */ return 1; } +#elif defined(__sun) && defined(__sparcv9) + +static __inline__ int gmx_cycles_have_counter(void) +{ + /* Solaris on SPARC*/ + return 1; +} #else static int gmx_cycles_have_counter(void) { @@ -458,6 +470,15 @@ return (((gmx_cycles_t)high2) << 32) | (gmx_cycles_t)low; } +#elif defined(__sun) && defined(__sparcv9) + +static __inline__ gmx_cycles_t gmx_cycles_read(void) +{ + gmx_cycles_t ret; + __asm__ __volatile__("rd %%tick, %0" : "=r" (ret)); + return ret; +} + #else static gmx_cycles_t gmx_cycles_read(void) { diff -Nru gromacs-4.5.4/include/gmx_lapack.h gromacs-4.5.5/include/gmx_lapack.h --- gromacs-4.5.4/include/gmx_lapack.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/gmx_lapack.h 2011-09-21 12:34:32.000000000 +0000 @@ -72,6 +72,11 @@ #include "types/simple.h" +/* Suppress Cygwin compiler warnings from using newlib version of + * ctype.h */ +#ifdef GMX_CYGWIN +#undef toupper +#endif #ifndef F77_FUNC #define F77_FUNC(name,NAME) name ## _ diff -Nru gromacs-4.5.4/include/gstat.h gromacs-4.5.5/include/gstat.h --- gromacs-4.5.4/include/gstat.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/gstat.h 2011-09-21 12:34:32.000000000 +0000 @@ -66,7 +66,7 @@ enum { effnNONE, effnEXP1, effnEXP2, effnEXP3, effnVAC, - effnEXP5, effnEXP7, effnEXP9, effnERREST, effnNR + effnEXP5, effnEXP7, effnEXP9, effnERF, effnERREST, effnNR }; /* must correspond with 'leg' g_chi.c:727 */ @@ -96,7 +96,7 @@ } t_dlist; -extern int nfp_ffn[effnNR]; +extern const int nfp_ffn[effnNR]; extern const char *s_ffn[effnNR+2]; diff -Nru gromacs-4.5.4/include/mdebin.h gromacs-4.5.5/include/mdebin.h --- gromacs-4.5.4/include/mdebin.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/mdebin.h 2011-09-21 12:34:32.000000000 +0000 @@ -73,9 +73,10 @@ gmx_bool bDynBox; gmx_bool bNHC_trotter; gmx_bool bMTTK; + gmx_bool bDiagPres; int f_nre; int epc; - tensor ref_p; + real ref_p; int etc; int nCrmsd; gmx_bool bEner[F_NRE]; diff -Nru gromacs-4.5.4/include/mdrun.h gromacs-4.5.5/include/mdrun.h --- gromacs-4.5.4/include/mdrun.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/mdrun.h 2011-09-21 12:34:32.000000000 +0000 @@ -176,6 +176,8 @@ gmx_integrator_t do_md_openmm; + + /* ROUTINES from minimize.c */ gmx_integrator_t do_steep; @@ -196,6 +198,39 @@ /* Do test particle insertion */ +/* ROUTINES from md_support.c */ + +/* return the number of steps between global communcations */ +int check_nstglobalcomm(FILE *fplog,t_commrec *cr, + int nstglobalcomm,t_inputrec *ir); + +/* check whether an 'nst'-style parameter p is a multiple of nst, and + set it to be one if not, with a warning. */ +void check_nst_param(FILE *fplog,t_commrec *cr, + const char *desc_nst,int nst, + const char *desc_p,int *p); + +/* check which of the multisim simulations has the shortest number of + steps and return that number of nsteps */ +gmx_large_int_t get_multisim_nsteps(const t_commrec *cr, + gmx_large_int_t nsteps); + +void rerun_parallel_comm(t_commrec *cr,t_trxframe *fr, + gmx_bool *bNotLastFrame); + +/* get the conserved energy associated with the ensemble type*/ +real compute_conserved_from_auxiliary(t_inputrec *ir, t_state *state, + t_extmass *MassQ); + +/* reset all cycle and time counters. */ +void reset_all_counters(FILE *fplog,t_commrec *cr, + gmx_large_int_t step, + gmx_large_int_t *step_rel,t_inputrec *ir, + gmx_wallcycle_t wcycle,t_nrnb *nrnb, + gmx_runtime_t *runtime); + + + /* ROUTINES from sim_util.c */ void do_pbc_first(FILE *log,matrix box,t_forcerec *fr, t_graph *graph,rvec x[]); @@ -206,6 +241,7 @@ void do_pbc_mtop(FILE *fplog,int ePBC,matrix box, gmx_mtop_t *mtop,rvec x[]); + /* ROUTINES from stat.c */ gmx_global_stat_t global_stat_init(t_inputrec *ir); @@ -333,7 +369,33 @@ /* Perform load balancing, i.e. split the particles over processors * based on their coordinates in the "dimension" direction. */ + +int multisim_min(const gmx_multisim_t *ms,int nmin,int n); +/* Set an appropriate value for n across the whole multi-simulation */ + +int multisim_nstsimsync(const t_commrec *cr, + const t_inputrec *ir,int repl_ex_nst); +/* Determine the interval for inter-simulation communication */ +void init_global_signals(globsig_t *gs,const t_commrec *cr, + const t_inputrec *ir,int repl_ex_nst); +/* Constructor for globsig_t */ + +void copy_coupling_state(t_state *statea,t_state *stateb, + gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts); +/* Copy stuff from state A to state B */ + +void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, + t_forcerec *fr, gmx_ekindata_t *ekind, + t_state *state, t_state *state_global, t_mdatoms *mdatoms, + t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, + gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, + tensor pres, rvec mu_tot, gmx_constr_t constr, + globsig_t *gs,gmx_bool bInterSimGS, + matrix box, gmx_mtop_t *top_global, real *pcurr, + int natoms, gmx_bool *bSumEkinhOld, int flags); +/* Compute global variables during integration */ + int mdrunner(int nthreads_requested, FILE *fplog,t_commrec *cr,int nfile, const t_filenm fnm[], const output_env_t oenv, gmx_bool bVerbose, gmx_bool bCompact, int nstglobalcomm, ivec ddxyz,int dd_node_order, diff -Nru gromacs-4.5.4/include/pbc.h gromacs-4.5.5/include/pbc.h --- gromacs-4.5.4/include/pbc.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/pbc.h 2011-09-21 12:34:32.000000000 +0000 @@ -33,8 +33,8 @@ * Gromacs Runs On Most of All Computer Systems */ -#ifndef _pbc_h -#define _pbc_h +#ifndef _types_pbc_h +#define _types_pbc_h #include "sysstuff.h" #include "typedefs.h" diff -Nru gromacs-4.5.4/include/pdbio.h gromacs-4.5.5/include/pdbio.h --- gromacs-4.5.4/include/pdbio.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/pdbio.h 2011-09-21 12:34:32.000000000 +0000 @@ -136,7 +136,7 @@ gmx_conect gmx_conect_generate(t_topology *top); /* Generate a conect structure from a topology */ -gmx_conect gmx_conect_init(); +gmx_conect gmx_conect_init(void); /* Initiate data structure */ void gmx_conect_done(gmx_conect gc); diff -Nru gromacs-4.5.4/include/string2.h gromacs-4.5.5/include/string2.h --- gromacs-4.5.4/include/string2.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/string2.h 2011-09-21 12:34:32.000000000 +0000 @@ -56,6 +56,21 @@ /*#include "typedefs.h"*/ #include "types/simple.h" +/* Suppress Cygwin compiler warnings from using newlib version of + * ctype.h */ +#ifdef GMX_CYGWIN +#undef isdigit +#undef isstring +#undef isspace +#undef isalnum +#undef isalpha +#undef ispunct +#undef isxdigit +#undef isupper +#undef islower +#undef toupper +#undef tolower +#endif #ifdef __cplusplus extern "C" { diff -Nru gromacs-4.5.4/include/thread_mpi/atomic.h gromacs-4.5.5/include/thread_mpi/atomic.h --- gromacs-4.5.4/include/thread_mpi/atomic.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/thread_mpi/atomic.h 2011-09-21 12:34:32.000000000 +0000 @@ -134,6 +134,9 @@ #include "atomic/xlc_ppc.h" +#elif defined (__sun) && (defined(__sparcv9) || defined(__sparc)) +/* Solaris on SPARC (Sun C Compiler, Solaris Studio) */ +#include "atomic/suncc-sparc.h" @@ -630,6 +633,7 @@ /** Atomic swap operation. Atomically swaps the data in the tMPI_Atomic_t operand with the value of b. + NOTE: DON'T USE YET! (This has no good asm counterparts on many architectures). \param a Pointer to atomic type \param b Value to swap @@ -648,6 +652,7 @@ Atomically swaps the pointer in the tMPI_Atomic_ptr_t operand with the value of b. + NOTE: DON'T USE YET! (This has no good asm counterparts on many architectures). \param a Pointer to atomic type \param b Value to swap diff -Nru gromacs-4.5.4/include/thread_mpi/hwinfo.h gromacs-4.5.5/include/thread_mpi/hwinfo.h --- gromacs-4.5.4/include/thread_mpi/hwinfo.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/thread_mpi/hwinfo.h 1970-01-01 00:00:00.000000000 +0000 @@ -1,71 +0,0 @@ -/* -This source code file is part of thread_mpi. -Written by Sander Pronk, Erik Lindahl, and possibly others. - -Copyright (c) 2009, Sander Pronk, Erik Lindahl. -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: -1) Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. -2) Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. -3) Neither the name of the copyright holders nor the - names of its contributors may be used to endorse or promote products - derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY US ''AS IS'' AND ANY -EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL WE BE LIABLE FOR ANY -DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND -ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -If you want to redistribute modifications, please consider that -scientific software is very special. Version control is crucial - -bugs must be traceable. We will be happy to consider code for -inclusion in the official distribution, but derived work should not -be called official thread_mpi. Details are found in the README & COPYING -files. -*/ - -#ifndef _TMPI_HWINFO_H_ -#define _TMPI_HWINFO_H_ - -/*! \file - - \brief CPU/core/HT count function. - -*/ - -/*! \brief Determine number of hardware threads that can be run simultaneously - - Returns the total number of cores and SMT threads that can run. - - \ret The maximum number of threads that can run simulataneously. If this - number cannot be determined for the current architecture, -1 is - returned. - */ -int tMPI_Get_hw_nthreads(void); - - -/*! \brief Determine the recommended number of hardware threads to run on - - - Returns the total number of cores and SMT threads to run on. This is - equal to the number of hardware threads available, or 1 if the number - can't be determined, or if there are no atomics for this platform. - - \ret The maximum number of threads to run on. - */ -int tMPI_Get_recommended_nthreads(void); - - -#endif - diff -Nru gromacs-4.5.4/include/thread_mpi/Makefile.am gromacs-4.5.5/include/thread_mpi/Makefile.am --- gromacs-4.5.4/include/thread_mpi/Makefile.am 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/thread_mpi/Makefile.am 2011-09-21 12:34:32.000000000 +0000 @@ -9,7 +9,7 @@ pkgincludethread_mpi_HEADERS = \ atomic.h event.h lock.h tmpi.h \ - barrier.h hwinfo.h mpi_bindings.h wait.h \ - collective.h list.h threads.h + barrier.h mpi_bindings.h wait.h \ + collective.h list.h threads.h numa_malloc.h diff -Nru gromacs-4.5.4/include/thread_mpi/Makefile.in gromacs-4.5.5/include/thread_mpi/Makefile.in --- gromacs-4.5.4/include/thread_mpi/Makefile.in 2011-03-21 15:13:36.000000000 +0000 +++ gromacs-4.5.5/include/thread_mpi/Makefile.in 2011-09-21 12:38:30.000000000 +0000 @@ -262,8 +262,8 @@ pkgincludethread_mpidir = ${pkgincludedir}/thread_mpi pkgincludethread_mpi_HEADERS = \ atomic.h event.h lock.h tmpi.h \ - barrier.h hwinfo.h mpi_bindings.h wait.h \ - collective.h list.h threads.h + barrier.h mpi_bindings.h wait.h \ + collective.h list.h threads.h numa_malloc.h all: all-recursive diff -Nru gromacs-4.5.4/include/thread_mpi/numa_malloc.h gromacs-4.5.5/include/thread_mpi/numa_malloc.h --- gromacs-4.5.4/include/thread_mpi/numa_malloc.h 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/include/thread_mpi/numa_malloc.h 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,130 @@ +/* +This source code file is part of thread_mpi. +Written by Sander Pronk, Erik Lindahl, and possibly others. + +Copyright (c) 2009, Sander Pronk, Erik Lindahl. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: +1) Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. +2) Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. +3) Neither the name of the copyright holders nor the + names of its contributors may be used to endorse or promote products + derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY US ''AS IS'' AND ANY +EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL WE BE LIABLE FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +If you want to redistribute modifications, please consider that +scientific software is very special. Version control is crucial - +bugs must be traceable. We will be happy to consider code for +inclusion in the official distribution, but derived work should not +be called official thread_mpi. Details are found in the README & COPYING +files. +*/ + + +#ifndef _TMPI_NUMA_MALLOC_H_ +#define _TMPI_NUMA_MALLOC_H_ + +/*! \file numa_alloc.h + + \brief NUMA aware memory allocators. + + This file provides a NUMA aware version of malloc() and friends to + force local allocation, preventing expensive 'remote' memory access. + + Note that memory allocated with tMPI_Malloc_local(), etc. MUST be + freed with tMPI_Free_numa(). + + Currently this is only implemented on Windows. Check for the presence + of these functions with + #ifdef TMPI_NUMA_MALLOC + .... + #endif + */ + + + +#ifdef __cplusplus +extern "C" +{ +#endif +#if 0 +} /* Avoids screwing up auto-indentation */ +#endif + + +#if (defined(WIN32) || defined( _WIN32 ) || defined(WIN64) || defined( _WIN64 ) || defined (__CYGWIN__)) + +#define TMPI_NUMA_MALLOC + +#endif + + +/*! \brief Allocate local memory by size in bytes. + + \see malloc() + + \param[in] size = size in units of sizeof() of the memory to be allocated + + \return Pointer to allocated memory, or NULL in case of failure + */ +void *tMPI_Malloc_local(size_t size); + + +/*! \brief Allocate local memory by array and element size. + + \see calloc() + + \param[in] nmemb = number of array members + \param[in] size = size in units of sizeof() of a single array element + + \return Pointer to allocated memory, or NULL in case of failure + */ +void *tMPI_Calloc_local(size_t nmemb, size_t size); + + +/*! \brief Re-allocate to local memory. + + \see realloc() + + \param[in] ptr = input pointer of originally allocated memory (can + be allocated with NUMA or non-NUMA malloc()) + \param[in] size = new size in units of sizeof(). + + \return Pointer to allocated memory, or NULL in case of failure + */ +void *tMPI_Realloc_local(void *ptr, size_t size); + + +/*! \brief Free memory allocate with any of the NUMA-aware allocators + + \see calloc() + + \param[in] ptr = pointer to block of memory allocated with a NUMA allocator + + \return Returns debug info: 0 if the memory was allocated with a NUMA + allocator, 1 if it was allocated by another allocator. + */ +int tMPI_Free_numa(void *ptr); + + +#ifdef __cplusplus +} +#endif + +#endif /* _TMPI_NUMA_MALLOC_H_ */ + diff -Nru gromacs-4.5.4/include/thread_mpi/threads.h gromacs-4.5.5/include/thread_mpi/threads.h --- gromacs-4.5.4/include/thread_mpi/threads.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/thread_mpi/threads.h 2011-09-21 12:34:32.000000000 +0000 @@ -256,10 +256,44 @@ enum tMPI_Thread_support tMPI_Thread_support(void); +/** Get the number of hardware threads that can be run simultaneously. + + Returns the total number of cores and SMT threads that can run. + + \ret The maximum number of threads that can run simulataneously. If this + number cannot be determined for the current architecture, 0 is + returned. */ +int tMPI_Thread_get_hw_number(void); + /** Create a new thread * * The new thread will call start_routine() with the argument arg. + * + * Please be careful not to change arg after calling this function. + * + * \param thread Pointer to opaque thread datatype + * \param start_routine The function to call in the new thread + * \param arg Argument to call with + * + * \return Status - 0 on success, or an error code. + */ +int tMPI_Thread_create(tMPI_Thread_t *thread, + void* (*start_routine)(void *), + void* arg); + +/** Create a new thread with processor affinity + * + * The new thread will call start_routine() with the argument arg. + * + * The new thread will have processor affinity assigned in a + * round-robin way, starting at processor 1. The first thread to call + * this function will be assigned to processor 0. + * + * This means that this funtion should ONLY be called when starting a + * thread on each processor: in any other case, this will lead to + * imbalances because processors 0 and 1 will be oversubscribed. + * * Please be careful not to change arg after calling this function. * * \param thread Pointer to opaque thread datatype @@ -268,9 +302,10 @@ * * \return Status - 0 on success, or an error code. */ -int tMPI_Thread_create (tMPI_Thread_t * thread, - void * (*start_routine)(void *), - void * arg); +int tMPI_Thread_create_aff(tMPI_Thread_t *thread, + void *(*start_routine)(void *), + void *arg); + @@ -285,8 +320,7 @@ * * \return 0 if the join went ok, or a non-zero error code. */ -int tMPI_Thread_join (tMPI_Thread_t thread, - void ** value_ptr); +int tMPI_Thread_join(tMPI_Thread_t thread, void **value_ptr); @@ -430,7 +464,7 @@ * \param cond Pointer to previously allocated condition variable * \return 0 or a non-zero error message. */ -int tMPI_Thread_cond_init(tMPI_Thread_cond_t * cond); +int tMPI_Thread_cond_init(tMPI_Thread_cond_t *cond); @@ -443,7 +477,7 @@ * \param cond Pointer to condition variable. * \return 0 or a non-zero error message. */ -int tMPI_Thread_cond_destroy(tMPI_Thread_cond_t * cond); +int tMPI_Thread_cond_destroy(tMPI_Thread_cond_t *cond); @@ -462,8 +496,8 @@ * * \return 0 or a non-zero error message. */ -int tMPI_Thread_cond_wait(tMPI_Thread_cond_t * cond, - tMPI_Thread_mutex_t * mtx); +int tMPI_Thread_cond_wait(tMPI_Thread_cond_t *cond, + tMPI_Thread_mutex_t *mtx); @@ -478,7 +512,7 @@ * * \return 0 or a non-zero error message. */ -int tMPI_Thread_cond_signal(tMPI_Thread_cond_t * cond); +int tMPI_Thread_cond_signal(tMPI_Thread_cond_t *cond); /** Unblock all waiting threads @@ -491,7 +525,7 @@ * * \return 0 or a non-zero error message. */ -int tMPI_Thread_cond_broadcast(tMPI_Thread_cond_t * cond); +int tMPI_Thread_cond_broadcast(tMPI_Thread_cond_t *cond); @@ -504,7 +538,7 @@ * join them can read this value if they try. * \return */ -void tMPI_Thread_exit(void * value_ptr); +void tMPI_Thread_exit(void *value_ptr); @@ -516,7 +550,7 @@ * \param thread Handle to thread we want to see dead. * \return 0 or a non-zero error message. */ -int tMPI_Thread_cancel(tMPI_Thread_t thread); +int tMPI_Thread_cancel(tMPI_Thread_t thread); diff -Nru gromacs-4.5.4/include/thread_mpi.h gromacs-4.5.5/include/thread_mpi.h --- gromacs-4.5.4/include/thread_mpi.h 2011-03-15 12:44:29.000000000 +0000 +++ gromacs-4.5.5/include/thread_mpi.h 2011-09-21 12:34:32.000000000 +0000 @@ -96,11 +96,11 @@ #include "thread_mpi/atomic.h" #include "thread_mpi/threads.h" +#include "thread_mpi/numa_malloc.h" #include "thread_mpi/barrier.h" #include "thread_mpi/event.h" #include "thread_mpi/lock.h" #include "thread_mpi/tmpi.h" #include "thread_mpi/collective.h" -#include "thread_mpi/hwinfo.h" diff -Nru gromacs-4.5.4/include/tmpi.h gromacs-4.5.5/include/tmpi.h --- gromacs-4.5.4/include/tmpi.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/tmpi.h 2011-09-21 12:34:32.000000000 +0000 @@ -118,13 +118,13 @@ #include "thread_mpi/atomic.h" +#include "thread_mpi/numa_malloc.h" #include "thread_mpi/threads.h" #include "thread_mpi/barrier.h" #include "thread_mpi/event.h" #include "thread_mpi/lock.h" #include "thread_mpi/tmpi.h" #include "thread_mpi/collective.h" -#include "thread_mpi/hwinfo.h" #include "thread_mpi/mpi_bindings.h" diff -Nru gromacs-4.5.4/include/typedefs.h gromacs-4.5.5/include/typedefs.h --- gromacs-4.5.4/include/typedefs.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/typedefs.h 2011-09-21 12:34:32.000000000 +0000 @@ -71,6 +71,9 @@ #include "types/constr.h" #include "types/matrix.h" #include "types/oenv.h" +#include "types/globsig.h" +#include "types/nlistheuristics.h" +#include "types/iteratedconstraints.h" #ifdef __cplusplus extern "C" { diff -Nru gromacs-4.5.4/include/types/atoms.h gromacs-4.5.5/include/types/atoms.h --- gromacs-4.5.4/include/types/atoms.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/types/atoms.h 2011-09-21 12:34:32.000000000 +0000 @@ -48,12 +48,12 @@ /* The particle type */ typedef struct { - real m,q; /* Mass and charge */ - real mB,qB; /* Mass and charge for Free Energy calc */ - unsigned short type; /* Atom type */ - unsigned short typeB; /* Atom type for Free Energy calc */ - int ptype; /* Particle type */ - int resind; /* Index into resinfo in t_atoms) */ + real m,q; /* Mass and charge */ + real mB,qB; /* Mass and charge for Free Energy calc */ + unsigned short type; /* Atom type */ + unsigned short typeB; /* Atom type for Free Energy calc */ + int ptype; /* Particle type */ + int resind; /* Index into resinfo (in t_atoms) */ int atomnumber; /* Atomic Number or NOTSET */ char elem[4]; /* Element name */ } t_atom; @@ -74,40 +74,39 @@ char atomnm[6]; /* True atom name including spaces */ real occup; /* Occupancy */ real bfac; /* B-factor */ - gmx_bool bAnisotropic; /* (an)isotropic switch */ + gmx_bool bAnisotropic; /* (an)isotropic switch */ int uij[6]; /* Anisotropic B-factor */ } t_pdbinfo; typedef struct { - int nr; /* Number of different groups */ + int nr; /* Number of different groups */ int *nm_ind; /* Index in the group names */ } t_grps; typedef struct { int nr; /* Nr of atoms */ - t_atom *atom; /* Array of atoms (dim: nr) */ - /* The following entries will not */ - /* allways be used (nres==0) */ - char ***atomname; /* Array of pointers to atom name */ - /* use: (*(atomname[i])) */ - char ***atomtype; /* Array of pointers to atom types */ - /* use: (*(atomtype[i])) */ - char ***atomtypeB; /* Array of pointers to B atom types */ - /* use: (*(atomtypeB[i])) */ - int nres; /* The number of resinfo entries */ + t_atom *atom; /* Array of atoms (dim: nr) */ + /* The following entries will not */ + /* always be used (nres==0) */ + char ***atomname; /* Array of pointers to atom name */ + /* use: (*(atomname[i])) */ + char ***atomtype; /* Array of pointers to atom types */ + /* use: (*(atomtype[i])) */ + char ***atomtypeB; /* Array of pointers to B atom types */ + /* use: (*(atomtypeB[i])) */ + int nres; /* The number of resinfo entries */ t_resinfo *resinfo; /* Array of residue names and numbers */ t_pdbinfo *pdbinfo; /* PDB Information, such as aniso. Bfac */ } t_atoms; typedef struct { - int nr; /* number of atomtypes */ - real *radius; /* GBSA radius for each atomtype */ - real *vol; /* GBSA efective volume for each atomtype */ - real *surftens; /* implicit solvent surftens for each atomtype */ - real *gb_radius; /* GB radius for each atom type */ - real *S_hct; /* Overlap factors for HCT/OBC GB models */ - - int *atomnumber; /* Atomic number, used for QM/MM */ + int nr; /* number of atomtypes */ + real *radius; /* GBSA radius for each atomtype */ + real *vol; /* GBSA efective volume for each atomtype */ + real *surftens; /* implicit solvent surftens for each atomtype */ + real *gb_radius; /* GB radius for each atom type */ + real *S_hct; /* Overlap factors for HCT/OBC GB models */ + int *atomnumber; /* Atomic number, used for QM/MM */ } t_atomtypes; diff -Nru gromacs-4.5.4/include/types/commrec.h gromacs-4.5.5/include/types/commrec.h --- gromacs-4.5.4/include/types/commrec.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/types/commrec.h 2011-09-21 12:34:32.000000000 +0000 @@ -115,6 +115,9 @@ int *ibuf; /* for ints */ int ibuf_alloc; + gmx_large_int_t *libuf; + int libuf_alloc; + float *fbuf; /* for floats */ int fbuf_alloc; diff -Nru gromacs-4.5.4/include/types/forcerec.h gromacs-4.5.5/include/types/forcerec.h --- gromacs-4.5.4/include/types/forcerec.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/types/forcerec.h 2011-09-21 12:34:32.000000000 +0000 @@ -218,7 +218,6 @@ int solvent_opt; int nWatMol; gmx_bool bGrid; - gmx_bool bExcl_IntraCGAll_InterCGNone; cginfo_mb_t *cginfo_mb; int *cginfo; rvec *cg_cm; diff -Nru gromacs-4.5.4/include/types/globsig.h gromacs-4.5.5/include/types/globsig.h --- gromacs-4.5.4/include/types/globsig.h 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/include/types/globsig.h 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,64 @@ +/* + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * GRoups of Organic Molecules in ACtion for Science + */ +#ifndef _globsig_h +#define _globsig_h + +#ifdef __cplusplus +extern "C" { +#endif + +#if 0 +} +/* Hack to make automatic indenting work */ +#endif + +/* simulation conditions to transmit. Keep in mind that they are + transmitted to other nodes through an MPI_Reduce after + casting them to a real (so the signals can be sent together with other + data). This means that the only meaningful values are positive, + negative or zero. */ +enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; + +typedef struct { + int nstms; /* The frequency for intersimulation communication */ + int sig[eglsNR]; /* The signal set by one process in do_md */ + int set[eglsNR]; /* The communicated signal, equal for all processes */ +} globsig_t; + +#ifdef __cplusplus +} +#endif + +#endif diff -Nru gromacs-4.5.4/include/types/iteratedconstraints.h gromacs-4.5.5/include/types/iteratedconstraints.h --- gromacs-4.5.4/include/types/iteratedconstraints.h 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/include/types/iteratedconstraints.h 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,70 @@ +/* + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * GRoups of Organic Molecules in ACtion for Science + */ +#ifndef _iteratedconstraints_h +#define _iteratedconstraints_h + +#ifdef __cplusplus +extern "C" { +#endif + +#if 0 +} +/* Hack to make automatic indenting work */ +#endif + +/* Definitions for convergence of iterated constraints */ + +/* iterate constraints up to 50 times */ +#define MAXITERCONST 50 + +/* data type */ +typedef struct +{ + real f,fprev,x,xprev; + int iter_i; + gmx_bool bIterate; + real allrelerr[MAXITERCONST+2]; + int num_close; /* number of "close" violations, caused by limited precision. */ +} gmx_iterate_t; + +void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate); + +gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf); + +#ifdef __cplusplus +} +#endif + +#endif diff -Nru gromacs-4.5.4/include/types/Makefile.am gromacs-4.5.5/include/types/Makefile.am --- gromacs-4.5.4/include/types/Makefile.am 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/types/Makefile.am 2011-09-21 12:34:32.000000000 +0000 @@ -9,8 +9,9 @@ mdatom.h simple.h block.h constr.h \ energy.h graph.h inputrec.h nblist.h \ ns.h nsgrid.h symtab.h commrec.h \ - enums.h group.h ishift.h \ + enums.h group.h ishift.h globsig.h \ topology.h fcdata.h filenm.h idef.h \ matrix.h nrnb.h trx.h state.h \ - pbc.h qmmmrec.h shellfc.h genborn.h + pbc.h qmmmrec.h shellfc.h genborn.h \ + iteratedconstraints.h nlistheuristics.h diff -Nru gromacs-4.5.4/include/types/Makefile.in gromacs-4.5.5/include/types/Makefile.in --- gromacs-4.5.4/include/types/Makefile.in 2011-03-21 15:13:36.000000000 +0000 +++ gromacs-4.5.5/include/types/Makefile.in 2011-09-21 12:38:30.000000000 +0000 @@ -225,10 +225,11 @@ mdatom.h simple.h block.h constr.h \ energy.h graph.h inputrec.h nblist.h \ ns.h nsgrid.h symtab.h commrec.h \ - enums.h group.h ishift.h \ + enums.h group.h ishift.h globsig.h \ topology.h fcdata.h filenm.h idef.h \ matrix.h nrnb.h trx.h state.h \ - pbc.h qmmmrec.h shellfc.h genborn.h + pbc.h qmmmrec.h shellfc.h genborn.h \ + iteratedconstraints.h nlistheuristics.h all: all-am diff -Nru gromacs-4.5.4/include/types/nlistheuristics.h gromacs-4.5.5/include/types/nlistheuristics.h --- gromacs-4.5.4/include/types/nlistheuristics.h 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/include/types/nlistheuristics.h 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,74 @@ +/* + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * GRoups of Organic Molecules in ACtion for Science + */ +#ifndef _nlistheuristics_h +#define _nlistheuristics_h + +#ifdef __cplusplus +extern "C" { +#endif + +#if 0 +} +/* Hack to make automatic indenting work */ +#endif + +typedef struct { + gmx_bool bGStatEveryStep; + gmx_large_int_t step_ns; + gmx_large_int_t step_nscheck; + gmx_large_int_t nns; + matrix scale_tot; + int nabnsb; + double s1; + double s2; + double ab; + double lt_runav; + double lt_runav2; +} gmx_nlheur_t; + +void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step); + +void init_nlistheuristics(gmx_nlheur_t *nlh, + gmx_bool bGStatEveryStep,gmx_large_int_t step); + +void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step); + +void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step); + +#ifdef __cplusplus +} +#endif + +#endif diff -Nru gromacs-4.5.4/include/types/pbc.h gromacs-4.5.5/include/types/pbc.h --- gromacs-4.5.4/include/types/pbc.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/types/pbc.h 2011-09-21 12:34:32.000000000 +0000 @@ -32,8 +32,8 @@ * And Hey: * GRoups of Organic Molecules in ACtion for Science */ -#ifndef _matrix_h -#define _matrix_h +#ifndef _pbc_h +#define _pbc_h #include "simple.h" diff -Nru gromacs-4.5.4/include/types/topology.h gromacs-4.5.5/include/types/topology.h --- gromacs-4.5.4/include/types/topology.h 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/include/types/topology.h 2011-09-21 12:34:32.000000000 +0000 @@ -52,7 +52,7 @@ typedef struct { char **name; /* Name of the molecule type */ - t_atoms atoms; /* The atoms */ + t_atoms atoms; /* The atoms */ t_ilist ilist[F_NRE]; t_block cgs; /* The charge groups */ t_blocka excls; /* The exclusions */ @@ -71,9 +71,9 @@ typedef struct { t_grps grps[egcNR]; /* Groups of things */ int ngrpname; /* Number of groupnames */ - char ***grpname; /* Names of the groups */ + char ***grpname; /* Names of the groups */ int ngrpnr[egcNR]; - unsigned char *grpnr[egcNR]; /* Group numbers or NULL */ + unsigned char *grpnr[egcNR]; /* Group numbers or NULL */ } gmx_groups_t; /* This macro gives the group number of group type egc for atom i. @@ -85,7 +85,7 @@ /* The global, complete system topology struct, based on molecule types. This structure should contain no data that is O(natoms) in memory. */ typedef struct { - char **name; /* Name of the topology */ + char **name; /* Name of the topology */ gmx_ffparams_t ffparams; int nmoltype; gmx_moltype_t *moltype; @@ -97,12 +97,12 @@ t_atomtypes atomtypes; /* Atomtype properties */ t_block mols; /* The molecules */ gmx_groups_t groups; - t_symtab symtab; /* The symbol table */ + t_symtab symtab; /* The symbol table */ } gmx_mtop_t; /* The mdrun node-local topology struct, completely written out */ typedef struct { - t_idef idef; /* The interaction function definition */ + t_idef idef; /* The interaction function definition */ t_atomtypes atomtypes; /* Atomtype properties */ t_block cgs; /* The charge groups */ t_blocka excls; /* The exclusions */ @@ -110,14 +110,14 @@ /* The old topology struct, completely written out, used in analysis tools */ typedef struct { - char **name; /* Name of the topology */ - t_idef idef; /* The interaction function definition */ - t_atoms atoms; /* The atoms */ + char **name; /* Name of the topology */ + t_idef idef; /* The interaction function definition */ + t_atoms atoms; /* The atoms */ t_atomtypes atomtypes; /* Atomtype properties */ t_block cgs; /* The charge groups */ t_block mols; /* The molecules */ t_blocka excls; /* The exclusions */ - t_symtab symtab; /* The symbol table */ + t_symtab symtab; /* The symbol table */ } t_topology; #ifdef __cplusplus diff -Nru gromacs-4.5.4/man/man1/do_dssp.1 gromacs-4.5.5/man/man1/do_dssp.1 --- gromacs-4.5.4/man/man1/do_dssp.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/do_dssp.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH do_dssp 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH do_dssp 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME do_dssp - assigns secondary structure and calculates solvent accessible surface area -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3do_dssp\fP .BI "\-f" " traj.xtc " @@ -26,12 +26,13 @@ .BI "\-xvg" " enum " .BI "\-sss" " string " .SH DESCRIPTION -\&do_dssp +\&\fB do_dssp\fR \&reads a trajectory file and computes the secondary structure for \&each time frame \&calling the dssp program. If you do not have the dssp program, -\&get it. do_dssp assumes that the dssp executable is -\&/usr/local/bin/dssp. If this is not the case, then you should +\&get it from http://swift.cmbi.ru.nl/gv/dssp. \fB do_dssp\fR assumes +\&that the dssp executable is located in +\&\fB /usr/local/bin/dssp\fR. If this is not the case, then you should \&set an environment variable \fB DSSP\fR pointing to the dssp \&executable, e.g.: @@ -42,7 +43,7 @@ \&The structure assignment for each residue and time is written to an \&\fB .xpm\fR matrix file. This file can be visualized with for instance \&\fB xv\fR and can be converted to postscript with \fB xpm2ps\fR. -\&Individual chains are separated by light grey lines in the xpm and +\&Individual chains are separated by light grey lines in the \fB .xpm\fR and \&postscript files. \&The number of residues with each secondary structure type and the \&total secondary structure (\fB \-sss\fR) count as a function of @@ -125,7 +126,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/editconf.1 gromacs-4.5.5/man/man1/editconf.1 --- gromacs-4.5.4/man/man1/editconf.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/editconf.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH editconf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH editconf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME editconf - edits the box and writes subgroups -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3editconf\fP .BI "\-f" " conf.gro " @@ -29,6 +29,7 @@ .BI "\-scale" " vector " .BI "\-density" " real " .BI "\-[no]pbc" "" +.BI "\-resnr" " int " .BI "\-[no]grasp" "" .BI "\-rvdw" " real " .BI "\-sig56" " real " @@ -38,7 +39,7 @@ .BI "\-label" " string " .BI "\-[no]conect" "" .SH DESCRIPTION -\&editconf converts generic structure format to \fB .gro\fR, \fB .g96\fR +\&\fB editconf\fR converts generic structure format to \fB .gro\fR, \fB .g96\fR \&or \fB .pdb\fR. \& @@ -56,18 +57,19 @@ \&The last two are special cases of a triclinic box. \&The length of the three box vectors of the truncated octahedron is the \&shortest distance between two opposite hexagons. -\&The volume of a dodecahedron is 0.71 and that of a truncated octahedron -\&is 0.77 of that of a cubic box with the same periodic image distance. +\&Relative to a cubic box with some periodic image distance, the volume of a +\&dodecahedron with this same periodic distance is 0.71 times that of the cube, +\&and that of a truncated octahedron is 0.77 times. \& \&Option \fB \-box\fR requires only -\&one value for a cubic box, dodecahedron and a truncated octahedron. +\&one value for a cubic, rhombic dodecahedral, or truncated octahedral box. \& -\&With \fB \-d\fR and a \fB triclinic\fR box the size of the system in the x, y -\&and z directions is used. With \fB \-d\fR and \fB cubic\fR, +\&With \fB \-d\fR and a \fB triclinic\fR box the size of the system in the \fI x\fR\-, \fI y\fR\-, +\&and \fI z\fR\-directions is used. With \fB \-d\fR and \fB cubic\fR, \&\fB dodecahedron\fR or \fB octahedron\fR boxes, the dimensions are set \&to the diameter of the system (largest distance between atoms) plus twice \&the specified distance. @@ -75,7 +77,7 @@ \&Option \fB \-angles\fR is only meaningful with option \fB \-box\fR and -\&a triclinic box and can not be used with option \fB \-d\fR. +\&a triclinic box and cannot be used with option \fB \-d\fR. \& @@ -90,17 +92,18 @@ \&\fB \-princ\fR aligns the principal axes of the system along the -\&coordinate axes, this may allow you to decrease the box volume, +\&coordinate axes, with the longest axis aligned with the \fI x\fR\-axis. +\&This may allow you to decrease the box volume, \&but beware that molecules can rotate significantly in a nanosecond. \& \&Scaling is applied before any of the other operations are \&performed. Boxes and coordinates can be scaled to give a certain density (option -\&\fB \-density\fR). Note that this may be inaccurate in case a gro -\&file is given as input. A special feature of the scaling option, when the +\&\fB \-density\fR). Note that this may be inaccurate in case a \fB .gro\fR +\&file is given as input. A special feature of the scaling option is that when the \&factor \-1 is given in one dimension, one obtains a mirror image, -\&mirrored in one of the plains, when one uses \-1 in three dimensions +\&mirrored in one of the planes. When one uses \-1 in three dimensions, \&a point\-mirror image is obtained. @@ -108,7 +111,7 @@ \&Periodicity can be removed in a crude manner. -\&It is important that the box sizes at the bottom of your input file +\&It is important that the box vectors at the bottom of your input file \&are correct when the periodicity is to be removed. \& @@ -126,7 +129,8 @@ \& -\&With the option \-mead a special pdb (pqr) file for the MEAD electrostatics +\&With the option \fB \-mead\fR a special \fB .pdb\fR (\fB .pqr\fR) +\&file for the MEAD electrostatics \&program (Poisson\-Boltzmann solver) can be made. A further prerequisite \&is that the input file is a run input file. \&The B\-factor field is then filled with the Van der Waals radius @@ -134,7 +138,7 @@ \& -\&The option \-grasp is similar, but it puts the charges in the B\-factor +\&The option \fB \-grasp\fR is similar, but it puts the charges in the B\-factor \&and the radius in the occupancy. \& @@ -145,13 +149,13 @@ \& -\&Finally with option \fB \-label\fR editconf can add a chain identifier -\&to a pdb file, which can be useful for analysis with e.g. rasmol. +\&Finally, with option \fB \-label\fR, \fB editconf\fR can add a chain identifier +\&to a \fB .pdb\fR file, which can be useful for analysis with e.g. Rasmol. \& \&To convert a truncated octrahedron file produced by a package which uses -\&a cubic box with the corners cut off (such as Gromos) use: +\&a cubic box with the corners cut off (such as GROMOS), use: \&\fB editconf \-f in \-rotate 0 45 35.264 \-bt o \-box veclen \-o out\fR @@ -188,7 +192,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-[no]ndef" "no " Choose output from default index groups @@ -230,11 +234,14 @@ Scaling factor .BI "\-density" " real" " 1000 " - Density (g/l) of the output box achieved by scaling + Density (g/L) of the output box achieved by scaling .BI "\-[no]pbc" "no " Remove the periodicity (make molecule whole again) +.BI "\-resnr" " int" " \-1" + Renumber residues starting from resnr + .BI "\-[no]grasp" "no " Store the charge of the atom in the B\-factor field and the radius of the atom in the occupancy field @@ -257,12 +264,10 @@ Add chain label for all residues .BI "\-[no]conect" "no " - Add CONECT records to a pdb file when written. Can only be done when a topology is present + Add CONECT records to a \fB .pdb\fR file when written. Can only be done when a topology is present .SH KNOWN PROBLEMS -\- For complex molecules, the periodicity removal routine may break down, - -\- in that case you can use trjconv. +\- For complex molecules, the periodicity removal routine may break down, in that case you can use \fB trjconv\fR. .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/eneconv.1 gromacs-4.5.5/man/man1/eneconv.1 --- gromacs-4.5.4/man/man1/eneconv.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/eneconv.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH eneconv 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH eneconv 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME eneconv - converts energy files -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3eneconv\fP .BI "\-f" " ener.edr " @@ -16,17 +16,18 @@ .BI "\-offset" " real " .BI "\-[no]settime" "" .BI "\-[no]sort" "" +.BI "\-[no]rmdh" "" .BI "\-scalefac" " real " .BI "\-[no]error" "" .SH DESCRIPTION \&With \fI multiple files\fR specified for the \fB \-f\fR option: \&Concatenates several energy files in sorted order. -\&In case of double time frames the one +\&In the case of double time frames, the one \&in the later file is used. By specifying \fB \-settime\fR you will be \&asked for the start time of each file. The input files are taken \&from the command line, -\&such that the command \fB eneconv \-o fixed.edr *.edr\fR should do +\&such that the command \fB eneconv \-f *.edr \-o fixed.edr\fR should do \&the trick. @@ -69,7 +70,7 @@ Only write out frame when t MOD dt = offset .BI "\-offset" " real" " 0 " - Time offset for \-dt option + Time offset for \fB \-dt\fR option .BI "\-[no]settime" "no " Change starting time interactively @@ -77,6 +78,9 @@ .BI "\-[no]sort" "yes " Sort energy files (not frames) +.BI "\-[no]rmdh" "no " + Remove free energy block data + .BI "\-scalefac" " real" " 1 " Multiply energy component by this factor diff -Nru gromacs-4.5.4/man/man1/g_anadock.1 gromacs-4.5.5/man/man1/g_anadock.1 --- gromacs-4.5.4/man/man1/g_anadock.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_anadock.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_anadock 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_anadock 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_anadock - cluster structures from Autodock runs -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_anadock\fP .BI "\-f" " eiwit.pdb " @@ -18,14 +18,14 @@ .BI "\-[no]rms" "" .BI "\-cutoff" " real " .SH DESCRIPTION -\&anadock analyses the results of an Autodock run and clusters the +\&\fB g_anadock\fR analyses the results of an Autodock run and clusters the \&structures together, based on distance or RMSD. The docked energy \&and free energy estimates are analysed, and for each cluster the \&energy statistics are printed. \&An alternative approach to this is to cluster the structures first -\&(using \fB g_cluster\fR and then sort the clusters on either lowest +\&using \fB g_cluster\fR and then sort the clusters on either lowest \&energy or average energy. .SH FILES .BI "\-f" " eiwit.pdb" diff -Nru gromacs-4.5.4/man/man1/g_anaeig.1 gromacs-4.5.5/man/man1/g_anaeig.1 --- gromacs-4.5.4/man/man1/g_anaeig.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_anaeig.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_anaeig 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_anaeig 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_anaeig - analyzes the eigenvectors -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_anaeig\fP .BI "\-v" " eigenvec.trr " @@ -91,12 +91,12 @@ \&\fB \-last\fR have been set explicitly, in which case all eigenvectors \&will be written to separate files. Chain identifiers will be added \&when writing a \fB .pdb\fR file with two or three structures (you -\&can use \fB rasmol \-nmrpdb\fR to view such a pdb file). +\&can use \fB rasmol \-nmrpdb\fR to view such a \fB .pdb\fR file). \& Overlap calculations between covariance analysis: -\& NOTE: the analysis should use the same fitting structure +\& \fB Note:\fR the analysis should use the same fitting structure \&\fB \-over\fR: calculate the subspace overlap of the eigenvectors in @@ -218,7 +218,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_analyze.1 gromacs-4.5.5/man/man1/g_analyze.1 --- gromacs-4.5.4/man/man1/g_analyze.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_analyze.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_analyze 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_analyze 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_analyze - analyzes data sets -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_analyze\fP .BI "\-f" " graph.xvg " @@ -47,23 +47,23 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_analyze reads an ascii file and analyzes data sets. +\&\fB g_analyze\fR reads an ASCII file and analyzes data sets. \&A line in the input file may start with a time -\&(see option \fB \-time\fR) and any number of y values may follow. +\&(see option \fB \-time\fR) and any number of \fI y\fR\-values may follow. \&Multiple sets can also be -\&read when they are separated by & (option \fB \-n\fR), -\&in this case only one y value is read from each line. +\&read when they are separated by & (option \fB \-n\fR); +\&in this case only one \fI y\fR\-value is read from each line. \&All lines starting with and @ are skipped. \&All analyses can also be done for the derivative of a set \&(option \fB \-d\fR). -\&All options, except for \fB \-av\fR and \fB \-power\fR assume that the +\&All options, except for \fB \-av\fR and \fB \-power\fR, assume that the \&points are equidistant in time. -\&g_analyze always shows the average and standard deviation of each -\&set. For each set it also shows the relative deviation of the third +\&\fB g_analyze\fR always shows the average and standard deviation of each +\&set, as well as the relative deviation of the third \&and fourth cumulant from those of a Gaussian distribution with the same \&standard deviation. @@ -104,13 +104,13 @@ \&that the autocorrelation is a sum of two exponentials. \&The analytical curve for the block average is: -\&f(t) = sigma sqrt(2/T ( a (tau1 ((exp(\-t/tau1) \- 1) tau1/t + 1)) + +\&f(t) = sigma\fB *\fRsqrt(2/T ( alpha (tau1 ((exp(\-t/tau1) \- 1) tau1/t + 1)) + -\& (1\-a) (tau2 ((exp(\-t/tau2) \- 1) tau2/t + 1)))), +\& (1\-alpha) (tau2 ((exp(\-t/tau2) \- 1) tau2/t + 1)))), where T is the total time. -\&a, tau1 and tau2 are obtained by fitting f2(t) to error2. +\&alpha, tau1 and tau2 are obtained by fitting f2(t) to error2. \&When the actual block average is very close to the analytical curve, -\&the error is sigma*sqrt(2/T (a tau1 + (1\-a) tau2)). +\&the error is sigma\fB *\fRsqrt(2/T (a tau1 + (1\-a) tau2)). \&The complete derivation is given in \&B. Hess, J. Chem. Phys. 116:209\-217, 2002. @@ -145,7 +145,7 @@ \&Option \fB \-power\fR fits the data to b ta, which is accomplished \&by fitting to a t + b on log\-log scale. All points after the first -\&zero or negative value are ignored. +\&zero or with a negative value are ignored. Option \fB \-luzar\fR performs a Luzar & Chandler kinetics analysis \&on output from \fB g_hbond\fR. The input file can be taken directly @@ -198,7 +198,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -222,7 +222,7 @@ Binwidth for the distribution .BI "\-errbar" " enum" " none" - Error bars for \-av: \fB none\fR, \fB stddev\fR, \fB error\fR or \fB 90\fR + Error bars for \fB \-av\fR: \fB none\fR, \fB stddev\fR, \fB error\fR or \fB 90\fR .BI "\-[no]integrate" "no " Integrate data function(s) numerically using trapezium rule @@ -234,10 +234,10 @@ Interpret second data set as error in the y values for integrating .BI "\-[no]regression" "no " - Perform a linear regression analysis on the data. If \-xydy is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize chi2 = (y \- A0 x0 \- A1 x1 \- ... \- AN xN)2 where now Y is the first data set in the input file and xi the others. Do read the information at the option \fB \-time\fR. + Perform a linear regression analysis on the data. If \fB \-xydy\fR is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize chi2 = (y \- A0 x0 \- A1 x1 \- ... \- AN xN)2 where now Y is the first data set in the input file and xi the others. Do read the information at the option \fB \-time\fR. .BI "\-[no]luzar" "no " - Do a Luzar and Chandler analysis on a correlation function and related as produced by g_hbond. When in addition the \-xydy flag is given the second and fourth column will be interpreted as errors in c(t) and n(t). + Do a Luzar and Chandler analysis on a correlation function and related as produced by \fB g_hbond\fR. When in addition the \fB \-xydy\fR flag is given the second and fourth column will be interpreted as errors in c(t) and n(t). .BI "\-temp" " real" " 298.15" Temperature for the Luzar hydrogen bonding kinetics analysis @@ -246,7 +246,7 @@ Time (ps) from which to start fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation .BI "\-fitend" " real" " 60 " - Time (ps) where to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. Only with \-gem + Time (ps) where to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. Only with \fB \-gem\fR .BI "\-smooth" " real" " \-1 " If = 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(\-x/tau) @@ -273,7 +273,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_angle.1 gromacs-4.5.5/man/man1/g_angle.1 --- gromacs-4.5.4/man/man1/g_angle.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_angle.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_angle 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_angle 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_angle - calculates distributions and correlations for angles and dihedrals -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_angle\fP .BI "\-f" " traj.xtc " @@ -36,22 +36,22 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_angle computes the angle distribution for a number of angles +\&\fB g_angle\fR computes the angle distribution for a number of angles \&or dihedrals. This way you can check whether your simulation -\&is correct. With option \-ov you can plot the average angle of -\&a group of angles as a function of time. With the \-all option +\&is correct. With option \fB \-ov\fR you can plot the average angle of +\&a group of angles as a function of time. With the \fB \-all\fR option \&the first graph is the average, the rest are the individual angles. -\&With the \-of option g_angle also calculates the fraction of trans +\&With the \fB \-of\fR option, \fB g_angle\fR also calculates the fraction of trans \&dihedrals (only for dihedrals) as function of time, but this is \&probably only fun for a selected few. -\&With option \-oc a dihedral correlation function is calculated. +\&With option \fB \-oc\fR a dihedral correlation function is calculated. -\&It should be noted that the indexfile should contain +\&It should be noted that the index file should contain \&atom\-triples for angles or atom\-quadruplets for dihedrals. \&If this is not the case, the program will crash. @@ -116,7 +116,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -134,7 +134,7 @@ Print dihedral angles modulo 360 degrees .BI "\-[no]chandler" "no " - Use Chandler correlation function (N[trans] = 1, N[gauche] = 0) rather than cosine correlation function. Trans is defined as phi \-60 || phi 60. + Use Chandler correlation function (N[trans] = 1, N[gauche] = 0) rather than cosine correlation function. Trans is defined as phi \-60 or phi 60. .BI "\-[no]avercorr" "no " Average the correlation functions for the individual angles/dihedrals @@ -149,7 +149,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_bar.1 gromacs-4.5.5/man/man1/g_bar.1 --- gromacs-4.5.4/man/man1/g_bar.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_bar.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,15 +1,15 @@ -.TH g_bar 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_bar 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_bar - calculates free energy difference estimates through Bennett's acceptance ratio -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_bar\fP .BI "\-f" " dhdl.xvg " +.BI "\-g" " ener.edr " .BI "\-o" " bar.xvg " .BI "\-oi" " barint.xvg " .BI "\-oh" " histogram.xvg " -.BI "\-g" " energy.edr " .BI "\-[no]h" "" .BI "\-[no]version" "" .BI "\-nice" " int " @@ -23,42 +23,73 @@ .BI "\-nbmax" " int " .BI "\-nbin" " int " .SH DESCRIPTION -\&g_bar calculates free energy difference estimates through -\&Bennett's acceptance ratio method. -\&Input option \fB \-f\fR expects multiple dhdl files. +\&\fB g_bar\fR calculates free energy difference estimates through +\&Bennett's acceptance ratio method (BAR). It also automatically +\&adds series of individual free energies obtained with BAR into +\&a combined free energy estimate. + + +\&Every individual BAR free energy difference relies on two +\&simulations at different states: say state A and state B, as +\&controlled by a parameter, lambda (see the \fB .mdp\fR parameter +\&\fB init_lambda\fR). The BAR method calculates a ratio of weighted +\&average of the Hamiltonian difference of state B given state A and +\&vice versa. If the Hamiltonian does not depend linearly on lambda +\&(in which case we can extrapolate the derivative of the Hamiltonian +\&with respect to lambda, as is the default when \fB free_energy\fR is on), +\&the energy differences to the other state need to be calculated +\&explicitly during the simulation. This can be controlled with +\&the \fB .mdp\fR option \fB foreign_lambda\fR. + + +\&Input option \fB \-f\fR expects multiple \fB dhdl.xvg\fR files. \&Two types of input files are supported: -\&* Files with only one y\-value, for such files it is assumed -\&that the y\-value is dH/dlambda and that the Hamiltonian depends -\&linearly on lambda. The lambda value of the simulation is inferred -\&from the subtitle if present, otherwise from a number in the -\&subdirectory in the file name. +\&\fB *\fR Files with only one \fI y\fR\-value, for such files it is assumed +\& that the \fI y\fR\-value is dH/dlambda and that the Hamiltonian depends +\& linearly on lambda. The lambda value of the simulation is inferred +\& from the subtitle (if present), otherwise from a number in the +\& subdirectory in the file name. \& -\&* Files with more than one y\-value. The files should have columns -\&with dH/dlambda and Delta lambda. The lambda values are inferred -\&from the legends: -\&lambda of the simulation from the legend of dH/dlambda -\&and the foreign lambda's from the legends of Delta H. +\&\fB *\fR Files with more than one \fI y\fR\-value. The files should have columns +\& with dH/dlambda and Deltalambda. The lambda values are inferred +\& from the legends: lambda of the simulation from the legend of dH/dlambda +\& and the foreign lambda values from the legends of Delta H. -\&The lambda of the simulation is parsed from dhdl.xvg file's legend -\&containing the string 'dH', the foreign lambda's from the legend +\&The lambda of the simulation is parsed from \fB dhdl.xvg\fR file's legend +\&containing the string 'dH', the foreign lambda values from the legend \&containing the capitalized letters 'D' and 'H'. The temperature \&is parsed from the legend line containing 'T ='. -\&The free energy estimates are determined using BAR with bisection, -\&the precision of the output is set with \fB \-prec\fR. +\&The input option \fB \-g\fR expects multiple \fB .edr\fR files. +\&These can contain either lists of energy differences (see the +\&\fB .mdp\fR option \fB separate_dhdl_file\fR), or a series of histograms +\&(see the \fB .mdp\fR options \fB dh_hist_size\fR and \fB dh_hist_spacing\fR). +\&The temperature and lambda values are automatically deduced from +\&the \fB ener.edr\fR file. + +The free energy estimates are determined using BAR with bisection, +\&with the precision of the output set with \fB \-prec\fR. \&An error estimate taking into account time correlations \&is made by splitting the data into blocks and determining \&the free energy differences over those blocks and assuming \&the blocks are independent. \&The final error estimate is determined from the average variance -\&over 5 blocks. A range of blocks numbers for error estimation can +\&over 5 blocks. A range of block numbers for error estimation can \&be provided with the options \fB \-nbmin\fR and \fB \-nbmax\fR. +\&\fB g_bar\fR tries to aggregate samples with the same 'native' and 'foreign' +\&lambda values, but always assumes independent samples. \fB Note\fR that +\&when aggregating energy differences/derivatives with different +\&sampling intervals, this is almost certainly not correct. Usually +\&subsequent energies are correlated and different time intervals mean +\&different degrees of correlation between samples. + + \&The results are split in two parts: the last part contains the final \&results in kJ/mol, together with the error estimate for each part \&and the total. The first part contains detailed free energy @@ -66,17 +97,17 @@ \&kT (together with their computed error estimate). The printed \&values are: -\&* lam_A: the lambda values for point A. +\&\fB *\fR lam_A: the lambda values for point A. -\&* lam_B: the lambda values for point B. +\&\fB *\fR lam_B: the lambda values for point B. -\&* DG: the free energy estimate. +\&\fB *\fR DG: the free energy estimate. -\&* s_A: an estimate of the relative entropy of B in A. +\&\fB *\fR s_A: an estimate of the relative entropy of B in A. -\&* s_A: an estimate of the relative entropy of A in B. +\&\fB *\fR s_A: an estimate of the relative entropy of A in B. -\&* stdev: an estimate expected per\-sample standard deviation. +\&\fB *\fR stdev: an estimate expected per\-sample standard deviation. \&The relative entropy of both states in each other's ensemble can be @@ -85,15 +116,19 @@ \&ensemble of lambda_A (and vice versa for s_B), is a \&measure of the 'distance' between Boltzmann distributions of \&the two states, that goes to zero for identical distributions. See -\&Wu & Kofke, J. Chem. Phys. 123 084109 (2009) for more information. +\&Wu & Kofke, J. Chem. Phys. 123 084109 (2005) for more information. \& \&The estimate of the expected per\-sample standard deviation, as given -\&in Bennett's original BAR paper: -\&Bennett, J. Comp. Phys. 22, p 245 (1976), Eq. 10 gives an estimate -\&of the quality of sampling (not directly of the actual statistical -\&error, because it assumes independent samples). +\&in Bennett's original BAR paper: Bennett, J. Comp. Phys. 22, p 245 (1976). +\&Eq. 10 therein gives an estimate of the quality of sampling (not directly +\&of the actual statistical error, because it assumes independent samples). + + +\&To get a visual estimate of the phase space overlap, use the +\&\fB \-oh\fR option to write series of histograms, together with the +\&\fB \-nbin\fR option. .SH FILES @@ -101,6 +136,10 @@ .B Input, Opt., Mult. xvgr/xmgr file +.BI "\-g" " ener.edr" +.B Input, Opt., Mult. + Energy file + .BI "\-o" " bar.xvg" .B Output, Opt. xvgr/xmgr file @@ -113,10 +152,6 @@ .B Output, Opt. xvgr/xmgr file -.BI "\-g" " energy.edr" -.B Input, Opt., Mult. - Energy file - .SH OTHER OPTIONS .BI "\-[no]h" "no " Print help info and quit @@ -128,7 +163,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_bond.1 gromacs-4.5.5/man/man1/g_bond.1 --- gromacs-4.5.4/man/man1/g_bond.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_bond.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_bond 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_bond 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_bond - calculates distances between atoms -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_bond\fP .BI "\-f" " traj.xtc " @@ -24,8 +24,8 @@ .BI "\-[no]aver" "" .BI "\-[no]averdist" "" .SH DESCRIPTION -\&g_bond makes a distribution of bond lengths. If all is well a -\&gaussian distribution should be made when using a harmonic potential. +\&\fB g_bond\fR makes a distribution of bond lengths. If all is well a +\&Gaussian distribution should be made when using a harmonic potential. \&Bonds are read from a single group in the index file in order i1\-j1 \&i2\-j2 through in\-jn. @@ -84,7 +84,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -99,7 +99,7 @@ Average bond length distributions .BI "\-[no]averdist" "yes " - Average distances (turns on \-d) + Average distances (turns on \fB \-d\fR) .SH KNOWN PROBLEMS \- It should be possible to get bond information from the topology. diff -Nru gromacs-4.5.4/man/man1/g_bundle.1 gromacs-4.5.5/man/man1/g_bundle.1 --- gromacs-4.5.4/man/man1/g_bundle.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_bundle.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_bundle 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_bundle 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_bundle - analyzes bundles of axes, e.g. helices -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_bundle\fP .BI "\-f" " traj.xtc " @@ -29,7 +29,7 @@ .BI "\-na" " int " .BI "\-[no]z" "" .SH DESCRIPTION -\&g_bundle analyzes bundles of axes. The axes can be for instance +\&\fB g_bundle\fR analyzes bundles of axes. The axes can be for instance \&helix axes. The program reads two index groups and divides both \&of them in \fB \-na\fR parts. The centers of mass of these parts \&define the tops and bottoms of the axes. @@ -50,8 +50,8 @@ \&With option \fB \-oa\fR the top, mid (or kink when \fB \-ok\fR is set) \&and bottom points of each axis -\&are written to a pdb file each frame. The residue numbers correspond -\&to the axis numbers. When viewing this file with \fB rasmol\fR, use the +\&are written to a \fB .pdb\fR file each frame. The residue numbers correspond +\&to the axis numbers. When viewing this file with Rasmol, use the \&command line option \fB \-nmrpdb\fR, and type \fB set axis true\fR to \&display the reference axis. .SH FILES @@ -136,7 +136,7 @@ Number of axes .BI "\-[no]z" "no " - Use the Z\-axis as reference iso the average axis + Use the \fI z\fR\-axis as reference instead of the average axis .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_chi.1 gromacs-4.5.5/man/man1/g_chi.1 --- gromacs-4.5.4/man/man1/g_chi.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_chi.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_chi 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_chi 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_chi - calculates everything you want to know about chi and other dihedrals -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_chi\fP .BI "\-s" " conf.gro " @@ -52,25 +52,25 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_chi computes phi, psi, omega and chi dihedrals for all your +\&\fB g_chi\fR computes phi, psi, omega, and chi dihedrals for all your \&amino acid backbone and sidechains. \&It can compute dihedral angle as a function of time, and as \&histogram distributions. -\&The distributions (histo\-(dihedral)(RESIDUE).xvg) are cumulative over all residues of each type. +\&The distributions \fB (histo\-(dihedral)(RESIDUE).xvg\fR) are cumulative over all residues of each type. \&If option \fB \-corr\fR is given, the program will \&calculate dihedral autocorrelation functions. The function used \&is C(t) = cos(chi(tau)) cos(chi(tau+t)) . The use of cosines \&rather than angles themselves, resolves the problem of periodicity. -\&(Van der Spoel & Berendsen (1997), \fB Biophys. J. 72\fR, 2032\-2041). +\&(Van der Spoel & Berendsen (1997), Biophys. J. 72, 2032\-2041). \&Separate files for each dihedral of each residue -\&(corr(dihedral)(RESIDUE)(nresnr).xvg) are output, as well as a +\&\fB (corr(dihedral)(RESIDUE)(nresnr).xvg\fR) are output, as well as a \&file containing the information for all residues (argument of \fB \-corr\fR). \&With option \fB \-all\fR, the angles themselves as a function of time for -\&each residue are printed to separate files (dihedral)(RESIDUE)(nresnr).xvg. +\&each residue are printed to separate files \fB (dihedral)(RESIDUE)(nresnr).xvg\fR. \&These can be in radians or degrees. @@ -85,32 +85,33 @@ \&(d) a table for each residue of the rotamer occupancy. -\&All rotamers are taken as 3\-fold, except for omegas and chi\-dihedrals -\&to planar groups (i.e. chi2 of aromatics asp and asn, chi3 of glu -\&and gln, and chi4 of arg), which are 2\-fold. "rotamer 0" means + +\&All rotamers are taken as 3\-fold, except for omega and chi dihedrals +\&to planar groups (i.e. chi2 of aromatics, Asp and Asn; chi3 of Glu +\&and Gln; and chi4 of Arg), which are 2\-fold. "rotamer 0" means \&that the dihedral was not in the core region of each rotamer. \&The width of the core region can be set with \fB \-core_rotamer\fR -\&The S2 order parameters are also output to an xvg file -\&(argument \fB \-o\fR ) and optionally as a pdb file with +\&The S2 order parameters are also output to an \fB .xvg\fR file +\&(argument \fB \-o\fR ) and optionally as a \fB .pdb\fR file with \&the S2 values as B\-factor (argument \fB \-p\fR). \&The total number of rotamer transitions per timestep \&(argument \fB \-ot\fR), the number of transitions per rotamer \&(argument \fB \-rt\fR), and the 3J couplings (argument \fB \-jc\fR), -\&can also be written to .xvg files. +\&can also be written to \fB .xvg\fR files. -\&If \fB \-chi_prod\fR is set (and maxchi 0), cumulative rotamers, e.g. +\&If \fB \-chi_prod\fR is set (and \fB \-maxchi\fR 0), cumulative rotamers, e.g. \&1+9(chi1\-1)+3(chi2\-1)+(chi3\-1) (if the residue has three 3\-fold -\&dihedrals and maxchi = 3) +\&dihedrals and \fB \-maxchi\fR = 3) \&are calculated. As before, if any dihedral is not in the core region, \&the rotamer is taken to be 0. The occupancies of these cumulative \&rotamers (starting with rotamer 0) are written to the file \&that is the argument of \fB \-cp\fR, and if the \fB \-all\fR flag \&is given, the rotamers as functions of time -\&are written to chiproduct(RESIDUE)(nresnr).xvg -\&and their occupancies to histo\-chiproduct(RESIDUE)(nresnr).xvg. +\&are written to \fB chiproduct(RESIDUE)(nresnr).xvg\fR +\&and their occupancies to \fB histo\-chiproduct(RESIDUE)(nresnr).xvg\fR. \&The option \fB \-r\fR generates a contour plot of the average omega angle @@ -185,7 +186,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -194,16 +195,16 @@ starting residue .BI "\-[no]phi" "no " - Output for Phi dihedral angles + Output for phi dihedral angles .BI "\-[no]psi" "no " - Output for Psi dihedral angles + Output for psi dihedral angles .BI "\-[no]omega" "no " - Output for Omega dihedrals (peptide bonds) + Output for omega dihedrals (peptide bonds) .BI "\-[no]rama" "no " - Generate Phi/Psi and Chi1/Chi2 ramachandran plots + Generate phi/psi and chi1/chi2 Ramachandran plots .BI "\-[no]viol" "no " Write a file that gives 0 or 1 for violated Ramachandran angles @@ -218,25 +219,25 @@ in angle vs time files, use radians rather than degrees. .BI "\-[no]shift" "no " - Compute chemical shifts from Phi/Psi angles + Compute chemical shifts from phi/psi angles .BI "\-binwidth" " int" " 1" bin width for histograms (degrees) .BI "\-core_rotamer" " real" " 0.5 " - only the central \-core_rotamer*(360/multiplicity) belongs to each rotamer (the rest is assigned to rotamer 0) + only the central \fB \-core_rotamer\fR*(360/multiplicity) belongs to each rotamer (the rest is assigned to rotamer 0) .BI "\-maxchi" " enum" " 0" - calculate first ndih Chi dihedrals: \fB 0\fR, \fB 1\fR, \fB 2\fR, \fB 3\fR, \fB 4\fR, \fB 5\fR or \fB 6\fR + calculate first ndih chi dihedrals: \fB 0\fR, \fB 1\fR, \fB 2\fR, \fB 3\fR, \fB 4\fR, \fB 5\fR or \fB 6\fR .BI "\-[no]normhisto" "yes " Normalize histograms .BI "\-[no]ramomega" "no " - compute average omega as a function of phi/psi and plot it in an xpm plot + compute average omega as a function of phi/psi and plot it in an \fB .xpm\fR plot .BI "\-bfact" " real" " \-1 " - B\-factor value for pdb file for atoms with no calculated dihedral order parameter + B\-factor value for \fB .pdb\fR file for atoms with no calculated dihedral order parameter .BI "\-[no]chi_prod" "no " compute a single cumulative rotamer for each residue @@ -245,7 +246,7 @@ Include dihedrals to sidechain hydrogens .BI "\-bmax" " real" " 0 " - Maximum B\-factor on any of the atoms that make up a dihedral, for the dihedral angle to be considere in the statistics. Applies to database work where a number of X\-Ray structures is analyzed. \-bmax = 0 means no limit. + Maximum B\-factor on any of the atoms that make up a dihedral, for the dihedral angle to be considere in the statistics. Applies to database work where a number of X\-Ray structures is analyzed. \fB \-bmax\fR = 0 means no limit. .BI "\-acflen" " int" " \-1" Length of the ACF, default is half the number of frames @@ -257,7 +258,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions @@ -271,11 +272,11 @@ .SH KNOWN PROBLEMS \- Produces MANY output files (up to about 4 times the number of residues in the protein, twice that if autocorrelation functions are calculated). Typically several hundred files are output. -\- Phi and psi dihedrals are calculated in a non\-standard way, using H\-N\-CA\-C for phi instead of C(\-)\-N\-CA\-C, and N\-CA\-C\-O for psi instead of N\-CA\-C\-N(+). This causes (usually small) discrepancies with the output of other tools like g_rama. +\- phi and psi dihedrals are calculated in a non\-standard way, using H\-N\-CA\-C for phi instead of C(\-)\-N\-CA\-C, and N\-CA\-C\-O for psi instead of N\-CA\-C\-N(+). This causes (usually small) discrepancies with the output of other tools like \fB g_rama\fR. -\- \-r0 option does not work properly +\- \fB \-r0\fR option does not work properly -\- Rotamers with multiplicity 2 are printed in chi.log as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0 +\- Rotamers with multiplicity 2 are printed in \fB chi.log\fR as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0 .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_cluster.1 gromacs-4.5.5/man/man1/g_cluster.1 --- gromacs-4.5.4/man/man1/g_cluster.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_cluster.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_cluster 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_cluster 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_cluster - clusters structures -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_cluster\fP .BI "\-f" " traj.xtc " @@ -45,10 +45,11 @@ .BI "\-seed" " int " .BI "\-niter" " int " .BI "\-kT" " real " +.BI "\-[no]pbc" "" .SH DESCRIPTION -\&g_cluster can cluster structures with several different methods. +\&\fB g_cluster\fR can cluster structures using several different methods. \&Distances between structures can be determined from a trajectory -\&or read from an XPM matrix file with the \fB \-dm\fR option. +\&or read from an \fB .xpm\fR matrix file with the \fB \-dm\fR option. \&RMS deviation after fitting or RMS deviation of atom\-pair distances \&can be used to define the distance between structures. @@ -74,7 +75,7 @@ \&(\fI Angew. Chem. Int. Ed.\fR \fB 1999\fR, \fI 38\fR, pp 236\-240). \&Count number of neighbors using cut\-off, take structure with \&largest number of neighbors with all its neighbors as cluster -\&and eleminate it from the pool of clusters. Repeat for remaining +\&and eliminate it from the pool of clusters. Repeat for remaining \&structures in pool. @@ -198,7 +199,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -237,10 +238,10 @@ Method for cluster determination: \fB linkage\fR, \fB jarvis\-patrick\fR, \fB monte\-carlo\fR, \fB diagonalization\fR or \fB gromos\fR .BI "\-minstruct" " int" " 1" - Minimum number of structures in cluster for coloring in the xpm file + Minimum number of structures in cluster for coloring in the \fB .xpm\fR file .BI "\-[no]binary" "no " - Treat the RMSD matrix as consisting of 0 and 1, where the cut\-off is given by \-cutoff + Treat the RMSD matrix as consisting of 0 and 1, where the cut\-off is given by \fB \-cutoff\fR .BI "\-M" " int" " 10" Number of nearest neighbors considered for Jarvis\-Patrick algorithm, 0 is use cutoff @@ -257,6 +258,9 @@ .BI "\-kT" " real" " 0.001 " Boltzmann weighting factor for Monte Carlo optimization (zero turns off uphill steps) +.BI "\-[no]pbc" "yes " + PBC check + .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_clustsize.1 gromacs-4.5.5/man/man1/g_clustsize.1 --- gromacs-4.5.4/man/man1/g_clustsize.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_clustsize.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_clustsize 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_clustsize 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_clustsize - calculate size distributions of atomic clusters -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_clustsize\fP .BI "\-f" " traj.xtc " @@ -35,8 +35,8 @@ .BI "\-rgbhi" " vector " .SH DESCRIPTION \&This program computes the size distributions of molecular/atomic clusters in -\&the gas phase. The output is given in the form of a XPM file. -\&The total number of clusters is written to a XVG file. +\&the gas phase. The output is given in the form of an \fB .xpm\fR file. +\&The total number of clusters is written to an \fB .xvg\fR file. \&When the \fB \-mol\fR option is given clusters will be made out of @@ -46,11 +46,11 @@ \&When velocities are present in your trajectory, the temperature of -\&the largest cluster will be printed in a separate xvg file assuming +\&the largest cluster will be printed in a separate \fB .xvg\fR file assuming \&that the particles are free to move. If you are using constraints, \&please correct the temperature. For instance water simulated with SHAKE \&or SETTLE will yield a temperature that is 1.5 times too low. You can -\&compensate for this with the \-ndf option. Remember to take the removal +\&compensate for this with the \fB \-ndf\fR option. Remember to take the removal \&of center of mass motion into account. @@ -124,7 +124,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -133,7 +133,7 @@ Largest distance (nm) to be considered in a cluster .BI "\-[no]mol" "no " - Cluster molecules rather than atoms (needs tpr file) + Cluster molecules rather than atoms (needs \fB .tpr\fR file) .BI "\-[no]pbc" "yes " Use periodic boundary conditions @@ -142,7 +142,7 @@ Number of frames to skip between writing .BI "\-nlevels" " int" " 20" - Number of levels of grey in xpm output + Number of levels of grey in \fB .xpm\fR output .BI "\-ndf" " int" " \-1" Number of degrees of freedom of the entire system for temperature calculation. If not set, the number of atoms times three is used. diff -Nru gromacs-4.5.4/man/man1/g_confrms.1 gromacs-4.5.5/man/man1/g_confrms.1 --- gromacs-4.5.4/man/man1/g_confrms.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_confrms.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_confrms 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_confrms 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_confrms - fits two structures and calculates the rmsd -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_confrms\fP .BI "\-f1" " conf1.gro " @@ -23,8 +23,8 @@ .BI "\-[no]label" "" .BI "\-[no]bfac" "" .SH DESCRIPTION -\&g_confrms computes the root mean square deviation (RMSD) of two -\&structures after LSQ fitting the second structure on the first one. +\&\fB g_confrms\fR computes the root mean square deviation (RMSD) of two +\&structures after least\-squares fitting the second structure on the first one. \&The two structures do NOT need to have the same number of atoms, \&only the two index groups used for the fit need to be identical. \&With \fB \-name\fR only matching atom names from the selected groups @@ -73,7 +73,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-[no]one" "no " Only write the fitted structure to file diff -Nru gromacs-4.5.4/man/man1/g_covar.1 gromacs-4.5.5/man/man1/g_covar.1 --- gromacs-4.5.4/man/man1/g_covar.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_covar.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_covar 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_covar 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_covar - calculates and diagonalizes the covariance matrix -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_covar\fP .BI "\-f" " traj.xtc " @@ -56,13 +56,22 @@ \& -\&Option \fB \-xpm\fR writes the whole covariance matrix to an xpm file. +\&Option \fB \-xpm\fR writes the whole covariance matrix to an \fB .xpm\fR file. \& -\&Option \fB \-xpma\fR writes the atomic covariance matrix to an xpm file, +\&Option \fB \-xpma\fR writes the atomic covariance matrix to an \fB .xpm\fR file, \&i.e. for each atom pair the sum of the xx, yy and zz covariances is \&written. +\& + + +\&Note that the diagonalization of a matrix requires memory and time +\&that will increase at least as fast as than the square of the number +\&of atoms involved. It is easy to run out of memory, in which +\&case this tool will probably exit with a 'Segmentation fault'. You +\&should consider carefully whether a reduced set of atoms will meet +\&your needs for lower costs. .SH FILES .BI "\-f" " traj.xtc" .B Input diff -Nru gromacs-4.5.4/man/man1/g_current.1 gromacs-4.5.5/man/man1/g_current.1 --- gromacs-4.5.4/man/man1/g_current.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_current.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_current 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_current 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_current - calculate current autocorrelation function of system -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_current\fP .BI "\-s" " topol.tpr " @@ -32,17 +32,17 @@ .BI "\-tr" " real " .BI "\-temp" " real " .SH DESCRIPTION -\&This is a tool for calculating the current autocorrelation function, the correlation +\&\fB g_current\fR is a tool for calculating the current autocorrelation function, the correlation \&of the rotational and translational dipole moment of the system, and the resulting static -\&dielectric constant. To obtain a reasonable result the index group has to be neutral. -\&Furthermore the routine is capable of extracting the static conductivity from the current -\&autocorrelation function, if velocities are given. Additionally an Einstein\-Helfand fit also -\&allows to get the static conductivity. +\&dielectric constant. To obtain a reasonable result, the index group has to be neutral. +\&Furthermore, the routine is capable of extracting the static conductivity from the current +\&autocorrelation function, if velocities are given. Additionally, an Einstein\-Helfand fit +\&can be used to obtain the static conductivity. \&The flag \fB \-caf\fR is for the output of the current autocorrelation function and \fB \-mc\fR writes the \&correlation of the rotational and translational part of the dipole moment in the corresponding -\&file. However this option is only available for trajectories containing velocities. +\&file. However, this option is only available for trajectories containing velocities. \&Options \fB \-sh\fR and \fB \-tr\fR are responsible for the averaging and integration of the \&autocorrelation functions. Since averaging proceeds by shifting the starting point \&through the trajectory, the shift can be modified with \fB \-sh\fR to enable the choice of uncorrelated @@ -64,10 +64,10 @@ \&\fB \-[no]nojump\fR unfolds the coordinates to allow free diffusion. This is required to get a continuous -\&translational dipole moment, required for the Einstein\-Helfand fit. The resuls from the fit allow to -\&determine the dielectric constant for system of charged molecules. However it is also possible to extract +\&translational dipole moment, required for the Einstein\-Helfand fit. The results from the fit allow +\&the determination of the dielectric constant for system of charged molecules. However, it is also possible to extract \&the dielectric constant from the fluctuations of the total dipole moment in folded coordinates. But this -\&options has to be used with care, since only very short time spans fulfill the approximation, that the density +\&option has to be used with care, since only very short time spans fulfill the approximation that the density \&of the molecules is approximately constant and the averages are already converged. To be on the safe side, \&the dielectric constant should be calculated with the help of the Einstein\-Helfand method for \&the translational part of the dielectric constant. @@ -128,7 +128,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -140,7 +140,7 @@ Removes jumps of atoms across the box. .BI "\-eps" " real" " 0 " - Dielectric constant of the surrounding medium. eps=0.0 corresponds to eps=infinity (thinfoil boundary conditions). + Dielectric constant of the surrounding medium. eps=0.0 corresponds to eps=infinity (tin\-foil boundary conditions). .BI "\-bfit" " real" " 100 " Begin of the fit of the straight line to the MSD of the translational fraction of the dipole moment. diff -Nru gromacs-4.5.4/man/man1/g_density.1 gromacs-4.5.5/man/man1/g_density.1 --- gromacs-4.5.4/man/man1/g_density.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_density.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_density 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_density 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_density - calculates the density of the system -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_density\fP .BI "\-f" " traj.xtc " @@ -25,17 +25,23 @@ .BI "\-[no]symm" "" .BI "\-[no]center" "" .SH DESCRIPTION -\&Compute partial densities across the box, using an index file. Densities -\&in kg/m3, number densities or electron densities can be +\&Compute partial densities across the box, using an index file. + + +\&For the total density of NPT simulations, use \fB g_energy\fR instead. +\& + + +\&Densities are in kg/m3, and number densities or electron densities can also be \&calculated. For electron densities, a file describing the number of \&electrons for each type of atom should be provided using \fB \-ei\fR. \&It should look like: -\& 2 +\& \fB 2\fR -\& atomname = nrelectrons +\& \fB atomname = nrelectrons\fR -\& atomname = nrelectrons +\& \fB atomname = nrelectrons\fR \&The first line contains the number of lines to read from the file. \&There should be one line for each unique atom name in your system. @@ -82,7 +88,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_densmap.1 gromacs-4.5.5/man/man1/g_densmap.1 --- gromacs-4.5.4/man/man1/g_densmap.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_densmap.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_densmap 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_densmap 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_densmap - calculates 2D planar or axial-radial density maps -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_densmap\fP .BI "\-f" " traj.xtc " @@ -31,11 +31,11 @@ .BI "\-dmin" " real " .BI "\-dmax" " real " .SH DESCRIPTION -\&g_densmap computes 2D number\-density maps. +\&\fB g_densmap\fR computes 2D number\-density maps. \&It can make planar and axial\-radial density maps. \&The output \fB .xpm\fR file can be visualized with for instance xv -\&and can be converted to postscript with xpm2ps. -\&Optionally, output can be in text form to a .dat file. +\&and can be converted to postscript with \fB xpm2ps\fR. +\&Optionally, output can be in text form to a \fB .dat\fR file with \fB \-od\fR, instead of the usual \fB .xpm\fR file with \fB \-o\fR. \& @@ -110,7 +110,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-bin" " real" " 0.02 " Grid size (nm) diff -Nru gromacs-4.5.4/man/man1/g_densorder.1 gromacs-4.5.5/man/man1/g_densorder.1 --- gromacs-4.5.4/man/man1/g_densorder.1 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_densorder.1 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,123 @@ +.TH g_densorder 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" +.SH NAME +g_densorder - calculate surface fluctuations + +.B VERSION 4.5.4-dev-20110404-bc5695c +.SH SYNOPSIS +\f3g_densorder\fP +.BI "\-s" " topol.tpr " +.BI "\-f" " traj.xtc " +.BI "\-n" " index.ndx " +.BI "\-o" " Density4D.dat " +.BI "\-or" " hello.out " +.BI "\-og" " interface.xpm " +.BI "\-Spect" " intfspect.out " +.BI "\-[no]h" "" +.BI "\-[no]version" "" +.BI "\-nice" " int " +.BI "\-b" " time " +.BI "\-e" " time " +.BI "\-dt" " time " +.BI "\-[no]w" "" +.BI "\-[no]1d" "" +.BI "\-bw" " real " +.BI "\-bwn" " real " +.BI "\-order" " int " +.BI "\-axis" " string " +.BI "\-method" " enum " +.BI "\-d1" " real " +.BI "\-d2" " real " +.BI "\-tblock" " int " +.BI "\-nlevel" " int " +.SH DESCRIPTION +\&A small program to reduce a two\-phase density distribution +\&along an axis, computed over a MD trajectory +\&to 2D surfaces fluctuating in time, by a fit to +\&a functional profile for interfacial densities +\&A time\-averaged spatial representation of the +\&interfaces can be output with the option \-tavg +.SH FILES +.BI "\-s" " topol.tpr" +.B Input + Run input file: tpr tpb tpa + +.BI "\-f" " traj.xtc" +.B Input + Trajectory: xtc trr trj gro g96 pdb cpt + +.BI "\-n" " index.ndx" +.B Input + Index file + +.BI "\-o" " Density4D.dat" +.B Output, Opt. + Generic data file + +.BI "\-or" " hello.out" +.B Output, Opt., Mult. + Generic output file + +.BI "\-og" " interface.xpm" +.B Output, Opt., Mult. + X PixMap compatible matrix file + +.BI "\-Spect" " intfspect.out" +.B Output, Opt., Mult. + Generic output file + +.SH OTHER OPTIONS +.BI "\-[no]h" "no " + Print help info and quit + +.BI "\-[no]version" "no " + Print version info and quit + +.BI "\-nice" " int" " 0" + Set the nicelevel + +.BI "\-b" " time" " 0 " + First frame (ps) to read from trajectory + +.BI "\-e" " time" " 0 " + Last frame (ps) to read from trajectory + +.BI "\-dt" " time" " 0 " + Only use frame when t MOD dt = first time (ps) + +.BI "\-[no]w" "no " + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files + +.BI "\-[no]1d" "no " + Pseudo\-1d interface geometry + +.BI "\-bw" " real" " 0.2 " + Binwidth of density distribution tangential to interface + +.BI "\-bwn" " real" " 0.05 " + Binwidth of density distribution normal to interface + +.BI "\-order" " int" " 0" + Order of Gaussian filter, order 0 equates to NO filtering + +.BI "\-axis" " string" " Z" + Axis Direction \- X, Y or Z + +.BI "\-method" " enum" " bisect" + Interface location method: \fB bisect\fR or \fB functional\fR + +.BI "\-d1" " real" " 0 " + Bulk density phase 1 (at small z) + +.BI "\-d2" " real" " 1000 " + Bulk density phase 2 (at large z) + +.BI "\-tblock" " int" " 100" + Number of frames in one time\-block average + +.BI "\-nlevel" " int" " 100" + Number of Height levels in 2D \- XPixMaps + +.SH SEE ALSO +.BR gromacs(7) + +More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. diff -Nru gromacs-4.5.4/man/man1/g_dielectric.1 gromacs-4.5.5/man/man1/g_dielectric.1 --- gromacs-4.5.4/man/man1/g_dielectric.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_dielectric.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_dielectric 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_dielectric 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_dielectric - calculates frequency dependent dielectric constants -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_dielectric\fP .BI "\-f" " dipcorr.xvg " @@ -32,19 +32,22 @@ .BI "\-ffn" " enum " .BI "\-nsmooth" " int " .SH DESCRIPTION -\&dielectric calculates frequency dependent dielectric constants +\&\fB g_dielectric\fR calculates frequency dependent dielectric constants \&from the autocorrelation function of the total dipole moment in -\&your simulation. This ACF can be generated by g_dipoles. +\&your simulation. This ACF can be generated by \fB g_dipoles\fR. \&For an estimate of the error you can run g_statistics on the \&ACF, and use the output thus generated for this program. \&The functional forms of the available functions are: -\&One parameter : y = Exp[\-a1 x], -\&Two parameters : y = a2 Exp[\-a1 x], +\&One parameter: y = Exp[\-a1 x], + +\&Two parameters: y = a2 Exp[\-a1 x], + \&Three parameters: y = a2 Exp[\-a1 x] + (1 \- a2) Exp[\-a3 x]. + \&Start values for the fit procedure can be given on the command line. -\&It is also possible to fix parameters at their start value, use \-fix +\&It is also possible to fix parameters at their start value, use \fB \-fix\fR \&with the number of the parameter you want to fix. \& @@ -95,7 +98,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -104,10 +107,10 @@ use fast fourier transform for correlation function .BI "\-[no]x1" "yes " - use first column as X axis rather than first data set + use first column as \fI x\fR\-axis rather than first data set .BI "\-eint" " real" " 5 " - Time were to end the integration of the data and start to use the fit + Time to end the integration of the data and start to use the fit .BI "\-bfit" " real" " 5 " Begin time of fit @@ -128,16 +131,16 @@ Start value for fit parameter tau2 .BI "\-eps0" " real" " 80 " - Epsilon 0 of your liquid + epsilon0 of your liquid .BI "\-epsRF" " real" " 78.5 " - Epsilon of the reaction field used in your simulation. A value of 0 means infinity. + epsilon of the reaction field used in your simulation. A value of 0 means infinity. .BI "\-fix" " int" " 0" Fix parameters at their start values, A (2), tau1 (1), or tau2 (4) .BI "\-ffn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-nsmooth" " int" " 3" Number of points for smoothing diff -Nru gromacs-4.5.4/man/man1/g_dih.1 gromacs-4.5.5/man/man1/g_dih.1 --- gromacs-4.5.4/man/man1/g_dih.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_dih.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_dih 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_dih 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_dih - analyzes dihedral transitions -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_dih\fP .BI "\-f" " traj.xtc " @@ -18,7 +18,7 @@ .BI "\-[no]sa" "" .BI "\-mult" " int " .SH DESCRIPTION -\&g_dih can do two things. The default is to analyze dihedral transitions +\&\fB g_dih\fR can do two things. The default is to analyze dihedral transitions \&by merely computing all the dihedral angles defined in your topology \&for the whole trajectory. When a dihedral flips over to another minimum \&an angle/time plot is made. @@ -61,7 +61,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-[no]sa" "no " Perform cluster analysis in dihedral space instead of analysing dihedral transitions. diff -Nru gromacs-4.5.4/man/man1/g_dipoles.1 gromacs-4.5.5/man/man1/g_dipoles.1 --- gromacs-4.5.4/man/man1/g_dipoles.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_dipoles.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_dipoles 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_dipoles 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_dipoles - computes the total dipole plus fluctuations -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_dipoles\fP .BI "\-en" " ener.edr " @@ -53,24 +53,24 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_dipoles computes the total dipole plus fluctuations of a simulation +\&\fB g_dipoles\fR computes the total dipole plus fluctuations of a simulation \&system. From this you can compute e.g. the dielectric constant for -\&low dielectric media. +\&low\-dielectric media. \&For molecules with a net charge, the net charge is subtracted at \¢er of mass of the molecule. -\&The file Mtot.xvg contains the total dipole moment of a frame, the +\&The file \fB Mtot.xvg\fR contains the total dipole moment of a frame, the \&components as well as the norm of the vector. -\&The file aver.xvg contains |Mu|2 and | Mu |2 during the +\&The file \fB aver.xvg\fR contains |Mu|2 and | Mu |2 during the \&simulation. -\&The file dipdist.xvg contains the distribution of dipole moments during +\&The file \fB dipdist.xvg\fR contains the distribution of dipole moments during \&the simulation -\&The mu_max is used as the highest value in the distribution graph. +\&The value of \fB \-mumax\fR is used as the highest value in the distribution graph. -\&Furthermore the dipole autocorrelation function will be computed when -\&option \-corr is used. The output file name is given with the \fB \-c\fR +\&Furthermore, the dipole autocorrelation function will be computed when +\&option \fB \-corr\fR is used. The output file name is given with the \fB \-c\fR \&option. \&The correlation functions can be averaged over all molecules \&(\fB mol\fR), plotted per molecule separately (\fB molsep\fR) @@ -81,7 +81,7 @@ \&Option \fB \-g\fR produces a plot of the distance dependent Kirkwood \&G\-factor, as well as the average cosine of the angle between the dipoles \&as a function of the distance. The plot also includes gOO and hOO -\&according to Nymand & Linse, JCP 112 (2000) pp 6386\-6395. In the same plot +\&according to Nymand & Linse, J. Chem. Phys. 112 (2000) pp 6386\-6395. In the same plot, \&we also include the energy per scale computed by taking the inner product of \&the dipoles divided by the distance to the third power. @@ -92,13 +92,13 @@ \&EXAMPLES -\&g_dipoles \-corr mol \-P1 \-o dip_sqr \-mu 2.273 \-mumax 5.0 \-nofft +\&\fB g_dipoles \-corr mol \-P1 \-o dip_sqr \-mu 2.273 \-mumax 5.0 \-nofft\fR \&This will calculate the autocorrelation function of the molecular \&dipoles using a first order Legendre polynomial of the angle of the \&dipole vector and itself a time t later. For this calculation 1001 -\&frames will be used. Further the dielectric constant will be calculated +\&frames will be used. Further, the dielectric constant will be calculated \&using an epsilonRF of infinity (default), temperature of 300 K (default) and \&an average dipole moment of the molecule of 2.273 (SPC). For the \&distribution function a maximum of 5.0 will be used. @@ -187,7 +187,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -214,7 +214,7 @@ Calculate |cos theta| between all pairs of molecules. May be slow .BI "\-ncos" " int" " 1" - Must be 1 or 2. Determines whether the cos is computed between all mole cules in one group, or between molecules in two different groups. This turns on the \-gkr flag. + Must be 1 or 2. Determines whether the cos is computed between all molecules in one group, or between molecules in two different groups. This turns on the \fB \-gkr\fR flag. .BI "\-axis" " string" " Z" Take the normal on the computational box in direction X, Y or Z. @@ -229,16 +229,16 @@ Same as previous option in case ncos = 2, i.e. dipole interaction between two groups of molecules .BI "\-rcmax" " real" " 0 " - Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterium based on the box length will be used. + Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterion based on the box length will be used. .BI "\-[no]phi" "no " - Plot the 'torsion angle' defined as the rotation of the two dipole vectors around the distance vector between the two molecules in the xpm file from the \-cmap option. By default the cosine of the angle between the dipoles is plotted. + Plot the 'torsion angle' defined as the rotation of the two dipole vectors around the distance vector between the two molecules in the \fB .xpm\fR file from the \fB \-cmap\fR option. By default the cosine of the angle between the dipoles is plotted. .BI "\-nlevels" " int" " 20" Number of colors in the cmap output .BI "\-ndegrees" " int" " 90" - Number of divisions on the y\-axis in the camp output (for 180 degrees) + Number of divisions on the \fI y\fR\-axis in the cmap output (for 180 degrees) .BI "\-acflen" " int" " \-1" Length of the ACF, default is half the number of frames @@ -250,7 +250,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_disre.1 gromacs-4.5.5/man/man1/g_disre.1 --- gromacs-4.5.4/man/man1/g_disre.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_disre.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_disre 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_disre 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_disre - analyzes distance restraints -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_disre\fP .BI "\-s" " topol.tpr " @@ -30,9 +30,9 @@ .BI "\-nlevels" " int " .BI "\-[no]third" "" .SH DESCRIPTION -\&g_disre computes violations of distance restraints. -\&If necessary all protons can be added to a protein molecule -\&using the protonate program. +\&\fB g_disre\fR computes violations of distance restraints. +\&If necessary, all protons can be added to a protein molecule +\&using the \fB g_protonate\fR program. \&The program always @@ -46,7 +46,7 @@ \&printing. -\&When the optional\fB \-q\fR flag is given a pdb file coloured by the +\&When the optional \fB \-q\fR flag is given a \fB .pdb\fR file coloured by the \&amount of average violations. @@ -124,7 +124,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_dist.1 gromacs-4.5.5/man/man1/g_dist.1 --- gromacs-4.5.4/man/man1/g_dist.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_dist.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_dist 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_dist 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_dist - calculates the distances between the centers of mass of two groups -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_dist\fP .BI "\-f" " traj.xtc " @@ -19,9 +19,9 @@ .BI "\-xvg" " enum " .BI "\-dist" " real " .SH DESCRIPTION -\&g_dist can calculate the distance between the centers of mass of two +\&\fB g_dist\fR can calculate the distance between the centers of mass of two \&groups of atoms as a function of time. The total distance and its -\&x, y and z components are plotted. +\&\fI x\fR\-, \fI y\fR\-, and \fI z\fR\-components are plotted. \&Or when \fB \-dist\fR is set, print all the atoms in group 2 that are diff -Nru gromacs-4.5.4/man/man1/g_dyndom.1 gromacs-4.5.5/man/man1/g_dyndom.1 --- gromacs-4.5.4/man/man1/g_dyndom.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_dyndom.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_dyndom 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_dyndom 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_dyndom - interpolate and extrapolate structure rotations -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_dyndom\fP .BI "\-f" " dyndom.pdb " @@ -19,11 +19,11 @@ .BI "\-head" " vector " .BI "\-tail" " vector " .SH DESCRIPTION -\&g_dyndom reads a pdb file output from DynDom -\&http://www.cmp.uea.ac.uk/dyndom/ -\&It reads the coordinates, and the coordinates of the rotation axis -\&furthermore it reads an index file containing the domains. -\&Furthermore it takes the first and last atom of the arrow file +\&\fB g_dyndom\fR reads a \fB .pdb\fR file output from DynDom +\&(http://www.cmp.uea.ac.uk/dyndom/). +\&It reads the coordinates, the coordinates of the rotation axis, +\&and an index file containing the domains. +\&Furthermore, it takes the first and last atom of the arrow file \&as command line arguments (head and tail) and \&finally it takes the translation vector (given in DynDom info file) \&and the angle of rotation (also as command line arguments). If the angle @@ -75,7 +75,7 @@ DymDom dtermined angle of rotation about rotation vector .BI "\-trans" " real" " 0 " - Translation (Aangstroem) along rotation vector (see DynDom info file) + Translation (Angstrom) along rotation vector (see DynDom info file) .BI "\-head" " vector" " 0 0 0" First atom of the arrow vector diff -Nru gromacs-4.5.4/man/man1/genbox.1 gromacs-4.5.5/man/man1/genbox.1 --- gromacs-4.5.4/man/man1/genbox.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/genbox.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH genbox 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH genbox 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME genbox - solvates a system -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3genbox\fP .BI "\-cp" " protein.gro " @@ -22,14 +22,14 @@ .BI "\-maxsol" " int " .BI "\-[no]vel" "" .SH DESCRIPTION -\&Genbox can do one of 3 things: +\&\fB genbox\fR can do one of 3 things: -\&1) Generate a box of solvent. Specify \-cs and \-box. Or specify \-cs and -\&\-cp with a structure file with a box, but without atoms. +\&1) Generate a box of solvent. Specify \fB \-cs\fR and \fB \-box\fR. Or specify \fB \-cs\fR and +\&\fB \-cp\fR with a structure file with a box, but without atoms. -\&2) Solvate a solute configuration, eg. a protein, in a bath of solvent +\&2) Solvate a solute configuration, e.g. a protein, in a bath of solvent \&molecules. Specify \fB \-cp\fR (solute) and \fB \-cs\fR (solvent). \&The box specified in the solute coordinate file (\fB \-cp\fR) is used, \&unless \fB \-box\fR is set. @@ -38,9 +38,9 @@ \&to change the box dimensions and center the solute. \&Solvent molecules are removed from the box where the \&distance between any atom of the solute molecule(s) and any atom of -\&the solvent molecule is less than the sum of the VanderWaals radii of -\&both atoms. A database (\fB vdwradii.dat\fR) of VanderWaals radii is -\&read by the program, atoms not in the database are +\&the solvent molecule is less than the sum of the van der Waals radii of +\&both atoms. A database (\fB vdwradii.dat\fR) of van der Waals radii is +\&read by the program, and atoms not in the database are \&assigned a default distance \fB \-vdwd\fR. \&Note that this option will also influence the distances between \&solvent molecules if they contain atoms that are not in the database. @@ -51,11 +51,16 @@ \&at random positions. \&The program iterates until \fB nmol\fR molecules \&have been inserted in the box. To test whether an insertion is -\&successful the same VanderWaals criterium is used as for removal of -\&solvent molecules. When no appropriately -\&sized holes (holes that can hold an extra molecule) are available the +\&successful the same van der Waals criterium is used as for removal of +\&solvent molecules. When no appropriately\-sized +\&holes (holes that can hold an extra molecule) are available, the \&program tries for \fB \-nmol\fR * \fB \-try\fR times before giving up. -\&Increase \-try if you have several small holes to fill. +\&Increase \fB \-try\fR if you have several small holes to fill. + + +\&If you need to do more than one of the above operations, it can be +\&best to call \fB genbox\fR separately for each operation, so that +\&you are sure of the order in which the operations occur. \&The default solvent is Simple Point Charge water (SPC), with coordinates @@ -81,18 +86,18 @@ \&longest molecule axis along a box edge. This way the amount of solvent \&molecules necessary is reduced. \&It should be kept in mind that this only works for -\&short simulations, as eg. an alpha\-helical peptide in solution can +\&short simulations, as e.g. an alpha\-helical peptide in solution can \&rotate over 90 degrees, within 500 ps. In general it is therefore \&better to make a more or less cubic box. -\&Setting \-shell larger than zero will place a layer of water of +\&Setting \fB \-shell\fR larger than zero will place a layer of water of \&the specified thickness (nm) around the solute. Hint: it is a good -\&idea to put the protein in the center of a box first (using editconf). +\&idea to put the protein in the center of a box first (using \fB editconf\fR). \& -\&Finally, genbox will optionally remove lines from your topology file in +\&Finally, \fB genbox\fR will optionally remove lines from your topology file in \&which a number of solvent molecules is already added, and adds a \&line with the total number of solvent molecules in your coordinate file. .SH FILES @@ -133,7 +138,7 @@ no of extra molecules to insert .BI "\-try" " int" " 10" - try inserting \-nmol*\-try times + try inserting \fB \-nmol\fR times \fB \-try\fR times .BI "\-seed" " int" " 1997" random generator seed diff -Nru gromacs-4.5.4/man/man1/genconf.1 gromacs-4.5.5/man/man1/genconf.1 --- gromacs-4.5.4/man/man1/genconf.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/genconf.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH genconf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH genconf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME genconf - multiplies a conformation in 'random' orientations -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3genconf\fP .BI "\-f" " conf.gro " @@ -22,9 +22,9 @@ .BI "\-maxrot" " vector " .BI "\-[no]renumber" "" .SH DESCRIPTION -\&genconf multiplies a given coordinate file by simply stacking them +\&\fB genconf\fR multiplies a given coordinate file by simply stacking them \&on top of each other, like a small child playing with wooden blocks. -\&The program makes a grid of \fI user defined\fR +\&The program makes a grid of \fI user\-defined\fR \&proportions (\fB \-nbox\fR), \&and interspaces the grid point with an extra space \fB \-dist\fR. @@ -32,7 +32,7 @@ \&When option \fB \-rot\fR is used the program does not check for overlap \&between molecules on grid points. It is recommended to make the box in \&the input file at least as big as the coordinates + -\&Van der Waals radius. +\&van der Waals radius. \&If the optional trajectory file is given, conformations are not diff -Nru gromacs-4.5.4/man/man1/g_enemat.1 gromacs-4.5.5/man/man1/g_enemat.1 --- gromacs-4.5.4/man/man1/g_enemat.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_enemat.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_enemat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_enemat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_enemat - extracts an energy matrix from an energy file -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_enemat\fP .BI "\-f" " ener.edr " @@ -35,12 +35,12 @@ .BI "\-[no]free" "" .BI "\-temp" " real " .SH DESCRIPTION -\&g_enemat extracts an energy matrix from the energy file (\fB \-f\fR). +\&\fB g_enemat\fR extracts an energy matrix from the energy file (\fB \-f\fR). \&With \fB \-groups\fR a file must be supplied with on each \&line a group of atoms to be used. For these groups matrix of \&interaction energies will be extracted from the energy file \&by looking for energy groups with names corresponding to pairs -\&of groups of atoms. E.g. if your \fB \-groups\fR file contains: +\&of groups of atoms, e.g. if your \fB \-groups\fR file contains: \&\fB 2\fR @@ -110,7 +110,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -122,7 +122,7 @@ Skip number of frames between data points .BI "\-[no]mean" "yes " - with \-groups extracts matrix of mean energies instead of matrix for each timestep + with \fB \-groups\fR extracts matrix of mean energies instead of matrix for each timestep .BI "\-nlevels" " int" " 20" number of levels for matrix colors diff -Nru gromacs-4.5.4/man/man1/g_energy.1 gromacs-4.5.5/man/man1/g_energy.1 --- gromacs-4.5.4/man/man1/g_energy.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_energy.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_energy 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_energy 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_energy - writes energies to xvg files and displays averages -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_energy\fP .BI "\-f" " ener.edr " @@ -20,6 +20,7 @@ .BI "\-corr" " enecorr.xvg " .BI "\-vis" " visco.xvg " .BI "\-ravg" " runavgdf.xvg " +.BI "\-odh" " dhdl.xvg " .BI "\-[no]h" "" .BI "\-[no]version" "" .BI "\-nice" " int " @@ -38,7 +39,6 @@ .BI "\-skip" " int " .BI "\-[no]aver" "" .BI "\-nmol" " int " -.BI "\-nconstr" " int " .BI "\-[no]fluc" "" .BI "\-[no]orinst" "" .BI "\-[no]ovec" "" @@ -50,56 +50,28 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_energy extracts energy components or distance restraint +\&\fB g_energy\fR extracts energy components or distance restraint \&data from an energy file. The user is prompted to interactively -\&select the energy terms she wants. +\&select the desired energy terms. -\&Average, RMSD and drift are calculated with full precision from the +\&Average, RMSD, and drift are calculated with full precision from the \&simulation (see printed manual). Drift is calculated by performing -\&a LSQ fit of the data to a straight line. The reported total drift +\&a least\-squares fit of the data to a straight line. The reported total drift \&is the difference of the fit at the first and last point. \&An error estimate of the average is given based on a block averages -\&over 5 blocks using the full precision averages. The error estimate +\&over 5 blocks using the full\-precision averages. The error estimate \&can be performed over multiple block lengths with the options \&\fB \-nbmin\fR and \fB \-nbmax\fR. -\&Note that in most cases the energy files contains averages over all +\&\fB Note\fR that in most cases the energy files contains averages over all \&MD steps, or over many more points than the number of frames in -\&energy file. This makes the g_energy statistics output more accurate -\&than the xvg output. When exact averages are not present in the energy -\&file the statistics mentioned above is simply over the single, per\-frame +\&energy file. This makes the \fB g_energy\fR statistics output more accurate +\&than the \fB .xvg\fR output. When exact averages are not present in the energy +\&file, the statistics mentioned above are simply over the single, per\-frame \&energy values. -\&The term fluctuation gives the RMSD around the LSQ fit. - - -\&Some fluctuation\-dependent properties can be calculated provided -\&the correct energy terms are selected. The following properties -\&will be computed: - -\&Property Energy terms needed - -\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- - -\&Heat capacity Cp (NPT sims): Enthalpy, Temp - -\&Heat capacity Cv (NVT sims): Etot, Temp - -\&Thermal expansion coeff. (NPT): Enthalpy, Vol, Temp - -\&Isothermal compressibility: Vol, Temp - -\&Adiabatic bulk modulus: Vol, Temp - -\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- - -\&You always need to set the number of molecules \fB \-nmol\fR, and, -\&if you used constraints in your simulations you will need to give -\&the number of constraints per molecule \fB \-nconstr\fR in order to -\&correct for this: (nconstr/2) kB is subtracted from the heat -\&capacity in this case. For instance in the case of rigid water -\&you need to give the value 3 to this option. +\&The term fluctuation gives the RMSD around the least\-squares fit. \&When the \fB \-viol\fR option is set, the time averaged @@ -129,6 +101,11 @@ \&\fB \-ovec\fR also the eigenvectors are plotted. +\&Option \fB \-odh\fR extracts and plots the free energy data +\&(Hamiltoian differences and/or the Hamiltonian derivative dhdl) +\&from the \fB ener.edr\fR file. + + \&With \fB \-fee\fR an estimate is calculated for the free\-energy \&difference with an ideal gas state: @@ -152,8 +129,9 @@ \&When a second energy file is specified (\fB \-f2\fR), a free energy \&difference is calculated dF = \-kT ln e \-(EB\-EA)/kT A , \&where EA and EB are the energies from the first and second energy -\&files, and the average is over the ensemble A. \fB NOTE\fR that -\&the energies must both be calculated from the same trajectory. +\&files, and the average is over the ensemble A. The running average +\&of the free energy difference is printed to a file specified by \fB \-ravg\fR. +\&\fB Note\fR that the energies must both be calculated from the same trajectory. .SH FILES .BI "\-f" " ener.edr" .B Input @@ -215,6 +193,10 @@ .B Output, Opt. xvgr/xmgr file +.BI "\-odh" " dhdl.xvg" +.B Output, Opt. + xvgr/xmgr file + .SH OTHER OPTIONS .BI "\-[no]h" "no " Print help info and quit @@ -232,7 +214,7 @@ Last frame (ps) to read from trajectory .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -270,9 +252,6 @@ .BI "\-nmol" " int" " 1" Number of molecules in your sample: the energies are divided by this number -.BI "\-nconstr" " int" " 0" - Number of constraints per molecule. Necessary for calculating the heat capacity - .BI "\-[no]fluc" "no " Calculate autocorrelation of energy fluctuations rather than energy itself @@ -280,7 +259,7 @@ Analyse instantaneous orientation data .BI "\-[no]ovec" "no " - Also plot the eigenvectors with \-oten + Also plot the eigenvectors with \fB \-oten\fR .BI "\-acflen" " int" " \-1" Length of the ACF, default is half the number of frames @@ -292,7 +271,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/genion.1 gromacs-4.5.5/man/man1/genion.1 --- gromacs-4.5.4/man/man1/genion.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/genion.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH genion 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH genion 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME genion - generates mono atomic ions on energetically favorable positions -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3genion\fP .BI "\-s" " topol.tpr " @@ -29,10 +29,10 @@ .BI "\-conc" " real " .BI "\-[no]neutral" "" .SH DESCRIPTION -\&genion replaces solvent molecules by monoatomic ions at +\&\fB genion\fR replaces solvent molecules by monoatomic ions at \&the position of the first atoms with the most favorable electrostatic \&potential or at random. The potential is calculated on all atoms, using -\&normal GROMACS particle based methods (in contrast to other methods +\&normal GROMACS particle\-based methods (in contrast to other methods \&based on solving the Poisson\-Boltzmann equation). \&The potential is recalculated after every ion insertion. \&If specified in the run input file, a reaction field, shift function @@ -45,18 +45,23 @@ \&The ion molecule type, residue and atom names in all force fields -\&are the capitalized element names without sign. Ions which can have -\&multiple charge states get the multiplicilty added, without sign, -\&for the uncommon states only. +\&are the capitalized element names without sign. This molecule name +\&should be given with \fB \-pname\fR or \fB \-nname\fR, and the +\&\fB [molecules]\fR section of your topology updated accordingly, +\&either by hand or with \fB \-p\fR. Do not use an atom name instead! +\& + +Ions which can have multiple charge states get the multiplicity +\&added, without sign, for the uncommon states only. \&With the option \fB \-pot\fR the potential can be written as B\-factors -\&in a pdb file (for visualisation using e.g. rasmol). +\&in a \fB .pdb\fR file (for visualisation using e.g. Rasmol). \&The unit of the potential is 1000 kJ/(mol e), the scaling be changed \&with the \fB \-scale\fR option. -\&For larger ions, e.g. sulfate we recommended to use genbox. +\&For larger ions, e.g. sulfate we recommended using \fB genbox\fR. .SH FILES .BI "\-s" " topol.tpr" .B Input @@ -127,10 +132,10 @@ Seed for random number generator .BI "\-scale" " real" " 0.001 " - Scaling factor for the potential for \-pot + Scaling factor for the potential for \fB \-pot\fR .BI "\-conc" " real" " 0 " - Specify salt concentration (mol/liter). This will add sufficient ions to reach up to the specified concentration as computed from the volume of the cell in the input tpr file. Overrides the \-np and nn options. + Specify salt concentration (mol/liter). This will add sufficient ions to reach up to the specified concentration as computed from the volume of the cell in the input \fB .tpr\fR file. Overrides the \fB \-np\fR and \fB \-nn\fR options. .BI "\-[no]neutral" "no " This option will add enough ions to neutralize the system. In combination with the concentration option a neutral system at a given salt concentration will be generated. diff -Nru gromacs-4.5.4/man/man1/genrestr.1 gromacs-4.5.5/man/man1/genrestr.1 --- gromacs-4.5.4/man/man1/genrestr.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/genrestr.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH genrestr 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH genrestr 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME genrestr - generates position restraints or distance restraints for index groups -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3genrestr\fP .BI "\-f" " conf.gro " @@ -21,9 +21,9 @@ .BI "\-cutoff" " real " .BI "\-[no]constr" "" .SH DESCRIPTION -\&genrestr produces an include file for a topology containing +\&\fB genrestr\fR produces an include file for a topology containing \&a list of atom numbers and three force constants for the -\&X, Y and Z direction. A single isotropic force constant may +\&\fI x\fR\-, \fI y\fR\-, and \fI z\fR\-direction. A single isotropic force constant may \&be given on the command line instead of three components. @@ -32,17 +32,17 @@ \&they should be included within the correct \fB [ moleculetype ]\fR \&block in the topology. Since the atom numbers in every moleculetype \&in the topology start at 1 and the numbers in the input file for -\&genpr number consecutively from 1, genpr will only produce a useful -\&file for the first molecule. +\&\fB genrestr\fR number consecutively from 1, \fB genrestr\fR will only +\&produce a useful file for the first molecule. -\&The \-of option produces an index file that can be used for -\&freezing atoms. In this case the input file must be a pdb file. +\&The \fB \-of\fR option produces an index file that can be used for +\&freezing atoms. In this case, the input file must be a \fB .pdb\fR file. -\&With the \fB \-disre\fR option half a matrix of distance restraints +\&With the \fB \-disre\fR option, half a matrix of distance restraints \&is generated instead of position restraints. With this matrix, that -\&one typically would apply to C\-alpha atoms in a protein, one can +\&one typically would apply to Calpha atoms in a protein, one can \&maintain the overall conformation of a protein without tieing it to \&a specific position (as with position restraints). .SH FILES @@ -73,10 +73,10 @@ Set the nicelevel .BI "\-fc" " vector" " 1000 1000 1000" - force constants (kJ mol\-1 nm\-2) + force constants (kJ/mol nm2) .BI "\-freeze" " real" " 0 " - if the \-of option or this one is given an index file will be written containing atom numbers of all atoms that have a B\-factor less than the level given here + if the \fB \-of\fR option or this one is given an index file will be written containing atom numbers of all atoms that have a B\-factor less than the level given here .BI "\-[no]disre" "no " Generate a distance restraint matrix for all the atoms in index diff -Nru gromacs-4.5.4/man/man1/g_filter.1 gromacs-4.5.5/man/man1/g_filter.1 --- gromacs-4.5.4/man/man1/g_filter.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_filter.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_filter 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_filter 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_filter - frequency filters trajectories, useful for making smooth movies -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_filter\fP .BI "\-f" " traj.xtc " @@ -22,7 +22,7 @@ .BI "\-[no]nojump" "" .BI "\-[no]fit" "" .SH DESCRIPTION -\&g_filter performs frequency filtering on a trajectory. +\&\fB g_filter\fR performs frequency filtering on a trajectory. \&The filter shape is cos(pi t/A) + 1 from \-A to +A, where A is given \&by the option \fB \-nf\fR times the time step in the input trajectory. \&This filter reduces fluctuations with period A by 85%, with period @@ -31,7 +31,7 @@ \&Option \fB \-ol\fR writes a low\-pass filtered trajectory. -\&A frame is written every \fB nf\fR input frames. +\&A frame is written every \fB \-nf\fR input frames. \&This ratio of filter length and output interval ensures a good \&suppression of aliasing of high\-frequency motion, which is useful for \&making smooth movies. Also averages of properties which are linear @@ -43,7 +43,7 @@ \&Option \fB \-oh\fR writes a high\-pass filtered trajectory. \&The high\-pass filtered coordinates are added to the coordinates \&from the structure file. When using high\-pass filtering use \fB \-fit\fR -\&or make sure you use a trajectory which has been fitted on +\&or make sure you use a trajectory that has been fitted on \&the coordinates in the structure file. .SH FILES .BI "\-f" " traj.xtc" @@ -86,7 +86,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-nf" " int" " 10" Sets the filter length as well as the output interval for low\-pass filtering diff -Nru gromacs-4.5.4/man/man1/g_gyrate.1 gromacs-4.5.5/man/man1/g_gyrate.1 --- gromacs-4.5.4/man/man1/g_gyrate.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_gyrate.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_gyrate 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_gyrate 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_gyrate - calculates the radius of gyration -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_gyrate\fP .BI "\-f" " traj.xtc " @@ -31,8 +31,8 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_gyrate computes the radius of gyration of a group of atoms -\&and the radii of gyration about the x, y and z axes, +\&\fB g_gyrate\fR computes the radius of gyration of a group of atoms +\&and the radii of gyration about the \fI x\fR\-, \fI y\fR\- and \fI z\fR\-axes, \&as a function of time. The atoms are explicitly mass weighted. @@ -41,8 +41,8 @@ \&sized parts. -\&With the option \fB \-nz\fR 2D radii of gyration in the x\-y plane -\&of slices along the z\-axis are calculated. +\&With the option \fB \-nz\fR 2D radii of gyration in the \fI x\-y\fR plane +\&of slices along the \fI z\fR\-axis are calculated. .SH FILES .BI "\-f" " traj.xtc" .B Input @@ -84,7 +84,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -114,7 +114,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_h2order.1 gromacs-4.5.5/man/man1/g_h2order.1 --- gromacs-4.5.4/man/man1/g_h2order.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_h2order.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_h2order 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_h2order 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_h2order - computes the orientation of water molecules -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_h2order\fP .BI "\-f" " traj.xtc " @@ -21,12 +21,12 @@ .BI "\-d" " string " .BI "\-sl" " int " .SH DESCRIPTION -\&Compute the orientation of water molecules with respect to the normal +\&\fB g_h2order\fR computes the orientation of water molecules with respect to the normal \&of the box. The program determines the average cosine of the angle -\&between de dipole moment of water and an axis of the box. The box is +\&between the dipole moment of water and an axis of the box. The box is \÷d in slices and the average orientation per slice is printed. \&Each water molecule is assigned to a slice, per time frame, based on the -\&position of the oxygen. When \-nm is used the angle between the water +\&position of the oxygen. When \fB \-nm\fR is used, the angle between the water \&dipole and the axis from the center of mass to the oxygen is calculated \&instead of the angle between the dipole and a box axis. .SH FILES @@ -70,7 +70,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -82,7 +82,7 @@ Calculate order parameter as function of boxlength, dividing the box in nr slices. .SH KNOWN PROBLEMS -\- The program assigns whole water molecules to a slice, based on the firstatom of three in the index file group. It assumes an order O,H,H.Name is not important, but the order is. If this demand is not met,assigning molecules to slices is different. +\- The program assigns whole water molecules to a slice, based on the first atom of three in the index file group. It assumes an order O,H,H. Name is not important, but the order is. If this demand is not met, assigning molecules to slices is different. .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_hbond.1 gromacs-4.5.5/man/man1/g_hbond.1 --- gromacs-4.5.4/man/man1/g_hbond.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_hbond.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_hbond 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_hbond 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_hbond - computes and analyzes hydrogen bonds -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_hbond\fP .BI "\-f" " traj.xtc " @@ -26,6 +26,7 @@ .BI "\-b" " time " .BI "\-e" " time " .BI "\-dt" " time " +.BI "\-tu" " enum " .BI "\-xvg" " enum " .BI "\-a" " real " .BI "\-r" " real " @@ -53,7 +54,7 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_hbond computes and analyzes hydrogen bonds. Hydrogen bonds are +\&\fB g_hbond\fR computes and analyzes hydrogen bonds. Hydrogen bonds are \&determined based on cutoffs for the angle Acceptor \- Donor \- Hydrogen \&(zero is extended) and the distance Hydrogen \- Acceptor. \&OH and NH groups are regarded as donors, O is an acceptor always, @@ -67,7 +68,7 @@ \&groups are analyzed. -\&If you set \-shell, you will be asked for an additional index group +\&If you set \fB \-shell\fR, you will be asked for an additional index group \&which should contain exactly one atom. In this case, only hydrogen \&bonds between atoms within the shell distance from the one atom are \&considered. @@ -205,6 +206,9 @@ .BI "\-dt" " time" " 0 " Only use frame when t MOD dt = first time (ps) +.BI "\-tu" " enum" " ps" + Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR + .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -218,7 +222,7 @@ Use distance Donor\-Acceptor (if TRUE) or Hydrogen\-Acceptor (FALSE) .BI "\-r2" " real" " 0 " - Second cutoff radius. Mainly useful with \-contact and \-ac + Second cutoff radius. Mainly useful with \fB \-contact\fR and \fB \-ac\fR .BI "\-abin" " real" " 1 " Binwidth angle distribution (degrees) @@ -236,10 +240,10 @@ when 0, only calculate hydrogen bonds within nm shell around one particle .BI "\-fitstart" " real" " 1 " - Time (ps) from which to start fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. With \-gemfit we suggest \-fitstart 0 + Time (ps) from which to start fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. With \fB \-gemfit\fR we suggest \fB \-fitstart 0\fR .BI "\-fitstart" " real" " 1 " - Time (ps) to which to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation (only with \-gemfit) + Time (ps) to which to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation (only with \fB \-gemfit\fR) .BI "\-temp" " real" " 298.15" Temperature (K) for computing the Gibbs energy corresponding to HB breaking and reforming @@ -248,7 +252,7 @@ If = 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(\-x/tau) .BI "\-dump" " int" " 0" - Dump the first N hydrogen bond ACFs in a single xvg file for debugging + Dump the first N hydrogen bond ACFs in a single \fB .xvg\fR file for debugging .BI "\-max_hb" " real" " 0 " Theoretical maximum number of hydrogen bonds used for normalizing HB autocorrelation function. Can be useful in case the program estimates it wrongly @@ -260,7 +264,7 @@ Use reversible geminate recombination for the kinetics/thermodynamics calclations. See Markovitch et al., J. Chem. Phys 129, 084505 (2008) for details.: \fB none\fR, \fB dd\fR, \fB ad\fR, \fB aa\fR or \fB a4\fR .BI "\-diff" " real" " \-1 " - Dffusion coefficient to use in the rev. gem. recomb. kinetic model. If non\-positive, then it will be fitted to the ACF along with ka and kd. + Dffusion coefficient to use in the reversible geminate recombination kinetic model. If negative, then it will be fitted to the ACF along with ka and kd. .BI "\-acflen" " int" " \-1" Length of the ACF, default is half the number of frames @@ -272,7 +276,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_helix.1 gromacs-4.5.5/man/man1/g_helix.1 --- gromacs-4.5.4/man/man1/g_helix.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_helix.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_helix 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_helix 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_helix - calculates basic properties of alpha helices -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_helix\fP .BI "\-s" " topol.tpr " @@ -27,46 +27,46 @@ .BI "\-ahxstart" " int " .BI "\-ahxend" " int " .SH DESCRIPTION -\&g_helix computes all kind of helix properties. First, the peptide -\&is checked to find the longest helical part. This is determined by -\&Hydrogen bonds and Phi/Psi angles. +\&\fB g_helix\fR computes all kinds of helix properties. First, the peptide +\&is checked to find the longest helical part, as determined by +\&hydrogen bonds and phi/psi angles. \&That bit is fitted -\&to an ideal helix around the Z\-axis and centered around the origin. +\&to an ideal helix around the \fI z\fR\-axis and centered around the origin. \&Then the following properties are computed: -\&\fB 1.\fR Helix radius (file radius.xvg). This is merely the +\&\fB 1.\fR Helix radius (file \fB radius.xvg\fR). This is merely the \&RMS deviation in two dimensions for all Calpha atoms. \&it is calced as sqrt((SUM i(x2(i)+y2(i)))/N), where N is the number \&of backbone atoms. For an ideal helix the radius is 0.23 nm -\&\fB 2.\fR Twist (file twist.xvg). The average helical angle per -\&residue is calculated. For alpha helix it is 100 degrees, -\&for 3\-10 helices it will be smaller, +\&\fB 2.\fR Twist (file \fB twist.xvg\fR). The average helical angle per +\&residue is calculated. For an alpha\-helix it is 100 degrees, +\&for 3\-10 helices it will be smaller, and \&for 5\-helices it will be larger. -\&\fB 3.\fR Rise per residue (file rise.xvg). The helical rise per -\&residue is plotted as the difference in Z\-coordinate between Ca -\&atoms. For an ideal helix this is 0.15 nm +\&\fB 3.\fR Rise per residue (file \fB rise.xvg\fR). The helical rise per +\&residue is plotted as the difference in \fI z\fR\-coordinate between Calpha +\&atoms. For an ideal helix, this is 0.15 nm -\&\fB 4.\fR Total helix length (file len\-ahx.xvg). The total length +\&\fB 4.\fR Total helix length (file \fB len\-ahx.xvg\fR). The total length \&of the \&helix in nm. This is simply the average rise (see above) times the \&number of helical residues (see below). -\&\fB 5.\fR Number of helical residues (file n\-ahx.xvg). The title says +\&\fB 5.\fR Number of helical residues (file \fB n\-ahx.xvg\fR). The title says \&it all. -\&\fB 6.\fR Helix Dipole, backbone only (file dip\-ahx.xvg). +\&\fB 6.\fR Helix dipole, backbone only (file \fB dip\-ahx.xvg\fR). \&\fB 7.\fR RMS deviation from ideal helix, calculated for the Calpha -\&atoms only (file rms\-ahx.xvg). +\&atoms only (file \fB rms\-ahx.xvg\fR). -\&\fB 8.\fR Average Calpha\-Calpha dihedral angle (file phi\-ahx.xvg). +\&\fB 8.\fR Average Calpha \- Calpha dihedral angle (file \fB phi\-ahx.xvg\fR). -\&\fB 9.\fR Average Phi and Psi angles (file phipsi.xvg). +\&\fB 9.\fR Average phi and psi angles (file \fB phipsi.xvg\fR). -\&\fB 10.\fR Ellipticity at 222 nm according to \fI Hirst and Brooks\fR +\&\fB 10.\fR Ellipticity at 222 nm according to Hirst and Brooks. \& @@ -115,7 +115,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-r0" " int" " 1" The first residue number in the sequence diff -Nru gromacs-4.5.4/man/man1/g_helixorient.1 gromacs-4.5.5/man/man1/g_helixorient.1 --- gromacs-4.5.4/man/man1/g_helixorient.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_helixorient.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_helixorient 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_helixorient 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_helixorient - calculates local pitch/bending/rotation/orientation inside helices -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_helixorient\fP .BI "\-s" " topol.tpr " @@ -26,18 +26,18 @@ .BI "\-[no]sidechain" "" .BI "\-[no]incremental" "" .SH DESCRIPTION -\&g_helixorient calculates the coordinates and direction of the average +\&\fB g_helixorient\fR calculates the coordinates and direction of the average \&axis inside an alpha helix, and the direction/vectors of both the -\&alpha carbon and (optionally) a sidechain atom relative to the axis. +\&Calpha and (optionally) a sidechain atom relative to the axis. -\&As input, you need to specify an index group with alpha carbon atoms -\&corresponding to an alpha helix of continuous residues. Sidechain +\&As input, you need to specify an index group with Calpha atoms +\&corresponding to an alpha\-helix of continuous residues. Sidechain \&directions require a second index group of the same size, containing \&the heavy atom in each residue that should represent the sidechain. -\&Note that this program does not do any fitting of structures. +\&\fB Note\fR that this program does not do any fitting of structures. \&We need four Calpha coordinates to define the local direction of the helix @@ -45,11 +45,11 @@ \&The tilt/rotation is calculated from Euler rotations, where we define -\&the helix axis as the local X axis, the residues/CA\-vector as Y, and the -\&Z axis from their cross product. We use the Euler Y\-Z\-X rotation, meaning +\&the helix axis as the local \fI x\fR\-axis, the residues/Calpha vector as \fI y\fR, and the +\&\fI z\fR\-axis from their cross product. We use the Euler Y\-Z\-X rotation, meaning \&we first tilt the helix axis (1) around and (2) orthogonal to the residues \&vector, and finally apply the (3) rotation around it. For debugging or other -\&purposes, we also write out the actual Euler rotation angles as theta1\-3.xvg +\&purposes, we also write out the actual Euler rotation angles as \fB theta[1\-3].xvg\fR .SH FILES .BI "\-s" " topol.tpr" .B Input diff -Nru gromacs-4.5.4/man/man1/g_hydorder.1 gromacs-4.5.5/man/man1/g_hydorder.1 --- gromacs-4.5.4/man/man1/g_hydorder.1 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_hydorder.1 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,103 @@ +.TH g_hydorder 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" +.SH NAME +g_hydorder +.B VERSION 4.5.4-dev-20110404-bc5695c +.SH SYNOPSIS +\f3g_hydorder\fP +.BI "\-f" " traj.xtc " +.BI "\-n" " index.ndx " +.BI "\-s" " topol.tpr " +.BI "\-o" " intf.xpm " +.BI "\-or" " raw.out " +.BI "\-Spect" " intfspect.out " +.BI "\-[no]h" "" +.BI "\-[no]version" "" +.BI "\-nice" " int " +.BI "\-b" " time " +.BI "\-e" " time " +.BI "\-dt" " time " +.BI "\-[no]w" "" +.BI "\-d" " enum " +.BI "\-bw" " real " +.BI "\-sgang1" " real " +.BI "\-sgang2" " real " +.BI "\-tblock" " int " +.BI "\-nlevel" " int " +.SH DESCRIPTION +\&The tetrahedrality order parameters can be determined +\&around an atom. Both angle an distance order parameters are calculated. See +\&P.\-L. Chau and A.J. Hardwick, Mol. Phys., 93, (1998), 511\-518. +\&for more details. +This application calculates the orderparameter in a 3d\-mesh in the box, and +\&with 2 phases in the box gives the user the option to define a 2D interface in time +\&separating the faces by specifying parameters \-sgang1 and \-sgang2 (It is important +\&to select these judiciously) +.SH FILES +.BI "\-f" " traj.xtc" +.B Input + Trajectory: xtc trr trj gro g96 pdb cpt + +.BI "\-n" " index.ndx" +.B Input + Index file + +.BI "\-s" " topol.tpr" +.B Input + Run input file: tpr tpb tpa + +.BI "\-o" " intf.xpm" +.B Output, Mult. + X PixMap compatible matrix file + +.BI "\-or" " raw.out" +.B Output, Opt., Mult. + Generic output file + +.BI "\-Spect" " intfspect.out" +.B Output, Opt., Mult. + Generic output file + +.SH OTHER OPTIONS +.BI "\-[no]h" "no " + Print help info and quit + +.BI "\-[no]version" "no " + Print version info and quit + +.BI "\-nice" " int" " 19" + Set the nicelevel + +.BI "\-b" " time" " 0 " + First frame (ps) to read from trajectory + +.BI "\-e" " time" " 0 " + Last frame (ps) to read from trajectory + +.BI "\-dt" " time" " 0 " + Only use frame when t MOD dt = first time (ps) + +.BI "\-[no]w" "no " + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files + +.BI "\-d" " enum" " z" + Direction of the normal on the membrane: \fB z\fR, \fB x\fR or \fB y\fR + +.BI "\-bw" " real" " 1 " + Binwidth of box mesh + +.BI "\-sgang1" " real" " 1 " + tetrahedral angle parameter in Phase 1 (bulk) + +.BI "\-sgang2" " real" " 1 " + tetrahedral angle parameter in Phase 2 (bulk) + +.BI "\-tblock" " int" " 1" + Number of frames in one time\-block average + +.BI "\-nlevel" " int" " 100" + Number of Height levels in 2D \- XPixMaps + +.SH SEE ALSO +.BR gromacs(7) + +More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. diff -Nru gromacs-4.5.4/man/man1/g_lie.1 gromacs-4.5.5/man/man1/g_lie.1 --- gromacs-4.5.4/man/man1/g_lie.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_lie.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_lie 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_lie 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_lie - free energy estimate from linear combinations -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_lie\fP .BI "\-f" " ener.edr " @@ -21,7 +21,7 @@ .BI "\-Cqq" " real " .BI "\-ligand" " string " .SH DESCRIPTION -\&g_lie computes a free energy estimate based on an energy analysis +\&\fB g_lie\fR computes a free energy estimate based on an energy analysis \&from. One needs an energy file with the following components: \&Coul (A\-B) LJ\-SR (A\-B) etc. .SH FILES @@ -53,7 +53,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_mdmat.1 gromacs-4.5.5/man/man1/g_mdmat.1 --- gromacs-4.5.4/man/man1/g_mdmat.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_mdmat.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_mdmat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_mdmat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_mdmat - calculates residue contact maps -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_mdmat\fP .BI "\-f" " traj.xtc " @@ -21,16 +21,15 @@ .BI "\-t" " real " .BI "\-nlevels" " int " .SH DESCRIPTION -\&g_mdmat makes distance matrices consisting of the smallest distance -\&between residue pairs. With \-frames these distance matrices can be -\&stored as a function -\&of time, to be able to see differences in tertiary structure as a -\&funcion of time. If you choose your options unwise, this may generate -\&a large output file. Default only an averaged matrix over the whole +\&\fB g_mdmat\fR makes distance matrices consisting of the smallest distance +\&between residue pairs. With \fB \-frames\fR, these distance matrices can be +\&stored in order to see differences in tertiary structure as a +\&function of time. If you choose your options unwisely, this may generate +\&a large output file. By default, only an averaged matrix over the whole \&trajectory is output. \&Also a count of the number of different atomic contacts between \&residues over the whole trajectory can be made. -\&The output can be processed with xpm2ps to make a PostScript (tm) plot. +\&The output can be processed with \fB xpm2ps\fR to make a PostScript (tm) plot. .SH FILES .BI "\-f" " traj.xtc" .B Input diff -Nru gromacs-4.5.4/man/man1/g_membed.1 gromacs-4.5.5/man/man1/g_membed.1 --- gromacs-4.5.4/man/man1/g_membed.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_membed.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_membed 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_membed 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_membed - embeds a protein into a lipid bilayer -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_membed\fP .BI "\-f" " into_mem.tpr " @@ -39,6 +39,7 @@ .BI "\-pf" " pullf.xvg " .BI "\-mtx" " nm.mtx " .BI "\-dn" " dipole.ndx " +.BI "\-multidir" " rundir " .BI "\-[no]h" "" .BI "\-[no]version" "" .BI "\-nice" " int " @@ -58,28 +59,27 @@ .BI "\-[no]compact" "" .BI "\-[no]v" "" .SH DESCRIPTION -\&g_membed embeds a membrane protein into an equilibrated lipid bilayer at the position +\&\fB g_membed\fR embeds a membrane protein into an equilibrated lipid bilayer at the position \&and orientation specified by the user. -\& \&SHORT MANUAL \-\-\-\-\-\-\-\-\-\-\-\- \&The user should merge the structure files of the protein and membrane (+solvent), creating a \&single structure file with the protein overlapping the membrane at the desired position and -\&orientation. Box size should be taken from the membrane structure file. The corresponding topology -\&files should also be merged. Consecutively, create a tpr file (input for g_membed) from these files,with the following options included in the mdp file. +\&orientation. The box size is taken from the membrane structure file. The corresponding topology +\&files should also be merged. Consecutively, create a \fB .tpr\fR file (input for \fB g_membed\fR) from these files,with the following options included in the \fB .mdp\fR file. -\& \- integrator = md +\& \- \fB integrator = md\fR -\& \- energygrp = Protein (or other group that you want to insert) +\& \- \fB energygrp = Protein\fR (or other group that you want to insert) -\& \- freezegrps = Protein +\& \- \fB freezegrps = Protein\fR -\& \- freezedim = Y Y Y +\& \- \fB freezedim = Y Y Y\fR -\& \- energygrp_excl = Protein Protein +\& \- \fB energygrp_excl = Protein Protein\fR \&The output is a structure file containing the protein embedded in the membrane. If a topology \&file is provided, the number of lipid and @@ -87,33 +87,31 @@ \&For a more extensive manual see Wolf et al, J Comp Chem 31 (2010) 2169\-2174, Appendix. -\& \&SHORT METHOD DESCRIPTION \&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- -\&1. The protein is resized around its center of mass by a factor \-xy in the xy\-plane -\&(the membrane plane) and a factor \-z in the z\-direction (if the size of the +\&1. The protein is resized around its center of mass by a factor \fB \-xy\fR in the xy\-plane +\&(the membrane plane) and a factor \fB \-z\fR in the \fI z\fR\-direction (if the size of the \&protein in the z\-direction is the same or smaller than the width of the membrane, a -\&\-z value larger than 1 can prevent that the protein will be enveloped by the lipids). +\&\fB \-z\fR value larger than 1 can prevent that the protein will be enveloped by the lipids). \&2. All lipid and solvent molecules overlapping with the resized protein are removed. All -\&intraprotein interactions are turned off to prevent numerical issues for small values of \-xy -\& or \-z +\&intraprotein interactions are turned off to prevent numerical issues for small values of \fB \-xy\fR +\& or \fB \-z\fR \&3. One md step is performed. -\&4. The resize factor (\-xy or \-z) is incremented by a small amount ((1\-xy)/nxy or (1\-z)/nz) and the +\&4. The resize factor (\fB \-xy\fR or \fB \-z\fR) is incremented by a small amount ((1\-xy)/nxy or (1\-z)/nz) and the \&protein is resized again around its center of mass. The resize factor for the xy\-plane -\&is incremented first. The resize factor for the z\-direction is not changed until the \-xy factor -\&is 1 (thus after \-nxy iteration). +\&is incremented first. The resize factor for the z\-direction is not changed until the \fB \-xy\fR factor +\&is 1 (thus after \fB \-nxy\fR iterations). -\&5. Repeat step 3 and 4 until the protein reaches its original size (\-nxy + \-nz iterations). +\&5. Repeat step 3 and 4 until the protein reaches its original size (\fB \-nxy\fR + \fB \-nz\fR iterations). -\&For a more extensive method descrition see Wolf et al, J Comp Chem, 31 (2010) 2169\-2174. +\&For a more extensive method description see Wolf et al, J Comp Chem, 31 (2010) 2169\-2174. -\& \&NOTE \-\-\-\- @@ -121,10 +119,9 @@ \& \- Protein can be any molecule you want to insert in the membrane. \& \- It is recommended to perform a short equilibration run after the embedding -\&(see Wolf et al, J Comp Chem 31 (2010) 2169\-2174, to re\-equilibrate the membrane. Clearly +\&(see Wolf et al, J Comp Chem 31 (2010) 2169\-2174), to re\-equilibrate the membrane. Clearly \&protein equilibration might require longer. -\& .SH FILES .BI "\-f" " into_mem.tpr" @@ -263,6 +260,10 @@ .B Output, Opt. Index file +.BI "\-multidir" " rundir" +.B Input, Opt., Mult. + Run directory + .SH OTHER OPTIONS .BI "\-[no]h" "no " Print help info and quit diff -Nru gromacs-4.5.4/man/man1/g_mindist.1 gromacs-4.5.5/man/man1/g_mindist.1 --- gromacs-4.5.4/man/man1/g_mindist.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_mindist.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_mindist 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_mindist 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_mindist - calculates the minimum distance between two groups -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_mindist\fP .BI "\-f" " traj.xtc " @@ -33,7 +33,7 @@ .BI "\-[no]respertime" "" .BI "\-[no]printresname" "" .SH DESCRIPTION -\&g_mindist computes the distance between one group and a number of +\&\fB g_mindist\fR computes the distance between one group and a number of \&other groups. Both the minimum distance \&(between any pair of atoms from the respective groups) \&and the number of contacts within a given @@ -111,7 +111,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_morph.1 gromacs-4.5.5/man/man1/g_morph.1 --- gromacs-4.5.4/man/man1/g_morph.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_morph.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_morph 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_morph 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_morph - linear interpolation of conformations -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_morph\fP .BI "\-f1" " conf1.gro " @@ -20,15 +20,15 @@ .BI "\-last" " real " .BI "\-[no]fit" "" .SH DESCRIPTION -\&g_morph does a linear interpolation of conformations in order to +\&\fB g_morph\fR does a linear interpolation of conformations in order to \&create intermediates. Of course these are completely unphysical, but \&that you may try to justify yourself. Output is in the form of a \&generic trajectory. The number of intermediates can be controlled with -\&the \-ninterm flag. The first and last flag correspond to the way of +\&the \fB \-ninterm\fR flag. The first and last flag correspond to the way of \&interpolating: 0 corresponds to input structure 1 while \&1 corresponds to input structure 2. -\&If you specify first 0 or last 1 extrapolation will be -\&on the path from input structure x1 to x2. In general the coordinates +\&If you specify \fB \-first\fR 0 or \fB \-last\fR 1 extrapolation will be +\&on the path from input structure x1 to x2. In general, the coordinates \&of the intermediate x(i) out of N total intermidates correspond to: @@ -36,8 +36,8 @@ \&Finally the RMSD with respect to both input structures can be computed -\&if explicitly selected (\-or option). In that case an index file may be -\&read to select what group RMS is computed from. +\&if explicitly selected (\fB \-or\fR option). In that case, an index file may be +\&read to select the group from which the RMS is computed. .SH FILES .BI "\-f1" " conf1.gro" .B Input @@ -70,7 +70,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_msd.1 gromacs-4.5.5/man/man1/g_msd.1 --- gromacs-4.5.4/man/man1/g_msd.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_msd.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_msd 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_msd 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_msd - calculates mean square displacements -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_msd\fP .BI "\-f" " traj.xtc " @@ -30,7 +30,7 @@ .BI "\-beginfit" " time " .BI "\-endfit" " time " .SH DESCRIPTION -\&g_msd computes the mean square displacement (MSD) of atoms from +\&\fB g_msd\fR computes the mean square displacement (MSD) of atoms from \&a set of initial positions. This provides an easy way to compute \&the diffusion constant using the Einstein relation. \&The time between the reference points for the MSD calculation @@ -49,7 +49,8 @@ \&each group, the order in the output is: trace xx yy zz yx zx zy. -\&If \fB \-mol\fR is set, g_msd plots the MSD for individual molecules: +\&If \fB \-mol\fR is set, \fB g_msd\fR plots the MSD for individual molecules +\&(including making molecules whole across periodic boundaries): \&for each individual molecule a diffusion constant is computed for \&its center of mass. The chosen index group will be split into \&molecules. @@ -62,7 +63,7 @@ \&With the option \fB \-rmcomm\fR, the center of mass motion of a \&specific group can be removed. For trajectories produced with \&GROMACS this is usually not necessary, -\&as mdrun usually already removes the center of mass motion. +\&as \fB mdrun\fR usually already removes the center of mass motion. \&When you use this option be sure that the whole system is stored \&in the trajectory file. @@ -79,7 +80,7 @@ \&\fB \-beginfit\fR and \fB \-endfit\fR. -\&Option \fB \-pdb\fR writes a pdb file with the coordinates of the frame +\&Option \fB \-pdb\fR writes a \fB .pdb\fR file with the coordinates of the frame \&at time \fB \-tpdb\fR with in the B\-factor field the square root of \&the diffusion coefficient of the molecule. \&This option implies option \fB \-mol\fR. @@ -128,7 +129,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -152,7 +153,7 @@ Remove center of mass motion .BI "\-tpdb" " time" " 0 " - The frame to use for option \-pdb (ps) + The frame to use for option \fB \-pdb\fR (ps) .BI "\-trestart" " time" " 10 " Time between restarting points in trajectory (ps) diff -Nru gromacs-4.5.4/man/man1/gmxcheck.1 gromacs-4.5.5/man/man1/gmxcheck.1 --- gromacs-4.5.4/man/man1/gmxcheck.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/gmxcheck.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH gmxcheck 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH gmxcheck 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME gmxcheck - checks and compares files -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3gmxcheck\fP .BI "\-f" " traj.xtc " @@ -26,7 +26,7 @@ .BI "\-[no]ab" "" .BI "\-lastener" " string " .SH DESCRIPTION -\&gmxcheck reads a trajectory (\fB .trj\fR, \fB .trr\fR or +\&\fB gmxcheck\fR reads a trajectory (\fB .trj\fR, \fB .trr\fR or \&\fB .xtc\fR), an energy file (\fB .ene\fR or \fB .edr\fR) \&or an index file (\fB .ndx\fR) \&and prints out useful information about them. @@ -44,11 +44,11 @@ \&If an index file, is given its contents will be summarized. -\&If both a trajectory and a tpr file are given (with \fB \-s1\fR) +\&If both a trajectory and a \fB .tpr\fR file are given (with \fB \-s1\fR) \&the program will check whether the bond lengths defined in the tpr \&file are indeed correct in the trajectory. If not you may have \&non\-matching files due to e.g. deshuffling or due to problems with -\&virtual sites. With these flags, gmxcheck provides a quick check for such problems. +\&virtual sites. With these flags, \fB gmxcheck\fR provides a quick check for such problems. \&The program can compare two run input (\fB .tpr\fR, \fB .tpb\fR or diff -Nru gromacs-4.5.4/man/man1/gmxdump.1 gromacs-4.5.5/man/man1/gmxdump.1 --- gromacs-4.5.4/man/man1/gmxdump.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/gmxdump.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH gmxdump 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH gmxdump 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME gmxdump - makes binary files human readable -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3gmxdump\fP .BI "\-s" " topol.tpr " @@ -18,7 +18,7 @@ .BI "\-[no]nr" "" .BI "\-[no]sys" "" .SH DESCRIPTION -\&gmxdump reads a run input file (\fB .tpa\fR/\fB .tpr\fR/\fB .tpb\fR), +\&\fB gmxdump\fR reads a run input file (\fB .tpa\fR/\fB .tpr\fR/\fB .tpb\fR), \&a trajectory (\fB .trj\fR/\fB .trr\fR/\fB .xtc\fR), an energy \&file (\fB .ene\fR/\fB .edr\fR), or a checkpoint file (\fB .cpt\fR) \&and prints that to standard output in a readable format. @@ -27,7 +27,7 @@ \&The program can also preprocess a topology to help finding problems. -\&Note that currently setting GMXLIB is the only way to customize +\&Note that currently setting \fB GMXLIB\fR is the only way to customize \&directories used for searching include files. .SH FILES .BI "\-s" " topol.tpr" diff -Nru gromacs-4.5.4/man/man1/g_nmeig.1 gromacs-4.5.5/man/man1/g_nmeig.1 --- gromacs-4.5.4/man/man1/g_nmeig.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_nmeig.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,14 +1,15 @@ -.TH g_nmeig 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_nmeig 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_nmeig - diagonalizes the Hessian -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_nmeig\fP .BI "\-f" " hessian.mtx " .BI "\-s" " topol.tpr " .BI "\-of" " eigenfreq.xvg " .BI "\-ol" " eigenval.xvg " +.BI "\-qc" " quant_corr.xvg " .BI "\-v" " eigenvec.trr " .BI "\-[no]h" "" .BI "\-[no]version" "" @@ -17,8 +18,10 @@ .BI "\-[no]m" "" .BI "\-first" " int " .BI "\-last" " int " +.BI "\-T" " real " +.BI "\-[no]constr" "" .SH DESCRIPTION -\&g_nmeig calculates the eigenvectors/values of a (Hessian) matrix, +\&\fB g_nmeig\fR calculates the eigenvectors/values of a (Hessian) matrix, \&which can be calculated with \fB mdrun\fR. \&The eigenvectors are written to a trajectory file (\fB \-v\fR). \&The structure is written first with t=0. The eigenvectors @@ -26,9 +29,32 @@ \&The eigenvectors can be analyzed with \fB g_anaeig\fR. \&An ensemble of structures can be generated from the eigenvectors with \&\fB g_nmens\fR. When mass weighting is used, the generated eigenvectors -\&will be scaled back to plain cartesian coordinates before generating the -\&output \- in this case they will no longer be exactly orthogonal in the -\&standard cartesian norm (But in the mass weighted norm they would be). +\&will be scaled back to plain Cartesian coordinates before generating the +\&output. In this case, they will no longer be exactly orthogonal in the +\&standard Cartesian norm, but in the mass\-weighted norm they would be. + + +\&This program can be optionally used to compute quantum corrections to heat capacity +\&and enthalpy by providing an extra file argument \fB \-qcorr\fR. See the GROMACS +\&manual, Chapter 1, for details. The result includes subtracting a harmonic +\°ree of freedom at the given temperature. +\&The total correction is printed on the terminal screen. +\&The recommended way of getting the corrections out is: + + +\&\fB g_nmeig \-s topol.tpr \-f nm.mtx \-first 7 \-last 10000 \-T 300 \-qc [\-constr]\fR + + +\&The \fB \-constr\fR option should be used when bond constraints were used during the +\&simulation \fB for all the covalent bonds\fR. If this is not the case, +\&you need to analyze the \fB quant_corr.xvg\fR file yourself. + + +\&To make things more flexible, the program can also take virtual sites into account +\&when computing quantum corrections. When selecting \fB \-constr\fR and +\&\fB \-qc\fR, the \fB \-begin\fR and \fB \-end\fR options will be set automatically as well. +\&Again, if you think you know it better, please check the \fB eigenfreq.xvg\fR +\&output. .SH FILES .BI "\-f" " hessian.mtx" .B Input @@ -36,7 +62,7 @@ .BI "\-s" " topol.tpr" .B Input - Structure+mass(db): tpr tpb tpa gro g96 pdb + Run input file: tpr tpb tpa .BI "\-of" " eigenfreq.xvg" .B Output @@ -46,6 +72,10 @@ .B Output xvgr/xmgr file +.BI "\-qc" " quant_corr.xvg" +.B Output, Opt. + xvgr/xmgr file + .BI "\-v" " eigenvec.trr" .B Output Full precision trajectory: trr trj cpt @@ -72,6 +102,12 @@ .BI "\-last" " int" " 50" Last eigenvector to write away +.BI "\-T" " real" " 298.15" + Temperature for computing quantum heat capacity and enthalpy when using normal mode calculations to correct classical simulations + +.BI "\-[no]constr" "no " + If constraints were used in the simulation but not in the normal mode analysis (this is the recommended way of doing it) you will need to set this for computing the quantum corrections. + .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_nmens.1 gromacs-4.5.5/man/man1/g_nmens.1 --- gromacs-4.5.4/man/man1/g_nmens.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_nmens.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_nmens 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_nmens 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_nmens - generates an ensemble of structures from the normal modes -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_nmens\fP .BI "\-v" " eigenvec.trr " @@ -21,7 +21,7 @@ .BI "\-last" " int " .SH DESCRIPTION \&\fB g_nmens\fR generates an ensemble around an average structure -\&in a subspace which is defined by a set of normal modes (eigenvectors). +\&in a subspace that is defined by a set of normal modes (eigenvectors). \&The eigenvectors are assumed to be mass\-weighted. \&The position along each eigenvector is randomly taken from a Gaussian \&distribution with variance kT/eigenvalue. diff -Nru gromacs-4.5.4/man/man1/g_nmtraj.1 gromacs-4.5.5/man/man1/g_nmtraj.1 --- gromacs-4.5.4/man/man1/g_nmtraj.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_nmtraj.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_nmtraj 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_nmtraj 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_nmtraj - generate a virtual trajectory from an eigenvector -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_nmtraj\fP .BI "\-s" " topol.tpr " @@ -18,7 +18,7 @@ .BI "\-nframes" " int " .SH DESCRIPTION \&\fB g_nmtraj\fR generates an virtual trajectory from an eigenvector, -\&corresponding to a harmonic cartesian oscillation around the average +\&corresponding to a harmonic Cartesian oscillation around the average \&structure. The eigenvectors should normally be mass\-weighted, but you can \&use non\-weighted eigenvectors to generate orthogonal motions. \&The output frames are written as a trajectory file covering an entire period, and @@ -26,10 +26,10 @@ \&PDB format you can view it directly in PyMol and also render a photorealistic movie. \&Motion amplitudes are calculated from the eigenvalues and a preset temperature, \&assuming equipartition of the energy over all modes. To make the motion clearly visible -\&in PyMol you might want to amplify it by setting an unrealistic high temperature. -\&However, be aware that both the linear cartesian displacements and mass weighting will +\&in PyMol you might want to amplify it by setting an unrealistically high temperature. +\&However, be aware that both the linear Cartesian displacements and mass weighting will \&lead to serious structure deformation for high amplitudes \- this is is simply a limitation -\&of the cartesian normal mode model. By default the selected eigenvector is set to 7, since +\&of the Cartesian normal mode model. By default the selected eigenvector is set to 7, since \& the first six normal modes are the translational and rotational degrees of freedom. .SH FILES .BI "\-s" " topol.tpr" diff -Nru gromacs-4.5.4/man/man1/g_options.1 gromacs-4.5.5/man/man1/g_options.1 --- gromacs-4.5.4/man/man1/g_options.1 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_options.1 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,49 @@ +.TH g_options 1 "Sun 10 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110410-e5eb052-dirty" +.SH NAME +g_options +.B VERSION 4.5.4-dev-20110410-e5eb052-dirty +.SH SYNOPSIS +\f3g_options\fP +.BI "\-[no]h" "" +.BI "\-[no]version" "" +.BI "\-nice" " int " +.SH DESCRIPTION +\&GROMACS programs have some standard options, +\&of which some are hidden by default: +.SH OTHER OPTIONS +.BI "\-[no]h" "no " + Print help info and quit + +.BI "\-[no]version" "no " + Print version info and quit + +.BI "\-nice" " int" " 0" + Set the nicelevel + +.SH KNOWN PROBLEMS +\- If the configuration script found Motif or Lesstif on your system, you can use the graphical interface (if not, you will get an error): +\fB \-X\fR gmx_bool \fB no\fR Use dialog box GUI to edit command line options + +\- When compiled on an SGI\-IRIX system, all GROMACS programs have an additional option: +\fB \-npri\fR int \fB 0\fR Set non blocking priority (try 128) + +\- Optional files are not used unless the option is set, in contrast to non\-optional files, where the default file name is used when the option is not set. + +\- All GROMACS programs will accept file options without a file extension or filename being specified. In such cases the default filenames will be used. With multiple input file types, such as generic structure format, the directory will be searched for files of each type with the supplied or default name. When no such file is found, or with output files the first file type will be used. + +\- All GROMACS programs with the exception of \fB mdrun\fR and \fB eneconv\fR check if the command line options are valid. If this is not the case, the program will be halted. + +\- Enumerated options (enum) should be used with one of the arguments listed in the option description, the argument may be abbreviated. The first match to the shortest argument in the list will be selected. + +\- Vector options can be used with 1 or 3 parameters. When only one parameter is supplied the two others are also set to this value. + +\- All GROMACS programs can read compressed or g\-zipped files. There might be a problem with reading compressed \fB .xtc\fR, \fB .trr\fR and \fB .trj\fR files, but these will not compress very well anyway. + +\- Most GROMACS programs can process a trajectory with fewer atoms than the run input or structure file, but only if the trajectory consists of the first n atoms of the run input or structure file. + +\- Many GROMACS programs will accept the \fB \-tu\fR option to set the time units to use in output files (e.g. for \fB xmgr\fR graphs or \fB xpm\fR matrices) and in all time options. + +.SH SEE ALSO +.BR gromacs(7) + +More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. diff -Nru gromacs-4.5.4/man/man1/g_order.1 gromacs-4.5.5/man/man1/g_order.1 --- gromacs-4.5.4/man/man1/g_order.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_order.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_order 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_order 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_order - computes the order parameter per atom for carbon tails -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_order\fP .BI "\-f" " traj.xtc " @@ -44,9 +44,9 @@ \&The program can also give all \&diagonal elements of the order tensor and even calculate the deuterium -\&order parameter Scd (default). If the option \-szonly is given, only one -\&order tensor component (specified by the \-d option) is given and the -\&order parameter per slice is calculated as well. If \-szonly is not +\&order parameter Scd (default). If the option \fB \-szonly\fR is given, only one +\&order tensor component (specified by the \fB \-d\fR option) is given and the +\&order parameter per slice is calculated as well. If \fB \-szonly\fR is not \&selected, all diagonal elements and the deuterium order parameter is \&given. @@ -125,7 +125,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -134,10 +134,10 @@ Direction of the normal on the membrane: \fB z\fR, \fB x\fR or \fB y\fR .BI "\-sl" " int" " 1" - Calculate order parameter as function of boxlength, dividing the box in nr slices. + Calculate order parameter as function of box length, dividing the box in nr slices. .BI "\-[no]szonly" "no " - Only give Sz element of order tensor. (axis can be specified with \-d) + Only give Sz element of order tensor. (axis can be specified with \fB \-d\fR) .BI "\-[no]unsat" "no " Calculate order parameters for unsaturated carbons. Note that this cannot be mixed with normal order parameters. diff -Nru gromacs-4.5.4/man/man1/g_pme_error.1 gromacs-4.5.5/man/man1/g_pme_error.1 --- gromacs-4.5.4/man/man1/g_pme_error.1 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_pme_error.1 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,70 @@ +.TH g_pme_error 1 "Sun 10 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110410-e5eb052-dirty" +.SH NAME +g_pme_error - estimates the error of using PME with a given input file + +.B VERSION 4.5.4-dev-20110410-e5eb052-dirty +.SH SYNOPSIS +\f3g_pme_error\fP +.BI "\-s" " topol.tpr " +.BI "\-o" " error.out " +.BI "\-so" " tuned.tpr " +.BI "\-[no]h" "" +.BI "\-[no]version" "" +.BI "\-nice" " int " +.BI "\-beta" " real " +.BI "\-[no]tune" "" +.BI "\-self" " real " +.BI "\-seed" " int " +.BI "\-[no]v" "" +.SH DESCRIPTION +\&\fB g_pme_error\fR estimates the error of the electrostatic forces +\&if using the sPME algorithm. The flag \fB \-tune\fR will determine +\&the splitting parameter such that the error is equally +\&distributed over the real and reciprocal space part. +\&The part of the error that stems from self interaction of the particles is computationally demanding. However, a good a approximation is to +\&just use a fraction of the particles for this term which can be +\&indicated by the flag \fB \-self\fR. + + +.SH FILES +.BI "\-s" " topol.tpr" +.B Input + Run input file: tpr tpb tpa + +.BI "\-o" " error.out" +.B Output + Generic output file + +.BI "\-so" " tuned.tpr" +.B Output, Opt. + Run input file: tpr tpb tpa + +.SH OTHER OPTIONS +.BI "\-[no]h" "no " + Print help info and quit + +.BI "\-[no]version" "no " + Print version info and quit + +.BI "\-nice" " int" " 0" + Set the nicelevel + +.BI "\-beta" " real" " \-1 " + If positive, overwrite ewald_beta from \fB .tpr\fR file with this value + +.BI "\-[no]tune" "no " + Tune the splitting parameter such that the error is equally distributed between real and reciprocal space + +.BI "\-self" " real" " 1 " + If between 0.0 and 1.0, determine self interaction error from just this fraction of the charged particles + +.BI "\-seed" " int" " 0" + Random number seed used for Monte Carlo algorithm when \fB \-self\fR is set to a value between 0.0 and 1.0 + +.BI "\-[no]v" "no " + Be loud and noisy + +.SH SEE ALSO +.BR gromacs(7) + +More information about \fBGROMACS\fR is available at <\fIhttp://www.gromacs.org/\fR>. diff -Nru gromacs-4.5.4/man/man1/g_polystat.1 gromacs-4.5.5/man/man1/g_polystat.1 --- gromacs-4.5.4/man/man1/g_polystat.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_polystat.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_polystat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_polystat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_polystat - calculates static properties of polymers -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_polystat\fP .BI "\-s" " topol.tpr " @@ -24,7 +24,7 @@ .BI "\-[no]mw" "" .BI "\-[no]pc" "" .SH DESCRIPTION -\&g_polystat plots static properties of polymers as a function of time +\&\fB g_polystat\fR plots static properties of polymers as a function of time \&and prints the average. @@ -103,7 +103,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_potential.1 gromacs-4.5.5/man/man1/g_potential.1 --- gromacs-4.5.4/man/man1/g_potential.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_potential.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_potential 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_potential 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_potential - calculates the electrostatic potential across the box -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_potential\fP .BI "\-f" " traj.xtc " @@ -28,14 +28,14 @@ .BI "\-ng" " int " .BI "\-[no]correct" "" .SH DESCRIPTION -\&Compute the electrostatical potential across the box. The potential is +\&\fB g_potential\fR computes the electrostatical potential across the box. The potential is \&calculated by first summing the charges per slice and then integrating \&twice of this charge distribution. Periodic boundaries are not taken \&into account. Reference of potential is taken to be the left side of -\&the box. It's also possible to calculate the potential in spherical +\&the box. It is also possible to calculate the potential in spherical \&coordinates as function of r by calculating a charge distribution in \&spherical slices and twice integrating them. epsilon_r is taken as 1, -\&2 is more appropriate in many cases. +\&but 2 is more appropriate in many cases. .SH FILES .BI "\-f" " traj.xtc" .B Input @@ -81,7 +81,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_principal.1 gromacs-4.5.5/man/man1/g_principal.1 --- gromacs-4.5.4/man/man1/g_principal.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_principal.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_principal 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_principal 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_principal - calculates axes of inertia for a group of atoms -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_principal\fP .BI "\-f" " traj.xtc " @@ -22,7 +22,7 @@ .BI "\-[no]w" "" .BI "\-[no]foo" "" .SH DESCRIPTION -\&g_principal calculates the three principal axes of inertia for a group +\&\fB g_principal\fR calculates the three principal axes of inertia for a group \&of atoms. .SH FILES .BI "\-f" " traj.xtc" @@ -76,7 +76,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-[no]foo" "no " Dummy option to avoid empty array diff -Nru gromacs-4.5.4/man/man1/g_protonate.1 gromacs-4.5.5/man/man1/g_protonate.1 --- gromacs-4.5.4/man/man1/g_protonate.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_protonate.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_protonate 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_protonate 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_protonate - protonates structures -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_protonate\fP .BI "\-s" " topol.tpr " @@ -16,15 +16,15 @@ .BI "\-e" " time " .BI "\-dt" " time " .SH DESCRIPTION -\&\fB protonate\fR reads (a) conformation(s) and adds all missing -\&hydrogens as defined in \fB ffgmx2.hdb\fR. If only \fB \-s\fR is +\&\fB g_protonate\fR reads (a) conformation(s) and adds all missing +\&hydrogens as defined in \fB gmx2.ff/aminoacids.hdb\fR. If only \fB \-s\fR is \&specified, this conformation will be protonated, if also \fB \-f\fR -\&is specified, the conformation(s) will be read from this file +\&is specified, the conformation(s) will be read from this file, \&which can be either a single conformation or a trajectory. \& -\&If a pdb file is supplied, residue names might not correspond to +\&If a \fB .pdb\fR file is supplied, residue names might not correspond to \&to the GROMACS naming conventions, in which case these residues will \&probably not be properly protonated. \& diff -Nru gromacs-4.5.4/man/man1/g_rama.1 gromacs-4.5.5/man/man1/g_rama.1 --- gromacs-4.5.4/man/man1/g_rama.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_rama.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_rama 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_rama 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_rama - computes Ramachandran plots -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_rama\fP .BI "\-f" " traj.xtc " @@ -17,7 +17,7 @@ .BI "\-[no]w" "" .BI "\-xvg" " enum " .SH DESCRIPTION -\&g_rama selects the Phi/Psi dihedral combinations from your topology file +\&\fB g_rama\fR selects the phi/psi dihedral combinations from your topology file \&and computes these as a function of time. \&Using simple Unix tools such as \fI grep\fR you can select out \&specific residues. @@ -54,7 +54,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_rdf.1 gromacs-4.5.5/man/man1/g_rdf.1 --- gromacs-4.5.4/man/man1/g_rdf.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_rdf.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_rdf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_rdf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_rdf - calculates radial distribution functions -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_rdf\fP .BI "\-f" " traj.xtc " @@ -42,22 +42,22 @@ \&a scattering experiment. -\&g_rdf calculates radial distribution functions in different ways. +\&\fB g_rdf\fR calculates radial distribution functions in different ways. \&The normal method is around a (set of) particle(s), the other methods \&are around the center of mass of a set of particles (\fB \-com\fR) \&or to the closest particle in a set (\fB \-surf\fR). -\&With all methods rdf's can also be calculated around axes parallel -\&to the z\-axis with option \fB \-xy\fR. +\&With all methods, the RDF can also be calculated around axes parallel +\&to the \fI z\fR\-axis with option \fB \-xy\fR. \&With option \fB \-surf\fR normalization can not be used. -\&The option \fB \-rdf\fR sets the type of rdf to be computed. +\&The option \fB \-rdf\fR sets the type of RDF to be computed. \&Default is for atoms or particles, but one can also select center -\&of mass or geometry of molecules or residues. In all cases only +\&of mass or geometry of molecules or residues. In all cases, only \&the atoms in the index groups are taken into account. -\&For molecules and/or the center of mass option a run input file +\&For molecules and/or the center of mass option, a run input file \&is required. -\&Other weighting than COM or COG can currently only be achieved +\&Weighting other than COM or COG can currently only be achieved \&by providing a run input file with different masses. \&Options \fB \-com\fR and \fB \-surf\fR also work in conjunction \&with \fB \-rdf\fR. @@ -65,17 +65,17 @@ \&If a run input file is supplied (\fB \-s\fR) and \fB \-rdf\fR is set \&to \fB atom\fR, exclusions defined -\&in that file are taken into account when calculating the rdf. +\&in that file are taken into account when calculating the RDF. \&The option \fB \-cut\fR is meant as an alternative way to avoid -\&intramolecular peaks in the rdf plot. +\&intramolecular peaks in the RDF plot. \&It is however better to supply a run input file with a higher number of -\&exclusions. For eg. benzene a topology with nrexcl set to 5 -\&would eliminate all intramolecular contributions to the rdf. +\&exclusions. For e.g. benzene a topology, setting nrexcl to 5 +\&would eliminate all intramolecular contributions to the RDF. \&Note that all atoms in the selected groups are used, also the ones \&that don't have Lennard\-Jones interactions. -\&Option \fB \-cn\fR produces the cumulative number rdf, +\&Option \fB \-cn\fR produces the cumulative number RDF, \&i.e. the average number of particles within a distance r. @@ -135,7 +135,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_rms.1 gromacs-4.5.5/man/man1/g_rms.1 --- gromacs-4.5.4/man/man1/g_rms.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_rms.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_rms 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_rms 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_rms - calculates rmsd's with a reference structure and rmsd matrices -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_rms\fP .BI "\-s" " topol.tpr " @@ -40,10 +40,10 @@ .BI "\-nlevels" " int " .BI "\-ng" " int " .SH DESCRIPTION -\&g_rms compares two structures by computing the root mean square -\&deviation (RMSD), the size\-independent 'rho' similarity parameter -\&(rho) or the scaled rho (rhosc), -\&see Maiorov & Crippen, PROTEINS \fB 22\fR, 273 (1995). +\&\fB g_rms\fR compares two structures by computing the root mean square +\&deviation (RMSD), the size\-independent rho similarity parameter +\&(\fB rho\fR) or the scaled rho (\fB rhosc\fR), +\&see Maiorov & Crippen, Proteins \fB 22\fR, 273 (1995). \&This is selected by \fB \-what\fR. Each structure from a trajectory (\fB \-f\fR) is compared to a @@ -54,7 +54,7 @@ \&With option \fB \-mir\fR also a comparison with the mirror image of \&the reference structure is calculated. \&This is useful as a reference for 'significant' values, see -\&Maiorov & Crippen, PROTEINS \fB 22\fR, 273 (1995). +\&Maiorov & Crippen, Proteins \fB 22\fR, 273 (1995). \&Option \fB \-prev\fR produces the comparison with a previous frame @@ -74,10 +74,10 @@ \&Option \fB \-mw\fR controls whether mass weighting is done or not. \&If you select the option (default) and -\&supply a valid tpr file masses will be taken from there, -\&otherwise the masses will be deduced from the atommass.dat file in -\&the GROMACS library directory. This is fine for proteins but not -\&necessarily for other molecules. A default mass of 12.011 amu (Carbon) +\&supply a valid \fB .tpr\fR file masses will be taken from there, +\&otherwise the masses will be deduced from the \fB atommass.dat\fR file in +\&\fB GMXLIB\fR. This is fine for proteins, but not +\&necessarily for other molecules. A default mass of 12.011 amu (carbon) \&is assigned to unknown atoms. You can check whether this happend by \&turning on the \fB \-debug\fR flag and inspecting the log file. @@ -161,7 +161,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_rmsdist.1 gromacs-4.5.5/man/man1/g_rmsdist.1 --- gromacs-4.5.4/man/man1/g_rmsdist.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_rmsdist.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_rmsdist 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty" +.TH g_rmsdist 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_rmsdist - calculates atom pair distances averaged with power \-2, \-3 or \-6 -.B VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_rmsdist\fP .BI "\-f" " traj.xtc " @@ -29,16 +29,16 @@ .BI "\-[no]sumh" "" .BI "\-[no]pbc" "" .SH DESCRIPTION -\&g_rmsdist computes the root mean square deviation of atom distances, +\&\fB g_rmsdist\fR computes the root mean square deviation of atom distances, \&which has the advantage that no fit is needed like in standard RMS -\&deviation as computed by g_rms. +\&deviation as computed by \fB g_rms\fR. \&The reference structure is taken from the structure file. -\&The rmsd at time t is calculated as the rms +\&The RMSD at time t is calculated as the RMS \&of the differences in distance between atom\-pairs in the reference \&structure and the structure at time t. -\&g_rmsdist can also produce matrices of the rms distances, rms distances +\&\fB g_rmsdist\fR can also produce matrices of the rms distances, rms distances \&scaled with the mean distance and the mean distances and matrices with \&NMR averaged distances (1/r3 and 1/r6 averaging). Finally, lists \&of atom pairs with 1/r3 and 1/r6 averaged distance below the @@ -120,7 +120,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_rmsf.1 gromacs-4.5.5/man/man1/g_rmsf.1 --- gromacs-4.5.4/man/man1/g_rmsf.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_rmsf.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_rmsf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_rmsf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_rmsf - calculates atomic fluctuations -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_rmsf\fP .BI "\-f" " traj.xtc " @@ -27,14 +27,14 @@ .BI "\-[no]aniso" "" .BI "\-[no]fit" "" .SH DESCRIPTION -\&g_rmsf computes the root mean square fluctuation (RMSF, i.e. standard -\&deviation) of atomic positions -\&after (optionally) fitting to a reference frame. +\&\fB g_rmsf\fR computes the root mean square fluctuation (RMSF, i.e. standard +\&deviation) of atomic positions in the trajectory (supplied with \fB \-f\fR) +\&after (optionally) fitting to a reference frame (supplied with \fB \-s\fR). \&With option \fB \-oq\fR the RMSF values are converted to B\-factor -\&values, which are written to a pdb file with the coordinates, of the -\&structure file, or of a pdb file when \fB \-q\fR is specified. +\&values, which are written to a \fB .pdb\fR file with the coordinates, of the +\&structure file, or of a \fB .pdb\fR file when \fB \-q\fR is specified. \&Option \fB \-ox\fR writes the B\-factors to a file with the average \&coordinates. @@ -43,18 +43,18 @@ \&respect to the reference structure is calculated. -\&With the option \fB aniso\fR g_rmsf will compute anisotropic +\&With the option \fB \-aniso\fR, \fB g_rmsf\fR will compute anisotropic \&temperature factors and then it will also output average coordinates -\&and a pdb file with ANISOU records (corresonding to the \fB \-oq\fR +\&and a \fB .pdb\fR file with ANISOU records (corresonding to the \fB \-oq\fR \&or \fB \-ox\fR option). Please note that the U values -\&are orientation dependent, so before comparison with experimental data +\&are orientation\-dependent, so before comparison with experimental data \&you should verify that you fit to the experimental coordinates. -\&When a pdb input file is passed to the program and the \fB \-aniso\fR +\&When a \fB .pdb\fR input file is passed to the program and the \fB \-aniso\fR \&flag is set \&a correlation plot of the Uij will be created, if any anisotropic -\&temperature factors are present in the pdb file. +\&temperature factors are present in the \fB .pdb\fR file. \&With option \fB \-dir\fR the average MSF (3x3) matrix is diagonalized. @@ -121,7 +121,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/grompp.1 gromacs-4.5.5/man/man1/grompp.1 --- gromacs-4.5.4/man/man1/grompp.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/grompp.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH grompp 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH grompp 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME grompp - makes a run input file -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3grompp\fP .BI "\-f" " grompp.mdp " @@ -37,7 +37,7 @@ \&for hydrogens and heavy atoms. \&Then a coordinate file is read and velocities can be generated \&from a Maxwellian distribution if requested. -\&grompp also reads parameters for the mdrun +\&\fB grompp\fR also reads parameters for the \fB mdrun\fR \&(eg. number of MD steps, time step, cut\-off), and others such as \&NEMD parameters, which are corrected so that the net acceleration \&is zero. @@ -45,15 +45,16 @@ \&file for the MD program. -\&grompp uses the atom names from the topology file. The atom names +\&\fB grompp\fR uses the atom names from the topology file. The atom names \&in the coordinate file (option \fB \-c\fR) are only read to generate \&warnings when they do not match the atom names in the topology. \&Note that the atom names are irrelevant for the simulation as \&only the atom types are used for generating interaction parameters. -\&grompp uses a built\-in preprocessor to resolve includes, macros -\&etcetera. The preprocessor supports the following keywords: +\&\fB grompp\fR uses a built\-in preprocessor to resolve includes, macros, +\&etc. The preprocessor supports the following keywords: + \&ifdef VARIABLE @@ -70,24 +71,20 @@ \&include filename + \&The functioning of these statements in your topology may be modulated by -\&using the following two flags in your \fB mdp\fR file: +\&using the following two flags in your \fB .mdp\fR file: + -\&define = \-DVARIABLE1 \-DVARIABLE2 +\&\fB define = \-DVARIABLE1 \-DVARIABLE2 -\&include = /home/john/doe +\&include = \-I/home/john/doe\fR \&For further information a C\-programming textbook may help you out. \&Specifying the \fB \-pp\fR flag will get the pre\-processed \&topology file written out so that you can verify its contents. -\&If your system does not have a c\-preprocessor, you can still -\&use grompp, but you do not have access to the features -\&from the cpp. Command line options to the c\-preprocessor can be given -\&in the \fB .mdp\fR file. See your local manual (man cpp). - - \&When using position restraints a file with restraint coordinates \&can be supplied with \fB \-r\fR, otherwise restraining will be done \&with respect to the conformation from the \fB \-c\fR option. @@ -98,26 +95,26 @@ \&Starting coordinates can be read from trajectory with \fB \-t\fR. \&The last frame with coordinates and velocities will be read, -\&unless the \fB \-time\fR option is used. +\&unless the \fB \-time\fR option is used. Only if this information +\&is absent will the coordinates in the \fB \-c\fR file be used. \&Note that these velocities will not be used when \fB gen_vel = yes\fR \&in your \fB .mdp\fR file. An energy file can be supplied with \&\fB \-e\fR to read Nose\-Hoover and/or Parrinello\-Rahman coupling -\&variables. Note that for continuation it is better and easier to supply -\&a checkpoint file directly to mdrun, since that always contains -\&the complete state of the system and you don't need to generate -\&a new run input file. Note that if you only want to change the number -\&of run steps tpbconv is more convenient than grompp. - - -\&Using the \fB \-morse\fR option grompp can convert the harmonic bonds -\&in your topology to morse potentials. This makes it possible to break -\&bonds. For this option to work you need an extra file in your $GMXLIB -\&with dissociation energy. Use the \-debug option to get more information -\&on the workings of this option (look for MORSE in the grompp.log file -\&using less or something like that). +\&variables. -\&By default all bonded interactions which have constant energy due to +\&\fB grompp\fR can be used to restart simulations (preserving +\&continuity) by supplying just a checkpoint file with \fB \-t\fR. +\&However, for simply changing the number of run steps to extend +\&a run, using \fB tpbconv\fR is more convenient than \fB grompp\fR. +\&You then supply the old checkpoint file directly to \fB mdrun\fR +\&with \fB \-cpi\fR. If you wish to change the ensemble or things +\&like output frequency, then supplying the checkpoint file to +\&\fB grompp\fR with \fB \-t\fR along with a new \fB .mdp\fR file +\&with \fB \-f\fR is the recommended procedure. + + +\&By default, all bonded interactions which have constant energy due to \&virtual site constructions will be removed. If this constant energy is \¬ zero, this will result in a shift in the total energy. All bonded \&interactions can be kept by turning off \fB \-rmvsbds\fR. Additionally, @@ -125,17 +122,24 @@ \&of virtual site constructions will be removed. If any constraints remain \&which involve virtual sites, a fatal error will result. -To verify your run input file, please make notice of all warnings +To verify your run input file, please take note of all warnings \&on the screen, and correct where necessary. Do also look at the contents -\&of the \fB mdout.mdp\fR file, this contains comment lines, as well as -\&the input that \fB grompp\fR has read. If in doubt you can start grompp +\&of the \fB mdout.mdp\fR file; this contains comment lines, as well as +\&the input that \fB grompp\fR has read. If in doubt, you can start \fB grompp\fR \&with the \fB \-debug\fR option which will give you more information -\&in a file called grompp.log (along with real debug info). Finally, you +\&in a file called \fB grompp.log\fR (along with real debug info). You \&can see the contents of the run input file with the \fB gmxdump\fR -\&program. +\&program. \fB gmxcheck\fR can be used to compare the contents of two +\&run input files. + +The \fB \-maxwarn\fR option can be used to override warnings printed +\&by \fB grompp\fR that otherwise halt output. In some cases, warnings are +\&harmless, but usually they are not. The user is advised to carefully +\&interpret the output messages before attempting to bypass them with +\&this option. .SH FILES .BI "\-f" " grompp.mdp" -.B Input, Opt. +.B Input grompp input file with MD parameters .BI "\-po" " mdout.mdp" @@ -198,7 +202,7 @@ Remove constant bonded interactions with virtual sites .BI "\-maxwarn" " int" " 0" - Number of allowed warnings during input processing + Number of allowed warnings during input processing. Not for normal use and may generate unstable systems .BI "\-[no]zero" "no " Set parameters for bonded interactions without defaults to zero instead of generating an error diff -Nru gromacs-4.5.4/man/man1/g_rotacf.1 gromacs-4.5.5/man/man1/g_rotacf.1 --- gromacs-4.5.4/man/man1/g_rotacf.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_rotacf.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_rotacf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_rotacf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_rotacf - calculates the rotational correlation function for molecules -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_rotacf\fP .BI "\-f" " traj.xtc " @@ -27,13 +27,13 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_rotacf calculates the rotational correlation function +\&\fB g_rotacf\fR calculates the rotational correlation function \&for molecules. Three atoms (i,j,k) must be given in the index -\&file, defining two vectors ij and jk. The rotational acf +\&file, defining two vectors ij and jk. The rotational ACF \&is calculated as the autocorrelation function of the vector \&n = ij x jk, i.e. the cross product of the two vectors. \&Since three atoms span a plane, the order of the three atoms -\&does not matter. Optionally, controlled by the \-d switch, you can +\&does not matter. Optionally, controlled by the \fB \-d\fR switch, you can \&calculate the rotational correlation function for linear molecules \&by specifying two atoms (i,j) in the index file. \& @@ -42,15 +42,14 @@ \&EXAMPLES -\&g_rotacf \-P 1 \-nparm 2 \-fft \-n index \-o rotacf\-x\-P1 -\&\-fa expfit\-x\-P1 \-beginfit 2.5 \-endfit 20.0 +\&\fB g_rotacf \-P 1 \-nparm 2 \-fft \-n index \-o rotacf\-x\-P1 +\&\-fa expfit\-x\-P1 \-beginfit 2.5 \-endfit 20.0\fR \&This will calculate the rotational correlation function using a first \&order Legendre polynomial of the angle of a vector defined by the index -\&file. The correlation function will be fitted from 2.5 ps till 20.0 ps -\&to a two parameter exponential. -\& +\&file. The correlation function will be fitted from 2.5 ps until 20.0 ps +\&to a two\-parameter exponential. .SH FILES .BI "\-f" " traj.xtc" .B Input @@ -88,7 +87,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -109,7 +108,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_rotmat.1 gromacs-4.5.5/man/man1/g_rotmat.1 --- gromacs-4.5.4/man/man1/g_rotmat.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_rotmat.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_rotmat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty" +.TH g_rotmat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_rotmat - plots the rotation matrix for fitting to a reference structure -.B VERSION 4.5-beta4-2010-08-26 09:43:57 +0200-33da7ba-dirty +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_rotmat\fP .BI "\-f" " traj.xtc " @@ -22,7 +22,7 @@ .BI "\-[no]fitxy" "" .BI "\-[no]mw" "" .SH DESCRIPTION -\&g_rotmat plots the rotation matrix required for least squares fitting +\&\fB g_rotmat\fR plots the rotation matrix required for least squares fitting \&a conformation onto the reference conformation provided with \&\fB \-s\fR. Translation is removed before fitting. \&The output are the three vectors that give the new directions @@ -36,7 +36,7 @@ \&determining the orientation of a molecule \&at an interface, possibly on a trajectory produced with \&\fB trjconv \-fit rotxy+transxy\fR to remove the rotation -\&in the xy\-plane. +\&in the \fI x\-y\fR plane. \& @@ -45,12 +45,12 @@ \&the lowest sum of RMSD's to all other structures is used. \&Since the computational cost of this procedure grows with \&the square of the number of frames, the \fB \-skip\fR option -\&can be useful. A full fit or only a fit in the x/y plane can +\&can be useful. A full fit or only a fit in the \fI x\-y\fR plane can \&be performed. \& -\&Option \fB \-fitxy\fR fits in the x/y plane before determining +\&Option \fB \-fitxy\fR fits in the \fI x\-y\fR plane before determining \&the rotation matrix. .SH FILES .BI "\-f" " traj.xtc" @@ -89,7 +89,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -98,7 +98,7 @@ Determine the optimal reference structure: \fB none\fR, \fB xyz\fR or \fB xy\fR .BI "\-skip" " int" " 1" - Use every nr\-th frame for \-ref + Use every nr\-th frame for \fB \-ref\fR .BI "\-[no]fitxy" "no " Fit the x/y rotation before determining the rotation diff -Nru gromacs-4.5.4/man/man1/g_saltbr.1 gromacs-4.5.5/man/man1/g_saltbr.1 --- gromacs-4.5.4/man/man1/g_saltbr.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_saltbr.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_saltbr 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_saltbr 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_saltbr - computes salt bridges -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_saltbr\fP .BI "\-f" " traj.xtc " @@ -16,15 +16,16 @@ .BI "\-t" " real " .BI "\-[no]sep" "" .SH DESCRIPTION -\&g_saltbr plots the distance between all combination of charged groups +\&\fB g_saltbr\fR plots the distance between all combination of charged groups \&as a function of time. The groups are combined in different ways. -\&A minimum distance can be given, (eg. the cut\-off), then groups +\&A minimum distance can be given (i.e. a cut\-off), such that groups \&that are never closer than that distance will not be plotted. -\&Output will be in a number of fixed filenames, min\-min.xvg, plus\-min.xvg -\&and plus\-plus.xvg, or files for every individual ion\-pair if the \fB \-sep\fR -\&option is selected. In this case files are named as \fB sb\-ResnameResnr\-Atomnr\fR. -\&There may be many such files. + +\&Output will be in a number of fixed filenames, \fB min\-min.xvg\fR, \fB plus\-min.xvg\fR +\&and \fB plus\-plus.xvg\fR, or files for every individual ion pair if the \fB \-sep\fR +\&option is selected. In this case, files are named as \fB sb\-(Resname)(Resnr)\-(Atomnr)\fR. +\&There may be \fB many\fR such files. .SH FILES .BI "\-f" " traj.xtc" .B Input diff -Nru gromacs-4.5.4/man/man1/g_sas.1 gromacs-4.5.5/man/man1/g_sas.1 --- gromacs-4.5.4/man/man1/g_sas.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_sas.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_sas 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_sas 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_sas - computes solvent accessible surface area -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_sas\fP .BI "\-f" " traj.xtc " @@ -31,17 +31,17 @@ .BI "\-[no]prot" "" .BI "\-dgs" " real " .SH DESCRIPTION -\&g_sas computes hydrophobic, hydrophilic and total solvent accessible surface area. -\&As a side effect the Connolly surface can be generated as well in -\&a pdb file where the nodes are represented as atoms and the vertices +\&\fB g_sas\fR computes hydrophobic, hydrophilic and total solvent accessible surface area. +\&As a side effect, the Connolly surface can be generated as well in +\&a \fB .pdb\fR file where the nodes are represented as atoms and the vertices \&connecting the nearest nodes as CONECT records. \&The program will ask for a group for the surface calculation \&and a group for the output. The calculation group should always \&consists of all the non\-solvent atoms in the system. \&The output group can be the whole or part of the calculation group. -\&The area can be plotted +\&The average and standard deviation of the area over the trajectory can be plotted \&per residue and atom as well (options \fB \-or\fR and \fB \-oa\fR). -\&In combination with the latter option an \fB itp\fR file can be +\&In combination with the latter option an \fB .itp\fR file can be \&generated (option \fB \-i\fR) \&which can be used to restrain surface atoms. @@ -55,9 +55,9 @@ \&Please consider whether the normal probe radius is appropriate \&in this case or whether you would rather use e.g. 0. It is good \&to keep in mind that the results for volume and density are very -\&approximate, in e.g. ice Ih one can easily fit water molecules in the -\&pores which would yield too low volume, too high surface area and too -\&high density. +\&approximate. For example, in ice Ih, one can easily fit water molecules in the +\&pores which would yield a volume that is too low, and surface area and density +\&that are both too high. .SH FILES .BI "\-f" " traj.xtc" .B Input @@ -115,7 +115,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -139,10 +139,10 @@ Take periodicity into account .BI "\-[no]prot" "yes " - Output the protein to the connelly pdb file too + Output the protein to the Connelly \fB .pdb\fR file too .BI "\-dgs" " real" " 0 " - default value for solvation free energy per area (kJ/mol/nm2) + Default value for solvation free energy per area (kJ/mol/nm2) .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_select.1 gromacs-4.5.5/man/man1/g_select.1 --- gromacs-4.5.4/man/man1/g_select.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_select.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_select 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_select 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_select - selects groups of atoms based on flexible textual selections -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_select\fP .BI "\-f" " traj.xtc " @@ -31,7 +31,7 @@ .BI "\-[no]cfnorm" "" .BI "\-resnr" " enum " .SH DESCRIPTION -\&g_select writes out basic data about dynamic selections. +\&\fB g_select\fR writes out basic data about dynamic selections. \&It can be used for some simple analyses, or the output can \&be combined with output from other programs and/or external \&analysis programs to calculate more complex things. @@ -66,7 +66,7 @@ \&With \fB \-on\fR, the selected atoms are written as a index file -\&compatible with make_ndx and the analyzing tools. Each selection +\&compatible with \fB make_ndx\fR and the analyzing tools. Each selection \&is written as a selection group and for dynamic selections a \&group is written for each frame. diff -Nru gromacs-4.5.4/man/man1/g_sgangle.1 gromacs-4.5.5/man/man1/g_sgangle.1 --- gromacs-4.5.4/man/man1/g_sgangle.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_sgangle.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_sgangle 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_sgangle 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_sgangle - computes the angle and distance between two groups -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_sgangle\fP .BI "\-f" " traj.xtc " @@ -26,10 +26,10 @@ \&Compute the angle and distance between two groups. \&The groups are defined by a number of atoms given in an index file and \&may be two or three atoms in size. -\&If \-one is set, only one group should be specified in the index +\&If \fB \-one\fR is set, only one group should be specified in the index \&file and the angle between this group at time 0 and t will be computed. \&The angles calculated depend on the order in which the atoms are -\&given. Giving for instance 5 6 will rotate the vector 5\-6 with +\&given. Giving, for instance, 5 6 will rotate the vector 5\-6 with \&180 degrees compared to giving 6 5. If three atoms are given, @@ -41,13 +41,13 @@ \&Here is what some of the file options do: -\&\-oa: Angle between the two groups specified in the index file. If a group contains three atoms the normal to the plane defined by those three atoms will be used. If a group contains two atoms, the vector defined by those two atoms will be used. +\&\fB \-oa\fR: Angle between the two groups specified in the index file. If a group contains three atoms the normal to the plane defined by those three atoms will be used. If a group contains two atoms, the vector defined by those two atoms will be used. -\&\-od: Distance between two groups. Distance is taken from the center of one group to the center of the other group. +\&\fB \-od\fR: Distance between two groups. Distance is taken from the center of one group to the center of the other group. -\&\-od1: If one plane and one vector is given, the distances for each of the atoms from the center of the plane is given separately. +\&\fB \-od1\fR: If one plane and one vector is given, the distances for each of the atoms from the center of the plane is given separately. -\&\-od2: For two planes this option has no meaning. +\&\fB \-od2\fR: For two planes this option has no meaning. .SH FILES .BI "\-f" " traj.xtc" .B Input @@ -97,7 +97,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -106,7 +106,7 @@ Only one group compute angle between vector at time zero and time t .BI "\-[no]z" "no " - Use the Z\-axis as reference + Use the \fI z\fR\-axis as reference .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_sham.1 gromacs-4.5.5/man/man1/g_sham.1 --- gromacs-4.5.4/man/man1/g_sham.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_sham.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_sham 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_sham 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_sham - read/write xmgr and xvgr data sets -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_sham\fP .BI "\-f" " graph.xvg " @@ -45,19 +45,19 @@ .BI "\-nlevels" " int " .BI "\-mname" " string " .SH DESCRIPTION -\&g_sham makes multi\-dimensional free\-energy, enthalpy and entropy plots. -\&g_sham reads one or more xvg files and analyzes data sets. -\&g_sham basic purpose is plotting Gibbs free energy landscapes +\&\fB g_sham\fR makes multi\-dimensional free\-energy, enthalpy and entropy plots. +\&\fB g_sham\fR reads one or more \fB .xvg\fR files and analyzes data sets. +\&The basic purpose of \fB g_sham\fR is to plot Gibbs free energy landscapes \&(option \fB \-ls\fR) -\&by Bolzmann inverting multi\-dimensional histograms (option \fB \-lp\fR) +\&by Bolzmann inverting multi\-dimensional histograms (option \fB \-lp\fR), \&but it can also \&make enthalpy (option \fB \-lsh\fR) and entropy (option \fB \-lss\fR) \&plots. The histograms can be made for any quantities the user supplies. \&A line in the input file may start with a time -\&(see option \fB \-time\fR) and any number of y values may follow. +\&(see option \fB \-time\fR) and any number of \fI y\fR\-values may follow. \&Multiple sets can also be \&read when they are separated by & (option \fB \-n\fR), -\&in this case only one y value is read from each line. +\&in this case only one \fI y\fR\-value is read from each line. \&All lines starting with and @ are skipped. \& @@ -71,23 +71,23 @@ \&Option \fB \-ene\fR can be used to supply a file with energies. \&These energies are used as a weighting function in the single -\&histogram analysis method due to Kumar et. al. When also temperatures -\&are supplied (as a second column in the file) an experimental +\&histogram analysis method by Kumar et al. When temperatures +\&are supplied (as a second column in the file), an experimental \&weighting scheme is applied. In addition the vales \&are used for making enthalpy and entropy plots. \& -\&With option \fB \-dim\fR dimensions can be gives for distances. +\&With option \fB \-dim\fR, dimensions can be gives for distances. \&When a distance is 2\- or 3\-dimensional, the circumference or surface \&sampled by two particles increases with increasing distance. \&Depending on what one would like to show, one can choose to correct \&the histogram and free\-energy for this volume effect. -\&The probability is normalized by r and r2 for a dimension of 2 and 3 +\&The probability is normalized by r and r2 for dimensions of 2 and 3, \&respectively. \&A value of \-1 is used to indicate an angle in degrees between two \&vectors: a sin(angle) normalization will be applied. -\&Note that for angles between vectors the inner\-product or cosine +\&\fB Note\fR that for angles between vectors the inner\-product or cosine \&is the natural quantity to use, as it will produce bins of the same \&volume. .SH FILES @@ -158,7 +158,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_sigeps.1 gromacs-4.5.5/man/man1/g_sigeps.1 --- gromacs-4.5.4/man/man1/g_sigeps.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_sigeps.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_sigeps 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_sigeps 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_sigeps - convert c6/12 or c6/cn combinations to and from sigma/epsilon -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_sigeps\fP .BI "\-o" " potje.xvg " @@ -23,10 +23,10 @@ .BI "\-qj" " real " .BI "\-sigfac" " real " .SH DESCRIPTION -\&Sigeps is a simple utility that converts c6/c12 or c6/cn combinations +\&\fB g_sigeps\fR is a simple utility that converts C6/C12 or C6/Cn combinations \&to sigma and epsilon, or vice versa. It can also plot the potential -\&in file. In addition it makes an approximation of a Buckingham potential -\&to a Lennard Jones potential. +\&in file. In addition, it makes an approximation of a Buckingham potential +\&to a Lennard\-Jones potential. .SH FILES .BI "\-o" " potje.xvg" .B Output @@ -43,7 +43,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_sorient.1 gromacs-4.5.5/man/man1/g_sorient.1 --- gromacs-4.5.4/man/man1/g_sorient.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_sorient.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_sorient 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_sorient 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_sorient - analyzes solvent orientation around solutes -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_sorient\fP .BI "\-f" " traj.xtc " @@ -29,17 +29,19 @@ .BI "\-rbin" " real " .BI "\-[no]pbc" "" .SH DESCRIPTION -\&g_sorient analyzes solvent orientation around solutes. +\&\fB g_sorient\fR analyzes solvent orientation around solutes. \&It calculates two angles between the vector from one or more \&reference positions to the first atom of each solvent molecule: + \&theta1: the angle with the vector from the first atom of the solvent \&molecule to the midpoint between atoms 2 and 3. \&theta2: the angle with the normal of the solvent plane, defined by the -\&same three atoms, or when the option \fB \-v23\fR is set +\&same three atoms, or, when the option \fB \-v23\fR is set, \&the angle with the vector between atoms 2 and 3. + \&The reference can be a set of atoms or \&the center of mass of a set of atoms. The group of solvent atoms should \&consist of 3 atoms per solvent molecule. @@ -115,7 +117,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_spatial.1 gromacs-4.5.5/man/man1/g_spatial.1 --- gromacs-4.5.4/man/man1/g_spatial.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_spatial.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_spatial 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_spatial 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME -g_spatial - calculates the spatial distribution function (more control than g_sdf) +g_spatial - calculates the spatial distribution function -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_spatial\fP .BI "\-s" " topol.tpr " @@ -21,57 +21,57 @@ .BI "\-bin" " real " .BI "\-nab" " int " .SH DESCRIPTION -\&g_spatial calculates the spatial distribution function and +\&\fB g_spatial\fR calculates the spatial distribution function and \&outputs it in a form that can be read by VMD as Gaussian98 cube format. -\&This was developed from template.c (gromacs\-3.3). -\&For a system of 32K atoms and a 50ns trajectory, the SDF can be generated +\&This was developed from template.c (GROMACS\-3.3). +\&For a system of 32,000 atoms and a 50 ns trajectory, the SDF can be generated \&in about 30 minutes, with most of the time dedicated to the two runs through -\&trjconv that are required to center everything properly. -\&This also takes a whole bunch of space (3 copies of the xtc file). +\&\fB trjconv\fR that are required to center everything properly. +\&This also takes a whole bunch of space (3 copies of the \fB .xtc\fR file). \&Still, the pictures are pretty and very informative when the fitted selection is properly made. -\&3\-4 atoms in a widely mobile group like a free amino acid in solution works +\&3\-4 atoms in a widely mobile group (like a free amino acid in solution) works \&well, or select the protein backbone in a stable folded structure to get the SDF \&of solvent and look at the time\-averaged solvation shell. -\&It is also possible using this program to generate the SDF based on some arbitrarty -\&Cartesian coordinate. To do that, simply omit the preliminary trjconv steps. +\&It is also possible using this program to generate the SDF based on some arbitrary +\&Cartesian coordinate. To do that, simply omit the preliminary \fB trjconv\fR steps. \&USAGE: -\&1. Use make_ndx to create a group containing the atoms around which you want the SDF +\&1. Use \fB make_ndx\fR to create a group containing the atoms around which you want the SDF -\&2. trjconv \-s a.tpr \-f a.xtc \-o b.xtc \-center tric \-ur compact \-pbc none +\&2. \fB trjconv \-s a.tpr \-f a.xtc \-o b.xtc \-center tric \-ur compact \-pbc none\fR -\&3. trjconv \-s a.tpr \-f b.xtc \-o c.xtc \-fit rot+trans +\&3. \fB trjconv \-s a.tpr \-f b.xtc \-o c.xtc \-fit rot+trans\fR -\&4. run g_spatial on the xtc output of step 3. +\&4. run \fB g_spatial\fR on the \fB .xtc\fR output of step 3. -\&5. Load grid.cube into VMD and view as an isosurface. +\&5. Load \fB grid.cube\fR into VMD and view as an isosurface. -\&*** Systems such as micelles will require trjconv \-pbc cluster between steps 1 and 2 +\&\fB Note\fR that systems such as micelles will require \fB trjconv \-pbc cluster\fR between steps 1 and 2 -\&WARNINGS: +\&WARNINGS: \&The SDF will be generated for a cube that contains all bins that have some non\-zero occupancy. -\&However, the preparatory \-fit rot+trans option to trjconv implies that your system will be rotating +\&However, the preparatory \fB \-fit rot+trans\fR option to \fB trjconv\fR implies that your system will be rotating \&and translating in space (in order that the selected group does not). Therefore the values that are \&returned will only be valid for some region around your central group/coordinate that has full overlap \&with system volume throughout the entire translated/rotated system over the course of the trajectory. \&It is up to the user to ensure that this is the case. -\&BUGS: +\&BUGS: \&When the allocated memory is not large enough, a segmentation fault may occur. This is usually detected -\&and the program is halted prior to the fault while displaying a warning message suggesting the use of the \-nab +\&and the program is halted prior to the fault while displaying a warning message suggesting the use of the \fB \-nab\fR (Number of Additional Bins) \&option. However, the program does not detect all such events. If you encounter a segmentation fault, run it again -\&with an increased \-nab value. +\&with an increased \fB \-nab\fR value. -\&RISKY OPTIONS: +\&RISKY OPTIONS: \&To reduce the amount of space and time required, you can output only the coords -\&that are going to be used in the first and subsequent run through trjconv. -\&However, be sure to set the \-nab option to a sufficiently high value since -\&memory is allocated for cube bins based on the initial coords and the \-nab -\&(Number of Additional Bins) option value. +\&that are going to be used in the first and subsequent run through \fB trjconv\fR. +\&However, be sure to set the \fB \-nab\fR option to a sufficiently high value since +\&memory is allocated for cube bins based on the initial coordinates and the \fB \-nab\fR +\&option value. .SH FILES .BI "\-s" " topol.tpr" @@ -106,13 +106,13 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-[no]pbc" "no " Use periodic boundary conditions for computing distances .BI "\-[no]div" "yes " - Calculate and apply the divisor for bin occupancies based on atoms/minimal cube size. Set as TRUE for visualization and as FALSE (\-nodiv) to get accurate counts per frame + Calculate and apply the divisor for bin occupancies based on atoms/minimal cube size. Set as TRUE for visualization and as FALSE (\fB \-nodiv\fR) to get accurate counts per frame .BI "\-ign" " int" " \-1" Do not display this number of outer cubes (positive values may reduce boundary speckles; \-1 ensures outer surface is visible) diff -Nru gromacs-4.5.4/man/man1/g_spol.1 gromacs-4.5.5/man/man1/g_spol.1 --- gromacs-4.5.4/man/man1/g_spol.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_spol.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_spol 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_spol 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_spol - analyzes solvent dipole orientation and polarization around solutes -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_spol\fP .BI "\-f" " traj.xtc " @@ -24,7 +24,7 @@ .BI "\-dip" " real " .BI "\-bw" " real " .SH DESCRIPTION -\&g_spol analyzes dipoles around a solute; it is especially useful +\&\fB g_spol\fR analyzes dipoles around a solute; it is especially useful \&for polarizable water. A group of reference atoms, or a center \&of mass reference (option \fB \-com\fR) and a group of solvent \&atoms is required. The program splits the group of solvent atoms @@ -35,7 +35,7 @@ \&the inner product of the distance vector \&and the dipole of the solvent molecule is determined. \&For solvent molecules with net charge (ions), the net charge of the ion -\&is subtracted evenly at all atoms in the selection of each ion. +\&is subtracted evenly from all atoms in the selection of each ion. \&The average of these dipole components is printed. \&The same is done for the polarization, where the average dipole is \&subtracted from the instantaneous dipole. The magnitude of the average @@ -79,7 +79,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR diff -Nru gromacs-4.5.4/man/man1/g_tcaf.1 gromacs-4.5.5/man/man1/g_tcaf.1 --- gromacs-4.5.4/man/man1/g_tcaf.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_tcaf.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_tcaf 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_tcaf 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_tcaf - calculates viscosities of liquids -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_tcaf\fP .BI "\-f" " traj.trr " @@ -33,36 +33,36 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_tcaf computes tranverse current autocorrelations. -\&These are used to estimate the shear viscosity eta. -\&For details see: Palmer, JCP 49 (1994) pp 359\-366. +\&\fB g_tcaf\fR computes tranverse current autocorrelations. +\&These are used to estimate the shear viscosity, eta. +\&For details see: Palmer, Phys. Rev. E 49 (1994) pp 359\-366. \&Transverse currents are calculated using the -\&k\-vectors (1,0,0) and (2,0,0) each also in the y\- and z\-direction, +\&k\-vectors (1,0,0) and (2,0,0) each also in the \fI y\fR\- and \fI z\fR\-direction, \&(1,1,0) and (1,\-1,0) each also in the 2 other planes (these vectors \&are not independent) and (1,1,1) and the 3 other box diagonals (also \¬ independent). For each k\-vector the sine and cosine are used, in \&combination with the velocity in 2 perpendicular directions. This gives \&a total of 16*2*2=64 transverse currents. One autocorrelation is -\&calculated fitted for each k\-vector, which gives 16 tcaf's. Each of -\&these tcaf's is fitted to f(t) = exp(\-v)(cosh(Wv) + 1/W sinh(Wv)), -\&v = \-t/(2 tau), W = sqrt(1 \- 4 tau eta/rho k2), which gives 16 tau's -\&and eta's. The fit weights decay with time as exp(\-t/wt), the tcaf and +\&calculated fitted for each k\-vector, which gives 16 TCAF's. Each of +\&these TCAF's is fitted to f(t) = exp(\-v)(cosh(Wv) + 1/W sinh(Wv)), +\&v = \-t/(2 tau), W = sqrt(1 \- 4 tau eta/rho k2), which gives 16 values of tau +\&and eta. The fit weights decay with time as exp(\-t/wt), and the TCAF and \&fit are calculated up to time 5*wt. -\&The eta's should be fitted to 1 \- a eta(k) k2, from which +\&The eta values should be fitted to 1 \- a eta(k) k2, from which \&one can estimate the shear viscosity at k=0. \&When the box is cubic, one can use the option \fB \-oc\fR, which -\&averages the tcaf's over all k\-vectors with the same length. +\&averages the TCAF's over all k\-vectors with the same length. \&This results in more accurate tcaf's. -\&Both the cubic tcaf's and fits are written to \fB \-oc\fR +\&Both the cubic TCAF's and fits are written to \fB \-oc\fR \&The cubic eta estimates are also written to \fB \-ov\fR. -\&With option \fB \-mol\fR the transverse current is determined of -\&molecules instead of atoms. In this case the index group should +\&With option \fB \-mol\fR, the transverse current is determined of +\&molecules instead of atoms. In this case, the index group should \&consist of molecule numbers instead of atom numbers. @@ -71,7 +71,7 @@ \&infinite wavelength. -\&NOTE: make sure you write coordinates and velocities often enough. +\&\fB Note:\fR make sure you write coordinates and velocities often enough. \&The initial, non\-exponential, part of the autocorrelation function \&is very important for obtaining a good fit. .SH FILES @@ -131,7 +131,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -155,7 +155,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_traj.1 gromacs-4.5.5/man/man1/g_traj.1 --- gromacs-4.5.4/man/man1/g_traj.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_traj.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_traj 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_traj 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_traj - plots x, v and f of selected atoms/groups (and more) from a trajectory -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_traj\fP .BI "\-f" " traj.xtc " @@ -41,9 +41,10 @@ .BI "\-[no]len" "" .BI "\-[no]fp" "" .BI "\-bin" " real " +.BI "\-ctime" " real " .BI "\-scale" " real " .SH DESCRIPTION -\&g_traj plots coordinates, velocities, forces and/or the box. +\&\fB g_traj\fR plots coordinates, velocities, forces and/or the box. \&With \fB \-com\fR the coordinates, velocities and forces are \&calculated for the center of mass of each group. \&When \fB \-mol\fR is set, the numbers in the index file are @@ -64,15 +65,16 @@ \&Options \fB \-cv\fR and \fB \-cf\fR write the average velocities -\&and average forces as temperature factors to a pdb file with -\&the average coordinates. The temperature factors are scaled such -\&that the maximum is 10. The scaling can be changed with the option -\&\fB \-scale\fR. To get the velocities or forces of one +\&and average forces as temperature factors to a \fB .pdb\fR file with +\&the average coordinates or the coordinates at \fB \-ctime\fR. +\&The temperature factors are scaled such that the maximum is 10. +\&The scaling can be changed with the option \fB \-scale\fR. +\&To get the velocities or forces of one \&frame set both \fB \-b\fR and \fB \-e\fR to the time of \&desired frame. When averaging over frames you might need to use \&the \fB \-nojump\fR option to obtain the correct average coordinates. \&If you select either of these option the average force and velocity -\&for each atom are written to an xvg file as well +\&for each atom are written to an \fB .xvg\fR file as well \&(specified with \fB \-av\fR or \fB \-af\fR). @@ -167,7 +169,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -205,8 +207,11 @@ .BI "\-bin" " real" " 1 " Binwidth for velocity histogram (nm/ps) +.BI "\-ctime" " real" " \-1 " + Use frame at this time for x in \fB \-cv\fR and \fB \-cf\fR instead of the average x + .BI "\-scale" " real" " 0 " - Scale factor for pdb output, 0 is autoscale + Scale factor for \fB .pdb\fR output, 0 is autoscale .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_tune_pme.1 gromacs-4.5.5/man/man1/g_tune_pme.1 --- gromacs-4.5.4/man/man1/g_tune_pme.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_tune_pme.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_tune_pme 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_tune_pme 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_tune_pme - time mdrun as a function of PME nodes to optimize settings -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_tune_pme\fP .BI "\-p" " perf.out " @@ -65,6 +65,7 @@ .BI "\-max" " real " .BI "\-min" " real " .BI "\-npme" " enum " +.BI "\-fix" " int " .BI "\-upfac" " real " .BI "\-downfac" " real " .BI "\-ntpr" " int " @@ -96,12 +97,12 @@ .BI "\-[no]ionize" "" .SH DESCRIPTION \&For a given number \fB \-np\fR or \fB \-nt\fR of processors/threads, this program systematically -\× mdrun with various numbers of PME\-only nodes and determines +\× \fB mdrun\fR with various numbers of PME\-only nodes and determines \&which setting is fastest. It will also test whether performance can \&be enhanced by shifting load from the reciprocal to the real space \&part of the Ewald sum. -\&Simply pass your \fB .tpr\fR file to g_tune_pme together with other options -\&for mdrun as needed. +\&Simply pass your \fB .tpr\fR file to \fB g_tune_pme\fR together with other options +\&for \fB mdrun\fR as needed. \&Which executables are used can be set in the environment variables @@ -109,23 +110,25 @@ \&will be used as defaults. Note that for certain MPI frameworks you \&need to provide a machine\- or hostfile. This can also be passed \&via the MPIRUN variable, e.g. -\&'export MPIRUN="/usr/local/mpirun \-machinefile hosts"' -\&Please call g_tune_pme with the normal options you would pass to -\&mdrun and add \fB \-np\fR for the number of processors to perform the +\&\fB export MPIRUN="/usr/local/mpirun \-machinefile hosts"\fR + + +\&Please call \fB g_tune_pme\fR with the normal options you would pass to +\&\fB mdrun\fR and add \fB \-np\fR for the number of processors to perform the \&tests on, or \fB \-nt\fR for the number of threads. You can also add \fB \-r\fR \&to repeat each test several times to get better statistics. -\&g_tune_pme can test various real space / reciprocal space workloads +\&\fB g_tune_pme\fR can test various real space / reciprocal space workloads \&for you. With \fB \-ntpr\fR you control how many extra \fB .tpr\fR files will be \&written with enlarged cutoffs and smaller fourier grids respectively. -\&Typically, the first test (no. 0) will be with the settings from the input -\&\fB .tpr\fR file; the last test (no. \fB ntpr\fR) will have cutoffs multiplied +\&Typically, the first test (number 0) will be with the settings from the input +\&\fB .tpr\fR file; the last test (number \fB ntpr\fR) will have cutoffs multiplied \&by (and at the same time fourier grid dimensions divided by) the scaling -\&factor \fB \-fac\fR (default 1.2). The remaining \fB .tpr\fR files will have equally -\&spaced values inbetween these extremes. Note that you can set \fB \-ntpr\fR to 1 +\&factor \fB \-fac\fR (default 1.2). The remaining \fB .tpr\fR files will have about +\&equally\-spaced values in between these extremes. \fB Note\fR that you can set \fB \-ntpr\fR to 1 \&if you just want to find the optimal number of PME\-only nodes; in that case \&your input \fB .tpr\fR file will remain unchanged. @@ -136,15 +139,15 @@ \&are by default reset after 100 steps. For large systems \&(1M atoms) you may have to set \fB \-resetstep\fR to a higher value. \&From the 'DD' load imbalance entries in the md.log output file you -\&can tell after how many steps the load is sufficiently balanced. +\&can tell after how many steps the load is sufficiently balanced. Example call: -Example call: \fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR +\fB g_tune_pme \-np 64 \-s protein.tpr \-launch\fR -\&After calling mdrun several times, detailed performance information -\&is available in the output file perf.out. -\&Note that during the benchmarks a couple of temporary files are written -\&(options \-b*), these will be automatically deleted after each test. +\&After calling \fB mdrun\fR several times, detailed performance information +\&is available in the output file \fB perf.out.\fR +\&\fB Note\fR that during the benchmarks, a couple of temporary files are written +\&(options \fB \-b\fR*), these will be automatically deleted after each test. \&If you want the simulation to be started automatically with the @@ -365,7 +368,7 @@ Number of nodes to run the tests on (must be 2 for separate PME nodes) .BI "\-npstring" " enum" " \-np" - Specify the number of processors to $MPIRUN using this string: \fB \-np\fR, \fB \-n\fR or \fB none\fR + Specify the number of processors to \fB $MPIRUN\fR using this string: \fB \-np\fR, \fB \-n\fR or \fB none\fR .BI "\-nt" " int" " 1" Number of threads to run the tests on (turns MPI & mpirun off) @@ -380,7 +383,10 @@ Min fraction of PME nodes to test with .BI "\-npme" " enum" " auto" - Benchmark all possible values for \-npme or just the subset that is expected to perform well: \fB auto\fR, \fB all\fR or \fB subset\fR + Benchmark all possible values for \fB \-npme\fR or just the subset that is expected to perform well: \fB auto\fR, \fB all\fR or \fB subset\fR + +.BI "\-fix" " int" " \-2" + If = \-1, do not vary the number of PME\-only nodes, instead use this fixed value and only vary rcoulomb and the PME grid spacing. .BI "\-upfac" " real" " 1.2 " Upper limit for rcoulomb scaling factor (Note that rcoulomb upscaling results in fourier grid downscaling) @@ -389,19 +395,19 @@ Lower limit for rcoulomb scaling factor .BI "\-ntpr" " int" " 0" - Number of tpr files to benchmark. Create these many files with scaling factors ranging from 1.0 to fac. If 1, automatically choose the number of tpr files to test + Number of \fB .tpr\fR files to benchmark. Create this many files with scaling factors ranging from 1.0 to fac. If 1, automatically choose the number of \fB .tpr\fR files to test .BI "\-four" " real" " 0 " - Use this fourierspacing value instead of the grid found in the tpr input file. (Spacing applies to a scaling factor of 1.0 if multiple tpr files are written) + Use this fourierspacing value instead of the grid found in the \fB .tpr\fR input file. (Spacing applies to a scaling factor of 1.0 if multiple \fB .tpr\fR files are written) .BI "\-steps" " step" " 1000" - Take timings for these many steps in the benchmark runs + Take timings for this many steps in the benchmark runs .BI "\-resetstep" " int" " 100" - Let dlb equilibrate these many steps before timings are taken (reset cycle counters after these many steps) + Let dlb equilibrate this many steps before timings are taken (reset cycle counters after this many steps) .BI "\-simsteps" " step" " \-1" - If non\-negative, perform these many steps in the real run (overwrite nsteps from tpr, add cpt steps) + If non\-negative, perform this many steps in the real run (overwrites nsteps from \fB .tpr\fR, add \fB .cpt\fR steps) .BI "\-[no]launch" "no " Lauch the real simulation after optimization @@ -467,7 +473,7 @@ Seed for replica exchange, \-1 is generate a seed .BI "\-[no]ionize" "no " - Do a simulation including the effect of an X\-Ray bombardment on your system + Do a simulation including the effect of an X\-ray bombardment on your system .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_vanhove.1 gromacs-4.5.5/man/man1/g_vanhove.1 --- gromacs-4.5.4/man/man1/g_vanhove.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_vanhove.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_vanhove 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_vanhove 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_vanhove - calculates Van Hove displacement functions -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_vanhove\fP .BI "\-f" " traj.xtc " @@ -30,10 +30,10 @@ .BI "\-rt" " real " .BI "\-ft" " int " .SH DESCRIPTION -\&g_vanhove computes the Van Hove correlation function. +\&\fB g_vanhove\fR computes the Van Hove correlation function. \&The Van Hove G(r,t) is the probability that a particle that is at r0 \&at time zero can be found at position r0+r at time t. -\&g_vanhove determines G not for a vector r, but for the length of r. +\&\fB g_vanhove\fR determines G not for a vector r, but for the length of r. \&Thus it gives the probability that a particle moves a distance of r \&in time t. \&Jumps across the periodic boundaries are removed. @@ -112,7 +112,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -127,7 +127,7 @@ Maximum r in the matrix (nm) .BI "\-rbin" " real" " 0.01 " - Binwidth in the matrix and for \-or (nm) + Binwidth in the matrix and for \fB \-or\fR (nm) .BI "\-mmax" " real" " 0 " Maximum density in the matrix, 0 is calculate (1/nm) @@ -136,16 +136,16 @@ Number of levels in the matrix .BI "\-nr" " int" " 1" - Number of curves for the \-or output + Number of curves for the \fB \-or\fR output .BI "\-fr" " int" " 0" - Frame spacing for the \-or output + Frame spacing for the \fB \-or\fR output .BI "\-rt" " real" " 0 " - Integration limit for the \-ot output (nm) + Integration limit for the \fB \-ot\fR output (nm) .BI "\-ft" " int" " 0" - Number of frames in the \-ot output, 0 is plot all + Number of frames in the \fB \-ot\fR output, 0 is plot all .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_velacc.1 gromacs-4.5.5/man/man1/g_velacc.1 --- gromacs-4.5.4/man/man1/g_velacc.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_velacc.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_velacc 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_velacc 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_velacc - calculates velocity autocorrelation functions -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_velacc\fP .BI "\-f" " traj.trr " @@ -27,7 +27,7 @@ .BI "\-beginfit" " real " .BI "\-endfit" " real " .SH DESCRIPTION -\&g_velacc computes the velocity autocorrelation function. +\&\fB g_velacc\fR computes the velocity autocorrelation function. \&When the \fB \-m\fR option is used, the momentum autocorrelation \&function is calculated. @@ -72,7 +72,7 @@ Only use frame when t MOD dt = first time (ps) .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -93,7 +93,7 @@ Order of Legendre polynomial for ACF (0 indicates none): \fB 0\fR, \fB 1\fR, \fB 2\fR or \fB 3\fR .BI "\-fitfn" " enum" " none" - Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR or \fB exp9\fR + Fit function: \fB none\fR, \fB exp\fR, \fB aexp\fR, \fB exp_exp\fR, \fB vac\fR, \fB exp5\fR, \fB exp7\fR, \fB exp9\fR or \fB erffit\fR .BI "\-ncskip" " int" " 0" Skip N points in the output file of correlation functions diff -Nru gromacs-4.5.4/man/man1/g_wham.1 gromacs-4.5.5/man/man1/g_wham.1 --- gromacs-4.5.4/man/man1/g_wham.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_wham.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_wham 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_wham 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_wham - weighted histogram analysis after umbrella sampling -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_wham\fP .BI "\-ix" " pullx\-files.dat " @@ -11,10 +11,11 @@ .BI "\-ip" " pdo\-files.dat " .BI "\-o" " profile.xvg " .BI "\-hist" " histo.xvg " +.BI "\-oiact" " iact.xvg " +.BI "\-iiact" " iact\-in.dat " .BI "\-bsres" " bsResult.xvg " .BI "\-bsprof" " bsProfs.xvg " .BI "\-tab" " umb\-pot.dat " -.BI "\-wcorr" " cycl\-corr.xvg " .BI "\-[no]h" "" .BI "\-[no]version" "" .BI "\-nice" " int " @@ -34,14 +35,15 @@ .BI "\-[no]log" "" .BI "\-unit" " enum " .BI "\-zprof0" " real " -.BI "\-cycl" " enum " -.BI "\-alpha" " real " -.BI "\-[no]flip" "" -.BI "\-[no]hist\-eq" "" +.BI "\-[no]cycl" "" +.BI "\-[no]sym" "" +.BI "\-[no]ac" "" +.BI "\-acsig" " real " +.BI "\-ac\-trestart" " real " .BI "\-nBootstrap" " int " -.BI "\-bs\-dt" " real " +.BI "\-bs\-method" " enum " +.BI "\-bs\-tau" " real " .BI "\-bs\-seed" " int " -.BI "\-[no]histbs" "" .BI "\-histbs\-block" " int " .BI "\-[no]vbs" "" .SH DESCRIPTION @@ -51,24 +53,24 @@ \&compute a potential of mean force (PMF). -\&At present, three input modes are supported: +\&At present, three input modes are supported. \&\fB *\fR With option \fB \-it\fR, the user provides a file which contains the -\& filenames of the umbrella simulation run\-input files (tpr files), -\& AND, with option \-ix, a file which contains filenames of -\& the pullx mdrun output files. The tpr and pullx files must -\& be in corresponding order, i.e. the first tpr created the -\& first pullx, etc. +\& file names of the umbrella simulation run\-input files (\fB .tpr\fR files), +\& AND, with option \fB \-ix\fR, a file which contains file names of +\& the pullx \fB mdrun\fR output files. The \fB .tpr\fR and pullx files must +\& be in corresponding order, i.e. the first \fB .tpr\fR created the +\& first pullx, etc. \&\fB *\fR Same as the previous input mode, except that the the user -\& provides the pull force ouput file names (pullf.xvg) with option \-if. -\& From the pull force the position in the ubrella potential is -\& computed. This does not work with tabulated umbrella potentials. -\&\fB *\fR With option \fB \-ip\fR, the user provides filenames of (gzipped) pdo files, i.e. -\& the gromacs 3.3 umbrella output files. If you have some unusual -\& reaction coordinate you may also generate your own pdo files and -\& feed them with the \-ip option into to g_wham. The pdo file header -\& must be similar to the folowing: +\& provides the pull force output file names (\fB pullf.xvg\fR) with option \fB \-if\fR. +\& From the pull force the position in the umbrella potential is +\& computed. This does not work with tabulated umbrella potentials. +\fB *\fR With option \fB \-ip\fR, the user provides file names of (gzipped) \fB .pdo\fR files, i.e. +\& the GROMACS 3.3 umbrella output files. If you have some unusual reaction coordinate you may also generate your own \fB .pdo\fR files and +\& feed them with the \fB \-ip\fR option into to \fB g_wham\fR. The \fB .pdo\fR file header +\& must be similar to the following: + \&\fB UMBRELLA 3.0 @@ -86,95 +88,134 @@ \&\fR -\& Nr of pull groups, umbrella positions, force constants, and names -\& may (of course) differ. Following the header, a time column and -\& a data columns for each pull group follow (i.e. the displacement -\& with respect to the umbrella center). Up to four pull groups are possible -\& at present. + +\&The number of pull groups, umbrella positions, force constants, and names +\&may (of course) differ. Following the header, a time column and +\&a data column for each pull group follows (i.e. the displacement +\&with respect to the umbrella center). Up to four pull groups are possible +\&per \fB .pdo\fR file at present. \&By default, the output files are \& \fB \-o\fR PMF output file -\& \fB \-hist\fR histograms output file +\& \fB \-hist\fR Histograms output file + +\&Always check whether the histograms sufficiently overlap. \&The umbrella potential is assumed to be harmonic and the force constants are -\&read from the tpr or pdo files. If a non\-harmonic umbrella force was applied -\&a tabulated potential can be provied with \-tab. +\&read from the \fB .tpr\fR or \fB .pdo\fR files. If a non\-harmonic umbrella force was applied +\&a tabulated potential can be provided with \fB \-tab\fR. \&WHAM OPTIONS +\-\-\-\-\-\-\-\-\-\-\-\- - -\& \fB \-bins\fR Nr of bins used in analysis +\& \fB \-bins\fR Number of bins used in analysis \& \fB \-temp\fR Temperature in the simulations \& \fB \-tol\fR Stop iteration if profile (probability) changed less than tolerance -\& \fB \-auto\fR Automatic determination of boudndaries +\& \fB \-auto\fR Automatic determination of boundaries \& \fB \-min,\-max\fR Boundaries of the profile -\&The data points which are used -\&to compute the profile can be restricted with options \-b, \-e, and \-dt. -\&Play particularly with \-b to ensure sufficient equilibration in each -\&umbrella window! - - -\&With \-log (default) the profile is written in energy units, otherwise (\-nolog) as -\&probability. The unit can be specified with \-unit. With energy output, -\&the energy in the first bin is defined to be zero. If you want the free energy at a different -\&position to be zero, choose with \-zprof0 (useful with bootstrapping, see below). - - -\&For cyclic (or periodic) reaction coordinates (dihedral angle, channel PMF -\&without osmotic gradient), \-cycl is useful. - -\&\fB \-cycl yes\fR min and max are assumed to -\&be neighboring points and histogram points outside min and max are mapped into -\&the interval [min,max] (compare histogram output). - -\&\fB \-cycl weighted\fR First, a non\-cyclic profile is computed. Subsequently, -\&periodicity is enforced by adding corrections dG(i) between neighboring bins -\&i and i+1. The correction is chosen proportional to 1/[n(i)*n(i+1)]alpha, where -\&n(i) denotes the total nr of data points in bin i as collected from all histograms. -\&alpha is defined with \-alpha. The corrections are written to the file defined by \-wcorr. -\& (Compare Hub and de Groot, PNAS 105:1198 (2008)) +\&The data points that are used to compute the profile +\&can be restricted with options \fB \-b\fR, \fB \-e\fR, and \fB \-dt\fR. +\&Adjust \fB \-b\fR to ensure sufficient equilibration in each +\&umbrella window. + + +\&With \fB \-log\fR (default) the profile is written in energy units, otherwise +\&(with \fB \-nolog\fR) as probability. The unit can be specified with \fB \-unit\fR. +\&With energy output, the energy in the first bin is defined to be zero. +\&If you want the free energy at a different +\&position to be zero, set \fB \-zprof0\fR (useful with bootstrapping, see below). + + +\&For cyclic or periodic reaction coordinates (dihedral angle, channel PMF +\&without osmotic gradient), the option \fB \-cycl\fR is useful. \fB g_wham\fR will make use of the +\&periodicity of the system and generate a periodic PMF. The first and the last bin of the +\&reaction coordinate will assumed be be neighbors. + + +\&Option \fB \-sym\fR symmetrizes the profile around z=0 before output, +\&which may be useful for, e.g. membranes. + + +\&AUTOCORRELATIONS +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- + +\&With \fB \-ac\fR, \fB g_wham\fR estimates the integrated autocorrelation +\&time (IACT) tau for each umbrella window and weights the respective +\&window with 1/[1+2*tau/dt]. The IACTs are written +\&to the file defined with \fB \-oiact\fR. In verbose mode, all +\&autocorrelation functions (ACFs) are written to \fB hist_autocorr.xvg\fR. +\&Because the IACTs can be severely underestimated in case of limited +\&sampling, option \fB \-acsig\fR allows to smooth the IACTs along the +\&reaction coordinate with a Gaussian (sigma provided with \fB \-acsig\fR, +\&see output in \fB iact.xvg\fR). Note that the IACTs are estimated by simple +\&integration of the ACFs while the ACFs are larger 0.05. +\&If you prefer to compute the IACTs by a more sophisticated (but possibly +\&less robust) method such as fitting to a double exponential, you can +\&compute the IACTs with \fB g_analyze\fR and provide them to \fB g_wham\fR with the file +\&\fB iact\-in.dat\fR (option \fB \-iiact\fR), which should contain one line per +\&input file (\fB .pdo\fR or pullx/f file) and one column per pull group in the respective file. \&ERROR ANALYSIS +\-\-\-\-\-\-\-\-\-\-\-\-\-\- \&Statistical errors may be estimated with bootstrap analysis. Use it with care, -\&otherwise the statistical error may be substantially undererstimated !! - -\&\fB \-nBootstrap\fR defines the nr of bootstraps. Two bootstrapping modes are supported. - -\&\fB \-histbs\fR Complete histograms are considered as independent data points (default). For each -\&bootstrap, N histograms are randomly chosen from the N given histograms (allowing duplication). -\&To avoid gaps without data along the reaction coordinate blocks of histograms (\-histbs\-block) -\&may be defined. In that case, the given histograms are divided into blocks and -\&only histograms within each block are mixed. Note that the histograms -\&within each block must be representative for all possible histograms, otherwise the -\&statistical error is undererstimated! - -\&\fB \-nohistbs\fR The given histograms are used to generate new random histograms, -\&such that the generated data points are distributed according the given histograms. The number -\&of points generated for each bootstrap histogram can be controlled with \-bs\-dt. -\&Note that one data point should be generated for each *independent* point in the given -\&histograms. With the long autocorrelations in MD simulations, this procedure may -\&easily understimate the error! - -\&Bootstrapping output: - -\&\fB \-bsres\fR Average profile and standard deviations - -\&\fB \-bsprof\fR All bootstrapping profiles - -\&With \fB \-vbs\fR (verbose bootstrapping), the histograms of each bootstrap are written, and, -\&with \fB \-nohistBS\fR, the cummulants of the histogram. +\&otherwise the statistical error may be substantially underestimated. +\&More background and examples for the bootstrap technique can be found in +\&Hub, de Groot and Van der Spoel, JCTC (2010) 6: 3713\-3720. + +\&\fB \-nBootstrap\fR defines the number of bootstraps (use, e.g., 100). +\&Four bootstrapping methods are supported and +\&selected with \fB \-bs\-method\fR. + +\& (1) \fB b\-hist\fR Default: complete histograms are considered as independent +\&data points, and the bootstrap is carried out by assigning random weights to the +\&histograms ("Bayesian bootstrap"). Note that each point along the reaction coordinate +\&must be covered by multiple independent histograms (e.g. 10 histograms), otherwise the +\&statistical error is underestimated. + +\& (2) \fB hist\fR Complete histograms are considered as independent data points. +\&For each bootstrap, N histograms are randomly chosen from the N given histograms +\&(allowing duplication, i.e. sampling with replacement). +\&To avoid gaps without data along the reaction coordinate blocks of histograms +\&(\fB \-histbs\-block\fR) may be defined. In that case, the given histograms are +\÷d into blocks and only histograms within each block are mixed. Note that +\&the histograms within each block must be representative for all possible histograms, +\&otherwise the statistical error is underestimated. + +\& (3) \fB traj\fR The given histograms are used to generate new random trajectories, +\&such that the generated data points are distributed according the given histograms +\&and properly autocorrelated. The autocorrelation time (ACT) for each window must be +\&known, so use \fB \-ac\fR or provide the ACT with \fB \-iiact\fR. If the ACT of all +\&windows are identical (and known), you can also provide them with \fB \-bs\-tau\fR. +\&Note that this method may severely underestimate the error in case of limited sampling, +\&that is if individual histograms do not represent the complete phase space at +\&the respective positions. + +\& (4) \fB traj\-gauss\fR The same as method \fB traj\fR, but the trajectories are +\¬ bootstrapped from the umbrella histograms but from Gaussians with the average +\&and width of the umbrella histograms. That method yields similar error estimates +\&like method \fB traj\fR. + +Bootstrapping output: + +\& \fB \-bsres\fR Average profile and standard deviations + +\& \fB \-bsprof\fR All bootstrapping profiles + +\&With \fB \-vbs\fR (verbose bootstrapping), the histograms of each bootstrap are written, +\&and, with bootstrap method \fB traj\fR, the cumulative distribution functions of +\&the histograms. .SH FILES .BI "\-ix" " pullx\-files.dat" .B Input, Opt. @@ -200,6 +241,14 @@ .B Output xvgr/xmgr file +.BI "\-oiact" " iact.xvg" +.B Output, Opt. + xvgr/xmgr file + +.BI "\-iiact" " iact\-in.dat" +.B Input, Opt. + Generic data file + .BI "\-bsres" " bsResult.xvg" .B Output, Opt. xvgr/xmgr file @@ -212,10 +261,6 @@ .B Input, Opt. Generic data file -.BI "\-wcorr" " cycl\-corr.xvg" -.B Input, Opt. - xvgr/xmgr file - .SH OTHER OPTIONS .BI "\-[no]h" "no " Print help info and quit @@ -236,7 +281,7 @@ Maximum coordinate in profile .BI "\-[no]auto" "yes " - determine min and max automatically + Determine min and max automatically .BI "\-bins" " int" " 200" Number of bins in profile @@ -248,13 +293,13 @@ Tolerance .BI "\-[no]v" "no " - verbose mode + Verbose mode .BI "\-b" " real" " 50 " - first time to analyse (ps) + First time to analyse (ps) .BI "\-e" " real" " 1e+20 " - last time to analyse (ps) + Last time to analyse (ps) .BI "\-dt" " real" " 0 " Analyse only every dt ps @@ -263,46 +308,49 @@ Write histograms and exit .BI "\-[no]boundsonly" "no " - Determine min and max and exit (with \-auto) + Determine min and max and exit (with \fB \-auto\fR) .BI "\-[no]log" "yes " Calculate the log of the profile before printing .BI "\-unit" " enum" " kJ" - energy unit in case of log output: \fB kJ\fR, \fB kCal\fR or \fB kT\fR + Energy unit in case of log output: \fB kJ\fR, \fB kCal\fR or \fB kT\fR .BI "\-zprof0" " real" " 0 " - Define profile to 0.0 at this position (with \-log) + Define profile to 0.0 at this position (with \fB \-log\fR) + +.BI "\-[no]cycl" "no " + Create cyclic/periodic profile. Assumes min and max are the same point. -.BI "\-cycl" " enum" " no" - Create cyclic/periodic profile. Assumes min and max are the same point.: \fB no\fR, \fB yes\fR or \fB weighted\fR +.BI "\-[no]sym" "no " + Symmetrize profile around z=0 -.BI "\-alpha" " real" " 2 " - for '\-cycl weighted', set parameter alpha +.BI "\-[no]ac" "no " + Calculate integrated autocorrelation times and use in wham -.BI "\-[no]flip" "no " - Combine halves of profile (not supported) +.BI "\-acsig" " real" " 0 " + Smooth autocorrelation times along reaction coordinate with Gaussian of this sigma -.BI "\-[no]hist\-eq" "no " - Enforce equal weight for all histograms. (Non\-Weighed\-HAM) +.BI "\-ac\-trestart" " real" " 1 " + When computing autocorrelation functions, restart computing every .. (ps) .BI "\-nBootstrap" " int" " 0" - nr of bootstraps to estimate statistical uncertainty + nr of bootstraps to estimate statistical uncertainty (e.g., 200) -.BI "\-bs\-dt" " real" " 0 " - timestep for synthetic bootstrap histograms (ps). Ensure independent data points! +.BI "\-bs\-method" " enum" " b\-hist" + Bootstrap method: \fB b\-hist\fR, \fB hist\fR, \fB traj\fR or \fB traj\-gauss\fR -.BI "\-bs\-seed" " int" " \-1" - seed for bootstrapping. (\-1 = use time) +.BI "\-bs\-tau" " real" " 0 " + Autocorrelation time (ACT) assumed for all histograms. Use option \fB \-ac\fR if ACT is unknown. -.BI "\-[no]histbs" "yes " - In bootstrapping, consider complete histograms as one data point. Accounts better for long autocorrelations. +.BI "\-bs\-seed" " int" " \-1" + Seed for bootstrapping. (\-1 = use time) .BI "\-histbs\-block" " int" " 8" - when mixin histograms only mix within blocks of \-histBS_block. + When mixing histograms only mix within blocks of \fB \-histbs\-block\fR. .BI "\-[no]vbs" "no " - verbose bootstrapping. Print the cummulants and a histogram file for each bootstrap. + Verbose bootstrapping. Print the CDFs and a histogram file for each bootstrap. .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_wheel.1 gromacs-4.5.5/man/man1/g_wheel.1 --- gromacs-4.5.4/man/man1/g_wheel.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_wheel.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_wheel 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_wheel 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_wheel - plots helical wheels -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_wheel\fP .BI "\-f" " nnnice.dat " @@ -15,9 +15,9 @@ .BI "\-T" " string " .BI "\-[no]nn" "" .SH DESCRIPTION -\&wheel plots a helical wheel representation of your sequence. -\&The input sequence is in the .dat file where the first line contains -\&the number of residues and each consecutive line contains a residuename. +\&\fB g_wheel\fR plots a helical wheel representation of your sequence. +\&The input sequence is in the \fB .dat\fR file where the first line contains +\&the number of residues and each consecutive line contains a residue name. .SH FILES .BI "\-f" " nnnice.dat" .B Input diff -Nru gromacs-4.5.4/man/man1/g_x2top.1 gromacs-4.5.5/man/man1/g_x2top.1 --- gromacs-4.5.4/man/man1/g_x2top.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_x2top.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_x2top 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_x2top 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_x2top - generates a primitive topology from coordinates -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_x2top\fP .BI "\-f" " conf.gro " @@ -27,11 +27,11 @@ .BI "\-kt" " real " .BI "\-kp" " real " .SH DESCRIPTION -\&x2top generates a primitive topology from a coordinate file. +\&\fB g_x2top\fR generates a primitive topology from a coordinate file. \&The program assumes all hydrogens are present when defining \&the hybridization from the atom name and the number of bonds. -\&The program can also make an rtp entry, which you can then add -\&to the rtp database. +\&The program can also make an \fB .rtp\fR entry, which you can then add +\&to the \fB .rtp\fR database. \&When \fB \-param\fR is set, equilibrium distances and angles @@ -49,11 +49,11 @@ \&The corresponding data files can be found in the library directory -\&with name atomname2type.n2t. Check chapter 5 of the manual for more -\&information about file formats. By default the forcefield selection +\&with name \fB atomname2type.n2t\fR. Check Chapter 5 of the manual for more +\&information about file formats. By default, the force field selection \&is interactive, but you can use the \fB \-ff\fR option to specify \&one of the short names above on the command line instead. In that -\&case pdb2gmx just looks for the corresponding file. +\&case \fB g_x2top\fR just looks for the corresponding file. .SH FILES @@ -107,7 +107,7 @@ Use periodic boundary conditions. .BI "\-[no]pdbq" "no " - Use the B\-factor supplied in a pdb file for the atomic charges + Use the B\-factor supplied in a \fB .pdb\fR file for the atomic charges .BI "\-[no]param" "yes " Print parameters in the output @@ -131,7 +131,7 @@ \- No improper dihedrals are generated -\- The atoms to atomtype translation table is incomplete (atomname2type.n2t files in the data directory). Please extend it and send the results back to the GROMACS crew. +\- The atoms to atomtype translation table is incomplete (\fB atomname2type.n2t\fR file in the data directory). Please extend it and send the results back to the GROMACS crew. .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/g_xrama.1 gromacs-4.5.5/man/man1/g_xrama.1 --- gromacs-4.5.4/man/man1/g_xrama.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/g_xrama.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH g_xrama 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH g_xrama 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME g_xrama - shows animated Ramachandran plots -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3g_xrama\fP .BI "\-f" " traj.xtc " @@ -14,15 +14,15 @@ .BI "\-e" " time " .BI "\-dt" " time " .SH DESCRIPTION -\&xrama shows a Ramachandran movie, that is, it shows +\&\fB g_xrama\fR shows a Ramachandran movie, that is, it shows \&the Phi/Psi angles as a function of time in an X\-Window. -Static Phi/Psi plots for printing can be made with g_rama. +Static Phi/Psi plots for printing can be made with \fB g_rama\fR. \&Some of the more common X command line options can be used: -\&\-bg, \-fg change colors, \-font fontname, changes the font. +\&\fB \-bg\fR, \fB \-fg\fR change colors, \fB \-font fontname\fR, changes the font. .SH FILES .BI "\-f" " traj.xtc" .B Input diff -Nru gromacs-4.5.4/man/man1/make_edi.1 gromacs-4.5.5/man/man1/make_edi.1 --- gromacs-4.5.4/man/man1/make_edi.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/make_edi.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH make_edi 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH make_edi 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME make_edi - generate input files for essential dynamics sampling -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3make_edi\fP .BI "\-f" " eigenvec.trr " @@ -19,28 +19,29 @@ .BI "\-mon" " string " .BI "\-linfix" " string " .BI "\-linacc" " string " -.BI "\-flood" " string " .BI "\-radfix" " string " .BI "\-radacc" " string " .BI "\-radcon" " string " +.BI "\-flood" " string " .BI "\-outfrq" " int " .BI "\-slope" " real " +.BI "\-linstep" " string " +.BI "\-accdir" " string " +.BI "\-radstep" " real " .BI "\-maxedsteps" " int " +.BI "\-eqsteps" " int " .BI "\-deltaF0" " real " .BI "\-deltaF" " real " .BI "\-tau" " real " -.BI "\-eqsteps" " int " .BI "\-Eflnull" " real " .BI "\-T" " real " .BI "\-alpha" " real " -.BI "\-linstep" " string " -.BI "\-accdir" " string " -.BI "\-radstep" " real " .BI "\-[no]restrain" "" .BI "\-[no]hessian" "" .BI "\-[no]harmonic" "" +.BI "\-constF" " string " .SH DESCRIPTION -\&\fB make_edi\fR generates an essential dynamics (ED) sampling input file to be used with mdrun +\&\fB make_edi\fR generates an essential dynamics (ED) sampling input file to be used with \fB mdrun\fR \&based on eigenvectors of a covariance matrix (\fB g_covar\fR) or from a \&normal modes anaysis (\fB g_nmeig\fR). \&ED sampling can be used to manipulate the position along collective coordinates @@ -67,7 +68,7 @@ \&B.L. de Groot, A.Amadei, R.M. Scheek, N.A.J. van Nuland and H.J.C. Berendsen; \&An extended sampling of the configurational space of HPr from E. coli -\&PROTEINS: Struct. Funct. Gen. 26: 314\-322 (1996) +\&Proteins: Struct. Funct. Gen. 26: 314\-322 (1996) \& You will be prompted for one or more index groups that correspond to the eigenvectors, @@ -89,7 +90,7 @@ \&\fB \-radacc\fR: perform acceptance radius expansion along selected eigenvectors. \&(steps in the desired direction will be accepted, others will be rejected). -\&Note: by default the starting MD structure will be taken as origin of the first +\&\fB Note:\fR by default the starting MD structure will be taken as origin of the first \&expansion cycle for radius expansion. If \fB \-ori\fR is specified, you will be able \&to read in a structure file that defines an external origin. @@ -101,7 +102,7 @@ \&NOTE: each eigenvector can be selected only once. -\&\fB \-outfrq\fR: frequency (in steps) of writing out projections etc. to .edo file +\&\fB \-outfrq\fR: frequency (in steps) of writing out projections etc. to \fB .edo\fR file \&\fB \-slope\fR: minimal slope in acceptance radius expansion. A new expansion @@ -116,21 +117,21 @@ \&Note on the parallel implementation: since ED sampling is a 'global' thing \&(collective coordinates etc.), at least on the 'protein' side, ED sampling \&is not very parallel\-friendly from an implentation point of view. Because -\¶llel ED requires much extra communication, expect the performance to be +\¶llel ED requires some extra communication, expect the performance to be \&lower as in a free MD simulation, especially on a large number of nodes. -\&All output of mdrun (specify with \-eo) is written to a .edo file. In the output +\&All output of \fB mdrun\fR (specify with \fB \-eo\fR) is written to a .edo file. In the output \&file, per OUTFRQ step the following information is present: -\&* the step number +\&\fB *\fR the step number -\&* the number of the ED dataset. (Note that you can impose multiple ED constraints in -\&a single simulation \- on different molecules e.g. \- if several .edi files were concatenated -\&first. The constraints are applied in the order they appear in the .edi file.) +\&\fB *\fR the number of the ED dataset. (\fB Note\fR that you can impose multiple ED constraints in +\&a single simulation (on different molecules) if several \fB .edi\fR files were concatenated +\&first. The constraints are applied in the order they appear in the \fB .edi\fR file.) -\&* RMSD (for atoms involved in fitting prior to calculating the ED constraints) +\&\fB *\fR RMSD (for atoms involved in fitting prior to calculating the ED constraints) \&* projections of the positions onto selected eigenvectors @@ -142,34 +143,34 @@ \&FLOODING: -\&with \-flood you can specify which eigenvectors are used to compute a flooding potential, +\&with \fB \-flood\fR, you can specify which eigenvectors are used to compute a flooding potential, \&which will lead to extra forces expelling the structure out of the region described \&by the covariance matrix. If you switch \-restrain the potential is inverted and the structure \&is kept in that region. \& -\&The origin is normally the average structure stored in the eigvec.trr file. -\&It can be changed with \-ori to an arbitrary position in configurational space. -\&With \-tau, \-deltaF0 and \-Eflnull you control the flooding behaviour. +\&The origin is normally the average structure stored in the \fB eigvec.trr\fR file. +\&It can be changed with \fB \-ori\fR to an arbitrary position in configurational space. +\&With \fB \-tau\fR, \fB \-deltaF0\fR, and \fB \-Eflnull\fR you control the flooding behaviour. \&Efl is the flooding strength, it is updated according to the rule of adaptive flooding. \&Tau is the time constant of adaptive flooding, high tau means slow adaption (i.e. growth). \&DeltaF0 is the flooding strength you want to reach after tau ps of simulation. -\&To use constant Efl set \-tau to zero. +\&To use constant Efl set \fB \-tau\fR to zero. \& -\&\-alpha is a fudge parameter to control the width of the flooding potential. A value of 2 has been found +\&\fB \-alpha\fR is a fudge parameter to control the width of the flooding potential. A value of 2 has been found \&to give good results for most standard cases in flooding of proteins. -\&Alpha basically accounts for incomplete sampling, if you sampled further the width of the ensemble would -\&increase, this is mimicked by alpha1. -\&For restraining alpha1 can give you smaller width in the restraining potential. +\&alpha basically accounts for incomplete sampling, if you sampled further the width of the ensemble would +\&increase, this is mimicked by alpha 1. +\&For restraining, alpha 1 can give you smaller width in the restraining potential. \& \&RESTART and FLOODING: \&If you want to restart a crashed flooding simulation please find the values deltaF and Efl in -\&the output file and manually put them into the .edi file under DELTA_F0 and EFL_NULL. +\&the output file and manually put them into the \fB .edi\fR file under DELTA_F0 and EFL_NULL. .SH FILES .BI "\-f" " eigenvec.trr" .B Input @@ -221,9 +222,6 @@ .BI "\-linacc" " string" " " Indices of eigenvectors for acceptance linear sampling -.BI "\-flood" " string" " " - Indices of eigenvectors for flooding - .BI "\-radfix" " string" " " Indices of eigenvectors for fixed increment radius expansion @@ -233,29 +231,41 @@ .BI "\-radcon" " string" " " Indices of eigenvectors for acceptance radius contraction +.BI "\-flood" " string" " " + Indices of eigenvectors for flooding + .BI "\-outfrq" " int" " 100" - Freqency (in steps) of writing output in .edo file + Freqency (in steps) of writing output in \fB .edo\fR file .BI "\-slope" " real" " 0 " Minimal slope in acceptance radius expansion +.BI "\-linstep" " string" " " + Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! "1.0 2.3 5.1 \-3.1") + +.BI "\-accdir" " string" " " + Directions for acceptance linear sampling \- only sign counts! (put in quotes! "\-1 +1 \-1.1") + +.BI "\-radstep" " real" " 0 " + Stepsize (nm/step) for fixed increment radius expansion + .BI "\-maxedsteps" " int" " 0" - Max nr of steps per cycle + Maximum number of steps per cycle + +.BI "\-eqsteps" " int" " 0" + Number of steps to run without any perturbations .BI "\-deltaF0" " real" " 150 " - Target destabilization energy \- used for flooding + Target destabilization energy for flooding .BI "\-deltaF" " real" " 0 " - Start deltaF with this parameter \- default 0, i.e. nonzero values only needed for restart + Start deltaF with this parameter \- default 0, nonzero values only needed for restart .BI "\-tau" " real" " 0.1 " Coupling constant for adaption of flooding strength according to deltaF0, 0 = infinity i.e. constant flooding strength -.BI "\-eqsteps" " int" " 0" - Number of steps to run without any perturbations - .BI "\-Eflnull" " real" " 0 " - This is the starting value of the flooding strength. The flooding strength is updated according to the adaptive flooding scheme. To use a constant flooding strength use \-tau 0. + The starting value of the flooding strength. The flooding strength is updated according to the adaptive flooding scheme. For a constant flooding strength use \fB \-tau\fR 0. .BI "\-T" " real" " 300 " T is temperature, the value is needed if you want to do flooding @@ -263,15 +273,6 @@ .BI "\-alpha" " real" " 1 " Scale width of gaussian flooding potential with alpha2 -.BI "\-linstep" " string" " " - Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! "1.0 2.3 5.1 \-3.1") - -.BI "\-accdir" " string" " " - Directions for acceptance linear sampling \- only sign counts! (put in quotes! "\-1 +1 \-1.1") - -.BI "\-radstep" " real" " 0 " - Stepsize (nm/step) for fixed increment radius expansion - .BI "\-[no]restrain" "no " Use the flooding potential with inverted sign \- effects as quasiharmonic restraining potential @@ -281,6 +282,9 @@ .BI "\-[no]harmonic" "no " The eigenvalues are interpreted as spring constant +.BI "\-constF" " string" " " + Constant force flooding: manually set the forces for the eigenvectors selected with \-flood (put in quotes! "1.0 2.3 5.1 \-3.1"). No other flooding parameters are needed when specifying the forces directly. + .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/Makefile.am gromacs-4.5.5/man/man1/Makefile.am --- gromacs-4.5.4/man/man1/Makefile.am 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/man/man1/Makefile.am 2011-09-21 12:34:32.000000000 +0000 @@ -18,6 +18,7 @@ g_current.1 \ g_density.1 \ g_densmap.1 \ + g_densorder.1 \ g_dielectric.1 \ g_dih.1 \ g_dipoles.1 \ @@ -32,6 +33,7 @@ g_hbond.1 \ g_helix.1 \ g_helixorient.1 \ + g_hydorder.1 \ g_lie.1 \ g_mdmat.1 \ g_membed.1 \ @@ -41,7 +43,9 @@ g_nmeig.1 \ g_nmens.1 \ g_nmtraj.1 \ + g_options.1 \ g_order.1 \ + g_pme_error.1 \ g_polystat.1 \ g_potential.1 \ g_principal.1 \ diff -Nru gromacs-4.5.4/man/man1/Makefile.in gromacs-4.5.5/man/man1/Makefile.in --- gromacs-4.5.4/man/man1/Makefile.in 2011-03-21 15:13:36.000000000 +0000 +++ gromacs-4.5.5/man/man1/Makefile.in 2011-09-21 12:38:30.000000000 +0000 @@ -234,6 +234,7 @@ g_current.1 \ g_density.1 \ g_densmap.1 \ + g_densorder.1 \ g_dielectric.1 \ g_dih.1 \ g_dipoles.1 \ @@ -248,6 +249,7 @@ g_hbond.1 \ g_helix.1 \ g_helixorient.1 \ + g_hydorder.1 \ g_lie.1 \ g_mdmat.1 \ g_membed.1 \ @@ -257,7 +259,9 @@ g_nmeig.1 \ g_nmens.1 \ g_nmtraj.1 \ + g_options.1 \ g_order.1 \ + g_pme_error.1 \ g_polystat.1 \ g_potential.1 \ g_principal.1 \ diff -Nru gromacs-4.5.4/man/man1/make_ndx.1 gromacs-4.5.5/man/man1/make_ndx.1 --- gromacs-4.5.4/man/man1/make_ndx.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/make_ndx.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH make_ndx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH make_ndx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME make_ndx - makes index files -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3make_ndx\fP .BI "\-f" " conf.gro " @@ -15,13 +15,13 @@ .SH DESCRIPTION \&Index groups are necessary for almost every gromacs program. \&All these programs can generate default index groups. You ONLY -\&have to use make_ndx when you need SPECIAL index groups. +\&have to use \fB make_ndx\fR when you need SPECIAL index groups. \&There is a default index group for the whole system, 9 default -\&index groups are generated for proteins, a default index group +\&index groups for proteins, and a default index group \&is generated for every other residue name. -\&When no index file is supplied, also make_ndx will generate the +\&When no index file is supplied, also \fB make_ndx\fR will generate the \&default groups. \&With the index editor you can select on atom, residue and chain names \&and numbers. diff -Nru gromacs-4.5.4/man/man1/mdrun.1 gromacs-4.5.5/man/man1/mdrun.1 --- gromacs-4.5.4/man/man1/mdrun.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/mdrun.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH mdrun 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH mdrun 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME mdrun - performs a simulation, do a normal mode analysis or an energy minimization -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3mdrun\fP .BI "\-s" " topol.tpr " @@ -32,6 +32,7 @@ .BI "\-pf" " pullf.xvg " .BI "\-mtx" " nm.mtx " .BI "\-dn" " dipole.ndx " +.BI "\-multidir" " rundir " .BI "\-[no]h" "" .BI "\-[no]version" "" .BI "\-nice" " int " @@ -39,7 +40,6 @@ .BI "\-xvg" " enum " .BI "\-[no]pd" "" .BI "\-dd" " vector " -.BI "\-nt" " int " .BI "\-npme" " int " .BI "\-ddorder" " enum " .BI "\-[no]ddcheck" "" @@ -62,20 +62,20 @@ .BI "\-reseed" " int " .BI "\-[no]ionize" "" .SH DESCRIPTION -\&The mdrun program is the main computational chemistry engine +\&The \fB mdrun\fR program is the main computational chemistry engine \&within GROMACS. Obviously, it performs Molecular Dynamics simulations, \&but it can also perform Stochastic Dynamics, Energy Minimization, \&test particle insertion or (re)calculation of energies. -\&Normal mode analysis is another option. In this case mdrun +\&Normal mode analysis is another option. In this case \fB mdrun\fR \&builds a Hessian matrix from single conformation. \&For usual Normal Modes\-like calculations, make sure that \&the structure provided is properly energy\-minimized. -\&The generated matrix can be diagonalized by g_nmeig. +\&The generated matrix can be diagonalized by \fB g_nmeig\fR. -\&The mdrun program reads the run input file (\fB \-s\fR) +\&The \fB mdrun\fR program reads the run input file (\fB \-s\fR) \&and distributes the topology over nodes if needed. -\&mdrun produces at least four output files. +\&\fB mdrun\fR produces at least four output files. \&A single log file (\fB \-g\fR) is written, unless the option \&\fB \-seppot\fR is used, in which case each node writes a log file. \&The trajectory file (\fB \-o\fR), contains coordinates, velocities and @@ -92,13 +92,13 @@ \&turned on. -\&When mdrun is started using MPI with more than 1 node, parallelization +\&When \fB mdrun\fR is started using MPI with more than 1 node, parallelization \&is used. By default domain decomposition is used, unless the \fB \-pd\fR \&option is set, which selects particle decomposition. \&With domain decomposition, the spatial decomposition can be set -\&with option \fB \-dd\fR. By default mdrun selects a good decomposition. +\&with option \fB \-dd\fR. By default \fB mdrun\fR selects a good decomposition. \&The user only needs to change this when the system is very inhomogeneous. \&Dynamic load balancing is set with the option \fB \-dlb\fR, \&which can give a significant performance improvement, @@ -119,7 +119,7 @@ \&this is computationally more efficient starting at about 12 nodes. \&The number of PME nodes is set with option \fB \-npme\fR, \&this can not be more than half of the nodes. -\&By default mdrun makes a guess for the number of PME +\&By default \fB mdrun\fR makes a guess for the number of PME \&nodes when the number of nodes is larger than 11 or performance wise \¬ compatible with the PME grid x dimension. \&But the user should optimize npme. Performance statistics on this issue @@ -133,6 +133,7 @@ \&This section lists all options that affect the domain decomposition. \& + \&Option \fB \-rdd\fR can be used to set the required maximum distance \&for inter charge\-group bonded interactions. \&Communication for two\-body bonded interactions below the non\-bonded @@ -142,31 +143,34 @@ \&and nearly indepedent of the value of \fB \-rdd\fR. \&With dynamic load balancing option \fB \-rdd\fR also sets \&the lower limit for the domain decomposition cell sizes. -\&By default \fB \-rdd\fR is determined by mdrun based on +\&By default \fB \-rdd\fR is determined by \fB mdrun\fR based on \&the initial coordinates. The chosen value will be a balance \&between interaction range and communication cost. \& + \&When inter charge\-group bonded interactions are beyond -\&the bonded cut\-off distance, mdrun terminates with an error message. +\&the bonded cut\-off distance, \fB mdrun\fR terminates with an error message. \&For pair interactions and tabulated bonds \&that do not generate exclusions, this check can be turned off \&with the option \fB \-noddcheck\fR. \& + \&When constraints are present, option \fB \-rcon\fR influences \&the cell size limit as well. \&Atoms connected by NC constraints, where NC is the LINCS order plus 1, \&should not be beyond the smallest cell size. A error message is \&generated when this happens and the user should change the decomposition \&or decrease the LINCS order and increase the number of LINCS iterations. -\&By default mdrun estimates the minimum cell size required for P\-LINCS +\&By default \fB mdrun\fR estimates the minimum cell size required for P\-LINCS \&in a conservative fashion. For high parallelization it can be useful \&to set the distance required for P\-LINCS with the option \fB \-rcon\fR. \& + \&The \fB \-dds\fR option sets the minimum allowed x, y and/or z scaling -\&of the cells with dynamic load balancing. mdrun will ensure that +\&of the cells with dynamic load balancing. \fB mdrun\fR will ensure that \&the cells can scale down by at least this factor. This option is used \&for the automated spatial decomposition (when not using \fB \-dd\fR) \&as well as for determining the number of grid pulses, which in turn @@ -181,7 +185,7 @@ \&This can improve performance for highly parallel simulations \&where this global communication step becomes the bottleneck. \&For a global thermostat and/or barostat the temperature -\&and/or pressure will also only be updated every \-gcom steps. +\&and/or pressure will also only be updated every \fB \-gcom\fR steps. \&By default it is set to the minimum of nstcalcenergy and nstlist. @@ -194,19 +198,19 @@ \&ED (essential dynamics) sampling is switched on by using the \fB \-ei\fR \&flag followed by an \fB .edi\fR file. \&The \fB .edi\fR file can be produced using options in the essdyn -\&menu of the WHAT IF program. mdrun produces a \fB .edo\fR file that +\&menu of the WHAT IF program. \fB mdrun\fR produces a \fB .edo\fR file that \&contains projections of positions, velocities and forces onto selected \&eigenvectors. \&When user\-defined potential functions have been selected in the -\&\fB .mdp\fR file the \fB \-table\fR option is used to pass mdrun +\&\fB .mdp\fR file the \fB \-table\fR option is used to pass \fB mdrun\fR \&a formatted table with potential functions. The file is read from -\&either the current directory or from the GMXLIB directory. -\&A number of pre\-formatted tables are presented in the GMXLIB dir, -\&for 6\-8, 6\-9, 6\-10, 6\-11, 6\-12 Lennard Jones potentials with +\&either the current directory or from the \fB GMXLIB\fR directory. +\&A number of pre\-formatted tables are presented in the \fB GMXLIB\fR dir, +\&for 6\-8, 6\-9, 6\-10, 6\-11, 6\-12 Lennard\-Jones potentials with \&normal Coulomb. -\&When pair interactions are present a separate table for pair interaction +\&When pair interactions are present, a separate table for pair interaction \&functions is read using the \fB \-tablep\fR option. @@ -214,7 +218,7 @@ \&interaction functions are read using the \fB \-tableb\fR option. \&For each different tabulated interaction type the table file name is \&modified in a different way: before the file extension an underscore is -\&appended, then a b for bonds, an a for angles or a d for dihedrals +\&appended, then a 'b' for bonds, an 'a' for angles or a 'd' for dihedrals \&and finally the table number of the interaction type. @@ -223,10 +227,16 @@ \&in the \fB .mdp\fR file. -\&With \fB \-multi\fR multiple systems are simulated in parallel. -\&As many input files are required as the number of systems. -\&The system number is appended to the run input and each output filename, -\&for instance topol.tpr becomes topol0.tpr, topol1.tpr etc. +\&With \fB \-multi\fR or \fB \-multidir\fR, multiple systems can be +\&simulated in parallel. +\&As many input files/directories are required as the number of systems. +\&The \fB \-multidir\fR option takes a list of directories (one for each +\&system) and runs in each of them, using the input/output file names, +\&such as specified by e.g. the \fB \-s\fR option, relative to these +\&directories. +\&With \fB \-multi\fR, the system number is appended to the run input +\&and each output filename, for instance \fB topol.tpr\fR becomes +\&\fB topol0.tpr\fR, \fB topol1.tpr\fR etc. \&The number of nodes per system is the total number of nodes \÷d by the number of systems. \&One use of this option is for NMR refinement: when distance @@ -235,8 +245,8 @@ \&With \fB \-replex\fR replica exchange is attempted every given number -\&of steps. The number of replicas is set with the \fB \-multi\fR option, -\&see above. +\&of steps. The number of replicas is set with the \fB \-multi\fR or +\&\fB \-multidir\fR option, described above. \&All run input files should use a different coupling temperature, \&the order of the files is not important. The random seed is set with \&\fB \-reseed\fR. The velocities are scaled and neighbor searching @@ -245,7 +255,7 @@ \&Finally some experimental algorithms can be tested when the \&appropriate options have been given. Currently under -\&investigation are: polarizability, and X\-Ray bombardments. +\&investigation are: polarizability and X\-ray bombardments. \& @@ -267,18 +277,22 @@ \&A simulation can be continued by reading the full state from file \&with option \fB \-cpi\fR. This option is intelligent in the way that \&if no checkpoint file is found, Gromacs just assumes a normal run and -\&starts from the first step of the tpr file. By default the output +\&starts from the first step of the \fB .tpr\fR file. By default the output \&will be appending to the existing output files. The checkpoint file \&contains checksums of all output files, such that you will never \&loose data when some output files are modified, corrupt or removed. \&There are three scenarios with \fB \-cpi\fR: -\&* no files with matching names are present: new output files are written -\&* all files are present with names and checksums matching those stored +\&\fB *\fR no files with matching names are present: new output files are written + + +\&\fB *\fR all files are present with names and checksums matching those stored \&in the checkpoint file: files are appended -\&* otherwise no files are modified and a fatal error is generated + +\&\fB *\fR otherwise no files are modified and a fatal error is generated + \&With \fB \-noappend\fR new output files are opened and the simulation \&part number is added to all output file names. @@ -309,18 +323,18 @@ \& -\&When mdrun receives a TERM signal, it will set nsteps to the current -\&step plus one. When mdrun receives an INT signal (e.g. when ctrl+C is +\&When \fB mdrun\fR receives a TERM signal, it will set nsteps to the current +\&step plus one. When \fB mdrun\fR receives an INT signal (e.g. when ctrl+C is \&pressed), it will stop after the next neighbor search step \&(with nstlist=0 at the next step). \&In both cases all the usual output will be written to file. -\&When running with MPI, a signal to one of the mdrun processes +\&When running with MPI, a signal to one of the \fB mdrun\fR processes \&is sufficient, this signal should not be sent to mpirun or -\&the mdrun process that is the parent of the others. +\&the \fB mdrun\fR process that is the parent of the others. \& -\&When mdrun is started with MPI, it does not run niced by default. +\&When \fB mdrun\fR is started with MPI, it does not run niced by default. .SH FILES .BI "\-s" " topol.tpr" .B Input @@ -430,6 +444,10 @@ .B Output, Opt. Index file +.BI "\-multidir" " rundir" +.B Input, Opt., Mult. + Run directory + .SH OTHER OPTIONS .BI "\-[no]h" "no " Print help info and quit @@ -452,9 +470,6 @@ .BI "\-dd" " vector" " 0 0 0" Domain decomposition grid, 0 is optimize -.BI "\-nt" " int" " 0" - Number of threads to start (0 is guess) - .BI "\-npme" " int" " \-1" Number of separate nodes to be used for PME, \-1 is guess diff -Nru gromacs-4.5.4/man/man1/mk_angndx.1 gromacs-4.5.5/man/man1/mk_angndx.1 --- gromacs-4.5.4/man/man1/mk_angndx.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/mk_angndx.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH mk_angndx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH mk_angndx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME mk_angndx - generates index files for g_angle -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3mk_angndx\fP .BI "\-s" " topol.tpr " @@ -14,7 +14,7 @@ .BI "\-[no]hyd" "" .BI "\-hq" " real " .SH DESCRIPTION -\&mk_angndx makes an index file for calculation of +\&\fB mk_angndx\fR makes an index file for calculation of \&angle distributions etc. It uses a run input file (\fB .tpx\fR) for the \&definitions of the angles, dihedrals etc. .SH FILES diff -Nru gromacs-4.5.4/man/man1/ngmx.1 gromacs-4.5.5/man/man1/ngmx.1 --- gromacs-4.5.4/man/man1/ngmx.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/ngmx.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH ngmx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH ngmx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME ngmx - displays a trajectory -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3ngmx\fP .BI "\-f" " traj.xtc " @@ -15,7 +15,7 @@ .BI "\-e" " time " .BI "\-dt" " time " .SH DESCRIPTION -\&ngmx is the Gromacs trajectory viewer. This program reads a +\&\fB ngmx\fR is the GROMACS trajectory viewer. This program reads a \&trajectory file, a run input file and an index file and plots a \&3D structure of your molecule on your standard X Window \&screen. No need for a high end graphics workstation, it even @@ -31,9 +31,8 @@ \&show computational box. -\&Some of the more common X command line options can be used: - -\&\-bg, \-fg change colors, \-font fontname, changes the font. +\&Some of the more common X command line options can be used: +\&\fB \-bg\fR, \fB \-fg\fR change colors, \fB \-font fontname\fR changes the font. .SH FILES .BI "\-f" " traj.xtc" .B Input diff -Nru gromacs-4.5.4/man/man1/pdb2gmx.1 gromacs-4.5.5/man/man1/pdb2gmx.1 --- gromacs-4.5.4/man/man1/pdb2gmx.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/pdb2gmx.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH pdb2gmx 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH pdb2gmx 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME pdb2gmx - converts pdb files to topology and coordinate files -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3pdb2gmx\fP .BI "\-f" " eiwit.pdb " @@ -41,22 +41,22 @@ .BI "\-[no]renum" "" .BI "\-[no]rtpres" "" .SH DESCRIPTION -\&This program reads a pdb (or gro) file, reads +\&This program reads a \fB .pdb\fR (or \fB .gro\fR) file, reads \&some database files, adds hydrogens to the molecules and generates -\&coordinates in Gromacs (Gromos), or optionally pdb, format -\&and a topology in Gromacs format. +\&coordinates in GROMACS (GROMOS), or optionally \fB .pdb\fR, format +\&and a topology in GROMACS format. \&These files can subsequently be processed to generate a run input file. \& -\&pdb2gmx will search for force fields by looking for +\&\fB pdb2gmx\fR will search for force fields by looking for \&a \fB forcefield.itp\fR file in subdirectories \fB forcefield.ff\fR -\&of the current working directory and of the Gomracs library directory +\&of the current working directory and of the Gromacs library directory \&as inferred from the path of the binary or the \fB GMXLIB\fR environment \&variable. \&By default the forcefield selection is interactive, \&but you can use the \fB \-ff\fR option to specify one of the short names -\&in the list on the command line instead. In that case pdb2gmx just looks +\&in the list on the command line instead. In that case \fB pdb2gmx\fR just looks \&for the corresponding \fB forcefield.ff\fR directory. \& @@ -66,14 +66,14 @@ \&If you want to modify or add a residue types, you can copy the force \&field directory from the Gromacs library directory to your current \&working directory. If you want to add new protein residue types, -\&you will need to modify residuetypes.dat in the libary directory +\&you will need to modify \fB residuetypes.dat\fR in the library directory \&or copy the whole library directory to a local directory and set \&the environment variable \fB GMXLIB\fR to the name of that directory. -\&Check chapter 5 of the manual for more information about file formats. +\&Check Chapter 5 of the manual for more information about file formats. \& -\&Note that a pdb file is nothing more than a file format, and it +\&Note that a \fB .pdb\fR file is nothing more than a file format, and it \&need not necessarily contain a protein structure. Every kind of \&molecule for which there is support in the database can be converted. \&If there is no support in the database, you can add it yourself. @@ -89,7 +89,7 @@ \&on NE2 or on both. By default these selections are done automatically. \&For His, this is based on an optimal hydrogen bonding \&conformation. Hydrogen bonds are defined based on a simple geometric -\&criterium, specified by the maximum hydrogen\-donor\-acceptor angle +\&criterion, specified by the maximum hydrogen\-donor\-acceptor angle \&and donor\-acceptor distance, which are set by \fB \-angle\fR and \&\fB \-dist\fR respectively. @@ -100,33 +100,33 @@ \&if you want a disulfide bridge or distance restraints between \&two protein chains or if you have a HEME group bound to a protein. \&In such cases multiple chains should be contained in a single -\&\fB molecule_type\fR definition. -\&To handle this, pdb2gmx has an option \fB \-chainsep\fR so you can +\&\fB moleculetype\fR definition. +\&To handle this, \fB pdb2gmx\fR has an option \fB \-chainsep\fR so you can \&choose whether a new chain should start when we find a TER record, \&when the chain id changes, combinations of either or both of these \&or fully interactively. -\&pdb2gmx will also check the occupancy field of the pdb file. +\&\fB pdb2gmx\fR will also check the occupancy field of the \fB .pdb\fR file. \&If any of the occupancies are not one, indicating that the atom is \¬ resolved well in the structure, a warning message is issued. -\&When a pdb file does not originate from an X\-Ray structure determination +\&When a \fB .pdb\fR file does not originate from an X\-ray structure determination \&all occupancy fields may be zero. Either way, it is up to the user \&to verify the correctness of the input data (read the article!). -\&During processing the atoms will be reordered according to Gromacs +\&During processing the atoms will be reordered according to GROMACS \&conventions. With \fB \-n\fR an index file can be generated that \&contains one group reordered in the same way. This allows you to -\&convert a Gromos trajectory and coordinate file to Gromos. There is +\&convert a GROMOS trajectory and coordinate file to GROMOS. There is \&one limitation: reordering is done after the hydrogens are stripped \&from the input and before new hydrogens are added. This means that \&you should not use \fB \-ignh\fR. \&The \fB .gro\fR and \fB .g96\fR file formats do not support chain -\&identifiers. Therefore it is useful to enter a pdb file name at -\&the \fB \-o\fR option when you want to convert a multichain pdb file. +\&identifiers. Therefore it is useful to enter a \fB .pdb\fR file name at +\&the \fB \-o\fR option when you want to convert a multi\-chain \fB .pdb\fR file. \& @@ -135,8 +135,8 @@ \&hydrogens into virtual sites and fixing angles, which fixes their \&position relative to neighboring atoms. Additionally, all atoms in the \&aromatic rings of the standard amino acids (i.e. PHE, TRP, TYR and HIS) -\&can be converted into virtual sites, elminating the fast improper dihedral -\&fluctuations in these rings. Note that in this case all other hydrogen +\&can be converted into virtual sites, eliminating the fast improper dihedral +\&fluctuations in these rings. \fB Note\fR that in this case all other hydrogen \&atoms are also converted to virtual sites. The mass of all atoms that are \&converted into virtual sites, is added to the heavy atoms. @@ -185,7 +185,7 @@ Condition in PDB files when a new chain and molecule_type should be started: \fB id_or_ter\fR, \fB id_and_ter\fR, \fB ter\fR, \fB id\fR or \fB interactive\fR .BI "\-ff" " string" " select" - Force field, interactive by default. Use \-h for information. + Force field, interactive by default. Use \fB \-h\fR for information. .BI "\-water" " enum" " select" Water model to use: \fB select\fR, \fB none\fR, \fB spc\fR, \fB spce\fR, \fB tip3p\fR, \fB tip4p\fR or \fB tip5p\fR @@ -200,22 +200,22 @@ Interactive termini selection, iso charged .BI "\-[no]lys" "no " - Interactive Lysine selection, iso charged + Interactive lysine selection, iso charged .BI "\-[no]arg" "no " - Interactive Arganine selection, iso charged + Interactive arginine selection, iso charged .BI "\-[no]asp" "no " - Interactive Aspartic Acid selection, iso charged + Interactive aspartic Acid selection, iso charged .BI "\-[no]glu" "no " - Interactive Glutamic Acid selection, iso charged + Interactive glutamic Acid selection, iso charged .BI "\-[no]gln" "no " - Interactive Glutamine selection, iso neutral + Interactive glutamine selection, iso neutral .BI "\-[no]his" "no " - Interactive Histidine selection, iso checking H\-bonds + Interactive histidine selection, iso checking H\-bonds .BI "\-angle" " real" " 135 " Minimum hydrogen\-donor\-acceptor angle for a H\-bond (degrees) @@ -224,10 +224,10 @@ Maximum donor\-acceptor distance for a H\-bond (nm) .BI "\-[no]una" "no " - Select aromatic rings with united CH atoms on Phenylalanine, Tryptophane and Tyrosine + Select aromatic rings with united CH atoms on phenylalanine, tryptophane and tyrosine .BI "\-[no]ignh" "no " - Ignore hydrogen atoms that are in the pdb file + Ignore hydrogen atoms that are in the coordinate file .BI "\-[no]missing" "no " Continue when atoms are missing, dangerous @@ -248,16 +248,16 @@ Change the mass of hydrogens to 2 amu .BI "\-[no]chargegrp" "yes " - Use charge groups in the rtp file + Use charge groups in the \fB .rtp\fR file .BI "\-[no]cmap" "yes " - Use cmap torsions (if enabled in the rtp file) + Use cmap torsions (if enabled in the \fB .rtp\fR file) .BI "\-[no]renum" "no " Renumber the residues consecutively in the output .BI "\-[no]rtpres" "no " - Use rtp entry names as residue names + Use \fB .rtp\fR entry names as residue names .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/tpbconv.1 gromacs-4.5.5/man/man1/tpbconv.1 --- gromacs-4.5.4/man/man1/tpbconv.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/tpbconv.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH tpbconv 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH tpbconv 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME tpbconv - makes a run input file for restarting a crashed run -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3tpbconv\fP .BI "\-s" " topol.tpr " @@ -24,27 +24,31 @@ \&tpbconv can edit run input files in four ways. -\&\fB 1st.\fR by modifying the number of steps in a run input file +\&\fB 1.\fR by modifying the number of steps in a run input file \&with options \fB \-extend\fR, \fB \-until\fR or \fB \-nsteps\fR \&(nsteps=\-1 means unlimited number of steps) -\&\fB 2nd.\fR (OBSOLETE) by creating a run input file +\&\fB 2.\fR (OBSOLETE) by creating a run input file \&for a continuation run when your simulation has crashed due to e.g. \&a full disk, or by making a continuation run input file. \&This option is obsolete, since mdrun now writes and reads \&checkpoint files. -\&Note that a frame with coordinates and velocities is needed. +\&\fB Note\fR that a frame with coordinates and velocities is needed. \&When pressure and/or Nose\-Hoover temperature coupling is used \&an energy file can be supplied to get an exact continuation \&of the original run. -\&\fB 3rd.\fR by creating a tpx file for a subset of your original +\&\fB 3.\fR by creating a \fB .tpx\fR file for a subset of your original \&tpx file, which is useful when you want to remove the solvent from -\&your tpx file, or when you want to make e.g. a pure Ca tpx file. -\&\fB WARNING: this tpx file is not fully functional\fR. -\&\fB 4th.\fR by setting the charges of a specified group +\&your \fB .tpx\fR file, or when you want to make e.g. a pure Calpha \fB .tpx\fR file. +\&Note that you may need to use \fB \-nsteps \-1\fR (or similar) to get +\&this to work. +\&\fB WARNING: this \fB .tpx\fR file is not fully functional\fR. + + +\&\fB 4.\fR by setting the charges of a specified group \&to zero. This is useful when doing free energy estimates \&using the LIE (Linear Interaction Energy) method. .SH FILES diff -Nru gromacs-4.5.4/man/man1/trjcat.1 gromacs-4.5.5/man/man1/trjcat.1 --- gromacs-4.5.4/man/man1/trjcat.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/trjcat.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH trjcat 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH trjcat 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME trjcat - concatenates trajectory files -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3trjcat\fP .BI "\-f" " traj.xtc " @@ -25,12 +25,12 @@ .BI "\-[no]overwrite" "" .BI "\-[no]cat" "" .SH DESCRIPTION -\&trjcat concatenates several input trajectory files in sorted order. +\&\fB trjcat\fR concatenates several input trajectory files in sorted order. \&In case of double time frames the one in the later file is used. \&By specifying \fB \-settime\fR you will be asked for the start time \&of each file. The input files are taken from the command line, -\&such that a command like \fB trjcat \-o fixed.trr *.trr\fR should do -\&the trick. Using \fB \-cat\fR you can simply paste several files +\&such that a command like \fB trjcat \-f *.trr \-o fixed.trr\fR should do +\&the trick. Using \fB \-cat\fR, you can simply paste several files \&together without removal of frames with identical time stamps. @@ -42,19 +42,19 @@ \&If the \fB \-demux\fR option is given, the N trajectories that are -\&read, are written in another order as specified in the xvg file. -\&The xvg file should contain something like: +\&read, are written in another order as specified in the \fB .xvg\fR file. +\&The \fB .xvg\fR file should contain something like: -\&0 0 1 2 3 4 5 +\&\fB 0 0 1 2 3 4 5 -\&2 1 0 2 3 5 4 +\&2 1 0 2 3 5 4\fR \&Where the first number is the time, and subsequent numbers point to \&trajectory indices. \&The frames corresponding to the numbers present at the first line \&are collected into the output trajectory. If the number of frames in -\&the trajectory does not match that in the xvg file then the program +\&the trajectory does not match that in the \fB .xvg\fR file then the program \&tries to be smart. Beware. .SH FILES .BI "\-f" " traj.xtc" @@ -99,7 +99,7 @@ Only write frame when t MOD dt = first time (ps) .BI "\-prec" " int" " 3" - Precision for .xtc and .gro writing in number of decimal places + Precision for \fB .xtc\fR and \fB .gro\fR writing in number of decimal places .BI "\-[no]vel" "yes " Read and write velocities if possible @@ -111,13 +111,13 @@ Sort trajectory files (not frames) .BI "\-[no]keeplast" "no " - keep overlapping frames at end of trajectory + Keep overlapping frames at end of trajectory .BI "\-[no]overwrite" "no " - overwrite overlapping frames during appending + Overwrite overlapping frames during appending .BI "\-[no]cat" "no " - do not discard double time frames + Do not discard double time frames .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/trjconv.1 gromacs-4.5.5/man/man1/trjconv.1 --- gromacs-4.5.4/man/man1/trjconv.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/trjconv.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH trjconv 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH trjconv 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME trjconv - converts and manipulates trajectory files -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3trjconv\fP .BI "\-f" " traj.xtc " @@ -31,6 +31,7 @@ .BI "\-[no]center" "" .BI "\-boxcenter" " enum " .BI "\-box" " vector " +.BI "\-clustercenter" " vector " .BI "\-trans" " vector " .BI "\-shift" " vector " .BI "\-fit" " enum " @@ -47,7 +48,7 @@ .BI "\-dropover" " real " .BI "\-[no]conect" "" .SH DESCRIPTION -\&trjconv can convert trajectory files in many ways: +\&\fB trjconv\fR can convert trajectory files in many ways: \&\fB 1.\fR from one format to another @@ -68,7 +69,7 @@ \&\fB 9.\fR cut the trajectory in small subtrajectories according \&to information in an index file. This allows subsequent analysis of -\&the subtrajectories that could, for example be the result of a +\&the subtrajectories that could, for example, be the result of a \&cluster analysis. Use option \fB \-sub\fR. \&This assumes that the entries in the index file are frame numbers and \&dumps each group in the index file to a separate trajectory file. @@ -77,7 +78,7 @@ \&in an \fB .xvg\fR file. -\&The program \fB trjcat\fR can concatenate multiple trajectory files. +\&The program \fB trjcat\fR is better suited for concatenating multiple trajectory files. \& @@ -91,7 +92,7 @@ \&is always taken from \fB \-ndec\fR, when this option is set. \&All other formats have fixed precision. \fB .trr\fR and \fB .trj\fR \&output can be single or double precision, depending on the precision -\&of the trjconv binary. +\&of the \fB trjconv\fR binary. \&Note that velocities are only supported in \&\fB .trr\fR, \fB .trj\fR, \fB .gro\fR and \fB .g96\fR files. @@ -103,7 +104,7 @@ \&Option \fB \-sep\fR can be used to write every frame to a separate -\&.gro, .g96 or .pdb file, default all frames all written to one file. +\&\fB .gro, .g96\fR or \fB .pdb\fR file. By default, all frames all written to one file. \&\fB .pdb\fR files with all frames concatenated can be viewed with \&\fB rasmol \-nmrpdb\fR. @@ -117,9 +118,9 @@ \&There are two options for fitting the trajectory to a reference -\&either for essential dynamics analysis or for whatever. +\&either for essential dynamics analysis, etc. \&The first option is just plain fitting to a reference structure -\&in the structure file, the second option is a progressive fit +\&in the structure file. The second option is a progressive fit \&in which the first timeframe is fitted to the reference structure \&in the structure file to obtain and each subsequent timeframe is \&fitted to the previously fitted structure. This way a continuous @@ -131,28 +132,32 @@ \&Option \fB \-pbc\fR sets the type of periodic boundary condition \&treatment: -\&* \fB mol\fR puts the center of mass of molecules in the box. +\&\fB * mol\fR puts the center of mass of molecules in the box. -\&* \fB res\fR puts the center of mass of residues in the box. +\&\fB * res\fR puts the center of mass of residues in the box. -\&* \fB atom\fR puts all the atoms in the box. +\&\fB * atom\fR puts all the atoms in the box. -\&* \fB nojump\fR checks if atoms jump across the box and then puts +\&\fB * nojump\fR checks if atoms jump across the box and then puts \&them back. This has the effect that all molecules \&will remain whole (provided they were whole in the initial -\&conformation), note that this ensures a continuous trajectory but +\&conformation). \fB Note\fR that this ensures a continuous trajectory but \&molecules may diffuse out of the box. The starting configuration \&for this procedure is taken from the structure file, if one is \&supplied, otherwise it is the first frame. -\&* \fB cluster\fR clusters all the atoms in the selected index -\&such that they are all closest to the center of mass of the cluster -\&which is iteratively updated. Note that this will only give meaningful +\&\fB * cluster\fR clusters all the atoms in the selected index +\&such that they are all closest to the center of mass of the cluster, +\&which is iteratively updated. \fB Note\fR that this will only give meaningful \&results if you in fact have a cluster. Luckily that can be checked \&afterwards using a trajectory viewer. Note also that if your molecules \&are broken this will not work either. -\&* \fB whole\fR only makes broken molecules whole. +\&The separate option \fB \-clustercenter\fR can be used to specify an +\&approximate center for the cluster. This is useful e.g. if you have +\&two big vesicles, and you want to maintain their relative positions. + +\&\fB * whole\fR only makes broken molecules whole. \&Option \fB \-ur\fR sets the unit cell representation for options @@ -163,7 +168,7 @@ \&\fB tric\fR is the triclinic unit cell. \&\fB compact\fR puts all atoms at the closest distance from the center \&of the box. This can be useful for visualizing e.g. truncated -\&octahedrons. The center for options \fB tric\fR and \fB compact\fR +\&octahedra. The center for options \fB tric\fR and \fB compact\fR \&is \fB tric\fR (see below), unless the option \fB \-boxcenter\fR \&is set differently. @@ -179,22 +184,19 @@ \&want all molecules in the box after the centering. -\&With \fB \-dt\fR it is possible to reduce the number of +\&With \fB \-dt\fR, it is possible to reduce the number of \&frames in the output. This option relies on the accuracy of the times \&in your input trajectory, so if these are inaccurate use the \&\fB \-timestep\fR option to modify the time (this can be done -\&simultaneously). For making smooth movies the program \fB g_filter\fR +\&simultaneously). For making smooth movies, the program \fB g_filter\fR \&can reduce the number of frames while using low\-pass frequency \&filtering, this reduces aliasing of high frequency motions. -\&Using \fB \-trunc\fR trjconv can truncate \fB .trj\fR in place, i.e. +\&Using \fB \-trunc\fR \fB trjconv\fR can truncate \fB .trj\fR in place, i.e. \&without copying the file. This is useful when a run has crashed -\&during disk I/O (one more disk full), or when two contiguous -\&trajectories must be concatenated without have double frames. - - -\&\fB trjcat\fR is more suitable for concatenating trajectory files. +\&during disk I/O (i.e. full disk), or when two contiguous +\&trajectories must be concatenated without having double frames. \&Option \fB \-dump\fR can be used to extract a frame at or near @@ -254,7 +256,7 @@ Time unit: \fB fs\fR, \fB ps\fR, \fB ns\fR, \fB us\fR, \fB ms\fR or \fB s\fR .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-xvg" " enum" " xmgrace" xvg plot formatting: \fB xmgrace\fR, \fB xmgr\fR or \fB none\fR @@ -292,6 +294,9 @@ .BI "\-box" " vector" " 0 0 0" Size for new cubic box (default: read from input) +.BI "\-clustercenter" " vector" " 0 0 0" + Optional starting point for pbc cluster option + .BI "\-trans" " vector" " 0 0 0" All coordinates will be translated by trans. This can advantageously be combined with \-pbc mol \-ur compact. @@ -311,7 +316,7 @@ Read and write forces if possible .BI "\-trunc" " time" " \-1 " - Truncate input trj file after this time (ps) + Truncate input trajectory file after this time (ps) .BI "\-exec" " string" " " Execute command for every output frame with the frame number as argument @@ -326,7 +331,7 @@ Write each frame to a separate .gro, .g96 or .pdb file .BI "\-nzero" " int" " 0" - Prepend file number in case you use the \-sep flag with this number of zeroes + If the \-sep flag is set, use these many digits for the file numbers and prepend zeros as needed .BI "\-dropunder" " real" " 0 " Drop all frames below this value @@ -335,7 +340,7 @@ Drop all frames above this value .BI "\-[no]conect" "no " - Add conect records when writing pdb files. Useful for visualization of non\-standard molecules, e.g. coarse grained ones + Add conect records when writing \fB .pdb\fR files. Useful for visualization of non\-standard molecules, e.g. coarse grained ones .SH SEE ALSO .BR gromacs(7) diff -Nru gromacs-4.5.4/man/man1/trjorder.1 gromacs-4.5.5/man/man1/trjorder.1 --- gromacs-4.5.4/man/man1/trjorder.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/trjorder.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH trjorder 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH trjorder 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME trjorder - orders molecules according to their distance to a group -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3trjorder\fP .BI "\-f" " traj.xtc " @@ -23,7 +23,7 @@ .BI "\-r" " real " .BI "\-[no]z" "" .SH DESCRIPTION -\&trjorder orders molecules according to the smallest distance +\&\fB trjorder\fR orders molecules according to the smallest distance \&to atoms in a reference group \&or on z\-coordinate (with option \fB \-z\fR). \&With distance ordering, it will ask for a group of reference @@ -36,7 +36,7 @@ \&to the output trajectory. -\&trjorder can be useful for e.g. analyzing the n waters closest to a +\&\fB trjorder\fR can be useful for e.g. analyzing the n waters closest to a \&protein. \&In that case the reference group would be the protein and the group \&of molecules would consist of all the water atoms. When an index group @@ -45,8 +45,8 @@ \& -\&If the output file is a pdb file, the distance to the reference target -\&will be stored in the B\-factor field in order to color with e.g. rasmol. +\&If the output file is a \fB .pdb\fR file, the distance to the reference target +\&will be stored in the B\-factor field in order to color with e.g. Rasmol. \& diff -Nru gromacs-4.5.4/man/man1/xpm2ps.1 gromacs-4.5.5/man/man1/xpm2ps.1 --- gromacs-4.5.4/man/man1/xpm2ps.1 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/man/man1/xpm2ps.1 2011-09-21 12:34:10.000000000 +0000 @@ -1,8 +1,8 @@ -.TH xpm2ps 1 "Thu 26 Aug 2010" "" "GROMACS suite, VERSION 4.5" +.TH xpm2ps 1 "Mon 4 Apr 2011" "" "GROMACS suite, VERSION 4.5.4-dev-20110404-bc5695c" .SH NAME xpm2ps - converts XPM matrices to encapsulated postscript (or XPM) -.B VERSION 4.5 +.B VERSION 4.5.4-dev-20110404-bc5695c .SH SYNOPSIS \f3xpm2ps\fP .BI "\-f" " root.xpm " @@ -32,30 +32,30 @@ .BI "\-cmin" " real " .BI "\-cmax" " real " .SH DESCRIPTION -\&xpm2ps makes a beautiful color plot of an XPixelMap file. +\&\fB xpm2ps\fR makes a beautiful color plot of an XPixelMap file. \&Labels and axis can be displayed, when they are supplied \&in the correct matrix format. -\&Matrix data may be generated by programs such as do_dssp, g_rms or -\&g_mdmat. +\&Matrix data may be generated by programs such as \fB do_dssp\fR, \fB g_rms\fR or +\&\fB g_mdmat\fR. -\&Parameters are set in the \fB m2p\fR file optionally supplied with -\&\fB \-di\fR. Reasonable defaults are provided. Settings for the y\-axis -\&default to those for the x\-axis. Font names have a defaulting hierarchy: +\&Parameters are set in the \fB .m2p\fR file optionally supplied with +\&\fB \-di\fR. Reasonable defaults are provided. Settings for the \fI y\fR\-axis +\&default to those for the \fI x\fR\-axis. Font names have a defaulting hierarchy: \&titlefont \- legendfont; titlefont \- (xfont \- yfont \- ytickfont) \&\- xtickfont, e.g. setting titlefont sets all fonts, setting xfont \&sets yfont, ytickfont and xtickfont. -\&When no \fB m2p\fR file is supplied, many setting are set by -\&command line options. The most important option is \fB \-size\fR +\&When no \fB .m2p\fR file is supplied, many settings are taken from +\&command line options. The most important option is \fB \-size\fR, \&which sets the size of the whole matrix in postscript units. \&This option can be overridden with the \fB \-bx\fR and \fB \-by\fR -\&options (and the corresponding parameters in the \fB m2p\fR file), +\&options (and the corresponding parameters in the \fB .m2p\fR file), \&which set the size of a single matrix element. -\&With \fB \-f2\fR a 2nd matrix file can be supplied, both matrix +\&With \fB \-f2\fR a second matrix file can be supplied. Both matrix \&files will be read simultaneously and the upper left half of the \&first one (\fB \-f\fR) is plotted together with the lower right \&half of the second one (\fB \-f2\fR). The diagonal will contain @@ -67,7 +67,7 @@ \&If the color coding and legend labels of both matrices are identical, \&only one legend will be displayed, else two separate legends are \&displayed. -\&With \fB \-combine\fR an alternative operation can be selected +\&With \fB \-combine\fR, an alternative operation can be selected \&to combine the matrices. The output range is automatically set \&to the actual range of the combined matrix. This can be overridden \&with \fB \-cmin\fR and \fB \-cmax\fR. @@ -75,10 +75,10 @@ \&\fB \-title\fR can be set to \fB none\fR to suppress the title, or to \&\fB ylabel\fR to show the title in the Y\-label position (alongside -\&the Y\-axis). +\&the \fI y\fR\-axis). -\&With the \fB \-rainbow\fR option dull grey\-scale matrices can be turned +\&With the \fB \-rainbow\fR option, dull grayscale matrices can be turned \&into attractive color pictures. @@ -120,7 +120,7 @@ Set the nicelevel .BI "\-[no]w" "no " - View output xvg, xpm, eps and pdb files + View output \fB .xvg\fR, \fB .xpm\fR, \fB .eps\fR and \fB .pdb\fR files .BI "\-[no]frame" "yes " Display frame, ticks, labels, title and legend @@ -141,7 +141,7 @@ Horizontal size of the matrix in ps units .BI "\-bx" " real" " 0 " - Element x\-size, overrides \-size (also y\-size when \-by is not set) + Element x\-size, overrides \fB \-size\fR (also y\-size when \fB \-by\fR is not set) .BI "\-by" " real" " 0 " Element y\-size @@ -156,10 +156,10 @@ only write out every nr\-th row and column .BI "\-[no]zeroline" "no " - insert line in xpm matrix where axis label is zero + insert line in \fB .xpm\fR matrix where axis label is zero .BI "\-legoffset" " int" " 0" - Skip first N colors from xpm file for the legend + Skip first N colors from \fB .xpm\fR file for the legend .BI "\-combine" " enum" " halves" Combine two matrices: \fB halves\fR, \fB add\fR, \fB sub\fR, \fB mult\fR or \fB div\fR diff -Nru gromacs-4.5.4/scripts/demux.pl gromacs-4.5.5/scripts/demux.pl --- gromacs-4.5.4/scripts/demux.pl 2010-09-29 11:35:02.000000000 +0000 +++ gromacs-4.5.5/scripts/demux.pl 2011-09-21 12:34:32.000000000 +0000 @@ -30,7 +30,7 @@ sub pr_order { my $t = shift; my $nrepl = shift; - printf(NDX "%-8g",$t); + printf(NDX "%-20g",$t); for(my $k=0; ($k<$nrepl); $k++) { my $oo = shift; printf(NDX " %3d",$oo); @@ -41,7 +41,7 @@ sub pr_revorder { my $t = shift; my $nrepl = shift; - printf(TEMP "%-8g",$t); + printf(TEMP "%-20g",$t); for(my $k=0; ($k<$nrepl); $k++) { my $oo = shift; printf(TEMP " %3d",$oo); diff -Nru gromacs-4.5.4/share/html/online/g_densorder.html gromacs-4.5.5/share/html/online/g_densorder.html --- gromacs-4.5.4/share/html/online/g_densorder.html 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/share/html/online/g_densorder.html 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,63 @@ + + +g_densorder + + + +
+ + + +
+

g_densorder

Main Table of Contents

VERSION 4.5.4-dev-20110404-3c0e5ec
+Mon 4 Apr 2011

+


+

Description

+

+A small program to reduce a two-phase density distribution +along an axis, computed over a MD trajectory +to 2D surfaces fluctuating in time, by a fit to +a functional profile for interfacial densities +A time-averaged spatial representation of the +interfaces can be output with the option -tavg +

+

Files

+ + + + + + + + + +
optionfilenametypedescription
-s topol.tpr Input Run input file: tpr tpb tpa
-f traj.xtc Input Trajectory: xtc trr trj gro g96 pdb cpt
-n index.ndx Input Index file
-o Density4D.dat Output, Opt. Generic data file
-or hello.out Output, Opt., Mult. Generic output file
-og interface.xpm Output, Opt., Mult. X PixMap compatible matrix file
-Spect intfspect.out Output, Opt., Mult. Generic output file
+

+

Other options

+ + + + + + + + + + + + + + + + + + + +
optiontypedefaultdescription
-[no]h bool no Print help info and quit
-[no]version bool no Print version info and quit
-nice int 0 Set the nicelevel
-b time 0 First frame (ps) to read from trajectory
-e time 0 Last frame (ps) to read from trajectory
-dt time 0 Only use frame when t MOD dt = first time (ps)
-[no]w bool no View output .xvg, .xpm, .eps and .pdb files
-[no]1d bool no Pseudo-1d interface geometry
-bw real 0.2 Binwidth of density distribution tangential to interface
-bwn real 0.05 Binwidth of density distribution normal to interface
-order int 0 Order of Gaussian filter, order 0 equates to NO filtering
-axis string Z Axis Direction - X, Y or Z
-method enum bisect Interface location method: bisect or functional
-d1 real 0 Bulk density phase 1 (at small z)
-d2 real 1000 Bulk density phase 2 (at large z)
-tblock int 100 Number of frames in one time-block average
-nlevel int 100 Number of Height levels in 2D - XPixMaps
+

+


+ + diff -Nru gromacs-4.5.4/share/html/online/g_tcaf.html gromacs-4.5.5/share/html/online/g_tcaf.html --- gromacs-4.5.4/share/html/online/g_tcaf.html 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/html/online/g_tcaf.html 2011-09-21 12:34:10.000000000 +0000 @@ -16,7 +16,7 @@

g_tcaf computes tranverse current autocorrelations. These are used to estimate the shear viscosity eta. -For details see: Palmer, JCP 49 (1994) pp 359-366.

+For details see: Palmer, Phys. Rev. E 49 (1994) pp 359-366.

Transverse currents are calculated using the k-vectors (1,0,0) and (2,0,0) each also in the y- and z-direction, (1,1,0) and (1,-1,0) each also in the 2 other planes (these vectors diff -Nru gromacs-4.5.4/share/html/online/Makefile.am gromacs-4.5.5/share/html/online/Makefile.am --- gromacs-4.5.4/share/html/online/Makefile.am 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/share/html/online/Makefile.am 2011-09-21 12:34:32.000000000 +0000 @@ -35,7 +35,7 @@ g_dielectric.html g_saltbr.html mdrun.html xrama.html \ g_dih.html g_sas.html mk_angndx.html xtc.html \ g_dipoles.html g_sgangle.html mtx.html xvg.html \ - g_densmap.html g_sham.html make_edi.html \ + g_densmap.html g_sham.html make_edi.html g_densorder.html \ style.css \ water.html gmxdemo.html speptide.html yourown.html \ methanol.html mixed.html protunf.html diff -Nru gromacs-4.5.4/share/html/online/Makefile.in gromacs-4.5.5/share/html/online/Makefile.in --- gromacs-4.5.4/share/html/online/Makefile.in 2011-03-21 15:13:36.000000000 +0000 +++ gromacs-4.5.5/share/html/online/Makefile.in 2011-09-21 12:38:30.000000000 +0000 @@ -246,7 +246,7 @@ g_dielectric.html g_saltbr.html mdrun.html xrama.html \ g_dih.html g_sas.html mk_angndx.html xtc.html \ g_dipoles.html g_sgangle.html mtx.html xvg.html \ - g_densmap.html g_sham.html make_edi.html \ + g_densmap.html g_sham.html make_edi.html g_densorder.html \ style.css \ water.html gmxdemo.html speptide.html yourown.html \ methanol.html mixed.html protunf.html diff -Nru gromacs-4.5.4/share/html/online/mdp_opt.html gromacs-4.5.5/share/html/online/mdp_opt.html --- gromacs-4.5.4/share/html/online/mdp_opt.html 2011-03-14 13:33:32.000000000 +0000 +++ gromacs-4.5.5/share/html/online/mdp_opt.html 2011-09-21 12:34:10.000000000 +0000 @@ -375,7 +375,7 @@

precision to write to xtc trajectory
xtc_grps:
group(s) to write to xtc trajectory, default the whole system is written -(if nstxtcout is larger than zero)
+(if nstxtcout > 0)
energygrps:
group(s) to write to energy file
@@ -406,11 +406,11 @@ as determined at the previous neighbor search. Coordinate scaling due to pressure coupling or the deform option is taken into account. -This option guarantees that their are no cut-off artifacts. -But for larger systems this can come at a high computational cost, +This option guarantees that their are no cut-off artifacts, +but for larger systems this can come at a high computational cost, since the neighbor list update frequency will be determined by just one or two particles moving slightly beyond the half buffer length -(which not even necessarily implies that the neighbor list is invalid), +(which does not necessarily imply that the neighbor list is invalid), while 99.99% of the particles are fine. @@ -449,10 +449,10 @@
periodic_molecules:
no
-
molecules are finite, fast molecular pbc can be used
+
molecules are finite, fast molecular PBC can be used
yes
for systems with molecules that couple to themselves through -the periodic boundary conditions, this requires a slower pbc algorithm +the periodic boundary conditions, this requires a slower PBC algorithm and molecules are not made whole in the output
@@ -511,12 +511,12 @@ Reasonable grid spacing for PPPM is 0.05-0.1 nm. See Shift for the details of the particle-particle potential.
-NOTE: PPPM is not functional in the current version, we plan to implement +NOTE: PPPM is not functional in the current version, but we plan to implement PPPM through a small modification of the PME code.
Reaction-Field
Reaction field with Coulomb cut-off rcoulomb, -where rcoulomb &ge rlist. +where rcoulombrlist. The dielectric constant beyond the cut-off is epsilon_rf. The dielectric constant can be set to infinity by setting epsilon_rf=0.
@@ -1005,7 +1005,7 @@ i.e. bonds are represented by a harmonic (or other) potential or a Morse potential (depending on the setting of morse) and angles by a harmonic (or other) potential. -
hbonds
+
h-bonds
Convert the bonds with H-atoms to constraints.
all-bonds
Convert all bonds to constraints.
diff -Nru gromacs-4.5.4/share/top/amber03.ff/forcefield.doc gromacs-4.5.5/share/top/amber03.ff/forcefield.doc --- gromacs-4.5.4/share/top/amber03.ff/forcefield.doc 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber03.ff/forcefield.doc 2011-09-21 12:34:10.000000000 +0000 @@ -1,4 +1,4 @@ -AMBER03 force field (Duan et al., J. Comp. Chem. 24, 1999-2012, 2003) +AMBER03 protein, nucleic AMBER94 (Duan et al., J. Comp. Chem. 24, 1999-2012, 2003) ******************************************************************** * The original ffamber ports were written by Eric J. Sorin, * diff -Nru gromacs-4.5.4/share/top/amber03.ff/ions.itp gromacs-4.5.5/share/top/amber03.ff/ions.itp --- gromacs-4.5.4/share/top/amber03.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber03.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -4,7 +4,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 IB 1 IB+ IB 1 1.00000 +1 IB 1 IB+ IB 1 1.00000 [ moleculetype ] @@ -13,7 +13,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 C0 1 CA CA 1 2.00000 +1 C0 1 CA CA 1 2.00000 [ moleculetype ] @@ -22,7 +22,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cl 1 CL CL 1 -1.00000 +1 Cl 1 CL CL 1 -1.00000 [ moleculetype ] @@ -31,7 +31,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Na 1 NA NA 1 1.00000 +1 Na 1 NA NA 1 1.00000 [ moleculetype ] @@ -40,7 +40,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 MG 1 MG MG 1 2.00000 +1 MG 1 MG MG 1 2.00000 [ moleculetype ] @@ -49,7 +49,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 K 1 K K 1 1.00000 +1 K 1 K K 1 1.00000 [ moleculetype ] @@ -58,7 +58,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Rb 1 RB RB 1 1.00000 +1 Rb 1 RB RB 1 1.00000 [ moleculetype ] @@ -67,7 +67,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cs 1 CS CS 1 1.00000 +1 Cs 1 CS CS 1 1.00000 [ moleculetype ] @@ -76,7 +76,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Li 1 LI LI 1 1.00000 +1 Li 1 LI LI 1 1.00000 [ moleculetype ] @@ -85,4 +85,4 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Zn 1 ZN ZN 1 2.00000 +1 Zn 1 ZN ZN 1 2.00000 diff -Nru gromacs-4.5.4/share/top/amber94.ff/ions.itp gromacs-4.5.5/share/top/amber94.ff/ions.itp --- gromacs-4.5.4/share/top/amber94.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber94.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -4,7 +4,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 IB 1 IB+ IB 1 1.00000 +1 IB 1 IB+ IB 1 1.00000 [ moleculetype ] @@ -13,7 +13,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 C0 1 CA CA 1 2.00000 +1 C0 1 CA CA 1 2.00000 [ moleculetype ] @@ -22,7 +22,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cl 1 CL CL 1 -1.00000 +1 Cl 1 CL CL 1 -1.00000 [ moleculetype ] @@ -31,7 +31,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Na 1 NA NA 1 1.00000 +1 Na 1 NA NA 1 1.00000 [ moleculetype ] @@ -40,7 +40,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 MG 1 MG MG 1 2.00000 +1 MG 1 MG MG 1 2.00000 [ moleculetype ] @@ -49,7 +49,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 K 1 K K 1 1.00000 +1 K 1 K K 1 1.00000 [ moleculetype ] @@ -58,7 +58,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Rb 1 RB RB 1 1.00000 +1 Rb 1 RB RB 1 1.00000 [ moleculetype ] @@ -67,7 +67,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cs 1 CS CS 1 1.00000 +1 Cs 1 CS CS 1 1.00000 [ moleculetype ] @@ -76,7 +76,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Li 1 LI LI 1 1.00000 +1 Li 1 LI LI 1 1.00000 [ moleculetype ] @@ -85,4 +85,4 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Zn 1 ZN ZN 1 2.00000 +1 Zn 1 ZN ZN 1 2.00000 diff -Nru gromacs-4.5.4/share/top/amber96.ff/forcefield.doc gromacs-4.5.5/share/top/amber96.ff/forcefield.doc --- gromacs-4.5.4/share/top/amber96.ff/forcefield.doc 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber96.ff/forcefield.doc 2011-09-21 12:34:10.000000000 +0000 @@ -1,4 +1,4 @@ -AMBER96 force field (Kollman et al., Acc. Chem. Res. 29, 461-469, 1996) +AMBER96 protein, nucleic AMBER94 (Kollman et al., Acc. Chem. Res. 29, 461-469, 1996) ******************************************************************** * The original ffamber ports were written by Eric J. Sorin, * diff -Nru gromacs-4.5.4/share/top/amber99.ff/forcefield.doc gromacs-4.5.5/share/top/amber99.ff/forcefield.doc --- gromacs-4.5.4/share/top/amber99.ff/forcefield.doc 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber99.ff/forcefield.doc 2011-09-21 12:34:10.000000000 +0000 @@ -1,4 +1,4 @@ -AMBER99 force field (Wang et al., J. Comp. Chem. 21, 1049-1074, 2000) +AMBER99 protein, nucleic AMBER94 (Wang et al., J. Comp. Chem. 21, 1049-1074, 2000) ******************************************************************** * The original ffamber ports were written by Eric J. Sorin, * diff -Nru gromacs-4.5.4/share/top/amber99.ff/ions.itp gromacs-4.5.5/share/top/amber99.ff/ions.itp --- gromacs-4.5.4/share/top/amber99.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber99.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -4,7 +4,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 IB 1 IB+ IB 1 1.00000 +1 IB 1 IB+ IB 1 1.00000 [ moleculetype ] @@ -13,7 +13,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 C0 1 CA CA 1 2.00000 +1 C0 1 CA CA 1 2.00000 [ moleculetype ] @@ -22,7 +22,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cl 1 CL CL 1 -1.00000 +1 Cl 1 CL CL 1 -1.00000 [ moleculetype ] @@ -31,7 +31,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Na 1 NA NA 1 1.00000 +1 Na 1 NA NA 1 1.00000 [ moleculetype ] @@ -40,7 +40,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 MG 1 MG MG 1 2.00000 +1 MG 1 MG MG 1 2.00000 [ moleculetype ] @@ -49,7 +49,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 K 1 K K 1 1.00000 +1 K 1 K K 1 1.00000 [ moleculetype ] @@ -58,7 +58,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Rb 1 RB RB 1 1.00000 +1 Rb 1 RB RB 1 1.00000 [ moleculetype ] @@ -67,7 +67,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cs 1 CS CS 1 1.00000 +1 Cs 1 CS CS 1 1.00000 [ moleculetype ] @@ -76,7 +76,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Li 1 LI LI 1 1.00000 +1 Li 1 LI LI 1 1.00000 [ moleculetype ] @@ -85,4 +85,4 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Zn 1 ZN ZN 1 2.00000 +1 Zn 1 ZN ZN 1 2.00000 diff -Nru gromacs-4.5.4/share/top/amber99sb.ff/forcefield.doc gromacs-4.5.5/share/top/amber99sb.ff/forcefield.doc --- gromacs-4.5.4/share/top/amber99sb.ff/forcefield.doc 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber99sb.ff/forcefield.doc 2011-09-21 12:34:10.000000000 +0000 @@ -1,4 +1,4 @@ -AMBER99SB force field (Hornak et al., Proteins 65, 712-725, 2006) +AMBER99SB protein, nucleic AMBER94 (Hornak et al., Proteins 65, 712-725, 2006) ******************************************************************** * The original ffamber ports were written by Eric J. Sorin, * diff -Nru gromacs-4.5.4/share/top/amber99sb.ff/ions.itp gromacs-4.5.5/share/top/amber99sb.ff/ions.itp --- gromacs-4.5.4/share/top/amber99sb.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber99sb.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -4,7 +4,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 IB 1 IB+ IB 1 1.00000 +1 IB 1 IB+ IB 1 1.00000 [ moleculetype ] @@ -13,7 +13,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 C0 1 CA CA 1 2.00000 +1 C0 1 CA CA 1 2.00000 [ moleculetype ] @@ -22,7 +22,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cl 1 CL CL 1 -1.00000 +1 Cl 1 CL CL 1 -1.00000 [ moleculetype ] @@ -31,7 +31,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Na 1 NA NA 1 1.00000 +1 Na 1 NA NA 1 1.00000 [ moleculetype ] @@ -40,7 +40,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 MG 1 MG MG 1 2.00000 +1 MG 1 MG MG 1 2.00000 [ moleculetype ] @@ -49,7 +49,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 K 1 K K 1 1.00000 +1 K 1 K K 1 1.00000 [ moleculetype ] @@ -58,7 +58,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Rb 1 RB RB 1 1.00000 +1 Rb 1 RB RB 1 1.00000 [ moleculetype ] @@ -67,7 +67,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cs 1 CS CS 1 1.00000 +1 Cs 1 CS CS 1 1.00000 [ moleculetype ] @@ -76,7 +76,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Li 1 LI LI 1 1.00000 +1 Li 1 LI LI 1 1.00000 [ moleculetype ] @@ -85,4 +85,4 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Zn 1 ZN ZN 1 2.00000 +1 Zn 1 ZN ZN 1 2.00000 diff -Nru gromacs-4.5.4/share/top/amber99sb-ildn.ff/forcefield.doc gromacs-4.5.5/share/top/amber99sb-ildn.ff/forcefield.doc --- gromacs-4.5.4/share/top/amber99sb-ildn.ff/forcefield.doc 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber99sb-ildn.ff/forcefield.doc 2011-09-21 12:34:10.000000000 +0000 @@ -1,4 +1,4 @@ -AMBER99SB-ILDN force field (Lindorff-Larsen et al., Proteins 78, 1950-58, 2010) +AMBER99SB-ILDN protein, nucleic AMBER94 (Lindorff-Larsen et al., Proteins 78, 1950-58, 2010) ******************************************************************** * Amber99sb-ildn is an improvement to Amber99SB by * diff -Nru gromacs-4.5.4/share/top/amber99sb-ildn.ff/ions.itp gromacs-4.5.5/share/top/amber99sb-ildn.ff/ions.itp --- gromacs-4.5.4/share/top/amber99sb-ildn.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amber99sb-ildn.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -4,7 +4,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 IB 1 IB+ IB 1 1.00000 +1 IB 1 IB+ IB 1 1.00000 [ moleculetype ] @@ -13,7 +13,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 C0 1 CA CA 1 2.00000 +1 C0 1 CA CA 1 2.00000 [ moleculetype ] @@ -22,7 +22,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cl 1 CL CL 1 -1.00000 +1 Cl 1 CL CL 1 -1.00000 [ moleculetype ] @@ -31,7 +31,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Na 1 NA NA 1 1.00000 +1 Na 1 NA NA 1 1.00000 [ moleculetype ] @@ -40,7 +40,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 MG 1 MG MG 1 2.00000 +1 MG 1 MG MG 1 2.00000 [ moleculetype ] @@ -49,7 +49,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 K 1 K K 1 1.00000 +1 K 1 K K 1 1.00000 [ moleculetype ] @@ -58,7 +58,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Rb 1 RB RB 1 1.00000 +1 Rb 1 RB RB 1 1.00000 [ moleculetype ] @@ -67,7 +67,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cs 1 CS CS 1 1.00000 +1 Cs 1 CS CS 1 1.00000 [ moleculetype ] @@ -76,7 +76,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Li 1 LI LI 1 1.00000 +1 Li 1 LI LI 1 1.00000 [ moleculetype ] @@ -85,4 +85,4 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Zn 1 ZN ZN 1 2.00000 +1 Zn 1 ZN ZN 1 2.00000 diff -Nru gromacs-4.5.4/share/top/amberGS.ff/aminoacids.rtp gromacs-4.5.5/share/top/amberGS.ff/aminoacids.rtp --- gromacs-4.5.4/share/top/amberGS.ff/aminoacids.rtp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amberGS.ff/aminoacids.rtp 2011-09-21 12:34:32.000000000 +0000 @@ -1994,7 +1994,6 @@ CZ3 CD2 CE3 HE3 CG NE1 CD1 HD1 CD1 CG CB CD2 - [ CPHE ] [ atoms ] diff -Nru gromacs-4.5.4/share/top/amberGS.ff/ffbonded.itp gromacs-4.5.5/share/top/amberGS.ff/ffbonded.itp --- gromacs-4.5.4/share/top/amberGS.ff/ffbonded.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amberGS.ff/ffbonded.itp 2011-09-21 12:34:32.000000000 +0000 @@ -1,18 +1,5 @@ [ bondtypes ] ; i j func b0 kb - C C 1 0.1525 259408.0 ; new99 - C OS 1 0.1323 376560.0 ; new99 - C H4 1 0.1080 307105.6 ; new99 - C H5 1 0.1080 307105.6 ; new99 - CA OH 1 0.1364 376560.0 ; new99 - CM OS 1 0.1240 401664.0 ; new99 - Cl CT 1 0.1766 194137.6 ; new99 - Br CT 1 0.1944 133051.2 ; new99 - I CT 1 0.2166 123846.4 ; new99 - F CA 1 0.1359 323004.8 ; new99 - Cl CA 1 0.1727 161502.4 ; new99 - I CA 1 0.2075 143092.8 ; new99 - Br CA 1 0.1890 143929.6 ; new99 OW HW 1 0.09572 462750.4 ; P water HW HW 1 0.15136 462750.4 ; P water C CA 1 0.14090 392459.2 ; 7,(1986),230; TYR @@ -123,51 +110,13 @@ ; i j k func th0 cth HW OW HW 1 104.520 836.800 ; TIP3P water HW HW OW 1 127.740 0.000 ; (found in crystallographic water with 3 bonds) -C C O 1 120.000 669.440 ; new99 -C C OH 1 120.000 669.440 ; new99 -CT C CT 1 117.000 527.184 ; new99 -CT C OS 1 115.000 669.440 ; new99 -O C OS 1 125.000 669.440 ; new99 -H4 C C 1 120.000 418.400 ; new99 -H4 C CM 1 115.000 418.400 ; new99 -H4 C CT 1 115.000 418.400 ; new99 -H4 C O 1 120.000 418.400 ; new99 -H4 C OH 1 120.000 418.400 ; new99 -H5 C N 1 120.000 418.400 ; new99 -H5 C O 1 119.000 418.400 ; new99 -H5 C OH 1 107.000 418.400 ; new99 -H5 C OS 1 107.000 418.400 ; new99 -CA CA OH 1 120.000 585.760 ; new99 -CA OH HO 1 113.000 418.400 ; new99 -F CA CA 1 121.000 585.760 ; new99 -Cl CA CA 1 118.800 585.760 ; new99 -Br CA CA 1 118.800 585.760 ; new99 -I CA CA 1 118.800 585.760 ; new99 -CM CM OS 1 125.000 669.440 ; new99 -H4 CM OS 1 113.000 418.400 ; new99 -HA CM HA 1 120.000 292.880 ; new99 -HA CM CT 1 120.000 418.400 ; new99 -H1 CT CM 1 109.500 418.400 ; new99 -HC CT CM 1 109.500 418.400 ; new99 -C CT OS 1 109.500 502.080 ; new99 -CM CT CT 1 111.000 527.184 ; new99 -CM CT OS 1 109.500 418.400 ; new99 -CT CT CA 1 114.000 527.184 ; new99 -OS CT OS 1 101.000 502.080 ; new99 -F CT CT 1 109.000 418.400 ; new99 -F CT H2 1 109.500 418.400 ; new99 -Cl CT CT 1 108.500 418.400 ; new99 -Cl CT H1 1 108.500 418.400 ; new99 -Br CT CT 1 108.000 418.400 ; new99 -Br CT H1 1 106.500 418.400 ; new99 -I CT CT 1 106.000 418.400 ; new99 CB C NA 1 111.300 585.760 ; NA CB C O 1 128.800 669.440 ; CM C NA 1 114.100 585.760 ; CM C O 1 125.300 669.440 ; CT C O 1 120.400 669.440 ; CT C O2 1 117.000 585.760 ; -CT C OH 1 110.000 669.440 ; new99 +CT C OH 1 117.000 585.760 ; N* C NA 1 115.400 585.760 ; N* C NC 1 118.600 585.760 ; N* C O 1 120.900 669.440 ; @@ -177,17 +126,17 @@ N C O 1 122.900 669.440 ; AA general O C O 1 126.000 669.440 ; AA COO- terminal residues O2 C O2 1 126.000 669.440 ; AA GLU (SCH JPC 79,2379) -O C OH 1 120.000 669.440 ; +O C OH 1 126.000 669.440 ; CA C CA 1 120.000 527.184 ; changed from 85.0 bsd on C6H6 nmodes; AA tyr CA C OH 1 120.000 585.760 ; AA tyr C CA CA 1 120.000 527.184 ; changed from 85.0 bsd on C6H6 nmodes CA CA CA 1 120.000 527.184 ; changed from 85.0 bsd on C6H6 nmodes CA CA CB 1 120.000 527.184 ; changed from 85.0 bsd on C6H6 nmodes CA CA CT 1 120.000 585.760 ; -CA CA HA 1 120.000 418.400 ; new99 -CA CA H4 1 120.000 418.400 ; new99 -CB CA HA 1 120.000 418.400 ; new99 -CB CA H4 1 120.000 418.400 ; new99 +CA CA HA 1 120.000 292.880 ; +CA CA H4 1 120.000 292.880 ; +CB CA HA 1 120.000 292.880 ; +CB CA H4 1 120.000 292.880 ; CB CA N2 1 123.500 585.760 ; CB CA NC 1 117.300 585.760 ; CM CA N2 1 120.100 585.760 ; @@ -195,9 +144,9 @@ N2 CA NA 1 116.000 585.760 ; N2 CA NC 1 119.300 585.760 ; NA CA NC 1 123.300 585.760 ; -C CA HA 1 120.000 418.400 ; new99 tyr +C CA HA 1 120.000 292.880 ; AA tyr N2 CA N2 1 120.000 585.760 ; AA arg -CN CA HA 1 120.000 418.400 ; new99 trp +CN CA HA 1 120.000 292.880 ; AA trp CA CA CN 1 120.000 527.184 ; changed from 85.0 bsd on C6H6 nmodes; AA trp C CB CB 1 119.200 527.184 ; changed from 85.0 bsd on C6H6 nmodes; NA gua C CB NB 1 130.000 585.760 ; @@ -210,22 +159,22 @@ C* CB CA 1 134.900 527.184 ; changed from 85.0 bsd on C6H6 nmodes; AA trp C* CB CN 1 108.800 527.184 ; changed from 85.0 bsd on C6H6 nmodes; AA trp CA CB CN 1 116.200 527.184 ; changed from 85.0 bsd on C6H6 nmodes; AA trp -H5 CK N* 1 123.050 418.400 ; new99 -H5 CK NB 1 123.050 418.400 ; new99 +H5 CK N* 1 123.050 292.880 ; +H5 CK NB 1 123.050 292.880 ; N* CK NB 1 113.900 585.760 ; C CM CM 1 120.700 527.184 ; changed from 85.0 bsd on C6H6 nmodes; NA thy C CM CT 1 119.700 585.760 ; -C CM HA 1 119.700 418.400 ; new99 -C CM H4 1 119.700 418.400 ; new99 +C CM HA 1 119.700 292.880 ; +C CM H4 1 119.700 292.880 ; CA CM CM 1 117.000 527.184 ; changed from 85.0 bsd on C6H6 nmodes; NA cyt -CA CM HA 1 123.300 418.400 ; new99 -CA CM H4 1 123.300 418.400 ; new99 +CA CM HA 1 123.300 292.880 ; +CA CM H4 1 123.300 292.880 ; CM CM CT 1 119.700 585.760 ; -CM CM HA 1 119.700 418.400 ; new99 -CM CM H4 1 119.700 418.400 ; new99 +CM CM HA 1 119.700 292.880 ; +CM CM H4 1 119.700 292.880 ; CM CM N* 1 121.200 585.760 ; -H4 CM N* 1 119.100 418.400 ; new99 -H5 CQ NC 1 115.450 418.400 ; new99 +H4 CM N* 1 119.100 292.880 ; +H5 CQ NC 1 115.450 292.880 ; NC CQ NC 1 129.100 585.760 ; CM CT HC 1 109.500 418.400 ; changed based on NMA nmodes CT CT CT 1 109.500 334.720 ; @@ -275,17 +224,17 @@ CW CC NA 1 120.000 585.760 ; AA his CW CC NB 1 120.000 585.760 ; AA his CT CC CW 1 120.000 585.760 ; AA his -H5 CR NA 1 120.000 418.400 ; new99 his -H5 CR NB 1 120.000 418.400 ; new99 his +H5 CR NA 1 120.000 292.880 ; AA his +H5 CR NB 1 120.000 292.880 ; AA his NA CR NA 1 120.000 585.760 ; AA his NA CR NB 1 120.000 585.760 ; AA his -CC CV H4 1 120.000 418.400 ; new99 his +CC CV H4 1 120.000 292.880 ; AA his CC CV NB 1 120.000 585.760 ; AA his -H4 CV NB 1 120.000 418.400 ; new99 his -CC CW H4 1 120.000 418.400 ; new99 his +H4 CV NB 1 120.000 292.880 ; AA his +CC CW H4 1 120.000 292.880 ; AA his CC CW NA 1 120.000 585.760 ; AA his -H4 CW NA 1 120.000 418.400 ; new99 his -C* CW H4 1 120.000 418.400 ; new99 trp +H4 CW NA 1 120.000 292.880 ; AA his +C* CW H4 1 120.000 292.880 ; AA trp C* CW NA 1 108.700 585.760 ; AA trp CT C* CW 1 125.000 585.760 ; AA trp CB C* CT 1 128.600 585.760 ; AA trp @@ -294,38 +243,38 @@ CB CN NA 1 104.400 585.760 ; AA trp CA CN CB 1 122.700 527.184 ; changed from 85.0 bsd on C6H6 nmodes; AA trp C N CT 1 121.900 418.400 ; AA general -C N H 1 120.000 418.400 ; new99 general, gln, asn,changed based on NMA nmodes -CT N H 1 118.040 418.400 ; new99 general, changed based on NMA nmodes +C N H 1 120.000 251.040 ; AA general, gln, asn,changed based on NMA nmodes +CT N H 1 118.040 251.040 ; AA general, changed based on NMA nmodes CT N CT 1 118.000 418.400 ; AA pro (DETAR JACS 99,1232) H N H 1 120.000 292.880 ; ade,cyt,gua,gln,asn ** C N* CM 1 121.600 585.760 ; C N* CT 1 117.600 585.760 ; -C N* H 1 119.200 418.400 ; new99 +C N* H 1 119.200 251.040 ; changed based on NMA nmodes CB N* CK 1 105.400 585.760 ; CB N* CT 1 125.800 585.760 ; -CB N* H 1 125.800 418.400 ; new99 +CB N* H 1 125.800 251.040 ; for unmethylated n.a. bases,chngd bsd NMA nmodes CK N* CT 1 128.800 585.760 ; -CK N* H 1 128.800 418.400 ; new99 for unmethylated n.a. bases,chngd bsd NMA nmodes +CK N* H 1 128.800 251.040 ; for unmethylated n.a. bases,chngd bsd NMA nmodes CM N* CT 1 121.200 585.760 ; -CM N* H 1 121.200 418.400 ; new99 for unmethylated n.a. bases,chngd bsd NMA nmodes -CA N2 H 1 120.000 418.400 ; new99 +CM N* H 1 121.200 251.040 ; for unmethylated n.a. bases,chngd bsd NMA nmodes +CA N2 H 1 120.000 292.880 ; H N2 H 1 120.000 292.880 ; -CT N2 H 1 118.400 418.400 ; new99 arg +CT N2 H 1 118.400 292.880 ; AA arg CA N2 CT 1 123.200 418.400 ; AA arg CT N3 H 1 109.500 418.400 ; AA lys, changed based on NMA nmodes CT N3 CT 1 109.500 418.400 ; AA pro/nt H N3 H 1 109.500 292.880 ; AA lys, AA(end) C NA C 1 126.400 585.760 ; C NA CA 1 125.200 585.760 ; -C NA H 1 116.800 418.400 ; new99 -CA NA H 1 118.000 418.400 ; new99 +C NA H 1 116.800 251.040 ; changed based on NMA nmodes +CA NA H 1 118.000 251.040 ; changed based on NMA nmodes CC NA CR 1 120.000 585.760 ; AA his -CC NA H 1 120.000 418.400 ; new99 his +CC NA H 1 120.000 251.040 ; AA his, changed based on NMA nmodes CR NA CW 1 120.000 585.760 ; AA his -CR NA H 1 120.000 418.400 ; new99 his -CW NA H 1 120.000 418.400 ; new99 his +CR NA H 1 120.000 251.040 ; AA his, changed based on NMA nmodes +CW NA H 1 120.000 251.040 ; AA his, changed based on NMA nmodes CN NA CW 1 111.600 585.760 ; AA trp -CN NA H 1 123.100 418.400 ; new99 trp +CN NA H 1 123.100 251.040 ; AA trp, changed based on NMA nmodes CB NB CK 1 103.800 585.760 ; CC NB CR 1 117.000 585.760 ; AA his CR NB CV 1 117.000 585.760 ; AA his @@ -333,7 +282,7 @@ CA NC CB 1 112.200 585.760 ; CA NC CQ 1 118.600 585.760 ; CB NC CQ 1 111.000 585.760 ; -C OH HO 1 113.000 418.400 ; new99 +C OH HO 1 113.000 292.880 ; CT OH HO 1 108.500 460.240 ; HO OH P 1 108.500 376.560 ; CT OS CT 1 109.500 502.080 ; @@ -349,42 +298,37 @@ CT SH HS 1 96.000 359.824 ; changed from 44.0 based on methanethiol nmodes HS SH HS 1 92.070 292.880 ; AA cys F CT F 1 109.100 644.336 ; JCC,13,(1992),963; -F CT H1 1 109.500 418.400 ; new99 +F CT H1 1 109.500 292.880 ; JCC,13,(1992),963; N C N 1 120.000 585.760 ; Added for Urea (same as N2-CA-N2) - EJS [ dihedraltypes ] ;i j k l func phase kd pn -CA CA CA OH 4 180.00 4.60240 2 ; new99 -H5 O C OH 4 180.00 4.60240 2 ; new99 -H5 O C OS 4 180.00 4.60240 2 ; new99 -CM CT CM HA 4 180.00 4.60240 2 ; new99 -CA CA CA Br 4 180.00 4.60240 2 ; new99 -CM H4 C O 4 180.00 4.60240 2 ; new99 -C CT N H 4 180.00 4.60240 2 ; new99 -C CT N O 4 180.00 4.60240 2 ; new99 +;impropers treated as propers in GROMACS to use correct AMBER analytical function CB CK N* CT 4 180.00 4.18400 2 ; -CK CB N* CT 4 180.00 4.18400 2 ; +CK CB N* CT 4 180.00 4.18400 2 ; +CM C N* CT 4 180.00 4.18400 2 ; dac guess, 9/94 C CM N* CT 4 180.00 4.18400 2 ; dac guess, 9/94 CT N* C CM 4 180.00 4.18400 2 ; CM C CM CT 4 180.00 4.60240 2 ; +C CM CM CT 4 180.00 4.60240 2 ; CT O C OH 4 180.00 43.93200 2 ; +CT CV CC NA 4 180.00 4.60240 2 ; NA CV CC CT 4 180.00 4.60240 2 ; +CT CW CC NB 4 180.00 4.60240 2 ; NB CW CC CT 4 180.00 4.60240 2 ; +CT CW CC NA 4 180.00 4.60240 2 ; NA CW CC CT 4 180.00 4.60240 2 ; +CB CT C* CW 4 180.00 4.60240 2 ; CW CB C* CT 4 180.00 4.60240 2 ; CA CA CA CT 4 180.00 4.60240 2 ; C CM CM CT 4 180.00 4.60240 2 ; dac guess, 9/94 +CM N2 CA NC 4 180.00 4.60240 2 ; dac guess, 9/94 NC CM CA N2 4 180.00 4.60240 2 ; dac guess, 9/94 +CB N2 CA NC 4 180.00 4.60240 2 ; dac, 10/94 CB NC CA N2 4 180.00 4.60240 2 ; dac, 10/94 +N2 NA CA NC 4 180.00 4.60240 2 ; dac, 10/94 NA NC CA N2 4 180.00 4.60240 2 ; dac, 10/94 CA CA C OH 4 180.00 4.60240 2 ; -CT CV CC NA 4 180.00 4.60240 2 ; -CT CW CC NB 4 180.00 4.60240 2 ; -CT CW CC NA 4 180.00 4.60240 2 ; -CB CT C* CW 4 180.00 4.60240 2 ; -CM N2 CA NC 4 180.00 4.60240 2 ; -CB N2 CA NC 4 180.00 4.60240 2 ; -N2 NA CA NC 4 180.00 4.60240 2 ; N N C O 4 180.00 43.93200 2 ; urea X O2 C O2 4 180.00 43.93200 2 ; JCC,7,(1986),230 X N2 CA N2 4 180.00 43.93200 2 ; JCC,7,(1986),230 @@ -406,94 +350,46 @@ [ dihedraltypes ] -;i j k l func - CT CT OS CT 9 0.0 1.60247 3 ; +;i j k l func C0 ... C5 CT CT OS CT 9 180.0 0.41840 2 ; - C N CT C 9 0.0 1.12968 2 ; new for 99sb - C N CT C 9 0.0 1.75728 3 ; new for 99sb - N CT C N 9 180.0 1.88280 1 ; new for 99sb - N CT C N 9 180.0 6.61072 2 ; new for 99sb - N CT C N 9 180.0 2.30120 3 ; new for 99sb - CT CT N C 9 0.0 8.36800 1 ; new for 99sb - CT CT N C 9 0.0 8.36800 2 ; new for 99sb - CT CT N C 9 0.0 1.67360 3 ; new for 99sb - CT CT C N 9 0.0 0.83680 1 ; new for 99sb - CT CT C N 9 0.0 0.83680 2 ; new for 99sb - CT CT C N 9 0.0 1.67360 3 ; new for 99sb - H N C O 9 180.0 10.46000 2 ; JCC,7,(1986),230 + CT CT OS CT 9 0.0 1.60247 3 ; + C N CT C 9 0.0 0.0 1 ; AmberGS + N CT C N 9 0.0 0.0 1 ; AmberGS + CT CT N C 9 0.0 2.21752 1 ; + CT CT N C 9 180.0 0.62760 3 ; + CT CT N C 9 180.0 2.09200 4 ; + CT CT C N 9 0.0 0.29288 2 ; + CT CT C N 9 0.0 0.41840 4 ; H N C O 9 0.0 8.36800 1 ; J.C.cistrans-NMA DE + H N C O 9 180.0 10.46000 2 ; JCC,7,(1986),230 CT S S CT 9 0.0 14.64400 2 ; JCC,7,(1986),230 CT S S CT 9 0.0 2.51040 3 ; JCC,7,(1986),230 - OS CT CT OS 9 0.0 0.60250 3 ; parm98, TC,PC,PAK - OS CT CT OS 9 0.0 4.91620 2 ; Piotr et al. - OS CT CT OH 9 0.0 0.60250 3 ; parm98, TC,PC,PAK - OS CT CT OH 9 0.0 4.91620 2 ; parm98, TC,PC,PAK - OH CT CT OH 9 0.0 0.60250 3 ; parm98, TC,PC,PAK - OH CT CT OH 9 0.0 4.91620 2 ; parm98, TC,PC,PAK - OH P OS CT 9 0.0 1.04600 3 ; JCC,7,(1986),230 + OS CT CT OS 9 0.0 4.18400 2 ; pucker anal (93') + OS CT CT OS 9 0.0 0.60250 3 ; JCC,7,(1986),230 + OS CT CT OH 9 0.0 4.18400 2 ; pucker anal (93') + OS CT CT OH 9 0.0 0.60250 3 ; JCC,7,(1986),230 + OH CT CT OH 9 0.0 4.18400 2 ; check glicolWC? puc + OH CT CT OH 9 0.0 0.60250 3 ; JCC,7,(1986),230 OH P OS CT 9 0.0 5.02080 2 ; gg> ene.631g*/mp2 - OS P OS CT 9 0.0 1.04600 3 ; JCC,7,(1986),230 + OH P OS CT 9 0.0 1.04600 3 ; JCC,7,(1986),230 OS P OS CT 9 0.0 5.02080 2 ; gg> ene.631g*/mp2 - OS CT N* CK 9 0.0 10.46000 1 ; parm98, TC,PC,PAK - OS CT N* CM 9 0.0 10.46000 1 ; parm98, TC,PC,PAK - H1 CT C O 9 0.0 3.34720 1 ; Junmei et al, 1999 - H1 CT C O 9 180.0 0.33472 3 ; Junmei et al, 1999 - HC CT C O 9 0.0 3.34720 1 ; Junmei et al, 1999 - HC CT C O 9 180.0 0.33472 3 ; Junmei et al, 1999 - HC CT CT HC 9 0.0 0.62760 3 ; Junmei et al, 1999 - HC CT CT CT 9 0.0 0.66944 3 ; Junmei et al, 1999 - HC CT CM CM 9 180.0 1.58992 3 ; Junmei et al, 1999 - HC CT CM CM 9 0.0 4.81160 1 ; Junmei et al, 1999 - HO OH CT CT 9 0.0 0.66944 3 ; Junmei et al, 1999 - HO OH CT CT 9 0.0 1.04600 1 ; Junmei et al, 1999 - HO OH C O 9 180.0 9.62320 2 ; Junmei et al, 1999 - HO OH C O 9 0.0 7.94960 1 ; Junmei et al, 1999 - CM CM C O 9 180.0 9.10020 2 ; Junmei et al, 1999 - CM CM C O 9 0.0 1.25520 3 ; Junmei et al, 1999 - CT CM CM CT 9 180.0 27.82360 2 ; Junmei et al, 1999 - CT CM CM CT 9 180.0 7.94960 1 ; Junmei et al, 1999 - CT CT CT CT 9 0.0 0.75312 3 ; Junmei et al, 1999 - CT CT CT CT 9 180.0 1.04600 2 ; Junmei et al, 1999 - CT CT CT CT 9 180.0 0.83680 1 ; Junmei et al, 1999 - CT CT OS C 9 0.0 1.60247 3 ; Junmei et al, 1999 - CT CT OS C 9 180.0 3.34720 1 ; Junmei et al, 1999 - CT OS CT OS 9 0.0 0.41840 3 ; Junmei et al, 1999 - CT OS CT OS 9 180.0 3.55640 2 ; Junmei et al, 1999 - CT OS CT OS 9 180.0 5.64840 1 ; Junmei et al, 1999 - O C OS CT 9 180.0 11.29680 2 ; Junmei et al, 1999 - O C OS CT 9 180.0 5.85760 1 ; Junmei et al, 1999 - F CT CT F 9 180.0 5.02080 1 ; Junmei et al, 1999 - Cl CT CT Cl 9 180.0 1.88280 1 ; Junmei et al, 1999 - Br CT CT Br 9 0.0 0.00000 0 ; Junmei et al, 1999 - H1 CT CT OS 9 0.0 1.04600 1 ; Junmei et al, 1999 - H1 CT CT OH 9 0.0 1.04600 1 ; Junmei et al, 1999 - H1 CT CT F 9 0.0 0.79496 1 ; Junmei et al, 1999 - H1 CT CT Cl 9 0.0 1.04600 1 ; Junmei et al, 1999 - H1 CT CT Br 9 0.0 2.30120 1 ; Junmei et al, 1999 - HC CT CT OS 9 0.0 1.04600 1 ; Junmei et al, 1999 - HC CT CT OH 9 0.0 1.04600 1 ; Junmei et al, 1999 - HC CT CT F 9 0.0 0.79496 1 ; Junmei et al, 1999 - HC CT CT Cl 9 0.0 1.04600 1 ; Junmei et al, 1999 - HC CT CT Br 9 0.0 2.30120 1 ; Junmei et al, 1999 - CT OS CT N* 9 0.0 1.60247 3 ; parm98.dat, TC,PC,PAK - CT OS CT N* 9 0.0 2.71960 2 ; Piotr et al. - X C C X 9 180.0 15.16700 2 ; Junmei et al, 1999 - X C O X 9 180.0 11.71520 2 ; Junmei et al, 1999 - X C OS X 9 180.0 11.29680 2 ; Junmei et al, 1999 - X CA OH X 9 180.0 3.76560 2 ; Junmei et al, 99 - X CM OS X 9 180.0 4.39320 2 ; Junmei et al, 1999 + OS P OS CT 9 0.0 1.04600 3 ; JCC,7,(1986),230 + OS CT N* CK 9 0.0 10.46000 1 ; sugar frag calc (PC) + OS CT N* CK 9 180.0 2.09200 2 ; sugar frag calc (PC) + OS CT N* CM 9 0.0 10.46000 1 ; sugar frag calc (PC) + OS CT N* CM 9 180.0 2.09200 2 ; sugar frag calc (PC) X C CA X 9 180.0 15.16700 2 ; intrpol.bsd.on C6H6 X C CB X 9 180.0 12.55200 2 ; intrpol.bsd.on C6H6 X C CM X 9 180.0 9.10020 2 ; intrpol.bsd.on C6H6 X C N* X 9 180.0 6.06680 2 ; JCC,7,(1986),230 X C NA X 9 180.0 5.64840 2 ; JCC,7,(1986),230 X C NC X 9 180.0 16.73600 2 ; JCC,7,(1986),230 - X C OH X 9 180.0 9.62320 2 ; Junmei et al, 1999 - X C CT X 9 0.0 0.00000 0 ; JCC,7,(1986),230 + X C OH X 9 180.0 3.76560 2 ; JCC,7,(1986),230 + X C CT X 9 0.0 0.00000 2 ; JCC,7,(1986),230 X CA CA X 9 180.0 15.16700 2 ; intrpol.bsd.on C6H6 X CA CB X 9 180.0 14.64400 2 ; intrpol.bsd.on C6H6 X CA CM X 9 180.0 10.66920 2 ; intrpol.bsd.on C6H6 - X CA CT X 9 0.0 0.00000 0 ; JCC,7,(1986),230 + X CA CT X 9 0.0 0.00000 2 ; JCC,7,(1986),230 X CA N2 X 9 180.0 10.04160 2 ; reinterpolated 93' X CA NA X 9 180.0 6.27600 2 ; JCC,7,(1986),230 X CA NC X 9 180.0 20.08320 2 ; JCC,7,(1986),230 @@ -504,27 +400,27 @@ X CK N* X 9 180.0 7.11280 2 ; JCC,7,(1986),230 X CK NB X 9 180.0 41.84000 2 ; JCC,7,(1986),230 X CM CM X 9 180.0 27.82360 2 ; intrpol.bsd.on C6H6 - X CM CT X 9 0.0 0.00000 0 ; JCC,7,(1986),230 + X CM CT X 9 0.0 0.00000 3 ; JCC,7,(1986),230 X CM N* X 9 180.0 7.74040 2 ; JCC,7,(1986),230 X CQ NC X 9 180.0 28.45120 2 ; JCC,7,(1986),230 X CT CT X 9 0.0 0.65084 3 ; JCC,7,(1986),230 - X CT N X 9 0.0 0.00000 0 ; JCC,7,(1986),230 - X CT N* X 9 0.0 0.00000 0 ; JCC,7,(1986),230 - X CT N2 X 9 0.0 0.00000 0 ; JCC,7,(1986),230 + X CT N X 9 0.0 0.00000 2 ; JCC,7,(1986),230 + X CT N* X 9 0.0 0.00000 2 ; JCC,7,(1986),230 + X CT N2 X 9 0.0 0.00000 3 ; JCC,7,(1986),230 X CT OH X 9 0.0 0.69733 3 ; JCC,7,(1986),230 X CT OS X 9 0.0 1.60387 3 ; JCC,7,(1986),230 X OH P X 9 0.0 1.04600 3 ; JCC,7,(1986),230 X OS P X 9 0.0 1.04600 3 ; JCC,7,(1986),230 - X C N X 9 180.0 10.46000 2 ; AA,NMA + X C N X 9 180.0 10.46000 2 ; AA|check Wendy?&NMA X CT N3 X 9 0.0 0.65084 3 ; JCC,7,(1986),230 X CT S X 9 0.0 1.39467 3 ; JCC,7,(1986),230 X CT SH X 9 0.0 1.04600 3 ; JCC,7,(1986),230 X C* CB X 9 180.0 7.00820 2 ; intrpol.bsd.onC6H6aa - X C* CT X 9 0.0 0.00000 0 ; JCC,7,(1986),230 + X C* CT X 9 0.0 0.00000 2 ; JCC,7,(1986),230 X C* CW X 9 180.0 27.30060 2 ; intrpol.bsd.on C6H6 X CA CN X 9 180.0 15.16700 2 ; reinterpolated 93' X CB CN X 9 180.0 12.55200 2 ; reinterpolated 93' - X CC CT X 9 0.0 0.00000 0 ; JCC,7,(1986),230 + X CC CT X 9 0.0 0.00000 2 ; JCC,7,(1986),230 X CC CV X 9 180.0 21.54760 2 ; intrpol.bsd.on C6H6 X CC CW X 9 180.0 22.48900 2 ; intrpol.bsd.on C6H6 X CC NA X 9 180.0 5.85760 2 ; JCC,7,(1986),230 @@ -534,6 +430,3 @@ X CR NB X 9 180.0 20.92000 2 ; JCC,7,(1986),230 X CV NB X 9 180.0 10.04160 2 ; JCC,7,(1986),230 X CW NA X 9 180.0 6.27600 2 ; JCC,7,(1986),230 - - - diff -Nru gromacs-4.5.4/share/top/amberGS.ff/forcefield.itp gromacs-4.5.5/share/top/amberGS.ff/forcefield.itp --- gromacs-4.5.4/share/top/amberGS.ff/forcefield.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amberGS.ff/forcefield.itp 2011-09-21 12:34:32.000000000 +0000 @@ -10,7 +10,7 @@ ******************************************************************** #define _FF_AMBER -#define _FF_AMBER96 +#define _FF_AMBER94 [ defaults ] ; nbfunc comb-rule gen-pairs fudgeLJ fudgeQQ diff -Nru gromacs-4.5.4/share/top/amberGS.ff/gbsa.itp gromacs-4.5.5/share/top/amberGS.ff/gbsa.itp --- gromacs-4.5.4/share/top/amberGS.ff/gbsa.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amberGS.ff/gbsa.itp 2011-09-21 12:34:32.000000000 +0000 @@ -1,6 +1,7 @@ [ implicit_genborn_params ] ; atype sar st pi gbr hct +;H0 0.1 1 1 0.125 0.85 ; H C 0.172 1 1.554 0.1875 0.72 ; C CA 0.18 1 1.037 0.1875 0.72 ; C CB 0.172 0.012 1.554 0.1875 0.72 ; C diff -Nru gromacs-4.5.4/share/top/amberGS.ff/ions.itp gromacs-4.5.5/share/top/amberGS.ff/ions.itp --- gromacs-4.5.4/share/top/amberGS.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amberGS.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -4,7 +4,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 IB 1 IB+ IB 1 1.00000 +1 IB 1 IB+ IB 1 1.00000 [ moleculetype ] @@ -13,7 +13,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 C0 1 CA CA 1 2.00000 +1 C0 1 CA CA 1 2.00000 [ moleculetype ] @@ -22,7 +22,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cl 1 CL CL 1 -1.00000 +1 Cl 1 CL CL 1 -1.00000 [ moleculetype ] @@ -31,7 +31,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Na 1 NA NA 1 1.00000 +1 Na 1 NA NA 1 1.00000 [ moleculetype ] @@ -40,7 +40,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 MG 1 MG MG 1 2.00000 +1 MG 1 MG MG 1 2.00000 [ moleculetype ] @@ -49,7 +49,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 K 1 K K 1 1.00000 +1 K 1 K K 1 1.00000 [ moleculetype ] @@ -58,7 +58,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Rb 1 RB RB 1 1.00000 +1 Rb 1 RB RB 1 1.00000 [ moleculetype ] @@ -67,7 +67,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Cs 1 CS CS 1 1.00000 +1 Cs 1 CS CS 1 1.00000 [ moleculetype ] @@ -76,7 +76,7 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Li 1 LI LI 1 1.00000 +1 Li 1 LI LI 1 1.00000 [ moleculetype ] @@ -85,4 +85,4 @@ [ atoms ] ; id at type res nr residu name at name cg nr charge - 1 Zn 1 ZN ZN 1 2.00000 +1 Zn 1 ZN ZN 1 2.00000 diff -Nru gromacs-4.5.4/share/top/amberGS.ff/rna.r2b gromacs-4.5.5/share/top/amberGS.ff/rna.r2b --- gromacs-4.5.4/share/top/amberGS.ff/rna.r2b 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/amberGS.ff/rna.r2b 2011-09-21 12:34:32.000000000 +0000 @@ -1,7 +1,6 @@ ; rtp residue to rtp building block table ;GMX Force-field A RA RA5 RA3 RAN -T RT RT5 RT3 RTN U RU RU5 RU3 RUN C RC RC5 RC3 RCN G RG RG5 RG3 RGN diff -Nru gromacs-4.5.4/share/top/charmm27.ff/aminoacids.hdb gromacs-4.5.5/share/top/charmm27.ff/aminoacids.hdb --- gromacs-4.5.4/share/top/charmm27.ff/aminoacids.hdb 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/charmm27.ff/aminoacids.hdb 2011-09-21 12:34:32.000000000 +0000 @@ -40,6 +40,9 @@ 1 5 HA CA N C CB 2 6 HB CB CG CA 1 2 HD2 OD2 CG CB +CT3 2 +1 1 HN N -C CH3 +3 4 HH3 CH3 N HN CYS2 3 1 1 HN N -C CA 1 5 HA CA N C CB diff -Nru gromacs-4.5.4/share/top/charmm27.ff/aminoacids.rtp gromacs-4.5.5/share/top/charmm27.ff/aminoacids.rtp --- gromacs-4.5.4/share/top/charmm27.ff/aminoacids.rtp 2010-11-09 21:32:53.000000000 +0000 +++ gromacs-4.5.5/share/top/charmm27.ff/aminoacids.rtp 2011-09-21 12:34:32.000000000 +0000 @@ -1672,3 +1672,43 @@ [ ZN2 ] [ atoms ] ZN ZN 2.00 0 + +[ ACE ] + [ atoms ] + CH3 CT3 -0.270 0 + HH31 HA 0.090 1 + HH32 HA 0.090 2 + HH33 HA 0.090 3 + C C 0.510 4 + O O -0.510 5 + [ bonds ] + C CH3 + C +N + CH3 HH31 + CH3 HH32 + CH3 HH33 + O C + [ impropers ] + C CH3 +N O + +[ CT3 ] +; this can also be done with the .c.tdb, but the atom naming is different +; and this can matter + [ atoms ] + N NH1 -0.470 0 + HN H 0.310 1 + CH3 CT3 -0.110 2 + HH31 HA 0.090 3 + HH32 HA 0.090 4 + HH33 HA 0.090 5 + [ bonds ] + -C N + N HN + N CH3 + CH3 HH31 + CH3 HH32 + CH3 HH33 + + [ impropers ] + N -C CH3 HN + -C CH3 N -O diff -Nru gromacs-4.5.4/share/top/charmm27.ff/dna.c.tdb gromacs-4.5.5/share/top/charmm27.ff/dna.c.tdb --- gromacs-4.5.4/share/top/charmm27.ff/dna.c.tdb 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/charmm27.ff/dna.c.tdb 2011-09-21 12:34:32.000000000 +0000 @@ -7,4 +7,4 @@ O3' O3' ON5 15.9994 -0.66 [ Add ] 1 2 H3T O3' C3' C4' - HN5 1.008 0.43 + HN5 1.008 0.43 -1 diff -Nru gromacs-4.5.4/share/top/charmm27.ff/dna.n.tdb gromacs-4.5.5/share/top/charmm27.ff/dna.n.tdb --- gromacs-4.5.4/share/top/charmm27.ff/dna.n.tdb 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/charmm27.ff/dna.n.tdb 2011-09-21 12:34:32.000000000 +0000 @@ -10,7 +10,7 @@ C5' C5' CN8B 12.011 0.05 [ Add ] 1 2 H5T O5' C5' C4' - HN5 1.008 0.43 + HN5 1.008 0.43 -1 diff -Nru gromacs-4.5.4/share/top/charmm27.ff/ions.itp gromacs-4.5.5/share/top/charmm27.ff/ions.itp --- gromacs-4.5.4/share/top/charmm27.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/charmm27.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -1,68 +1,68 @@ [ moleculetype ] ; added by Bjelkmar Jan 2010, from c32b1/toppar/stream/toppar_water_ions.str -; molname nrexcl -OH 1 +; molname nrexcl +OH 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 OC 1 OH O1 1 -1.32 -2 H 1 OH H1 1 0.32 +; id at type res nr residu name at name cg nr charge mass +1 OC 1 OH O1 1 -1.32 +2 H 1 OH H1 1 0.32 [ bonds ] -;i j funct length force.c. -1 2 1 0.09700 456056 ; hydroxyl bond +;i j funct length force.c. +1 2 1 0.09700 456056 ; hydroxyl bond [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 SOD 1 NA NA 1 1 +; id at type res nr residu name at name cg nr charge +1 SOD 1 NA NA 1 1 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 MG 1 MG MG 1 2 +; id at type res nr residu name at name cg nr charge +1 MG 1 MG MG 1 2 [ moleculetype ] -; molname nrexcl -K 1 +; molname nrexcl +K 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 POT 1 K K 1 1 +; id at type res nr residu name at name cg nr charge +1 POT 1 K K 1 1 [ moleculetype ] -; molname nrexcl -Ces 1 +; molname nrexcl +CS 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 CES 1 Ces Ces 1 1 +; id at type res nr residu name at name cg nr charge +1 CES 1 CS CS 1 1 [ moleculetype ] -; molname nrexcl -Cal 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 CAL 1 Cal Cal 1 2 +; id at type res nr residu name at name cg nr charge +1 CAL 1 CA CA 1 2 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 CLA 1 CL CL 1 -1 +; id at type res nr residu name at name cg nr charge +1 CLA 1 CL CL 1 -1 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 ZN 1 ZN ZN 1 -2 +; id at type res nr residu name at name cg nr charge +1 ZN 1 ZN ZN 1 -2 diff -Nru gromacs-4.5.4/share/top/charmm27.ff/rna.c.tdb gromacs-4.5.5/share/top/charmm27.ff/rna.c.tdb --- gromacs-4.5.4/share/top/charmm27.ff/rna.c.tdb 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/charmm27.ff/rna.c.tdb 2011-09-21 12:34:32.000000000 +0000 @@ -7,4 +7,4 @@ O3' O3' ON5 15.9994 -0.66 [ Add ] 1 2 H3T O3' C3' C4' - HN5 1.008 0.43 + HN5 1.008 0.43 -1 diff -Nru gromacs-4.5.4/share/top/charmm27.ff/rna.n.tdb gromacs-4.5.5/share/top/charmm27.ff/rna.n.tdb --- gromacs-4.5.4/share/top/charmm27.ff/rna.n.tdb 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/charmm27.ff/rna.n.tdb 2011-09-21 12:34:32.000000000 +0000 @@ -10,7 +10,7 @@ C5' C5' CN8B 12.011 0.05 [ Add ] 1 2 H5T O5' C5' C4' - HN5 1.008 0.43 + HN5 1.008 0.43 -1 diff -Nru gromacs-4.5.4/share/top/gmx2.ff/ions.itp gromacs-4.5.5/share/top/gmx2.ff/ions.itp --- gromacs-4.5.4/share/top/gmx2.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gmx2.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -7,41 +7,41 @@ 1 K 1 K K 1 1 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 NA 1 NA NA 1 1 +; id at type res nr residu name at name cg nr charge +1 NA 1 NA NA 1 1 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 CA 1 CA CA 1 2 +; id at type res nr residu name at name cg nr charge +1 CA 1 CA CA 1 2 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 MG 1 MG MG 1 2 +; id at type res nr residu name at name cg nr charge +1 MG 1 MG MG 1 2 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 CL 1 CL CL 1 -1 +; id at type res nr residu name at name cg nr charge +1 CL 1 CL CL 1 -1 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 ZN 1 ZN ZN 1 2 +; id at type res nr residu name at name cg nr charge +1 ZN 1 ZN ZN 1 2 diff -Nru gromacs-4.5.4/share/top/gmx.ff/ions.itp gromacs-4.5.5/share/top/gmx.ff/ions.itp --- gromacs-4.5.4/share/top/gmx.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gmx.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -7,41 +7,41 @@ 1 K 1 K K 1 1 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 NA 1 NA NA 1 1 +; id at type res nr residu name at name cg nr charge +1 NA 1 NA NA 1 1 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 CA 1 CA CA 1 2 +; id at type res nr residu name at name cg nr charge +1 CA 1 CA CA 1 2 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 MG 1 MG MG 1 2 +; id at type res nr residu name at name cg nr charge +1 MG 1 MG MG 1 2 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 CL 1 CL CL 1 -1 +; id at type res nr residu name at name cg nr charge +1 CL 1 CL CL 1 -1 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge -1 ZN 1 ZN ZN 1 2 +; id at type res nr residu name at name cg nr charge +1 ZN 1 ZN ZN 1 2 diff -Nru gromacs-4.5.4/share/top/gromos43a1.ff/ions.itp gromacs-4.5.5/share/top/gromos43a1.ff/ions.itp --- gromacs-4.5.4/share/top/gromos43a1.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gromos43a1.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -1,55 +1,55 @@ [ moleculetype ] -; molname nrexcl -CU1 1 +; molname nrexcl +CU1 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU1+ 1 CU1 CU 1 1 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU1+ 1 CU1 CU 1 1 63.54600 [ moleculetype ] -; molname nrexcl -CU 1 +; molname nrexcl +CU 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU2+ 1 CU CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU2+ 1 CU CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 ZN2+ 1 ZN ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 ZN2+ 1 ZN ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 MG2+ 1 MG MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 MG2+ 1 MG MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CA2+ 1 CA CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 CA2+ 1 CA CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 NA+ 1 NA NA 1 1 22.9898 +; id at type res nr residu name at name cg nr charge mass +1 NA+ 1 NA NA 1 1 22.9898 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CL- 1 CL CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 CL- 1 CL CL 1 -1 35.45300 diff -Nru gromacs-4.5.4/share/top/gromos43a2.ff/ions.itp gromacs-4.5.5/share/top/gromos43a2.ff/ions.itp --- gromacs-4.5.4/share/top/gromos43a2.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gromos43a2.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -1,55 +1,55 @@ [ moleculetype ] -; molname nrexcl -CU1 1 +; molname nrexcl +CU1 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU1+ 1 CU1 CU 1 1 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU1+ 1 CU1 CU 1 1 63.54600 [ moleculetype ] -; molname nrexcl -CU 1 +; molname nrexcl +CU 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU2+ 1 CU CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU2+ 1 CU CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 ZN2+ 1 ZN ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 ZN2+ 1 ZN ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 MG2+ 1 MG MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 MG2+ 1 MG MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CA2+ 1 CA CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 CA2+ 1 CA CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 NA+ 1 NA NA 1 1 22.9898 +; id at type res nr residu name at name cg nr charge mass +1 NA+ 1 NA NA 1 1 22.9898 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CL- 1 CL CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 CL- 1 CL CL 1 -1 35.45300 diff -Nru gromacs-4.5.4/share/top/gromos45a3.ff/ions.itp gromacs-4.5.5/share/top/gromos45a3.ff/ions.itp --- gromacs-4.5.4/share/top/gromos45a3.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gromos45a3.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -1,55 +1,55 @@ [ moleculetype ] -; molname nrexcl -CU1 1 +; molname nrexcl +CU1 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU1+ 1 CU1 CU 1 1 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU1+ 1 CU1 CU 1 1 63.54600 [ moleculetype ] -; molname nrexcl -CU 1 +; molname nrexcl +CU 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU2+ 1 CU CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU2+ 1 CU CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 ZN2+ 1 ZN ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 ZN2+ 1 ZN ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 MG2+ 1 MG MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 MG2+ 1 MG MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CA2+ 1 CA CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 CA2+ 1 CA CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 NA+ 1 NA NA 1 1 22.9898 +; id at type res nr residu name at name cg nr charge mass +1 NA+ 1 NA NA 1 1 22.9898 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CL- 1 CL CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 CL- 1 CL CL 1 -1 35.45300 diff -Nru gromacs-4.5.4/share/top/gromos53a5.ff/aminoacids.rtp gromacs-4.5.5/share/top/gromos53a5.ff/aminoacids.rtp --- gromacs-4.5.4/share/top/gromos53a5.ff/aminoacids.rtp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gromos53a5.ff/aminoacids.rtp 2011-09-21 12:34:10.000000000 +0000 @@ -6454,7 +6454,7 @@ C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 @@ -6462,9 +6462,9 @@ O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 C5 C6 O6 HO6 gd_30 O6 C6 C5 O5 gd_5 @@ -6472,7 +6472,7 @@ C4 C5 O5 C1 gd_29 C5 O5 C1 C2 gd_29 O5 C1 O1 +C4 gd_6 - O5 C1 O1 +C4 gd_28 + O5 C1 O1 +C4 gd_28 [ GLCB ] [ atoms ] @@ -6545,7 +6545,7 @@ C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 @@ -6553,9 +6553,9 @@ O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 C5 C6 O6 HO6 gd_30 O6 C6 C5 O5 gd_5 @@ -6636,7 +6636,7 @@ C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 @@ -6644,9 +6644,9 @@ O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 C5 C6 O6 HO6 gd_30 O6 C6 C5 C4 gd_1 @@ -6722,32 +6722,32 @@ C1 C3 O2 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - C5 C6 O6 HO6 gd_30 - O6 C6 C5 C4 gd_1 - O6 C6 C5 O5 gd_3 - O6 C6 C5 O5 gd_35 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_2 - O5 C1 O1 +C4 gd_32 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + C5 C6 O6 HO6 gd_30 + O6 C6 C5 C4 gd_1 + O6 C6 C5 O5 gd_3 + O6 C6 C5 O5 gd_35 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_2 + O5 C1 O1 +C4 gd_32 [ MANA ] [ atoms ] @@ -7059,26 +7059,23 @@ HO4 O4 C4 C3 gd_30 O4 C4 C3 O3 gd_18 O4 C4 C3 C2 gd_17 + C4 C3 C2 C1 gd_34 C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 O4 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 C5 C6 O6 HO6 gd_30 - O6 C6 C5 C5 gd_5 + O6 C6 C5 O5 gd_5 O6 C6 C5 O5 gd_37 C4 C5 O5 C1 gd_29 - C2' C5 O3' O3' gd_30 C5 O5 C1 C2 gd_29 O5 C1 O1 C1' gd_6 O5 C1 O1 C1' gd_28 @@ -7086,20 +7083,19 @@ C1 O1 C1' O5' gd_28 C2' C1' O5' C5' gd_29 O1 C1' C2' C3' gd_17 - O1 C1' C2' C3' gd_34 O1 C1' C2' O2' gd_18 O5' C1' C2' C3' gd_17 C1' O5' C5' C4' gd_29 O5' C5' C4' C3' gd_17 C6' C5' C4' O4' gd_17 - C6' C5' C4' C3' gd_34 O5' C5' C6' O6' gd_5 - O5' C5' C6' O6' gd_37 + O5' C5' C6' O6' gd_37 + C2' C3' O3' HO3' gd_30 C3' C4' O4' HO4' gd_30 C5' C4' C3' O3' gd_17 C5' C4' C3' C2' gd_34 O4' C4' C3' C2' gd_17 - C4' O4' C3' O3' gd_18 + O4' C4' C3' O3' gd_18 C4' C3' C2' C1' gd_34 C4' C3' C2' O2' gd_17 O3' C3' C2' C1' gd_17 @@ -7180,7 +7176,7 @@ C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 @@ -7188,9 +7184,9 @@ O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 O61 C6 C5 O5 gd_40 C4 C5 O5 C1 gd_29 @@ -7271,7 +7267,7 @@ C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 @@ -7279,9 +7275,9 @@ O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 O61 C6 C5 O5 gd_40 C4 C5 O5 C1 gd_29 @@ -7356,29 +7352,29 @@ C1 O5 O1 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - O61 C6 C5 O5 gd_40 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_6 - O5 C1 O1 +C4 gd_28 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + O61 C6 C5 O5 gd_40 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_6 + O5 C1 O1 +C4 gd_28 [ UGUA ] [ atoms ] @@ -7447,29 +7443,29 @@ C1 O5 O1 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - O61 C6 C5 O5 gd_40 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_6 - O5 C1 O1 +C4 gd_28 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + O61 C6 C5 O5 gd_40 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_6 + O5 C1 O1 +C4 gd_28 [ DPPC ] [ atoms ] diff -Nru gromacs-4.5.4/share/top/gromos53a5.ff/ions.itp gromacs-4.5.5/share/top/gromos53a5.ff/ions.itp --- gromacs-4.5.4/share/top/gromos53a5.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gromos53a5.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -1,55 +1,55 @@ [ moleculetype ] -; molname nrexcl -CU1 1 +; molname nrexcl +CU1 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU1+ 1 CU1 CU 1 1 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU1+ 1 CU1 CU 1 1 63.54600 [ moleculetype ] -; molname nrexcl -CU 1 +; molname nrexcl +CU 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU2+ 1 CU CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU2+ 1 CU CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 ZN2+ 1 ZN ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 ZN2+ 1 ZN ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 MG2+ 1 MG MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 MG2+ 1 MG MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CA2+ 1 CA CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 CA2+ 1 CA CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 NA+ 1 NA NA 1 1 22.9898 +; id at type res nr residu name at name cg nr charge mass +1 NA+ 1 NA NA 1 1 22.9898 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CL- 1 CL CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 CL- 1 CL CL 1 -1 35.45300 diff -Nru gromacs-4.5.4/share/top/gromos53a6.ff/aminoacids.rtp gromacs-4.5.5/share/top/gromos53a6.ff/aminoacids.rtp --- gromacs-4.5.4/share/top/gromos53a6.ff/aminoacids.rtp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gromos53a6.ff/aminoacids.rtp 2011-09-21 12:34:10.000000000 +0000 @@ -6448,31 +6448,31 @@ C1 O5 O1 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - C5 C6 O6 HO6 gd_30 - O6 C6 C5 O5 gd_5 - O6 C6 C5 O5 gd_37 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + C5 C6 O6 HO6 gd_30 + O6 C6 C5 O5 gd_5 + O6 C6 C5 O5 gd_37 C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_6 - O5 C1 O1 +C4 gd_28 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_6 + O5 C1 O1 +C4 gd_28 [ GLCB ] [ atoms ] @@ -6539,31 +6539,31 @@ C1 C3 O2 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - C5 C6 O6 HO6 gd_30 - O6 C6 C5 O5 gd_5 - O6 C6 C5 O5 gd_37 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_2 - O5 C1 O1 +C4 gd_32 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + C5 C6 O6 HO6 gd_30 + O6 C6 C5 O5 gd_5 + O6 C6 C5 O5 gd_37 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_2 + O5 C1 O1 +C4 gd_32 [ GALA ] [ atoms ] @@ -6630,32 +6630,32 @@ C1 O5 O1 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - C5 C6 O6 HO6 gd_30 - O6 C6 C5 C4 gd_1 - O6 C6 C5 O5 gd_3 - O6 C6 C5 O5 gd_35 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_6 - O5 C1 O1 +C4 gd_28 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + C5 C6 O6 HO6 gd_30 + O6 C6 C5 C4 gd_1 + O6 C6 C5 O5 gd_3 + O6 C6 C5 O5 gd_35 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_6 + O5 C1 O1 +C4 gd_28 [ GALB ] [ atoms ] @@ -6722,31 +6722,31 @@ C1 C3 O2 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - C5 C6 O6 HO6 gd_30 - O6 C6 C5 C4 gd_1 - O6 C6 C5 O5 gd_3 - O6 C6 C5 O5 gd_35 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_2 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + C5 C6 O6 HO6 gd_30 + O6 C6 C5 C4 gd_1 + O6 C6 C5 O5 gd_3 + O6 C6 C5 O5 gd_35 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_2 O5 C1 O1 +C4 gd_32 [ MANA ] @@ -6814,31 +6814,31 @@ C1 O5 O1 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - C5 C6 O6 HO6 gd_30 - O6 C6 C5 O5 gd_5 - O6 C6 C5 O5 gd_37 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_6 - O5 C1 O1 +C4 gd_28 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + C5 C6 O6 HO6 gd_30 + O6 C6 C5 O5 gd_5 + O6 C6 C5 O5 gd_37 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_6 + O5 C1 O1 +C4 gd_28 [ MANB ] [ atoms ] @@ -6905,31 +6905,31 @@ C5 -O1 C3 C4 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - C5 C6 O6 HO6 gd_30 - O6 C6 C5 O5 gd_5 - O6 C6 C5 O5 gd_37 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_2 - O5 C1 O1 +C4 gd_32 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + C5 C6 O6 HO6 gd_30 + O6 C6 C5 O5 gd_5 + O6 C6 C5 O5 gd_37 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_2 + O5 C1 O1 +C4 gd_32 [ TRH ] [ atoms ] @@ -7059,26 +7059,23 @@ HO4 O4 C4 C3 gd_30 O4 C4 C3 O3 gd_18 O4 C4 C3 C2 gd_17 + C4 C3 C2 C1 gd_34 C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 O4 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 C5 C6 O6 HO6 gd_30 - O6 C6 C5 C5 gd_5 + O6 C6 C5 O5 gd_5 O6 C6 C5 O5 gd_37 C4 C5 O5 C1 gd_29 - C2' C5 O3' O3' gd_30 C5 O5 C1 C2 gd_29 O5 C1 O1 C1' gd_6 O5 C1 O1 C1' gd_28 @@ -7086,20 +7083,19 @@ C1 O1 C1' O5' gd_28 C2' C1' O5' C5' gd_29 O1 C1' C2' C3' gd_17 - O1 C1' C2' C3' gd_34 O1 C1' C2' O2' gd_18 O5' C1' C2' C3' gd_17 C1' O5' C5' C4' gd_29 O5' C5' C4' C3' gd_17 C6' C5' C4' O4' gd_17 - C6' C5' C4' C3' gd_34 O5' C5' C6' O6' gd_5 O5' C5' C6' O6' gd_37 + C2' C3' O3' HO3' gd_30 C3' C4' O4' HO4' gd_30 C5' C4' C3' O3' gd_17 C5' C4' C3' C2' gd_34 O4' C4' C3' C2' gd_17 - C4' O4' C3' O3' gd_18 + O4' C4' C3' O3' gd_18 C4' C3' C2' C1' gd_34 C4' C3' C2' O2' gd_17 O3' C3' C2' C1' gd_17 @@ -7174,29 +7170,29 @@ C1 C3 O2 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - O61 C6 C5 O5 gd_40 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_2 - O5 C1 O1 +C4 gd_32 + O2 C2 C1 O1 gd_18 + O61 C6 C5 O5 gd_40 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_2 + O5 C1 O1 +C4 gd_32 [ UMNB ] [ atoms ] @@ -7271,7 +7267,7 @@ C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 @@ -7279,9 +7275,9 @@ O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 O61 C6 C5 O5 gd_40 C4 C5 O5 C1 gd_29 @@ -7362,7 +7358,7 @@ C5 C4 C3 O3 gd_17 C5 C4 C3 C2 gd_34 -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 + C3 C4 C5 O5 gd_34 C3 C4 C5 O5 gd_17 C2 C3 O3 HO3 gd_30 C4 C3 C2 O2 gd_17 @@ -7370,9 +7366,9 @@ O3 C3 C2 O2 gd_18 O3 C3 C2 C1 gd_17 C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 C3 C2 C1 O5 gd_17 C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 O2 C2 C1 O1 gd_18 O61 C6 C5 O5 gd_40 C4 C5 O5 C1 gd_29 @@ -7447,29 +7443,29 @@ C1 O5 O1 C2 gi_2 [ dihedrals ] ; ai aj ak al gromos type - -C1 -O1 C4 C3 gd_30 - -O1 C4 C3 O3 gd_18 - -O1 C4 C3 C2 gd_17 - C5 C4 C3 O3 gd_17 - C5 C4 C3 C2 gd_34 - -O1 C4 C5 C6 gd_17 - C3 C4 C5 C6 gd_34 - C3 C4 C5 O5 gd_17 - C2 C3 O3 HO3 gd_30 - C4 C3 C2 O2 gd_17 - C4 C3 C2 C1 gd_34 - O3 C3 C2 O2 gd_18 - O3 C3 C2 C1 gd_17 - C1 C2 O2 HO2 gd_30 - C3 C2 C1 O5 gd_17 - C3 C2 C1 O1 gd_17 - C3 C2 C1 O1 gd_34 - O2 C2 C1 O1 gd_18 - O61 C6 C5 O5 gd_40 - C4 C5 O5 C1 gd_29 - C5 O5 C1 C2 gd_29 - O5 C1 O1 +C4 gd_6 - O5 C1 O1 +C4 gd_28 + -C1 -O1 C4 C3 gd_30 + -O1 C4 C3 O3 gd_18 + -O1 C4 C3 C2 gd_17 + C5 C4 C3 O3 gd_17 + C5 C4 C3 C2 gd_34 + -O1 C4 C5 C6 gd_17 + C3 C4 C5 O5 gd_34 + C3 C4 C5 O5 gd_17 + C2 C3 O3 HO3 gd_30 + C4 C3 C2 O2 gd_17 + C4 C3 C2 C1 gd_34 + O3 C3 C2 O2 gd_18 + O3 C3 C2 C1 gd_17 + C1 C2 O2 HO2 gd_30 + C3 C2 C1 O5 gd_34 + C3 C2 C1 O5 gd_17 + C3 C2 C1 O1 gd_17 + O2 C2 C1 O1 gd_18 + O61 C6 C5 O5 gd_40 + C4 C5 O5 C1 gd_29 + C5 O5 C1 C2 gd_29 + O5 C1 O1 +C4 gd_6 + O5 C1 O1 +C4 gd_28 [ DPPC ] [ atoms ] diff -Nru gromacs-4.5.4/share/top/gromos53a6.ff/ions.itp gromacs-4.5.5/share/top/gromos53a6.ff/ions.itp --- gromacs-4.5.4/share/top/gromos53a6.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/gromos53a6.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -1,55 +1,55 @@ [ moleculetype ] -; molname nrexcl -CU1 1 +; molname nrexcl +CU1 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU1+ 1 CU1 CU 1 1 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU1+ 1 CU1 CU 1 1 63.54600 [ moleculetype ] -; molname nrexcl -CU 1 +; molname nrexcl +CU 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU2+ 1 CU CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU2+ 1 CU CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 ZN2+ 1 ZN ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 ZN2+ 1 ZN ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 MG2+ 1 MG MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 MG2+ 1 MG MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CA2+ 1 CA CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 CA2+ 1 CA CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 NA+ 1 NA NA 1 1 22.9898 +; id at type res nr residu name at name cg nr charge mass +1 NA+ 1 NA NA 1 1 22.9898 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CL- 1 CL CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 CL- 1 CL CL 1 -1 35.45300 diff -Nru gromacs-4.5.4/share/top/gurgle.dat gromacs-4.5.5/share/top/gurgle.dat --- gromacs-4.5.4/share/top/gurgle.dat 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/share/top/gurgle.dat 2011-09-21 12:34:32.000000000 +0000 @@ -1,4 +1,4 @@ -365 +366 ¶™ß¦Šß¨ž‘‹ß¬’š‹—–‘˜ß»‘šß¦Šß·ž‰šß‹ß»ß¶‹ß¦ŠŒš“™ ×·–˜—“ž‘›šß¶¶Ö ¶ß³–‰šß‹—šß³–™šß«—š†ß¨–Œ—ß«—š†ß»–› ×«–œ”†Ö µšŒŠŒß½Š–“‹ß²†ß·‹› ×²–‘–Œ‹†Ö @@ -364,3 +364,4 @@ ¼ž‘߶ߗž‰šßš‰š†‹—–‘˜ß“Š›šß‹—ž‘ßš‰š†‹—–‘˜ßš“ŒšÀ ×»ššß¯Š“šÖ ·šØŒßŠŒ–‘˜ßœ›šß‹—ž‹ß‘“†ß†Šßž‘›ß¶ß”‘ˆ ×´ž‹šß½ŠŒ—Ö ¼—š’–œž“ߘžŒšŒß™–““–‘˜ß“Š‘˜Œß™ß“–‹‹“šß‘šŒ ×½“žœ”ߺ†š›ß¯šžŒÖ +¶Ø‰šßžŒ–œž““†ßšœ’šßžß‰š˜š‹ž–ž‘ߌ–‘œšß‹—šß‘“†ß’šž‹ß¶Ø’ßšž‹–‘˜ß–Œß™’ßž‘–’ž“Œß¶Ø‰šß”–““š›ß’†Œš“™ ×²ž”ߥŠœ”šš˜Ö diff -Nru gromacs-4.5.4/share/top/ions.itp gromacs-4.5.5/share/top/ions.itp --- gromacs-4.5.4/share/top/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -13,60 +13,60 @@ ; do not have the signs of the ions in the molecule name. [ moleculetype ] -; molname nrexcl -CU1+ 1 +; molname nrexcl +CU1+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU1+ 1 CU1+ CU1+ 1 1 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU1+ 1 CU1+ CU1+ 1 1 63.54600 [ moleculetype ] -; molname nrexcl -CU2+ 1 +; molname nrexcl +CU2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CU2+ 1 CU2+ CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 CU2+ 1 CU2+ CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN2+ 1 +; molname nrexcl +ZN2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 ZN2+ 1 ZN2+ ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 ZN2+ 1 ZN2+ ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG2+ 1 +; molname nrexcl +MG2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 MG2+ 1 MG2+ MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 MG2+ 1 MG2+ MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA2+ 1 +; molname nrexcl +CA2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CA2+ 1 CA2+ CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 CA2+ 1 CA2+ CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -NA+ 1 +; molname nrexcl +NA+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 NA+ 1 NA+ NA 1 1 22.9898 +; id at type res nr residu name at name cg nr charge mass +1 NA+ 1 NA+ NA 1 1 22.9898 [ moleculetype ] -; molname nrexcl -CL- 1 +; molname nrexcl +CL- 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 CL- 1 CL- CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 CL- 1 CL- CL 1 -1 35.45300 #include "gromos43a1.ff/ions.itp" @@ -79,107 +79,107 @@ ; do not have the signs of the ions in the molecule name. [ moleculetype ] -; molname nrexcl -CU2+ 1 +; molname nrexcl +CU2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 Cu2+ 1 CU2+ CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 Cu2+ 1 CU2+ CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN2+ 1 +; molname nrexcl +ZN2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 Zn2+ 1 ZN2+ ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 Zn2+ 1 ZN2+ ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG2+ 1 +; molname nrexcl +MG2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_411 1 MG2+ MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 opls_411 1 MG2+ MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA2+ 1 +; molname nrexcl +CA2+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_412 1 CA2+ CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 opls_412 1 CA2+ CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -LI+ 1 +; molname nrexcl +LI+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_406 1 LI+ NA 1 1 6.941 +; id at type res nr residu name at name cg nr charge mass +1 opls_406 1 LI+ LI 1 1 6.941 [ moleculetype ] -; molname nrexcl -NA+ 1 +; molname nrexcl +NA+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_407 1 NA+ NA 1 1 22.98977 +; id at type res nr residu name at name cg nr charge mass +1 opls_407 1 NA+ NA 1 1 22.98977 [ moleculetype ] -; molname nrexcl -K+ 1 +; molname nrexcl +K+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_408 1 K+ K 1 1 39.0983 +; id at type res nr residu name at name cg nr charge mass +1 opls_408 1 K+ K 1 1 39.0983 [ moleculetype ] -; molname nrexcl -Rb+ 1 +; molname nrexcl +Rb+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_409 1 Rb+ Rb 1 1 85.4678 +; id at type res nr residu name at name cg nr charge mass +1 opls_409 1 Rb+ Rb 1 1 85.4678 [ moleculetype ] -; molname nrexcl -Cs+ 1 +; molname nrexcl +Cs+ 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_410 1 Cs+ Cs 1 1 132.9054 +; id at type res nr residu name at name cg nr charge mass +1 opls_410 1 Cs+ Cs 1 1 132.9054 [ moleculetype ] -; molname nrexcl -F- 1 +; molname nrexcl +F- 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_400 1 F- F 1 -1 18.9984 +; id at type res nr residu name at name cg nr charge mass +1 opls_400 1 F- F 1 -1 18.9984 [ moleculetype ] -; molname nrexcl -CL- 1 +; molname nrexcl +CL- 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_401 1 CL- CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 opls_401 1 CL- CL 1 -1 35.45300 [ moleculetype ] -; molname nrexcl -BR- 1 +; molname nrexcl +BR- 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_402 1 BR- BR 1 -1 79.904 +; id at type res nr residu name at name cg nr charge mass +1 opls_402 1 BR- BR 1 -1 79.904 [ moleculetype ] -; molname nrexcl -I- 1 +; molname nrexcl +I- 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_403 1 I- I 1 -1 126.9045 +; id at type res nr residu name at name cg nr charge mass +1 opls_403 1 I- I 1 -1 126.9045 #endif diff -Nru gromacs-4.5.4/share/top/oplsaa.ff/ions.itp gromacs-4.5.5/share/top/oplsaa.ff/ions.itp --- gromacs-4.5.4/share/top/oplsaa.ff/ions.itp 2010-11-09 21:32:43.000000000 +0000 +++ gromacs-4.5.5/share/top/oplsaa.ff/ions.itp 2011-09-21 12:34:10.000000000 +0000 @@ -3,105 +3,105 @@ ; [ moleculetype ] -; molname nrexcl -CU 1 +; molname nrexcl +CU 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 Cu2+ 1 CU CU 1 2 63.54600 +; id at type res nr residu name at name cg nr charge mass +1 Cu2+ 1 CU CU 1 2 63.54600 [ moleculetype ] -; molname nrexcl -ZN 1 +; molname nrexcl +ZN 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 Zn2+ 1 ZN ZN 1 2 65.37000 +; id at type res nr residu name at name cg nr charge mass +1 Zn2+ 1 ZN ZN 1 2 65.37000 [ moleculetype ] -; molname nrexcl -MG 1 +; molname nrexcl +MG 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_411 1 MG MG 1 2 24.30500 +; id at type res nr residu name at name cg nr charge mass +1 opls_411 1 MG MG 1 2 24.30500 [ moleculetype ] -; molname nrexcl -CA 1 +; molname nrexcl +CA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_412 1 CA CA 1 2 40.08000 +; id at type res nr residu name at name cg nr charge mass +1 opls_412 1 CA CA 1 2 40.08000 [ moleculetype ] -; molname nrexcl -LI 1 +; molname nrexcl +LI 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_406 1 LI NA 1 1 6.941 +; id at type res nr residu name at name cg nr charge mass +1 opls_406 1 LI LI 1 1 6.941 [ moleculetype ] -; molname nrexcl -NA 1 +; molname nrexcl +NA 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_407 1 NA NA 1 1 22.98977 +; id at type res nr residu name at name cg nr charge mass +1 opls_407 1 NA NA 1 1 22.98977 [ moleculetype ] -; molname nrexcl -K 1 +; molname nrexcl +K 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_408 1 K K 1 1 39.0983 +; id at type res nr residu name at name cg nr charge mass +1 opls_408 1 K K 1 1 39.0983 [ moleculetype ] -; molname nrexcl -RB 1 +; molname nrexcl +RB 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_409 1 RB RB 1 1 85.4678 +; id at type res nr residu name at name cg nr charge mass +1 opls_409 1 RB RB 1 1 85.4678 [ moleculetype ] -; molname nrexcl -CS 1 +; molname nrexcl +CS 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_410 1 CS CS 1 1 132.9054 +; id at type res nr residu name at name cg nr charge mass +1 opls_410 1 CS CS 1 1 132.9054 [ moleculetype ] -; molname nrexcl -F 1 +; molname nrexcl +F 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_400 1 F F 1 -1 18.9984 +; id at type res nr residu name at name cg nr charge mass +1 opls_400 1 F F 1 -1 18.9984 [ moleculetype ] -; molname nrexcl -CL 1 +; molname nrexcl +CL 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_401 1 CL- CL 1 -1 35.45300 +; id at type res nr residu name at name cg nr charge mass +1 opls_401 1 CL CL 1 -1 35.45300 [ moleculetype ] -; molname nrexcl -BR 1 +; molname nrexcl +BR 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_402 1 BR BR 1 -1 79.904 +; id at type res nr residu name at name cg nr charge mass +1 opls_402 1 BR BR 1 -1 79.904 [ moleculetype ] -; molname nrexcl -I 1 +; molname nrexcl +I 1 [ atoms ] -; id at type res nr residu name at name cg nr charge mass -1 opls_403 1 I I 1 -1 126.9045 +; id at type res nr residu name at name cg nr charge mass +1 opls_403 1 I I 1 -1 126.9045 diff -Nru gromacs-4.5.4/share/top/residuetypes.dat gromacs-4.5.5/share/top/residuetypes.dat --- gromacs-4.5.4/share/top/residuetypes.dat 2010-12-15 10:49:52.000000000 +0000 +++ gromacs-4.5.5/share/top/residuetypes.dat 2011-09-21 12:34:32.000000000 +0000 @@ -10,6 +10,7 @@ ASP1 Protein ASPH Protein ASH Protein +CT3 Protein CYS Protein CYS1 Protein CYS2 Protein diff -Nru gromacs-4.5.4/src/config.h.cmakein gromacs-4.5.5/src/config.h.cmakein --- gromacs-4.5.4/src/config.h.cmakein 2011-03-21 08:35:27.000000000 +0000 +++ gromacs-4.5.5/src/config.h.cmakein 2011-09-21 12:34:10.000000000 +0000 @@ -61,6 +61,9 @@ */ #cmakedefine GMX_FLOAT_FORMAT_IEEE754 +/* Detect Cygwin */ +#cmakedefine GMX_CYGWIN + /* Use assembly intrinsics kernels for BlueGene */ #cmakedefine GMX_BLUEGENE @@ -167,6 +170,12 @@ /* Define for profiling option */ #cmakedefine TMPI_PROFILE +/* Define for Linux pthread_setaffinity */ +#cmakedefine HAVE_PTHREAD_SETAFFINITY + +/* Define for Windows NUMA-aware allocator functions*/ +#cmakedefine TMPI_WINDOWS_NUMA_API + /* Define for sysconf() */ #cmakedefine HAVE_SYSCONF diff -Nru gromacs-4.5.4/src/config.h.in gromacs-4.5.5/src/config.h.in --- gromacs-4.5.4/src/config.h.in 2011-03-21 15:14:03.000000000 +0000 +++ gromacs-4.5.5/src/config.h.in 2011-09-21 12:39:02.000000000 +0000 @@ -255,6 +255,9 @@ /* Define if you have POSIX threads libraries and header files. */ #undef HAVE_PTHREAD +/* pthread_setaffinity_np is available */ +#undef HAVE_PTHREAD_SETAFFINITY + /* Define to 1 if you have the header file. */ #undef HAVE_REGEX_H diff -Nru gromacs-4.5.4/src/gmxlib/checkpoint.c gromacs-4.5.5/src/gmxlib/checkpoint.c --- gromacs-4.5.4/src/gmxlib/checkpoint.c 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/checkpoint.c 2011-09-21 12:34:32.000000000 +0000 @@ -1406,7 +1406,6 @@ check_string(fplog,"Build machine",BUILD_MACHINE,bmach ,&mm); check_string(fplog,"Program name" ,Program() ,fprog ,&mm); - npp = cr->nnodes - cr->npmenodes; check_int (fplog,"#nodes" ,cr->nnodes ,npp_f+npme_f ,&mm); if (bPartDecomp) { @@ -1414,9 +1413,15 @@ dd_nc[YY] = 1; dd_nc[ZZ] = 1; } - if (npp > 1) + if (cr->nnodes > 1) { check_int (fplog,"#PME-nodes" ,cr->npmenodes,npme_f ,&mm); + + npp = cr->nnodes; + if (cr->npmenodes >= 0) + { + npp -= cr->npmenodes; + } if (npp == npp_f) { check_int (fplog,"#DD-cells[x]",dd_nc[XX] ,dd_nc_f[XX],&mm); @@ -1557,10 +1562,12 @@ if (!PAR(cr)) { nppnodes = 1; + cr->npmenodes = 0; } else if (bPartDecomp) { nppnodes = cr->nnodes; + cr->npmenodes = 0; } else if (cr->nnodes == nppnodes_f + npmenodes_f) { @@ -1930,7 +1937,7 @@ t_fileio *fp; fp = gmx_fio_open(fn,"r"); - read_checkpoint_data(fp,simulation_part,step,t,state,TRUE,NULL,NULL); + read_checkpoint_data(fp,simulation_part,step,t,state,FALSE,NULL,NULL); if( gmx_fio_close(fp) != 0) { gmx_file("Cannot read/write checkpoint; corrupt file, or maybe you are out of quota?"); diff -Nru gromacs-4.5.4/src/gmxlib/CMakeLists.txt gromacs-4.5.5/src/gmxlib/CMakeLists.txt --- gromacs-4.5.4/src/gmxlib/CMakeLists.txt 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/CMakeLists.txt 2011-09-21 12:34:32.000000000 +0000 @@ -101,11 +101,9 @@ # so they should not be included in the library file(GLOB_RECURSE NOT_GMXLIB_SOURCES *_test.c *\#*) list(REMOVE_ITEM GMXLIB_SOURCES ${NOT_GMXLIB_SOURCES}) -# Selection has test_ instead of _test. Removing here for special case, perhaps make general? -if(GMX_FAHCORE) - file(GLOB SELECTION_TEST selection/test*) - list(REMOVE_ITEM GMXLIB_SOURCES ${SELECTION_TEST}) -endif(GMX_FAHCORE) +# Selection has test_ instead of _test. +file(GLOB SELECTION_TEST selection/test*) +list(REMOVE_ITEM GMXLIB_SOURCES ${SELECTION_TEST}) # only fiddle with assembly kernels if we're not doing OpenMM build if(NOT GMX_OPENMM) diff -Nru gromacs-4.5.4/src/gmxlib/copyrite.c gromacs-4.5.5/src/gmxlib/copyrite.c --- gromacs-4.5.4/src/gmxlib/copyrite.c 2011-03-21 15:04:58.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/copyrite.c 2011-09-21 12:34:32.000000000 +0000 @@ -328,8 +328,8 @@ "Algorithms for Constrained Molecular Dynamics", "J. Comp. Chem.", 16, 1995, "1192-1209" }, - { "Essman95a", - "U. Essman, L. Perela, M. L. Berkowitz, T. Darden, H. Lee and L. G. Pedersen ", + { "Essmann95a", + "U. Essmann, L. Perera, M. L. Berkowitz, T. Darden, H. Lee and L. G. Pedersen ", "A smooth particle mesh Ewald method", "J. Chem. Phys.", 103, 1995, "8577-8592" }, @@ -398,6 +398,11 @@ "Auger Electron Cascades in Water and Ice", "Chem. Phys.", 299, 2004, "277-283" }, + { "Pascal2011a", + "T. A. Pascal and S. T. Lin and W. A. Goddard III", + "Thermodynamics of liquids: standard molar entropies and heat capacities of common solvents from 2PT molecular dynamics", + "Phys. Chem. Chem. Phys.", + 13, 2011, "169-181" }, { "Caleman2011b", "C. Caleman and M. Hong and J. S. Hub and L. T. da Costa and P. J. van Maaren and D. van der Spoel", "Force Field Benchmark 1: Density, Heat of Vaporization, Heat Capacity, Surface Tension and Dielectric Constant of 152 Organic Liquids", diff -Nru gromacs-4.5.4/src/gmxlib/disre.c gromacs-4.5.5/src/gmxlib/disre.c --- gromacs-4.5.4/src/gmxlib/disre.c 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/disre.c 2011-09-21 12:34:32.000000000 +0000 @@ -127,7 +127,7 @@ } } - if (PAR(cr) && !bPartDecomp) + if (cr && PAR(cr) && !bPartDecomp) { /* Temporary check, will be removed when disre is implemented with DD */ const char *notestr="NOTE: atoms involved in distance restraints should be within the longest cut-off distance, if this is not the case mdrun generates a fatal error, in that case use particle decomposition (mdrun option -pd)"; @@ -181,7 +181,7 @@ dd->Rtav_6 = &(dd->Rt_6[dd->nres]); ptr = getenv("GMX_DISRE_ENSEMBLE_SIZE"); - if (cr->ms != NULL && ptr != NULL) + if (cr && cr->ms != NULL && ptr != NULL) { #ifdef GMX_MPI dd->nsystems = 0; @@ -225,7 +225,7 @@ if (fplog) { fprintf(fplog,"There are %d distance restraints involving %d atom pairs\n",dd->nres,dd->npair); } - if (cr->ms) + if (cr && cr->ms) { check_multi_int(fplog,cr->ms,fcd->disres.nres, "the number of distance restraints"); diff -Nru gromacs-4.5.4/src/gmxlib/enxio.c gromacs-4.5.5/src/gmxlib/enxio.c --- gromacs-4.5.4/src/gmxlib/enxio.c 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/enxio.c 2011-09-21 12:34:32.000000000 +0000 @@ -1111,14 +1111,22 @@ if (ir->etc == etcNOSEHOOVER) { + char cns[20]; + + cns[0] = '\0'; + for(i=0; ingtc; i++) { ni = groups->grps[egcTC].nm_ind[i]; bufi = *(groups->grpname[ni]); for(j=0; (jnhchainlength); j++) { - sprintf(buf,"Xi-%d-%s",j,bufi); + if (IR_NVT_TROTTER(ir)) + { + sprintf(cns,"-%d",j); + } + sprintf(buf,"Xi%s-%s",cns,bufi); state->nosehoover_xi[i] = find_energy(buf,nre,enm,fr); - sprintf(buf,"vXi-%d-%s",j,bufi); + sprintf(buf,"vXi%s-%s",cns,bufi); state->nosehoover_vxi[i] = find_energy(buf,nre,enm,fr); } diff -Nru gromacs-4.5.4/src/gmxlib/futil.c gromacs-4.5.5/src/gmxlib/futil.c --- gromacs-4.5.4/src/gmxlib/futil.c 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/futil.c 2011-09-21 12:34:32.000000000 +0000 @@ -560,7 +560,7 @@ } else { - if(errno=EINVAL) + if(errno==EINVAL) { sfree(gmxdir); *p_gmxdir = NULL; @@ -595,22 +595,30 @@ #ifdef HAVE_DIRENT_H - struct dirent tmp_dirent; + struct dirent * direntp_large; struct dirent * p; if(gmxdir!=NULL && gmxdir->dirent_handle!=NULL) { - rc = readdir_r(gmxdir->dirent_handle,&tmp_dirent,&p); + /* On some platforms no space is present for d_name in dirent. + * Since d_name is guaranteed to be the last entry, allocating + * extra space for dirent will allow more size for d_name. + * GMX_MAX_PATH should always be >= the max possible d_name. + */ + smalloc(direntp_large, sizeof(*direntp_large) + GMX_PATH_MAX); + rc = readdir_r(gmxdir->dirent_handle,direntp_large,&p); + if(p!=NULL && rc==0) { - strncpy(name,tmp_dirent.d_name,maxlength_name); + strncpy(name,direntp_large->d_name,maxlength_name); } else { name[0] = '\0'; rc = ENOENT; } + sfree(direntp_large); } else { diff -Nru gromacs-4.5.4/src/gmxlib/gmxfio.c gromacs-4.5.5/src/gmxlib/gmxfio.c --- gromacs-4.5.4/src/gmxlib/gmxfio.c 2011-03-15 12:44:31.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/gmxfio.c 2011-09-21 12:34:32.000000000 +0000 @@ -540,6 +540,13 @@ /* If it is not, open it as a regular file */ fio->fp = ffopen(fn,newmode); } + + /* for appending seek to end of file to make sure ftell gives correct position + * important for checkpointing */ + if (newmode[0]=='a') + { + gmx_fseek(fio->fp, 0, SEEK_END); + } } else { diff -Nru gromacs-4.5.4/src/gmxlib/gmx_system_xdr.c gromacs-4.5.5/src/gmxlib/gmx_system_xdr.c --- gromacs-4.5.4/src/gmxlib/gmx_system_xdr.c 2011-03-15 12:44:30.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/gmx_system_xdr.c 2011-09-21 12:34:32.000000000 +0000 @@ -95,7 +95,7 @@ /* * for unit alignment */ -const static char xdr_zero[BYTES_PER_XDR_UNIT] = {0, 0, 0, 0}; +static char xdr_zero[BYTES_PER_XDR_UNIT] = {0, 0, 0, 0}; static xdr_uint32_t xdr_swapbytes(xdr_uint32_t x) { diff -Nru gromacs-4.5.4/src/gmxlib/index.c gromacs-4.5.5/src/gmxlib/index.c --- gromacs-4.5.4/src/gmxlib/index.c 2011-03-15 12:44:31.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/index.c 2011-09-21 12:34:32.000000000 +0000 @@ -148,7 +148,7 @@ } static void -p_status(const char **restype, int nres, const char **typenames, int ntypes, gmx_bool bVerb) +p_status(const char **restype, int nres, const char **typenames, int ntypes) { int i,j; int found; @@ -172,16 +172,15 @@ } } - if (bVerb) + for(i=0; (i 0) { - if(counter[i]>0) - { - printf("There are: %5d %10s residues\n",counter[i],typenames[i]); - } + printf("There are: %5d %10s residues\n",counter[i],typenames[i]); } } + + sfree(counter); } @@ -307,11 +306,37 @@ } } +/*! /brief Instances of this struct contain the data necessary to + * construct a single (protein) index group in + * analyse_prot(). */ +typedef struct gmx_help_make_index_group +{ + /* The set of atom names that will be used to form this index group */ + const char **defining_atomnames; + /* Size of the defining_atomnames array */ + const int num_defining_atomnames; + /* Name of this index group */ + const char *group_name; + /* Whether the above atom names name the atoms in the group, or + * those not in the group */ + gmx_bool bTakeComplement; + /* The index in wholename gives the first item in the arrays of + * atomnames that should be tested with 'gmx_strncasecmp' in stead of + * gmx_strcasecmp, or -1 if all items should be tested with strcasecmp + * This is comparable to using a '*' wildcard at the end of specific + * atom names, but that is more involved to implement... + */ + int wholename; + /* Only create this index group if it differs from the one specified in compareto, + where -1 means to always create this group. */ + int compareto; +} t_gmx_help_make_index_group; + static void analyse_prot(const char ** restype,t_atoms *atoms, t_blocka *gb,char ***gn,gmx_bool bASK,gmx_bool bVerb) { - /* atomnames to be used in constructing index groups: */ - static const char *pnoh[] = { "H" }; + /* lists of atomnames to be used in constructing index groups: */ + static const char *pnoh[] = { "H", "HN" }; static const char *pnodum[] = { "MN1", "MN2", "MCB1", "MCB2", "MCG1", "MCG2", "MCD1", "MCD2", "MCE1", "MCE2", "MNZ1", "MNZ2" }; static const char *calpha[] = { "CA" }; @@ -319,36 +344,21 @@ static const char *mc[] = { "N","CA","C","O","O1","O2","OC1","OC2","OT","OXT" }; static const char *mcb[] = { "N","CA","CB","C","O","O1","O2","OC1","OC2","OT","OXT" }; static const char *mch[] = { "N","CA","C","O","O1","O2","OC1","OC2","OT","OXT", - "H1","H2","H3","H" }; - /* array of arrays of atomnames: */ - static const char **chains[] = { NULL,pnoh,calpha,bb,mc,mcb,mch,mch,mch,pnodum }; -#define NCH asize(chains) - /* array of sizes of arrays of atomnames: */ - const int sizes[NCH] = { - 0, asize(pnoh), asize(calpha), asize(bb), - asize(mc), asize(mcb), asize(mch), asize(mch), asize(mch), asize(pnodum) - }; - /* descriptive names of index groups */ - const char *ch_name[NCH] = { - "Protein", "Protein-H", "C-alpha", "Backbone", - "MainChain", "MainChain+Cb", "MainChain+H", "SideChain", "SideChain-H", - "Prot-Masses" - }; - /* construct index group containing (TRUE) or excluding (FALSE) - given atom names */ - const gmx_bool complement[NCH] = { - TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE - }; - const int wholename[NCH] = { -1, 0,-1,-1,-1,-1,-1,-1, 11,-1 }; - /* the index in wholename gives the first item in the arrays of - * atomtypes that should be tested with 'gmx_strncasecmp' in stead of - * gmx_strcasecmp, or -1 if all items should be tested with strcasecmp - * This is comparable to using a '*' wildcard at the end of specific - * atom names, but that is more involved to implement... - */ - /* only add index group if it differs from the specified one, - specify -1 to always add group */ - const int compareto[NCH] = { -1,-1,-1,-1,-1,-1,-1,-1,-1, 0 }; + "H1","H2","H3","H","HN" }; + + static const t_gmx_help_make_index_group constructing_data[] = + {{ NULL, 0, "Protein", TRUE, -1, -1}, + { pnoh, asize(pnoh), "Protein-H", TRUE, 0, -1}, + { calpha, asize(calpha), "C-alpha", FALSE, -1, -1}, + { bb, asize(bb), "Backbone", FALSE, -1, -1}, + { mc, asize(mc), "MainChain", FALSE, -1, -1}, + { mcb, asize(mcb), "MainChain+Cb", FALSE, -1, -1}, + { mch, asize(mch), "MainChain+H", FALSE, -1, -1}, + { mch, asize(mch), "SideChain", TRUE, -1, -1}, + { mch, asize(mch), "SideChain-H", TRUE, 11, -1}, + { pnodum, asize(pnodum), "Prot-Masses", TRUE, -1, 0}, + }; + const int num_index_groups = asize(constructing_data); int n,j; atom_id *aid; @@ -365,44 +375,48 @@ /* calculate the number of protein residues */ npres=0; - for(i=0; (inres); i++) - if (!gmx_strcasecmp(restype[i],"Protein")) - { + for(i=0; (inres); i++) { + if (0 == gmx_strcasecmp(restype[i],"Protein")) { npres++; + } } /* find matching or complement atoms */ - for(i=0; (i<(int)NCH); i++) { + for(i=0; (i<(int)num_index_groups); i++) { nra=0; for(n=0; (nnr); n++) { - if (!gmx_strcasecmp(restype[atoms->atom[n].resind],"Protein")) { - + if (0 == gmx_strcasecmp(restype[atoms->atom[n].resind],"Protein")) { match=FALSE; - for(j=0; (jatomname[n]; - while (isdigit(atnm[0])) + while (isdigit(atnm[0])) { atnm++; - if ( (wholename[i]==-1) || (jatom[n].resind; for(;((atoms->atom[n].resind==resind) && (nnr));n++) { match=FALSE; - for(j=0;(jatomname[n]) == 0) + for(j=0;(jatomname[n])) { match=TRUE; - if (match != complement[i]) + } + } + if (constructing_data[i].bTakeComplement != match) { aid[nra++]=n; + } } /* copy the residuename to the tail of the groupname */ if (nra > 0) { t_resinfo *ri; ri = &atoms->resinfo[resind]; sprintf(ndx_name,"%s_%s%d%c", - ch_name[i],*ri->name,ri->nr,ri->ic==' ' ? '\0' : ri->ic); + constructing_data[i].group_name,*ri->name,ri->nr,ri->ic==' ' ? '\0' : ri->ic); add_grp(gb,gn,nra,aid,ndx_name); nra = 0; } @@ -442,16 +459,19 @@ hold=nra; nra+=2; } else if (strcmp("C",*atoms->atomname[n]) == 0) { - if (hold == -1) + if (hold == -1) { gmx_incons("Atom naming problem"); + } aid[hold]=n; } else if (strcmp("O",*atoms->atomname[n]) == 0) { - if (hold == -1) + if (hold == -1) { gmx_incons("Atom naming problem"); + } aid[hold+1]=n; } else if (strcmp("O1",*atoms->atomname[n]) == 0) { - if (hold == -1) + if (hold == -1) { gmx_incons("Atom naming problem"); + } aid[hold+1]=n; } else aid[nra++]=n; @@ -741,30 +761,25 @@ resnm = *atoms->resinfo[i].name; gmx_residuetype_get_type(rt,resnm,&(restype[i])); - if(i==0) + /* Note that this does not lead to a N*N loop, but N*K, where + * K is the number of residue _types_, which is small and independent of N. + */ + found = 0; + for(k=0;knres,p_typename,ntypes,bVerb); + if (bVerb) + { + p_status(restype,atoms->nres,p_typename,ntypes); + } for(k=0;kmpb, 1); ms->mpb->ibuf=NULL; + ms->mpb->libuf=NULL; ms->mpb->fbuf=NULL; ms->mpb->dbuf=NULL; ms->mpb->ibuf_alloc=0; + ms->mpb->libuf_alloc=0; ms->mpb->fbuf_alloc=0; ms->mpb->dbuf_alloc=0; #endif @@ -572,9 +574,11 @@ /* initialize the MPI_IN_PLACE replacement buffers */ snew(cr->mpb, 1); cr->mpb->ibuf=NULL; + cr->mpb->libuf=NULL; cr->mpb->fbuf=NULL; cr->mpb->dbuf=NULL; cr->mpb->ibuf_alloc=0; + cr->mpb->libuf_alloc=0; cr->mpb->fbuf_alloc=0; cr->mpb->dbuf_alloc=0; #endif diff -Nru gromacs-4.5.4/src/gmxlib/matio.c gromacs-4.5.5/src/gmxlib/matio.c --- gromacs-4.5.4/src/gmxlib/matio.c 2011-03-15 12:44:31.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/matio.c 2011-09-21 12:34:32.000000000 +0000 @@ -445,8 +445,7 @@ if (m>=0) gmx_incons("Not enough rows in the matrix"); - /* This code makes me cry. DvdS 2010-07-08 */ - /*sfree(line);*/ + sfree(line_buf); } int read_xpm_matrix(const char *fnm,t_matrix **matrix) diff -Nru gromacs-4.5.4/src/gmxlib/network.c gromacs-4.5.5/src/gmxlib/network.c --- gromacs-4.5.4/src/gmxlib/network.c 2011-03-21 08:35:27.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/network.c 2011-09-21 12:34:32.000000000 +0000 @@ -589,25 +589,25 @@ #else int i; - if (nr > cr->mpb->ibuf_alloc) { - cr->mpb->ibuf_alloc = nr; - srenew(cr->mpb->ibuf,cr->mpb->ibuf_alloc); + if (nr > cr->mpb->libuf_alloc) { + cr->mpb->libuf_alloc = nr; + srenew(cr->mpb->libuf,cr->mpb->libuf_alloc); } if (cr->nc.bUse) { /* Use two step summing */ - MPI_Allreduce(r,cr->mpb->ibuf,nr,GMX_MPI_LARGE_INT,MPI_SUM, + MPI_Allreduce(r,cr->mpb->libuf,nr,GMX_MPI_LARGE_INT,MPI_SUM, cr->nc.comm_intra); if (cr->nc.rank_intra == 0) { /* Sum with the buffers reversed */ - MPI_Allreduce(cr->mpb->ibuf,r,nr,GMX_MPI_LARGE_INT,MPI_SUM, + MPI_Allreduce(cr->mpb->libuf,r,nr,GMX_MPI_LARGE_INT,MPI_SUM, cr->nc.comm_inter); } MPI_Bcast(r,nr,GMX_MPI_LARGE_INT,0,cr->nc.comm_intra); } else { - MPI_Allreduce(r,cr->mpb->ibuf,nr,GMX_MPI_LARGE_INT,MPI_SUM, + MPI_Allreduce(r,cr->mpb->libuf,nr,GMX_MPI_LARGE_INT,MPI_SUM, cr->mpi_comm_mygroup); for(i=0; impb->ibuf[i]; + r[i] = cr->mpb->libuf[i]; } #endif #endif @@ -709,14 +709,14 @@ /* this is thread-unsafe, but it will do for now: */ int i; - if (nr > ms->mpb->ibuf_alloc) { - ms->mpb->ibuf_alloc = nr; - srenew(ms->mpb->ibuf,ms->mpb->ibuf_alloc); + if (nr > ms->mpb->libuf_alloc) { + ms->mpb->libuf_alloc = nr; + srenew(ms->mpb->libuf,ms->mpb->libuf_alloc); } - MPI_Allreduce(r,ms->mpb->ibuf,nr,GMX_MPI_LARGE_INT,MPI_SUM, + MPI_Allreduce(r,ms->mpb->libuf,nr,GMX_MPI_LARGE_INT,MPI_SUM, ms->mpi_comm_masters); for(i=0; impb->ibuf[i]; + r[i] = ms->mpb->libuf[i]; #endif #endif } diff -Nru gromacs-4.5.4/src/gmxlib/rmpbc.c gromacs-4.5.5/src/gmxlib/rmpbc.c --- gromacs-4.5.4/src/gmxlib/rmpbc.c 2011-03-15 12:44:32.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/rmpbc.c 2011-09-21 12:34:32.000000000 +0000 @@ -64,7 +64,10 @@ int i; rmpbc_graph_t *gr; - if (ePBC == epbcNONE || gpbc->idef->ntypes <= 0) + if (ePBC == epbcNONE + || NULL == gpbc + || NULL == gpbc->idef + || gpbc->idef->ntypes <= 0) { return NULL; } @@ -128,19 +131,22 @@ { int i; - for(i=0; ingraph; i++) - { - done_graph(gpbc->graph[i].gr); - } - if (gpbc->graph != NULL) + if (NULL != gpbc) { - sfree(gpbc->graph); + for(i=0; ingraph; i++) + { + done_graph(gpbc->graph[i].gr); + } + if (gpbc->graph != NULL) + { + sfree(gpbc->graph); + } } } static int gmx_rmpbc_ePBC(gmx_rmpbc_t gpbc,matrix box) { - if (gpbc->ePBC >= 0) + if (NULL != gpbc && gpbc->ePBC >= 0) { return gpbc->ePBC; } diff -Nru gromacs-4.5.4/src/gmxlib/string2.c gromacs-4.5.5/src/gmxlib/string2.c --- gromacs-4.5.4/src/gmxlib/string2.c 2011-03-15 12:44:32.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/string2.c 2011-09-21 12:34:32.000000000 +0000 @@ -179,6 +179,9 @@ #if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) /* Windows */ ctime_s( tmpbuf, STRLEN, clock ); +#elif (defined(__sun)) + /*Solaris*/ + ctime_r(clock, tmpbuf, n); #else ctime_r(clock,tmpbuf); #endif diff -Nru gromacs-4.5.4/src/gmxlib/symtab.c gromacs-4.5.5/src/gmxlib/symtab.c --- gromacs-4.5.4/src/gmxlib/symtab.c 2011-03-15 12:44:32.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/symtab.c 2011-09-21 12:34:32.000000000 +0000 @@ -60,7 +60,8 @@ int len,i; if(strlen(s)>(size_t)(maxlen-1)) - gmx_fatal(FARGS,"Character buffer size too small\n"); + gmx_fatal(FARGS,"String '%s' (%d) is longer than buffer (%d).\n", + s, strlen(s), maxlen-1); for (; (*s)&&((*s)==' '); s++); for (len=strlen(s); (len>0); len--) if (s[len-1]!=' ') break; @@ -157,9 +158,9 @@ char **put_symtab(t_symtab *symtab,const char *name) { - char buf[256]; + char buf[1024]; - return enter_buf(symtab,trim_string(name,buf,255)); + return enter_buf(symtab,trim_string(name,buf,1023)); } void open_symtab(t_symtab *symtab) diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/CMakeLists.txt gromacs-4.5.5/src/gmxlib/thread_mpi/CMakeLists.txt --- gromacs-4.5.4/src/gmxlib/thread_mpi/CMakeLists.txt 2011-03-15 12:44:32.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/CMakeLists.txt 2011-09-21 12:34:32.000000000 +0000 @@ -2,7 +2,7 @@ # Note that not all .c files are compiled directly: some of them # are #included (some multiple times) from other source files. set(THREAD_MPI_LIB_SOURCE - alltoall.c hwinfo.c reduce.c + alltoall.c reduce.c barrier.c list.c reduce_fast.c bcast.c lock.c scatter.c collective.c once.c tmpi_init.c @@ -10,7 +10,7 @@ errhandler.c p2p_send_recv.c type.c event.c p2p_wait.c gather.c profile.c - group.c ) + group.c numa_malloc.c) if (THREAD_PTHREADS) diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/hwinfo.c gromacs-4.5.5/src/gmxlib/thread_mpi/hwinfo.c --- gromacs-4.5.4/src/gmxlib/thread_mpi/hwinfo.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/hwinfo.c 1970-01-01 00:00:00.000000000 +0000 @@ -1,103 +0,0 @@ -/* -This source code file is part of thread_mpi. -Written by Sander Pronk, Erik Lindahl, and possibly others. - -Copyright (c) 2009, Sander Pronk, Erik Lindahl. -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: -1) Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. -2) Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. -3) Neither the name of the copyright holders nor the - names of its contributors may be used to endorse or promote products - derived from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY US ''AS IS'' AND ANY -EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL WE BE LIABLE FOR ANY -DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND -ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -If you want to redistribute modifications, please consider that -scientific software is very special. Version control is crucial - -bugs must be traceable. We will be happy to consider code for -inclusion in the official distribution, but derived work should not -be called official thread_mpi. Details are found in the README & COPYING -files. -*/ - - -#ifdef HAVE_TMPI_CONFIG_H -#include "tmpi_config.h" -#else -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif -#endif - -#ifdef HAVE_UNISTD_H -#include -#endif -#ifdef THREAD_WINDOWS -#include -#endif - -#include -#include -#include -#include - -#include "impl.h" -#include "thread_mpi/hwinfo.h" - -#ifdef TMPI_TRACE -#include -#endif - - -int tMPI_Get_hw_nthreads(void) -{ - int ret=-1; -#ifdef HAVE_SYSCONF -#if defined(_SC_NPROCESSORS_ONLN) - ret=sysconf(_SC_NPROCESSORS_ONLN); -#elif defined(_SC_NPROC_ONLN) - ret=sysconf(_SC_NPROC_ONLN); -#elif defined(_SC_NPROCESSORS_CONF) - ret=sysconf(_SC_NPROCESSORS_CONF); -#elif defined(_SC_NPROC_CONF) - ret=sysconf(_SC_NPROC_CONF); -#endif -#endif - -#ifdef THREAD_WINDOWS - SYSTEM_INFO sysinfo; - GetSystemInfo( &sysinfo ); - - ret=sysinfo.dwNumberOfProcessors; -#endif - return ret; -} - - -int tMPI_Get_recommended_nthreads(void) -{ - int N=1; /* the default is 1 */ - -#ifndef TMPI_NO_ATOMICS - N=tMPI_Get_hw_nthreads(); - if (N<1) - N=1; -#endif - return N; -} - diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/impl.h gromacs-4.5.5/src/gmxlib/thread_mpi/impl.h --- gromacs-4.5.4/src/gmxlib/thread_mpi/impl.h 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/impl.h 2011-09-21 12:34:32.000000000 +0000 @@ -62,7 +62,6 @@ #include "thread_mpi/tmpi.h" #include "thread_mpi/collective.h" #include "thread_mpi/barrier.h" -#include "thread_mpi/hwinfo.h" #include "thread_mpi/lock.h" #ifdef TMPI_PROFILE #include "profile.h" @@ -687,17 +686,11 @@ void tMPI_Trace_print(const char *fmt, ...); #endif -/* error-checking malloc/realloc/free: */ +/* error-checking malloc/realloc: */ void *tMPI_Malloc(size_t size); void *tMPI_Realloc(void *p, size_t size); void tMPI_Free(void *p); -/* -//use the following instead of the above function definition for debugging mis- matched allocate/free calls. -#include -#define tMPI_Free(a) sfree(a) -*/ - /* get the current thread structure pointer */ #define tMPI_Get_current() ((struct tmpi_thread*) \ diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/Makefile.am gromacs-4.5.5/src/gmxlib/thread_mpi/Makefile.am --- gromacs-4.5.4/src/gmxlib/thread_mpi/Makefile.am 2011-03-15 12:44:32.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/Makefile.am 2011-09-21 12:34:32.000000000 +0000 @@ -20,7 +20,7 @@ event.c p2p_wait.c topology.c \ gather.c profile.c type.c \ group.c profile.h winthreads.c \ - hwinfo.c pthreads.c winthreads.h + pthreads.c winthreads.h numa_malloc.c CLEANFILES = *.la *~ \\\#* diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/Makefile.in gromacs-4.5.5/src/gmxlib/thread_mpi/Makefile.in --- gromacs-4.5.4/src/gmxlib/thread_mpi/Makefile.in 2011-03-21 15:13:39.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/Makefile.in 2011-09-21 12:38:33.000000000 +0000 @@ -57,8 +57,8 @@ bcast.lo lock.lo reduce_fast.lo collective.lo once.lo \ scatter.lo comm.lo p2p_protocol.lo tmpi_init.lo errhandler.lo \ p2p_send_recv.lo event.lo p2p_wait.lo topology.lo gather.lo \ - profile.lo type.lo group.lo winthreads.lo hwinfo.lo \ - pthreads.lo + profile.lo type.lo group.lo winthreads.lo pthreads.lo \ + numa_malloc.lo libthread_mpi_la_OBJECTS = $(am_libthread_mpi_la_OBJECTS) DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/src depcomp = $(SHELL) $(top_srcdir)/config/depcomp @@ -233,7 +233,7 @@ event.c p2p_wait.c topology.c \ gather.c profile.c type.c \ group.c profile.h winthreads.c \ - hwinfo.c pthreads.c winthreads.h + pthreads.c winthreads.h numa_malloc.c CLEANFILES = *.la *~ \\\#* all: all-am @@ -297,9 +297,9 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/event.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gather.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/group.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hwinfo.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/list.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lock.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/numa_malloc.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/once.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/p2p_protocol.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/p2p_send_recv.Plo@am__quote@ diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/numa_malloc.c gromacs-4.5.5/src/gmxlib/thread_mpi/numa_malloc.c --- gromacs-4.5.4/src/gmxlib/thread_mpi/numa_malloc.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/numa_malloc.c 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,530 @@ + + +#ifdef HAVE_TMPI_CONFIG_H +#include "tmpi_config.h" +#endif + + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + + +#ifdef HAVE_UNISTD_H +#include +#endif + + +#include +#include +#include +#ifdef WITH_DMALLOC +#include "dmalloc.h" +#endif + + +#if ! (defined(WIN32) || defined( _WIN32 ) || defined(WIN64) || defined( _WIN64 ) || defined (__CYGWIN__)) + + +/* We don't have specific NUMA aware allocators: */ + +void *tMPI_Malloc_local(size_t size) +{ + return malloc(size); +} + +void *tMPI_Calloc_local(size_t nmemb, size_t size) +{ + return calloc(nmemb, size); +} + +void *tMPI_Realloc_local(void *ptr, size_t size) +{ + return realloc(ptr, size); +} + +int tMPI_Free_numa(void *ptr) +{ + free(ptr); + return 0; /* we don't detect errors here */ +} + +#else + +#define TMPI_NUMA_MALLOC + +/* + Windows NUMA memory allocation support. + + NUMA support is implemented to maximize the chance that memory access + patterns remain Local to the NUMA node. This avoids penalties accessing + "remote" memory. + An important assumption here is that code paths which allocate and + reallocate heap blocks are likely to be accessing that allocated memory + on the same NUMA node. + Testing has shown the above criteria to be met, yielding gains of > 15% + when on Windows with NUMA hardware. + + The high level approach is: + 1. Use a separate heap per NUMA node. This reduces heap contention, steers + allocations to the local NUMA node, and avoids re-use of freed heap + blocks across (remote) NUMA nodes. + 2. Allocate each heap locally to each NUMA node, such that heap control + structures are on the NUMA node accessing the heap. + 3. During realloc operations, transfer the new block to the local NUMA + node, if appropriate. This is a rare case when thread affinity and + access patterns are correct. + 4. Use GetProcAddress() to obtain function pointers to functions that are + operating system version dependent, to allow maximum binary + compatibility. + + Scott Field (sfield@microsoft.com) Jan-2011 + */ + +//#define _WIN32_WINNT 0x0601 +#include + + + +/* + __declspec(align()) may not be supported by all compilers, so define the + size of the structure manually to force alignment + note that HeapAlloc() already returns aligned blocks. + typedef __declspec(align(32)) struct ... +*/ +typedef struct { + DWORD dwMagic; + HANDLE hHeap; /* 8 */ + size_t cbAllocationSize; /* 8 */ + ULONG ProcessorNumber; /* processor number at time of allocation + (development/testing) */ + USHORT NodeNumber; /* NUMA node number at time of allocation + (development/testing) */ +} HEAPHEADER, *PHEAPHEADER; + +#define HEAP_NUMA_MAGIC 0x05AF0777 +#define HEAPHEADER_SIZE (32) + +#ifdef C_ASSERT +/* fail compile if size of HEAPHEADER exceeds pre-defined value */ +C_ASSERT(sizeof(HEAPHEADER) <= HEAPHEADER_SIZE); +#endif + +/* function prototypes and variables to support obtaining function + addresses dynamically -- supports down-level operating systems */ + +typedef BOOL (WINAPI *func_GetNumaHighestNodeNumber_t)( PULONG HighestNodeNumber ); +typedef BOOL (WINAPI *func_GetNumaProcessorNodeEx_t)( PPROCESSOR_NUMBER Processor, PUSHORT NodeNumber ); +typedef VOID (WINAPI *func_GetCurrentProcessorNumberEx_t)( PPROCESSOR_NUMBER ProcNumber ); + +func_GetNumaHighestNodeNumber_t smalloc_GetNumaHighestNodeNumber; /* WinXP SP2, WinXP64, WinSrv 2003 */ +func_GetNumaProcessorNodeEx_t smalloc_GetNumaProcessorNodeEx; /* Windows 7, WinSrv 2008R2 */ +func_GetCurrentProcessorNumberEx_t smalloc_GetCurrentProcessorNumberEx; /* Windows 7, WinSrv 2008R2 */ + +#define NUMA_STATUS_UNKNOWN (0) +#define NUMA_STATUS_NOT_NUMA (1) +#define NUMA_STATUS_NUMA (2) + +DWORD g_dwTlsHeap; /* TLS slot used for preferred heap handle */ +HANDLE *g_hHeap; /* array of heap handles */ +ULONG g_ulNumaStatus; /* 0 = unknown, 1 = not NUMA, 2 = NUMA */ + +VOID +InitNumaHeapSupport( + VOID + ) +{ + HMODULE hModKernel32; /* module handle to kernel32.dll -- we already + reference it, so it's already loaded */ + ULONG ulNumaHighestNodeNumber; + + /* grab the addresses for the NUMA functions. + It's fine if there is a race condition reaching this routine */ + hModKernel32 = GetModuleHandleA("kernel32.dll"); + if(hModKernel32 == NULL) + { + g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; + return; + } + + smalloc_GetNumaHighestNodeNumber = (func_GetNumaHighestNodeNumber_t)GetProcAddress( hModKernel32, "GetNumaHighestNodeNumber" ); + smalloc_GetCurrentProcessorNumberEx = (func_GetCurrentProcessorNumberEx_t)GetProcAddress( hModKernel32, "GetCurrentProcessorNumberEx" ); + smalloc_GetNumaProcessorNodeEx = (func_GetNumaProcessorNodeEx_t)GetProcAddress( hModKernel32, "GetNumaProcessorNodeEx" ); + + if( (smalloc_GetNumaHighestNodeNumber == NULL) || + (smalloc_GetCurrentProcessorNumberEx == NULL) || + (smalloc_GetNumaProcessorNodeEx == NULL) ) + { + g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; + return; + } + + /* determine how many NUMA nodes are present */ + + if(!smalloc_GetNumaHighestNodeNumber(&ulNumaHighestNodeNumber) || + (ulNumaHighestNodeNumber == 0) ) + { + g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; + return; + } + + /* handle deferred creation of TLS slot. + note: this could be moved to one-time init path. + failures here result in assuming the system is not NUMA. + */ + + if( g_dwTlsHeap == 0 ) + { + DWORD dwTlsHeap = TlsAlloc(); + DWORD dwPriorValue; + + if( dwTlsHeap == TLS_OUT_OF_INDEXES ) + { + g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; + return; + } + + dwPriorValue = (DWORD)InterlockedCompareExchange( + (LONG volatile *)&g_dwTlsHeap, + (LONG) dwTlsHeap, + 0 + ); + + if( dwPriorValue != 0 ) + { + TlsFree( dwTlsHeap ); + } + } + + /* handle deferred creation of heap handle array. + note: this could be moved to one-time init path. + */ + + if( g_hHeap == NULL ) + { + HANDLE *hHeapNew; + HANDLE *hPriorValue; + + /* allocate an array to contain a heap handle for each NUMA node */ + hHeapNew = (HANDLE*)HeapAlloc( + GetProcessHeap(), + HEAP_ZERO_MEMORY, + sizeof(HANDLE) * (ulNumaHighestNodeNumber+1) + ); + + if( hHeapNew == NULL ) + { + g_ulNumaStatus = NUMA_STATUS_NOT_NUMA; + return; + } + + hPriorValue = (HANDLE *)InterlockedCompareExchange( + (LONG volatile *)&g_hHeap, + (LONG) hHeapNew, + 0 + ); + + if( hPriorValue != NULL ) + { + HeapFree(GetProcessHeap(), 0, hHeapNew); + } + } + + /* indicate system is NUMA */ + g_ulNumaStatus = NUMA_STATUS_NUMA; + + return; +} + +HANDLE +ReturnHeapHandle( + VOID + ) +{ + HANDLE hHeap; /* preferred heap handle to + return to caller */ + PROCESSOR_NUMBER CurrentProcessorNumber; /* processor number associated + with calling thread */ + USHORT CurrentNumaNodeNumber; /* NUMA node number assocaited + with calling thread */ + + /* determine NUMA status of system. */ + + if( g_ulNumaStatus == NUMA_STATUS_UNKNOWN ) + { + InitNumaHeapSupport(); + if( g_ulNumaStatus == NUMA_STATUS_NOT_NUMA ) + { + return GetProcessHeap(); + } + } else if( g_ulNumaStatus == NUMA_STATUS_NOT_NUMA ) + { + /* not NUMA, return the process heap handle */ + return GetProcessHeap(); + } + + + /* return the preferred heap handle from the TLS slot, if set. + This is the commonly taken path. */ + + hHeap = (HANDLE)TlsGetValue( g_dwTlsHeap ); + + if( hHeap != NULL ) + { + return hHeap; + } + + + /* preferred heap handle not yet set. + determine the numa node we're executing on, and create a heap which + is assigned to this node. + one (soft) assumption that is made here is that thread affinity has + been set such that threads do not move between NUMA nodes. + */ + + smalloc_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); + + if(!smalloc_GetNumaProcessorNodeEx(&CurrentProcessorNumber, &CurrentNumaNodeNumber)) + { + /* GetNumaProcessorNodeEx() can fail on WOW64/32bit if invoked + against processor numbers > 32. + this should never be reached for 64bit builds. + */ + CurrentNumaNodeNumber = 0; + } + + + /* check if the NUMA node array slot already contains a heap */ + /* CurrentNumaNodeNumber cannot execeed count of heaps, as NUMA nodes + cannot be added. */ + + hHeap = g_hHeap[ CurrentNumaNodeNumber ]; + + if( hHeap == NULL ) + { + HANDLE hHeapPrior = NULL; + ULONG ulOption = 2; /* HEAP_LFH */ + + /* create a heap for this numa node + defer creating the heap - while running on each node - to ensure + the heap control structures get created on the local NUMA node. + */ + + hHeap = HeapCreate(0, 0, 0); + + if( hHeap == NULL ) + { + /* just return the process heap. We'll try to create a heap + again next time */ + return GetProcessHeap(); + } + + /* make the new heap a low-fragmentation heap */ + + HeapSetInformation( + hHeap, + 0, /* HeapCompatibilityInformation */ + &ulOption, + sizeof(ulOption) + ); + + /* set the array slot entry for this NUMA node to contain the newly + allocated heap */ + + hHeapPrior = (HANDLE)InterlockedCompareExchangePointer(&(g_hHeap[CurrentNumaNodeNumber]), hHeap, NULL); + if( hHeapPrior != NULL ) + { + HeapDestroy( hHeap ); + hHeap = hHeapPrior; + } + } + + /* we reached here since there was no heap assigned to the TLS slot. + Assign it. */ + TlsSetValue(g_dwTlsHeap, hHeap); + + return hHeap; +} + + + + +void *tMPI_Malloc_local(size_t size) +{ + HANDLE hHeap; + unsigned char *ptr; + size_t new_size; + HEAPHEADER *phdr; + + hHeap = ReturnHeapHandle(); + + new_size = size + HEAPHEADER_SIZE; + + ptr = (unsigned char *)HeapAlloc( hHeap, 0, new_size ); + + if( ptr == NULL ) + { + return NULL; + } + + phdr = (HEAPHEADER*)ptr; + + phdr->dwMagic = HEAP_NUMA_MAGIC; + phdr->hHeap = hHeap; /* track the heap handle for realloc + and free */ + phdr->cbAllocationSize = new_size; /* track the allocation size for + realloc and debugging */ + + return ( ptr + HEAPHEADER_SIZE ); +} + + +void *tMPI_Calloc_local(size_t nelem, size_t elsize) +{ + void *ptr; + size_t size = nelem * elsize; + + ptr = tMPI_Malloc_local(size); + + if(ptr != NULL) + { + memset(ptr, 0, size); + } + + return ptr; +} + + +void *tMPI_Realloc_local(void *ptr, size_t size) +{ + HANDLE hHeap; + HEAPHEADER *phdr; + unsigned char *new_ptr; + size_t new_size; + + /* calculate the allocation address and check for presence of the hint + which indicates this was allocated by our allocator. + */ + + phdr = (HEAPHEADER*)((unsigned char*)ptr - HEAPHEADER_SIZE); + + if( phdr->dwMagic != HEAP_NUMA_MAGIC ) + { + /* TODO: call tMPI_Error() */ + /*gmx_fatal(errno,__FILE__,__LINE__, + "Invalid Heap header during realloc. %p", ptr);*/ + + return NULL; + } + + /* calculate size of new/realloc'd block. + */ + + new_size = size + HEAPHEADER_SIZE; + + /* if the NUMA Node changed between the initial allocation and the + reallocation, copy the memory to an allocation on the new local node: + we assume the new realloc'd block is more likely to be manipulated by + the current thread which is calling realloc. + the simple way to detect this condition is to compare the preferred heap + handle with the heap handle stored in the current memory block. + */ + + hHeap = ReturnHeapHandle(); + + if( hHeap != phdr->hHeap ) + { + new_ptr = HeapAlloc( hHeap, 0, new_size ); + + /* if the new allocation succeeded, copy the buffer and free the + original buffer. + */ + + if( new_ptr != NULL ) + { + size_t copy_size; + + /* the realloc can be larger or smaller than the original + allocation size. + */ + + if( new_size > phdr->cbAllocationSize ) + { + copy_size = phdr->cbAllocationSize; + } else { + copy_size = new_size; + } + + /* copy the current memory block contents into the newly allocated + buffer, and then free the original buffer. + */ + + memcpy( new_ptr, phdr, copy_size ); + + HeapFree( phdr->hHeap, 0, phdr ); + } + + } else { + + /* NodeNumber of existing allocation matches current node number. + realloc from the heap associated with the existing allocation. + */ + + hHeap = phdr->hHeap; + + new_ptr = HeapReAlloc( + hHeap, + 0, + phdr, + new_size + ); + } + + if( new_ptr == NULL ) + { + return NULL; + } + + phdr = (HEAPHEADER*)new_ptr; + phdr->cbAllocationSize = new_size; /* update allocation size to match + realloc */ + phdr->hHeap = hHeap; + + return ( new_ptr + HEAPHEADER_SIZE ); +} + + +int tMPI_Free_numa(void *ptr) +{ + HEAPHEADER *phdr; + + /* caller doesn't call us on ptr == NULL case, so we don't need to + check that here. */ + + phdr = (HEAPHEADER*)((unsigned char*)ptr - HEAPHEADER_SIZE); + + /* this check should happen in __try / __except block until the + mis-matched free/sfree calls are fixed, but this is here primarilly + for debugging and catching mis-matched memory alloc and free references. + */ + + if(phdr->dwMagic != HEAP_NUMA_MAGIC) + { + /* ptr is leaked here, rather than faulting in the allocator. + this is done in order to track mis-matched alloc/free calls. + */ + return 1; + } + + phdr->dwMagic = 0; + + HeapFree( phdr->hHeap, 0, phdr ); + + return 0; +} + +#endif /* NUMA allocation functions for (_WIN32 || _WIN64) */ + + + + diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/pthreads.c gromacs-4.5.5/src/gmxlib/thread_mpi/pthreads.c --- gromacs-4.5.4/src/gmxlib/thread_mpi/pthreads.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/pthreads.c 2011-09-21 12:34:32.000000000 +0000 @@ -52,6 +52,10 @@ #ifdef THREAD_PTHREADS +#ifdef HAVE_PTHREAD_SETAFFINITY +#define _GNU_SOURCE +#endif + /* pthread.h must be the first header, apart from the defines in config.h */ #include @@ -65,6 +69,7 @@ #include #include + #include "thread_mpi/atomic.h" #include "thread_mpi/threads.h" #include "impl.h" @@ -83,9 +88,16 @@ static pthread_mutex_t barrier_init=PTHREAD_MUTEX_INITIALIZER; +/* lock & variable for setting main thread affinity */ +static tMPI_Spinlock_t main_thread_aff_lock=TMPI_SPINLOCK_INITIALIZER; +static tMPI_Atomic_t main_thread_aff_set={ 0 }; +static tMPI_Atomic_t aff_thread_number; + +/* TODO: this needs to go away! (there's another one in winthreads.c) + fatal errors are thankfully really rare*/ void tMPI_Fatal_error(const char *file, int line, const char *message, ...) { va_list ap; @@ -104,6 +116,25 @@ return TMPI_THREAD_SUPPORT_YES; } + +int tMPI_Thread_get_hw_number(void) +{ + int ret=0; +#ifdef HAVE_SYSCONF +#if defined(_SC_NPROCESSORS_ONLN) + ret=sysconf(_SC_NPROCESSORS_ONLN); +#elif defined(_SC_NPROC_ONLN) + ret=sysconf(_SC_NPROC_ONLN); +#elif defined(_SC_NPROCESSORS_CONF) + ret=sysconf(_SC_NPROCESSORS_CONF); +#elif defined(_SC_NPROC_CONF) + ret=sysconf(_SC_NPROC_CONF); +#endif +#endif + + return ret; +} + int tMPI_Thread_create(tMPI_Thread_t *thread, void *(*start_routine)(void *), void *arg) { @@ -130,6 +161,80 @@ } +/* set thread's own affinity to a processor number n */ +static int tMPI_Set_affinity(int n) +{ +#ifdef HAVE_PTHREAD_SETAFFINITY + cpu_set_t set; + + CPU_ZERO(&set); + CPU_SET(n, &set); + return pthread_setaffinity_np(pthread_self(), sizeof(set), &set); +#endif + return 0; +} + +int tMPI_Thread_create_aff(tMPI_Thread_t *thread, + void *(*start_routine)(void *), + void *arg) +{ + int ret; + + /* set the calling thread's affinity mask */ + if (tMPI_Atomic_get(&main_thread_aff_set) == 0) + { +#ifdef HAVE_PTHREAD_SETAFFINITY + cpu_set_t set; +#endif + /* this can be a spinlock because the chances of collision are low. */ + tMPI_Spinlock_lock( &main_thread_aff_lock ); + tMPI_Atomic_set( &aff_thread_number, 0); +#ifdef HAVE_PTHREAD_SETAFFINITY + CPU_ZERO(&set); + CPU_SET(0, &set); + pthread_setaffinity_np(pthread_self(), sizeof(set), &set); + /*fprintf(stderr, "Setting affinity.\n");*/ +#endif + tMPI_Atomic_set( &main_thread_aff_set, 1); + tMPI_Spinlock_unlock( &main_thread_aff_lock ); + } + + + if(thread==NULL) + { + tMPI_Fatal_error(TMPI_FARGS,"Invalid thread pointer."); + return EINVAL; + } + + *thread=(struct tMPI_Thread*)malloc(sizeof(struct tMPI_Thread)*1); + ret=pthread_create(&((*thread)->th),NULL,start_routine,arg); + + if(ret!=0) + { + /* Cannot use tMPI_error() since messages use threads for locking */ + tMPI_Fatal_error(TMPI_FARGS,"Failed to create POSIX thread, rc=%d",ret); + /* Use system memory allocation routines */ + return -1; + } + else + { +#ifdef HAVE_PTHREAD_SETAFFINITY + int n; + cpu_set_t set; + + n=tMPI_Atomic_add_return(&aff_thread_number, 1); + CPU_ZERO(&set); + CPU_SET(n, &set); + return pthread_setaffinity_np((*thread)->th, sizeof(set), &set); +#else + return 0; +#endif + } +} + + + + int tMPI_Thread_join(tMPI_Thread_t thread, void **value_ptr) { diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/settings.h gromacs-4.5.5/src/gmxlib/thread_mpi/settings.h --- gromacs-4.5.4/src/gmxlib/thread_mpi/settings.h 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/settings.h 2011-09-21 12:34:32.000000000 +0000 @@ -122,3 +122,8 @@ /*#define TMPI_PROFILE*/ +/* whether to turn on thread affinity (required for NUMA optimizations) + if the number of threads to spawn is equal to the number of processors. */ +#define TMPI_THREAD_AFFINITY + + diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/tmpi_init.c gromacs-4.5.5/src/gmxlib/thread_mpi/tmpi_init.c --- gromacs-4.5.4/src/gmxlib/thread_mpi/tmpi_init.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/tmpi_init.c 2011-09-21 12:34:32.000000000 +0000 @@ -249,7 +249,10 @@ } if (*nthreads<1) { - *nthreads=tMPI_Get_recommended_nthreads(); + int nth=tMPI_Thread_get_hw_number(); + + if (nth<1) nth=1; /* make sure it's at least 1 */ + *nthreads=nth; } return ret; @@ -392,6 +395,7 @@ if (N>0) { int i; + int set_affinity=FALSE; tmpi_finalized=FALSE; Nthreads=N; @@ -439,11 +443,36 @@ threads[i].start_fn_main=start_fn_main; threads[i].start_arg=start_arg; } + + /* now check whether to set affinity */ +#ifdef TMPI_THREAD_AFFINITY + { + int nhw=tMPI_Thread_get_hw_number(); + if ((nhw > 1) && (nhw == N)) + { + set_affinity=TRUE; + } + } +#endif + for(i=1;i=1) /* we're the main process */ diff -Nru gromacs-4.5.4/src/gmxlib/thread_mpi/winthreads.c gromacs-4.5.5/src/gmxlib/thread_mpi/winthreads.c --- gromacs-4.5.4/src/gmxlib/thread_mpi/winthreads.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/thread_mpi/winthreads.c 2011-09-21 12:34:32.000000000 +0000 @@ -86,10 +86,445 @@ static tMPI_Spinlock_t init_init=TMPI_SPINLOCK_INITIALIZER; /* whether tMPI_Thread_create has initialized these mutexes */ -tMPI_Atomic_t init_inited={ 0 }; +static tMPI_Atomic_t init_inited={ 0 }; +/* whether the main thread affinity has been set */ +static tMPI_Spinlock_t main_thread_aff_lock=TMPI_SPINLOCK_INITIALIZER; +static tMPI_Atomic_t main_thread_aff_set={ 0 }; + +/* + NUMA and Processor Group awareness support. + + NUMA support is implemented to maximize the chance that memory access + patterns remain Local to the NUMA node. + NUMA node processor affinity is utilized to prevent scheduler associated + drift across NUMA nodes. + Process Group support is implemented to enable > 64 processors to be + utilized. This is only supported when building 64bit. + + The high level approach is: + 1. Build a description of CPU topology, including processor numbers, NUMA + node numbers, and affinity masks. + 2. For processor intensive worker threads, create threads such that + the processor affinity and thread stack is kept local within a NUMA node. + 3. Employ simple round-robin affinity and node assignment approach when + creating threads. + 4. Use GetProcAddress() to obtain function pointers to functions that + are operating system version dependent, to allow maximum binary + compatibility. + + Scott Field (sfield@microsoft.com) Jan-2011 +*/ + + +typedef struct { + PROCESSOR_NUMBER ProcessorNumber; + GROUP_AFFINITY GroupAffinity; + USHORT NumaNodeNumber; +} MPI_NUMA_PROCESSOR_INFO; + + +/* thread/processor index, to allow setting round-robin affinity. */ +volatile ULONG g_ulThreadIndex; +/* a value of zero implies the system is not NUMA */ +ULONG g_ulHighestNumaNodeNumber=0; +/* total number of processors in g_MPI_ProcessInfo array */ +ULONG g_ulTotalProcessors; +/* array describing available processors, affinity masks, and NUMA node */ +MPI_NUMA_PROCESSOR_INFO *g_MPI_ProcessorInfo; + +/* function prototypes and variables to support obtaining function addresses + dynamically -- supports down-level operating systems */ + +typedef BOOL (WINAPI *func_GetNumaHighestNodeNumber_t)( PULONG + HighestNodeNumber ); +typedef BOOL (WINAPI *func_SetThreadGroupAffinity_t)( HANDLE hThread, + const GROUP_AFFINITY *GroupAffinity, + PGROUP_AFFINITY PreviousGroupAffinity ); +typedef BOOL (WINAPI *func_SetThreadIdealProcessorEx_t)( HANDLE hThread, + PPROCESSOR_NUMBER lpIdealProcessor, + PPROCESSOR_NUMBER lpPreviousIdealProcessor ); +typedef BOOL (WINAPI *func_GetNumaNodeProcessorMaskEx_t)( USHORT Node, + PGROUP_AFFINITY ProcessorMask ); +typedef BOOL (WINAPI *func_GetNumaProcessorNodeEx_t)( + PPROCESSOR_NUMBER Processor, + PUSHORT NodeNumber ); +typedef VOID (WINAPI *func_GetCurrentProcessorNumberEx_t)( + PPROCESSOR_NUMBER ProcNumber ); + +typedef HANDLE (WINAPI *func_CreateRemoteThreadEx_t)( + HANDLE hProcess, + LPSECURITY_ATTRIBUTES lpThreadAttributes, + SIZE_T dwStackSize, + LPTHREAD_START_ROUTINE lpStartAddress, + LPVOID lpParameter, + DWORD dwCreationFlags, + LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList, + LPDWORD lpThreadId); + +typedef BOOL (WINAPI *func_InitializeProcThreadAttributeList_t)( + LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList, + DWORD dwAttributeCount, + DWORD dwFlags, + PSIZE_T lpSize); +typedef BOOL (WINAPI *func_UpdateProcThreadAttribute_t)( + LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList, + DWORD dwFlags, + DWORD_PTR Attribute, + PVOID lpValue, + SIZE_T cbSize, + PVOID lpPreviousValue, + PSIZE_T lpReturnSize); +typedef VOID (WINAPI *func_DeleteProcThreadAttributeList_t)( + LPPROC_THREAD_ATTRIBUTE_LIST lpAttributeList); +typedef DWORD (WINAPI *func_GetActiveProcessorCount_t)(WORD GroupNumber); +typedef WORD (WINAPI *func_GetActiveProcessorGroupCount_t)(void); + + +/* WinXP SP2, WinXP64, WinSrv 2003 */ +func_GetNumaHighestNodeNumber_t func_GetNumaHighestNodeNumber; +/* Windows 7, WinSrv 2008R2 */ +func_SetThreadGroupAffinity_t func_SetThreadGroupAffinity; +func_SetThreadIdealProcessorEx_t func_SetThreadIdealProcessorEx; +func_GetNumaNodeProcessorMaskEx_t func_GetNumaNodeProcessorMaskEx; +func_GetNumaProcessorNodeEx_t func_GetNumaProcessorNodeEx; +func_GetCurrentProcessorNumberEx_t func_GetCurrentProcessorNumberEx; +func_GetActiveProcessorCount_t func_GetActiveProcessorCount; +func_GetActiveProcessorGroupCount_t func_GetActiveProcessorGroupCount; +func_CreateRemoteThreadEx_t func_CreateRemoteThreadEx; +/* Windows Vista, WinSrv 2008 */ +func_InitializeProcThreadAttributeList_t func_InitializeProcThreadAttributeList; +func_UpdateProcThreadAttribute_t func_UpdateProcThreadAttribute; +func_DeleteProcThreadAttributeList_t func_DeleteProcThreadAttributeList; + + +/* Set the main thread's affinity */ +static int tMPI_Set_main_thread_affinity(void) +{ + /* calling thread PROCESSOR_NUMBER */ + PROCESSOR_NUMBER CurrentProcessorNumber; + /* calling thread GROUP_AFFINITY */ + GROUP_AFFINITY CurrentThreadGroupAffinity; + /* calling thread NUMA node */ + USHORT CurrentNumaNodeNumber; + /* we can pre-check because it's atomic */ + if (tMPI_Atomic_get(&main_thread_aff_set) == 0) + { + /* this can be a spinlock because the chances of collision are low. */ + tMPI_Spinlock_lock( &main_thread_aff_lock ); + if( g_ulHighestNumaNodeNumber != 0 ) + { + func_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); + + + /* set the NUMA node affinity for the current thread + failures to set the current thread affinity are ignored, + as a fringe case can arise on >32 processor systems with a 32bit + build/code. + */ + func_SetThreadIdealProcessorEx(GetCurrentThread(), + &CurrentProcessorNumber, + NULL); + + if(func_GetNumaProcessorNodeEx(&CurrentProcessorNumber, + &CurrentNumaNodeNumber)) + { + /* for the NUMA node number associated with the current processor + number, get the group affinity mask */ + if(func_GetNumaNodeProcessorMaskEx(CurrentNumaNodeNumber, + &CurrentThreadGroupAffinity)) + { + /* set the current thread affinity to prevent it from running on + other NUMA nodes */ + func_SetThreadGroupAffinity(GetCurrentThread(), + &CurrentThreadGroupAffinity, + NULL); + } + } + } + else + { + /* No NUMA. For now, we just do a similar thing. */ + if ( (func_GetCurrentProcessorNumberEx != NULL) && + (func_SetThreadIdealProcessorEx)) + { + func_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); + func_SetThreadIdealProcessorEx(GetCurrentThread(), + &CurrentProcessorNumber, + NULL); + } + } + tMPI_Atomic_set( &main_thread_aff_set, 1); + tMPI_Spinlock_unlock( &main_thread_aff_lock ); + } + return 0; +} + +/* returns 0 on success. + Success is returned if the system is non-NUMA, OR the system doesn't + support appropriate NUMA APIs, OR the system is NUMA and we successfully + initialized support. + + returns -1 on error. + This can happen if an API returned an error, a memory allocation failed, or + we failed to initialize affinity mapping information. +*/ +int tMPI_Init_NUMA(void) +{ + /* module handle to kernel32.dll -- we already reference it, so it's already loaded */ + HMODULE hModKernel32 = NULL; + /* 0-based NUMA node count -- does not imply all nodes have available (eg: hot-plug) processors */ + ULONG ulHighestNumaNodeNumber; + /* total number of processors available per affinity masks */ + DWORD dwTotalProcessors = 0; + ULONG i = 0; + + /* calling thread PROCESSOR_NUMBER */ + PROCESSOR_NUMBER CurrentProcessorNumber; + /* calling thread GROUP_AFFINITY */ + GROUP_AFFINITY CurrentThreadGroupAffinity; + /* calling thread NUMA node */ + USHORT CurrentNumaNodeNumber; + + WORD wActiveGroupCount; + WORD GroupIndex; + + /* array of processor information structures */ + MPI_NUMA_PROCESSOR_INFO *pMPI_ProcessorInfo = NULL; + + /* assume an error condition */ + int iRet = -1; + + hModKernel32 = GetModuleHandleA("kernel32.dll"); + + if( hModKernel32 == NULL ) + { + return 0; + } + + /* obtain addresses of relevant NUMA functions, most of which are + Windows 7 / Windows Server 2008R2 only functions + this is done using GetProcAddress to enable the binary to run on older + Windows versions. + */ + + func_GetNumaHighestNodeNumber = (func_GetNumaHighestNodeNumber_t) GetProcAddress( hModKernel32, "GetNumaHighestNodeNumber" ); + + if( func_GetNumaHighestNodeNumber == NULL ) + { + return 0; + } + + /* determine if we're on a NUMA system and if so, determine the number of + (potential) nodes */ + + if(!func_GetNumaHighestNodeNumber( &ulHighestNumaNodeNumber )) + { + return -1; + } + + if( ulHighestNumaNodeNumber == 0 ) + { + /* system is not NUMA */ + return 0; + } + + func_SetThreadGroupAffinity = (func_SetThreadGroupAffinity_t)GetProcAddress( hModKernel32, "SetThreadGroupAffinity" ); + func_SetThreadIdealProcessorEx = (func_SetThreadIdealProcessorEx_t)GetProcAddress( hModKernel32, "SetThreadIdealProcessorEx" ); + func_CreateRemoteThreadEx = (func_CreateRemoteThreadEx_t)GetProcAddress( hModKernel32, "CreateRemoteThreadEx" ); + func_GetNumaNodeProcessorMaskEx = (func_GetNumaNodeProcessorMaskEx_t)GetProcAddress( hModKernel32, "GetNumaNodeProcessorMaskEx" ); + func_GetNumaProcessorNodeEx = (func_GetNumaProcessorNodeEx_t)GetProcAddress( hModKernel32, "GetNumaProcessorNodeEx" ); + func_GetCurrentProcessorNumberEx = (func_GetCurrentProcessorNumberEx_t)GetProcAddress( hModKernel32, "GetCurrentProcessorNumberEx" ); + func_GetActiveProcessorCount = (func_GetActiveProcessorCount_t)GetProcAddress( hModKernel32, "GetActiveProcessorCount" ); + func_GetActiveProcessorGroupCount = (func_GetActiveProcessorGroupCount_t)GetProcAddress( hModKernel32, "GetActiveProcessorGroupCount" ); + func_InitializeProcThreadAttributeList = (func_InitializeProcThreadAttributeList_t)GetProcAddress( hModKernel32, "InitializeProcThreadAttributeList" ); + func_UpdateProcThreadAttribute = (func_UpdateProcThreadAttribute_t)GetProcAddress( hModKernel32, "UpdateProcThreadAttribute" ); + func_DeleteProcThreadAttributeList = (func_DeleteProcThreadAttributeList_t)GetProcAddress( hModKernel32, "DeleteProcThreadAttributeList" ); + + if( (func_SetThreadGroupAffinity == NULL) || + (func_SetThreadIdealProcessorEx == NULL) || + (func_CreateRemoteThreadEx == NULL) || + (func_GetNumaNodeProcessorMaskEx == NULL) || + (func_GetNumaProcessorNodeEx == NULL) || + (func_GetCurrentProcessorNumberEx == NULL) || + (func_GetActiveProcessorCount == NULL) || + (func_GetActiveProcessorGroupCount == NULL) || + (func_InitializeProcThreadAttributeList == NULL) || + (func_UpdateProcThreadAttribute == NULL) || + (func_DeleteProcThreadAttributeList == NULL) ) + { + /* if any addresses couldn't be located, assume NUMA functionality + isn't supported */ + return 0; + } + + /* count the active processors across the groups */ + + func_GetCurrentProcessorNumberEx(&CurrentProcessorNumber); + + wActiveGroupCount = func_GetActiveProcessorGroupCount(); + + dwTotalProcessors = func_GetActiveProcessorCount( ALL_PROCESSOR_GROUPS ); + +#if !((defined WIN64 || defined _WIN64)) + /* WOW64 doesn't allow setting the affinity correctly beyond 32 + processors -- the KAFFINITY mask is only 32 bits wide + This check is only here for completeness -- large systems should be + running 64bit Gromacs code, where the processor quantity is not + constrained. + By failing here, the WOW64 32bit client will use normal CreateThread(), + which can schedule up to 64 un-affinitized threads + */ + + if( dwTotalProcessors > 32 ) + { + return 0; + } +#endif + + /* allocate array of processor info blocks */ + + pMPI_ProcessorInfo = tMPI_Malloc( sizeof(MPI_NUMA_PROCESSOR_INFO) * + dwTotalProcessors ); + if(pMPI_ProcessorInfo == NULL) + { + tMPI_Fatal_error(TMPI_FARGS,"tMPI_Malloc failed for processor information"); + goto cleanup; + } + + /* zero fill to cover reserved must be-zero fields */ + memset(pMPI_ProcessorInfo, 0, sizeof(MPI_NUMA_PROCESSOR_INFO) * dwTotalProcessors); + + /* loop through each processor group, and for each group, capture the + processor numbers and NUMA node information. */ + + for(GroupIndex = 0 ; GroupIndex < wActiveGroupCount ; GroupIndex++) + { + DWORD dwGroupProcessorCount; + BYTE ProcessorIndex; + + dwGroupProcessorCount = func_GetActiveProcessorCount( GroupIndex ); + + for(ProcessorIndex = 0 ; ProcessorIndex < dwGroupProcessorCount ; + ProcessorIndex++) + { + PROCESSOR_NUMBER *pProcessorNumber = &(pMPI_ProcessorInfo[i].ProcessorNumber); + GROUP_AFFINITY *pGroupAffinity = &(pMPI_ProcessorInfo[i].GroupAffinity); + USHORT *pNodeNumber = &(pMPI_ProcessorInfo[i].NumaNodeNumber); + + pProcessorNumber->Group = GroupIndex; + pProcessorNumber->Number = ProcessorIndex; + + /* save an index to the processor array entry for the current processor + this is used to enable subsequent threads to be created in a round + robin fashion starting at the next array entry + */ + + if( (CurrentProcessorNumber.Group == pProcessorNumber->Group ) && + (CurrentProcessorNumber.Number == pProcessorNumber->Number) ) + { + /* set global: current thread index into processor array */ + g_ulThreadIndex = i; + } + + /* capture the node number and group affinity associated with processor entry + any failures here are assumed to be catastrophic and disable + the group & NUMA aware thread support + */ + + if(!func_GetNumaProcessorNodeEx(pProcessorNumber, pNodeNumber)) + { + tMPI_Fatal_error(TMPI_FARGS, + "Processor enumeration, GetNumaProcessorNodeEx failed, error code=%d", + GetLastError()); + goto cleanup; + } + + if(!func_GetNumaNodeProcessorMaskEx(*pNodeNumber, pGroupAffinity)) + { + tMPI_Fatal_error(TMPI_FARGS, + "Processor enumeration, GetNumaNodeProcessorMaskEx failed, error code=%d", + GetLastError()); + goto cleanup; + } + + /* future enhancement: construct GroupAffinity (single) processor + mask within NUMA node for this processor entry */ + + /* increment processor array index */ + i++; + + /* sanity check, should never happen */ + + if(i > dwTotalProcessors) + { + tMPI_Fatal_error(TMPI_FARGS,"Processor enumeration exceeds allocated memory!"); + goto cleanup; + } + } + } + +#if 0 + /* set the NUMA node affinity for the current thread + failures to set the current thread affinity are ignored, + as a fringe case can arise on >32 processor systems with a 32bit + build/code. + */ + func_SetThreadIdealProcessorEx(GetCurrentThread(), + &CurrentProcessorNumber, + NULL); + + if(func_GetNumaProcessorNodeEx(&CurrentProcessorNumber, + &CurrentNumaNodeNumber)) + { + /* for the NUMA node number associated with the current processor + number, get the group affinity mask */ + if(func_GetNumaNodeProcessorMaskEx(CurrentNumaNodeNumber, + &CurrentThreadGroupAffinity)) + { + /* set the current thread affinity to prevent it from running on + other NUMA nodes */ + func_SetThreadGroupAffinity(GetCurrentThread(), + &CurrentThreadGroupAffinity, + NULL); + } + } +#endif + + /* capture number of processors, highest NUMA node number, and processor + array */ + g_ulTotalProcessors = dwTotalProcessors; + g_ulHighestNumaNodeNumber = ulHighestNumaNodeNumber; + g_MPI_ProcessorInfo = pMPI_ProcessorInfo; + + iRet = 0 ; + +#if 0 + // TODO: debug DISCARD + printf("primary thread tid=%lu group=%lu mask=0x%I64x group=%lu number=%lu ulThreadIndex=%lu\n", + GetCurrentThreadId(), + CurrentThreadGroupAffinity.Group, + (ULONGLONG)CurrentThreadGroupAffinity.Mask, + (ULONG)CurrentProcessorNumber.Group, + (ULONG)CurrentProcessorNumber.Number, + g_ulThreadIndex); +#endif + +cleanup: + + if( iRet != 0 ) + { + if( pMPI_ProcessorInfo ) + { + tMPI_Free( pMPI_ProcessorInfo ); + } + } + + return 0; +} + static void tMPI_Init_initers(void) { int state; @@ -108,6 +543,9 @@ InitializeCriticalSection(&cond_init); InitializeCriticalSection(&barrier_init); + /* fatal errors are handled by the routine by calling tMPI_Fatal_error() */ + tMPI_Init_NUMA(); + tMPI_Atomic_memory_barrier_rel(); tMPI_Atomic_set(&init_inited, 1); } @@ -116,7 +554,8 @@ } } - +/* TODO: this needs to go away! (there's another one in pthreads.c) + fatal errors are thankfully really rare*/ void tMPI_Fatal_error(const char *file, int line, const char *message, ...) { va_list ap; @@ -151,6 +590,159 @@ return 0; } +HANDLE tMPI_Thread_create_NUMA(LPSECURITY_ATTRIBUTES lpThreadAttributes, + SIZE_T dwStackSize, + LPTHREAD_START_ROUTINE lpStartAddress, + LPVOID lpParameter, + DWORD dwCreationFlags, + LPDWORD lpThreadId) +{ + LPPROC_THREAD_ATTRIBUTE_LIST pAttributeList = NULL; + HANDLE hThread = NULL; + SIZE_T cbAttributeList = 0; + GROUP_AFFINITY GroupAffinity; + PROCESSOR_NUMBER IdealProcessorNumber; + ULONG CurrentProcessorIndex; + + /* for each thread created, round-robin through the set of valid + processors and affinity masks. + the assumption is that callers of tMPI_Thread_create_NUMA are creating + threads that saturate a given processor. + for cases where threads are being created that rarely do work, standard + thread creation (eg: CreateThread) should be invoked instead. + */ + + CurrentProcessorIndex = (ULONG)InterlockedIncrement((volatile LONG *)&g_ulThreadIndex); + CurrentProcessorIndex = CurrentProcessorIndex % g_ulTotalProcessors; + + /* group, mask. */ + + memcpy(&GroupAffinity, + &(g_MPI_ProcessorInfo[CurrentProcessorIndex].GroupAffinity), + sizeof(GROUP_AFFINITY)); + + /* group, processor number */ + + memcpy(&IdealProcessorNumber, + &(g_MPI_ProcessorInfo[CurrentProcessorIndex].ProcessorNumber), + sizeof(PROCESSOR_NUMBER)); + + /* determine size of allocation for AttributeList */ + + if(!func_InitializeProcThreadAttributeList(pAttributeList, + 2, + 0, + &cbAttributeList)) + { + DWORD dwLastError = GetLastError(); + if( dwLastError != ERROR_INSUFFICIENT_BUFFER ) + { + tMPI_Fatal_error(TMPI_FARGS, + "InitializeProcThreadAttributeList, error code=%d", + dwLastError); + goto cleanup; + } + } + + pAttributeList = (LPPROC_THREAD_ATTRIBUTE_LIST)tMPI_Malloc( cbAttributeList ); + if( pAttributeList == NULL ) + { + tMPI_Fatal_error(TMPI_FARGS,"Failed to allocate pAttributeList"); + goto cleanup; + } + + memset( pAttributeList, 0, cbAttributeList ); + + if(!func_InitializeProcThreadAttributeList(pAttributeList, + 2, + 0, + &cbAttributeList)) + { + tMPI_Fatal_error(TMPI_FARGS, + "InitializeProcThreadAttributeList, error code=%d", + GetLastError()); + goto cleanup; + } + + if(!func_UpdateProcThreadAttribute(pAttributeList, + 0, + PROC_THREAD_ATTRIBUTE_GROUP_AFFINITY, + &GroupAffinity, + sizeof(GroupAffinity), + NULL, + NULL)) + { + tMPI_Fatal_error(TMPI_FARGS,"UpdateProcThreadAttribute, error code=%d", + GetLastError()); + goto cleanup; + } + + if(!func_UpdateProcThreadAttribute(pAttributeList, + 0, + PROC_THREAD_ATTRIBUTE_IDEAL_PROCESSOR, + &IdealProcessorNumber, + sizeof(IdealProcessorNumber), + NULL, + NULL)) + { + tMPI_Fatal_error(TMPI_FARGS,"UpdateProcThreadAttribute, error code=%d", + GetLastError()); + goto cleanup; + } + + + hThread = func_CreateRemoteThreadEx( GetCurrentProcess(), + lpThreadAttributes, + dwStackSize, + lpStartAddress, + lpParameter, + dwCreationFlags, + pAttributeList, + lpThreadId); + + func_DeleteProcThreadAttributeList( pAttributeList ); + +#if 0 + // TODO: debug only or DISCARD + if( hThread ) + { + PROCESSOR_NUMBER ProcNumber; + USHORT NodeNumber; + + GetThreadIdealProcessorEx(hThread, &ProcNumber); + GetNumaProcessorNodeEx(&ProcNumber, &NodeNumber); + + printf("started thread tid=%lu group=%lu mask=0x%I64x number=%lu numanode=%lu\n", + *lpThreadId, + GroupAffinity.Group, + (ULONGLONG)GroupAffinity.Mask, + ProcNumber.Number, + NodeNumber + ); + } +#endif + +cleanup: + + if( pAttributeList ) + { + tMPI_Free( pAttributeList ); + } + + return hThread; +} + +int tMPI_Thread_get_hw_number(void) +{ + int ret; + + SYSTEM_INFO sysinfo; + GetSystemInfo( &sysinfo ); + + ret=sysinfo.dwNumberOfProcessors; + return ret; +} + int tMPI_Thread_create(tMPI_Thread_t *thread, void *(*start_routine)(void *), void *arg) @@ -161,30 +753,104 @@ tMPI_Init_initers(); /* a small memory leak to be sure that it doesn't get deallocated - once this function ends */ + once this function ends, before the newly created thread uses it. */ prm=(struct tMPI_Thread_starter_param*) - malloc(sizeof(struct tMPI_Thread_starter_param)); + tMPI_Malloc(sizeof(struct tMPI_Thread_starter_param)); prm->start_routine= start_routine; prm->param=arg; - *thread=(struct tMPI_Thread*)malloc(sizeof(struct tMPI_Thread)*1); + *thread=(struct tMPI_Thread*)tMPI_Malloc(sizeof(struct tMPI_Thread)*1); if(thread==NULL) { tMPI_Fatal_error(TMPI_FARGS,"Invalid thread pointer."); return EINVAL; } - - (*thread)->th = CreateThread(NULL, 0, tMPI_Win32_thread_starter, prm, 0, + /* just create a plain thread. */ + (*thread)->th = CreateThread(NULL, + 0, + tMPI_Win32_thread_starter, + prm, + 0, &thread_id); if((*thread)->th==NULL) { + tMPI_Free(thread); tMPI_Fatal_error(TMPI_FARGS,"Failed to create thread, error code=%d", GetLastError()); return -1; } - /* inherit the thread priority from the paren thread. */ + + /* inherit the thread priority from the parent thread. */ + /* TODO: is there value in setting this, vs. just allowing it to default + from the process? currently, this limits the effectivenes of changing + the priority in eg: TaskManager. */ + SetThreadPriority(((*thread)->th), GetThreadPriority(GetCurrentThread())); + + return 0; +} + + + + + +int tMPI_Thread_create_aff(tMPI_Thread_t *thread, + void *(*start_routine)(void *), void *arg) +{ + DWORD thread_id; + struct tMPI_Thread_starter_param *prm; + + tMPI_Init_initers(); + tMPI_Set_main_thread_affinity(); + + /* a small memory leak to be sure that it doesn't get deallocated + once this function ends, before the newly created thread uses it. */ + prm=(struct tMPI_Thread_starter_param*) + tMPI_Malloc(sizeof(struct tMPI_Thread_starter_param)); + prm->start_routine= start_routine; + prm->param=arg; + + *thread=(struct tMPI_Thread*)tMPI_Malloc(sizeof(struct tMPI_Thread)*1); + + if(thread==NULL) + { + tMPI_Fatal_error(TMPI_FARGS,"Invalid thread pointer."); + return EINVAL; + } + + if( g_ulHighestNumaNodeNumber != 0 ) + { + /* if running on a NUMA system, use the group and NUMA aware thread + creation logic */ + (*thread)->th = tMPI_Thread_create_NUMA(NULL, + 0, + tMPI_Win32_thread_starter, + prm, + 0, + &thread_id); + } else { + /* TODO: for now, non-NUMA systems don't set thread affinity. */ + (*thread)->th = CreateThread(NULL, + 0, + tMPI_Win32_thread_starter, + prm, + 0, + &thread_id); + } + + if((*thread)->th==NULL) + { + tMPI_Free(thread); + tMPI_Fatal_error(TMPI_FARGS,"Failed to create thread, error code=%d", + GetLastError()); + return -1; + } + + /* inherit the thread priority from the parent thread. */ + /* TODO: is there value in setting this, vs. just allowing it to default + from the process? currently, this limits the effectivenes of changing + the priority in eg: TaskManager. */ SetThreadPriority(((*thread)->th), GetThreadPriority(GetCurrentThread())); return 0; @@ -217,7 +883,7 @@ } } CloseHandle(thread->th); - free(thread); + tMPI_Free(thread); return 0; } @@ -269,7 +935,7 @@ } DeleteCriticalSection(&(mtx->mutex->cs)); - free(mtx->mutex); + tMPI_Free(mtx->mutex); return 0; } @@ -383,7 +1049,7 @@ int tMPI_Thread_key_delete(tMPI_Thread_key_t key) { TlsFree(key.key->wkey); - free(key.key); + tMPI_Free(key.key); return 0; } @@ -490,7 +1156,7 @@ /* windows doesnt have this function */ #else DeleteCriticalSection(&(cond->condp->wtr_lock)); - free(cond->condp); + tMPI_Free(cond->condp); #endif return 0; } @@ -732,7 +1398,7 @@ tMPI_Thread_cond_destroy(&(barrier->barrierp->cv)); - free(barrier->barrierp); + tMPI_Free(barrier->barrierp); return 0; } diff -Nru gromacs-4.5.4/src/gmxlib/topsort.c gromacs-4.5.5/src/gmxlib/topsort.c --- gromacs-4.5.4/src/gmxlib/topsort.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/topsort.c 2011-09-21 12:34:32.000000000 +0000 @@ -108,6 +108,9 @@ bPert = (ip->lj14.c6A != ip->lj14.c6B || ip->lj14.c12A != ip->lj14.c12B); break; + case F_CMAP: + bPert = FALSE; + break; default: bPert = FALSE; gmx_fatal(FARGS,"Function type %s not implemented in ip_pert", diff -Nru gromacs-4.5.4/src/gmxlib/trxio.c gromacs-4.5.5/src/gmxlib/trxio.c --- gromacs-4.5.4/src/gmxlib/trxio.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/trxio.c 2011-09-21 12:34:32.000000000 +0000 @@ -690,6 +690,9 @@ /* Checkpoint files can not contain mulitple frames */ break; case efG96: + gmx_fatal(FARGS, + "Reading trajectories in .g96 format is broken. Please use\n" + "a different file format."); read_g96_conf(gmx_fio_getfp(status->fio),NULL,fr); bRet = (fr->natoms > 0); break; diff -Nru gromacs-4.5.4/src/gmxlib/typedefs.c gromacs-4.5.5/src/gmxlib/typedefs.c --- gromacs-4.5.4/src/gmxlib/typedefs.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/typedefs.c 2011-09-21 12:34:32.000000000 +0000 @@ -468,7 +468,6 @@ sfree(enerhist->ener_ave); sfree(enerhist->ener_sum); sfree(enerhist->ener_sum_sim); - sfree(enerhist->dht); if (enerhist->dht != NULL) { diff -Nru gromacs-4.5.4/src/gmxlib/version.c gromacs-4.5.5/src/gmxlib/version.c --- gromacs-4.5.4/src/gmxlib/version.c 2011-03-21 15:14:09.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/version.c 2011-09-21 12:39:02.000000000 +0000 @@ -1,4 +1,4 @@ #include "version.h" -const char _gmx_ver_string[] = "VERSION 4.5.4-20110321-fe29f33-dirty"; -const char _gmx_full_git_hash[] = "fe29f33d948b12d5731c1d3e78966523e46943fa-dirty"; +const char _gmx_ver_string[] = "VERSION 4.5.5-20110921-c9635ce-dirty"; +const char _gmx_full_git_hash[] = "c9635cec6fd784301000b4330022a227c3a6da2a-dirty"; const char _gmx_central_base_hash[] = ""; diff -Nru gromacs-4.5.4/src/gmxlib/wman.c gromacs-4.5.5/src/gmxlib/wman.c --- gromacs-4.5.4/src/gmxlib/wman.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/gmxlib/wman.c 2011-09-21 12:34:32.000000000 +0000 @@ -90,6 +90,10 @@ { "[BR]", "\\\\" }, { "%", "\\%" }, { "&", "\\&" }, + /* The next couple of lines allow true Greek symbols to be written to the + manual, which makes it look pretty */ + { "[GRK]", "$\\" }, + { "[grk]", "$" }, /* The next two lines used to substitute "|" and "||" to "or", but only * g_angle used that functionality, so that was changed to a textual * "or" there, so that other places could use those symbols to indicate @@ -107,7 +111,9 @@ { "[IT]", "" }, { "[it]", "" }, { "[PAR]","\n\n" }, - { "[BR]", "\n"} + { "[BR]", "\n"}, + { "[GRK]", "" }, + { "[grk]", "" } }; #define NSRTTY asize(sandrTty) @@ -122,7 +128,9 @@ { "[IT]", "''" }, { "[it]", "''" }, { "[PAR]","\n\n" }, - { "[BR]", "\n"} + { "[BR]", "\n" }, + { "[GRK]", "&" }, + { "[grk]", ";" } }; #define NSRWIKI asize(sandrWiki) @@ -140,7 +148,9 @@ { "^", "" }, { "#", "" }, { "[BR]", "\n"}, - { "-", "\\-"} + { "-", "\\-"}, + { "[GRK]", "" }, + { "[grk]", "" } }; #define NSRNROFF asize(sandrNROFF) @@ -154,7 +164,9 @@ { "[IT]", "" }, { "[it]", "" }, { "[PAR]","

" }, - { "[BR]", "
" } + { "[BR]", "
" }, + { "[GRK]", "&" }, + { "[grk]", ";" } }; #define NSRHTML asize(sandrHTML) @@ -168,7 +180,9 @@ { "[IT]", "" }, { "[it]", "" }, { "[PAR]","\n" }, - { "[BR]", "
" } + { "[BR]", "
" }, + { "[GRK]", "" }, + { "[grk]", "" } }; #define NSRXML asize(sandrXML) diff -Nru gromacs-4.5.4/src/kernel/compute_io.c gromacs-4.5.5/src/kernel/compute_io.c --- gromacs-4.5.4/src/kernel/compute_io.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/compute_io.c 2011-09-21 12:34:32.000000000 +0000 @@ -1,4 +1,5 @@ -/* +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * * * This source code is part of * @@ -40,31 +41,44 @@ #include #include "typedefs.h" +static int div_nsteps(int nsteps,int nst) +{ + if (nst > 0) + { + return (1 + nsteps + nst - 1)/nst; + } + else + { + return 0; + } +} + double compute_io(t_inputrec *ir,int natoms,gmx_groups_t *groups, int nrener,int nrepl) { int nsteps = ir->nsteps; int i,nxtcatoms=0; - int nstx=0,nstv=0,nstf=0,nste=0,nstlog=0,nstxtc=0,nfep=0; + int nstx,nstv,nstf,nste,nstlog,nstxtc,nfep=0; double cio; - if (ir->nstxout > 0) - nstx = 1 + nsteps / ir->nstxout; - if (ir->nstvout > 0) - nstv = 1 + nsteps / ir->nstvout; - if (ir->nstfout > 0) - nstf = (1 + nsteps) / ir->nstfout; - if (ir->nstxtcout > 0) { - for(i=0; igrpnr[egcXTC] == NULL || groups->grpnr[egcXTC][i] == 0) - nxtcatoms++; + nstx = div_nsteps(nsteps,ir->nstxout); + nstv = div_nsteps(nsteps,ir->nstvout); + nstf = div_nsteps(nsteps,ir->nstfout); + nstxtc = div_nsteps(nsteps,ir->nstxtcout); + if (ir->nstxtcout > 0) + { + for(i=0; igrpnr[egcXTC] == NULL || groups->grpnr[egcXTC][i] == 0) + { + nxtcatoms++; + } + } } - nstxtc = (1 + nsteps) / ir->nstxtcout; - } - if (ir->nstlog > 0) - nstlog = 1 + nsteps / ir->nstlog; - if (ir->nstenergy > 0) - nste = 3 + nsteps / ir->nstenergy; + nstlog = div_nsteps(nsteps,ir->nstlog); + /* We add 2 for the header */ + nste = div_nsteps(2+nsteps,ir->nstenergy); + cio = 80*natoms; cio += (nstx+nstf+nstv)*sizeof(real)*(3.0*natoms); cio += nstxtc*(14*4 + nxtcatoms*5.0); /* roughly 5 bytes per atom */ @@ -82,7 +96,7 @@ { int nchars = 8 + ndh*10; /* time data ~8 chars/line, dH data ~10 chars/line */ - cio += ((1 + nsteps)/ir->nstdhdl)*nchars; + cio += div_nsteps(nsteps,ir->nstdhdl)*nchars; } else { @@ -90,24 +104,21 @@ if (ir->dh_hist_size <= 0) { /* as data blocks: 1 real per dH point */ - cio += ((1 + nsteps)/ir->nstdhdl)*ndh*sizeof(real); + cio += div_nsteps(nsteps,ir->nstenergy)*ndh*sizeof(real); } else { /* as histograms: dh_hist_size ints per histogram */ - cio += ((1 + nsteps)/ir->nstenergy)* + cio += div_nsteps(nsteps,ir->nstenergy)* sizeof(int)*ir->dh_hist_size*ndh; } } } - if (ir->pull != NULL) { - if (ir->pull->nstxout > 0) { - cio += (1 + nsteps)/ir->pull->nstxout*20; /* roughly 20 chars per line */ + if (ir->pull != NULL) + { + cio += div_nsteps(nsteps,ir->pull->nstxout)*20; /* roughly 20 chars per line */ + cio += div_nsteps(nsteps,ir->pull->nstfout)*20; /* roughly 20 chars per line */ } - if (ir->pull->nstfout > 0) { - cio += (1 + nsteps)/ir->pull->nstfout*20; /* roughly 20 chars per line */ - } - } return cio*nrepl/(1024*1024); } diff -Nru gromacs-4.5.4/src/kernel/genhydro.c gromacs-4.5.5/src/kernel/genhydro.c --- gromacs-4.5.4/src/kernel/genhydro.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/genhydro.c 2011-09-21 12:34:32.000000000 +0000 @@ -146,8 +146,9 @@ for(rnr=0; rnr < pdba->nres; rnr++) { ahptr=search_h_db(nah,ah,*pdba->resinfo[rnr].rtp); if ( ahptr ) { - if (hb[rnr].name==NULL) - hb[rnr].name=strdup(ahptr->name); + if (hb[rnr].name==NULL) { + hb[rnr].name=strdup(ahptr->name); + } merge_hacks(ahptr, &hb[rnr]); } } @@ -166,17 +167,22 @@ all hacks involving atoms from resp. previous or next residue (i.e. which name begins with '-' (N) or '+' (C) */ bIgnore = FALSE; - if ( bN ) /* N-terminus: ignore '-' */ - for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) - bIgnore = hbr->hack[j].a[k][0]=='-'; - if ( bC ) /* C-terminus: ignore '+' */ - for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) - bIgnore = hbr->hack[j].a[k][0]=='+'; + if ( bN ) { /* N-terminus: ignore '-' */ + for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) { + bIgnore = hbr->hack[j].a[k][0]=='-'; + } + } + if ( bC ) { /* C-terminus: ignore '+' */ + for(k=0; k<4 && hbr->hack[j].a[k] && !bIgnore; k++) { + bIgnore = hbr->hack[j].a[k][0]=='+'; + } + } /* must be either hdb entry (tp>0) or add from tdb (oname==NULL) and first control aton (AI) matches this atom or delete/replace from tdb (oname!=NULL) and oname matches this atom */ - if (debug) fprintf(debug," %s", - hbr->hack[j].oname?hbr->hack[j].oname:hbr->hack[j].AI); + if (debug) { + fprintf(debug," %s",hbr->hack[j].oname?hbr->hack[j].oname:hbr->hack[j].AI); + } if ( !bIgnore && ( ( ( hbr->hack[j].tp > 0 || hbr->hack[j].oname==NULL ) && @@ -184,56 +190,60 @@ ( hbr->hack[j].oname!=NULL && strcmp(atomname, hbr->hack[j].oname) == 0) ) ) { /* now expand all hacks for this atom */ - if (debug) fprintf(debug," +%dh",hbr->hack[j].nr); + if (debug) { + fprintf(debug," +%dh",hbr->hack[j].nr); + } srenew(*abi,*nabi + hbr->hack[j].nr); for(k=0; k < hbr->hack[j].nr; k++) { - copy_t_hack(&hbr->hack[j], &(*abi)[*nabi + k]); - (*abi)[*nabi + k].bXSet = FALSE; - /* if we're adding (oname==NULL) and don't have a new name (nname) - yet, build it from atomname */ - if ( (*abi)[*nabi + k].nname==NULL ) { - if ( (*abi)[*nabi + k].oname==NULL ) { - (*abi)[*nabi + k].nname=strdup(atomname); - (*abi)[*nabi + k].nname[0]='H'; - } - } else { - if (gmx_debug_at) { - fprintf(debug,"Hack '%s' %d, replacing nname '%s' with '%s' (old name '%s')\n", - atomname,j, - (*abi)[*nabi + k].nname,hbr->hack[j].nname, - (*abi)[*nabi + k].oname ? (*abi)[*nabi + k].oname : ""); - } - sfree((*abi)[*nabi + k].nname); - (*abi)[*nabi + k].nname=strdup(hbr->hack[j].nname); - } + copy_t_hack(&hbr->hack[j], &(*abi)[*nabi + k]); + (*abi)[*nabi + k].bXSet = FALSE; + /* if we're adding (oname==NULL) and don't have a new name (nname) + yet, build it from atomname */ + if ( (*abi)[*nabi + k].nname==NULL ) { + if ( (*abi)[*nabi + k].oname==NULL ) { + (*abi)[*nabi + k].nname=strdup(atomname); + (*abi)[*nabi + k].nname[0]='H'; + } + } else { + if (gmx_debug_at) { + fprintf(debug,"Hack '%s' %d, replacing nname '%s' with '%s' (old name '%s')\n", + atomname,j, + (*abi)[*nabi + k].nname,hbr->hack[j].nname, + (*abi)[*nabi + k].oname ? (*abi)[*nabi + k].oname : ""); + } + sfree((*abi)[*nabi + k].nname); + (*abi)[*nabi + k].nname=strdup(hbr->hack[j].nname); + } - if (hbr->hack[j].tp == 10 && k == 2) { - /* This is a water virtual site, not a hydrogen */ - /* Ugly hardcoded name hack */ - (*abi)[*nabi + k].nname[0] = 'M'; - } else if (hbr->hack[j].tp == 11 && k >= 2) { - /* This is a water lone pair, not a hydrogen */ - /* Ugly hardcoded name hack */ - srenew((*abi)[*nabi + k].nname,4); - (*abi)[*nabi + k].nname[0] = 'L'; - (*abi)[*nabi + k].nname[1] = 'P'; - (*abi)[*nabi + k].nname[2] = '1' + k - 2; - (*abi)[*nabi + k].nname[3] = '\0'; - } else if ( hbr->hack[j].nr > 1 ) { - /* adding more than one atom, number them */ - l = strlen((*abi)[*nabi + k].nname); - srenew((*abi)[*nabi + k].nname, l+2); - (*abi)[*nabi + k].nname[l] = '1' + k; - (*abi)[*nabi + k].nname[l+1] = '\0'; - } + if (hbr->hack[j].tp == 10 && k == 2) { + /* This is a water virtual site, not a hydrogen */ + /* Ugly hardcoded name hack */ + (*abi)[*nabi + k].nname[0] = 'M'; + } else if (hbr->hack[j].tp == 11 && k >= 2) { + /* This is a water lone pair, not a hydrogen */ + /* Ugly hardcoded name hack */ + srenew((*abi)[*nabi + k].nname,4); + (*abi)[*nabi + k].nname[0] = 'L'; + (*abi)[*nabi + k].nname[1] = 'P'; + (*abi)[*nabi + k].nname[2] = '1' + k - 2; + (*abi)[*nabi + k].nname[3] = '\0'; + } else if ( hbr->hack[j].nr > 1 ) { + /* adding more than one atom, number them */ + l = strlen((*abi)[*nabi + k].nname); + srenew((*abi)[*nabi + k].nname, l+2); + (*abi)[*nabi + k].nname[l] = '1' + k; + (*abi)[*nabi + k].nname[l+1] = '\0'; + } } (*nabi) += hbr->hack[j].nr; /* add hacks to atoms we've just added */ - if ( hbr->hack[j].tp > 0 || hbr->hack[j].oname==NULL ) - for(k=0; k < hbr->hack[j].nr; k++) - expand_hackblocks_one(hbr, (*abi)[*nabi-hbr->hack[j].nr+k].nname, + if ( hbr->hack[j].tp > 0 || hbr->hack[j].oname==NULL ) { + for(k=0; k < hbr->hack[j].nr; k++) { + expand_hackblocks_one(hbr, (*abi)[*nabi-hbr->hack[j].nr+k].nname, nabi, abi, bN, bC); + } + } } } } @@ -313,30 +323,31 @@ for(j=0; j < nab[i]; j+=ab[i][j].nr) { /* check if we're adding: */ if (ab[i][j].oname==NULL && ab[i][j].tp > 0) { - bFoundAll = TRUE; - for(m=0; (m= 0) { - copy_rvec(ab[ii][jj].newx, xa[m]); - } else { - bFoundAll = FALSE; - if (bCheckMissing) { - gmx_fatal(FARGS,"Atom %s not found in residue %s %d" - ", rtp entry %s" - " while adding hydrogens", - ab[i][j].a[m], - *pdba->resinfo[rnr].name, - pdba->resinfo[rnr].nr, - *pdba->resinfo[rnr].rtp); - } - } - } else + if (ia < 0) { + /* not found in original atoms, might still be in t_hack (ab) */ + hacksearch_atom(&ii, &jj, ab[i][j].a[m], nab, ab, rnr, pdba); + if (ii >= 0) { + copy_rvec(ab[ii][jj].newx, xa[m]); + } else { + bFoundAll = FALSE; + if (bCheckMissing) { + gmx_fatal(FARGS,"Atom %s not found in residue %s %d" + ", rtp entry %s" + " while adding hydrogens", + ab[i][j].a[m], + *pdba->resinfo[rnr].name, + pdba->resinfo[rnr].nr, + *pdba->resinfo[rnr].rtp); + } + } + } else { copy_rvec(x[ia], xa[m]); + } } if (bFoundAll) { for(m=0; (mbInit ) { - if (debug) fprintf(debug,"protonate: Initializing protdata\n"); + if (debug) { + fprintf(debug,"protonate: Initializing protdata\n"); + } + /* set forcefield to use: */ - strcpy(protdata->FF,"ffgmx2"); + strcpy(protdata->FF,"gmx2.ff"); + /* get the databases: */ protdata->nah = read_h_db(protdata->FF,&protdata->ah); open_symtab(&protdata->tab); protdata->atype = read_atype(protdata->FF,&protdata->tab); nntdb = read_ter_db(protdata->FF,'n',&protdata->ntdb,protdata->atype); - if (nntdb < 1) - gmx_fatal(FARGS,"no n-terminus db"); + if (nntdb < 1) { + gmx_fatal(FARGS,"no N-terminus database"); + } nctdb = read_ter_db(protdata->FF,'c',&protdata->ctdb,protdata->atype); - if (nctdb < 1) - gmx_fatal(FARGS,"no c-terminus db"); + if (nctdb < 1) { + gmx_fatal(FARGS,"no C-terminus database"); + } /* set terminus types: -NH3+ (different for Proline) and -COO- */ atoms=*atomsptr; @@ -656,15 +673,16 @@ snew(protdata->sel_ctdb, NTERPAIRS); if (nntdb>=4 && nctdb>=2) { - /* Yuk, yuk, hardcoded default termini selections !!! */ - if (strncmp(*atoms->resinfo[atoms->atom[atoms->nr-1].resind].name,"PRO",3)==0) - nt = 3; - else - nt = 1; - ct = 1; + /* Yuk, yuk, hardcoded default termini selections !!! */ + if (strncmp(*atoms->resinfo[atoms->atom[atoms->nr-1].resind].name,"PRO",3)==0) { + nt = 3; + } else { + nt = 1; + } + ct = 1; } else { - nt = 0; - ct = 0; + nt = 0; + ct = 0; } protdata->sel_ntdb[0]=&(protdata->ntdb[nt]); protdata->sel_ctdb[0]=&(protdata->ctdb[ct]); @@ -689,8 +707,10 @@ /* set flag to show we're initialized: */ protdata->bInit=TRUE; } else { - if (debug) fprintf(debug,"protonate: using available protdata\n"); - /* add_h will need the unprotonated topoloy again: */ + if (debug) { + fprintf(debug,"protonate: using available protdata\n"); + } + /* add_h will need the unprotonated topology again: */ atoms = protdata->upatoms; bUpdate_pdba=FALSE; bKeep_old_pdba=FALSE; @@ -701,12 +721,15 @@ NTERPAIRS, protdata->sel_ntdb, protdata->sel_ctdb, protdata->rN, protdata->rC, TRUE, &protdata->nab, &protdata->ab, bUpdate_pdba, bKeep_old_pdba); - if ( ! protdata->patoms ) + if ( ! protdata->patoms ) { /* store protonated topology */ protdata->patoms = atoms; + } *atomsptr = protdata->patoms; - if (debug) fprintf(debug,"natoms: %d -> %d (nadd=%d)\n", - protdata->upatoms->nr, protdata->patoms->nr, nadd); + if (debug) { + fprintf(debug,"natoms: %d -> %d (nadd=%d)\n", + protdata->upatoms->nr, protdata->patoms->nr, nadd); + } return nadd; #undef NTERPAIRS } diff -Nru gromacs-4.5.4/src/kernel/genhydro.h gromacs-4.5.5/src/kernel/genhydro.h --- gromacs-4.5.4/src/kernel/genhydro.h 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/genhydro.h 2011-09-21 12:34:32.000000000 +0000 @@ -51,7 +51,7 @@ * ntdb[i] and ctdb[i] may be NULL, no replacement will be done then. * rN[i] is the residue number of the N-terminus of chain i, * rC[i] is the residue number of the C-terminus of chain i - * if bMissing==TRUE, conitue when atoms are not found + * if bMissing==TRUE, continue when atoms are not found * if nabptr && abptrb, the hack array will be returned in them to be used * a second time * if bUpdate_pdba, hydrogens are added to *pdbaptr, else it is unchanged @@ -59,10 +59,10 @@ */ extern int protonate(t_atoms **atoms, rvec **x, t_protonate *protdata); -/* Protonate molecule according to ffgmx2 +/* Protonate molecule according to gmx2.ff/aminoacids.hdb * when called the first time, new atoms are added to atoms, * second time only coordinates are generated - * return the New total number of atoms + * return the new total number of atoms */ extern void deprotonate(t_atoms *atoms,rvec *x); diff -Nru gromacs-4.5.4/src/kernel/gmxdump.c gromacs-4.5.5/src/kernel/gmxdump.c --- gromacs-4.5.4/src/kernel/gmxdump.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/gmxdump.c 2011-09-21 12:34:32.000000000 +0000 @@ -466,7 +466,7 @@ "This program is essential for checking your run input file in case of", "problems.[PAR]", "The program can also preprocess a topology to help finding problems.", - "Note that currently setting GMXLIB is the only way to customize", + "Note that currently setting [TT]GMXLIB[tt] is the only way to customize", "directories used for searching include files.", }; t_filenm fnm[] = { diff -Nru gromacs-4.5.4/src/kernel/g_protonate.c gromacs-4.5.5/src/kernel/g_protonate.c --- gromacs-4.5.4/src/kernel/g_protonate.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/g_protonate.c 2011-09-21 12:34:32.000000000 +0000 @@ -37,6 +37,7 @@ #endif #include +#include "string2.h" #include "typedefs.h" #include "macros.h" #include "copyrite.h" @@ -55,7 +56,7 @@ "[TT]g_protonate[tt] reads (a) conformation(s) and adds all missing", "hydrogens as defined in [TT]gmx2.ff/aminoacids.hdb[tt]. If only [TT]-s[tt] is", "specified, this conformation will be protonated, if also [TT]-f[tt]", - "is specified, the conformation(s) will be read from this file", + "is specified, the conformation(s) will be read from this file, ", "which can be either a single conformation or a trajectory.", "[PAR]", "If a [TT].pdb[tt] file is supplied, residue names might not correspond to", @@ -65,7 +66,7 @@ "If an index file is specified, please note that the atom numbers", "should correspond to the [BB]protonated[bb] state." }; - + char title[STRLEN+1]; const char *infile; char *grpnm; @@ -84,6 +85,10 @@ gmx_bool bReadMultiple; output_env_t oenv; + const char *bugs[] = { + "For the moment, only .pdb files are accepted to the -s flag" + }; + t_filenm fnm[] = { { efTPS, NULL, NULL, ffREAD }, { efTRX, "-f", NULL, ffOPTRD }, @@ -94,7 +99,7 @@ CopyRight(stderr,argv[0]); parse_common_args(&argc,argv,PCA_CAN_TIME, - NFILE,fnm,0,NULL,asize(desc),desc,0,NULL,&oenv); + NFILE,fnm,0,NULL,asize(desc),desc,asize(bugs),bugs,&oenv); infile=opt2fn("-s",NFILE,fnm); read_tps_conf(infile,title,&top,&ePBC,&x,NULL,box,FALSE); @@ -104,8 +109,9 @@ bReadMultiple = opt2bSet("-f",NFILE,fnm); if (bReadMultiple) { infile = opt2fn("-f",NFILE,fnm); - if ( !read_first_frame(oenv,&status, infile, &fr, TRX_NEED_X ) ) + if ( !read_first_frame(oenv,&status, infile, &fr, TRX_NEED_X ) ) { gmx_fatal(FARGS,"cannot read coordinate file %s",infile); + } natoms = fr.natoms; } else { clear_trxframe(&fr,TRUE); @@ -120,16 +126,22 @@ } /* check input */ - if ( natoms == 0 ) + if ( natoms == 0 ) { gmx_fatal(FARGS,"no atoms in coordinate file %s",infile); - if ( natoms > atoms->nr ) + } + + if ( natoms > atoms->nr ) { gmx_fatal(FARGS,"topology with %d atoms does not match " "coordinates with %d atoms",atoms->nr,natoms); - for(i=0; i natoms) + } + + for(i=0; i natoms) { gmx_fatal(FARGS,"An atom number in group %s is larger than the number of " "atoms (%d) in the coordinate file %s",grpnm,natoms,infile); - + } + } + /* get indexed copy of atoms */ snew(iatoms,1); init_t_atoms(iatoms,nidx,FALSE); @@ -138,10 +150,15 @@ for(i=0; iatom[i] = atoms->atom[index[i]]; iatoms->atomname[i] = atoms->atomname[index[i]]; - if ( i>0 && (atoms->atom[index[i]].resind!=atoms->atom[index[i-1]].resind) ) + if ( i>0 && (atoms->atom[index[i]].resind!=atoms->atom[index[i-1]].resind) ) { resind++; + } iatoms->atom[i].resind = resind; iatoms->resinfo[resind] = atoms->resinfo[atoms->atom[index[i]].resind]; + /* allocate some space for the rtp name and copy from name */ + snew(iatoms->resinfo[resind].rtp,1); + *iatoms->resinfo[resind].rtp = gmx_strdup(*atoms->resinfo[resind].name); + iatoms->nres = max(iatoms->nres, iatoms->atom[i].resind+1); } @@ -151,10 +168,13 @@ snew(ix, nidx); frame=0; do { - if (debug) fprintf(debug,"FRAME %d (%d %g)\n",frame,fr.step,fr.time); + if (debug) { + fprintf(debug,"FRAME %d (%d %g)\n",frame,fr.step,fr.time); + } /* get indexed copy of x */ - for(i=0; i[BR]", + "#include [PAR]", "The functioning of these statements in your topology may be modulated by", - "using the following two flags in your [TT]mdp[tt] file:[BR]", - "define = -DVARIABLE1 -DVARIABLE2[BR]", - "include = -I/home/john/doe[BR]", + "using the following two flags in your [TT].mdp[tt] file:[PAR]", + "[TT]define = -DVARIABLE1 -DVARIABLE2[BR]", + "include = -I/home/john/doe[tt][BR]", "For further information a C-programming textbook may help you out.", "Specifying the [TT]-pp[tt] flag will get the pre-processed", "topology file written out so that you can verify its contents.[PAR]", - - "If your system does not have a c-preprocessor, you can still", - "use [TT]grompp[tt], but you do not have access to the features ", - "from the cpp. Command line options to the c-preprocessor can be given", - "in the [TT].mdp[tt] file. See your local manual (man cpp).[PAR]", + + /* cpp has been unnecessary for some time, hasn't it? + "If your system does not have a C-preprocessor, you can still", + "use [TT]grompp[tt], but you do not have access to the features ", + "from the cpp. Command line options to the C-preprocessor can be given", + "in the [TT].mdp[tt] file. See your local manual (man cpp).[PAR]", + */ "When using position restraints a file with restraint coordinates", "can be supplied with [TT]-r[tt], otherwise restraining will be done", @@ -1191,8 +1193,8 @@ "[TT]-e[tt] to read Nose-Hoover and/or Parrinello-Rahman coupling", "variables.[PAR]", - "[TT]grompp[tt] can be used to restart simulations preserving", - "continuity by supplying just a checkpoint file with [TT]-t[tt].", + "[TT]grompp[tt] can be used to restart simulations (preserving", + "continuity) by supplying just a checkpoint file with [TT]-t[tt].", "However, for simply changing the number of run steps to extend", "a run, using [TT]tpbconv[tt] is more convenient than [TT]grompp[tt].", "You then supply the old checkpoint file directly to [TT]mdrun[tt]", @@ -1209,10 +1211,10 @@ "of virtual site constructions will be removed. If any constraints remain", "which involve virtual sites, a fatal error will result.[PAR]" - "To verify your run input file, please make notice of all warnings", + "To verify your run input file, please take note of all warnings", "on the screen, and correct where necessary. Do also look at the contents", - "of the [TT]mdout.mdp[tt] file, this contains comment lines, as well as", - "the input that [TT]grompp[tt] has read. If in doubt you can start grompp", + "of the [TT]mdout.mdp[tt] file; this contains comment lines, as well as", + "the input that [TT]grompp[tt] has read. If in doubt, you can start [TT]grompp[tt]", "with the [TT]-debug[tt] option which will give you more information", "in a file called [TT]grompp.log[tt] (along with real debug info). You", "can see the contents of the run input file with the [TT]gmxdump[tt]", diff -Nru gromacs-4.5.4/src/kernel/g_x2top.c gromacs-4.5.5/src/kernel/g_x2top.c --- gromacs-4.5.4/src/kernel/g_x2top.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/g_x2top.c 2011-09-21 12:34:32.000000000 +0000 @@ -379,17 +379,17 @@ "G53a5 GROMOS96 53a5 Forcefield (official distribution)[PAR]", "oplsaa OPLS-AA/L all-atom force field (2001 aminoacid dihedrals)[PAR]", "The corresponding data files can be found in the library directory", - "with name atomname2type.n2t. Check chapter 5 of the manual for more", - "information about file formats. By default the forcefield selection", + "with name [TT]atomname2type.n2t[tt]. Check Chapter 5 of the manual for more", + "information about file formats. By default, the force field selection", "is interactive, but you can use the [TT]-ff[tt] option to specify", "one of the short names above on the command line instead. In that", - "case [TT]pdb2gmx[tt] just looks for the corresponding file.[PAR]", + "case [TT]g_x2top[tt] just looks for the corresponding file.[PAR]", }; const char *bugs[] = { "The atom type selection is primitive. Virtually no chemical knowledge is used", "Periodic boundary conditions screw up the bonding", "No improper dihedrals are generated", - "The atoms to atomtype translation table is incomplete (atomname2type.n2t files in the data directory). Please extend it and send the results back to the GROMACS crew." + "The atoms to atomtype translation table is incomplete ([TT]atomname2type.n2t[tt] file in the data directory). Please extend it and send the results back to the GROMACS crew." }; FILE *fp; t_params plist[F_NRE]; diff -Nru gromacs-4.5.4/src/kernel/h_db.c gromacs-4.5.5/src/kernel/h_db.c --- gromacs-4.5.4/src/kernel/h_db.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/h_db.c 2011-09-21 12:34:32.000000000 +0000 @@ -183,8 +183,10 @@ /* Sort the list (necessary to be able to use bsearch */ qsort(aah,nah,(size_t)sizeof(**ah),compaddh); + /* if (debug) dump_h_db(hfn,nah,aah); + */ *nahptr = nah; *ah = aah; diff -Nru gromacs-4.5.4/src/kernel/hizzie.c gromacs-4.5.5/src/kernel/hizzie.c --- gromacs-4.5.4/src/kernel/hizzie.c 2011-03-15 12:44:33.000000000 +0000 +++ gromacs-4.5.5/src/kernel/hizzie.c 2011-09-21 12:34:32.000000000 +0000 @@ -189,30 +189,48 @@ gmx_bool bHDd,bHEd; rvec xh1,xh2; int natom; - int i,nd,na,aj,hisind,his0,type=-1; + int i,j,nd,na,aj,hisind,his0,type=-1; int nd1,ne2,cg,cd2,ce1; t_blocka *hb; real d; char *atomnm; natom=pdba->nr; + + i = 0; + while (i < natom && + gmx_strcasecmp(*pdba->resinfo[pdba->atom[i].resind].name,"HIS") != 0) + { + i++; + } + if (natom == i) + { + return; + } + + /* A histidine residue exists that requires automated assignment, so + * doing the analysis of donors and acceptors is worthwhile. */ + fprintf(stderr, + "Analysing hydrogen-bonding network for automated assigment of histidine\n" + " protonation."); + snew(donor,natom); snew(acceptor,natom); snew(hbond,natom); snew(hb,1); nd=na=0; - for(i=0; (iatomname[i],NPA,prot_acc) != -1) { - acceptor[i] = TRUE; + for(j=0; (jatomname[j],NPA,prot_acc) != -1) { + acceptor[j] = TRUE; na++; } - if (in_strings(*pdba->atomname[i],NPD,prot_don) != -1) { - donor[i] = TRUE; + if (in_strings(*pdba->atomname[j],NPD,prot_don) != -1) { + donor[j] = TRUE; nd++; } } - fprintf(stderr,"There are %d donors and %d acceptors\n",nd,na); + fprintf(stderr," %d donors and %d acceptors were found.\n",nd,na); chk_allhb(pdba,x,hb,donor,acceptor,dist); if (debug) pr_hbonds(debug,hb,pdba); @@ -220,10 +238,14 @@ /* Now do the HIS stuff */ hisind=-1; - for(i=0; (iresinfo[pdba->atom[i].resind].name,"HIS") != 0) + { i++; - else { + } + else + { if (pdba->atom[i].resind != hisind) { hisind=pdba->atom[i].resind; diff -Nru gromacs-4.5.4/src/kernel/md.c gromacs-4.5.5/src/kernel/md.c --- gromacs-4.5.4/src/kernel/md.c 2011-03-21 08:35:27.000000000 +0000 +++ gromacs-4.5.5/src/kernel/md.c 2011-09-21 12:34:32.000000000 +0000 @@ -37,9 +37,6 @@ #include #endif -#include -#include - #if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) /* _isnan() */ #include @@ -103,1009 +100,6 @@ #endif -/* simulation conditions to transmit. Keep in mind that they are - transmitted to other nodes through an MPI_Reduce after - casting them to a real (so the signals can be sent together with other - data). This means that the only meaningful values are positive, - negative or zero. */ -enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; -/* Is the signal in one simulation independent of other simulations? */ -gmx_bool gs_simlocal[eglsNR] = { TRUE, FALSE, FALSE, TRUE }; - -typedef struct { - int nstms; /* The frequency for intersimulation communication */ - int sig[eglsNR]; /* The signal set by one process in do_md */ - int set[eglsNR]; /* The communicated signal, equal for all processes */ -} globsig_t; - - - -/* check which of the multisim simulations has the shortest number of - steps and return that number of nsteps */ -static gmx_large_int_t get_multisim_nsteps(const t_commrec *cr, - gmx_large_int_t nsteps) -{ - gmx_large_int_t steps_out; - - if MASTER(cr) - { - gmx_large_int_t *buf; - int s; - - snew(buf,cr->ms->nsim); - - buf[cr->ms->sim] = nsteps; - gmx_sumli_sim(cr->ms->nsim, buf, cr->ms); - - steps_out=-1; - for(s=0; sms->nsim; s++) - { - /* find the smallest positive number */ - if (buf[s]>= 0 && ((steps_out < 0) || (buf[s]=0 && steps_outms->sim, steps_out); - } - } - /* broadcast to non-masters */ - gmx_bcast(sizeof(gmx_large_int_t), &steps_out, cr); - return steps_out; -} - -static int multisim_min(const gmx_multisim_t *ms,int nmin,int n) -{ - int *buf; - gmx_bool bPos,bEqual; - int s,d; - - snew(buf,ms->nsim); - buf[ms->sim] = n; - gmx_sumi_sim(ms->nsim,buf,ms); - bPos = TRUE; - bEqual = TRUE; - for(s=0; snsim; s++) - { - bPos = bPos && (buf[s] > 0); - bEqual = bEqual && (buf[s] == buf[0]); - } - if (bPos) - { - if (bEqual) - { - nmin = min(nmin,buf[0]); - } - else - { - /* Find the least common multiple */ - for(d=2; dnsim && d % buf[s] == 0) - { - s++; - } - if (s == ms->nsim) - { - /* We found the LCM and it is less than nmin */ - nmin = d; - break; - } - } - } - } - sfree(buf); - - return nmin; -} - -static int multisim_nstsimsync(const t_commrec *cr, - const t_inputrec *ir,int repl_ex_nst) -{ - int nmin; - - if (MASTER(cr)) - { - nmin = INT_MAX; - nmin = multisim_min(cr->ms,nmin,ir->nstlist); - nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); - nmin = multisim_min(cr->ms,nmin,repl_ex_nst); - if (nmin == INT_MAX) - { - gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); - } - /* Avoid inter-simulation communication at every (second) step */ - if (nmin <= 2) - { - nmin = 10; - } - } - - gmx_bcast(sizeof(int),&nmin,cr); - - return nmin; -} - -static void init_global_signals(globsig_t *gs,const t_commrec *cr, - const t_inputrec *ir,int repl_ex_nst) -{ - int i; - - if (MULTISIM(cr)) - { - gs->nstms = multisim_nstsimsync(cr,ir,repl_ex_nst); - if (debug) - { - fprintf(debug,"Syncing simulations for checkpointing and termination every %d steps\n",gs->nstms); - } - } - else - { - gs->nstms = 1; - } - - for(i=0; isig[i] = 0; - gs->set[i] = 0; - } -} - -static void copy_coupling_state(t_state *statea,t_state *stateb, - gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts) -{ - - /* MRS note -- might be able to get rid of some of the arguments. Look over it when it's all debugged */ - - int i,j,nc; - - /* Make sure we have enough space for x and v */ - if (statea->nalloc > stateb->nalloc) - { - stateb->nalloc = statea->nalloc; - srenew(stateb->x,stateb->nalloc); - srenew(stateb->v,stateb->nalloc); - } - - stateb->natoms = statea->natoms; - stateb->ngtc = statea->ngtc; - stateb->nnhpres = statea->nnhpres; - stateb->veta = statea->veta; - if (ekinda) - { - copy_mat(ekinda->ekin,ekindb->ekin); - for (i=0; ingtc; i++) - { - ekindb->tcstat[i].T = ekinda->tcstat[i].T; - ekindb->tcstat[i].Th = ekinda->tcstat[i].Th; - copy_mat(ekinda->tcstat[i].ekinh,ekindb->tcstat[i].ekinh); - copy_mat(ekinda->tcstat[i].ekinf,ekindb->tcstat[i].ekinf); - ekindb->tcstat[i].ekinscalef_nhc = ekinda->tcstat[i].ekinscalef_nhc; - ekindb->tcstat[i].ekinscaleh_nhc = ekinda->tcstat[i].ekinscaleh_nhc; - ekindb->tcstat[i].vscale_nhc = ekinda->tcstat[i].vscale_nhc; - } - } - copy_rvecn(statea->x,stateb->x,0,stateb->natoms); - copy_rvecn(statea->v,stateb->v,0,stateb->natoms); - copy_mat(statea->box,stateb->box); - copy_mat(statea->box_rel,stateb->box_rel); - copy_mat(statea->boxv,stateb->boxv); - - for (i = 0; ingtc; i++) - { - nc = i*opts->nhchainlength; - for (j=0; jnhchainlength; j++) - { - stateb->nosehoover_xi[nc+j] = statea->nosehoover_xi[nc+j]; - stateb->nosehoover_vxi[nc+j] = statea->nosehoover_vxi[nc+j]; - } - } - if (stateb->nhpres_xi != NULL) - { - for (i = 0; innhpres; i++) - { - nc = i*opts->nhchainlength; - for (j=0; jnhchainlength; j++) - { - stateb->nhpres_xi[nc+j] = statea->nhpres_xi[nc+j]; - stateb->nhpres_vxi[nc+j] = statea->nhpres_vxi[nc+j]; - } - } - } -} - -static real compute_conserved_from_auxiliary(t_inputrec *ir, t_state *state, t_extmass *MassQ) -{ - real quantity = 0; - switch (ir->etc) - { - case etcNO: - break; - case etcBERENDSEN: - break; - case etcNOSEHOOVER: - quantity = NPT_energy(ir,state,MassQ); - break; - case etcVRESCALE: - quantity = vrescale_energy(&(ir->opts),state->therm_integral); - break; - default: - break; - } - return quantity; -} - -static void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, - t_forcerec *fr, gmx_ekindata_t *ekind, - t_state *state, t_state *state_global, t_mdatoms *mdatoms, - t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, - gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, - tensor pres, rvec mu_tot, gmx_constr_t constr, - globsig_t *gs,gmx_bool bInterSimGS, - matrix box, gmx_mtop_t *top_global, real *pcurr, - int natoms, gmx_bool *bSumEkinhOld, int flags) -{ - int i,gsi; - real gs_buf[eglsNR]; - tensor corr_vir,corr_pres,shakeall_vir; - gmx_bool bEner,bPres,bTemp, bVV; - gmx_bool bRerunMD, bStopCM, bGStat, bIterate, - bFirstIterate,bReadEkin,bEkinAveVel,bScaleEkin, bConstrain; - real ekin,temp,prescorr,enercorr,dvdlcorr; - - /* translate CGLO flags to gmx_booleans */ - bRerunMD = flags & CGLO_RERUNMD; - bStopCM = flags & CGLO_STOPCM; - bGStat = flags & CGLO_GSTAT; - - bReadEkin = (flags & CGLO_READEKIN); - bScaleEkin = (flags & CGLO_SCALEEKIN); - bEner = flags & CGLO_ENERGY; - bTemp = flags & CGLO_TEMPERATURE; - bPres = (flags & CGLO_PRESSURE); - bConstrain = (flags & CGLO_CONSTRAINT); - bIterate = (flags & CGLO_ITERATE); - bFirstIterate = (flags & CGLO_FIRSTITERATE); - - /* we calculate a full state kinetic energy either with full-step velocity verlet - or half step where we need the pressure */ - - bEkinAveVel = (ir->eI==eiVV || (ir->eI==eiVVAK && bPres) || bReadEkin); - - /* in initalization, it sums the shake virial in vv, and to - sums ekinh_old in leapfrog (or if we are calculating ekinh_old) for other reasons */ - - /* ########## Kinetic energy ############## */ - - if (bTemp) - { - /* Non-equilibrium MD: this is parallellized, but only does communication - * when there really is NEMD. - */ - - if (PAR(cr) && (ekind->bNEMD)) - { - accumulate_u(cr,&(ir->opts),ekind); - } - debug_gmx(); - if (bReadEkin) - { - restore_ekinstate_from_state(cr,ekind,&state_global->ekinstate); - } - else - { - - calc_ke_part(state,&(ir->opts),mdatoms,ekind,nrnb,bEkinAveVel,bIterate); - } - - debug_gmx(); - - /* Calculate center of mass velocity if necessary, also parallellized */ - if (bStopCM && !bRerunMD && bEner) - { - calc_vcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms, - state->x,state->v,vcm); - } - } - - if (bTemp || bPres || bEner || bConstrain) - { - if (!bGStat) - { - /* We will not sum ekinh_old, - * so signal that we still have to do it. - */ - *bSumEkinhOld = TRUE; - - } - else - { - if (gs != NULL) - { - for(i=0; isig[i]; - } - } - if (PAR(cr)) - { - wallcycle_start(wcycle,ewcMoveE); - GMX_MPE_LOG(ev_global_stat_start); - global_stat(fplog,gstat,cr,enerd,force_vir,shake_vir,mu_tot, - ir,ekind,constr,vcm, - gs != NULL ? eglsNR : 0,gs_buf, - top_global,state, - *bSumEkinhOld,flags); - GMX_MPE_LOG(ev_global_stat_finish); - wallcycle_stop(wcycle,ewcMoveE); - } - if (gs != NULL) - { - if (MULTISIM(cr) && bInterSimGS) - { - if (MASTER(cr)) - { - /* Communicate the signals between the simulations */ - gmx_sum_sim(eglsNR,gs_buf,cr->ms); - } - /* Communicate the signals form the master to the others */ - gmx_bcast(eglsNR*sizeof(gs_buf[0]),gs_buf,cr); - } - for(i=0; i= 0 ? - (int)(gs_buf[i] + 0.5) : - (int)(gs_buf[i] - 0.5)); - if (gsi != 0) - { - gs->set[i] = gsi; - } - /* Turn off the local signal */ - gs->sig[i] = 0; - } - } - } - *bSumEkinhOld = FALSE; - } - } - - if (!ekind->bNEMD && debug && bTemp && (vcm->nr > 0)) - { - correct_ekin(debug, - mdatoms->start,mdatoms->start+mdatoms->homenr, - state->v,vcm->group_p[0], - mdatoms->massT,mdatoms->tmass,ekind->ekin); - } - - if (bEner) { - /* Do center of mass motion removal */ - if (bStopCM && !bRerunMD) /* is this correct? Does it get called too often with this logic? */ - { - check_cm_grp(fplog,vcm,ir,1); - do_stopcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms->cVCM, - state->x,state->v,vcm); - inc_nrnb(nrnb,eNR_STOPCM,mdatoms->homenr); - } - - /* Calculate the amplitude of the cosine velocity profile */ - ekind->cosacc.vcos = ekind->cosacc.mvcos/mdatoms->tmass; - } - - if (bTemp) - { - /* Sum the kinetic energies of the groups & calc temp */ - /* compute full step kinetic energies if vv, or if vv-avek and we are computing the pressure with IR_NPT_TROTTER */ - /* three maincase: VV with AveVel (md-vv), vv with AveEkin (md-vv-avek), leap with AveEkin (md). - Leap with AveVel is not supported; it's not clear that it will actually work. - bEkinAveVel: If TRUE, we simply multiply ekin by ekinscale to get a full step kinetic energy. - If FALSE, we average ekinh_old and ekinh*ekinscale_nhc to get an averaged half step kinetic energy. - bSaveEkinOld: If TRUE (in the case of iteration = bIterate is TRUE), we don't reset the ekinscale_nhc. - If FALSE, we go ahead and erase over it. - */ - enerd->term[F_TEMP] = sum_ekin(&(ir->opts),ekind,&(enerd->term[F_DKDL]), - bEkinAveVel,bIterate,bScaleEkin); - - enerd->term[F_EKIN] = trace(ekind->ekin); - } - - /* ########## Long range energy information ###### */ - - if (bEner || bPres || bConstrain) - { - calc_dispcorr(fplog,ir,fr,0,top_global->natoms,box,state->lambda, - corr_pres,corr_vir,&prescorr,&enercorr,&dvdlcorr); - } - - if (bEner && bFirstIterate) - { - enerd->term[F_DISPCORR] = enercorr; - enerd->term[F_EPOT] += enercorr; - enerd->term[F_DVDL] += dvdlcorr; - if (fr->efep != efepNO) { - enerd->dvdl_lin += dvdlcorr; - } - } - - /* ########## Now pressure ############## */ - if (bPres || bConstrain) - { - - m_add(force_vir,shake_vir,total_vir); - - /* Calculate pressure and apply LR correction if PPPM is used. - * Use the box from last timestep since we already called update(). - */ - - enerd->term[F_PRES] = calc_pres(fr->ePBC,ir->nwall,box,ekind->ekin,total_vir,pres, - (fr->eeltype==eelPPPM)?enerd->term[F_COUL_RECIP]:0.0); - - /* Calculate long range corrections to pressure and energy */ - /* this adds to enerd->term[F_PRES] and enerd->term[F_ETOT], - and computes enerd->term[F_DISPCORR]. Also modifies the - total_vir and pres tesors */ - - m_add(total_vir,corr_vir,total_vir); - m_add(pres,corr_pres,pres); - enerd->term[F_PDISPCORR] = prescorr; - enerd->term[F_PRES] += prescorr; - *pcurr = enerd->term[F_PRES]; - /* calculate temperature using virial */ - enerd->term[F_VTEMP] = calc_temp(trace(total_vir),ir->opts.nrdf[0]); - - } -} - - -/* Definitions for convergence of iterated constraints */ - -/* iterate constraints up to 50 times */ -#define MAXITERCONST 50 - -/* data type */ -typedef struct -{ - real f,fprev,x,xprev; - int iter_i; - gmx_bool bIterate; - real allrelerr[MAXITERCONST+2]; - int num_close; /* number of "close" violations, caused by limited precision. */ -} gmx_iterate_t; - -#ifdef GMX_DOUBLE -#define CONVERGEITER 0.000000001 -#define CLOSE_ENOUGH 0.000001000 -#else -#define CONVERGEITER 0.0001 -#define CLOSE_ENOUGH 0.0050 -#endif - -/* we want to keep track of the close calls. If there are too many, there might be some other issues. - so we make sure that it's either less than some predetermined number, or if more than that number, - only some small fraction of the total. */ -#define MAX_NUMBER_CLOSE 50 -#define FRACTION_CLOSE 0.001 - -/* maximum length of cyclic traps to check, emerging from limited numerical precision */ -#define CYCLEMAX 20 - -static void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate) -{ - int i; - - iterate->iter_i = 0; - iterate->bIterate = bIterate; - iterate->num_close = 0; - for (i=0;iallrelerr[i] = 0; - } -} - -static gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf) -{ - /* monitor convergence, and use a secant search to propose new - values. - x_{i} - x_{i-1} - The secant method computes x_{i+1} = x_{i} - f(x_{i}) * --------------------- - f(x_{i}) - f(x_{i-1}) - - The function we are trying to zero is fom-x, where fom is the - "figure of merit" which is the pressure (or the veta value) we - would get by putting in an old value of the pressure or veta into - the incrementor function for the step or half step. I have - verified that this gives the same answer as self consistent - iteration, usually in many fewer steps, especially for small tau_p. - - We could possibly eliminate an iteration with proper use - of the value from the previous step, but that would take a bit - more bookkeeping, especially for veta, since tests indicate the - function of veta on the last step is not sufficiently close to - guarantee convergence this step. This is - good enough for now. On my tests, I could use tau_p down to - 0.02, which is smaller that would ever be necessary in - practice. Generally, 3-5 iterations will be sufficient */ - - real relerr,err,xmin; - char buf[256]; - int i; - gmx_bool incycle; - - if (bFirstIterate) - { - iterate->x = fom; - iterate->f = fom-iterate->x; - iterate->xprev = 0; - iterate->fprev = 0; - *newf = fom; - } - else - { - iterate->f = fom-iterate->x; /* we want to zero this difference */ - if ((iterate->iter_i > 1) && (iterate->iter_i < MAXITERCONST)) - { - if (iterate->f==iterate->fprev) - { - *newf = iterate->f; - } - else - { - *newf = iterate->x - (iterate->x-iterate->xprev)*(iterate->f)/(iterate->f-iterate->fprev); - } - } - else - { - /* just use self-consistent iteration the first step to initialize, or - if it's not converging (which happens occasionally -- need to investigate why) */ - *newf = fom; - } - } - /* Consider a slight shortcut allowing us to exit one sooner -- we check the - difference between the closest of x and xprev to the new - value. To be 100% certain, we should check the difference between - the last result, and the previous result, or - - relerr = (fabs((x-xprev)/fom)); - - but this is pretty much never necessary under typical conditions. - Checking numerically, it seems to lead to almost exactly the same - trajectories, but there are small differences out a few decimal - places in the pressure, and eventually in the v_eta, but it could - save an interation. - - if (fabs(*newf-x) < fabs(*newf - xprev)) { xmin = x;} else { xmin = xprev;} - relerr = (fabs((*newf-xmin) / *newf)); - */ - - err = fabs((iterate->f-iterate->fprev)); - relerr = fabs(err/fom); - - iterate->allrelerr[iterate->iter_i] = relerr; - - if (iterate->iter_i > 0) - { - if (debug) - { - fprintf(debug,"Iterating NPT constraints: %6i %20.12f%14.6g%20.12f\n", - iterate->iter_i,fom,relerr,*newf); - } - - if ((relerr < CONVERGEITER) || (err < CONVERGEITER) || (fom==0) || ((iterate->x == iterate->xprev) && iterate->iter_i > 1)) - { - iterate->bIterate = FALSE; - if (debug) - { - fprintf(debug,"Iterating NPT constraints: CONVERGED\n"); - } - return TRUE; - } - if (iterate->iter_i > MAXITERCONST) - { - if (relerr < CLOSE_ENOUGH) - { - incycle = FALSE; - for (i=1;iallrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-1]) && - (iterate->allrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-(1+2*i)])) { - incycle = TRUE; - if (debug) - { - fprintf(debug,"Exiting from an NPT iterating cycle of length %d\n",i); - } - break; - } - } - - if (incycle) { - /* step 1: trapped in a numerical attractor */ - /* we are trapped in a numerical attractor, and can't converge any more, and are close to the final result. - Better to give up convergence here than have the simulation die. - */ - iterate->num_close++; - return TRUE; - } - else - { - /* Step #2: test if we are reasonably close for other reasons, then monitor the number. If not, die */ - - /* how many close calls have we had? If less than a few, we're OK */ - if (iterate->num_close < MAX_NUMBER_CLOSE) - { - sprintf(buf,"Slight numerical convergence deviation with NPT at step %d, relative error only %10.5g, likely not a problem, continuing\n",nsteps,relerr); - md_print_warning(cr,fplog,buf); - iterate->num_close++; - return TRUE; - /* if more than a few, check the total fraction. If too high, die. */ - } else if (iterate->num_close/(double)nsteps > FRACTION_CLOSE) { - gmx_fatal(FARGS,"Could not converge NPT constraints, too many exceptions (%d%%\n",iterate->num_close/(double)nsteps); - } - } - } - else - { - gmx_fatal(FARGS,"Could not converge NPT constraints\n"); - } - } - } - - iterate->xprev = iterate->x; - iterate->x = *newf; - iterate->fprev = iterate->f; - iterate->iter_i++; - - return FALSE; -} - -static void check_nst_param(FILE *fplog,t_commrec *cr, - const char *desc_nst,int nst, - const char *desc_p,int *p) -{ - char buf[STRLEN]; - - if (*p > 0 && *p % nst != 0) - { - /* Round up to the next multiple of nst */ - *p = ((*p)/nst + 1)*nst; - sprintf(buf,"NOTE: %s changes %s to %d\n",desc_nst,desc_p,*p); - md_print_warning(cr,fplog,buf); - } -} - -static void reset_all_counters(FILE *fplog,t_commrec *cr, - gmx_large_int_t step, - gmx_large_int_t *step_rel,t_inputrec *ir, - gmx_wallcycle_t wcycle,t_nrnb *nrnb, - gmx_runtime_t *runtime) -{ - char buf[STRLEN],sbuf[STEPSTRSIZE]; - - /* Reset all the counters related to performance over the run */ - sprintf(buf,"Step %s: resetting all time and cycle counters\n", - gmx_step_str(step,sbuf)); - md_print_warning(cr,fplog,buf); - - wallcycle_stop(wcycle,ewcRUN); - wallcycle_reset_all(wcycle); - if (DOMAINDECOMP(cr)) - { - reset_dd_statistics_counters(cr->dd); - } - init_nrnb(nrnb); - ir->init_step += *step_rel; - ir->nsteps -= *step_rel; - *step_rel = 0; - wallcycle_start(wcycle,ewcRUN); - runtime_start(runtime); - print_date_and_time(fplog,cr->nodeid,"Restarted time",runtime); -} - -static void min_zero(int *n,int i) -{ - if (i > 0 && (*n == 0 || i < *n)) - { - *n = i; - } -} - -static int lcd4(int i1,int i2,int i3,int i4) -{ - int nst; - - nst = 0; - min_zero(&nst,i1); - min_zero(&nst,i2); - min_zero(&nst,i3); - min_zero(&nst,i4); - if (nst == 0) - { - gmx_incons("All 4 inputs for determininig nstglobalcomm are <= 0"); - } - - while (nst > 1 && ((i1 > 0 && i1 % nst != 0) || - (i2 > 0 && i2 % nst != 0) || - (i3 > 0 && i3 % nst != 0) || - (i4 > 0 && i4 % nst != 0))) - { - nst--; - } - - return nst; -} - -static int check_nstglobalcomm(FILE *fplog,t_commrec *cr, - int nstglobalcomm,t_inputrec *ir) -{ - char buf[STRLEN]; - - if (!EI_DYNAMICS(ir->eI)) - { - nstglobalcomm = 1; - } - - if (nstglobalcomm == -1) - { - if (!(ir->nstcalcenergy > 0 || - ir->nstlist > 0 || - ir->etc != etcNO || - ir->epc != epcNO)) - { - nstglobalcomm = 10; - if (ir->nstenergy > 0 && ir->nstenergy < nstglobalcomm) - { - nstglobalcomm = ir->nstenergy; - } - } - else - { - /* Ensure that we do timely global communication for - * (possibly) each of the four following options. - */ - nstglobalcomm = lcd4(ir->nstcalcenergy, - ir->nstlist, - ir->etc != etcNO ? ir->nsttcouple : 0, - ir->epc != epcNO ? ir->nstpcouple : 0); - } - } - else - { - if (ir->nstlist > 0 && - nstglobalcomm > ir->nstlist && nstglobalcomm % ir->nstlist != 0) - { - nstglobalcomm = (nstglobalcomm / ir->nstlist)*ir->nstlist; - sprintf(buf,"WARNING: nstglobalcomm is larger than nstlist, but not a multiple, setting it to %d\n",nstglobalcomm); - md_print_warning(cr,fplog,buf); - } - if (ir->nstcalcenergy > 0) - { - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nstcalcenergy",&ir->nstcalcenergy); - } - if (ir->etc != etcNO && ir->nsttcouple > 0) - { - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nsttcouple",&ir->nsttcouple); - } - if (ir->epc != epcNO && ir->nstpcouple > 0) - { - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nstpcouple",&ir->nstpcouple); - } - - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nstenergy",&ir->nstenergy); - - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nstlog",&ir->nstlog); - } - - if (ir->comm_mode != ecmNO && ir->nstcomm < nstglobalcomm) - { - sprintf(buf,"WARNING: Changing nstcomm from %d to %d\n", - ir->nstcomm,nstglobalcomm); - md_print_warning(cr,fplog,buf); - ir->nstcomm = nstglobalcomm; - } - - return nstglobalcomm; -} - -void check_ir_old_tpx_versions(t_commrec *cr,FILE *fplog, - t_inputrec *ir,gmx_mtop_t *mtop) -{ - /* Check required for old tpx files */ - if (IR_TWINRANGE(*ir) && ir->nstlist > 1 && - ir->nstcalcenergy % ir->nstlist != 0) - { - md_print_warning(cr,fplog,"Old tpr file with twin-range settings: modifying energy calculation and/or T/P-coupling frequencies"); - - if (gmx_mtop_ftype_count(mtop,F_CONSTR) + - gmx_mtop_ftype_count(mtop,F_CONSTRNC) > 0 && - ir->eConstrAlg == econtSHAKE) - { - md_print_warning(cr,fplog,"With twin-range cut-off's and SHAKE the virial and pressure are incorrect"); - if (ir->epc != epcNO) - { - gmx_fatal(FARGS,"Can not do pressure coupling with twin-range cut-off's and SHAKE"); - } - } - check_nst_param(fplog,cr,"nstlist",ir->nstlist, - "nstcalcenergy",&ir->nstcalcenergy); - if (ir->epc != epcNO) - { - check_nst_param(fplog,cr,"nstlist",ir->nstlist, - "nstpcouple",&ir->nstpcouple); - } - check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, - "nstenergy",&ir->nstenergy); - check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, - "nstlog",&ir->nstlog); - if (ir->efep != efepNO) - { - check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, - "nstdhdl",&ir->nstdhdl); - } - } -} - -typedef struct { - gmx_bool bGStatEveryStep; - gmx_large_int_t step_ns; - gmx_large_int_t step_nscheck; - gmx_large_int_t nns; - matrix scale_tot; - int nabnsb; - double s1; - double s2; - double ab; - double lt_runav; - double lt_runav2; -} gmx_nlheur_t; - -static void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step) -{ - nlh->lt_runav = 0; - nlh->lt_runav2 = 0; - nlh->step_nscheck = step; -} - -static void init_nlistheuristics(gmx_nlheur_t *nlh, - gmx_bool bGStatEveryStep,gmx_large_int_t step) -{ - nlh->bGStatEveryStep = bGStatEveryStep; - nlh->nns = 0; - nlh->nabnsb = 0; - nlh->s1 = 0; - nlh->s2 = 0; - nlh->ab = 0; - - reset_nlistheuristics(nlh,step); -} - -static void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step) -{ - gmx_large_int_t nl_lt; - char sbuf[STEPSTRSIZE],sbuf2[STEPSTRSIZE]; - - /* Determine the neighbor list life time */ - nl_lt = step - nlh->step_ns; - if (debug) - { - fprintf(debug,"%d atoms beyond ns buffer, updating neighbor list after %s steps\n",nlh->nabnsb,gmx_step_str(nl_lt,sbuf)); - } - nlh->nns++; - nlh->s1 += nl_lt; - nlh->s2 += nl_lt*nl_lt; - nlh->ab += nlh->nabnsb; - if (nlh->lt_runav == 0) - { - nlh->lt_runav = nl_lt; - /* Initialize the fluctuation average - * such that at startup we check after 0 steps. - */ - nlh->lt_runav2 = sqr(nl_lt/2.0); - } - /* Running average with 0.9 gives an exp. history of 9.5 */ - nlh->lt_runav2 = 0.9*nlh->lt_runav2 + 0.1*sqr(nlh->lt_runav - nl_lt); - nlh->lt_runav = 0.9*nlh->lt_runav + 0.1*nl_lt; - if (nlh->bGStatEveryStep) - { - /* Always check the nlist validity */ - nlh->step_nscheck = step; - } - else - { - /* We check after: - 2*sigma - * The factor 2 is quite conservative, - * but we assume that with nstlist=-1 the user - * prefers exact integration over performance. - */ - nlh->step_nscheck = step - + (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2)) - 1; - } - if (debug) - { - fprintf(debug,"nlist life time %s run av. %4.1f sig %3.1f check %s check with -gcom %d\n", - gmx_step_str(nl_lt,sbuf),nlh->lt_runav,sqrt(nlh->lt_runav2), - gmx_step_str(nlh->step_nscheck-step+1,sbuf2), - (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2))); - } -} - -static void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step) -{ - int d; - - if (bReset) - { - reset_nlistheuristics(nlh,step); - } - else - { - update_nliststatistics(nlh,step); - } - - nlh->step_ns = step; - /* Initialize the cumulative coordinate scaling matrix */ - clear_mat(nlh->scale_tot); - for(d=0; dscale_tot[d][d] = 1.0; - } -} - -static void rerun_parallel_comm(t_commrec *cr,t_trxframe *fr, - gmx_bool *bNotLastFrame) -{ - gmx_bool bAlloc; - rvec *xp,*vp; - - bAlloc = (fr->natoms == 0); - - if (MASTER(cr) && !*bNotLastFrame) - { - fr->natoms = -1; - } - xp = fr->x; - vp = fr->v; - gmx_bcast(sizeof(*fr),fr,cr); - fr->x = xp; - fr->v = vp; - - *bNotLastFrame = (fr->natoms >= 0); - - if (*bNotLastFrame && PARTDECOMP(cr)) - { - /* x and v are the only variable size quantities stored in trr - * that are required for rerun (f is not needed). - */ - if (bAlloc) - { - snew(fr->x,fr->natoms); - snew(fr->v,fr->natoms); - } - if (fr->bX) - { - gmx_bcast(fr->natoms*sizeof(fr->x[0]),fr->x[0],cr); - } - if (fr->bV) - { - gmx_bcast(fr->natoms*sizeof(fr->v[0]),fr->v[0],cr); - } - } -} - double do_md(FILE *fplog,t_commrec *cr,int nfile,const t_filenm fnm[], const output_env_t oenv, gmx_bool bVerbose,gmx_bool bCompact, int nstglobalcomm, diff -Nru gromacs-4.5.4/src/kernel/md_openmm.c gromacs-4.5.5/src/kernel/md_openmm.c --- gromacs-4.5.4/src/kernel/md_openmm.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/md_openmm.c 2011-09-21 12:34:32.000000000 +0000 @@ -98,105 +98,6 @@ /* include even when OpenMM not used to force compilation of do_md_openmm */ #include "openmm_wrapper.h" -/* simulation conditions to transmit */ -enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; - -typedef struct -{ - int nstms; /* The frequency for intersimulation communication */ - int sig[eglsNR]; /* The signal set by one process in do_md */ - int set[eglsNR]; /* The communicated signal, equal for all processes */ -} globsig_t; - - -static int multisim_min(const gmx_multisim_t *ms,int nmin,int n) -{ - int *buf; - gmx_bool bPos,bEqual; - int s,d; - - snew(buf,ms->nsim); - buf[ms->sim] = n; - gmx_sumi_sim(ms->nsim,buf,ms); - bPos = TRUE; - bEqual = TRUE; - for (s=0; snsim; s++) - { - bPos = bPos && (buf[s] > 0); - bEqual = bEqual && (buf[s] == buf[0]); - } - if (bPos) - { - if (bEqual) - { - nmin = min(nmin,buf[0]); - } - else - { - /* Find the least common multiple */ - for (d=2; dnsim && d % buf[s] == 0) - { - s++; - } - if (s == ms->nsim) - { - /* We found the LCM and it is less than nmin */ - nmin = d; - break; - } - } - } - } - sfree(buf); - - return nmin; -} - -static int multisim_nstsimsync(const t_commrec *cr, - const t_inputrec *ir,int repl_ex_nst) -{ - int nmin; - - if (MASTER(cr)) - { - nmin = INT_MAX; - nmin = multisim_min(cr->ms,nmin,ir->nstlist); - nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); - nmin = multisim_min(cr->ms,nmin,repl_ex_nst); - if (nmin == INT_MAX) - { - gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); - } - /* Avoid inter-simulation communication at every (second) step */ - if (nmin <= 2) - { - nmin = 10; - } - } - - gmx_bcast(sizeof(int),&nmin,cr); - - return nmin; -} - -static void init_global_signals(globsig_t *gs,const t_commrec *cr, - const t_inputrec *ir,int repl_ex_nst) -{ - int i; - - gs->nstms = 1; - - for (i=0; isig[i] = 0; - gs->set[i] = 0; - } -} - - double do_md_openmm(FILE *fplog,t_commrec *cr,int nfile,const t_filenm fnm[], const output_env_t oenv, gmx_bool bVerbose,gmx_bool bCompact, int nstglobalcomm, diff -Nru gromacs-4.5.4/src/kernel/mdrun.c gromacs-4.5.5/src/kernel/mdrun.c --- gromacs-4.5.4/src/kernel/mdrun.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/mdrun.c 2011-09-21 12:34:32.000000000 +0000 @@ -189,7 +189,7 @@ "(the simulation will run correctly also when this is not the case).", "[PAR]", "This section lists all options that affect the domain decomposition.", - "[BR]", + "[PAR]", "Option [TT]-rdd[tt] can be used to set the required maximum distance", "for inter charge-group bonded interactions.", "Communication for two-body bonded interactions below the non-bonded", @@ -202,13 +202,13 @@ "By default [TT]-rdd[tt] is determined by [TT]mdrun[tt] based on", "the initial coordinates. The chosen value will be a balance", "between interaction range and communication cost.", - "[BR]", + "[PAR]", "When inter charge-group bonded interactions are beyond", "the bonded cut-off distance, [TT]mdrun[tt] terminates with an error message.", "For pair interactions and tabulated bonds", "that do not generate exclusions, this check can be turned off", "with the option [TT]-noddcheck[tt].", - "[BR]", + "[PAR]", "When constraints are present, option [TT]-rcon[tt] influences", "the cell size limit as well.", "Atoms connected by NC constraints, where NC is the LINCS order plus 1,", @@ -218,7 +218,7 @@ "By default [TT]mdrun[tt] estimates the minimum cell size required for P-LINCS", "in a conservative fashion. For high parallelization it can be useful", "to set the distance required for P-LINCS with the option [TT]-rcon[tt].", - "[BR]", + "[PAR]", "The [TT]-dds[tt] option sets the minimum allowed x, y and/or z scaling", "of the cells with dynamic load balancing. [TT]mdrun[tt] will ensure that", "the cells can scale down by at least this factor. This option is used", @@ -248,17 +248,17 @@ "When user-defined potential functions have been selected in the", "[TT].mdp[tt] file the [TT]-table[tt] option is used to pass [TT]mdrun[tt]", "a formatted table with potential functions. The file is read from", - "either the current directory or from the GMXLIB directory.", - "A number of pre-formatted tables are presented in the GMXLIB dir,", - "for 6-8, 6-9, 6-10, 6-11, 6-12 Lennard Jones potentials with", + "either the current directory or from the [TT]GMXLIB[tt] directory.", + "A number of pre-formatted tables are presented in the [TT]GMXLIB[tt] dir,", + "for 6-8, 6-9, 6-10, 6-11, 6-12 Lennard-Jones potentials with", "normal Coulomb.", - "When pair interactions are present a separate table for pair interaction", + "When pair interactions are present, a separate table for pair interaction", "functions is read using the [TT]-tablep[tt] option.[PAR]", "When tabulated bonded functions are present in the topology,", "interaction functions are read using the [TT]-tableb[tt] option.", "For each different tabulated interaction type the table file name is", "modified in a different way: before the file extension an underscore is", - "appended, then a b for bonds, an a for angles or a d for dihedrals", + "appended, then a 'b' for bonds, an 'a' for angles or a 'd' for dihedrals", "and finally the table number of the interaction type.[PAR]", "The options [TT]-px[tt] and [TT]-pf[tt] are used for writing pull COM", "coordinates and forces when pulling is selected", @@ -287,7 +287,7 @@ "is performed after every exchange.[PAR]", "Finally some experimental algorithms can be tested when the", "appropriate options have been given. Currently under", - "investigation are: polarizability, and X-Ray bombardments.", + "investigation are: polarizability and X-ray bombardments.", "[PAR]", "The option [TT]-pforce[tt] is useful when you suspect a simulation", "crashes due to too large forces. With this option coordinates and", @@ -309,11 +309,11 @@ "will be appending to the existing output files. The checkpoint file", "contains checksums of all output files, such that you will never", "loose data when some output files are modified, corrupt or removed.", - "There are three scenarios with [TT]-cpi[tt]:[BR]", - "* no files with matching names are present: new output files are written[BR]", - "* all files are present with names and checksums matching those stored", - "in the checkpoint file: files are appended[BR]", - "* otherwise no files are modified and a fatal error is generated[BR]", + "There are three scenarios with [TT]-cpi[tt]:[PAR]", + "[TT]*[tt] no files with matching names are present: new output files are written[PAR]", + "[TT]*[tt] all files are present with names and checksums matching those stored", + "in the checkpoint file: files are appended[PAR]", + "[TT]*[tt] otherwise no files are modified and a fatal error is generated[PAR]", "With [TT]-noappend[tt] new output files are opened and the simulation", "part number is added to all output file names.", "Note that in all cases the checkpoint file itself is not renamed", @@ -595,6 +595,11 @@ { sim_part = sim_part_fn + 1; } + + if (MULTISIM(cr)) + { + check_multi_int(stdout,cr->ms,sim_part,"simulation part"); + } } else { diff -Nru gromacs-4.5.4/src/kernel/pdb2gmx.c gromacs-4.5.5/src/kernel/pdb2gmx.c --- gromacs-4.5.4/src/kernel/pdb2gmx.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/pdb2gmx.c 2011-09-21 12:34:32.000000000 +0000 @@ -825,41 +825,60 @@ int old_prev_chainnum; int old_this_chainnum; t_resinfo *ri; + char select[STRLEN]; int new_chainnum; - + int this_atomnum; + int prev_atomnum; + const char * prev_atomname; + const char * this_atomname; + const char * prev_resname; + const char * this_resname; + int prev_resnum; + int this_resnum; + char prev_chainid; + char this_chainid; + int prev_chainnumber; + int this_chainnumber; + enum { SPLIT_ID_OR_TER, SPLIT_ID_AND_TER, SPLIT_ID_ONLY, - SPLIT_TER_ONLY + SPLIT_TER_ONLY, + SPLIT_INTERACTIVE } splitting; - printf("Splitting PDB chains based on "); splitting = SPLIT_TER_ONLY; /* keep compiler happy */ /* Be a bit flexible to catch typos */ - if (!strncmp(chainsep,"id_o",4) || !strncmp(chainsep,"int",3)) + if (!strncmp(chainsep,"id_o",4)) { /* For later interactive splitting we tentatively assign new chain numbers at either changing id or ter records */ splitting = SPLIT_ID_OR_TER; - printf("TER records or changing chain id.\n"); + printf("Splitting chemical chains based on TER records or chain id changing.\n"); + } + else if (!strncmp(chainsep,"int",3)) + { + /* For later interactive splitting we tentatively assign new chain numbers at either changing id or ter records */ + splitting = SPLIT_INTERACTIVE; + printf("Splitting chemical chains interactively.\n"); } else if (!strncmp(chainsep,"id_a",4)) { splitting = SPLIT_ID_AND_TER; - printf("TER records and chain id.\n"); + printf("Splitting chemical chains based on TER records and chain id changing.\n"); } else if (strlen(chainsep)==2 && !strncmp(chainsep,"id",4)) { splitting = SPLIT_ID_ONLY; - printf("changing chain id only (ignoring TER records).\n"); + printf("Splitting chemical chains based on changing chain id only (ignoring TER records).\n"); } else if (chainsep[0]=='t') { splitting = SPLIT_TER_ONLY; - printf("TER records only (ignoring chain id).\n"); + printf("Splitting chemical chains based on TER records only (ignoring chain id).\n"); } else { @@ -872,11 +891,32 @@ old_prev_chainnum = -1; new_chainnum = -1; + this_atomname = NULL; + this_atomnum = -1; + this_resname = NULL; + this_resnum = -1; + this_chainid = '?'; + this_chainnumber = -1; + for(i=0;inres;i++) { ri = &pdba->resinfo[i]; - old_this_chainid = ri->chainid; - old_this_chainnum = ri->chainnum; + old_this_chainid = ri->chainid; + old_this_chainnum = ri->chainnum; + + prev_atomname = this_atomname; + prev_atomnum = this_atomnum; + prev_resname = this_resname; + prev_resnum = this_resnum; + prev_chainid = this_chainid; + prev_chainnumber = this_chainnumber; + + this_atomname = *(pdba->atomname[i]); + this_atomnum = (pdba->pdbinfo != NULL) ? pdba->pdbinfo[i].atomnr : i+1; + this_resname = *ri->name; + this_resnum = ri->nr; + this_chainid = ri->chainid; + this_chainnumber = ri->chainnum; switch (splitting) { @@ -907,6 +947,27 @@ new_chainnum++; } break; + case SPLIT_INTERACTIVE: + if(old_this_chainid != old_prev_chainid || old_this_chainnum != old_prev_chainnum) + { + if(i>0) + { + printf("Split the chain (and introduce termini) between residue %s%d (chain id '%c', atom %d %s)\n" + "and residue %s%d (chain id '%c', atom %d %s) ? [n/y]\n", + prev_resname,prev_resnum,prev_chainid,prev_atomnum,prev_atomname, + this_resname,this_resnum,this_chainid,this_atomnum,this_atomname); + + if(NULL==fgets(select,STRLEN-1,stdin)) + { + gmx_fatal(FARGS,"Error reading from stdin"); + } + } + if(i==0 || select[0] == 'y') + { + new_chainnum++; + } + } + break; default: gmx_fatal(FARGS,"Internal inconsistency - this shouldn't happen..."); break; @@ -948,13 +1009,13 @@ const char *desc[] = { "This program reads a [TT].pdb[tt] (or [TT].gro[tt]) file, reads", "some database files, adds hydrogens to the molecules and generates", - "coordinates in Gromacs (Gromos), or optionally [TT].pdb[tt], format", - "and a topology in Gromacs format.", + "coordinates in GROMACS (GROMOS), or optionally [TT].pdb[tt], format", + "and a topology in GROMACS format.", "These files can subsequently be processed to generate a run input file.", "[PAR]", "[TT]pdb2gmx[tt] will search for force fields by looking for", "a [TT]forcefield.itp[tt] file in subdirectories [TT].ff[tt]", - "of the current working directory and of the Gromacs library directory", + "of the current working directory and of the GROMACS library directory", "as inferred from the path of the binary or the [TT]GMXLIB[tt] environment", "variable.", "By default the forcefield selection is interactive,", @@ -965,12 +1026,12 @@ "After choosing a force field, all files will be read only from", "the corresponding force field directory.", "If you want to modify or add a residue types, you can copy the force", - "field directory from the Gromacs library directory to your current", + "field directory from the GROMACS library directory to your current", "working directory. If you want to add new protein residue types,", "you will need to modify [TT]residuetypes.dat[tt] in the library directory", "or copy the whole library directory to a local directory and set", "the environment variable [TT]GMXLIB[tt] to the name of that directory.", - "Check chapter 5 of the manual for more information about file formats.", + "Check Chapter 5 of the manual for more information about file formats.", "[PAR]", "Note that a [TT].pdb[tt] file is nothing more than a file format, and it", @@ -981,40 +1042,56 @@ "The program has limited intelligence, it reads a number of database", "files, that allow it to make special bonds (Cys-Cys, Heme-His, etc.),", "if necessary this can be done manually. The program can prompt the", - "user to select which kind of LYS, ASP, GLU, CYS or HIS residue she", - "wants. For LYS the choice is between neutral (two protons on NZ) or", - "protonated (three protons, default), for ASP and GLU unprotonated", - "(default) or protonated, for HIS the proton can be either on ND1,", + "user to select which kind of LYS, ASP, GLU, CYS or HIS residue is", + "desired. For Lys the choice is between neutral (two protons on NZ) or", + "protonated (three protons, default), for Asp and Glu unprotonated", + "(default) or protonated, for His the proton can be either on ND1,", "on NE2 or on both. By default these selections are done automatically.", "For His, this is based on an optimal hydrogen bonding", "conformation. Hydrogen bonds are defined based on a simple geometric", "criterion, specified by the maximum hydrogen-donor-acceptor angle", "and donor-acceptor distance, which are set by [TT]-angle[tt] and", "[TT]-dist[tt] respectively.[PAR]", - + + "The protonation state of N- and C-termini can be chosen interactively", + "with the [TT]-ter[tt] flag. Default termini are ionized (NH3+ and COO-),", + "respectively. Some force fields support zwitterionic forms for chains of", + "one residue, but for polypeptides these options should NOT be selected.", + "The AMBER force fields have unique forms for the terminal residues,", + "and these are incompatible with the [TT]-ter[tt] mechanism. You need", + "to prefix your N- or C-terminal residue names with \"N\" or \"C\"", + "respectively to use these forms, making sure you preserve the format", + "of the coordinate file. Alternatively, use named terminating residues", + "(e.g. ACE, NME).[PAR]", + "The separation of chains is not entirely trivial since the markup", "in user-generated PDB files frequently varies and sometimes it", "is desirable to merge entries across a TER record, for instance", "if you want a disulfide bridge or distance restraints between", "two protein chains or if you have a HEME group bound to a protein.", "In such cases multiple chains should be contained in a single", - "[TT]molecule_type[tt] definition.", - "To handle this, [TT]pdb2gmx[tt] has an option [TT]-chainsep[tt] so you can", - "choose whether a new chain should start when we find a TER record,", - "when the chain id changes, combinations of either or both of these", - "or fully interactively.[PAR]", - + "[TT]moleculetype[tt] definition.", + "To handle this, [TT]pdb2gmx[tt] uses two separate options.", + "First, [TT]-chainsep[tt] allows you to choose when a new chemical chain should", + "start, and termini added when applicable. This can be done based on the", + "existence of TER records, when the chain id changes, or combinations of either", + "or both of these. You can also do the selection fully interactively.", + "In addition, there is a [TT]-merge[tt] option that controls how multiple chains", + "are merged into one moleculetype, after adding all the chemical termini (or not).", + "This can be turned off (no merging), all non-water chains can be merged into a", + "single molecule, or the selection can be done interactively.[PAR]", + "[TT]pdb2gmx[tt] will also check the occupancy field of the [TT].pdb[tt] file.", "If any of the occupancies are not one, indicating that the atom is", "not resolved well in the structure, a warning message is issued.", - "When a [TT].pdb[tt] file does not originate from an X-Ray structure determination", + "When a [TT].pdb[tt] file does not originate from an X-ray structure determination", "all occupancy fields may be zero. Either way, it is up to the user", "to verify the correctness of the input data (read the article!).[PAR]", - "During processing the atoms will be reordered according to Gromacs", + "During processing the atoms will be reordered according to GROMACS", "conventions. With [TT]-n[tt] an index file can be generated that", "contains one group reordered in the same way. This allows you to", - "convert a Gromos trajectory and coordinate file to Gromos. There is", + "convert a GROMOS trajectory and coordinate file to GROMOS. There is", "one limitation: reordering is done after the hydrogens are stripped", "from the input and before new hydrogens are added. This means that", "you should not use [TT]-ignh[tt].[PAR]", @@ -1030,7 +1107,7 @@ "position relative to neighboring atoms. Additionally, all atoms in the", "aromatic rings of the standard amino acids (i.e. PHE, TRP, TYR and HIS)", "can be converted into virtual sites, eliminating the fast improper dihedral", - "fluctuations in these rings. Note that in this case all other hydrogen", + "fluctuations in these rings. [BB]Note[bb] that in this case all other hydrogen", "atoms are also converted to virtual sites. The mass of all atoms that are", "converted into virtual sites, is added to the heavy atoms.[PAR]", "Also slowing down of dihedral motion can be done with [TT]-heavyh[tt]", @@ -1084,7 +1161,7 @@ int nssbonds; t_ssbond *ssbonds; rvec *pdbx,*x; - gmx_bool bVsites=FALSE,bWat,bPrevWat=FALSE,bITP,bVsiteAromatics=FALSE,bMerge; + gmx_bool bVsites=FALSE,bWat,bPrevWat=FALSE,bITP,bVsiteAromatics=FALSE,bCheckMerge; real mHmult=0; t_hackblock *hb_chain; t_restp *restp_chain; @@ -1107,6 +1184,7 @@ int this_chainstart; int prev_chainstart; gmx_bool bMerged; + int nchainmerges; gmx_atomprop_t aps; @@ -1135,6 +1213,7 @@ static const char *vsitestr[] = { NULL, "none", "hydrogens", "aromatics", NULL }; static const char *watstr[] = { NULL, "select", "none", "spc", "spce", "tip3p", "tip4p", "tip5p", NULL }; static const char *chainsep[] = { NULL, "id_or_ter", "id_and_ter", "ter", "id", "interactive", NULL }; + static const char *merge[] = {NULL, "no", "all", "interactive", NULL }; static const char *ff = "select"; t_pargs pa[] = { @@ -1145,7 +1224,9 @@ { "-sb", FALSE, etREAL, {&short_bond_dist}, "HIDDENShort bond warning distance" }, { "-chainsep", FALSE, etENUM, {chainsep}, - "Condition in PDB files when a new chain and molecule_type should be started" }, + "Condition in PDB files when a new chain should be started (adding termini)" }, + { "-merge", FALSE, etENUM, {&merge}, + "Merge multiple chains into a single [moleculetype]" }, { "-ff", FALSE, etSTR, {&ff}, "Force field, interactive by default. Use [TT]-h[tt] for information." }, { "-water", FALSE, etENUM, {watstr}, @@ -1155,26 +1236,26 @@ { "-ss", FALSE, etBOOL, {&bCysMan}, "Interactive SS bridge selection" }, { "-ter", FALSE, etBOOL, {&bTerMan}, - "Interactive termini selection, iso charged" }, + "Interactive termini selection, instead of charged (default)" }, { "-lys", FALSE, etBOOL, {&bLysMan}, - "Interactive Lysine selection, iso charged" }, + "Interactive lysine selection, instead of charged" }, { "-arg", FALSE, etBOOL, {&bArgMan}, - "Interactive Arganine selection, iso charged" }, + "Interactive arginine selection, instead of charged" }, { "-asp", FALSE, etBOOL, {&bAspMan}, - "Interactive Aspartic Acid selection, iso charged" }, + "Interactive aspartic acid selection, instead of charged" }, { "-glu", FALSE, etBOOL, {&bGluMan}, - "Interactive Glutamic Acid selection, iso charged" }, + "Interactive glutamic acid selection, instead of charged" }, { "-gln", FALSE, etBOOL, {&bGlnMan}, - "Interactive Glutamine selection, iso neutral" }, + "Interactive glutamine selection, instead of neutral" }, { "-his", FALSE, etBOOL, {&bHisMan}, - "Interactive Histidine selection, iso checking H-bonds" }, + "Interactive histidine selection, instead of checking H-bonds" }, { "-angle", FALSE, etREAL, {&angle}, "Minimum hydrogen-donor-acceptor angle for a H-bond (degrees)" }, { "-dist", FALSE, etREAL, {&distance}, "Maximum donor-acceptor distance for a H-bond (nm)" }, { "-una", FALSE, etBOOL, {&bUnA}, - "Select aromatic rings with united CH atoms on Phenylalanine, " - "Tryptophane and Tyrosine" }, + "Select aromatic rings with united CH atoms on phenylalanine, " + "tryptophane and tyrosine" }, { "-sort", FALSE, etBOOL, {&bSort}, "HIDDENSort the residues according to database, turning this off is dangerous as charge groups might be broken in parts" }, { "-ignh", FALSE, etBOOL, {&bRemoveH}, @@ -1321,8 +1402,7 @@ modify_chain_numbers(&pdba_all,chainsep[0]); - - bMerge = !strncmp(chainsep[0],"int",3); + nchainmerges = 0; this_atomname = NULL; this_atomnum = -1; @@ -1335,6 +1415,7 @@ prev_chainstart = 0; pdb_ch=NULL; + bMerged = FALSE; for (i=0; (i0 && !bWat) + + bMerged = FALSE; + if (i>0 && !bWat) { - printf("Merge chain ending with residue %s%d (chain id '%c', atom %d %s) with\n" - "chain starting with residue %s%d (chain id '%c', atom %d %s)? [n/y]\n", - prev_resname,prev_resnum,prev_chainid,prev_atomnum,prev_atomname, - this_resname,this_resnum,this_chainid,this_atomnum,this_atomname); - - if(NULL==fgets(select,STRLEN-1,stdin)) + if(!strncmp(merge[0],"int",3)) { - gmx_fatal(FARGS,"Error reading from stdin"); + printf("Merge chain ending with residue %s%d (chain id '%c', atom %d %s) and chain starting with\n" + "residue %s%d (chain id '%c', atom %d %s) into a single moleculetype (keeping termini)? [n/y]\n", + prev_resname,prev_resnum,prev_chainid,prev_atomnum,prev_atomname, + this_resname,this_resnum,this_chainid,this_atomnum,this_atomname); + + if(NULL==fgets(select,STRLEN-1,stdin)) + { + gmx_fatal(FARGS,"Error reading from stdin"); + } + bMerged = (select[0] == 'y'); + } + else if(!strncmp(merge[0],"all",3)) + { + bMerged = TRUE; } - } - else - { - select[0] = 'n'; } - bMerged = (select[0] == 'y'); - if (bMerged) - { + if (bMerged) + { pdb_ch[nch-1].chainstart[pdb_ch[nch-1].nterpairs] = - pdba_all.atom[i].resind - prev_chainstart; + pdba_all.atom[i].resind - prev_chainstart; pdb_ch[nch-1].nterpairs++; srenew(pdb_ch[nch-1].chainstart,pdb_ch[nch-1].nterpairs+1); + nchainmerges++; } else { @@ -1490,9 +1577,9 @@ } } - if (bMerge) - printf("\nMerged %d chains into one molecule definition\n\n", - pdb_ch[0].nterpairs); + if (nchainmerges>0) + printf("\nMerged chains into joint molecule definitions at %d places.\n\n", + nchainmerges); printf("There are %d chains and %d blocks of water and " "%d residues with %d atoms\n", diff -Nru gromacs-4.5.4/src/kernel/pgutil.c gromacs-4.5.5/src/kernel/pgutil.c --- gromacs-4.5.4/src/kernel/pgutil.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/pgutil.c 2011-09-21 12:34:32.000000000 +0000 @@ -48,13 +48,16 @@ { if (strcmp(bondtype,"check") != 0) { if (bDontQuit) { - fprintf(stderr, - "WARNING: atom %s not found in residue seq.nr. %d while adding %s\n", - atomname,resind+1,bondtype); + gmx_warning("WARNING: Atom %s is used in an interaction of type %s in the\n" + "topology database, but an atom of that name was not found in\n" + "residue number %d.\n", + atomname,bondtype,resind+1); } else { gmx_fatal(fatal_errno,file,line, - "Atom %s not found in residue seq.nr. %d while adding %s\n", - atomname,resind+1,bondtype); + "Atom %s is used in an interaction of type %s in the topology\n" + "database, but an atom of that name was not found in residue\n" + "number %d.\n", + atomname,bondtype,resind+1); } } } diff -Nru gromacs-4.5.4/src/kernel/readir.c gromacs-4.5.5/src/kernel/readir.c --- gromacs-4.5.4/src/kernel/readir.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/readir.c 2011-09-21 12:34:32.000000000 +0000 @@ -1310,10 +1310,14 @@ int i; for(i=0; (iopts.ngfrz; g++) { - for(d=0; dopts.nFreeze[g][d] != 0) { - AbsRef[d] = 1; - } + int d,g,i; + gmx_mtop_ilistloop_t iloop; + t_ilist *ilist; + int nmol; + t_iparams *pr; + + clear_ivec(AbsRef); + + if (!posres_only) + { + /* Check the COM */ + for(d=0; dopts.ngfrz; g++) + { + for(d=0; dopts.nFreeze[g][d] != 0) + { + AbsRef[d] = 1; + } + } + } } - } - /* Check for position restraints */ - iloop = gmx_mtop_ilistloop_init(sys); - while (gmx_mtop_ilistloop_next(iloop,&ilist,&nmol)) { - if (nmol > 0) { - for(i=0; iffparams.iparams[ilist[F_POSRES].iatoms[i]]; - for(d=0; dposres.fcA[d] != 0) { - AbsRef[d] = 1; - } - } - } + + /* Check for position restraints */ + iloop = gmx_mtop_ilistloop_init(sys); + while (gmx_mtop_ilistloop_next(iloop,&ilist,&nmol)) + { + if (nmol > 0 && + (AbsRef[XX] == 0 || AbsRef[YY] == 0 || AbsRef[ZZ] == 0)) + { + for(i=0; iffparams.iparams[ilist[F_POSRES].iatoms[i]]; + for(d=0; dposres.fcA[d] != 0) + { + AbsRef[d] = 1; + } + } + } + } } - } - return (AbsRef[XX] != 0 && AbsRef[YY] != 0 && AbsRef[ZZ] != 0); + return (AbsRef[XX] != 0 && AbsRef[YY] != 0 && AbsRef[ZZ] != 0); } void triple_check(const char *mdparin,t_inputrec *ir,gmx_mtop_t *sys, @@ -2282,10 +2304,26 @@ if (EI_DYNAMICS(ir->eI) && !EI_SD(ir->eI) && ir->eI != eiBD && ir->comm_mode == ecmNO && - !(absolute_reference(ir,sys,AbsRef) || ir->nsteps <= 10)) { + !(absolute_reference(ir,sys,FALSE,AbsRef) || ir->nsteps <= 10)) { warning(wi,"You are not using center of mass motion removal (mdp option comm-mode), numerical rounding errors can lead to build up of kinetic energy of the center of mass"); } - + + /* Check for pressure coupling with absolute position restraints */ + if (ir->epc != epcNO && ir->refcoord_scaling == erscNO) + { + absolute_reference(ir,sys,TRUE,AbsRef); + { + for(m=0; mcompress[m]) > 0) + { + warning(wi,"You are using pressure coupling with absolute position restraints, this will give artifacts. Use the refcoord_scaling option."); + break; + } + } + } + } + bCharge = FALSE; aloopb = gmx_mtop_atomloop_block_init(sys); while (gmx_mtop_atomloop_block_next(aloopb,&atom,&nmol)) { @@ -2380,7 +2418,7 @@ if (ir->ePull != epullNO) { if (ir->pull->grp[0].nat == 0) { - absolute_reference(ir,sys,AbsRef); + absolute_reference(ir,sys,FALSE,AbsRef); for(m=0; mpull->dim[m] && !AbsRef[m]) { warning(wi,"You are using an absolute reference for pulling, but the rest of the system does not have an absolute reference. This will lead to artifacts."); diff -Nru gromacs-4.5.4/src/kernel/repl_ex.c gromacs-4.5.5/src/kernel/repl_ex.c --- gromacs-4.5.4/src/kernel/repl_ex.c 2011-03-21 08:35:27.000000000 +0000 +++ gromacs-4.5.5/src/kernel/repl_ex.c 2011-09-21 12:34:32.000000000 +0000 @@ -89,24 +89,20 @@ { bDiff = TRUE; } - - if (bDiff) + } + if (bDiff) + { + if (re->type >= 0 && re->type < ereNR) { - if (re->type >= 0 && re->type < ereNR) - { - gmx_fatal(FARGS,"For replica exchange both %s and %s differ", - erename[re->type],erename[ere]); - } - else - { - /* Set the replica exchange type and quantities */ - re->type = ere; - snew(re->q,re->nrepl); - for(s=0; snsim; s++) - { - re->q[s] = qall[s]; - } - } + gmx_fatal(FARGS,"For replica exchange both %s and %s differ", + erename[re->type],erename[ere]); + } + /* Set the replica exchange type and quantities */ + re->type = ere; + snew(re->q,re->nrepl); + for(s=0; snsim; s++) + { + re->q[s] = qall[s]; } } diff -Nru gromacs-4.5.4/src/kernel/resall.c gromacs-4.5.5/src/kernel/resall.c --- gromacs-4.5.4/src/kernel/resall.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/resall.c 2011-09-21 12:34:32.000000000 +0000 @@ -82,7 +82,7 @@ trim(buf); } } - while (NULL!=buf && strlen(buf)==0); + while (!feof(in) && NULL!=buf && strlen(buf)==0); if ((buf != NULL) && (sscanf(buf,"%s%lf",name,&m) == 2)) { diff -Nru gromacs-4.5.4/src/kernel/runner.c gromacs-4.5.5/src/kernel/runner.c --- gromacs-4.5.4/src/kernel/runner.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/runner.c 2011-09-21 12:34:32.000000000 +0000 @@ -274,7 +274,7 @@ } else { - nthreads = tMPI_Get_recommended_nthreads(); + nthreads = tMPI_Thread_get_hw_number(); } } @@ -647,10 +647,6 @@ { if (PAR(cr)) { - if (!MASTER(cr)) - { - snew(state,1); - } bcast_state(cr,state,TRUE); } } @@ -884,15 +880,3 @@ return rc; } - -void md_print_warning(const t_commrec *cr,FILE *fplog,const char *buf) -{ - if (MASTER(cr)) - { - fprintf(stderr,"\n%s\n",buf); - } - if (fplog) - { - fprintf(fplog,"\n%s\n",buf); - } -} diff -Nru gromacs-4.5.4/src/kernel/ter_db.c gromacs-4.5.5/src/kernel/ter_db.c --- gromacs-4.5.4/src/kernel/ter_db.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/ter_db.c 2011-09-21 12:34:32.000000000 +0000 @@ -470,8 +470,15 @@ int i,sel,ret; printf("%s\n",title); - for(i=0; (i= nb)); diff -Nru gromacs-4.5.4/src/kernel/topio.c gromacs-4.5.5/src/kernel/topio.c --- gromacs-4.5.4/src/kernel/topio.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/topio.c 2011-09-21 12:34:32.000000000 +0000 @@ -531,7 +531,10 @@ gmx_cpp_t handle; char *tmp_line=NULL; char warn_buf[STRLEN]; - + const char *floating_point_arithmetic_tip = + "Total charge should normally be an integer. See\n" + "http://www.gromacs.org/Documentation/Floating_Point_Arithmetic\n" + "for discussion on how close it should be to an integer.\n"; /* We need to open the output file before opening the input file, * because cpp_open_file can change the current working directory. */ @@ -922,11 +925,11 @@ if(!title) title=put_symtab(symtab,""); if (fabs(qt) > 1e-4) { - sprintf(warn_buf,"System has non-zero total charge: %e\n\n",qt); + sprintf(warn_buf,"System has non-zero total charge: %.6f\n%s\n",qt,floating_point_arithmetic_tip); warning_note(wi,warn_buf); } if (fabs(qBt) > 1e-4 && !gmx_within_tol(qBt,qt,1e-6)) { - sprintf(warn_buf,"State B has non-zero total charge: %e\n\n",qBt); + sprintf(warn_buf,"State B has non-zero total charge: %.6f\n%s\n",qBt,floating_point_arithmetic_tip); warning_note(wi,warn_buf); } DS_Done (&DS); diff -Nru gromacs-4.5.4/src/kernel/tpbconv.c gromacs-4.5.5/src/kernel/tpbconv.c --- gromacs-4.5.4/src/kernel/tpbconv.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/tpbconv.c 2011-09-21 12:34:32.000000000 +0000 @@ -1,4 +1,5 @@ -/* +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * * * This source code is part of * @@ -55,6 +56,7 @@ #include "vec.h" #include "mtop_util.h" #include "random.h" +#include "checkpoint.h" #define RANGECHK(i,n) if ((i)>=(n)) gmx_fatal(FARGS,"Your index file contains atomnumbers (e.g. %d)\nthat are larger than the number of atoms in the tpr file (%d)",(i),(n)) @@ -307,7 +309,7 @@ "of the original run.[PAR]", "[BB]3.[bb] by creating a [TT].tpx[tt] file for a subset of your original", "tpx file, which is useful when you want to remove the solvent from", - "your [TT].tpx[tt] file, or when you want to make e.g. a pure Ca [TT].tpx[tt] file.", + "your [TT].tpx[tt] file, or when you want to make e.g. a pure C[GRK]alpha[grk] [TT].tpx[tt] file.", "Note that you may need to use [TT]-nsteps -1[tt] (or similar) to get", "this to work.", "[BB]WARNING: this [TT].tpx[tt] file is not fully functional[bb].[PAR]", @@ -399,7 +401,7 @@ if (bTraj) { fprintf(stderr,"\n" - "NOTE: Reading the state from trajectory is an obsolete feaure of tpbconv.\n" + "NOTE: Reading the state from trajectory is an obsolete feature of tpbconv.\n" " Continuation should be done by loading a checkpoint file with mdrun -cpi\n" " This guarantees that all state variables are transferred.\n" " tpbconv is now only useful for increasing nsteps,\n" @@ -429,97 +431,126 @@ } frame_fn = ftp2fn(efTRN,NFILE,fnm); - fprintf(stderr, - "\nREADING COORDS, VELS AND BOX FROM TRAJECTORY %s...\n\n", - frame_fn); - - fp = open_trn(frame_fn,"r"); - if (bScanEner) { - fp_ener = open_enx(ftp2fn(efEDR,NFILE,fnm),"r"); - do_enxnms(fp_ener,&nre,&enm); - snew(fr_ener,1); - fr_ener->t = -1e-12; - } - - /* Now scan until the last set of x and v (step == 0) - * or the ones at step step. - */ - bFrame = TRUE; - frame = 0; - while (bFrame) { - bFrame = fread_trnheader(fp,&head,&bOK); - if (bOK && frame == 0) { - if (mtop.natoms != head.natoms) - gmx_fatal(FARGS,"Number of atoms in Topology (%d) " - "is not the same as in Trajectory (%d)\n", - mtop.natoms,head.natoms); - snew(newx,head.natoms); - snew(newv,head.natoms); - } - bFrame = bFrame && bOK; - if (bFrame) { - - bOK = fread_htrn(fp,&head,newbox,newx,newv,NULL); - } - bFrame = bFrame && bOK; - bUse = FALSE; - if (bFrame && - (head.x_size) && (head.v_size || !bVel)) { - bUse = TRUE; - if (bScanEner) { - /* Read until the energy time is >= the trajectory time */ - while (fr_ener->t < head.t && do_enx(fp_ener,fr_ener)); - bUse = (fr_ener->t == head.t); - } - if (bUse) { - tmpx = newx; - newx = state.x; - state.x = tmpx; - tmpv = newv; - newv = state.v; - state.v = tmpv; - run_t = head.t; - run_step = head.step; - state.lambda = head.lambda; - copy_mat(newbox,state.box); - } - } - if (bFrame || !bOK) { - sprintf(buf,"\r%s %s frame %s%s: step %s%s time %s", - "%s","%s","%6",gmx_large_int_fmt,"%6",gmx_large_int_fmt," %8.3f"); - fprintf(stderr,buf, - bUse ? "Read " : "Skipped",ftp2ext(fn2ftp(frame_fn)), - frame,head.step,head.t); - frame++; - if (bTime && (head.t >= start_t)) - bFrame = FALSE; - } - } - if (bScanEner) { - close_enx(fp_ener); - free_enxframe(fr_ener); - free_enxnms(nre,enm); - } - close_trn(fp); - fprintf(stderr,"\n"); - - if (!bOK) - fprintf(stderr,"%s frame %s (step %s, time %g) is incomplete\n", - ftp2ext(fn2ftp(frame_fn)),gmx_step_str(frame-1,buf2), - gmx_step_str(head.step,buf),head.t); - fprintf(stderr,"\nUsing frame of step %s time %g\n", - gmx_step_str(run_step,buf),run_t); - - if (bNeedEner) { - if (bReadEner) { - get_enx_state(ftp2fn(efEDR,NFILE,fnm),run_t,&mtop.groups,ir,&state); - } else { - fprintf(stderr,"\nWARNING: The simulation uses %s temperature and/or %s pressure coupling,\n" - " the continuation will only be exact when an energy file is supplied\n\n", - ETCOUPLTYPE(etcNOSEHOOVER), - EPCOUPLTYPE(epcPARRINELLORAHMAN)); - } - } + + if (fn2ftp(frame_fn) == efCPT) + { + int sim_part; + + fprintf(stderr, + "\nREADING STATE FROM CHECKPOINT %s...\n\n", + frame_fn); + + read_checkpoint_state(frame_fn,&sim_part, + &run_step,&run_t,&state); + } + else + { + fprintf(stderr, + "\nREADING COORDS, VELS AND BOX FROM TRAJECTORY %s...\n\n", + frame_fn); + + fp = open_trn(frame_fn,"r"); + if (bScanEner) + { + fp_ener = open_enx(ftp2fn(efEDR,NFILE,fnm),"r"); + do_enxnms(fp_ener,&nre,&enm); + snew(fr_ener,1); + fr_ener->t = -1e-12; + } + + /* Now scan until the last set of x and v (step == 0) + * or the ones at step step. + */ + bFrame = TRUE; + frame = 0; + while (bFrame) + { + bFrame = fread_trnheader(fp,&head,&bOK); + if (bOK && frame == 0) + { + if (mtop.natoms != head.natoms) + gmx_fatal(FARGS,"Number of atoms in Topology (%d) " + "is not the same as in Trajectory (%d)\n", + mtop.natoms,head.natoms); + snew(newx,head.natoms); + snew(newv,head.natoms); + } + bFrame = bFrame && bOK; + if (bFrame) + { + bOK = fread_htrn(fp,&head,newbox,newx,newv,NULL); + } + bFrame = bFrame && bOK; + bUse = FALSE; + if (bFrame && + (head.x_size) && (head.v_size || !bVel)) + { + bUse = TRUE; + if (bScanEner) + { + /* Read until the energy time is >= the trajectory time */ + while (fr_ener->t < head.t && do_enx(fp_ener,fr_ener)); + bUse = (fr_ener->t == head.t); + } + if (bUse) + { + tmpx = newx; + newx = state.x; + state.x = tmpx; + tmpv = newv; + newv = state.v; + state.v = tmpv; + run_t = head.t; + run_step = head.step; + state.lambda = head.lambda; + copy_mat(newbox,state.box); + } + } + if (bFrame || !bOK) + { + sprintf(buf,"\r%s %s frame %s%s: step %s%s time %s", + "%s","%s","%6",gmx_large_int_fmt,"%6",gmx_large_int_fmt," %8.3f"); + fprintf(stderr,buf, + bUse ? "Read " : "Skipped",ftp2ext(fn2ftp(frame_fn)), + frame,head.step,head.t); + frame++; + if (bTime && (head.t >= start_t)) + bFrame = FALSE; + } + } + if (bScanEner) + { + close_enx(fp_ener); + free_enxframe(fr_ener); + free_enxnms(nre,enm); + } + close_trn(fp); + fprintf(stderr,"\n"); + + if (!bOK) + { + fprintf(stderr,"%s frame %s (step %s, time %g) is incomplete\n", + ftp2ext(fn2ftp(frame_fn)),gmx_step_str(frame-1,buf2), + gmx_step_str(head.step,buf),head.t); + } + fprintf(stderr,"\nUsing frame of step %s time %g\n", + gmx_step_str(run_step,buf),run_t); + + if (bNeedEner) + { + if (bReadEner) + { + get_enx_state(ftp2fn(efEDR,NFILE,fnm),run_t,&mtop.groups,ir,&state); + } + else + { + fprintf(stderr,"\nWARNING: The simulation uses %s temperature and/or %s pressure coupling,\n" + " the continuation will only be exact when an energy file is supplied\n\n", + ETCOUPLTYPE(etcNOSEHOOVER), + EPCOUPLTYPE(epcPARRINELLORAHMAN)); + } + } + } } if (bNsteps) { diff -Nru gromacs-4.5.4/src/kernel/vsite_parm.c gromacs-4.5.5/src/kernel/vsite_parm.c --- gromacs-4.5.4/src/kernel/vsite_parm.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/vsite_parm.c 2011-09-21 12:34:32.000000000 +0000 @@ -317,6 +317,30 @@ return angle; } +static char *get_atomtype_name_AB(t_atom *atom,gpp_atomtype_t atype) +{ + char *name; + + name = get_atomtype_name(atom->type,atype); + + /* When using the decoupling option, atom types are changed + * to decoupled for the non-bonded interactions, but the virtual + * sites constructions should be based on the "normal" interactions. + * So we return the state B atom type name if the state A atom + * type is the decoupled one. We should actually check for the atom + * type number, but that's not passed here. So we check for + * the decoupled atom type name. This should not cause trouble + * as this code is only used for topologies with v-sites without + * parameters generated by pdb2gmx. + */ + if (strcmp(name,"decoupled") == 0) + { + name = get_atomtype_name(atom->typeB,atype); + } + + return name; +} + static gmx_bool calc_vsite3_param(gpp_atomtype_t atype, t_param *param, t_atoms *at, int nrbond, t_mybonded *bonds, @@ -336,14 +360,14 @@ for (i=0; i<4; i++) fprintf(debug,"atom %u type %s ", param->a[i]+1, - get_atomtype_name(at->atom[param->a[i]].type,atype)); + get_atomtype_name_AB(&at->atom[param->a[i]],atype)); fprintf(debug,"\n"); } bXH3 = - ( (gmx_strncasecmp(get_atomtype_name(at->atom[param->AK].type,atype),"MNH",3)==0) && - (gmx_strncasecmp(get_atomtype_name(at->atom[param->AL].type,atype),"MNH",3)==0) ) || - ( (gmx_strncasecmp(get_atomtype_name(at->atom[param->AK].type,atype),"MCH3",4)==0) && - (gmx_strncasecmp(get_atomtype_name(at->atom[param->AL].type,atype),"MCH3",4)==0) ); + ( (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AK],atype),"MNH",3)==0) && + (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AL],atype),"MNH",3)==0) ) || + ( (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AK],atype),"MCH3",4)==0) && + (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AL],atype),"MCH3",4)==0) ); bjk = get_bond_length(nrbond, bonds, param->AJ, param->AK); bjl = get_bond_length(nrbond, bonds, param->AJ, param->AL); @@ -484,14 +508,14 @@ int i; for (i=0; i<4; i++) fprintf(debug,"atom %u type %s ", - param->a[i]+1,get_atomtype_name(at->atom[param->a[i]].type,atype)); + param->a[i]+1,get_atomtype_name_AB(&at->atom[param->a[i]],atype)); fprintf(debug,"\n"); } bXH3 = - ( (gmx_strncasecmp(get_atomtype_name(at->atom[param->AK].type,atype),"MNH",3)==0) && - (gmx_strncasecmp(get_atomtype_name(at->atom[param->AL].type,atype),"MNH",3)==0) ) || - ( (gmx_strncasecmp(get_atomtype_name(at->atom[param->AK].type,atype),"MCH3",4)==0) && - (gmx_strncasecmp(get_atomtype_name(at->atom[param->AL].type,atype),"MCH3",4)==0) ); + ( (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AK],atype),"MNH",3)==0) && + (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AL],atype),"MNH",3)==0) ) || + ( (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AK],atype),"MCH3",4)==0) && + (gmx_strncasecmp(get_atomtype_name_AB(&at->atom[param->AL],atype),"MCH3",4)==0) ); /* check if construction parity must be swapped */ bSwapParity = ( param->C1 == -1 ); diff -Nru gromacs-4.5.4/src/kernel/xlate.c gromacs-4.5.5/src/kernel/xlate.c --- gromacs-4.5.4/src/kernel/xlate.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/kernel/xlate.c 2011-09-21 12:34:32.000000000 +0000 @@ -63,7 +63,7 @@ { char filebase[STRLEN]; char line[STRLEN]; - char rbuf[1024],abuf[1024],repbuf[1024],dumbuf[1024]; + char abuf[1024],rbuf[1024],repbuf[1024],dumbuf[1024]; char *_ptr; int n,na,idum; t_xlate_atom *xl; diff -Nru gromacs-4.5.4/src/mdlib/clincs.c gromacs-4.5.5/src/mdlib/clincs.c --- gromacs-4.5.4/src/mdlib/clincs.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/clincs.c 2011-09-21 12:34:32.000000000 +0000 @@ -1161,7 +1161,7 @@ t_nrnb *nrnb, int maxwarn,int *warncount) { - char buf[STRLEN],buf2[22]; + char buf[STRLEN],buf2[22],buf3[STRLEN]; int i,warn,p_imax,error; real ncons_loc,p_ssd,p_max; t_pbc pbc,*pbc_null; @@ -1324,10 +1324,19 @@ { cconerr(cr->dd,lincsd->nc,lincsd->bla,lincsd->bllen,xprime,pbc_null, &ncons_loc,&p_ssd,&p_max,&p_imax); - sprintf(buf,"\nStep %s, time %g (ps) LINCS WARNING\n" + if (MULTISIM(cr)) + { + sprintf(buf3," in simulation %d", cr->ms->sim); + } + else + { + buf3[0] = 0; + } + sprintf(buf,"\nStep %s, time %g (ps) LINCS WARNING%s\n" "relative constraint deviation after LINCS:\n" "rms %.6f, max %.6f (between atoms %d and %d)\n", gmx_step_str(step,buf2),ir->init_t+step*ir->delta_t, + buf3, sqrt(p_ssd/ncons_loc),p_max, ddglatnr(cr->dd,lincsd->bla[2*p_imax]), ddglatnr(cr->dd,lincsd->bla[2*p_imax+1])); diff -Nru gromacs-4.5.4/src/mdlib/constr.c gromacs-4.5.5/src/mdlib/constr.c --- gromacs-4.5.4/src/mdlib/constr.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/constr.c 2011-09-21 12:34:32.000000000 +0000 @@ -82,14 +82,13 @@ atom_id blocknr; } t_sortblock; -static t_vetavars *init_vetavars(real veta,real vetanew, t_inputrec *ir, gmx_ekindata_t *ekind, gmx_bool bPscal) +static void *init_vetavars(t_vetavars *vars, + gmx_bool constr_deriv, + real veta,real vetanew, t_inputrec *ir, gmx_ekindata_t *ekind, gmx_bool bPscal) { - t_vetavars *vars; double g; int i; - snew(vars,1); - snew(vars->vscale_nhc,ir->opts.ngtc); /* first, set the alpha integrator variable */ if ((ir->opts.nrdf[0] > 0) && bPscal) { @@ -103,25 +102,39 @@ vars->vscale = exp(g)*series_sinhx(g); vars->rvscale = vars->vscale*vars->rscale; vars->veta = vetanew; - if ((ekind==NULL) || (!bPscal)) + + if (constr_deriv) { - for (i=0;iopts.ngtc;i++) + snew(vars->vscale_nhc,ir->opts.ngtc); + if ((ekind==NULL) || (!bPscal)) { - vars->vscale_nhc[i] = 1; + for (i=0;iopts.ngtc;i++) + { + vars->vscale_nhc[i] = 1; + } } - } else { - for (i=0;iopts.ngtc;i++) + else { - vars->vscale_nhc[i] = ekind->tcstat[i].vscale_nhc; + for (i=0;iopts.ngtc;i++) + { + vars->vscale_nhc[i] = ekind->tcstat[i].vscale_nhc; + } } } + else + { + vars->vscale_nhc = NULL; + } + return vars; } static void free_vetavars(t_vetavars *vars) { - sfree(vars->vscale_nhc); - sfree(vars); + if (vars->vscale_nhc != NULL) + { + sfree(vars->vscale_nhc); + } } static int pcomp(const void *p1, const void *p2) @@ -296,7 +309,7 @@ int nsettle; t_pbc pbc; char buf[22]; - t_vetavars *vetavar; + t_vetavars vetavar; if (econq == econqForceDispl && !EI_ENERGY_MINIMIZATION(ir->eI)) { @@ -311,7 +324,8 @@ nrend = start+homenr; /* set constants for pressure control integration */ - vetavar = init_vetavars(veta,vetanew,ir,ekind,bPscal); + init_vetavars(&vetavar,econq!=econqCoord, + veta,vetanew,ir,ekind,bPscal); if (ir->delta_t == 0) { @@ -362,14 +376,16 @@ homenr,md->invmass,constr->nblocks,constr->sblock, idef,ir,box,x,xprime,nrnb, constr->lagr,lambda,dvdlambda, - invdt,v,vir!=NULL,rmdr,constr->maxwarn>=0,econq,vetavar); + invdt,v,vir!=NULL,rmdr,constr->maxwarn>=0,econq, + &vetavar); break; case (econqVeloc): bOK = bshakef(fplog,constr->shaked, homenr,md->invmass,constr->nblocks,constr->sblock, idef,ir,box,x,min_proj,nrnb, constr->lagr,lambda,dvdlambda, - invdt,NULL,vir!=NULL,rmdr,constr->maxwarn>=0,econq,vetavar); + invdt,NULL,vir!=NULL,rmdr,constr->maxwarn>=0,econq, + &vetavar); break; default: gmx_fatal(FARGS,"Internal error, SHAKE called for constraining something else than coordinates"); @@ -397,7 +413,7 @@ case econqCoord: csettle(constr->settled, nsettle,settle->iatoms,x[0],xprime[0], - invdt,v[0],vir!=NULL,rmdr,&error,vetavar); + invdt,v[0],vir!=NULL,rmdr,&error,&vetavar); inc_nrnb(nrnb,eNR_SETTLE,nsettle); if (v != NULL) { @@ -434,7 +450,7 @@ case econqForceDispl: settle_proj(fplog,constr->settled,econq, nsettle,settle->iatoms,x, - xprime,min_proj,vir!=NULL,rmdr,vetavar); + xprime,min_proj,vir!=NULL,rmdr,&vetavar); /* This is an overestimate */ inc_nrnb(nrnb,eNR_SETTLE,nsettle); break; @@ -447,7 +463,7 @@ } } - free_vetavars(vetavar); + free_vetavars(&vetavar); if (vir != NULL) { diff -Nru gromacs-4.5.4/src/mdlib/coupling.c gromacs-4.5.5/src/mdlib/coupling.c --- gromacs-4.5.4/src/mdlib/coupling.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/coupling.c 2011-09-21 12:34:32.000000000 +0000 @@ -59,8 +59,8 @@ { /* general routine for both barostat and thermostat nose hoover chains */ - int i,j,mi,mj,jmax,nd; - double Ekin,Efac,reft,kT; + int i,j,mi,mj,jmax; + double Ekin,Efac,reft,kT,nd; double dt; t_grp_tcstat *tcstat; double *ivxi,*ixi; diff -Nru gromacs-4.5.4/src/mdlib/domdec.c gromacs-4.5.5/src/mdlib/domdec.c --- gromacs-4.5.4/src/mdlib/domdec.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/domdec.c 2011-09-21 12:34:32.000000000 +0000 @@ -6078,11 +6078,11 @@ case edlbNO: break; case edlbAUTO: - dd_warning(cr,fplog,"NOTE: reproducability requested, will not use dynamic load balancing\n"); + dd_warning(cr,fplog,"NOTE: reproducibility requested, will not use dynamic load balancing\n"); eDLB = edlbNO; break; case edlbYES: - dd_warning(cr,fplog,"WARNING: reproducability requested with dynamic load balancing, the simulation will NOT be binary reproducable\n"); + dd_warning(cr,fplog,"WARNING: reproducibility requested with dynamic load balancing, the simulation will NOT be binary reproducible\n"); break; default: gmx_fatal(FARGS,"Death horror: undefined case (%d) for load balancing choice",eDLB); @@ -6459,7 +6459,7 @@ if (cr->npmenodes > dd->nnodes) { gmx_fatal_collective(FARGS,cr,NULL, - "The number of separate PME node (%d) is larger than the number of PP nodes (%d), this is not supported.",cr->npmenodes,dd->nnodes); + "The number of separate PME nodes (%d) is larger than the number of PP nodes (%d), this is not supported.",cr->npmenodes,dd->nnodes); } if (cr->npmenodes > 0) { diff -Nru gromacs-4.5.4/src/mdlib/domdec_setup.c gromacs-4.5.5/src/mdlib/domdec_setup.c --- gromacs-4.5.4/src/mdlib/domdec_setup.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/domdec_setup.c 2011-09-21 12:34:32.000000000 +0000 @@ -37,6 +37,11 @@ { int d,ndiv; + if (n <= 0) + { + gmx_fatal(FARGS, "Can only factorize positive integers."); + } + /* Decompose n in factors */ snew(*fac,n/2); snew(*mfac,n/2); @@ -270,6 +275,19 @@ ir->ePBC==epbcXYZ && ir->ewald_geometry==eewg3DC); } +/* Avoid integer overflows */ +static float comm_pme_cost_vol(int npme, int a, int b, int c) +{ + float comm_vol; + + comm_vol = npme - 1; + comm_vol *= npme; + comm_vol *= div_up(a, npme); + comm_vol *= div_up(b, npme); + comm_vol *= c; + return comm_vol; +} + static float comm_cost_est(gmx_domdec_t *dd,real limit,real cutoff, matrix box,gmx_ddbox_t *ddbox, int natoms,t_inputrec *ir, @@ -287,6 +305,7 @@ */ float pbcdx_rect_fac = 0.1; float pbcdx_tric_fac = 0.2; + float temp; /* Check the DD algorithm restrictions */ if ((ir->ePBC == epbcXY && ir->nwall < 2 && nc[ZZ] > 1) || @@ -410,7 +429,14 @@ { nk = (i==0 ? ir->nkx : ir->nky); overlap = (nk % npme[i] == 0 ? ir->pme_order-1 : ir->pme_order); - comm_pme += npme[i]*overlap*ir->nkx*ir->nky*ir->nkz/nk; + temp = npme[i]; + temp *= overlap; + temp *= ir->nkx; + temp *= ir->nky; + temp *= ir->nkz; + temp /= nk; + comm_pme += temp; +/* Old line comm_pme += npme[i]*overlap*ir->nkx*ir->nky*ir->nkz/nk; */ } } @@ -420,8 +446,8 @@ * are similar and therefore these formulas also prefer load balance * in the FFT and pme_solve calculation. */ - comm_pme += (npme[YY] - 1)*npme[YY]*div_up(ir->nky,npme[YY])*div_up(ir->nkz,npme[YY])*ir->nkx; - comm_pme += (npme[XX] - 1)*npme[XX]*div_up(ir->nkx,npme[XX])*div_up(ir->nky,npme[XX])*ir->nkz; + comm_pme += comm_pme_cost_vol(npme[YY], ir->nky, ir->nkz, ir->nkx); + comm_pme += comm_pme_cost_vol(npme[XX], ir->nkx, ir->nky, ir->nkz); /* Add cost of pbc_dx for bondeds */ cost_pbcdx = 0; @@ -635,34 +661,53 @@ real cellsize_limit,real cutoff_dd, gmx_bool bInterCGBondeds,gmx_bool bInterCGMultiBody) { - int npme,nkx,nky; - int ldiv; + int nnodes_div,ldiv; real limit; if (MASTER(cr)) { + nnodes_div = cr->nnodes; + if (EEL_PME(ir->coulombtype)) + { + if (cr->npmenodes > 0) + { + if (cr->nnodes <= 2) + { + gmx_fatal(FARGS, + "Can not have separate PME nodes with 2 or less nodes"); + } + if (cr->npmenodes >= cr->nnodes) + { + gmx_fatal(FARGS, + "Can not have %d separate PME nodes with just %d total nodes", + cr->npmenodes, cr->nnodes); + } + + /* If the user purposely selected the number of PME nodes, + * only check for large primes in the PP node count. + */ + nnodes_div -= cr->npmenodes; + } + } + else + { + cr->npmenodes = 0; + } + if (cr->nnodes > 12) { - ldiv = largest_divisor(cr->nnodes); + ldiv = largest_divisor(nnodes_div); /* Check if the largest divisor is more than nnodes^2/3 */ - if (ldiv*ldiv*ldiv > cr->nnodes*cr->nnodes) + if (ldiv*ldiv*ldiv > nnodes_div*nnodes_div) { gmx_fatal(FARGS,"The number of nodes you selected (%d) contains a large prime factor %d. In most cases this will lead to bad performance. Choose a number with smaller prime factors or set the decomposition (option -dd) manually.", - cr->nnodes,ldiv); + nnodes_div,ldiv); } } if (EEL_PME(ir->coulombtype)) { - if (cr->npmenodes >= 0) - { - if (cr->nnodes <= 2 && cr->npmenodes > 0) - { - gmx_fatal(FARGS, - "Can not have separate PME nodes with 2 or less nodes"); - } - } - else + if (cr->npmenodes < 0) { if (cr->nnodes <= 10) { @@ -678,13 +723,6 @@ fprintf(fplog,"Using %d separate PME nodes\n",cr->npmenodes); } } - else - { - if (cr->npmenodes < 0) - { - cr->npmenodes = 0; - } - } limit = optimize_ncells(fplog,cr->nnodes,cr->npmenodes, bDynLoadBal,dlb_scale, diff -Nru gromacs-4.5.4/src/mdlib/domdec_top.c gromacs-4.5.5/src/mdlib/domdec_top.c --- gromacs-4.5.4/src/mdlib/domdec_top.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/domdec_top.c 2011-09-21 12:34:32.000000000 +0000 @@ -1889,7 +1889,7 @@ { /* We copy the coordinates so the original coordinates remain * unchanged, just to be 100% sure that we do not affect - * binary reproducability of simulations. + * binary reproducibility of simulations. */ n = molt->cgs.index[molt->cgs.nr]; for(i=0; irefproj[i]-vec->xproj[i]),2); } vec->radius=sqrt(rad); - + /* Add average positions */ - for (i = 0; i < edi->sav.nr; i++) + for (i = 0; i < edi->sav.nr; i++) rvec_inc(x[i], edi->sav.x[i]); } -/* Project vector x, subtract average positions prior to projection and add +/* Project vector x, subtract average positions prior to projection and add * them afterwards to retain the unchanged vector. Store in xproj. Mass-weighting * is applied. */ -static void project_to_eigvectors(rvec *x, /* The positions to project to an eigenvector */ +static void project_to_eigvectors(rvec *x, /* The positions to project to an eigenvector */ t_eigvec *vec, /* The eigenvectors */ t_edpar *edi) { @@ -276,20 +279,20 @@ if (!vec->neig) return; /* Subtract average positions */ - for (i=0; isav.nr; i++) + for (i=0; isav.nr; i++) rvec_dec(x[i], edi->sav.x[i]); for (i=0; ineig; i++) vec->xproj[i] = projectx(edi, x, vec->vec[i]); /* Add average positions */ - for (i=0; isav.nr; i++) + for (i=0; isav.nr; i++) rvec_inc(x[i], edi->sav.x[i]); } /* Project vector x onto all edi->vecs (mon, linfix,...) */ -static void project(rvec *x, /* positions to project */ +static void project(rvec *x, /* positions to project */ t_edpar *edi) /* edi data set */ { /* It is not more work to subtract the average position in every @@ -309,7 +312,7 @@ real rad=0.0; - for (i=0; ineig; i++) + for (i=0; ineig; i++) rad += pow((vec->refproj[i]-vec->xproj[i]),2); return rad=sqrt(rad); @@ -318,7 +321,7 @@ /* Debug helper */ #ifdef DEBUGHELPERS -static void dump_xcoll(t_edpar *edi, struct t_do_edsam *buf, t_commrec *cr, +static void dump_xcoll(t_edpar *edi, struct t_do_edsam *buf, t_commrec *cr, int step) { int i; @@ -327,22 +330,22 @@ rvec *xcoll; ivec *shifts, *eshifts; - + if (!MASTER(cr)) return; - + xcoll = buf->xcoll; shifts = buf->shifts_xcoll; eshifts = buf->extra_shifts_xcoll; - + sprintf(fn, "xcolldump_step%d.txt", step); fp = fopen(fn, "w"); - + for (i=0; isav.nr; i++) - fprintf(fp, "%d %9.5f %9.5f %9.5f %d %d %d %d %d %d\n", - edi->sav.anrs[i]+1, + fprintf(fp, "%d %9.5f %9.5f %9.5f %d %d %d %d %d %d\n", + edi->sav.anrs[i]+1, xcoll[i][XX] , xcoll[i][YY] , xcoll[i][ZZ], - shifts[i][XX] , shifts[i][YY] , shifts[i][ZZ], + shifts[i][XX] , shifts[i][YY] , shifts[i][ZZ], eshifts[i][XX], eshifts[i][YY], eshifts[i][ZZ]); fclose(fp); @@ -354,7 +357,7 @@ { int i; - + fprintf(out, "#%s positions:\n%d\n", name, s->nr); if (s->nr == 0) return; @@ -362,7 +365,7 @@ fprintf(out, "#index, x, y, z"); if (s->sqrtm) fprintf(out, ", sqrt(m)"); - for (i=0; inr; i++) + for (i=0; inr; i++) { fprintf(out, "\n%6d %11.6f %11.6f %11.6f",s->anrs[i], s->x[i][XX], s->x[i][YY], s->x[i][ZZ]); if (s->sqrtm) @@ -378,12 +381,12 @@ { int i,j; - + fprintf(out, "#%s eigenvectors:\n%d\n", name, ev->neig); /* Dump the data for every eigenvector: */ for (i=0; ineig; i++) { - fprintf(out, "EV %4d\ncomponents %d\nstepsize %f\nxproj %f\nfproj %f\nrefproj %f\nradius %f\nComponents:\n", + fprintf(out, "EV %4d\ncomponents %d\nstepsize %f\nxproj %f\nfproj %f\nrefproj %f\nradius %f\nComponents:\n", ev->ieig[i], length, ev->stpsz[i], ev->xproj[i], ev->fproj[i], ev->refproj[i], ev->radius); for (j=0; jvec[i][j][XX], ev->vec[i][j][YY], ev->vec[i][j][ZZ]); @@ -445,11 +448,11 @@ /* Debug helper */ -static void dump_rvec(FILE *out, int dim, rvec *x) +static void dump_rvec(FILE *out, int dim, rvec *x) { int i; - + for (i=0; ibuf->do_edfit; - if (bFirst) + if (bFirst) { snew(loc->omega,2*DIM); snew(loc->om,2*DIM); @@ -597,11 +600,11 @@ } -static void rmfit(int nat, rvec *xcoll, rvec transvec, matrix rotmat) +static void rmfit(int nat, rvec *xcoll, rvec transvec, matrix rotmat) { rvec vec; matrix tmat; - + /* Remove rotation. * The inverse rotation is described by the transposed rotation matrix */ @@ -619,19 +622,19 @@ /********************************************************************************** ******************** FLOODING **************************************************** ********************************************************************************** - -The flooding ability was added later to edsam. Many of the edsam functionality could be reused for that purpose. -The flooding covariance matrix, i.e. the selected eigenvectors and their corresponding eigenvalues are -read as 7th Component Group. The eigenvalues are coded into the stepsize parameter (as used by -linfix or -linacc). + +The flooding ability was added later to edsam. Many of the edsam functionality could be reused for that purpose. +The flooding covariance matrix, i.e. the selected eigenvectors and their corresponding eigenvalues are +read as 7th Component Group. The eigenvalues are coded into the stepsize parameter (as used by -linfix or -linacc). do_md clls right in the beginning the function init_edsam, which reads the edi file, saves all the necessary information in the edi structure and calls init_flood, to initialise some extra fields in the edi->flood structure. -since the flooding acts on forces do_flood is called from the function force() (force.c), while the other +since the flooding acts on forces do_flood is called from the function force() (force.c), while the other edsam functionality is hooked into md via the update() (update.c) function acting as constraint on positions. do_flood makes a copy of the positions, -fits them, projects them computes flooding_energy, and flooding forces. The forces are computed in the +fits them, projects them computes flooding_energy, and flooding forces. The forces are computed in the space of the eigenvectors and are then blown up to the full cartesian space and rotated back to remove the fit. Then do_flood adds these forces to the forcefield-forces (given as parameter) and updates the adaptive flooding parameters Efl and deltaF. @@ -645,28 +648,28 @@ signs of alpha2 and Efl, such that the sign in the exponential of Vfl is not inverted but the sign of Vfl is inverted. Vfl = Efl * exp (- .../Efl/alpha2*x^2...) With tau>0 the negative Efl will grow slowly so that the restraint is switched off slowly. When Efl==0 and inverted flooding is ON is reached no - further adaption is applied, Efl will stay constant at zero. + further adaption is applied, Efl will stay constant at zero. -To use restraints with harmonic potentials switch -restrain and -harmonic. Then the eigenvalues are -used as spring constants for the harmonic potential. +To use restraints with harmonic potentials switch -restrain and -harmonic. Then the eigenvalues are +used as spring constants for the harmonic potential. Note that eq3 in the flooding paper (J. Comp. Chem. 2006, 27, 1693-1702) defines the parameter lambda \ as the inverse of the spring constant, whereas the implementation uses lambda as the spring constant. To use more than one flooding matrix just concatenate several .edi files (cat flood1.edi flood2.edi > flood_all.edi) the routine read_edi_file reads all of theses flooding files. -The structure t_edi is now organized as a list of t_edis and the function do_flood cycles through the list -calling the do_single_flood() routine for every single entry. Since every state variables have been kept in one -edi there is no interdependence whatsoever. The forces are added together. +The structure t_edi is now organized as a list of t_edis and the function do_flood cycles through the list +calling the do_single_flood() routine for every single entry. Since every state variables have been kept in one +edi there is no interdependence whatsoever. The forces are added together. - To write energies into the .edr file, call the function + To write energies into the .edr file, call the function get_flood_enx_names(char**, int *nnames) to get the Header (Vfl1 Vfl2... Vfln) and call - get_flood_energies(real Vfl[],int nnames); + get_flood_energies(real Vfl[],int nnames); TODO: - one could program the whole thing such that Efl, Vfl and deltaF is written to the .edr file. -- i dont know how to do that, yet. - Maybe one should give a range of atoms for which to remove motion, so that motion is removed with + Maybe one should give a range of atoms for which to remove motion, so that motion is removed with two edsam files from two peptide chains */ @@ -676,7 +679,7 @@ char buf[22]; gmx_bool bOutputRef=FALSE; - + fprintf(fp,"%d.th FL: %s %12.5e %12.5e %12.5e\n", edi->flood.flood_id, gmx_step_str(step,buf), edi->flood.Efl, edi->flood.Vfl, edi->flood.deltaF); @@ -703,10 +706,10 @@ } } fprintf(fp,"FL_FORCES: "); - + for (i=0; iflood.vecs.neig; i++) fprintf(fp," %12.5e",edi->flood.vecs.fproj[i]); - + fprintf(fp,"\n"); } @@ -737,12 +740,15 @@ edi->flood.vecs.refproj[i] = edi->flood.vecs.refproj0[i] + step * edi->flood.vecs.refprojslope[i]; } } - + sum=0.0; /* Compute sum which will be the exponent of the exponential */ for (i=0; iflood.vecs.neig; i++) + { + /* stpsz stores the reciprocal eigenvalue 1/sigma_i */ sum += edi->flood.vecs.stpsz[i]*(edi->flood.vecs.xproj[i]-edi->flood.vecs.refproj[i])*(edi->flood.vecs.xproj[i]-edi->flood.vecs.refproj[i]); - + } + /* Compute the Gauss function*/ if (edi->flood.bHarmonic) { @@ -762,7 +768,7 @@ { /* compute the forces in the subspace of the flooding eigenvectors * by the formula F_i= V_{fl}(c) * ( \frac {kT} {E_{fl}} \lambda_i c_i */ - + int i; real energy=edi->flood.Vfl; @@ -785,31 +791,31 @@ static void flood_blowup(t_edpar *edi, rvec *forces_cart) { /* this function lifts the forces from the subspace to the cartesian space - all the values not contained in the subspace are assumed to be zero and then - a coordinate transformation from eigenvector to cartesian vectors is performed - The nonexistent values don't have to be set to zero explicitly, they would occur + all the values not contained in the subspace are assumed to be zero and then + a coordinate transformation from eigenvector to cartesian vectors is performed + The nonexistent values don't have to be set to zero explicitly, they would occur as zero valued summands, hence we just stop to compute this part of the sum. for every atom we add all the contributions to this atom from all the different eigenvectors. - NOTE: one could add directly to the forcefield forces, would mean we wouldn't have to clear the - field forces_cart prior the computation, but momentarily we want to compute the forces separately + NOTE: one could add directly to the forcefield forces, would mean we wouldn't have to clear the + field forces_cart prior the computation, but we compute the forces separately to have them accessible for diagnostics */ int j,eig; rvec dum; real *forces_sub; - - + + forces_sub = edi->flood.vecs.fproj; - - + + /* Calculate the cartesian forces for the local atoms */ - + /* Clear forces first */ - for (j=0; jsav.nr_loc; j++) + for (j=0; jsav.nr_loc; j++) clear_rvec(forces_cart[j]); - + /* Now compute atomwise */ for (j=0; jsav.nr_loc; j++) { @@ -828,8 +834,8 @@ /* Update the values of Efl, deltaF depending on tau and Vfl */ static void update_adaption(t_edpar *edi) { - /* this function updates the parameter Efl and deltaF according to the rules given in - * 'predicting unimolecular chemical reactions: chemical flooding' M Mueller et al, + /* this function updates the parameter Efl and deltaF according to the rules given in + * 'predicting unimolecular chemical reactions: chemical flooding' M Mueller et al, * J. chem Phys. */ if ((edi->flood.tau < 0 ? -edi->flood.tau : edi->flood.tau ) > 0.00000001) @@ -852,25 +858,25 @@ gmx_large_int_t step, matrix box, t_commrec *cr) -{ +{ int i; matrix rotmat; /* rotation matrix */ matrix tmat; /* inverse rotation */ rvec transvec; /* translation vector */ struct t_do_edsam *buf; - + buf=edi->buf->do_edsam; - + /* Broadcast the positions of the AVERAGE structure such that they are known on * every processor. Each node contributes its local positions x and stores them in - * the collective ED array buf->xcoll */ - communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, x, - edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); - + * the collective ED array buf->xcoll */ + communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, x, + edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); + /* Only assembly REFERENCE positions if their indices differ from the average ones */ if (!edi->bRefEqAv) - communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, x, + communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, x, edi->sref.nr, edi->sref.nr_loc, edi->sref.anrs_loc, edi->sref.c_ind, edi->sref.x_old, box); /* If bUpdateShifts was TRUE, the shifts have just been updated in get_positions. @@ -879,26 +885,29 @@ /* Now all nodes have all of the ED/flooding positions in edi->sav->xcoll, * as well as the indices in edi->sav.anrs */ - + /* Fit the reference indices to the reference structure */ if (edi->bRefEqAv) fit_to_reference(buf->xcoll , transvec, rotmat, edi); else fit_to_reference(buf->xc_ref, transvec, rotmat, edi); - + /* Now apply the translation and rotation to the ED structure */ translate_and_rotate(buf->xcoll, edi->sav.nr, transvec, rotmat); /* Project fitted structure onto supbspace -> store in edi->flood.vecs.xproj */ - project_to_eigvectors(buf->xcoll,&edi->flood.vecs,edi); - - /* Compute Vfl(x) from flood.xproj */ - edi->flood.Vfl = flood_energy(edi, step); - - update_adaption(edi); + project_to_eigvectors(buf->xcoll,&edi->flood.vecs,edi); + + if (FALSE == edi->flood.bConstForce) + { + /* Compute Vfl(x) from flood.xproj */ + edi->flood.Vfl = flood_energy(edi, step); - /* Compute the flooding forces */ - flood_forces(edi); + update_adaption(edi); + + /* Compute the flooding forces */ + flood_forces(edi); + } /* Translate them into cartesian positions */ flood_blowup(edi, edi->flood.forces_cartesian); @@ -930,10 +939,10 @@ { t_edpar *edi; - + if (ed->eEDtype != eEDflood) return; - + edi = ed->edpar; while (edi) { @@ -945,10 +954,13 @@ } -/* Called by init_edi, configure some flooding related variables and structures, +/* Called by init_edi, configure some flooding related variables and structures, * print headers to output files */ static void init_flood(t_edpar *edi, gmx_edsam_t ed, real dt, t_commrec *cr) { + int i; + + edi->flood.Efl = edi->flood.constEfl; edi->flood.Vfl = 0; edi->flood.dt = dt; @@ -957,12 +969,25 @@ { /* If in any of the datasets we find a flooding vector, flooding is turned on */ ed->eEDtype = eEDflood; - + + fprintf(stderr,"ED: Flooding of matrix %d is switched on.\n", edi->flood.flood_id); + + if (edi->flood.bConstForce) + { + /* We have used stpsz as a vehicle to carry the fproj values for constant + * force flooding. Now we copy that to flood.vecs.fproj. Note that + * in const force flooding, fproj is never changed. */ + for (i=0; iflood.vecs.neig; i++) + { + edi->flood.vecs.fproj[i] = edi->flood.vecs.stpsz[i]; + + fprintf(stderr, "ED: applying on eigenvector %d a constant force of %g\n", + edi->flood.vecs.ieig[i], edi->flood.vecs.fproj[i]); + } + } fprintf(ed->edo,"FL_HEADER: Flooding of matrix %d is switched on! The flooding output will have the following format:\n", edi->flood.flood_id); - fprintf(stderr,"ED: Flooding of matrix %d is switched on.\n", edi->flood.flood_id); - if (edi->flood.flood_id<1) - fprintf(ed->edo,"FL_HEADER: Step Efl Vfl deltaF\n"); + fprintf(ed->edo,"FL_HEADER: Step Efl Vfl deltaF\n"); } } @@ -994,7 +1019,7 @@ t_edpar *actual; int count; - + actual=edi; count = 1; while (actual) @@ -1003,7 +1028,7 @@ actual=actual->next_edi; count++; } - if (nnames!=count-1) + if (nnames!=count-1) gmx_fatal(FARGS,"Number of energies is not consistent with t_edi structure"); } /************* END of FLOODING IMPLEMENTATION ****************************/ @@ -1011,22 +1036,22 @@ gmx_edsam_t ed_open(int nfile,const t_filenm fnm[],unsigned long Flags,t_commrec *cr) -{ +{ gmx_edsam_t ed; - - + + /* Allocate space for the ED data structure */ snew(ed, 1); - + /* We want to perform ED (this switch might later be upgraded to eEDflood) */ ed->eEDtype = eEDedsam; - if (MASTER(cr)) + if (MASTER(cr)) { /* Open .edi input file: */ ed->edinam=ftp2fn(efEDI,nfile,fnm); /* The master opens the .edo output file */ - fprintf(stderr,"ED sampling will be performed!\n"); + fprintf(stderr,"ED sampling will be performed!\n"); ed->edonam = ftp2fn(efEDO,nfile,fnm); ed->edo = gmx_fio_fopen(ed->edonam,(Flags & MD_APPENDFILES)? "a+" : "w+"); ed->bStartFromCpt = Flags & MD_STARTFROMCPT; @@ -1049,10 +1074,10 @@ { /* We need these additional variables in the parallel case: */ snew(s->c_ind , s->nr ); /* Collective indices */ - /* Local atom indices get assigned in dd_make_local_group_indices. + /* Local atom indices get assigned in dd_make_local_group_indices. * There, also memory is allocated */ s->nalloc_loc = 0; /* allocation size of s->anrs_loc */ - snew_bc(cr, s->x_old, s->nr); /* To be able to always make the ED molecule whole, ... */ + snew_bc(cr, s->x_old, s->nr); /* To be able to always make the ED molecule whole, ... */ nblock_bc(cr, s->nr, s->x_old); /* ... keep track of shift changes with the help of old coords */ } @@ -1115,16 +1140,16 @@ { int nr; t_edpar *edi; - + /* Master lets the other nodes know if its ED only or also flooding */ gmx_bcast(sizeof(ed->eEDtype), &(ed->eEDtype), cr); - + snew_bc(cr, ed->edpar,1); /* Now transfer the ED data set(s) */ edi = ed->edpar; for (nr=0; nrvecs.radcon, edi->sav.nr, FALSE); /* Broadcast flooding eigenvectors and, if needed, values for the moving reference */ bc_ed_vecs(cr, &edi->flood.vecs, edi->sav.nr, edi->flood.bHarmonic); - + /* Set the pointer to the next ED dataset */ if (edi->next_edi) { @@ -1156,22 +1181,22 @@ /* init-routine called for every *.edi-cycle, initialises t_edpar structure */ static void init_edi(gmx_mtop_t *mtop,t_inputrec *ir, - t_commrec *cr,gmx_edsam_t ed,t_edpar *edi) + t_commrec *cr,gmx_edsam_t ed,t_edpar *edi) { int i; real totalmass = 0.0; rvec com; t_atom *atom; - /* NOTE Init_edi is executed on the master process only + /* NOTE Init_edi is executed on the master process only * The initialized data sets are then transmitted to the * other nodes in broadcast_ed_data */ - edi->bNeedDoEdsam = edi->vecs.mon.neig - || edi->vecs.linfix.neig - || edi->vecs.linacc.neig - || edi->vecs.radfix.neig - || edi->vecs.radacc.neig + edi->bNeedDoEdsam = edi->vecs.mon.neig + || edi->vecs.linfix.neig + || edi->vecs.linacc.neig + || edi->vecs.radfix.neig + || edi->vecs.radacc.neig || edi->vecs.radcon.neig; /* evaluate masses (reference structure) */ @@ -1187,11 +1212,22 @@ { edi->sref.m[i] = 1.0; } + + /* Check that every m > 0. Bad things will happen otherwise. */ + if (edi->sref.m[i] <= 0.0) + { + gmx_fatal(FARGS, "Reference structure atom %d (sam.edi index %d) has a mass of %g.\n" + "For a mass-weighted fit, all reference structure atoms need to have a mass >0.\n" + "Either make the covariance analysis non-mass-weighted, or exclude massless\n" + "atoms from the reference structure by creating a proper index group.\n", + i, edi->sref.anrs[i]+1, edi->sref.m[i]); + } + totalmass += edi->sref.m[i]; } edi->sref.mtot = totalmass; - /* Masses m and sqrt(m) for the average structure. Note that m + /* Masses m and sqrt(m) for the average structure. Note that m * is needed if forces have to be evaluated in do_edsam */ snew(edi->sav.sqrtm, edi->sav.nr ); snew(edi->sav.m , edi->sav.nr ); @@ -1207,6 +1243,16 @@ { edi->sav.sqrtm[i] = 1.0; } + + /* Check that every m > 0. Bad things will happen otherwise. */ + if (edi->sav.sqrtm[i] <= 0.0) + { + gmx_fatal(FARGS, "Average structure atom %d (sam.edi index %d) has a mass of %g.\n" + "For ED with mass-weighting, all average structure atoms need to have a mass >0.\n" + "Either make the covariance analysis non-mass-weighted, or exclude massless\n" + "atoms from the average structure by creating a proper index group.\n", + i, edi->sav.anrs[i]+1, atom->m); + } } /* put reference structure in origin */ @@ -1223,7 +1269,7 @@ static void check(const char *line, const char *label) { - if (!strstr(line,label)) + if (!strstr(line,label)) gmx_fatal(FARGS,"Could not find input parameter %s at expected position in edsam input-file (.edi)\nline read instead is %s",label,line); } @@ -1233,13 +1279,13 @@ char line[STRLEN+1]; int idum; - + fgets2 (line,STRLEN,file); check(line,label); fgets2 (line,STRLEN,file); sscanf (line,"%d",&idum); return idum; -} +} static int read_edint(FILE *file,gmx_bool *bEOF) @@ -1248,14 +1294,14 @@ int idum; char *eof; - + eof=fgets2 (line,STRLEN,file); if (eof==NULL) { *bEOF = TRUE; return -1; } - eof=fgets2 (line,STRLEN,file); + eof=fgets2 (line,STRLEN,file); if (eof==NULL) { *bEOF = TRUE; @@ -1272,7 +1318,7 @@ char line[STRLEN+1]; double rdum; - + fgets2 (line,STRLEN,file); check(line,label); fgets2 (line,STRLEN,file); @@ -1287,7 +1333,7 @@ char line[STRLEN+1]; double d[3]; - + for(i=0; ineig=read_checked_edint(in,"NUMBER OF EIGENVECTORS"); if (tvec->neig >0) { @@ -1349,9 +1395,12 @@ switch(nscan) { case 4: - /* Every 4 values read */ + /* Every 4 values read, including reference position */ + *bHaveReference = TRUE; break; case 3: + /* A reference position is provided */ + *bHaveReference = TRUE; /* No value for slope, set to 0 */ refprojslope_dum = 0.0; break; @@ -1390,12 +1439,15 @@ /* calls read_edvec for the vector groups, only for flooding there is an extra call */ static void read_edvecs(FILE *in,int nr,t_edvecs *vecs) { - read_edvec(in,nr,&vecs->mon ,FALSE); - read_edvec(in,nr,&vecs->linfix,FALSE); - read_edvec(in,nr,&vecs->linacc,FALSE); - read_edvec(in,nr,&vecs->radfix,FALSE); - read_edvec(in,nr,&vecs->radacc,FALSE); - read_edvec(in,nr,&vecs->radcon,FALSE); + gmx_bool bHaveReference = FALSE; + + + read_edvec(in, nr, &vecs->mon , FALSE, &bHaveReference); + read_edvec(in, nr, &vecs->linfix, FALSE, &bHaveReference); + read_edvec(in, nr, &vecs->linacc, FALSE, &bHaveReference); + read_edvec(in, nr, &vecs->radfix, FALSE, &bHaveReference); + read_edvec(in, nr, &vecs->radacc, FALSE, &bHaveReference); + read_edvec(in, nr, &vecs->radcon, FALSE, &bHaveReference); } @@ -1404,7 +1456,7 @@ { int i; - + /* If the number of atoms differs between the two structures, * they cannot be identical */ if (sref.nr != sav.nr) @@ -1426,10 +1478,13 @@ static int read_edi(FILE* in, gmx_edsam_t ed,t_edpar *edi,int nr_mdatoms, int edi_nr, t_commrec *cr) { int readmagic; - const int magic=669; + const int magic=670; gmx_bool bEOF; - + /* Was a specific reference point for the flooding/umbrella potential provided in the edi file? */ + gmx_bool bHaveReference = FALSE; + + /* the edi file is not free format, so expect problems if the input is corrupt. */ /* check the magic number */ @@ -1442,6 +1497,8 @@ { if (readmagic==666 || readmagic==667 || readmagic==668) gmx_fatal(FARGS,"Wrong magic number: Use newest version of make_edi to produce edi file"); + else if (readmagic == 669) + ; else gmx_fatal(FARGS,"Wrong magic number %d in %s",readmagic,ed->edinam); } @@ -1450,7 +1507,7 @@ edi->nini=read_edint(in,&bEOF); if (edi->nini != nr_mdatoms) gmx_fatal(FARGS,"Nr of atoms in %s (%d) does not match nr of md atoms (%d)", - ed->edinam,edi->nini,nr_mdatoms); + ed->edinam,edi->nini,nr_mdatoms); /* Done checking. For the rest we blindly trust the input */ edi->fitmas = read_checked_edint(in,"FITMAS"); @@ -1467,6 +1524,10 @@ edi->flood.alpha2 = read_checked_edreal(in,"ALPHA2"); edi->flood.kT = read_checked_edreal(in,"KT"); edi->flood.bHarmonic = read_checked_edint(in,"HARMONIC"); + if (readmagic > 669) + edi->flood.bConstForce = read_checked_edint(in,"CONST_FORCE_FLOODING"); + else + edi->flood.bConstForce = FALSE; edi->flood.flood_id = edi_nr; edi->sref.nr = read_checked_edint(in,"NREF"); @@ -1491,7 +1552,7 @@ /* eigenvectors */ read_edvecs(in,edi->sav.nr,&edi->vecs); - read_edvec(in,edi->sav.nr,&edi->flood.vecs,edi->flood.bHarmonic); + read_edvec(in,edi->sav.nr,&edi->flood.vecs,edi->flood.bHarmonic, &bHaveReference); /* target positions */ edi->star.nr=read_edint(in,&bEOF); @@ -1507,12 +1568,19 @@ edi->sori.nr=read_edint(in,&bEOF); if (edi->sori.nr > 0) { + if (bHaveReference) + { + /* Both an -ori structure and a at least one manual reference point have been + * specified. That's ambiguous and probably not intentional. */ + gmx_fatal(FARGS, "ED: An origin structure has been provided and a at least one (moving) reference\n" + " point was manually specified in the edi file. That is ambiguous. Aborting.\n"); + } snew(edi->sori.anrs,edi->sori.nr); snew(edi->sori.x ,edi->sori.nr); edi->sori.sqrtm =NULL; read_edx(in,edi->sori.nr,edi->sori.anrs,edi->sori.x); } - + /* all done */ return 1; } @@ -1522,18 +1590,18 @@ /* Read in the edi input file. Note that it may contain several ED data sets which were * achieved by concatenating multiple edi files. The standard case would be a single ED * data set, though. */ -static void read_edi_file(gmx_edsam_t ed, t_edpar *edi, int nr_mdatoms, t_commrec *cr) +static void read_edi_file(gmx_edsam_t ed, t_edpar *edi, int nr_mdatoms, t_commrec *cr) { FILE *in; t_edpar *curr_edi,*last_edi; t_edpar *edi_read; int edi_nr = 0; - + /* This routine is executed on the master only */ /* Open the .edi parameter input file */ - in = gmx_fio_fopen(ed->edinam,"r"); + in = gmx_fio_fopen(ed->edinam,"r"); fprintf(stderr, "ED: Reading edi file %s\n", ed->edinam); /* Now read a sequence of ED input parameter sets from the edi file */ @@ -1544,7 +1612,7 @@ edi_nr++; /* Make shure that the number of atoms in each dataset is the same as in the tpr file */ if (edi->nini != nr_mdatoms) - gmx_fatal(FARGS,"edi file %s (dataset #%d) was made for %d atoms, but the simulation contains %d atoms.", + gmx_fatal(FARGS,"edi file %s (dataset #%d) was made for %d atoms, but the simulation contains %d atoms.", ed->edinam, edi_nr, edi->nini, nr_mdatoms); /* Since we arrived within this while loop we know that there is still another data set to be read in */ /* We need to allocate space for the data: */ @@ -1555,15 +1623,15 @@ last_edi = curr_edi; /* Let's prepare to read in the next edi data set: */ curr_edi = edi_read; - } - if (edi_nr == 0) + } + if (edi_nr == 0) gmx_fatal(FARGS, "No complete ED data set found in edi file %s.", ed->edinam); /* Terminate the edi dataset list with a NULL pointer: */ last_edi->next_edi = NULL; fprintf(stderr, "ED: Found %d ED dataset%s.\n", edi_nr, edi_nr>1? "s" : ""); - + /* Close the .edi file again */ gmx_fio_fclose(in); } @@ -1573,19 +1641,19 @@ rvec *xcopy; /* Working copy of the positions in fit_to_reference */ }; -/* Fit the current positions to the reference positions +/* Fit the current positions to the reference positions * Do not actually do the fit, just return rotation and translation. - * Note that the COM of the reference structure was already put into + * Note that the COM of the reference structure was already put into * the origin by init_edi. */ static void fit_to_reference(rvec *xcoll, /* The positions to be fitted */ - rvec transvec, /* The translation vector */ + rvec transvec, /* The translation vector */ matrix rotmat, /* The rotation matrix */ t_edpar *edi) /* Just needed for do_edfit */ { rvec com; /* center of mass */ int i; struct t_fit_to_ref *loc; - + GMX_MPE_LOG(ev_fit_to_reference_start); @@ -1596,7 +1664,7 @@ snew(edi->buf->fit_to_ref->xcopy, edi->sref.nr); } loc = edi->buf->fit_to_ref; - + /* We do not touch the original positions but work on a copy. */ for (i=0; isref.nr; i++) copy_rvec(xcoll[i], loc->xcopy[i]); @@ -1620,7 +1688,7 @@ static void translate_and_rotate(rvec *x, /* The positions to be translated and rotated */ int nat, /* How many positions are there? */ - rvec transvec, /* The translation vector */ + rvec transvec, /* The translation vector */ matrix rotmat) /* The rotation matrix */ { /* Translation */ @@ -1633,7 +1701,7 @@ /* Gets the rms deviation of the positions to the structure s */ /* fit_to_structure has to be called before calling this routine! */ -static real rmsd_from_structure(rvec *x, /* The positions under consideration */ +static real rmsd_from_structure(rvec *x, /* The positions under consideration */ struct gmx_edx *s) /* The structure from which the rmsd shall be computed */ { real rmsd=0.0; @@ -1654,7 +1722,7 @@ { t_edpar *edi; - + if (ed->eEDtype != eEDnone) { /* Loop over ED datasets (usually there is just one dataset, though) */ @@ -1666,15 +1734,15 @@ if (!edi->bRefEqAv) dd_make_local_group_indices(dd->ga2la, edi->sref.nr, edi->sref.anrs, &edi->sref.nr_loc, &edi->sref.anrs_loc, &edi->sref.nalloc_loc, edi->sref.c_ind); - + /* Local atoms of the average structure (on these ED will be performed) */ dd_make_local_group_indices(dd->ga2la, edi->sav.nr, edi->sav.anrs, &edi->sav.nr_loc, &edi->sav.anrs_loc, &edi->sav.nalloc_loc, edi->sav.c_ind); - /* Indicate that the ED shift vectors for this structure need to be updated + /* Indicate that the ED shift vectors for this structure need to be updated * at the next call to communicate_group_positions, since obviously we are in a NS step */ edi->buf->do_edsam->bUpdateShifts = TRUE; - + /* Set the pointer to the next ED dataset (if any) */ edi=edi->next_edi; } @@ -1694,7 +1762,7 @@ tz=is[ZZ]; if(TRICLINIC(box)) - { + { xu[XX] = x[XX]-tx*box[XX][XX]-ty*box[YY][XX]-tz*box[ZZ][XX]; xu[YY] = x[YY]-ty*box[YY][YY]-tz*box[ZZ][YY]; xu[ZZ] = x[ZZ]-tz*box[ZZ][ZZ]; @@ -1783,7 +1851,7 @@ rvec vec_dum; - if (edi->vecs.radfix.neig == 0) + if (edi->vecs.radfix.neig == 0) return; snew(proj, edi->vecs.radfix.neig); @@ -1825,7 +1893,7 @@ rvec vec_dum; - if (edi->vecs.radacc.neig == 0) + if (edi->vecs.radacc.neig == 0) return; snew(proj,edi->vecs.radacc.neig); @@ -1845,7 +1913,7 @@ ratio = edi->vecs.radacc.radius/rad - 1.0; rad = edi->vecs.radacc.radius; } - else + else edi->vecs.radacc.radius = rad; /* loop over radacc vectors */ @@ -1861,7 +1929,7 @@ svmul(proj[i], edi->vecs.radacc.vec[i][j], vec_dum); rvec_inc(xcoll[j], vec_dum); } - } + } sfree(proj); } @@ -1883,7 +1951,7 @@ { bFirst = FALSE; loc = edi->buf->do_radcon; - } + } else { bFirst = TRUE; @@ -1891,7 +1959,7 @@ } loc = edi->buf->do_radcon; - if (edi->vecs.radcon.neig == 0) + if (edi->vecs.radcon.neig == 0) return; if (bFirst) @@ -1917,7 +1985,7 @@ loc->proj[i] -= edi->vecs.radcon.refproj[i]; loc->proj[i] /= edi->sav.sqrtm[i]; loc->proj[i] *= ratio; - + for (j=0; jsav.nr; j++) { svmul(loc->proj[i], edi->vecs.radcon.vec[i][j], vec_dum); @@ -1954,16 +2022,16 @@ rvec_dec(xcoll[i], edi->sav.x[i]); /* apply the constraints */ - if (step >= 0) + if (step >= 0) do_linfix(xcoll, edi, step, cr); do_linacc(xcoll, edi, cr); - if (step >= 0) + if (step >= 0) do_radfix(xcoll, edi, step, cr); do_radacc(xcoll, edi, cr); do_radcon(xcoll, edi, cr); /* add back the average positions */ - for (i=0; isav.nr; i++) + for (i=0; isav.nr; i++) rvec_inc(xcoll[i], edi->sav.x[i]); GMX_MPE_LOG(ev_ed_apply_cons_finish); @@ -1972,11 +2040,11 @@ /* Write out the projections onto the eigenvectors */ static void write_edo(int nr_edi, t_edpar *edi, gmx_edsam_t ed, gmx_large_int_t step,real rmsd) -{ +{ int i; char buf[22]; - + if (edi->bNeedDoEdsam) { if (step == -1) @@ -1985,8 +2053,6 @@ { fprintf(ed->edo,"Step %s, ED #%d ", gmx_step_str(step, buf), nr_edi); fprintf(ed->edo," RMSD %f nm\n",rmsd); - if (ed->eEDtype == eEDflood) - fprintf(ed->edo, " Efl=%f deltaF=%f Vfl=%f\n",edi->flood.Efl,edi->flood.deltaF,edi->flood.Vfl); } if (edi->vecs.mon.neig) @@ -2039,17 +2105,31 @@ /* Returns if any constraints are switched on */ static int ed_constraints(gmx_bool edtype, t_edpar *edi) -{ - if (edtype == eEDedsam || edtype == eEDflood) +{ + if (edtype == eEDedsam || edtype == eEDflood) { - return (edi->vecs.linfix.neig || edi->vecs.linacc.neig || - edi->vecs.radfix.neig || edi->vecs.radacc.neig || + return (edi->vecs.linfix.neig || edi->vecs.linacc.neig || + edi->vecs.radfix.neig || edi->vecs.radacc.neig || edi->vecs.radcon.neig); - } + } return 0; } +/* Copies reference projection 'refproj' to fixed 'refproj0' variable for flooding/ + * umbrella sampling simulations. */ +static void copyEvecReference(t_eigvec* floodvecs) +{ + int i; + + + for (i=0; ineig; i++) + { + floodvecs->refproj0[i] = floodvecs->refproj[i]; + } +} + + void init_edsam(gmx_mtop_t *mtop, /* global topology */ t_inputrec *ir, /* input record */ t_commrec *cr, /* communication record */ @@ -2065,7 +2145,7 @@ rvec *xstart = NULL; /* the positions which are subject to ED sampling */ rvec fit_transvec; /* translation ... */ matrix fit_rotmat; /* ... and rotation from fit to reference structure */ - + if (!DOMAINDECOMP(cr) && PAR(cr) && MASTER(cr)) gmx_fatal(FARGS, "Please switch on domain decomposition to use essential dynamics in parallel."); @@ -2074,7 +2154,7 @@ if (MASTER(cr)) fprintf(stderr, "ED: Initializing essential dynamics constraints.\n"); - + /* Needed for initializing radacc radius in do_edsam */ ed->bFirst = 1; @@ -2087,15 +2167,15 @@ /* Read the whole edi file at once: */ read_edi_file(ed,ed->edpar,mtop->natoms,cr); - /* Initialization for every ED/flooding dataset. Flooding uses one edi dataset per + /* Initialization for every ED/flooding dataset. Flooding uses one edi dataset per * flooding vector, Essential dynamics can be applied to more than one structure - * as well, but will be done in the order given in the edi file, so + * as well, but will be done in the order given in the edi file, so * expect different results for different order of edi file concatenation! */ edi=ed->edpar; while(edi != NULL) { init_edi(mtop,ir,cr,ed,edi); - + /* Init flooding parameters if needed */ init_flood(edi,ed,ir->delta_t,cr); @@ -2104,7 +2184,7 @@ } } - /* The master does the work here. The other nodes get the positions + /* The master does the work here. The other nodes get the positions * not before dd_partition_system which is called after init_edsam */ if (MASTER(cr)) { @@ -2117,11 +2197,11 @@ /* Reset pointer to first ED data set which contains the actual ED data */ edi=ed->edpar; - + /* Loop over all ED/flooding data sets (usually only one, though) */ for (nr_edi = 1; nr_edi <= numedis; nr_edi++) { - /* We use srenew to allocate memory since the size of the buffers + /* We use srenew to allocate memory since the size of the buffers * is likely to change with every ED dataset */ srenew(xfit , edi->sref.nr ); srenew(xstart, edi->sav.nr ); @@ -2130,29 +2210,29 @@ for (i=0; i < edi->sref.nr; i++) { copy_rvec(x_pbc[edi->sref.anrs[i]], xfit[i]); - - /* Save the sref positions such that in the next time step the molecule can + + /* Save the sref positions such that in the next time step the molecule can * be made whole again (in the parallel case) */ if (PAR(cr)) copy_rvec(xfit[i], edi->sref.x_old[i]); } - + /* Extract the positions of the atoms subject to ED sampling */ for (i=0; i < edi->sav.nr; i++) { copy_rvec(x_pbc[edi->sav.anrs[i]], xstart[i]); - /* Save the sav positions such that in the next time step the molecule can + /* Save the sav positions such that in the next time step the molecule can * be made whole again (in the parallel case) */ if (PAR(cr)) copy_rvec(xstart[i], edi->sav.x_old[i]); } - + /* Make the fit to the REFERENCE structure, get translation and rotation */ fit_to_reference(xfit, fit_transvec, fit_rotmat, edi); /* Output how well we fit to the reference at the start */ - translate_and_rotate(xfit, edi->sref.nr, fit_transvec, fit_rotmat); + translate_and_rotate(xfit, edi->sref.nr, fit_transvec, fit_rotmat); fprintf(stderr, "ED: Initial RMSD from reference after fit = %f nm (dataset #%d)\n", rmsd_from_structure(xfit, &edi->sref), nr_edi); @@ -2175,7 +2255,7 @@ rad_project(edi, xstart, &edi->vecs.radcon, cr); /* process structure that will serve as origin of expansion circle */ - if (eEDflood == ed->eEDtype) + if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) fprintf(stderr, "ED: Setting center of flooding potential (0 = average structure)\n"); if (edi->sori.nr > 0) { @@ -2186,18 +2266,21 @@ translate_and_rotate(edi->sori.x, edi->sav.nr, fit_transvec, fit_rotmat); rad_project(edi, edi->sori.x, &edi->vecs.radacc, cr); rad_project(edi, edi->sori.x, &edi->vecs.radfix, cr); - if (ed->eEDtype == eEDflood) + if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) { fprintf(stderr, "ED: The ORIGIN structure will define the flooding potential center.\n"); /* Set center of flooding potential to the ORIGIN structure */ rad_project(edi, edi->sori.x, &edi->flood.vecs, cr); + /* We already know that no (moving) reference position was provided, + * therefore we can overwrite refproj[0]*/ + copyEvecReference(&edi->flood.vecs); } } else /* No origin structure given */ { rad_project(edi, xstart, &edi->vecs.radacc, cr); rad_project(edi, xstart, &edi->vecs.radfix, cr); - if (ed->eEDtype == eEDflood) + if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) { if (edi->flood.bHarmonic) { @@ -2216,12 +2299,14 @@ } } /* For convenience, output the center of the flooding potential for the eigenvectors */ - if (eEDflood == ed->eEDtype) + if ( (eEDflood == ed->eEDtype) && (FALSE == edi->flood.bConstForce) ) { for (i=0; iflood.vecs.neig; i++) { - fprintf(stdout, "ED: EV %d flooding potential center: %11.4e (adding %11.4e/timestep)\n", - i, edi->flood.vecs.refproj[i], edi->flood.vecs.refprojslope[i]); + fprintf(stdout, "ED: EV %d flooding potential center: %11.4e", i, edi->flood.vecs.refproj[i]); + if (edi->flood.bHarmonic) + fprintf(stdout, " (adding %11.4e/timestep)", edi->flood.vecs.refprojslope[i]); + fprintf(stdout, "\n"); } } @@ -2234,15 +2319,15 @@ write_edo(nr_edi, edi, ed, -1, 0); /* Prepare for the next edi data set: */ - edi=edi->next_edi; + edi=edi->next_edi; } /* Cleaning up on the master node: */ sfree(x_pbc); sfree(xfit); sfree(xstart); - + } /* end of MASTER only section */ - + if (PAR(cr)) { /* First let everybody know how many ED data sets to expect */ @@ -2252,9 +2337,9 @@ } else { - /* In the single-CPU case, point the local atom numbers pointers to the global + /* In the single-CPU case, point the local atom numbers pointers to the global * one, so that we can use the same notation in serial and parallel case: */ - + /* Loop over all ED data sets (usually only one, though) */ edi=ed->edpar; for (nr_edi = 1; nr_edi <= numedis; nr_edi++) @@ -2302,8 +2387,8 @@ /* Collective positions of atoms with the average indices */ snew(edi->buf->do_edsam->xcoll , edi->sav.nr); - snew(edi->buf->do_edsam->shifts_xcoll , edi->sav.nr); /* buffer for xcoll shifts */ - snew(edi->buf->do_edsam->extra_shifts_xcoll , edi->sav.nr); + snew(edi->buf->do_edsam->shifts_xcoll , edi->sav.nr); /* buffer for xcoll shifts */ + snew(edi->buf->do_edsam->extra_shifts_xcoll , edi->sav.nr); /* Collective positions of atoms with the reference indices */ if (!edi->bRefEqAv) { @@ -2311,7 +2396,7 @@ snew(edi->buf->do_edsam->shifts_xc_ref , edi->sref.nr); /* To store the shifts in */ snew(edi->buf->do_edsam->extra_shifts_xc_ref, edi->sref.nr); } - + /* Get memory for flooding forces */ snew(edi->flood.forces_cartesian , edi->sav.nr); @@ -2323,8 +2408,8 @@ /* An on we go to the next edi dataset */ edi=edi->next_edi; } - - /* Flush the edo file so that the user can check some things + + /* Flush the edo file so that the user can check some things * when the simulation has started */ if (ed->edo) fflush(ed->edo); @@ -2361,11 +2446,11 @@ * two-step sd2 integrator is used */ if ( (ir->eI==eiSD2) && (v != NULL) ) bSuppress = TRUE; - + dt_1 = 1.0/ir->delta_t; - + /* Loop over all ED datasets (usually one) */ - edi = ed->edpar; + edi = ed->edpar; edinr = 0; while (edi != NULL) { @@ -2379,29 +2464,29 @@ /* initialise radacc radius for slope criterion */ buf->oldrad=calc_radius(&edi->vecs.radacc); - /* Copy the positions into buf->xc* arrays and after ED + /* Copy the positions into buf->xc* arrays and after ED * feed back corrections to the official positions */ /* Broadcast the ED positions such that every node has all of them * Every node contributes its local positions xs and stores it in * the collective buf->xcoll array. Note that for edinr > 1 * xs could already have been modified by an earlier ED */ - - communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, xs, - edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); + + communicate_group_positions(cr, buf->xcoll, buf->shifts_xcoll, buf->extra_shifts_xcoll, buf->bUpdateShifts, xs, + edi->sav.nr, edi->sav.nr_loc, edi->sav.anrs_loc, edi->sav.c_ind, edi->sav.x_old, box); #ifdef DEBUG_ED dump_xcoll(edi, buf, cr, step); #endif /* Only assembly reference positions if their indices differ from the average ones */ if (!edi->bRefEqAv) - communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, xs, + communicate_group_positions(cr, buf->xc_ref, buf->shifts_xc_ref, buf->extra_shifts_xc_ref, buf->bUpdateShifts, xs, edi->sref.nr, edi->sref.nr_loc, edi->sref.anrs_loc, edi->sref.c_ind, edi->sref.x_old, box); - + /* If bUpdateShifts was TRUE then the shifts have just been updated in get_positions. * We do not need to uptdate the shifts until the next NS step */ buf->bUpdateShifts = FALSE; - + /* Now all nodes have all of the ED positions in edi->sav->xcoll, * as well as the indices in edi->sav.anrs */ @@ -2410,7 +2495,7 @@ fit_to_reference(buf->xcoll , transvec, rotmat, edi); else fit_to_reference(buf->xc_ref, transvec, rotmat, edi); - + /* Now apply the translation and rotation to the ED structure */ translate_and_rotate(buf->xcoll, edi->sav.nr, transvec, rotmat); @@ -2419,7 +2504,7 @@ { if (edi->bRefEqAv) { - /* Indices of reference and average structures are identical, + /* Indices of reference and average structures are identical, * thus we can calculate the rmsd to SREF using xcoll */ rmsdev = rmsd_from_structure(buf->xcoll,&edi->sref); } @@ -2468,7 +2553,7 @@ if (MASTER(cr) && !bSuppress) write_edo(edinr, edi, ed, step, rmsdev); } - + /* Copy back the positions unless monitoring only */ if (ed_constraints(ed->eEDtype, edi)) { @@ -2476,17 +2561,17 @@ rmfit(edi->sav.nr, buf->xcoll, transvec, rotmat); /* Copy the ED corrected positions into the coordinate array */ - /* Each node copies its local part. In the serial case, nat_loc is the + /* Each node copies its local part. In the serial case, nat_loc is the * total number of ED atoms */ for (i=0; isav.nr_loc; i++) { /* Unshift local ED coordinate and store in x_unsh */ - ed_unshift_single_coord(box, buf->xcoll[edi->sav.c_ind[i]], + ed_unshift_single_coord(box, buf->xcoll[edi->sav.c_ind[i]], buf->shifts_xcoll[edi->sav.c_ind[i]], x_unsh); - + /* dx is the ED correction to the positions: */ rvec_sub(x_unsh, xs[edi->sav.anrs_loc[i]], dx); - + if (v != NULL) { /* dv is the ED correction to the velocity: */ @@ -2499,10 +2584,10 @@ } } } /* END of if (edi->bNeedDoEdsam) */ - + /* Prepare for the next ED dataset */ edi = edi->next_edi; - + } /* END of loop over ED datasets */ ed->bFirst = FALSE; diff -Nru gromacs-4.5.4/src/mdlib/forcerec.c gromacs-4.5.5/src/mdlib/forcerec.c --- gromacs-4.5.4/src/mdlib/forcerec.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/forcerec.c 2011-09-21 12:34:32.000000000 +0000 @@ -518,8 +518,7 @@ } static cginfo_mb_t *init_cginfo_mb(FILE *fplog,const gmx_mtop_t *mtop, - t_forcerec *fr,gmx_bool bNoSolvOpt, - gmx_bool *bExcl_IntraCGAll_InterCGNone) + t_forcerec *fr,gmx_bool bNoSolvOpt) { const t_block *cgs; const t_blocka *excl; @@ -534,8 +533,6 @@ ncg_tot = ncg_mtop(mtop); snew(cginfo_mb,mtop->nmolblock); - *bExcl_IntraCGAll_InterCGNone = TRUE; - excl_nalloc = 10; snew(bExcl,excl_nalloc); cg_offset = 0; @@ -649,11 +646,6 @@ gmx_fatal(FARGS,"A charge group has size %d which is larger than the limit of %d atoms",a1-a0,MAX_CHARGEGROUP_SIZE); } SET_CGINFO_NATOMS(cginfo[cgm+cg],a1-a0); - - if (!bExclIntraAll || bExclInter) - { - *bExcl_IntraCGAll_InterCGNone = FALSE; - } } } cg_offset += molb->nmol*cgs->nr; @@ -1444,7 +1436,7 @@ { if (fp) fprintf(fp,"Will do PME sum in reciprocal space.\n"); - please_cite(fp,"Essman95a"); + please_cite(fp,"Essmann95a"); if (ir->ewald_geometry == eewg3DC) { @@ -1761,8 +1753,8 @@ fr->qr = mk_QMMMrec(); /* Set all the static charge group info */ - fr->cginfo_mb = init_cginfo_mb(fp,mtop,fr,bNoSolvOpt, - &fr->bExcl_IntraCGAll_InterCGNone); + fr->cginfo_mb = init_cginfo_mb(fp,mtop,fr,bNoSolvOpt); + if (DOMAINDECOMP(cr)) { fr->cginfo = NULL; } else { diff -Nru gromacs-4.5.4/src/mdlib/genborn_sse2_double.c gromacs-4.5.5/src/mdlib/genborn_sse2_double.c --- gromacs-4.5.4/src/mdlib/genborn_sse2_double.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/genborn_sse2_double.c 2011-09-21 12:34:32.000000000 +0000 @@ -817,7 +817,7 @@ { for(i=n0;ibRad[k]; + rbi = born->bRad[i]; rb[i] = rbi * rbi * born->drobc[i] * dvda[i]; } } diff -Nru gromacs-4.5.4/src/mdlib/iteratedconstraints.c gromacs-4.5.5/src/mdlib/iteratedconstraints.c --- gromacs-4.5.4/src/mdlib/iteratedconstraints.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/iteratedconstraints.c 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,232 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * Gallium Rubidium Oxygen Manganese Argon Carbon Silicon + */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) +/* _isnan() */ +#include +#endif + +#include "typedefs.h" +#include "gmx_fatal.h" +#include "mdrun.h" + +#ifdef GMX_DOUBLE +#define CONVERGEITER 0.000000001 +#define CLOSE_ENOUGH 0.000001000 +#else +#define CONVERGEITER 0.0001 +#define CLOSE_ENOUGH 0.0050 +#endif + +/* we want to keep track of the close calls. If there are too many, there might be some other issues. + so we make sure that it's either less than some predetermined number, or if more than that number, + only some small fraction of the total. */ +#define MAX_NUMBER_CLOSE 50 +#define FRACTION_CLOSE 0.001 + +/* maximum length of cyclic traps to check, emerging from limited numerical precision */ +#define CYCLEMAX 20 + +void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate) +{ + int i; + + iterate->iter_i = 0; + iterate->bIterate = bIterate; + iterate->num_close = 0; + for (i=0;iallrelerr[i] = 0; + } +} + +gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf) +{ + /* monitor convergence, and use a secant search to propose new + values. + x_{i} - x_{i-1} + The secant method computes x_{i+1} = x_{i} - f(x_{i}) * --------------------- + f(x_{i}) - f(x_{i-1}) + + The function we are trying to zero is fom-x, where fom is the + "figure of merit" which is the pressure (or the veta value) we + would get by putting in an old value of the pressure or veta into + the incrementor function for the step or half step. I have + verified that this gives the same answer as self consistent + iteration, usually in many fewer steps, especially for small tau_p. + + We could possibly eliminate an iteration with proper use + of the value from the previous step, but that would take a bit + more bookkeeping, especially for veta, since tests indicate the + function of veta on the last step is not sufficiently close to + guarantee convergence this step. This is + good enough for now. On my tests, I could use tau_p down to + 0.02, which is smaller that would ever be necessary in + practice. Generally, 3-5 iterations will be sufficient */ + + real relerr,err,xmin; + char buf[256]; + int i; + gmx_bool incycle; + + if (bFirstIterate) + { + iterate->x = fom; + iterate->f = fom-iterate->x; + iterate->xprev = 0; + iterate->fprev = 0; + *newf = fom; + } + else + { + iterate->f = fom-iterate->x; /* we want to zero this difference */ + if ((iterate->iter_i > 1) && (iterate->iter_i < MAXITERCONST)) + { + if (iterate->f==iterate->fprev) + { + *newf = iterate->f; + } + else + { + *newf = iterate->x - (iterate->x-iterate->xprev)*(iterate->f)/(iterate->f-iterate->fprev); + } + } + else + { + /* just use self-consistent iteration the first step to initialize, or + if it's not converging (which happens occasionally -- need to investigate why) */ + *newf = fom; + } + } + /* Consider a slight shortcut allowing us to exit one sooner -- we check the + difference between the closest of x and xprev to the new + value. To be 100% certain, we should check the difference between + the last result, and the previous result, or + + relerr = (fabs((x-xprev)/fom)); + + but this is pretty much never necessary under typical conditions. + Checking numerically, it seems to lead to almost exactly the same + trajectories, but there are small differences out a few decimal + places in the pressure, and eventually in the v_eta, but it could + save an interation. + + if (fabs(*newf-x) < fabs(*newf - xprev)) { xmin = x;} else { xmin = xprev;} + relerr = (fabs((*newf-xmin) / *newf)); + */ + + err = fabs((iterate->f-iterate->fprev)); + relerr = fabs(err/fom); + + iterate->allrelerr[iterate->iter_i] = relerr; + + if (iterate->iter_i > 0) + { + if (debug) + { + fprintf(debug,"Iterating NPT constraints: %6i %20.12f%14.6g%20.12f\n", + iterate->iter_i,fom,relerr,*newf); + } + + if ((relerr < CONVERGEITER) || (err < CONVERGEITER) || (fom==0) || ((iterate->x == iterate->xprev) && iterate->iter_i > 1)) + { + iterate->bIterate = FALSE; + if (debug) + { + fprintf(debug,"Iterating NPT constraints: CONVERGED\n"); + } + return TRUE; + } + if (iterate->iter_i > MAXITERCONST) + { + if (relerr < CLOSE_ENOUGH) + { + incycle = FALSE; + for (i=1;iallrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-1]) && + (iterate->allrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-(1+2*i)])) { + incycle = TRUE; + if (debug) + { + fprintf(debug,"Exiting from an NPT iterating cycle of length %d\n",i); + } + break; + } + } + + if (incycle) { + /* step 1: trapped in a numerical attractor */ + /* we are trapped in a numerical attractor, and can't converge any more, and are close to the final result. + Better to give up convergence here than have the simulation die. + */ + iterate->num_close++; + return TRUE; + } + else + { + /* Step #2: test if we are reasonably close for other reasons, then monitor the number. If not, die */ + + /* how many close calls have we had? If less than a few, we're OK */ + if (iterate->num_close < MAX_NUMBER_CLOSE) + { + sprintf(buf,"Slight numerical convergence deviation with NPT at step %d, relative error only %10.5g, likely not a problem, continuing\n",nsteps,relerr); + md_print_warning(cr,fplog,buf); + iterate->num_close++; + return TRUE; + /* if more than a few, check the total fraction. If too high, die. */ + } else if (iterate->num_close/(double)nsteps > FRACTION_CLOSE) { + gmx_fatal(FARGS,"Could not converge NPT constraints, too many exceptions (%d%%\n",iterate->num_close/(double)nsteps); + } + } + } + else + { + gmx_fatal(FARGS,"Could not converge NPT constraints\n"); + } + } + } + + iterate->xprev = iterate->x; + iterate->x = *newf; + iterate->fprev = iterate->f; + iterate->iter_i++; + + return FALSE; +} + diff -Nru gromacs-4.5.4/src/mdlib/Makefile.am gromacs-4.5.5/src/mdlib/Makefile.am --- gromacs-4.5.4/src/mdlib/Makefile.am 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/Makefile.am 2011-09-21 12:34:32.000000000 +0000 @@ -24,8 +24,9 @@ edsam.c ewald.c \ force.c forcerec.c \ ghat.c init.c \ + iteratedconstraints.c md_support.c \ mdatom.c mdebin.c minimize.c \ - mvxvf.c ns.c nsgrid.c \ + mvxvf.c ns.c nlistheuristics.c nsgrid.c \ perf_est.c genborn.c \ genborn_sse2_single.c \ genborn_sse2_single.h \ diff -Nru gromacs-4.5.4/src/mdlib/Makefile.in gromacs-4.5.5/src/mdlib/Makefile.in --- gromacs-4.5.4/src/mdlib/Makefile.in 2011-03-21 15:13:39.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/Makefile.in 2011-09-21 12:38:33.000000000 +0000 @@ -78,7 +78,8 @@ coupling.lo domdec.lo domdec_box.lo domdec_con.lo \ domdec_network.lo domdec_setup.lo domdec_top.lo ebin.lo \ edsam.lo ewald.lo force.lo forcerec.lo ghat.lo init.lo \ - mdatom.lo mdebin.lo minimize.lo mvxvf.lo ns.lo nsgrid.lo \ + iteratedconstraints.lo md_support.lo mdatom.lo mdebin.lo \ + minimize.lo mvxvf.lo ns.lo nlistheuristics.lo nsgrid.lo \ perf_est.lo genborn.lo genborn_sse2_single.lo \ genborn_sse2_double.lo genborn_allvsall.lo \ genborn_allvsall_sse2_single.lo \ @@ -277,8 +278,9 @@ edsam.c ewald.c \ force.c forcerec.c \ ghat.c init.c \ + iteratedconstraints.c md_support.c \ mdatom.c mdebin.c minimize.c \ - mvxvf.c ns.c nsgrid.c \ + mvxvf.c ns.c nlistheuristics.c nsgrid.c \ perf_est.c genborn.c \ genborn_sse2_single.c \ genborn_sse2_single.h \ @@ -430,11 +432,14 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_wallcycle.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/groupcoord.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/init.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/iteratedconstraints.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/md_support.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mdatom.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mdebin.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mdebin_bar.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/minimize.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mvxvf.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/nlistheuristics.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ns.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/nsgrid.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/partdec.Plo@am__quote@ diff -Nru gromacs-4.5.4/src/mdlib/mdebin.c gromacs-4.5.5/src/mdlib/mdebin.c --- gromacs-4.5.4/src/mdlib/mdebin.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/mdebin.c 2011-09-21 12:34:32.000000000 +0000 @@ -84,12 +84,6 @@ #define NBOXS asize(boxs_nm) #define NTRICLBOXS asize(tricl_boxs_nm) -static gmx_bool bTricl,bDynBox; -static int f_nre=0,epc,etc,nCrmsd; - - - - t_mdebin *init_mdebin(ener_file_t fp_ene, const gmx_mtop_t *mtop, @@ -263,13 +257,8 @@ } md->epc = ir->epc; - for (i=0;iref_p[i][j] = ir->ref_p[i][j]; - } - } + md->bDiagPres = !TRICLINIC(ir->ref_p); + md->ref_p = (ir->ref_p[XX][XX]+ir->ref_p[YY][YY]+ir->ref_p[ZZ][ZZ])/DIM; md->bTricl = TRICLINIC(ir->compress) || TRICLINIC(ir->deform); md->bDynBox = DYNAMIC_BOX(*ir); md->etc = ir->etc; @@ -296,8 +285,11 @@ unit_length); md->ivol = get_ebin_space(md->ebin, 1, vol_nm, unit_volume); md->idens = get_ebin_space(md->ebin, 1, dens_nm, unit_density_SI); - md->ipv = get_ebin_space(md->ebin, 1, pv_nm, unit_energy); - md->ienthalpy = get_ebin_space(md->ebin, 1, enthalpy_nm, unit_energy); + if (md->bDiagPres) + { + md->ipv = get_ebin_space(md->ebin, 1, pv_nm, unit_energy); + md->ienthalpy = get_ebin_space(md->ebin, 1, enthalpy_nm, unit_energy); + } } if (md->bConstrVir) { @@ -701,30 +693,20 @@ vol = box[XX][XX]*box[YY][YY]*box[ZZ][ZZ]; dens = (tmass*AMU)/(vol*NANO*NANO*NANO); - /* This is pV (in kJ/mol). The pressure is the reference pressure, - not the instantaneous pressure */ - pv = 0; - for (i=0;ij) - { - pv += box[i][j]*md->ref_p[i][j]/PRESFAC; - } - else - { - pv += box[j][i]*md->ref_p[j][i]/PRESFAC; - } - } - } - add_ebin(md->ebin,md->ib ,nboxs,bs ,bSum); add_ebin(md->ebin,md->ivol ,1 ,&vol ,bSum); add_ebin(md->ebin,md->idens,1 ,&dens,bSum); - add_ebin(md->ebin,md->ipv ,1 ,&pv ,bSum); - enthalpy = pv + enerd->term[F_ETOT]; - add_ebin(md->ebin,md->ienthalpy ,1 ,&enthalpy ,bSum); + + if (md->bDiagPres) + { + /* This is pV (in kJ/mol). The pressure is the reference pressure, + not the instantaneous pressure */ + pv = vol*md->ref_p/PRESFAC; + + add_ebin(md->ebin,md->ipv ,1 ,&pv ,bSum); + enthalpy = pv + enerd->term[F_ETOT]; + add_ebin(md->ebin,md->ienthalpy ,1 ,&enthalpy ,bSum); + } } if (md->bConstrVir) { diff -Nru gromacs-4.5.4/src/mdlib/md_support.c gromacs-4.5.5/src/mdlib/md_support.c --- gromacs-4.5.4/src/mdlib/md_support.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/md_support.c 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,748 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * Gallium Rubidium Oxygen Manganese Argon Carbon Silicon + */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) +/* _isnan() */ +#include +#endif + +#include "typedefs.h" +#include "string2.h" +#include "smalloc.h" +#include "mdrun.h" +#include "domdec.h" +#include "mtop_util.h" +#include "gmx_wallcycle.h" +#include "vcm.h" +#include "nrnb.h" + +/* Is the signal in one simulation independent of other simulations? */ +gmx_bool gs_simlocal[eglsNR] = { TRUE, FALSE, FALSE, TRUE }; + +/* check which of the multisim simulations has the shortest number of + steps and return that number of nsteps */ +gmx_large_int_t get_multisim_nsteps(const t_commrec *cr, + gmx_large_int_t nsteps) +{ + gmx_large_int_t steps_out; + + if MASTER(cr) + { + gmx_large_int_t *buf; + int s; + + snew(buf,cr->ms->nsim); + + buf[cr->ms->sim] = nsteps; + gmx_sumli_sim(cr->ms->nsim, buf, cr->ms); + + steps_out=-1; + for(s=0; sms->nsim; s++) + { + /* find the smallest positive number */ + if (buf[s]>= 0 && ((steps_out < 0) || (buf[s]=0 && steps_outms->sim, steps_out); + } + } + /* broadcast to non-masters */ + gmx_bcast(sizeof(gmx_large_int_t), &steps_out, cr); + return steps_out; +} + +int multisim_min(const gmx_multisim_t *ms,int nmin,int n) +{ + int *buf; + gmx_bool bPos,bEqual; + int s,d; + + snew(buf,ms->nsim); + buf[ms->sim] = n; + gmx_sumi_sim(ms->nsim,buf,ms); + bPos = TRUE; + bEqual = TRUE; + for(s=0; snsim; s++) + { + bPos = bPos && (buf[s] > 0); + bEqual = bEqual && (buf[s] == buf[0]); + } + if (bPos) + { + if (bEqual) + { + nmin = min(nmin,buf[0]); + } + else + { + /* Find the least common multiple */ + for(d=2; dnsim && d % buf[s] == 0) + { + s++; + } + if (s == ms->nsim) + { + /* We found the LCM and it is less than nmin */ + nmin = d; + break; + } + } + } + } + sfree(buf); + + return nmin; +} + +int multisim_nstsimsync(const t_commrec *cr, + const t_inputrec *ir,int repl_ex_nst) +{ + int nmin; + + if (MASTER(cr)) + { + nmin = INT_MAX; + nmin = multisim_min(cr->ms,nmin,ir->nstlist); + nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); + nmin = multisim_min(cr->ms,nmin,repl_ex_nst); + if (nmin == INT_MAX) + { + gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); + } + /* Avoid inter-simulation communication at every (second) step */ + if (nmin <= 2) + { + nmin = 10; + } + } + + gmx_bcast(sizeof(int),&nmin,cr); + + return nmin; +} + +void init_global_signals(globsig_t *gs,const t_commrec *cr, + const t_inputrec *ir,int repl_ex_nst) +{ + int i; + + if (MULTISIM(cr)) + { + gs->nstms = multisim_nstsimsync(cr,ir,repl_ex_nst); + if (debug) + { + fprintf(debug,"Syncing simulations for checkpointing and termination every %d steps\n",gs->nstms); + } + } + else + { + gs->nstms = 1; + } + + for(i=0; isig[i] = 0; + gs->set[i] = 0; + } +} + +void copy_coupling_state(t_state *statea,t_state *stateb, + gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts) +{ + + /* MRS note -- might be able to get rid of some of the arguments. Look over it when it's all debugged */ + + int i,j,nc; + + /* Make sure we have enough space for x and v */ + if (statea->nalloc > stateb->nalloc) + { + stateb->nalloc = statea->nalloc; + srenew(stateb->x,stateb->nalloc); + srenew(stateb->v,stateb->nalloc); + } + + stateb->natoms = statea->natoms; + stateb->ngtc = statea->ngtc; + stateb->nnhpres = statea->nnhpres; + stateb->veta = statea->veta; + if (ekinda) + { + copy_mat(ekinda->ekin,ekindb->ekin); + for (i=0; ingtc; i++) + { + ekindb->tcstat[i].T = ekinda->tcstat[i].T; + ekindb->tcstat[i].Th = ekinda->tcstat[i].Th; + copy_mat(ekinda->tcstat[i].ekinh,ekindb->tcstat[i].ekinh); + copy_mat(ekinda->tcstat[i].ekinf,ekindb->tcstat[i].ekinf); + ekindb->tcstat[i].ekinscalef_nhc = ekinda->tcstat[i].ekinscalef_nhc; + ekindb->tcstat[i].ekinscaleh_nhc = ekinda->tcstat[i].ekinscaleh_nhc; + ekindb->tcstat[i].vscale_nhc = ekinda->tcstat[i].vscale_nhc; + } + } + copy_rvecn(statea->x,stateb->x,0,stateb->natoms); + copy_rvecn(statea->v,stateb->v,0,stateb->natoms); + copy_mat(statea->box,stateb->box); + copy_mat(statea->box_rel,stateb->box_rel); + copy_mat(statea->boxv,stateb->boxv); + + for (i = 0; ingtc; i++) + { + nc = i*opts->nhchainlength; + for (j=0; jnhchainlength; j++) + { + stateb->nosehoover_xi[nc+j] = statea->nosehoover_xi[nc+j]; + stateb->nosehoover_vxi[nc+j] = statea->nosehoover_vxi[nc+j]; + } + } + if (stateb->nhpres_xi != NULL) + { + for (i = 0; innhpres; i++) + { + nc = i*opts->nhchainlength; + for (j=0; jnhchainlength; j++) + { + stateb->nhpres_xi[nc+j] = statea->nhpres_xi[nc+j]; + stateb->nhpres_vxi[nc+j] = statea->nhpres_vxi[nc+j]; + } + } + } +} + +real compute_conserved_from_auxiliary(t_inputrec *ir, t_state *state, t_extmass *MassQ) +{ + real quantity = 0; + switch (ir->etc) + { + case etcNO: + break; + case etcBERENDSEN: + break; + case etcNOSEHOOVER: + quantity = NPT_energy(ir,state,MassQ); + break; + case etcVRESCALE: + quantity = vrescale_energy(&(ir->opts),state->therm_integral); + break; + default: + break; + } + return quantity; +} + +void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, + t_forcerec *fr, gmx_ekindata_t *ekind, + t_state *state, t_state *state_global, t_mdatoms *mdatoms, + t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, + gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, + tensor pres, rvec mu_tot, gmx_constr_t constr, + globsig_t *gs,gmx_bool bInterSimGS, + matrix box, gmx_mtop_t *top_global, real *pcurr, + int natoms, gmx_bool *bSumEkinhOld, int flags) +{ + int i,gsi; + real gs_buf[eglsNR]; + tensor corr_vir,corr_pres,shakeall_vir; + gmx_bool bEner,bPres,bTemp, bVV; + gmx_bool bRerunMD, bStopCM, bGStat, bIterate, + bFirstIterate,bReadEkin,bEkinAveVel,bScaleEkin, bConstrain; + real ekin,temp,prescorr,enercorr,dvdlcorr; + + /* translate CGLO flags to gmx_booleans */ + bRerunMD = flags & CGLO_RERUNMD; + bStopCM = flags & CGLO_STOPCM; + bGStat = flags & CGLO_GSTAT; + + bReadEkin = (flags & CGLO_READEKIN); + bScaleEkin = (flags & CGLO_SCALEEKIN); + bEner = flags & CGLO_ENERGY; + bTemp = flags & CGLO_TEMPERATURE; + bPres = (flags & CGLO_PRESSURE); + bConstrain = (flags & CGLO_CONSTRAINT); + bIterate = (flags & CGLO_ITERATE); + bFirstIterate = (flags & CGLO_FIRSTITERATE); + + /* we calculate a full state kinetic energy either with full-step velocity verlet + or half step where we need the pressure */ + + bEkinAveVel = (ir->eI==eiVV || (ir->eI==eiVVAK && bPres) || bReadEkin); + + /* in initalization, it sums the shake virial in vv, and to + sums ekinh_old in leapfrog (or if we are calculating ekinh_old) for other reasons */ + + /* ########## Kinetic energy ############## */ + + if (bTemp) + { + /* Non-equilibrium MD: this is parallellized, but only does communication + * when there really is NEMD. + */ + + if (PAR(cr) && (ekind->bNEMD)) + { + accumulate_u(cr,&(ir->opts),ekind); + } + debug_gmx(); + if (bReadEkin) + { + restore_ekinstate_from_state(cr,ekind,&state_global->ekinstate); + } + else + { + + calc_ke_part(state,&(ir->opts),mdatoms,ekind,nrnb,bEkinAveVel,bIterate); + } + + debug_gmx(); + + /* Calculate center of mass velocity if necessary, also parallellized */ + if (bStopCM && !bRerunMD && bEner) + { + calc_vcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms, + state->x,state->v,vcm); + } + } + + if (bTemp || bPres || bEner || bConstrain) + { + if (!bGStat) + { + /* We will not sum ekinh_old, + * so signal that we still have to do it. + */ + *bSumEkinhOld = TRUE; + + } + else + { + if (gs != NULL) + { + for(i=0; isig[i]; + } + } + if (PAR(cr)) + { + wallcycle_start(wcycle,ewcMoveE); + GMX_MPE_LOG(ev_global_stat_start); + global_stat(fplog,gstat,cr,enerd,force_vir,shake_vir,mu_tot, + ir,ekind,constr,vcm, + gs != NULL ? eglsNR : 0,gs_buf, + top_global,state, + *bSumEkinhOld,flags); + GMX_MPE_LOG(ev_global_stat_finish); + wallcycle_stop(wcycle,ewcMoveE); + } + if (gs != NULL) + { + if (MULTISIM(cr) && bInterSimGS) + { + if (MASTER(cr)) + { + /* Communicate the signals between the simulations */ + gmx_sum_sim(eglsNR,gs_buf,cr->ms); + } + /* Communicate the signals form the master to the others */ + gmx_bcast(eglsNR*sizeof(gs_buf[0]),gs_buf,cr); + } + for(i=0; i= 0 ? + (int)(gs_buf[i] + 0.5) : + (int)(gs_buf[i] - 0.5)); + if (gsi != 0) + { + gs->set[i] = gsi; + } + /* Turn off the local signal */ + gs->sig[i] = 0; + } + } + } + *bSumEkinhOld = FALSE; + } + } + + if (!ekind->bNEMD && debug && bTemp && (vcm->nr > 0)) + { + correct_ekin(debug, + mdatoms->start,mdatoms->start+mdatoms->homenr, + state->v,vcm->group_p[0], + mdatoms->massT,mdatoms->tmass,ekind->ekin); + } + + if (bEner) { + /* Do center of mass motion removal */ + if (bStopCM && !bRerunMD) /* is this correct? Does it get called too often with this logic? */ + { + check_cm_grp(fplog,vcm,ir,1); + do_stopcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms->cVCM, + state->x,state->v,vcm); + inc_nrnb(nrnb,eNR_STOPCM,mdatoms->homenr); + } + + /* Calculate the amplitude of the cosine velocity profile */ + ekind->cosacc.vcos = ekind->cosacc.mvcos/mdatoms->tmass; + } + + if (bTemp) + { + /* Sum the kinetic energies of the groups & calc temp */ + /* compute full step kinetic energies if vv, or if vv-avek and we are computing the pressure with IR_NPT_TROTTER */ + /* three maincase: VV with AveVel (md-vv), vv with AveEkin (md-vv-avek), leap with AveEkin (md). + Leap with AveVel is not supported; it's not clear that it will actually work. + bEkinAveVel: If TRUE, we simply multiply ekin by ekinscale to get a full step kinetic energy. + If FALSE, we average ekinh_old and ekinh*ekinscale_nhc to get an averaged half step kinetic energy. + bSaveEkinOld: If TRUE (in the case of iteration = bIterate is TRUE), we don't reset the ekinscale_nhc. + If FALSE, we go ahead and erase over it. + */ + enerd->term[F_TEMP] = sum_ekin(&(ir->opts),ekind,&(enerd->term[F_DKDL]), + bEkinAveVel,bIterate,bScaleEkin); + + enerd->term[F_EKIN] = trace(ekind->ekin); + } + + /* ########## Long range energy information ###### */ + + if (bEner || bPres || bConstrain) + { + calc_dispcorr(fplog,ir,fr,0,top_global->natoms,box,state->lambda, + corr_pres,corr_vir,&prescorr,&enercorr,&dvdlcorr); + } + + if (bEner && bFirstIterate) + { + enerd->term[F_DISPCORR] = enercorr; + enerd->term[F_EPOT] += enercorr; + enerd->term[F_DVDL] += dvdlcorr; + if (fr->efep != efepNO) { + enerd->dvdl_lin += dvdlcorr; + } + } + + /* ########## Now pressure ############## */ + if (bPres || bConstrain) + { + + m_add(force_vir,shake_vir,total_vir); + + /* Calculate pressure and apply LR correction if PPPM is used. + * Use the box from last timestep since we already called update(). + */ + + enerd->term[F_PRES] = calc_pres(fr->ePBC,ir->nwall,box,ekind->ekin,total_vir,pres, + (fr->eeltype==eelPPPM)?enerd->term[F_COUL_RECIP]:0.0); + + /* Calculate long range corrections to pressure and energy */ + /* this adds to enerd->term[F_PRES] and enerd->term[F_ETOT], + and computes enerd->term[F_DISPCORR]. Also modifies the + total_vir and pres tesors */ + + m_add(total_vir,corr_vir,total_vir); + m_add(pres,corr_pres,pres); + enerd->term[F_PDISPCORR] = prescorr; + enerd->term[F_PRES] += prescorr; + *pcurr = enerd->term[F_PRES]; + /* calculate temperature using virial */ + enerd->term[F_VTEMP] = calc_temp(trace(total_vir),ir->opts.nrdf[0]); + + } +} + +void check_nst_param(FILE *fplog,t_commrec *cr, + const char *desc_nst,int nst, + const char *desc_p,int *p) +{ + char buf[STRLEN]; + + if (*p > 0 && *p % nst != 0) + { + /* Round up to the next multiple of nst */ + *p = ((*p)/nst + 1)*nst; + sprintf(buf,"NOTE: %s changes %s to %d\n",desc_nst,desc_p,*p); + md_print_warning(cr,fplog,buf); + } +} + +void reset_all_counters(FILE *fplog,t_commrec *cr, + gmx_large_int_t step, + gmx_large_int_t *step_rel,t_inputrec *ir, + gmx_wallcycle_t wcycle,t_nrnb *nrnb, + gmx_runtime_t *runtime) +{ + char buf[STRLEN],sbuf[STEPSTRSIZE]; + + /* Reset all the counters related to performance over the run */ + sprintf(buf,"Step %s: resetting all time and cycle counters\n", + gmx_step_str(step,sbuf)); + md_print_warning(cr,fplog,buf); + + wallcycle_stop(wcycle,ewcRUN); + wallcycle_reset_all(wcycle); + if (DOMAINDECOMP(cr)) + { + reset_dd_statistics_counters(cr->dd); + } + init_nrnb(nrnb); + ir->init_step += *step_rel; + ir->nsteps -= *step_rel; + *step_rel = 0; + wallcycle_start(wcycle,ewcRUN); + runtime_start(runtime); + print_date_and_time(fplog,cr->nodeid,"Restarted time",runtime); +} + +void min_zero(int *n,int i) +{ + if (i > 0 && (*n == 0 || i < *n)) + { + *n = i; + } +} + +int lcd4(int i1,int i2,int i3,int i4) +{ + int nst; + + nst = 0; + min_zero(&nst,i1); + min_zero(&nst,i2); + min_zero(&nst,i3); + min_zero(&nst,i4); + if (nst == 0) + { + gmx_incons("All 4 inputs for determininig nstglobalcomm are <= 0"); + } + + while (nst > 1 && ((i1 > 0 && i1 % nst != 0) || + (i2 > 0 && i2 % nst != 0) || + (i3 > 0 && i3 % nst != 0) || + (i4 > 0 && i4 % nst != 0))) + { + nst--; + } + + return nst; +} + +int check_nstglobalcomm(FILE *fplog,t_commrec *cr, + int nstglobalcomm,t_inputrec *ir) +{ + char buf[STRLEN]; + + if (!EI_DYNAMICS(ir->eI)) + { + nstglobalcomm = 1; + } + + if (nstglobalcomm == -1) + { + if (!(ir->nstcalcenergy > 0 || + ir->nstlist > 0 || + ir->etc != etcNO || + ir->epc != epcNO)) + { + nstglobalcomm = 10; + if (ir->nstenergy > 0 && ir->nstenergy < nstglobalcomm) + { + nstglobalcomm = ir->nstenergy; + } + } + else + { + /* Ensure that we do timely global communication for + * (possibly) each of the four following options. + */ + nstglobalcomm = lcd4(ir->nstcalcenergy, + ir->nstlist, + ir->etc != etcNO ? ir->nsttcouple : 0, + ir->epc != epcNO ? ir->nstpcouple : 0); + } + } + else + { + if (ir->nstlist > 0 && + nstglobalcomm > ir->nstlist && nstglobalcomm % ir->nstlist != 0) + { + nstglobalcomm = (nstglobalcomm / ir->nstlist)*ir->nstlist; + sprintf(buf,"WARNING: nstglobalcomm is larger than nstlist, but not a multiple, setting it to %d\n",nstglobalcomm); + md_print_warning(cr,fplog,buf); + } + if (ir->nstcalcenergy > 0) + { + check_nst_param(fplog,cr,"-gcom",nstglobalcomm, + "nstcalcenergy",&ir->nstcalcenergy); + } + if (ir->etc != etcNO && ir->nsttcouple > 0) + { + check_nst_param(fplog,cr,"-gcom",nstglobalcomm, + "nsttcouple",&ir->nsttcouple); + } + if (ir->epc != epcNO && ir->nstpcouple > 0) + { + check_nst_param(fplog,cr,"-gcom",nstglobalcomm, + "nstpcouple",&ir->nstpcouple); + } + + check_nst_param(fplog,cr,"-gcom",nstglobalcomm, + "nstenergy",&ir->nstenergy); + + check_nst_param(fplog,cr,"-gcom",nstglobalcomm, + "nstlog",&ir->nstlog); + } + + if (ir->comm_mode != ecmNO && ir->nstcomm < nstglobalcomm) + { + sprintf(buf,"WARNING: Changing nstcomm from %d to %d\n", + ir->nstcomm,nstglobalcomm); + md_print_warning(cr,fplog,buf); + ir->nstcomm = nstglobalcomm; + } + + return nstglobalcomm; +} + +void check_ir_old_tpx_versions(t_commrec *cr,FILE *fplog, + t_inputrec *ir,gmx_mtop_t *mtop) +{ + /* Check required for old tpx files */ + if (IR_TWINRANGE(*ir) && ir->nstlist > 1 && + ir->nstcalcenergy % ir->nstlist != 0) + { + md_print_warning(cr,fplog,"Old tpr file with twin-range settings: modifying energy calculation and/or T/P-coupling frequencies"); + + if (gmx_mtop_ftype_count(mtop,F_CONSTR) + + gmx_mtop_ftype_count(mtop,F_CONSTRNC) > 0 && + ir->eConstrAlg == econtSHAKE) + { + md_print_warning(cr,fplog,"With twin-range cut-off's and SHAKE the virial and pressure are incorrect"); + if (ir->epc != epcNO) + { + gmx_fatal(FARGS,"Can not do pressure coupling with twin-range cut-off's and SHAKE"); + } + } + check_nst_param(fplog,cr,"nstlist",ir->nstlist, + "nstcalcenergy",&ir->nstcalcenergy); + if (ir->epc != epcNO) + { + check_nst_param(fplog,cr,"nstlist",ir->nstlist, + "nstpcouple",&ir->nstpcouple); + } + check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, + "nstenergy",&ir->nstenergy); + check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, + "nstlog",&ir->nstlog); + if (ir->efep != efepNO) + { + check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, + "nstdhdl",&ir->nstdhdl); + } + } +} + +void rerun_parallel_comm(t_commrec *cr,t_trxframe *fr, + gmx_bool *bNotLastFrame) +{ + gmx_bool bAlloc; + rvec *xp,*vp; + + bAlloc = (fr->natoms == 0); + + if (MASTER(cr) && !*bNotLastFrame) + { + fr->natoms = -1; + } + xp = fr->x; + vp = fr->v; + gmx_bcast(sizeof(*fr),fr,cr); + fr->x = xp; + fr->v = vp; + + *bNotLastFrame = (fr->natoms >= 0); + + if (*bNotLastFrame && PARTDECOMP(cr)) + { + /* x and v are the only variable size quantities stored in trr + * that are required for rerun (f is not needed). + */ + if (bAlloc) + { + snew(fr->x,fr->natoms); + snew(fr->v,fr->natoms); + } + if (fr->bX) + { + gmx_bcast(fr->natoms*sizeof(fr->x[0]),fr->x[0],cr); + } + if (fr->bV) + { + gmx_bcast(fr->natoms*sizeof(fr->v[0]),fr->v[0],cr); + } + } +} + +void md_print_warning(const t_commrec *cr,FILE *fplog,const char *buf) +{ + if (MASTER(cr)) + { + fprintf(stderr,"\n%s\n",buf); + } + if (fplog) + { + fprintf(fplog,"\n%s\n",buf); + } +} diff -Nru gromacs-4.5.4/src/mdlib/nlistheuristics.c gromacs-4.5.5/src/mdlib/nlistheuristics.c --- gromacs-4.5.4/src/mdlib/nlistheuristics.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/nlistheuristics.c 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,139 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * Gallium Rubidium Oxygen Manganese Argon Carbon Silicon + */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#if ((defined WIN32 || defined _WIN32 || defined WIN64 || defined _WIN64) && !defined __CYGWIN__ && !defined __CYGWIN32__) +/* _isnan() */ +#include +#endif + +#include "typedefs.h" +#include "gmx_fatal.h" +#include "vec.h" + +void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step) +{ + nlh->lt_runav = 0; + nlh->lt_runav2 = 0; + nlh->step_nscheck = step; +} + +void init_nlistheuristics(gmx_nlheur_t *nlh, + gmx_bool bGStatEveryStep,gmx_large_int_t step) +{ + nlh->bGStatEveryStep = bGStatEveryStep; + nlh->nns = 0; + nlh->nabnsb = 0; + nlh->s1 = 0; + nlh->s2 = 0; + nlh->ab = 0; + + reset_nlistheuristics(nlh,step); +} + +void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step) +{ + gmx_large_int_t nl_lt; + char sbuf[STEPSTRSIZE],sbuf2[STEPSTRSIZE]; + + /* Determine the neighbor list life time */ + nl_lt = step - nlh->step_ns; + if (debug) + { + fprintf(debug,"%d atoms beyond ns buffer, updating neighbor list after %s steps\n",nlh->nabnsb,gmx_step_str(nl_lt,sbuf)); + } + nlh->nns++; + nlh->s1 += nl_lt; + nlh->s2 += nl_lt*nl_lt; + nlh->ab += nlh->nabnsb; + if (nlh->lt_runav == 0) + { + nlh->lt_runav = nl_lt; + /* Initialize the fluctuation average + * such that at startup we check after 0 steps. + */ + nlh->lt_runav2 = sqr(nl_lt/2.0); + } + /* Running average with 0.9 gives an exp. history of 9.5 */ + nlh->lt_runav2 = 0.9*nlh->lt_runav2 + 0.1*sqr(nlh->lt_runav - nl_lt); + nlh->lt_runav = 0.9*nlh->lt_runav + 0.1*nl_lt; + if (nlh->bGStatEveryStep) + { + /* Always check the nlist validity */ + nlh->step_nscheck = step; + } + else + { + /* We check after: - 2*sigma + * The factor 2 is quite conservative, + * but we assume that with nstlist=-1 the user + * prefers exact integration over performance. + */ + nlh->step_nscheck = step + + (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2)) - 1; + } + if (debug) + { + fprintf(debug,"nlist life time %s run av. %4.1f sig %3.1f check %s check with -gcom %d\n", + gmx_step_str(nl_lt,sbuf),nlh->lt_runav,sqrt(nlh->lt_runav2), + gmx_step_str(nlh->step_nscheck-step+1,sbuf2), + (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2))); + } +} + +void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step) +{ + int d; + + if (bReset) + { + reset_nlistheuristics(nlh,step); + } + else + { + update_nliststatistics(nlh,step); + } + + nlh->step_ns = step; + /* Initialize the cumulative coordinate scaling matrix */ + clear_mat(nlh->scale_tot); + for(d=0; dscale_tot[d][d] = 1.0; + } +} diff -Nru gromacs-4.5.4/src/mdlib/ns.c gromacs-4.5.5/src/mdlib/ns.c --- gromacs-4.5.4/src/mdlib/ns.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/ns.c 2011-09-21 12:34:32.000000000 +0000 @@ -317,10 +317,6 @@ { fprintf(log,"\nUsing charge-group - charge-group neighbor lists and kernels\n\n"); } - if (!fr->bExcl_IntraCGAll_InterCGNone) - { - gmx_fatal(FARGS,"The charge-group - charge-group force loops only support systems with all intra-cg interactions excluded and no inter-cg exclusions, this is not the case for this system."); - } } if (fr->solvent_opt == esolTIP4P) { @@ -547,7 +543,8 @@ static inline void add_j_to_nblist_cg(t_nblist *nlist, atom_id j_start,int j_end, - t_excl *bexcl,gmx_bool bLR) + t_excl *bexcl,gmx_bool i_is_j, + gmx_bool bLR) { int nrj=nlist->nrj; int j; @@ -577,6 +574,14 @@ { nlist->excl[nrj*MAX_CGCGSIZE + j - j_start] = bexcl[j]; } + if (i_is_j) + { + /* Avoid double counting of intra-cg interactions */ + for(j=1; jexcl[nrj*MAX_CGCGSIZE + j] |= (1<nrj ++; } @@ -1257,7 +1262,7 @@ /* Here we add the j charge group jcg to the list, * exclusions are also added to the list. */ - add_j_to_nblist_cg(vdwc,index[jcg],index[jcg+1],bExcl,bLR); + add_j_to_nblist_cg(vdwc,index[jcg],index[jcg+1],bExcl,icg==jcg,bLR); } } diff -Nru gromacs-4.5.4/src/mdlib/partdec.c gromacs-4.5.5/src/mdlib/partdec.c --- gromacs-4.5.4/src/mdlib/partdec.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/partdec.c 2011-09-21 12:34:32.000000000 +0000 @@ -552,9 +552,8 @@ } pdc->nconstraints = cnt; - /* This should really be calculated, but 1000 is a _lot_ for overlapping constraints... */ - snew(pdc->sendbuf,1000); - snew(pdc->recvbuf,1000); + snew(pdc->sendbuf,max(6*(pd->index[cr->nodeid+1]-pd->constraints->right_range_send),6*(pdc->left_range_send-pd->index[cr->nodeid]))); + snew(pdc->recvbuf,max(6*(pd->index[cr->nodeid]-pdc->left_range_receive),6*(pdc->right_range_receive-pd->index[cr->nodeid+1]))); } diff -Nru gromacs-4.5.4/src/mdlib/pull.c gromacs-4.5.5/src/mdlib/pull.c --- gromacs-4.5.4/src/mdlib/pull.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/pull.c 2011-09-21 12:34:32.000000000 +0000 @@ -456,7 +456,7 @@ dvec ref,vec; double d0,inpr; double lambda, rm, mass, invdt=0; - gmx_bool bConverged = FALSE; + gmx_bool bConverged_all,bConverged=FALSE; int niter=0,g,ii,j,m,max_iter=100; double q,a,b,c; /* for solving the quadratic equation, see Num. Recipes in C ed 2 p. 184 */ @@ -524,8 +524,11 @@ } } - while (!bConverged && niter < max_iter) + bConverged_all = TRUE; + while (!bConverged_all && niter < max_iter) { + bConverged_all = TRUE; + /* loop over all constraints */ for(g=1; g<1+pull->ngrp; g++) { @@ -711,16 +714,17 @@ break; } - /* DEBUG */ - if (debug) + if (!bConverged) { - if (!bConverged) + if (debug) { fprintf(debug,"NOT CONVERGED YET: Group %d:" "d_ref = %f %f %f, current d = %f\n", g,ref[0],ref[1],ref[2],dnorm(unc_ij)); } - } /* END DEBUG */ + + bConverged_all = FALSE; + } } niter++; diff -Nru gromacs-4.5.4/src/mdlib/tables.c gromacs-4.5.5/src/mdlib/tables.c --- gromacs-4.5.4/src/mdlib/tables.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/mdlib/tables.c 2011-09-21 12:34:32.000000000 +0000 @@ -1074,7 +1074,7 @@ fprintf(fp,"%15.10e %15.10e %15.10e\n",x0,y0,yp); } - ffclose(fp); + gmx_fio_fclose(fp); } /* diff -Nru gromacs-4.5.4/src/ngmx/ngmx.c gromacs-4.5.5/src/ngmx/ngmx.c --- gromacs-4.5.4/src/ngmx/ngmx.c 2011-03-04 11:10:43.000000000 +0000 +++ gromacs-4.5.5/src/ngmx/ngmx.c 2011-09-21 12:34:10.000000000 +0000 @@ -267,7 +267,7 @@ int main(int argc, char *argv[]) { const char *desc[] = { - "[TT]ngmx[tt] is the Gromacs trajectory viewer. This program reads a", + "[TT]ngmx[tt] is the GROMACS trajectory viewer. This program reads a", "trajectory file, a run input file and an index file and plots a", "3D structure of your molecule on your standard X Window", "screen. No need for a high end graphics workstation, it even", @@ -279,8 +279,8 @@ "runs on MIT-X (real X), open windows and motif,", "user friendly menus, option to remove periodicity, option to", "show computational box.[PAR]", - "Some of the more common X command line options can be used:[BR]", - "[TT]-bg[tt], [TT]-fg[tt] change colors, [TT]-font[tt] fontname, changes the font." + "Some of the more common X command line options can be used: ", + "[TT]-bg[tt], [TT]-fg[tt] change colors, [TT]-font fontname[tt] changes the font." }; const char *bugs[] = { "Balls option does not work", diff -Nru gromacs-4.5.4/src/tools/binsearch.c gromacs-4.5.5/src/tools/binsearch.c --- gromacs-4.5.4/src/tools/binsearch.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/binsearch.c 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,174 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * $Id: densorder.c,v 0.9 + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.0 + * + * Copyright (c) 1991-2001 + * BIOSON Research Institute, Dept. of Biophysical Chemistry + * University of Groningen, The Netherlands + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . + * + * And Hey: + * Gyas ROwers Mature At Cryogenic Speed + */ + +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include "types/simple.h" +#include "gmx_fatal.h" + +/*Make range-array (Permutation identity) for sorting */ +void rangeArray(int *ar,int size) +{ + int i; + for (i=0;i=0){ + for (i = startndx; i <=endndx; i++) { + j = i; + + while (j > startndx && arr[j - 1] > arr[j]) { + Swap(&arr[j],&arr[j-1]); + pswap(&perm[j],&perm[j-1]); + j--; + } + + } + + } + + if(direction<0){ + for (i = startndx; i <=endndx; i++) { + j = i; + + while (j > startndx && arr[j - 1] < arr[j]) { + Swap(&arr[j],&arr[j-1]); + pswap(&perm[j],&perm[j-1]); + j--; + } + + } + } +} + + +int BinarySearch (real *array, int low, int high, real key,int direction) +{ + int mid, max, min; + max=high+2; + min=low+1; + +/*Iterative implementation*/ + + if (direction>=0){ + while (max-min>1){ + mid=(min+max)>>1; + if(key1){ + mid=(min+max)>>1; + if(key>array[mid-1]) max=mid; + else min=mid; + } + return min-1; + + }/*end -ifelse direction*/ + return -1; +} + + +int start_binsearch(real *array, int *perm, int low, int high, + real key, int direction) +{ + insertionSort(array,perm,low,high,direction); + return BinarySearch(array,low,high,key,direction); +} + +int LinearSearch (double *array,int startindx, int stopindx, + double key,int *count, int direction) +{ + /*Iterative implementation - assume elements sorted*/ + int i; + int keyindex; + + if(direction>=0){ + keyindex=startindx; + for (i=startindx;i<=stopindx;i++){ + (*count)++; + if(array[i]>key) { + keyindex=i-1; + return keyindex; + } + } + } + else if(direction<0 ){ + keyindex=stopindx; + for(i=stopindx;i>=startindx;i--){ + (*count)++; + if (array[i]>key){ + keyindex=i+1; + return keyindex; + } + } + } + + else + gmx_fatal(FARGS,"Startindex=stopindex=%d\n",startindx); + + return -1; +} + diff -Nru gromacs-4.5.4/src/tools/binsearch.h gromacs-4.5.5/src/tools/binsearch.h --- gromacs-4.5.4/src/tools/binsearch.h 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/binsearch.h 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,54 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * $Id: densorder.c,v 0.9 + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.0 + * + * Copyright (c) 1991-2001 + * BIOSON Research Institute, Dept. of Biophysical Chemistry + * University of Groningen, The Netherlands + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . + * + * And Hey: + * Gyas ROwers Mature At Cryogenic Speed + */ + +#ifndef _binsearch_h +#define _binsearch_h + +#include "types/simple.h" + +extern void rangeArray(int *ar,int size); + +extern void insertionSort(real *ar, int *perm, int start, int end, int direction); + +extern int BinarySearch(real *ar, int start, int end, real key, int direction); + +extern int start_binsearch(real *array, int *perm, int low, int high, + real key, int direction); + +extern int LinearSearch(double *array,int startindx, int stopindx, + double key,int *count, int direction); + +#endif diff -Nru gromacs-4.5.4/src/tools/CMakeLists.txt gromacs-4.5.5/src/tools/CMakeLists.txt --- gromacs-4.5.4/src/tools/CMakeLists.txt 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/tools/CMakeLists.txt 2011-09-21 12:34:32.000000000 +0000 @@ -20,7 +20,7 @@ gmx_polystat.c gmx_potential.c gmx_rama.c gmx_rdf.c gmx_rms.c gmx_rmsf.c gmx_rotacf.c gmx_saltbr.c gmx_sas.c - gmx_select.c gmx_rmsdist.c gmx_rotmat.c + gmx_select.c gmx_rmsdist.c gmx_rotmat.c gmx_sgangle.c gmx_sorient.c gmx_spol.c gmx_tcaf.c gmx_traj.c gmx_velacc.c gmx_helixorient.c gmx_clustsize.c gmx_mdmat.c gmx_wham.c @@ -29,7 +29,9 @@ gmx_editconf.c gmx_genbox.c gmx_genion.c gmx_genconf.c gmx_genpr.c gmx_eneconv.c gmx_vanhove.c gmx_wheel.c addconf.c calcpot.c edittop.c gmx_bar.c - gmx_membed.c gmx_pme_error.c gmx_options.c + gmx_membed.c gmx_pme_error.c gmx_options.c gmx_dos.c + gmx_hydorder.c gmx_densorder.c powerspect.c dens_filter.c + binsearch.c ) @@ -53,6 +55,7 @@ g_spol g_spatial g_tcaf g_traj g_tune_pme g_vanhove g_velacc g_clustsize g_mdmat g_wham g_sigeps g_bar g_membed g_pme_error g_rmsdist g_rotmat g_options + g_dos g_hydorder g_densorder ) set(GMX_TOOLS_PROGRAMS_NOT_FOR_INSTALLATION diff -Nru gromacs-4.5.4/src/tools/dens_filter.c gromacs-4.5.5/src/tools/dens_filter.c --- gromacs-4.5.4/src/tools/dens_filter.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/dens_filter.c 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,133 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * $Id: densorder.c,v 0.9 + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.0 + * + * Copyright (c) 1991-2001 + * BIOSON Research Institute, Dept. of Biophysical Chemistry + * University of Groningen, The Netherlands + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . + * + * And Hey: + * Gyas ROwers Mature At Cryogenic Speed + */ + +#ifdef HAVE_CONFIG_H +#include +#endif +/* dens_filter.c + * Routines for Filters and convolutions + */ + +#include +#include "typedefs.h" +#include "dens_filter.h" +#include "smalloc.h" +#include "vec.h" + +#ifdef GMX_DOUBLE +#define EXP(x) (exp(x)) +#else +#define EXP(x) (expf(x)) +#endif + +/* Modulo function assuming y>0 but with arbitrary INTEGER x */ +static int MOD(int x, int y){ + if (x<0) x=x+y; + return (mod(x,y)); +} + + +gmx_bool convolution(int dataSize,real *x, int kernelSize, real* kernel) +{ + int i, j, k; + real *out; + snew(out,dataSize); + /* check validity of params */ + if(!x || !kernel) return FALSE; + if(dataSize <=0 || kernelSize <= 0) return FALSE; + + /* start convolution from out[kernelSize-1] to out[dataSize-1] (last) */ + for(i = kernelSize-1; i < dataSize; ++i) + { + for(j = i, k = 0; k < kernelSize; --j, ++k) + out[i] += x[j] * kernel[k]; + } + + /* convolution from out[0] to out[kernelSize-2] */ + for(i = 0; i < kernelSize - 1; ++i) + { + for(j = i, k = 0; j >= 0; --j, ++k) + out[i] += x[j] * kernel[k]; + } + + for(i=0;i datasize) return FALSE; + + snew(filtered,datasize); + + for(i=0;(inres); - - for(i=0; (inres); i++) { - if (search_str(nb,cb,*atoms->resinfo[i].name) != -1) - bb[i]=TRUE; - } - return bb; -} - static void check_oo(t_atoms *atoms) { char *OOO; @@ -388,9 +375,10 @@ "reads a trajectory file and computes the secondary structure for", "each time frame ", "calling the dssp program. If you do not have the dssp program,", - "get it. [TT]do_dssp[tt] assumes that the dssp executable is", - "/usr/local/bin/dssp. If this is not the case, then you should", - "set an environment variable [BB]DSSP[bb] pointing to the dssp", + "get it from http://swift.cmbi.ru.nl/gv/dssp. [TT]do_dssp[tt] assumes ", + "that the dssp executable is located in ", + "[TT]/usr/local/bin/dssp[tt]. If this is not the case, then you should", + "set an environment variable [TT]DSSP[tt] pointing to the dssp", "executable, e.g.: [PAR]", "[TT]setenv DSSP /opt/dssp/bin/dssp[tt][PAR]", "The structure assignment for each residue and time is written to an", @@ -474,7 +462,7 @@ read_tps_conf(ftp2fn(efTPS,NFILE,fnm),title,&top,&ePBC,&xp,NULL,box,FALSE); atoms=&(top.atoms); check_oo(atoms); - bPhbres=bPhobics(atoms); + bPhbres=bPhobics((int)atoms->nres,(char *)atoms->resinfo); get_index(atoms,ftp2fn_null(efNDX,NFILE,fnm),1,&gnx,&index,&grpnm); nres=0; diff -Nru gromacs-4.5.4/src/tools/expfit.c gromacs-4.5.5/src/tools/expfit.c --- gromacs-4.5.4/src/tools/expfit.c 2010-11-09 21:32:45.000000000 +0000 +++ gromacs-4.5.5/src/tools/expfit.c 2011-09-21 12:34:32.000000000 +0000 @@ -1,4 +1,5 @@ /* + * $Id: expfit.c,v 1.33 2005/08/29 19:39:11 lindahl Exp $ * * This source code is part of * @@ -49,10 +50,10 @@ #include "statutil.h" #include "index.h" -int nfp_ffn[effnNR] = { 0, 1, 2, 3, 2, 5, 7, 9, 3 }; +const int nfp_ffn[effnNR] = { 0, 1, 2, 3, 2, 5, 7, 9, 4, 3}; const char *s_ffn[effnNR+2] = { NULL, "none", "exp", "aexp", "exp_exp", "vac", - "exp5", "exp7", "exp9", NULL, NULL }; + "exp5", "exp7", "exp9","erffit", NULL, NULL }; /* We don't allow errest as a choice on the command line */ const char *longs_ffn[effnNR] = { @@ -64,6 +65,7 @@ "y = a1 exp(-x/a2) + a3 exp(-x/a4) + a5", "y = a1 exp(-x/a2) + a3 exp(-x/a4) + a5 exp(-x/a6) + a7", "y = a1 exp(-x/a2) + a3 exp(-x/a4) + a5 exp(-x/a6) + a7 exp(-x/a8) + a9", + "y = 1/2*(a1+a2) - 1/2*(a1-a2)*erf( (x-a3) /a4^2)", "y = a2*ee(a1,x) + (1-a2)*ee(a2,x)" }; @@ -84,6 +86,42 @@ return 0; return A*exp(-x/tau); } + +static real signum(real num){ + real sign; + if(num<0){ + sign=-1.0; + } + else { + sign=1.0; + } + return sign; +} + +void erffit (real x, real a[], real *y, real dyda[]) +{ +/* Fuction + * y=(a1+a2)/2-(a1-a2)/2*erf((x-a3)/a4^2) + */ + +real erfarg; +real erfval; +real erfarg2; +real derf; + + erfarg=(x-a[3])/(a[4]*a[4]); + erfarg2=erfarg*erfarg; + erfval=gmx_erf(erfarg)/2; + derf=(2./sqrt(M_PI))*(a[1]-a[2])/2*exp(-erfarg2)/(a[4]*a[4]); + + *y=(a[1]+a[2])/2-(a[1]-a[2])*erfval; + dyda[1]=1/2-erfval; + dyda[2]=1/2+erfval; + dyda[3]=derf; + dyda[4]=2*derf*erfarg; +} + + static void exp_one_parm(real x,real a[],real *y,real dyda[]) { @@ -283,7 +321,7 @@ typedef void (*myfitfn)(real x,real a[],real *y,real dyda[]); myfitfn mfitfn[effnNR] = { exp_one_parm, exp_one_parm, exp_two_parm, exp_3_parm, vac_2_parm, - exp_5_parm, exp_7_parm, exp_9_parm, errest_3_parm + exp_5_parm, exp_7_parm, exp_9_parm, erffit, errest_3_parm }; real fit_function(int eFitFn,real *parm,real x) @@ -318,7 +356,7 @@ snew(dum,ma+1); for(i=1; (i 2) fprintf(stderr," %10.5e",a[3]); + if (mfit > 3) + fprintf(stderr," %10.5e",a[4]); fprintf(stderr,"\n"); } j++; @@ -398,7 +438,7 @@ real do_lmfit(int ndata,real c1[],real sig[],real dt,real x0[], real begintimefit,real endtimefit,const output_env_t oenv, - gmx_bool bVerbose, int eFitFn,real fitparms[],int fix) + gmx_bool bVerbose, int eFitFn,real fitparms[],int fix) { FILE *fp; char buf[32]; @@ -484,7 +524,7 @@ fprintf(fp,"%10.5e %10.5e %10.5e\n", ttt,c1[j],fit_function(eFitFn,parm,ttt)); } - ffclose(fp); + fclose(fp); } } for(i=0;(i +#endif + +#include + + + +/* This is just a wrapper binary. +* The code that used to be in g_density.c is now in gmx_density.c, +* where the old main function is called gmx_density(). +*/ + +int main(int argc, char *argv[]) +{ + gmx_densorder(argc,argv); + return 0; +} + + + diff -Nru gromacs-4.5.4/src/tools/g_dos.c gromacs-4.5.5/src/tools/g_dos.c --- gromacs-4.5.4/src/tools/g_dos.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/g_dos.c 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,54 @@ +/* + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * Green Red Orange Magenta Azure Cyan Skyblue + */ +#ifdef HAVE_CONFIG_H +#include +#endif + +#include + + +/* This is just a wrapper binary. +* The code that used to be in g_dos.c is now in gmx_dos.c, +* where the old main function is called gmx_velacc(). +*/ +int +main(int argc, char *argv[]) +{ + gmx_dos(argc,argv); + return 0; +} + + + diff -Nru gromacs-4.5.4/src/tools/geminate.c gromacs-4.5.5/src/tools/geminate.c --- gromacs-4.5.4/src/tools/geminate.c 2010-11-09 21:32:45.000000000 +0000 +++ gromacs-4.5.5/src/tools/geminate.c 2011-09-21 12:34:32.000000000 +0000 @@ -47,6 +47,7 @@ #include #endif +#include #include "typedefs.h" #include "smalloc.h" #include "vec.h" @@ -700,6 +701,8 @@ gsl_vector_get(p, 0), gsl_vector_get(p, 1), GD->params); + fixGemACF(GD->ctTheory, nFitPoints); + /* Removing a bunch of points from the log-part. */ #ifdef HAVE_OPENMP #pragma omp parallel for schedule(dynamic) \ @@ -876,12 +879,25 @@ params->kd, s->fval, size, d2); - if (iter%10 == 1) + if (iter%1 == 0) { eq10v2(GD->ctTheory, time, nData, params->ka, params->kd, params); + /* fixGemACF(GD->ctTheory, nFitPoints); */ sprintf(dumpname, "Iter_%i.xvg", iter); for(i=0; inData; i++) - dumpdata[i] = (real)(GD->ctTheory[i]); + { + dumpdata[i] = (real)(GD->ctTheory[i]); +#ifdef HAS_ISFINITE + if (!isfinite(dumpdata[i])) +#elif defined HAS__ISFINITE + if (!_isfinite(dumpdata[i])) +#else + if (0) +#endif + { + gmx_fatal(FARGS, "Non-finite value in acf."); + } + } dumpN(dumpdata, GD->nData, dumpname); } } @@ -1213,3 +1229,90 @@ return r; } + +static void _patchBad(double *ct, int n, double dy) +{ + /* Just do lin. interpolation for now. */ + int i; + + for (i=1; i 1e-6) + { + ct[0] = 1.0; + fprintf(stderr, "|ct[0]-1.0| = %1.6d. Setting ct[0] to 1.0.\n", abs(ct[0]-1.0)); + } + + for (i=0; i +#endif + +#include + + + +/* This is just a wrapper binary. +*/ +int +main(int argc, char *argv[]) +{ + gmx_hydorder(argc,argv); + return 0; +} + + + diff -Nru gromacs-4.5.4/src/tools/gmx_anaeig.c gromacs-4.5.5/src/tools/gmx_anaeig.c --- gromacs-4.5.4/src/tools/gmx_anaeig.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_anaeig.c 2011-09-21 12:34:10.000000000 +0000 @@ -794,7 +794,7 @@ "can use [TT]rasmol -nmrpdb[tt] to view such a [TT].pdb[tt] file).[PAR]", " Overlap calculations between covariance analysis:[BR]", - " NOTE: the analysis should use the same fitting structure[PAR]", + " [BB]Note:[bb] the analysis should use the same fitting structure[PAR]", "[TT]-over[tt]: calculate the subspace overlap of the eigenvectors in", "file [TT]-v2[tt] with eigenvectors [TT]-first[tt] to [TT]-last[tt]", diff -Nru gromacs-4.5.4/src/tools/gmx_analyze.c gromacs-4.5.5/src/tools/gmx_analyze.c --- gromacs-4.5.4/src/tools/gmx_analyze.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_analyze.c 2011-09-21 12:34:32.000000000 +0000 @@ -888,21 +888,21 @@ int gmx_analyze(int argc,char *argv[]) { static const char *desc[] = { - "[TT]g_analyze[tt] reads an ascii file and analyzes data sets.", + "[TT]g_analyze[tt] reads an ASCII file and analyzes data sets.", "A line in the input file may start with a time", - "(see option [TT]-time[tt]) and any number of y values may follow.", + "(see option [TT]-time[tt]) and any number of [IT]y[it]-values may follow.", "Multiple sets can also be", - "read when they are separated by & (option [TT]-n[tt]),", - "in this case only one y value is read from each line.", + "read when they are separated by & (option [TT]-n[tt]);", + "in this case only one [IT]y[it]-value is read from each line.", "All lines starting with # and @ are skipped.", "All analyses can also be done for the derivative of a set", "(option [TT]-d[tt]).[PAR]", - "All options, except for [TT]-av[tt] and [TT]-power[tt] assume that the", + "All options, except for [TT]-av[tt] and [TT]-power[tt], assume that the", "points are equidistant in time.[PAR]", "[TT]g_analyze[tt] always shows the average and standard deviation of each", - "set. For each set it also shows the relative deviation of the third", + "set, as well as the relative deviation of the third", "and fourth cumulant from those of a Gaussian distribution with the same", "standard deviation.[PAR]", @@ -910,7 +910,7 @@ "Option [TT]-cc[tt] plots the resemblance of set i with a cosine of", "i/2 periods. The formula is:[BR]" - "2 (int0-T y(t) cos(i pi t) dt)^2 / int0-T y(t) y(t) dt[BR]", + "2 (int0-T y(t) cos(i [GRK]pi[grk] t) dt)^2 / int0-T y(t) y(t) dt[BR]", "This is useful for principal components obtained from covariance", "analysis, since the principal components of random diffusion are", "pure cosines.[PAR]", @@ -935,12 +935,12 @@ "Also an analytical block average curve is plotted, assuming", "that the autocorrelation is a sum of two exponentials.", "The analytical curve for the block average is:[BR]", - "f(t) = sigma sqrt(2/T ( a (tau1 ((exp(-t/tau1) - 1) tau1/t + 1)) +[BR]", - " (1-a) (tau2 ((exp(-t/tau2) - 1) tau2/t + 1)))),[BR]" + "f(t) = [GRK]sigma[grk][TT]*[tt]sqrt(2/T ( [GRK]alpha[grk] ([GRK]tau[grk]1 ((exp(-t/[GRK]tau[grk]1) - 1) [GRK]tau[grk]1/t + 1)) +[BR]", + " (1-[GRK]alpha[grk]) ([GRK]tau[grk]2 ((exp(-t/[GRK]tau[grk]2) - 1) [GRK]tau[grk]2/t + 1)))),[BR]" "where T is the total time.", - "a, tau1 and tau2 are obtained by fitting f^2(t) to error^2.", + "[GRK]alpha[grk], [GRK]tau[grk]1 and [GRK]tau[grk]2 are obtained by fitting f^2(t) to error^2.", "When the actual block average is very close to the analytical curve,", - "the error is sigma*sqrt(2/T (a tau1 + (1-a) tau2)).", + "the error is [GRK]sigma[grk][TT]*[tt]sqrt(2/T (a [GRK]tau[grk]1 + (1-a) [GRK]tau[grk]2)).", "The complete derivation is given in", "B. Hess, J. Chem. Phys. 116:209-217, 2002.[PAR]", @@ -955,12 +955,12 @@ "Option [TT]-gem[tt] fits bimolecular rate constants ka and kb", "(and optionally kD) to the hydrogen bond autocorrelation function", "according to the reversible geminate recombination model. Removal of", - "the ballistic component first is strongly adviced. The model is presented in", + "the ballistic component first is strongly advised. The model is presented in", "O. Markovitch, J. Chem. Phys. 129:084505, 2008.[PAR]", "Option [TT]-filter[tt] prints the RMS high-frequency fluctuation", "of each set and over all sets with respect to a filtered average.", - "The filter is proportional to cos(pi t/len) where t goes from -len/2", + "The filter is proportional to cos([GRK]pi[grk] t/len) where t goes from -len/2", "to len/2. len is supplied with the option [TT]-filter[tt].", "This filter reduces oscillations with period len/2 and len by a factor", "of 0.79 and 0.33 respectively.[PAR]", @@ -970,7 +970,7 @@ "Option [TT]-power[tt] fits the data to b t^a, which is accomplished", "by fitting to a t + b on log-log scale. All points after the first", - "zero or negative value are ignored.[PAR]" + "zero or with a negative value are ignored.[PAR]" "Option [TT]-luzar[tt] performs a Luzar & Chandler kinetics analysis", "on output from [TT]g_hbond[tt]. The input file can be taken directly", @@ -1012,7 +1012,7 @@ { "-xydy", FALSE, etBOOL, {&bXYdy}, "Interpret second data set as error in the y values for integrating" }, { "-regression",FALSE,etBOOL,{&bRegression}, - "Perform a linear regression analysis on the data. If [TT]-xydy[tt] is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize chi^2 = (y - A0 x0 - A1 x1 - ... - AN xN)^2 where now Y is the first data set in the input file and xi the others. Do read the information at the option [TT]-time[tt]." }, + "Perform a linear regression analysis on the data. If [TT]-xydy[tt] is set a second set will be interpreted as the error bar in the Y value. Otherwise, if multiple data sets are present a multilinear regression will be performed yielding the constant A that minimize [GRK]chi[grk]^2 = (y - A0 x0 - A1 x1 - ... - AN xN)^2 where now Y is the first data set in the input file and xi the others. Do read the information at the option [TT]-time[tt]." }, { "-luzar", FALSE, etBOOL, {&bLuzar}, "Do a Luzar and Chandler analysis on a correlation function and related as produced by [TT]g_hbond[tt]. When in addition the [TT]-xydy[tt] flag is given the second and fourth column will be interpreted as errors in c(t) and n(t)." }, { "-temp", FALSE, etREAL, {&temp}, @@ -1022,7 +1022,7 @@ { "-fitend", FALSE, etREAL, {&fit_end}, "Time (ps) where to stop fitting the correlation functions in order to obtain the forward and backward rate constants for HB breaking and formation. Only with [TT]-gem[tt]" }, { "-smooth",FALSE, etREAL, {&smooth_tail_start}, - "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/tau)" }, + "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/[GRK]tau[grk])" }, { "-nbmin", FALSE, etINT, {&nb_min}, "HIDDENMinimum number of blocks for block averaging" }, { "-resol", FALSE, etINT, {&resol}, diff -Nru gromacs-4.5.4/src/tools/gmx_bar.c gromacs-4.5.5/src/tools/gmx_bar.c --- gromacs-4.5.4/src/tools/gmx_bar.c 2011-03-14 13:33:32.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_bar.c 2011-09-21 12:34:10.000000000 +0000 @@ -56,6 +56,11 @@ #include "gmx_ana.h" #include "maths.h" +/* Suppress Cygwin compiler warnings from using newlib version of + * ctype.h */ +#ifdef GMX_CYGWIN +#undef isdigit +#endif /* the dhdl.xvg data from a simulation (actually obsolete, but still here for reading the dhdl.xvg file*/ @@ -2482,54 +2487,54 @@ "Every individual BAR free energy difference relies on two ", "simulations at different states: say state A and state B, as", - "controlled by a parameter, lambda (see the mdp parameter", + "controlled by a parameter, [GRK]lambda[grk] (see the [TT].mdp[tt] parameter", "[TT]init_lambda[tt]). The BAR method calculates a ratio of weighted", "average of the Hamiltonian difference of state B given state A and", - "vice versa. If the Hamiltonian does not linearly depend on lambda", + "vice versa. If the Hamiltonian does not depend linearly on [GRK]lambda[grk]", "(in which case we can extrapolate the derivative of the Hamiltonian", - "with respect to lambda, as is the default when [TT]free_energy[tt] is on),", + "with respect to [GRK]lambda[grk], as is the default when [TT]free_energy[tt] is on),", "the energy differences to the other state need to be calculated", "explicitly during the simulation. This can be controlled with", - "the mdp option [TT]foreign_lambda[tt].[PAR]", + "the [TT].mdp[tt] option [TT]foreign_lambda[tt].[PAR]", - "Input option [TT]-f[tt] expects multiple dhdl files. ", + "Input option [TT]-f[tt] expects multiple [TT]dhdl.xvg[tt] files. ", "Two types of input files are supported:[BR]", - "[TT]*[tt] Files with only one y-value, for such files it is assumed ", - " that the y-value is dH/dlambda and that the Hamiltonian depends ", - " linearly on lambda. The lambda value of the simulation is inferred ", - " from the subtitle if present, otherwise from a number in the", + "[TT]*[tt] Files with only one [IT]y[it]-value, for such files it is assumed ", + " that the [IT]y[it]-value is dH/d[GRK]lambda[grk] and that the Hamiltonian depends ", + " linearly on [GRK]lambda[grk]. The [GRK]lambda[grk] value of the simulation is inferred ", + " from the subtitle (if present), otherwise from a number in the", " subdirectory in the file name.", "[BR]", - "[TT]*[tt] Files with more than one y-value. The files should have columns ", - " with dH/dlambda and Delta lambda. The lambda values are inferred ", - " from the legends: lambda of the simulation from the legend of dH/dlambda ", - " and the foreign lambda's from the legends of Delta H.[PAR]", - "The lambda of the simulation is parsed from dhdl.xvg file's legend ", - "containing the string 'dH', the foreign lambdas from the legend ", + "[TT]*[tt] Files with more than one [IT]y[it]-value. The files should have columns ", + " with dH/d[GRK]lambda[grk] and [GRK]Delta[grk][GRK]lambda[grk]. The [GRK]lambda[grk] values are inferred ", + " from the legends: [GRK]lambda[grk] of the simulation from the legend of dH/d[GRK]lambda[grk] ", + " and the foreign [GRK]lambda[grk] values from the legends of Delta H.[PAR]", + "The [GRK]lambda[grk] of the simulation is parsed from [TT]dhdl.xvg[tt] file's legend ", + "containing the string 'dH', the foreign [GRK]lambda[grk] values from the legend ", "containing the capitalized letters 'D' and 'H'. The temperature ", "is parsed from the legend line containing 'T ='.[PAR]", - "The input option [TT]-g[tt] expects multiple .edr files. ", + "The input option [TT]-g[tt] expects multiple [TT].edr[tt] files. ", "These can contain either lists of energy differences (see the", - "mdp option separate_dhdl_file), or a series of histograms", - "(see the mdp options [TT]dh_hist_size[tt] and [TT]dh_hist_spacing[tt]).", - "The temperature and lambda values are automatically deduced from", - "the ener.edr file.[PAR]" + "[TT].mdp[tt] option [TT]separate_dhdl_file[tt]), or a series of histograms", + "(see the [TT].mdp[tt] options [TT]dh_hist_size[tt] and [TT]dh_hist_spacing[tt]).", + "The temperature and [GRK]lambda[grk] values are automatically deduced from", + "the [TT]ener.edr[tt] file.[PAR]" "The free energy estimates are determined using BAR with bisection, ", - "the precision of the output is set with [TT]-prec[tt]. ", + "with the precision of the output set with [TT]-prec[tt]. ", "An error estimate taking into account time correlations ", "is made by splitting the data into blocks and determining ", "the free energy differences over those blocks and assuming ", "the blocks are independent. ", "The final error estimate is determined from the average variance ", - "over 5 blocks. A range of blocks numbers for error estimation can ", + "over 5 blocks. A range of block numbers for error estimation can ", "be provided with the options [TT]-nbmin[tt] and [TT]-nbmax[tt].[PAR]", "[TT]g_bar[tt] tries to aggregate samples with the same 'native' and 'foreign'", - "lambda values, but always assumes independent samples: note that", + "[GRK]lambda[grk] values, but always assumes independent samples. [BB]Note[bb] that", "when aggregating energy differences/derivatives with different", - "sampling intervals, this is almost certainly not correct: usually", + "sampling intervals, this is almost certainly not correct. Usually", "subsequent energies are correlated and different time intervals mean", "different degrees of correlation between samples.[PAR]", @@ -2539,8 +2544,8 @@ "difference estimates and phase space overlap measures in units of ", "kT (together with their computed error estimate). The printed ", "values are:[BR]", - "[TT]*[tt] lam_A: the lambda values for point A.[BR]", - "[TT]*[tt] lam_B: the lambda values for point B.[BR]", + "[TT]*[tt] lam_A: the [GRK]lambda[grk] values for point A.[BR]", + "[TT]*[tt] lam_B: the [GRK]lambda[grk] values for point B.[BR]", "[TT]*[tt] DG: the free energy estimate.[BR]", "[TT]*[tt] s_A: an estimate of the relative entropy of B in A.[BR]", "[TT]*[tt] s_A: an estimate of the relative entropy of A in B.[BR]", @@ -2710,7 +2715,7 @@ fpb = NULL; if (opt2bSet("-o",NFILE,fnm)) { - sprintf(buf,"%s (%s)","\\DeltaG",unit_energy); + sprintf(buf,"%s (%s)","\\DeltaG","kT"); fpb = xvgropen_type(opt2fn("-o",NFILE,fnm),"Free energy differences", "\\lambda",buf,exvggtXYDY,oenv); } @@ -2718,7 +2723,7 @@ fpi = NULL; if (opt2bSet("-oi",NFILE,fnm)) { - sprintf(buf,"%s (%s)","\\DeltaG",unit_energy); + sprintf(buf,"%s (%s)","\\DeltaG","kT"); fpi = xvgropen(opt2fn("-oi",NFILE,fnm),"Free energy integral", "\\lambda",buf,oenv); } diff -Nru gromacs-4.5.4/src/tools/gmx_bundle.c gromacs-4.5.5/src/tools/gmx_bundle.c --- gromacs-4.5.4/src/tools/gmx_bundle.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_bundle.c 2011-09-21 12:34:10.000000000 +0000 @@ -185,7 +185,7 @@ "With option [TT]-oa[tt] the top, mid (or kink when [TT]-ok[tt] is set)", "and bottom points of each axis", "are written to a [TT].pdb[tt] file each frame. The residue numbers correspond", - "to the axis numbers. When viewing this file with [TT]rasmol[tt], use the", + "to the axis numbers. When viewing this file with Rasmol, use the", "command line option [TT]-nmrpdb[tt], and type [TT]set axis true[tt] to", "display the reference axis." }; @@ -195,7 +195,7 @@ { "-na", FALSE, etINT, {&n}, "Number of axes" }, { "-z", FALSE, etBOOL, {&bZ}, - "Use the Z-axis as reference iso the average axis" } + "Use the [IT]z[it]-axis as reference instead of the average axis" } }; FILE *out,*flen,*fdist,*fz,*ftilt,*ftiltr,*ftiltl; FILE *fkink=NULL,*fkinkr=NULL,*fkinkl=NULL; diff -Nru gromacs-4.5.4/src/tools/gmx_chi.c gromacs-4.5.5/src/tools/gmx_chi.c --- gromacs-4.5.4/src/tools/gmx_chi.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_chi.c 2011-09-21 12:34:10.000000000 +0000 @@ -1006,14 +1006,14 @@ int gmx_chi(int argc,char *argv[]) { const char *desc[] = { - "[TT]g_chi[tt] computes phi, psi, omega and chi dihedrals for all your ", + "[TT]g_chi[tt] computes [GRK]phi[grk], [GRK]psi[grk], [GRK]omega[grk], and [GRK]chi[grk] dihedrals for all your ", "amino acid backbone and sidechains.", "It can compute dihedral angle as a function of time, and as", "histogram distributions.", "The distributions [TT](histo-(dihedral)(RESIDUE).xvg[tt]) are cumulative over all residues of each type.[PAR]", "If option [TT]-corr[tt] is given, the program will", "calculate dihedral autocorrelation functions. The function used", - "is C(t) = < cos(chi(tau)) cos(chi(tau+t)) >. The use of cosines", + "is C(t) = < cos([GRK]chi[grk]([GRK]tau[grk])) cos([GRK]chi[grk]([GRK]tau[grk]+t)) >. The use of cosines", "rather than angles themselves, resolves the problem of periodicity.", "(Van der Spoel & Berendsen (1997), Biophys. J. 72, 2032-2041).", "Separate files for each dihedral of each residue", @@ -1024,27 +1024,27 @@ "These can be in radians or degrees.[PAR]", "A log file (argument [TT]-g[tt]) is also written. This contains [BR]", "(a) information about the number of residues of each type.[BR]", - "(b) The NMR 3J coupling constants from the Karplus equation.[BR]", + "(b) The NMR ^3J coupling constants from the Karplus equation.[BR]", "(c) a table for each residue of the number of transitions between ", - "rotamers per nanosecond, and the order parameter S2 of each dihedral.[BR]", - "(d) a table for each residue of the rotamer occupancy.[BR]", - "All rotamers are taken as 3-fold, except for omegas and chi-dihedrals", - "to planar groups (i.e. chi2 of aromatics Asp and Asn, chi3 of Glu", - "and Gln, and chi4 of Arg), which are 2-fold. \"rotamer 0\" means ", + "rotamers per nanosecond, and the order parameter S^2 of each dihedral.[BR]", + "(d) a table for each residue of the rotamer occupancy.[PAR]", + "All rotamers are taken as 3-fold, except for [GRK]omega[grk] and [GRK]chi[grk] dihedrals", + "to planar groups (i.e. [GRK]chi[grk]2 of aromatics, Asp and Asn; [GRK]chi[grk]3 of Glu", + "and Gln; and [GRK]chi[grk]4 of Arg), which are 2-fold. \"rotamer 0\" means ", "that the dihedral was not in the core region of each rotamer. ", "The width of the core region can be set with [TT]-core_rotamer[tt][PAR]", - "The S2 order parameters are also output to an [TT].xvg[tt] file", + "The S^2 order parameters are also output to an [TT].xvg[tt] file", "(argument [TT]-o[tt] ) and optionally as a [TT].pdb[tt] file with", - "the S2 values as B-factor (argument [TT]-p[tt]). ", + "the S^2 values as B-factor (argument [TT]-p[tt]). ", "The total number of rotamer transitions per timestep", "(argument [TT]-ot[tt]), the number of transitions per rotamer", - "(argument [TT]-rt[tt]), and the 3J couplings (argument [TT]-jc[tt]), ", + "(argument [TT]-rt[tt]), and the ^3J couplings (argument [TT]-jc[tt]), ", "can also be written to [TT].xvg[tt] files.[PAR]", - "If [TT]-chi_prod[tt] is set (and maxchi > 0), cumulative rotamers, e.g.", - "1+9(chi1-1)+3(chi2-1)+(chi3-1) (if the residue has three 3-fold ", - "dihedrals and maxchi >= 3)", + "If [TT]-chi_prod[tt] is set (and [TT]-maxchi[tt] > 0), cumulative rotamers, e.g.", + "1+9([GRK]chi[grk]1-1)+3([GRK]chi[grk]2-1)+([GRK]chi[grk]3-1) (if the residue has three 3-fold ", + "dihedrals and [TT]-maxchi[tt] >= 3)", "are calculated. As before, if any dihedral is not in the core region,", "the rotamer is taken to be 0. The occupancies of these cumulative ", "rotamers (starting with rotamer 0) are written to the file", @@ -1053,17 +1053,17 @@ "are written to [TT]chiproduct(RESIDUE)(nresnr).xvg[tt] ", "and their occupancies to [TT]histo-chiproduct(RESIDUE)(nresnr).xvg[tt].[PAR]", - "The option [TT]-r[tt] generates a contour plot of the average omega angle", - "as a function of the phi and psi angles, that is, in a Ramachandran plot", - "the average omega angle is plotted using color coding.", + "The option [TT]-r[tt] generates a contour plot of the average [GRK]omega[grk] angle", + "as a function of the [GRK]phi[grk] and [GRK]psi[grk] angles, that is, in a Ramachandran plot", + "the average [GRK]omega[grk] angle is plotted using color coding.", }; const char *bugs[] = { "Produces MANY output files (up to about 4 times the number of residues in the protein, twice that if autocorrelation functions are calculated). Typically several hundred files are output.", - "Phi and psi dihedrals are calculated in a non-standard way, using H-N-CA-C for phi instead of C(-)-N-CA-C, and N-CA-C-O for psi instead of N-CA-C-N(+). This causes (usually small) discrepancies with the output of other tools like [TT]g_rama[tt].", + "[GRK]phi[grk] and [GRK]psi[grk] dihedrals are calculated in a non-standard way, using H-N-CA-C for [GRK]phi[grk] instead of C(-)-N-CA-C, and N-CA-C-O for [GRK]psi[grk] instead of N-CA-C-N(+). This causes (usually small) discrepancies with the output of other tools like [TT]g_rama[tt].", "[TT]-r0[tt] option does not work properly", - "Rotamers with multiplicity 2 are printed in chi.log as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0" + "Rotamers with multiplicity 2 are printed in [TT]chi.log[tt] as if they had multiplicity 3, with the 3rd (g(+)) always having probability 0" }; /* defaults */ @@ -1079,13 +1079,13 @@ { "-r0", FALSE, etINT, {&r0}, "starting residue" }, { "-phi", FALSE, etBOOL, {&bPhi}, - "Output for Phi dihedral angles" }, + "Output for [GRK]phi[grk] dihedral angles" }, { "-psi", FALSE, etBOOL, {&bPsi}, - "Output for Psi dihedral angles" }, + "Output for [GRK]psi[grk] dihedral angles" }, { "-omega",FALSE, etBOOL, {&bOmega}, - "Output for Omega dihedrals (peptide bonds)" }, + "Output for [GRK]omega[grk] dihedrals (peptide bonds)" }, { "-rama", FALSE, etBOOL, {&bRama}, - "Generate Phi/Psi and Chi1/Chi2 ramachandran plots" }, + "Generate [GRK]phi[grk]/[GRK]psi[grk] and [GRK]chi[grk]1/[GRK]chi[grk]2 Ramachandran plots" }, { "-viol", FALSE, etBOOL, {&bViol}, "Write a file that gives 0 or 1 for violated Ramachandran angles" }, { "-periodic", FALSE, etBOOL, {&bPBC}, @@ -1095,13 +1095,13 @@ { "-rad", FALSE, etBOOL, {&bRAD}, "in angle vs time files, use radians rather than degrees."}, { "-shift", FALSE, etBOOL, {&bShift}, - "Compute chemical shifts from Phi/Psi angles" }, + "Compute chemical shifts from [GRK]phi[grk]/[GRK]psi[grk] angles" }, { "-binwidth", FALSE, etINT, {&ndeg}, "bin width for histograms (degrees)" }, { "-core_rotamer", FALSE, etREAL, {&core_frac}, "only the central [TT]-core_rotamer[tt]*(360/multiplicity) belongs to each rotamer (the rest is assigned to rotamer 0)" }, { "-maxchi", FALSE, etENUM, {maxchistr}, - "calculate first ndih Chi dihedrals" }, + "calculate first ndih [GRK]chi[grk] dihedrals" }, { "-normhisto", FALSE, etBOOL, {&bNormHisto}, "Normalize histograms" }, { "-ramomega",FALSE,etBOOL, {&bRamOmega}, diff -Nru gromacs-4.5.4/src/tools/gmx_cluster.c gromacs-4.5.5/src/tools/gmx_cluster.c --- gromacs-4.5.4/src/tools/gmx_cluster.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_cluster.c 2011-09-21 12:34:10.000000000 +0000 @@ -1256,9 +1256,10 @@ for(i=0; i +#endif +#include +#include "sysstuff.h" +#include "string.h" +#include "string2.h" +#include "typedefs.h" +#include "smalloc.h" +#include "macros.h" +#include "gstat.h" +#include "vec.h" +#include "xvgr.h" +#include "pbc.h" +#include "copyrite.h" +#include "futil.h" +#include "statutil.h" +#include "index.h" +#include "tpxio.h" +#include "physics.h" +#include "matio.h" +#include "dens_filter.h" +#include "binsearch.h" +#include "powerspect.h" +#include "gmx_ana.h" + +#ifdef GMX_DOUBLE +#define FLOOR(x) ((int) floor(x)) +#else +#define FLOOR(x) ((int) floorf(x)) +#endif + +enum {methSEL, methBISECT, methFUNCFIT, methNR}; + +static void center_coords(t_atoms *atoms,matrix box,rvec x0[],int axis) +{ + int i,m; + real tmass,mm; + rvec com,shift,box_center; + + tmass = 0; + clear_rvec(com); + for(i=0; (inr); i++) + { + mm = atoms->atom[i].m; + tmass += mm; + for(m=0; (mnr); i++) + rvec_dec(x0[i],shift); +} + + +static void density_in_time (const char *fn, atom_id **index ,int gnx[], int grpn, real bw, real bwz, int nsttblock, real *****Densdevel, int *xslices, int *yslices, int *zslices,int *tblock, t_topology *top, int ePBC, int axis,gmx_bool bCenter, gmx_bool bps1d, const output_env_t oenv) + +{ +/* + * *****Densdevel pointer to array of density values in slices and frame-blocks Densdevel[*nsttblock][*xslices][*yslices][*zslices] + * Densslice[x][y][z] + * nsttblock - nr of frames in each time-block + * bw widths of normal slices + * + * axis - axis direction (normal to slices) + * nndx - number ot atoms in **index + * grpn - group number in index + */ + t_trxstatus *status; + gmx_rmpbc_t gpbc=NULL; + matrix box; /* Box - 3x3 -each step*/ + rvec *x0; /* List of Coord without PBC*/ + int natoms,i,j,k,n, /* loop indices, checks etc*/ + ax1=0,ax2=0, /* tangent directions */ + framenr=0, /* frame number in trajectory*/ + slicex, slicey, slicez; /*slice # of x y z position */ + real ***Densslice=NULL; /* Density-slice in one frame*/ + real dscale; /*physical scaling factor*/ + real t,x,y,z; /* time and coordinates*/ + rvec bbww; + + *tblock=0;/* blocknr in block average - initialise to 0*/ + /* Axis: X=0, Y=1,Z=2 */ + switch(axis) + { + case 0: + ax1=YY; ax2=ZZ; /*Surface: YZ*/ + break; + case 1: + ax1=ZZ; ax2=XX; /* Surface : XZ*/ + break; + case 2: + ax1 = XX; ax2 = YY; /* Surface XY*/ + break; + default: + gmx_fatal(FARGS,"Invalid axes. Terminating\n"); + } + + if( (natoms= read_first_x(oenv,&status,fn,&t,&x0,box)==0)) + gmx_fatal(FARGS, "Could not read coordinates from file"); /* Open trajectory for read*/ + + + *zslices=1+FLOOR(box[axis][axis]/bwz); + *yslices=1+FLOOR(box[ax2][ax2]/bw); + *xslices=1+FLOOR(box[ax1][ax1]/bw); + if(bps1d) + { + if(*xslices<*yslices) *xslices=1; + else *yslices=1; + } + fprintf(stderr, + "\nDividing the box in %5d x %5d x %5d slices with binw %f along axis %d\n",*xslices,*yslices,*zslices,bw,axis ); + + + /****Start trajectory processing***/ + + /*Initialize Densdevel and PBC-remove*/ + gpbc=gmx_rmpbc_init(&top->idef,ePBC,top->atoms.nr,box); + + *Densdevel=NULL; + + do + { + bbww[XX] = box[ax1][ax1]/ *xslices; + bbww[YY] = box[ax2][ax2]/ *yslices; + bbww[ZZ] = box[axis][axis]/ *zslices; + gmx_rmpbc(gpbc,top->atoms.nr,box,x0); + /*Reset Densslice every nsttblock steps*/ + if ( framenr % nsttblock==0 ) + { + snew(Densslice,*xslices); + for (i=0;i<*xslices;i++) + { + snew(Densslice[i],*yslices); + for (j=0;j<*yslices;j++) + { + snew(Densslice[i][j],*zslices); + } + } + + /*Allocate Memory to extra frame in Densdevel - rather stupid approach: *A single frame each time, although only every nsttblock steps.*/ + srenew(*Densdevel,*tblock+1); + + } + + + dscale=(*xslices)*(*yslices)*(*zslices)*AMU/ (box[ax1][ax1]*box[ax2][ax2]*box[axis][axis]*nsttblock*(NANO*NANO*NANO)); + + if (bCenter) + center_coords(&top->atoms,box,x0,axis); + + + for (j=0;jbox[ax1][ax1]) + x-=box[ax1][ax1]; + + while (y<0) + y+=box[ax2][ax2]; + while(y>box[ax2][ax2]) + y-=box[ax2][ax2]; + + while (z<0) + z+=box[axis][axis]; + while(z>box[axis][axis]) + z-=box[axis][axis]; + + slicex=((int) (x/bbww[XX])) % *xslices; + slicey=((int) (y/bbww[YY])) % *yslices; + slicez=((int) (z/bbww[ZZ])) % *zslices; + Densslice[slicex][slicey][slicez]+=(top->atoms.atom[index[0][j]].m*dscale); + + + } + + framenr++; + + if(framenr % nsttblock == 0) + { + /*Implicit incrementation of Densdevel via renewal of Densslice*/ + /*only every nsttblock steps*/ + (*Densdevel)[*tblock]=Densslice; + (*tblock)++; + } + + } while(read_next_x(oenv,status,&t,natoms,x0,box)); + + + /*Free memory we no longer need and exit.*/ + gmx_rmpbc_done(gpbc); + close_trj(status); + + if (0) + { + FILE *fp; + fp = fopen("koko.xvg","w"); + for(j=0; (j<*zslices); j++) + { + fprintf(fp,"%5d",j); + for(i=0; (i<*tblock); i++) + { + fprintf(fp," %10g",(*Densdevel)[i][9][1][j]); + } + fprintf(fp,"\n"); + } + fclose(fp); + } + +} + + + +static void printdensavg(char *fldfn, real ****Densmap, int xslices, int yslices, int zslices, int tdim) +{ +/*Debug-filename and filehandle*/ + FILE *fldH; + int n,i,j,k; + real totdens=0; + fldH=ffopen(fldfn,"w"); + fprintf(fldH,"%i %i %i %i\n",tdim, xslices,yslices,zslices); + for(n=0;n1.0 || abs(deltandx)>3){ + pos=zperm[ndx1]; + spread=-1; + } + else { + pos=zperm[ndx1]+alpha*deltandx; + spread=binwidth*deltandx; + } + * For the 2nd interface can use the same formulation, since alpha should become negative ie: + * alpha=(densmid-Densmap[n][i][j][zperm[ndx2]])/(Densmap[n][i][j][zperm[nxd2+1]]-Densmap[n][i][j][zperm[ndx2]]); + * deltandx=zperm[ndx2+1]-zperm[ndx2]; + * pos=zperm[ndx2]+alpha*deltandx; */ + + /*After filtering we use the direct approach */ + int1[n][j+(i*yslices)]->Z=(zperm[ndx1]+onehalf)*binwidth; + int1[n][j+(i*yslices)]->t=binwidth; + int2[n][j+(i*yslices)]->Z=(zperm[ndx2]+onehalf)*binwidth; + int2[n][j+(i*yslices)]->t=binwidth; + } + } + } + } + + if(method==methFUNCFIT) + { + /*Assume a box divided in 2 along midpoint of z for starters*/ + startpoint=0.0; + endpoint = binwidth*zslices; + splitpoint = (startpoint+endpoint)/2.0; + /*Initial fit proposals*/ + beginfit1[0] = dens1; + beginfit1[1] = dens2; + beginfit1[2] = (splitpoint/2); + beginfit1[3] = 0.5; + + beginfit2[0] = dens2; + beginfit2[1] = dens1; + beginfit2[2] = (3*splitpoint/2); + beginfit2[3] = 0.5; + + snew(zDensavg,zslices); + snew(sigma1,zslices); + snew(sigma2,zslices); + + for(k=0;kZ=fit1[2]; + int1[n][j+(yslices*i)]->t=fit1[3]; + do_lmfit(zslices,Densmap[n][i][j],sigma2,binwidth,NULL,splitpoint,endpoint,oenv,FALSE,effnERF,fit2,2); + int2[n][j+(yslices*i)]->Z=fit2[2]; + int2[n][j+(yslices*i)]->t=fit2[3]; + } + } + } + } + + + *intf1=int1; + *intf2=int2; + +} + +static void writesurftoxpms(t_interf ***surf1,t_interf ***surf2, int tblocks,int xbins, int ybins, int zbins, real bw,real bwz, char **outfiles,int maplevels ) +{ + char numbuf[12]; + int n, i, j; + real **profile1, **profile2; + real max1, max2, min1, min2, *xticks, *yticks; + t_rgb lo={0,0,0}; + t_rgb hi={1,1,1}; + FILE *xpmfile1, *xpmfile2; + +/*Prepare xpm structures for output*/ + +/*Allocate memory to tick's and matrices*/ + snew (xticks,xbins+1); + snew (yticks,ybins+1); + + profile1=mk_matrix(xbins,ybins,FALSE); + profile2=mk_matrix(xbins,ybins,FALSE); + + for (i=0;iZ; + profile2[i][j]=(surf2[n][j+ybins*i])->Z; + /*Finding max and min values*/ + if(profile1[i][j]>max1) max1=profile1[i][j]; + if(profile1[i][j]max2) max2=profile2[i][j]; + if(profile2[i][j]Z,(int1[n][j+ybins*i])->t); + fprintf(raw2,"%i %i %8.5f %6.4f\n",i,j,(int2[n][j+ybins*i])->Z,(int2[n][j+ybins*i])->t); + } + } + } + + ffclose(raw1); + ffclose(raw2); +} + + + +int gmx_densorder(int argc,char *argv[]) +{ + static const char *desc[] = { + "A small program to reduce a two-phase density distribution", + "along an axis, computed over a MD trajectory", + "to 2D surfaces fluctuating in time, by a fit to", + "a functional profile for interfacial densities", + "A time-averaged spatial representation of the" , + "interfaces can be output with the option -tavg" + }; + + /* Extra arguments - but note how you always get the begin/end + * options when running the program, without mentioning them here! + */ + + output_env_t oenv; + t_topology *top; + char title[STRLEN],**grpname; + int ePBC, *ngx; + static real binw=0.2; + static real binwz=0.05; + static real dens1=0.00; + static real dens2=1000.00; + static int ftorder=0; + static int nsttblock=100; + static int axis= 2; + static char *axtitle="Z"; + static int ngrps=1; + atom_id **index; /* Index list for single group*/ + int xslices, yslices, zslices, tblock; + static gmx_bool bGraph=FALSE; + static gmx_bool bCenter = FALSE; + static gmx_bool bFourier=FALSE; + static gmx_bool bRawOut=FALSE; + static gmx_bool bOut=FALSE; + static gmx_bool b1d=FALSE; + static int nlevels=100; + /*Densitymap - Densmap[t][x][y][z]*/ + real ****Densmap=NULL; + /* Surfaces surf[t][surf_x,surf_y]*/ + t_interf ***surf1, ***surf2; + + static const char *meth[]={NULL,"bisect","functional",NULL}; + int eMeth; + + char **graphfiles, **rawfiles, **spectra; /* Filenames for xpm-surface maps, rawdata and powerspectra */ + int nfxpm=-1,nfraw, nfspect; /* # files for interface maps and spectra = # interfaces */ + + t_pargs pa[] = { + { "-1d", FALSE, etBOOL, {&b1d}, + "Pseudo-1d interface geometry"}, + { "-bw",FALSE,etREAL,{&binw}, + "Binwidth of density distribution tangential to interface"}, + { "-bwn", FALSE, etREAL, {&binwz}, + "Binwidth of density distribution normal to interface"}, + { "-order", FALSE, etINT,{&ftorder}, + "Order of Gaussian filter, order 0 equates to NO filtering"}, + {"-axis", FALSE, etSTR,{&axtitle}, + "Axis Direction - X, Y or Z"}, + {"-method",FALSE ,etENUM,{meth}, + "Interface location method"}, + {"-d1", FALSE, etREAL,{&dens1}, + "Bulk density phase 1 (at small z)"}, + {"-d2", FALSE, etREAL,{&dens2}, + "Bulk density phase 2 (at large z)"}, + { "-tblock",FALSE,etINT,{&nsttblock}, + "Number of frames in one time-block average"}, + { "-nlevel", FALSE,etINT, {&nlevels}, + "Number of Height levels in 2D - XPixMaps"} + }; + + + t_filenm fnm[] = { + { efTPX, "-s", NULL, ffREAD }, /* this is for the topology */ + { efTRX, "-f", NULL, ffREAD }, /* and this for the trajectory */ + { efNDX, "-n", NULL, ffREAD}, /* this is to select groups */ + { efDAT, "-o", "Density4D",ffOPTWR}, /* This is for outputting the entire 4D densityfield in binary format */ + { efOUT, "-or", NULL,ffOPTWRMULT}, /* This is for writing out the entire information in the t_interf arrays */ + { efXPM, "-og" ,"interface",ffOPTWRMULT},/* This is for writing out the interface meshes - one xpm-file per tblock*/ + { efOUT, "-Spect","intfspect",ffOPTWRMULT}, /* This is for the trajectory averaged Fourier-spectra*/ + }; + +#define NFILE asize(fnm) + + CopyRight(stderr,argv[0]); + + /* This is the routine responsible for adding default options, + * calling the X/motif interface, etc. */ + parse_common_args(&argc,argv,PCA_CAN_TIME | PCA_CAN_VIEW, + NFILE,fnm,asize(pa),pa,asize(desc),desc,0,NULL,&oenv); + + + eMeth=nenum(meth); + bFourier=opt2bSet("-Spect",NFILE,fnm); + bRawOut=opt2bSet("-or",NFILE,fnm); + bGraph=opt2bSet("-og",NFILE,fnm); + bOut=opt2bSet("-o",NFILE,fnm); + top=read_top(ftp2fn(efTPX,NFILE,fnm),&ePBC); + snew(grpname,ngrps); + snew(index,ngrps); + snew(ngx,ngrps); + +/* Calculate axis */ + axis = toupper(axtitle[0]) - 'X'; + + get_index(&top->atoms,ftp2fn_null(efNDX,NFILE,fnm),ngrps,ngx,index,grpname); + + density_in_time(ftp2fn(efTRX,NFILE,fnm),index,ngx,ngrps,binw,binwz,nsttblock,&Densmap,&xslices,&yslices,&zslices,&tblock,top,ePBC,axis,bCenter,b1d,oenv); + + if(ftorder>0) + { + filterdensmap(Densmap,xslices,yslices,zslices,tblock,2*ftorder+1); + } + + if (bOut) + { + outputfield(opt2fn("-o",NFILE,fnm),Densmap,xslices,yslices,zslices,tblock); + } + + interfaces_txy(Densmap,xslices,yslices,zslices,tblock,binwz,eMeth,dens1,dens2,&surf1,&surf2,oenv); + + if(bGraph) + { + + /*Output surface-xpms*/ + nfxpm=opt2fns(&graphfiles,"-og",NFILE,fnm); + if(nfxpm!=2) + { + gmx_fatal(FARGS,"No or not correct number (2) of output-files: %d",nfxpm); + } + writesurftoxpms(surf1, surf2, tblock,xslices,yslices,zslices,binw,binwz,graphfiles,zslices); + } + + + + + +/*Output raw-data*/ + if (bRawOut) + { + nfraw=opt2fns(&rawfiles,"-or",NFILE,fnm); + if(nfraw!=2) + { + gmx_fatal(FARGS,"No or not correct number (2) of output-files: %d",nfxpm); + } + writeraw(surf1,surf2,tblock,xslices,yslices,rawfiles); + } + + + + if(bFourier) + { + nfspect=opt2fns(&spectra,"-Spect",NFILE,fnm); + if(nfspect!=2) + { + gmx_fatal(FARGS,"No or not correct number (2) of output-file-series: %d" + ,nfspect); + } + powerspectavg_intf(surf1, surf2, tblock,xslices,yslices,spectra); + } + + sfree(Densmap); + if(bGraph || bFourier || bRawOut) + { + sfree(surf1); + sfree(surf2); + } + + thanx(stderr); + return 0; +} diff -Nru gromacs-4.5.4/src/tools/gmx_dielectric.c gromacs-4.5.5/src/tools/gmx_dielectric.c --- gromacs-4.5.4/src/tools/gmx_dielectric.c 2011-03-14 13:33:32.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_dielectric.c 2011-09-21 12:34:32.000000000 +0000 @@ -198,8 +198,6 @@ "[TT]g_dielectric[tt] calculates frequency dependent dielectric constants", "from the autocorrelation function of the total dipole moment in", "your simulation. This ACF can be generated by [TT]g_dipoles[tt].", - "For an estimate of the error you can run g_statistics on the", - "ACF, and use the output thus generated for this program.", "The functional forms of the available functions are:[PAR]", "One parameter: y = Exp[-a1 x],[BR]", "Two parameters: y = a2 Exp[-a1 x],[BR]", @@ -239,9 +237,9 @@ { "-fft", FALSE, etBOOL, {&bFour}, "use fast fourier transform for correlation function" }, { "-x1", FALSE, etBOOL, {&bX}, - "use first column as X axis rather than first data set" }, + "use first column as [IT]x[it]-axis rather than first data set" }, { "-eint", FALSE, etREAL, {&tendInt}, - "Time were to end the integration of the data and start to use the fit"}, + "Time to end the integration of the data and start to use the fit"}, { "-bfit", FALSE, etREAL, {&tbegin}, "Begin time of fit" }, { "-efit", FALSE, etREAL, {&tend}, @@ -251,13 +249,13 @@ { "-A", FALSE, etREAL, {&A}, "Start value for fit parameter A" }, { "-tau1", FALSE, etREAL, {&tau1}, - "Start value for fit parameter tau1" }, + "Start value for fit parameter [GRK]tau[grk]1" }, { "-tau2", FALSE, etREAL, {&tau2}, - "Start value for fit parameter tau2" }, + "Start value for fit parameter [GRK]tau[grk]2" }, { "-eps0", FALSE, etREAL, {&eps0}, - "Epsilon 0 of your liquid" }, + "[GRK]epsilon[grk]0 of your liquid" }, { "-epsRF", FALSE, etREAL, {&epsRF}, - "Epsilon of the reaction field used in your simulation. A value of 0 means infinity." }, + "[GRK]epsilon[grk] of the reaction field used in your simulation. A value of 0 means infinity." }, { "-fix", FALSE, etINT, {&fix}, "Fix parameters at their start values, A (2), tau1 (1), or tau2 (4)" }, { "-ffn", FALSE, etENUM, {s_ffn}, @@ -270,6 +268,10 @@ parse_common_args(&argc,argv,PCA_CAN_TIME | PCA_CAN_VIEW | PCA_BE_NICE, NFILE,fnm,asize(pa),pa,asize(desc),desc,0,NULL,&oenv); please_cite(stdout,"Spoel98a"); + printf("WARNING: non-polarizable models can never yield an infinite\n" + "dielectric constant that is different from 1. This is incorrect\n" + "in the reference given above (Spoel98a).\n\n"); + nx = read_xvg(opt2fn("-f",NFILE,fnm),&yd,&ny); dt = yd[0][1] - yd[0][0]; diff -Nru gromacs-4.5.4/src/tools/gmx_dipoles.c gromacs-4.5.5/src/tools/gmx_dipoles.c --- gromacs-4.5.4/src/tools/gmx_dipoles.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_dipoles.c 2011-09-21 12:34:10.000000000 +0000 @@ -1268,7 +1268,7 @@ const char *desc[] = { "[TT]g_dipoles[tt] computes the total dipole plus fluctuations of a simulation", "system. From this you can compute e.g. the dielectric constant for", - "low dielectric media.", + "low-dielectric media.", "For molecules with a net charge, the net charge is subtracted at", "center of mass of the molecule.[PAR]", "The file [TT]Mtot.xvg[tt] contains the total dipole moment of a frame, the", @@ -1277,8 +1277,8 @@ "simulation.", "The file [TT]dipdist.xvg[tt] contains the distribution of dipole moments during", "the simulation", - "The mu_max is used as the highest value in the distribution graph.[PAR]", - "Furthermore the dipole autocorrelation function will be computed when", + "The value of [TT]-mumax[tt] is used as the highest value in the distribution graph.[PAR]", + "Furthermore, the dipole autocorrelation function will be computed when", "option [TT]-corr[tt] is used. The output file name is given with the [TT]-c[tt]", "option.", "The correlation functions can be averaged over all molecules", @@ -1288,17 +1288,17 @@ "Option [TT]-g[tt] produces a plot of the distance dependent Kirkwood", "G-factor, as well as the average cosine of the angle between the dipoles", "as a function of the distance. The plot also includes gOO and hOO", - "according to Nymand & Linse, JCP 112 (2000) pp 6386-6395. In the same plot", + "according to Nymand & Linse, J. Chem. Phys. 112 (2000) pp 6386-6395. In the same plot, ", "we also include the energy per scale computed by taking the inner product of", "the dipoles divided by the distance to the third power.[PAR]", "[PAR]", "EXAMPLES[PAR]", - "[TT]g_dipoles -corr mol -P1 -o dip_sqr -mu 2.273 -mumax 5.0 -nofft[tt][PAR]", + "[TT]g_dipoles -corr mol -P 1 -o dip_sqr -mu 2.273 -mumax 5.0[tt][PAR]", "This will calculate the autocorrelation function of the molecular", "dipoles using a first order Legendre polynomial of the angle of the", "dipole vector and itself a time t later. For this calculation 1001", - "frames will be used. Further the dielectric constant will be calculated", - "using an epsilonRF of infinity (default), temperature of 300 K (default) and", + "frames will be used. Further, the dielectric constant will be calculated", + "using an [GRK]epsilon[grk]RF of infinity (default), temperature of 300 K (default) and", "an average dipole moment of the molecule of 2.273 (SPC). For the", "distribution function a maximum of 5.0 will be used." }; @@ -1315,7 +1315,7 @@ { "-mu", FALSE, etREAL, {&mu_aver}, "dipole of a single molecule (in Debye)" }, { "-mumax", FALSE, etREAL, {&mu_max}, - "max dipole in Debye (for histrogram)" }, + "max dipole in Debye (for histogram)" }, { "-epsilonRF",FALSE, etREAL, {&epsilonRF}, "epsilon of the reaction field used during the simulation, needed for dielectric constant calculation. WARNING: 0.0 means infinity (default)" }, { "-skip", FALSE, etINT, {&skip}, @@ -1325,7 +1325,7 @@ { "-corr", FALSE, etENUM, {corrtype}, "Correlation function to calculate" }, { "-pairs", FALSE, etBOOL, {&bPairs}, - "Calculate |cos theta| between all pairs of molecules. May be slow" }, + "Calculate |cos [GRK]theta[grk]| between all pairs of molecules. May be slow" }, { "-ncos", FALSE, etINT, {&ncos}, "Must be 1 or 2. Determines whether the is computed between all molecules in one group, or between molecules in two different groups. This turns on the [TT]-gkr[tt] flag." }, { "-axis", FALSE, etSTR, {&axtitle}, @@ -1337,13 +1337,13 @@ { "-gkratom2", FALSE, etINT, {&nFB}, "Same as previous option in case ncos = 2, i.e. dipole interaction between two groups of molecules" }, { "-rcmax", FALSE, etREAL, {&rcmax}, - "Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterium based on the box length will be used." }, + "Maximum distance to use in the dipole orientation distribution (with ncos == 2). If zero, a criterion based on the box length will be used." }, { "-phi", FALSE, etBOOL, {&bPhi}, "Plot the 'torsion angle' defined as the rotation of the two dipole vectors around the distance vector between the two molecules in the [TT].xpm[tt] file from the [TT]-cmap[tt] option. By default the cosine of the angle between the dipoles is plotted." }, { "-nlevels", FALSE, etINT, {&nlevels}, "Number of colors in the cmap output" }, { "-ndegrees", FALSE, etINT, {&ndegrees}, - "Number of divisions on the y-axis in the camp output (for 180 degrees)" } + "Number of divisions on the [IT]y[it]-axis in the cmap output (for 180 degrees)" } }; int *gnx; int nFF[2]; diff -Nru gromacs-4.5.4/src/tools/gmx_disre.c gromacs-4.5.5/src/tools/gmx_disre.c --- gromacs-4.5.4/src/tools/gmx_disre.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_disre.c 2011-09-21 12:34:32.000000000 +0000 @@ -668,7 +668,7 @@ if (ftp2bSet(efNDX,NFILE,fnm)) { rd_index(ftp2fn(efNDX,NFILE,fnm),1,&isize,&index,&grpname); - xvg=xvgropen(opt2fn("-dr",NFILE,fnm),"Inidividual Restraints","Time (ps)", + xvg=xvgropen(opt2fn("-dr",NFILE,fnm),"Individual Restraints","Time (ps)", "nm",oenv); snew(vvindex,isize); snew(leg,isize); diff -Nru gromacs-4.5.4/src/tools/gmx_dist.c gromacs-4.5.5/src/tools/gmx_dist.c --- gromacs-4.5.4/src/tools/gmx_dist.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_dist.c 2011-09-21 12:34:32.000000000 +0000 @@ -71,13 +71,13 @@ const char *desc[] = { "[TT]g_dist[tt] can calculate the distance between the centers of mass of two", "groups of atoms as a function of time. The total distance and its", - "x, y and z components are plotted.[PAR]", + "[IT]x[it]-, [IT]y[it]-, and [IT]z[it]-components are plotted.[PAR]", "Or when [TT]-dist[tt] is set, print all the atoms in group 2 that are", "closer than a certain distance to the center of mass of group 1.[PAR]", "With options [TT]-lt[tt] and [TT]-dist[tt] the number of contacts", "of all atoms in group 2 that are closer than a certain distance", "to the center of mass of group 1 are plotted as a function of the time", - "that the contact was continously present.[PAR]", + "that the contact was continuously present.[PAR]", "Other programs that calculate distances are [TT]g_mindist[tt]", "and [TT]g_bond[tt]." }; diff -Nru gromacs-4.5.4/src/tools/gmx_dos.c gromacs-4.5.5/src/tools/gmx_dos.c --- gromacs-4.5.4/src/tools/gmx_dos.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_dos.c 2011-09-21 12:34:32.000000000 +0000 @@ -0,0 +1,582 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * Green Red Orange Magenta Azure Cyan Skyblue + */ +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include + +#include "confio.h" +#include "copyrite.h" +#include "gmx_fatal.h" +#include "futil.h" +#include "gstat.h" +#include "macros.h" +#include "maths.h" +#include "physics.h" +#include "index.h" +#include "smalloc.h" +#include "statutil.h" +#include "string.h" +#include "sysstuff.h" +#include "txtdump.h" +#include "typedefs.h" +#include "vec.h" +#include "strdb.h" +#include "xvgr.h" +#include "correl.h" +#include "gmx_ana.h" +#include "gmx_fft.h" + +enum { VACF, MVACF, DOS, DOS_SOLID, DOS_DIFF, DOS_CP, DOS_S, DOS_A, DOS_E, DOS_NR }; + +static double FD(double Delta,double f) +{ + return (2*pow(Delta,-4.5)*pow(f,7.5) - + 6*pow(Delta,-3)*pow(f,5) - + pow(Delta,-1.5)*pow(f,3.5) + + 6*pow(Delta,-1.5)*pow(f,2.5) + + 2*f - 2); +} + +static double YYY(double f,double y) +{ + return (2*pow(y*f,3) - sqr(f)*y*(1+6*y) + + (2+6*y)*f - 2); +} + +static double calc_compress(double y) +{ + if (y==1) + return 0; + return ((1+y+sqr(y)-pow(y,3))/(pow(1-y,3))); +} + +static double bisector(double Delta,double tol, + double ff0,double ff1, + double ff(double,double)) +{ + double fd0,fd,fd1,f,f0,f1; + double tolmin = 1e-8; + + f0 = ff0; + f1 = ff1; + if (tol < tolmin) + { + fprintf(stderr,"Unrealistic tolerance %g for bisector. Setting it to %g\n",tol,tolmin); + tol = tolmin; + } + + do { + fd0 = ff(Delta,f0); + fd1 = ff(Delta,f1); + f = (f0+f1)*0.5; + fd = ff(Delta,f); + if (fd < 0) + f0 = f; + else if (fd > 0) + f1 = f; + else + return f; + } while ((f1-f0) > tol); + + return f; +} + +static double calc_fluidicity(double Delta,double tol) +{ + return bisector(Delta,tol,0,1,FD); +} + +static double calc_y(double f,double Delta,double toler) +{ + double y1,y2; + + y1 = pow(f/Delta,1.5); + y2 = bisector(f,toler,0,10000,YYY); + if (fabs((y1-y2)/(y1+y2)) > 100*toler) + fprintf(stderr,"Inconsistency computing y: y1 = %f, y2 = %f, using y1.\n", + y1,y2); + + return y1; +} + +static double calc_Shs(double f,double y) +{ + double fy = f*y; + + return BOLTZ*(log(calc_compress(fy)) + fy*(3*fy-4)/sqr(1-fy)); +} + +static real old_calc_fluidicity(real Delta,real tol) +{ + real fd0,fd,fd1,f,f0=0,f1=1; + real tolmin = 1e-6; + + /* Since the fluidity is monotonous according to Fig. 2 in Lin2003a, + J. Chem. Phys. 112 (2003) p. 11792 we can use a bisection method + to get it. */ + if (tol < tolmin) + { + fprintf(stderr,"Unrealistic tolerance %g for calc_fluidity. Setting it to %g\n",tol,tolmin); + tol=1e-6; + } + + do { + fd0 = FD(Delta,f0); + fd1 = FD(Delta,f1); + f = (f0+f1)*0.5; + fd = FD(Delta,f); + if (fd < 0) + f0 = f; + else if (fd > 0) + f1 = f; + else + return f; + } while ((f1-f0) > tol); + + return f; +} + +static real wCsolid(real nu,real beta) +{ + real bhn = beta*PLANCK*nu; + real ebn,koko; + + if (bhn == 0) + return 1.0; + else + { + ebn = exp(bhn); + koko = sqr(1-ebn); + return sqr(bhn)*ebn/koko; + } +} + +static real wSsolid(real nu,real beta) +{ + real bhn = beta*PLANCK*nu; + + if (bhn == 0) + { + return 1; + } + else + { + return bhn/(exp(bhn)-1) - log(1-exp(-bhn)); + } +} + +static real wAsolid(real nu,real beta) +{ + real bhn = beta*PLANCK*nu; + + if (bhn == 0) + { + return 0; + } + else + { + return log((1-exp(-bhn))/(exp(-bhn/2))) - log(bhn); + } +} + +static real wEsolid(real nu,real beta) +{ + real bhn = beta*PLANCK*nu; + + if (bhn == 0) + { + return 1; + } + else + { + return bhn/2 + bhn/(exp(bhn)-1)-1; + } +} + +static void dump_fy(output_env_t oenv,real toler) +{ + FILE *fp; + double Delta,f,y,DD; + const char *leg[] = { "f", "fy", "y" }; + + DD = pow(10.0,0.125); + fp=xvgropen("fy.xvg","Fig. 2, Lin2003a","Delta","y or fy",oenv); + xvgr_legend(fp,asize(leg),leg,oenv); + fprintf(fp,"@ world 1e-05, 0, 1000, 1\n"); + fprintf(fp,"@ xaxes scale Logarithmic\n"); + for (Delta=1e-5; (Delta <= 1000); Delta*=DD) + { + f = calc_fluidicity(Delta,toler); + y = calc_y(f,Delta,toler); + fprintf(fp,"%10g %10g %10g %10g\n",Delta,f,f*y,y); + } + fclose(fp); +} + +static void dump_w(output_env_t oenv,real beta) +{ + FILE *fp; + double nu; + const char *leg[] = { "wCv", "wS", "wA", "wE" }; + + fp=xvgropen("w.xvg","Fig. 1, Berens1983a","\\f{12}b\\f{4}h\\f{12}n", + "w",oenv); + xvgr_legend(fp,asize(leg),leg,oenv); + for (nu=1; (nu<100); nu+=0.05) + { + fprintf(fp,"%10g %10g %10g %10g %10g\n",beta*PLANCK*nu, + wCsolid(nu,beta),wSsolid(nu,beta), + wAsolid(nu,beta),wEsolid(nu,beta)); + } + fclose(fp); +} + +int gmx_dos(int argc,char *argv[]) +{ + const char *desc[] = { + "[TT]g_dos[tt] computes the Density of States from a simulations.", + "In order for this to be meaningful the velocities must be saved", + "in the trajecotry with sufficiently high frequency such as to cover", + "all vibrations. For flexible systems that would be around a few fs", + "between saving. Properties based on the DoS are printed on the", + "standard output." + }; + const char *bugs[] = { + "This program needs a lot of memory: total usage equals the number of atoms times 3 times number of frames times 4 (or 8 when run in double precision)." + }; + FILE *fp,*fplog; + t_topology top; + int ePBC=-1; + t_trxframe fr; + matrix box; + int gnx; + char title[256]; + real t0,t1,m; + t_trxstatus *status; + int nV,nframes,n_alloc,i,j,k,l,fftcode,Nmol,Natom; + double rho,dt,V2sum,Vsum,V,tmass,dostot,dos2,dosabs; + real **c1,**dos,mi,beta,bfac,*nu,*tt,stddev,c1j; + output_env_t oenv; + gmx_fft_t fft; + double cP,S,A,E,DiffCoeff,Delta,f,y,z,sigHS,Shs,Sig,DoS0,recip_fac; + double wCdiff,wSdiff,wAdiff,wEdiff; + + static gmx_bool bVerbose=TRUE,bAbsolute=FALSE,bNormalize=FALSE; + static gmx_bool bRecip=FALSE,bDump=FALSE; + static real Temp=298.15,toler=1e-6; + t_pargs pa[] = { + { "-v", FALSE, etBOOL, {&bVerbose}, + "Be loud and noisy." }, + { "-recip", FALSE, etBOOL, {&bRecip}, + "Use cm^-1 on X-axis instead of 1/ps for DoS plots." }, + { "-abs", FALSE, etBOOL, {&bAbsolute}, + "Use the absolute value of the Fourier transform of the VACF as the Density of States. Default is to use the real component only" }, + { "-normdos", FALSE, etBOOL, {&bNormalize}, + "Normalize the DoS such that it adds up to 3N. This is a hack that should not be necessary." }, + { "-T", FALSE, etREAL, {&Temp}, + "Temperature in the simulation" }, + { "-toler", FALSE, etREAL, {&toler}, + "[HIDDEN]Tolerance when computing the fluidicity using bisection algorithm" }, + { "-dump", FALSE, etBOOL, {&bDump}, + "[HIDDEN]Dump the y/fy plot corresponding to Fig. 2 inLin2003a and the and the weighting functions corresponding to Fig. 1 in Berens1983a." } + }; + + t_filenm fnm[] = { + { efTRN, "-f", NULL, ffREAD }, + { efTPX, "-s", NULL, ffREAD }, + { efNDX, NULL, NULL, ffOPTRD }, + { efXVG, "-vacf", "vacf", ffWRITE }, + { efXVG, "-mvacf","mvacf", ffWRITE }, + { efXVG, "-dos", "dos", ffWRITE }, + { efLOG, "-g", "dos", ffWRITE }, + }; +#define NFILE asize(fnm) + int npargs; + t_pargs *ppa; + const char *DoSlegend[] = { + "DoS(v)", "DoS(v)[Solid]", "DoS(v)[Diff]" + }; + + CopyRight(stderr,argv[0]); + npargs = asize(pa); + ppa = add_acf_pargs(&npargs,pa); + parse_common_args(&argc,argv,PCA_CAN_VIEW | PCA_CAN_TIME | PCA_BE_NICE, + NFILE,fnm,npargs,ppa,asize(desc),desc, + asize(bugs),bugs,&oenv); + + beta = 1/(Temp*BOLTZ); + if (bDump) + { + printf("Dumping reference figures. Thanks for your patience.\n"); + dump_fy(oenv,toler); + dump_w(oenv,beta); + exit(0); + } + + fplog = gmx_fio_fopen(ftp2fn(efLOG,NFILE,fnm),"w"); + fprintf(fplog,"Doing density of states analysis based on trajectory.\n"); + please_cite(fplog,"Pascal2011a"); + please_cite(fplog,"Caleman2011b"); + + read_tps_conf(ftp2fn(efTPX,NFILE,fnm),title,&top,&ePBC,NULL,NULL,box, + TRUE); + V = det(box); + tmass = 0; + for(i=0; (i= n_alloc) + { + n_alloc+=100; + for(i=0; i 0) + { + V = Vsum/nV; + } + if (bVerbose) + printf("Going to do %d fourier transforms of length %d. Hang on.\n", + gnx,nframes); + low_do_autocorr(NULL,oenv,NULL,nframes,gnx,nframes,c1,dt,eacNormal,0,FALSE, + FALSE,FALSE,-1,-1,0,0); + snew(dos,DOS_NR); + for(j=0; (jnpoints = edat->nframes; + edat->nsteps = edat->nframes; + + for(k=0; (k<5); k++) + { + for(i=0; (is[i].slope*dt; + + if (NULL != debug) + fprintf(debug,"slope for set %d is %g\n",i,edat->s[i].slope); + + for(j=0; (jnframes); j++) + { + edat->s[i].ener[j] -= j*delta; + edat->s[i].es[j].sum = 0; + edat->s[i].es[j].sum2 = 0; + } + } + calc_averages(nset,edat,nbmin,nbmax); + } +} + +static void calc_fluctuation_props(FILE *fp, + gmx_bool bDriftCorr,real dt, + int nset,int set[],int nmol, + char **leg,enerdata_t *edat, + int nbmin,int nbmax) +{ + int i,j; + double vvhh,vv,v,h,hh2,vv2,varv,hh,varh,tt,cv,cp,alpha,kappa,dcp,et,varet; + double NANO3; + enum { eVol, eEnth, eTemp, eEtot, eNR }; + const char *my_ener[] = { "Volume", "Enthalpy", "Temperature", "Total Energy" }; + int ii[eNR]; + + NANO3 = NANO*NANO*NANO; + if (!bDriftCorr) + { + fprintf(fp,"\nYou may want to use the -driftcorr flag in order to correct\n" + "for spurious drift in the graphs. Note that this is not\n" + "a substitute for proper equilibration and sampling!\n"); + } + else + { + remove_drift(nset,nbmin,nbmax,dt,edat); + } + for(i=0; (is[ii[eTemp]].av; + } + /* Volume */ + vv = varv = NOTSET; + if ((ii[eVol] < nset) && (ii[eTemp] < nset)) + { + vv = edat->s[ii[eVol]].av*NANO3; + varv = dsqr(edat->s[ii[eVol]].rmsd*NANO3); + kappa = (varv/vv)/(BOLTZMANN*tt); + } + /* Enthalpy */ + hh = varh = NOTSET; + if ((ii[eEnth] < nset) && (ii[eTemp] < nset)) + { + hh = KILO*edat->s[ii[eEnth]].av/AVOGADRO; + varh = dsqr(KILO*edat->s[ii[eEnth]].rmsd/AVOGADRO); + cp = AVOGADRO*((varh/nmol)/(BOLTZMANN*tt*tt)); + } + /* Total energy */ + et = varet = NOTSET; + if ((ii[eEtot] < nset) && (hh == NOTSET) && (tt != NOTSET)) + { + /* Only compute cv in constant volume runs, which we can test + by checking whether the enthalpy was computed. + */ + et = edat->s[ii[eEtot]].av; + varet = sqr(edat->s[ii[eEtot]].rmsd); + cv = KILO*((varet/nmol)/(BOLTZ*tt*tt)); + } + /* Alpha, dcp */ + if ((ii[eVol] < nset) && (ii[eEnth] < nset) && (ii[eTemp] < nset)) + { + vvhh = 0; + for(j=0; (jnframes); j++) + { + v = edat->s[ii[eVol]].ener[j]*NANO3; + h = KILO*edat->s[ii[eEnth]].ener[j]/AVOGADRO; + vvhh += (v*h); + } + vvhh /= edat->nframes; + alpha = (vvhh-vv*hh)/(vv*BOLTZMANN*tt*tt); + dcp = (vv*AVOGADRO/nmol)*tt*sqr(alpha)/(kappa); + } + + if (tt != NOTSET) + { + if (nmol < 2) + fprintf(fp,"\nWARNING: nmol = %d, this may not be what you want.\n", + nmol); + fprintf(fp,"\nTemperature dependent fluctuation properties at T = %g.\n",tt); + fprintf(fp,"\nHeat capacities obtained from fluctuations do *not* include\n"); + fprintf(fp,"quantum corrections. If you want to get a more accurate estimate\n"); + fprintf(fp,"please use the g_dos program.\n\n"); + fprintf(fp,"WARNING: Please verify that your simulations are converged and perform\n" + "a block-averaging error analysis (not implemented in g_energy yet)\n"); + + if (debug != NULL) + { + if (varv != NOTSET) + fprintf(fp,"varv = %10g (m^6)\n",varv*AVOGADRO/nmol); + if (vvhh != NOTSET) + fprintf(fp,"vvhh = %10g (m^3 J)\n",vvhh); + } + if (vv != NOTSET) + fprintf(fp,"Volume = %10g m^3/mol\n", + vv*AVOGADRO/nmol); + if (varh != NOTSET) + fprintf(fp,"Enthalpy = %10g kJ/mol\n", + hh*AVOGADRO/(KILO*nmol)); + if (alpha != NOTSET) + fprintf(fp,"Coefficient of Thermal Expansion Alpha_P = %10g (1/K)\n", + alpha); + if (kappa != NOTSET) + { + fprintf(fp,"Isothermal Compressibility Kappa = %10g (J/m^3)\n", + kappa); + fprintf(fp,"Adiabatic bulk modulus = %10g (m^3/J)\n", + 1.0/kappa); + } + if (cp != NOTSET) + fprintf(fp,"Heat capacity at constant pressure Cp = %10g J/mol K\n", + cp); + if (cv != NOTSET) + fprintf(fp,"Heat capacity at constant volume Cv = %10g J/mol K\n", + cv); + if (dcp != NOTSET) + fprintf(fp,"Cp-Cv = %10g J/mol K\n", + dcp); + please_cite(fp,"Allen1987a"); + } + else + { + fprintf(fp,"You should select the temperature in order to obtain fluctuation properties.\n"); + } +} + static void analyse_ener(gmx_bool bCorr,const char *corrfn, - gmx_bool bFee,gmx_bool bSum,gmx_bool bFluct, + gmx_bool bFee,gmx_bool bSum,gmx_bool bFluct,gmx_bool bTempFluct, gmx_bool bVisco,const char *visfn,int nmol, gmx_large_int_t start_step,double start_t, gmx_large_int_t step,double t, @@ -857,14 +1022,13 @@ /* Check out the printed manual for equations! */ double Dt,aver,stddev,errest,delta_t,totaldrift; enerdata_t *esum=NULL; - real xxx,integral,intBulk; + real xxx,integral,intBulk,Temp=0,Pres=0; real sfrac,oldfrac,diffsum,diffav,fstep,pr_aver,pr_stddev,pr_errest; double beta=0,expE,expEtot,*fee=NULL; gmx_large_int_t nsteps; int nexact,nnotexact; double x1m,x1mk; - real Temp=-1,Pres=-1,VarV=-1,VarT=-1,VarEtot=-1,AvEtot=0; - int i,j,nout; + int i,j,k,nout; real chi2; char buf[256],eebuf[100]; @@ -951,16 +1115,11 @@ fee[i] = log(expE/edat->nframes)/beta + aver/nmol; } if (strstr(leg[i],"empera") != NULL) { - VarT = sqr(stddev); Temp = aver; } else if (strstr(leg[i],"olum") != NULL) { - VarV = sqr(stddev); Vaver= aver; } else if (strstr(leg[i],"essure") != NULL) { Pres = aver; - } else if (strstr(leg[i],"otal") != NULL) { - VarEtot = sqr(stddev); - AvEtot = aver; } if (bIsEner[i]) { pr_aver = aver/nmol-ezero; @@ -1004,6 +1163,7 @@ else fprintf(stdout,"\n"); } + /* Do correlation function */ if (edat->nframes > 1) { @@ -1216,7 +1376,7 @@ /* coll data */ double temp=0, start_time=0, delta_time=0, start_lambda=0, delta_lambda=0; static int setnr=0; - gmx_bool changing_lambda; + gmx_bool changing_lambda=FALSE; /* now count the blocks & handle the global dh data */ for(i=0;inblock;i++) @@ -1480,25 +1640,39 @@ "[TT]g_energy[tt] extracts energy components or distance restraint", "data from an energy file. The user is prompted to interactively", - "select the energy terms she wants.[PAR]", + "select the desired energy terms.[PAR]", - "Average, RMSD and drift are calculated with full precision from the", + "Average, RMSD, and drift are calculated with full precision from the", "simulation (see printed manual). Drift is calculated by performing", "a least-squares fit of the data to a straight line. The reported total drift", "is the difference of the fit at the first and last point.", "An error estimate of the average is given based on a block averages", - "over 5 blocks using the full precision averages. The error estimate", + "over 5 blocks using the full-precision averages. The error estimate", "can be performed over multiple block lengths with the options", "[TT]-nbmin[tt] and [TT]-nbmax[tt].", - "Note that in most cases the energy files contains averages over all", + "[BB]Note[bb] that in most cases the energy files contains averages over all", "MD steps, or over many more points than the number of frames in", "energy file. This makes the [TT]g_energy[tt] statistics output more accurate", "than the [TT].xvg[tt] output. When exact averages are not present in the energy", - "file the statistics mentioned above are simply over the single, per-frame", + "file, the statistics mentioned above are simply over the single, per-frame", "energy values.[PAR]", "The term fluctuation gives the RMSD around the least-squares fit.[PAR]", + "Some fluctuation-dependent properties can be calculated provided", + "the correct energy terms are selected. The following properties", + "will be computed:[BR]", + "Property Energy terms needed[BR]", + "---------------------------------------------------[BR]", + "Heat capacity Cp (NPT sims): Enthalpy, Temp [BR]", + "Heat capacity Cv (NVT sims): Etot, Temp [BR]", + "Thermal expansion coeff. (NPT): Enthalpy, Vol, Temp[BR]", + "Isothermal compressibility: Vol, Temp [BR]", + "Adiabatic bulk modulus: Vol, Temp [BR]", + "---------------------------------------------------[BR]", + "You always need to set the number of molecules [TT]-nmol[tt].", + "The Cp/Cv computations do [BB]not[bb] include any corrections", + "for quantum effects. Use the [TT]g_dos[tt] program if you need that (and you do).[PAR]" "When the [TT]-viol[tt] option is set, the time averaged", "violations are plotted and the running time-averaged and", "instantaneous sum of violations are recalculated. Additionally", @@ -1529,26 +1703,27 @@ "With [TT]-fee[tt] an estimate is calculated for the free-energy", "difference with an ideal gas state: [BR]", - " Delta A = A(N,V,T) - A_idgas(N,V,T) = kT ln < e^(Upot/kT) >[BR]", - " Delta G = G(N,p,T) - G_idgas(N,p,T) = kT ln < e^(Upot/kT) >[BR]", + " [GRK]Delta[grk] A = A(N,V,T) - A_idgas(N,V,T) = kT ln < e^(Upot/kT) >[BR]", + " [GRK]Delta[grk] G = G(N,p,T) - G_idgas(N,p,T) = kT ln < e^(Upot/kT) >[BR]", "where k is Boltzmann's constant, T is set by [TT]-fetemp[tt] and", "the average is over the ensemble (or time in a trajectory).", "Note that this is in principle", "only correct when averaging over the whole (Boltzmann) ensemble", "and using the potential energy. This also allows for an entropy", "estimate using:[BR]", - " Delta S(N,V,T) = S(N,V,T) - S_idgas(N,V,T) = ( - Delta A)/T[BR]", - " Delta S(N,p,T) = S(N,p,T) - S_idgas(N,p,T) = ( + pV - Delta G)/T", + " [GRK]Delta[grk] S(N,V,T) = S(N,V,T) - S_idgas(N,V,T) = ( - [GRK]Delta[grk] A)/T[BR]", + " [GRK]Delta[grk] S(N,p,T) = S(N,p,T) - S_idgas(N,p,T) = ( + pV - [GRK]Delta[grk] G)/T", "[PAR]", "When a second energy file is specified ([TT]-f2[tt]), a free energy", "difference is calculated dF = -kT ln < e ^ -(EB-EA)/kT >A ,", "where EA and EB are the energies from the first and second energy", - "files, and the average is over the ensemble A. [BB]NOTE[bb] that", - "the energies must both be calculated from the same trajectory." + "files, and the average is over the ensemble A. The running average", + "of the free energy difference is printed to a file specified by [TT]-ravg[tt].", + "[BB]Note[bb] that the energies must both be calculated from the same trajectory." }; - static gmx_bool bSum=FALSE,bFee=FALSE,bPrAll=FALSE,bFluct=FALSE; + static gmx_bool bSum=FALSE,bFee=FALSE,bPrAll=FALSE,bFluct=FALSE,bDriftCorr=FALSE; static gmx_bool bDp=FALSE,bMutot=FALSE,bOrinst=FALSE,bOvec=FALSE; static int skip=0,nmol=1,nbmin=5,nbmax=5; static real reftemp=300.0,ezero=0; @@ -1575,6 +1750,8 @@ "Also print the exact average and rmsd stored in the energy frames (only when 1 term is requested)" }, { "-nmol", FALSE, etINT, {&nmol}, "Number of molecules in your sample: the energies are divided by this number" }, + { "-driftcorr", FALSE, etBOOL, {&bDriftCorr}, + "Useful only for calculations of fluctuation properties. The drift in the observables will be subtracted before computing the fluctuation properties."}, { "-fluc", FALSE, etBOOL, {&bFluct}, "Calculate autocorrelation of energy fluctuations rather than energy itself" }, { "-orinst", FALSE, etBOOL, {&bOrinst}, @@ -1899,12 +2076,20 @@ if (edat.nframes % 1000 == 0) { srenew(edat.step,edat.nframes+1000); + memset(&(edat.step[edat.nframes]),0,1000*sizeof(edat.step[0])); srenew(edat.steps,edat.nframes+1000); + memset(&(edat.steps[edat.nframes]),0,1000*sizeof(edat.steps[0])); srenew(edat.points,edat.nframes+1000); + memset(&(edat.points[edat.nframes]),0,1000*sizeof(edat.points[0])); for(i=0; ibox,box_center); + /* pbc_dx_aiuc only works correctly with the rectangular box center */ + calc_box_center(ecenterRECT,pbc->box,box_center); shift = pbc_dx_aiuc(pbc,x,box_center,dx); @@ -627,8 +628,8 @@ "The program iterates until [TT]nmol[tt] molecules", "have been inserted in the box. To test whether an insertion is ", "successful the same van der Waals criterium is used as for removal of ", - "solvent molecules. When no appropriately ", - "sized holes (holes that can hold an extra molecule) are available the ", + "solvent molecules. When no appropriately-sized ", + "holes (holes that can hold an extra molecule) are available, the ", "program tries for [TT]-nmol[tt] * [TT]-try[tt] times before giving up. ", "Increase [TT]-try[tt] if you have several small holes to fill.[PAR]", diff -Nru gromacs-4.5.4/src/tools/gmx_genconf.c gromacs-4.5.5/src/tools/gmx_genconf.c --- gromacs-4.5.4/src/tools/gmx_genconf.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_genconf.c 2011-09-21 12:34:10.000000000 +0000 @@ -111,13 +111,13 @@ const char *desc[] = { "[TT]genconf[tt] multiplies a given coordinate file by simply stacking them", "on top of each other, like a small child playing with wooden blocks.", - "The program makes a grid of [IT]user defined[it]", + "The program makes a grid of [IT]user-defined[it]", "proportions ([TT]-nbox[tt]), ", "and interspaces the grid point with an extra space [TT]-dist[tt].[PAR]", "When option [TT]-rot[tt] is used the program does not check for overlap", "between molecules on grid points. It is recommended to make the box in", "the input file at least as big as the coordinates + ", - "Van der Waals radius.[PAR]", + "van der Waals radius.[PAR]", "If the optional trajectory file is given, conformations are not", "generated, but read from this file and translated appropriately to", "build the grid." diff -Nru gromacs-4.5.4/src/tools/gmx_genion.c gromacs-4.5.5/src/tools/gmx_genion.c --- gromacs-4.5.4/src/tools/gmx_genion.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_genion.c 2011-09-21 12:34:10.000000000 +0000 @@ -302,10 +302,10 @@ fprintf(fpout,"%-10s %d\n",grpname,nsol_last); } if (p_num > 0) { - fprintf(fpout,"%-10s %d\n",p_name,p_num); + fprintf(fpout,"%-15s %d\n",p_name,p_num); } if (n_num > 0) { - fprintf(fpout,"%-10s %d\n",n_name,n_num); + fprintf(fpout,"%-15s %d\n",n_name,n_num); } } } @@ -341,7 +341,7 @@ "[PAR]Ions which can have multiple charge states get the multiplicity", "added, without sign, for the uncommon states only.[PAR]", "With the option [TT]-pot[tt] the potential can be written as B-factors", - "in a [TT].pdb[tt] file (for visualisation using e.g. rasmol).", + "in a [TT].pdb[tt] file (for visualisation using e.g. Rasmol).", "The unit of the potential is 1000 kJ/(mol e), the scaling be changed", "with the [TT]-scale[tt] option.[PAR]", "For larger ions, e.g. sulfate we recommended using [TT]genbox[tt]." diff -Nru gromacs-4.5.4/src/tools/gmx_genpr.c gromacs-4.5.5/src/tools/gmx_genpr.c --- gromacs-4.5.4/src/tools/gmx_genpr.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_genpr.c 2011-09-21 12:34:10.000000000 +0000 @@ -56,20 +56,20 @@ const char *desc[] = { "[TT]genrestr[tt] produces an include file for a topology containing", "a list of atom numbers and three force constants for the", - "X, Y and Z direction. A single isotropic force constant may", + "[IT]x[it]-, [IT]y[it]-, and [IT]z[it]-direction. A single isotropic force constant may", "be given on the command line instead of three components.[PAR]", "WARNING: position restraints only work for the one molecule at a time.", "Position restraints are interactions within molecules, therefore", "they should be included within the correct [TT][ moleculetype ][tt]", "block in the topology. Since the atom numbers in every moleculetype", "in the topology start at 1 and the numbers in the input file for", - "genpr number consecutively from 1, genpr will only produce a useful", - "file for the first molecule.[PAR]", + "[TT]genrestr[tt] number consecutively from 1, [TT]genrestr[tt] will only", + "produce a useful file for the first molecule.[PAR]", "The [TT]-of[tt] option produces an index file that can be used for", "freezing atoms. In this case, the input file must be a [TT].pdb[tt] file.[PAR]", "With the [TT]-disre[tt] option, half a matrix of distance restraints", "is generated instead of position restraints. With this matrix, that", - "one typically would apply to C-alpha atoms in a protein, one can", + "one typically would apply to C[GRK]alpha[grk] atoms in a protein, one can", "maintain the overall conformation of a protein without tieing it to", "a specific position (as with position restraints)." }; @@ -84,7 +84,7 @@ t_pargs pa[] = { { "-fc", FALSE, etRVEC, {fc}, - "force constants (kJ mol-1 nm-2)" }, + "force constants (kJ/mol nm^2)" }, { "-freeze", FALSE, etREAL, {&freeze_level}, "if the [TT]-of[tt] option or this one is given an index file will be written containing atom numbers of all atoms that have a B-factor less than the level given here" }, { "-disre", FALSE, etBOOL, {&bDisre}, diff -Nru gromacs-4.5.4/src/tools/gmx_gyrate.c gromacs-4.5.5/src/tools/gmx_gyrate.c --- gromacs-4.5.4/src/tools/gmx_gyrate.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_gyrate.c 2011-09-21 12:34:10.000000000 +0000 @@ -152,13 +152,13 @@ { const char *desc[] = { "[TT]g_gyrate[tt] computes the radius of gyration of a group of atoms", - "and the radii of gyration about the x, y and z axes,", + "and the radii of gyration about the [IT]x[it]-, [IT]y[it]- and [IT]z[it]-axes,", "as a function of time. The atoms are explicitly mass weighted.[PAR]", "With the [TT]-nmol[tt] option the radius of gyration will be calculated", "for multiple molecules by splitting the analysis group in equally", "sized parts.[PAR]", - "With the option [TT]-nz[tt] 2D radii of gyration in the x-y plane", - "of slices along the z-axis are calculated." + "With the option [TT]-nz[tt] 2D radii of gyration in the [IT]x-y[it] plane", + "of slices along the [IT]z[it]-axis are calculated." }; static int nmol=1,nz=0; static gmx_bool bQ=FALSE,bRot=FALSE,bMOI=FALSE; diff -Nru gromacs-4.5.4/src/tools/gmx_hbond.c gromacs-4.5.5/src/tools/gmx_hbond.c --- gromacs-4.5.4/src/tools/gmx_hbond.c 2011-03-21 15:04:58.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_hbond.c 2011-09-21 12:34:10.000000000 +0000 @@ -1494,7 +1494,7 @@ if (bBox){ if (d>a && bMerge && (bContact || isInterchangable(hb, d, a, grpd, grpa))) { /* acceptor is also a donor and vice versa? */ - return hbNo; + /* return hbNo; */ daSwap = TRUE; /* If so, then their history should be filed with donor and acceptor swapped. */ } if (hb->bGem) { @@ -2375,11 +2375,11 @@ */ if (acType != AC_LUZAR) { -#if (_OPENMP >= 200805) /* =====================\ */ - nThreads = min((nThreads <= 0) ? INT_MAX : nThreads, omp_get_thread_limit()); -#else +/* #if (_OPENMP >= 200805) /\* =====================\ *\/ */ +/* nThreads = min((nThreads <= 0) ? INT_MAX : nThreads, omp_get_thread_limit()); */ +/* #else */ nThreads = min((nThreads <= 0) ? INT_MAX : nThreads, omp_get_num_procs()); -#endif /* _OPENMP >= 200805 ====================/ */ +/* #endif /\* _OPENMP >= 200805 ====================/ *\/ */ omp_set_num_threads(nThreads); snew(dondata, nThreads); @@ -3180,7 +3180,7 @@ { "-temp", FALSE, etREAL, {&temp}, "Temperature (K) for computing the Gibbs energy corresponding to HB breaking and reforming" }, { "-smooth",FALSE, etREAL, {&smooth_tail_start}, - "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/tau)" }, + "If >= 0, the tail of the ACF will be smoothed by fitting it to an exponential function: y = A exp(-x/[GRK]tau[grk])" }, { "-dump", FALSE, etINT, {&nDump}, "Dump the first N hydrogen bond ACFs in a single [TT].xvg[tt] file for debugging" }, { "-max_hb",FALSE, etREAL, {&maxnhb}, @@ -3190,7 +3190,7 @@ { "-geminate", FALSE, etENUM, {gemType}, "Use reversible geminate recombination for the kinetics/thermodynamics calclations. See Markovitch et al., J. Chem. Phys 129, 084505 (2008) for details."}, { "-diff", FALSE, etREAL, {&D}, - "Dffusion coefficient to use in the rev. gem. recomb. kinetic model. If non-positive, then it will be fitted to the ACF along with ka and kd."}, + "Dffusion coefficient to use in the reversible geminate recombination kinetic model. If negative, then it will be fitted to the ACF along with ka and kd."}, #ifdef HAVE_OPENMP { "-nthreads", FALSE, etINT, {&nThreads}, "Number of threads used for the parallel loop over autocorrelations. nThreads <= 0 means maximum number of threads. Requires linking with OpenMP. The number of threads is limited by the number of processors (before OpenMP v.3 ) or environment variable OMP_THREAD_LIMIT (OpenMP v.3)"}, @@ -3557,11 +3557,11 @@ if (bParallel) { -#if (_OPENMP > 200805) - actual_nThreads = min((nThreads <= 0) ? INT_MAX : nThreads, omp_get_thread_limit()); -#else +/* #if (_OPENMP > 200805) */ +/* actual_nThreads = min((nThreads <= 0) ? INT_MAX : nThreads, omp_get_thread_limit()); */ +/* #else */ actual_nThreads = min((nThreads <= 0) ? INT_MAX : nThreads, omp_get_num_procs()); -#endif +/* #endif */ omp_set_num_threads(actual_nThreads); printf("Frame loop parallelized with OpenMP using %i threads.\n", actual_nThreads); fflush(stdout); @@ -3619,7 +3619,7 @@ dist, ang, peri, icell, jcell, \ grp, ogrp, ai, aj, xjj, yjj, zjj, \ xk, yk, zk, ihb, id, resdist, \ - xkk, ykk, zkk, kcell, ak, k, bTric) \ + xkk, ykk, zkk, kcell, ak, k, bTric) \ default(none) \ shared(hb, p_hb, p_adist, p_rdist, actual_nThreads, \ x, bBox, box, hbox, rcut, r2cut, rshell, \ @@ -3654,7 +3654,6 @@ if (hb->bDAnr) count_da_grid(ngrid, grid, hb->danr[nframes]); } /* omp single */ - #ifdef HAVE_OPENMP p_hb[threadNr]->time = hb->time; /* This pointer may have changed. */ #endif @@ -3738,7 +3737,7 @@ /* The outer grid loop will have to do for now. */ #pragma omp for schedule(dynamic) #endif - for(xi=0; (xi +#endif + +#include +#include + +#include "sysstuff.h" +#include "string.h" +#include "typedefs.h" +#include "statutil.h" +#include "smalloc.h" +#include "macros.h" +#include "gstat.h" +#include "vec.h" +#include "xvgr.h" +#include "pbc.h" +#include "copyrite.h" +#include "futil.h" +#include "statutil.h" +#include "index.h" +#include "tpxio.h" +#include "matio.h" +#include "binsearch.h" +#include "powerspect.h" + +/* Print name of first atom in all groups in index file */ +static void print_types(atom_id index[], atom_id a[], int ngrps, + char *groups[], t_topology *top) +{ + int i; + + fprintf(stderr,"Using following groups: \n"); + for(i = 0; i < ngrps; i++) + fprintf(stderr,"Groupname: %s First atomname: %s First atomnr %u\n", + groups[i], *(top->atoms.atomname[a[index[i]]]), a[index[i]]); + fprintf(stderr,"\n"); +} + +static void check_length(real length, int a, int b) +{ + if (length > 0.3) + fprintf(stderr,"WARNING: distance between atoms %d and " + "%d > 0.3 nm (%f). Index file might be corrupt.\n", + a, b, length); +} + +static void find_tetra_order_grid(t_topology top, int ePBC, + int natoms, matrix box, + rvec x[],int maxidx,atom_id index[], + real time, real *sgmean, real *skmean, + int nslicex, int nslicey, int nslicez, + real ***sggrid,real ***skgrid) +{ + int ix,jx,i,j,k,l,n,*nn[4]; + rvec dx,rj,rk,urk,urj; + real cost,cost2,*sgmol,*skmol,rmean,rmean2,r2,box2,*r_nn[4]; + t_pbc pbc; + int slindex_x,slindex_y,slindex_z; + int ***sl_count; + real onethird=1.0/3.0; + gmx_rmpbc_t gpbc; + + /* dmat = init_mat(maxidx, FALSE); */ + + box2 = box[XX][XX] * box[XX][XX]; + + /* Initialize expanded sl_count array */ + snew(sl_count,nslicex); + for(i=0;i 0) + { + sggrid[i][j][k] /= sl_count[i][j][k]; + skgrid[i][j][k] /= sl_count[i][j][k]; + } + } + } + } + + sfree(sl_count); + sfree(sgmol); + sfree(skmol); + for (i=0; (i<4); i++) + { + sfree(r_nn[i]); + sfree(nn[i]); + } +} + +/*Determines interface from tetrahedral order parameter in box with specified binwidth. */ +/*Outputs interface positions(bins), the number of timeframes, and the number of surface-mesh points in xy*/ + +static void calc_tetra_order_interface(const char *fnNDX,const char *fnTPS,const char *fnTRX, real binw, int tblock, + int *nframes, int *nslicex, int *nslicey, + real sgang1,real sgang2,real ****intfpos, + output_env_t oenv) +{ + FILE *fpsg=NULL,*fpsk=NULL; + char *sgslfn="sg_ang_mesh"; /* Hardcoded filenames for debugging*/ + char *skslfn="sk_dist_mesh"; + t_topology top; + int ePBC; + char title[STRLEN],subtitle[STRLEN]; + t_trxstatus *status; + int natoms; + real t; + rvec *xtop,*x; + matrix box; + real sg,sk, sgintf, pos; + atom_id **index=NULL; + char **grpname=NULL; + int i,j,k,n,*isize,ng, nslicez, framenr; + real ***sg_grid=NULL,***sk_grid=NULL, ***sg_fravg=NULL, ***sk_fravg=NULL, ****sk_4d=NULL, ****sg_4d=NULL; + int *perm; + int ndx1, ndx2; + int bins; + const real onehalf=1.0/2.0; + /* real ***intfpos[2]; pointers to arrays of two interface positions zcoord(framenr,xbin,ybin): intfpos[interface_index][t][nslicey*x+y] + * i.e 1D Row-major order in (t,x,y) */ + + + read_tps_conf(fnTPS,title,&top,&ePBC,&xtop,NULL,box,FALSE); + + *nslicex= (int)(box[XX][XX]/binw + onehalf); /*Calculate slicenr from binwidth*/ + *nslicey= (int)(box[YY][YY]/binw + onehalf); + nslicez= (int)(box[ZZ][ZZ]/binw + onehalf); + + + + ng = 1; + /* get index groups */ + printf("Select the group that contains the atoms you want to use for the tetrahedrality order parameter calculation:\n"); + snew(grpname,ng); + snew(index,ng); + snew(isize,ng); + get_index(&top.atoms,fnNDX,ng,isize,index,grpname); + + /* Analyze trajectory */ + natoms=read_first_x(oenv,&status,fnTRX,&t,&x,box); + if ( natoms > top.atoms.nr ) + gmx_fatal(FARGS,"Topology (%d atoms) does not match trajectory (%d atoms)", + top.atoms.nr,natoms); + check_index(NULL,ng,index[0],NULL,natoms); + + + /*Prepare structures for temporary storage of frame info*/ + snew(sg_grid,*nslicex); + snew(sk_grid,*nslicex); + for(i=0;i<*nslicex;i++) + { + snew(sg_grid[i],*nslicey); + snew(sk_grid[i],*nslicey); + for(j=0;j<*nslicey;j++) + { + snew(sg_grid[i][j],nslicez); + snew(sk_grid[i][j],nslicez); + } + } + + sg_4d=NULL; + sk_4d=NULL; + *nframes = 0; + framenr=0; + +/* Loop over frames*/ + do + { + /*Initialize box meshes (temporary storage for each tblock frame -reinitialise every tblock steps */ + if(framenr%tblock ==0) + { + srenew(sk_4d,*nframes+1); + srenew(sg_4d,*nframes+1); + snew(sg_fravg,*nslicex); + snew(sk_fravg,*nslicex); + for(i=0;i<*nslicex;i++) + { + snew(sg_fravg[i],*nslicey); + snew(sk_fravg[i],*nslicey); + for(j=0;j<*nslicey;j++) + { + snew(sg_fravg[i][j],nslicez); + snew(sk_fravg[i][j],nslicez); + } + } + } + + find_tetra_order_grid(top,ePBC,natoms,box,x,isize[0],index[0],t, + &sg,&sk,*nslicex,*nslicey,nslicez,sg_grid,sk_grid); + for(i=0;i<*nslicex;i++) + { + for(j=0;j<*nslicey;j++) + { + for(k=0;k 0.01){ + pos=( (sgintf-sg_4d[n][i][j][perm[ndx1]])*perm[ndx1+1]+(sg_4d[n][i][j][perm[ndx1+1]]-sgintf)*perm[ndx1 ])*/ + (*intfpos)[0][n][j+*nslicey*i]=(perm[ndx1]+onehalf)*binw; + /*right interface (1)*/ + /*alpha=(sgintf-sg_4d[n][i][j][perm[ndx2]])/(sg_4d[n][i][j][perm[ndx2]+1]-sg_4d[n][i][j][perm[ndx2]]);*/ + /*(*intfpos)[1][n][j+*nslicey*i]=((1-alpha)*perm[ndx2]+alpha*(perm[ndx2]+1)+onehalf)*box[ZZ][ZZ]/nslicez;*/ + (*intfpos)[1][n][j+*nslicey*i]=(perm[ndx2]+onehalf)*binw; + } + } + } + + + /*sfree(perm);*/ + sfree(sk_4d); + sfree(sg_4d); + /*sfree(sg_grid);*/ + /*sfree(sk_grid);*/ + + +} + +static void writesurftoxpms(real ***surf, int tblocks,int xbins, int ybins, real bw,char **outfiles,int maplevels ) +{ + + char numbuf[8]; + int n, i, j; + real **profile1, **profile2; + real max1, max2, min1, min2, *xticks, *yticks; + t_rgb lo={1,1,1}; + t_rgb hi={0,0,0}; + FILE *xpmfile1, *xpmfile2; + +/*Prepare xpm structures for output*/ + +/*Allocate memory to tick's and matrices*/ + snew (xticks,xbins+1); + snew (yticks,ybins+1); + + profile1=mk_matrix(xbins,ybins,FALSE); + profile2=mk_matrix(xbins,ybins,FALSE); + + for (i=0;imax1) max1=profile1[i][j]; + if(profile1[i][j]max2) max2=profile2[i][j]; + if(profile2[i][j] U) or a continuous one" }, + "Use a discrete folding criterion (F <-> U) or a continuous one" }, { "-mult", FALSE, etINT, {&nmult}, "Factor to multiply the data with before discretization" } }; diff -Nru gromacs-4.5.4/src/tools/gmx_membed.c gromacs-4.5.5/src/tools/gmx_membed.c --- gromacs-4.5.4/src/tools/gmx_membed.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_membed.c 2011-09-21 12:34:32.000000000 +0000 @@ -153,7 +153,7 @@ int *mol; int *block; int nr; -} rm_t; +} rmm_t; int search_string(char *s,int ng,char ***gn) { @@ -560,7 +560,7 @@ } } -int gen_rm_list(rm_t *rm_p,t_block *ins_at,t_block *rest_at,t_pbc *pbc, gmx_mtop_t *mtop, +int gen_rm_list(rmm_t *rm_p,t_block *ins_at,t_block *rest_at,t_pbc *pbc, gmx_mtop_t *mtop, rvec *r, rvec *r_ins, mem_t *mem_p, pos_ins_t *pos_ins, real probe_rad, int low_up_rm, gmx_bool bALLOW_ASYMMETRY) { int i,j,k,l,at,at2,mol_id; @@ -697,7 +697,7 @@ return nupper+nlower; } -void rm_group(t_inputrec *ir, gmx_groups_t *groups, gmx_mtop_t *mtop, rm_t *rm_p, t_state *state, t_block *ins_at, pos_ins_t *pos_ins) +void rm_group(t_inputrec *ir, gmx_groups_t *groups, gmx_mtop_t *mtop, rmm_t *rm_p, t_state *state, t_block *ins_at, pos_ins_t *pos_ins) { int i,j,k,n,rm,mol_id,at,block; rvec *x_tmp,*v_tmp; @@ -873,7 +873,7 @@ return rm_at; } -void top_update(const char *topfile, char *ins, rm_t *rm_p, gmx_mtop_t *mtop) +void top_update(const char *topfile, char *ins, rmm_t *rm_p, gmx_mtop_t *mtop) { #define TEMP_FILENM "temp.top" int bMolecules=0; @@ -944,866 +944,6 @@ #undef TEMP_FILENM } -void md_print_warning(const t_commrec *cr,FILE *fplog,const char *buf) -{ - if (MASTER(cr)) - { - fprintf(stderr,"\n%s\n",buf); - } - if (fplog) - { - fprintf(fplog,"\n%s\n",buf); - } -} - -/* simulation conditions to transmit. Keep in mind that they are - transmitted to other nodes through an MPI_Reduce after - casting them to a real (so the signals can be sent together with other - data). This means that the only meaningful values are positive, - negative or zero. */ -enum { eglsNABNSB, eglsCHKPT, eglsSTOPCOND, eglsRESETCOUNTERS, eglsNR }; -/* Is the signal in one simulation independent of other simulations? */ -gmx_bool gs_simlocal[eglsNR] = { TRUE, FALSE, FALSE, TRUE }; - -typedef struct { - int nstms; /* The frequency for intersimulation communication */ - int sig[eglsNR]; /* The signal set by one process in do_md */ - int set[eglsNR]; /* The communicated signal, equal for all processes */ -} globsig_t; - - -static int multisim_min(const gmx_multisim_t *ms,int nmin,int n) -{ - int *buf; - gmx_bool bPos,bEqual; - int s,d; - - snew(buf,ms->nsim); - buf[ms->sim] = n; - gmx_sumi_sim(ms->nsim,buf,ms); - bPos = TRUE; - bEqual = TRUE; - for(s=0; snsim; s++) - { - bPos = bPos && (buf[s] > 0); - bEqual = bEqual && (buf[s] == buf[0]); - } - if (bPos) - { - if (bEqual) - { - nmin = min(nmin,buf[0]); - } - else - { - /* Find the least common multiple */ - for(d=2; dnsim && d % buf[s] == 0) - { - s++; - } - if (s == ms->nsim) - { - /* We found the LCM and it is less than nmin */ - nmin = d; - break; - } - } - } - } - sfree(buf); - - return nmin; -} - -static int multisim_nstsimsync(const t_commrec *cr, - const t_inputrec *ir,int repl_ex_nst) -{ - int nmin; - - if (MASTER(cr)) - { - nmin = INT_MAX; - nmin = multisim_min(cr->ms,nmin,ir->nstlist); - nmin = multisim_min(cr->ms,nmin,ir->nstcalcenergy); - nmin = multisim_min(cr->ms,nmin,repl_ex_nst); - if (nmin == INT_MAX) - { - gmx_fatal(FARGS,"Can not find an appropriate interval for inter-simulation communication, since nstlist, nstcalcenergy and -replex are all <= 0"); - } - /* Avoid inter-simulation communication at every (second) step */ - if (nmin <= 2) - { - nmin = 10; - } - } - - gmx_bcast(sizeof(int),&nmin,cr); - - return nmin; -} - -static void init_global_signals(globsig_t *gs,const t_commrec *cr, - const t_inputrec *ir,int repl_ex_nst) -{ - int i; - - if (MULTISIM(cr)) - { - gs->nstms = multisim_nstsimsync(cr,ir,repl_ex_nst); - if (debug) - { - fprintf(debug,"Syncing simulations for checkpointing and termination every %d steps\n",gs->nstms); - } - } - else - { - gs->nstms = 1; - } - - for(i=0; isig[i] = 0; - gs->set[i] = 0; - } -} - -static void copy_coupling_state(t_state *statea,t_state *stateb, - gmx_ekindata_t *ekinda,gmx_ekindata_t *ekindb, t_grpopts* opts) -{ - - /* MRS note -- might be able to get rid of some of the arguments. Look over it when it's all debugged */ - - int i,j,nc; - - /* Make sure we have enough space for x and v */ - if (statea->nalloc > stateb->nalloc) - { - stateb->nalloc = statea->nalloc; - srenew(stateb->x,stateb->nalloc); - srenew(stateb->v,stateb->nalloc); - } - - stateb->natoms = statea->natoms; - stateb->ngtc = statea->ngtc; - stateb->nnhpres = statea->nnhpres; - stateb->veta = statea->veta; - if (ekinda) - { - copy_mat(ekinda->ekin,ekindb->ekin); - for (i=0; ingtc; i++) - { - ekindb->tcstat[i].T = ekinda->tcstat[i].T; - ekindb->tcstat[i].Th = ekinda->tcstat[i].Th; - copy_mat(ekinda->tcstat[i].ekinh,ekindb->tcstat[i].ekinh); - copy_mat(ekinda->tcstat[i].ekinf,ekindb->tcstat[i].ekinf); - ekindb->tcstat[i].ekinscalef_nhc = ekinda->tcstat[i].ekinscalef_nhc; - ekindb->tcstat[i].ekinscaleh_nhc = ekinda->tcstat[i].ekinscaleh_nhc; - ekindb->tcstat[i].vscale_nhc = ekinda->tcstat[i].vscale_nhc; - } - } - copy_rvecn(statea->x,stateb->x,0,stateb->natoms); - copy_rvecn(statea->v,stateb->v,0,stateb->natoms); - copy_mat(statea->box,stateb->box); - copy_mat(statea->box_rel,stateb->box_rel); - copy_mat(statea->boxv,stateb->boxv); - - for (i = 0; ingtc; i++) - { - nc = i*opts->nhchainlength; - for (j=0; jnhchainlength; j++) - { - stateb->nosehoover_xi[nc+j] = statea->nosehoover_xi[nc+j]; - stateb->nosehoover_vxi[nc+j] = statea->nosehoover_vxi[nc+j]; - } - } - if (stateb->nhpres_xi != NULL) - { - for (i = 0; innhpres; i++) - { - nc = i*opts->nhchainlength; - for (j=0; jnhchainlength; j++) - { - stateb->nhpres_xi[nc+j] = statea->nhpres_xi[nc+j]; - stateb->nhpres_vxi[nc+j] = statea->nhpres_vxi[nc+j]; - } - } - } -} - -static void compute_globals(FILE *fplog, gmx_global_stat_t gstat, t_commrec *cr, t_inputrec *ir, - t_forcerec *fr, gmx_ekindata_t *ekind, - t_state *state, t_state *state_global, t_mdatoms *mdatoms, - t_nrnb *nrnb, t_vcm *vcm, gmx_wallcycle_t wcycle, - gmx_enerdata_t *enerd,tensor force_vir, tensor shake_vir, tensor total_vir, - tensor pres, rvec mu_tot, gmx_constr_t constr, - globsig_t *gs,gmx_bool bInterSimGS, - matrix box, gmx_mtop_t *top_global, real *pcurr, - int natoms, gmx_bool *bSumEkinhOld, int flags) -{ - int i,gsi; - real gs_buf[eglsNR]; - tensor corr_vir,corr_pres; - gmx_bool bEner,bPres,bTemp; - gmx_bool bRerunMD, bStopCM, bGStat, bIterate, - bFirstIterate,bReadEkin,bEkinAveVel,bScaleEkin, bConstrain; - real prescorr,enercorr,dvdlcorr; - - /* translate CGLO flags to gmx_booleans */ - bRerunMD = flags & CGLO_RERUNMD; - bStopCM = flags & CGLO_STOPCM; - bGStat = flags & CGLO_GSTAT; - bReadEkin = (flags & CGLO_READEKIN); - bScaleEkin = (flags & CGLO_SCALEEKIN); - bEner = flags & CGLO_ENERGY; - bTemp = flags & CGLO_TEMPERATURE; - bPres = (flags & CGLO_PRESSURE); - bConstrain = (flags & CGLO_CONSTRAINT); - bIterate = (flags & CGLO_ITERATE); - bFirstIterate = (flags & CGLO_FIRSTITERATE); - - /* we calculate a full state kinetic energy either with full-step velocity verlet - or half step where we need the pressure */ - bEkinAveVel = (ir->eI==eiVV || (ir->eI==eiVVAK && IR_NPT_TROTTER(ir) && bPres) || bReadEkin); - - /* in initalization, it sums the shake virial in vv, and to - sums ekinh_old in leapfrog (or if we are calculating ekinh_old for other reasons */ - - /* ########## Kinetic energy ############## */ - - if (bTemp) - { - /* Non-equilibrium MD: this is parallellized, but only does communication - * when there really is NEMD. - */ - - if (PAR(cr) && (ekind->bNEMD)) - { - accumulate_u(cr,&(ir->opts),ekind); - } - debug_gmx(); - if (bReadEkin) - { - restore_ekinstate_from_state(cr,ekind,&state_global->ekinstate); - } - else - { - - calc_ke_part(state,&(ir->opts),mdatoms,ekind,nrnb,bEkinAveVel,bIterate); - } - - debug_gmx(); - - /* Calculate center of mass velocity if necessary, also parallellized */ - if (bStopCM && !bRerunMD && bEner) - { - calc_vcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms, - state->x,state->v,vcm); - } - } - - if (bTemp || bPres || bEner || bConstrain) - { - if (!bGStat) - { - /* We will not sum ekinh_old, - * so signal that we still have to do it. - */ - *bSumEkinhOld = TRUE; - - } - else - { - if (gs != NULL) - { - for(i=0; isig[i]; - } - } - if (PAR(cr)) - { - wallcycle_start(wcycle,ewcMoveE); - GMX_MPE_LOG(ev_global_stat_start); - global_stat(fplog,gstat,cr,enerd,force_vir,shake_vir,mu_tot, - ir,ekind,constr,vcm, - gs != NULL ? eglsNR : 0,gs_buf, - top_global,state, - *bSumEkinhOld,flags); - GMX_MPE_LOG(ev_global_stat_finish); - wallcycle_stop(wcycle,ewcMoveE); - } - if (gs != NULL) - { - if (MULTISIM(cr) && bInterSimGS) - { - if (MASTER(cr)) - { - /* Communicate the signals between the simulations */ - gmx_sum_sim(eglsNR,gs_buf,cr->ms); - } - /* Communicate the signals form the master to the others */ - gmx_bcast(eglsNR*sizeof(gs_buf[0]),gs_buf,cr); - } - for(i=0; i= 0 ? - (int)(gs_buf[i] + 0.5) : - (int)(gs_buf[i] - 0.5)); - if (gsi != 0) - { - gs->set[i] = gsi; - } - /* Turn off the local signal */ - gs->sig[i] = 0; - } - } - } - *bSumEkinhOld = FALSE; - } - } - - if (!ekind->bNEMD && debug && bTemp && (vcm->nr > 0)) - { - correct_ekin(debug, - mdatoms->start,mdatoms->start+mdatoms->homenr, - state->v,vcm->group_p[0], - mdatoms->massT,mdatoms->tmass,ekind->ekin); - } - - if (bEner) { - /* Do center of mass motion removal */ - if (bStopCM && !bRerunMD) /* is this correct? Does it get called too often with this logic? */ - { - check_cm_grp(fplog,vcm,ir,1); - do_stopcm_grp(fplog,mdatoms->start,mdatoms->homenr,mdatoms->cVCM, - state->x,state->v,vcm); - inc_nrnb(nrnb,eNR_STOPCM,mdatoms->homenr); - } - } - - if (bTemp) - { - /* Sum the kinetic energies of the groups & calc temp */ - /* compute full step kinetic energies if vv, or if vv-avek and we are computing the pressure with IR_NPT_TROTTER */ - /* three maincase: VV with AveVel (md-vv), vv with AveEkin (md-vv-avek), leap with AveEkin (md). - Leap with AveVel is also an option for the future but not supported now. - bEkinAveVel: If TRUE, we simply multiply ekin by ekinscale to get a full step kinetic energy. - If FALSE, we average ekinh_old and ekinh*ekinscale_nhc to get an averaged half step kinetic energy. - bSaveEkinOld: If TRUE (in the case of iteration = bIterate is TRUE), we don't reset the ekinscale_nhc. - If FALSE, we go ahead and erase over it. - */ - enerd->term[F_TEMP] = sum_ekin(&(ir->opts),ekind,&(enerd->term[F_DKDL]), - bEkinAveVel,bIterate,bScaleEkin); - - enerd->term[F_EKIN] = trace(ekind->ekin); - } - - /* ########## Long range energy information ###### */ - - if (bEner || bPres || bConstrain) - { - calc_dispcorr(fplog,ir,fr,0,top_global->natoms,box,state->lambda, - corr_pres,corr_vir,&prescorr,&enercorr,&dvdlcorr); - } - - if (bEner && bFirstIterate) - { - enerd->term[F_DISPCORR] = enercorr; - enerd->term[F_EPOT] += enercorr; - enerd->term[F_DVDL] += dvdlcorr; - if (fr->efep != efepNO) { - enerd->dvdl_lin += dvdlcorr; - } - } - - /* ########## Now pressure ############## */ - if (bPres || bConstrain) - { - - m_add(force_vir,shake_vir,total_vir); - - /* Calculate pressure and apply LR correction if PPPM is used. - * Use the box from last timestep since we already called update(). - */ - - enerd->term[F_PRES] = calc_pres(fr->ePBC,ir->nwall,box,ekind->ekin,total_vir,pres, - (fr->eeltype==eelPPPM)?enerd->term[F_COUL_RECIP]:0.0); - - /* Calculate long range corrections to pressure and energy */ - /* this adds to enerd->term[F_PRES] and enerd->term[F_ETOT], - and computes enerd->term[F_DISPCORR]. Also modifies the - total_vir and pres tesors */ - - m_add(total_vir,corr_vir,total_vir); - m_add(pres,corr_pres,pres); - enerd->term[F_PDISPCORR] = prescorr; - enerd->term[F_PRES] += prescorr; - *pcurr = enerd->term[F_PRES]; - /* calculate temperature using virial */ - enerd->term[F_VTEMP] = calc_temp(trace(total_vir),ir->opts.nrdf[0]); - - } -} - - -/* Definitions for convergence of iterated constraints */ - -/* iterate constraints up to 50 times */ -#define MAXITERCONST 50 - -/* data type */ -typedef struct -{ - real f,fprev,x,xprev; - int iter_i; - gmx_bool bIterate; - real allrelerr[MAXITERCONST+2]; - int num_close; /* number of "close" violations, caused by limited precision. */ -} gmx_iterate_t; - -#ifdef GMX_DOUBLE -#define CONVERGEITER 0.000000001 -#define CLOSE_ENOUGH 0.000001000 -#else -#define CONVERGEITER 0.0001 -#define CLOSE_ENOUGH 0.0050 -#endif - -/* we want to keep track of the close calls. If there are too many, there might be some other issues. - so we make sure that it's either less than some predetermined number, or if more than that number, - only some small fraction of the total. */ -#define MAX_NUMBER_CLOSE 50 -#define FRACTION_CLOSE 0.001 - -/* maximum length of cyclic traps to check, emerging from limited numerical precision */ -#define CYCLEMAX 20 - -static void gmx_iterate_init(gmx_iterate_t *iterate,gmx_bool bIterate) -{ - int i; - - iterate->iter_i = 0; - iterate->bIterate = bIterate; - iterate->num_close = 0; - for (i=0;iallrelerr[i] = 0; - } -} - -static gmx_bool done_iterating(const t_commrec *cr,FILE *fplog, int nsteps, gmx_iterate_t *iterate, gmx_bool bFirstIterate, real fom, real *newf) -{ - /* monitor convergence, and use a secant search to propose new - values. - x_{i} - x_{i-1} - The secant method computes x_{i+1} = x_{i} - f(x_{i}) * --------------------- - f(x_{i}) - f(x_{i-1}) - - The function we are trying to zero is fom-x, where fom is the - "figure of merit" which is the pressure (or the veta value) we - would get by putting in an old value of the pressure or veta into - the incrementor function for the step or half step. I have - verified that this gives the same answer as self consistent - iteration, usually in many fewer steps, especially for small tau_p. - - We could possibly eliminate an iteration with proper use - of the value from the previous step, but that would take a bit - more bookkeeping, especially for veta, since tests indicate the - function of veta on the last step is not sufficiently close to - guarantee convergence this step. This is - good enough for now. On my tests, I could use tau_p down to - 0.02, which is smaller that would ever be necessary in - practice. Generally, 3-5 iterations will be sufficient */ - - real relerr,err; - char buf[256]; - int i; - gmx_bool incycle; - - if (bFirstIterate) - { - iterate->x = fom; - iterate->f = fom-iterate->x; - iterate->xprev = 0; - iterate->fprev = 0; - *newf = fom; - } - else - { - iterate->f = fom-iterate->x; /* we want to zero this difference */ - if ((iterate->iter_i > 1) && (iterate->iter_i < MAXITERCONST)) - { - if (iterate->f==iterate->fprev) - { - *newf = iterate->f; - } - else - { - *newf = iterate->x - (iterate->x-iterate->xprev)*(iterate->f)/(iterate->f-iterate->fprev); - } - } - else - { - /* just use self-consistent iteration the first step to initialize, or - if it's not converging (which happens occasionally -- need to investigate why) */ - *newf = fom; - } - } - /* Consider a slight shortcut allowing us to exit one sooner -- we check the - difference between the closest of x and xprev to the new - value. To be 100% certain, we should check the difference between - the last result, and the previous result, or - - relerr = (fabs((x-xprev)/fom)); - - but this is pretty much never necessary under typical conditions. - Checking numerically, it seems to lead to almost exactly the same - trajectories, but there are small differences out a few decimal - places in the pressure, and eventually in the v_eta, but it could - save an interation. - - if (fabs(*newf-x) < fabs(*newf - xprev)) { xmin = x;} else { xmin = xprev;} - relerr = (fabs((*newf-xmin) / *newf)); - */ - - err = fabs((iterate->f-iterate->fprev)); - relerr = fabs(err/fom); - - iterate->allrelerr[iterate->iter_i] = relerr; - - if (iterate->iter_i > 0) - { - if (debug) - { - fprintf(debug,"Iterating NPT constraints: %6i %20.12f%14.6g%20.12f\n", - iterate->iter_i,fom,relerr,*newf); - } - - if ((relerr < CONVERGEITER) || (err < CONVERGEITER) || (fom==0) || ((iterate->x == iterate->xprev) && iterate->iter_i > 1)) - { - iterate->bIterate = FALSE; - if (debug) - { - fprintf(debug,"Iterating NPT constraints: CONVERGED\n"); - } - return TRUE; - } - if (iterate->iter_i > MAXITERCONST) - { - if (relerr < CLOSE_ENOUGH) - { - incycle = FALSE; - for (i=1;iallrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-1]) && - (iterate->allrelerr[iterate->iter_i-(1+i)] == iterate->allrelerr[iterate->iter_i-(1+2*i)])) { - incycle = TRUE; - if (debug) - { - fprintf(debug,"Exiting from an NPT iterating cycle of length %d\n",i); - } - break; - } - } - - if (incycle) { - /* step 1: trapped in a numerical attractor */ - /* we are trapped in a numerical attractor, and can't converge any more, and are close to the final result. - Better to give up convergence here than have the simulation die. - */ - iterate->num_close++; - return TRUE; - } - else - { - /* Step #2: test if we are reasonably close for other reasons, then monitor the number. If not, die */ - - /* how many close calls have we had? If less than a few, we're OK */ - if (iterate->num_close < MAX_NUMBER_CLOSE) - { - sprintf(buf,"Slight numerical convergence deviation with NPT at step %d, relative error only %10.5g, likely not a problem, continuing\n",nsteps,relerr); - md_print_warning(cr,fplog,buf); - iterate->num_close++; - return TRUE; - /* if more than a few, check the total fraction. If too high, die. */ - } else if (iterate->num_close/(double)nsteps > FRACTION_CLOSE) { - gmx_fatal(FARGS,"Could not converge NPT constraints, too many exceptions (%d%%\n",iterate->num_close/(double)nsteps); - } - } - } - else - { - gmx_fatal(FARGS,"Could not converge NPT constraints\n"); - } - } - } - - iterate->xprev = iterate->x; - iterate->x = *newf; - iterate->fprev = iterate->f; - iterate->iter_i++; - - return FALSE; -} - -static void check_nst_param(FILE *fplog,t_commrec *cr, - const char *desc_nst,int nst, - const char *desc_p,int *p) -{ - char buf[STRLEN]; - - if (*p > 0 && *p % nst != 0) - { - /* Round up to the next multiple of nst */ - *p = ((*p)/nst + 1)*nst; - sprintf(buf,"NOTE: %s changes %s to %d\n",desc_nst,desc_p,*p); - md_print_warning(cr,fplog,buf); - } -} - -static void reset_all_counters(FILE *fplog,t_commrec *cr, - gmx_large_int_t step, - gmx_large_int_t *step_rel,t_inputrec *ir, - gmx_wallcycle_t wcycle,t_nrnb *nrnb, - gmx_runtime_t *runtime) -{ - char buf[STRLEN],sbuf[STEPSTRSIZE]; - - /* Reset all the counters related to performance over the run */ - sprintf(buf,"Step %s: resetting all time and cycle counters\n", - gmx_step_str(step,sbuf)); - md_print_warning(cr,fplog,buf); - - wallcycle_stop(wcycle,ewcRUN); - wallcycle_reset_all(wcycle); - if (DOMAINDECOMP(cr)) - { - reset_dd_statistics_counters(cr->dd); - } - init_nrnb(nrnb); - ir->init_step += *step_rel; - ir->nsteps -= *step_rel; - *step_rel = 0; - wallcycle_start(wcycle,ewcRUN); - runtime_start(runtime); - print_date_and_time(fplog,cr->nodeid,"Restarted time",runtime); -} - -static int check_nstglobalcomm(FILE *fplog,t_commrec *cr, - int nstglobalcomm,t_inputrec *ir) -{ - char buf[STRLEN]; - - if (!EI_DYNAMICS(ir->eI)) - { - nstglobalcomm = 1; - } - - if (nstglobalcomm == -1) - { - if (ir->nstcalcenergy == 0 && ir->nstlist == 0) - { - nstglobalcomm = 10; - if (ir->nstenergy > 0 && ir->nstenergy < nstglobalcomm) - { - nstglobalcomm = ir->nstenergy; - } - } - else - { - /* We assume that if nstcalcenergy > nstlist, - * nstcalcenergy is a multiple of nstlist. - */ - if (ir->nstcalcenergy == 0 || - (ir->nstlist > 0 && ir->nstlist < ir->nstcalcenergy)) - { - nstglobalcomm = ir->nstlist; - } - else - { - nstglobalcomm = ir->nstcalcenergy; - } - } - } - else - { - if (ir->nstlist > 0 && - nstglobalcomm > ir->nstlist && nstglobalcomm % ir->nstlist != 0) - { - nstglobalcomm = (nstglobalcomm / ir->nstlist)*ir->nstlist; - sprintf(buf,"WARNING: nstglobalcomm is larger than nstlist, but not a multiple, setting it to %d\n",nstglobalcomm); - md_print_warning(cr,fplog,buf); - } - if (nstglobalcomm > ir->nstcalcenergy) - { - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nstcalcenergy",&ir->nstcalcenergy); - } - - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nstenergy",&ir->nstenergy); - - check_nst_param(fplog,cr,"-gcom",nstglobalcomm, - "nstlog",&ir->nstlog); - } - - if (ir->comm_mode != ecmNO && ir->nstcomm < nstglobalcomm) - { - sprintf(buf,"WARNING: Changing nstcomm from %d to %d\n", - ir->nstcomm,nstglobalcomm); - md_print_warning(cr,fplog,buf); - ir->nstcomm = nstglobalcomm; - } - - return nstglobalcomm; -} - -void check_ir_old_tpx_versions(t_commrec *cr,FILE *fplog, - t_inputrec *ir,gmx_mtop_t *mtop) -{ - /* Check required for old tpx files */ - if (IR_TWINRANGE(*ir) && ir->nstlist > 1 && - ir->nstcalcenergy % ir->nstlist != 0) - { - md_print_warning(cr,fplog,"Old tpr file with twin-range settings: modifying energy calculation and/or T/P-coupling frequencies"); - - if (gmx_mtop_ftype_count(mtop,F_CONSTR) + - gmx_mtop_ftype_count(mtop,F_CONSTRNC) > 0 && - ir->eConstrAlg == econtSHAKE) - { - md_print_warning(cr,fplog,"With twin-range cut-off's and SHAKE the virial and pressure are incorrect"); - if (ir->epc != epcNO) - { - gmx_fatal(FARGS,"Can not do pressure coupling with twin-range cut-off's and SHAKE"); - } - } - check_nst_param(fplog,cr,"nstlist",ir->nstlist, - "nstcalcenergy",&ir->nstcalcenergy); - check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, - "nstenergy",&ir->nstenergy); - check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, - "nstlog",&ir->nstlog); - if (ir->efep != efepNO) - { - check_nst_param(fplog,cr,"nstcalcenergy",ir->nstcalcenergy, - "nstdhdl",&ir->nstdhdl); - } - } -} - -typedef struct { - gmx_bool bGStatEveryStep; - gmx_large_int_t step_ns; - gmx_large_int_t step_nscheck; - gmx_large_int_t nns; - matrix scale_tot; - int nabnsb; - double s1; - double s2; - double ab; - double lt_runav; - double lt_runav2; -} gmx_nlheur_t; - -static void reset_nlistheuristics(gmx_nlheur_t *nlh,gmx_large_int_t step) -{ - nlh->lt_runav = 0; - nlh->lt_runav2 = 0; - nlh->step_nscheck = step; -} - -static void init_nlistheuristics(gmx_nlheur_t *nlh, - gmx_bool bGStatEveryStep,gmx_large_int_t step) -{ - nlh->bGStatEveryStep = bGStatEveryStep; - nlh->nns = 0; - nlh->nabnsb = 0; - nlh->s1 = 0; - nlh->s2 = 0; - nlh->ab = 0; - - reset_nlistheuristics(nlh,step); -} - -static void update_nliststatistics(gmx_nlheur_t *nlh,gmx_large_int_t step) -{ - gmx_large_int_t nl_lt; - char sbuf[STEPSTRSIZE],sbuf2[STEPSTRSIZE]; - - /* Determine the neighbor list life time */ - nl_lt = step - nlh->step_ns; - if (debug) - { - fprintf(debug,"%d atoms beyond ns buffer, updating neighbor list after %s steps\n",nlh->nabnsb,gmx_step_str(nl_lt,sbuf)); - } - nlh->nns++; - nlh->s1 += nl_lt; - nlh->s2 += nl_lt*nl_lt; - nlh->ab += nlh->nabnsb; - if (nlh->lt_runav == 0) - { - nlh->lt_runav = nl_lt; - /* Initialize the fluctuation average - * such that at startup we check after 0 steps. - */ - nlh->lt_runav2 = sqr(nl_lt/2.0); - } - /* Running average with 0.9 gives an exp. history of 9.5 */ - nlh->lt_runav2 = 0.9*nlh->lt_runav2 + 0.1*sqr(nlh->lt_runav - nl_lt); - nlh->lt_runav = 0.9*nlh->lt_runav + 0.1*nl_lt; - if (nlh->bGStatEveryStep) - { - /* Always check the nlist validity */ - nlh->step_nscheck = step; - } - else - { - /* We check after: - 2*sigma - * The factor 2 is quite conservative, - * but we assume that with nstlist=-1 the user - * prefers exact integration over performance. - */ - nlh->step_nscheck = step - + (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2)) - 1; - } - if (debug) - { - fprintf(debug,"nlist life time %s run av. %4.1f sig %3.1f check %s check with -gcom %d\n", - gmx_step_str(nl_lt,sbuf),nlh->lt_runav,sqrt(nlh->lt_runav2), - gmx_step_str(nlh->step_nscheck-step+1,sbuf2), - (int)(nlh->lt_runav - 2.0*sqrt(nlh->lt_runav2))); - } -} - -static void set_nlistheuristics(gmx_nlheur_t *nlh,gmx_bool bReset,gmx_large_int_t step) -{ - int d; - - if (bReset) - { - reset_nlistheuristics(nlh,step); - } - else - { - update_nliststatistics(nlh,step); - } - - nlh->step_ns = step; - /* Initialize the cumulative coordinate scaling matrix */ - clear_mat(nlh->scale_tot); - for(d=0; dscale_tot[d][d] = 1.0; - } -} - double do_md_membed(FILE *fplog,t_commrec *cr,int nfile,const t_filenm fnm[], const output_env_t oenv, gmx_bool bVerbose,gmx_bool bCompact, int nstglobalcomm, @@ -3618,7 +2758,7 @@ t_block *ins_at,*rest_at; pos_ins_t *pos_ins; mem_t *mem_p; - rm_t *rm_p; + rmm_t *rm_p; gmx_groups_t *groups; gmx_bool bExcl=FALSE; t_atoms atoms; @@ -4283,14 +3423,13 @@ { const char *desc[] = { "[TT]g_membed[tt] embeds a membrane protein into an equilibrated lipid bilayer at the position", - "and orientation specified by the user.\n", - "\n", - "SHORT MANUAL\n------------\n", + "and orientation specified by the user.[PAR]", + "SHORT MANUAL[BR]------------[BR]", "The user should merge the structure files of the protein and membrane (+solvent), creating a", "single structure file with the protein overlapping the membrane at the desired position and", - "orientation. Box size should be taken from the membrane structure file. The corresponding topology", + "orientation. The box size is taken from the membrane structure file. The corresponding topology", "files should also be merged. Consecutively, create a [TT].tpr[tt] file (input for [TT]g_membed[tt]) from these files," - "with the following options included in the [TT].mdp[tt] file.\n", + "with the following options included in the [TT].mdp[tt] file.[BR]", " - [TT]integrator = md[tt][BR]", " - [TT]energygrp = Protein[tt] (or other group that you want to insert)[BR]", " - [TT]freezegrps = Protein[tt][BR]", @@ -4298,32 +3437,29 @@ " - [TT]energygrp_excl = Protein Protein[tt][BR]", "The output is a structure file containing the protein embedded in the membrane. If a topology", "file is provided, the number of lipid and ", - "solvent molecules will be updated to match the new structure file.\n", - "For a more extensive manual see Wolf et al, J Comp Chem 31 (2010) 2169-2174, Appendix.\n", - "\n", - "SHORT METHOD DESCRIPTION\n", - "------------------------\n", - "1. The protein is resized around its center of mass by a factor -xy in the xy-plane", - "(the membrane plane) and a factor -z in the z-direction (if the size of the", + "solvent molecules will be updated to match the new structure file.[BR]", + "For a more extensive manual see Wolf et al, J Comp Chem 31 (2010) 2169-2174, Appendix.[PAR]", + "SHORT METHOD DESCRIPTION[BR]", + "------------------------[BR]", + "1. The protein is resized around its center of mass by a factor [TT]-xy[tt] in the xy-plane", + "(the membrane plane) and a factor [TT]-z[tt] in the [IT]z[it]-direction (if the size of the", "protein in the z-direction is the same or smaller than the width of the membrane, a", - "-z value larger than 1 can prevent that the protein will be enveloped by the lipids).\n", + "[TT]-z[tt] value larger than 1 can prevent that the protein will be enveloped by the lipids).[BR]", "2. All lipid and solvent molecules overlapping with the resized protein are removed. All", - "intraprotein interactions are turned off to prevent numerical issues for small values of -xy", - " or -z\n", - "3. One md step is performed.\n", - "4. The resize factor (-xy or -z) is incremented by a small amount ((1-xy)/nxy or (1-z)/nz) and the", + "intraprotein interactions are turned off to prevent numerical issues for small values of [TT]-xy[tt]", + " or [TT]-z[tt][BR]", + "3. One md step is performed.[BR]", + "4. The resize factor ([TT]-xy[tt] or [TT]-z[tt]) is incremented by a small amount ((1-xy)/nxy or (1-z)/nz) and the", "protein is resized again around its center of mass. The resize factor for the xy-plane", - "is incremented first. The resize factor for the z-direction is not changed until the -xy factor", - "is 1 (thus after -nxy iteration).\n", - "5. Repeat step 3 and 4 until the protein reaches its original size (-nxy + -nz iterations).\n", - "For a more extensive method descrition see Wolf et al, J Comp Chem, 31 (2010) 2169-2174.\n", - "\n", - "NOTE\n----\n", - " - Protein can be any molecule you want to insert in the membrane.\n", + "is incremented first. The resize factor for the z-direction is not changed until the [TT]-xy[tt] factor", + "is 1 (thus after [TT]-nxy[tt] iterations).[BR]", + "5. Repeat step 3 and 4 until the protein reaches its original size ([TT]-nxy[tt] + [TT]-nz[tt] iterations).[BR]", + "For a more extensive method description see Wolf et al, J Comp Chem, 31 (2010) 2169-2174.[PAR]", + "NOTE[BR]----[BR]", + " - Protein can be any molecule you want to insert in the membrane.[BR]", " - It is recommended to perform a short equilibration run after the embedding", - "(see Wolf et al, J Comp Chem 31 (2010) 2169-2174, to re-equilibrate the membrane. Clearly", - "protein equilibration might require longer.\n", - "\n" + "(see Wolf et al, J Comp Chem 31 (2010) 2169-2174), to re-equilibrate the membrane. Clearly", + "protein equilibration might require longer.[PAR]" }; t_commrec *cr; t_filenm fnm[] = { @@ -4543,7 +3679,7 @@ only started at mdrunner_threads, though. */ if (nthreads<1) { - nthreads=tMPI_Get_recommended_nthreads(); + nthreads=tMPI_Thread_get_hw_number(); } #else nthreads=1; diff -Nru gromacs-4.5.4/src/tools/gmx_mindist.c gromacs-4.5.5/src/tools/gmx_mindist.c --- gromacs-4.5.4/src/tools/gmx_mindist.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_mindist.c 2011-09-21 12:34:32.000000000 +0000 @@ -485,7 +485,7 @@ "(between any pair of atoms from the respective groups)", "and the number of contacts within a given", "distance are written to two separate output files.", - "With the [TT]-group[tt] option a contact of an atom an other group", + "With the [TT]-group[tt] option a contact of an atom in another group", "with multiple atoms in the first group is counted as one contact", "instead of as multiple contacts.", "With [TT]-or[tt], minimum distances to each residue in the first", diff -Nru gromacs-4.5.4/src/tools/gmx_morph.c gromacs-4.5.5/src/tools/gmx_morph.c --- gromacs-4.5.4/src/tools/gmx_morph.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_morph.c 2011-09-21 12:34:10.000000000 +0000 @@ -74,13 +74,13 @@ "the [TT]-ninterm[tt] flag. The first and last flag correspond to the way of", "interpolating: 0 corresponds to input structure 1 while", "1 corresponds to input structure 2.", - "If you specify first < 0 or last > 1 extrapolation will be", - "on the path from input structure x1 to x2. In general the coordinates", + "If you specify [TT]-first[tt] < 0 or [TT]-last[tt] > 1 extrapolation will be", + "on the path from input structure x1 to x2. In general, the coordinates", "of the intermediate x(i) out of N total intermidates correspond to:[PAR]", "x(i) = x1 + (first+(i/(N-1))*(last-first))*(x2-x1)[PAR]", "Finally the RMSD with respect to both input structures can be computed", - "if explicitly selected ([TT]-or[tt] option). In that case an index file may be", - "read to select what group RMS is computed from." + "if explicitly selected ([TT]-or[tt] option). In that case, an index file may be", + "read to select the group from which the RMS is computed." }; t_filenm fnm[] = { { efSTX, "-f1", "conf1", ffREAD }, diff -Nru gromacs-4.5.4/src/tools/gmx_nmeig.c gromacs-4.5.5/src/tools/gmx_nmeig.c --- gromacs-4.5.4/src/tools/gmx_nmeig.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_nmeig.c 2011-09-21 12:34:10.000000000 +0000 @@ -267,19 +267,19 @@ "output. In this case, they will no longer be exactly orthogonal in the", "standard Cartesian norm, but in the mass-weighted norm they would be.[PAR]", "This program can be optionally used to compute quantum corrections to heat capacity", - "and enthalpy by providing an extra file argument -qcorr. See gromacs", - "manual chapter 1 for details. The result includes subtracting a harmonic", + "and enthalpy by providing an extra file argument [TT]-qcorr[tt]. See the GROMACS", + "manual, Chapter 1, for details. The result includes subtracting a harmonic", "degree of freedom at the given temperature.", "The total correction is printed on the terminal screen.", - "The recommended way of getting the corrections out is:", - "g_nmeig -s topol.tpr -f nm.mtx -first 7 -last 10000 -T 300 -qc [-constr]", - "The constr should be used when bond constraints were used during the", - "simulation [BB]for all the covalent bonds[bb]. If this is not the case", - "you need to analyse the quant_corr.xvg file yourself.[PAR]", - "To make things more flexible, the program can also take vsites into account", + "The recommended way of getting the corrections out is:[PAR]", + "[TT]g_nmeig -s topol.tpr -f nm.mtx -first 7 -last 10000 -T 300 -qc [-constr][tt][PAR]", + "The [TT]-constr[tt] option should be used when bond constraints were used during the", + "simulation [BB]for all the covalent bonds[bb]. If this is not the case, ", + "you need to analyze the [TT]quant_corr.xvg[tt] file yourself.[PAR]", + "To make things more flexible, the program can also take virtual sites into account", "when computing quantum corrections. When selecting [TT]-constr[tt] and", - "[TT]-qc[tt] the [TT]-begin[tt] and [TT]-end[tt] options will be set automatically as well.", - "Again, if you think you know it better, please check the eigenfreq.xvg", + "[TT]-qc[tt], the [TT]-begin[tt] and [TT]-end[tt] options will be set automatically as well.", + "Again, if you think you know it better, please check the [TT]eigenfreq.xvg[tt]", "output." }; diff -Nru gromacs-4.5.4/src/tools/gmx_order.c gromacs-4.5.5/src/tools/gmx_order.c --- gromacs-4.5.4/src/tools/gmx_order.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_order.c 2011-09-21 12:34:10.000000000 +0000 @@ -801,7 +801,7 @@ { "-d", FALSE, etENUM, {normal_axis}, "Direction of the normal on the membrane" }, { "-sl", FALSE, etINT, {&nslices}, - "Calculate order parameter as function of boxlength, dividing the box" + "Calculate order parameter as function of box length, dividing the box" " in #nr slices." }, { "-szonly", FALSE, etBOOL,{&bSzonly}, "Only give Sz element of order tensor. (axis can be specified with [TT]-d[tt])" }, diff -Nru gromacs-4.5.4/src/tools/gmx_pme_error.c gromacs-4.5.5/src/tools/gmx_pme_error.c --- gromacs-4.5.4/src/tools/gmx_pme_error.c 2011-03-15 12:44:34.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_pme_error.c 2011-09-21 12:34:10.000000000 +0000 @@ -497,12 +497,12 @@ x_per_core = xtot; } /* -#ifdef GMX_MPI +#ifdef GMX_LIB_MPI MPI_Barrier(MPI_COMM_WORLD); #endif */ -#ifdef GMX_MPI +#ifdef GMX_LIB_MPI #ifdef TAKETIME if (MASTER(cr)) t0 = MPI_Wtime(); @@ -728,7 +728,7 @@ if (MASTER(cr)) fprintf(stderr, "\n"); - +#ifdef GMX_LIB_MPI #ifdef TAKETIME if (MASTER(cr)) { @@ -736,6 +736,7 @@ fprintf(fp_out, "Recip. err. est. took : %lf s\n", t1); } #endif +#endif #ifdef DEBUG if (PAR(cr)) @@ -1078,7 +1079,7 @@ cr = init_par(&argc,&argv); -#ifdef GMX_MPI +#ifdef GMX_LIB_MPI MPI_Barrier(MPI_COMM_WORLD); #endif diff -Nru gromacs-4.5.4/src/tools/gmx_potential.c gromacs-4.5.5/src/tools/gmx_potential.c --- gromacs-4.5.4/src/tools/gmx_potential.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_potential.c 2011-09-21 12:34:10.000000000 +0000 @@ -55,6 +55,11 @@ #include "index.h" #include "gmx_ana.h" +/* Suppress Cygwin compiler warnings from using newlib version of + * ctype.h */ +#ifdef GMX_CYGWIN +#undef toupper +#endif #define EPS0 8.85419E-12 #define ELC 1.60219E-19 diff -Nru gromacs-4.5.4/src/tools/gmx_rama.c gromacs-4.5.5/src/tools/gmx_rama.c --- gromacs-4.5.4/src/tools/gmx_rama.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_rama.c 2011-09-21 12:34:10.000000000 +0000 @@ -69,7 +69,7 @@ int gmx_rama(int argc,char *argv[]) { const char *desc[] = { - "[TT]g_rama[tt] selects the Phi/Psi dihedral combinations from your topology file", + "[TT]g_rama[tt] selects the [GRK]phi[grk]/[GRK]psi[grk] dihedral combinations from your topology file", "and computes these as a function of time.", "Using simple Unix tools such as [IT]grep[it] you can select out", "specific residues." diff -Nru gromacs-4.5.4/src/tools/gmx_rdf.c gromacs-4.5.5/src/tools/gmx_rdf.c --- gromacs-4.5.4/src/tools/gmx_rdf.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_rdf.c 2011-09-21 12:34:10.000000000 +0000 @@ -630,30 +630,30 @@ "The normal method is around a (set of) particle(s), the other methods", "are around the center of mass of a set of particles ([TT]-com[tt])", "or to the closest particle in a set ([TT]-surf[tt]).", - "With all methods rdf's can also be calculated around axes parallel", - "to the z-axis with option [TT]-xy[tt].", + "With all methods, the RDF can also be calculated around axes parallel", + "to the [IT]z[it]-axis with option [TT]-xy[tt].", "With option [TT]-surf[tt] normalization can not be used.[PAR]", - "The option [TT]-rdf[tt] sets the type of rdf to be computed.", + "The option [TT]-rdf[tt] sets the type of RDF to be computed.", "Default is for atoms or particles, but one can also select center", - "of mass or geometry of molecules or residues. In all cases only", + "of mass or geometry of molecules or residues. In all cases, only", "the atoms in the index groups are taken into account.", - "For molecules and/or the center of mass option a run input file", + "For molecules and/or the center of mass option, a run input file", "is required.", - "Other weighting than COM or COG can currently only be achieved", + "Weighting other than COM or COG can currently only be achieved", "by providing a run input file with different masses.", "Options [TT]-com[tt] and [TT]-surf[tt] also work in conjunction", "with [TT]-rdf[tt].[PAR]", "If a run input file is supplied ([TT]-s[tt]) and [TT]-rdf[tt] is set", "to [TT]atom[tt], exclusions defined", - "in that file are taken into account when calculating the rdf.", + "in that file are taken into account when calculating the RDF.", "The option [TT]-cut[tt] is meant as an alternative way to avoid", - "intramolecular peaks in the rdf plot.", + "intramolecular peaks in the RDF plot.", "It is however better to supply a run input file with a higher number of", - "exclusions. For eg. benzene a topology with nrexcl set to 5", - "would eliminate all intramolecular contributions to the rdf.", + "exclusions. For e.g. benzene a topology, setting nrexcl to 5", + "would eliminate all intramolecular contributions to the RDF.", "Note that all atoms in the selected groups are used, also the ones", "that don't have Lennard-Jones interactions.[PAR]", - "Option [TT]-cn[tt] produces the cumulative number rdf,", + "Option [TT]-cn[tt] produces the cumulative number RDF,", "i.e. the average number of particles within a distance r.[PAR]", "To bridge the gap between theory and experiment structure factors can", "be computed (option [TT]-sq[tt]). The algorithm uses FFT, the grid", diff -Nru gromacs-4.5.4/src/tools/gmx_rms.c gromacs-4.5.5/src/tools/gmx_rms.c --- gromacs-4.5.4/src/tools/gmx_rms.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_rms.c 2011-09-21 12:34:10.000000000 +0000 @@ -95,19 +95,19 @@ *desc[] = { "[TT]g_rms[tt] compares two structures by computing the root mean square", - "deviation (RMSD), the size-independent 'rho' similarity parameter", - "(rho) or the scaled rho (rhosc), ", - "see Maiorov & Crippen, PROTEINS [BB]22[bb], 273 (1995).", + "deviation (RMSD), the size-independent [GRK]rho[grk] similarity parameter", + "([TT]rho[tt]) or the scaled [GRK]rho[grk] ([TT]rhosc[tt]), ", + "see Maiorov & Crippen, Proteins [BB]22[bb], 273 (1995).", "This is selected by [TT]-what[tt].[PAR]" - "Each structure from a trajectory ([TT]-f[tt]) is compared to a", + "Each structure from a trajectory ([TT]-f[tt]) is compared to a", "reference structure. The reference structure", "is taken from the structure file ([TT]-s[tt]).[PAR]", "With option [TT]-mir[tt] also a comparison with the mirror image of", "the reference structure is calculated.", "This is useful as a reference for 'significant' values, see", - "Maiorov & Crippen, PROTEINS [BB]22[bb], 273 (1995).[PAR]", + "Maiorov & Crippen, Proteins [BB]22[bb], 273 (1995).[PAR]", "Option [TT]-prev[tt] produces the comparison with a previous frame", "the specified number of frames ago.[PAR]", @@ -124,9 +124,9 @@ "Option [TT]-mw[tt] controls whether mass weighting is done or not.", "If you select the option (default) and ", "supply a valid [TT].tpr[tt] file masses will be taken from there, ", - "otherwise the masses will be deduced from the atommass.dat file in", - "the GROMACS library directory. This is fine for proteins but not", - "necessarily for other molecules. A default mass of 12.011 amu (Carbon)", + "otherwise the masses will be deduced from the [TT]atommass.dat[tt] file in", + "[TT]GMXLIB[tt]. This is fine for proteins, but not", + "necessarily for other molecules. A default mass of 12.011 amu (carbon)", "is assigned to unknown atoms. You can check whether this happend by", "turning on the [TT]-debug[tt] flag and inspecting the log file.[PAR]", diff -Nru gromacs-4.5.4/src/tools/gmx_rmsdist.c gromacs-4.5.5/src/tools/gmx_rmsdist.c --- gromacs-4.5.4/src/tools/gmx_rmsdist.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_rmsdist.c 2011-09-21 12:34:32.000000000 +0000 @@ -513,7 +513,7 @@ "which has the advantage that no fit is needed like in standard RMS", "deviation as computed by [TT]g_rms[tt].", "The reference structure is taken from the structure file.", - "The rmsd at time t is calculated as the rms", + "The RMSD at time t is calculated as the RMS", "of the differences in distance between atom-pairs in the reference", "structure and the structure at time t.[PAR]", "[TT]g_rmsdist[tt] can also produce matrices of the rms distances, rms distances", @@ -668,9 +668,11 @@ fprintf(stderr, "\n"); ffclose(fp); - close_trj(status); teller = nframes_read(status); + + close_trj(status); + calc_rms(isize,teller,dtot,dtot2,mean,&meanmax,rms,&rmsmax,rmsc,&rmscmax); fprintf(stderr,"rmsmax = %g, rmscmax = %g\n",rmsmax,rmscmax); diff -Nru gromacs-4.5.4/src/tools/gmx_rotacf.c gromacs-4.5.5/src/tools/gmx_rotacf.c --- gromacs-4.5.4/src/tools/gmx_rotacf.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_rotacf.c 2011-09-21 12:34:10.000000000 +0000 @@ -58,14 +58,14 @@ { const char *desc[] = { "[TT]g_rotacf[tt] calculates the rotational correlation function", - "for molecules. Three atoms (i,j,k) must be given in the index", + "for molecules. Atom triplets (i,j,k) must be given in the index", "file, defining two vectors ij and jk. The rotational ACF", "is calculated as the autocorrelation function of the vector", "n = ij x jk, i.e. the cross product of the two vectors.", "Since three atoms span a plane, the order of the three atoms", - "does not matter. Optionally, controlled by the [TT]-d[tt] switch, you can", + "does not matter. Optionally, by invoking the [TT]-d[tt] switch, you can", "calculate the rotational correlation function for linear molecules", - "by specifying two atoms (i,j) in the index file.", + "by specifying atom pairs (i,j) in the index file.", "[PAR]", "EXAMPLES[PAR]", "[TT]g_rotacf -P 1 -nparm 2 -fft -n index -o rotacf-x-P1", diff -Nru gromacs-4.5.4/src/tools/gmx_rotmat.c gromacs-4.5.5/src/tools/gmx_rotmat.c --- gromacs-4.5.4/src/tools/gmx_rotmat.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_rotmat.c 2011-09-21 12:34:10.000000000 +0000 @@ -193,17 +193,17 @@ "determining the orientation of a molecule", "at an interface, possibly on a trajectory produced with", "[TT]trjconv -fit rotxy+transxy[tt] to remove the rotation", - "in the xy-plane.", + "in the [IT]x-y[it] plane.", "[PAR]", "Option [TT]-ref[tt] determines a reference structure for fitting,", "instead of using the structure from [TT]-s[tt]. The structure with", "the lowest sum of RMSD's to all other structures is used.", "Since the computational cost of this procedure grows with", "the square of the number of frames, the [TT]-skip[tt] option", - "can be useful. A full fit or only a fit in the x/y plane can", + "can be useful. A full fit or only a fit in the [IT]x-y[it] plane can", "be performed.", "[PAR]", - "Option [TT]-fitxy[tt] fits in the x/y plane before determining", + "Option [TT]-fitxy[tt] fits in the [IT]x-y[it] plane before determining", "the rotation matrix." }; const char *reffit[] = diff -Nru gromacs-4.5.4/src/tools/gmx_saltbr.c gromacs-4.5.5/src/tools/gmx_saltbr.c --- gromacs-4.5.4/src/tools/gmx_saltbr.c 2011-03-15 12:44:35.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_saltbr.c 2011-09-21 12:34:10.000000000 +0000 @@ -122,12 +122,12 @@ const char *desc[] = { "[TT]g_saltbr[tt] plots the distance between all combination of charged groups", "as a function of time. The groups are combined in different ways.", - "A minimum distance can be given, (ie. a cut-off), then groups", - "that are never closer than that distance will not be plotted.[BR]", + "A minimum distance can be given (i.e. a cut-off), such that groups", + "that are never closer than that distance will not be plotted.[PAR]", "Output will be in a number of fixed filenames, [TT]min-min.xvg[tt], [TT]plus-min.xvg[tt]", - "and [TT]plus-plus.xvg[tt], or files for every individual ion-pair if the [TT]-sep[tt]", - "option is selected. In this case files are named as [TT]sb-ResnameResnr-Atomnr[tt].", - "There may be many such files." + "and [TT]plus-plus.xvg[tt], or files for every individual ion pair if the [TT]-sep[tt]", + "option is selected. In this case, files are named as [TT]sb-(Resname)(Resnr)-(Atomnr)[tt].", + "There may be [BB]many[bb] such files." }; static gmx_bool bSep=FALSE; static real truncate=1000.0; diff -Nru gromacs-4.5.4/src/tools/gmx_sas.c gromacs-4.5.5/src/tools/gmx_sas.c --- gromacs-4.5.4/src/tools/gmx_sas.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_sas.c 2011-09-21 12:34:10.000000000 +0000 @@ -565,27 +565,31 @@ int gmx_sas(int argc,char *argv[]) { const char *desc[] = { - "[TT]g_sas[tt] computes hydrophobic, hydrophilic and total solvent accessible surface area.", - "As a side effect the Connolly surface can be generated as well in", - "a [TT].pdb[tt] file where the nodes are represented as atoms and the vertices", - "connecting the nearest nodes as CONECT records.", + "[TT]g_sas[tt] computes hydrophobic, hydrophilic and total solvent", + "accessible surface area. See Eisenhaber F, Lijnzaad P, Argos P,", + "Sander C, & Scharf M (1995) J. Comput. Chem. 16, 273-284.", + "As a side effect, the Connolly surface can be generated as well in", + "a [TT].pdb[tt] file where the nodes are represented as atoms and the", + "vertice connecting the nearest nodes as CONECT records.", "The program will ask for a group for the surface calculation", "and a group for the output. The calculation group should always", "consists of all the non-solvent atoms in the system.", "The output group can be the whole or part of the calculation group.", "The average and standard deviation of the area over the trajectory can be plotted", "per residue and atom as well (options [TT]-or[tt] and [TT]-oa[tt]).", - "In combination with the latter option an [TT]itp[tt] file can be", + "In combination with the latter option an [TT].itp[tt] file can be", "generated (option [TT]-i[tt])", "which can be used to restrain surface atoms.[PAR]", + "By default, periodic boundary conditions are taken into account,", "this can be turned off using the [TT]-nopbc[tt] option.[PAR]", - "With the [TT]-tv[tt] option the total volume and density of the molecule can be", - "computed.", + + "With the [TT]-tv[tt] option the total volume and density of the", + "molecule can be computed.", "Please consider whether the normal probe radius is appropriate", "in this case or whether you would rather use e.g. 0. It is good", "to keep in mind that the results for volume and density are very", - "approximate, in e.g. ice Ih one can easily fit water molecules in the", + "approximate. For example, in ice Ih, one can easily fit water molecules in the", "pores which would yield a volume that is too low, and surface area and density", "that are both too high." }; @@ -610,9 +614,9 @@ { "-pbc", FALSE, etBOOL, {&bPBC}, "Take periodicity into account" }, { "-prot", FALSE, etBOOL, {&bSave}, - "Output the protein to the connelly [TT].pdb[tt] file too" }, + "Output the protein to the Connelly [TT].pdb[tt] file too" }, { "-dgs", FALSE, etREAL, {&dgs_default}, - "default value for solvation free energy per area (kJ/mol/nm^2)" } + "Default value for solvation free energy per area (kJ/mol/nm^2)" } }; t_filenm fnm[] = { { efTRX, "-f", NULL, ffREAD }, diff -Nru gromacs-4.5.4/src/tools/gmx_sgangle.c gromacs-4.5.5/src/tools/gmx_sgangle.c --- gromacs-4.5.4/src/tools/gmx_sgangle.c 2011-03-21 08:35:27.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_sgangle.c 2011-09-21 12:34:10.000000000 +0000 @@ -445,7 +445,7 @@ "If [TT]-one[tt] is set, only one group should be specified in the index", "file and the angle between this group at time 0 and t will be computed.", "The angles calculated depend on the order in which the atoms are ", - "given. Giving for instance 5 6 will rotate the vector 5-6 with ", + "given. Giving, for instance, 5 6 will rotate the vector 5-6 with ", "180 degrees compared to giving 6 5. [PAR]If three atoms are given, ", "the normal on the plane spanned by those three atoms will be", "calculated, using the formula P1P2 x P1P3.", @@ -470,7 +470,7 @@ { "-one", FALSE, etBOOL, {&bOne}, "Only one group compute angle between vector at time zero and time t"}, { "-z", FALSE, etBOOL, {&bZ}, - "Use the Z-axis as reference" } + "Use the [IT]z[it]-axis as reference" } }; #define NPA asize(pa) diff -Nru gromacs-4.5.4/src/tools/gmx_sham.c gromacs-4.5.5/src/tools/gmx_sham.c --- gromacs-4.5.4/src/tools/gmx_sham.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_sham.c 2011-09-21 12:34:32.000000000 +0000 @@ -686,10 +686,10 @@ "make enthalpy (option [TT]-lsh[tt]) and entropy (option [TT]-lss[tt])", "plots. The histograms can be made for any quantities the user supplies.", "A line in the input file may start with a time", - "(see option [TT]-time[tt]) and any number of y values may follow.", + "(see option [TT]-time[tt]) and any number of [IT]y[it]-values may follow.", "Multiple sets can also be", "read when they are separated by & (option [TT]-n[tt]),", - "in this case only one y value is read from each line.", + "in this case only one [IT]y[it]-value is read from each line.", "All lines starting with # and @ are skipped.", "[PAR]", "Option [TT]-ge[tt] can be used to supply a file with free energies", @@ -699,7 +699,7 @@ "[PAR]", "Option [TT]-ene[tt] can be used to supply a file with energies.", "These energies are used as a weighting function in the single", - "histogram analysis method by Kumar et. al. When temperatures", + "histogram analysis method by Kumar et al. When temperatures", "are supplied (as a second column in the file), an experimental", "weighting scheme is applied. In addition the vales", "are used for making enthalpy and entropy plots.", @@ -709,7 +709,7 @@ "sampled by two particles increases with increasing distance.", "Depending on what one would like to show, one can choose to correct", "the histogram and free-energy for this volume effect.", - "The probability is normalized by r and r^2 for a dimension of 2 and 3", + "The probability is normalized by r and r^2 for dimensions of 2 and 3, ", "respectively.", "A value of -1 is used to indicate an angle in degrees between two", "vectors: a sin(angle) normalization will be applied.", @@ -792,7 +792,7 @@ { efXPM, "-lss", "entropy", ffOPTWR }, { efXPM, "-map", "map", ffOPTWR }, { efPDB, "-ls3", "gibbs3", ffOPTWR }, - { efXVG, "-mdata","mapdata", ffOPTWR }, + { efXVG, "-mdata","mapdata", ffOPTRD }, { efLOG, "-g", "shamlog", ffOPTWR } }; #define NFILE asize(fnm) diff -Nru gromacs-4.5.4/src/tools/gmx_sorient.c gromacs-4.5.5/src/tools/gmx_sorient.c --- gromacs-4.5.4/src/tools/gmx_sorient.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_sorient.c 2011-09-21 12:34:10.000000000 +0000 @@ -127,23 +127,23 @@ const char *desc[] = { "[TT]g_sorient[tt] analyzes solvent orientation around solutes.", "It calculates two angles between the vector from one or more", - "reference positions to the first atom of each solvent molecule:[BR]", - "theta1: the angle with the vector from the first atom of the solvent", + "reference positions to the first atom of each solvent molecule:[PAR]", + "[GRK]theta[grk]1: the angle with the vector from the first atom of the solvent", "molecule to the midpoint between atoms 2 and 3.[BR]", - "theta2: the angle with the normal of the solvent plane, defined by the", - "same three atoms, or when the option [TT]-v23[tt] is set", - "the angle with the vector between atoms 2 and 3.[BR]", + "[GRK]theta[grk]2: the angle with the normal of the solvent plane, defined by the", + "same three atoms, or, when the option [TT]-v23[tt] is set, ", + "the angle with the vector between atoms 2 and 3.[PAR]", "The reference can be a set of atoms or", "the center of mass of a set of atoms. The group of solvent atoms should", "consist of 3 atoms per solvent molecule.", "Only solvent molecules between [TT]-rmin[tt] and [TT]-rmax[tt] are", "considered for [TT]-o[tt] and [TT]-no[tt] each frame.[PAR]", - "[TT]-o[tt]: distribtion of cos(theta1) for rmin<=r<=rmax.[PAR]", - "[TT]-no[tt]: distribution of cos(theta2) for rmin<=r<=rmax.[PAR]", - "[TT]-ro[tt]: and <3cos^2(theta2)-1> as a function of the", + "[TT]-o[tt]: distribtion of cos([GRK]theta[grk]1) for rmin<=r<=rmax.[PAR]", + "[TT]-no[tt]: distribution of cos([GRK]theta[grk]2) for rmin<=r<=rmax.[PAR]", + "[TT]-ro[tt]: and <3cos^2([GRK]theta[grk]2)-1> as a function of the", "distance.[PAR]", "[TT]-co[tt]: the sum over all solvent molecules within distance r", - "of cos(theta1) and 3cos^2(theta2)-1 as a function of r.[PAR]", + "of cos([GRK]theta[grk]1) and 3cos^2([GRK]theta[grk]2)-1 as a function of r.[PAR]", "[TT]-rc[tt]: the distribution of the solvent molecules as a function of r" }; diff -Nru gromacs-4.5.4/src/tools/gmx_spatial.c gromacs-4.5.5/src/tools/gmx_spatial.c --- gromacs-4.5.4/src/tools/gmx_spatial.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_spatial.c 2011-09-21 12:34:10.000000000 +0000 @@ -65,41 +65,41 @@ "[TT]g_spatial[tt] calculates the spatial distribution function and ", "outputs it in a form that can be read by VMD as Gaussian98 cube format. ", "This was developed from template.c (GROMACS-3.3). ", - "For a system of 32K atoms and a 50ns trajectory, the SDF can be generated ", + "For a system of 32,000 atoms and a 50 ns trajectory, the SDF can be generated ", "in about 30 minutes, with most of the time dedicated to the two runs through ", "[TT]trjconv[tt] that are required to center everything properly. ", "This also takes a whole bunch of space (3 copies of the [TT].xtc[tt] file). ", "Still, the pictures are pretty and very informative when the fitted selection is properly made. ", - "3-4 atoms in a widely mobile group like a free amino acid in solution works ", + "3-4 atoms in a widely mobile group (like a free amino acid in solution) works ", "well, or select the protein backbone in a stable folded structure to get the SDF ", "of solvent and look at the time-averaged solvation shell. ", - "It is also possible using this program to generate the SDF based on some arbitrarty ", + "It is also possible using this program to generate the SDF based on some arbitrary ", "Cartesian coordinate. To do that, simply omit the preliminary [TT]trjconv[tt] steps. \n", "USAGE: \n", "1. Use [TT]make_ndx[tt] to create a group containing the atoms around which you want the SDF \n", "2. [TT]trjconv -s a.tpr -f a.xtc -o b.xtc -center tric -ur compact -pbc none[tt] \n", "3. [TT]trjconv -s a.tpr -f b.xtc -o c.xtc -fit rot+trans[tt] \n", "4. run [TT]g_spatial[tt] on the [TT].xtc[tt] output of step #3. \n", - "5. Load grid.cube into VMD and view as an isosurface. \n", - "*** Systems such as micelles will require [TT]trjconv -pbc cluster[tt] between steps 1 and 2\n", - "WARNINGS: \n", + "5. Load [TT]grid.cube[tt] into VMD and view as an isosurface. \n", + "[BB]Note[bb] that systems such as micelles will require [TT]trjconv -pbc cluster[tt] between steps 1 and 2\n", + "WARNINGS:[BR]", "The SDF will be generated for a cube that contains all bins that have some non-zero occupancy. ", "However, the preparatory [TT]-fit rot+trans[tt] option to [TT]trjconv[tt] implies that your system will be rotating ", "and translating in space (in order that the selected group does not). Therefore the values that are ", "returned will only be valid for some region around your central group/coordinate that has full overlap ", "with system volume throughout the entire translated/rotated system over the course of the trajectory. ", "It is up to the user to ensure that this is the case. \n", - "BUGS: \n", + "BUGS:[BR]", "When the allocated memory is not large enough, a segmentation fault may occur. This is usually detected ", - "and the program is halted prior to the fault while displaying a warning message suggesting the use of the [TT]-nab[tt] ", + "and the program is halted prior to the fault while displaying a warning message suggesting the use of the [TT]-nab[tt] (Number of Additional Bins)", "option. However, the program does not detect all such events. If you encounter a segmentation fault, run it again ", "with an increased [TT]-nab[tt] value. \n", - "RISKY OPTIONS: \n", + "RISKY OPTIONS:[BR]", "To reduce the amount of space and time required, you can output only the coords ", "that are going to be used in the first and subsequent run through [TT]trjconv[tt]. ", "However, be sure to set the [TT]-nab[tt] option to a sufficiently high value since ", - "memory is allocated for cube bins based on the initial coords and the [TT]-nab[tt] ", - "(Number of Additional Bins) option value. \n" + "memory is allocated for cube bins based on the initial coordinates and the [TT]-nab[tt] ", + "option value. \n" }; static gmx_bool bPBC=FALSE; diff -Nru gromacs-4.5.4/src/tools/gmx_spol.c gromacs-4.5.5/src/tools/gmx_spol.c --- gromacs-4.5.4/src/tools/gmx_spol.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_spol.c 2011-09-21 12:34:10.000000000 +0000 @@ -156,7 +156,7 @@ "the inner product of the distance vector", "and the dipole of the solvent molecule is determined.", "For solvent molecules with net charge (ions), the net charge of the ion", - "is subtracted evenly at all atoms in the selection of each ion.", + "is subtracted evenly from all atoms in the selection of each ion.", "The average of these dipole components is printed.", "The same is done for the polarization, where the average dipole is", "subtracted from the instantaneous dipole. The magnitude of the average", diff -Nru gromacs-4.5.4/src/tools/gmx_tcaf.c gromacs-4.5.5/src/tools/gmx_tcaf.c --- gromacs-4.5.4/src/tools/gmx_tcaf.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_tcaf.c 2011-09-21 12:34:10.000000000 +0000 @@ -218,34 +218,34 @@ { const char *desc[] = { "[TT]g_tcaf[tt] computes tranverse current autocorrelations.", - "These are used to estimate the shear viscosity eta.", - "For details see: Palmer, JCP 49 (1994) pp 359-366.[PAR]", + "These are used to estimate the shear viscosity, [GRK]eta[grk].", + "For details see: Palmer, Phys. Rev. E 49 (1994) pp 359-366.[PAR]", "Transverse currents are calculated using the", - "k-vectors (1,0,0) and (2,0,0) each also in the y- and z-direction,", + "k-vectors (1,0,0) and (2,0,0) each also in the [IT]y[it]- and [IT]z[it]-direction,", "(1,1,0) and (1,-1,0) each also in the 2 other planes (these vectors", "are not independent) and (1,1,1) and the 3 other box diagonals (also", "not independent). For each k-vector the sine and cosine are used, in", "combination with the velocity in 2 perpendicular directions. This gives", "a total of 16*2*2=64 transverse currents. One autocorrelation is", - "calculated fitted for each k-vector, which gives 16 tcaf's. Each of", - "these tcaf's is fitted to f(t) = exp(-v)(cosh(Wv) + 1/W sinh(Wv)),", - "v = -t/(2 tau), W = sqrt(1 - 4 tau eta/rho k^2), which gives 16 tau's", - "and eta's. The fit weights decay with time as exp(-t/wt), the tcaf and", + "calculated fitted for each k-vector, which gives 16 TCAF's. Each of", + "these TCAF's is fitted to f(t) = exp(-v)(cosh(Wv) + 1/W sinh(Wv)),", + "v = -t/(2 [GRK]tau[grk]), W = sqrt(1 - 4 [GRK]tau[grk] [GRK]eta[grk]/[GRK]rho[grk] k^2), which gives 16 values of [GRK]tau[grk]", + "and [GRK]eta[grk]. The fit weights decay with time as exp(-t/wt), and the TCAF and", "fit are calculated up to time 5*wt.", - "The eta's should be fitted to 1 - a eta(k) k^2, from which", + "The [GRK]eta[grk] values should be fitted to 1 - a [GRK]eta[grk](k) k^2, from which", "one can estimate the shear viscosity at k=0.[PAR]", "When the box is cubic, one can use the option [TT]-oc[tt], which", - "averages the tcaf's over all k-vectors with the same length.", + "averages the TCAF's over all k-vectors with the same length.", "This results in more accurate tcaf's.", - "Both the cubic tcaf's and fits are written to [TT]-oc[tt]", - "The cubic eta estimates are also written to [TT]-ov[tt].[PAR]", - "With option [TT]-mol[tt] the transverse current is determined of", - "molecules instead of atoms. In this case the index group should", + "Both the cubic TCAF's and fits are written to [TT]-oc[tt]", + "The cubic [GRK]eta[grk] estimates are also written to [TT]-ov[tt].[PAR]", + "With option [TT]-mol[tt], the transverse current is determined of", + "molecules instead of atoms. In this case, the index group should", "consist of molecule numbers instead of atom numbers.[PAR]", "The k-dependent viscosities in the [TT]-ov[tt] file should be", - "fitted to eta(k) = eta0 (1 - a k^2) to obtain the viscosity at", + "fitted to [GRK]eta[grk](k) = [GRK]eta[grk]0 (1 - a k^2) to obtain the viscosity at", "infinite wavelength.[PAR]", - "NOTE: make sure you write coordinates and velocities often enough.", + "[BB]Note:[bb] make sure you write coordinates and velocities often enough.", "The initial, non-exponential, part of the autocorrelation function", "is very important for obtaining a good fit." }; diff -Nru gromacs-4.5.4/src/tools/gmx_trjcat.c gromacs-4.5.5/src/tools/gmx_trjcat.c --- gromacs-4.5.4/src/tools/gmx_trjcat.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_trjcat.c 2011-09-21 12:34:10.000000000 +0000 @@ -438,7 +438,7 @@ { "-dt", FALSE, etTIME, { &dt }, "Only write frame when t MOD dt = first time (%t)" }, { "-prec", FALSE, etINT, - { &prec }, "Precision for .xtc and .gro writing in number of decimal places" }, + { &prec }, "Precision for [TT].xtc[tt] and [TT].gro[tt] writing in number of decimal places" }, { "-vel", FALSE, etBOOL, { &bVels }, "Read and write velocities if possible" }, { "-settime", FALSE, etBOOL, @@ -446,11 +446,11 @@ { "-sort", FALSE, etBOOL, { &bSort }, "Sort trajectory files (not frames)" }, { "-keeplast", FALSE, etBOOL, - { &bKeepLast }, "keep overlapping frames at end of trajectory" }, + { &bKeepLast }, "Keep overlapping frames at end of trajectory" }, { "-overwrite", FALSE, etBOOL, - { &bOverwrite }, "overwrite overlapping frames during appending" }, + { &bOverwrite }, "Overwrite overlapping frames during appending" }, { "-cat", FALSE, etBOOL, - { &bCat }, "do not discard double time frames" } }; + { &bCat }, "Do not discard double time frames" } }; #define npargs asize(pa) int ftpin, i, frame, frame_out, step = 0, trjout = 0; t_trxstatus *status; diff -Nru gromacs-4.5.4/src/tools/gmx_trjconv.c gromacs-4.5.5/src/tools/gmx_trjconv.c --- gromacs-4.5.4/src/tools/gmx_trjconv.c 2011-03-14 13:33:32.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_trjconv.c 2011-09-21 12:34:32.000000000 +0000 @@ -526,8 +526,10 @@ "dumps each group in the index file to a separate trajectory file.[BR]", "[BB]10.[bb] select frames within a certain range of a quantity given", "in an [TT].xvg[tt] file.[PAR]", + "The program [TT]trjcat[tt] is better suited for concatenating multiple trajectory files.", "[PAR]", + "Currently seven formats are supported for input and output:", "[TT].xtc[tt], [TT].trr[tt], [TT].trj[tt], [TT].gro[tt], [TT].g96[tt],", "[TT].pdb[tt] and [TT].g87[tt].", @@ -541,20 +543,24 @@ "of the [TT]trjconv[tt] binary.", "Note that velocities are only supported in", "[TT].trr[tt], [TT].trj[tt], [TT].gro[tt] and [TT].g96[tt] files.[PAR]", + "Option [TT]-app[tt] can be used to", "append output to an existing trajectory file.", "No checks are performed to ensure integrity", "of the resulting combined trajectory file.[PAR]", + "Option [TT]-sep[tt] can be used to write every frame to a separate", "[TT].gro, .g96[tt] or [TT].pdb[tt] file. By default, all frames all written to one file.", "[TT].pdb[tt] files with all frames concatenated can be viewed with", "[TT]rasmol -nmrpdb[tt].[PAR]", + "It is possible to select part of your trajectory and write it out", "to a new trajectory file in order to save disk space, e.g. for leaving", "out the water from a trajectory of a protein in water.", "[BB]ALWAYS[bb] put the original trajectory on tape!", "We recommend to use the portable [TT].xtc[tt] format for your analysis", "to save disk space and to have portable files.[PAR]", + "There are two options for fitting the trajectory to a reference", "either for essential dynamics analysis, etc.", "The first option is just plain fitting to a reference structure", @@ -565,9 +571,11 @@ "trajectory is generated, which might not be the case when using the", "regular fit method, e.g. when your protein undergoes large", "conformational transitions.[PAR]", + "Option [TT]-pbc[tt] sets the type of periodic boundary condition", "treatment:[BR]", - "[TT]* mol[tt] puts the center of mass of molecules in the box.[BR]", + "[TT]* mol[tt] puts the center of mass of molecules in the box,", + "and requires a run input file to be supplied with [TT]-s[tt].[BR]", "[TT]* res[tt] puts the center of mass of residues in the box.[BR]", "[TT]* atom[tt] puts all the atoms in the box.[BR]", "[TT]* nojump[tt] checks if atoms jump across the box and then puts", @@ -587,6 +595,7 @@ "approximate center for the cluster. This is useful e.g. if you have", "two big vesicles, and you want to maintain their relative positions.[BR]", "[TT]* whole[tt] only makes broken molecules whole.[PAR]", + "Option [TT]-ur[tt] sets the unit cell representation for options", "[TT]mol[tt], [TT]res[tt] and [TT]atom[tt] of [TT]-pbc[tt].", "All three options give different results for triclinic boxes and", @@ -598,6 +607,7 @@ "octahedra. The center for options [TT]tric[tt] and [TT]compact[tt]", "is [TT]tric[tt] (see below), unless the option [TT]-boxcenter[tt]", "is set differently.[PAR]", + "Option [TT]-center[tt] centers the system in the box. The user can", "select the group which is used to determine the geometrical center.", "Option [TT]-boxcenter[tt] sets the location of the center of the box", @@ -607,6 +617,12 @@ "[TT]zero[tt]: zero.", "Use option [TT]-pbc mol[tt] in addition to [TT]-center[tt] when you", "want all molecules in the box after the centering.[PAR]", + + "It is not always possible to use combinations of [TT]-pbc[tt],", + "[TT]-fit[tt], [TT]-ur[tt] and [TT]-center[tt] to do exactly what", + "you want in one call to [TT]trjconv[tt]. Consider using multiple", + "calls, and check out the GROMACS website for suggestions.[PAR]", + "With [TT]-dt[tt], it is possible to reduce the number of ", "frames in the output. This option relies on the accuracy of the times", "in your input trajectory, so if these are inaccurate use the", @@ -614,12 +630,15 @@ "simultaneously). For making smooth movies, the program [TT]g_filter[tt]", "can reduce the number of frames while using low-pass frequency", "filtering, this reduces aliasing of high frequency motions.[PAR]", + "Using [TT]-trunc[tt] [TT]trjconv[tt] can truncate [TT].trj[tt] in place, i.e.", "without copying the file. This is useful when a run has crashed", "during disk I/O (i.e. full disk), or when two contiguous", "trajectories must be concatenated without having double frames.[PAR]", + "Option [TT]-dump[tt] can be used to extract a frame at or near", "one specific time from your trajectory.[PAR]", + "Option [TT]-drop[tt] reads an [TT].xvg[tt] file with times and values.", "When options [TT]-dropunder[tt] and/or [TT]-dropover[tt] are set,", "frames with a value below and above the value of the respective options", @@ -938,6 +957,11 @@ " trajectories.\ntry splitting the index file in %d parts.\n" "FOPEN_MAX = %d", clust->clust->nr,1+clust->clust->nr/FOPEN_MAX,FOPEN_MAX); + gmx_warning("The -sub option could require as many open output files as there are\n" + "index groups in the file (%d). If you get I/O errors opening new files,\n" + "try reducing the number of index groups in the file, and perhaps\n" + "using trjconv -sub several times on different chunks of your index file.\n", + clust->clust->nr); snew(clust_status,clust->clust->nr); snew(clust_status_id,clust->clust->nr); @@ -1139,7 +1163,10 @@ /* check if index is meaningful */ for(i=0; i= natoms) - gmx_fatal(FARGS,"Index[%d] %d is larger than the number of atoms in the trajectory file (%d)",i,index[i]+1,natoms); + gmx_fatal(FARGS, + "Index[%d] %d is larger than the number of atoms in the\n" + "trajectory file (%d). There is a mismatch in the contents\n" + "of your -f, -s and/or -n files.",i,index[i]+1,natoms); bCopy = bCopy || (i != index[i]); } if (bCopy) { @@ -1361,6 +1388,8 @@ } /* Copy the input trxframe struct to the output trxframe struct */ frout = fr; + frout.bV &= bVels; + frout.bF &= bForce; frout.natoms = nout; if (bNeedPrec && (bSetPrec || !fr.bPrec)) { frout.bPrec = TRUE; @@ -1368,18 +1397,18 @@ } if (bCopy) { frout.x = xmem; - if (bVels) { + if (frout.bV) { frout.v = vmem; } - if (bForce) { + if (frout.bF) { frout.f = fmem; } for(i=0; iclust->index[my_clust+1]- clust->clust->index[my_clust])) { close_trx(clust_status[my_clust]); + clust_status[my_clust] = NULL; clust_status_id[my_clust] = -2; ntrxopen--; if (ntrxopen < 0) @@ -1451,7 +1481,7 @@ switch(ftp) { case efGRO: write_hconf_p(out,title,&useatoms,prec2ndec(frout.prec), - frout.x,fr.bV?frout.v:NULL,frout.box); + frout.x,frout.bV?frout.v:NULL,frout.box); break; case efPDB: fprintf(out,"REMARK GENERATED BY TRJCONV\n"); diff -Nru gromacs-4.5.4/src/tools/gmx_trjorder.c gromacs-4.5.5/src/tools/gmx_trjorder.c --- gromacs-4.5.4/src/tools/gmx_trjorder.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_trjorder.c 2011-09-21 12:34:10.000000000 +0000 @@ -99,7 +99,7 @@ "with any Gromacs program to analyze the n closest waters.", "[PAR]", "If the output file is a [TT].pdb[tt] file, the distance to the reference target", - "will be stored in the B-factor field in order to color with e.g. rasmol.", + "will be stored in the B-factor field in order to color with e.g. Rasmol.", "[PAR]", "With option [TT]-nshell[tt] the number of molecules within a shell", "of radius [TT]-r[tt] around the reference group are printed." diff -Nru gromacs-4.5.4/src/tools/gmx_tune_pme.c gromacs-4.5.5/src/tools/gmx_tune_pme.c --- gromacs-4.5.4/src/tools/gmx_tune_pme.c 2011-03-15 12:44:35.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_tune_pme.c 2011-09-21 12:34:32.000000000 +0000 @@ -1845,10 +1845,19 @@ /* Skip options not meant for mdrun */ if (!is_main_switch(opt)) { - /* Print it to a string buffer, strip away trailing whitespaces that pa_val also returns: */ - sprintf(strbuf2, "%s", pa_val(&pa[i],buf,BUFLENGTH)); - rtrim(strbuf2); - sprintf(strbuf, "%s %s ", opt, strbuf2); + /* Boolean arguments need to be generated in the -[no]argname format */ + if (pa[i].type == etBOOL) + { + sprintf(strbuf,"-%s%s ",*pa[i].u.b ? "" : "no",opt+1); + } + else + { + /* Print it to a string buffer, strip away trailing whitespaces that pa_val also returns: */ + sprintf(strbuf2, "%s", pa_val(&pa[i],buf,BUFLENGTH)); + rtrim(strbuf2); + sprintf(strbuf, "%s %s ", opt, strbuf2); + } + /* We need the -np (or -nt) switch in a separate buffer - whether or not it was set! */ if (0 == strcmp(opt,np_or_nt)) { @@ -1997,7 +2006,7 @@ "MPIRUN and MDRUN. If these are not present, 'mpirun' and 'mdrun'", "will be used as defaults. Note that for certain MPI frameworks you", "need to provide a machine- or hostfile. This can also be passed", - "via the MPIRUN variable, e.g.", + "via the MPIRUN variable, e.g.[PAR]", "[TT]export MPIRUN=\"/usr/local/mpirun -machinefile hosts\"[tt][PAR]", "Please call [TT]g_tune_pme[tt] with the normal options you would pass to", "[TT]mdrun[tt] and add [TT]-np[tt] for the number of processors to perform the", @@ -2006,11 +2015,11 @@ "[TT]g_tune_pme[tt] can test various real space / reciprocal space workloads", "for you. With [TT]-ntpr[tt] you control how many extra [TT].tpr[tt] files will be", "written with enlarged cutoffs and smaller fourier grids respectively.", - "Typically, the first test (No. 0) will be with the settings from the input", - "[TT].tpr[tt] file; the last test (No. [TT]ntpr[tt]) will have cutoffs multiplied", + "Typically, the first test (number 0) will be with the settings from the input", + "[TT].tpr[tt] file; the last test (number [TT]ntpr[tt]) will have cutoffs multiplied", "by (and at the same time fourier grid dimensions divided by) the scaling", - "factor [TT]-fac[tt] (default 1.2). The remaining [TT].tpr[tt] files will have about equally", - "spaced values inbetween these extremes. Note that you can set [TT]-ntpr[tt] to 1", + "factor [TT]-fac[tt] (default 1.2). The remaining [TT].tpr[tt] files will have about ", + "equally-spaced values in between these extremes. [BB]Note[bb] that you can set [TT]-ntpr[tt] to 1", "if you just want to find the optimal number of PME-only nodes; in that case", "your input [TT].tpr[tt] file will remain unchanged.[PAR]", "For the benchmark runs, the default of 1000 time steps should suffice for most", @@ -2019,11 +2028,11 @@ "are by default reset after 100 steps. For large systems", "(>1M atoms) you may have to set [TT]-resetstep[tt] to a higher value.", "From the 'DD' load imbalance entries in the md.log output file you", - "can tell after how many steps the load is sufficiently balanced.[PAR]" - "Example call: [TT]g_tune_pme -np 64 -s protein.tpr -launch[tt][PAR]", + "can tell after how many steps the load is sufficiently balanced. Example call:[PAR]" + "[TT]g_tune_pme -np 64 -s protein.tpr -launch[tt][PAR]", "After calling [TT]mdrun[tt] several times, detailed performance information", - "is available in the output file perf.out. ", - "Note that during the benchmarks a couple of temporary files are written", + "is available in the output file [TT]perf.out.[tt] ", + "[BB]Note[bb] that during the benchmarks, a couple of temporary files are written", "(options [TT]-b[tt]*), these will be automatically deleted after each test.[PAR]", "If you want the simulation to be started automatically with the", "optimized parameters, use the command line option [TT]-launch[tt].[PAR]", @@ -2166,9 +2175,9 @@ { "-np", FALSE, etINT, {&nnodes}, "Number of nodes to run the tests on (must be > 2 for separate PME nodes)" }, { "-npstring", FALSE, etENUM, {procstring}, - "Specify the number of processors to $MPIRUN using this string"}, + "Specify the number of processors to [TT]$MPIRUN[tt] using this string"}, { "-passall", FALSE, etBOOL, {&bPassAll}, - "HIDDENPut arguments unknown to [TT]mdrun[tt] at the end of the command line. Can e.g. be used for debugging purposes. "}, + "HIDDENPut arguments unknown to [TT]mdrun[tt] at the end of the command line. Can be used for debugging purposes. "}, { "-nt", FALSE, etINT, {&nthreads}, "Number of threads to run the tests on (turns MPI & mpirun off)"}, { "-r", FALSE, etINT, {&repeats}, @@ -2186,17 +2195,17 @@ { "-downfac", FALSE, etREAL, {&downfac}, "Lower limit for rcoulomb scaling factor" }, { "-ntpr", FALSE, etINT, {&ntprs}, - "Number of [TT].tpr[tt] files to benchmark. Create these many files with scaling factors ranging from 1.0 to fac. If < 1, automatically choose the number of [TT].tpr[tt] files to test" }, + "Number of [TT].tpr[tt] files to benchmark. Create this many files with scaling factors ranging from 1.0 to fac. If < 1, automatically choose the number of [TT].tpr[tt] files to test" }, { "-four", FALSE, etREAL, {&fs}, "Use this fourierspacing value instead of the grid found in the [TT].tpr[tt] input file. (Spacing applies to a scaling factor of 1.0 if multiple [TT].tpr[tt] files are written)" }, { "-steps", FALSE, etGMX_LARGE_INT, {&bench_nsteps}, - "Take timings for these many steps in the benchmark runs" }, + "Take timings for this many steps in the benchmark runs" }, { "-resetstep",FALSE, etINT, {&presteps}, - "Let dlb equilibrate these many steps before timings are taken (reset cycle counters after these many steps)" }, + "Let dlb equilibrate this many steps before timings are taken (reset cycle counters after this many steps)" }, { "-simsteps", FALSE, etGMX_LARGE_INT, {&new_sim_nsteps}, - "If non-negative, perform these many steps in the real run (overwrite nsteps from [TT].tpr[tt], add [TT].cpt[tt] steps)" }, + "If non-negative, perform this many steps in the real run (overwrites nsteps from [TT].tpr[tt], add [TT].cpt[tt] steps)" }, { "-launch", FALSE, etBOOL, {&bLaunch}, - "Lauch the real simulation after optimization" }, + "Launch the real simulation after optimization" }, /******************/ /* mdrun options: */ /******************/ @@ -2251,7 +2260,7 @@ { "-rerunvsite", FALSE, etBOOL, {&bRerunVSite}, "HIDDENRecalculate virtual site coordinates with [TT]-rerun[tt]" }, { "-ionize", FALSE, etBOOL, {&bIonize}, - "Do a simulation including the effect of an X-Ray bombardment on your system" }, + "Do a simulation including the effect of an X-ray bombardment on your system" }, { "-confout", FALSE, etBOOL, {&bConfout}, "HIDDENWrite the last configuration with [TT]-c[tt] and force checkpointing at the last step" }, { "-stepout", FALSE, etINT, {&nstepout}, @@ -2336,8 +2345,9 @@ fs, bench_nsteps, fnm, NFILE, sim_part, presteps, asize(pa),pa); - /* Determine max and min number of PME nodes to test: */ - if ((nnodes > 2) && (npme_fixed >= -1)) + /* Determine the maximum and minimum number of PME nodes to test, + * the actual list of settings is build in do_the_tests(). */ + if ((nnodes > 2) && (npme_fixed < -1)) { maxPMEnodes = floor(maxPMEfraction*nnodes); minPMEnodes = max(floor(minPMEfraction*nnodes), 0); diff -Nru gromacs-4.5.4/src/tools/gmx_wham.c gromacs-4.5.5/src/tools/gmx_wham.c --- gromacs-4.5.4/src/tools/gmx_wham.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_wham.c 2011-09-21 12:34:32.000000000 +0000 @@ -1776,6 +1776,7 @@ nColRefEachGrp=0; nColRefOnce=0; } + nColExpect = 1 + nColRefOnce + header->npullgrps*(nColRefEachGrp+nColPerGrp); bHaveForce = opt->bPullf; @@ -1801,7 +1802,8 @@ } if (ny != nColExpect) { - gmx_fatal(FARGS,"Found %d pull groups in %s,\n but %d data columns in %s (expected %d)\n", + gmx_fatal(FARGS,"Found %d pull groups in %s,\n but %d data columns in %s (expected %d)\n" + "\nMaybe you confused options -ix and -if ?\n", header->npullgrps,fntpr,ny-1,fn,nColExpect-1); } @@ -1914,13 +1916,19 @@ pos=dist_ndim(y + 1 + nColRefOnce + g*nColPerGrp,header->pull_ndim,i); break; case epullgPOS: + /* Columns + Time ref[ndim] group1[ndim] group2[ndim] ... */ case epullgCYL: - /* with geometry==position, we have the reference once (nColRefOnce==ndim), but + /* Columns + Time ref1[ndim] group1[ndim] ref2[ndim] group2[ndim] ... */ + + /* * with geometry==position, we have the reference once (nColRefOnce==ndim), but no extra reference group columns before each group (nColRefEachGrp==0) - with geometry==cylinder, we have no initial ref group column (nColRefOnce==0), + + * with geometry==cylinder, we have no initial ref group column (nColRefOnce==0), but ndim ref group colums before every group (nColRefEachGrp==ndim) Distance to reference: */ - pos=y[1 + nColRefOnce + g*(nColRefEachGrp+nColPerGrp)][i]; + pos=y[1 + nColRefOnce + nColRefEachGrp + g*(nColRefEachGrp+nColPerGrp)][i]; break; default: gmx_fatal(FARGS,"Bad error, this error should have been catched before. Ups.\n"); @@ -2549,13 +2557,13 @@ "which may be useful for, e.g. membranes.[PAR]", "AUTOCORRELATIONS[BR]----------------[BR]", "With [TT]-ac[tt], [TT]g_wham[tt] estimates the integrated autocorrelation ", - "time (IACT) tau for each umbrella window and weights the respective ", - "window with 1/[1+2*tau/dt]. The IACTs are written ", + "time (IACT) [GRK]tau[grk] for each umbrella window and weights the respective ", + "window with 1/[1+2*[GRK]tau[grk]/dt]. The IACTs are written ", "to the file defined with [TT]-oiact[tt]. In verbose mode, all ", "autocorrelation functions (ACFs) are written to [TT]hist_autocorr.xvg[tt]. ", "Because the IACTs can be severely underestimated in case of limited ", - "sampling, option [TT]-acsig[tt] allows to smooth the IACTs along the ", - "reaction coordinate with a Gaussian (sigma provided with [TT]-acsig[tt], ", + "sampling, option [TT]-acsig[tt] allows one to smooth the IACTs along the ", + "reaction coordinate with a Gaussian ([GRK]sigma[grk] provided with [TT]-acsig[tt], ", "see output in [TT]iact.xvg[tt]). Note that the IACTs are estimated by simple ", "integration of the ACFs while the ACFs are larger 0.05.", "If you prefer to compute the IACTs by a more sophisticated (but possibly ", @@ -2616,7 +2624,7 @@ { "-max", FALSE, etREAL, {&opt.max}, "Maximum coordinate in profile"}, { "-auto", FALSE, etBOOL, {&opt.bAuto}, - "determine min and max automatically"}, + "Determine min and max automatically"}, { "-bins",FALSE, etINT, {&opt.bins}, "Number of bins in profile"}, { "-temp", FALSE, etREAL, {&opt.Temperature}, @@ -2624,11 +2632,11 @@ { "-tol", FALSE, etREAL, {&opt.Tolerance}, "Tolerance"}, { "-v", FALSE, etBOOL, {&opt.verbose}, - "verbose mode"}, + "Verbose mode"}, { "-b", FALSE, etREAL, {&opt.tmin}, - "first time to analyse (ps)"}, + "First time to analyse (ps)"}, { "-e", FALSE, etREAL, {&opt.tmax}, - "last time to analyse (ps)"}, + "Last time to analyse (ps)"}, { "-dt", FALSE, etREAL, {&opt.dt}, "Analyse only every dt ps"}, { "-histonly", FALSE, etBOOL, {&opt.bHistOnly}, @@ -2638,19 +2646,19 @@ { "-log", FALSE, etBOOL, {&opt.bLog}, "Calculate the log of the profile before printing"}, { "-unit", FALSE, etENUM, {en_unit}, - "energy unit in case of log output" }, + "Energy unit in case of log output" }, { "-zprof0", FALSE, etREAL, {&opt.zProf0}, "Define profile to 0.0 at this position (with [TT]-log[tt])"}, { "-cycl", FALSE, etBOOL, {&opt.bCycl}, "Create cyclic/periodic profile. Assumes min and max are the same point."}, { "-sym", FALSE, etBOOL, {&opt.bSym}, - "symmetrize profile around z=0"}, + "Symmetrize profile around z=0"}, { "-hist-eq", FALSE, etBOOL, {&opt.bHistEq}, "HIDDENEnforce equal weight for all histograms. (Non-Weighed-HAM)"}, { "-ac", FALSE, etBOOL, {&opt.bCalcTauInt}, - "calculate integrated autocorrelation times and use in wham"}, + "Calculate integrated autocorrelation times and use in wham"}, { "-acsig", FALSE, etREAL, {&opt.sigSmoothIact}, - "Smooth autocorrelation times along reaction coordinate with Gaussian of this sigma"}, + "Smooth autocorrelation times along reaction coordinate with Gaussian of this [GRK]sigma[grk]"}, { "-ac-trestart", FALSE, etREAL, {&opt.acTrestart}, "When computing autocorrelation functions, restart computing every .. (ps)"}, { "-acred", FALSE, etBOOL, {&opt.bAllowReduceIact}, @@ -2659,15 +2667,15 @@ { "-nBootstrap", FALSE, etINT, {&opt.nBootStrap}, "nr of bootstraps to estimate statistical uncertainty (e.g., 200)" }, { "-bs-method", FALSE, etENUM, {en_bsMethod}, - "bootstrap method" }, + "Bootstrap method" }, { "-bs-tau", FALSE, etREAL, {&opt.tauBootStrap}, "Autocorrelation time (ACT) assumed for all histograms. Use option [TT]-ac[tt] if ACT is unknown."}, { "-bs-seed", FALSE, etINT, {&opt.bsSeed}, - "seed for bootstrapping. (-1 = use time)"}, + "Seed for bootstrapping. (-1 = use time)"}, { "-histbs-block", FALSE, etINT, {&opt.histBootStrapBlockLength}, - "when mixing histograms only mix within blocks of [TT]-histbs-block[tt]."}, + "When mixing histograms only mix within blocks of [TT]-histbs-block[tt]."}, { "-vbs", FALSE, etBOOL, {&opt.bs_verbose}, - "verbose bootstrapping. Print the CDFs and a histogram file for each bootstrap."}, + "Verbose bootstrapping. Print the CDFs and a histogram file for each bootstrap."}, { "-stepout", FALSE, etINT, {&opt.stepchange}, "HIDDENWrite maximum change every ... (set to 1 with [TT]-v[tt])"}, { "-updateContr", FALSE, etINT, {&opt.stepUpdateContrib}, diff -Nru gromacs-4.5.4/src/tools/gmx_wheel.c gromacs-4.5.5/src/tools/gmx_wheel.c --- gromacs-4.5.4/src/tools/gmx_wheel.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_wheel.c 2011-09-21 12:34:10.000000000 +0000 @@ -205,7 +205,7 @@ const char *desc[] = { "[TT]g_wheel[tt] plots a helical wheel representation of your sequence.", "The input sequence is in the [TT].dat[tt] file where the first line contains", - "the number of residues and each consecutive line contains a residue" + "the number of residues and each consecutive line contains a residue " "name." }; output_env_t oenv; diff -Nru gromacs-4.5.4/src/tools/gmx_xpm2ps.c gromacs-4.5.5/src/tools/gmx_xpm2ps.c --- gromacs-4.5.4/src/tools/gmx_xpm2ps.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/gmx_xpm2ps.c 2011-09-21 12:34:10.000000000 +0000 @@ -941,6 +941,12 @@ printf("Combining two %dx%d matrices\n",mat1[k].nx,mat1[k].ny); rmat1 = matrix2real(&mat1[k], NULL); rmat2 = matrix2real(&mat2[k], NULL); + if (NULL == rmat1 || NULL == rmat2) + { + gmx_fatal(FARGS, "Could not extract real data from %s xpm matrices. Note that, e.g.,\n" + "g_rms and g_mdmat provide such data, but not do_dssp.\n", + (NULL==rmat1 && NULL==rmat2) ? "both" : "one of the" ); + } rlo=1e38; rhi=-1e38; for(j=0; j legendfont; titlefont -> (xfont -> yfont -> ytickfont)", "-> xtickfont, e.g. setting titlefont sets all fonts, setting xfont", "sets yfont, ytickfont and xtickfont.[PAR]", - "When no [TT]m2p[tt] file is supplied, many settings are taken from", + "When no [TT].m2p[tt] file is supplied, many settings are taken from", "command line options. The most important option is [TT]-size[tt],", "which sets the size of the whole matrix in postscript units.", "This option can be overridden with the [TT]-bx[tt] and [TT]-by[tt]", - "options (and the corresponding parameters in the [TT]m2p[tt] file),", + "options (and the corresponding parameters in the [TT].m2p[tt] file),", "which set the size of a single matrix element.[PAR]", "With [TT]-f2[tt] a second matrix file can be supplied. Both matrix", "files will be read simultaneously and the upper left half of the", @@ -1125,7 +1131,7 @@ "with [TT]-cmin[tt] and [TT]-cmax[tt].[PAR]", "[TT]-title[tt] can be set to [TT]none[tt] to suppress the title, or to", "[TT]ylabel[tt] to show the title in the Y-label position (alongside", - "the Y-axis).[PAR]", + "the [IT]y[it]-axis).[PAR]", "With the [TT]-rainbow[tt] option, dull grayscale matrices can be turned", "into attractive color pictures.[PAR]", "Merged or rainbowed matrices can be written to an XPixelMap file with", diff -Nru gromacs-4.5.4/src/tools/g_sigeps.c gromacs-4.5.5/src/tools/g_sigeps.c --- gromacs-4.5.4/src/tools/g_sigeps.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/g_sigeps.c 2011-09-21 12:34:10.000000000 +0000 @@ -73,10 +73,10 @@ int main(int argc,char *argv[]) { const char *desc[] = { - "[TT]g_sigeps[tt] is a simple utility that converts c6/c12 or c6/cn combinations", - "to sigma and epsilon, or vice versa. It can also plot the potential", - "in file. In addition it makes an approximation of a Buckingham potential", - "to a Lennard Jones potential." + "[TT]g_sigeps[tt] is a simple utility that converts C6/C12 or C6/Cn combinations", + "to [GRK]sigma[grk] and [GRK]epsilon[grk], or vice versa. It can also plot the potential", + "in file. In addition, it makes an approximation of a Buckingham potential", + "to a Lennard-Jones potential." }; static real c6=1.0e-3,cn=1.0e-6,qi=0,qj=0,sig=0.3,eps=1,sigfac=0.7; static real Abh=1e5,Bbh=32,Cbh=1e-3; diff -Nru gromacs-4.5.4/src/tools/interf.h gromacs-4.5.5/src/tools/interf.h --- gromacs-4.5.4/src/tools/interf.h 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/interf.h 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,52 @@ +/* + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * Green Red Orange Magenta Azure Cyan Skyblue + */ + +#ifndef _interf_h +#define _interf_h + +#include "typedefs.h" + +typedef struct { + real Z; /* Interface height-coordinate */ + real t; /* Interface thickness */ +} t_interf; + +static void init_interf(t_interf *surf) +{ + surf->Z = 0; + surf->t = 0; +} + +#endif diff -Nru gromacs-4.5.4/src/tools/levenmar.c gromacs-4.5.5/src/tools/levenmar.c --- gromacs-4.5.4/src/tools/levenmar.c 2010-11-09 21:32:45.000000000 +0000 +++ gromacs-4.5.5/src/tools/levenmar.c 2011-09-21 12:34:10.000000000 +0000 @@ -1,4 +1,5 @@ /* + * $Id: levenmar.c,v 1.20 2004/01/23 18:11:02 lindahl Exp $ * * This source code is part of * diff -Nru gromacs-4.5.4/src/tools/make_edi.c gromacs-4.5.5/src/tools/make_edi.c --- gromacs-4.5.4/src/tools/make_edi.c 2011-03-14 13:33:32.000000000 +0000 +++ gromacs-4.5.5/src/tools/make_edi.c 2011-09-21 12:34:10.000000000 +0000 @@ -5,7 +5,7 @@ * G R O M A C S * * GROningen MAchine for Chemical Simulations - * + * * VERSION 3.2.0 * * The make_edi program was generously contributed by Oliver Lange, based @@ -15,7 +15,7 @@ * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. - * + * * If you want to redistribute modifications, please consider that * scientific software is very special. Version control is crucial - * bugs must be traceable. We will be happy to consider code for @@ -62,18 +62,25 @@ #include "rmpbc.h" #include "txtdump.h" #include "eigio.h" -#include "index.h" +#include "index.h" +/* Suppress Cygwin compiler warnings from using newlib version of + * ctype.h */ +#ifdef GMX_CYGWIN +#undef isdigit +#endif typedef struct -{ +{ real deltaF0; gmx_bool bHarmonic; + gmx_bool bConstForce; /* Do constant force flooding instead of + evaluating a flooding potential */ real tau; real deltaF; - real kT; + real kT; real constEfl; - real alpha2; + real alpha2; } t_edflood; @@ -93,7 +100,7 @@ int nini; /* total Nr of atoms */ gmx_bool fitmas; /* true if trans fit with cm */ gmx_bool pcamas; /* true if mass-weighted PCA */ - int presteps; /* number of steps to run without any + int presteps; /* number of steps to run without any * perturbations ... just monitoring */ int outfrq; /* freq (in steps) of writing to edo */ int maxedsteps; /* max nr of steps per cycle */ @@ -141,26 +148,26 @@ /*enums to define the different lexical stati */ enum { sBefore, sNumber, sMinus, sRange, sZero, sSmaller, sError, sSteppedRange }; - + int status=sBefore; /*status of the deterministic automat to scan str */ int number=0; int end_number=0; - + char *start=NULL; /*holds the string of the number behind a ','*/ char *end=NULL; /*holds the string of the number behind a '-' */ - + int nvecs=0; /* counts the number of vectors in the list*/ step=NULL; snew(pos,n+4); startpos=pos; strcpy(pos,str); - pos[n]=','; + pos[n]=','; pos[n+1]='1'; pos[n+2]='\0'; *list = NULL; - + while ((c=*pos)!=0) { switch(status) { /* expect a number */ @@ -184,22 +191,22 @@ else status=sError; break; /* have read a '-' -> expect a number */ - case sMinus: + case sMinus: if (isdigit(c)) { end=pos; status=sRange; break; } else status=sError; break; - + case sSteppedRange: if (isdigit(c)) { if (step) { - status=sError; break; + status=sError; break; } else step=pos; status=sRange; break; } else status=sError; break; - + /* have read the number after a minus, expect ',' or ':' */ case sRange: if (c==',') { @@ -228,7 +235,7 @@ /* format error occured */ case sError: - gmx_fatal(FARGS,"Error in the list of eigenvectors for %s at pos %d with char %c",listname,pos-startpos,*(pos-1)); + gmx_fatal(FARGS,"Error in the list of eigenvectors for %s at pos %d with char %c",listname,pos-startpos,*(pos-1)); /* logical error occured */ case sZero: @@ -246,7 +253,7 @@ sfree(startpos); return nvecs; } /*sscan_list*/ - + void write_eigvec(FILE* fp, int natoms, int eig_list[], rvec** eigvecs,int nvec, const char *grouptitle,real steps[]) { /* eig_list is a zero-terminated list of indices into the eigvecs array. eigvecs are coordinates of eigenvectors @@ -257,18 +264,18 @@ int n=0,i; rvec x; real sum; while (eig_list[n++]); /*count selected eigenvecs*/ - + fprintf(fp,"# NUMBER OF EIGENVECTORS + %s\n %d\n",grouptitle,n-1); - + /* write list of eigenvector indicess */ for(n=0;eig_list[n];n++) { if (steps) - fprintf(fp,"%8d %g\n",eig_list[n],steps[n]); - else + fprintf(fp,"%8d %g\n",eig_list[n],steps[n]); + else fprintf(fp,"%8d %g\n",eig_list[n],1.0); } n=0; - + /* dump coordinates of the selected eigenvectors */ while (eig_list[n]) { sum=0; @@ -277,21 +284,21 @@ gmx_fatal(FARGS,"Selected eigenvector %d is higher than maximum number %d of available eigenvectors",eig_list[n],nvec); copy_rvec(eigvecs[eig_list[n]-1][i],x); sum+=norm2(x); - fprintf(fp,"%8.5f %8.5f %8.5f\n",x[XX],x[YY],x[ZZ]); - } + fprintf(fp,"%8.5f %8.5f %8.5f\n",x[XX],x[YY],x[ZZ]); + } n++; } } /*enum referring to the different lists of eigenvectors*/ -enum { evLINFIX, evLINACC, evFLOOD, evRADFIX, evRADACC, evRADCON , evMON, evEND }; +enum { evLINFIX, evLINACC, evFLOOD, evRADFIX, evRADACC, evRADCON , evMON, evNr }; #define oldMAGIC 666 -#define MAGIC 669 +#define MAGIC 670 -void write_the_whole_thing(FILE* fp, t_edipar *edpars, rvec** eigvecs, - int nvec, int *eig_listen[], real* evStepList[]) +void write_the_whole_thing(FILE* fp, t_edipar *edpars, rvec** eigvecs, + int nvec, int *eig_listen[], real* evStepList[]) { /* write edi-file */ @@ -300,15 +307,16 @@ MAGIC,edpars->nini,edpars->fitmas,edpars->pcamas); fprintf(fp,"#OUTFRQ\n %d\n#MAXLEN\n %d\n#SLOPECRIT\n %f\n", edpars->outfrq,edpars->maxedsteps,edpars->slope); - fprintf(fp,"#PRESTEPS\n %d\n#DELTA_F0\n %f\n#INIT_DELTA_F\n %f\n#TAU\n %f\n#EFL_NULL\n %f\n#ALPHA2\n %f\n#KT\n %f\n#HARMONIC\n %d\n", - edpars->presteps,edpars->flood.deltaF0,edpars->flood.deltaF,edpars->flood.tau,edpars->flood.constEfl,edpars->flood.alpha2,edpars->flood.kT,edpars->flood.bHarmonic); - + fprintf(fp,"#PRESTEPS\n %d\n#DELTA_F0\n %f\n#INIT_DELTA_F\n %f\n#TAU\n %f\n#EFL_NULL\n %f\n#ALPHA2\n %f\n#KT\n %f\n#HARMONIC\n %d\n#CONST_FORCE_FLOODING\n %d\n", + edpars->presteps,edpars->flood.deltaF0,edpars->flood.deltaF,edpars->flood.tau,edpars->flood.constEfl, + edpars->flood.alpha2,edpars->flood.kT,edpars->flood.bHarmonic,edpars->flood.bConstForce); + /* Average and reference positions */ write_t_edx(fp,edpars->sref,"NREF, XREF"); write_t_edx(fp,edpars->sav,"NAV, XAV"); /*Eigenvectors */ - + write_eigvec(fp, edpars->ned, eig_listen[evMON],eigvecs,nvec,"COMPONENTS GROUP 1",NULL); write_eigvec(fp, edpars->ned, eig_listen[evLINFIX],eigvecs,nvec,"COMPONENTS GROUP 2",evStepList[evLINFIX]); write_eigvec(fp, edpars->ned, eig_listen[evLINACC],eigvecs,nvec,"COMPONENTS GROUP 3",evStepList[evLINACC]); @@ -321,9 +329,9 @@ /*Target and Origin positions */ write_t_edx(fp,edpars->star,"NTARGET, XTARGET"); write_t_edx(fp,edpars->sori,"NORIGIN, XORIGIN"); -} +} -int read_conffile(const char *confin,char *title,rvec *x[]) +int read_conffile(const char *confin,char *title,rvec *x[]) { /* read coordinates out of STX file */ int natoms; @@ -342,23 +350,23 @@ snew(*x,natoms); read_stx_conf(confin,title,&confat,*x,NULL,NULL,box); return natoms; -} +} -void read_eigenvalues(int vecs[],const char *eigfile, real values[], - gmx_bool bHesse, real kT) +void read_eigenvalues(int vecs[],const char *eigfile, real values[], + gmx_bool bHesse, real kT) { int neig,nrow,i; double **eigval; - + neig = read_xvg(eigfile,&eigval,&nrow); - + fprintf(stderr,"Read %d eigenvalues\n",neig); - for(i=bHesse ? 6 : 0 ; ianrs,1); } -void filter2edx(struct edix *edx,int nindex, atom_id index[],int ngro, - atom_id igro[],rvec *x,const char* structure) +void filter2edx(struct edix *edx,int nindex, atom_id index[],int ngro, + atom_id igro[],rvec *x,const char* structure) { /* filter2edx copies coordinates from x to edx which are given in index */ - + int pos,i; int ix=edx->nr; edx->nr+=nindex; @@ -433,7 +441,7 @@ void get_structure(t_atoms *atoms,const char *IndexFile, const char *StructureFile,struct edix *edx,int nfit, - atom_id ifit[],int natoms, atom_id index[]) + atom_id ifit[],int natoms, atom_id index[]) { atom_id *igro; /*index corresponding to target or origin structure*/ int ngro; @@ -441,7 +449,7 @@ rvec *xtar; char title[STRLEN]; char* grpname; - + ntar=read_conffile(StructureFile,title,&xtar); printf("Select an index group of %d elements that corresponds to the atoms in the structure file %s\n", @@ -460,7 +468,7 @@ static const char *desc[] = { "[TT]make_edi[tt] generates an essential dynamics (ED) sampling input file to be used with [TT]mdrun[tt]", - "based on eigenvectors of a covariance matrix ([TT]g_covar[tt]) or from a", + "based on eigenvectors of a covariance matrix ([TT]g_covar[tt]) or from a", "normal modes anaysis ([TT]g_nmeig[tt]).", "ED sampling can be used to manipulate the position along collective coordinates", "(eigenvectors) of (biological) macromolecules during a simulation. Particularly,", @@ -481,10 +489,10 @@ "J. Biomol. Struct. Dyn. 13 : 741-751 (1996)[BR]", "B.L. de Groot, A.Amadei, R.M. Scheek, N.A.J. van Nuland and H.J.C. Berendsen; ", "An extended sampling of the configurational space of HPr from E. coli", - "PROTEINS: Struct. Funct. Gen. 26: 314-322 (1996)", + "Proteins: Struct. Funct. Gen. 26: 314-322 (1996)", "[PAR]You will be prompted for one or more index groups that correspond to the eigenvectors,", "reference structure, target positions, etc.[PAR]", - + "[TT]-mon[tt]: monitor projections of the coordinates onto selected eigenvectors.[PAR]", "[TT]-linfix[tt]: perform fixed-step linear expansion along selected eigenvectors.[PAR]", "[TT]-linacc[tt]: perform acceptance linear expansion along selected eigenvectors.", @@ -492,13 +500,13 @@ "[TT]-radfix[tt]: perform fixed-step radius expansion along selected eigenvectors.[PAR]", "[TT]-radacc[tt]: perform acceptance radius expansion along selected eigenvectors.", "(steps in the desired direction will be accepted, others will be rejected).", - "Note: by default the starting MD structure will be taken as origin of the first", + "[BB]Note:[bb] by default the starting MD structure will be taken as origin of the first", "expansion cycle for radius expansion. If [TT]-ori[tt] is specified, you will be able", "to read in a structure file that defines an external origin.[PAR]", "[TT]-radcon[tt]: perform acceptance radius contraction along selected eigenvectors", "towards a target structure specified with [TT]-tar[tt].[PAR]", "NOTE: each eigenvector can be selected only once. [PAR]", - "[TT]-outfrq[tt]: frequency (in steps) of writing out projections etc. to .edo file[PAR]", + "[TT]-outfrq[tt]: frequency (in steps) of writing out projections etc. to [TT].edo[tt] file[PAR]", "[TT]-slope[tt]: minimal slope in acceptance radius expansion. A new expansion", "cycle will be started if the spontaneous increase of the radius (in nm/step)", "is less than the value specified.[PAR]", @@ -507,53 +515,54 @@ "Note on the parallel implementation: since ED sampling is a 'global' thing", "(collective coordinates etc.), at least on the 'protein' side, ED sampling", "is not very parallel-friendly from an implentation point of view. Because", - "parallel ED requires much extra communication, expect the performance to be", + "parallel ED requires some extra communication, expect the performance to be", "lower as in a free MD simulation, especially on a large number of nodes. [PAR]", "All output of [TT]mdrun[tt] (specify with [TT]-eo[tt]) is written to a .edo file. In the output", "file, per OUTFRQ step the following information is present: [PAR]", - "* the step number[BR]", - "* the number of the ED dataset. (Note that you can impose multiple ED constraints in", - "a single simulation - on different molecules e.g. - if several .edi files were concatenated", - "first. The constraints are applied in the order they appear in the .edi file.) [BR]", - "* RMSD (for atoms involved in fitting prior to calculating the ED constraints)[BR]", + "[TT]*[tt] the step number[BR]", + "[TT]*[tt] the number of the ED dataset. ([BB]Note[bb] that you can impose multiple ED constraints in", + "a single simulation (on different molecules) if several [TT].edi[tt] files were concatenated", + "first. The constraints are applied in the order they appear in the [TT].edi[tt] file.) [BR]", + "[TT]*[tt] RMSD (for atoms involved in fitting prior to calculating the ED constraints)[BR]", "* projections of the positions onto selected eigenvectors[BR]", "[PAR][PAR]", "FLOODING:[PAR]", - "with -flood you can specify which eigenvectors are used to compute a flooding potential,", + "with [TT]-flood[tt], you can specify which eigenvectors are used to compute a flooding potential,", "which will lead to extra forces expelling the structure out of the region described", "by the covariance matrix. If you switch -restrain the potential is inverted and the structure", "is kept in that region.", "[PAR]", - "The origin is normally the average structure stored in the eigvec.trr file.", - "It can be changed with -ori to an arbitrary position in configurational space.", - "With -tau, -deltaF0 and -Eflnull you control the flooding behaviour.", + "The origin is normally the average structure stored in the [TT]eigvec.trr[tt] file.", + "It can be changed with [TT]-ori[tt] to an arbitrary position in configurational space.", + "With [TT]-tau[tt], [TT]-deltaF0[tt], and [TT]-Eflnull[tt] you control the flooding behaviour.", "Efl is the flooding strength, it is updated according to the rule of adaptive flooding.", - "Tau is the time constant of adaptive flooding, high tau means slow adaption (i.e. growth). ", + "Tau is the time constant of adaptive flooding, high [GRK]tau[grk] means slow adaption (i.e. growth). ", "DeltaF0 is the flooding strength you want to reach after tau ps of simulation.", - "To use constant Efl set -tau to zero.", + "To use constant Efl set [TT]-tau[tt] to zero.", "[PAR]", - "-alpha is a fudge parameter to control the width of the flooding potential. A value of 2 has been found", + "[TT]-alpha[tt] is a fudge parameter to control the width of the flooding potential. A value of 2 has been found", "to give good results for most standard cases in flooding of proteins.", - "Alpha basically accounts for incomplete sampling, if you sampled further the width of the ensemble would", - "increase, this is mimicked by alpha>1.", - "For restraining alpha<1 can give you smaller width in the restraining potential.", + "[GRK]alpha[grk] basically accounts for incomplete sampling, if you sampled further the width of the ensemble would", + "increase, this is mimicked by [GRK]alpha[grk] > 1.", + "For restraining, [GRK]alpha[grk] < 1 can give you smaller width in the restraining potential.", "[PAR]", "RESTART and FLOODING:", "If you want to restart a crashed flooding simulation please find the values deltaF and Efl in", - "the output file and manually put them into the .edi file under DELTA_F0 and EFL_NULL." + "the output file and manually put them into the [TT].edi[tt] file under DELTA_F0 and EFL_NULL." }; - + /* Save all the params in this struct and then save it in an edi file. * ignoring fields nmass,massnrs,mass,tmass,nfit,fitnrs,edo */ - static t_edipar edi_params; - - enum { evSTEPEND = evRADFIX + 1}; - static const char* evSelections[evEND]= {NULL,NULL,NULL,NULL,NULL,NULL}; - static const char* evOptions[evEND] = {"-linfix","-linacc","-flood","-radfix","-radacc","-radcon","-mon"}; - static const char* evParams[evSTEPEND] ={NULL,NULL}; - static const char* evStepOptions[evSTEPEND] = {"-linstep","-accdir","-not_used","-radstep"}; - static real* evStepList[evSTEPEND]; + static t_edipar edi_params; + + enum { evStepNr = evRADFIX + 1}; + static const char* evSelections[evNr]= {NULL,NULL,NULL,NULL,NULL,NULL}; + static const char* evOptions[evNr] = {"-linfix","-linacc","-flood","-radfix","-radacc","-radcon","-mon"}; + static const char* evParams[evStepNr] ={NULL,NULL}; + static const char* evStepOptions[evStepNr] = {"-linstep","-accdir","-not_used","-radstep"}; + static const char* ConstForceStr; + static real* evStepList[evStepNr]; static real radfix=0.0; static real deltaF0=150; static real deltaF=0; @@ -561,7 +570,7 @@ static real constEfl=0.0; static real alpha=1; static int eqSteps=0; - static int* listen[evEND]; + static int* listen[evNr]; static real T=300.0; const real kB = 2.5 / 300.0; /* k_boltzmann in MD units */ static gmx_bool bRestrain = FALSE; @@ -574,49 +583,53 @@ "Indices of eigenvectors for fixed increment linear sampling" }, { "-linacc", FALSE, etSTR, {&evSelections[1]}, "Indices of eigenvectors for acceptance linear sampling" }, - { "-flood", FALSE, etSTR, {&evSelections[2]}, - "Indices of eigenvectors for flooding"}, { "-radfix", FALSE, etSTR, {&evSelections[3]}, "Indices of eigenvectors for fixed increment radius expansion" }, { "-radacc", FALSE, etSTR, {&evSelections[4]}, "Indices of eigenvectors for acceptance radius expansion" }, { "-radcon", FALSE, etSTR, {&evSelections[5]}, "Indices of eigenvectors for acceptance radius contraction" }, + { "-flood", FALSE, etSTR, {&evSelections[2]}, + "Indices of eigenvectors for flooding"}, { "-outfrq", FALSE, etINT, {&edi_params.outfrq}, "Freqency (in steps) of writing output in [TT].edo[tt] file" }, { "-slope", FALSE, etREAL, { &edi_params.slope}, "Minimal slope in acceptance radius expansion"}, + { "-linstep", FALSE, etSTR, {&evParams[0]}, + "Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! \"1.0 2.3 5.1 -3.1\")"}, + { "-accdir", FALSE, etSTR, {&evParams[1]}, + "Directions for acceptance linear sampling - only sign counts! (put in quotes! \"-1 +1 -1.1\")"}, + { "-radstep", FALSE, etREAL, {&radfix}, + "Stepsize (nm/step) for fixed increment radius expansion"}, { "-maxedsteps", FALSE, etINT, {&edi_params.maxedsteps}, - "Max nr of steps per cycle" }, + "Maximum number of steps per cycle" }, + { "-eqsteps", FALSE, etINT, {&eqSteps}, + "Number of steps to run without any perturbations "}, { "-deltaF0", FALSE,etREAL, {&deltaF0}, - "Target destabilization energy - used for flooding"}, + "Target destabilization energy for flooding"}, { "-deltaF", FALSE, etREAL, {&deltaF}, - "Start deltaF with this parameter - default 0, i.e. nonzero values only needed for restart"}, - { "-tau", FALSE, etREAL, {&tau}, + "Start deltaF with this parameter - default 0, nonzero values only needed for restart"}, + { "-tau", FALSE, etREAL, {&tau}, "Coupling constant for adaption of flooding strength according to deltaF0, 0 = infinity i.e. constant flooding strength"}, - { "-eqsteps", FALSE, etINT, {&eqSteps}, - "Number of steps to run without any perturbations "}, { "-Eflnull", FALSE, etREAL, {&constEfl}, - "This is the starting value of the flooding strength. The flooding strength is updated according to the adaptive flooding scheme. To use a constant flooding strength use [TT]-tau[tt] 0. "}, + "The starting value of the flooding strength. The flooding strength is updated " + "according to the adaptive flooding scheme. For a constant flooding strength use [TT]-tau[tt] 0. "}, { "-T", FALSE, etREAL, {&T}, "T is temperature, the value is needed if you want to do flooding "}, { "-alpha",FALSE,etREAL,{&alpha}, "Scale width of gaussian flooding potential with alpha^2 "}, - { "-linstep", FALSE, etSTR, {&evParams[0]}, - "Stepsizes (nm/step) for fixed increment linear sampling (put in quotes! \"1.0 2.3 5.1 -3.1\")"}, - { "-accdir", FALSE, etSTR, {&evParams[1]}, - "Directions for acceptance linear sampling - only sign counts! (put in quotes! \"-1 +1 -1.1\")"}, - { "-radstep", FALSE, etREAL, {&radfix}, - "Stepsize (nm/step) for fixed increment radius expansion"}, { "-restrain",FALSE, etBOOL, {&bRestrain}, "Use the flooding potential with inverted sign -> effects as quasiharmonic restraining potential"}, { "-hessian",FALSE, etBOOL, {&bHesse}, "The eigenvectors and eigenvalues are from a Hessian matrix"}, - { "-harmonic",FALSE, etBOOL, {&bHarmonic}, + { "-harmonic",FALSE, etBOOL, {&bHarmonic}, "The eigenvalues are interpreted as spring constant"}, + { "-constF", FALSE, etSTR, {&ConstForceStr}, + "Constant force flooding: manually set the forces for the eigenvectors selected with -flood " + "(put in quotes! \"1.0 2.3 5.1 -3.1\"). No other flooding parameters are needed when specifying the forces directly."} }; #define NPA asize(pa) - + rvec *xref1; int nvec1,*eignr1=NULL; rvec *xav1,**eigvec1=NULL; @@ -630,14 +643,14 @@ int ev_class; /* parameter _class i.e. evMON, evRADFIX etc. */ int nvecs; real *eigval1=NULL; /* in V3.3 this is parameter of read_eigenvectors */ - + const char *EdiFile; const char *TargetFile; const char *OriginFile; const char *EigvecFile; - + output_env_t oenv; - + /*to read topology file*/ t_topology top; int ePBC; @@ -645,10 +658,10 @@ matrix topbox; rvec *xtop; gmx_bool bTop, bFit1; - + t_filenm fnm[] = { { efTRN, "-f", "eigenvec", ffREAD }, - { efXVG, "-eig", "eigenval", ffOPTRD }, + { efXVG, "-eig", "eigenval", ffOPTRD }, { efTPS, NULL, NULL, ffREAD }, { efNDX, NULL, NULL, ffOPTRD }, { efSTX, "-tar", "target", ffOPTRD}, @@ -660,64 +673,69 @@ CopyRight(stderr,argv[0]); parse_common_args(&argc,argv, 0 , NFILE,fnm,NPA,pa,asize(desc),desc,0,NULL,&oenv); - + indexfile=ftp2fn_null(efNDX,NFILE,fnm); EdiFile=ftp2fn(efEDI,NFILE,fnm); TargetFile = opt2fn_null("-tar",NFILE,fnm); OriginFile = opt2fn_null("-ori",NFILE,fnm); - - - for (ev_class=0; ev_classnr; - + /*store reference and average structure in edi_params*/ make_t_edx(&edi_params.sref,nfit,xref1,ifit); make_t_edx(&edi_params.sav,natoms,xav1,index); - + /* Store target positions in edi_params */ if (opt2bSet("-tar",NFILE,fnm)) { diff -Nru gromacs-4.5.4/src/tools/Makefile.am gromacs-4.5.5/src/tools/Makefile.am --- gromacs-4.5.4/src/tools/Makefile.am 2011-03-21 10:51:30.000000000 +0000 +++ gromacs-4.5.5/src/tools/Makefile.am 2011-09-21 12:34:32.000000000 +0000 @@ -24,7 +24,7 @@ gmx_analyze.c gmx_anaeig.c gmx_bar.c \ gmx_angle.c gmx_bond.c \ gmx_bundle.c gmx_chi.c gmx_cluster.c gmx_confrms.c \ - gmx_covar.c gmx_current.c \ + gmx_covar.c gmx_current.c gmx_dos.c \ gmx_density.c gmx_densmap.c gmx_dih.c \ gmx_dielectric.c gmx_kinetics.c gmx_spatial.c \ gmx_dipoles.c gmx_disre.c gmx_dist.c gmx_dyndom.c \ @@ -43,8 +43,12 @@ gmx_trjconv.c gmx_trjcat.c gmx_trjorder.c gmx_xpm2ps.c \ gmx_editconf.c gmx_genbox.c gmx_genion.c gmx_genconf.c \ gmx_genpr.c gmx_eneconv.c gmx_vanhove.c gmx_wheel.c \ - addconf.c addconf.h gmx_tune_pme.c gmx_membed.c \ - calcpot.c calcpot.h edittop.c + addconf.c addconf.h gmx_tune_pme.c gmx_membed.c \ + calcpot.c calcpot.h edittop.c \ + dens_filter.c dens_filter.h \ + powerspect.c powerspect.h interf.h \ + gmx_densorder.c gmx_hydorder.c \ + binsearch.h binsearch.c bin_PROGRAMS = \ do_dssp editconf eneconv \ @@ -55,7 +59,7 @@ g_analyze g_anaeig g_bar \ g_angle g_bond \ g_bundle g_chi g_cluster g_confrms \ - g_covar g_current \ + g_covar g_current g_dos \ g_density g_densmap g_dih \ g_dielectric g_helixorient g_principal \ g_dipoles g_disre g_dist g_dyndom \ @@ -71,12 +75,8 @@ g_spatial g_pme_error g_options \ g_tcaf g_traj g_tune_pme \ g_vanhove g_velacc g_membed \ - g_clustsize g_mdmat g_wham \ - g_sigeps - -# These programs are not compiled or installed by default - you will have to -# issue "make " and copy the binary to the correct location yourself! -# Add new entries in Makefile.am! + g_clustsize g_mdmat g_wham g_kinetics \ + g_sigeps g_densorder g_hydorder EXTRA_DIST = libgmxana.pc.cmakein diff -Nru gromacs-4.5.4/src/tools/Makefile.in gromacs-4.5.5/src/tools/Makefile.in --- gromacs-4.5.4/src/tools/Makefile.in 2011-03-21 15:13:40.000000000 +0000 +++ gromacs-4.5.5/src/tools/Makefile.in 2011-09-21 12:38:34.000000000 +0000 @@ -48,25 +48,26 @@ g_anaeig$(EXEEXT) g_bar$(EXEEXT) g_angle$(EXEEXT) \ g_bond$(EXEEXT) g_bundle$(EXEEXT) g_chi$(EXEEXT) \ g_cluster$(EXEEXT) g_confrms$(EXEEXT) g_covar$(EXEEXT) \ - g_current$(EXEEXT) g_density$(EXEEXT) g_densmap$(EXEEXT) \ - g_dih$(EXEEXT) g_dielectric$(EXEEXT) g_helixorient$(EXEEXT) \ - g_principal$(EXEEXT) g_dipoles$(EXEEXT) g_disre$(EXEEXT) \ - g_dist$(EXEEXT) g_dyndom$(EXEEXT) g_enemat$(EXEEXT) \ - g_energy$(EXEEXT) g_lie$(EXEEXT) g_filter$(EXEEXT) \ - g_gyrate$(EXEEXT) g_h2order$(EXEEXT) g_hbond$(EXEEXT) \ - g_helix$(EXEEXT) g_mindist$(EXEEXT) g_msd$(EXEEXT) \ - g_morph$(EXEEXT) g_nmeig$(EXEEXT) g_nmens$(EXEEXT) \ - g_order$(EXEEXT) g_kinetics$(EXEEXT) g_polystat$(EXEEXT) \ - g_potential$(EXEEXT) g_rama$(EXEEXT) g_rdf$(EXEEXT) \ - g_rms$(EXEEXT) g_rmsdist$(EXEEXT) g_rmsf$(EXEEXT) \ - g_rotacf$(EXEEXT) g_rotmat$(EXEEXT) g_saltbr$(EXEEXT) \ - g_sas$(EXEEXT) g_select$(EXEEXT) g_sgangle$(EXEEXT) \ - g_sham$(EXEEXT) g_sorient$(EXEEXT) g_spol$(EXEEXT) \ - g_spatial$(EXEEXT) g_pme_error$(EXEEXT) g_options$(EXEEXT) \ - g_tcaf$(EXEEXT) g_traj$(EXEEXT) g_tune_pme$(EXEEXT) \ - g_vanhove$(EXEEXT) g_velacc$(EXEEXT) g_membed$(EXEEXT) \ - g_clustsize$(EXEEXT) g_mdmat$(EXEEXT) g_wham$(EXEEXT) \ - g_sigeps$(EXEEXT) + g_current$(EXEEXT) g_dos$(EXEEXT) g_density$(EXEEXT) \ + g_densmap$(EXEEXT) g_dih$(EXEEXT) g_dielectric$(EXEEXT) \ + g_helixorient$(EXEEXT) g_principal$(EXEEXT) g_dipoles$(EXEEXT) \ + g_disre$(EXEEXT) g_dist$(EXEEXT) g_dyndom$(EXEEXT) \ + g_enemat$(EXEEXT) g_energy$(EXEEXT) g_lie$(EXEEXT) \ + g_filter$(EXEEXT) g_gyrate$(EXEEXT) g_h2order$(EXEEXT) \ + g_hbond$(EXEEXT) g_helix$(EXEEXT) g_mindist$(EXEEXT) \ + g_msd$(EXEEXT) g_morph$(EXEEXT) g_nmeig$(EXEEXT) \ + g_nmens$(EXEEXT) g_order$(EXEEXT) g_kinetics$(EXEEXT) \ + g_polystat$(EXEEXT) g_potential$(EXEEXT) g_rama$(EXEEXT) \ + g_rdf$(EXEEXT) g_rms$(EXEEXT) g_rmsdist$(EXEEXT) \ + g_rmsf$(EXEEXT) g_rotacf$(EXEEXT) g_rotmat$(EXEEXT) \ + g_saltbr$(EXEEXT) g_sas$(EXEEXT) g_select$(EXEEXT) \ + g_sgangle$(EXEEXT) g_sham$(EXEEXT) g_sorient$(EXEEXT) \ + g_spol$(EXEEXT) g_spatial$(EXEEXT) g_pme_error$(EXEEXT) \ + g_options$(EXEEXT) g_tcaf$(EXEEXT) g_traj$(EXEEXT) \ + g_tune_pme$(EXEEXT) g_vanhove$(EXEEXT) g_velacc$(EXEEXT) \ + g_membed$(EXEEXT) g_clustsize$(EXEEXT) g_mdmat$(EXEEXT) \ + g_wham$(EXEEXT) g_kinetics$(EXEEXT) g_sigeps$(EXEEXT) \ + g_densorder$(EXEEXT) g_hydorder$(EXEEXT) subdir = src/tools DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ $(srcdir)/libgmxana.pc.in @@ -108,15 +109,15 @@ eigio.lo cmat.lo eigensolver.lo nsc.lo hxprops.lo fitahx.lo \ gmx_analyze.lo gmx_anaeig.lo gmx_bar.lo gmx_angle.lo \ gmx_bond.lo gmx_bundle.lo gmx_chi.lo gmx_cluster.lo \ - gmx_confrms.lo gmx_covar.lo gmx_current.lo gmx_density.lo \ - gmx_densmap.lo gmx_dih.lo gmx_dielectric.lo gmx_kinetics.lo \ - gmx_spatial.lo gmx_dipoles.lo gmx_disre.lo gmx_dist.lo \ - gmx_dyndom.lo gmx_enemat.lo gmx_energy.lo gmx_lie.lo \ - gmx_filter.lo gmx_gyrate.lo gmx_h2order.lo gmx_hbond.lo \ - gmx_helix.lo gmx_mindist.lo gmx_msd.lo gmx_morph.lo \ - gmx_nmeig.lo gmx_nmens.lo gmx_order.lo gmx_principal.lo \ - gmx_polystat.lo gmx_potential.lo gmx_rama.lo gmx_rdf.lo \ - gmx_rms.lo gmx_rmsdist.lo gmx_rmsf.lo gmx_rotacf.lo \ + gmx_confrms.lo gmx_covar.lo gmx_current.lo gmx_dos.lo \ + gmx_density.lo gmx_densmap.lo gmx_dih.lo gmx_dielectric.lo \ + gmx_kinetics.lo gmx_spatial.lo gmx_dipoles.lo gmx_disre.lo \ + gmx_dist.lo gmx_dyndom.lo gmx_enemat.lo gmx_energy.lo \ + gmx_lie.lo gmx_filter.lo gmx_gyrate.lo gmx_h2order.lo \ + gmx_hbond.lo gmx_helix.lo gmx_mindist.lo gmx_msd.lo \ + gmx_morph.lo gmx_nmeig.lo gmx_nmens.lo gmx_order.lo \ + gmx_principal.lo gmx_polystat.lo gmx_potential.lo gmx_rama.lo \ + gmx_rdf.lo gmx_rms.lo gmx_rmsdist.lo gmx_rmsf.lo gmx_rotacf.lo \ gmx_rotmat.lo gmx_saltbr.lo gmx_sas.lo gmx_select.lo \ gmx_pme_error.lo gmx_options.lo gmx_sgangle.lo gmx_sorient.lo \ gmx_spol.lo gmx_tcaf.lo gmx_traj.lo gmx_velacc.lo \ @@ -125,7 +126,9 @@ gmx_trjcat.lo gmx_trjorder.lo gmx_xpm2ps.lo gmx_editconf.lo \ gmx_genbox.lo gmx_genion.lo gmx_genconf.lo gmx_genpr.lo \ gmx_eneconv.lo gmx_vanhove.lo gmx_wheel.lo addconf.lo \ - gmx_tune_pme.lo gmx_membed.lo calcpot.lo edittop.lo + gmx_tune_pme.lo gmx_membed.lo calcpot.lo edittop.lo \ + dens_filter.lo powerspect.lo gmx_densorder.lo gmx_hydorder.lo \ + binsearch.lo libgmxana@LIBSUFFIX@_la_OBJECTS = \ $(am_libgmxana@LIBSUFFIX@_la_OBJECTS) libgmxana@LIBSUFFIX@_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \ @@ -222,6 +225,11 @@ g_densmap_LDADD = $(LDADD) g_densmap_DEPENDENCIES = $(lib_LTLIBRARIES) \ ../mdlib/libmd@LIBSUFFIX@.la ../gmxlib/libgmx@LIBSUFFIX@.la +g_densorder_SOURCES = g_densorder.c +g_densorder_OBJECTS = g_densorder.$(OBJEXT) +g_densorder_LDADD = $(LDADD) +g_densorder_DEPENDENCIES = $(lib_LTLIBRARIES) \ + ../mdlib/libmd@LIBSUFFIX@.la ../gmxlib/libgmx@LIBSUFFIX@.la g_dielectric_SOURCES = g_dielectric.c g_dielectric_OBJECTS = g_dielectric.$(OBJEXT) g_dielectric_LDADD = $(LDADD) @@ -247,6 +255,11 @@ g_dist_LDADD = $(LDADD) g_dist_DEPENDENCIES = $(lib_LTLIBRARIES) ../mdlib/libmd@LIBSUFFIX@.la \ ../gmxlib/libgmx@LIBSUFFIX@.la +g_dos_SOURCES = g_dos.c +g_dos_OBJECTS = g_dos.$(OBJEXT) +g_dos_LDADD = $(LDADD) +g_dos_DEPENDENCIES = $(lib_LTLIBRARIES) ../mdlib/libmd@LIBSUFFIX@.la \ + ../gmxlib/libgmx@LIBSUFFIX@.la g_dyndom_SOURCES = g_dyndom.c g_dyndom_OBJECTS = g_dyndom.$(OBJEXT) g_dyndom_LDADD = $(LDADD) @@ -292,6 +305,11 @@ g_helixorient_LDADD = $(LDADD) g_helixorient_DEPENDENCIES = $(lib_LTLIBRARIES) \ ../mdlib/libmd@LIBSUFFIX@.la ../gmxlib/libgmx@LIBSUFFIX@.la +g_hydorder_SOURCES = g_hydorder.c +g_hydorder_OBJECTS = g_hydorder.$(OBJEXT) +g_hydorder_LDADD = $(LDADD) +g_hydorder_DEPENDENCIES = $(lib_LTLIBRARIES) \ + ../mdlib/libmd@LIBSUFFIX@.la ../gmxlib/libgmx@LIBSUFFIX@.la g_kinetics_SOURCES = g_kinetics.c g_kinetics_OBJECTS = g_kinetics.$(OBJEXT) g_kinetics_LDADD = $(LDADD) @@ -559,34 +577,36 @@ eneconv.c g_anadock.c g_anaeig.c g_analyze.c g_angle.c g_bar.c \ g_bond.c g_bundle.c g_chi.c g_cluster.c g_clustsize.c \ g_confrms.c g_covar.c g_current.c g_density.c g_densmap.c \ - g_dielectric.c g_dih.c g_dipoles.c g_disre.c g_dist.c \ - g_dyndom.c g_enemat.c g_energy.c g_filter.c g_gyrate.c \ - g_h2order.c g_hbond.c g_helix.c g_helixorient.c g_kinetics.c \ - g_lie.c g_mdmat.c g_membed.c g_mindist.c g_morph.c g_msd.c \ - g_nmeig.c g_nmens.c g_nmtraj.c g_options.c g_order.c \ - g_pme_error.c g_polystat.c g_potential.c g_principal.c \ - g_rama.c g_rdf.c g_rms.c g_rmsdist.c g_rmsf.c g_rotacf.c \ - g_rotmat.c g_saltbr.c g_sas.c g_select.c g_sgangle.c g_sham.c \ - g_sigeps.c g_sorient.c g_spatial.c g_spol.c g_tcaf.c g_traj.c \ - g_tune_pme.c g_vanhove.c g_velacc.c g_wham.c g_wheel.c \ - genbox.c genconf.c genion.c genrestr.c make_edi.c make_ndx.c \ - mk_angndx.c trjcat.c trjconv.c trjorder.c xpm2ps.c + g_densorder.c g_dielectric.c g_dih.c g_dipoles.c g_disre.c \ + g_dist.c g_dos.c g_dyndom.c g_enemat.c g_energy.c g_filter.c \ + g_gyrate.c g_h2order.c g_hbond.c g_helix.c g_helixorient.c \ + g_hydorder.c g_kinetics.c g_lie.c g_mdmat.c g_membed.c \ + g_mindist.c g_morph.c g_msd.c g_nmeig.c g_nmens.c g_nmtraj.c \ + g_options.c g_order.c g_pme_error.c g_polystat.c g_potential.c \ + g_principal.c g_rama.c g_rdf.c g_rms.c g_rmsdist.c g_rmsf.c \ + g_rotacf.c g_rotmat.c g_saltbr.c g_sas.c g_select.c \ + g_sgangle.c g_sham.c g_sigeps.c g_sorient.c g_spatial.c \ + g_spol.c g_tcaf.c g_traj.c g_tune_pme.c g_vanhove.c g_velacc.c \ + g_wham.c g_wheel.c genbox.c genconf.c genion.c genrestr.c \ + make_edi.c make_ndx.c mk_angndx.c trjcat.c trjconv.c \ + trjorder.c xpm2ps.c DIST_SOURCES = $(libgmxana@LIBSUFFIX@_la_SOURCES) do_dssp.c editconf.c \ eneconv.c g_anadock.c g_anaeig.c g_analyze.c g_angle.c g_bar.c \ g_bond.c g_bundle.c g_chi.c g_cluster.c g_clustsize.c \ g_confrms.c g_covar.c g_current.c g_density.c g_densmap.c \ - g_dielectric.c g_dih.c g_dipoles.c g_disre.c g_dist.c \ - g_dyndom.c g_enemat.c g_energy.c g_filter.c g_gyrate.c \ - g_h2order.c g_hbond.c g_helix.c g_helixorient.c g_kinetics.c \ - g_lie.c g_mdmat.c g_membed.c g_mindist.c g_morph.c g_msd.c \ - g_nmeig.c g_nmens.c g_nmtraj.c g_options.c g_order.c \ - g_pme_error.c g_polystat.c g_potential.c g_principal.c \ - g_rama.c g_rdf.c g_rms.c g_rmsdist.c g_rmsf.c g_rotacf.c \ - g_rotmat.c g_saltbr.c g_sas.c g_select.c g_sgangle.c g_sham.c \ - g_sigeps.c g_sorient.c g_spatial.c g_spol.c g_tcaf.c g_traj.c \ - g_tune_pme.c g_vanhove.c g_velacc.c g_wham.c g_wheel.c \ - genbox.c genconf.c genion.c genrestr.c make_edi.c make_ndx.c \ - mk_angndx.c trjcat.c trjconv.c trjorder.c xpm2ps.c + g_densorder.c g_dielectric.c g_dih.c g_dipoles.c g_disre.c \ + g_dist.c g_dos.c g_dyndom.c g_enemat.c g_energy.c g_filter.c \ + g_gyrate.c g_h2order.c g_hbond.c g_helix.c g_helixorient.c \ + g_hydorder.c g_kinetics.c g_lie.c g_mdmat.c g_membed.c \ + g_mindist.c g_morph.c g_msd.c g_nmeig.c g_nmens.c g_nmtraj.c \ + g_options.c g_order.c g_pme_error.c g_polystat.c g_potential.c \ + g_principal.c g_rama.c g_rdf.c g_rms.c g_rmsdist.c g_rmsf.c \ + g_rotacf.c g_rotmat.c g_saltbr.c g_sas.c g_select.c \ + g_sgangle.c g_sham.c g_sigeps.c g_sorient.c g_spatial.c \ + g_spol.c g_tcaf.c g_traj.c g_tune_pme.c g_vanhove.c g_velacc.c \ + g_wham.c g_wheel.c genbox.c genconf.c genion.c genrestr.c \ + make_edi.c make_ndx.c mk_angndx.c trjcat.c trjconv.c \ + trjorder.c xpm2ps.c DATA = $(pkgconfig_DATA) ETAGS = etags CTAGS = ctags @@ -749,7 +769,7 @@ gmx_analyze.c gmx_anaeig.c gmx_bar.c \ gmx_angle.c gmx_bond.c \ gmx_bundle.c gmx_chi.c gmx_cluster.c gmx_confrms.c \ - gmx_covar.c gmx_current.c \ + gmx_covar.c gmx_current.c gmx_dos.c \ gmx_density.c gmx_densmap.c gmx_dih.c \ gmx_dielectric.c gmx_kinetics.c gmx_spatial.c \ gmx_dipoles.c gmx_disre.c gmx_dist.c gmx_dyndom.c \ @@ -768,13 +788,13 @@ gmx_trjconv.c gmx_trjcat.c gmx_trjorder.c gmx_xpm2ps.c \ gmx_editconf.c gmx_genbox.c gmx_genion.c gmx_genconf.c \ gmx_genpr.c gmx_eneconv.c gmx_vanhove.c gmx_wheel.c \ - addconf.c addconf.h gmx_tune_pme.c gmx_membed.c \ - calcpot.c calcpot.h edittop.c - + addconf.c addconf.h gmx_tune_pme.c gmx_membed.c \ + calcpot.c calcpot.h edittop.c \ + dens_filter.c dens_filter.h \ + powerspect.c powerspect.h interf.h \ + gmx_densorder.c gmx_hydorder.c \ + binsearch.h binsearch.c -# These programs are not compiled or installed by default - you will have to -# issue "make " and copy the binary to the correct location yourself! -# Add new entries in Makefile.am! EXTRA_DIST = libgmxana.pc.cmakein LDADD = $(lib_LTLIBRARIES) ../mdlib/libmd@LIBSUFFIX@.la \ ../gmxlib/libgmx@LIBSUFFIX@.la @@ -946,6 +966,9 @@ g_densmap$(EXEEXT): $(g_densmap_OBJECTS) $(g_densmap_DEPENDENCIES) @rm -f g_densmap$(EXEEXT) $(LINK) $(g_densmap_OBJECTS) $(g_densmap_LDADD) $(LIBS) +g_densorder$(EXEEXT): $(g_densorder_OBJECTS) $(g_densorder_DEPENDENCIES) + @rm -f g_densorder$(EXEEXT) + $(LINK) $(g_densorder_OBJECTS) $(g_densorder_LDADD) $(LIBS) g_dielectric$(EXEEXT): $(g_dielectric_OBJECTS) $(g_dielectric_DEPENDENCIES) @rm -f g_dielectric$(EXEEXT) $(LINK) $(g_dielectric_OBJECTS) $(g_dielectric_LDADD) $(LIBS) @@ -961,6 +984,9 @@ g_dist$(EXEEXT): $(g_dist_OBJECTS) $(g_dist_DEPENDENCIES) @rm -f g_dist$(EXEEXT) $(LINK) $(g_dist_OBJECTS) $(g_dist_LDADD) $(LIBS) +g_dos$(EXEEXT): $(g_dos_OBJECTS) $(g_dos_DEPENDENCIES) + @rm -f g_dos$(EXEEXT) + $(LINK) $(g_dos_OBJECTS) $(g_dos_LDADD) $(LIBS) g_dyndom$(EXEEXT): $(g_dyndom_OBJECTS) $(g_dyndom_DEPENDENCIES) @rm -f g_dyndom$(EXEEXT) $(LINK) $(g_dyndom_OBJECTS) $(g_dyndom_LDADD) $(LIBS) @@ -988,6 +1014,9 @@ g_helixorient$(EXEEXT): $(g_helixorient_OBJECTS) $(g_helixorient_DEPENDENCIES) @rm -f g_helixorient$(EXEEXT) $(LINK) $(g_helixorient_OBJECTS) $(g_helixorient_LDADD) $(LIBS) +g_hydorder$(EXEEXT): $(g_hydorder_OBJECTS) $(g_hydorder_DEPENDENCIES) + @rm -f g_hydorder$(EXEEXT) + $(LINK) $(g_hydorder_OBJECTS) $(g_hydorder_LDADD) $(LIBS) g_kinetics$(EXEEXT): $(g_kinetics_OBJECTS) $(g_kinetics_DEPENDENCIES) @rm -f g_kinetics$(EXEEXT) $(LINK) $(g_kinetics_OBJECTS) $(g_kinetics_LDADD) $(LIBS) @@ -1148,9 +1177,11 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/addconf.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/anadih.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/autocorr.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/binsearch.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/calcpot.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmat.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/correl.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dens_filter.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dlist.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/do_dssp.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/editconf.Po@am__quote@ @@ -1175,11 +1206,13 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_current.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_density.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_densmap.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_densorder.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_dielectric.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_dih.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_dipoles.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_disre.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_dist.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_dos.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_dyndom.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_enemat.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_energy.Po@am__quote@ @@ -1189,6 +1222,7 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_hbond.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_helix.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_helixorient.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_hydorder.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_kinetics.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_lie.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/g_mdmat.Po@am__quote@ @@ -1247,11 +1281,13 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_current.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_density.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_densmap.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_densorder.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_dielectric.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_dih.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_dipoles.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_disre.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_dist.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_dos.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_dyndom.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_editconf.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_eneconv.Plo@am__quote@ @@ -1267,6 +1303,7 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_hbond.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_helix.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_helixorient.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_hydorder.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_kinetics.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_lie.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/gmx_mdmat.Plo@am__quote@ @@ -1316,6 +1353,7 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mk_angndx.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/nsc.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/polynomials.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/powerspect.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pp2shift.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trjcat.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trjconv.Po@am__quote@ diff -Nru gromacs-4.5.4/src/tools/make_ndx.c gromacs-4.5.5/src/tools/make_ndx.c --- gromacs-4.5.4/src/tools/make_ndx.c 2011-03-04 11:10:44.000000000 +0000 +++ gromacs-4.5.5/src/tools/make_ndx.c 2011-09-21 12:34:10.000000000 +0000 @@ -1184,7 +1184,7 @@ "All these programs can generate default index groups. You ONLY", "have to use [TT]make_ndx[tt] when you need SPECIAL index groups.", "There is a default index group for the whole system, 9 default", - "index groups are generated for proteins, a default index group", + "index groups for proteins, and a default index group", "is generated for every other residue name.[PAR]", "When no index file is supplied, also [TT]make_ndx[tt] will generate the", "default groups.", diff -Nru gromacs-4.5.4/src/tools/powerspect.c gromacs-4.5.5/src/tools/powerspect.c --- gromacs-4.5.4/src/tools/powerspect.c 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/powerspect.c 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,136 @@ +/* -*- mode: c; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; c-file-style: "stroustrup"; -*- + * $Id: densorder.c,v 0.9 + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.0 + * + * Copyright (c) 1991-2001 + * BIOSON Research Institute, Dept. of Biophysical Chemistry + * University of Groningen, The Netherlands + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * Do check out http://www.gromacs.org , or mail us at gromacs@gromacs.org . + * + * And Hey: + * Gyas ROwers Mature At Cryogenic Speed + */ + +#ifdef HAVE_CONFIG_H +#include +#endif +#include +#include +#include +#include +#include "interf.h" +#include "powerspect.h" + +void addtoavgenergy(t_complex *list, real *result, int size, int tsteps){ + int i; + for (i=0;iZ; + surf[1][n][i]=if2[n][i]->Z; + } + } + powerspectavg(surf, t,xb,yb,fnms); +} + diff -Nru gromacs-4.5.4/src/tools/powerspect.h gromacs-4.5.5/src/tools/powerspect.h --- gromacs-4.5.4/src/tools/powerspect.h 1970-01-01 00:00:00.000000000 +0000 +++ gromacs-4.5.5/src/tools/powerspect.h 2011-09-21 12:34:10.000000000 +0000 @@ -0,0 +1,48 @@ +/* + * + * This source code is part of + * + * G R O M A C S + * + * GROningen MAchine for Chemical Simulations + * + * VERSION 3.2.0 + * Written by David van der Spoel, Erik Lindahl, Berk Hess, and others. + * Copyright (c) 1991-2000, University of Groningen, The Netherlands. + * Copyright (c) 2001-2004, The GROMACS development team, + * check out http://www.gromacs.org for more information. + + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * If you want to redistribute modifications, please consider that + * scientific software is very special. Version control is crucial - + * bugs must be traceable. We will be happy to consider code for + * inclusion in the official distribution, but derived work must not + * be called official GROMACS. Details are found in the README & COPYING + * files - if they are missing, get the official version at www.gromacs.org. + * + * To help us fund GROMACS development, we humbly ask that you cite + * the papers on the package - you can find them in the top README file. + * + * For more info, check our website at http://www.gromacs.org + * + * And Hey: + * Green Red Orange Magenta Azure Cyan Skyblue + */ + +#ifndef _powerspect_h +#define _powerspect_h + +#include "typedefs.h" +#include "interf.h" + +extern void powerspectavg(real ***interface, int t, int xbins, int ybins, + char **outfiles); + +extern void powerspectavg_intf(t_interf ***if1,t_interf ***if2,int t, + int xbins, int ybins, char **outfiles); + +#endif