From 1bef8ec3a4e9ba8467740ec7a36be4ea3de9a787 Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 14:28:49 +0000
Subject: [PATCH 01/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12340
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
src/MPIIO/dump_atom_mpiio.cpp | 2 +-
src/MPIIO/dump_custom_mpiio.cpp | 2 +-
src/MPIIO/dump_xyz_mpiio.cpp | 2 +-
src/MPIIO/restart_mpiio.cpp | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/MPIIO/dump_atom_mpiio.cpp b/src/MPIIO/dump_atom_mpiio.cpp
index 2767847a6a..d4a2f29f8a 100644
--- a/src/MPIIO/dump_atom_mpiio.cpp
+++ b/src/MPIIO/dump_atom_mpiio.cpp
@@ -98,7 +98,7 @@ void DumpAtomMPIIO::openfile()
}
else { // replace open
- int err = MPI_File_open( world, filecurrent, MPI_MODE_CREATE | MPI_MODE_APPEND | MPI_MODE_WRONLY , MPI_INFO_NULL, &mpifh);
+ int err = MPI_File_open( world, filecurrent, MPI_MODE_CREATE | MPI_MODE_WRONLY , MPI_INFO_NULL, &mpifh);
if (err != MPI_SUCCESS) {
char str[128];
sprintf(str,"Cannot open dump file %s",filecurrent);
diff --git a/src/MPIIO/dump_custom_mpiio.cpp b/src/MPIIO/dump_custom_mpiio.cpp
index 2922ad30c0..7aac8e665a 100644
--- a/src/MPIIO/dump_custom_mpiio.cpp
+++ b/src/MPIIO/dump_custom_mpiio.cpp
@@ -119,7 +119,7 @@ void DumpCustomMPIIO::openfile()
}
else { // replace open
- int err = MPI_File_open( world, filecurrent, MPI_MODE_CREATE | MPI_MODE_APPEND | MPI_MODE_WRONLY , MPI_INFO_NULL, &mpifh);
+ int err = MPI_File_open( world, filecurrent, MPI_MODE_CREATE | MPI_MODE_WRONLY , MPI_INFO_NULL, &mpifh);
if (err != MPI_SUCCESS) {
char str[128];
sprintf(str,"Cannot open dump file %s",filecurrent);
diff --git a/src/MPIIO/dump_xyz_mpiio.cpp b/src/MPIIO/dump_xyz_mpiio.cpp
index 108ab8dfee..af1f96c94a 100644
--- a/src/MPIIO/dump_xyz_mpiio.cpp
+++ b/src/MPIIO/dump_xyz_mpiio.cpp
@@ -118,7 +118,7 @@ void DumpXYZMPIIO::openfile()
}
else { // replace open
- int err = MPI_File_open( world, filecurrent, MPI_MODE_CREATE | MPI_MODE_APPEND | MPI_MODE_WRONLY , MPI_INFO_NULL, &mpifh);
+ int err = MPI_File_open( world, filecurrent, MPI_MODE_CREATE | MPI_MODE_WRONLY , MPI_INFO_NULL, &mpifh);
if (err != MPI_SUCCESS) {
char str[128];
sprintf(str,"Cannot open dump file %s",filecurrent);
diff --git a/src/MPIIO/restart_mpiio.cpp b/src/MPIIO/restart_mpiio.cpp
index 55935d09d3..c72e37f99e 100644
--- a/src/MPIIO/restart_mpiio.cpp
+++ b/src/MPIIO/restart_mpiio.cpp
@@ -58,7 +58,7 @@ void RestartMPIIO::openForRead(char *filename)
void RestartMPIIO::openForWrite(char *filename)
{
- int err = MPI_File_open(world, filename, MPI_MODE_APPEND | MPI_MODE_WRONLY,
+ int err = MPI_File_open(world, filename, MPI_MODE_WRONLY,
MPI_INFO_NULL, &mpifh);
if (err != MPI_SUCCESS) {
char str[MPI_MAX_ERROR_STRING+128];
From a0fba99324bbadab78cfab0a721e21f02bbef279 Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 14:29:00 +0000
Subject: [PATCH 02/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12341
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
src/atom.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/atom.cpp b/src/atom.cpp
index 550b959f22..006538bc85 100644
--- a/src/atom.cpp
+++ b/src/atom.cpp
@@ -369,7 +369,7 @@ void Atom::create_avec(const char *style, int narg, char **arg, int trysuffix)
if (sflag) {
char estyle[256];
- if (sflag = 1) sprintf(estyle,"%s/%s",style,lmp->suffix);
+ if (sflag == 1) sprintf(estyle,"%s/%s",style,lmp->suffix);
else sprintf(estyle,"%s/%s",style,lmp->suffix2);
int n = strlen(estyle) + 1;
atom_style = new char[n];
From 05c3613356a83efe639e17572301893e116549da Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 14:39:56 +0000
Subject: [PATCH 03/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12342
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
doc/fix_langevin.html | 29 +++++++++++++++--------------
doc/fix_langevin.txt | 29 +++++++++++++++--------------
2 files changed, 30 insertions(+), 28 deletions(-)
diff --git a/doc/fix_langevin.html b/doc/fix_langevin.html
index 36ffc14e3c..4bcfc831c1 100644
--- a/doc/fix_langevin.html
+++ b/doc/fix_langevin.html
@@ -239,20 +239,21 @@ group. As a result, the center-of-mass of a system with zero initial
momentum will not drift over time.
Date: Mon, 25 Aug 2014 14:48:45 +0000
Subject: [PATCH 04/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12343
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
doc/Section_accelerate.html | 32 ++++++++++++++++----------------
doc/Section_accelerate.txt | 32 ++++++++++++++++----------------
doc/Section_example.html | 2 +-
doc/Section_example.txt | 2 +-
doc/Section_intro.html | 2 +-
doc/Section_intro.txt | 2 +-
doc/Section_packages.html | 18 +++++++++++++++++-
doc/Section_packages.txt | 18 +++++++++++++++++-
doc/Section_start.html | 4 ++--
doc/Section_start.txt | 4 ++--
doc/package.html | 2 +-
doc/package.txt | 2 +-
doc/suffix.html | 2 +-
doc/suffix.txt | 2 +-
14 files changed, 78 insertions(+), 46 deletions(-)
diff --git a/doc/Section_accelerate.html b/doc/Section_accelerate.html
index 296219f985..8ee4f4331d 100644
--- a/doc/Section_accelerate.html
+++ b/doc/Section_accelerate.html
@@ -176,8 +176,8 @@ discussed below.
package. These styles support vectorized single and mixed precision
calculations, in addition to full double precision. In extreme cases,
this can provide speedups over 3.5x on CPUs. The package also
-supports acceleration with offload to Intel corprocessors (Xeon
-Phi). This can result in additional speedup over 2x depending on the
+supports acceleration with offload to Intel(R) Xeon Phi(TM) coprocessors.
+This can result in additional speedup over 2x depending on the
hardware configuration.
Styles with a "kk" suffix are part of the KOKKOS package, and can be
@@ -977,10 +977,10 @@ LAMMPS.
The USER-INTEL package was developed by Mike Brown at Intel
Corporation. It provides a capability to accelerate simulations by
-offloading neighbor list and non-bonded force calculations to Intel
-coprocessors (Xeon Phi). Additionally, it supports running
+offloading neighbor list and non-bonded force calculations to Intel(R)
+Xeon Phi(TM) coprocessors. Additionally, it supports running
simulations in single, mixed, or double precision with vectorization,
-even if a coprocessor is not present, i.e. on an Intel CPU. The same
+even if a coprocessor is not present, i.e. on an Intel(R) CPU. The same
C++ code is used for both cases. When offloading to a coprocessor,
the routine is run twice, once with an offload flag.
@@ -1006,19 +1006,19 @@ LINKFLAGS variables. You also need to add -DLAMMPS_MEMALIGN=64 and
If you are compiling on the same architecture that will be used for
the runs, adding the flag -xHost will enable vectorization with the
-Intel compiler. In order to build with support for an Intel
+Intel(R) compiler. In order to build with support for an Intel(R)
coprocessor, the flag -offload should be added to the LINKFLAGS line
and the flag -DLMP_INTEL_OFFLOAD should be added to the CCFLAGS
line.
The files src/MAKE/Makefile.intel and src/MAKE/Makefile.intel_offload
are included in the src/MAKE directory with options that perform well
-with the Intel compiler. The latter Makefile has support for offload
+with the Intel(R) compiler. The latter Makefile has support for offload
to coprocessors and the former does not.
-It is recommended that Intel Compiler 2013 SP1 update 1 be used for
+
It is recommended that Intel(R) Compiler 2013 SP1 update 1 be used for
compiling. Newer versions have some performance issues that are being
-addressed. If using Intel MPI, version 5 or higher is recommended.
+addressed. If using Intel(R) MPI, version 5 or higher is recommended.
The rest of the compilation is the same as for any other package that
has no additional library dependencies, e.g.
@@ -1034,7 +1034,7 @@ them.
The total number of MPI tasks used by LAMMPS (one or multiple per
compute node) is set in the usual manner via the mpirun or mpiexec
-commands, and is independent of the Intel package.
+commands, and is independent of the USER-INTEL package.
Input script requirements to run using pair styles with a intel
suffix are as follows:
@@ -1054,10 +1054,10 @@ use all single or all double precision, the package
intel command must be used in the input script with a
"single" or "double" keyword specified.
-Running with an Intel coprocessor:
+
Running with an Intel(R) coprocessor:
The USER-INTEL package supports offload of a fraction of the work to
-Intel coprocessors (Xeon Phi). This is accomplished by setting a
+Intel(R) Xeon Phi(TM) coprocessors. This is accomplished by setting a
balance fraction on the package intel command. A
balance of 0 runs all calculations on the CPU. A balance of 1 runs
all calculations on the coprocessor. A balance of 0.5 runs half of
@@ -1075,8 +1075,8 @@ adding a short warm-up run (10-20 steps) will allow the load-balancer
to find a setting that will carry over to additional runs.
The default for the package intel command is to have
-all the MPI tasks on a given compute node use a single coprocessor
-(Xeon Phi). In general, running with a large number of MPI tasks on
+all the MPI tasks on a given compute node use a single Xeon Phi(TM) coprocessor
+In general, running with a large number of MPI tasks on
each node will perform best with offload. Each MPI task will
automatically get affinity to a subset of the hardware threads
available on the coprocessor. For example, if your card has 61 cores,
@@ -1087,7 +1087,7 @@ tuning of the number of threads to use per MPI task or the number of
threads to use per core can be accomplished with keywords to the
package intel command.
-If LAMMPS is using offload to a coprocessor (Xeon Phi), a diagnostic
+
If LAMMPS is using offload to a Intel(R) Xeon Phi(TM) coprocessor, a diagnostic
line during the setup for a run is printed to the screen (not to log
files) indicating that offload is being used and the number of
coprocessor threads per MPI task. Additionally, an offload timing
@@ -1095,7 +1095,7 @@ summary is printed at the end of each run. When using offload, the
sort frequency for atom data is changed to 1 so
that the per-atom data is sorted every neighbor build.
-To use multiple coprocessors (Xeon Phis) on each compute node, the
+
To use multiple coprocessors on each compute node, the
offload_cards keyword can be specified with the package
intel command to specify the number of coprocessors to
use.
diff --git a/doc/Section_accelerate.txt b/doc/Section_accelerate.txt
index 160d67c108..04481007c0 100644
--- a/doc/Section_accelerate.txt
+++ b/doc/Section_accelerate.txt
@@ -172,8 +172,8 @@ Styles with an "intel" suffix are part of the USER-INTEL
package. These styles support vectorized single and mixed precision
calculations, in addition to full double precision. In extreme cases,
this can provide speedups over 3.5x on CPUs. The package also
-supports acceleration with offload to Intel corprocessors (Xeon
-Phi). This can result in additional speedup over 2x depending on the
+supports acceleration with offload to Intel(R) Xeon Phi(TM) coprocessors.
+This can result in additional speedup over 2x depending on the
hardware configuration.
Styles with a "kk" suffix are part of the KOKKOS package, and can be
@@ -973,10 +973,10 @@ LAMMPS.
The USER-INTEL package was developed by Mike Brown at Intel
Corporation. It provides a capability to accelerate simulations by
-offloading neighbor list and non-bonded force calculations to Intel
-coprocessors (Xeon Phi). Additionally, it supports running
+offloading neighbor list and non-bonded force calculations to Intel(R)
+Xeon Phi(TM) coprocessors. Additionally, it supports running
simulations in single, mixed, or double precision with vectorization,
-even if a coprocessor is not present, i.e. on an Intel CPU. The same
+even if a coprocessor is not present, i.e. on an Intel(R) CPU. The same
C++ code is used for both cases. When offloading to a coprocessor,
the routine is run twice, once with an offload flag.
@@ -1002,19 +1002,19 @@ LINKFLAGS variables. You also need to add -DLAMMPS_MEMALIGN=64 and
If you are compiling on the same architecture that will be used for
the runs, adding the flag {-xHost} will enable vectorization with the
-Intel compiler. In order to build with support for an Intel
+Intel(R) compiler. In order to build with support for an Intel(R)
coprocessor, the flag {-offload} should be added to the LINKFLAGS line
and the flag {-DLMP_INTEL_OFFLOAD} should be added to the CCFLAGS
line.
The files src/MAKE/Makefile.intel and src/MAKE/Makefile.intel_offload
are included in the src/MAKE directory with options that perform well
-with the Intel compiler. The latter Makefile has support for offload
+with the Intel(R) compiler. The latter Makefile has support for offload
to coprocessors and the former does not.
-It is recommended that Intel Compiler 2013 SP1 update 1 be used for
+It is recommended that Intel(R) Compiler 2013 SP1 update 1 be used for
compiling. Newer versions have some performance issues that are being
-addressed. If using Intel MPI, version 5 or higher is recommended.
+addressed. If using Intel(R) MPI, version 5 or higher is recommended.
The rest of the compilation is the same as for any other package that
has no additional library dependencies, e.g.
@@ -1030,7 +1030,7 @@ them.
The total number of MPI tasks used by LAMMPS (one or multiple per
compute node) is set in the usual manner via the mpirun or mpiexec
-commands, and is independent of the Intel package.
+commands, and is independent of the USER-INTEL package.
Input script requirements to run using pair styles with a {intel}
suffix are as follows:
@@ -1050,10 +1050,10 @@ use all single or all double precision, the "package
intel"_package.html command must be used in the input script with a
"single" or "double" keyword specified.
-[Running with an Intel coprocessor:]
+[Running with an Intel(R) coprocessor:]
The USER-INTEL package supports offload of a fraction of the work to
-Intel coprocessors (Xeon Phi). This is accomplished by setting a
+Intel(R) Xeon Phi(TM) coprocessors. This is accomplished by setting a
balance fraction on the "package intel"_package.html command. A
balance of 0 runs all calculations on the CPU. A balance of 1 runs
all calculations on the coprocessor. A balance of 0.5 runs half of
@@ -1071,8 +1071,8 @@ adding a short warm-up run (10-20 steps) will allow the load-balancer
to find a setting that will carry over to additional runs.
The default for the "package intel"_package.html command is to have
-all the MPI tasks on a given compute node use a single coprocessor
-(Xeon Phi). In general, running with a large number of MPI tasks on
+all the MPI tasks on a given compute node use a single Xeon Phi(TM) coprocessor
+In general, running with a large number of MPI tasks on
each node will perform best with offload. Each MPI task will
automatically get affinity to a subset of the hardware threads
available on the coprocessor. For example, if your card has 61 cores,
@@ -1083,7 +1083,7 @@ tuning of the number of threads to use per MPI task or the number of
threads to use per core can be accomplished with keywords to the
"package intel"_package.html command.
-If LAMMPS is using offload to a coprocessor (Xeon Phi), a diagnostic
+If LAMMPS is using offload to a Intel(R) Xeon Phi(TM) coprocessor, a diagnostic
line during the setup for a run is printed to the screen (not to log
files) indicating that offload is being used and the number of
coprocessor threads per MPI task. Additionally, an offload timing
@@ -1091,7 +1091,7 @@ summary is printed at the end of each run. When using offload, the
"sort"_atom_modify.html frequency for atom data is changed to 1 so
that the per-atom data is sorted every neighbor build.
-To use multiple coprocessors (Xeon Phis) on each compute node, the
+To use multiple coprocessors on each compute node, the
{offload_cards} keyword can be specified with the "package
intel"_package.html command to specify the number of coprocessors to
use.
diff --git a/doc/Section_example.html b/doc/Section_example.html
index dfc356a3d4..7683b56578 100644
--- a/doc/Section_example.html
+++ b/doc/Section_example.html
@@ -59,7 +59,7 @@ section of the LAMMPS WWW Site.
| gpu | use of the GPU package for GPU acceleration |
| hugoniostat | Hugoniostat shock dynamics |
| indent | spherical indenter into a 2d solid |
-| intel | use of the USER-INTEL package for CPU or Xeon Phi acceleration |
+| intel | use of the USER-INTEL package for CPU or Intel(R) Xeon Phi(TM) coprocessor |
| kim | use of potentials in Knowledge Base for Interatomic Models (KIM) |
| line | line segment particles in 2d rigid bodies |
| meam | MEAM test for SiC and shear (same as shear examples) |
diff --git a/doc/Section_example.txt b/doc/Section_example.txt
index eaaebfb481..9992de7fdf 100644
--- a/doc/Section_example.txt
+++ b/doc/Section_example.txt
@@ -55,7 +55,7 @@ friction: frictional contact of spherical asperities between 2d surfaces
gpu: use of the GPU package for GPU acceleration
hugoniostat: Hugoniostat shock dynamics
indent: spherical indenter into a 2d solid
-intel: use of the USER-INTEL package for CPU or Xeon Phi acceleration
+intel: use of the USER-INTEL package for CPU or Intel(R) Xeon Phi(TM) coprocessor
kim: use of potentials in Knowledge Base for Interatomic Models (KIM)
line: line segment particles in 2d rigid bodies
meam: MEAM test for SiC and shear (same as shear examples)
diff --git a/doc/Section_intro.html b/doc/Section_intro.html
index aaeaf0ab5c..173180c3a2 100644
--- a/doc/Section_intro.html
+++ b/doc/Section_intro.html
@@ -109,7 +109,7 @@ it to LAMMPS.
open-source distribution
highly portable C++
optional libraries used: MPI and single-processor FFT
- GPU (CUDA and OpenCL), Intel Xeon Phi, and OpenMP support for many code features
+ GPU (CUDA and OpenCL), Intel(R) Xeon Phi(TM) coprocessors, and OpenMP support for many code features
easy to extend with new features and functionality
runs from an input script
syntax for defining and using variables and formulas
diff --git a/doc/Section_intro.txt b/doc/Section_intro.txt
index 6ded6a8635..f860fa2775 100644
--- a/doc/Section_intro.txt
+++ b/doc/Section_intro.txt
@@ -105,7 +105,7 @@ General features :h4
open-source distribution
highly portable C++
optional libraries used: MPI and single-processor FFT
- GPU (CUDA and OpenCL), Intel Xeon Phi, and OpenMP support for many code features
+ GPU (CUDA and OpenCL), Intel(R) Xeon Phi(TM) coprocessors, and OpenMP support for many code features
easy to extend with new features and functionality
runs from an input script
syntax for defining and using variables and formulas
diff --git a/doc/Section_packages.html b/doc/Section_packages.html
index 7ac4e3cac6..e151cc6053 100644
--- a/doc/Section_packages.html
+++ b/doc/Section_packages.html
@@ -125,7 +125,7 @@ on how to build LAMMPS with both kinds of auxiliary libraries.
| USER-CUDA | NVIDIA GPU styles | Christian Trott (U Tech Ilmenau) | Section accelerate | USER/cuda | - | lib/cuda |
| USER-EFF | electron force field | Andres Jaramillo-Botero (Caltech) | pair_style eff/cut | USER/eff | eff | - |
| USER-FEP | free energy perturbation | Agilio Padua (U Blaise Pascal Clermont-Ferrand) | fix adapt/fep | USER/fep | - | - |
-| USER-INTEL | Vectorized CPU and Intel coprocessor styles | W. Michael Brown (Intel) | Section accelerate | examples/intel | - | - |
+| USER-INTEL | Vectorized CPU and Intel(R) coprocessor styles | W. Michael Brown (Intel) | Section accelerate | examples/intel | - | - |
| USER-LB | Lattice Boltzmann fluid | Colin Denniston (U Western Ontario) | fix lb/fluid | USER/lb | - | - |
| USER-MISC | single-file contributions | USER-MISC/README | USER-MISC/README | - | - | - |
| USER-MOLFILE | VMD molfile plug-ins | Axel Kohlmeyer (Temple U) | dump molfile | - | - | VMD-MOLFILE |
@@ -390,6 +390,22 @@ Contact him directly if you have questions.
+USER-INTEL package
+
+This package provides options for performing neighbor list and
+non-bonded force calculations in single, mixed, or double precision
+and also a capability for accelerating calculations with an
+Intel(R) Xeon Phi(TM) coprocessor.
+
+See this section of the manual to get started:
+
+Section_accelerate
+
+The person who created this package is W. Michael Brown at Intel
+(michael.w.brown at intel.com). Contact him directly if you have questions.
+
+
+
USER-LB package
This package contains a LAMMPS implementation of a background
diff --git a/doc/Section_packages.txt b/doc/Section_packages.txt
index ea0810e923..1936eea35b 100644
--- a/doc/Section_packages.txt
+++ b/doc/Section_packages.txt
@@ -117,7 +117,7 @@ USER-COLVARS, collective variables, Fiorin & Henin & Kohlmeyer (3), "fix colvars
USER-CUDA, NVIDIA GPU styles, Christian Trott (U Tech Ilmenau), "Section accelerate"_Section_accelerate.html#acc_7, USER/cuda, -, lib/cuda
USER-EFF, electron force field, Andres Jaramillo-Botero (Caltech), "pair_style eff/cut"_pair_eff.html, USER/eff, "eff"_eff, -
USER-FEP, free energy perturbation, Agilio Padua (U Blaise Pascal Clermont-Ferrand), "fix adapt/fep"_fix_adapt.html, USER/fep, -, -
-USER-INTEL, Vectorized CPU and Intel coprocessor styles, W. Michael Brown (Intel), "Section accelerate"_Section_accelerate.html#acc_9, examples/intel, -, -
+USER-INTEL, Vectorized CPU and Intel(R) coprocessor styles, W. Michael Brown (Intel), "Section accelerate"_Section_accelerate.html#acc_9, examples/intel, -, -
USER-LB, Lattice Boltzmann fluid, Colin Denniston (U Western Ontario), "fix lb/fluid"_fix_lb_fluid.html, USER/lb, -, -
USER-MISC, single-file contributions, USER-MISC/README, USER-MISC/README, -, -, -
USER-MOLFILE, "VMD"_VMD molfile plug-ins, Axel Kohlmeyer (Temple U), "dump molfile"_dump_molfile.html, -, -, VMD-MOLFILE
@@ -377,6 +377,22 @@ Contact him directly if you have questions.
:line
+USER-INTEL package :h4
+
+This package provides options for performing neighbor list and
+non-bonded force calculations in single, mixed, or double precision
+and also a capability for accelerating calculations with an
+Intel(R) Xeon Phi(TM) coprocessor.
+
+See this section of the manual to get started:
+
+"Section_accelerate"_Section_accelerate.html#acc_9
+
+The person who created this package is W. Michael Brown at Intel
+(michael.w.brown at intel.com). Contact him directly if you have questions.
+
+:line
+
USER-LB package :h4
This package contains a LAMMPS implementation of a background
diff --git a/doc/Section_start.html b/doc/Section_start.html
index 67da141f95..6448a72a76 100644
--- a/doc/Section_start.html
+++ b/doc/Section_start.html
@@ -1493,8 +1493,8 @@ default GPU settings, as if the command "package gpu force/neigh 0 0
changed by using the package gpu command in your script
if desired.
-For the Intel package, using this command-line switch also invokes the
-default Intel settings, as if the command "package intel * mixed
+
For the USER-INTEL package, using this command-line switch also invokes the
+default USER-INTEL settings, as if the command "package intel * mixed
balance -1" were used at the top of your input script. These settings
can be changed by using the package intel command in
your script if desired. If the USER-OMP package is installed, the
diff --git a/doc/Section_start.txt b/doc/Section_start.txt
index c7714905a4..db3fc8e360 100644
--- a/doc/Section_start.txt
+++ b/doc/Section_start.txt
@@ -1487,8 +1487,8 @@ default GPU settings, as if the command "package gpu force/neigh 0 0
changed by using the "package gpu"_package.html command in your script
if desired.
-For the Intel package, using this command-line switch also invokes the
-default Intel settings, as if the command "package intel * mixed
+For the USER-INTEL package, using this command-line switch also invokes the
+default USER-INTEL settings, as if the command "package intel * mixed
balance -1" were used at the top of your input script. These settings
can be changed by using the "package intel"_package.html command in
your script if desired. If the USER-OMP package is installed, the
diff --git a/doc/package.html b/doc/package.html
index 8e7f8dd231..6a1f0ec39a 100644
--- a/doc/package.html
+++ b/doc/package.html
@@ -249,7 +249,7 @@ terms and single precision for everything else), or double (intel
styles use double precision for all calculations).
Additional keyword-value pairs are available that are used to
-determine how work is offloaded to an Intel coprocessor. If LAMMPS is
+determine how work is offloaded to an Intel(R) coprocessor. If LAMMPS is
built without offload support, these values are ignored. The
additional settings are as follows:
diff --git a/doc/package.txt b/doc/package.txt
index 6237fb76cb..c535f4c304 100644
--- a/doc/package.txt
+++ b/doc/package.txt
@@ -243,7 +243,7 @@ terms and single precision for everything else), or {double} (intel
styles use double precision for all calculations).
Additional keyword-value pairs are available that are used to
-determine how work is offloaded to an Intel coprocessor. If LAMMPS is
+determine how work is offloaded to an Intel(R) coprocessor. If LAMMPS is
built without offload support, these values are ignored. The
additional settings are as follows:
diff --git a/doc/suffix.html b/doc/suffix.html
index 479a9bcd29..c1aae192de 100644
--- a/doc/suffix.html
+++ b/doc/suffix.html
@@ -51,7 +51,7 @@ run on one or more GPUs or multicore CPU/GPU nodes
USER-INTEL = a collection of pair styles and neighbor routines
optimized to run in single, mixed, or double precision on CPUs and
-Intel coprocessors (Xeon Phi).
+Intel(R) Xeon Phi(TM) coprocessors.
KOKKOS = a collection of atom, pair, and fix styles optimized to run
using the Kokkos library on various kinds of hardware, including GPUs
diff --git a/doc/suffix.txt b/doc/suffix.txt
index 6309b5fa16..d2e0780dda 100644
--- a/doc/suffix.txt
+++ b/doc/suffix.txt
@@ -48,7 +48,7 @@ run on one or more GPUs or multicore CPU/GPU nodes :l
USER-INTEL = a collection of pair styles and neighbor routines
optimized to run in single, mixed, or double precision on CPUs and
-Intel coprocessors (Xeon Phi). :l
+Intel(R) Xeon Phi(TM) coprocessors. :l
KOKKOS = a collection of atom, pair, and fix styles optimized to run
using the Kokkos library on various kinds of hardware, including GPUs
From 15ae2e3f5ec099dfb23fea88e27477a266fbc094 Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 14:48:52 +0000
Subject: [PATCH 05/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12344
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
src/USER-INTEL/README | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/src/USER-INTEL/README b/src/USER-INTEL/README
index 0b38928b2e..d70dd45293 100644
--- a/src/USER-INTEL/README
+++ b/src/USER-INTEL/README
@@ -1,6 +1,6 @@
--------------------------------
- LAMMPS Intel Package
+ LAMMPS Intel(R) Package
--------------------------------
W. Michael Brown (Intel)
@@ -12,14 +12,15 @@ This package is based on the USER-OMP package and provides LAMMPS styles that:
1. include support for single and mixed precision in addition to double.
2. include modifications to support vectorization for key routines
- 3. include modifications to support offload to Xeon Phi coprocessors
+ 3. include modifications to support offload to Intel(R) Xeon Phi(TM)
+ coprocessors
-----------------------------------------------------------------------------
When using the suffix command with "intel", intel styles will be used if they
-exist; if they do not, and an omp version exists, that style will be used.
-This is accomplished through the files *ompinto_intel.h that are created
-in the src directory when the intel package is installed. For example,
+exist; if they do not, and the USER-OMP package is installed and an omp version
+exists, that style will be used. For example, in the case the USER-OMP package
+is installed,
kspace_style pppm/intel 1e-4
@@ -31,5 +32,8 @@ because no pppm style has been implemented for the Intel package.
-----------------------------------------------------------------------------
-In order to use offload to Xeon Phi, the flag -DLMP_INTEL_OFFLOAD should be
-set in the Makefile. Offload requires the use of Intel compilers.
+In order to use offload to Intel(R) Xeon Phi(TM) coprocessors, the flag
+-DLMP_INTEL_OFFLOAD should be set in the Makefile. Offload requires the use of
+Intel compilers.
+
+
From 6809f93138d329b7bdfe51ff3d732f1d5dc5f672 Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 14:53:05 +0000
Subject: [PATCH 06/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12345
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
src/USER-INTEL/README | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/USER-INTEL/README b/src/USER-INTEL/README
index d70dd45293..27c60d237a 100644
--- a/src/USER-INTEL/README
+++ b/src/USER-INTEL/README
@@ -36,4 +36,10 @@ In order to use offload to Intel(R) Xeon Phi(TM) coprocessors, the flag
-DLMP_INTEL_OFFLOAD should be set in the Makefile. Offload requires the use of
Intel compilers.
+-----------------------------------------------------------------------------
+
+The files in this package must be compiled with the Intel C++
+compiler, i.e. icc/icpc.
+
+
From 6e78f83b3de9b7860c208ced3392c0a02c63f79a Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 14:54:37 +0000
Subject: [PATCH 07/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12346
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
doc/Section_accelerate.html | 4 ++++
doc/Section_accelerate.txt | 4 ++++
2 files changed, 8 insertions(+)
diff --git a/doc/Section_accelerate.html b/doc/Section_accelerate.html
index 8ee4f4331d..88d03984b3 100644
--- a/doc/Section_accelerate.html
+++ b/doc/Section_accelerate.html
@@ -1004,6 +1004,10 @@ flags to enable OpenMP support (-openmp) to both the CCFLAGS and
LINKFLAGS variables. You also need to add -DLAMMPS_MEMALIGN=64 and
-restrict to CCFLAGS.
+Note that currently you must use the Intel C++ compiler (icc/icpc) to
+build the package. In the future, using other compilers (e.g. g++)
+may be possible.
+
If you are compiling on the same architecture that will be used for
the runs, adding the flag -xHost will enable vectorization with the
Intel(R) compiler. In order to build with support for an Intel(R)
diff --git a/doc/Section_accelerate.txt b/doc/Section_accelerate.txt
index 04481007c0..4e4984a680 100644
--- a/doc/Section_accelerate.txt
+++ b/doc/Section_accelerate.txt
@@ -1000,6 +1000,10 @@ flags to enable OpenMP support ({-openmp}) to both the CCFLAGS and
LINKFLAGS variables. You also need to add -DLAMMPS_MEMALIGN=64 and
-restrict to CCFLAGS.
+Note that currently you must use the Intel C++ compiler (icc/icpc) to
+build the package. In the future, using other compilers (e.g. g++)
+may be possible.
+
If you are compiling on the same architecture that will be used for
the runs, adding the flag {-xHost} will enable vectorization with the
Intel(R) compiler. In order to build with support for an Intel(R)
From 508ea4a57533ad334680b4f8ca3f7bb308ea09f0 Mon Sep 17 00:00:00 2001
From: athomps
Date: Mon, 25 Aug 2014 15:19:26 +0000
Subject: [PATCH 08/11] Added Steve's suggestions
git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@12347 f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
doc/fix_langevin.html | 10 +++++++++-
doc/fix_langevin.txt | 10 +++++++++-
2 files changed, 18 insertions(+), 2 deletions(-)
diff --git a/doc/fix_langevin.html b/doc/fix_langevin.html
index 4bcfc831c1..bc35b2181f 100644
--- a/doc/fix_langevin.html
+++ b/doc/fix_langevin.html
@@ -253,7 +253,15 @@ not exactly conjugate to the positions. As a result the temperature
(computed from the discretized velocities) will be systematically
lower than the target temperature, by a small amount which grows with
the timestep. Nonetheless, the distribution of atom positions will
-still be consistent with the target temperature.
+still be consistent with the target temperature. For molecules containing
+C-H bonds, configurational properties generated with dt = 2.5 fs and
+tdamp = 100 fs are indistinguishable from dt = 0.5 fs.
+Because the velocity distribution systematically decreases with increasing
+timestep, the method should not be used to
+generate properties that depend on the velocity distribution, such as
+the velocity autocorrelation function (VACF). In the above example, the
+velocity distribution at dt = 2.5fs generates an average temperature of 220 K,
+instead of 300 K.
diff --git a/doc/fix_langevin.txt b/doc/fix_langevin.txt
index 8173956b04..6e129c358e 100644
--- a/doc/fix_langevin.txt
+++ b/doc/fix_langevin.txt
@@ -241,7 +241,15 @@ not exactly conjugate to the positions. As a result the temperature
(computed from the discretized velocities) will be systematically
lower than the target temperature, by a small amount which grows with
the timestep. Nonetheless, the distribution of atom positions will
-still be consistent with the target temperature.
+still be consistent with the target temperature. For molecules containing
+C-H bonds, configurational properties generated with dt = 2.5 fs and
+tdamp = 100 fs are indistinguishable from dt = 0.5 fs.
+Because the velocity distribution systematically decreases with increasing
+timestep, the method should not be used to
+generate properties that depend on the velocity distribution, such as
+the velocity autocorrelation function (VACF). In the above example, the
+velocity distribution at dt = 2.5fs generates an average temperature of 220 K,
+instead of 300 K.
:line
From 4ea728dc800718991d7ec3eb954fbede1affbc7a Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 16:01:17 +0000
Subject: [PATCH 09/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12348
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
src/KSPACE/msm.cpp | 3 +++
src/KSPACE/msm_cg.cpp | 3 +++
src/KSPACE/pppm.cpp | 4 ++++
src/KSPACE/pppm_cg.cpp | 3 +++
src/KSPACE/pppm_disp.cpp | 3 +++
src/KSPACE/pppm_disp_tip4p.cpp | 3 +++
src/KSPACE/pppm_stagger.cpp | 3 +++
src/KSPACE/pppm_tip4p.cpp | 3 +++
src/MISC/fix_gld.cpp | 12 ++++++------
src/SHOCK/fix_wall_piston.cpp | 9 +--------
src/USER-OMP/pppm_disp_omp.cpp | 3 +++
src/comm_tiled.cpp | 6 ++----
src/compute_temp_partial.cpp | 6 +++---
src/compute_temp_profile.cpp | 30 +++++++++++++++---------------
src/compute_temp_ramp.cpp | 24 ++++++++++++------------
src/delete_bonds.cpp | 3 ++-
src/rcb.cpp | 2 --
src/read_restart.cpp | 5 ++++-
18 files changed, 73 insertions(+), 52 deletions(-)
diff --git a/src/KSPACE/msm.cpp b/src/KSPACE/msm.cpp
index 81dbc98b47..bdbe80c67f 100644
--- a/src/KSPACE/msm.cpp
+++ b/src/KSPACE/msm.cpp
@@ -1428,6 +1428,9 @@ void MSM::particle_map()
int flag = 0;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
for (int i = 0; i < nlocal; i++) {
// (nx,ny,nz) = global coords of grid pt to "lower left" of charge
diff --git a/src/KSPACE/msm_cg.cpp b/src/KSPACE/msm_cg.cpp
index e1f1262c9f..07177324dc 100644
--- a/src/KSPACE/msm_cg.cpp
+++ b/src/KSPACE/msm_cg.cpp
@@ -309,6 +309,9 @@ void MSMCG::particle_map()
int flag = 0;
int i;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
for (int j = 0; j < num_charged; j++) {
i = is_charged[j];
diff --git a/src/KSPACE/pppm.cpp b/src/KSPACE/pppm.cpp
index a5697910c4..faa6b9a248 100644
--- a/src/KSPACE/pppm.cpp
+++ b/src/KSPACE/pppm.cpp
@@ -1875,6 +1875,10 @@ void PPPM::particle_map()
int nlocal = atom->nlocal;
int flag = 0;
+
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
for (int i = 0; i < nlocal; i++) {
// (nx,ny,nz) = global coords of grid pt to "lower left" of charge
diff --git a/src/KSPACE/pppm_cg.cpp b/src/KSPACE/pppm_cg.cpp
index d071c3993a..9651ac7aa6 100644
--- a/src/KSPACE/pppm_cg.cpp
+++ b/src/KSPACE/pppm_cg.cpp
@@ -282,6 +282,9 @@ void PPPMCG::particle_map()
double **x = atom->x;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
int flag = 0;
for (int j = 0; j < num_charged; j++) {
int i = is_charged[j];
diff --git a/src/KSPACE/pppm_disp.cpp b/src/KSPACE/pppm_disp.cpp
index 1dfea3bf77..d565ce00cf 100755
--- a/src/KSPACE/pppm_disp.cpp
+++ b/src/KSPACE/pppm_disp.cpp
@@ -4209,6 +4209,9 @@ void PPPMDisp::particle_map(double delx, double dely, double delz,
double **x = atom->x;
int nlocal = atom->nlocal;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
int flag = 0;
for (int i = 0; i < nlocal; i++) {
diff --git a/src/KSPACE/pppm_disp_tip4p.cpp b/src/KSPACE/pppm_disp_tip4p.cpp
index 0875c881d6..aa4f3607c6 100755
--- a/src/KSPACE/pppm_disp_tip4p.cpp
+++ b/src/KSPACE/pppm_disp_tip4p.cpp
@@ -78,6 +78,9 @@ void PPPMDispTIP4P::particle_map_c(double delx, double dely, double delz,
double **x = atom->x;
int nlocal = atom->nlocal;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
int flag = 0;
for (int i = 0; i < nlocal; i++) {
if (type[i] == typeO) {
diff --git a/src/KSPACE/pppm_stagger.cpp b/src/KSPACE/pppm_stagger.cpp
index 3863f41f89..62db9d6441 100755
--- a/src/KSPACE/pppm_stagger.cpp
+++ b/src/KSPACE/pppm_stagger.cpp
@@ -679,6 +679,9 @@ void PPPMStagger::particle_map()
double **x = atom->x;
int nlocal = atom->nlocal;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
int flag = 0;
for (int i = 0; i < nlocal; i++) {
diff --git a/src/KSPACE/pppm_tip4p.cpp b/src/KSPACE/pppm_tip4p.cpp
index decdb1bad4..4345786339 100644
--- a/src/KSPACE/pppm_tip4p.cpp
+++ b/src/KSPACE/pppm_tip4p.cpp
@@ -73,6 +73,9 @@ void PPPMTIP4P::particle_map()
double **x = atom->x;
int nlocal = atom->nlocal;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
int flag = 0;
for (int i = 0; i < nlocal; i++) {
if (type[i] == typeO) {
diff --git a/src/MISC/fix_gld.cpp b/src/MISC/fix_gld.cpp
index 66944502f7..998d7f4ebe 100644
--- a/src/MISC/fix_gld.cpp
+++ b/src/MISC/fix_gld.cpp
@@ -57,16 +57,16 @@ FixGLD::FixGLD(LAMMPS *lmp, int narg, char **arg) :
// 1 = Group ID (e.g., all)
// 2 = gld (name of this fix)
// 3 = t_start (Starting target temperature)
- t_start = atof(arg[3]);
+ t_start = force->numeric(FLERR,arg[3]);
// 4 = t_stop (Stopping target temperature)
- t_stop = atof(arg[4]);
+ t_stop = force->numeric(FLERR,arg[4]);
// 5 = prony_terms (number of terms in Prony series)
- prony_terms = atoi(arg[5]);
+ prony_terms = force->inumeric(FLERR,arg[5]);
// 6 = seed (random seed)
- int seed = atoi(arg[6]);
+ int seed = force->inumeric(FLERR,arg[6]);
// 7 = series type
if(strcmp(arg[7],"pprony") == 0) {
@@ -101,8 +101,8 @@ FixGLD::FixGLD(LAMMPS *lmp, int narg, char **arg) :
int iarg = narg_min;
int icoeff = 0;
while (iarg < narg && icoeff < prony_terms) {
- double pc = atof(arg[iarg]);
- double ptau = atof(arg[iarg+1]);
+ double pc = force->numeric(FLERR,arg[iarg]);
+ double ptau = force->numeric(FLERR,arg[iarg+1]);
if (pc < 0)
error->all(FLERR,"Fix gld c coefficients must be >= 0");
diff --git a/src/SHOCK/fix_wall_piston.cpp b/src/SHOCK/fix_wall_piston.cpp
index 25c3b6dd3c..2f908bccb4 100644
--- a/src/SHOCK/fix_wall_piston.cpp
+++ b/src/SHOCK/fix_wall_piston.cpp
@@ -135,14 +135,7 @@ FixWallPiston::FixWallPiston(LAMMPS *lmp, int narg, char **arg) :
// setup scaling
- double xscale,yscale,zscale;
- if (scaleflag) {
- xscale = domain->lattice->xlattice;
- yscale = domain->lattice->ylattice;
- zscale = domain->lattice->zlattice;
- }
- else xscale = yscale = zscale = 1.0;
-
+ const double zscale = (scaleflag) ? domain->lattice->zlattice : 1.0;
vz *= zscale;
z0 *= zscale;
roughdist *= zscale;
diff --git a/src/USER-OMP/pppm_disp_omp.cpp b/src/USER-OMP/pppm_disp_omp.cpp
index 21ba45e91d..b22b553341 100644
--- a/src/USER-OMP/pppm_disp_omp.cpp
+++ b/src/USER-OMP/pppm_disp_omp.cpp
@@ -354,6 +354,9 @@ void PPPMDispOMP::particle_map(double dxinv, double dyinv,
const int nyhi_out = nyhi_o;
const int nzhi_out = nzhi_o;
+ if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
+ error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+
int i, flag = 0;
#if defined(_OPENMP)
#pragma omp parallel for private(i) default(none) reduction(+:flag) schedule(static)
diff --git a/src/comm_tiled.cpp b/src/comm_tiled.cpp
index 71b169eaaf..816ab5e959 100644
--- a/src/comm_tiled.cpp
+++ b/src/comm_tiled.cpp
@@ -775,11 +775,10 @@ void CommTiled::exchange()
void CommTiled::borders()
{
- int i,m,n,irecv,nlast,nsend,nrecv,ngroup,ncount,ncountall;
+ int i,m,n,nlast,nsend,nrecv,ngroup,ncount,ncountall;
double xlo,xhi,ylo,yhi,zlo,zhi;
double *bbox;
double **x;
- MPI_Status status;
AtomVec *avec = atom->avec;
// send/recv max one = max # of atoms in single send/recv for any swap
@@ -1371,7 +1370,7 @@ void CommTiled::reverse_comm_dump(Dump *dump)
void CommTiled::forward_comm_array(int nsize, double **array)
{
- int i,j,k,m,n,iatom,last,irecv,nsend,nrecv;
+ int i,j,k,m,iatom,last,irecv,nsend,nrecv;
MPI_Status status;
// insure send/recv bufs are big enough for nsize
@@ -1732,7 +1731,6 @@ int CommTiled::point_drop_tiled(int idim, double *x)
if (!done) proc = point_drop_tiled_recurse(xnew,0,nprocs-1);
}
} else if (idim == 1) {
- int done = 1;
if (rcbinfo[proc].mysplit[2][0] == rcbinfo[me].mysplit[2][1]) {
xnew[2] -= EPSILON * (subhi[2]-sublo[2]);
proc = point_drop_tiled_recurse(xnew,0,nprocs-1);
diff --git a/src/compute_temp_partial.cpp b/src/compute_temp_partial.cpp
index baa316e847..4fcb27dd45 100644
--- a/src/compute_temp_partial.cpp
+++ b/src/compute_temp_partial.cpp
@@ -38,9 +38,9 @@ ComputeTempPartial::ComputeTempPartial(LAMMPS *lmp, int narg, char **arg) :
tempflag = 1;
tempbias = 1;
- xflag = atoi(arg[3]);
- yflag = atoi(arg[4]);
- zflag = atoi(arg[5]);
+ xflag = force->inumeric(FLERR,arg[3]);
+ yflag = force->inumeric(FLERR,arg[4]);
+ zflag = force->inumeric(FLERR,arg[5]);
if (zflag && domain->dimension == 2)
error->all(FLERR,"Compute temp/partial cannot use vz for 2d systemx");
diff --git a/src/compute_temp_profile.cpp b/src/compute_temp_profile.cpp
index 268162a463..d1e107a822 100644
--- a/src/compute_temp_profile.cpp
+++ b/src/compute_temp_profile.cpp
@@ -41,9 +41,9 @@ ComputeTempProfile::ComputeTempProfile(LAMMPS *lmp, int narg, char **arg) :
tempflag = 1;
tempbias = 1;
- xflag = atoi(arg[3]);
- yflag = atoi(arg[4]);
- zflag = atoi(arg[5]);
+ xflag = force->inumeric(FLERR,arg[3]);
+ yflag = force->inumeric(FLERR,arg[4]);
+ zflag = force->inumeric(FLERR,arg[5]);
if (zflag && domain->dimension == 2)
error->all(FLERR,"Compute temp/profile cannot use vz for 2d systemx");
@@ -59,44 +59,44 @@ ComputeTempProfile::ComputeTempProfile(LAMMPS *lmp, int narg, char **arg) :
int iarg = 6;
if (strcmp(arg[iarg],"x") == 0) {
if (iarg+2 > narg) error->all(FLERR,"Illegal compute temp/profile command");
- nbinx = atoi(arg[iarg+1]);
+ nbinx = force->inumeric(FLERR,arg[iarg+1]);
iarg += 2;
} else if (strcmp(arg[iarg],"y") == 0) {
if (iarg+2 > narg) error->all(FLERR,"Illegal compute temp/profile command");
- nbiny = atoi(arg[iarg+1]);
+ nbiny = force->inumeric(FLERR,arg[iarg+1]);
iarg += 2;
} else if (strcmp(arg[iarg],"z") == 0) {
if (iarg+2 > narg) error->all(FLERR,"Illegal compute temp/profile command");
if (domain->dimension == 2)
error->all(FLERR,"Compute temp/profile cannot bin z for 2d systems");
- nbinz = atoi(arg[iarg+1]);
+ nbinz = force->inumeric(FLERR,arg[iarg+1]);
iarg += 2;
} else if (strcmp(arg[iarg],"xy") == 0) {
if (iarg+3 > narg) error->all(FLERR,"Illegal compute temp/profile command");
- nbinx = atoi(arg[iarg+1]);
- nbiny = atoi(arg[iarg+2]);
+ nbinx = force->inumeric(FLERR,arg[iarg+1]);
+ nbiny = force->inumeric(FLERR,arg[iarg+2]);
iarg += 3;
} else if (strcmp(arg[iarg],"yz") == 0) {
if (iarg+3 > narg) error->all(FLERR,"Illegal compute temp/profile command");
if (domain->dimension == 2)
error->all(FLERR,"Compute temp/profile cannot bin z for 2d systems");
- nbiny = atoi(arg[iarg+1]);
- nbinz = atoi(arg[iarg+2]);
+ nbiny = force->inumeric(FLERR,arg[iarg+1]);
+ nbinz = force->inumeric(FLERR,arg[iarg+2]);
iarg += 3;
} else if (strcmp(arg[iarg],"xz") == 0) {
if (iarg+3 > narg) error->all(FLERR,"Illegal compute temp/profile command");
if (domain->dimension == 2)
error->all(FLERR,"Compute temp/profile cannot bin z for 2d systems");
- nbinx = atoi(arg[iarg+1]);
- nbinz = atoi(arg[iarg+2]);
+ nbinx = force->inumeric(FLERR,arg[iarg+1]);
+ nbinz = force->inumeric(FLERR,arg[iarg+2]);
iarg += 3;
} else if (strcmp(arg[iarg],"xyz") == 0) {
if (iarg+4 > narg) error->all(FLERR,"Illegal compute temp/profile command");
if (domain->dimension == 2)
error->all(FLERR,"Compute temp/profile cannot bin z for 2d systems");
- nbinx = atoi(arg[iarg+1]);
- nbiny = atoi(arg[iarg+2]);
- nbinz = atoi(arg[iarg+3]);
+ nbinx = force->inumeric(FLERR,arg[iarg+1]);
+ nbiny = force->inumeric(FLERR,arg[iarg+2]);
+ nbinz = force->inumeric(FLERR,arg[iarg+3]);
iarg += 4;
} else error->all(FLERR,"Illegal compute temp/profile command");
diff --git a/src/compute_temp_ramp.cpp b/src/compute_temp_ramp.cpp
index 288bc30abe..33a89229f8 100644
--- a/src/compute_temp_ramp.cpp
+++ b/src/compute_temp_ramp.cpp
@@ -74,14 +74,14 @@ ComputeTempRamp::ComputeTempRamp(LAMMPS *lmp, int narg, char **arg) :
else error->all(FLERR,"Illegal compute temp/ramp command");
if (v_dim == 0) {
- v_lo = xscale*atof(arg[4]);
- v_hi = xscale*atof(arg[5]);
+ v_lo = xscale*force->numeric(FLERR,arg[4]);
+ v_hi = xscale*force->numeric(FLERR,arg[5]);
} else if (v_dim == 1) {
- v_lo = yscale*atof(arg[4]);
- v_hi = yscale*atof(arg[5]);
+ v_lo = yscale*force->numeric(FLERR,arg[4]);
+ v_hi = yscale*force->numeric(FLERR,arg[5]);
} else if (v_dim == 2) {
- v_lo = zscale*atof(arg[4]);
- v_hi = zscale*atof(arg[5]);
+ v_lo = zscale*force->numeric(FLERR,arg[4]);
+ v_hi = zscale*force->numeric(FLERR,arg[5]);
}
if (strcmp(arg[6],"x") == 0) coord_dim = 0;
@@ -90,14 +90,14 @@ ComputeTempRamp::ComputeTempRamp(LAMMPS *lmp, int narg, char **arg) :
else error->all(FLERR,"Illegal compute temp/ramp command");
if (coord_dim == 0) {
- coord_lo = xscale*atof(arg[7]);
- coord_hi = xscale*atof(arg[8]);
+ coord_lo = xscale*force->numeric(FLERR,arg[7]);
+ coord_hi = xscale*force->numeric(FLERR,arg[8]);
} else if (coord_dim == 1) {
- coord_lo = yscale*atof(arg[7]);
- coord_hi = yscale*atof(arg[8]);
+ coord_lo = yscale*force->numeric(FLERR,arg[7]);
+ coord_hi = yscale*force->numeric(FLERR,arg[8]);
} else if (coord_dim == 2) {
- coord_lo = zscale*atof(arg[7]);
- coord_hi = zscale*atof(arg[8]);
+ coord_lo = zscale*force->numeric(FLERR,arg[7]);
+ coord_hi = zscale*force->numeric(FLERR,arg[8]);
}
maxbias = 0;
diff --git a/src/delete_bonds.cpp b/src/delete_bonds.cpp
index b380508ee9..6ed4d211d1 100644
--- a/src/delete_bonds.cpp
+++ b/src/delete_bonds.cpp
@@ -25,6 +25,8 @@
#include "special.h"
#include "error.h"
+#include
+
using namespace LAMMPS_NS;
enum{MULTI,ATOM,BOND,ANGLE,DIHEDRAL,IMPROPER,STATS};
@@ -80,7 +82,6 @@ void DeleteBonds::command(int narg, char **arg)
int *tlist = NULL;
int iarg = 2;
- int which;
if (style != MULTI && style != STATS) {
if (narg < 3) error->all(FLERR,"Illegal delete_bonds command");
diff --git a/src/rcb.cpp b/src/rcb.cpp
index 61cb44bd3f..d46766e45b 100644
--- a/src/rcb.cpp
+++ b/src/rcb.cpp
@@ -176,7 +176,6 @@ void RCB::compute(int dimension, int n, double **x, double *wt,
// procmid = 1st proc in upper half of partition
int procpartner,procpartner2;
- int readnumber;
int procmid;
int proclower = 0;
@@ -656,7 +655,6 @@ void median_merge(void *in, void *inout, int *len, MPI_Datatype *dptr)
void RCB::invert(int sortflag)
{
- Invert *sbuf,*rbuf;
// only create Irregular if not previously created
// allows Irregular to persist for multiple RCB calls by fix balance
diff --git a/src/read_restart.cpp b/src/read_restart.cpp
index 441ecbfcd2..d49c271ac9 100644
--- a/src/read_restart.cpp
+++ b/src/read_restart.cpp
@@ -459,7 +459,10 @@ void ReadRestart::command(int narg, char **arg)
// in case read by different proc than wrote restart file
// first do map_init() since irregular->migrate_atoms() will do map_clear()
- if (atom->map_style) atom->map_init();
+ if (atom->map_style) {
+ atom->map_init();
+ atom->map_set();
+ }
if (domain->triclinic) domain->x2lamda(atom->nlocal);
Irregular *irregular = new Irregular(lmp);
irregular->migrate_atoms(1);
From 80b02160f1ebaa3b26d77427c10ddb890fe16505 Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 16:47:19 +0000
Subject: [PATCH 10/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12349
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
src/delete_bonds.cpp | 2 --
1 file changed, 2 deletions(-)
diff --git a/src/delete_bonds.cpp b/src/delete_bonds.cpp
index 6ed4d211d1..c4823cc01b 100644
--- a/src/delete_bonds.cpp
+++ b/src/delete_bonds.cpp
@@ -25,8 +25,6 @@
#include "special.h"
#include "error.h"
-#include
-
using namespace LAMMPS_NS;
enum{MULTI,ATOM,BOND,ANGLE,DIHEDRAL,IMPROPER,STATS};
From b74fcc80ac13880ddd164c049797402b363d6d10 Mon Sep 17 00:00:00 2001
From: sjplimp
Date: Mon, 25 Aug 2014 16:49:25 +0000
Subject: [PATCH 11/11] git-svn-id:
svn://svn.icms.temple.edu/lammps-ro/trunk@12350
f3b2605a-c512-4ea7-a41b-209d697bcdaa
---
src/KSPACE/msm.cpp | 2 +-
src/KSPACE/msm_cg.cpp | 2 +-
src/KSPACE/pppm.cpp | 2 +-
src/KSPACE/pppm_cg.cpp | 2 +-
src/KSPACE/pppm_disp.cpp | 2 +-
src/KSPACE/pppm_disp_tip4p.cpp | 2 +-
src/KSPACE/pppm_stagger.cpp | 2 +-
src/KSPACE/pppm_tip4p.cpp | 2 +-
8 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/src/KSPACE/msm.cpp b/src/KSPACE/msm.cpp
index bdbe80c67f..9ba0c58191 100644
--- a/src/KSPACE/msm.cpp
+++ b/src/KSPACE/msm.cpp
@@ -1429,7 +1429,7 @@ void MSM::particle_map()
int flag = 0;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
for (int i = 0; i < nlocal; i++) {
diff --git a/src/KSPACE/msm_cg.cpp b/src/KSPACE/msm_cg.cpp
index 07177324dc..5e351cfcf2 100644
--- a/src/KSPACE/msm_cg.cpp
+++ b/src/KSPACE/msm_cg.cpp
@@ -310,7 +310,7 @@ void MSMCG::particle_map()
int i;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
for (int j = 0; j < num_charged; j++) {
i = is_charged[j];
diff --git a/src/KSPACE/pppm.cpp b/src/KSPACE/pppm.cpp
index faa6b9a248..a2672ca7b7 100644
--- a/src/KSPACE/pppm.cpp
+++ b/src/KSPACE/pppm.cpp
@@ -1877,7 +1877,7 @@ void PPPM::particle_map()
int flag = 0;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
for (int i = 0; i < nlocal; i++) {
diff --git a/src/KSPACE/pppm_cg.cpp b/src/KSPACE/pppm_cg.cpp
index 9651ac7aa6..be84a5fc0b 100644
--- a/src/KSPACE/pppm_cg.cpp
+++ b/src/KSPACE/pppm_cg.cpp
@@ -283,7 +283,7 @@ void PPPMCG::particle_map()
double **x = atom->x;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
int flag = 0;
for (int j = 0; j < num_charged; j++) {
diff --git a/src/KSPACE/pppm_disp.cpp b/src/KSPACE/pppm_disp.cpp
index d565ce00cf..37fa0b46f6 100755
--- a/src/KSPACE/pppm_disp.cpp
+++ b/src/KSPACE/pppm_disp.cpp
@@ -4210,7 +4210,7 @@ void PPPMDisp::particle_map(double delx, double dely, double delz,
int nlocal = atom->nlocal;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
int flag = 0;
for (int i = 0; i < nlocal; i++) {
diff --git a/src/KSPACE/pppm_disp_tip4p.cpp b/src/KSPACE/pppm_disp_tip4p.cpp
index aa4f3607c6..c021e3dcc0 100755
--- a/src/KSPACE/pppm_disp_tip4p.cpp
+++ b/src/KSPACE/pppm_disp_tip4p.cpp
@@ -79,7 +79,7 @@ void PPPMDispTIP4P::particle_map_c(double delx, double dely, double delz,
int nlocal = atom->nlocal;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
int flag = 0;
for (int i = 0; i < nlocal; i++) {
diff --git a/src/KSPACE/pppm_stagger.cpp b/src/KSPACE/pppm_stagger.cpp
index 62db9d6441..f0ee7e10dc 100755
--- a/src/KSPACE/pppm_stagger.cpp
+++ b/src/KSPACE/pppm_stagger.cpp
@@ -680,7 +680,7 @@ void PPPMStagger::particle_map()
int nlocal = atom->nlocal;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
int flag = 0;
for (int i = 0; i < nlocal; i++) {
diff --git a/src/KSPACE/pppm_tip4p.cpp b/src/KSPACE/pppm_tip4p.cpp
index 4345786339..f3c6d3c9a4 100644
--- a/src/KSPACE/pppm_tip4p.cpp
+++ b/src/KSPACE/pppm_tip4p.cpp
@@ -74,7 +74,7 @@ void PPPMTIP4P::particle_map()
int nlocal = atom->nlocal;
if (!isfinite(boxlo[0]) || !isfinite(boxlo[1]) || !isfinite(boxlo[2]))
- error->one(FLERR,"Non-numeric box dimensions. Simulation unstable.");
+ error->one(FLERR,"Non-numeric box dimensions - simulation unstable");
int flag = 0;
for (int i = 0; i < nlocal; i++) {