From ff36bad09964fecad2b6569fef6992b164e9b56d Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 00:33:48 -0400 Subject: [PATCH 01/79] cleanup includes in variable.h --- src/variable.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/variable.h b/src/variable.h index 512195bd14..c5f501f266 100644 --- a/src/variable.h +++ b/src/variable.h @@ -14,9 +14,8 @@ #ifndef LMP_VARIABLE_H #define LMP_VARIABLE_H -#include +#include #include "pointers.h" -#include "input.h" namespace LAMMPS_NS { From f7507512b131e2c515db82751b1a793de66aa657 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 00:39:47 -0400 Subject: [PATCH 02/79] apply memory alignment settings from my_page.h to my_pool_chunk.h --- src/my_pool_chunk.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/my_pool_chunk.h b/src/my_pool_chunk.h index 8bf88d35bb..a313e45f05 100644 --- a/src/my_pool_chunk.h +++ b/src/my_pool_chunk.h @@ -43,6 +43,10 @@ public variables: #ifndef LAMMPS_MY_POOL_CHUNK_H #define LAMMPS_MY_POOL_CHUNK_H +#if defined(LMP_USER_INTEL) && !defined(LAMMPS_MEMALIGN) && !defined(_WIN32) +#define LAMMPS_MEMALIGN 64 +#endif + #include namespace LAMMPS_NS { @@ -190,9 +194,17 @@ class MyPoolChunk { for (int i = oldpage; i < npage; i++) { whichbin[i] = ibin; +#if defined(LAMMPS_MEMALIGN) + void *ptr; + if (posix_memalign(&ptr, LAMMPS_MEMALIGN, + chunkperpage*chunksize[ibin]*sizeof(T))) + errorflag = 2; + pages[i] = (T *) ptr; +#else pages[i] = (T *) malloc(chunkperpage*chunksize[ibin]*sizeof(T)); size += chunkperpage*chunksize[ibin]; if (!pages[i]) errorflag = 2; +#endif } // reset free list for unused chunks on new pages From 17602b4c26fa94e02e204b3e8e85a48cecc65569 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 01:02:17 -0400 Subject: [PATCH 03/79] some more include file cleanup. include cstdlib where functions like atoi() are used remove unneeded include statements from headers --- src/PYTHON/python_impl.cpp | 1 + src/USER-MEAMC/meam.h | 1 - src/compute_reduce_chunk.cpp | 3 ++- src/fix_vector.cpp | 1 + src/lammps.cpp | 1 + src/variable.cpp | 1 + 6 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/PYTHON/python_impl.cpp b/src/PYTHON/python_impl.cpp index aaa4f74c69..9c650330af 100644 --- a/src/PYTHON/python_impl.cpp +++ b/src/PYTHON/python_impl.cpp @@ -15,6 +15,7 @@ Contributing author: Richard Berger and Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include #include #include "lmppython.h" #include "force.h" diff --git a/src/USER-MEAMC/meam.h b/src/USER-MEAMC/meam.h index 42fd722e01..bb40202243 100644 --- a/src/USER-MEAMC/meam.h +++ b/src/USER-MEAMC/meam.h @@ -3,7 +3,6 @@ #include "memory.h" #include -#include #define maxelt 5 diff --git a/src/compute_reduce_chunk.cpp b/src/compute_reduce_chunk.cpp index f31672ef74..5eda71b21b 100644 --- a/src/compute_reduce_chunk.cpp +++ b/src/compute_reduce_chunk.cpp @@ -12,7 +12,8 @@ ------------------------------------------------------------------------- */ #include -#include +#include +#include #include "compute_reduce_chunk.h" #include "atom.h" #include "update.h" diff --git a/src/fix_vector.cpp b/src/fix_vector.cpp index 6387af7676..5657e59ab0 100644 --- a/src/fix_vector.cpp +++ b/src/fix_vector.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "fix_vector.h" #include "update.h" diff --git a/src/lammps.cpp b/src/lammps.cpp index f8d04c9323..320d89ed52 100644 --- a/src/lammps.cpp +++ b/src/lammps.cpp @@ -13,6 +13,7 @@ #include #include +#include #include #include #include diff --git a/src/variable.cpp b/src/variable.cpp index ea7f3044d7..1416754073 100644 --- a/src/variable.cpp +++ b/src/variable.cpp @@ -26,6 +26,7 @@ #include "region.h" #include "modify.h" #include "compute.h" +#include "input.h" #include "fix.h" #include "fix_store.h" #include "force.h" From 08ac695a062079390a47d7115e10428493c5cf75 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 01:03:08 -0400 Subject: [PATCH 04/79] move include statements from headers to implementation files where possible in USER-REAXC --- src/USER-OMP/reaxc_multi_body_omp.cpp | 1 + src/USER-REAXC/pair_reaxc.cpp | 1 + src/USER-REAXC/reaxc_control.cpp | 2 ++ src/USER-REAXC/reaxc_ffield.cpp | 2 ++ src/USER-REAXC/reaxc_forces.cpp | 1 + src/USER-REAXC/reaxc_init_md.cpp | 1 + src/USER-REAXC/reaxc_io_tools.cpp | 3 ++- src/USER-REAXC/reaxc_multi_body.cpp | 1 + src/USER-REAXC/reaxc_reset_tools.cpp | 1 + src/USER-REAXC/reaxc_tool_box.cpp | 5 +++++ src/USER-REAXC/reaxc_traj.cpp | 1 + src/USER-REAXC/reaxc_types.h | 10 +--------- 12 files changed, 19 insertions(+), 10 deletions(-) diff --git a/src/USER-OMP/reaxc_multi_body_omp.cpp b/src/USER-OMP/reaxc_multi_body_omp.cpp index 7552e7a733..d791f945a8 100644 --- a/src/USER-OMP/reaxc_multi_body_omp.cpp +++ b/src/USER-OMP/reaxc_multi_body_omp.cpp @@ -26,6 +26,7 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc_omp.h" #include "thr_data.h" diff --git a/src/USER-REAXC/pair_reaxc.cpp b/src/USER-REAXC/pair_reaxc.cpp index 8f8dcfb8fc..224f3e2568 100644 --- a/src/USER-REAXC/pair_reaxc.cpp +++ b/src/USER-REAXC/pair_reaxc.cpp @@ -20,6 +20,7 @@ Hybrid and hybrid/overlay compatibility added by Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include #include "pair_reaxc.h" #include "atom.h" #include "update.h" diff --git a/src/USER-REAXC/reaxc_control.cpp b/src/USER-REAXC/reaxc_control.cpp index 535226fff8..060c1a0342 100644 --- a/src/USER-REAXC/reaxc_control.cpp +++ b/src/USER-REAXC/reaxc_control.cpp @@ -24,6 +24,8 @@ . ----------------------------------------------------------------------*/ +#include +#include #include "pair_reaxc.h" #include "reaxc_control.h" #include "reaxc_tool_box.h" diff --git a/src/USER-REAXC/reaxc_ffield.cpp b/src/USER-REAXC/reaxc_ffield.cpp index 9534637645..2160d180cf 100644 --- a/src/USER-REAXC/reaxc_ffield.cpp +++ b/src/USER-REAXC/reaxc_ffield.cpp @@ -24,6 +24,8 @@ . ----------------------------------------------------------------------*/ +#include +#include #include "pair_reaxc.h" #include "error.h" #include "reaxc_ffield.h" diff --git a/src/USER-REAXC/reaxc_forces.cpp b/src/USER-REAXC/reaxc_forces.cpp index 186cde681a..79094ece43 100644 --- a/src/USER-REAXC/reaxc_forces.cpp +++ b/src/USER-REAXC/reaxc_forces.cpp @@ -24,6 +24,7 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc.h" #include "reaxc_forces.h" #include "reaxc_bond_orders.h" diff --git a/src/USER-REAXC/reaxc_init_md.cpp b/src/USER-REAXC/reaxc_init_md.cpp index df5de49034..a0e15e98f5 100644 --- a/src/USER-REAXC/reaxc_init_md.cpp +++ b/src/USER-REAXC/reaxc_init_md.cpp @@ -24,6 +24,7 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc.h" #include "reaxc_init_md.h" #include "reaxc_allocate.h" diff --git a/src/USER-REAXC/reaxc_io_tools.cpp b/src/USER-REAXC/reaxc_io_tools.cpp index 51aa8bca0f..f4a1486c48 100644 --- a/src/USER-REAXC/reaxc_io_tools.cpp +++ b/src/USER-REAXC/reaxc_io_tools.cpp @@ -24,6 +24,7 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc.h" #include "update.h" #include "reaxc_io_tools.h" @@ -85,7 +86,7 @@ int Init_Output_Files( reax_system *system, control_params *control, /************************ close output files ************************/ -int Close_Output_Files( reax_system *system, control_params *control, +int Close_Output_Files( reax_system *system, control_params * /* control */, output_controls *out_control, mpi_datatypes * /*mpi_data*/ ) { if (out_control->write_steps > 0) diff --git a/src/USER-REAXC/reaxc_multi_body.cpp b/src/USER-REAXC/reaxc_multi_body.cpp index f7d72a2678..371b8ed65e 100644 --- a/src/USER-REAXC/reaxc_multi_body.cpp +++ b/src/USER-REAXC/reaxc_multi_body.cpp @@ -24,6 +24,7 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc.h" #include "reaxc_multi_body.h" #include "reaxc_bond_orders.h" diff --git a/src/USER-REAXC/reaxc_reset_tools.cpp b/src/USER-REAXC/reaxc_reset_tools.cpp index e00656694c..c72ccbadcd 100644 --- a/src/USER-REAXC/reaxc_reset_tools.cpp +++ b/src/USER-REAXC/reaxc_reset_tools.cpp @@ -24,6 +24,7 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc.h" #include "reaxc_reset_tools.h" #include "reaxc_list.h" diff --git a/src/USER-REAXC/reaxc_tool_box.cpp b/src/USER-REAXC/reaxc_tool_box.cpp index ffe42e37bb..2cf66d8655 100644 --- a/src/USER-REAXC/reaxc_tool_box.cpp +++ b/src/USER-REAXC/reaxc_tool_box.cpp @@ -24,9 +24,14 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc.h" #include "reaxc_tool_box.h" +#if !defined(_MSC_VER) +#include +#endif + #include "error.h" struct timeval tim; diff --git a/src/USER-REAXC/reaxc_traj.cpp b/src/USER-REAXC/reaxc_traj.cpp index 356d7b6eeb..a536445113 100644 --- a/src/USER-REAXC/reaxc_traj.cpp +++ b/src/USER-REAXC/reaxc_traj.cpp @@ -24,6 +24,7 @@ . ----------------------------------------------------------------------*/ +#include #include "pair_reaxc.h" #include "reaxc_traj.h" #include "reaxc_list.h" diff --git a/src/USER-REAXC/reaxc_types.h b/src/USER-REAXC/reaxc_types.h index 0821c065cc..319c373927 100644 --- a/src/USER-REAXC/reaxc_types.h +++ b/src/USER-REAXC/reaxc_types.h @@ -27,19 +27,11 @@ #ifndef __REAX_TYPES_H_ #define __REAX_TYPES_H_ -#include #include "lmptype.h" - -#include -#include +#include #include -#include -#include -#include -#include #include "accelerator_kokkos.h" - namespace LAMMPS_NS { class Error;} #if defined LMP_USER_OMP From 84e156d380519a7091f657fb89387d4b866280be Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 09:14:36 -0400 Subject: [PATCH 05/79] first batch of changes suggested by using include-what-you-use tool --- src/angle.cpp | 1 - src/angle.h | 2 +- src/angle_deprecated.cpp | 1 + src/angle_hybrid.cpp | 3 +-- src/angle_zero.cpp | 3 +-- src/bond.h | 2 +- src/compute.h | 2 +- src/dihedral.h | 2 +- src/dump.h | 2 +- src/fix.h | 2 +- src/improper.h | 2 +- src/lmptype.h | 4 ---- src/main.cpp | 3 --- src/pair.h | 2 +- src/pointers.h | 9 +++++++-- 15 files changed, 18 insertions(+), 22 deletions(-) diff --git a/src/angle.cpp b/src/angle.cpp index 2a297990ac..1b9532ea32 100644 --- a/src/angle.cpp +++ b/src/angle.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "angle.h" #include "atom.h" #include "comm.h" diff --git a/src/angle.h b/src/angle.h index 3d8371242e..6fc8a664c6 100644 --- a/src/angle.h +++ b/src/angle.h @@ -15,7 +15,7 @@ #define LMP_ANGLE_H #include -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/angle_deprecated.cpp b/src/angle_deprecated.cpp index b5af217b7b..73fcccc53a 100644 --- a/src/angle_deprecated.cpp +++ b/src/angle_deprecated.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include +#include #include "angle_deprecated.h" #include "angle_hybrid.h" #include "comm.h" diff --git a/src/angle_hybrid.cpp b/src/angle_hybrid.cpp index 6afa7413b2..47baf770a5 100644 --- a/src/angle_hybrid.cpp +++ b/src/angle_hybrid.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include #include #include "angle_hybrid.h" #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/angle_zero.cpp b/src/angle_zero.cpp index 6eb127fa58..62eab85aee 100644 --- a/src/angle_zero.cpp +++ b/src/angle_zero.cpp @@ -15,8 +15,7 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ -#include -#include +#include #include #include "angle_zero.h" #include "atom.h" diff --git a/src/bond.h b/src/bond.h index 8fb7040832..f9fb9384ed 100644 --- a/src/bond.h +++ b/src/bond.h @@ -15,7 +15,7 @@ #define LMP_BOND_H #include -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/compute.h b/src/compute.h index a023834368..38d001db6f 100644 --- a/src/compute.h +++ b/src/compute.h @@ -14,7 +14,7 @@ #ifndef LMP_COMPUTE_H #define LMP_COMPUTE_H -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/dihedral.h b/src/dihedral.h index f1b42008bf..8654132ed5 100644 --- a/src/dihedral.h +++ b/src/dihedral.h @@ -15,7 +15,7 @@ #define LMP_DIHEDRAL_H #include -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/dump.h b/src/dump.h index 1c6a131f76..d42e7f1f39 100644 --- a/src/dump.h +++ b/src/dump.h @@ -16,7 +16,7 @@ #include #include -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/fix.h b/src/fix.h index 7eaff38bd3..7e55e96269 100644 --- a/src/fix.h +++ b/src/fix.h @@ -14,7 +14,7 @@ #ifndef LMP_FIX_H #define LMP_FIX_H -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/improper.h b/src/improper.h index d940b43a13..4af5ad4a35 100644 --- a/src/improper.h +++ b/src/improper.h @@ -15,7 +15,7 @@ #define LMP_IMPROPER_H #include -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/lmptype.h b/src/lmptype.h index 12fa6cc4fb..8a596e9f83 100644 --- a/src/lmptype.h +++ b/src/lmptype.h @@ -48,10 +48,6 @@ namespace LAMMPS_NS { -// enum used for KOKKOS host/device flags - -enum ExecutionSpace{Host,Device}; - // reserve 2 hi bits in molecular system neigh list for special bonds flag // max local + ghost atoms per processor = 2^30 - 1 diff --git a/src/main.cpp b/src/main.cpp index 8eb5e4e543..1be9c253eb 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -14,9 +14,6 @@ #include #include "lammps.h" #include "input.h" -#include "error.h" -#include -#include #if defined(LAMMPS_TRAP_FPE) && defined(_GNU_SOURCE) #include diff --git a/src/pair.h b/src/pair.h index 7481514dae..501f3af8f8 100644 --- a/src/pair.h +++ b/src/pair.h @@ -14,7 +14,7 @@ #ifndef LMP_PAIR_H #define LMP_PAIR_H -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/pointers.h b/src/pointers.h index 44967f5135..fc359a5667 100644 --- a/src/pointers.h +++ b/src/pointers.h @@ -21,9 +21,10 @@ #ifndef LMP_POINTERS_H #define LMP_POINTERS_H -#include "lmptype.h" +#include "lmptype.h" // IWYU pragma: export #include -#include "lammps.h" +#include +#include "lammps.h" // IWYU pragma: export namespace LAMMPS_NS { @@ -34,6 +35,10 @@ namespace LAMMPS_NS { #define MIN(A,B) ((A) < (B) ? (A) : (B)) #define MAX(A,B) ((A) > (B) ? (A) : (B)) +// enum used for KOKKOS host/device flags + +enum ExecutionSpace{Host,Device}; + class Pointers { public: Pointers(LAMMPS *ptr) : From 333bec0222ed2f68fa84dc208c0b2f738e5e9da2 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 10:12:53 -0400 Subject: [PATCH 06/79] headers that directly or indirectly include pointers.h may assume is loaded, too. --- src/angle.h | 1 - src/angle_hybrid.h | 1 - src/angle_zero.h | 1 - src/atom.cpp | 4 ---- src/bond.h | 1 - src/dihedral.h | 1 - src/dump.h | 1 - src/improper.h | 1 - src/pointers.h | 2 +- 9 files changed, 1 insertion(+), 12 deletions(-) diff --git a/src/angle.h b/src/angle.h index 6fc8a664c6..7a008f7ca7 100644 --- a/src/angle.h +++ b/src/angle.h @@ -14,7 +14,6 @@ #ifndef LMP_ANGLE_H #define LMP_ANGLE_H -#include #include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/angle_hybrid.h b/src/angle_hybrid.h index 4fde71e43f..730d55b0e2 100644 --- a/src/angle_hybrid.h +++ b/src/angle_hybrid.h @@ -20,7 +20,6 @@ AngleStyle(hybrid,AngleHybrid) #ifndef LMP_ANGLE_HYBRID_H #define LMP_ANGLE_HYBRID_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/angle_zero.h b/src/angle_zero.h index b91be5c8d7..bc1ce0725f 100644 --- a/src/angle_zero.h +++ b/src/angle_zero.h @@ -20,7 +20,6 @@ AngleStyle(zero,AngleZero) #ifndef LMP_ANGLE_ZERO_H #define LMP_ANGLE_ZERO_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/atom.cpp b/src/atom.cpp index 1f5d5a80c4..8176039165 100644 --- a/src/atom.cpp +++ b/src/atom.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include -#include #include #include #include -#include #include "atom.h" #include "style_atom.h" #include "atom_vec.h" @@ -28,14 +26,12 @@ #include "fix.h" #include "compute.h" #include "output.h" -#include "thermo.h" #include "update.h" #include "domain.h" #include "group.h" #include "input.h" #include "variable.h" #include "molecule.h" -#include "atom_masks.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/bond.h b/src/bond.h index f9fb9384ed..5c3b933083 100644 --- a/src/bond.h +++ b/src/bond.h @@ -14,7 +14,6 @@ #ifndef LMP_BOND_H #define LMP_BOND_H -#include #include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/dihedral.h b/src/dihedral.h index 8654132ed5..ed6c02c5b9 100644 --- a/src/dihedral.h +++ b/src/dihedral.h @@ -14,7 +14,6 @@ #ifndef LMP_DIHEDRAL_H #define LMP_DIHEDRAL_H -#include #include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/dump.h b/src/dump.h index d42e7f1f39..0173aa3112 100644 --- a/src/dump.h +++ b/src/dump.h @@ -15,7 +15,6 @@ #define LMP_DUMP_H #include -#include #include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/improper.h b/src/improper.h index 4af5ad4a35..234dc9cb20 100644 --- a/src/improper.h +++ b/src/improper.h @@ -14,7 +14,6 @@ #ifndef LMP_IMPROPER_H #define LMP_IMPROPER_H -#include #include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/pointers.h b/src/pointers.h index fc359a5667..f9ef229c90 100644 --- a/src/pointers.h +++ b/src/pointers.h @@ -23,7 +23,7 @@ #include "lmptype.h" // IWYU pragma: export #include -#include +#include // IWYU pragma: export #include "lammps.h" // IWYU pragma: export namespace LAMMPS_NS { From 48220b39b5813b8144a9ca8aa6dd37aa688b238f Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 10:13:43 -0400 Subject: [PATCH 07/79] include explicitly in .cpp files, though --- src/angle_hybrid.cpp | 1 + src/atom.cpp | 2 +- src/atom_map.cpp | 2 ++ src/atom_vec.cpp | 1 + src/atom_vec.h | 3 +-- src/atom_vec_body.h | 1 - 6 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/angle_hybrid.cpp b/src/angle_hybrid.cpp index 47baf770a5..48bb241100 100644 --- a/src/angle_hybrid.cpp +++ b/src/angle_hybrid.cpp @@ -12,6 +12,7 @@ ------------------------------------------------------------------------- */ #include +#include #include #include #include "angle_hybrid.h" diff --git a/src/atom.cpp b/src/atom.cpp index 8176039165..b79febfc20 100644 --- a/src/atom.cpp +++ b/src/atom.cpp @@ -12,6 +12,7 @@ ------------------------------------------------------------------------- */ #include +#include #include #include #include @@ -25,7 +26,6 @@ #include "modify.h" #include "fix.h" #include "compute.h" -#include "output.h" #include "update.h" #include "domain.h" #include "group.h" diff --git a/src/atom_map.cpp b/src/atom_map.cpp index e9cd590624..35d7435ae2 100644 --- a/src/atom_map.cpp +++ b/src/atom_map.cpp @@ -11,6 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "lmptype.h" +#include #include #include "atom.h" #include "comm.h" diff --git a/src/atom_vec.cpp b/src/atom_vec.cpp index a7ca6fcb19..91e1980dd0 100644 --- a/src/atom_vec.cpp +++ b/src/atom_vec.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include #include "atom_vec.h" diff --git a/src/atom_vec.h b/src/atom_vec.h index 87fb35d9c7..26c181be1e 100644 --- a/src/atom_vec.h +++ b/src/atom_vec.h @@ -14,8 +14,7 @@ #ifndef LMP_ATOM_VEC_H #define LMP_ATOM_VEC_H -#include -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/atom_vec_body.h b/src/atom_vec_body.h index 4d02c4b3e0..09f03caca1 100644 --- a/src/atom_vec_body.h +++ b/src/atom_vec_body.h @@ -112,7 +112,6 @@ class AtomVecBody : public AtomVec { void grow_bonus(); void copy_bonus(int, int); - //void check(int); }; } From 03099d6e54e8b5832e945b32b81afcfeb3a3440b Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 17:11:53 -0400 Subject: [PATCH 08/79] some more include file consistency changes --- src/atom_vec_body.cpp | 3 +-- src/atom_vec_body.h | 1 - src/atom_vec_ellipsoid.cpp | 2 +- src/atom_vec_line.cpp | 1 - src/atom_vec_sphere.cpp | 2 -- src/atom_vec_tri.cpp | 1 - src/balance.cpp | 3 --- src/balance.h | 1 - src/body.cpp | 3 --- src/body.h | 1 - src/bond.cpp | 2 +- src/bond_hybrid.cpp | 4 ++-- src/pointers.h | 5 +++++ 13 files changed, 10 insertions(+), 19 deletions(-) diff --git a/src/atom_vec_body.cpp b/src/atom_vec_body.cpp index d5f286c077..3e9528d6b9 100644 --- a/src/atom_vec_body.cpp +++ b/src/atom_vec_body.cpp @@ -11,17 +11,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include #include "atom_vec_body.h" +#include "my_pool_chunk.h" #include "style_body.h" #include "body.h" #include "atom.h" #include "comm.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "memory.h" #include "error.h" diff --git a/src/atom_vec_body.h b/src/atom_vec_body.h index 09f03caca1..38309648fb 100644 --- a/src/atom_vec_body.h +++ b/src/atom_vec_body.h @@ -21,7 +21,6 @@ AtomStyle(body,AtomVecBody) #define LMP_ATOM_VEC_BODY_H #include "atom_vec.h" -#include "my_pool_chunk.h" namespace LAMMPS_NS { diff --git a/src/atom_vec_ellipsoid.cpp b/src/atom_vec_ellipsoid.cpp index 2bf3f683d0..ad167bef79 100644 --- a/src/atom_vec_ellipsoid.cpp +++ b/src/atom_vec_ellipsoid.cpp @@ -16,11 +16,11 @@ ------------------------------------------------------------------------- */ #include +#include #include "atom_vec_ellipsoid.h" #include "math_extra.h" #include "atom.h" #include "comm.h" -#include "force.h" #include "domain.h" #include "modify.h" #include "fix.h" diff --git a/src/atom_vec_line.cpp b/src/atom_vec_line.cpp index 020b622c93..6b197d2663 100644 --- a/src/atom_vec_line.cpp +++ b/src/atom_vec_line.cpp @@ -19,7 +19,6 @@ #include "comm.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "math_const.h" #include "memory.h" diff --git a/src/atom_vec_sphere.cpp b/src/atom_vec_sphere.cpp index dec98e5200..b3f4bfe391 100644 --- a/src/atom_vec_sphere.cpp +++ b/src/atom_vec_sphere.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include #include "atom_vec_sphere.h" @@ -19,7 +18,6 @@ #include "comm.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "fix_adapt.h" #include "math_const.h" diff --git a/src/atom_vec_tri.cpp b/src/atom_vec_tri.cpp index 8fbe0a92dc..b0b6eca19b 100644 --- a/src/atom_vec_tri.cpp +++ b/src/atom_vec_tri.cpp @@ -20,7 +20,6 @@ #include "comm.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "math_const.h" #include "memory.h" diff --git a/src/balance.cpp b/src/balance.cpp index 61ac895467..04f342b69b 100644 --- a/src/balance.cpp +++ b/src/balance.cpp @@ -20,7 +20,6 @@ #include #include -#include #include #include "balance.h" #include "atom.h" @@ -30,7 +29,6 @@ #include "domain.h" #include "force.h" #include "update.h" -#include "group.h" #include "modify.h" #include "fix_store.h" #include "imbalance.h" @@ -39,7 +37,6 @@ #include "imbalance_neigh.h" #include "imbalance_store.h" #include "imbalance_var.h" -#include "timer.h" #include "memory.h" #include "error.h" diff --git a/src/balance.h b/src/balance.h index 420031502a..424da33757 100644 --- a/src/balance.h +++ b/src/balance.h @@ -20,7 +20,6 @@ CommandStyle(balance,Balance) #ifndef LMP_BALANCE_H #define LMP_BALANCE_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/body.cpp b/src/body.cpp index 78e2f5d71b..10f88bd43b 100644 --- a/src/body.cpp +++ b/src/body.cpp @@ -11,11 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include #include "body.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/body.h b/src/body.h index 59001620f8..44581b75f6 100644 --- a/src/body.h +++ b/src/body.h @@ -16,7 +16,6 @@ #include "pointers.h" #include "atom_vec_body.h" -#include "my_pool_chunk.h" namespace LAMMPS_NS { diff --git a/src/bond.cpp b/src/bond.cpp index edcd869425..0d50b7e3e5 100644 --- a/src/bond.cpp +++ b/src/bond.cpp @@ -11,7 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include "bond.h" #include "atom.h" #include "comm.h" diff --git a/src/bond_hybrid.cpp b/src/bond_hybrid.cpp index 65609b4b6e..0fb23a3214 100644 --- a/src/bond_hybrid.cpp +++ b/src/bond_hybrid.cpp @@ -11,13 +11,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include +#include #include #include #include "bond_hybrid.h" #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/pointers.h b/src/pointers.h index f9ef229c90..5df5b72d47 100644 --- a/src/pointers.h +++ b/src/pointers.h @@ -39,6 +39,11 @@ namespace LAMMPS_NS { enum ExecutionSpace{Host,Device}; +// global forward declarations + +template class MyPoolChunk; +template class MyPage; + class Pointers { public: Pointers(LAMMPS *ptr) : From 2c0a66b7f8c21ea580dc7bb893461d3585969559 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 20:50:25 -0400 Subject: [PATCH 09/79] increase buffer size of fix tune/kspace. header cleanup. remove use of iostreams --- src/KSPACE/fix_tune_kspace.cpp | 41 +++++++++++++++++----------------- src/KSPACE/fix_tune_kspace.h | 9 ++++---- 2 files changed, 24 insertions(+), 26 deletions(-) diff --git a/src/KSPACE/fix_tune_kspace.cpp b/src/KSPACE/fix_tune_kspace.cpp index 0c726985dc..2b22b44340 100644 --- a/src/KSPACE/fix_tune_kspace.cpp +++ b/src/KSPACE/fix_tune_kspace.cpp @@ -15,13 +15,11 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include #include -#include +#include #include "fix_tune_kspace.h" #include "update.h" -#include "domain.h" -#include "atom.h" -#include "comm.h" #include "force.h" #include "kspace.h" #include "pair.h" @@ -31,9 +29,6 @@ #include "neighbor.h" #include "modify.h" #include "compute.h" -#include -#include -#include #define SWAP(a,b) {temp=(a);(a)=(b);(b)=temp;} #define SIGN(a,b) ((b) >= 0.0 ? fabs(a) : -fabs(a)) #define GOLD 1.618034 @@ -101,7 +96,7 @@ void FixTuneKspace::init() double old_acc = force->kspace->accuracy/force->kspace->two_charge_force; char old_acc_str[16]; snprintf(old_acc_str,16,"%g",old_acc); - strcpy(new_acc_str,old_acc_str); + strncpy(new_acc_str,old_acc_str,16); int itmp; double *p_cutoff = (double *) force->pair->extract("cut_coul",itmp); @@ -131,36 +126,37 @@ void FixTuneKspace::pre_exchange() // test Ewald store_old_kspace_settings(); strcpy(new_kspace_style,"ewald"); - sprintf(new_pair_style,"%s/long",base_pair_style); + snprintf(new_pair_style,64,"%s/long",base_pair_style); update_pair_style(new_pair_style,pair_cut_coul); update_kspace_style(new_kspace_style,new_acc_str); } else if (niter == 2) { // test PPPM store_old_kspace_settings(); strcpy(new_kspace_style,"pppm"); - sprintf(new_pair_style,"%s/long",base_pair_style); + snprintf(new_pair_style,64,"%s/long",base_pair_style); update_pair_style(new_pair_style,pair_cut_coul); update_kspace_style(new_kspace_style,new_acc_str); } else if (niter == 3) { // test MSM store_old_kspace_settings(); strcpy(new_kspace_style,"msm"); - sprintf(new_pair_style,"%s/msm",base_pair_style); + snprintf(new_pair_style,64,"%s/msm",base_pair_style); update_pair_style(new_pair_style,pair_cut_coul); update_kspace_style(new_kspace_style,new_acc_str); } else if (niter == 4) { store_old_kspace_settings(); - cout << "ewald_time = " << ewald_time << endl; - cout << "pppm_time = " << pppm_time << endl; - cout << "msm_time = " << msm_time << endl; + if (screen) fprintf(screen,"ewald_time = %g\npppm_time = %g\nmsm_time = %g", + ewald_time, pppm_time, msm_time); + if (logfile) fprintf(logfile,"ewald_time = %g\npppm_time = %g\nmsm_time = %g", + ewald_time, pppm_time, msm_time); // switch to fastest one strcpy(new_kspace_style,"ewald"); - sprintf(new_pair_style,"%s/long",base_pair_style); + snprintf(new_pair_style,64,"%s/long",base_pair_style); if (pppm_time < ewald_time && pppm_time < msm_time) strcpy(new_kspace_style,"pppm"); else if (msm_time < pppm_time && msm_time < ewald_time) { strcpy(new_kspace_style,"msm"); - sprintf(new_pair_style,"%s/msm",base_pair_style); + snprintf(new_pair_style,64,"%s/msm",base_pair_style); } update_pair_style(new_pair_style,pair_cut_coul); update_kspace_style(new_kspace_style,new_acc_str); @@ -243,8 +239,8 @@ void FixTuneKspace::update_pair_style(char *new_pair_style, p_pair_settings_file = tmpfile(); force->pair->write_restart(p_pair_settings_file); rewind(p_pair_settings_file); - - cout << "Creating new pair style: " << new_pair_style << endl; + if (screen) fprintf(screen,"Creating new pair style: %s\n",new_pair_style); + if (logfile) fprintf(logfile,"Creating new pair style: %s\n",new_pair_style); // delete old pair style and create new one force->create_pair(new_pair_style,1); @@ -253,7 +249,8 @@ void FixTuneKspace::update_pair_style(char *new_pair_style, double *pcutoff = (double *) force->pair->extract("cut_coul",itmp); double current_cutoff = *pcutoff; - cout << "Coulomb cutoff for real space: " << current_cutoff << endl; + if (screen) fprintf(screen,"Coulomb cutoff for real space: %g\n", current_cutoff); + if (logfile) fprintf(logfile,"Coulomb cutoff for real space: %g\n", current_cutoff); // close temporary file fclose(p_pair_settings_file); @@ -321,7 +318,8 @@ void FixTuneKspace::adjust_rcut(double time) int itmp; double *p_cutoff = (double *) force->pair->extract("cut_coul",itmp); double current_cutoff = *p_cutoff; - cout << "Old Coulomb cutoff for real space: " << current_cutoff << endl; + if (screen) fprintf(screen,"Old Coulomb cutoff for real space: %g\n",current_cutoff); + if (logfile) fprintf(logfile,"Old Coulomb cutoff for real space: %g\n",current_cutoff); // use Brent's method from Numerical Recipes to find optimal real space cutoff @@ -391,7 +389,8 @@ void FixTuneKspace::adjust_rcut(double time) // report the new cutoff double *new_cutoff = (double *) force->pair->extract("cut_coul",itmp); current_cutoff = *new_cutoff; - cout << "Adjusted Coulomb cutoff for real space: " << current_cutoff << endl; + if (screen) fprintf(screen,"Adjusted Coulomb cutoff for real space: %g\n", current_cutoff); + if (logfile) fprintf(logfile,"Adjusted Coulomb cutoff for real space: %g\n", current_cutoff); store_old_kspace_settings(); update_pair_style(new_pair_style,pair_cut_coul); diff --git a/src/KSPACE/fix_tune_kspace.h b/src/KSPACE/fix_tune_kspace.h index 6f40fc8711..1ccd735317 100644 --- a/src/KSPACE/fix_tune_kspace.h +++ b/src/KSPACE/fix_tune_kspace.h @@ -20,7 +20,6 @@ FixStyle(tune/kspace,FixTuneKspace) #ifndef LMP_FIX_TUNE_KSPACE_H #define LMP_FIX_TUNE_KSPACE_H -#include #include "fix.h" namespace LAMMPS_NS { @@ -52,10 +51,10 @@ class FixTuneKspace : public Fix { double ewald_time,pppm_time,msm_time; double pair_cut_coul; - char new_acc_str[12]; - char new_kspace_style[20]; - char new_pair_style[20]; - char base_pair_style[20]; + char new_acc_str[16]; + char new_kspace_style[64]; + char new_pair_style[64]; + char base_pair_style[64]; int old_differentiation_flag; int old_slabflag; From 932f052cbf0cf4e94a4df52bbe3414dfeca90959 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 20:52:23 -0400 Subject: [PATCH 10/79] more header cleanup --- src/GPU/pair_vashishta_gpu.cpp | 1 - src/angle_deprecated.cpp | 1 - src/angle_hybrid.cpp | 1 - src/atom.cpp | 1 - src/atom_map.cpp | 2 +- src/atom_vec.cpp | 1 - src/atom_vec_hybrid.h | 1 - src/bond_zero.cpp | 4 ++-- src/change_box.cpp | 1 - src/citeme.cpp | 3 +-- src/citeme.h | 3 +-- src/comm.cpp | 1 + src/comm_brick.cpp | 8 -------- src/hashlittle.cpp | 2 +- src/lammps.cpp | 1 + 15 files changed, 8 insertions(+), 23 deletions(-) diff --git a/src/GPU/pair_vashishta_gpu.cpp b/src/GPU/pair_vashishta_gpu.cpp index b496359b8a..5539653756 100644 --- a/src/GPU/pair_vashishta_gpu.cpp +++ b/src/GPU/pair_vashishta_gpu.cpp @@ -14,7 +14,6 @@ /* ---------------------------------------------------------------------- Contributing author: Anders Hafreager (UiO) ------------------------------------------------------------------------- */ -#include #include #include #include diff --git a/src/angle_deprecated.cpp b/src/angle_deprecated.cpp index 73fcccc53a..b5af217b7b 100644 --- a/src/angle_deprecated.cpp +++ b/src/angle_deprecated.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include -#include #include "angle_deprecated.h" #include "angle_hybrid.h" #include "comm.h" diff --git a/src/angle_hybrid.cpp b/src/angle_hybrid.cpp index 48bb241100..47baf770a5 100644 --- a/src/angle_hybrid.cpp +++ b/src/angle_hybrid.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include #include "angle_hybrid.h" diff --git a/src/atom.cpp b/src/atom.cpp index b79febfc20..eab8a3063d 100644 --- a/src/atom.cpp +++ b/src/atom.cpp @@ -13,7 +13,6 @@ #include #include -#include #include #include #include "atom.h" diff --git a/src/atom_map.cpp b/src/atom_map.cpp index 35d7435ae2..b14ebdba68 100644 --- a/src/atom_map.cpp +++ b/src/atom_map.cpp @@ -11,7 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include "lmptype.h" +#include "pointers.h" #include #include #include "atom.h" diff --git a/src/atom_vec.cpp b/src/atom_vec.cpp index 91e1980dd0..a7ca6fcb19 100644 --- a/src/atom_vec.cpp +++ b/src/atom_vec.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include #include "atom_vec.h" diff --git a/src/atom_vec_hybrid.h b/src/atom_vec_hybrid.h index a027923a17..8129baccba 100644 --- a/src/atom_vec_hybrid.h +++ b/src/atom_vec_hybrid.h @@ -20,7 +20,6 @@ AtomStyle(hybrid,AtomVecHybrid) #ifndef LMP_ATOM_VEC_HYBRID_H #define LMP_ATOM_VEC_HYBRID_H -#include #include "atom_vec.h" namespace LAMMPS_NS { diff --git a/src/bond_zero.cpp b/src/bond_zero.cpp index 0847cf9e6b..3932846cb4 100644 --- a/src/bond_zero.cpp +++ b/src/bond_zero.cpp @@ -15,8 +15,8 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ -#include -#include +#include +#include #include #include "bond_zero.h" #include "atom.h" diff --git a/src/change_box.cpp b/src/change_box.cpp index b7d3cb245f..1fed65b430 100644 --- a/src/change_box.cpp +++ b/src/change_box.cpp @@ -13,7 +13,6 @@ #include #include -#include #include #include "change_box.h" #include "atom.h" diff --git a/src/citeme.cpp b/src/citeme.cpp index d021722671..24896b448c 100644 --- a/src/citeme.cpp +++ b/src/citeme.cpp @@ -11,10 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include "citeme.h" -#include "version.h" #include "universe.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/citeme.h b/src/citeme.h index 262b284337..c383ec2227 100644 --- a/src/citeme.h +++ b/src/citeme.h @@ -15,7 +15,6 @@ #define LMP_CITEME_H #include "pointers.h" -#include #include namespace LAMMPS_NS { @@ -29,7 +28,7 @@ class CiteMe : protected Pointers { private: FILE *fp; // opaque pointer to log.cite file object typedef std::set citeset; - citeset *cs; // registered set of publications + citeset *cs; // registered set of publications }; } diff --git a/src/comm.cpp b/src/comm.cpp index 052de93793..5f846cf292 100644 --- a/src/comm.cpp +++ b/src/comm.cpp @@ -21,6 +21,7 @@ #include "force.h" #include "pair.h" #include "modify.h" +#include "neighbor.h" #include "fix.h" #include "compute.h" #include "domain.h" diff --git a/src/comm_brick.cpp b/src/comm_brick.cpp index 330551aaed..47f60a3da6 100644 --- a/src/comm_brick.cpp +++ b/src/comm_brick.cpp @@ -19,23 +19,15 @@ #include #include #include -#include #include "comm_brick.h" -#include "comm_tiled.h" -#include "universe.h" #include "atom.h" #include "atom_vec.h" -#include "force.h" #include "pair.h" #include "domain.h" #include "neighbor.h" -#include "group.h" -#include "modify.h" #include "fix.h" #include "compute.h" -#include "output.h" #include "dump.h" -#include "math_extra.h" #include "error.h" #include "memory.h" diff --git a/src/hashlittle.cpp b/src/hashlittle.cpp index f612be9eeb..42109abd24 100644 --- a/src/hashlittle.cpp +++ b/src/hashlittle.cpp @@ -3,7 +3,7 @@ // bob_jenkins@burtleburtle.net #include -#include +#include #include // if the system defines the __BYTE_ORDER__ define, diff --git a/src/lammps.cpp b/src/lammps.cpp index 320d89ed52..83a2f057ee 100644 --- a/src/lammps.cpp +++ b/src/lammps.cpp @@ -12,6 +12,7 @@ ------------------------------------------------------------------------- */ #include +#include #include #include #include From 9c53a5ca3f1c756601b091a97ea5020a7187d2e5 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 21:40:28 -0400 Subject: [PATCH 11/79] add first draft of a summary of the rules for include files --- doc/include-file-conventions.md | 125 ++++++++++++++++++++++++++++++++ 1 file changed, 125 insertions(+) create mode 100644 doc/include-file-conventions.md diff --git a/doc/include-file-conventions.md b/doc/include-file-conventions.md new file mode 100644 index 0000000000..5152051ba5 --- /dev/null +++ b/doc/include-file-conventions.md @@ -0,0 +1,125 @@ +# Outline of include file conventions in LAMMPS + +This purpose of this document is to provide a point of reference +for LAMMPS developers and contributors as to what include files +and definitions to put where into LAMMPS source. +Last change 2019-06-27 + +## Table of Contents + + * [Motivation](#motivation) + * [Rules](#rules) + * [Tools](#tools) + * [Legacy Code](#legacy-code) + +## Motivation + +The conventions outlined in this document are supposed to help making +maintenance of the LAMMPS software easier. By trying to achieve +consistency across files contributed by different developers, it will +become easier to modify and adjust files by the code maintainers, and +overall the chance for errors or portability issues will be reduced. +Also the rules employed are supposed to minimize naming conflicts and +simplify dependencies between files (and thus speed up compilation), as +well as make otherwise hidden dependencies visible. + +## Rules + +Below are the various rules that are applied. Not all a enforced +strictly and automatically. If there are no significant side effects, +exceptions may be possible for cases, where a full compliance to the +rules may require a large effort compared to the benefit. + +### Core Files Versus Package Files + +All rules listed below are most strictly observed for core LAMMPS files. +Which are the files that are not part of a package and files of the +packages MOLECULE, MANYBODY, KSPACE, and RIGID. On the other end of +the spectrum are USER packages and legacy packages that predate these +rules and thus may not be fully compliant. Also new contributions +will be checked more closely, while existing code is incrementally +adapted to the rules as time and required effort permits. + +### System Versus Local Header Files + +All system or library provided include files are included with angular +brackets (examples: `#include ` or `#include `) while +include files provided with LAMMPS are included with double quotes +(examples: `#include "pointers.h"` or `#include "compute_temp.h"`). + +For headers declaring functions of the C-library, the corresponding +C++ versions should be included (examples: `#include ` or +`#include `). However, those are limited to those defined +in the C++98 standard. Some files thus must use the older style unless +the minimum C++ standard requirement of LAMMPS is lifted to C++11 or +even beyond (examples: `#include ` versus `#include ` +or `#include ` versus `#include `). + +### C++ Standard Compliance + +LAMMPS core files currently correspond to the C++98 standard. Files +requiring C++11 or later are only permitted in (optional) packages +and particularly packages that are not part of the list of commonly +used packages like MOLECULE, KSPACE, MANYBODY, or RIGID. + +Also, LAMMPS uses the C-style stdio library for I/O instead of iostreams. +Since using both at the same time can cause problems, iostreams should +be avoided where possible. + +### Lean Header Files + +Header files will typically contain the definition of a (single) class. +These header files should have as few include statements as possible. +This is particularly important for classes that implement a "style" and +thus use a macro of the kind `SomeStyle(some/name,SomeName)`. These will +be all included in the auto-generated `"some_style.h"` files which will +result in a high potential for direct or indirect symbol name clashes. + +In the ideal case, the header would only include one file defining the +parent class. That would typically be either `#include "pointers.h"` for +the `Pointers` class, or a header of a class derived from it like +`#include "pair.h"` for the `Pair` class and so on. Referenced to other +classes inside the class should be make through pointers, for which forward +declarations (inside the `LAMMPS_NS` or the new class'es namespace) can +be employed. The full definition will then be included into the corresponding +implementation file. In the given example from above, the header file +would be called `some_name.h` and the implementation `some_name.cpp` (all +lower case with underscores, while the class itself would be in camel case +and no underscores, and the style name with lower case names separated by +a forward slash). + +### Implementation Files + +In the implementation files (typically, those would have the same base name +as the corresponding header with a .cpp extension instead of .h) include +statments should follow the "include what you use" principle. + +### Special Cases and Exceptions + +#### pointers.h + +The `pointer.h` header file also includes `cstdio` and `lmptype.h` +(and throught it `stdint.h`, `intttypes.h`, and `climits`). +This means any header including `pointers.h` can assume that `FILE`, +`NULL`, `INT_MAX` are defined. + +## Tools + +The [Include What You Use tool](https://include-what-you-use.org/) +can be used to provide supporting information about compliance with +the rules listed here. There are some limitations and the IWWU tool +may give incorrect advice. The tools is activated by setting the +CMake variable `CMAKE_CXX_INCLUDE_WHAT_YOU_USE` variable to the +path of the `include-what-you-use` command. When activated, the +tool will be run after each compilation and provide suggestions for +which include files should be added or removed. + +## Legacy Code + +A lot of code predates the application of the rules in this document, +and those rules are a moving target as well. So there is going to be +significant chunks of code, that does not fully comply. This applies +for example to the USER-REAXC, or the USER-ATC package. The LAMMPS +developers are dedicated to make an effort to improve the compliance +and welcome volunteers wanting to help with the process. + From 86a9e4fca24a7cefc832333a3ff75a057763e370 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 21:40:50 -0400 Subject: [PATCH 12/79] make body package compile again --- src/BODY/body_nparticle.cpp | 1 + src/BODY/body_rounded_polygon.cpp | 1 + src/BODY/body_rounded_polyhedron.cpp | 1 + 3 files changed, 3 insertions(+) diff --git a/src/BODY/body_nparticle.cpp b/src/BODY/body_nparticle.cpp index 10529ad3af..21070107f5 100644 --- a/src/BODY/body_nparticle.cpp +++ b/src/BODY/body_nparticle.cpp @@ -13,6 +13,7 @@ #include #include "body_nparticle.h" +#include "my_pool_chunk.h" #include "math_extra.h" #include "atom_vec_body.h" #include "atom.h" diff --git a/src/BODY/body_rounded_polygon.cpp b/src/BODY/body_rounded_polygon.cpp index d352c789d7..f7741ada88 100644 --- a/src/BODY/body_rounded_polygon.cpp +++ b/src/BODY/body_rounded_polygon.cpp @@ -17,6 +17,7 @@ #include #include "body_rounded_polygon.h" +#include "my_pool_chunk.h" #include "atom_vec_body.h" #include "atom.h" #include "force.h" diff --git a/src/BODY/body_rounded_polyhedron.cpp b/src/BODY/body_rounded_polyhedron.cpp index 99a380a932..34d918f1f6 100644 --- a/src/BODY/body_rounded_polyhedron.cpp +++ b/src/BODY/body_rounded_polyhedron.cpp @@ -17,6 +17,7 @@ #include #include "body_rounded_polyhedron.h" +#include "my_pool_chunk.h" #include "atom_vec_body.h" #include "atom.h" #include "force.h" From 4ec3a508fc1731e5d6d3708005515ff0addace9f Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 21:54:07 -0400 Subject: [PATCH 13/79] bulk removal of #include from header files --- src/CLASS2/angle_class2.h | 1 - src/CLASS2/bond_class2.h | 1 - src/CLASS2/dihedral_class2.h | 1 - src/CLASS2/improper_class2.h | 1 - src/GPU/pair_eam_gpu.h | 1 - src/KOKKOS/atom_vec_hybrid_kokkos.h | 1 - src/KOKKOS/pair_eam_alloy_kokkos.h | 1 - src/KOKKOS/pair_eam_fs_kokkos.h | 1 - src/KOKKOS/pair_eam_kokkos.h | 1 - src/KOKKOS/pair_hybrid_kokkos.h | 1 - src/KOKKOS/pair_reaxc_kokkos.h | 1 - src/KOKKOS/pair_tersoff_kokkos.h | 1 - src/KOKKOS/pair_tersoff_mod_kokkos.h | 1 - src/KOKKOS/pair_tersoff_zbl_kokkos.h | 1 - src/MANYBODY/fix_qeq_comb.h | 1 - src/MANYBODY/pair_eam.h | 1 - src/MANYBODY/pair_eim.h | 1 - src/MC/fix_atom_swap.h | 1 - src/MC/fix_gcmc.h | 1 - src/MISC/fix_deposit.h | 1 - src/MOLECULE/angle_charmm.h | 1 - src/MOLECULE/angle_cosine.h | 1 - src/MOLECULE/angle_cosine_delta.h | 1 - src/MOLECULE/angle_cosine_periodic.h | 1 - src/MOLECULE/angle_cosine_squared.h | 1 - src/MOLECULE/angle_harmonic.h | 1 - src/MOLECULE/angle_table.h | 1 - src/MOLECULE/bond_fene.h | 1 - src/MOLECULE/bond_fene_expand.h | 1 - src/MOLECULE/bond_gromos.h | 1 - src/MOLECULE/bond_harmonic.h | 1 - src/MOLECULE/bond_morse.h | 1 - src/MOLECULE/bond_nonlinear.h | 1 - src/MOLECULE/bond_quartic.h | 1 - src/MOLECULE/bond_table.h | 1 - src/MOLECULE/dihedral_charmm.h | 1 - src/MOLECULE/dihedral_charmmfsw.h | 1 - src/MOLECULE/dihedral_harmonic.h | 1 - src/MOLECULE/dihedral_helix.h | 1 - src/MOLECULE/dihedral_multi_harmonic.h | 1 - src/MOLECULE/dihedral_opls.h | 1 - src/MOLECULE/improper_cvff.h | 1 - src/MOLECULE/improper_harmonic.h | 1 - src/MOLECULE/improper_umbrella.h | 1 - src/REPLICA/neb.h | 1 - src/SPIN/neb_spin.h | 1 - src/USER-CGDNA/mf_oxdna.h | 1 - src/USER-CGSDK/angle_sdk.h | 1 - src/USER-DIFFRACTION/fix_saed_vtk.h | 1 - src/USER-INTEL/angle_charmm_intel.h | 1 - src/USER-INTEL/angle_harmonic_intel.h | 1 - src/USER-INTEL/bond_fene_intel.h | 1 - src/USER-INTEL/bond_harmonic_intel.h | 1 - src/USER-INTEL/improper_cvff_intel.h | 1 - src/USER-INTEL/improper_harmonic_intel.h | 1 - src/USER-INTEL/intel_simd.h | 1 - src/USER-INTEL/pair_eam_intel.h | 1 - src/USER-MANIFOLD/manifold_thylakoid.h | 1 - src/USER-MGPT/mgpt_readpot.h | 1 - src/USER-MGPT/pair_mgpt.h | 1 - src/USER-MISC/angle_cosine_shift.h | 1 - src/USER-MISC/angle_cosine_shift_exp.h | 1 - src/USER-MISC/angle_dipole.h | 1 - src/USER-MISC/angle_fourier.h | 1 - src/USER-MISC/angle_fourier_simple.h | 1 - src/USER-MISC/angle_quartic.h | 1 - src/USER-MISC/bond_harmonic_shift.h | 1 - src/USER-MISC/bond_harmonic_shift_cut.h | 1 - src/USER-MISC/dihedral_cosine_shift_exp.h | 1 - src/USER-MISC/dihedral_fourier.h | 1 - src/USER-MISC/dihedral_nharmonic.h | 1 - src/USER-MISC/dihedral_quadratic.h | 1 - src/USER-MISC/dihedral_spherical.h | 1 - src/USER-MISC/fix_ave_correlate_long.h | 1 - src/USER-MISC/fix_srp.h | 1 - src/USER-MISC/improper_cossq.h | 1 - src/USER-MISC/improper_distance.h | 1 - src/USER-MISC/improper_fourier.h | 1 - src/USER-MISC/improper_ring.h | 1 - src/USER-MOFFF/angle_class2_p6.h | 1 - src/USER-MOFFF/angle_cosine_buck6d.h | 1 - src/USER-MOFFF/improper_inversion_harmonic.h | 1 - src/USER-REAXC/fix_reaxc_bonds.h | 1 - src/bond_hybrid.h | 1 - src/bond_zero.h | 1 - src/citeme.cpp | 1 - src/comm_brick.cpp | 1 - src/comm_tiled.cpp | 5 +---- src/comm_tiled.h | 1 + src/compute.cpp | 4 ---- src/compute_adf.h | 1 - src/compute_rdf.h | 1 - src/dihedral_hybrid.h | 1 - src/dihedral_zero.h | 1 - src/fix_ave_atom.h | 1 - src/fix_ave_chunk.h | 1 - src/fix_ave_correlate.h | 1 - src/fix_ave_histo.h | 1 - src/fix_ave_histo_weight.h | 1 - src/fix_ave_time.h | 1 - src/fix_balance.h | 1 - src/fix_halt.h | 1 - src/fix_move.h | 1 - src/fix_print.h | 1 - src/fix_store.h | 1 - src/fix_tmd.h | 1 - src/force.h | 1 - src/group.h | 1 - src/image.h | 1 - src/imbalance.h | 1 - src/improper_hybrid.h | 1 - src/improper_zero.h | 1 - src/input.h | 1 - src/lammps.h | 1 - src/modify.h | 1 - src/pair_hybrid.h | 1 - src/read_data.h | 1 - src/read_dump.h | 1 - src/read_restart.h | 1 - src/universe.h | 1 - src/variable.h | 1 - src/write_coeff.h | 1 - src/write_data.h | 1 - src/write_restart.h | 1 - 124 files changed, 2 insertions(+), 129 deletions(-) diff --git a/src/CLASS2/angle_class2.h b/src/CLASS2/angle_class2.h index 8444ada057..cc155747ac 100644 --- a/src/CLASS2/angle_class2.h +++ b/src/CLASS2/angle_class2.h @@ -20,7 +20,6 @@ AngleStyle(class2,AngleClass2) #ifndef LMP_ANGLE_CLASS2_H #define LMP_ANGLE_CLASS2_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/CLASS2/bond_class2.h b/src/CLASS2/bond_class2.h index 89d930b548..f0fcc6825e 100644 --- a/src/CLASS2/bond_class2.h +++ b/src/CLASS2/bond_class2.h @@ -20,7 +20,6 @@ BondStyle(class2,BondClass2) #ifndef LMP_BOND_CLASS2_H #define LMP_BOND_CLASS2_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/CLASS2/dihedral_class2.h b/src/CLASS2/dihedral_class2.h index a4ea9e4bd9..32cd289137 100644 --- a/src/CLASS2/dihedral_class2.h +++ b/src/CLASS2/dihedral_class2.h @@ -20,7 +20,6 @@ DihedralStyle(class2,DihedralClass2) #ifndef LMP_DIHEDRAL_CLASS2_H #define LMP_DIHEDRAL_CLASS2_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/CLASS2/improper_class2.h b/src/CLASS2/improper_class2.h index 1cc3417731..cac805046a 100644 --- a/src/CLASS2/improper_class2.h +++ b/src/CLASS2/improper_class2.h @@ -20,7 +20,6 @@ ImproperStyle(class2,ImproperClass2) #ifndef LMP_IMPROPER_CLASS2_H #define LMP_IMPROPER_CLASS2_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/GPU/pair_eam_gpu.h b/src/GPU/pair_eam_gpu.h index 099529f3df..e4742a3bef 100644 --- a/src/GPU/pair_eam_gpu.h +++ b/src/GPU/pair_eam_gpu.h @@ -20,7 +20,6 @@ PairStyle(eam/gpu,PairEAMGPU) #ifndef LMP_PAIR_EAM_GPU_H #define LMP_PAIR_EAM_GPU_H -#include #include "pair_eam.h" namespace LAMMPS_NS { diff --git a/src/KOKKOS/atom_vec_hybrid_kokkos.h b/src/KOKKOS/atom_vec_hybrid_kokkos.h index 1bbbd26319..4cfb186b17 100644 --- a/src/KOKKOS/atom_vec_hybrid_kokkos.h +++ b/src/KOKKOS/atom_vec_hybrid_kokkos.h @@ -20,7 +20,6 @@ AtomStyle(hybrid/kk,AtomVecHybridKokkos) #ifndef LMP_ATOM_VEC_HYBRID_KOKKOS_H #define LMP_ATOM_VEC_HYBRID_KOKKOS_H -#include #include "atom_vec_kokkos.h" #include "kokkos_type.h" diff --git a/src/KOKKOS/pair_eam_alloy_kokkos.h b/src/KOKKOS/pair_eam_alloy_kokkos.h index 6593ccae73..e1dd9ab47d 100644 --- a/src/KOKKOS/pair_eam_alloy_kokkos.h +++ b/src/KOKKOS/pair_eam_alloy_kokkos.h @@ -23,7 +23,6 @@ PairStyle(eam/alloy/kk/host,PairEAMAlloyKokkos) #ifndef LMP_PAIR_EAM_ALLOY_KOKKOS_H #define LMP_PAIR_EAM_ALLOY_KOKKOS_H -#include #include "kokkos_base.h" #include "pair_kokkos.h" #include "pair_eam.h" diff --git a/src/KOKKOS/pair_eam_fs_kokkos.h b/src/KOKKOS/pair_eam_fs_kokkos.h index f75605ff6d..e93977869e 100644 --- a/src/KOKKOS/pair_eam_fs_kokkos.h +++ b/src/KOKKOS/pair_eam_fs_kokkos.h @@ -23,7 +23,6 @@ PairStyle(eam/fs/kk/host,PairEAMFSKokkos) #ifndef LMP_PAIR_EAM_FS_KOKKOS_H #define LMP_PAIR_EAM_FS_KOKKOS_H -#include #include "kokkos_base.h" #include "pair_kokkos.h" #include "pair_eam.h" diff --git a/src/KOKKOS/pair_eam_kokkos.h b/src/KOKKOS/pair_eam_kokkos.h index 4040eba858..3bf89c549a 100644 --- a/src/KOKKOS/pair_eam_kokkos.h +++ b/src/KOKKOS/pair_eam_kokkos.h @@ -23,7 +23,6 @@ PairStyle(eam/kk/host,PairEAMKokkos) #ifndef LMP_PAIR_EAM_KOKKOS_H #define LMP_PAIR_EAM_KOKKOS_H -#include #include "kokkos_base.h" #include "pair_kokkos.h" #include "pair_eam.h" diff --git a/src/KOKKOS/pair_hybrid_kokkos.h b/src/KOKKOS/pair_hybrid_kokkos.h index 94e034f875..799354cf01 100644 --- a/src/KOKKOS/pair_hybrid_kokkos.h +++ b/src/KOKKOS/pair_hybrid_kokkos.h @@ -20,7 +20,6 @@ PairStyle(hybrid/kk,PairHybridKokkos) #ifndef LMP_PAIR_HYBRID_KOKKOS_H #define LMP_PAIR_HYBRID_KOKKOS_H -#include #include "pair_hybrid.h" #include "pair_kokkos.h" #include "kokkos_type.h" diff --git a/src/KOKKOS/pair_reaxc_kokkos.h b/src/KOKKOS/pair_reaxc_kokkos.h index 89dfc4d884..783ea33c4e 100644 --- a/src/KOKKOS/pair_reaxc_kokkos.h +++ b/src/KOKKOS/pair_reaxc_kokkos.h @@ -23,7 +23,6 @@ PairStyle(reax/c/kk/host,PairReaxCKokkos) #ifndef LMP_PAIR_REAXC_KOKKOS_H #define LMP_PAIR_REAXC_KOKKOS_H -#include #include "pair_kokkos.h" #include "pair_reaxc.h" #include "neigh_list_kokkos.h" diff --git a/src/KOKKOS/pair_tersoff_kokkos.h b/src/KOKKOS/pair_tersoff_kokkos.h index f73d4fe2d8..7d41fe2346 100644 --- a/src/KOKKOS/pair_tersoff_kokkos.h +++ b/src/KOKKOS/pair_tersoff_kokkos.h @@ -23,7 +23,6 @@ PairStyle(tersoff/kk/host,PairTersoffKokkos) #ifndef LMP_PAIR_TERSOFF_KOKKOS_H #define LMP_PAIR_TERSOFF_KOKKOS_H -#include #include "pair_kokkos.h" #include "pair_tersoff.h" #include "neigh_list_kokkos.h" diff --git a/src/KOKKOS/pair_tersoff_mod_kokkos.h b/src/KOKKOS/pair_tersoff_mod_kokkos.h index d7c94ffc93..889e1eadfa 100644 --- a/src/KOKKOS/pair_tersoff_mod_kokkos.h +++ b/src/KOKKOS/pair_tersoff_mod_kokkos.h @@ -23,7 +23,6 @@ PairStyle(tersoff/mod/kk/host,PairTersoffMODKokkos) #ifndef LMP_PAIR_TERSOFF_MOD_KOKKOS_H #define LMP_PAIR_TERSOFF_MOD_KOKKOS_H -#include #include "pair_kokkos.h" #include "pair_tersoff_mod.h" #include "neigh_list_kokkos.h" diff --git a/src/KOKKOS/pair_tersoff_zbl_kokkos.h b/src/KOKKOS/pair_tersoff_zbl_kokkos.h index 3af4e0d8eb..0c7fa2e963 100644 --- a/src/KOKKOS/pair_tersoff_zbl_kokkos.h +++ b/src/KOKKOS/pair_tersoff_zbl_kokkos.h @@ -23,7 +23,6 @@ PairStyle(tersoff/zbl/kk/host,PairTersoffZBLKokkos) #ifndef LMP_PAIR_TERSOFF_ZBL_KOKKOS_H #define LMP_PAIR_TERSOFF_ZBL_KOKKOS_H -#include #include "pair_kokkos.h" #include "pair_tersoff_zbl.h" #include "neigh_list_kokkos.h" diff --git a/src/MANYBODY/fix_qeq_comb.h b/src/MANYBODY/fix_qeq_comb.h index dd4c9f7290..c3a0ac08f3 100644 --- a/src/MANYBODY/fix_qeq_comb.h +++ b/src/MANYBODY/fix_qeq_comb.h @@ -20,7 +20,6 @@ FixStyle(qeq/comb,FixQEQComb) #ifndef LMP_FIX_QEQ_COMB_H #define LMP_FIX_QEQ_COMB_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/MANYBODY/pair_eam.h b/src/MANYBODY/pair_eam.h index 234552157b..8bcb44c347 100644 --- a/src/MANYBODY/pair_eam.h +++ b/src/MANYBODY/pair_eam.h @@ -20,7 +20,6 @@ PairStyle(eam,PairEAM) #ifndef LMP_PAIR_EAM_H #define LMP_PAIR_EAM_H -#include #include "pair.h" namespace LAMMPS_NS { diff --git a/src/MANYBODY/pair_eim.h b/src/MANYBODY/pair_eim.h index 50f9934c44..f9fb2d5a77 100644 --- a/src/MANYBODY/pair_eim.h +++ b/src/MANYBODY/pair_eim.h @@ -20,7 +20,6 @@ PairStyle(eim,PairEIM) #ifndef LMP_PAIR_EIM_H #define LMP_PAIR_EIM_H -#include #include "pair.h" namespace LAMMPS_NS { diff --git a/src/MC/fix_atom_swap.h b/src/MC/fix_atom_swap.h index 19895704f1..a5ce89b16b 100644 --- a/src/MC/fix_atom_swap.h +++ b/src/MC/fix_atom_swap.h @@ -20,7 +20,6 @@ FixStyle(atom/swap,FixAtomSwap) #ifndef LMP_FIX_MCSWAP_H #define LMP_FIX_MCSWAP_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/MC/fix_gcmc.h b/src/MC/fix_gcmc.h index 5d0b7aab8f..da4232d19b 100644 --- a/src/MC/fix_gcmc.h +++ b/src/MC/fix_gcmc.h @@ -20,7 +20,6 @@ FixStyle(gcmc,FixGCMC) #ifndef LMP_FIX_GCMC_H #define LMP_FIX_GCMC_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/MISC/fix_deposit.h b/src/MISC/fix_deposit.h index 38958b80e7..e3104c890d 100644 --- a/src/MISC/fix_deposit.h +++ b/src/MISC/fix_deposit.h @@ -20,7 +20,6 @@ FixStyle(deposit,FixDeposit) #ifndef LMP_FIX_DEPOSIT_H #define LMP_FIX_DEPOSIT_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/angle_charmm.h b/src/MOLECULE/angle_charmm.h index 2228ad8732..444c833d37 100644 --- a/src/MOLECULE/angle_charmm.h +++ b/src/MOLECULE/angle_charmm.h @@ -20,7 +20,6 @@ AngleStyle(charmm,AngleCharmm) #ifndef LMP_ANGLE_CHARMM_H #define LMP_ANGLE_CHARMM_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/angle_cosine.h b/src/MOLECULE/angle_cosine.h index f2406bc5dd..ca1f4178f8 100644 --- a/src/MOLECULE/angle_cosine.h +++ b/src/MOLECULE/angle_cosine.h @@ -20,7 +20,6 @@ AngleStyle(cosine,AngleCosine) #ifndef LMP_ANGLE_COSINE_H #define LMP_ANGLE_COSINE_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/angle_cosine_delta.h b/src/MOLECULE/angle_cosine_delta.h index 1e19ecaf79..70b574b234 100644 --- a/src/MOLECULE/angle_cosine_delta.h +++ b/src/MOLECULE/angle_cosine_delta.h @@ -20,7 +20,6 @@ AngleStyle(cosine/delta,AngleCosineDelta) #ifndef LMP_ANGLE_COSINE_DELTA_H #define LMP_ANGLE_COSINE_DELTA_H -#include #include "angle_cosine_squared.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/angle_cosine_periodic.h b/src/MOLECULE/angle_cosine_periodic.h index e131e85101..f0188b6c17 100644 --- a/src/MOLECULE/angle_cosine_periodic.h +++ b/src/MOLECULE/angle_cosine_periodic.h @@ -20,7 +20,6 @@ AngleStyle(cosine/periodic, AngleCosinePeriodic) #ifndef LMP_ANGLE_PERIODIC_H #define LMP_ANGLE_PERIODIC_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/angle_cosine_squared.h b/src/MOLECULE/angle_cosine_squared.h index 8e8c84c0f9..a19a923850 100644 --- a/src/MOLECULE/angle_cosine_squared.h +++ b/src/MOLECULE/angle_cosine_squared.h @@ -20,7 +20,6 @@ AngleStyle(cosine/squared,AngleCosineSquared) #ifndef LMP_ANGLE_COSINE_SQUARED_H #define LMP_ANGLE_COSINE_SQUARED_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/angle_harmonic.h b/src/MOLECULE/angle_harmonic.h index e0c067653b..f371178d58 100644 --- a/src/MOLECULE/angle_harmonic.h +++ b/src/MOLECULE/angle_harmonic.h @@ -20,7 +20,6 @@ AngleStyle(harmonic,AngleHarmonic) #ifndef LMP_ANGLE_HARMONIC_H #define LMP_ANGLE_HARMONIC_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/angle_table.h b/src/MOLECULE/angle_table.h index 0088ace39b..46633d28cc 100644 --- a/src/MOLECULE/angle_table.h +++ b/src/MOLECULE/angle_table.h @@ -20,7 +20,6 @@ AngleStyle(table,AngleTable) #ifndef LMP_ANGLE_TABLE_H #define LMP_ANGLE_TABLE_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_fene.h b/src/MOLECULE/bond_fene.h index 58cd6ce289..1963e3ca22 100644 --- a/src/MOLECULE/bond_fene.h +++ b/src/MOLECULE/bond_fene.h @@ -20,7 +20,6 @@ BondStyle(fene,BondFENE) #ifndef LMP_BOND_FENE_H #define LMP_BOND_FENE_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_fene_expand.h b/src/MOLECULE/bond_fene_expand.h index cb316ac5f2..8cfc17dc68 100644 --- a/src/MOLECULE/bond_fene_expand.h +++ b/src/MOLECULE/bond_fene_expand.h @@ -20,7 +20,6 @@ BondStyle(fene/expand,BondFENEExpand) #ifndef LMP_BOND_FENE_EXPAND_H #define LMP_BOND_FENE_EXPAND_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_gromos.h b/src/MOLECULE/bond_gromos.h index c26ad64b3d..966b914437 100644 --- a/src/MOLECULE/bond_gromos.h +++ b/src/MOLECULE/bond_gromos.h @@ -20,7 +20,6 @@ BondStyle(gromos,BondGromos) #ifndef LMP_BOND_GROMOS_H #define LMP_BOND_GROMOS_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_harmonic.h b/src/MOLECULE/bond_harmonic.h index 5c692b2a8e..576e63629b 100644 --- a/src/MOLECULE/bond_harmonic.h +++ b/src/MOLECULE/bond_harmonic.h @@ -20,7 +20,6 @@ BondStyle(harmonic,BondHarmonic) #ifndef LMP_BOND_HARMONIC_H #define LMP_BOND_HARMONIC_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_morse.h b/src/MOLECULE/bond_morse.h index c4d60bc217..030a94a8da 100644 --- a/src/MOLECULE/bond_morse.h +++ b/src/MOLECULE/bond_morse.h @@ -20,7 +20,6 @@ BondStyle(morse,BondMorse) #ifndef LMP_BOND_MORSE_H #define LMP_BOND_MORSE_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_nonlinear.h b/src/MOLECULE/bond_nonlinear.h index 175421264b..7782b93778 100644 --- a/src/MOLECULE/bond_nonlinear.h +++ b/src/MOLECULE/bond_nonlinear.h @@ -20,7 +20,6 @@ BondStyle(nonlinear,BondNonlinear) #ifndef LMP_BOND_NONLINEAR_H #define LMP_BOND_NONLINEAR_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_quartic.h b/src/MOLECULE/bond_quartic.h index 2aaa76e2c3..60ccf307b9 100644 --- a/src/MOLECULE/bond_quartic.h +++ b/src/MOLECULE/bond_quartic.h @@ -20,7 +20,6 @@ BondStyle(quartic,BondQuartic) #ifndef LMP_BOND_QUARTIC_H #define LMP_BOND_QUARTIC_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/bond_table.h b/src/MOLECULE/bond_table.h index 5766239167..3db3ade3ab 100644 --- a/src/MOLECULE/bond_table.h +++ b/src/MOLECULE/bond_table.h @@ -20,7 +20,6 @@ BondStyle(table,BondTable) #ifndef LMP_BOND_TABLE_H #define LMP_BOND_TABLE_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/dihedral_charmm.h b/src/MOLECULE/dihedral_charmm.h index 8f51b398db..4be3925dad 100644 --- a/src/MOLECULE/dihedral_charmm.h +++ b/src/MOLECULE/dihedral_charmm.h @@ -20,7 +20,6 @@ DihedralStyle(charmm,DihedralCharmm) #ifndef LMP_DIHEDRAL_CHARMM_H #define LMP_DIHEDRAL_CHARMM_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/dihedral_charmmfsw.h b/src/MOLECULE/dihedral_charmmfsw.h index dd31067a8d..b33250004b 100644 --- a/src/MOLECULE/dihedral_charmmfsw.h +++ b/src/MOLECULE/dihedral_charmmfsw.h @@ -20,7 +20,6 @@ DihedralStyle(charmmfsw,DihedralCharmmfsw) #ifndef LMP_DIHEDRAL_CHARMMFSW_H #define LMP_DIHEDRAL_CHARMMFSW_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/dihedral_harmonic.h b/src/MOLECULE/dihedral_harmonic.h index 2031261256..938e59918b 100644 --- a/src/MOLECULE/dihedral_harmonic.h +++ b/src/MOLECULE/dihedral_harmonic.h @@ -20,7 +20,6 @@ DihedralStyle(harmonic,DihedralHarmonic) #ifndef LMP_DIHEDRAL_HARMONIC_H #define LMP_DIHEDRAL_HARMONIC_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/dihedral_helix.h b/src/MOLECULE/dihedral_helix.h index 745ab84115..0213c59e8a 100644 --- a/src/MOLECULE/dihedral_helix.h +++ b/src/MOLECULE/dihedral_helix.h @@ -20,7 +20,6 @@ DihedralStyle(helix,DihedralHelix) #ifndef LMP_DIHEDRAL_HELIX_H #define LMP_DIHEDRAL_HELIX_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/dihedral_multi_harmonic.h b/src/MOLECULE/dihedral_multi_harmonic.h index 32f17e75ae..bb3d7183f7 100644 --- a/src/MOLECULE/dihedral_multi_harmonic.h +++ b/src/MOLECULE/dihedral_multi_harmonic.h @@ -20,7 +20,6 @@ DihedralStyle(multi/harmonic,DihedralMultiHarmonic) #ifndef LMP_DIHEDRAL_MULTI_HARMONIC_H #define LMP_DIHEDRAL_MULTI_HARMONIC_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/dihedral_opls.h b/src/MOLECULE/dihedral_opls.h index c1e64ada1e..01878173cd 100644 --- a/src/MOLECULE/dihedral_opls.h +++ b/src/MOLECULE/dihedral_opls.h @@ -20,7 +20,6 @@ DihedralStyle(opls,DihedralOPLS) #ifndef LMP_DIHEDRAL_OPLS_H #define LMP_DIHEDRAL_OPLS_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/improper_cvff.h b/src/MOLECULE/improper_cvff.h index d4c30cc2ee..055d2ca9b8 100644 --- a/src/MOLECULE/improper_cvff.h +++ b/src/MOLECULE/improper_cvff.h @@ -20,7 +20,6 @@ ImproperStyle(cvff,ImproperCvff) #ifndef LMP_IMPROPER_CVFF_H #define LMP_IMPROPER_CVFF_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/improper_harmonic.h b/src/MOLECULE/improper_harmonic.h index fbbb8d33d6..5949c6911e 100644 --- a/src/MOLECULE/improper_harmonic.h +++ b/src/MOLECULE/improper_harmonic.h @@ -20,7 +20,6 @@ ImproperStyle(harmonic,ImproperHarmonic) #ifndef LMP_IMPROPER_HARMONIC_H #define LMP_IMPROPER_HARMONIC_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/MOLECULE/improper_umbrella.h b/src/MOLECULE/improper_umbrella.h index dc2262d01c..da9d6c8f4b 100644 --- a/src/MOLECULE/improper_umbrella.h +++ b/src/MOLECULE/improper_umbrella.h @@ -20,7 +20,6 @@ ImproperStyle(umbrella,ImproperUmbrella) #ifndef LMP_IMPROPER_UMBRELLA_H #define LMP_IMPROPER_UMBRELLA_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/REPLICA/neb.h b/src/REPLICA/neb.h index f585a0c8a7..b53992711c 100644 --- a/src/REPLICA/neb.h +++ b/src/REPLICA/neb.h @@ -20,7 +20,6 @@ CommandStyle(neb,NEB) #ifndef LMP_NEB_H #define LMP_NEB_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/SPIN/neb_spin.h b/src/SPIN/neb_spin.h index c128eaffa4..568eca0957 100644 --- a/src/SPIN/neb_spin.h +++ b/src/SPIN/neb_spin.h @@ -20,7 +20,6 @@ CommandStyle(neb/spin,NEBSpin) #ifndef LMP_NEB_SPIN_H #define LMP_NEB_SPIN_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/USER-CGDNA/mf_oxdna.h b/src/USER-CGDNA/mf_oxdna.h index c63a37cde2..e4ed1bbd03 100644 --- a/src/USER-CGDNA/mf_oxdna.h +++ b/src/USER-CGDNA/mf_oxdna.h @@ -14,7 +14,6 @@ #ifndef MF_OXDNA_H #define MF_OXDNA_H -#include #include "math_extra.h" namespace MFOxdna { diff --git a/src/USER-CGSDK/angle_sdk.h b/src/USER-CGSDK/angle_sdk.h index 293004ad4d..2e94b44470 100644 --- a/src/USER-CGSDK/angle_sdk.h +++ b/src/USER-CGSDK/angle_sdk.h @@ -20,7 +20,6 @@ AngleStyle(sdk,AngleSDK) #ifndef LMP_ANGLE_SDK_H #define LMP_ANGLE_SDK_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-DIFFRACTION/fix_saed_vtk.h b/src/USER-DIFFRACTION/fix_saed_vtk.h index 2fc09c781c..94abbf0194 100644 --- a/src/USER-DIFFRACTION/fix_saed_vtk.h +++ b/src/USER-DIFFRACTION/fix_saed_vtk.h @@ -20,7 +20,6 @@ FixStyle(saed/vtk,FixSAEDVTK) #ifndef LMP_FIX_SAED_VTK_H #define LMP_FIX_SAED_VTK_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/USER-INTEL/angle_charmm_intel.h b/src/USER-INTEL/angle_charmm_intel.h index 5d173ee6a9..155ecfaff9 100644 --- a/src/USER-INTEL/angle_charmm_intel.h +++ b/src/USER-INTEL/angle_charmm_intel.h @@ -24,7 +24,6 @@ AngleStyle(charmm/intel,AngleCharmmIntel) #ifndef LMP_ANGLE_CHARMM_INTEL_H #define LMP_ANGLE_CHARMM_INTEL_H -#include #include "angle_charmm.h" #include "fix_intel.h" diff --git a/src/USER-INTEL/angle_harmonic_intel.h b/src/USER-INTEL/angle_harmonic_intel.h index e7768542a1..c00292f7ce 100644 --- a/src/USER-INTEL/angle_harmonic_intel.h +++ b/src/USER-INTEL/angle_harmonic_intel.h @@ -24,7 +24,6 @@ AngleStyle(harmonic/intel,AngleHarmonicIntel) #ifndef LMP_ANGLE_HARMONIC_INTEL_H #define LMP_ANGLE_HARMONIC_INTEL_H -#include #include "angle_harmonic.h" #include "fix_intel.h" diff --git a/src/USER-INTEL/bond_fene_intel.h b/src/USER-INTEL/bond_fene_intel.h index afe3b85470..58fcdb8669 100644 --- a/src/USER-INTEL/bond_fene_intel.h +++ b/src/USER-INTEL/bond_fene_intel.h @@ -24,7 +24,6 @@ BondStyle(fene/intel,BondFENEIntel) #ifndef LMP_BOND_FENE_INTEL_H #define LMP_BOND_FENE_INTEL_H -#include #include "bond_fene.h" #include "fix_intel.h" diff --git a/src/USER-INTEL/bond_harmonic_intel.h b/src/USER-INTEL/bond_harmonic_intel.h index b86a560d6e..3c1d050a3b 100644 --- a/src/USER-INTEL/bond_harmonic_intel.h +++ b/src/USER-INTEL/bond_harmonic_intel.h @@ -24,7 +24,6 @@ BondStyle(harmonic/intel,BondHarmonicIntel) #ifndef LMP_BOND_HARMONIC_INTEL_H #define LMP_BOND_HARMONIC_INTEL_H -#include #include "bond_harmonic.h" #include "fix_intel.h" diff --git a/src/USER-INTEL/improper_cvff_intel.h b/src/USER-INTEL/improper_cvff_intel.h index e815fa75c9..812b49d50c 100644 --- a/src/USER-INTEL/improper_cvff_intel.h +++ b/src/USER-INTEL/improper_cvff_intel.h @@ -24,7 +24,6 @@ ImproperStyle(cvff/intel,ImproperCvffIntel) #ifndef LMP_IMPROPER_CVFF_INTEL_H #define LMP_IMPROPER_CVFF_INTEL_H -#include #include "improper_cvff.h" #include "fix_intel.h" diff --git a/src/USER-INTEL/improper_harmonic_intel.h b/src/USER-INTEL/improper_harmonic_intel.h index ce38e8fc31..6d7c829961 100644 --- a/src/USER-INTEL/improper_harmonic_intel.h +++ b/src/USER-INTEL/improper_harmonic_intel.h @@ -24,7 +24,6 @@ ImproperStyle(harmonic/intel,ImproperHarmonicIntel) #ifndef LMP_IMPROPER_HARMONIC_INTEL_H #define LMP_IMPROPER_HARMONIC_INTEL_H -#include #include "improper_harmonic.h" #include "fix_intel.h" diff --git a/src/USER-INTEL/intel_simd.h b/src/USER-INTEL/intel_simd.h index 75fc9828b9..9022f439c4 100644 --- a/src/USER-INTEL/intel_simd.h +++ b/src/USER-INTEL/intel_simd.h @@ -29,7 +29,6 @@ authors for more details. #ifndef INTEL_SIMD_H #define INTEL_SIMD_H -#include #include "intel_preprocess.h" #include "immintrin.h" diff --git a/src/USER-INTEL/pair_eam_intel.h b/src/USER-INTEL/pair_eam_intel.h index 83b1fbf6a1..a9590f6b3d 100644 --- a/src/USER-INTEL/pair_eam_intel.h +++ b/src/USER-INTEL/pair_eam_intel.h @@ -20,7 +20,6 @@ PairStyle(eam/intel,PairEAMIntel) #ifndef LMP_PAIR_EAM_INTEL_H #define LMP_PAIR_EAM_INTEL_H -#include #include "pair_eam.h" #include "fix_intel.h" diff --git a/src/USER-MANIFOLD/manifold_thylakoid.h b/src/USER-MANIFOLD/manifold_thylakoid.h index 5e5d3b9c41..d8ebe2e94f 100644 --- a/src/USER-MANIFOLD/manifold_thylakoid.h +++ b/src/USER-MANIFOLD/manifold_thylakoid.h @@ -3,7 +3,6 @@ #include "manifold.h" #include -#include #include "manifold_thylakoid_shared.h" diff --git a/src/USER-MGPT/mgpt_readpot.h b/src/USER-MGPT/mgpt_readpot.h index c19ea40774..62f66883b6 100644 --- a/src/USER-MGPT/mgpt_readpot.h +++ b/src/USER-MGPT/mgpt_readpot.h @@ -19,7 +19,6 @@ #ifndef READPOT__ #define READPOT__ -#include #include "mgpt_splinetab.h" diff --git a/src/USER-MGPT/pair_mgpt.h b/src/USER-MGPT/pair_mgpt.h index 94c66fb603..70b36364b1 100644 --- a/src/USER-MGPT/pair_mgpt.h +++ b/src/USER-MGPT/pair_mgpt.h @@ -32,7 +32,6 @@ PairStyle(mgpt,PairMGPT) #include #include -#include #include #include "pair.h" diff --git a/src/USER-MISC/angle_cosine_shift.h b/src/USER-MISC/angle_cosine_shift.h index 030709a0e2..febabcc090 100644 --- a/src/USER-MISC/angle_cosine_shift.h +++ b/src/USER-MISC/angle_cosine_shift.h @@ -20,7 +20,6 @@ AngleStyle(cosine/shift,AngleCosineShift) #ifndef LMP_ANGLE_COSINE_SHIFT_H #define LMP_ANGLE_COSINE_SHIFT_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/angle_cosine_shift_exp.h b/src/USER-MISC/angle_cosine_shift_exp.h index 8b8e389380..9614ddcc19 100644 --- a/src/USER-MISC/angle_cosine_shift_exp.h +++ b/src/USER-MISC/angle_cosine_shift_exp.h @@ -18,7 +18,6 @@ AngleStyle(cosine/shift/exp,AngleCosineShiftExp) #ifndef LMP_ANGLE_COSINE_SHIFT_EXP_H #define LMP_ANGLE_COSINE_SHIFT_EXP_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/angle_dipole.h b/src/USER-MISC/angle_dipole.h index 6c5dccb803..187822d0d4 100644 --- a/src/USER-MISC/angle_dipole.h +++ b/src/USER-MISC/angle_dipole.h @@ -20,7 +20,6 @@ AngleStyle(dipole,AngleDipole) #ifndef LMP_ANGLE_DIPOLE_H #define LMP_ANGLE_DIPOLE_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/angle_fourier.h b/src/USER-MISC/angle_fourier.h index 14b4eedf57..53eeea98da 100644 --- a/src/USER-MISC/angle_fourier.h +++ b/src/USER-MISC/angle_fourier.h @@ -20,7 +20,6 @@ AngleStyle(fourier,AngleFourier) #ifndef ANGLE_FOURIER_H #define ANGLE_FOURIER_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/angle_fourier_simple.h b/src/USER-MISC/angle_fourier_simple.h index 3a7bd37750..df2253317f 100644 --- a/src/USER-MISC/angle_fourier_simple.h +++ b/src/USER-MISC/angle_fourier_simple.h @@ -20,7 +20,6 @@ AngleStyle(fourier/simple,AngleFourierSimple) #ifndef ANGLE_FOURIER_SIMPLE_H #define ANGLE_FOURIER_SIMPLE_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/angle_quartic.h b/src/USER-MISC/angle_quartic.h index 7043cab064..b916a5f89f 100644 --- a/src/USER-MISC/angle_quartic.h +++ b/src/USER-MISC/angle_quartic.h @@ -20,7 +20,6 @@ AngleStyle(quartic,AngleQuartic) #ifndef LMP_ANGLE_QUARTIC_H #define LMP_ANGLE_QUARTIC_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/bond_harmonic_shift.h b/src/USER-MISC/bond_harmonic_shift.h index ff0d358243..b77cefb4af 100644 --- a/src/USER-MISC/bond_harmonic_shift.h +++ b/src/USER-MISC/bond_harmonic_shift.h @@ -20,7 +20,6 @@ BondStyle(harmonic/shift,BondHarmonicShift) #ifndef LMP_BOND_HARMONIC_SHIFT_H #define LMP_BOND_HARMONIC_SHIFT_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/bond_harmonic_shift_cut.h b/src/USER-MISC/bond_harmonic_shift_cut.h index 5db76d51aa..ad2bcd61ad 100644 --- a/src/USER-MISC/bond_harmonic_shift_cut.h +++ b/src/USER-MISC/bond_harmonic_shift_cut.h @@ -20,7 +20,6 @@ BondStyle(harmonic/shift/cut,BondHarmonicShiftCut) #ifndef LMP_BOND_HARMONIC_SHIFT_CUT_H #define LMP_BOND_HARMONIC_SHIFT_CUT_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/dihedral_cosine_shift_exp.h b/src/USER-MISC/dihedral_cosine_shift_exp.h index fc4be5049b..4d180f42de 100644 --- a/src/USER-MISC/dihedral_cosine_shift_exp.h +++ b/src/USER-MISC/dihedral_cosine_shift_exp.h @@ -20,7 +20,6 @@ DihedralStyle(cosine/shift/exp,DihedralCosineShiftExp) #ifndef LMP_DIHEDRAL_COSINE_SHIFT_EXP_H #define LMP_DIHEDRAL_COSINE_SHIFT_EXP_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/dihedral_fourier.h b/src/USER-MISC/dihedral_fourier.h index c1ed843c34..8b6291fc4c 100644 --- a/src/USER-MISC/dihedral_fourier.h +++ b/src/USER-MISC/dihedral_fourier.h @@ -20,7 +20,6 @@ DihedralStyle(fourier,DihedralFourier) #ifndef LMP_DIHEDRAL_FOURIER_H #define LMP_DIHEDRAL_FOURIER_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/dihedral_nharmonic.h b/src/USER-MISC/dihedral_nharmonic.h index 7c6a35b200..6fd1da3b8b 100644 --- a/src/USER-MISC/dihedral_nharmonic.h +++ b/src/USER-MISC/dihedral_nharmonic.h @@ -20,7 +20,6 @@ DihedralStyle(nharmonic,DihedralNHarmonic) #ifndef DIHEDRAL_NHARMONIC_H #define DIHEDRAL_NHARMONIC_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/dihedral_quadratic.h b/src/USER-MISC/dihedral_quadratic.h index edc29c3cf8..0b99cbc4f7 100644 --- a/src/USER-MISC/dihedral_quadratic.h +++ b/src/USER-MISC/dihedral_quadratic.h @@ -20,7 +20,6 @@ DihedralStyle(quadratic,DihedralQuadratic) #ifndef LMP_DIHEDRAL_QUADRATIC_H #define LMP_DIHEDRAL_QUADRATIC_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/dihedral_spherical.h b/src/USER-MISC/dihedral_spherical.h index ae0ece189a..472db36f33 100644 --- a/src/USER-MISC/dihedral_spherical.h +++ b/src/USER-MISC/dihedral_spherical.h @@ -20,7 +20,6 @@ DihedralStyle(spherical,DihedralSpherical) #ifndef LMP_DIHEDRAL_SPHERICAL_H #define LMP_DIHEDRAL_SPHERICAL_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/fix_ave_correlate_long.h b/src/USER-MISC/fix_ave_correlate_long.h index 548a0e7183..a0c5863e99 100644 --- a/src/USER-MISC/fix_ave_correlate_long.h +++ b/src/USER-MISC/fix_ave_correlate_long.h @@ -20,7 +20,6 @@ FixStyle(ave/correlate/long,FixAveCorrelateLong) #ifndef LMP_FIX_AVE_CORRELATE_LONG_H #define LMP_FIX_AVE_CORRELATE_LONG_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/fix_srp.h b/src/USER-MISC/fix_srp.h index 7dbf044bda..f8343df8a6 100644 --- a/src/USER-MISC/fix_srp.h +++ b/src/USER-MISC/fix_srp.h @@ -20,7 +20,6 @@ FixStyle(SRP,FixSRP) #ifndef LMP_FIX_SRP_H #define LMP_FIX_SRP_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/improper_cossq.h b/src/USER-MISC/improper_cossq.h index ea880adfaf..9e430bfa1a 100644 --- a/src/USER-MISC/improper_cossq.h +++ b/src/USER-MISC/improper_cossq.h @@ -20,7 +20,6 @@ ImproperStyle(cossq,ImproperCossq) #ifndef LMP_IMPROPER_COSSQ_H #define LMP_IMPROPER_COSSQ_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/improper_distance.h b/src/USER-MISC/improper_distance.h index 57e4d671e9..d7575c3585 100644 --- a/src/USER-MISC/improper_distance.h +++ b/src/USER-MISC/improper_distance.h @@ -20,7 +20,6 @@ ImproperStyle(distance,ImproperDistance) #ifndef LMP_IMPROPER_DISTANCE_H #define LMP_IMPROPER_DISTANCE_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/improper_fourier.h b/src/USER-MISC/improper_fourier.h index 0525c45494..91dfacfd8e 100644 --- a/src/USER-MISC/improper_fourier.h +++ b/src/USER-MISC/improper_fourier.h @@ -20,7 +20,6 @@ ImproperStyle(fourier,ImproperFourier) #ifndef LMP_IMPROPER_FOURIER_H #define LMP_IMPROPER_FOURIER_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/USER-MISC/improper_ring.h b/src/USER-MISC/improper_ring.h index c31329816f..7c53c6f59f 100644 --- a/src/USER-MISC/improper_ring.h +++ b/src/USER-MISC/improper_ring.h @@ -20,7 +20,6 @@ ImproperStyle(ring,ImproperRing) #ifndef LMP_IMPROPER_RING_H #define LMP_IMPROPER_RING_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/USER-MOFFF/angle_class2_p6.h b/src/USER-MOFFF/angle_class2_p6.h index b583a45b19..f2f324c0c6 100644 --- a/src/USER-MOFFF/angle_class2_p6.h +++ b/src/USER-MOFFF/angle_class2_p6.h @@ -20,7 +20,6 @@ AngleStyle(class2/p6,AngleClass2P6) #ifndef LMP_ANGLE_CLASS2_P6_H #define LMP_ANGLE_CLASS2_P6_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MOFFF/angle_cosine_buck6d.h b/src/USER-MOFFF/angle_cosine_buck6d.h index 689b1634e0..1d0df10228 100644 --- a/src/USER-MOFFF/angle_cosine_buck6d.h +++ b/src/USER-MOFFF/angle_cosine_buck6d.h @@ -20,7 +20,6 @@ AngleStyle(cosine/buck6d, AngleCosineBuck6d) #ifndef LMP_ANGLE_COSINE_BUCK6D_H #define LMP_ANGLE_COSINE_BUCK6D_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-MOFFF/improper_inversion_harmonic.h b/src/USER-MOFFF/improper_inversion_harmonic.h index 201c9e358d..206b40aebf 100644 --- a/src/USER-MOFFF/improper_inversion_harmonic.h +++ b/src/USER-MOFFF/improper_inversion_harmonic.h @@ -20,7 +20,6 @@ ImproperStyle(inversion/harmonic,ImproperInversionHarmonic) #ifndef LMP_IMPROPER_INVERSION_HARMONIC_H #define LMP_IMPROPER_INVERSION_HARMONIC_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/USER-REAXC/fix_reaxc_bonds.h b/src/USER-REAXC/fix_reaxc_bonds.h index d72f5446b5..60f41beb02 100644 --- a/src/USER-REAXC/fix_reaxc_bonds.h +++ b/src/USER-REAXC/fix_reaxc_bonds.h @@ -20,7 +20,6 @@ FixStyle(reax/c/bonds,FixReaxCBonds) #ifndef LMP_FIX_REAXC_BONDS_H #define LMP_FIX_REAXC_BONDS_H -#include #include "fix.h" #include "pointers.h" diff --git a/src/bond_hybrid.h b/src/bond_hybrid.h index e51d467ac1..19e4debfed 100644 --- a/src/bond_hybrid.h +++ b/src/bond_hybrid.h @@ -20,7 +20,6 @@ BondStyle(hybrid,BondHybrid) #ifndef LMP_BOND_HYBRID_H #define LMP_BOND_HYBRID_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/bond_zero.h b/src/bond_zero.h index 9443ff0784..7cbd2b9a96 100644 --- a/src/bond_zero.h +++ b/src/bond_zero.h @@ -20,7 +20,6 @@ BondStyle(zero,BondZero) #ifndef LMP_BOND_ZERO_H #define LMP_BOND_ZERO_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/citeme.cpp b/src/citeme.cpp index 24896b448c..c8745891cf 100644 --- a/src/citeme.cpp +++ b/src/citeme.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "citeme.h" #include "universe.h" diff --git a/src/comm_brick.cpp b/src/comm_brick.cpp index 47f60a3da6..dcf30807f5 100644 --- a/src/comm_brick.cpp +++ b/src/comm_brick.cpp @@ -18,7 +18,6 @@ #include #include #include -#include #include "comm_brick.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/comm_tiled.cpp b/src/comm_tiled.cpp index d1d625445a..a85520ed45 100644 --- a/src/comm_tiled.cpp +++ b/src/comm_tiled.cpp @@ -11,19 +11,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "comm_tiled.h" -#include "comm_brick.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" -#include "force.h" #include "pair.h" #include "neighbor.h" -#include "modify.h" #include "fix.h" #include "compute.h" -#include "output.h" #include "dump.h" #include "memory.h" #include "error.h" diff --git a/src/comm_tiled.h b/src/comm_tiled.h index 13ecbc4b01..5a9beb28f7 100644 --- a/src/comm_tiled.h +++ b/src/comm_tiled.h @@ -14,6 +14,7 @@ #ifndef LMP_COMM_TILED_H #define LMP_COMM_TILED_H +#include #include "comm.h" namespace LAMMPS_NS { diff --git a/src/compute.cpp b/src/compute.cpp index 207f825ec8..8ff8487104 100644 --- a/src/compute.cpp +++ b/src/compute.cpp @@ -11,15 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include #include #include "compute.h" -#include "atom.h" #include "domain.h" #include "force.h" -#include "comm.h" #include "group.h" #include "modify.h" #include "fix.h" diff --git a/src/compute_adf.h b/src/compute_adf.h index a7983b7173..f768013207 100644 --- a/src/compute_adf.h +++ b/src/compute_adf.h @@ -20,7 +20,6 @@ ComputeStyle(adf,ComputeADF) #ifndef LMP_COMPUTE_ADF_H #define LMP_COMPUTE_ADF_H -#include #include "compute.h" namespace LAMMPS_NS { diff --git a/src/compute_rdf.h b/src/compute_rdf.h index 52a93a38dd..85f6ce6ad2 100644 --- a/src/compute_rdf.h +++ b/src/compute_rdf.h @@ -20,7 +20,6 @@ ComputeStyle(rdf,ComputeRDF) #ifndef LMP_COMPUTE_RDF_H #define LMP_COMPUTE_RDF_H -#include #include "compute.h" namespace LAMMPS_NS { diff --git a/src/dihedral_hybrid.h b/src/dihedral_hybrid.h index 0839fdfc61..2804060af4 100644 --- a/src/dihedral_hybrid.h +++ b/src/dihedral_hybrid.h @@ -20,7 +20,6 @@ DihedralStyle(hybrid,DihedralHybrid) #ifndef LMP_DIHEDRAL_HYBRID_H #define LMP_DIHEDRAL_HYBRID_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/dihedral_zero.h b/src/dihedral_zero.h index e7dbb0d3a5..e97f8f6641 100644 --- a/src/dihedral_zero.h +++ b/src/dihedral_zero.h @@ -24,7 +24,6 @@ DihedralStyle(zero,DihedralZero) #ifndef LMP_DIHEDRAL_ZERO_H #define LMP_DIHEDRAL_ZERO_H -#include #include "dihedral.h" namespace LAMMPS_NS { diff --git a/src/fix_ave_atom.h b/src/fix_ave_atom.h index e4baf6bda1..42aa282d53 100644 --- a/src/fix_ave_atom.h +++ b/src/fix_ave_atom.h @@ -20,7 +20,6 @@ FixStyle(ave/atom,FixAveAtom) #ifndef LMP_FIX_AVE_ATOM_H #define LMP_FIX_AVE_ATOM_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_ave_chunk.h b/src/fix_ave_chunk.h index 4dc1c1c246..dac5761ae8 100644 --- a/src/fix_ave_chunk.h +++ b/src/fix_ave_chunk.h @@ -20,7 +20,6 @@ FixStyle(ave/chunk,FixAveChunk) #ifndef LMP_FIX_AVE_CHUNK_H #define LMP_FIX_AVE_CHUNK_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_ave_correlate.h b/src/fix_ave_correlate.h index ff20e8ba94..05fd6b6576 100644 --- a/src/fix_ave_correlate.h +++ b/src/fix_ave_correlate.h @@ -20,7 +20,6 @@ FixStyle(ave/correlate,FixAveCorrelate) #ifndef LMP_FIX_AVE_CORRELATE_H #define LMP_FIX_AVE_CORRELATE_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_ave_histo.h b/src/fix_ave_histo.h index 3616959c61..35bdfcfa7f 100644 --- a/src/fix_ave_histo.h +++ b/src/fix_ave_histo.h @@ -20,7 +20,6 @@ FixStyle(ave/histo,FixAveHisto) #ifndef LMP_FIX_AVE_HISTO_H #define LMP_FIX_AVE_HISTO_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_ave_histo_weight.h b/src/fix_ave_histo_weight.h index e5638e1215..6ec3ba5721 100644 --- a/src/fix_ave_histo_weight.h +++ b/src/fix_ave_histo_weight.h @@ -20,7 +20,6 @@ FixStyle(ave/histo/weight,FixAveHistoWeight) #ifndef LMP_FIX_AVE_HISTO_WEIGHT_H #define LMP_FIX_AVE_HISTO_WEIGHT_H -#include #include "fix_ave_histo.h" namespace LAMMPS_NS { diff --git a/src/fix_ave_time.h b/src/fix_ave_time.h index 62dfbad296..01228f9e55 100644 --- a/src/fix_ave_time.h +++ b/src/fix_ave_time.h @@ -20,7 +20,6 @@ FixStyle(ave/time,FixAveTime) #ifndef LMP_FIX_AVE_TIME_H #define LMP_FIX_AVE_TIME_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_balance.h b/src/fix_balance.h index 64383b5950..76cbea258a 100644 --- a/src/fix_balance.h +++ b/src/fix_balance.h @@ -20,7 +20,6 @@ FixStyle(balance,FixBalance) #ifndef LMP_FIX_BALANCE_H #define LMP_FIX_BALANCE_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_halt.h b/src/fix_halt.h index 372c915a7f..93c5e95078 100644 --- a/src/fix_halt.h +++ b/src/fix_halt.h @@ -20,7 +20,6 @@ FixStyle(halt,FixHalt) #ifndef LMP_FIX_HALT_H #define LMP_FIX_HALT_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_move.h b/src/fix_move.h index 5993d7d6e8..740b051be0 100644 --- a/src/fix_move.h +++ b/src/fix_move.h @@ -20,7 +20,6 @@ FixStyle(move,FixMove) #ifndef LMP_FIX_MOVE_H #define LMP_FIX_MOVE_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_print.h b/src/fix_print.h index 37b6680aee..5644160220 100644 --- a/src/fix_print.h +++ b/src/fix_print.h @@ -20,7 +20,6 @@ FixStyle(print,FixPrint) #ifndef LMP_FIX_PRINT_H #define LMP_FIX_PRINT_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_store.h b/src/fix_store.h index 5524770a97..437c14f0f7 100644 --- a/src/fix_store.h +++ b/src/fix_store.h @@ -20,7 +20,6 @@ FixStyle(STORE,FixStore) #ifndef LMP_FIX_STORE_H #define LMP_FIX_STORE_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/fix_tmd.h b/src/fix_tmd.h index b6db41dd5a..f23a64a027 100644 --- a/src/fix_tmd.h +++ b/src/fix_tmd.h @@ -20,7 +20,6 @@ FixStyle(tmd,FixTMD) #ifndef LMP_FIX_TMD_H #define LMP_FIX_TMD_H -#include #include "fix.h" namespace LAMMPS_NS { diff --git a/src/force.h b/src/force.h index 227b9427c0..26a3ecdfb8 100644 --- a/src/force.h +++ b/src/force.h @@ -15,7 +15,6 @@ #define LMP_FORCE_H #include "pointers.h" -#include #include #include diff --git a/src/group.h b/src/group.h index 962d37b32a..ec913f98bc 100644 --- a/src/group.h +++ b/src/group.h @@ -14,7 +14,6 @@ #ifndef LMP_GROUP_H #define LMP_GROUP_H -#include #include "pointers.h" #include diff --git a/src/image.h b/src/image.h index 5672bf85c5..7df81425d9 100644 --- a/src/image.h +++ b/src/image.h @@ -15,7 +15,6 @@ #define LMP_IMAGE_H #include -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/imbalance.h b/src/imbalance.h index d3c3b9a642..5f43c2e51d 100644 --- a/src/imbalance.h +++ b/src/imbalance.h @@ -14,7 +14,6 @@ #ifndef LMP_IMBALANCE_H #define LMP_IMBALANCE_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/improper_hybrid.h b/src/improper_hybrid.h index 89595ccfc4..3e5423b173 100644 --- a/src/improper_hybrid.h +++ b/src/improper_hybrid.h @@ -20,7 +20,6 @@ ImproperStyle(hybrid,ImproperHybrid) #ifndef LMP_IMPROPER_HYBRID_H #define LMP_IMPROPER_HYBRID_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/improper_zero.h b/src/improper_zero.h index 0a2290b6f7..1a70059070 100644 --- a/src/improper_zero.h +++ b/src/improper_zero.h @@ -20,7 +20,6 @@ ImproperStyle(zero,ImproperZero) #ifndef LMP_IMPROPER_ZERO_H #define LMP_IMPROPER_ZERO_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/input.h b/src/input.h index 33e83bfb06..9573b569bc 100644 --- a/src/input.h +++ b/src/input.h @@ -14,7 +14,6 @@ #ifndef LMP_INPUT_H #define LMP_INPUT_H -#include #include "pointers.h" #include #include diff --git a/src/lammps.h b/src/lammps.h index e02d0c764a..5820f25591 100644 --- a/src/lammps.h +++ b/src/lammps.h @@ -14,7 +14,6 @@ #ifndef LMP_LAMMPS_H #define LMP_LAMMPS_H -#include namespace LAMMPS_NS { diff --git a/src/modify.h b/src/modify.h index 5ff81855fe..b736485196 100644 --- a/src/modify.h +++ b/src/modify.h @@ -14,7 +14,6 @@ #ifndef LMP_MODIFY_H #define LMP_MODIFY_H -#include #include "pointers.h" #include #include diff --git a/src/pair_hybrid.h b/src/pair_hybrid.h index e313e16f18..074517a859 100644 --- a/src/pair_hybrid.h +++ b/src/pair_hybrid.h @@ -20,7 +20,6 @@ PairStyle(hybrid,PairHybrid) #ifndef LMP_PAIR_HYBRID_H #define LMP_PAIR_HYBRID_H -#include #include "pair.h" namespace LAMMPS_NS { diff --git a/src/read_data.h b/src/read_data.h index 26ab6ff381..98de607f6b 100644 --- a/src/read_data.h +++ b/src/read_data.h @@ -20,7 +20,6 @@ CommandStyle(read_data,ReadData) #ifndef LMP_READ_DATA_H #define LMP_READ_DATA_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/read_dump.h b/src/read_dump.h index 3ee13f779c..6fb4f11ed1 100644 --- a/src/read_dump.h +++ b/src/read_dump.h @@ -23,7 +23,6 @@ CommandStyle(read_dump,ReadDump) #define LMP_READ_DUMP_H #include -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/read_restart.h b/src/read_restart.h index 23d6ec3fba..63adf37b22 100644 --- a/src/read_restart.h +++ b/src/read_restart.h @@ -20,7 +20,6 @@ CommandStyle(read_restart,ReadRestart) #ifndef LMP_READ_RESTART_H #define LMP_READ_RESTART_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/universe.h b/src/universe.h index 3073409b86..fd6655c749 100644 --- a/src/universe.h +++ b/src/universe.h @@ -14,7 +14,6 @@ #ifndef LMP_UNIVERSE_H #define LMP_UNIVERSE_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/variable.h b/src/variable.h index c5f501f266..a504da14ec 100644 --- a/src/variable.h +++ b/src/variable.h @@ -14,7 +14,6 @@ #ifndef LMP_VARIABLE_H #define LMP_VARIABLE_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/write_coeff.h b/src/write_coeff.h index 569a615e6e..b995e60d63 100644 --- a/src/write_coeff.h +++ b/src/write_coeff.h @@ -20,7 +20,6 @@ CommandStyle(write_coeff,WriteCoeff) #ifndef LMP_WRITE_COEFF_H #define LMP_WRITE_COEFF_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/write_data.h b/src/write_data.h index 6f1bb2ec47..1c0f6b2a7c 100644 --- a/src/write_data.h +++ b/src/write_data.h @@ -20,7 +20,6 @@ CommandStyle(write_data,WriteData) #ifndef LMP_WRITE_DATA_H #define LMP_WRITE_DATA_H -#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/write_restart.h b/src/write_restart.h index c6202acbfd..e7cdc6a501 100644 --- a/src/write_restart.h +++ b/src/write_restart.h @@ -20,7 +20,6 @@ CommandStyle(write_restart,WriteRestart) #ifndef LMP_WRITE_RESTART_H #define LMP_WRITE_RESTART_H -#include #include "pointers.h" namespace LAMMPS_NS { From 123bd57376066ade0dc92c891bd97de152afd2ad Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 21:59:05 -0400 Subject: [PATCH 14/79] try to make KOKKOS compile again --- src/KOKKOS/kokkos_type.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/KOKKOS/kokkos_type.h b/src/KOKKOS/kokkos_type.h index 942c2af241..e900bbd6d1 100644 --- a/src/KOKKOS/kokkos_type.h +++ b/src/KOKKOS/kokkos_type.h @@ -14,7 +14,7 @@ #ifndef LMP_LMPTYPE_KOKKOS_H #define LMP_LMPTYPE_KOKKOS_H -#include "lmptype.h" +#include "pointers.h" #include #include From 2c119551f7af4eb6dfe1d0424debdec0d6089f80 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 22:13:42 -0400 Subject: [PATCH 15/79] add statement about order of include files --- doc/include-file-conventions.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/doc/include-file-conventions.md b/doc/include-file-conventions.md index 5152051ba5..8d70d6cdec 100644 --- a/doc/include-file-conventions.md +++ b/doc/include-file-conventions.md @@ -94,6 +94,14 @@ In the implementation files (typically, those would have the same base name as the corresponding header with a .cpp extension instead of .h) include statments should follow the "include what you use" principle. +### Order of Include Statements + +Include files should be included in this order: +* lmptype.h (should only be included if `MPI_LMP_XXX` data types are used) +* mpi.h +* system and library headers (anything that is using angular brackets; C-library headers first, then C++) +* LAMMPS local headers (first the header matching the implementation file, the rest in mostly alphabetical order) + ### Special Cases and Exceptions #### pointers.h From a5cb6ddd4a798e4618e2e506ad9d14021f0c4670 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 27 Jun 2019 22:14:06 -0400 Subject: [PATCH 16/79] lammps.h must include cstdio and mpi.h --- src/lammps.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/lammps.h b/src/lammps.h index 5820f25591..dc2916f214 100644 --- a/src/lammps.h +++ b/src/lammps.h @@ -14,6 +14,8 @@ #ifndef LMP_LAMMPS_H #define LMP_LAMMPS_H +#include +#include namespace LAMMPS_NS { From 378474c4e642f34614d471953bb3758c04c8754a Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 28 Jun 2019 02:01:08 -0400 Subject: [PATCH 17/79] more include file cleanup suggested by IWYU --- src/atom_map.cpp | 1 - src/atom_vec_body.cpp | 1 + src/bond_hybrid.cpp | 1 - src/bond_zero.cpp | 1 - src/comm.h | 2 +- src/comm_tiled.cpp | 1 + src/compute_adf.cpp | 3 --- src/compute_aggregate_atom.cpp | 1 + src/compute_angle.cpp | 2 +- src/compute_angmom_chunk.cpp | 1 + src/compute_bond.cpp | 2 +- src/compute_centro_atom.cpp | 1 - src/compute_chunk_atom.cpp | 6 ++++-- src/compute_cluster_atom.cpp | 2 +- src/compute_cna_atom.cpp | 2 +- src/compute_com_chunk.cpp | 1 + src/compute_contact_atom.cpp | 3 --- src/compute_coord_atom.cpp | 1 - src/compute_dihedral.cpp | 2 +- src/compute_dihedral_local.cpp | 2 -- src/compute_dipole_chunk.cpp | 2 ++ src/compute_displace_atom.cpp | 1 - src/compute_erotate_sphere.cpp | 3 --- src/compute_fragment_atom.cpp | 1 + src/compute_global_atom.cpp | 4 ---- src/compute_group_group.cpp | 1 - src/compute_gyration.cpp | 2 +- src/compute_gyration_chunk.cpp | 1 + src/compute_heat_flux.cpp | 3 +-- src/compute_hexorder_atom.cpp | 4 ++-- src/compute_improper.cpp | 2 +- src/compute_improper_local.cpp | 1 - src/compute_inertia_chunk.cpp | 1 + src/compute_ke.cpp | 2 -- src/compute_msd.cpp | 1 + src/compute_msd_chunk.cpp | 1 + src/compute_omega_chunk.cpp | 1 + src/compute_pair_local.cpp | 1 - src/compute_pe_atom.cpp | 1 - src/compute_pressure.cpp | 1 - src/compute_property_chunk.cpp | 1 + src/compute_rdf.cpp | 1 - src/compute_reduce.cpp | 2 -- src/compute_reduce_region.cpp | 3 +-- 44 files changed, 30 insertions(+), 47 deletions(-) diff --git a/src/atom_map.cpp b/src/atom_map.cpp index b14ebdba68..6af3b9c288 100644 --- a/src/atom_map.cpp +++ b/src/atom_map.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include "pointers.h" #include #include #include "atom.h" diff --git a/src/atom_vec_body.cpp b/src/atom_vec_body.cpp index 3e9528d6b9..fad5b3eae0 100644 --- a/src/atom_vec_body.cpp +++ b/src/atom_vec_body.cpp @@ -13,6 +13,7 @@ #include #include +#include #include "atom_vec_body.h" #include "my_pool_chunk.h" #include "style_body.h" diff --git a/src/bond_hybrid.cpp b/src/bond_hybrid.cpp index 0fb23a3214..9028886758 100644 --- a/src/bond_hybrid.cpp +++ b/src/bond_hybrid.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include #include "bond_hybrid.h" diff --git a/src/bond_zero.cpp b/src/bond_zero.cpp index 3932846cb4..c473abbe4b 100644 --- a/src/bond_zero.cpp +++ b/src/bond_zero.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "bond_zero.h" #include "atom.h" diff --git a/src/comm.h b/src/comm.h index 30360b1059..6d5592585f 100644 --- a/src/comm.h +++ b/src/comm.h @@ -14,7 +14,7 @@ #ifndef LMP_COMM_H #define LMP_COMM_H -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/comm_tiled.cpp b/src/comm_tiled.cpp index a85520ed45..385b7fdf22 100644 --- a/src/comm_tiled.cpp +++ b/src/comm_tiled.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include #include "comm_tiled.h" diff --git a/src/compute_adf.cpp b/src/compute_adf.cpp index e9f9ba2b6f..a17561ff54 100644 --- a/src/compute_adf.cpp +++ b/src/compute_adf.cpp @@ -17,18 +17,15 @@ #include #include -#include #include #include "compute_adf.h" #include "atom.h" #include "update.h" #include "force.h" #include "pair.h" -#include "domain.h" #include "neighbor.h" #include "neigh_request.h" #include "neigh_list.h" -#include "group.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/compute_aggregate_atom.cpp b/src/compute_aggregate_atom.cpp index 6c8c8e5d9a..9a797124bd 100644 --- a/src/compute_aggregate_atom.cpp +++ b/src/compute_aggregate_atom.cpp @@ -15,6 +15,7 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include #include #include #include "compute_aggregate_atom.h" diff --git a/src/compute_angle.cpp b/src/compute_angle.cpp index 59945f5832..c1c02a1cc4 100644 --- a/src/compute_angle.cpp +++ b/src/compute_angle.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include -#include #include "compute_angle.h" +#include "angle.h" #include "update.h" #include "force.h" #include "angle_hybrid.h" diff --git a/src/compute_angmom_chunk.cpp b/src/compute_angmom_chunk.cpp index a70eaaf49f..ec42015527 100644 --- a/src/compute_angmom_chunk.cpp +++ b/src/compute_angmom_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_angmom_chunk.h" #include "atom.h" diff --git a/src/compute_bond.cpp b/src/compute_bond.cpp index 896aaec9bd..4fd3bbef30 100644 --- a/src/compute_bond.cpp +++ b/src/compute_bond.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include -#include #include "compute_bond.h" +#include "bond.h" #include "update.h" #include "force.h" #include "bond_hybrid.h" diff --git a/src/compute_centro_atom.cpp b/src/compute_centro_atom.cpp index 5096879b32..7df94271fc 100644 --- a/src/compute_centro_atom.cpp +++ b/src/compute_centro_atom.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include -#include #include "compute_centro_atom.h" #include "atom.h" #include "update.h" diff --git a/src/compute_chunk_atom.cpp b/src/compute_chunk_atom.cpp index 61b653b375..fd9204f1cb 100644 --- a/src/compute_chunk_atom.cpp +++ b/src/compute_chunk_atom.cpp @@ -14,8 +14,11 @@ // NOTE: allow for bin center to be variables for sphere/cylinder #include +#include #include #include +#include +#include #include "compute_chunk_atom.h" #include "atom.h" #include "update.h" @@ -24,6 +27,7 @@ #include "region.h" #include "lattice.h" #include "modify.h" +#include "fix.h" #include "fix_store.h" #include "comm.h" #include "group.h" @@ -33,8 +37,6 @@ #include "memory.h" #include "error.h" -#include - using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/compute_cluster_atom.cpp b/src/compute_cluster_atom.cpp index 0c34b42671..febe0658a0 100644 --- a/src/compute_cluster_atom.cpp +++ b/src/compute_cluster_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include -#include #include "compute_cluster_atom.h" #include "atom.h" #include "update.h" diff --git a/src/compute_cna_atom.cpp b/src/compute_cna_atom.cpp index b8ad3f0f64..d764e739b3 100644 --- a/src/compute_cna_atom.cpp +++ b/src/compute_cna_atom.cpp @@ -15,8 +15,8 @@ Contributing author: Wan Liang (Chinese Academy of Sciences) ------------------------------------------------------------------------- */ +#include #include -#include #include #include "compute_cna_atom.h" #include "atom.h" diff --git a/src/compute_com_chunk.cpp b/src/compute_com_chunk.cpp index ec66767245..7b4c960cf4 100644 --- a/src/compute_com_chunk.cpp +++ b/src/compute_com_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_com_chunk.h" #include "atom.h" diff --git a/src/compute_contact_atom.cpp b/src/compute_contact_atom.cpp index e60a51832a..e4afc1d761 100644 --- a/src/compute_contact_atom.cpp +++ b/src/compute_contact_atom.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include -#include #include "compute_contact_atom.h" #include "atom.h" #include "update.h" @@ -22,7 +20,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "force.h" -#include "pair.h" #include "comm.h" #include "memory.h" #include "error.h" diff --git a/src/compute_coord_atom.cpp b/src/compute_coord_atom.cpp index 54f4c70c71..8cedcbc027 100644 --- a/src/compute_coord_atom.cpp +++ b/src/compute_coord_atom.cpp @@ -13,7 +13,6 @@ #include #include -#include #include "compute_coord_atom.h" #include "compute_orientorder_atom.h" #include "atom.h" diff --git a/src/compute_dihedral.cpp b/src/compute_dihedral.cpp index 3595b2eda3..16823050da 100644 --- a/src/compute_dihedral.cpp +++ b/src/compute_dihedral.cpp @@ -12,10 +12,10 @@ ------------------------------------------------------------------------- */ #include -#include #include "compute_dihedral.h" #include "update.h" #include "force.h" +#include "dihedral.h" #include "dihedral_hybrid.h" #include "error.h" diff --git a/src/compute_dihedral_local.cpp b/src/compute_dihedral_local.cpp index 9efdd61cb8..784ae9c607 100644 --- a/src/compute_dihedral_local.cpp +++ b/src/compute_dihedral_local.cpp @@ -20,10 +20,8 @@ #include "update.h" #include "domain.h" #include "force.h" -#include "dihedral.h" #include "input.h" #include "variable.h" - #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/compute_dipole_chunk.cpp b/src/compute_dipole_chunk.cpp index b0474b6359..090bc5df94 100644 --- a/src/compute_dipole_chunk.cpp +++ b/src/compute_dipole_chunk.cpp @@ -11,6 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include +#include #include #include "compute_dipole_chunk.h" #include "atom.h" diff --git a/src/compute_displace_atom.cpp b/src/compute_displace_atom.cpp index d8f279058e..3773159143 100644 --- a/src/compute_displace_atom.cpp +++ b/src/compute_displace_atom.cpp @@ -19,7 +19,6 @@ #include "group.h" #include "domain.h" #include "modify.h" -#include "fix.h" #include "fix_store.h" #include "input.h" #include "variable.h" diff --git a/src/compute_erotate_sphere.cpp b/src/compute_erotate_sphere.cpp index 31ed0aaba5..65bb8a9770 100644 --- a/src/compute_erotate_sphere.cpp +++ b/src/compute_erotate_sphere.cpp @@ -14,11 +14,8 @@ #include #include "compute_erotate_sphere.h" #include "atom.h" -#include "atom_vec.h" #include "update.h" #include "force.h" -#include "domain.h" -#include "group.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/compute_fragment_atom.cpp b/src/compute_fragment_atom.cpp index bb273f3bdb..d59b519d09 100644 --- a/src/compute_fragment_atom.cpp +++ b/src/compute_fragment_atom.cpp @@ -15,6 +15,7 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include #include #include "compute_fragment_atom.h" #include "atom.h" diff --git a/src/compute_global_atom.cpp b/src/compute_global_atom.cpp index dc9ab52f49..6685f746a1 100644 --- a/src/compute_global_atom.cpp +++ b/src/compute_global_atom.cpp @@ -16,12 +16,8 @@ #include "compute_global_atom.h" #include "atom.h" #include "update.h" -#include "domain.h" #include "modify.h" #include "fix.h" -#include "force.h" -#include "comm.h" -#include "group.h" #include "input.h" #include "variable.h" #include "memory.h" diff --git a/src/compute_group_group.cpp b/src/compute_group_group.cpp index e55f679b2e..11e1aac720 100644 --- a/src/compute_group_group.cpp +++ b/src/compute_group_group.cpp @@ -33,7 +33,6 @@ #include "comm.h" #include "domain.h" #include "math_const.h" -#include "utils.h" using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/compute_gyration.cpp b/src/compute_gyration.cpp index f8d19853e0..3c5656a5af 100644 --- a/src/compute_gyration.cpp +++ b/src/compute_gyration.cpp @@ -11,7 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include "compute_gyration.h" #include "update.h" #include "atom.h" diff --git a/src/compute_gyration_chunk.cpp b/src/compute_gyration_chunk.cpp index 6a23398aca..f3db37d62f 100644 --- a/src/compute_gyration_chunk.cpp +++ b/src/compute_gyration_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include #include "compute_gyration_chunk.h" diff --git a/src/compute_heat_flux.cpp b/src/compute_heat_flux.cpp index e402da7842..9bd827c713 100644 --- a/src/compute_heat_flux.cpp +++ b/src/compute_heat_flux.cpp @@ -16,14 +16,13 @@ Mario Pinto (Computational Research Lab, Pune, India) ------------------------------------------------------------------------- */ -#include +#include #include #include "compute_heat_flux.h" #include "atom.h" #include "update.h" #include "modify.h" #include "force.h" -#include "group.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/compute_hexorder_atom.cpp b/src/compute_hexorder_atom.cpp index 6d17ae15bd..c54f4b1aae 100644 --- a/src/compute_hexorder_atom.cpp +++ b/src/compute_hexorder_atom.cpp @@ -15,9 +15,9 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ -#include +#include #include -#include +#include #include "compute_hexorder_atom.h" #include "atom.h" #include "update.h" diff --git a/src/compute_improper.cpp b/src/compute_improper.cpp index ac2a23e727..2f068dfb74 100644 --- a/src/compute_improper.cpp +++ b/src/compute_improper.cpp @@ -12,10 +12,10 @@ ------------------------------------------------------------------------- */ #include -#include #include "compute_improper.h" #include "update.h" #include "force.h" +#include "improper.h" #include "improper_hybrid.h" #include "error.h" diff --git a/src/compute_improper_local.cpp b/src/compute_improper_local.cpp index 2861850c79..ec1734cd96 100644 --- a/src/compute_improper_local.cpp +++ b/src/compute_improper_local.cpp @@ -20,7 +20,6 @@ #include "update.h" #include "domain.h" #include "force.h" -#include "improper.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/compute_inertia_chunk.cpp b/src/compute_inertia_chunk.cpp index a33073c35a..d1a7cb9fc1 100644 --- a/src/compute_inertia_chunk.cpp +++ b/src/compute_inertia_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_inertia_chunk.h" #include "atom.h" diff --git a/src/compute_ke.cpp b/src/compute_ke.cpp index fb3c5a9695..3418cc678f 100644 --- a/src/compute_ke.cpp +++ b/src/compute_ke.cpp @@ -16,8 +16,6 @@ #include "atom.h" #include "update.h" #include "force.h" -#include "domain.h" -#include "group.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/compute_msd.cpp b/src/compute_msd.cpp index fc47b2609a..d2e17eff9e 100644 --- a/src/compute_msd.cpp +++ b/src/compute_msd.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_msd.h" #include "atom.h" diff --git a/src/compute_msd_chunk.cpp b/src/compute_msd_chunk.cpp index 1f974cc06c..8520b36993 100644 --- a/src/compute_msd_chunk.cpp +++ b/src/compute_msd_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_msd_chunk.h" #include "atom.h" diff --git a/src/compute_omega_chunk.cpp b/src/compute_omega_chunk.cpp index 23447da602..360255e908 100644 --- a/src/compute_omega_chunk.cpp +++ b/src/compute_omega_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_omega_chunk.h" #include "atom.h" diff --git a/src/compute_pair_local.cpp b/src/compute_pair_local.cpp index c356a08be9..1ab46a0297 100644 --- a/src/compute_pair_local.cpp +++ b/src/compute_pair_local.cpp @@ -22,7 +22,6 @@ #include "neighbor.h" #include "neigh_request.h" #include "neigh_list.h" -#include "group.h" #include "memory.h" #include "error.h" diff --git a/src/compute_pe_atom.cpp b/src/compute_pe_atom.cpp index 2f1dc5650e..b3ace2d419 100644 --- a/src/compute_pe_atom.cpp +++ b/src/compute_pe_atom.cpp @@ -24,7 +24,6 @@ #include "improper.h" #include "kspace.h" #include "modify.h" -#include "fix.h" #include "memory.h" #include "error.h" diff --git a/src/compute_pressure.cpp b/src/compute_pressure.cpp index dde02a5aed..431f039de3 100644 --- a/src/compute_pressure.cpp +++ b/src/compute_pressure.cpp @@ -13,7 +13,6 @@ #include #include -#include #include "compute_pressure.h" #include "atom.h" #include "update.h" diff --git a/src/compute_property_chunk.cpp b/src/compute_property_chunk.cpp index 489890e1cc..089e867598 100644 --- a/src/compute_property_chunk.cpp +++ b/src/compute_property_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_property_chunk.h" #include "atom.h" diff --git a/src/compute_rdf.cpp b/src/compute_rdf.cpp index d49485b4ea..b1fa8bb2a3 100644 --- a/src/compute_rdf.cpp +++ b/src/compute_rdf.cpp @@ -17,7 +17,6 @@ #include #include -#include #include #include "compute_rdf.h" #include "atom.h" diff --git a/src/compute_reduce.cpp b/src/compute_reduce.cpp index 16dc84628a..e7692b0797 100644 --- a/src/compute_reduce.cpp +++ b/src/compute_reduce.cpp @@ -20,8 +20,6 @@ #include "domain.h" #include "modify.h" #include "fix.h" -#include "force.h" -#include "comm.h" #include "group.h" #include "input.h" #include "variable.h" diff --git a/src/compute_reduce_region.cpp b/src/compute_reduce_region.cpp index 8e91a299e8..30a5c6393f 100644 --- a/src/compute_reduce_region.cpp +++ b/src/compute_reduce_region.cpp @@ -11,8 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include +#include #include "compute_reduce_region.h" #include "atom.h" #include "update.h" From 557a1274e48fdb950a998c28f2e5eba6a996065d Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 28 Jun 2019 02:12:47 -0400 Subject: [PATCH 18/79] even more include file cleanup --- src/compute_slice.cpp | 2 +- src/compute_stress_atom.cpp | 1 - src/compute_temp.cpp | 2 -- src/compute_temp_chunk.cpp | 1 + src/compute_temp_com.cpp | 3 --- src/compute_temp_partial.cpp | 1 - src/compute_temp_profile.cpp | 2 -- src/compute_temp_ramp.cpp | 2 -- src/compute_temp_sphere.cpp | 2 -- src/compute_torque_chunk.cpp | 1 + src/compute_vacf.cpp | 1 + src/compute_vcm_chunk.cpp | 2 +- src/create_atoms.cpp | 5 +---- src/create_bonds.cpp | 2 +- src/create_box.cpp | 2 -- src/delete_atoms.cpp | 3 ++- src/delete_bonds.cpp | 1 - src/deprecated.cpp | 1 - src/dihedral.cpp | 3 --- 19 files changed, 9 insertions(+), 28 deletions(-) diff --git a/src/compute_slice.cpp b/src/compute_slice.cpp index ac70e7dd15..6e509c24d4 100644 --- a/src/compute_slice.cpp +++ b/src/compute_slice.cpp @@ -11,13 +11,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include #include "compute_slice.h" #include "update.h" #include "modify.h" #include "fix.h" -#include "group.h" #include "input.h" #include "variable.h" #include "memory.h" diff --git a/src/compute_stress_atom.cpp b/src/compute_stress_atom.cpp index 5211f015ab..f84c977bdb 100644 --- a/src/compute_stress_atom.cpp +++ b/src/compute_stress_atom.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "compute_stress_atom.h" #include "atom.h" diff --git a/src/compute_temp.cpp b/src/compute_temp.cpp index f7d3a890ec..c330249a7e 100644 --- a/src/compute_temp.cpp +++ b/src/compute_temp.cpp @@ -12,13 +12,11 @@ ------------------------------------------------------------------------- */ #include -#include #include "compute_temp.h" #include "atom.h" #include "update.h" #include "force.h" #include "domain.h" -#include "comm.h" #include "group.h" #include "error.h" diff --git a/src/compute_temp_chunk.cpp b/src/compute_temp_chunk.cpp index 920515e05c..229e98e258 100644 --- a/src/compute_temp_chunk.cpp +++ b/src/compute_temp_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_temp_chunk.h" #include "atom.h" diff --git a/src/compute_temp_com.cpp b/src/compute_temp_com.cpp index f2ad40ea43..21814e1940 100644 --- a/src/compute_temp_com.cpp +++ b/src/compute_temp_com.cpp @@ -12,15 +12,12 @@ ------------------------------------------------------------------------- */ #include -#include -#include #include "compute_temp_com.h" #include "atom.h" #include "update.h" #include "force.h" #include "group.h" #include "domain.h" -#include "lattice.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/compute_temp_partial.cpp b/src/compute_temp_partial.cpp index 4425aebdda..8d5ff66796 100644 --- a/src/compute_temp_partial.cpp +++ b/src/compute_temp_partial.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include "compute_temp_partial.h" #include "atom.h" #include "update.h" diff --git a/src/compute_temp_profile.cpp b/src/compute_temp_profile.cpp index c7f0b28a6c..21c87b31a2 100644 --- a/src/compute_temp_profile.cpp +++ b/src/compute_temp_profile.cpp @@ -12,14 +12,12 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "compute_temp_profile.h" #include "atom.h" #include "update.h" #include "force.h" #include "group.h" -#include "fix.h" #include "domain.h" #include "memory.h" #include "error.h" diff --git a/src/compute_temp_ramp.cpp b/src/compute_temp_ramp.cpp index ba572645f3..715d2aa9f4 100644 --- a/src/compute_temp_ramp.cpp +++ b/src/compute_temp_ramp.cpp @@ -12,14 +12,12 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "compute_temp_ramp.h" #include "atom.h" #include "update.h" #include "force.h" #include "group.h" -#include "fix.h" #include "domain.h" #include "lattice.h" #include "memory.h" diff --git a/src/compute_temp_sphere.cpp b/src/compute_temp_sphere.cpp index 651da6dee5..b490a5ec45 100644 --- a/src/compute_temp_sphere.cpp +++ b/src/compute_temp_sphere.cpp @@ -15,12 +15,10 @@ #include #include "compute_temp_sphere.h" #include "atom.h" -#include "atom_vec.h" #include "update.h" #include "force.h" #include "domain.h" #include "modify.h" -#include "comm.h" #include "group.h" #include "error.h" diff --git a/src/compute_torque_chunk.cpp b/src/compute_torque_chunk.cpp index d9de99bcb2..e43155493f 100644 --- a/src/compute_torque_chunk.cpp +++ b/src/compute_torque_chunk.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_torque_chunk.h" #include "atom.h" diff --git a/src/compute_vacf.cpp b/src/compute_vacf.cpp index 3ef3acf0bf..787c2503ca 100644 --- a/src/compute_vacf.cpp +++ b/src/compute_vacf.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_vacf.h" #include "atom.h" diff --git a/src/compute_vcm_chunk.cpp b/src/compute_vcm_chunk.cpp index a6dd796c63..cf30130763 100644 --- a/src/compute_vcm_chunk.cpp +++ b/src/compute_vcm_chunk.cpp @@ -11,13 +11,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "compute_vcm_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" #include "compute_chunk_atom.h" -#include "domain.h" #include "memory.h" #include "error.h" diff --git a/src/create_atoms.cpp b/src/create_atoms.cpp index 52e4256fca..8504023a70 100644 --- a/src/create_atoms.cpp +++ b/src/create_atoms.cpp @@ -11,8 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include +#include #include #include "create_atoms.h" #include "atom.h" @@ -23,8 +22,6 @@ #include "modify.h" #include "force.h" #include "special.h" -#include "fix.h" -#include "compute.h" #include "domain.h" #include "lattice.h" #include "region.h" diff --git a/src/create_bonds.cpp b/src/create_bonds.cpp index e19b565554..e00fe109ca 100644 --- a/src/create_bonds.cpp +++ b/src/create_bonds.cpp @@ -15,7 +15,7 @@ Contributing authors: Mike Salerno (NRL) added single methods ------------------------------------------------------------------------- */ -#include +#include #include #include "create_bonds.h" #include "atom.h" diff --git a/src/create_box.cpp b/src/create_box.cpp index b5e37b759c..5ec960bec4 100644 --- a/src/create_box.cpp +++ b/src/create_box.cpp @@ -11,12 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "create_box.h" #include "atom.h" #include "atom_vec.h" -#include "force.h" #include "domain.h" #include "region.h" #include "region_prism.h" diff --git a/src/delete_atoms.cpp b/src/delete_atoms.cpp index 41df167f07..ff4b97a3a4 100644 --- a/src/delete_atoms.cpp +++ b/src/delete_atoms.cpp @@ -11,8 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include +#include #include "delete_atoms.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/delete_bonds.cpp b/src/delete_bonds.cpp index fe32bca879..c4d591543a 100644 --- a/src/delete_bonds.cpp +++ b/src/delete_bonds.cpp @@ -18,7 +18,6 @@ #include "atom.h" #include "atom_vec.h" #include "domain.h" -#include "neighbor.h" #include "comm.h" #include "force.h" #include "group.h" diff --git a/src/deprecated.cpp b/src/deprecated.cpp index b937482669..66ddcfeff4 100644 --- a/src/deprecated.cpp +++ b/src/deprecated.cpp @@ -18,7 +18,6 @@ #include #include "deprecated.h" #include "comm.h" -#include "force.h" #include "error.h" #include "input.h" diff --git a/src/dihedral.cpp b/src/dihedral.cpp index adccf2a490..d2de841dd0 100644 --- a/src/dihedral.cpp +++ b/src/dihedral.cpp @@ -11,13 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "dihedral.h" #include "atom.h" #include "comm.h" #include "force.h" -#include "pair.h" -#include "suffix.h" #include "atom_masks.h" #include "memory.h" #include "error.h" From 31cbccda85de0c04dff11eebe97eabc53b57a738 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 28 Jun 2019 21:38:19 -0400 Subject: [PATCH 19/79] continue cleaning up include file lists --- src/RIGID/fix_shake.cpp | 4 +--- src/dihedral_hybrid.cpp | 3 +-- src/dihedral_zero.cpp | 3 --- src/displace_atoms.cpp | 2 +- src/domain.cpp | 4 ---- src/domain.h | 2 +- src/dump.cpp | 2 -- src/dump_atom.cpp | 1 - src/dump_cfg.cpp | 8 -------- src/dump_custom.cpp | 1 - src/dump_dcd.cpp | 2 -- src/dump_image.cpp | 4 ++-- src/dump_local.cpp | 1 - src/dump_movie.cpp | 3 --- src/dump_xyz.cpp | 1 - src/error.cpp | 1 - src/finish.cpp | 4 ---- src/fix.cpp | 1 - src/fix_adapt.cpp | 2 -- src/fix_addforce.cpp | 1 + src/fix_ave_atom.cpp | 1 - src/fix_ave_chunk.cpp | 2 ++ src/fix_ave_correlate.cpp | 2 ++ src/fix_ave_histo.cpp | 3 ++- src/fix_ave_histo_weight.cpp | 8 +++----- src/fix_ave_time.cpp | 2 ++ src/fix_aveforce.cpp | 1 - src/fix_balance.cpp | 2 -- src/fix_box_relax.cpp | 1 - src/fix_deform.cpp | 1 - src/fix_drag.cpp | 2 +- src/fix_dt_reset.cpp | 2 +- src/fix_external.cpp | 2 -- src/fix_gravity.cpp | 3 +-- src/fix_halt.cpp | 3 +-- src/fix_heat.cpp | 2 +- src/fix_indent.cpp | 3 +-- src/fix_langevin.cpp | 3 --- src/fix_lineforce.cpp | 1 - src/fix_minimize.cpp | 2 -- src/fix_momentum.cpp | 3 ++- src/fix_move.cpp | 2 -- src/fix_neigh_history.cpp | 4 +--- src/fix_neigh_history.h | 1 - src/fix_nh.cpp | 2 -- src/fix_nh_sphere.cpp | 2 +- src/fix_nve.cpp | 1 - src/fix_nve_limit.cpp | 3 +-- src/fix_nve_noforce.cpp | 1 - src/fix_nve_sphere.cpp | 3 --- src/fix_nvt_sllod.cpp | 1 - src/fix_planeforce.cpp | 1 - src/fix_press_berendsen.cpp | 2 -- src/fix_print.cpp | 2 +- src/fix_property_atom.cpp | 2 -- src/fix_read_restart.cpp | 1 - src/fix_recenter.cpp | 2 +- src/fix_respa.cpp | 1 - src/fix_restrain.cpp | 3 +-- 59 files changed, 32 insertions(+), 101 deletions(-) diff --git a/src/RIGID/fix_shake.cpp b/src/RIGID/fix_shake.cpp index 23ced2d0e7..5c202706af 100644 --- a/src/RIGID/fix_shake.cpp +++ b/src/RIGID/fix_shake.cpp @@ -13,11 +13,9 @@ #include #include -#include +#include #include -#include #include "fix_shake.h" -#include "fix_rattle.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/dihedral_hybrid.cpp b/src/dihedral_hybrid.cpp index f3e4823d53..27fd7084bc 100644 --- a/src/dihedral_hybrid.cpp +++ b/src/dihedral_hybrid.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include #include #include "dihedral_hybrid.h" #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/dihedral_zero.cpp b/src/dihedral_zero.cpp index 8145d5f32d..0367477267 100644 --- a/src/dihedral_zero.cpp +++ b/src/dihedral_zero.cpp @@ -15,13 +15,10 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ -#include -#include #include #include "dihedral_zero.h" #include "atom.h" #include "force.h" -#include "comm.h" #include "memory.h" #include "error.h" diff --git a/src/displace_atoms.cpp b/src/displace_atoms.cpp index 7b29b1d3d5..8bae173a1d 100644 --- a/src/displace_atoms.cpp +++ b/src/displace_atoms.cpp @@ -12,7 +12,7 @@ ------------------------------------------------------------------------- */ #include -#include +#include #include #include "displace_atoms.h" #include "atom.h" diff --git a/src/domain.cpp b/src/domain.cpp index 74d7560c31..197eff514a 100644 --- a/src/domain.cpp +++ b/src/domain.cpp @@ -16,9 +16,7 @@ ------------------------------------------------------------------------- */ #include -#include #include -#include #include #include "domain.h" #include "style_region.h" @@ -37,13 +35,11 @@ #include "output.h" #include "thermo.h" #include "universe.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "utils.h" using namespace LAMMPS_NS; -using namespace MathConst; #define BIG 1.0e20 #define SMALL 1.0e-4 diff --git a/src/domain.h b/src/domain.h index e131d07a1b..a0bda8ae72 100644 --- a/src/domain.h +++ b/src/domain.h @@ -15,9 +15,9 @@ #define LMP_DOMAIN_H #include -#include "pointers.h" #include #include +#include "pointers.h" namespace LAMMPS_NS { diff --git a/src/dump.cpp b/src/dump.cpp index 8fa07a9cb2..b08a4de2ad 100644 --- a/src/dump.cpp +++ b/src/dump.cpp @@ -12,9 +12,7 @@ ------------------------------------------------------------------------- */ #include -#include #include -#include #include "dump.h" #include "atom.h" #include "irregular.h" diff --git a/src/dump_atom.cpp b/src/dump_atom.cpp index 74583f4013..c95256ac21 100644 --- a/src/dump_atom.cpp +++ b/src/dump_atom.cpp @@ -16,7 +16,6 @@ #include "domain.h" #include "atom.h" #include "update.h" -#include "group.h" #include "memory.h" #include "error.h" diff --git a/src/dump_cfg.cpp b/src/dump_cfg.cpp index ddd662c8a6..eb5329e0d1 100644 --- a/src/dump_cfg.cpp +++ b/src/dump_cfg.cpp @@ -16,18 +16,10 @@ Memory efficiency improved by Ray Shan (Sandia) ------------------------------------------------------------------------- */ -#include -#include #include #include "dump_cfg.h" #include "atom.h" #include "domain.h" -#include "comm.h" -#include "modify.h" -#include "compute.h" -#include "input.h" -#include "fix.h" -#include "variable.h" #include "memory.h" #include "error.h" diff --git a/src/dump_custom.cpp b/src/dump_custom.cpp index 17ad4b89ef..75e4e42bcd 100644 --- a/src/dump_custom.cpp +++ b/src/dump_custom.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include #include "dump_custom.h" diff --git a/src/dump_dcd.cpp b/src/dump_dcd.cpp index 384e9089c0..ce669fecfd 100644 --- a/src/dump_dcd.cpp +++ b/src/dump_dcd.cpp @@ -17,8 +17,6 @@ ------------------------------------------------------------------------- */ #include -#include // requires C++-11 -#include #include #include #include "dump_dcd.h" diff --git a/src/dump_image.cpp b/src/dump_image.cpp index 0d63d2e4cb..0b4ca43879 100644 --- a/src/dump_image.cpp +++ b/src/dump_image.cpp @@ -11,20 +11,20 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include -#include #include #include "dump_image.h" #include "image.h" #include "atom.h" +#include "atom_vec.h" #include "atom_vec_line.h" #include "atom_vec_tri.h" #include "atom_vec_body.h" #include "body.h" #include "molecule.h" #include "domain.h" -#include "group.h" #include "force.h" #include "comm.h" #include "modify.h" diff --git a/src/dump_local.cpp b/src/dump_local.cpp index 8dc0554690..f99b7ac06c 100644 --- a/src/dump_local.cpp +++ b/src/dump_local.cpp @@ -15,7 +15,6 @@ #include #include #include "dump_local.h" -#include "atom.h" #include "modify.h" #include "fix.h" #include "compute.h" diff --git a/src/dump_movie.cpp b/src/dump_movie.cpp index 59dfdc3d6e..37d8a37f4d 100644 --- a/src/dump_movie.cpp +++ b/src/dump_movie.cpp @@ -15,13 +15,10 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include -#include #include #include "dump_movie.h" #include "comm.h" #include "force.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/dump_xyz.cpp b/src/dump_xyz.cpp index fd52671d81..4d50cfc2c8 100644 --- a/src/dump_xyz.cpp +++ b/src/dump_xyz.cpp @@ -14,7 +14,6 @@ #include #include "dump_xyz.h" #include "atom.h" -#include "group.h" #include "error.h" #include "memory.h" #include "update.h" diff --git a/src/error.cpp b/src/error.cpp index cc80dcb4d8..8970145b7c 100644 --- a/src/error.cpp +++ b/src/error.cpp @@ -16,7 +16,6 @@ #include #include "error.h" #include "universe.h" -#include "update.h" #include "output.h" #include "input.h" diff --git a/src/finish.cpp b/src/finish.cpp index 1baa6d6fda..77c959b945 100644 --- a/src/finish.cpp +++ b/src/finish.cpp @@ -15,12 +15,10 @@ #include #include #include -#include #include "finish.h" #include "timer.h" #include "universe.h" #include "accelerator_kokkos.h" -#include "accelerator_omp.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" @@ -32,10 +30,8 @@ #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "output.h" #include "memory.h" #include "error.h" -#include "utils.h" #ifdef LMP_USER_OMP #include "modify.h" diff --git a/src/fix.cpp b/src/fix.cpp index 634bc2393d..1913ed483e 100644 --- a/src/fix.cpp +++ b/src/fix.cpp @@ -17,7 +17,6 @@ #include "atom.h" #include "group.h" #include "force.h" -#include "comm.h" #include "atom_masks.h" #include "memory.h" #include "error.h" diff --git a/src/fix_adapt.cpp b/src/fix_adapt.cpp index 9a5b528747..7ac6128558 100644 --- a/src/fix_adapt.cpp +++ b/src/fix_adapt.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include -#include #include "fix_adapt.h" #include "atom.h" #include "bond.h" diff --git a/src/fix_addforce.cpp b/src/fix_addforce.cpp index d66457a1f1..e29c4ffe9f 100644 --- a/src/fix_addforce.cpp +++ b/src/fix_addforce.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include #include "fix_addforce.h" diff --git a/src/fix_ave_atom.cpp b/src/fix_ave_atom.cpp index c8cbad75c9..e6566632de 100644 --- a/src/fix_ave_atom.cpp +++ b/src/fix_ave_atom.cpp @@ -15,7 +15,6 @@ #include #include "fix_ave_atom.h" #include "atom.h" -#include "domain.h" #include "update.h" #include "modify.h" #include "compute.h" diff --git a/src/fix_ave_chunk.cpp b/src/fix_ave_chunk.cpp index 7aed4dcbe7..1533d1fa4f 100644 --- a/src/fix_ave_chunk.cpp +++ b/src/fix_ave_chunk.cpp @@ -11,6 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include +#include // IWYU pragma: keep #include #include #include diff --git a/src/fix_ave_correlate.cpp b/src/fix_ave_correlate.cpp index 5c95f20ec2..555c1ac026 100644 --- a/src/fix_ave_correlate.cpp +++ b/src/fix_ave_correlate.cpp @@ -17,6 +17,8 @@ Reese Jones (Sandia) ------------------------------------------------------------------------- */ +#include +#include // IWYU pragma: keep #include #include #include diff --git a/src/fix_ave_histo.cpp b/src/fix_ave_histo.cpp index 87da5222f0..29fdc21c74 100644 --- a/src/fix_ave_histo.cpp +++ b/src/fix_ave_histo.cpp @@ -11,6 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include +#include // IWYU pragma: keep #include #include #include @@ -19,7 +21,6 @@ #include "update.h" #include "modify.h" #include "compute.h" -#include "group.h" #include "input.h" #include "variable.h" #include "memory.h" diff --git a/src/fix_ave_histo_weight.cpp b/src/fix_ave_histo_weight.cpp index c78f4fa1e3..5eeb074472 100644 --- a/src/fix_ave_histo_weight.cpp +++ b/src/fix_ave_histo_weight.cpp @@ -14,21 +14,19 @@ /* ---------------------------------------------------------------------- Contributing author: Shawn Coleman (ARL) ------------------------------------------------------------------------- */ - -#include -#include +#include +#include // IWYU pragma: keep #include +#include "fix.h" #include "fix_ave_histo_weight.h" #include "atom.h" #include "update.h" #include "modify.h" #include "compute.h" -#include "group.h" #include "input.h" #include "variable.h" #include "memory.h" #include "error.h" -#include "force.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/fix_ave_time.cpp b/src/fix_ave_time.cpp index 50654b6561..4820215f46 100644 --- a/src/fix_ave_time.cpp +++ b/src/fix_ave_time.cpp @@ -15,6 +15,8 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include +#include // IWYU pragma: keep #include #include #include diff --git a/src/fix_aveforce.cpp b/src/fix_aveforce.cpp index 1c87ba5785..4791a8b022 100644 --- a/src/fix_aveforce.cpp +++ b/src/fix_aveforce.cpp @@ -13,7 +13,6 @@ #include #include -#include #include "fix_aveforce.h" #include "atom.h" #include "update.h" diff --git a/src/fix_balance.cpp b/src/fix_balance.cpp index ddaf42b49d..f9c32e8df0 100644 --- a/src/fix_balance.cpp +++ b/src/fix_balance.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include "fix_balance.h" #include "balance.h" #include "update.h" @@ -26,7 +25,6 @@ #include "modify.h" #include "fix_store.h" #include "rcb.h" -#include "timer.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/fix_box_relax.cpp b/src/fix_box_relax.cpp index a315330d14..c73c0ade88 100644 --- a/src/fix_box_relax.cpp +++ b/src/fix_box_relax.cpp @@ -17,7 +17,6 @@ #include #include -#include #include "fix_box_relax.h" #include "atom.h" #include "domain.h" diff --git a/src/fix_deform.cpp b/src/fix_deform.cpp index 909ead3e2a..96d7580c39 100644 --- a/src/fix_deform.cpp +++ b/src/fix_deform.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_deform.h" #include "atom.h" diff --git a/src/fix_drag.cpp b/src/fix_drag.cpp index e4cf12d1ff..006d1c46d0 100644 --- a/src/fix_drag.cpp +++ b/src/fix_drag.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_drag.h" #include "atom.h" diff --git a/src/fix_dt_reset.cpp b/src/fix_dt_reset.cpp index 7566094b48..4e6195c4fa 100644 --- a/src/fix_dt_reset.cpp +++ b/src/fix_dt_reset.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_dt_reset.h" #include "atom.h" diff --git a/src/fix_external.cpp b/src/fix_external.cpp index b1ffa65e49..2c926e26b5 100644 --- a/src/fix_external.cpp +++ b/src/fix_external.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include -#include #include "fix_external.h" #include "atom.h" #include "update.h" diff --git a/src/fix_gravity.cpp b/src/fix_gravity.cpp index bc10eb2807..8508a92cc4 100644 --- a/src/fix_gravity.cpp +++ b/src/fix_gravity.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "fix_gravity.h" #include "atom.h" diff --git a/src/fix_halt.cpp b/src/fix_halt.cpp index 5fda4c30d6..133494fb8e 100644 --- a/src/fix_halt.cpp +++ b/src/fix_halt.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_halt.h" #include "update.h" #include "force.h" -#include "update.h" #include "input.h" #include "variable.h" #include "atom.h" diff --git a/src/fix_heat.cpp b/src/fix_heat.cpp index f34845785c..f78a9c0860 100644 --- a/src/fix_heat.cpp +++ b/src/fix_heat.cpp @@ -15,8 +15,8 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_heat.h" #include "atom.h" diff --git a/src/fix_indent.cpp b/src/fix_indent.cpp index b8e07dfd53..6a42cadefd 100644 --- a/src/fix_indent.cpp +++ b/src/fix_indent.cpp @@ -15,9 +15,9 @@ Contributing author: Ravi Agrawal (Northwestern U) ------------------------------------------------------------------------- */ +#include #include #include -#include #include "fix_indent.h" #include "atom.h" #include "input.h" @@ -26,7 +26,6 @@ #include "lattice.h" #include "update.h" #include "modify.h" -#include "output.h" #include "respa.h" #include "error.h" #include "force.h" diff --git a/src/fix_langevin.cpp b/src/fix_langevin.cpp index 36ea47daf6..0f48562048 100644 --- a/src/fix_langevin.cpp +++ b/src/fix_langevin.cpp @@ -19,7 +19,6 @@ #include #include #include -#include #include "fix_langevin.h" #include "math_extra.h" #include "atom.h" @@ -28,8 +27,6 @@ #include "update.h" #include "modify.h" #include "compute.h" -#include "domain.h" -#include "region.h" #include "respa.h" #include "comm.h" #include "input.h" diff --git a/src/fix_lineforce.cpp b/src/fix_lineforce.cpp index aea1a2a25b..61c6341aa6 100644 --- a/src/fix_lineforce.cpp +++ b/src/fix_lineforce.cpp @@ -13,7 +13,6 @@ #include #include -#include #include "fix_lineforce.h" #include "atom.h" #include "update.h" diff --git a/src/fix_minimize.cpp b/src/fix_minimize.cpp index fa39643a1b..df2dfb02a7 100644 --- a/src/fix_minimize.cpp +++ b/src/fix_minimize.cpp @@ -11,12 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_minimize.h" #include "atom.h" #include "domain.h" #include "memory.h" -#include "error.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/fix_momentum.cpp b/src/fix_momentum.cpp index 680251e670..bf94a94362 100644 --- a/src/fix_momentum.cpp +++ b/src/fix_momentum.cpp @@ -11,7 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include +#include #include #include "fix_momentum.h" #include "atom.h" diff --git a/src/fix_move.cpp b/src/fix_move.cpp index 0a5f506ab2..646f943ef9 100644 --- a/src/fix_move.cpp +++ b/src/fix_move.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_move.h" #include "atom.h" -#include "group.h" #include "update.h" #include "modify.h" #include "force.h" diff --git a/src/fix_neigh_history.cpp b/src/fix_neigh_history.cpp index 207c409596..ca593f29df 100644 --- a/src/fix_neigh_history.cpp +++ b/src/fix_neigh_history.cpp @@ -13,16 +13,14 @@ #include #include -#include #include "fix_neigh_history.h" +#include "my_page.h" #include "atom.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" #include "force.h" #include "pair.h" -#include "update.h" -#include "modify.h" #include "memory.h" #include "error.h" diff --git a/src/fix_neigh_history.h b/src/fix_neigh_history.h index 601e8a55a2..51d03f5b12 100644 --- a/src/fix_neigh_history.h +++ b/src/fix_neigh_history.h @@ -21,7 +21,6 @@ FixStyle(NEIGH_HISTORY,FixNeighHistory) #define LMP_FIX_NEIGH_HISTORY_H #include "fix.h" -#include "my_page.h" namespace LAMMPS_NS { diff --git a/src/fix_nh.cpp b/src/fix_nh.cpp index deca0ad83d..3ffdff54cf 100644 --- a/src/fix_nh.cpp +++ b/src/fix_nh.cpp @@ -16,10 +16,8 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_nh.h" -#include "math_extra.h" #include "atom.h" #include "force.h" #include "group.h" diff --git a/src/fix_nh_sphere.cpp b/src/fix_nh_sphere.cpp index f176493242..0f1024700a 100644 --- a/src/fix_nh_sphere.cpp +++ b/src/fix_nh_sphere.cpp @@ -16,10 +16,10 @@ ------------------------------------------------------------------------- */ #include +#include #include "fix_nh_sphere.h" #include "atom.h" #include "atom_vec.h" -#include "group.h" #include "error.h" #include "force.h" #include "domain.h" diff --git a/src/fix_nve.cpp b/src/fix_nve.cpp index 959483230e..3396f3ca47 100644 --- a/src/fix_nve.cpp +++ b/src/fix_nve.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "fix_nve.h" #include "atom.h" diff --git a/src/fix_nve_limit.cpp b/src/fix_nve_limit.cpp index 68ff0665a1..49bed2e3dd 100644 --- a/src/fix_nve_limit.cpp +++ b/src/fix_nve_limit.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "fix_nve_limit.h" #include "atom.h" diff --git a/src/fix_nve_noforce.cpp b/src/fix_nve_noforce.cpp index d4fca9e676..7b61aac18e 100644 --- a/src/fix_nve_noforce.cpp +++ b/src/fix_nve_noforce.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "fix_nve_noforce.h" #include "atom.h" diff --git a/src/fix_nve_sphere.cpp b/src/fix_nve_sphere.cpp index 0bee8b8685..94e8aa88ac 100644 --- a/src/fix_nve_sphere.cpp +++ b/src/fix_nve_sphere.cpp @@ -12,14 +12,11 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_nve_sphere.h" #include "atom.h" #include "domain.h" #include "atom_vec.h" -#include "update.h" -#include "respa.h" #include "force.h" #include "error.h" #include "math_vector.h" diff --git a/src/fix_nvt_sllod.cpp b/src/fix_nvt_sllod.cpp index c7d23364a7..16e2fb1d3d 100644 --- a/src/fix_nvt_sllod.cpp +++ b/src/fix_nvt_sllod.cpp @@ -15,7 +15,6 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ -#include #include #include "fix_nvt_sllod.h" #include "math_extra.h" diff --git a/src/fix_planeforce.cpp b/src/fix_planeforce.cpp index 45dc782fcf..a83d00a506 100644 --- a/src/fix_planeforce.cpp +++ b/src/fix_planeforce.cpp @@ -13,7 +13,6 @@ #include #include -#include #include "fix_planeforce.h" #include "atom.h" #include "update.h" diff --git a/src/fix_press_berendsen.cpp b/src/fix_press_berendsen.cpp index 95db004436..ad3e3d1e1c 100644 --- a/src/fix_press_berendsen.cpp +++ b/src/fix_press_berendsen.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_press_berendsen.h" #include "atom.h" @@ -23,7 +22,6 @@ #include "compute.h" #include "kspace.h" #include "update.h" -#include "respa.h" #include "domain.h" #include "error.h" diff --git a/src/fix_print.cpp b/src/fix_print.cpp index f6db88114a..da2e2b54f3 100644 --- a/src/fix_print.cpp +++ b/src/fix_print.cpp @@ -11,7 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include #include "fix_print.h" #include "update.h" diff --git a/src/fix_property_atom.cpp b/src/fix_property_atom.cpp index c89419f850..62c3ec985b 100644 --- a/src/fix_property_atom.cpp +++ b/src/fix_property_atom.cpp @@ -19,8 +19,6 @@ #include "memory.h" #include "error.h" -#include "update.h" - using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/fix_read_restart.cpp b/src/fix_read_restart.cpp index 3c3178f4af..afedf9c12c 100644 --- a/src/fix_read_restart.cpp +++ b/src/fix_read_restart.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_read_restart.h" #include "atom.h" #include "memory.h" diff --git a/src/fix_recenter.cpp b/src/fix_recenter.cpp index 75b383d67a..cd50d7dc34 100644 --- a/src/fix_recenter.cpp +++ b/src/fix_recenter.cpp @@ -15,7 +15,7 @@ Contributing author: Naveen Michaud-Agrawal (Johns Hopkins U) ------------------------------------------------------------------------- */ -#include +#include #include #include "fix_recenter.h" #include "atom.h" diff --git a/src/fix_respa.cpp b/src/fix_respa.cpp index 64461ba7ca..ea2eb5050a 100644 --- a/src/fix_respa.cpp +++ b/src/fix_respa.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "fix_respa.h" #include "atom.h" diff --git a/src/fix_restrain.cpp b/src/fix_restrain.cpp index 08485d65b3..3b9980d567 100644 --- a/src/fix_restrain.cpp +++ b/src/fix_restrain.cpp @@ -16,9 +16,9 @@ support for bond and angle restraints by Andres Jaramillo-Botero (Caltech) ------------------------------------------------------------------------- */ +#include #include #include -#include #include "fix_restrain.h" #include "atom.h" #include "force.h" @@ -26,7 +26,6 @@ #include "domain.h" #include "comm.h" #include "respa.h" -#include "input.h" #include "math_const.h" #include "memory.h" #include "error.h" From 96744c49338448068b16c1fe24ad2557460b13b1 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sat, 29 Jun 2019 21:30:23 -0400 Subject: [PATCH 20/79] more include file cleanup --- src/BODY/body_nparticle.cpp | 1 + src/BODY/body_rounded_polygon.cpp | 1 + src/BODY/body_rounded_polyhedron.cpp | 1 + src/fix_setforce.cpp | 2 +- src/fix_spring.cpp | 2 -- src/fix_spring_chunk.cpp | 2 -- src/fix_spring_rg.cpp | 2 -- src/fix_spring_self.cpp | 2 +- src/fix_store.cpp | 1 - src/fix_store_force.cpp | 1 - src/fix_temp_berendsen.cpp | 1 - src/fix_temp_csld.cpp | 1 - src/fix_temp_csvr.cpp | 3 +-- src/fix_temp_rescale.cpp | 3 --- src/fix_tmd.cpp | 1 - src/fix_vector.cpp | 1 - src/fix_viscous.cpp | 2 -- src/fix_wall.cpp | 4 +--- src/fix_wall_harmonic.cpp | 1 - src/fix_wall_reflect.cpp | 1 - src/fix_wall_region.cpp | 5 +---- src/force.cpp | 3 --- src/group.cpp | 3 +-- src/hashlittle.cpp | 1 - src/image.cpp | 3 +-- src/imbalance.h | 2 +- src/imbalance_var.cpp | 4 +--- src/improper.cpp | 1 - src/improper_hybrid.cpp | 3 +-- src/improper_zero.cpp | 3 --- src/info.cpp | 12 ++++++------ src/input.cpp | 5 ----- src/integrate.cpp | 1 - src/irregular.cpp | 1 - src/irregular.h | 1 + src/kspace.cpp | 2 ++ src/kspace.h | 1 + src/lammps.cpp | 1 - src/library.cpp | 4 +--- src/library.h | 2 ++ src/math_extra.h | 3 --- src/memory.cpp | 2 -- src/memory.h | 1 - src/min.cpp | 2 +- src/min_cg.cpp | 2 -- src/min_fire.cpp | 2 +- src/min_hftn.cpp | 1 + src/min_linesearch.cpp | 7 ++----- src/min_quickmin.cpp | 1 - src/min_sd.cpp | 2 -- src/minimize.cpp | 1 - src/modify.cpp | 1 - src/molecule.cpp | 6 +++--- src/nbin.cpp | 2 +- src/neigh_list.cpp | 4 +--- src/neigh_list.h | 1 - src/neighbor.cpp | 3 --- src/neighbor.h | 1 - src/npair_copy.cpp | 7 ------- src/npair_full_bin.cpp | 1 - src/npair_full_bin_atomonly.cpp | 2 -- src/procmap.cpp | 1 + 62 files changed, 37 insertions(+), 107 deletions(-) diff --git a/src/BODY/body_nparticle.cpp b/src/BODY/body_nparticle.cpp index 21070107f5..b2d9dbaca3 100644 --- a/src/BODY/body_nparticle.cpp +++ b/src/BODY/body_nparticle.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "body_nparticle.h" #include "my_pool_chunk.h" diff --git a/src/BODY/body_rounded_polygon.cpp b/src/BODY/body_rounded_polygon.cpp index f7741ada88..6e1e49319e 100644 --- a/src/BODY/body_rounded_polygon.cpp +++ b/src/BODY/body_rounded_polygon.cpp @@ -15,6 +15,7 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include #include #include "body_rounded_polygon.h" #include "my_pool_chunk.h" diff --git a/src/BODY/body_rounded_polyhedron.cpp b/src/BODY/body_rounded_polyhedron.cpp index 34d918f1f6..4b5208c397 100644 --- a/src/BODY/body_rounded_polyhedron.cpp +++ b/src/BODY/body_rounded_polyhedron.cpp @@ -15,6 +15,7 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include #include #include "body_rounded_polyhedron.h" #include "my_pool_chunk.h" diff --git a/src/fix_setforce.cpp b/src/fix_setforce.cpp index fc8b7aeb59..f01008dc10 100644 --- a/src/fix_setforce.cpp +++ b/src/fix_setforce.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include "fix_setforce.h" #include "atom.h" #include "update.h" diff --git a/src/fix_spring.cpp b/src/fix_spring.cpp index 328a0eeafd..c87cec2766 100644 --- a/src/fix_spring.cpp +++ b/src/fix_spring.cpp @@ -16,13 +16,11 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_spring.h" #include "atom.h" #include "update.h" #include "respa.h" -#include "domain.h" #include "force.h" #include "group.h" #include "error.h" diff --git a/src/fix_spring_chunk.cpp b/src/fix_spring_chunk.cpp index 5b5d95b111..f6ebadde94 100644 --- a/src/fix_spring_chunk.cpp +++ b/src/fix_spring_chunk.cpp @@ -12,14 +12,12 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_spring_chunk.h" #include "atom.h" #include "update.h" #include "force.h" #include "respa.h" -#include "domain.h" #include "modify.h" #include "compute_chunk_atom.h" #include "compute_com_chunk.h" diff --git a/src/fix_spring_rg.cpp b/src/fix_spring_rg.cpp index 28c8969006..1d5b87c599 100644 --- a/src/fix_spring_rg.cpp +++ b/src/fix_spring_rg.cpp @@ -16,8 +16,6 @@ Paul Crozier (SNL) ------------------------------------------------------------------------- */ -#include -#include #include #include "fix_spring_rg.h" #include "atom.h" diff --git a/src/fix_spring_self.cpp b/src/fix_spring_self.cpp index 670883af41..a5aa600229 100644 --- a/src/fix_spring_self.cpp +++ b/src/fix_spring_self.cpp @@ -15,7 +15,7 @@ Contributing author: Naveen Michaud-Agrawal (Johns Hopkins University) ------------------------------------------------------------------------- */ -#include +#include #include #include "fix_spring_self.h" #include "atom.h" diff --git a/src/fix_store.cpp b/src/fix_store.cpp index 9db65d0987..a370632489 100644 --- a/src/fix_store.cpp +++ b/src/fix_store.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "fix_store.h" #include "atom.h" diff --git a/src/fix_store_force.cpp b/src/fix_store_force.cpp index a841714098..8afd985615 100644 --- a/src/fix_store_force.cpp +++ b/src/fix_store_force.cpp @@ -15,7 +15,6 @@ #include "fix_store_force.h" #include "atom.h" #include "update.h" -#include "group.h" #include "respa.h" #include "memory.h" #include "error.h" diff --git a/src/fix_temp_berendsen.cpp b/src/fix_temp_berendsen.cpp index 55518015c4..b4dd65b0c5 100644 --- a/src/fix_temp_berendsen.cpp +++ b/src/fix_temp_berendsen.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_temp_berendsen.h" #include "atom.h" diff --git a/src/fix_temp_csld.cpp b/src/fix_temp_csld.cpp index 7bdf776355..57f7104c61 100644 --- a/src/fix_temp_csld.cpp +++ b/src/fix_temp_csld.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_temp_csld.h" #include "atom.h" diff --git a/src/fix_temp_csvr.cpp b/src/fix_temp_csvr.cpp index 495a155113..9f8135ffc8 100644 --- a/src/fix_temp_csvr.cpp +++ b/src/fix_temp_csvr.cpp @@ -16,13 +16,12 @@ Based on code by Paolo Raiteri (Curtin U) and Giovanni Bussi (SISSA) ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_temp_csvr.h" #include "atom.h" #include "force.h" -#include "memory.h" #include "comm.h" #include "input.h" #include "variable.h" diff --git a/src/fix_temp_rescale.cpp b/src/fix_temp_rescale.cpp index 11dfa6a5fc..378997c0c4 100644 --- a/src/fix_temp_rescale.cpp +++ b/src/fix_temp_rescale.cpp @@ -12,15 +12,12 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_temp_rescale.h" #include "atom.h" #include "force.h" #include "group.h" #include "update.h" -#include "domain.h" -#include "region.h" #include "comm.h" #include "input.h" #include "variable.h" diff --git a/src/fix_tmd.cpp b/src/fix_tmd.cpp index 4cbb244bc0..a0425db36c 100644 --- a/src/fix_tmd.cpp +++ b/src/fix_tmd.cpp @@ -18,7 +18,6 @@ #include #include -#include #include #include "fix_tmd.h" #include "atom.h" diff --git a/src/fix_vector.cpp b/src/fix_vector.cpp index 5657e59ab0..b7be472be6 100644 --- a/src/fix_vector.cpp +++ b/src/fix_vector.cpp @@ -18,7 +18,6 @@ #include "force.h" #include "modify.h" #include "compute.h" -#include "group.h" #include "input.h" #include "variable.h" #include "memory.h" diff --git a/src/fix_viscous.cpp b/src/fix_viscous.cpp index e845142322..cc60b1bda4 100644 --- a/src/fix_viscous.cpp +++ b/src/fix_viscous.cpp @@ -11,8 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include #include "fix_viscous.h" #include "atom.h" diff --git a/src/fix_wall.cpp b/src/fix_wall.cpp index e84d01191d..1046efc2df 100644 --- a/src/fix_wall.cpp +++ b/src/fix_wall.cpp @@ -11,11 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include +#include #include #include "fix_wall.h" -#include "atom.h" #include "input.h" #include "variable.h" #include "domain.h" diff --git a/src/fix_wall_harmonic.cpp b/src/fix_wall_harmonic.cpp index 4dc067178a..6c6d5ec402 100644 --- a/src/fix_wall_harmonic.cpp +++ b/src/fix_wall_harmonic.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_wall_harmonic.h" #include "atom.h" #include "error.h" diff --git a/src/fix_wall_reflect.cpp b/src/fix_wall_reflect.cpp index 8acba72035..edf5c40a5f 100644 --- a/src/fix_wall_reflect.cpp +++ b/src/fix_wall_reflect.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "fix_wall_reflect.h" #include "atom.h" diff --git a/src/fix_wall_region.cpp b/src/fix_wall_region.cpp index ff147d7446..cb1c3c2ab2 100644 --- a/src/fix_wall_region.cpp +++ b/src/fix_wall_region.cpp @@ -11,18 +11,15 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_wall_region.h" #include "atom.h" -#include "atom_vec.h" #include "domain.h" #include "region.h" #include "force.h" -#include "lattice.h" #include "update.h" -#include "output.h" #include "respa.h" #include "error.h" #include "math_const.h" diff --git a/src/force.cpp b/src/force.cpp index 2648358932..e4939a10e8 100644 --- a/src/force.cpp +++ b/src/force.cpp @@ -21,7 +21,6 @@ #include "style_improper.h" #include "style_pair.h" #include "style_kspace.h" -#include "atom.h" #include "comm.h" #include "pair.h" #include "pair_hybrid.h" @@ -32,8 +31,6 @@ #include "dihedral.h" #include "improper.h" #include "kspace.h" -#include "group.h" -#include "memory.h" #include "error.h" #include "utils.h" diff --git a/src/group.cpp b/src/group.cpp index 256bab7778..a37d209947 100644 --- a/src/group.cpp +++ b/src/group.cpp @@ -13,9 +13,8 @@ #include #include -#include #include -#include +#include #include "group.h" #include "domain.h" #include "atom.h" diff --git a/src/hashlittle.cpp b/src/hashlittle.cpp index 42109abd24..e9340a7e55 100644 --- a/src/hashlittle.cpp +++ b/src/hashlittle.cpp @@ -2,7 +2,6 @@ // from lookup3.c, by Bob Jenkins, May 2006, Public Domain // bob_jenkins@burtleburtle.net -#include #include #include diff --git a/src/image.cpp b/src/image.cpp index 3df167bbf6..ccd6d98d87 100644 --- a/src/image.cpp +++ b/src/image.cpp @@ -18,7 +18,6 @@ #include #include #include -#include #include #include "image.h" #include "math_extra.h" @@ -29,7 +28,7 @@ #include "memory.h" #ifdef LAMMPS_JPEG -#include "jpeglib.h" +#include #endif #ifdef LAMMPS_PNG diff --git a/src/imbalance.h b/src/imbalance.h index 5f43c2e51d..0cc4ac844e 100644 --- a/src/imbalance.h +++ b/src/imbalance.h @@ -14,7 +14,7 @@ #ifndef LMP_IMBALANCE_H #define LMP_IMBALANCE_H -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/imbalance_var.cpp b/src/imbalance_var.cpp index e089b1df0c..ba17c06866 100644 --- a/src/imbalance_var.cpp +++ b/src/imbalance_var.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "imbalance_var.h" #include "atom.h" @@ -20,9 +21,6 @@ #include "memory.h" #include "error.h" -// DEBUG -#include "update.h" - using namespace LAMMPS_NS; /* -------------------------------------------------------------------- */ diff --git a/src/improper.cpp b/src/improper.cpp index 17e2df4e59..eefe3222ee 100644 --- a/src/improper.cpp +++ b/src/improper.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "improper.h" #include "atom.h" #include "comm.h" diff --git a/src/improper_hybrid.cpp b/src/improper_hybrid.cpp index 5fdcb42a96..af1382d3eb 100644 --- a/src/improper_hybrid.cpp +++ b/src/improper_hybrid.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include #include #include "improper_hybrid.h" #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/improper_zero.cpp b/src/improper_zero.cpp index 747dd57919..3f36954a0a 100644 --- a/src/improper_zero.cpp +++ b/src/improper_zero.cpp @@ -15,13 +15,10 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ -#include -#include #include #include "improper_zero.h" #include "atom.h" #include "force.h" -#include "comm.h" #include "memory.h" #include "error.h" diff --git a/src/info.cpp b/src/info.cpp index 25b9879408..bb2d3c4b45 100644 --- a/src/info.cpp +++ b/src/info.cpp @@ -16,7 +16,13 @@ Richard Berger (Temple U) ------------------------------------------------------------------------- */ +#include +#include #include +#include +#include +#include +#include #include "info.h" #include "accelerator_kokkos.h" #include "atom.h" @@ -44,18 +50,12 @@ #include "error.h" #include "utils.h" -#include -#include -#include -#include - #ifdef _WIN32 #define PSAPI_VERSION 1 #include #include // requires C++-11 #include #else -#include #include #include #endif diff --git a/src/input.cpp b/src/input.cpp index 9e0ad78d9e..cbad1d78bf 100644 --- a/src/input.cpp +++ b/src/input.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include #include @@ -52,10 +51,6 @@ #include "memory.h" #include "utils.h" -#ifdef _OPENMP -#include -#endif - #ifdef _WIN32 #include #endif diff --git a/src/integrate.cpp b/src/integrate.cpp index d6b27e042d..545de849d5 100644 --- a/src/integrate.cpp +++ b/src/integrate.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "integrate.h" #include "update.h" #include "force.h" diff --git a/src/irregular.cpp b/src/irregular.cpp index 1865f9cbf6..2040d12d0b 100644 --- a/src/irregular.cpp +++ b/src/irregular.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "irregular.h" #include "atom.h" diff --git a/src/irregular.h b/src/irregular.h index d56bcb253d..3fdfe20b36 100644 --- a/src/irregular.h +++ b/src/irregular.h @@ -14,6 +14,7 @@ #ifndef LMP_IRREGULAR_H #define LMP_IRREGULAR_H +#include #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/kspace.cpp b/src/kspace.cpp index 643cf22113..b51191857d 100644 --- a/src/kspace.cpp +++ b/src/kspace.cpp @@ -11,6 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include +#include #include #include #include "kspace.h" diff --git a/src/kspace.h b/src/kspace.h index 69f4ccb433..83ce19cd87 100644 --- a/src/kspace.h +++ b/src/kspace.h @@ -14,6 +14,7 @@ #ifndef LMP_KSPACE_H #define LMP_KSPACE_H +#include #include "pointers.h" #ifdef FFT_SINGLE diff --git a/src/lammps.cpp b/src/lammps.cpp index 83a2f057ee..b73d9f1968 100644 --- a/src/lammps.cpp +++ b/src/lammps.cpp @@ -48,7 +48,6 @@ #include "output.h" #include "citeme.h" #include "accelerator_kokkos.h" -#include "accelerator_omp.h" #include "timer.h" #include "lmppython.h" #include "version.h" diff --git a/src/library.cpp b/src/library.cpp index a653b83adb..033b814865 100644 --- a/src/library.cpp +++ b/src/library.cpp @@ -15,13 +15,11 @@ // customize by adding new LAMMPS-specific functions #include +#include #include #include #include "library.h" -#include "lmptype.h" -#include "lammps.h" #include "universe.h" -#include "input.h" #include "atom_vec.h" #include "atom.h" #include "domain.h" diff --git a/src/library.h b/src/library.h index f6f8d9d75c..8b03bb3621 100644 --- a/src/library.h +++ b/src/library.h @@ -17,7 +17,9 @@ */ #include +#ifdef LAMMPS_BIGBIG #include /* for int64_t */ +#endif /* ifdefs allow this file to be included in a C program */ diff --git a/src/math_extra.h b/src/math_extra.h index 85f57224cf..09b135c641 100644 --- a/src/math_extra.h +++ b/src/math_extra.h @@ -19,9 +19,6 @@ #define LMP_MATH_EXTRA_H #include -#include -#include -#include "error.h" namespace MathExtra { diff --git a/src/memory.cpp b/src/memory.cpp index b2f8a95b17..ca7fd3ea7f 100644 --- a/src/memory.cpp +++ b/src/memory.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include -#include #include "memory.h" #include "error.h" diff --git a/src/memory.h b/src/memory.h index c5eddc7fe7..42c9bf6aba 100644 --- a/src/memory.h +++ b/src/memory.h @@ -14,7 +14,6 @@ #ifndef LMP_MEMORY_H #define LMP_MEMORY_H -#include "lmptype.h" #include "pointers.h" namespace LAMMPS_NS { diff --git a/src/min.cpp b/src/min.cpp index 2a42a444a0..f2e1c982be 100644 --- a/src/min.cpp +++ b/src/min.cpp @@ -19,8 +19,8 @@ JR Shewchuk, http://www-2.cs.cmu.edu/~jrs/jrspapers.html#cg ------------------------------------------------------------------------- */ +#include #include -#include #include #include "min.h" #include "atom.h" diff --git a/src/min_cg.cpp b/src/min_cg.cpp index 20e8cc30dd..eb8831c8f5 100644 --- a/src/min_cg.cpp +++ b/src/min_cg.cpp @@ -13,9 +13,7 @@ #include #include -#include #include "min_cg.h" -#include "atom.h" #include "update.h" #include "output.h" #include "timer.h" diff --git a/src/min_fire.cpp b/src/min_fire.cpp index a50071d562..79346341bb 100644 --- a/src/min_fire.cpp +++ b/src/min_fire.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "min_fire.h" #include "universe.h" @@ -19,7 +20,6 @@ #include "update.h" #include "output.h" #include "timer.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/min_hftn.cpp b/src/min_hftn.cpp index 0c834fbeb4..c2c251c386 100644 --- a/src/min_hftn.cpp +++ b/src/min_hftn.cpp @@ -17,6 +17,7 @@ "Parallel Unconstrained Min", Plantenga, SAND98-8201 ------------------------------------------------------------------------- */ +#include #include #include #include "atom.h" diff --git a/src/min_linesearch.cpp b/src/min_linesearch.cpp index f93a56b09d..33a781ecfe 100644 --- a/src/min_linesearch.cpp +++ b/src/min_linesearch.cpp @@ -21,19 +21,16 @@ JR Shewchuk, http://www-2.cs.cmu.edu/~jrs/jrspapers.html#cg ------------------------------------------------------------------------- */ +#include #include #include "min_linesearch.h" #include "atom.h" -#include "update.h" -#include "neighbor.h" -#include "domain.h" #include "modify.h" +#include "neighbor.h" #include "fix_minimize.h" #include "pair.h" #include "output.h" #include "thermo.h" -#include "timer.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/min_quickmin.cpp b/src/min_quickmin.cpp index 8b48816355..784da82686 100644 --- a/src/min_quickmin.cpp +++ b/src/min_quickmin.cpp @@ -20,7 +20,6 @@ #include "update.h" #include "output.h" #include "timer.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/min_sd.cpp b/src/min_sd.cpp index 5d44437ca0..d66601119b 100644 --- a/src/min_sd.cpp +++ b/src/min_sd.cpp @@ -12,9 +12,7 @@ ------------------------------------------------------------------------- */ #include -#include #include "min_sd.h" -#include "atom.h" #include "update.h" #include "output.h" #include "timer.h" diff --git a/src/minimize.cpp b/src/minimize.cpp index e27fffd74b..e1af924019 100644 --- a/src/minimize.cpp +++ b/src/minimize.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "minimize.h" #include "domain.h" #include "update.h" diff --git a/src/modify.cpp b/src/modify.cpp index 3f034bf034..61497d86db 100644 --- a/src/modify.cpp +++ b/src/modify.cpp @@ -11,7 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include "modify.h" #include "style_compute.h" diff --git a/src/molecule.cpp b/src/molecule.cpp index 454459084a..4a3790296f 100644 --- a/src/molecule.cpp +++ b/src/molecule.cpp @@ -11,7 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include +#include +#include #include #include "molecule.h" #include "atom.h" @@ -21,12 +23,10 @@ #include "comm.h" #include "domain.h" #include "math_extra.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; #define MAXLINE 256 #define EPSILON 1.0e-7 diff --git a/src/nbin.cpp b/src/nbin.cpp index a30b76cca0..0480c9730d 100644 --- a/src/nbin.cpp +++ b/src/nbin.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include "nbin.h" #include "neighbor.h" #include "neigh_request.h" #include "domain.h" -#include "update.h" #include "memory.h" #include "error.h" diff --git a/src/neigh_list.cpp b/src/neigh_list.cpp index 6bdb9beae6..651b2ed70a 100644 --- a/src/neigh_list.cpp +++ b/src/neigh_list.cpp @@ -12,15 +12,13 @@ ------------------------------------------------------------------------- */ #include "neigh_list.h" +#include "my_page.h" #include "atom.h" #include "comm.h" -#include "update.h" -#include "pair.h" #include "neighbor.h" #include "neigh_request.h" #include "my_page.h" #include "memory.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/neigh_list.h b/src/neigh_list.h index 755a1bf134..aca11cd921 100644 --- a/src/neigh_list.h +++ b/src/neigh_list.h @@ -15,7 +15,6 @@ #define LMP_NEIGH_LIST_H #include "pointers.h" -#include "my_page.h" namespace LAMMPS_NS { diff --git a/src/neighbor.cpp b/src/neighbor.cpp index 0382624198..a2efc5919b 100644 --- a/src/neighbor.cpp +++ b/src/neighbor.cpp @@ -17,7 +17,6 @@ #include #include -#include #include #include "neighbor.h" #include "neigh_list.h" @@ -48,8 +47,6 @@ #include "error.h" #include "utils.h" -#include - using namespace LAMMPS_NS; using namespace NeighConst; diff --git a/src/neighbor.h b/src/neighbor.h index 3466dd426a..50de4b4c98 100644 --- a/src/neighbor.h +++ b/src/neighbor.h @@ -15,7 +15,6 @@ #define LMP_NEIGHBOR_H #include "pointers.h" -#include namespace LAMMPS_NS { diff --git a/src/npair_copy.cpp b/src/npair_copy.cpp index 9426d22ed3..0a522c628d 100644 --- a/src/npair_copy.cpp +++ b/src/npair_copy.cpp @@ -12,14 +12,7 @@ ------------------------------------------------------------------------- */ #include "npair_copy.h" -#include "neighbor.h" #include "neigh_list.h" -#include "atom.h" -#include "atom_vec.h" -#include "molecule.h" -#include "domain.h" -#include "my_page.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/npair_full_bin.cpp b/src/npair_full_bin.cpp index 94a6af129c..464dca9251 100644 --- a/src/npair_full_bin.cpp +++ b/src/npair_full_bin.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_full_bin.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_full_bin_atomonly.cpp b/src/npair_full_bin_atomonly.cpp index db84733f1c..758fc7e42b 100644 --- a/src/npair_full_bin_atomonly.cpp +++ b/src/npair_full_bin_atomonly.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "npair_full_bin_atomonly.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/procmap.cpp b/src/procmap.cpp index 9d1ed83e73..08b60a26af 100644 --- a/src/procmap.cpp +++ b/src/procmap.cpp @@ -15,6 +15,7 @@ Contributing author (NUMA option) : Mike Brown (ORNL) ------------------------------------------------------------------------- */ +#include #include "procmap.h" #include "universe.h" #include "comm.h" From 3e88dacd3f351ad4a373a27b76d6799d7e1558c9 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 30 Jun 2019 17:27:29 -0400 Subject: [PATCH 21/79] recover broken compilation of the USER-EFF package --- src/USER-EFF/fix_nvt_sllod_eff.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/USER-EFF/fix_nvt_sllod_eff.cpp b/src/USER-EFF/fix_nvt_sllod_eff.cpp index ed2274dcf9..0ebbf04d64 100644 --- a/src/USER-EFF/fix_nvt_sllod_eff.cpp +++ b/src/USER-EFF/fix_nvt_sllod_eff.cpp @@ -12,6 +12,7 @@ ------------------------------------------------------------------------- */ #include +#include #include #include "fix_nvt_sllod_eff.h" #include "math_extra.h" From e29361523f472a67ca2c7309b7b6da3c9b29aef4 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 30 Jun 2019 18:30:59 -0400 Subject: [PATCH 22/79] recover compilation of the USER-PHONON package --- src/USER-PHONON/dynamical_matrix.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/USER-PHONON/dynamical_matrix.cpp b/src/USER-PHONON/dynamical_matrix.cpp index d94bd11a80..559ef4c36f 100644 --- a/src/USER-PHONON/dynamical_matrix.cpp +++ b/src/USER-PHONON/dynamical_matrix.cpp @@ -3,15 +3,15 @@ // #include -#include +#include +#include #include "dynamical_matrix.h" #include "atom.h" -#include "modify.h" #include "domain.h" #include "comm.h" +#include "error.h" #include "group.h" #include "force.h" -#include "math_extra.h" #include "memory.h" #include "bond.h" #include "angle.h" @@ -25,7 +25,6 @@ #include "finish.h" #include - using namespace LAMMPS_NS; enum{REGULAR,ESKM}; From 78af59438101a989c6c1a5708601f7ba4a474f95 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 30 Jun 2019 22:45:41 -0400 Subject: [PATCH 23/79] fix typos. restore compilation of LAMMPS class implementation with OpenMP --- doc/include-file-conventions.md | 12 ++++++------ src/lammps.cpp | 1 + 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/doc/include-file-conventions.md b/doc/include-file-conventions.md index 8d70d6cdec..3f591361f5 100644 --- a/doc/include-file-conventions.md +++ b/doc/include-file-conventions.md @@ -25,7 +25,7 @@ well as make otherwise hidden dependencies visible. ## Rules -Below are the various rules that are applied. Not all a enforced +Below are the various rules that are applied. Not all are enforced strictly and automatically. If there are no significant side effects, exceptions may be possible for cases, where a full compliance to the rules may require a large effort compared to the benefit. @@ -78,9 +78,9 @@ result in a high potential for direct or indirect symbol name clashes. In the ideal case, the header would only include one file defining the parent class. That would typically be either `#include "pointers.h"` for the `Pointers` class, or a header of a class derived from it like -`#include "pair.h"` for the `Pair` class and so on. Referenced to other +`#include "pair.h"` for the `Pair` class and so on. References to other classes inside the class should be make through pointers, for which forward -declarations (inside the `LAMMPS_NS` or the new class'es namespace) can +declarations (inside the `LAMMPS_NS` or the new class' namespace) can be employed. The full definition will then be included into the corresponding implementation file. In the given example from above, the header file would be called `some_name.h` and the implementation `some_name.cpp` (all @@ -92,7 +92,7 @@ a forward slash). In the implementation files (typically, those would have the same base name as the corresponding header with a .cpp extension instead of .h) include -statments should follow the "include what you use" principle. +statements should follow the "include what you use" principle. ### Order of Include Statements @@ -107,7 +107,7 @@ Include files should be included in this order: #### pointers.h The `pointer.h` header file also includes `cstdio` and `lmptype.h` -(and throught it `stdint.h`, `intttypes.h`, and `climits`). +(and through it `stdint.h`, `intttypes.h`, and `climits`). This means any header including `pointers.h` can assume that `FILE`, `NULL`, `INT_MAX` are defined. @@ -115,7 +115,7 @@ This means any header including `pointers.h` can assume that `FILE`, The [Include What You Use tool](https://include-what-you-use.org/) can be used to provide supporting information about compliance with -the rules listed here. There are some limitations and the IWWU tool +the rules listed here. There are some limitations and the IWYU tool may give incorrect advice. The tools is activated by setting the CMake variable `CMAKE_CXX_INCLUDE_WHAT_YOU_USE` variable to the path of the `include-what-you-use` command. When activated, the diff --git a/src/lammps.cpp b/src/lammps.cpp index b73d9f1968..83a2f057ee 100644 --- a/src/lammps.cpp +++ b/src/lammps.cpp @@ -48,6 +48,7 @@ #include "output.h" #include "citeme.h" #include "accelerator_kokkos.h" +#include "accelerator_omp.h" #include "timer.h" #include "lmppython.h" #include "version.h" From e0c04355bb1019ee3ce37242a2cd426dedaef128 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 30 Jun 2019 22:59:44 -0400 Subject: [PATCH 24/79] try to recover compiling of USER-OMP with OpenMP enabled --- src/USER-OMP/fix_neigh_history_omp.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/USER-OMP/fix_neigh_history_omp.cpp b/src/USER-OMP/fix_neigh_history_omp.cpp index efa7f5a3f1..be03e1d8f2 100644 --- a/src/USER-OMP/fix_neigh_history_omp.cpp +++ b/src/USER-OMP/fix_neigh_history_omp.cpp @@ -14,6 +14,7 @@ #include #include #include "fix_neigh_history_omp.h" +#include "my_page.h" #include "atom.h" #include "comm.h" #include "neighbor.h" From 44372f52369cb101a3ca6757035d9e1ec2443fb6 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 30 Jun 2019 23:12:08 -0400 Subject: [PATCH 25/79] more fixes for USER-OMP --- src/USER-OMP/fix_rigid_nh_omp.cpp | 6 ++++-- src/USER-OMP/fix_rigid_omp.cpp | 6 ++++-- src/USER-OMP/fix_rigid_small_omp.cpp | 4 ++-- src/lammps.cpp | 2 +- 4 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/USER-OMP/fix_rigid_nh_omp.cpp b/src/USER-OMP/fix_rigid_nh_omp.cpp index 53d0134741..e6a6e065bf 100644 --- a/src/USER-OMP/fix_rigid_nh_omp.cpp +++ b/src/USER-OMP/fix_rigid_nh_omp.cpp @@ -15,6 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include +#include + #include "fix_rigid_nh_omp.h" #include "atom.h" @@ -24,13 +27,12 @@ #include "comm.h" #include "compute.h" #include "domain.h" +#include "error.h" #include "force.h" #include "kspace.h" #include "modify.h" #include "update.h" -#include - #if defined(_OPENMP) #include #endif diff --git a/src/USER-OMP/fix_rigid_omp.cpp b/src/USER-OMP/fix_rigid_omp.cpp index 12c6362ed8..20478b3ca1 100644 --- a/src/USER-OMP/fix_rigid_omp.cpp +++ b/src/USER-OMP/fix_rigid_omp.cpp @@ -15,6 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include +#include + #include "fix_rigid_omp.h" #include "atom.h" @@ -23,8 +26,7 @@ #include "atom_vec_tri.h" #include "comm.h" #include "domain.h" - -#include +#include "error.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/fix_rigid_small_omp.cpp b/src/USER-OMP/fix_rigid_small_omp.cpp index a0495b3b93..1f6173497d 100644 --- a/src/USER-OMP/fix_rigid_small_omp.cpp +++ b/src/USER-OMP/fix_rigid_small_omp.cpp @@ -15,6 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include + #include "fix_rigid_small_omp.h" #include "atom.h" @@ -24,8 +26,6 @@ #include "comm.h" #include "domain.h" -#include - #if defined(_OPENMP) #include #endif diff --git a/src/lammps.cpp b/src/lammps.cpp index 83a2f057ee..052d14dfed 100644 --- a/src/lammps.cpp +++ b/src/lammps.cpp @@ -48,7 +48,7 @@ #include "output.h" #include "citeme.h" #include "accelerator_kokkos.h" -#include "accelerator_omp.h" +#include "accelerator_omp.h" // IWYU pragma: keep #include "timer.h" #include "lmppython.h" #include "version.h" From 39f5b8c734af3e2408656f473638dcf39400babc Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 1 Jul 2019 04:16:00 -0400 Subject: [PATCH 26/79] transform POEMS library to conform to IWYU conventions --- lib/poems/body.cpp | 14 ++++++++++++-- lib/poems/body.h | 20 +++++++++----------- lib/poems/body23joint.cpp | 16 ++++++++-------- lib/poems/body23joint.h | 6 ++---- lib/poems/colmatmap.h | 3 +++ lib/poems/colmatrix.cpp | 3 +-- lib/poems/colmatrix.h | 3 ++- lib/poems/eulerparameters.cpp | 4 ++++ lib/poems/eulerparameters.h | 6 +++--- lib/poems/fastmatrixops.cpp | 13 +++++++++++-- lib/poems/fastmatrixops.h | 11 ++++++++++- lib/poems/fixedpoint.cpp | 3 +++ lib/poems/fixedpoint.h | 2 ++ lib/poems/freebodyjoint.cpp | 12 ++++++++---- lib/poems/freebodyjoint.h | 3 +++ lib/poems/inertialframe.cpp | 4 +++- lib/poems/inertialframe.h | 3 +++ lib/poems/joint.cpp | 19 +++++++++++++++---- lib/poems/joint.h | 9 +++++++-- lib/poems/mat3x3.cpp | 3 ++- lib/poems/mat3x3.h | 3 +-- lib/poems/mat4x4.cpp | 2 ++ lib/poems/mat4x4.h | 4 +++- lib/poems/mat6x6.cpp | 2 ++ lib/poems/mat6x6.h | 3 ++- lib/poems/matrix.h | 2 ++ lib/poems/matrixfun.cpp | 10 ++++++++-- lib/poems/matrixfun.h | 18 +++++++++++++----- lib/poems/mixedjoint.cpp | 11 ++++++++--- lib/poems/mixedjoint.h | 4 ++++ lib/poems/norm.cpp | 6 ++++++ lib/poems/norm.h | 7 +++++-- lib/poems/onbody.cpp | 7 +++++-- lib/poems/onbody.h | 12 +++++++----- lib/poems/onfunctions.cpp | 9 +++++++-- lib/poems/onfunctions.h | 5 ++++- lib/poems/onsolver.cpp | 14 +++++++++++--- lib/poems/onsolver.h | 4 +++- lib/poems/particle.cpp | 1 - lib/poems/particle.h | 2 ++ lib/poems/poemstreenode.h | 6 ------ lib/poems/point.cpp | 4 +++- lib/poems/prismaticjoint.cpp | 4 ++++ lib/poems/prismaticjoint.h | 4 +++- lib/poems/revolutejoint.cpp | 4 ++++ lib/poems/revolutejoint.h | 5 +++-- lib/poems/rigidbody.cpp | 3 ++- lib/poems/rigidbody.h | 2 ++ lib/poems/rowmatrix.cpp | 2 +- lib/poems/rowmatrix.h | 3 +++ lib/poems/solver.cpp | 3 ++- lib/poems/solver.h | 4 ++-- lib/poems/sphericaljoint.cpp | 10 +++++++--- lib/poems/sphericaljoint.h | 6 ++---- lib/poems/system.cpp | 19 ++++++++++++++++++- lib/poems/system.h | 25 +------------------------ lib/poems/vect3.cpp | 9 +++++++++ lib/poems/vect3.h | 4 ++++ lib/poems/vect4.cpp | 2 ++ lib/poems/vect4.h | 4 +++- lib/poems/vect6.cpp | 2 ++ lib/poems/vect6.h | 3 +++ lib/poems/workspace.cpp | 19 +++++++++++++++---- lib/poems/workspace.h | 9 --------- 64 files changed, 301 insertions(+), 138 deletions(-) diff --git a/lib/poems/body.cpp b/lib/poems/body.cpp index 4ef05dd1e6..487d5e1ab7 100644 --- a/lib/poems/body.cpp +++ b/lib/poems/body.cpp @@ -14,9 +14,19 @@ * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - -#include "bodies.h" + +#include + +#include "body.h" +#include "inertialframe.h" +#include "mat3x3.h" +#include "particle.h" +#include "poemslist.h" #include "point.h" +#include "rigidbody.h" +#include "vect3.h" + +class Joint; using namespace std; diff --git a/lib/poems/body.h b/lib/poems/body.h index f8e0f6a5a3..06a9c72417 100644 --- a/lib/poems/body.h +++ b/lib/poems/body.h @@ -19,13 +19,11 @@ #ifndef BODY_H #define BODY_H -#include "poemslist.h" #include +#include "poemslist.h" #include "poemsobject.h" - -#include "matrices.h" - - +#include "mat3x3.h" +#include "vect3.h" // emumerated type enum BodyType { @@ -33,16 +31,16 @@ enum BodyType { PARTICLE = 1, RIGIDBODY = 2 }; - + class Point; class Joint; -class CompBody; + class Body : public POEMSObject { public: double mass; Mat3x3 inertia; - + Vect3 r; Vect3 v; Vect3 v_k; @@ -54,13 +52,13 @@ public: Vect3 alpha; Vect3 alpha_t; double KE; - + List joints; List points; Body(); - + bool ReadIn(std::istream& in); void WriteOut(std::ostream& out); bool ReadInPoints(std::istream& in); @@ -68,7 +66,7 @@ public: Point* GetPoint(int p); void AddJoint(Joint* joint); void AddPoint(Point* point); - + virtual bool ReadInBodyData(std::istream& in) = 0; virtual void WriteOutBodyData(std::ostream& out) = 0; virtual ~Body(); diff --git a/lib/poems/body23joint.cpp b/lib/poems/body23joint.cpp index 8cd0a95bca..7aa761fe2a 100644 --- a/lib/poems/body23joint.cpp +++ b/lib/poems/body23joint.cpp @@ -14,18 +14,18 @@ * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - +#include #include "body23joint.h" -#include "point.h" -#include "matrixfun.h" #include "body.h" -#include "fastmatrixops.h" -#include "norm.h" +#include "colmatrix.h" #include "eulerparameters.h" -#include "matrices.h" -#include - +#include "fastmatrixops.h" +#include "mat3x3.h" +#include "matrixfun.h" +#include "point.h" +#include "vect3.h" +#include "virtualmatrix.h" Body23Joint::Body23Joint(){ DimQandU(4,2); diff --git a/lib/poems/body23joint.h b/lib/poems/body23joint.h index 60253ac8a4..c47cdfb9de 100644 --- a/lib/poems/body23joint.h +++ b/lib/poems/body23joint.h @@ -18,11 +18,9 @@ #ifndef BODY23JOINT_H #define BODY23JOINT_H +#include #include "joint.h" -#include "vect3.h" -#include "mat3x3.h" - - +#include "matrix.h" class Body23Joint : public Joint { Matrix const_sP; diff --git a/lib/poems/colmatmap.h b/lib/poems/colmatmap.h index 3a6267a247..6d84870046 100644 --- a/lib/poems/colmatmap.h +++ b/lib/poems/colmatmap.h @@ -19,7 +19,10 @@ #ifndef COLMATMAP_H #define COLMATMAP_H +#include + #include "virtualcolmatrix.h" +#include "virtualmatrix.h" class ColMatrix; diff --git a/lib/poems/colmatrix.cpp b/lib/poems/colmatrix.cpp index dc6f49be2b..e7ae98a368 100644 --- a/lib/poems/colmatrix.cpp +++ b/lib/poems/colmatrix.cpp @@ -16,9 +16,8 @@ *_________________________________________________________________________*/ #include "colmatrix.h" -#include "rowmatrix.h" + #include -#include #include using namespace std; diff --git a/lib/poems/colmatrix.h b/lib/poems/colmatrix.h index 11fd85a928..70f13356e2 100644 --- a/lib/poems/colmatrix.h +++ b/lib/poems/colmatrix.h @@ -19,8 +19,9 @@ #ifndef COLMATRIX_H #define COLMATRIX_H +#include #include "virtualcolmatrix.h" -#include "colmatmap.h" +#include "virtualmatrix.h" class Matrix; class Vect6; diff --git a/lib/poems/eulerparameters.cpp b/lib/poems/eulerparameters.cpp index 032bc7da82..f698c40b3a 100644 --- a/lib/poems/eulerparameters.cpp +++ b/lib/poems/eulerparameters.cpp @@ -16,8 +16,12 @@ *_________________________________________________________________________*/ #include "eulerparameters.h" + #include +#include "colmatrix.h" +#include "mat3x3.h" + using namespace std; void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot){ diff --git a/lib/poems/eulerparameters.h b/lib/poems/eulerparameters.h index 029ade4b78..2e69a85fb9 100644 --- a/lib/poems/eulerparameters.h +++ b/lib/poems/eulerparameters.h @@ -14,12 +14,12 @@ * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #ifndef EULERPARAMETERS_H #define EULERPARAMETERS_H -#include "colmatrix.h" -#include "mat3x3.h" +class ColMatrix; +class Mat3x3; void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); diff --git a/lib/poems/fastmatrixops.cpp b/lib/poems/fastmatrixops.cpp index 782381a706..e6c81f0659 100644 --- a/lib/poems/fastmatrixops.cpp +++ b/lib/poems/fastmatrixops.cpp @@ -15,10 +15,19 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ -#include -#include "fastmatrixops.h" #include +#include "fastmatrixops.h" +#include "colmatmap.h" +#include "colmatrix.h" +#include "mat3x3.h" +#include "mat4x4.h" +#include "mat6x6.h" +#include "matrix.h" +#include "vect3.h" +#include "vect4.h" +#include "vect6.h" + using namespace std; // diff --git a/lib/poems/fastmatrixops.h b/lib/poems/fastmatrixops.h index e7ccdbd0ca..b2784a6e53 100644 --- a/lib/poems/fastmatrixops.h +++ b/lib/poems/fastmatrixops.h @@ -17,7 +17,16 @@ #ifndef FASTMATRIXOPS_H #define FASTMATRIXOPS_H -#include "matrices.h" + +class ColMatMap; +class ColMatrix; +class Mat3x3; +class Mat4x4; +class Mat6x6; +class Matrix; +class Vect3; +class Vect4; +class Vect6; void FastCross(Vect3& a, Vect3& b, Vect3& c); void FastSimpleRotation(Vect3& v, double q, Mat3x3& C); diff --git a/lib/poems/fixedpoint.cpp b/lib/poems/fixedpoint.cpp index 8600882393..238ddfed70 100644 --- a/lib/poems/fixedpoint.cpp +++ b/lib/poems/fixedpoint.cpp @@ -17,9 +17,12 @@ #include "fixedpoint.h" + #include #include +#include "virtualmatrix.h" + using namespace std; FixedPoint::FixedPoint(){ diff --git a/lib/poems/fixedpoint.h b/lib/poems/fixedpoint.h index b5ecb23906..fb8f23b0ae 100644 --- a/lib/poems/fixedpoint.h +++ b/lib/poems/fixedpoint.h @@ -19,6 +19,8 @@ #ifndef FIXEDPOINT_H #define FIXEDPOINT_H +#include + #include "point.h" #include "vect3.h" diff --git a/lib/poems/freebodyjoint.cpp b/lib/poems/freebodyjoint.cpp index d00f0bdb98..e6c59340f3 100644 --- a/lib/poems/freebodyjoint.cpp +++ b/lib/poems/freebodyjoint.cpp @@ -16,14 +16,18 @@ *_________________________________________________________________________*/ #include "freebodyjoint.h" -#include "point.h" + +#include + #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" -#include "norm.h" #include "eulerparameters.h" -#include "matrices.h" -#include +#include "colmatrix.h" +#include "mat3x3.h" +#include "mat6x6.h" +#include "vect3.h" +#include "virtualmatrix.h" FreeBodyJoint::FreeBodyJoint(){ diff --git a/lib/poems/freebodyjoint.h b/lib/poems/freebodyjoint.h index 27cacf7dc6..10574847e1 100644 --- a/lib/poems/freebodyjoint.h +++ b/lib/poems/freebodyjoint.h @@ -18,7 +18,10 @@ #ifndef FREEBODYJOINT_H #define FREEBODYJOINT_H +#include + #include "joint.h" +#include "matrix.h" class FreeBodyJoint : public Joint{ diff --git a/lib/poems/inertialframe.cpp b/lib/poems/inertialframe.cpp index 6c97b2f584..98ec820e7f 100644 --- a/lib/poems/inertialframe.cpp +++ b/lib/poems/inertialframe.cpp @@ -16,7 +16,9 @@ *_________________________________________________________________________*/ #include "inertialframe.h" -#include "fixedpoint.h" + +#include "mat3x3.h" +#include "virtualmatrix.h" using namespace std; diff --git a/lib/poems/inertialframe.h b/lib/poems/inertialframe.h index 08d0279a1e..3620641537 100644 --- a/lib/poems/inertialframe.h +++ b/lib/poems/inertialframe.h @@ -19,7 +19,10 @@ #ifndef INERTIALFRAME_H #define INERTIALFRAME_H +#include + #include "body.h" +#include "vect3.h" class InertialFrame : public Body { diff --git a/lib/poems/joint.cpp b/lib/poems/joint.cpp index 3bdd7b5fcd..ff24d5ebf5 100644 --- a/lib/poems/joint.cpp +++ b/lib/poems/joint.cpp @@ -16,13 +16,24 @@ *_________________________________________________________________________*/ -#include "joints.h" +#include +#include +#include + #include "body.h" #include "point.h" -#include -#include "matrixfun.h" #include "fastmatrixops.h" -#include +#include "body23joint.h" +#include "colmatrix.h" +#include "freebodyjoint.h" +#include "joint.h" +#include "mat3x3.h" +#include "matrix.h" +#include "mixedjoint.h" +#include "prismaticjoint.h" +#include "revolutejoint.h" +#include "sphericaljoint.h" +#include "virtualmatrix.h" using namespace std; diff --git a/lib/poems/joint.h b/lib/poems/joint.h index 17122af775..958805c4b5 100644 --- a/lib/poems/joint.h +++ b/lib/poems/joint.h @@ -18,9 +18,14 @@ #ifndef JOINT_H #define JOINT_H -#include "poemsobject.h" #include -#include "matrices.h" +#include "poemsobject.h" +#include "colmatrix.h" +#include "mat3x3.h" +#include "matrix.h" +#include "vect3.h" + +class VirtualMatrix; enum JointType { XYZJOINT = 0, diff --git a/lib/poems/mat3x3.cpp b/lib/poems/mat3x3.cpp index df24d4b108..3d9f1adcca 100644 --- a/lib/poems/mat3x3.cpp +++ b/lib/poems/mat3x3.cpp @@ -16,8 +16,9 @@ *_________________________________________________________________________*/ -#include "mat3x3.h" #include +#include +#include "mat3x3.h" using namespace std; diff --git a/lib/poems/mat3x3.h b/lib/poems/mat3x3.h index 4362b3ad9c..18abeadddc 100644 --- a/lib/poems/mat3x3.h +++ b/lib/poems/mat3x3.h @@ -18,12 +18,11 @@ #ifndef MAT3X3_H #define MAT3X3_H +#include #include "virtualmatrix.h" - class Vect3; class Mat6x6; -class Matrix; class ColMatrix; class Mat3x3 : public VirtualMatrix { diff --git a/lib/poems/mat4x4.cpp b/lib/poems/mat4x4.cpp index 4a611a6796..a6a587bc03 100644 --- a/lib/poems/mat4x4.cpp +++ b/lib/poems/mat4x4.cpp @@ -16,7 +16,9 @@ *_________________________________________________________________________*/ #include "mat4x4.h" + #include +#include using namespace std; diff --git a/lib/poems/mat4x4.h b/lib/poems/mat4x4.h index d7942b248e..c847f6e0d2 100644 --- a/lib/poems/mat4x4.h +++ b/lib/poems/mat4x4.h @@ -18,11 +18,13 @@ #ifndef MAT4X4_H #define MAT4X4_H +#include + #include "virtualmatrix.h" #include "matrix.h" - class Vect4; +class Matrix; class Mat4x4 : public VirtualMatrix { double elements[4][4]; diff --git a/lib/poems/mat6x6.cpp b/lib/poems/mat6x6.cpp index 16bffc5026..fdc917e03d 100644 --- a/lib/poems/mat6x6.cpp +++ b/lib/poems/mat6x6.cpp @@ -16,7 +16,9 @@ *_________________________________________________________________________*/ #include "mat6x6.h" + #include +#include using namespace std; diff --git a/lib/poems/mat6x6.h b/lib/poems/mat6x6.h index 11951b0442..5eaa4f803b 100644 --- a/lib/poems/mat6x6.h +++ b/lib/poems/mat6x6.h @@ -17,8 +17,9 @@ #ifndef MAT6X6_H #define MAT6X6_H -#include "virtualmatrix.h" +#include +#include "virtualmatrix.h" class Matrix; class Mat3x3; diff --git a/lib/poems/matrix.h b/lib/poems/matrix.h index 63699b9835..8bd8110760 100644 --- a/lib/poems/matrix.h +++ b/lib/poems/matrix.h @@ -18,6 +18,8 @@ #ifndef MATRIX_H #define MATRIX_H +#include + #include "virtualmatrix.h" class Mat3x3; diff --git a/lib/poems/matrixfun.cpp b/lib/poems/matrixfun.cpp index d193114679..99fbae4ca1 100644 --- a/lib/poems/matrixfun.cpp +++ b/lib/poems/matrixfun.cpp @@ -16,9 +16,15 @@ *_________________________________________________________________________*/ #include "matrixfun.h" -#include -#include "fastmatrixops.h" + #include +#include + +#include "fastmatrixops.h" +#include "vect4.h" +#include "virtualcolmatrix.h" +#include "virtualmatrix.h" +#include "virtualrowmatrix.h" using namespace std; diff --git a/lib/poems/matrixfun.h b/lib/poems/matrixfun.h index 600b608ad3..e9721eca7b 100644 --- a/lib/poems/matrixfun.h +++ b/lib/poems/matrixfun.h @@ -14,11 +14,22 @@ * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #ifndef MATRIXFUN_H #define MATRIXFUN_H -#include "matrices.h" +#include "colmatrix.h" +#include "mat3x3.h" +#include "mat4x4.h" +#include "mat6x6.h" +#include "matrix.h" +#include "rowmatrix.h" +#include "vect3.h" +#include "vect6.h" + +class VirtualColMatrix; +class VirtualMatrix; +class VirtualRowMatrix; // Create a Matrix VirtualMatrix* NewMatrix(int type); @@ -70,7 +81,4 @@ Matrix HStack(VirtualMatrix& A, VirtualMatrix& B); void Set6DAngularVector(Vect6& v6, Vect3& v3); void Set6DLinearVector(Vect6& v6, Vect3& v3); - - - #endif diff --git a/lib/poems/mixedjoint.cpp b/lib/poems/mixedjoint.cpp index c834ef621e..ef4ccd25df 100644 --- a/lib/poems/mixedjoint.cpp +++ b/lib/poems/mixedjoint.cpp @@ -16,13 +16,18 @@ *_________________________________________________________________________*/ #include "mixedjoint.h" -#include "point.h" + +#include + #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" -#include "norm.h" #include "eulerparameters.h" -#include "matrices.h" +#include "colmatrix.h" +#include "mat3x3.h" +#include "mat6x6.h" +#include "vect3.h" +#include "virtualmatrix.h" diff --git a/lib/poems/mixedjoint.h b/lib/poems/mixedjoint.h index 5f59b95f09..417f689523 100644 --- a/lib/poems/mixedjoint.h +++ b/lib/poems/mixedjoint.h @@ -18,7 +18,11 @@ #ifndef MIXEDJOINT_H #define MIXEDJOINT_H +#include + #include "joint.h" +#include "matrix.h" +#include "vect6.h" class MixedJoint : public Joint{ diff --git a/lib/poems/norm.cpp b/lib/poems/norm.cpp index 0f918cf968..6b8a56fa29 100644 --- a/lib/poems/norm.cpp +++ b/lib/poems/norm.cpp @@ -16,7 +16,13 @@ *_________________________________________________________________________*/ #include + #include "norm.h" +#include "colmatrix.h" +#include "rowmatrix.h" +#include "vect3.h" +#include "vect4.h" +#include "vect6.h" double Magnitude(ColMatrix& A){ double G; diff --git a/lib/poems/norm.h b/lib/poems/norm.h index 963a2ec5b2..b3ff285dea 100644 --- a/lib/poems/norm.h +++ b/lib/poems/norm.h @@ -18,8 +18,11 @@ #ifndef NORM_H #define NORM_H -#include "matrices.h" - +class ColMatrix; +class RowMatrix; +class Vect3; +class Vect4; +class Vect6; double Magnitude(ColMatrix& A); double Magnitude(RowMatrix& A); diff --git a/lib/poems/onbody.cpp b/lib/poems/onbody.cpp index 102900df8d..bf843be161 100644 --- a/lib/poems/onbody.cpp +++ b/lib/poems/onbody.cpp @@ -16,15 +16,18 @@ *_________________________________________________________________________*/ #include "onbody.h" + +#include +#include + #include "body.h" #include "inertialframe.h" #include "joint.h" #include "onfunctions.h" #include "virtualmatrix.h" #include "matrixfun.h" -#include -#include "norm.h" #include "eulerparameters.h" +#include "colmatrix.h" using namespace std; diff --git a/lib/poems/onbody.h b/lib/poems/onbody.h index d9923773c7..20190dfee8 100644 --- a/lib/poems/onbody.h +++ b/lib/poems/onbody.h @@ -22,6 +22,13 @@ #include "matrix.h" #include "vect6.h" #include "mat6x6.h" +#include "joint.h" +#include "mat3x3.h" +#include "vect3.h" + +class Body; +class ColMatrix; +class InertialFrame; // emumerated type enum Direction { @@ -29,11 +36,6 @@ enum Direction { FORWARD= 1 }; -class Body; -class InertialFrame; -class Joint; -class OnSolver; - class OnBody { Body* system_body; Joint* system_joint; diff --git a/lib/poems/onfunctions.cpp b/lib/poems/onfunctions.cpp index 582ab8cf8b..1d91dbf378 100644 --- a/lib/poems/onfunctions.cpp +++ b/lib/poems/onfunctions.cpp @@ -17,8 +17,13 @@ #include "onfunctions.h" -#include "matrixfun.h" -#include + +#include "mat3x3.h" +#include "mat6x6.h" +#include "vect3.h" +#include "vect6.h" +#include "virtualmatrix.h" + using namespace std; // friend of Vect3 & Vect6 diff --git a/lib/poems/onfunctions.h b/lib/poems/onfunctions.h index 8a69694095..42d0f4ac1c 100644 --- a/lib/poems/onfunctions.h +++ b/lib/poems/onfunctions.h @@ -18,7 +18,10 @@ #ifndef ONFUNCTIONS_H #define ONFUNCTIONS_H -#include "matrices.h" +class Mat3x3; +class Mat6x6; +class Vect3; +class Vect6; void OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV); void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC); diff --git a/lib/poems/onsolver.cpp b/lib/poems/onsolver.cpp index ad04d7e9e3..dd94c9c7ad 100644 --- a/lib/poems/onsolver.cpp +++ b/lib/poems/onsolver.cpp @@ -16,13 +16,21 @@ *_________________________________________________________________________*/ +#include +#include + #include "onsolver.h" #include "system.h" #include "onbody.h" #include "body.h" -#include "matrixfun.h" -#include - +#include "colmatmap.h" +#include "colmatrix.h" +#include "defines.h" +#include "inertialframe.h" +#include "matrix.h" +#include "poemslist.h" +#include "vect3.h" +#include "virtualmatrix.h" using namespace std; diff --git a/lib/poems/onsolver.h b/lib/poems/onsolver.h index f32b5880a9..b4bbd5e25d 100644 --- a/lib/poems/onsolver.h +++ b/lib/poems/onsolver.h @@ -21,7 +21,9 @@ #include "solver.h" #include "onbody.h" -#include + +class ColMatrix; +class Matrix; diff --git a/lib/poems/particle.cpp b/lib/poems/particle.cpp index 3496bc1906..0d953e00f6 100644 --- a/lib/poems/particle.cpp +++ b/lib/poems/particle.cpp @@ -17,7 +17,6 @@ #include "particle.h" -#include "fixedpoint.h" Particle::Particle(){ } diff --git a/lib/poems/particle.h b/lib/poems/particle.h index 20aa4831ea..0f13252f99 100644 --- a/lib/poems/particle.h +++ b/lib/poems/particle.h @@ -19,6 +19,8 @@ #ifndef PARTICLE_H #define PARTICLE_H +#include + #include "body.h" diff --git a/lib/poems/poemstreenode.h b/lib/poems/poemstreenode.h index b8f46031a5..e22bd9b97d 100644 --- a/lib/poems/poemstreenode.h +++ b/lib/poems/poemstreenode.h @@ -18,12 +18,6 @@ #ifndef TREENODE_H #define TREENODE_H -//#define NULL 0 - - -//Tree depends on TreeNode -class Tree; - // declares a tree node object for a binary tree class TreeNode{ diff --git a/lib/poems/point.cpp b/lib/poems/point.cpp index 4383844736..d7eed94efd 100644 --- a/lib/poems/point.cpp +++ b/lib/poems/point.cpp @@ -16,7 +16,9 @@ *_________________________________________________________________________*/ -#include "points.h" +#include "fixedpoint.h" +#include "point.h" +#include "vect3.h" Point::Point(){ position.Zeros(); diff --git a/lib/poems/prismaticjoint.cpp b/lib/poems/prismaticjoint.cpp index 7c01667a86..c7d4bed568 100644 --- a/lib/poems/prismaticjoint.cpp +++ b/lib/poems/prismaticjoint.cpp @@ -16,10 +16,14 @@ *_________________________________________________________________________*/ #include "prismaticjoint.h" + #include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" +#include "colmatrix.h" +#include "mat3x3.h" +#include "virtualmatrix.h" PrismaticJoint::PrismaticJoint(){ q.Dim(1); diff --git a/lib/poems/prismaticjoint.h b/lib/poems/prismaticjoint.h index 17cf050a78..c17be350cb 100644 --- a/lib/poems/prismaticjoint.h +++ b/lib/poems/prismaticjoint.h @@ -18,9 +18,11 @@ #ifndef PRISMATICJOINT_H #define PRISMATICJOINT_H +#include + #include "joint.h" #include "vect3.h" -#include "mat3x3.h" +#include "matrix.h" diff --git a/lib/poems/revolutejoint.cpp b/lib/poems/revolutejoint.cpp index ec5b1bec02..955a2f0dea 100644 --- a/lib/poems/revolutejoint.cpp +++ b/lib/poems/revolutejoint.cpp @@ -16,10 +16,14 @@ *_________________________________________________________________________*/ #include "revolutejoint.h" + #include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" +#include "colmatrix.h" +#include "mat3x3.h" +#include "virtualmatrix.h" RevoluteJoint::RevoluteJoint(){ DimQandU(1); diff --git a/lib/poems/revolutejoint.h b/lib/poems/revolutejoint.h index 478d48dbb9..ac1c06d5c5 100644 --- a/lib/poems/revolutejoint.h +++ b/lib/poems/revolutejoint.h @@ -18,11 +18,12 @@ #ifndef REVOLUTEJOINT_H #define REVOLUTEJOINT_H +#include #include "joint.h" #include "vect3.h" -#include "mat3x3.h" - +#include "matrix.h" +class VirtualMatrix; class RevoluteJoint : public Joint { Vect3 axis_pk; // unit vector in body1 basis diff --git a/lib/poems/rigidbody.cpp b/lib/poems/rigidbody.cpp index 3ac424f9e9..53acfa8bd4 100644 --- a/lib/poems/rigidbody.cpp +++ b/lib/poems/rigidbody.cpp @@ -16,7 +16,8 @@ *_________________________________________________________________________*/ #include "rigidbody.h" -#include "fixedpoint.h" +#include "mat3x3.h" +#include "virtualmatrix.h" using namespace std; diff --git a/lib/poems/rigidbody.h b/lib/poems/rigidbody.h index 0bb2a3ece2..2f4430e264 100644 --- a/lib/poems/rigidbody.h +++ b/lib/poems/rigidbody.h @@ -18,6 +18,8 @@ #ifndef RIGIDBODY_H #define RIGIDBODY_H +#include + #include "body.h" class RigidBody : public Body { diff --git a/lib/poems/rowmatrix.cpp b/lib/poems/rowmatrix.cpp index feb185070e..9fa57e773f 100644 --- a/lib/poems/rowmatrix.cpp +++ b/lib/poems/rowmatrix.cpp @@ -16,7 +16,7 @@ *_________________________________________________________________________*/ #include "rowmatrix.h" -#include "colmatrix.h" + #include #include diff --git a/lib/poems/rowmatrix.h b/lib/poems/rowmatrix.h index b04113e8ed..1dbb3d11e0 100644 --- a/lib/poems/rowmatrix.h +++ b/lib/poems/rowmatrix.h @@ -19,7 +19,10 @@ #ifndef ROWMATRIX_H #define ROWMATRIX_H +#include + #include "virtualrowmatrix.h" +#include "virtualmatrix.h" class RowMatrix : public VirtualRowMatrix { double* elements; diff --git a/lib/poems/solver.cpp b/lib/poems/solver.cpp index 67f5b607e3..9d2245149f 100644 --- a/lib/poems/solver.cpp +++ b/lib/poems/solver.cpp @@ -15,9 +15,10 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ +#include #include "solver.h" #include "system.h" -#include "matrices.h" +#include "onsolver.h" Solver::Solver(){ diff --git a/lib/poems/solver.h b/lib/poems/solver.h index 45564dd1ef..6a2debf497 100644 --- a/lib/poems/solver.h +++ b/lib/poems/solver.h @@ -17,12 +17,12 @@ #ifndef SOLVER_H #define SOLVER_H -#include + #include "colmatmap.h" -#include "matrices.h" #include "defines.h" class System; +class Matrix; class Solver{ protected: diff --git a/lib/poems/sphericaljoint.cpp b/lib/poems/sphericaljoint.cpp index fb5330db17..cba6d00a6e 100644 --- a/lib/poems/sphericaljoint.cpp +++ b/lib/poems/sphericaljoint.cpp @@ -17,14 +17,18 @@ #include "sphericaljoint.h" + +#include + #include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" -#include "norm.h" #include "eulerparameters.h" -#include "matrices.h" -#include +#include "colmatrix.h" +#include "mat3x3.h" +#include "vect3.h" +#include "virtualmatrix.h" SphericalJoint::SphericalJoint(){ diff --git a/lib/poems/sphericaljoint.h b/lib/poems/sphericaljoint.h index ef29f8e38e..90f1547873 100644 --- a/lib/poems/sphericaljoint.h +++ b/lib/poems/sphericaljoint.h @@ -18,11 +18,9 @@ #ifndef SPHERICALJOINT_H #define SPHERICALJOINT_H +#include #include "joint.h" -#include "vect3.h" -#include "mat3x3.h" - - +#include "matrix.h" class SphericalJoint : public Joint { Matrix const_sP; diff --git a/lib/poems/system.cpp b/lib/poems/system.cpp index 369213f7d0..1ac9ce1236 100644 --- a/lib/poems/system.cpp +++ b/lib/poems/system.cpp @@ -17,9 +17,26 @@ #include "system.h" + +#include +#include + #include "body.h" #include "joint.h" -#include +#include "colmatrix.h" +#include "eulerparameters.h" +#include "fixedpoint.h" +#include "freebodyjoint.h" +#include "inertialframe.h" +#include "mat3x3.h" +#include "matrix.h" +#include "matrixfun.h" +#include "rigidbody.h" +#include "sphericaljoint.h" +#include "vect3.h" +#include "virtualmatrix.h" + +class Point; System::System(){ diff --git a/lib/poems/system.h b/lib/poems/system.h index 1b59395de7..e5ce27194b 100644 --- a/lib/poems/system.h +++ b/lib/poems/system.h @@ -15,35 +15,12 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #ifndef SYSTEM_H #define SYSTEM_H - #include -#include -#include -#include -#include - #include "poemslist.h" -#include "matrices.h" -#include "workspace.h" -#include "matrixfun.h" -#include "onsolver.h" -#include "system.h" -#include "inertialframe.h" -#include "rigidbody.h" -#include "revolutejoint.h" -#include "fixedpoint.h" -#include "freebodyjoint.h" -#include "sphericaljoint.h" -#include "body23joint.h" -#include "mixedjoint.h" -#include "eulerparameters.h" -#include "matrices.h" -#include "norm.h" - class Body; class Joint; diff --git a/lib/poems/vect3.cpp b/lib/poems/vect3.cpp index 03c5d7bc00..7ce3230238 100644 --- a/lib/poems/vect3.cpp +++ b/lib/poems/vect3.cpp @@ -16,7 +16,9 @@ *_________________________________________________________________________*/ #include "vect3.h" + #include +#include using namespace std; @@ -141,6 +143,13 @@ Vect3& Vect3::operator+=(const Vect3& A){ return *this; } +Vect3& Vect3::operator-(){ + elements[0] = -elements[0]; + elements[1] = -elements[1]; + elements[2] = -elements[2]; + return *this; +} + Vect3& Vect3::operator-=(const Vect3& A){ elements[0] -= A.elements[0]; elements[1] -= A.elements[1]; diff --git a/lib/poems/vect3.h b/lib/poems/vect3.h index ababe18e51..a28832db6c 100644 --- a/lib/poems/vect3.h +++ b/lib/poems/vect3.h @@ -18,7 +18,10 @@ #ifndef VECT3_H #define VECT3_H +#include + #include "virtualcolmatrix.h" +#include "virtualmatrix.h" class Matrix; class Mat3x3; @@ -52,6 +55,7 @@ public: Vect3& operator*=(double b); Vect3& operator+=(const Vect3& A); Vect3& operator-=(const Vect3& A); + Vect3& operator-(); friend Matrix T(const Vect3& A); // a wasteful transpose friend Mat3x3 CrossMat(Vect3& a); // a wasteful cross matrix implementation diff --git a/lib/poems/vect4.cpp b/lib/poems/vect4.cpp index 3b5afddc50..b045998017 100644 --- a/lib/poems/vect4.cpp +++ b/lib/poems/vect4.cpp @@ -16,7 +16,9 @@ *_________________________________________________________________________*/ #include "vect4.h" + #include +#include using namespace std; diff --git a/lib/poems/vect4.h b/lib/poems/vect4.h index 695f5e158a..0b28994043 100644 --- a/lib/poems/vect4.h +++ b/lib/poems/vect4.h @@ -18,8 +18,10 @@ #ifndef VECT4_H #define VECT4_H -#include "virtualcolmatrix.h" +#include +#include "virtualcolmatrix.h" +#include "virtualmatrix.h" class Matrix; class Mat4x4; diff --git a/lib/poems/vect6.cpp b/lib/poems/vect6.cpp index eb65d24f16..5baadafc34 100644 --- a/lib/poems/vect6.cpp +++ b/lib/poems/vect6.cpp @@ -16,7 +16,9 @@ *_________________________________________________________________________*/ #include "vect6.h" + #include +#include using namespace std; diff --git a/lib/poems/vect6.h b/lib/poems/vect6.h index c346c852ef..8047c1bbf8 100644 --- a/lib/poems/vect6.h +++ b/lib/poems/vect6.h @@ -18,7 +18,10 @@ #ifndef VECT6_H #define VECT6_H +#include + #include "virtualcolmatrix.h" +#include "virtualmatrix.h" class Matrix; class Mat6x6; diff --git a/lib/poems/workspace.cpp b/lib/poems/workspace.cpp index 2b3257b0dd..29a1c95832 100644 --- a/lib/poems/workspace.cpp +++ b/lib/poems/workspace.cpp @@ -15,15 +15,26 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ +#include +#include // IWYU pragma: keep +#include #include "workspace.h" #include "system.h" #include "solver.h" #include "SystemProcessor.h" -#include -#include -#include -#include +#include "POEMSChain.h" +#include "body.h" +#include "colmatmap.h" +#include "colmatrix.h" +#include "defines.h" +#include "joint.h" +#include "mat3x3.h" +#include "matrix.h" +#include "matrixfun.h" +#include "poemslist.h" +#include "vect3.h" +#include "virtualmatrix.h" using namespace std; diff --git a/lib/poems/workspace.h b/lib/poems/workspace.h index 5faaf904dc..6213815d81 100644 --- a/lib/poems/workspace.h +++ b/lib/poems/workspace.h @@ -19,15 +19,6 @@ #ifndef WORKSPACE_H #define WORKSPACE_H -#include "matrices.h" -#include -#include -#include -#include -#include -#include - - class System; class Solver; From 2443c8ad13ac452bcea30a3895f55394d89186ca Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 1 Jul 2019 09:14:22 -0400 Subject: [PATCH 27/79] reduce IWYU warnings for lammps.cpp --- src/lammps.cpp | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/lammps.cpp b/src/lammps.cpp index 052d14dfed..f8e7dceb89 100644 --- a/src/lammps.cpp +++ b/src/lammps.cpp @@ -19,20 +19,20 @@ #include #include #include "lammps.h" -#include "style_angle.h" -#include "style_atom.h" -#include "style_bond.h" -#include "style_command.h" -#include "style_compute.h" -#include "style_dihedral.h" -#include "style_dump.h" -#include "style_fix.h" -#include "style_improper.h" -#include "style_integrate.h" -#include "style_kspace.h" -#include "style_minimize.h" -#include "style_pair.h" -#include "style_region.h" +#include "style_angle.h" // IWYU pragma: keep +#include "style_atom.h" // IWYU pragma: keep +#include "style_bond.h" // IWYU pragma: keep +#include "style_command.h" // IWYU pragma: keep +#include "style_compute.h" // IWYU pragma: keep +#include "style_dihedral.h" // IWYU pragma: keep +#include "style_dump.h" // IWYU pragma: keep +#include "style_fix.h" // IWYU pragma: keep +#include "style_improper.h" // IWYU pragma: keep +#include "style_integrate.h" // IWYU pragma: keep +#include "style_kspace.h" // IWYU pragma: keep +#include "style_minimize.h" // IWYU pragma: keep +#include "style_pair.h" // IWYU pragma: keep +#include "style_region.h" // IWYU pragma: keep #include "universe.h" #include "input.h" #include "info.h" From 42c31227d9635de1da42550c8458aca622195a7a Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 1 Jul 2019 14:31:41 -0400 Subject: [PATCH 28/79] continuing to clean up include file lists --- lib/poems/mat4x4.h | 2 -- src/KSPACE/pair_buck_coul_long.cpp | 3 +-- src/KSPACE/pair_buck_long_coul_long.cpp | 4 +--- src/MC/fix_bond_swap.cpp | 3 +-- src/MC/fix_bond_swap.h | 1 - src/MC/fix_gcmc.cpp | 7 ++----- src/PYTHON/fix_python_invoke.cpp | 3 --- src/PYTHON/fix_python_move.cpp | 7 ------- src/PYTHON/pair_python.cpp | 2 -- src/PYTHON/python_impl.cpp | 3 ++- src/PYTHON/python_impl.h | 1 + src/RIGID/fix_rigid_nh.cpp | 3 +-- src/RIGID/fix_rigid_nph_small.cpp | 1 - src/RIGID/fix_rigid_npt.cpp | 1 - src/RIGID/fix_rigid_npt_small.cpp | 1 - src/RIGID/fix_rigid_small.cpp | 4 ++-- src/imbalance_store.cpp | 1 - src/imbalance_time.cpp | 1 - src/lmppython.cpp | 4 ++++ src/lmppython.h | 5 ----- src/math_special.cpp | 2 +- src/min_linesearch.cpp | 1 - src/neigh_list.cpp | 2 +- src/npair_full_bin_ghost.cpp | 1 - src/npair_full_multi.cpp | 1 - src/npair_full_nsq.cpp | 1 - src/npair_full_nsq_ghost.cpp | 1 - src/npair_half_bin_atomonly_newton.cpp | 3 --- src/npair_half_bin_newtoff.cpp | 1 - src/npair_half_bin_newtoff_ghost.cpp | 1 - src/npair_half_bin_newton.cpp | 1 - src/npair_half_bin_newton_tri.cpp | 1 - src/npair_half_multi_newtoff.cpp | 1 - src/npair_half_multi_newton.cpp | 1 - src/npair_half_multi_newton_tri.cpp | 1 - src/npair_half_nsq_newtoff.cpp | 1 - src/npair_half_nsq_newtoff_ghost.cpp | 1 - src/npair_half_nsq_newton.cpp | 1 - src/npair_half_respa_bin_newtoff.cpp | 1 - src/npair_half_respa_bin_newton.cpp | 1 - src/npair_half_respa_bin_newton_tri.cpp | 1 - src/npair_half_respa_nsq_newtoff.cpp | 1 - src/npair_half_respa_nsq_newton.cpp | 1 - src/npair_half_size_bin_newtoff.cpp | 2 -- src/npair_half_size_bin_newton.cpp | 2 -- src/npair_half_size_bin_newton_tri.cpp | 2 -- src/npair_half_size_nsq_newtoff.cpp | 2 -- src/npair_half_size_nsq_newton.cpp | 2 -- src/npair_halffull_newtoff.cpp | 4 ---- src/npair_halffull_newton.cpp | 3 --- src/npair_skip.cpp | 3 --- src/pair_buck_coul_cut.cpp | 3 +-- src/pair_coul_cut.cpp | 3 +-- src/pointers.h | 1 + src/variable.cpp | 2 +- 55 files changed, 21 insertions(+), 92 deletions(-) diff --git a/lib/poems/mat4x4.h b/lib/poems/mat4x4.h index c847f6e0d2..a6ae232473 100644 --- a/lib/poems/mat4x4.h +++ b/lib/poems/mat4x4.h @@ -19,9 +19,7 @@ #define MAT4X4_H #include - #include "virtualmatrix.h" -#include "matrix.h" class Vect4; class Matrix; diff --git a/src/KSPACE/pair_buck_coul_long.cpp b/src/KSPACE/pair_buck_coul_long.cpp index 0a1ec88da5..a5427965dc 100644 --- a/src/KSPACE/pair_buck_coul_long.cpp +++ b/src/KSPACE/pair_buck_coul_long.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_buck_coul_long.h" #include "atom.h" diff --git a/src/KSPACE/pair_buck_long_coul_long.cpp b/src/KSPACE/pair_buck_long_coul_long.cpp index c7a4a4b2f6..bcd290891e 100644 --- a/src/KSPACE/pair_buck_long_coul_long.cpp +++ b/src/KSPACE/pair_buck_long_coul_long.cpp @@ -15,9 +15,8 @@ Contributing author: Pieter J. in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "math_vector.h" #include "pair_buck_long_coul_long.h" @@ -29,7 +28,6 @@ #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "memory.h" #include "error.h" diff --git a/src/MC/fix_bond_swap.cpp b/src/MC/fix_bond_swap.cpp index 9a72667907..5da2b845d6 100644 --- a/src/MC/fix_bond_swap.cpp +++ b/src/MC/fix_bond_swap.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_bond_swap.h" #include "atom.h" @@ -23,7 +23,6 @@ #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "group.h" #include "comm.h" #include "domain.h" #include "modify.h" diff --git a/src/MC/fix_bond_swap.h b/src/MC/fix_bond_swap.h index 0443144c23..d24159d807 100644 --- a/src/MC/fix_bond_swap.h +++ b/src/MC/fix_bond_swap.h @@ -21,7 +21,6 @@ FixStyle(bond/swap,FixBondSwap) #define LMP_FIX_BONDSWAP_H #include "fix.h" -#include "pair.h" namespace LAMMPS_NS { diff --git a/src/MC/fix_gcmc.cpp b/src/MC/fix_gcmc.cpp index 7ab0879335..4e48b71611 100644 --- a/src/MC/fix_gcmc.cpp +++ b/src/MC/fix_gcmc.cpp @@ -15,8 +15,8 @@ Contributing author: Paul Crozier, Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_gcmc.h" #include "atom.h" @@ -43,10 +43,7 @@ #include "math_const.h" #include "memory.h" #include "error.h" -#include "thermo.h" -#include "output.h" #include "neighbor.h" -#include "utils.h" using namespace LAMMPS_NS; using namespace FixConst; @@ -371,7 +368,7 @@ void FixGCMC::options(int narg, char **arg) ngrouptypesmax*sizeof(char *), "fix_gcmc:grouptypestrings"); } - grouptypes[ngrouptypes] = atoi(arg[iarg+1]); + grouptypes[ngrouptypes] = force->inumeric(FLERR,arg[iarg+1]); int n = strlen(arg[iarg+2]) + 1; grouptypestrings[ngrouptypes] = new char[n]; strcpy(grouptypestrings[ngrouptypes],arg[iarg+2]); diff --git a/src/PYTHON/fix_python_invoke.cpp b/src/PYTHON/fix_python_invoke.cpp index 280c2d91e2..f704bd9741 100644 --- a/src/PYTHON/fix_python_invoke.cpp +++ b/src/PYTHON/fix_python_invoke.cpp @@ -16,13 +16,10 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_python_invoke.h" -#include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" #include "lmppython.h" #include "python_compat.h" diff --git a/src/PYTHON/fix_python_move.cpp b/src/PYTHON/fix_python_move.cpp index ec21dbeadd..56b7768669 100644 --- a/src/PYTHON/fix_python_move.cpp +++ b/src/PYTHON/fix_python_move.cpp @@ -16,15 +16,8 @@ ------------------------------------------------------------------------- */ #include -#include -#include #include #include "fix_python_move.h" -#include "atom.h" -#include "comm.h" -#include "force.h" -#include "memory.h" -#include "neigh_list.h" #include "lmppython.h" #include "error.h" #include "python_compat.h" diff --git a/src/PYTHON/pair_python.cpp b/src/PYTHON/pair_python.cpp index 2148fc67b8..638077da48 100644 --- a/src/PYTHON/pair_python.cpp +++ b/src/PYTHON/pair_python.cpp @@ -16,12 +16,10 @@ ------------------------------------------------------------------------- */ #include -#include #include #include #include "pair_python.h" #include "atom.h" -#include "comm.h" #include "force.h" #include "memory.h" #include "update.h" diff --git a/src/PYTHON/python_impl.cpp b/src/PYTHON/python_impl.cpp index 9c650330af..249d4f7bb1 100644 --- a/src/PYTHON/python_impl.cpp +++ b/src/PYTHON/python_impl.cpp @@ -16,8 +16,9 @@ ------------------------------------------------------------------------- */ #include +#include #include -#include "lmppython.h" +#include "python_impl.h" #include "force.h" #include "input.h" #include "variable.h" diff --git a/src/PYTHON/python_impl.h b/src/PYTHON/python_impl.h index 2ccdda95c9..f890f54f3b 100644 --- a/src/PYTHON/python_impl.h +++ b/src/PYTHON/python_impl.h @@ -15,6 +15,7 @@ #define LMP_PYTHON_IMPL_H #include "pointers.h" +#include "lmppython.h" namespace LAMMPS_NS { diff --git a/src/RIGID/fix_rigid_nh.cpp b/src/RIGID/fix_rigid_nh.cpp index 4dceb1b8b4..4acc8d3411 100644 --- a/src/RIGID/fix_rigid_nh.cpp +++ b/src/RIGID/fix_rigid_nh.cpp @@ -17,8 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_rigid_nh.h" #include "math_extra.h" @@ -32,7 +32,6 @@ #include "comm.h" #include "force.h" #include "kspace.h" -#include "output.h" #include "memory.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_nph_small.cpp b/src/RIGID/fix_rigid_nph_small.cpp index d32e3043f4..9b045eaf13 100644 --- a/src/RIGID/fix_rigid_nph_small.cpp +++ b/src/RIGID/fix_rigid_nph_small.cpp @@ -19,7 +19,6 @@ #include #include "fix_rigid_nph_small.h" -#include "domain.h" #include "modify.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_npt.cpp b/src/RIGID/fix_rigid_npt.cpp index da5d5ffaa5..526fc8f614 100644 --- a/src/RIGID/fix_rigid_npt.cpp +++ b/src/RIGID/fix_rigid_npt.cpp @@ -19,7 +19,6 @@ #include #include "fix_rigid_npt.h" -#include "domain.h" #include "modify.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_npt_small.cpp b/src/RIGID/fix_rigid_npt_small.cpp index f1fd5470da..fff338d687 100644 --- a/src/RIGID/fix_rigid_npt_small.cpp +++ b/src/RIGID/fix_rigid_npt_small.cpp @@ -19,7 +19,6 @@ #include #include "fix_rigid_npt_small.h" -#include "domain.h" #include "modify.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_small.cpp b/src/RIGID/fix_rigid_small.cpp index dedd71c98d..8c2feb6436 100644 --- a/src/RIGID/fix_rigid_small.cpp +++ b/src/RIGID/fix_rigid_small.cpp @@ -11,10 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include #include +#include #include "fix_rigid_small.h" #include "math_extra.h" #include "atom.h" @@ -31,7 +32,6 @@ #include "neighbor.h" #include "force.h" #include "input.h" -#include "output.h" #include "variable.h" #include "random_mars.h" #include "math_const.h" diff --git a/src/imbalance_store.cpp b/src/imbalance_store.cpp index 6b69caf785..c117b60860 100644 --- a/src/imbalance_store.cpp +++ b/src/imbalance_store.cpp @@ -14,7 +14,6 @@ #include #include "imbalance_store.h" #include "atom.h" -#include "input.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/imbalance_time.cpp b/src/imbalance_time.cpp index a5fe538b8f..ceb3c08220 100644 --- a/src/imbalance_time.cpp +++ b/src/imbalance_time.cpp @@ -14,7 +14,6 @@ #include #include "imbalance_time.h" #include "atom.h" -#include "comm.h" #include "force.h" #include "timer.h" #include "error.h" diff --git a/src/lmppython.cpp b/src/lmppython.cpp index 7c6a490c24..52abd93f10 100644 --- a/src/lmppython.cpp +++ b/src/lmppython.cpp @@ -12,7 +12,11 @@ ------------------------------------------------------------------------- */ #include "lmppython.h" +#if LMP_PYTHON +#include "python_impl.h" +#else #include "error.h" +#endif using namespace LAMMPS_NS; diff --git a/src/lmppython.h b/src/lmppython.h index afc21037fb..3d55c4827b 100644 --- a/src/lmppython.h +++ b/src/lmppython.h @@ -51,11 +51,6 @@ private: }; } - -#endif - -#if LMP_PYTHON -#include "python_impl.h" #endif /* ERROR/WARNING messages: diff --git a/src/math_special.cpp b/src/math_special.cpp index 31567bdc77..b2f545ddc6 100644 --- a/src/math_special.cpp +++ b/src/math_special.cpp @@ -1,5 +1,5 @@ #include -#include // requires C++-11 +#include // IWYU pragma: keep #include "math_special.h" using namespace LAMMPS_NS; diff --git a/src/min_linesearch.cpp b/src/min_linesearch.cpp index 33a781ecfe..3c0621c602 100644 --- a/src/min_linesearch.cpp +++ b/src/min_linesearch.cpp @@ -26,7 +26,6 @@ #include "min_linesearch.h" #include "atom.h" #include "modify.h" -#include "neighbor.h" #include "fix_minimize.h" #include "pair.h" #include "output.h" diff --git a/src/neigh_list.cpp b/src/neigh_list.cpp index 651b2ed70a..31720cc78c 100644 --- a/src/neigh_list.cpp +++ b/src/neigh_list.cpp @@ -12,7 +12,7 @@ ------------------------------------------------------------------------- */ #include "neigh_list.h" -#include "my_page.h" +#include "my_page.h" // IWYU pragma: keep #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/npair_full_bin_ghost.cpp b/src/npair_full_bin_ghost.cpp index 2edd03cc9e..61b27dd99d 100644 --- a/src/npair_full_bin_ghost.cpp +++ b/src/npair_full_bin_ghost.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_full_bin_ghost.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_full_multi.cpp b/src/npair_full_multi.cpp index 9a2490ac5d..40ed2275be 100644 --- a/src/npair_full_multi.cpp +++ b/src/npair_full_multi.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_full_multi.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_full_nsq.cpp b/src/npair_full_nsq.cpp index 1b404ffc94..76b66fd004 100644 --- a/src/npair_full_nsq.cpp +++ b/src/npair_full_nsq.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_full_nsq.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_full_nsq_ghost.cpp b/src/npair_full_nsq_ghost.cpp index 1727b2905e..b20fa9b8ce 100644 --- a/src/npair_full_nsq_ghost.cpp +++ b/src/npair_full_nsq_ghost.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_full_nsq_ghost.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_bin_atomonly_newton.cpp b/src/npair_half_bin_atomonly_newton.cpp index 6da44b4a5c..a7fa3985ef 100644 --- a/src/npair_half_bin_atomonly_newton.cpp +++ b/src/npair_half_bin_atomonly_newton.cpp @@ -12,12 +12,9 @@ ------------------------------------------------------------------------- */ #include "npair_half_bin_atomonly_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/npair_half_bin_newtoff.cpp b/src/npair_half_bin_newtoff.cpp index 4c44741ffe..65768918c9 100644 --- a/src/npair_half_bin_newtoff.cpp +++ b/src/npair_half_bin_newtoff.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_bin_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_bin_newtoff_ghost.cpp b/src/npair_half_bin_newtoff_ghost.cpp index 72ec15e66a..91fbf049cb 100644 --- a/src/npair_half_bin_newtoff_ghost.cpp +++ b/src/npair_half_bin_newtoff_ghost.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_bin_newtoff_ghost.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_bin_newton.cpp b/src/npair_half_bin_newton.cpp index 3a387870e3..fe388e1144 100644 --- a/src/npair_half_bin_newton.cpp +++ b/src/npair_half_bin_newton.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_bin_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_bin_newton_tri.cpp b/src/npair_half_bin_newton_tri.cpp index 169e710e0e..1f0e3c1187 100644 --- a/src/npair_half_bin_newton_tri.cpp +++ b/src/npair_half_bin_newton_tri.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_bin_newton_tri.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_multi_newtoff.cpp b/src/npair_half_multi_newtoff.cpp index 07b5c87a6c..57dcf29cc7 100644 --- a/src/npair_half_multi_newtoff.cpp +++ b/src/npair_half_multi_newtoff.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_multi_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_multi_newton.cpp b/src/npair_half_multi_newton.cpp index 3d90979329..a9293d3d64 100644 --- a/src/npair_half_multi_newton.cpp +++ b/src/npair_half_multi_newton.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_multi_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_multi_newton_tri.cpp b/src/npair_half_multi_newton_tri.cpp index 909c69246b..c1d845cb38 100644 --- a/src/npair_half_multi_newton_tri.cpp +++ b/src/npair_half_multi_newton_tri.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_multi_newton_tri.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_nsq_newtoff.cpp b/src/npair_half_nsq_newtoff.cpp index 06e8344332..db369687d0 100644 --- a/src/npair_half_nsq_newtoff.cpp +++ b/src/npair_half_nsq_newtoff.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_nsq_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_nsq_newtoff_ghost.cpp b/src/npair_half_nsq_newtoff_ghost.cpp index 1865061a8b..0a9b6d0f45 100644 --- a/src/npair_half_nsq_newtoff_ghost.cpp +++ b/src/npair_half_nsq_newtoff_ghost.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_nsq_newtoff_ghost.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_nsq_newton.cpp b/src/npair_half_nsq_newton.cpp index 11c71d5609..69489915b2 100644 --- a/src/npair_half_nsq_newton.cpp +++ b/src/npair_half_nsq_newton.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_nsq_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_respa_bin_newtoff.cpp b/src/npair_half_respa_bin_newtoff.cpp index 0145771f4a..8c1d8d684f 100644 --- a/src/npair_half_respa_bin_newtoff.cpp +++ b/src/npair_half_respa_bin_newtoff.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_respa_bin_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_respa_bin_newton.cpp b/src/npair_half_respa_bin_newton.cpp index 72a613204d..d2598fa1a4 100644 --- a/src/npair_half_respa_bin_newton.cpp +++ b/src/npair_half_respa_bin_newton.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_respa_bin_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_respa_bin_newton_tri.cpp b/src/npair_half_respa_bin_newton_tri.cpp index add1cf6e5c..efe48d48e1 100644 --- a/src/npair_half_respa_bin_newton_tri.cpp +++ b/src/npair_half_respa_bin_newton_tri.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_respa_bin_newton_tri.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_respa_nsq_newtoff.cpp b/src/npair_half_respa_nsq_newtoff.cpp index c0e932f0ae..334ebb5ca8 100644 --- a/src/npair_half_respa_nsq_newtoff.cpp +++ b/src/npair_half_respa_nsq_newtoff.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_respa_nsq_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_respa_nsq_newton.cpp b/src/npair_half_respa_nsq_newton.cpp index f7d161896d..7ecd02b0c5 100644 --- a/src/npair_half_respa_nsq_newton.cpp +++ b/src/npair_half_respa_nsq_newton.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_respa_nsq_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_size_bin_newtoff.cpp b/src/npair_half_size_bin_newtoff.cpp index 021452028b..b9e44675ac 100644 --- a/src/npair_half_size_bin_newtoff.cpp +++ b/src/npair_half_size_bin_newtoff.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_bin_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_size_bin_newton.cpp b/src/npair_half_size_bin_newton.cpp index 760c09570a..93bcc25373 100644 --- a/src/npair_half_size_bin_newton.cpp +++ b/src/npair_half_size_bin_newton.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_bin_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_size_bin_newton_tri.cpp b/src/npair_half_size_bin_newton_tri.cpp index d831982ed6..39068c02bc 100644 --- a/src/npair_half_size_bin_newton_tri.cpp +++ b/src/npair_half_size_bin_newton_tri.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_bin_newton_tri.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_size_nsq_newtoff.cpp b/src/npair_half_size_nsq_newtoff.cpp index 1c2fe5f3d5..6f169d0b6c 100644 --- a/src/npair_half_size_nsq_newtoff.cpp +++ b/src/npair_half_size_nsq_newtoff.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_nsq_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_half_size_nsq_newton.cpp b/src/npair_half_size_nsq_newton.cpp index ce9f8ec186..d427c14809 100644 --- a/src/npair_half_size_nsq_newton.cpp +++ b/src/npair_half_size_nsq_newton.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_nsq_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_halffull_newtoff.cpp b/src/npair_halffull_newtoff.cpp index 84816f07b2..6ff5433e88 100644 --- a/src/npair_halffull_newtoff.cpp +++ b/src/npair_halffull_newtoff.cpp @@ -12,12 +12,8 @@ ------------------------------------------------------------------------- */ #include "npair_halffull_newtoff.h" -#include "neighbor.h" #include "neigh_list.h" -#include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/npair_halffull_newton.cpp b/src/npair_halffull_newton.cpp index 371bbd33a8..0912cfe12f 100644 --- a/src/npair_halffull_newton.cpp +++ b/src/npair_halffull_newton.cpp @@ -12,12 +12,9 @@ ------------------------------------------------------------------------- */ #include "npair_halffull_newton.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/npair_skip.cpp b/src/npair_skip.cpp index 1fe202537a..028041a947 100644 --- a/src/npair_skip.cpp +++ b/src/npair_skip.cpp @@ -12,12 +12,9 @@ ------------------------------------------------------------------------- */ #include "npair_skip.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/pair_buck_coul_cut.cpp b/src/pair_buck_coul_cut.cpp index 094797694c..64475166e3 100644 --- a/src/pair_buck_coul_cut.cpp +++ b/src/pair_buck_coul_cut.cpp @@ -15,9 +15,8 @@ Contributing author: Eduardo Bringa (LLNL) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include "pair_buck_coul_cut.h" #include "atom.h" #include "comm.h" diff --git a/src/pair_coul_cut.cpp b/src/pair_coul_cut.cpp index 196e064219..28973026cd 100644 --- a/src/pair_coul_cut.cpp +++ b/src/pair_coul_cut.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_coul_cut.h" #include "atom.h" diff --git a/src/pointers.h b/src/pointers.h index 5df5b72d47..1af07d5158 100644 --- a/src/pointers.h +++ b/src/pointers.h @@ -23,6 +23,7 @@ #include "lmptype.h" // IWYU pragma: export #include +#include // IWYU pragme: export #include // IWYU pragma: export #include "lammps.h" // IWYU pragma: export diff --git a/src/variable.cpp b/src/variable.cpp index 1416754073..111fc75a9a 100644 --- a/src/variable.cpp +++ b/src/variable.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include #include @@ -34,7 +35,6 @@ #include "thermo.h" #include "random_mars.h" #include "math_const.h" -#include "atom_masks.h" #include "lmppython.h" #include "memory.h" #include "info.h" From fc1d8f2cbf03245a376dcb9fd4b1dcaf95e36fe5 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Tue, 2 Jul 2019 01:12:16 -0400 Subject: [PATCH 29/79] more cleanup of include file handling. starting to work on files in packages --- src/OPT/pair_lj_long_coul_long_opt.cpp | 1 + src/PYTHON/fix_python_invoke.cpp | 2 +- src/PYTHON/fix_python_move.cpp | 2 +- src/PYTHON/pair_python.cpp | 2 +- src/PYTHON/python_impl.cpp | 2 +- src/RIGID/fix_ehex.cpp | 7 +-- src/RIGID/fix_ehex.h | 20 ++++----- src/RIGID/fix_rattle.cpp | 11 ----- src/RIGID/fix_rattle.h | 1 - src/RIGID/fix_rigid.cpp | 3 +- src/RIGID/fix_rigid_nh.cpp | 1 - src/RIGID/fix_rigid_nh_small.cpp | 3 +- src/RIGID/fix_rigid_nph.cpp | 1 - src/SHOCK/fix_append_atoms.cpp | 2 +- src/SHOCK/fix_msst.cpp | 5 +-- src/SHOCK/fix_nphug.cpp | 3 -- src/SHOCK/fix_wall_piston.cpp | 2 - src/SNAP/compute_snav_atom.cpp | 3 +- src/SNAP/pair_snap.cpp | 5 +-- src/SNAP/sna.cpp | 8 +--- src/SPIN/compute_spin.cpp | 8 +--- src/SPIN/fix_langevin_spin.cpp | 24 +++-------- src/SPIN/fix_neb_spin.cpp | 4 -- src/SPIN/fix_nve_spin.cpp | 16 +------ src/SPIN/fix_nve_spin.h | 2 - src/SPIN/fix_precession_spin.cpp | 9 +--- src/SPIN/fix_setforce_spin.cpp | 4 -- src/SPIN/min_spin.cpp | 3 -- src/SPIN/neb_spin.cpp | 8 ---- src/SPIN/pair_spin.cpp | 13 +----- src/SPIN/pair_spin.h | 2 +- src/SPIN/pair_spin_dipole_cut.cpp | 4 +- src/SPIN/pair_spin_dipole_long.cpp | 55 ++++++++++++------------ src/SPIN/pair_spin_dmi.cpp | 8 +--- src/SPIN/pair_spin_exchange.cpp | 8 +--- src/SPIN/pair_spin_magelec.cpp | 8 +--- src/SPIN/pair_spin_neel.cpp | 9 +--- src/SRD/fix_srd.cpp | 3 +- src/SRD/fix_wall_srd.cpp | 4 +- src/USER-EFF/atom_vec_electron.cpp | 2 - src/USER-EFF/compute_ke_atom_eff.cpp | 1 - src/USER-EFF/compute_ke_eff.cpp | 2 - src/USER-EFF/compute_temp_deform_eff.cpp | 1 - src/USER-EFF/compute_temp_eff.cpp | 2 - src/USER-EFF/compute_temp_region_eff.cpp | 2 - src/USER-EFF/fix_langevin_eff.cpp | 6 --- src/USER-EFF/fix_nh_eff.cpp | 2 - src/USER-EFF/fix_nve_eff.cpp | 2 - src/USER-EFF/fix_nvt_eff.cpp | 1 - src/USER-EFF/fix_temp_rescale_eff.cpp | 2 - src/USER-EFF/pair_eff_cut.cpp | 3 +- src/USER-PHONON/fix_phonon.cpp | 5 +-- 52 files changed, 76 insertions(+), 231 deletions(-) diff --git a/src/OPT/pair_lj_long_coul_long_opt.cpp b/src/OPT/pair_lj_long_coul_long_opt.cpp index 243b64391f..03853057f4 100644 --- a/src/OPT/pair_lj_long_coul_long_opt.cpp +++ b/src/OPT/pair_lj_long_coul_long_opt.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include +#include #include "pair_lj_long_coul_long_opt.h" #include "atom.h" #include "force.h" diff --git a/src/PYTHON/fix_python_invoke.cpp b/src/PYTHON/fix_python_invoke.cpp index f704bd9741..7fa9861c3f 100644 --- a/src/PYTHON/fix_python_invoke.cpp +++ b/src/PYTHON/fix_python_invoke.cpp @@ -15,7 +15,7 @@ Contributing author: Richard Berger (Temple U) ------------------------------------------------------------------------- */ -#include +#include // IWYU pragma: keep #include #include "fix_python_invoke.h" #include "force.h" diff --git a/src/PYTHON/fix_python_move.cpp b/src/PYTHON/fix_python_move.cpp index 56b7768669..b253df6828 100644 --- a/src/PYTHON/fix_python_move.cpp +++ b/src/PYTHON/fix_python_move.cpp @@ -15,7 +15,7 @@ Contributing author: Richard Berger (Temple U) ------------------------------------------------------------------------- */ -#include +#include // IWYU pragma: keep #include #include "fix_python_move.h" #include "lmppython.h" diff --git a/src/PYTHON/pair_python.cpp b/src/PYTHON/pair_python.cpp index 638077da48..5b8f23400b 100644 --- a/src/PYTHON/pair_python.cpp +++ b/src/PYTHON/pair_python.cpp @@ -15,7 +15,7 @@ Contributing authors: Axel Kohlmeyer and Richard Berger (Temple U) ------------------------------------------------------------------------- */ -#include +#include // IWYU pragma: keep #include #include #include "pair_python.h" diff --git a/src/PYTHON/python_impl.cpp b/src/PYTHON/python_impl.cpp index 249d4f7bb1..7456021675 100644 --- a/src/PYTHON/python_impl.cpp +++ b/src/PYTHON/python_impl.cpp @@ -17,7 +17,7 @@ #include #include -#include +#include // IWYU pragma: keep #include "python_impl.h" #include "force.h" #include "input.h" diff --git a/src/RIGID/fix_ehex.cpp b/src/RIGID/fix_ehex.cpp index 1476c71d3f..0bbdea51c6 100644 --- a/src/RIGID/fix_ehex.cpp +++ b/src/RIGID/fix_ehex.cpp @@ -22,8 +22,8 @@ which implements the heat exchange (HEX) algorithm. ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_ehex.h" #include "atom.h" @@ -33,14 +33,9 @@ #include "force.h" #include "update.h" #include "modify.h" -#include "input.h" -#include "variable.h" #include "memory.h" #include "error.h" #include "fix_shake.h" -#include "neighbor.h" -#include "comm.h" -#include "timer.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/RIGID/fix_ehex.h b/src/RIGID/fix_ehex.h index e29ddac135..860ed3d1f3 100644 --- a/src/RIGID/fix_ehex.h +++ b/src/RIGID/fix_ehex.h @@ -22,8 +22,6 @@ FixStyle(ehex,FixEHEX) #define LMP_FIX_EHEX_H #include "fix.h" -#include "fix_shake.h" -#include "region.h" #define EHEX_DEBUG 0 namespace LAMMPS_NS { @@ -41,9 +39,9 @@ class FixEHEX : public Fix { double memory_usage(); void update_scalingmask(); void com_properties(double *, double *, double *, double*, double *, double*); - bool rescale_atom(int i, Region*region); + bool rescale_atom(int i, class Region *region); virtual void grow_arrays(int nmax); - bool check_cluster(tagint *shake_atom, int n, Region * region); + bool check_cluster(tagint *shake_atom, int n, class Region *region); private: int iregion; @@ -53,14 +51,14 @@ class FixEHEX : public Fix { char *idregion; int me; - double **x; // coordinates - double **f; // forces - double **v; // velocities - double *mass; // masses - double *rmass; // reduced masses - int *type; // atom types + double **x; // coordinates + double **f; // forces + double **v; // velocities + double *mass; // masses + double *rmass; // reduced masses + int *type; // atom types int nlocal; // number of local atoms - FixShake * fshake; // pointer to fix_shake/fix_rattle + class FixShake * fshake; // pointer to fix_shake/fix_rattle int constraints; // constraints (0/1) int cluster; // rescaling entire clusters (0/1) int hex; // HEX mode (0/1) diff --git a/src/RIGID/fix_rattle.cpp b/src/RIGID/fix_rattle.cpp index 403f3091c6..db43b9e82d 100644 --- a/src/RIGID/fix_rattle.cpp +++ b/src/RIGID/fix_rattle.cpp @@ -17,31 +17,20 @@ #include #include -#include #include -#include #include "fix_rattle.h" #include "atom.h" -#include "atom_vec.h" -#include "molecule.h" #include "update.h" -#include "respa.h" #include "modify.h" #include "domain.h" #include "force.h" -#include "bond.h" -#include "angle.h" #include "comm.h" -#include "group.h" -#include "fix_respa.h" -#include "math_const.h" #include "math_extra.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; using namespace FixConst; -using namespace MathConst; using namespace MathExtra; // set RATTLE_DEBUG 1 to check constraints at end of timestep diff --git a/src/RIGID/fix_rattle.h b/src/RIGID/fix_rattle.h index 48edaef379..cab148f10c 100644 --- a/src/RIGID/fix_rattle.h +++ b/src/RIGID/fix_rattle.h @@ -20,7 +20,6 @@ FixStyle(rattle,FixRattle) #ifndef LMP_FIX_RATTLE_H #define LMP_FIX_RATTLE_H -#include "fix.h" #include "fix_shake.h" namespace LAMMPS_NS { diff --git a/src/RIGID/fix_rigid.cpp b/src/RIGID/fix_rigid.cpp index abb669bc02..19eb22a7fa 100644 --- a/src/RIGID/fix_rigid.cpp +++ b/src/RIGID/fix_rigid.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include #include #include "fix_rigid.h" @@ -31,7 +31,6 @@ #include "force.h" #include "input.h" #include "variable.h" -#include "output.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_nh.cpp b/src/RIGID/fix_rigid_nh.cpp index 4acc8d3411..2e1090ec88 100644 --- a/src/RIGID/fix_rigid_nh.cpp +++ b/src/RIGID/fix_rigid_nh.cpp @@ -17,7 +17,6 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ -#include #include #include #include "fix_rigid_nh.h" diff --git a/src/RIGID/fix_rigid_nh_small.cpp b/src/RIGID/fix_rigid_nh_small.cpp index 5016d3f168..8de588bd9b 100644 --- a/src/RIGID/fix_rigid_nh_small.cpp +++ b/src/RIGID/fix_rigid_nh_small.cpp @@ -17,8 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_rigid_nh_small.h" #include "math_extra.h" @@ -32,7 +32,6 @@ #include "comm.h" #include "force.h" #include "kspace.h" -#include "output.h" #include "memory.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_nph.cpp b/src/RIGID/fix_rigid_nph.cpp index 45a4a8d09c..6080fb05af 100644 --- a/src/RIGID/fix_rigid_nph.cpp +++ b/src/RIGID/fix_rigid_nph.cpp @@ -19,7 +19,6 @@ #include #include "fix_rigid_nph.h" -#include "domain.h" #include "modify.h" #include "error.h" diff --git a/src/SHOCK/fix_append_atoms.cpp b/src/SHOCK/fix_append_atoms.cpp index 2e515839c5..5e81b75c0d 100644 --- a/src/SHOCK/fix_append_atoms.cpp +++ b/src/SHOCK/fix_append_atoms.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include -#include #include "fix_append_atoms.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/SHOCK/fix_msst.cpp b/src/SHOCK/fix_msst.cpp index c800e8a85d..15ee4d370f 100644 --- a/src/SHOCK/fix_msst.cpp +++ b/src/SHOCK/fix_msst.cpp @@ -17,22 +17,19 @@ see Reed, Fried, Joannopoulos, Phys Rev Lett, 90, 235503 (2003) ------------------------------------------------------------------------- */ +#include #include -#include #include #include "fix_msst.h" #include "atom.h" #include "force.h" #include "comm.h" -#include "output.h" #include "modify.h" #include "fix_external.h" #include "compute.h" #include "kspace.h" #include "update.h" -#include "respa.h" #include "domain.h" -#include "thermo.h" #include "memory.h" #include "error.h" diff --git a/src/SHOCK/fix_nphug.cpp b/src/SHOCK/fix_nphug.cpp index c6df6646cf..5d5a1642c0 100644 --- a/src/SHOCK/fix_nphug.cpp +++ b/src/SHOCK/fix_nphug.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "fix_nphug.h" #include "modify.h" @@ -22,8 +21,6 @@ #include "force.h" #include "domain.h" #include "group.h" -#include "memory.h" -#include "comm.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/SHOCK/fix_wall_piston.cpp b/src/SHOCK/fix_wall_piston.cpp index eb89e19517..31f70b4174 100644 --- a/src/SHOCK/fix_wall_piston.cpp +++ b/src/SHOCK/fix_wall_piston.cpp @@ -13,10 +13,8 @@ #include #include -#include #include "fix_wall_piston.h" #include "atom.h" -#include "modify.h" #include "domain.h" #include "lattice.h" #include "update.h" diff --git a/src/SNAP/compute_snav_atom.cpp b/src/SNAP/compute_snav_atom.cpp index 1f702496ed..5faf7a1872 100644 --- a/src/SNAP/compute_snav_atom.cpp +++ b/src/SNAP/compute_snav_atom.cpp @@ -10,10 +10,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include "sna.h" #include #include #include "compute_snav_atom.h" +#include "sna.h" #include "atom.h" #include "update.h" #include "modify.h" @@ -21,7 +21,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "force.h" -#include "pair.h" #include "comm.h" #include "memory.h" #include "error.h" diff --git a/src/SNAP/pair_snap.cpp b/src/SNAP/pair_snap.cpp index f9ba8922a0..f0f3ef72c6 100644 --- a/src/SNAP/pair_snap.cpp +++ b/src/SNAP/pair_snap.cpp @@ -11,24 +11,21 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include #include #include "pair_snap.h" #include "atom.h" -#include "atom_vec.h" #include "force.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "sna.h" -#include "domain.h" #include "memory.h" #include "error.h" -#include - using namespace LAMMPS_NS; #define MAXLINE 1024 diff --git a/src/SNAP/sna.cpp b/src/SNAP/sna.cpp index ec545c51b2..d7d9b5163d 100644 --- a/src/SNAP/sna.cpp +++ b/src/SNAP/sna.cpp @@ -15,17 +15,11 @@ Contributing authors: Aidan Thompson, Christian Trott, SNL ------------------------------------------------------------------------- */ -#include "sna.h" #include +#include "sna.h" #include "math_const.h" -#include "math_extra.h" -#include -#include - #include "memory.h" #include "error.h" -#include "comm.h" -#include "atom.h" using namespace std; using namespace LAMMPS_NS; diff --git a/src/SPIN/compute_spin.cpp b/src/SPIN/compute_spin.cpp index 0a881e1de6..ec11bc68f2 100644 --- a/src/SPIN/compute_spin.cpp +++ b/src/SPIN/compute_spin.cpp @@ -22,20 +22,16 @@ ------------------------------------------------------------------------- */ #include -#include -#include "atom.h" +#include #include "compute_spin.h" -#include "domain.h" +#include "atom.h" #include "error.h" #include "force.h" -#include "math_special.h" #include "math_const.h" #include "memory.h" -#include "modify.h" #include "update.h" using namespace LAMMPS_NS; -using namespace MathSpecial; using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/SPIN/fix_langevin_spin.cpp b/src/SPIN/fix_langevin_spin.cpp index ec6f719a77..6936c701c6 100644 --- a/src/SPIN/fix_langevin_spin.cpp +++ b/src/SPIN/fix_langevin_spin.cpp @@ -21,31 +21,19 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ -#include #include #include -#include - -#include "atom.h" -#include "atom_vec_ellipsoid.h" -#include "comm.h" -#include "compute.h" -#include "domain.h" -#include "error.h" #include "fix_langevin_spin.h" +#include "comm.h" +#include "error.h" #include "force.h" -#include "group.h" -#include "input.h" #include "math_const.h" -#include "math_extra.h" #include "memory.h" #include "modify.h" -#include "random_mars.h" #include "random_park.h" -#include "region.h" #include "respa.h" #include "update.h" -#include "variable.h" +#include "utils.h" using namespace LAMMPS_NS; using namespace FixConst; @@ -142,13 +130,11 @@ void FixLangevinSpin::init() void FixLangevinSpin::setup(int vflag) { - if (strstr(update->integrate_style,"verlet")) - post_force(vflag); - else { + if (utils::strmatch(update->integrate_style,"^respa")) { ((Respa *) update->integrate)->copy_flevel_f(nlevels_respa-1); post_force_respa(vflag,nlevels_respa-1,0); ((Respa *) update->integrate)->copy_f_flevel(nlevels_respa-1); - } + } else post_force(vflag); } /* ---------------------------------------------------------------------- */ diff --git a/src/SPIN/fix_neb_spin.cpp b/src/SPIN/fix_neb_spin.cpp index a8cb0cd2ca..7ed8967a24 100644 --- a/src/SPIN/fix_neb_spin.cpp +++ b/src/SPIN/fix_neb_spin.cpp @@ -23,13 +23,11 @@ #include #include -#include #include #include "fix_neb_spin.h" #include "universe.h" #include "update.h" #include "atom.h" -#include "domain.h" #include "comm.h" #include "modify.h" #include "compute.h" @@ -37,11 +35,9 @@ #include "memory.h" #include "error.h" #include "force.h" -#include "math_const.h" using namespace LAMMPS_NS; using namespace FixConst; -using namespace MathConst; enum{SINGLE_PROC_DIRECT,SINGLE_PROC_MAP,MULTI_PROC}; diff --git a/src/SPIN/fix_nve_spin.cpp b/src/SPIN/fix_nve_spin.cpp index 595ddb0cc2..d35585c7a6 100644 --- a/src/SPIN/fix_nve_spin.cpp +++ b/src/SPIN/fix_nve_spin.cpp @@ -21,38 +21,24 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ -#include -#include #include - +#include "fix_nve_spin.h" #include "atom.h" -#include "atom_vec.h" #include "citeme.h" #include "comm.h" #include "domain.h" #include "error.h" -#include "fix_nve_spin.h" #include "fix_precession_spin.h" #include "fix_langevin_spin.h" #include "fix_setforce_spin.h" #include "force.h" -#include "math_vector.h" -#include "math_extra.h" -#include "math_const.h" #include "memory.h" #include "modify.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "pair.h" -#include "pair_hybrid.h" #include "pair_spin.h" -#include "respa.h" #include "update.h" using namespace LAMMPS_NS; using namespace FixConst; -using namespace MathConst; -using namespace MathExtra; static const char cite_fix_nve_spin[] = "fix nve/spin command:\n\n" diff --git a/src/SPIN/fix_nve_spin.h b/src/SPIN/fix_nve_spin.h index 4800575c06..1e3b87c1fb 100644 --- a/src/SPIN/fix_nve_spin.h +++ b/src/SPIN/fix_nve_spin.h @@ -21,8 +21,6 @@ FixStyle(nve/spin,FixNVESpin) #define LMP_FIX_NVE_SPIN_H #include "fix.h" -#include "pair.h" -#include "pair_spin.h" namespace LAMMPS_NS { diff --git a/src/SPIN/fix_precession_spin.cpp b/src/SPIN/fix_precession_spin.cpp index 1ea134d367..7764bb0438 100644 --- a/src/SPIN/fix_precession_spin.cpp +++ b/src/SPIN/fix_precession_spin.cpp @@ -21,21 +21,16 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include +#include "fix_precession_spin.h" #include "atom.h" #include "error.h" -#include "domain.h" -#include "error.h" -#include "fix_precession_spin.h" #include "force.h" #include "input.h" #include "math_const.h" -#include "memory.h" #include "modify.h" -#include "neigh_list.h" #include "respa.h" #include "update.h" #include "variable.h" diff --git a/src/SPIN/fix_setforce_spin.cpp b/src/SPIN/fix_setforce_spin.cpp index c2807418ec..1ab35c9663 100644 --- a/src/SPIN/fix_setforce_spin.cpp +++ b/src/SPIN/fix_setforce_spin.cpp @@ -21,7 +21,6 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ -#include #include #include "fix_setforce_spin.h" #include "atom.h" @@ -29,12 +28,9 @@ #include "modify.h" #include "domain.h" #include "region.h" -#include "respa.h" #include "input.h" #include "variable.h" #include "memory.h" -#include "error.h" -#include "force.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/SPIN/min_spin.cpp b/src/SPIN/min_spin.cpp index 2bddc110e7..3a330f448a 100644 --- a/src/SPIN/min_spin.cpp +++ b/src/SPIN/min_spin.cpp @@ -19,7 +19,6 @@ #include #include -#include #include #include "min_spin.h" #include "universe.h" @@ -29,8 +28,6 @@ #include "output.h" #include "timer.h" #include "error.h" -#include "modify.h" -#include "math_special.h" #include "math_const.h" using namespace LAMMPS_NS; diff --git a/src/SPIN/neb_spin.cpp b/src/SPIN/neb_spin.cpp index 46a0541488..400ce3d363 100644 --- a/src/SPIN/neb_spin.cpp +++ b/src/SPIN/neb_spin.cpp @@ -21,18 +21,12 @@ Computer Physics Communications, 196, 335-347. ------------------------------------------------------------------------- */ -// lmptype.h must be first b/c this file uses MAXBIGINT and includes mpi.h -// due to OpenMPI bug which sets INT64_MAX via its mpi.h -// before lmptype.h can set flags to insure it is done correctly - -#include "lmptype.h" #include #include #include #include #include "neb_spin.h" #include "citeme.h" -#include "compute.h" #include "force.h" #include "universe.h" #include "atom.h" @@ -49,10 +43,8 @@ #include "timer.h" #include "memory.h" #include "error.h" -#include "math_const.h" using namespace LAMMPS_NS; -using namespace MathConst; static const char cite_neb_spin[] = "neb/spin command:\n\n" diff --git a/src/SPIN/pair_spin.cpp b/src/SPIN/pair_spin.cpp index 929b79bef3..93d9a1e127 100644 --- a/src/SPIN/pair_spin.cpp +++ b/src/SPIN/pair_spin.cpp @@ -21,26 +21,15 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ -#include -#include #include - +#include "pair_spin.h" #include "atom.h" -#include "comm.h" #include "error.h" #include "fix.h" -#include "fix_nve_spin.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "math_const.h" -#include "memory.h" #include "modify.h" #include "pair.h" -#include "pair_hybrid.h" -#include "pair_hybrid_overlay.h" -#include "pair_spin.h" #include "update.h" using namespace LAMMPS_NS; diff --git a/src/SPIN/pair_spin.h b/src/SPIN/pair_spin.h index 1be8550c65..3a909e1d13 100644 --- a/src/SPIN/pair_spin.h +++ b/src/SPIN/pair_spin.h @@ -14,7 +14,7 @@ #ifndef LMP_PAIR_SPIN_H #define LMP_PAIR_SPIN_H -#include "pair.h" +#include "pair.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/SPIN/pair_spin_dipole_cut.cpp b/src/SPIN/pair_spin_dipole_cut.cpp index 4ff198488a..8d9b5b8f2b 100644 --- a/src/SPIN/pair_spin_dipole_cut.cpp +++ b/src/SPIN/pair_spin_dipole_cut.cpp @@ -21,9 +21,8 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_spin_dipole_cut.h" #include "atom.h" @@ -31,6 +30,7 @@ #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" +#include "fix.h" #include "fix_nve_spin.h" #include "force.h" #include "math_const.h" diff --git a/src/SPIN/pair_spin_dipole_long.cpp b/src/SPIN/pair_spin_dipole_long.cpp index e3575a6a07..84c55a8c3c 100644 --- a/src/SPIN/pair_spin_dipole_long.cpp +++ b/src/SPIN/pair_spin_dipole_long.cpp @@ -13,20 +13,19 @@ /* ------------------------------------------------------------------------ Contributing authors: Julien Tranchida (SNL) - Stan Moore (SNL) + Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include - #include "pair_spin_dipole_long.h" #include "atom.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" +#include "fix.h" #include "fix_nve_spin.h" #include "force.h" #include "kspace.h" @@ -59,12 +58,12 @@ lockfixnvespin(NULL) no_virial_fdotr_compute = 1; lattice_flag = 0; - hbar = force->hplanck/MY_2PI; // eV/(rad.THz) + hbar = force->hplanck/MY_2PI; // eV/(rad.THz) mub = 9.274e-4; // in A.Ang^2 mu_0 = 785.15; // in eV/Ang/A^2 mub2mu0 = mub * mub * mu_0 / (4.0*MY_PI); // in eV.Ang^3 - //mub2mu0 = mub * mub * mu_0 / (4.0*MY_PI); // in eV - mub2mu0hbinv = mub2mu0 / hbar; // in rad.THz + //mub2mu0 = mub * mub * mu_0 / (4.0*MY_PI); // in eV + mub2mu0hbinv = mub2mu0 / hbar; // in rad.THz } @@ -243,7 +242,7 @@ void PairSpinDipoleLong::compute(int eflag, int vflag) double **x = atom->x; double **f = atom->f; double **fm = atom->fm; - double **sp = atom->sp; + double **sp = atom->sp; int *type = atom->type; int nlocal = atom->nlocal; int newton_pair = force->newton_pair; @@ -314,36 +313,36 @@ void PairSpinDipoleLong::compute(int eflag, int vflag) bij[2] = (3.0*bij[1] + pre2*expm2) * r2inv; bij[3] = (5.0*bij[2] + pre3*expm2) * r2inv; - compute_long(i,j,eij,bij,fmi,spi,spj); - compute_long_mech(i,j,eij,bij,fmi,spi,spj); + compute_long(i,j,eij,bij,fmi,spi,spj); + compute_long_mech(i,j,eij,bij,fmi,spi,spj); } // force accumulation - f[i][0] += fi[0]; - f[i][1] += fi[1]; + f[i][0] += fi[0]; + f[i][1] += fi[1]; f[i][2] += fi[2]; - fm[i][0] += fmi[0]; - fm[i][1] += fmi[1]; + fm[i][0] += fmi[0]; + fm[i][1] += fmi[1]; fm[i][2] += fmi[2]; if (newton_pair || j < nlocal) { - f[j][0] -= fi[0]; - f[j][1] -= fi[1]; + f[j][0] -= fi[0]; + f[j][1] -= fi[1]; f[j][2] -= fi[2]; } if (eflag) { - if (rsq <= local_cut2) { - evdwl -= spi[0]*fmi[0] + spi[1]*fmi[1] + - spi[2]*fmi[2]; - evdwl *= hbar; - } + if (rsq <= local_cut2) { + evdwl -= spi[0]*fmi[0] + spi[1]*fmi[1] + + spi[2]*fmi[2]; + evdwl *= hbar; + } } else evdwl = 0.0; if (evflag) ev_tally_xyz(i,j,nlocal,newton_pair, - evdwl,ecoul,fi[0],fi[1],fi[2],rij[0],rij[1],rij[2]); + evdwl,ecoul,fi[0],fi[1],fi[2],rij[0],rij[1],rij[2]); } } @@ -365,7 +364,7 @@ void PairSpinDipoleLong::compute_single_pair(int ii, double fmi[3]) int *type = atom->type; double **x = atom->x; - double **sp = atom->sp; + double **sp = atom->sp; double **fm_long = atom->fm_long; ilist = list->ilist; @@ -550,7 +549,7 @@ void PairSpinDipoleLong::write_restart(FILE *fp) for (j = i; j <= atom->ntypes; j++) { fwrite(&setflag[i][j],sizeof(int),1,fp); if (setflag[i][j]) { - fwrite(&cut_spin_long[i][j],sizeof(int),1,fp); + fwrite(&cut_spin_long[i][j],sizeof(int),1,fp); } } } @@ -573,10 +572,10 @@ void PairSpinDipoleLong::read_restart(FILE *fp) if (me == 0) fread(&setflag[i][j],sizeof(int),1,fp); MPI_Bcast(&setflag[i][j],1,MPI_INT,0,world); if (setflag[i][j]) { - if (me == 0) { - fread(&cut_spin_long[i][j],sizeof(int),1,fp); - } - MPI_Bcast(&cut_spin_long[i][j],1,MPI_INT,0,world); + if (me == 0) { + fread(&cut_spin_long[i][j],sizeof(int),1,fp); + } + MPI_Bcast(&cut_spin_long[i][j],1,MPI_INT,0,world); } } } diff --git a/src/SPIN/pair_spin_dmi.cpp b/src/SPIN/pair_spin_dmi.cpp index 41430d230f..651f4397bd 100644 --- a/src/SPIN/pair_spin_dmi.cpp +++ b/src/SPIN/pair_spin_dmi.cpp @@ -21,28 +21,24 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include #include -#include #include - +#include "pair_spin_dmi.h" #include "atom.h" #include "comm.h" #include "error.h" #include "force.h" #include "fix.h" #include "fix_nve_spin.h" -#include "pair_hybrid.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "math_const.h" #include "memory.h" #include "modify.h" -#include "pair_spin_dmi.h" #include "update.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/SPIN/pair_spin_exchange.cpp b/src/SPIN/pair_spin_exchange.cpp index 93b6d9501e..059a8f5f34 100644 --- a/src/SPIN/pair_spin_exchange.cpp +++ b/src/SPIN/pair_spin_exchange.cpp @@ -21,28 +21,24 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include #include -#include #include - +#include "pair_spin_exchange.h" #include "atom.h" #include "comm.h" #include "error.h" #include "fix.h" #include "fix_nve_spin.h" #include "force.h" -#include "pair_hybrid.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "math_const.h" #include "memory.h" #include "modify.h" -#include "pair_spin_exchange.h" #include "update.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/SPIN/pair_spin_magelec.cpp b/src/SPIN/pair_spin_magelec.cpp index 1f1488b93c..55b96582c8 100644 --- a/src/SPIN/pair_spin_magelec.cpp +++ b/src/SPIN/pair_spin_magelec.cpp @@ -21,28 +21,24 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include #include -#include #include - +#include "pair_spin_magelec.h" #include "atom.h" #include "comm.h" #include "error.h" #include "fix.h" #include "fix_nve_spin.h" #include "force.h" -#include "pair_hybrid.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "math_const.h" #include "memory.h" #include "modify.h" -#include "pair_spin_magelec.h" #include "update.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/SPIN/pair_spin_neel.cpp b/src/SPIN/pair_spin_neel.cpp index 03041da17f..4d68dbdc22 100644 --- a/src/SPIN/pair_spin_neel.cpp +++ b/src/SPIN/pair_spin_neel.cpp @@ -21,29 +21,24 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include #include -#include #include - +#include "pair_spin_neel.h" #include "atom.h" #include "comm.h" #include "error.h" -#include "force.h" #include "fix.h" #include "fix_nve_spin.h" #include "force.h" -#include "pair_hybrid.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "math_const.h" #include "memory.h" #include "modify.h" -#include "pair_spin_neel.h" #include "update.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/SRD/fix_srd.cpp b/src/SRD/fix_srd.cpp index d87d2b5e56..a20ec212fd 100644 --- a/src/SRD/fix_srd.cpp +++ b/src/SRD/fix_srd.cpp @@ -15,9 +15,9 @@ Contributing authors: Jeremy Lechman (SNL), Pieter in 't Veld (BASF) ------------------------------------------------------------------------- */ +#include #include #include -#include #include "fix_srd.h" #include "math_extra.h" #include "atom.h" @@ -27,7 +27,6 @@ #include "group.h" #include "update.h" #include "force.h" -#include "pair.h" #include "domain.h" #include "neighbor.h" #include "comm.h" diff --git a/src/SRD/fix_wall_srd.cpp b/src/SRD/fix_wall_srd.cpp index 24b0c3cec5..cb0f023640 100644 --- a/src/SRD/fix_wall_srd.cpp +++ b/src/SRD/fix_wall_srd.cpp @@ -11,11 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include #include "fix_wall_srd.h" -#include "atom.h" -#include "modify.h" #include "fix.h" #include "domain.h" #include "lattice.h" diff --git a/src/USER-EFF/atom_vec_electron.cpp b/src/USER-EFF/atom_vec_electron.cpp index 1bc5387c9e..5de78f7510 100644 --- a/src/USER-EFF/atom_vec_electron.cpp +++ b/src/USER-EFF/atom_vec_electron.cpp @@ -15,7 +15,6 @@ Contributing author: Andres Jaramillo-Botero (Caltech) ------------------------------------------------------------------------- */ -#include #include #include #include "atom_vec_electron.h" @@ -23,7 +22,6 @@ #include "comm.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "citeme.h" #include "memory.h" diff --git a/src/USER-EFF/compute_ke_atom_eff.cpp b/src/USER-EFF/compute_ke_atom_eff.cpp index b1b87cd3df..c943366f1b 100644 --- a/src/USER-EFF/compute_ke_atom_eff.cpp +++ b/src/USER-EFF/compute_ke_atom_eff.cpp @@ -15,7 +15,6 @@ Contributing author: Andres Jaramillo-Botero ------------------------------------------------------------------------- */ -#include #include #include #include "compute_ke_atom_eff.h" diff --git a/src/USER-EFF/compute_ke_eff.cpp b/src/USER-EFF/compute_ke_eff.cpp index b4f571cb63..3e277fc66c 100644 --- a/src/USER-EFF/compute_ke_eff.cpp +++ b/src/USER-EFF/compute_ke_eff.cpp @@ -16,14 +16,12 @@ ------------------------------------------------------------------------- */ #include -#include #include #include "compute_ke_eff.h" #include "atom.h" #include "update.h" #include "force.h" #include "domain.h" -#include "group.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-EFF/compute_temp_deform_eff.cpp b/src/USER-EFF/compute_temp_deform_eff.cpp index 23abb4f99d..7a12a69982 100644 --- a/src/USER-EFF/compute_temp_deform_eff.cpp +++ b/src/USER-EFF/compute_temp_deform_eff.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include -#include #include #include #include "compute_temp_deform_eff.h" diff --git a/src/USER-EFF/compute_temp_eff.cpp b/src/USER-EFF/compute_temp_eff.cpp index 956461adf1..d745269ff5 100644 --- a/src/USER-EFF/compute_temp_eff.cpp +++ b/src/USER-EFF/compute_temp_eff.cpp @@ -17,8 +17,6 @@ #include #include -#include -#include #include "compute_temp_eff.h" #include "atom.h" #include "update.h" diff --git a/src/USER-EFF/compute_temp_region_eff.cpp b/src/USER-EFF/compute_temp_region_eff.cpp index 659bdfca5e..cec87b29ab 100644 --- a/src/USER-EFF/compute_temp_region_eff.cpp +++ b/src/USER-EFF/compute_temp_region_eff.cpp @@ -16,14 +16,12 @@ ------------------------------------------------------------------------- */ #include -#include #include #include #include "compute_temp_region_eff.h" #include "atom.h" #include "update.h" #include "force.h" -#include "modify.h" #include "domain.h" #include "region.h" #include "group.h" diff --git a/src/USER-EFF/fix_langevin_eff.cpp b/src/USER-EFF/fix_langevin_eff.cpp index d362113997..5158d7c681 100644 --- a/src/USER-EFF/fix_langevin_eff.cpp +++ b/src/USER-EFF/fix_langevin_eff.cpp @@ -17,19 +17,13 @@ #include #include -#include #include #include "fix_langevin_eff.h" -#include "math_extra.h" #include "atom.h" -#include "force.h" #include "update.h" #include "modify.h" #include "compute.h" #include "domain.h" -#include "region.h" -#include "respa.h" -#include "comm.h" #include "input.h" #include "variable.h" #include "random_mars.h" diff --git a/src/USER-EFF/fix_nh_eff.cpp b/src/USER-EFF/fix_nh_eff.cpp index 3e0a59612c..034233732e 100644 --- a/src/USER-EFF/fix_nh_eff.cpp +++ b/src/USER-EFF/fix_nh_eff.cpp @@ -15,12 +15,10 @@ Contributing author: Andres Jaramillo-Botero (Caltech) ------------------------------------------------------------------------- */ -#include #include #include "fix_nh_eff.h" #include "atom.h" #include "atom_vec.h" -#include "group.h" #include "error.h" #include "domain.h" diff --git a/src/USER-EFF/fix_nve_eff.cpp b/src/USER-EFF/fix_nve_eff.cpp index 699dd9f949..ea719c91c0 100644 --- a/src/USER-EFF/fix_nve_eff.cpp +++ b/src/USER-EFF/fix_nve_eff.cpp @@ -15,8 +15,6 @@ Contributing author: Andres Jaramillo-Botero (Caltech) ------------------------------------------------------------------------- */ -#include -#include #include #include #include "fix_nve_eff.h" diff --git a/src/USER-EFF/fix_nvt_eff.cpp b/src/USER-EFF/fix_nvt_eff.cpp index 9e23ee023b..8516accd31 100644 --- a/src/USER-EFF/fix_nvt_eff.cpp +++ b/src/USER-EFF/fix_nvt_eff.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include -#include #include "fix_nvt_eff.h" #include "group.h" #include "modify.h" diff --git a/src/USER-EFF/fix_temp_rescale_eff.cpp b/src/USER-EFF/fix_temp_rescale_eff.cpp index 37f45b3c28..4a8f4b0372 100644 --- a/src/USER-EFF/fix_temp_rescale_eff.cpp +++ b/src/USER-EFF/fix_temp_rescale_eff.cpp @@ -23,8 +23,6 @@ #include "force.h" #include "group.h" #include "update.h" -#include "domain.h" -#include "region.h" #include "comm.h" #include "modify.h" #include "compute.h" diff --git a/src/USER-EFF/pair_eff_cut.cpp b/src/USER-EFF/pair_eff_cut.cpp index f566922ef7..a4c0557620 100644 --- a/src/USER-EFF/pair_eff_cut.cpp +++ b/src/USER-EFF/pair_eff_cut.cpp @@ -15,8 +15,8 @@ Contributing author: Andres Jaramillo-Botero ------------------------------------------------------------------------- */ +#include #include -#include #include #include #include "pair_eff_cut.h" @@ -31,7 +31,6 @@ #include "neigh_list.h" #include "memory.h" #include "error.h" -#include "atom_vec_electron.h" using namespace LAMMPS_NS; diff --git a/src/USER-PHONON/fix_phonon.cpp b/src/USER-PHONON/fix_phonon.cpp index cdbe4068bc..9b663ce383 100644 --- a/src/USER-PHONON/fix_phonon.cpp +++ b/src/USER-PHONON/fix_phonon.cpp @@ -23,8 +23,8 @@ konglt@sjtu.edu.cn; konglt@gmail.com ------------------------------------------------------------------------- */ -#include -#include +#include +#include #include #include "fix_phonon.h" #include "fft3d_wrap.h" @@ -33,7 +33,6 @@ #include "domain.h" #include "force.h" #include "group.h" -#include "lattice.h" #include "modify.h" #include "update.h" #include "citeme.h" From 11708c8f96aa0f020d8c562a577940578ec4882a Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Tue, 2 Jul 2019 12:07:26 -0400 Subject: [PATCH 30/79] continue cleaning up include files based on IWYU --- src/npair_skip_respa.cpp | 3 --- src/npair_skip_size.cpp | 2 -- src/npair_skip_size_off2on.cpp | 2 -- src/npair_skip_size_off2on_oneside.cpp | 2 -- src/nstencil_full_bin_2d.cpp | 2 -- src/nstencil_full_bin_3d.cpp | 2 -- src/nstencil_full_ghost_bin_2d.cpp | 2 -- src/nstencil_full_ghost_bin_3d.cpp | 2 -- src/nstencil_full_multi_2d.cpp | 2 -- src/nstencil_full_multi_3d.cpp | 2 -- src/nstencil_half_bin_2d_newtoff.cpp | 2 -- src/nstencil_half_bin_2d_newton.cpp | 2 -- src/nstencil_half_bin_2d_newton_tri.cpp | 2 -- src/nstencil_half_bin_3d_newtoff.cpp | 2 -- src/nstencil_half_bin_3d_newton.cpp | 2 -- src/nstencil_half_bin_3d_newton_tri.cpp | 2 -- src/nstencil_half_ghost_bin_2d_newtoff.cpp | 2 -- src/nstencil_half_ghost_bin_3d_newtoff.cpp | 2 -- src/nstencil_half_multi_2d_newtoff.cpp | 2 -- src/nstencil_half_multi_2d_newton.cpp | 2 -- src/nstencil_half_multi_2d_newton_tri.cpp | 2 -- src/nstencil_half_multi_3d_newtoff.cpp | 2 -- src/nstencil_half_multi_3d_newton.cpp | 2 -- src/nstencil_half_multi_3d_newton_tri.cpp | 2 -- src/ntopo.cpp | 2 +- src/output.cpp | 3 --- src/pair.cpp | 10 ++-------- src/pair_beck.cpp | 3 +-- src/pair_born.cpp | 3 +-- src/pair_born_coul_dsf.cpp | 4 +--- src/pair_born_coul_wolf.cpp | 4 +--- src/pair_buck.cpp | 3 +-- src/pair_coul_debye.cpp | 6 +----- src/pair_coul_dsf.cpp | 3 +-- src/pair_coul_streitz.cpp | 4 +--- src/pair_coul_wolf.cpp | 4 +--- src/pair_dpd.cpp | 4 +--- src/pair_dpd_tstat.cpp | 1 + src/pair_gauss.cpp | 4 +--- src/pair_hybrid.cpp | 3 +-- src/pair_hybrid_overlay.cpp | 3 --- src/pair_lj96_cut.cpp | 4 +--- src/pair_lj_cubic.cpp | 5 +---- src/pair_lj_cut.cpp | 4 +--- 44 files changed, 19 insertions(+), 107 deletions(-) diff --git a/src/npair_skip_respa.cpp b/src/npair_skip_respa.cpp index 1d4eda5354..68436654b2 100644 --- a/src/npair_skip_respa.cpp +++ b/src/npair_skip_respa.cpp @@ -12,12 +12,9 @@ ------------------------------------------------------------------------- */ #include "npair_skip_respa.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/npair_skip_size.cpp b/src/npair_skip_size.cpp index 67717ae576..436d21f76f 100644 --- a/src/npair_skip_size.cpp +++ b/src/npair_skip_size.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_skip_size.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_skip_size_off2on.cpp b/src/npair_skip_size_off2on.cpp index 74a80e6d3d..cd674ff777 100644 --- a/src/npair_skip_size_off2on.cpp +++ b/src/npair_skip_size_off2on.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_skip_size_off2on.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/npair_skip_size_off2on_oneside.cpp b/src/npair_skip_size_off2on_oneside.cpp index a042acd1c6..0540592cba 100644 --- a/src/npair_skip_size_off2on_oneside.cpp +++ b/src/npair_skip_size_off2on_oneside.cpp @@ -11,9 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_skip_size_off2on_oneside.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/nstencil_full_bin_2d.cpp b/src/nstencil_full_bin_2d.cpp index 0986c40dd4..b18d990bba 100644 --- a/src/nstencil_full_bin_2d.cpp +++ b/src/nstencil_full_bin_2d.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_full_bin_2d.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_full_bin_3d.cpp b/src/nstencil_full_bin_3d.cpp index b6a2198132..46ec073ddd 100644 --- a/src/nstencil_full_bin_3d.cpp +++ b/src/nstencil_full_bin_3d.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_full_bin_3d.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_full_ghost_bin_2d.cpp b/src/nstencil_full_ghost_bin_2d.cpp index bbbf1a4466..5ac19569c5 100644 --- a/src/nstencil_full_ghost_bin_2d.cpp +++ b/src/nstencil_full_ghost_bin_2d.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_full_ghost_bin_2d.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_full_ghost_bin_3d.cpp b/src/nstencil_full_ghost_bin_3d.cpp index e9abca2174..6ee56516dc 100644 --- a/src/nstencil_full_ghost_bin_3d.cpp +++ b/src/nstencil_full_ghost_bin_3d.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_full_ghost_bin_3d.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_full_multi_2d.cpp b/src/nstencil_full_multi_2d.cpp index ed2ffe11dc..c69c53a761 100644 --- a/src/nstencil_full_multi_2d.cpp +++ b/src/nstencil_full_multi_2d.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_full_multi_2d.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_full_multi_3d.cpp b/src/nstencil_full_multi_3d.cpp index c171bfadc5..df47c1e7e9 100644 --- a/src/nstencil_full_multi_3d.cpp +++ b/src/nstencil_full_multi_3d.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_full_multi_3d.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_bin_2d_newtoff.cpp b/src/nstencil_half_bin_2d_newtoff.cpp index e51db6fe7a..f3a6c5d08b 100644 --- a/src/nstencil_half_bin_2d_newtoff.cpp +++ b/src/nstencil_half_bin_2d_newtoff.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_2d_newtoff.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_bin_2d_newton.cpp b/src/nstencil_half_bin_2d_newton.cpp index 9479bbf0c8..8fdc8f1aa9 100644 --- a/src/nstencil_half_bin_2d_newton.cpp +++ b/src/nstencil_half_bin_2d_newton.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_2d_newton.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_bin_2d_newton_tri.cpp b/src/nstencil_half_bin_2d_newton_tri.cpp index 4f89b1c326..30d064fb29 100644 --- a/src/nstencil_half_bin_2d_newton_tri.cpp +++ b/src/nstencil_half_bin_2d_newton_tri.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_2d_newton_tri.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_bin_3d_newtoff.cpp b/src/nstencil_half_bin_3d_newtoff.cpp index 433de400c2..e44a93d47d 100644 --- a/src/nstencil_half_bin_3d_newtoff.cpp +++ b/src/nstencil_half_bin_3d_newtoff.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_3d_newtoff.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_bin_3d_newton.cpp b/src/nstencil_half_bin_3d_newton.cpp index 24c234c004..998ed28afe 100644 --- a/src/nstencil_half_bin_3d_newton.cpp +++ b/src/nstencil_half_bin_3d_newton.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_3d_newton.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_bin_3d_newton_tri.cpp b/src/nstencil_half_bin_3d_newton_tri.cpp index 691ce0bb80..2aae44ceaf 100644 --- a/src/nstencil_half_bin_3d_newton_tri.cpp +++ b/src/nstencil_half_bin_3d_newton_tri.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_3d_newton_tri.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_ghost_bin_2d_newtoff.cpp b/src/nstencil_half_ghost_bin_2d_newtoff.cpp index 4bb0ecafe2..6f9a7585fe 100644 --- a/src/nstencil_half_ghost_bin_2d_newtoff.cpp +++ b/src/nstencil_half_ghost_bin_2d_newtoff.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_ghost_bin_2d_newtoff.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_ghost_bin_3d_newtoff.cpp b/src/nstencil_half_ghost_bin_3d_newtoff.cpp index 1026b11542..6492fe4a4e 100644 --- a/src/nstencil_half_ghost_bin_3d_newtoff.cpp +++ b/src/nstencil_half_ghost_bin_3d_newtoff.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_ghost_bin_3d_newtoff.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_multi_2d_newtoff.cpp b/src/nstencil_half_multi_2d_newtoff.cpp index 567abe2878..63cd3fd524 100644 --- a/src/nstencil_half_multi_2d_newtoff.cpp +++ b/src/nstencil_half_multi_2d_newtoff.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_multi_2d_newtoff.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_multi_2d_newton.cpp b/src/nstencil_half_multi_2d_newton.cpp index 5dc2c37148..f6f6c488a5 100644 --- a/src/nstencil_half_multi_2d_newton.cpp +++ b/src/nstencil_half_multi_2d_newton.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_multi_2d_newton.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_multi_2d_newton_tri.cpp b/src/nstencil_half_multi_2d_newton_tri.cpp index 59a5a1d19e..b44ab36ea0 100644 --- a/src/nstencil_half_multi_2d_newton_tri.cpp +++ b/src/nstencil_half_multi_2d_newton_tri.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_multi_2d_newton_tri.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_multi_3d_newtoff.cpp b/src/nstencil_half_multi_3d_newtoff.cpp index 72b882dddc..5a83c4e002 100644 --- a/src/nstencil_half_multi_3d_newtoff.cpp +++ b/src/nstencil_half_multi_3d_newtoff.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_multi_3d_newtoff.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_multi_3d_newton.cpp b/src/nstencil_half_multi_3d_newton.cpp index 9a5d5cab65..5b0c7f9f63 100644 --- a/src/nstencil_half_multi_3d_newton.cpp +++ b/src/nstencil_half_multi_3d_newton.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_multi_3d_newton.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/nstencil_half_multi_3d_newton_tri.cpp b/src/nstencil_half_multi_3d_newton_tri.cpp index 953beb3211..b25a0d0bdb 100644 --- a/src/nstencil_half_multi_3d_newton_tri.cpp +++ b/src/nstencil_half_multi_3d_newton_tri.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_multi_3d_newton_tri.h" -#include "neighbor.h" -#include "neigh_list.h" #include "atom.h" using namespace LAMMPS_NS; diff --git a/src/ntopo.cpp b/src/ntopo.cpp index 8a87a5d6e5..05e287e192 100644 --- a/src/ntopo.cpp +++ b/src/ntopo.cpp @@ -11,7 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include #include "ntopo.h" #include "atom.h" #include "neighbor.h" diff --git a/src/output.cpp b/src/output.cpp index 6253d7de37..fb2f9a700d 100644 --- a/src/output.cpp +++ b/src/output.cpp @@ -11,8 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include #include "output.h" #include "style_dump.h" @@ -26,7 +24,6 @@ #include "domain.h" #include "thermo.h" #include "modify.h" -#include "compute.h" #include "force.h" #include "dump.h" #include "write_restart.h" diff --git a/src/pair.cpp b/src/pair.cpp index 2b4863a54c..3d7bdaa62c 100644 --- a/src/pair.cpp +++ b/src/pair.cpp @@ -16,23 +16,17 @@ ------------------------------------------------------------------------- */ #include -#include -#include -#include +#include // IWYU pragma: keep +#include // IWYU pragma: keep #include -#include -#include #include #include "pair.h" #include "atom.h" #include "neighbor.h" -#include "neigh_list.h" #include "domain.h" #include "comm.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "modify.h" #include "compute.h" #include "suffix.h" #include "atom_masks.h" diff --git a/src/pair_beck.cpp b/src/pair_beck.cpp index 17731ebf0b..8ba3ef80f2 100644 --- a/src/pair_beck.cpp +++ b/src/pair_beck.cpp @@ -15,9 +15,8 @@ Contributing author: Jonathan Zimmerman (Sandia) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include "pair_beck.h" #include "atom.h" #include "comm.h" diff --git a/src/pair_born.cpp b/src/pair_born.cpp index 78434c91f8..ae7456ddbb 100644 --- a/src/pair_born.cpp +++ b/src/pair_born.cpp @@ -15,9 +15,8 @@ Contributing Author: Sai Jayaraman (Sandia) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_born.h" #include "atom.h" diff --git a/src/pair_born_coul_dsf.cpp b/src/pair_born_coul_dsf.cpp index 2e565897b5..51b9a2677d 100644 --- a/src/pair_born_coul_dsf.cpp +++ b/src/pair_born_coul_dsf.cpp @@ -16,10 +16,8 @@ References: Fennell and Gezelter, JCP 124, 234104 (2006) ------------------------------------------------------------------------- */ +#include #include -#include -#include -#include #include "pair_born_coul_dsf.h" #include "atom.h" #include "comm.h" diff --git a/src/pair_born_coul_wolf.cpp b/src/pair_born_coul_wolf.cpp index 3bb0e39e57..f4ccac80a1 100644 --- a/src/pair_born_coul_wolf.cpp +++ b/src/pair_born_coul_wolf.cpp @@ -15,10 +15,8 @@ Contributing author: Yongfeng Zhang (INL), yongfeng.zhang@inl.gov ------------------------------------------------------------------------- */ +#include #include -#include -#include -#include #include "pair_born_coul_wolf.h" #include "atom.h" #include "comm.h" diff --git a/src/pair_buck.cpp b/src/pair_buck.cpp index a3cf1a38d6..b9795fb0ed 100644 --- a/src/pair_buck.cpp +++ b/src/pair_buck.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_buck.h" #include "atom.h" diff --git a/src/pair_coul_debye.cpp b/src/pair_coul_debye.cpp index c8afdabb93..cd23ef1919 100644 --- a/src/pair_coul_debye.cpp +++ b/src/pair_coul_debye.cpp @@ -11,17 +11,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include -#include -#include #include "pair_coul_debye.h" #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/pair_coul_dsf.cpp b/src/pair_coul_dsf.cpp index e487ff171c..4c15b5d330 100644 --- a/src/pair_coul_dsf.cpp +++ b/src/pair_coul_dsf.cpp @@ -16,9 +16,8 @@ References: Fennell and Gezelter, JCP 124, 234104 (2006) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_coul_dsf.h" #include "atom.h" diff --git a/src/pair_coul_streitz.cpp b/src/pair_coul_streitz.cpp index 282c855249..f577564ac1 100644 --- a/src/pair_coul_streitz.cpp +++ b/src/pair_coul_streitz.cpp @@ -15,8 +15,8 @@ Contributing author: Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include #include -#include #include #include #include "pair_coul_streitz.h" @@ -27,8 +27,6 @@ #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "group.h" -#include "update.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/pair_coul_wolf.cpp b/src/pair_coul_wolf.cpp index dbf21b8bee..8c15378de8 100644 --- a/src/pair_coul_wolf.cpp +++ b/src/pair_coul_wolf.cpp @@ -15,10 +15,8 @@ Contributing author: Yongfeng Zhang (INL), yongfeng.zhang@inl.gov ------------------------------------------------------------------------- */ +#include #include -#include -#include -#include #include "pair_coul_wolf.h" #include "atom.h" #include "comm.h" diff --git a/src/pair_dpd.cpp b/src/pair_dpd.cpp index 914b4aee17..e5e6cf7dae 100644 --- a/src/pair_dpd.cpp +++ b/src/pair_dpd.cpp @@ -15,12 +15,10 @@ Contributing author: Kurt Smith (U Pittsburgh) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include "pair_dpd.h" #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "update.h" #include "force.h" diff --git a/src/pair_dpd_tstat.cpp b/src/pair_dpd_tstat.cpp index 1207c954eb..66c8d91ab1 100644 --- a/src/pair_dpd_tstat.cpp +++ b/src/pair_dpd_tstat.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "pair_dpd_tstat.h" #include "atom.h" diff --git a/src/pair_gauss.cpp b/src/pair_gauss.cpp index 2d157d6cac..7df9a417c3 100644 --- a/src/pair_gauss.cpp +++ b/src/pair_gauss.cpp @@ -15,15 +15,13 @@ Contributing author: Sai Jayaraman (Sandia) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_gauss.h" #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/pair_hybrid.cpp b/src/pair_hybrid.cpp index 9aff8a387a..daeee3d2b3 100644 --- a/src/pair_hybrid.cpp +++ b/src/pair_hybrid.cpp @@ -12,8 +12,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include +#include #include #include #include "pair_hybrid.h" diff --git a/src/pair_hybrid_overlay.cpp b/src/pair_hybrid_overlay.cpp index 717c0de1d1..496e3d0406 100644 --- a/src/pair_hybrid_overlay.cpp +++ b/src/pair_hybrid_overlay.cpp @@ -11,14 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include #include #include "pair_hybrid_overlay.h" #include "atom.h" #include "force.h" -#include "neighbor.h" -#include "neigh_request.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/pair_lj96_cut.cpp b/src/pair_lj96_cut.cpp index cefe9b87e0..62e645ef2c 100644 --- a/src/pair_lj96_cut.cpp +++ b/src/pair_lj96_cut.cpp @@ -15,9 +15,8 @@ Contributing author: Chuanfu Luo (luochuanfu@gmail.com) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_lj96_cut.h" #include "atom.h" @@ -27,7 +26,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory.h" diff --git a/src/pair_lj_cubic.cpp b/src/pair_lj_cubic.cpp index fdbfca608f..8b1b4b7627 100644 --- a/src/pair_lj_cubic.cpp +++ b/src/pair_lj_cubic.cpp @@ -16,15 +16,12 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include #include -#include -#include -#include #include "pair_lj_cubic.h" #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/pair_lj_cut.cpp b/src/pair_lj_cut.cpp index 2a0fcde3a5..9284923218 100644 --- a/src/pair_lj_cut.cpp +++ b/src/pair_lj_cut.cpp @@ -15,9 +15,8 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_lj_cut.h" #include "atom.h" @@ -27,7 +26,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory.h" From 7967cb11339b3ae52e9de9c671e5c611b1d9b1f2 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Tue, 2 Jul 2019 22:56:56 -0400 Subject: [PATCH 31/79] put implementation header first to avoid issues with mpi.h and lmptype.h with OpenMPI --- doc/include-file-conventions.md | 4 ++-- src/angle.h | 2 +- src/angle_deprecated.cpp | 5 +++-- src/angle_hybrid.cpp | 2 +- src/angle_zero.cpp | 2 +- src/atom.cpp | 2 +- src/atom_map.cpp | 2 +- src/atom_vec.cpp | 2 +- src/atom_vec_atomic.cpp | 2 +- src/atom_vec_body.cpp | 2 +- src/atom_vec_charge.cpp | 2 +- src/atom_vec_ellipsoid.cpp | 2 +- src/atom_vec_hybrid.cpp | 2 +- src/atom_vec_line.cpp | 2 +- src/atom_vec_sphere.cpp | 2 +- src/atom_vec_tri.cpp | 2 +- src/balance.cpp | 2 +- src/body.cpp | 2 +- src/bond.cpp | 2 +- src/bond_deprecated.cpp | 2 +- src/bond_hybrid.cpp | 2 +- src/bond_zero.cpp | 2 +- src/change_box.cpp | 2 +- src/comm.cpp | 2 +- src/comm_brick.cpp | 2 +- src/comm_tiled.cpp | 2 +- src/compute.cpp | 2 +- src/compute_adf.cpp | 2 +- src/compute_aggregate_atom.cpp | 2 +- src/compute_angle.cpp | 2 +- src/compute_angle_local.cpp | 2 +- src/compute_angmom_chunk.cpp | 2 +- src/compute_bond.cpp | 2 +- src/compute_bond_local.cpp | 2 +- src/compute_centro_atom.cpp | 2 +- src/compute_chunk_atom.cpp | 2 +- src/compute_chunk_spread_atom.cpp | 2 +- src/compute_cluster_atom.cpp | 2 +- src/compute_cna_atom.cpp | 2 +- src/compute_com_chunk.cpp | 2 +- src/compute_contact_atom.cpp | 2 +- src/compute_coord_atom.cpp | 2 +- src/compute_deprecated.cpp | 2 +- src/compute_dihedral.cpp | 2 +- src/compute_dihedral_local.cpp | 2 +- src/compute_dipole_chunk.cpp | 2 +- src/compute_displace_atom.cpp | 2 +- src/compute_erotate_sphere.cpp | 2 +- src/compute_erotate_sphere_atom.cpp | 2 +- src/compute_fragment_atom.cpp | 2 +- src/compute_global_atom.cpp | 2 +- src/compute_group_group.cpp | 2 +- src/compute_gyration.cpp | 2 +- src/compute_gyration_chunk.cpp | 2 +- src/compute_heat_flux.cpp | 2 +- src/compute_hexorder_atom.cpp | 2 +- src/compute_improper.cpp | 2 +- src/compute_improper_local.cpp | 2 +- src/compute_inertia_chunk.cpp | 2 +- src/compute_ke.cpp | 2 +- src/compute_ke_atom.cpp | 2 +- src/compute_msd.cpp | 2 +- src/compute_msd_chunk.cpp | 2 +- src/compute_omega_chunk.cpp | 2 +- src/compute_orientorder_atom.cpp | 2 +- src/compute_pair.cpp | 2 +- src/compute_pair_local.cpp | 2 +- src/compute_pe.cpp | 2 +- src/compute_pe_atom.cpp | 2 +- src/compute_pressure.cpp | 2 +- src/compute_property_atom.cpp | 2 +- src/compute_property_chunk.cpp | 2 +- src/compute_property_local.cpp | 2 +- src/compute_rdf.cpp | 2 +- src/compute_reduce.cpp | 2 +- src/compute_reduce_chunk.cpp | 2 +- src/compute_reduce_region.cpp | 2 +- src/compute_slice.cpp | 2 +- src/compute_stress_atom.cpp | 2 +- src/compute_temp.cpp | 2 +- src/compute_temp_chunk.cpp | 2 +- src/compute_temp_com.cpp | 2 +- src/compute_temp_deform.cpp | 2 +- src/compute_temp_partial.cpp | 2 +- src/compute_temp_profile.cpp | 2 +- src/compute_temp_ramp.cpp | 2 +- src/compute_temp_region.cpp | 2 +- src/compute_temp_sphere.cpp | 2 +- src/compute_torque_chunk.cpp | 2 +- src/compute_vacf.cpp | 2 +- src/compute_vcm_chunk.cpp | 2 +- src/create_atoms.cpp | 2 +- src/create_bonds.cpp | 2 +- src/create_box.cpp | 2 +- src/delete_atoms.cpp | 2 +- src/delete_bonds.cpp | 2 +- src/deprecated.cpp | 2 +- src/dihedral_deprecated.cpp | 2 +- src/dihedral_hybrid.cpp | 2 +- src/dihedral_zero.cpp | 2 +- src/displace_atoms.cpp | 2 +- src/domain.cpp | 2 +- src/dump.cpp | 2 +- src/dump_atom.cpp | 2 +- src/dump_cfg.cpp | 2 +- src/dump_custom.cpp | 2 +- src/dump_dcd.cpp | 2 +- src/dump_deprecated.cpp | 2 +- src/dump_image.cpp | 2 +- src/dump_local.cpp | 2 +- src/dump_movie.cpp | 2 +- src/dump_xyz.cpp | 2 +- src/error.cpp | 2 +- src/finish.cpp | 2 +- src/fix.cpp | 2 +- src/fix_adapt.cpp | 2 +- src/fix_addforce.cpp | 2 +- src/fix_ave_atom.cpp | 2 +- src/fix_ave_chunk.cpp | 3 +-- src/fix_ave_correlate.cpp | 3 +-- src/fix_ave_histo.cpp | 3 +-- src/fix_ave_histo_weight.cpp | 3 +-- src/fix_ave_time.cpp | 3 +-- src/fix_aveforce.cpp | 2 +- src/fix_balance.cpp | 2 +- src/fix_box_relax.cpp | 2 +- src/fix_controller.cpp | 2 +- src/fix_deform.cpp | 2 +- src/fix_deprecated.cpp | 2 +- src/fix_drag.cpp | 2 +- src/fix_dt_reset.cpp | 2 +- src/fix_enforce2d.cpp | 2 +- src/fix_external.cpp | 2 +- src/fix_gravity.cpp | 2 +- src/fix_group.cpp | 2 +- src/fix_halt.cpp | 2 +- src/fix_heat.cpp | 2 +- src/fix_indent.cpp | 2 +- src/fix_langevin.cpp | 2 +- src/fix_lineforce.cpp | 2 +- src/fix_momentum.cpp | 2 +- src/fix_move.cpp | 2 +- src/fix_neigh_history.cpp | 2 +- src/fix_nh.cpp | 2 +- src/fix_nh_sphere.cpp | 2 +- src/fix_nph.cpp | 2 +- src/fix_nph_sphere.cpp | 2 +- src/fix_npt.cpp | 2 +- src/fix_npt_sphere.cpp | 2 +- src/fix_nve.cpp | 2 +- src/fix_nve_limit.cpp | 2 +- src/fix_nve_noforce.cpp | 2 +- src/fix_nve_sphere.cpp | 2 +- src/fix_nvt.cpp | 2 +- src/fix_nvt_sllod.cpp | 2 +- src/fix_nvt_sphere.cpp | 2 +- src/fix_planeforce.cpp | 2 +- src/fix_press_berendsen.cpp | 2 +- src/fix_print.cpp | 2 +- src/fix_property_atom.cpp | 2 +- src/fix_recenter.cpp | 2 +- src/fix_respa.cpp | 2 +- src/fix_restrain.cpp | 2 +- src/fix_setforce.cpp | 2 +- src/fix_spring.cpp | 2 +- src/fix_spring_chunk.cpp | 2 +- src/fix_spring_rg.cpp | 2 +- src/fix_spring_self.cpp | 2 +- src/fix_store.cpp | 2 +- src/fix_store_force.cpp | 2 +- src/fix_store_state.cpp | 2 +- src/fix_temp_berendsen.cpp | 2 +- src/fix_temp_csld.cpp | 2 +- src/fix_temp_csvr.cpp | 2 +- src/fix_temp_rescale.cpp | 2 +- src/fix_tmd.cpp | 2 +- src/fix_vector.cpp | 2 +- src/fix_viscous.cpp | 2 +- src/fix_wall.cpp | 2 +- src/fix_wall_lj1043.cpp | 2 +- src/fix_wall_lj126.cpp | 2 +- src/fix_wall_lj93.cpp | 2 +- src/fix_wall_reflect.cpp | 2 +- src/fix_wall_region.cpp | 2 +- src/force.cpp | 2 +- src/group.cpp | 2 +- src/hashlittle.cpp | 5 ++--- src/hashlittle.h | 11 ++++++++++- src/image.cpp | 2 +- src/output.cpp | 1 + src/pair_lj_cut_coul_cut.cpp | 3 +-- src/pair_lj_cut_coul_debye.cpp | 2 +- src/pair_lj_cut_coul_dsf.cpp | 7 +++---- src/pointers.h | 2 +- 194 files changed, 209 insertions(+), 206 deletions(-) diff --git a/doc/include-file-conventions.md b/doc/include-file-conventions.md index 3f591361f5..1f206c8f88 100644 --- a/doc/include-file-conventions.md +++ b/doc/include-file-conventions.md @@ -97,10 +97,10 @@ statements should follow the "include what you use" principle. ### Order of Include Statements Include files should be included in this order: -* lmptype.h (should only be included if `MPI_LMP_XXX` data types are used) +* the header matching the implementation (`some_class.h` for file `some_class.cpp`) * mpi.h * system and library headers (anything that is using angular brackets; C-library headers first, then C++) -* LAMMPS local headers (first the header matching the implementation file, the rest in mostly alphabetical order) +* LAMMPS local headers (preferably in alphabetical order) ### Special Cases and Exceptions diff --git a/src/angle.h b/src/angle.h index 7a008f7ca7..3e6812c4fd 100644 --- a/src/angle.h +++ b/src/angle.h @@ -14,7 +14,7 @@ #ifndef LMP_ANGLE_H #define LMP_ANGLE_H -#include "pointers.h" // IWYU pragma: export +#include "pointers.h" namespace LAMMPS_NS { diff --git a/src/angle_deprecated.cpp b/src/angle_deprecated.cpp index b5af217b7b..cc29c9978e 100644 --- a/src/angle_deprecated.cpp +++ b/src/angle_deprecated.cpp @@ -15,12 +15,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "angle_deprecated.h" +#include #include "angle_hybrid.h" #include "comm.h" #include "force.h" #include "error.h" +#include "utils.h" using namespace LAMMPS_NS; @@ -43,7 +44,7 @@ void AngleDeprecated::settings(int, char **) // hybrid substyles are created in AngleHybrid::settings(), so when this is // called, our style was just added at the end of the list of substyles - if (strncmp(my_style,"hybrid",6) == 0) { + if (utils::strmatch(my_style,"^hybrid")) { AngleHybrid *hybrid = (AngleHybrid *)force->angle; my_style = hybrid->keywords[hybrid->nstyles]; } diff --git a/src/angle_hybrid.cpp b/src/angle_hybrid.cpp index 47baf770a5..a4729efb38 100644 --- a/src/angle_hybrid.cpp +++ b/src/angle_hybrid.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "angle_hybrid.h" #include #include #include -#include "angle_hybrid.h" #include "atom.h" #include "neighbor.h" #include "comm.h" diff --git a/src/angle_zero.cpp b/src/angle_zero.cpp index 62eab85aee..3c92b852b3 100644 --- a/src/angle_zero.cpp +++ b/src/angle_zero.cpp @@ -15,9 +15,9 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ +#include "angle_zero.h" #include #include -#include "angle_zero.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/atom.cpp b/src/atom.cpp index eab8a3063d..1073d9ebbb 100644 --- a/src/atom.cpp +++ b/src/atom.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom.h" #include #include #include #include -#include "atom.h" #include "style_atom.h" #include "atom_vec.h" #include "atom_vec_ellipsoid.h" diff --git a/src/atom_map.cpp b/src/atom_map.cpp index 6af3b9c288..7949e327a9 100644 --- a/src/atom_map.cpp +++ b/src/atom_map.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom.h" #include #include -#include "atom.h" #include "comm.h" #include "memory.h" #include "error.h" diff --git a/src/atom_vec.cpp b/src/atom_vec.cpp index a7ca6fcb19..11fe2dba06 100644 --- a/src/atom_vec.cpp +++ b/src/atom_vec.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec.h" #include #include -#include "atom_vec.h" #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/atom_vec_atomic.cpp b/src/atom_vec_atomic.cpp index e1c9a1e524..7b452e018f 100644 --- a/src/atom_vec_atomic.cpp +++ b/src/atom_vec_atomic.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_atomic.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/atom_vec_body.cpp b/src/atom_vec_body.cpp index fad5b3eae0..8cc220c8b9 100644 --- a/src/atom_vec_body.cpp +++ b/src/atom_vec_body.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_body.h" #include #include #include -#include "atom_vec_body.h" #include "my_pool_chunk.h" #include "style_body.h" #include "body.h" diff --git a/src/atom_vec_charge.cpp b/src/atom_vec_charge.cpp index 440393385d..950fe06488 100644 --- a/src/atom_vec_charge.cpp +++ b/src/atom_vec_charge.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_charge.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/atom_vec_ellipsoid.cpp b/src/atom_vec_ellipsoid.cpp index ad167bef79..a9c36a61f4 100644 --- a/src/atom_vec_ellipsoid.cpp +++ b/src/atom_vec_ellipsoid.cpp @@ -15,9 +15,9 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "atom_vec_ellipsoid.h" #include #include -#include "atom_vec_ellipsoid.h" #include "math_extra.h" #include "atom.h" #include "comm.h" diff --git a/src/atom_vec_hybrid.cpp b/src/atom_vec_hybrid.cpp index 7e1fb01e5d..a750b17ac3 100644 --- a/src/atom_vec_hybrid.cpp +++ b/src/atom_vec_hybrid.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_hybrid.h" #include #include -#include "atom_vec_hybrid.h" #include "atom.h" #include "domain.h" #include "modify.h" diff --git a/src/atom_vec_line.cpp b/src/atom_vec_line.cpp index 6b197d2663..d694c42043 100644 --- a/src/atom_vec_line.cpp +++ b/src/atom_vec_line.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_line.h" #include #include #include -#include "atom_vec_line.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/atom_vec_sphere.cpp b/src/atom_vec_sphere.cpp index b3f4bfe391..713fb0d721 100644 --- a/src/atom_vec_sphere.cpp +++ b/src/atom_vec_sphere.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_sphere.h" #include #include -#include "atom_vec_sphere.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/atom_vec_tri.cpp b/src/atom_vec_tri.cpp index b0b6eca19b..9a6afce02f 100644 --- a/src/atom_vec_tri.cpp +++ b/src/atom_vec_tri.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_tri.h" #include #include #include -#include "atom_vec_tri.h" #include "math_extra.h" #include "atom.h" #include "comm.h" diff --git a/src/balance.cpp b/src/balance.cpp index 04f342b69b..c3b6f7d3bf 100644 --- a/src/balance.cpp +++ b/src/balance.cpp @@ -18,10 +18,10 @@ //#define BALANCE_DEBUG 1 +#include "balance.h" #include #include #include -#include "balance.h" #include "atom.h" #include "comm.h" #include "rcb.h" diff --git a/src/body.cpp b/src/body.cpp index 10f88bd43b..c0e58d3f4c 100644 --- a/src/body.cpp +++ b/src/body.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "body.h" +#include using namespace LAMMPS_NS; diff --git a/src/bond.cpp b/src/bond.cpp index 0d50b7e3e5..bb54306280 100644 --- a/src/bond.cpp +++ b/src/bond.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "bond.h" +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/bond_deprecated.cpp b/src/bond_deprecated.cpp index 567b1a4d00..3e20553cac 100644 --- a/src/bond_deprecated.cpp +++ b/src/bond_deprecated.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "bond_deprecated.h" +#include #include "bond_hybrid.h" #include "comm.h" #include "force.h" diff --git a/src/bond_hybrid.cpp b/src/bond_hybrid.cpp index 9028886758..0b1c944196 100644 --- a/src/bond_hybrid.cpp +++ b/src/bond_hybrid.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "bond_hybrid.h" #include #include #include -#include "bond_hybrid.h" #include "atom.h" #include "neighbor.h" #include "comm.h" diff --git a/src/bond_zero.cpp b/src/bond_zero.cpp index c473abbe4b..9be37c13be 100644 --- a/src/bond_zero.cpp +++ b/src/bond_zero.cpp @@ -15,9 +15,9 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ +#include "bond_zero.h" #include #include -#include "bond_zero.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/change_box.cpp b/src/change_box.cpp index 1fed65b430..98119fb3bf 100644 --- a/src/change_box.cpp +++ b/src/change_box.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "change_box.h" #include #include #include -#include "change_box.h" #include "atom.h" #include "modify.h" #include "fix.h" diff --git a/src/comm.cpp b/src/comm.cpp index 5f846cf292..53ec6b990c 100644 --- a/src/comm.cpp +++ b/src/comm.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "comm.h" #include #include #include -#include "comm.h" #include "universe.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/comm_brick.cpp b/src/comm_brick.cpp index dcf30807f5..928357d5be 100644 --- a/src/comm_brick.cpp +++ b/src/comm_brick.cpp @@ -15,10 +15,10 @@ Contributing author (triclinic) : Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "comm_brick.h" #include #include #include -#include "comm_brick.h" #include "atom.h" #include "atom_vec.h" #include "pair.h" diff --git a/src/comm_tiled.cpp b/src/comm_tiled.cpp index 385b7fdf22..e145f50f75 100644 --- a/src/comm_tiled.cpp +++ b/src/comm_tiled.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "comm_tiled.h" #include #include #include -#include "comm_tiled.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/compute.cpp b/src/compute.cpp index 8ff8487104..cc92d2b5d3 100644 --- a/src/compute.cpp +++ b/src/compute.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute.h" #include #include -#include "compute.h" #include "domain.h" #include "force.h" #include "group.h" diff --git a/src/compute_adf.cpp b/src/compute_adf.cpp index a17561ff54..dee5fb214f 100644 --- a/src/compute_adf.cpp +++ b/src/compute_adf.cpp @@ -15,10 +15,10 @@ Contributing authors: Aidan P. Thompson (SNL) ------------------------------------------------------------------------- */ +#include "compute_adf.h" #include #include #include -#include "compute_adf.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_aggregate_atom.cpp b/src/compute_aggregate_atom.cpp index 9a797124bd..e495ac6899 100644 --- a/src/compute_aggregate_atom.cpp +++ b/src/compute_aggregate_atom.cpp @@ -15,10 +15,10 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "compute_aggregate_atom.h" #include #include #include -#include "compute_aggregate_atom.h" #include "atom.h" #include "atom_vec.h" #include "update.h" diff --git a/src/compute_angle.cpp b/src/compute_angle.cpp index c1c02a1cc4..fc72a58453 100644 --- a/src/compute_angle.cpp +++ b/src/compute_angle.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_angle.h" +#include #include "angle.h" #include "update.h" #include "force.h" diff --git a/src/compute_angle_local.cpp b/src/compute_angle_local.cpp index 1196211665..b100824ea9 100644 --- a/src/compute_angle_local.cpp +++ b/src/compute_angle_local.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_angle_local.h" #include #include -#include "compute_angle_local.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/compute_angmom_chunk.cpp b/src/compute_angmom_chunk.cpp index ec42015527..05ea963b82 100644 --- a/src/compute_angmom_chunk.cpp +++ b/src/compute_angmom_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_angmom_chunk.h" #include #include -#include "compute_angmom_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_bond.cpp b/src/compute_bond.cpp index 4fd3bbef30..5cc947c764 100644 --- a/src/compute_bond.cpp +++ b/src/compute_bond.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_bond.h" +#include #include "bond.h" #include "update.h" #include "force.h" diff --git a/src/compute_bond_local.cpp b/src/compute_bond_local.cpp index ccdd3ee77c..d579772384 100644 --- a/src/compute_bond_local.cpp +++ b/src/compute_bond_local.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_bond_local.h" #include #include -#include "compute_bond_local.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/compute_centro_atom.cpp b/src/compute_centro_atom.cpp index 7df94271fc..18fc31390f 100644 --- a/src/compute_centro_atom.cpp +++ b/src/compute_centro_atom.cpp @@ -15,8 +15,8 @@ Contributing author: Michel Perez (U Lyon) for non-fcc lattices ------------------------------------------------------------------------- */ -#include #include "compute_centro_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_chunk_atom.cpp b/src/compute_chunk_atom.cpp index fd9204f1cb..92567101de 100644 --- a/src/compute_chunk_atom.cpp +++ b/src/compute_chunk_atom.cpp @@ -13,13 +13,13 @@ // NOTE: allow for bin center to be variables for sphere/cylinder +#include "compute_chunk_atom.h" #include #include #include #include #include #include -#include "compute_chunk_atom.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_chunk_spread_atom.cpp b/src/compute_chunk_spread_atom.cpp index 3d0cea1add..51dad00c25 100644 --- a/src/compute_chunk_spread_atom.cpp +++ b/src/compute_chunk_spread_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_chunk_spread_atom.h" #include #include -#include "compute_chunk_spread_atom.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_cluster_atom.cpp b/src/compute_cluster_atom.cpp index febe0658a0..ff227b3590 100644 --- a/src/compute_cluster_atom.cpp +++ b/src/compute_cluster_atom.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_cluster_atom.h" #include #include #include -#include "compute_cluster_atom.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_cna_atom.cpp b/src/compute_cna_atom.cpp index d764e739b3..054798f637 100644 --- a/src/compute_cna_atom.cpp +++ b/src/compute_cna_atom.cpp @@ -15,10 +15,10 @@ Contributing author: Wan Liang (Chinese Academy of Sciences) ------------------------------------------------------------------------- */ +#include "compute_cna_atom.h" #include #include #include -#include "compute_cna_atom.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_com_chunk.cpp b/src/compute_com_chunk.cpp index 7b4c960cf4..c39911214c 100644 --- a/src/compute_com_chunk.cpp +++ b/src/compute_com_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_com_chunk.h" #include #include -#include "compute_com_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_contact_atom.cpp b/src/compute_contact_atom.cpp index e4afc1d761..7a288afb43 100644 --- a/src/compute_contact_atom.cpp +++ b/src/compute_contact_atom.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_contact_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_coord_atom.cpp b/src/compute_coord_atom.cpp index 8cedcbc027..30747c1314 100644 --- a/src/compute_coord_atom.cpp +++ b/src/compute_coord_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_coord_atom.h" #include #include -#include "compute_coord_atom.h" #include "compute_orientorder_atom.h" #include "atom.h" #include "update.h" diff --git a/src/compute_deprecated.cpp b/src/compute_deprecated.cpp index 069fa73437..1db78b6bdf 100644 --- a/src/compute_deprecated.cpp +++ b/src/compute_deprecated.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_deprecated.h" +#include #include "comm.h" #include "error.h" diff --git a/src/compute_dihedral.cpp b/src/compute_dihedral.cpp index 16823050da..e50903104a 100644 --- a/src/compute_dihedral.cpp +++ b/src/compute_dihedral.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_dihedral.h" +#include #include "update.h" #include "force.h" #include "dihedral.h" diff --git a/src/compute_dihedral_local.cpp b/src/compute_dihedral_local.cpp index 784ae9c607..ac2c884c3f 100644 --- a/src/compute_dihedral_local.cpp +++ b/src/compute_dihedral_local.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_dihedral_local.h" #include #include -#include "compute_dihedral_local.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/compute_dipole_chunk.cpp b/src/compute_dipole_chunk.cpp index 090bc5df94..3790da2035 100644 --- a/src/compute_dipole_chunk.cpp +++ b/src/compute_dipole_chunk.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_dipole_chunk.h" #include #include #include -#include "compute_dipole_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_displace_atom.cpp b/src/compute_displace_atom.cpp index 3773159143..41db4db1d6 100644 --- a/src/compute_displace_atom.cpp +++ b/src/compute_displace_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_displace_atom.h" #include #include -#include "compute_displace_atom.h" #include "atom.h" #include "update.h" #include "group.h" diff --git a/src/compute_erotate_sphere.cpp b/src/compute_erotate_sphere.cpp index 65bb8a9770..2a8588f061 100644 --- a/src/compute_erotate_sphere.cpp +++ b/src/compute_erotate_sphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_erotate_sphere.h" +#include #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_erotate_sphere_atom.cpp b/src/compute_erotate_sphere_atom.cpp index 999bc062c5..78664a912f 100644 --- a/src/compute_erotate_sphere_atom.cpp +++ b/src/compute_erotate_sphere_atom.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_erotate_sphere_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_fragment_atom.cpp b/src/compute_fragment_atom.cpp index d59b519d09..f9b68dd217 100644 --- a/src/compute_fragment_atom.cpp +++ b/src/compute_fragment_atom.cpp @@ -15,9 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "compute_fragment_atom.h" #include #include -#include "compute_fragment_atom.h" #include "atom.h" #include "atom_vec.h" #include "update.h" diff --git a/src/compute_global_atom.cpp b/src/compute_global_atom.cpp index 6685f746a1..15f8a8f1aa 100644 --- a/src/compute_global_atom.cpp +++ b/src/compute_global_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_global_atom.h" #include #include -#include "compute_global_atom.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_group_group.cpp b/src/compute_group_group.cpp index 11e1aac720..f978b4a228 100644 --- a/src/compute_group_group.cpp +++ b/src/compute_group_group.cpp @@ -16,10 +16,10 @@ K-space terms added by Stan Moore (BYU) ------------------------------------------------------------------------- */ +#include "compute_group_group.h" #include #include #include -#include "compute_group_group.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_gyration.cpp b/src/compute_gyration.cpp index 3c5656a5af..2b1a26cc75 100644 --- a/src/compute_gyration.cpp +++ b/src/compute_gyration.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_gyration.h" +#include #include "update.h" #include "atom.h" #include "group.h" diff --git a/src/compute_gyration_chunk.cpp b/src/compute_gyration_chunk.cpp index f3db37d62f..5677ce4b6a 100644 --- a/src/compute_gyration_chunk.cpp +++ b/src/compute_gyration_chunk.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_gyration_chunk.h" #include #include #include -#include "compute_gyration_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_heat_flux.cpp b/src/compute_heat_flux.cpp index 9bd827c713..b717dce04a 100644 --- a/src/compute_heat_flux.cpp +++ b/src/compute_heat_flux.cpp @@ -16,9 +16,9 @@ Mario Pinto (Computational Research Lab, Pune, India) ------------------------------------------------------------------------- */ +#include "compute_heat_flux.h" #include #include -#include "compute_heat_flux.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_hexorder_atom.cpp b/src/compute_hexorder_atom.cpp index c54f4b1aae..96d4c47678 100644 --- a/src/compute_hexorder_atom.cpp +++ b/src/compute_hexorder_atom.cpp @@ -15,10 +15,10 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "compute_hexorder_atom.h" #include #include #include -#include "compute_hexorder_atom.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_improper.cpp b/src/compute_improper.cpp index 2f068dfb74..181771dcfb 100644 --- a/src/compute_improper.cpp +++ b/src/compute_improper.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_improper.h" +#include #include "update.h" #include "force.h" #include "improper.h" diff --git a/src/compute_improper_local.cpp b/src/compute_improper_local.cpp index ec1734cd96..e363749b67 100644 --- a/src/compute_improper_local.cpp +++ b/src/compute_improper_local.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_improper_local.h" #include #include -#include "compute_improper_local.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/compute_inertia_chunk.cpp b/src/compute_inertia_chunk.cpp index d1a7cb9fc1..be980a08ee 100644 --- a/src/compute_inertia_chunk.cpp +++ b/src/compute_inertia_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_inertia_chunk.h" #include #include -#include "compute_inertia_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_ke.cpp b/src/compute_ke.cpp index 3418cc678f..c6ba478dcb 100644 --- a/src/compute_ke.cpp +++ b/src/compute_ke.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_ke.h" +#include #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_ke_atom.cpp b/src/compute_ke_atom.cpp index c5506996da..102d6364ff 100644 --- a/src/compute_ke_atom.cpp +++ b/src/compute_ke_atom.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_ke_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_msd.cpp b/src/compute_msd.cpp index d2e17eff9e..b4115d859c 100644 --- a/src/compute_msd.cpp +++ b/src/compute_msd.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_msd.h" #include #include -#include "compute_msd.h" #include "atom.h" #include "update.h" #include "group.h" diff --git a/src/compute_msd_chunk.cpp b/src/compute_msd_chunk.cpp index 8520b36993..8039a4fcd5 100644 --- a/src/compute_msd_chunk.cpp +++ b/src/compute_msd_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_msd_chunk.h" #include #include -#include "compute_msd_chunk.h" #include "atom.h" #include "group.h" #include "update.h" diff --git a/src/compute_omega_chunk.cpp b/src/compute_omega_chunk.cpp index 360255e908..327c64493f 100644 --- a/src/compute_omega_chunk.cpp +++ b/src/compute_omega_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_omega_chunk.h" #include #include -#include "compute_omega_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_orientorder_atom.cpp b/src/compute_orientorder_atom.cpp index 8a0a525fdc..266df575f9 100644 --- a/src/compute_orientorder_atom.cpp +++ b/src/compute_orientorder_atom.cpp @@ -16,10 +16,10 @@ Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "compute_orientorder_atom.h" #include #include #include -#include "compute_orientorder_atom.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_pair.cpp b/src/compute_pair.cpp index df4f3a1ddb..e9a3faf723 100644 --- a/src/compute_pair.cpp +++ b/src/compute_pair.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_pair.h" #include #include #include -#include "compute_pair.h" #include "update.h" #include "force.h" #include "pair.h" diff --git a/src/compute_pair_local.cpp b/src/compute_pair_local.cpp index 1ab46a0297..2018d929f3 100644 --- a/src/compute_pair_local.cpp +++ b/src/compute_pair_local.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_pair_local.h" #include #include #include -#include "compute_pair_local.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_pe.cpp b/src/compute_pe.cpp index 5839ec2095..fd7b74b43a 100644 --- a/src/compute_pe.cpp +++ b/src/compute_pe.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_pe.h" #include #include -#include "compute_pe.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_pe_atom.cpp b/src/compute_pe_atom.cpp index b3ace2d419..274e1b05a6 100644 --- a/src/compute_pe_atom.cpp +++ b/src/compute_pe_atom.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_pe_atom.h" +#include #include "atom.h" #include "update.h" #include "comm.h" diff --git a/src/compute_pressure.cpp b/src/compute_pressure.cpp index 431f039de3..1782a040ae 100644 --- a/src/compute_pressure.cpp +++ b/src/compute_pressure.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_pressure.h" #include #include -#include "compute_pressure.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/compute_property_atom.cpp b/src/compute_property_atom.cpp index 0b57840696..065e3eeb82 100644 --- a/src/compute_property_atom.cpp +++ b/src/compute_property_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_property_atom.h" #include #include -#include "compute_property_atom.h" #include "math_extra.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/compute_property_chunk.cpp b/src/compute_property_chunk.cpp index 089e867598..579c7cae3f 100644 --- a/src/compute_property_chunk.cpp +++ b/src/compute_property_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_property_chunk.h" #include #include -#include "compute_property_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_property_local.cpp b/src/compute_property_local.cpp index ddcf5913ca..651e1190b1 100644 --- a/src/compute_property_local.cpp +++ b/src/compute_property_local.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_property_local.h" +#include #include "atom.h" #include "atom_vec.h" #include "update.h" diff --git a/src/compute_rdf.cpp b/src/compute_rdf.cpp index b1fa8bb2a3..501a506c98 100644 --- a/src/compute_rdf.cpp +++ b/src/compute_rdf.cpp @@ -15,10 +15,10 @@ Contributing authors: Paul Crozier (SNL), Jeff Greathouse (SNL) ------------------------------------------------------------------------- */ +#include "compute_rdf.h" #include #include #include -#include "compute_rdf.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_reduce.cpp b/src/compute_reduce.cpp index e7692b0797..8467554faa 100644 --- a/src/compute_reduce.cpp +++ b/src/compute_reduce.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_reduce.h" #include #include #include -#include "compute_reduce.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/compute_reduce_chunk.cpp b/src/compute_reduce_chunk.cpp index 5eda71b21b..3b68e20fcb 100644 --- a/src/compute_reduce_chunk.cpp +++ b/src/compute_reduce_chunk.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_reduce_chunk.h" #include #include #include -#include "compute_reduce_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_reduce_region.cpp b/src/compute_reduce_region.cpp index 30a5c6393f..9074124a61 100644 --- a/src/compute_reduce_region.cpp +++ b/src/compute_reduce_region.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_reduce_region.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_slice.cpp b/src/compute_slice.cpp index 6e509c24d4..67b60882f6 100644 --- a/src/compute_slice.cpp +++ b/src/compute_slice.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_slice.h" #include #include #include -#include "compute_slice.h" #include "update.h" #include "modify.h" #include "fix.h" diff --git a/src/compute_stress_atom.cpp b/src/compute_stress_atom.cpp index f84c977bdb..7c0ed9ef17 100644 --- a/src/compute_stress_atom.cpp +++ b/src/compute_stress_atom.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_stress_atom.h" +#include #include "atom.h" #include "update.h" #include "comm.h" diff --git a/src/compute_temp.cpp b/src/compute_temp.cpp index c330249a7e..e77531ee28 100644 --- a/src/compute_temp.cpp +++ b/src/compute_temp.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_temp.h" +#include #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_temp_chunk.cpp b/src/compute_temp_chunk.cpp index 229e98e258..e66aa64a27 100644 --- a/src/compute_temp_chunk.cpp +++ b/src/compute_temp_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_temp_chunk.h" #include #include -#include "compute_temp_chunk.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_temp_com.cpp b/src/compute_temp_com.cpp index 21814e1940..e5b9b3d828 100644 --- a/src/compute_temp_com.cpp +++ b/src/compute_temp_com.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_temp_com.h" +#include #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_temp_deform.cpp b/src/compute_temp_deform.cpp index 39780b5cf6..ff8909a5c7 100644 --- a/src/compute_temp_deform.cpp +++ b/src/compute_temp_deform.cpp @@ -15,9 +15,9 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "compute_temp_deform.h" #include #include -#include "compute_temp_deform.h" #include "domain.h" #include "atom.h" #include "update.h" diff --git a/src/compute_temp_partial.cpp b/src/compute_temp_partial.cpp index 8d5ff66796..6bffcef374 100644 --- a/src/compute_temp_partial.cpp +++ b/src/compute_temp_partial.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_temp_partial.h" +#include #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_temp_profile.cpp b/src/compute_temp_profile.cpp index 21c87b31a2..fce145848e 100644 --- a/src/compute_temp_profile.cpp +++ b/src/compute_temp_profile.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_temp_profile.h" #include #include -#include "compute_temp_profile.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_temp_ramp.cpp b/src/compute_temp_ramp.cpp index 715d2aa9f4..0899f89fd1 100644 --- a/src/compute_temp_ramp.cpp +++ b/src/compute_temp_ramp.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_temp_ramp.h" #include #include -#include "compute_temp_ramp.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_temp_region.cpp b/src/compute_temp_region.cpp index 4aa4dac0a1..a1b1b77648 100644 --- a/src/compute_temp_region.cpp +++ b/src/compute_temp_region.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_temp_region.h" #include #include -#include "compute_temp_region.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_temp_sphere.cpp b/src/compute_temp_sphere.cpp index b490a5ec45..d2bfe6db61 100644 --- a/src/compute_temp_sphere.cpp +++ b/src/compute_temp_sphere.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_temp_sphere.h" #include #include -#include "compute_temp_sphere.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/compute_torque_chunk.cpp b/src/compute_torque_chunk.cpp index e43155493f..35eef8fe10 100644 --- a/src/compute_torque_chunk.cpp +++ b/src/compute_torque_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_torque_chunk.h" #include #include -#include "compute_torque_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/compute_vacf.cpp b/src/compute_vacf.cpp index 787c2503ca..761f827347 100644 --- a/src/compute_vacf.cpp +++ b/src/compute_vacf.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_vacf.h" #include #include -#include "compute_vacf.h" #include "atom.h" #include "update.h" #include "group.h" diff --git a/src/compute_vcm_chunk.cpp b/src/compute_vcm_chunk.cpp index cf30130763..b0a8dbeee7 100644 --- a/src/compute_vcm_chunk.cpp +++ b/src/compute_vcm_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_vcm_chunk.h" #include #include -#include "compute_vcm_chunk.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/create_atoms.cpp b/src/create_atoms.cpp index 8504023a70..f6cff042fe 100644 --- a/src/create_atoms.cpp +++ b/src/create_atoms.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "create_atoms.h" #include #include -#include "create_atoms.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/create_bonds.cpp b/src/create_bonds.cpp index e00fe109ca..5b7c354595 100644 --- a/src/create_bonds.cpp +++ b/src/create_bonds.cpp @@ -15,9 +15,9 @@ Contributing authors: Mike Salerno (NRL) added single methods ------------------------------------------------------------------------- */ +#include "create_bonds.h" #include #include -#include "create_bonds.h" #include "atom.h" #include "domain.h" #include "force.h" diff --git a/src/create_box.cpp b/src/create_box.cpp index 5ec960bec4..4a826cb691 100644 --- a/src/create_box.cpp +++ b/src/create_box.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "create_box.h" +#include #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/delete_atoms.cpp b/src/delete_atoms.cpp index ff4b97a3a4..e8d9c5d53b 100644 --- a/src/delete_atoms.cpp +++ b/src/delete_atoms.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "delete_atoms.h" #include #include #include -#include "delete_atoms.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_ellipsoid.h" diff --git a/src/delete_bonds.cpp b/src/delete_bonds.cpp index c4d591543a..c450f77ee7 100644 --- a/src/delete_bonds.cpp +++ b/src/delete_bonds.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "delete_bonds.h" #include #include #include -#include "delete_bonds.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/deprecated.cpp b/src/deprecated.cpp index 66ddcfeff4..86af54fbfd 100644 --- a/src/deprecated.cpp +++ b/src/deprecated.cpp @@ -15,8 +15,8 @@ Contributing authors: Axel Kohlmeyer (Temple U), ------------------------------------------------------------------------- */ -#include #include "deprecated.h" +#include #include "comm.h" #include "error.h" #include "input.h" diff --git a/src/dihedral_deprecated.cpp b/src/dihedral_deprecated.cpp index 70888ca76d..0205b1b887 100644 --- a/src/dihedral_deprecated.cpp +++ b/src/dihedral_deprecated.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "dihedral_deprecated.h" +#include #include "dihedral_hybrid.h" #include "comm.h" #include "force.h" diff --git a/src/dihedral_hybrid.cpp b/src/dihedral_hybrid.cpp index 27fd7084bc..0863be955d 100644 --- a/src/dihedral_hybrid.cpp +++ b/src/dihedral_hybrid.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "dihedral_hybrid.h" #include #include #include -#include "dihedral_hybrid.h" #include "atom.h" #include "neighbor.h" #include "comm.h" diff --git a/src/dihedral_zero.cpp b/src/dihedral_zero.cpp index 0367477267..daf46fe79a 100644 --- a/src/dihedral_zero.cpp +++ b/src/dihedral_zero.cpp @@ -15,8 +15,8 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ -#include #include "dihedral_zero.h" +#include #include "atom.h" #include "force.h" #include "memory.h" diff --git a/src/displace_atoms.cpp b/src/displace_atoms.cpp index 8bae173a1d..dc94c3ed35 100644 --- a/src/displace_atoms.cpp +++ b/src/displace_atoms.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "displace_atoms.h" #include #include #include -#include "displace_atoms.h" #include "atom.h" #include "modify.h" #include "domain.h" diff --git a/src/domain.cpp b/src/domain.cpp index 197eff514a..372b264013 100644 --- a/src/domain.cpp +++ b/src/domain.cpp @@ -15,10 +15,10 @@ Contributing author (triclinic) : Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "domain.h" #include #include #include -#include "domain.h" #include "style_region.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/dump.cpp b/src/dump.cpp index b08a4de2ad..57a8decbb0 100644 --- a/src/dump.cpp +++ b/src/dump.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "dump.h" #include #include -#include "dump.h" #include "atom.h" #include "irregular.h" #include "update.h" diff --git a/src/dump_atom.cpp b/src/dump_atom.cpp index c95256ac21..e2e77cfb77 100644 --- a/src/dump_atom.cpp +++ b/src/dump_atom.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "dump_atom.h" +#include #include "domain.h" #include "atom.h" #include "update.h" diff --git a/src/dump_cfg.cpp b/src/dump_cfg.cpp index eb5329e0d1..3430720b8c 100644 --- a/src/dump_cfg.cpp +++ b/src/dump_cfg.cpp @@ -16,8 +16,8 @@ Memory efficiency improved by Ray Shan (Sandia) ------------------------------------------------------------------------- */ -#include #include "dump_cfg.h" +#include #include "atom.h" #include "domain.h" #include "memory.h" diff --git a/src/dump_custom.cpp b/src/dump_custom.cpp index 75e4e42bcd..ce83e442c9 100644 --- a/src/dump_custom.cpp +++ b/src/dump_custom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "dump_custom.h" #include #include -#include "dump_custom.h" #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/dump_dcd.cpp b/src/dump_dcd.cpp index ce669fecfd..254b371e22 100644 --- a/src/dump_dcd.cpp +++ b/src/dump_dcd.cpp @@ -16,10 +16,10 @@ Axel Kohlmeyer (Temple U), support for groups ------------------------------------------------------------------------- */ +#include "dump_dcd.h" #include #include #include -#include "dump_dcd.h" #include "domain.h" #include "atom.h" #include "update.h" diff --git a/src/dump_deprecated.cpp b/src/dump_deprecated.cpp index f0999f4276..4263b9801f 100644 --- a/src/dump_deprecated.cpp +++ b/src/dump_deprecated.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "dump_deprecated.h" +#include #include "comm.h" #include "error.h" diff --git a/src/dump_image.cpp b/src/dump_image.cpp index 0b4ca43879..7e6bc0c44c 100644 --- a/src/dump_image.cpp +++ b/src/dump_image.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "dump_image.h" #include #include #include #include -#include "dump_image.h" #include "image.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/dump_local.cpp b/src/dump_local.cpp index f99b7ac06c..9f021a7b6a 100644 --- a/src/dump_local.cpp +++ b/src/dump_local.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "dump_local.h" #include #include #include -#include "dump_local.h" #include "modify.h" #include "fix.h" #include "compute.h" diff --git a/src/dump_movie.cpp b/src/dump_movie.cpp index 37d8a37f4d..ea67320d4a 100644 --- a/src/dump_movie.cpp +++ b/src/dump_movie.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "dump_movie.h" +#include #include "comm.h" #include "force.h" #include "error.h" diff --git a/src/dump_xyz.cpp b/src/dump_xyz.cpp index 4d50cfc2c8..10ba10f995 100644 --- a/src/dump_xyz.cpp +++ b/src/dump_xyz.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "dump_xyz.h" +#include #include "atom.h" #include "error.h" #include "memory.h" diff --git a/src/error.cpp b/src/error.cpp index 8970145b7c..656c957ee2 100644 --- a/src/error.cpp +++ b/src/error.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "error.h" #include #include #include -#include "error.h" #include "universe.h" #include "output.h" #include "input.h" diff --git a/src/finish.cpp b/src/finish.cpp index 77c959b945..bef3ae89eb 100644 --- a/src/finish.cpp +++ b/src/finish.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "finish.h" #include #include #include #include -#include "finish.h" #include "timer.h" #include "universe.h" #include "accelerator_kokkos.h" diff --git a/src/fix.cpp b/src/fix.cpp index 1913ed483e..e0cfeca1a9 100644 --- a/src/fix.cpp +++ b/src/fix.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix.h" #include #include -#include "fix.h" #include "atom.h" #include "group.h" #include "force.h" diff --git a/src/fix_adapt.cpp b/src/fix_adapt.cpp index 7ac6128558..8668690e1d 100644 --- a/src/fix_adapt.cpp +++ b/src/fix_adapt.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_adapt.h" +#include #include "atom.h" #include "bond.h" #include "update.h" diff --git a/src/fix_addforce.cpp b/src/fix_addforce.cpp index e29c4ffe9f..275ec2c846 100644 --- a/src/fix_addforce.cpp +++ b/src/fix_addforce.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_addforce.h" #include #include #include -#include "fix_addforce.h" #include "atom.h" #include "atom_masks.h" #include "update.h" diff --git a/src/fix_ave_atom.cpp b/src/fix_ave_atom.cpp index e6566632de..694df2bcf7 100644 --- a/src/fix_ave_atom.cpp +++ b/src/fix_ave_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_ave_atom.h" #include #include -#include "fix_ave_atom.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/fix_ave_chunk.cpp b/src/fix_ave_chunk.cpp index 1533d1fa4f..45eb38f5c2 100644 --- a/src/fix_ave_chunk.cpp +++ b/src/fix_ave_chunk.cpp @@ -11,12 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_ave_chunk.h" #include -#include // IWYU pragma: keep #include #include #include -#include "fix_ave_chunk.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/fix_ave_correlate.cpp b/src/fix_ave_correlate.cpp index 555c1ac026..f65b53efc8 100644 --- a/src/fix_ave_correlate.cpp +++ b/src/fix_ave_correlate.cpp @@ -17,12 +17,11 @@ Reese Jones (Sandia) ------------------------------------------------------------------------- */ +#include "fix_ave_correlate.h" #include -#include // IWYU pragma: keep #include #include #include -#include "fix_ave_correlate.h" #include "update.h" #include "modify.h" #include "compute.h" diff --git a/src/fix_ave_histo.cpp b/src/fix_ave_histo.cpp index 29fdc21c74..5a5de6d0b6 100644 --- a/src/fix_ave_histo.cpp +++ b/src/fix_ave_histo.cpp @@ -11,12 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_ave_histo.h" #include -#include // IWYU pragma: keep #include #include #include -#include "fix_ave_histo.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/fix_ave_histo_weight.cpp b/src/fix_ave_histo_weight.cpp index 5eeb074472..1f0d282e5d 100644 --- a/src/fix_ave_histo_weight.cpp +++ b/src/fix_ave_histo_weight.cpp @@ -14,11 +14,10 @@ /* ---------------------------------------------------------------------- Contributing author: Shawn Coleman (ARL) ------------------------------------------------------------------------- */ +#include "fix_ave_histo_weight.h" #include -#include // IWYU pragma: keep #include #include "fix.h" -#include "fix_ave_histo_weight.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/fix_ave_time.cpp b/src/fix_ave_time.cpp index 4820215f46..05d556d0c8 100644 --- a/src/fix_ave_time.cpp +++ b/src/fix_ave_time.cpp @@ -15,12 +15,11 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "fix_ave_time.h" #include -#include // IWYU pragma: keep #include #include #include -#include "fix_ave_time.h" #include "update.h" #include "force.h" #include "modify.h" diff --git a/src/fix_aveforce.cpp b/src/fix_aveforce.cpp index 4791a8b022..8ad07780a9 100644 --- a/src/fix_aveforce.cpp +++ b/src/fix_aveforce.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_aveforce.h" #include #include -#include "fix_aveforce.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/fix_balance.cpp b/src/fix_balance.cpp index f9c32e8df0..5ca1ec124a 100644 --- a/src/fix_balance.cpp +++ b/src/fix_balance.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_balance.h" +#include #include "balance.h" #include "update.h" #include "atom.h" diff --git a/src/fix_box_relax.cpp b/src/fix_box_relax.cpp index c73c0ade88..c19ea918b4 100644 --- a/src/fix_box_relax.cpp +++ b/src/fix_box_relax.cpp @@ -15,9 +15,9 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "fix_box_relax.h" #include #include -#include "fix_box_relax.h" #include "atom.h" #include "domain.h" #include "update.h" diff --git a/src/fix_controller.cpp b/src/fix_controller.cpp index eb7a794962..855869a574 100644 --- a/src/fix_controller.cpp +++ b/src/fix_controller.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_controller.h" #include #include -#include "fix_controller.h" #include "force.h" #include "update.h" #include "modify.h" diff --git a/src/fix_deform.cpp b/src/fix_deform.cpp index 96d7580c39..9d84c4bb62 100644 --- a/src/fix_deform.cpp +++ b/src/fix_deform.cpp @@ -15,9 +15,9 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "fix_deform.h" #include #include -#include "fix_deform.h" #include "atom.h" #include "update.h" #include "comm.h" diff --git a/src/fix_deprecated.cpp b/src/fix_deprecated.cpp index 7db27152ba..0c212668b3 100644 --- a/src/fix_deprecated.cpp +++ b/src/fix_deprecated.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_deprecated.h" +#include #include "comm.h" #include "error.h" diff --git a/src/fix_drag.cpp b/src/fix_drag.cpp index 006d1c46d0..9af5a37675 100644 --- a/src/fix_drag.cpp +++ b/src/fix_drag.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_drag.h" #include #include #include -#include "fix_drag.h" #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/fix_dt_reset.cpp b/src/fix_dt_reset.cpp index 4e6195c4fa..da4bdad827 100644 --- a/src/fix_dt_reset.cpp +++ b/src/fix_dt_reset.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_dt_reset.h" #include #include #include -#include "fix_dt_reset.h" #include "atom.h" #include "update.h" #include "integrate.h" diff --git a/src/fix_enforce2d.cpp b/src/fix_enforce2d.cpp index 986ded5d16..3edd24e9af 100644 --- a/src/fix_enforce2d.cpp +++ b/src/fix_enforce2d.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_enforce2d.h" +#include #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/fix_external.cpp b/src/fix_external.cpp index 2c926e26b5..afb420df93 100644 --- a/src/fix_external.cpp +++ b/src/fix_external.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_external.h" +#include #include "atom.h" #include "update.h" #include "memory.h" diff --git a/src/fix_gravity.cpp b/src/fix_gravity.cpp index 8508a92cc4..14ba913c01 100644 --- a/src/fix_gravity.cpp +++ b/src/fix_gravity.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_gravity.h" #include #include #include -#include "fix_gravity.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/fix_group.cpp b/src/fix_group.cpp index 8a332bed95..d2eea9f781 100644 --- a/src/fix_group.cpp +++ b/src/fix_group.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_group.h" +#include #include "group.h" #include "update.h" #include "atom.h" diff --git a/src/fix_halt.cpp b/src/fix_halt.cpp index 133494fb8e..8ebb39f0e9 100644 --- a/src/fix_halt.cpp +++ b/src/fix_halt.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_halt.h" #include #include #include -#include "fix_halt.h" #include "update.h" #include "force.h" #include "input.h" diff --git a/src/fix_heat.cpp b/src/fix_heat.cpp index f78a9c0860..67d445df92 100644 --- a/src/fix_heat.cpp +++ b/src/fix_heat.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "fix_heat.h" #include #include #include -#include "fix_heat.h" #include "atom.h" #include "domain.h" #include "region.h" diff --git a/src/fix_indent.cpp b/src/fix_indent.cpp index 6a42cadefd..04837ff39b 100644 --- a/src/fix_indent.cpp +++ b/src/fix_indent.cpp @@ -15,10 +15,10 @@ Contributing author: Ravi Agrawal (Northwestern U) ------------------------------------------------------------------------- */ +#include "fix_indent.h" #include #include #include -#include "fix_indent.h" #include "atom.h" #include "input.h" #include "variable.h" diff --git a/src/fix_langevin.cpp b/src/fix_langevin.cpp index 0f48562048..f8fea76c94 100644 --- a/src/fix_langevin.cpp +++ b/src/fix_langevin.cpp @@ -16,10 +16,10 @@ Aidan Thompson (SNL) GJF formulation ------------------------------------------------------------------------- */ +#include "fix_langevin.h" #include #include #include -#include "fix_langevin.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/fix_lineforce.cpp b/src/fix_lineforce.cpp index 61c6341aa6..c153ee65dd 100644 --- a/src/fix_lineforce.cpp +++ b/src/fix_lineforce.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_lineforce.h" #include #include -#include "fix_lineforce.h" #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/fix_momentum.cpp b/src/fix_momentum.cpp index bf94a94362..a363cb8eac 100644 --- a/src/fix_momentum.cpp +++ b/src/fix_momentum.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_momentum.h" #include #include #include -#include "fix_momentum.h" #include "atom.h" #include "domain.h" #include "group.h" diff --git a/src/fix_move.cpp b/src/fix_move.cpp index 646f943ef9..770c0fca6b 100644 --- a/src/fix_move.cpp +++ b/src/fix_move.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_move.h" #include #include -#include "fix_move.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/fix_neigh_history.cpp b/src/fix_neigh_history.cpp index ca593f29df..5c740ae649 100644 --- a/src/fix_neigh_history.cpp +++ b/src/fix_neigh_history.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_neigh_history.h" #include #include -#include "fix_neigh_history.h" #include "my_page.h" #include "atom.h" #include "comm.h" diff --git a/src/fix_nh.cpp b/src/fix_nh.cpp index 3ffdff54cf..bb3fe7559c 100644 --- a/src/fix_nh.cpp +++ b/src/fix_nh.cpp @@ -15,9 +15,9 @@ Contributing authors: Mark Stevens (SNL), Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "fix_nh.h" #include #include -#include "fix_nh.h" #include "atom.h" #include "force.h" #include "group.h" diff --git a/src/fix_nh_sphere.cpp b/src/fix_nh_sphere.cpp index 0f1024700a..1ff3fc2d4d 100644 --- a/src/fix_nh_sphere.cpp +++ b/src/fix_nh_sphere.cpp @@ -15,9 +15,9 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "fix_nh_sphere.h" #include #include -#include "fix_nh_sphere.h" #include "atom.h" #include "atom_vec.h" #include "error.h" diff --git a/src/fix_nph.cpp b/src/fix_nph.cpp index 40265ef57c..7148b024de 100644 --- a/src/fix_nph.cpp +++ b/src/fix_nph.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nph.h" +#include #include "modify.h" #include "error.h" diff --git a/src/fix_nph_sphere.cpp b/src/fix_nph_sphere.cpp index 3fcbe5e9c6..f64f144f34 100644 --- a/src/fix_nph_sphere.cpp +++ b/src/fix_nph_sphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nph_sphere.h" +#include #include "modify.h" #include "error.h" diff --git a/src/fix_npt.cpp b/src/fix_npt.cpp index d17577d68d..e856fafe2d 100644 --- a/src/fix_npt.cpp +++ b/src/fix_npt.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_npt.h" +#include #include "modify.h" #include "error.h" diff --git a/src/fix_npt_sphere.cpp b/src/fix_npt_sphere.cpp index 50ac990daf..9cbb17b0ca 100644 --- a/src/fix_npt_sphere.cpp +++ b/src/fix_npt_sphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_npt_sphere.h" +#include #include "modify.h" #include "error.h" diff --git a/src/fix_nve.cpp b/src/fix_nve.cpp index 3396f3ca47..863ce5404d 100644 --- a/src/fix_nve.cpp +++ b/src/fix_nve.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nve.h" +#include #include "atom.h" #include "force.h" #include "update.h" diff --git a/src/fix_nve_limit.cpp b/src/fix_nve_limit.cpp index 49bed2e3dd..d63c736e73 100644 --- a/src/fix_nve_limit.cpp +++ b/src/fix_nve_limit.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nve_limit.h" #include #include #include -#include "fix_nve_limit.h" #include "atom.h" #include "force.h" #include "update.h" diff --git a/src/fix_nve_noforce.cpp b/src/fix_nve_noforce.cpp index 7b61aac18e..022e8abe74 100644 --- a/src/fix_nve_noforce.cpp +++ b/src/fix_nve_noforce.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nve_noforce.h" +#include #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/fix_nve_sphere.cpp b/src/fix_nve_sphere.cpp index 94e8aa88ac..c0fea17c2b 100644 --- a/src/fix_nve_sphere.cpp +++ b/src/fix_nve_sphere.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nve_sphere.h" #include #include -#include "fix_nve_sphere.h" #include "atom.h" #include "domain.h" #include "atom_vec.h" diff --git a/src/fix_nvt.cpp b/src/fix_nvt.cpp index 7247612dd4..6f0d4c6c50 100644 --- a/src/fix_nvt.cpp +++ b/src/fix_nvt.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nvt.h" +#include #include "group.h" #include "modify.h" #include "error.h" diff --git a/src/fix_nvt_sllod.cpp b/src/fix_nvt_sllod.cpp index 16e2fb1d3d..138794862a 100644 --- a/src/fix_nvt_sllod.cpp +++ b/src/fix_nvt_sllod.cpp @@ -15,8 +15,8 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ -#include #include "fix_nvt_sllod.h" +#include #include "math_extra.h" #include "atom.h" #include "domain.h" diff --git a/src/fix_nvt_sphere.cpp b/src/fix_nvt_sphere.cpp index 44046699ba..fed3799011 100644 --- a/src/fix_nvt_sphere.cpp +++ b/src/fix_nvt_sphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nvt_sphere.h" +#include #include "group.h" #include "modify.h" #include "error.h" diff --git a/src/fix_planeforce.cpp b/src/fix_planeforce.cpp index a83d00a506..a3f27277bd 100644 --- a/src/fix_planeforce.cpp +++ b/src/fix_planeforce.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_planeforce.h" #include #include -#include "fix_planeforce.h" #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/fix_press_berendsen.cpp b/src/fix_press_berendsen.cpp index ad3e3d1e1c..c090c554e2 100644 --- a/src/fix_press_berendsen.cpp +++ b/src/fix_press_berendsen.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_press_berendsen.h" #include #include -#include "fix_press_berendsen.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/fix_print.cpp b/src/fix_print.cpp index da2e2b54f3..dc76fc39f9 100644 --- a/src/fix_print.cpp +++ b/src/fix_print.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_print.h" #include #include -#include "fix_print.h" #include "update.h" #include "input.h" #include "modify.h" diff --git a/src/fix_property_atom.cpp b/src/fix_property_atom.cpp index 62c3ec985b..555114e4f9 100644 --- a/src/fix_property_atom.cpp +++ b/src/fix_property_atom.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_property_atom.h" #include #include -#include "fix_property_atom.h" #include "atom.h" #include "comm.h" #include "memory.h" diff --git a/src/fix_recenter.cpp b/src/fix_recenter.cpp index cd50d7dc34..f461e0fa52 100644 --- a/src/fix_recenter.cpp +++ b/src/fix_recenter.cpp @@ -15,9 +15,9 @@ Contributing author: Naveen Michaud-Agrawal (Johns Hopkins U) ------------------------------------------------------------------------- */ +#include "fix_recenter.h" #include #include -#include "fix_recenter.h" #include "atom.h" #include "group.h" #include "update.h" diff --git a/src/fix_respa.cpp b/src/fix_respa.cpp index ea2eb5050a..742dd5c58b 100644 --- a/src/fix_respa.cpp +++ b/src/fix_respa.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_respa.h" +#include #include "atom.h" #include "force.h" #include "memory.h" diff --git a/src/fix_restrain.cpp b/src/fix_restrain.cpp index 3b9980d567..5a0d4fb662 100644 --- a/src/fix_restrain.cpp +++ b/src/fix_restrain.cpp @@ -16,10 +16,10 @@ support for bond and angle restraints by Andres Jaramillo-Botero (Caltech) ------------------------------------------------------------------------- */ +#include "fix_restrain.h" #include #include #include -#include "fix_restrain.h" #include "atom.h" #include "force.h" #include "update.h" diff --git a/src/fix_setforce.cpp b/src/fix_setforce.cpp index f01008dc10..77c4bfbddc 100644 --- a/src/fix_setforce.cpp +++ b/src/fix_setforce.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_setforce.h" #include #include -#include "fix_setforce.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/fix_spring.cpp b/src/fix_spring.cpp index c87cec2766..510b194ab7 100644 --- a/src/fix_spring.cpp +++ b/src/fix_spring.cpp @@ -15,9 +15,9 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "fix_spring.h" #include #include -#include "fix_spring.h" #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/fix_spring_chunk.cpp b/src/fix_spring_chunk.cpp index f6ebadde94..e14936a976 100644 --- a/src/fix_spring_chunk.cpp +++ b/src/fix_spring_chunk.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_spring_chunk.h" #include #include -#include "fix_spring_chunk.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/fix_spring_rg.cpp b/src/fix_spring_rg.cpp index 1d5b87c599..f1e68bffa4 100644 --- a/src/fix_spring_rg.cpp +++ b/src/fix_spring_rg.cpp @@ -16,8 +16,8 @@ Paul Crozier (SNL) ------------------------------------------------------------------------- */ -#include #include "fix_spring_rg.h" +#include #include "atom.h" #include "update.h" #include "group.h" diff --git a/src/fix_spring_self.cpp b/src/fix_spring_self.cpp index a5aa600229..c94f21b492 100644 --- a/src/fix_spring_self.cpp +++ b/src/fix_spring_self.cpp @@ -15,9 +15,9 @@ Contributing author: Naveen Michaud-Agrawal (Johns Hopkins University) ------------------------------------------------------------------------- */ +#include "fix_spring_self.h" #include #include -#include "fix_spring_self.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/fix_store.cpp b/src/fix_store.cpp index a370632489..94c62c1850 100644 --- a/src/fix_store.cpp +++ b/src/fix_store.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_store.h" +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/fix_store_force.cpp b/src/fix_store_force.cpp index 8afd985615..5c25f0e162 100644 --- a/src/fix_store_force.cpp +++ b/src/fix_store_force.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_store_force.h" +#include #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/fix_store_state.cpp b/src/fix_store_state.cpp index da899a173c..18dfa026d9 100644 --- a/src/fix_store_state.cpp +++ b/src/fix_store_state.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_store_state.h" #include #include -#include "fix_store_state.h" #include "atom.h" #include "domain.h" #include "update.h" diff --git a/src/fix_temp_berendsen.cpp b/src/fix_temp_berendsen.cpp index b4dd65b0c5..be8922be4e 100644 --- a/src/fix_temp_berendsen.cpp +++ b/src/fix_temp_berendsen.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_temp_berendsen.h" #include #include -#include "fix_temp_berendsen.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/fix_temp_csld.cpp b/src/fix_temp_csld.cpp index 57f7104c61..f827c88f51 100644 --- a/src/fix_temp_csld.cpp +++ b/src/fix_temp_csld.cpp @@ -15,9 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_temp_csld.h" #include #include -#include "fix_temp_csld.h" #include "atom.h" #include "force.h" #include "memory.h" diff --git a/src/fix_temp_csvr.cpp b/src/fix_temp_csvr.cpp index 9f8135ffc8..55cbb60407 100644 --- a/src/fix_temp_csvr.cpp +++ b/src/fix_temp_csvr.cpp @@ -16,10 +16,10 @@ Based on code by Paolo Raiteri (Curtin U) and Giovanni Bussi (SISSA) ------------------------------------------------------------------------- */ +#include "fix_temp_csvr.h" #include #include #include -#include "fix_temp_csvr.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/fix_temp_rescale.cpp b/src/fix_temp_rescale.cpp index 378997c0c4..a9d605d5ba 100644 --- a/src/fix_temp_rescale.cpp +++ b/src/fix_temp_rescale.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_temp_rescale.h" #include #include -#include "fix_temp_rescale.h" #include "atom.h" #include "force.h" #include "group.h" diff --git a/src/fix_tmd.cpp b/src/fix_tmd.cpp index a0425db36c..ec8cdb859c 100644 --- a/src/fix_tmd.cpp +++ b/src/fix_tmd.cpp @@ -16,10 +16,10 @@ Christian Burisch (Bochum Univeristy, Germany) ------------------------------------------------------------------------- */ +#include "fix_tmd.h" #include #include #include -#include "fix_tmd.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/fix_vector.cpp b/src/fix_vector.cpp index b7be472be6..53093acbf6 100644 --- a/src/fix_vector.cpp +++ b/src/fix_vector.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_vector.h" #include #include -#include "fix_vector.h" #include "update.h" #include "force.h" #include "modify.h" diff --git a/src/fix_viscous.cpp b/src/fix_viscous.cpp index cc60b1bda4..bdd1e19976 100644 --- a/src/fix_viscous.cpp +++ b/src/fix_viscous.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_viscous.h" +#include #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/fix_wall.cpp b/src/fix_wall.cpp index 1046efc2df..8ceafb4bfc 100644 --- a/src/fix_wall.cpp +++ b/src/fix_wall.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_wall.h" #include #include -#include "fix_wall.h" #include "input.h" #include "variable.h" #include "domain.h" diff --git a/src/fix_wall_lj1043.cpp b/src/fix_wall_lj1043.cpp index a93f4dd699..5656cf113d 100644 --- a/src/fix_wall_lj1043.cpp +++ b/src/fix_wall_lj1043.cpp @@ -15,8 +15,8 @@ Contributing author: Jonathan Lee (Sandia) ------------------------------------------------------------------------- */ -#include #include "fix_wall_lj1043.h" +#include #include "atom.h" #include "math_const.h" diff --git a/src/fix_wall_lj126.cpp b/src/fix_wall_lj126.cpp index 369ef78c97..e748e2ef13 100644 --- a/src/fix_wall_lj126.cpp +++ b/src/fix_wall_lj126.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_wall_lj126.h" +#include #include "atom.h" #include "error.h" diff --git a/src/fix_wall_lj93.cpp b/src/fix_wall_lj93.cpp index ce5a06c81b..c0e81b60ee 100644 --- a/src/fix_wall_lj93.cpp +++ b/src/fix_wall_lj93.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_wall_lj93.h" +#include #include "atom.h" #include "error.h" diff --git a/src/fix_wall_reflect.cpp b/src/fix_wall_reflect.cpp index edf5c40a5f..bc3414d650 100644 --- a/src/fix_wall_reflect.cpp +++ b/src/fix_wall_reflect.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_wall_reflect.h" +#include #include "atom.h" #include "comm.h" #include "update.h" diff --git a/src/fix_wall_region.cpp b/src/fix_wall_region.cpp index cb1c3c2ab2..c1a689d90a 100644 --- a/src/fix_wall_region.cpp +++ b/src/fix_wall_region.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_wall_region.h" #include #include #include -#include "fix_wall_region.h" #include "atom.h" #include "domain.h" #include "region.h" diff --git a/src/force.cpp b/src/force.cpp index e4939a10e8..1a826b2843 100644 --- a/src/force.cpp +++ b/src/force.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "force.h" #include #include #include -#include "force.h" #include "style_bond.h" #include "style_angle.h" #include "style_dihedral.h" diff --git a/src/group.cpp b/src/group.cpp index a37d209947..d119964ea1 100644 --- a/src/group.cpp +++ b/src/group.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "group.h" #include #include #include #include -#include "group.h" #include "domain.h" #include "atom.h" #include "force.h" diff --git a/src/hashlittle.cpp b/src/hashlittle.cpp index e9340a7e55..c3824b71fe 100644 --- a/src/hashlittle.cpp +++ b/src/hashlittle.cpp @@ -2,8 +2,7 @@ // from lookup3.c, by Bob Jenkins, May 2006, Public Domain // bob_jenkins@burtleburtle.net -#include -#include +#include "hashlittle.h" // if the system defines the __BYTE_ORDER__ define, // we use it instead of guessing the platform @@ -141,7 +140,7 @@ acceptable. Do NOT use for cryptographic purposes. ------------------------------------------------------------------------------- */ -uint32_t hashlittle( const void *key, size_t length, uint32_t initval) +uint32_t LAMMPS_NS::hashlittle(const void *key, size_t length, uint32_t initval) { #ifndef PURIFY_HATES_HASHLITTLE diff --git a/src/hashlittle.h b/src/hashlittle.h index 7b57a35c80..75380d366b 100644 --- a/src/hashlittle.h +++ b/src/hashlittle.h @@ -2,4 +2,13 @@ // from lookup3.c, by Bob Jenkins, May 2006, Public Domain // bob_jenkins@burtleburtle.net -uint32_t hashlittle(const void *key, size_t length, uint32_t); +#ifndef LMP_HASHLITTLE_H +#define LMP_HASHLITTLE_H + +#include +#include + +namespace LAMMPS_NS { + uint32_t hashlittle(const void *key, size_t length, uint32_t); +} +#endif diff --git a/src/image.cpp b/src/image.cpp index ccd6d98d87..4a5009b8ed 100644 --- a/src/image.cpp +++ b/src/image.cpp @@ -15,11 +15,11 @@ Contributing author: Nathan Fabian (Sandia) ------------------------------------------------------------------------- */ +#include "image.h" #include #include #include #include -#include "image.h" #include "math_extra.h" #include "random_mars.h" #include "math_const.h" diff --git a/src/output.cpp b/src/output.cpp index fb2f9a700d..be6f66b7aa 100644 --- a/src/output.cpp +++ b/src/output.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include #include "output.h" #include "style_dump.h" diff --git a/src/pair_lj_cut_coul_cut.cpp b/src/pair_lj_cut_coul_cut.cpp index 38a6e2c431..9ffa02156e 100644 --- a/src/pair_lj_cut_coul_cut.cpp +++ b/src/pair_lj_cut_coul_cut.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include -#include #include #include "pair_lj_cut_coul_cut.h" #include "atom.h" diff --git a/src/pair_lj_cut_coul_debye.cpp b/src/pair_lj_cut_coul_debye.cpp index cc6e92b2e3..ab6220bd24 100644 --- a/src/pair_lj_cut_coul_debye.cpp +++ b/src/pair_lj_cut_coul_debye.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include #include -#include #include "pair_lj_cut_coul_debye.h" #include "atom.h" #include "neigh_list.h" diff --git a/src/pair_lj_cut_coul_dsf.cpp b/src/pair_lj_cut_coul_dsf.cpp index f114a5851f..778f9f2fb4 100644 --- a/src/pair_lj_cut_coul_dsf.cpp +++ b/src/pair_lj_cut_coul_dsf.cpp @@ -16,11 +16,10 @@ References: Fennell and Gezelter, JCP 124, 234104 (2006) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_cut_coul_dsf.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pointers.h b/src/pointers.h index 1af07d5158..2d528db392 100644 --- a/src/pointers.h +++ b/src/pointers.h @@ -22,7 +22,7 @@ #define LMP_POINTERS_H #include "lmptype.h" // IWYU pragma: export -#include +#include // IWYU pragma: export #include // IWYU pragme: export #include // IWYU pragma: export #include "lammps.h" // IWYU pragma: export From 256531a29a31d2f80f860504d0653c4013794338 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 3 Jul 2019 19:34:13 -0400 Subject: [PATCH 32/79] put implementation header first for all remaining main folder source files --- src/imbalance_neigh.cpp | 2 +- src/imbalance_store.cpp | 2 +- src/imbalance_time.cpp | 2 +- src/imbalance_var.cpp | 2 +- src/improper_deprecated.cpp | 2 +- src/improper_hybrid.cpp | 2 +- src/improper_zero.cpp | 2 +- src/info.cpp | 2 +- src/input.cpp | 2 +- src/irregular.cpp | 2 +- src/kspace.cpp | 2 +- src/kspace_deprecated.cpp | 2 +- src/lammps.cpp | 2 +- src/lattice.cpp | 2 +- src/library.cpp | 2 +- src/main.cpp | 2 +- src/math_extra.cpp | 2 +- src/math_special.cpp | 2 +- src/memory.cpp | 2 +- src/min.cpp | 2 +- src/min_cg.cpp | 2 +- src/min_fire.cpp | 2 +- src/min_hftn.cpp | 2 +- src/min_linesearch.cpp | 2 +- src/min_quickmin.cpp | 2 +- src/min_sd.cpp | 2 +- src/modify.cpp | 2 +- src/molecule.cpp | 2 +- src/nbin.cpp | 2 +- src/neighbor.cpp | 2 +- src/npair.cpp | 2 +- src/ntopo.cpp | 2 +- src/ntopo_angle_all.cpp | 2 +- src/ntopo_angle_partial.cpp | 2 +- src/ntopo_angle_template.cpp | 2 +- src/ntopo_bond_all.cpp | 2 +- src/ntopo_bond_partial.cpp | 2 +- src/ntopo_bond_template.cpp | 2 +- src/ntopo_dihedral_all.cpp | 2 +- src/ntopo_dihedral_partial.cpp | 2 +- src/ntopo_dihedral_template.cpp | 2 +- src/ntopo_improper_all.cpp | 2 +- src/ntopo_improper_partial.cpp | 2 +- src/ntopo_improper_template.cpp | 2 +- src/output.cpp | 2 +- src/pair.cpp | 2 +- src/pair_beck.cpp | 2 +- src/pair_born.cpp | 2 +- src/pair_born_coul_dsf.cpp | 2 +- src/pair_born_coul_wolf.cpp | 2 +- src/pair_buck.cpp | 2 +- src/pair_buck_coul_cut.cpp | 2 +- src/pair_coul_cut.cpp | 2 +- src/pair_coul_debye.cpp | 2 +- src/pair_coul_dsf.cpp | 2 +- src/pair_coul_streitz.cpp | 2 +- src/pair_coul_wolf.cpp | 2 +- src/pair_deprecated.cpp | 2 +- src/pair_dpd.cpp | 2 +- src/pair_dpd_tstat.cpp | 2 +- src/pair_gauss.cpp | 2 +- src/pair_hybrid.cpp | 2 +- src/pair_hybrid_overlay.cpp | 2 +- src/pair_lj96_cut.cpp | 2 +- src/pair_lj_cubic.cpp | 2 +- src/pair_lj_cut.cpp | 2 +- src/pair_lj_cut_coul_cut.cpp | 2 +- src/pair_lj_cut_coul_debye.cpp | 2 +- src/pair_lj_cut_coul_wolf.cpp | 2 +- src/pair_lj_expand.cpp | 2 +- src/pair_lj_gromacs.cpp | 2 +- src/pair_lj_gromacs_coul_gromacs.cpp | 2 +- src/pair_lj_smooth.cpp | 2 +- src/pair_lj_smooth_linear.cpp | 2 +- src/pair_mie_cut.cpp | 2 +- src/pair_morse.cpp | 2 +- src/pair_soft.cpp | 2 +- src/pair_table.cpp | 2 +- src/pair_ufm.cpp | 2 +- src/pair_yukawa.cpp | 2 +- src/pair_zbl.cpp | 2 +- src/pair_zero.cpp | 2 +- src/procmap.cpp | 2 +- src/random_mars.cpp | 2 +- src/random_park.cpp | 2 +- src/rcb.cpp | 2 +- src/read_data.cpp | 2 +- src/read_dump.cpp | 2 +- src/read_restart.cpp | 2 +- src/reader.cpp | 2 +- src/reader_native.cpp | 2 +- src/reader_xyz.cpp | 2 +- src/region.cpp | 2 +- src/region_block.cpp | 2 +- src/region_cone.cpp | 2 +- src/region_cylinder.cpp | 2 +- src/region_deprecated.cpp | 2 +- src/region_intersect.cpp | 2 +- src/region_plane.cpp | 2 +- src/region_prism.cpp | 2 +- src/region_sphere.cpp | 2 +- src/region_union.cpp | 2 +- src/replicate.cpp | 2 +- src/rerun.cpp | 2 +- src/reset_ids.cpp | 2 +- src/respa.cpp | 2 +- src/run.cpp | 2 +- src/set.cpp | 2 +- src/special.cpp | 2 +- src/thermo.cpp | 2 +- src/timer.cpp | 2 +- src/universe.cpp | 2 +- src/update.cpp | 2 +- src/utils.cpp | 2 +- src/variable.cpp | 2 +- src/velocity.cpp | 2 +- src/verlet.cpp | 2 +- src/write_coeff.cpp | 2 +- src/write_data.cpp | 2 +- src/write_dump.cpp | 2 +- src/write_restart.cpp | 2 +- 121 files changed, 121 insertions(+), 121 deletions(-) diff --git a/src/imbalance_neigh.cpp b/src/imbalance_neigh.cpp index 2a55754da8..19f3915a11 100644 --- a/src/imbalance_neigh.cpp +++ b/src/imbalance_neigh.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "imbalance_neigh.h" +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/imbalance_store.cpp b/src/imbalance_store.cpp index c117b60860..343d47b189 100644 --- a/src/imbalance_store.cpp +++ b/src/imbalance_store.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "imbalance_store.h" +#include #include "atom.h" #include "error.h" diff --git a/src/imbalance_time.cpp b/src/imbalance_time.cpp index ceb3c08220..0831713204 100644 --- a/src/imbalance_time.cpp +++ b/src/imbalance_time.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "imbalance_time.h" +#include #include "atom.h" #include "force.h" #include "timer.h" diff --git a/src/imbalance_var.cpp b/src/imbalance_var.cpp index ba17c06866..ba84ef01ef 100644 --- a/src/imbalance_var.cpp +++ b/src/imbalance_var.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "imbalance_var.h" #include #include -#include "imbalance_var.h" #include "atom.h" #include "group.h" #include "input.h" diff --git a/src/improper_deprecated.cpp b/src/improper_deprecated.cpp index 6f4d08764f..62a688527a 100644 --- a/src/improper_deprecated.cpp +++ b/src/improper_deprecated.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "improper_deprecated.h" +#include #include "improper_hybrid.h" #include "comm.h" #include "force.h" diff --git a/src/improper_hybrid.cpp b/src/improper_hybrid.cpp index af1382d3eb..f078a73ec0 100644 --- a/src/improper_hybrid.cpp +++ b/src/improper_hybrid.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "improper_hybrid.h" #include #include #include -#include "improper_hybrid.h" #include "atom.h" #include "neighbor.h" #include "comm.h" diff --git a/src/improper_zero.cpp b/src/improper_zero.cpp index 3f36954a0a..efa70c8ff5 100644 --- a/src/improper_zero.cpp +++ b/src/improper_zero.cpp @@ -15,8 +15,8 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ -#include #include "improper_zero.h" +#include #include "atom.h" #include "force.h" #include "memory.h" diff --git a/src/info.cpp b/src/info.cpp index bb2d3c4b45..8f55fab367 100644 --- a/src/info.cpp +++ b/src/info.cpp @@ -16,6 +16,7 @@ Richard Berger (Temple U) ------------------------------------------------------------------------- */ +#include "info.h" #include #include #include @@ -23,7 +24,6 @@ #include #include #include -#include "info.h" #include "accelerator_kokkos.h" #include "atom.h" #include "comm.h" diff --git a/src/input.cpp b/src/input.cpp index cbad1d78bf..f887bc0245 100644 --- a/src/input.cpp +++ b/src/input.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "input.h" #include #include #include @@ -18,7 +19,6 @@ #include #include #include -#include "input.h" #include "style_command.h" #include "universe.h" #include "atom.h" diff --git a/src/irregular.cpp b/src/irregular.cpp index 2040d12d0b..b67214df25 100644 --- a/src/irregular.cpp +++ b/src/irregular.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "irregular.h" #include #include -#include "irregular.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/kspace.cpp b/src/kspace.cpp index b51191857d..f9020416bf 100644 --- a/src/kspace.cpp +++ b/src/kspace.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "kspace.h" #include #include #include #include -#include "kspace.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/kspace_deprecated.cpp b/src/kspace_deprecated.cpp index 1d62de2692..0b6490b4cf 100644 --- a/src/kspace_deprecated.cpp +++ b/src/kspace_deprecated.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "kspace_deprecated.h" +#include #include "comm.h" #include "force.h" #include "error.h" diff --git a/src/lammps.cpp b/src/lammps.cpp index f8e7dceb89..5ddc1600a4 100644 --- a/src/lammps.cpp +++ b/src/lammps.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "lammps.h" #include #include #include @@ -18,7 +19,6 @@ #include #include #include -#include "lammps.h" #include "style_angle.h" // IWYU pragma: keep #include "style_atom.h" // IWYU pragma: keep #include "style_bond.h" // IWYU pragma: keep diff --git a/src/lattice.cpp b/src/lattice.cpp index ee2fea2a75..98faf680e8 100644 --- a/src/lattice.cpp +++ b/src/lattice.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "lattice.h" #include #include #include -#include "lattice.h" #include "update.h" #include "domain.h" #include "comm.h" diff --git a/src/library.cpp b/src/library.cpp index 033b814865..eabe5fd179 100644 --- a/src/library.cpp +++ b/src/library.cpp @@ -14,11 +14,11 @@ // C or Fortran style library interface to LAMMPS // customize by adding new LAMMPS-specific functions +#include "library.h" #include #include #include #include -#include "library.h" #include "universe.h" #include "atom_vec.h" #include "atom.h" diff --git a/src/main.cpp b/src/main.cpp index 1be9c253eb..b7f6adbdda 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "lammps.h" +#include #include "input.h" #if defined(LAMMPS_TRAP_FPE) && defined(_GNU_SOURCE) diff --git a/src/math_extra.cpp b/src/math_extra.cpp index f7e5bb646b..797d210d0e 100644 --- a/src/math_extra.cpp +++ b/src/math_extra.cpp @@ -15,9 +15,9 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "math_extra.h" #include #include -#include "math_extra.h" #define MAXJACOBI 50 diff --git a/src/math_special.cpp b/src/math_special.cpp index b2f545ddc6..bf11a1ad45 100644 --- a/src/math_special.cpp +++ b/src/math_special.cpp @@ -1,6 +1,6 @@ +#include "math_special.h" #include #include // IWYU pragma: keep -#include "math_special.h" using namespace LAMMPS_NS; diff --git a/src/memory.cpp b/src/memory.cpp index ca7fd3ea7f..a513dde6c2 100644 --- a/src/memory.cpp +++ b/src/memory.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "memory.h" +#include #include "error.h" #if defined(LMP_USER_INTEL) && defined(__INTEL_COMPILER) diff --git a/src/min.cpp b/src/min.cpp index f2e1c982be..408954edb8 100644 --- a/src/min.cpp +++ b/src/min.cpp @@ -19,10 +19,10 @@ JR Shewchuk, http://www-2.cs.cmu.edu/~jrs/jrspapers.html#cg ------------------------------------------------------------------------- */ +#include "min.h" #include #include #include -#include "min.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/min_cg.cpp b/src/min_cg.cpp index eb8831c8f5..ff318d23da 100644 --- a/src/min_cg.cpp +++ b/src/min_cg.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "min_cg.h" #include #include -#include "min_cg.h" #include "update.h" #include "output.h" #include "timer.h" diff --git a/src/min_fire.cpp b/src/min_fire.cpp index 79346341bb..b7f853afd2 100644 --- a/src/min_fire.cpp +++ b/src/min_fire.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "min_fire.h" #include #include -#include "min_fire.h" #include "universe.h" #include "atom.h" #include "force.h" diff --git a/src/min_hftn.cpp b/src/min_hftn.cpp index c2c251c386..dcfed10fef 100644 --- a/src/min_hftn.cpp +++ b/src/min_hftn.cpp @@ -17,12 +17,12 @@ "Parallel Unconstrained Min", Plantenga, SAND98-8201 ------------------------------------------------------------------------- */ +#include "min_hftn.h" #include #include #include #include "atom.h" #include "fix_minimize.h" -#include "min_hftn.h" #include "modify.h" #include "output.h" #include "pair.h" diff --git a/src/min_linesearch.cpp b/src/min_linesearch.cpp index 3c0621c602..a7a10dcd51 100644 --- a/src/min_linesearch.cpp +++ b/src/min_linesearch.cpp @@ -21,9 +21,9 @@ JR Shewchuk, http://www-2.cs.cmu.edu/~jrs/jrspapers.html#cg ------------------------------------------------------------------------- */ +#include "min_linesearch.h" #include #include -#include "min_linesearch.h" #include "atom.h" #include "modify.h" #include "fix_minimize.h" diff --git a/src/min_quickmin.cpp b/src/min_quickmin.cpp index 784da82686..04e72b046d 100644 --- a/src/min_quickmin.cpp +++ b/src/min_quickmin.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "min_quickmin.h" #include #include -#include "min_quickmin.h" #include "universe.h" #include "atom.h" #include "force.h" diff --git a/src/min_sd.cpp b/src/min_sd.cpp index d66601119b..e4e159003f 100644 --- a/src/min_sd.cpp +++ b/src/min_sd.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "min_sd.h" +#include #include "update.h" #include "output.h" #include "timer.h" diff --git a/src/modify.cpp b/src/modify.cpp index 61497d86db..a9b8817aed 100644 --- a/src/modify.cpp +++ b/src/modify.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "modify.h" +#include #include "style_compute.h" #include "style_fix.h" #include "atom.h" diff --git a/src/molecule.cpp b/src/molecule.cpp index 4a3790296f..38887ebb0c 100644 --- a/src/molecule.cpp +++ b/src/molecule.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "molecule.h" #include #include #include #include -#include "molecule.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_body.h" diff --git a/src/nbin.cpp b/src/nbin.cpp index 0480c9730d..99d41db140 100644 --- a/src/nbin.cpp +++ b/src/nbin.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "nbin.h" +#include #include "neighbor.h" #include "neigh_request.h" #include "domain.h" diff --git a/src/neighbor.cpp b/src/neighbor.cpp index a2efc5919b..d38aed08c0 100644 --- a/src/neighbor.cpp +++ b/src/neighbor.cpp @@ -15,10 +15,10 @@ Contributing author (triclinic and multi-neigh) : Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "neighbor.h" #include #include #include -#include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "nbin.h" diff --git a/src/npair.cpp b/src/npair.cpp index 24cdc7750a..b63135fad6 100644 --- a/src/npair.cpp +++ b/src/npair.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair.h" +#include #include "neighbor.h" #include "neigh_request.h" #include "nbin.h" diff --git a/src/ntopo.cpp b/src/ntopo.cpp index 05e287e192..ca63b85328 100644 --- a/src/ntopo.cpp +++ b/src/ntopo.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo.h" +#include #include "atom.h" #include "neighbor.h" #include "comm.h" diff --git a/src/ntopo_angle_all.cpp b/src/ntopo_angle_all.cpp index 2a358c8ce5..e0c20609a1 100644 --- a/src/ntopo_angle_all.cpp +++ b/src/ntopo_angle_all.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_angle_all.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_angle_partial.cpp b/src/ntopo_angle_partial.cpp index c82110cda5..a6fd900825 100644 --- a/src/ntopo_angle_partial.cpp +++ b/src/ntopo_angle_partial.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_angle_partial.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_angle_template.cpp b/src/ntopo_angle_template.cpp index 15a8b658f3..8cbcf8bcbd 100644 --- a/src/ntopo_angle_template.cpp +++ b/src/ntopo_angle_template.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_angle_template.h" +#include #include "atom.h" #include "atom_vec.h" #include "force.h" diff --git a/src/ntopo_bond_all.cpp b/src/ntopo_bond_all.cpp index 42e9e2303d..5309754554 100644 --- a/src/ntopo_bond_all.cpp +++ b/src/ntopo_bond_all.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_bond_all.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_bond_partial.cpp b/src/ntopo_bond_partial.cpp index 5a1acd9191..1cbf5eed11 100644 --- a/src/ntopo_bond_partial.cpp +++ b/src/ntopo_bond_partial.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_bond_partial.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_bond_template.cpp b/src/ntopo_bond_template.cpp index fa98658ad0..cd7b85aa19 100644 --- a/src/ntopo_bond_template.cpp +++ b/src/ntopo_bond_template.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_bond_template.h" +#include #include "atom.h" #include "atom_vec.h" #include "force.h" diff --git a/src/ntopo_dihedral_all.cpp b/src/ntopo_dihedral_all.cpp index 9c94fb10f9..5af2d526e0 100644 --- a/src/ntopo_dihedral_all.cpp +++ b/src/ntopo_dihedral_all.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_dihedral_all.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_dihedral_partial.cpp b/src/ntopo_dihedral_partial.cpp index 14749e6511..faac57aa51 100644 --- a/src/ntopo_dihedral_partial.cpp +++ b/src/ntopo_dihedral_partial.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_dihedral_partial.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_dihedral_template.cpp b/src/ntopo_dihedral_template.cpp index 8ea860c2e2..bce8ecf4bc 100644 --- a/src/ntopo_dihedral_template.cpp +++ b/src/ntopo_dihedral_template.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_dihedral_template.h" +#include #include "atom.h" #include "atom_vec.h" #include "force.h" diff --git a/src/ntopo_improper_all.cpp b/src/ntopo_improper_all.cpp index 6c478dec52..0cbecbf962 100644 --- a/src/ntopo_improper_all.cpp +++ b/src/ntopo_improper_all.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_improper_all.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_improper_partial.cpp b/src/ntopo_improper_partial.cpp index 2c37668ca8..17e5d4cf62 100644 --- a/src/ntopo_improper_partial.cpp +++ b/src/ntopo_improper_partial.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_improper_partial.h" +#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/ntopo_improper_template.cpp b/src/ntopo_improper_template.cpp index 953e010d89..a80fe60e1d 100644 --- a/src/ntopo_improper_template.cpp +++ b/src/ntopo_improper_template.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "ntopo_improper_template.h" +#include #include "atom.h" #include "atom_vec.h" #include "force.h" diff --git a/src/output.cpp b/src/output.cpp index be6f66b7aa..193db9ae2a 100644 --- a/src/output.cpp +++ b/src/output.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "output.h" #include #include -#include "output.h" #include "style_dump.h" #include "atom.h" #include "neighbor.h" diff --git a/src/pair.cpp b/src/pair.cpp index 3d7bdaa62c..36194aec9b 100644 --- a/src/pair.cpp +++ b/src/pair.cpp @@ -15,12 +15,12 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair.h" #include #include // IWYU pragma: keep #include // IWYU pragma: keep #include #include -#include "pair.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/pair_beck.cpp b/src/pair_beck.cpp index 8ba3ef80f2..b94436b696 100644 --- a/src/pair_beck.cpp +++ b/src/pair_beck.cpp @@ -15,9 +15,9 @@ Contributing author: Jonathan Zimmerman (Sandia) ------------------------------------------------------------------------- */ +#include "pair_beck.h" #include #include -#include "pair_beck.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_born.cpp b/src/pair_born.cpp index ae7456ddbb..bd993acb56 100644 --- a/src/pair_born.cpp +++ b/src/pair_born.cpp @@ -15,10 +15,10 @@ Contributing Author: Sai Jayaraman (Sandia) ------------------------------------------------------------------------- */ +#include "pair_born.h" #include #include #include -#include "pair_born.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_born_coul_dsf.cpp b/src/pair_born_coul_dsf.cpp index 51b9a2677d..f7e139c750 100644 --- a/src/pair_born_coul_dsf.cpp +++ b/src/pair_born_coul_dsf.cpp @@ -16,9 +16,9 @@ References: Fennell and Gezelter, JCP 124, 234104 (2006) ------------------------------------------------------------------------- */ +#include "pair_born_coul_dsf.h" #include #include -#include "pair_born_coul_dsf.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_born_coul_wolf.cpp b/src/pair_born_coul_wolf.cpp index f4ccac80a1..f4d533bdb0 100644 --- a/src/pair_born_coul_wolf.cpp +++ b/src/pair_born_coul_wolf.cpp @@ -15,9 +15,9 @@ Contributing author: Yongfeng Zhang (INL), yongfeng.zhang@inl.gov ------------------------------------------------------------------------- */ +#include "pair_born_coul_wolf.h" #include #include -#include "pair_born_coul_wolf.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_buck.cpp b/src/pair_buck.cpp index b9795fb0ed..a94ce87891 100644 --- a/src/pair_buck.cpp +++ b/src/pair_buck.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_buck.h" #include #include #include -#include "pair_buck.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_buck_coul_cut.cpp b/src/pair_buck_coul_cut.cpp index 64475166e3..d05c139f71 100644 --- a/src/pair_buck_coul_cut.cpp +++ b/src/pair_buck_coul_cut.cpp @@ -15,9 +15,9 @@ Contributing author: Eduardo Bringa (LLNL) ------------------------------------------------------------------------- */ +#include "pair_buck_coul_cut.h" #include #include -#include "pair_buck_coul_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_coul_cut.cpp b/src/pair_coul_cut.cpp index 28973026cd..9e6f238eba 100644 --- a/src/pair_coul_cut.cpp +++ b/src/pair_coul_cut.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_coul_cut.h" #include #include #include -#include "pair_coul_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_coul_debye.cpp b/src/pair_coul_debye.cpp index cd23ef1919..1b87a93701 100644 --- a/src/pair_coul_debye.cpp +++ b/src/pair_coul_debye.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_coul_debye.h" #include #include -#include "pair_coul_debye.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_coul_dsf.cpp b/src/pair_coul_dsf.cpp index 4c15b5d330..22230182b0 100644 --- a/src/pair_coul_dsf.cpp +++ b/src/pair_coul_dsf.cpp @@ -16,10 +16,10 @@ References: Fennell and Gezelter, JCP 124, 234104 (2006) ------------------------------------------------------------------------- */ +#include "pair_coul_dsf.h" #include #include #include -#include "pair_coul_dsf.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_coul_streitz.cpp b/src/pair_coul_streitz.cpp index f577564ac1..628f6a6b36 100644 --- a/src/pair_coul_streitz.cpp +++ b/src/pair_coul_streitz.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include "pair_coul_streitz.h" #include #include #include #include -#include "pair_coul_streitz.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_coul_wolf.cpp b/src/pair_coul_wolf.cpp index 8c15378de8..15c7839fc6 100644 --- a/src/pair_coul_wolf.cpp +++ b/src/pair_coul_wolf.cpp @@ -15,9 +15,9 @@ Contributing author: Yongfeng Zhang (INL), yongfeng.zhang@inl.gov ------------------------------------------------------------------------- */ +#include "pair_coul_wolf.h" #include #include -#include "pair_coul_wolf.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_deprecated.cpp b/src/pair_deprecated.cpp index 0b1342fb2d..058809eb80 100644 --- a/src/pair_deprecated.cpp +++ b/src/pair_deprecated.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_deprecated.h" +#include #include "pair_hybrid.h" #include "comm.h" #include "force.h" diff --git a/src/pair_dpd.cpp b/src/pair_dpd.cpp index e5e6cf7dae..ec65eaafd6 100644 --- a/src/pair_dpd.cpp +++ b/src/pair_dpd.cpp @@ -15,9 +15,9 @@ Contributing author: Kurt Smith (U Pittsburgh) ------------------------------------------------------------------------- */ +#include "pair_dpd.h" #include #include -#include "pair_dpd.h" #include "atom.h" #include "comm.h" #include "update.h" diff --git a/src/pair_dpd_tstat.cpp b/src/pair_dpd_tstat.cpp index 66c8d91ab1..15d7c90b27 100644 --- a/src/pair_dpd_tstat.cpp +++ b/src/pair_dpd_tstat.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_dpd_tstat.h" #include #include -#include "pair_dpd_tstat.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/pair_gauss.cpp b/src/pair_gauss.cpp index 7df9a417c3..7fd3233f4c 100644 --- a/src/pair_gauss.cpp +++ b/src/pair_gauss.cpp @@ -15,10 +15,10 @@ Contributing author: Sai Jayaraman (Sandia) ------------------------------------------------------------------------- */ +#include "pair_gauss.h" #include #include #include -#include "pair_gauss.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_hybrid.cpp b/src/pair_hybrid.cpp index daeee3d2b3..762b9fe8fc 100644 --- a/src/pair_hybrid.cpp +++ b/src/pair_hybrid.cpp @@ -12,10 +12,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_hybrid.h" #include #include #include -#include "pair_hybrid.h" #include "atom.h" #include "force.h" #include "pair.h" diff --git a/src/pair_hybrid_overlay.cpp b/src/pair_hybrid_overlay.cpp index 496e3d0406..e67cb677af 100644 --- a/src/pair_hybrid_overlay.cpp +++ b/src/pair_hybrid_overlay.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_hybrid_overlay.h" #include #include -#include "pair_hybrid_overlay.h" #include "atom.h" #include "force.h" #include "error.h" diff --git a/src/pair_lj96_cut.cpp b/src/pair_lj96_cut.cpp index 62e645ef2c..c27038900d 100644 --- a/src/pair_lj96_cut.cpp +++ b/src/pair_lj96_cut.cpp @@ -15,10 +15,10 @@ Contributing author: Chuanfu Luo (luochuanfu@gmail.com) ------------------------------------------------------------------------- */ +#include "pair_lj96_cut.h" #include #include #include -#include "pair_lj96_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_cubic.cpp b/src/pair_lj_cubic.cpp index 8b1b4b7627..7990952494 100644 --- a/src/pair_lj_cubic.cpp +++ b/src/pair_lj_cubic.cpp @@ -16,9 +16,9 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cubic.h" #include #include -#include "pair_lj_cubic.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_cut.cpp b/src/pair_lj_cut.cpp index 9284923218..0302858adb 100644 --- a/src/pair_lj_cut.cpp +++ b/src/pair_lj_cut.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut.h" #include #include #include -#include "pair_lj_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_cut_coul_cut.cpp b/src/pair_lj_cut_coul_cut.cpp index 9ffa02156e..d4640bee3a 100644 --- a/src/pair_lj_cut_coul_cut.cpp +++ b/src/pair_lj_cut_coul_cut.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_cut.h" #include #include #include -#include "pair_lj_cut_coul_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_cut_coul_debye.cpp b/src/pair_lj_cut_coul_debye.cpp index ab6220bd24..4ef533a743 100644 --- a/src/pair_lj_cut_coul_debye.cpp +++ b/src/pair_lj_cut_coul_debye.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_debye.h" #include #include -#include "pair_lj_cut_coul_debye.h" #include "atom.h" #include "neigh_list.h" #include "force.h" diff --git a/src/pair_lj_cut_coul_wolf.cpp b/src/pair_lj_cut_coul_wolf.cpp index 55aff0d7c5..fb641f7d24 100644 --- a/src/pair_lj_cut_coul_wolf.cpp +++ b/src/pair_lj_cut_coul_wolf.cpp @@ -15,11 +15,11 @@ Contributing author: Vishal Boddu (FAU) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_wolf.h" #include #include #include #include -#include "pair_lj_cut_coul_wolf.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_expand.cpp b/src/pair_lj_expand.cpp index d5c0a40f2d..60593fd01d 100644 --- a/src/pair_lj_expand.cpp +++ b/src/pair_lj_expand.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_expand.h" #include #include #include #include -#include "pair_lj_expand.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_gromacs.cpp b/src/pair_lj_gromacs.cpp index 1fdaefebe9..4796c288d7 100644 --- a/src/pair_lj_gromacs.cpp +++ b/src/pair_lj_gromacs.cpp @@ -15,11 +15,11 @@ Contributing author: Mark Stevens (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_gromacs.h" #include #include #include #include -#include "pair_lj_gromacs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_gromacs_coul_gromacs.cpp b/src/pair_lj_gromacs_coul_gromacs.cpp index 28dc8ec79b..45beeb1daf 100644 --- a/src/pair_lj_gromacs_coul_gromacs.cpp +++ b/src/pair_lj_gromacs_coul_gromacs.cpp @@ -15,11 +15,11 @@ Contributing author: Mark Stevens (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_gromacs_coul_gromacs.h" #include #include #include #include -#include "pair_lj_gromacs_coul_gromacs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_smooth.cpp b/src/pair_lj_smooth.cpp index ecacadbffa..d89fee1148 100644 --- a/src/pair_lj_smooth.cpp +++ b/src/pair_lj_smooth.cpp @@ -15,10 +15,10 @@ Contributing author: Craig Maloney (UCSB) ------------------------------------------------------------------------- */ +#include "pair_lj_smooth.h" #include #include #include -#include "pair_lj_smooth.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_smooth_linear.cpp b/src/pair_lj_smooth_linear.cpp index 265828c4cf..6ed19a452f 100644 --- a/src/pair_lj_smooth_linear.cpp +++ b/src/pair_lj_smooth_linear.cpp @@ -15,10 +15,10 @@ Contributing author: Jonathan Zimmerman (Sandia) ------------------------------------------------------------------------- */ +#include "pair_lj_smooth_linear.h" #include #include #include -#include "pair_lj_smooth_linear.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_mie_cut.cpp b/src/pair_mie_cut.cpp index 231832dc48..d2b0c20cd5 100644 --- a/src/pair_mie_cut.cpp +++ b/src/pair_mie_cut.cpp @@ -15,11 +15,11 @@ Contributing author: Cassiano Aimoli (aimoli@gmail.com) ------------------------------------------------------------------------- */ +#include "pair_mie_cut.h" #include #include #include #include -#include "pair_mie_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_morse.cpp b/src/pair_morse.cpp index dca1834c14..47102932db 100644 --- a/src/pair_morse.cpp +++ b/src/pair_morse.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_morse.h" #include #include #include #include -#include "pair_morse.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_soft.cpp b/src/pair_soft.cpp index 7602f7b925..f3d7423b04 100644 --- a/src/pair_soft.cpp +++ b/src/pair_soft.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_soft.h" #include #include #include #include -#include "pair_soft.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_table.cpp b/src/pair_table.cpp index b1b6f45eda..63cda78c67 100644 --- a/src/pair_table.cpp +++ b/src/pair_table.cpp @@ -15,11 +15,11 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_table.h" #include #include #include #include -#include "pair_table.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/pair_ufm.cpp b/src/pair_ufm.cpp index 226fb6e7d9..40b72136ff 100644 --- a/src/pair_ufm.cpp +++ b/src/pair_ufm.cpp @@ -17,11 +17,11 @@ Maurice de Koning (Unicamp/Brazil) - dekoning@ifi.unicamp.br ------------------------------------------------------------------------- */ +#include "pair_ufm.h" #include #include #include #include -#include "pair_ufm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_yukawa.cpp b/src/pair_yukawa.cpp index 913afbd5a1..4a2cf23952 100644 --- a/src/pair_yukawa.cpp +++ b/src/pair_yukawa.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_yukawa.h" #include #include -#include "pair_yukawa.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/pair_zbl.cpp b/src/pair_zbl.cpp index 254a82ea64..b01c301785 100644 --- a/src/pair_zbl.cpp +++ b/src/pair_zbl.cpp @@ -15,11 +15,11 @@ Contributing authors: Stephen Foiles, Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "pair_zbl.h" #include #include #include #include -#include "pair_zbl.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_zero.cpp b/src/pair_zero.cpp index 143808f598..2692710e20 100644 --- a/src/pair_zero.cpp +++ b/src/pair_zero.cpp @@ -15,11 +15,11 @@ Contributing author: Carsten Svaneborg (SDU) ------------------------------------------------------------------------- */ +#include "pair_zero.h" #include #include #include #include -#include "pair_zero.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/procmap.cpp b/src/procmap.cpp index 08b60a26af..47afb76da9 100644 --- a/src/procmap.cpp +++ b/src/procmap.cpp @@ -15,8 +15,8 @@ Contributing author (NUMA option) : Mike Brown (ORNL) ------------------------------------------------------------------------- */ -#include #include "procmap.h" +#include #include "universe.h" #include "comm.h" #include "domain.h" diff --git a/src/random_mars.cpp b/src/random_mars.cpp index 464e640eab..9de5290d29 100644 --- a/src/random_mars.cpp +++ b/src/random_mars.cpp @@ -14,8 +14,8 @@ // Marsaglia random number generator // see RANMAR in F James, Comp Phys Comm, 60, 329 (1990) -#include #include "random_mars.h" +#include #include "error.h" using namespace LAMMPS_NS; diff --git a/src/random_park.cpp b/src/random_park.cpp index fc00939bd4..e12e8a3a10 100644 --- a/src/random_park.cpp +++ b/src/random_park.cpp @@ -13,8 +13,8 @@ // Park/Miller RNG -#include #include "random_park.h" +#include #include "error.h" using namespace LAMMPS_NS; diff --git a/src/rcb.cpp b/src/rcb.cpp index 83cdccdf80..b19beae3c5 100644 --- a/src/rcb.cpp +++ b/src/rcb.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "rcb.h" #include #include -#include "rcb.h" #include "irregular.h" #include "memory.h" #include "error.h" diff --git a/src/read_data.cpp b/src/read_data.cpp index e70a526c38..a50d41b498 100644 --- a/src/read_data.cpp +++ b/src/read_data.cpp @@ -15,13 +15,13 @@ // due to OpenMPI bug which sets INT64_MAX via its mpi.h // before lmptype.h can set flags to insure it is done correctly +#include "read_data.h" #include "lmptype.h" #include #include #include #include #include -#include "read_data.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_ellipsoid.h" diff --git a/src/read_dump.cpp b/src/read_dump.cpp index 395f4c8edd..49f96db680 100644 --- a/src/read_dump.cpp +++ b/src/read_dump.cpp @@ -19,11 +19,11 @@ // due to OpenMPI bug which sets INT64_MAX via its mpi.h // before lmptype.h can set flags to insure it is done correctly +#include "read_dump.h" #include "lmptype.h" #include #include #include -#include "read_dump.h" #include "reader.h" #include "style_reader.h" #include "atom.h" diff --git a/src/read_restart.cpp b/src/read_restart.cpp index 6e156da837..17b313bfa2 100644 --- a/src/read_restart.cpp +++ b/src/read_restart.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "read_restart.h" #include #include #include #include -#include "read_restart.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/reader.cpp b/src/reader.cpp index cf344b37b3..a1fe51f662 100644 --- a/src/reader.cpp +++ b/src/reader.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "reader.h" #include #include -#include "reader.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/reader_native.cpp b/src/reader_native.cpp index 2c60ffdfd4..9e98a95759 100644 --- a/src/reader_native.cpp +++ b/src/reader_native.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "reader_native.h" #include #include -#include "reader_native.h" #include "atom.h" #include "memory.h" #include "error.h" diff --git a/src/reader_xyz.cpp b/src/reader_xyz.cpp index 37d30bd740..fa553dc30f 100644 --- a/src/reader_xyz.cpp +++ b/src/reader_xyz.cpp @@ -15,9 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "reader_xyz.h" #include #include -#include "reader_xyz.h" #include "atom.h" #include "memory.h" #include "error.h" diff --git a/src/region.cpp b/src/region.cpp index 6b49a2819b..0c4bec16e0 100644 --- a/src/region.cpp +++ b/src/region.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region.h" #include #include #include -#include "region.h" #include "update.h" #include "domain.h" #include "lattice.h" diff --git a/src/region_block.cpp b/src/region_block.cpp index e55c481189..bc52fcd7cf 100644 --- a/src/region_block.cpp +++ b/src/region_block.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region_block.h" #include #include -#include "region_block.h" #include "force.h" #include "domain.h" #include "math_extra.h" diff --git a/src/region_cone.cpp b/src/region_cone.cpp index 72f56a268f..345c9fa8e2 100644 --- a/src/region_cone.cpp +++ b/src/region_cone.cpp @@ -15,10 +15,10 @@ Contributing author: Pim Schravendijk ------------------------------------------------------------------------- */ +#include "region_cone.h" #include #include #include -#include "region_cone.h" #include "domain.h" #include "error.h" #include "force.h" diff --git a/src/region_cylinder.cpp b/src/region_cylinder.cpp index 7709c57aab..968453cf37 100644 --- a/src/region_cylinder.cpp +++ b/src/region_cylinder.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region_cylinder.h" #include #include #include -#include "region_cylinder.h" #include "update.h" #include "domain.h" #include "input.h" diff --git a/src/region_deprecated.cpp b/src/region_deprecated.cpp index 87225959fa..a2e4e88393 100644 --- a/src/region_deprecated.cpp +++ b/src/region_deprecated.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "region_deprecated.h" +#include #include "comm.h" #include "error.h" diff --git a/src/region_intersect.cpp b/src/region_intersect.cpp index 96d3bed16c..c6c11cf35c 100644 --- a/src/region_intersect.cpp +++ b/src/region_intersect.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region_intersect.h" #include #include -#include "region_intersect.h" #include "domain.h" #include "error.h" #include "force.h" diff --git a/src/region_plane.cpp b/src/region_plane.cpp index e67a2c85bd..950c0a4b53 100644 --- a/src/region_plane.cpp +++ b/src/region_plane.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region_plane.h" #include #include #include -#include "region_plane.h" #include "error.h" #include "force.h" diff --git a/src/region_prism.cpp b/src/region_prism.cpp index 22fc504c37..38fc23da21 100644 --- a/src/region_prism.cpp +++ b/src/region_prism.cpp @@ -15,10 +15,10 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "region_prism.h" #include #include #include -#include "region_prism.h" #include "domain.h" #include "force.h" #include "math_extra.h" diff --git a/src/region_sphere.cpp b/src/region_sphere.cpp index 8080ef5882..9c478960e3 100644 --- a/src/region_sphere.cpp +++ b/src/region_sphere.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region_sphere.h" #include #include #include -#include "region_sphere.h" #include "update.h" #include "input.h" #include "variable.h" diff --git a/src/region_union.cpp b/src/region_union.cpp index 33ac6fedd7..f4e30f5b94 100644 --- a/src/region_union.cpp +++ b/src/region_union.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region_union.h" #include #include -#include "region_union.h" #include "domain.h" #include "error.h" #include "force.h" diff --git a/src/replicate.cpp b/src/replicate.cpp index 3c8f4a8aee..6f8c94238a 100644 --- a/src/replicate.cpp +++ b/src/replicate.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "replicate.h" #include #include -#include "replicate.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_hybrid.h" diff --git a/src/rerun.cpp b/src/rerun.cpp index 063ea882c2..e75779ccc0 100644 --- a/src/rerun.cpp +++ b/src/rerun.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "rerun.h" #include #include -#include "rerun.h" #include "read_dump.h" #include "domain.h" #include "update.h" diff --git a/src/reset_ids.cpp b/src/reset_ids.cpp index b2cf7a9bbc..b68b7ca797 100644 --- a/src/reset_ids.cpp +++ b/src/reset_ids.cpp @@ -28,7 +28,7 @@ ResetIDs::ResetIDs(LAMMPS *lmp) : Pointers(lmp) {} /* ---------------------------------------------------------------------- */ -void ResetIDs::command(int narg, char **/*arg*/) +void ResetIDs::command(int narg, char ** /* arg */) { if (domain->box_exist == 0) error->all(FLERR,"Reset_ids command before simulation box is defined"); diff --git a/src/respa.cpp b/src/respa.cpp index 6fa9959d78..867662b3c2 100644 --- a/src/respa.cpp +++ b/src/respa.cpp @@ -15,9 +15,9 @@ Contributing authors: Mark Stevens (SNL), Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "respa.h" #include #include -#include "respa.h" #include "neighbor.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/run.cpp b/src/run.cpp index beb71be52c..60861ad3b9 100644 --- a/src/run.cpp +++ b/src/run.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "run.h" #include #include -#include "run.h" #include "domain.h" #include "update.h" #include "force.h" diff --git a/src/set.cpp b/src/set.cpp index 00b2d8a9b0..d34aa7753a 100644 --- a/src/set.cpp +++ b/src/set.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "set.h" #include #include #include #include -#include "set.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_ellipsoid.h" diff --git a/src/special.cpp b/src/special.cpp index 903794c0f6..f8661e238c 100644 --- a/src/special.cpp +++ b/src/special.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "special.h" #include #include -#include "special.h" #include "atom.h" #include "atom_vec.h" #include "force.h" diff --git a/src/thermo.cpp b/src/thermo.cpp index f4ab7b0779..d267ea260c 100644 --- a/src/thermo.cpp +++ b/src/thermo.cpp @@ -15,12 +15,12 @@ // due to OpenMPI bug which sets INT64_MAX via its mpi.h // before lmptype.h can set flags to insure it is done correctly +#include "thermo.h" #include "lmptype.h" #include #include #include #include -#include "thermo.h" #include "atom.h" #include "update.h" #include "comm.h" diff --git a/src/timer.cpp b/src/timer.cpp index 65cb6ab5d8..0dad8fb756 100644 --- a/src/timer.cpp +++ b/src/timer.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "timer.h" #include #include #include -#include "timer.h" #include "comm.h" #include "error.h" #include "force.h" diff --git a/src/universe.cpp b/src/universe.cpp index f078590103..2a7117da51 100644 --- a/src/universe.cpp +++ b/src/universe.cpp @@ -11,12 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "universe.h" #include #include #include #include #include -#include "universe.h" #include "version.h" #include "error.h" #include "force.h" diff --git a/src/update.cpp b/src/update.cpp index f5e706e354..e83f4d9f72 100644 --- a/src/update.cpp +++ b/src/update.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "update.h" #include #include -#include "update.h" #include "integrate.h" #include "min.h" #include "style_integrate.h" diff --git a/src/utils.cpp b/src/utils.cpp index 8468b22d8c..ea2ab57f6f 100644 --- a/src/utils.cpp +++ b/src/utils.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "utils.h" #include #include -#include "utils.h" #include "lammps.h" #include "error.h" diff --git a/src/variable.cpp b/src/variable.cpp index 111fc75a9a..440fb07f95 100644 --- a/src/variable.cpp +++ b/src/variable.cpp @@ -11,13 +11,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "variable.h" #include #include #include #include #include #include -#include "variable.h" #include "universe.h" #include "atom.h" #include "update.h" diff --git a/src/velocity.cpp b/src/velocity.cpp index 95d820cc22..1a03f71128 100644 --- a/src/velocity.cpp +++ b/src/velocity.cpp @@ -11,12 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "velocity.h" #include #include #include #include #include -#include "velocity.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/verlet.cpp b/src/verlet.cpp index fcba248d5f..5ccef36259 100644 --- a/src/verlet.cpp +++ b/src/verlet.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "verlet.h" +#include #include "neighbor.h" #include "domain.h" #include "comm.h" diff --git a/src/write_coeff.cpp b/src/write_coeff.cpp index 9bf54b3c08..08ff964e7c 100644 --- a/src/write_coeff.cpp +++ b/src/write_coeff.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "write_coeff.h" #include #include #include -#include "write_coeff.h" #include "pair.h" #include "bond.h" #include "angle.h" diff --git a/src/write_data.cpp b/src/write_data.cpp index decc92ea8c..b78e701d35 100644 --- a/src/write_data.cpp +++ b/src/write_data.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "write_data.h" #include #include -#include "write_data.h" #include "atom.h" #include "atom_vec.h" #include "group.h" diff --git a/src/write_dump.cpp b/src/write_dump.cpp index 072680a8a5..903f0e0cdd 100644 --- a/src/write_dump.cpp +++ b/src/write_dump.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "write_dump.h" +#include #include "style_dump.h" #include "dump.h" #include "dump_image.h" diff --git a/src/write_restart.cpp b/src/write_restart.cpp index e0e17cd292..5adb39067c 100644 --- a/src/write_restart.cpp +++ b/src/write_restart.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "write_restart.h" #include #include -#include "write_restart.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_hybrid.h" From 5b3a15bd944b0dc6a3b49c0f8d088e6797cfc6db Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 3 Jul 2019 19:44:58 -0400 Subject: [PATCH 33/79] putting implementation header first in package folder sources --- src/ASPHERE/compute_erotate_asphere.cpp | 2 +- src/ASPHERE/compute_temp_asphere.cpp | 2 +- src/ASPHERE/fix_nh_asphere.cpp | 2 +- src/ASPHERE/fix_nph_asphere.cpp | 2 +- src/ASPHERE/fix_npt_asphere.cpp | 2 +- src/ASPHERE/fix_nve_asphere.cpp | 2 +- src/ASPHERE/fix_nve_asphere_noforce.cpp | 2 +- src/ASPHERE/fix_nve_line.cpp | 2 +- src/ASPHERE/fix_nve_tri.cpp | 2 +- src/ASPHERE/fix_nvt_asphere.cpp | 2 +- src/ASPHERE/pair_gayberne.cpp | 2 +- src/ASPHERE/pair_line_lj.cpp | 2 +- src/ASPHERE/pair_resquared.cpp | 2 +- src/ASPHERE/pair_tri_lj.cpp | 2 +- src/BODY/body_nparticle.cpp | 2 +- src/BODY/body_rounded_polygon.cpp | 2 +- src/BODY/body_rounded_polyhedron.cpp | 2 +- src/BODY/compute_body_local.cpp | 2 +- src/BODY/compute_temp_body.cpp | 2 +- src/BODY/fix_nh_body.cpp | 2 +- src/BODY/fix_nph_body.cpp | 2 +- src/BODY/fix_npt_body.cpp | 2 +- src/BODY/fix_nve_body.cpp | 2 +- src/BODY/fix_nvt_body.cpp | 2 +- src/BODY/fix_wall_body_polygon.cpp | 2 +- src/BODY/fix_wall_body_polyhedron.cpp | 2 +- src/BODY/pair_body_nparticle.cpp | 2 +- src/BODY/pair_body_rounded_polygon.cpp | 2 +- src/BODY/pair_body_rounded_polyhedron.cpp | 2 +- src/CLASS2/angle_class2.cpp | 2 +- src/CLASS2/bond_class2.cpp | 2 +- src/CLASS2/dihedral_class2.cpp | 2 +- src/CLASS2/improper_class2.cpp | 2 +- src/CLASS2/pair_lj_class2.cpp | 2 +- src/CLASS2/pair_lj_class2_coul_cut.cpp | 2 +- src/CLASS2/pair_lj_class2_coul_long.cpp | 2 +- src/COLLOID/fix_wall_colloid.cpp | 2 +- src/COLLOID/pair_brownian.cpp | 2 +- src/COLLOID/pair_brownian_poly.cpp | 2 +- src/COLLOID/pair_colloid.cpp | 2 +- src/COLLOID/pair_lubricate.cpp | 2 +- src/COLLOID/pair_lubricateU.cpp | 2 +- src/COLLOID/pair_lubricateU_poly.cpp | 2 +- src/COLLOID/pair_lubricate_poly.cpp | 2 +- src/COLLOID/pair_yukawa_colloid.cpp | 2 +- src/CORESHELL/compute_temp_cs.cpp | 2 +- src/CORESHELL/pair_born_coul_dsf_cs.cpp | 2 +- src/CORESHELL/pair_born_coul_long_cs.cpp | 2 +- src/CORESHELL/pair_born_coul_wolf_cs.cpp | 2 +- src/CORESHELL/pair_buck_coul_long_cs.cpp | 2 +- src/CORESHELL/pair_coul_long_cs.cpp | 2 +- src/CORESHELL/pair_coul_wolf_cs.cpp | 3 +-- src/CORESHELL/pair_lj_cut_coul_long_cs.cpp | 2 +- src/DIPOLE/atom_vec_dipole.cpp | 2 +- src/DIPOLE/pair_lj_cut_dipole_cut.cpp | 2 +- src/DIPOLE/pair_lj_cut_dipole_long.cpp | 2 +- src/DIPOLE/pair_lj_long_dipole_long.cpp | 2 +- src/GPU/fix_gpu.cpp | 2 +- src/GPU/pair_beck_gpu.cpp | 2 +- src/GPU/pair_born_coul_long_cs_gpu.cpp | 2 +- src/GPU/pair_born_coul_long_gpu.cpp | 2 +- src/GPU/pair_born_coul_wolf_cs_gpu.cpp | 2 +- src/GPU/pair_born_coul_wolf_gpu.cpp | 2 +- src/GPU/pair_born_gpu.cpp | 2 +- src/GPU/pair_buck_coul_cut_gpu.cpp | 2 +- src/GPU/pair_buck_coul_long_gpu.cpp | 2 +- src/GPU/pair_buck_gpu.cpp | 2 +- src/GPU/pair_colloid_gpu.cpp | 2 +- src/GPU/pair_coul_cut_gpu.cpp | 2 +- src/GPU/pair_coul_debye_gpu.cpp | 2 +- src/GPU/pair_coul_dsf_gpu.cpp | 2 +- src/GPU/pair_coul_long_cs_gpu.cpp | 2 +- src/GPU/pair_coul_long_gpu.cpp | 2 +- src/GPU/pair_dpd_gpu.cpp | 2 +- src/GPU/pair_dpd_tstat_gpu.cpp | 2 +- src/GPU/pair_eam_alloy_gpu.cpp | 2 +- src/GPU/pair_eam_fs_gpu.cpp | 2 +- src/GPU/pair_eam_gpu.cpp | 2 +- src/GPU/pair_gauss_gpu.cpp | 2 +- src/GPU/pair_gayberne_gpu.cpp | 2 +- src/GPU/pair_lj96_cut_gpu.cpp | 2 +- src/GPU/pair_lj_charmm_coul_long_gpu.cpp | 2 +- src/GPU/pair_lj_class2_coul_long_gpu.cpp | 2 +- src/GPU/pair_lj_class2_gpu.cpp | 2 +- src/GPU/pair_lj_cubic_gpu.cpp | 2 +- src/GPU/pair_lj_cut_coul_cut_gpu.cpp | 2 +- src/GPU/pair_lj_cut_coul_debye_gpu.cpp | 2 +- src/GPU/pair_lj_cut_coul_dsf_gpu.cpp | 2 +- src/GPU/pair_lj_cut_coul_long_gpu.cpp | 2 +- src/GPU/pair_lj_cut_coul_msm_gpu.cpp | 2 +- src/GPU/pair_lj_cut_dipole_cut_gpu.cpp | 2 +- src/GPU/pair_lj_cut_dipole_long_gpu.cpp | 2 +- src/GPU/pair_lj_cut_gpu.cpp | 2 +- src/GPU/pair_lj_expand_coul_long_gpu.cpp | 2 +- src/GPU/pair_lj_expand_gpu.cpp | 2 +- src/GPU/pair_lj_gromacs_gpu.cpp | 2 +- src/GPU/pair_lj_sdk_coul_long_gpu.cpp | 2 +- src/GPU/pair_lj_sdk_gpu.cpp | 2 +- src/GPU/pair_lj_sf_dipole_sf_gpu.cpp | 2 +- src/GPU/pair_mie_cut_gpu.cpp | 2 +- src/GPU/pair_morse_gpu.cpp | 2 +- src/GPU/pair_resquared_gpu.cpp | 2 +- src/GPU/pair_soft_gpu.cpp | 2 +- src/GPU/pair_sw_gpu.cpp | 2 +- src/GPU/pair_table_gpu.cpp | 2 +- src/GPU/pair_tersoff_gpu.cpp | 2 +- src/GPU/pair_tersoff_mod_gpu.cpp | 2 +- src/GPU/pair_tersoff_zbl_gpu.cpp | 2 +- src/GPU/pair_ufm_gpu.cpp | 2 +- src/GPU/pair_vashishta_gpu.cpp | 3 ++- src/GPU/pair_yukawa_colloid_gpu.cpp | 2 +- src/GPU/pair_yukawa_gpu.cpp | 2 +- src/GPU/pair_zbl_gpu.cpp | 2 +- src/GPU/pppm_gpu.cpp | 2 +- src/GRANULAR/fix_freeze.cpp | 2 +- src/GRANULAR/fix_pour.cpp | 2 +- src/GRANULAR/fix_wall_gran.cpp | 2 +- src/GRANULAR/fix_wall_gran_region.cpp | 2 +- src/GRANULAR/pair_gran_hertz_history.cpp | 2 +- src/GRANULAR/pair_gran_hooke.cpp | 2 +- src/GRANULAR/pair_gran_hooke_history.cpp | 2 +- src/GRANULAR/pair_granular.cpp | 2 +- src/KIM/kim_query.cpp | 2 +- src/KIM/pair_kim.cpp | 4 +--- src/KOKKOS/angle_charmm_kokkos.cpp | 2 +- src/KOKKOS/angle_class2_kokkos.cpp | 2 +- src/KOKKOS/angle_cosine_kokkos.cpp | 2 +- src/KOKKOS/angle_harmonic_kokkos.cpp | 2 +- src/KOKKOS/atom_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_angle_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_atomic_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_bond_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_charge_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_dpd_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_full_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_hybrid_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_molecular_kokkos.cpp | 2 +- src/KOKKOS/atom_vec_sphere_kokkos.cpp | 2 +- src/KOKKOS/bond_class2_kokkos.cpp | 2 +- src/KOKKOS/bond_fene_kokkos.cpp | 2 +- src/KOKKOS/bond_harmonic_kokkos.cpp | 2 +- src/KOKKOS/comm_tiled_kokkos.cpp | 2 +- src/KOKKOS/compute_temp_kokkos.cpp | 2 +- src/KOKKOS/dihedral_charmm_kokkos.cpp | 2 +- src/KOKKOS/dihedral_class2_kokkos.cpp | 2 +- src/KOKKOS/dihedral_opls_kokkos.cpp | 2 +- src/KOKKOS/fix_deform_kokkos.cpp | 2 +- src/KOKKOS/fix_dpd_energy_kokkos.cpp | 2 +- src/KOKKOS/fix_enforce2d_kokkos.cpp | 2 +- src/KOKKOS/fix_eos_table_rx_kokkos.cpp | 2 +- src/KOKKOS/fix_langevin_kokkos.cpp | 2 +- src/KOKKOS/fix_momentum_kokkos.cpp | 2 +- src/KOKKOS/fix_nh_kokkos.cpp | 2 +- src/KOKKOS/fix_nph_kokkos.cpp | 2 +- src/KOKKOS/fix_npt_kokkos.cpp | 2 +- src/KOKKOS/fix_nve_kokkos.cpp | 2 +- src/KOKKOS/fix_nvt_kokkos.cpp | 2 +- src/KOKKOS/fix_property_atom_kokkos.cpp | 2 +- src/KOKKOS/fix_qeq_reax_kokkos.cpp | 2 +- src/KOKKOS/fix_reaxc_bonds_kokkos.cpp | 2 +- src/KOKKOS/fix_reaxc_species_kokkos.cpp | 2 +- src/KOKKOS/fix_rx_kokkos.cpp | 2 +- src/KOKKOS/fix_setforce_kokkos.cpp | 2 +- src/KOKKOS/fix_shardlow_kokkos.cpp | 2 +- src/KOKKOS/fix_wall_lj93_kokkos.cpp | 2 +- src/KOKKOS/fix_wall_reflect_kokkos.cpp | 2 +- src/KOKKOS/gridcomm_kokkos.cpp | 2 +- src/KOKKOS/improper_class2_kokkos.cpp | 2 +- src/KOKKOS/improper_harmonic_kokkos.cpp | 2 +- src/KOKKOS/kokkos.cpp | 2 +- src/KOKKOS/math_special_kokkos.cpp | 2 +- src/KOKKOS/pair_buck_coul_cut_kokkos.cpp | 2 +- src/KOKKOS/pair_buck_coul_long_kokkos.cpp | 2 +- src/KOKKOS/pair_buck_kokkos.cpp | 2 +- src/KOKKOS/pair_coul_cut_kokkos.cpp | 2 +- src/KOKKOS/pair_coul_debye_kokkos.cpp | 2 +- src/KOKKOS/pair_coul_dsf_kokkos.cpp | 2 +- src/KOKKOS/pair_coul_long_kokkos.cpp | 2 +- src/KOKKOS/pair_coul_wolf_kokkos.cpp | 2 +- src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp | 3 +-- src/KOKKOS/pair_eam_alloy_kokkos.cpp | 2 +- src/KOKKOS/pair_eam_fs_kokkos.cpp | 2 +- src/KOKKOS/pair_eam_kokkos.cpp | 2 +- src/KOKKOS/pair_exp6_rx_kokkos.cpp | 2 +- src/KOKKOS/pair_hybrid_kokkos.cpp | 2 +- src/KOKKOS/pair_hybrid_overlay_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_class2_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_cut_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_expand_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_gromacs_kokkos.cpp | 2 +- src/KOKKOS/pair_lj_sdk_kokkos.cpp | 2 +- src/KOKKOS/pair_morse_kokkos.cpp | 2 +- src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp | 4 ++-- src/KOKKOS/pair_reaxc_kokkos.cpp | 2 +- src/KOKKOS/pair_sw_kokkos.cpp | 2 +- src/KOKKOS/pair_table_kokkos.cpp | 2 +- src/KOKKOS/pair_table_rx_kokkos.cpp | 2 +- src/KOKKOS/pair_tersoff_kokkos.cpp | 2 +- src/KOKKOS/pair_tersoff_mod_kokkos.cpp | 2 +- src/KOKKOS/pair_tersoff_zbl_kokkos.cpp | 2 +- src/KOKKOS/pair_vashishta_kokkos.cpp | 2 +- src/KOKKOS/pair_yukawa_kokkos.cpp | 3 ++- src/KOKKOS/pair_zbl_kokkos.cpp | 2 +- src/KOKKOS/pppm_kokkos.cpp | 2 +- src/KOKKOS/rand_pool_wrap_kokkos.cpp | 2 +- src/KOKKOS/region_block_kokkos.cpp | 2 +- src/KOKKOS/verlet_kokkos.cpp | 2 +- src/KSPACE/ewald.cpp | 2 +- src/KSPACE/ewald_dipole.cpp | 2 +- src/KSPACE/ewald_dipole_spin.cpp | 2 +- src/KSPACE/ewald_disp.cpp | 2 +- src/KSPACE/fft3d.cpp | 2 +- src/KSPACE/fft3d_wrap.cpp | 2 +- src/KSPACE/fix_tune_kspace.cpp | 2 +- src/KSPACE/gridcomm.cpp | 2 +- src/KSPACE/msm.cpp | 2 +- src/KSPACE/msm_cg.cpp | 2 +- src/KSPACE/pair_born_coul_long.cpp | 2 +- src/KSPACE/pair_born_coul_msm.cpp | 2 +- src/KSPACE/pair_buck_coul_long.cpp | 2 +- src/KSPACE/pair_buck_coul_msm.cpp | 2 +- src/KSPACE/pair_buck_long_coul_long.cpp | 2 +- src/KSPACE/pair_coul_long.cpp | 2 +- src/KSPACE/pair_coul_msm.cpp | 2 +- src/KSPACE/pair_lj_charmm_coul_long.cpp | 2 +- src/KSPACE/pair_lj_charmm_coul_msm.cpp | 2 +- src/KSPACE/pair_lj_charmmfsw_coul_long.cpp | 2 +- src/KSPACE/pair_lj_cut_coul_long.cpp | 2 +- src/KSPACE/pair_lj_cut_coul_msm.cpp | 2 +- src/KSPACE/pair_lj_cut_tip4p_long.cpp | 2 +- src/KSPACE/pair_lj_long_coul_long.cpp | 2 +- src/KSPACE/pair_lj_long_tip4p_long.cpp | 2 +- src/KSPACE/pair_tip4p_long.cpp | 2 +- src/KSPACE/pppm.cpp | 2 +- src/KSPACE/pppm_cg.cpp | 4 +--- src/KSPACE/pppm_dipole.cpp | 2 +- src/KSPACE/pppm_dipole_spin.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 +- src/KSPACE/remap.cpp | 2 +- src/KSPACE/remap_wrap.cpp | 2 +- 253 files changed, 256 insertions(+), 260 deletions(-) diff --git a/src/ASPHERE/compute_erotate_asphere.cpp b/src/ASPHERE/compute_erotate_asphere.cpp index afec2a9b28..665506acdf 100644 --- a/src/ASPHERE/compute_erotate_asphere.cpp +++ b/src/ASPHERE/compute_erotate_asphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_erotate_asphere.h" +#include #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/ASPHERE/compute_temp_asphere.cpp b/src/ASPHERE/compute_temp_asphere.cpp index 011d8cae80..32773b2925 100644 --- a/src/ASPHERE/compute_temp_asphere.cpp +++ b/src/ASPHERE/compute_temp_asphere.cpp @@ -15,9 +15,9 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "compute_temp_asphere.h" #include #include -#include "compute_temp_asphere.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/ASPHERE/fix_nh_asphere.cpp b/src/ASPHERE/fix_nh_asphere.cpp index 828c064a52..9e8e9d73d9 100644 --- a/src/ASPHERE/fix_nh_asphere.cpp +++ b/src/ASPHERE/fix_nh_asphere.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "fix_nh_asphere.h" #include #include #include #include "math_extra.h" -#include "fix_nh_asphere.h" #include "atom.h" #include "atom_vec_ellipsoid.h" #include "group.h" diff --git a/src/ASPHERE/fix_nph_asphere.cpp b/src/ASPHERE/fix_nph_asphere.cpp index 5f201a8463..70880701ca 100644 --- a/src/ASPHERE/fix_nph_asphere.cpp +++ b/src/ASPHERE/fix_nph_asphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nph_asphere.h" +#include #include "modify.h" #include "error.h" diff --git a/src/ASPHERE/fix_npt_asphere.cpp b/src/ASPHERE/fix_npt_asphere.cpp index 5d52891169..26d4fff81d 100644 --- a/src/ASPHERE/fix_npt_asphere.cpp +++ b/src/ASPHERE/fix_npt_asphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_npt_asphere.h" +#include #include "modify.h" #include "error.h" diff --git a/src/ASPHERE/fix_nve_asphere.cpp b/src/ASPHERE/fix_nve_asphere.cpp index 61e3c35293..05219e442f 100644 --- a/src/ASPHERE/fix_nve_asphere.cpp +++ b/src/ASPHERE/fix_nve_asphere.cpp @@ -15,10 +15,10 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "fix_nve_asphere.h" #include #include #include -#include "fix_nve_asphere.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/ASPHERE/fix_nve_asphere_noforce.cpp b/src/ASPHERE/fix_nve_asphere_noforce.cpp index 9cc430592a..015cc8cfb6 100644 --- a/src/ASPHERE/fix_nve_asphere_noforce.cpp +++ b/src/ASPHERE/fix_nve_asphere_noforce.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nve_asphere_noforce.h" #include #include #include -#include "fix_nve_asphere_noforce.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/ASPHERE/fix_nve_line.cpp b/src/ASPHERE/fix_nve_line.cpp index 51a502df89..57335f22e0 100644 --- a/src/ASPHERE/fix_nve_line.cpp +++ b/src/ASPHERE/fix_nve_line.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nve_line.h" #include #include #include -#include "fix_nve_line.h" #include "atom.h" #include "atom_vec_line.h" #include "domain.h" diff --git a/src/ASPHERE/fix_nve_tri.cpp b/src/ASPHERE/fix_nve_tri.cpp index fb9bf64c58..b1f7667d06 100644 --- a/src/ASPHERE/fix_nve_tri.cpp +++ b/src/ASPHERE/fix_nve_tri.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nve_tri.h" #include #include #include -#include "fix_nve_tri.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_tri.h" diff --git a/src/ASPHERE/fix_nvt_asphere.cpp b/src/ASPHERE/fix_nvt_asphere.cpp index 5ef91923eb..597fb03514 100644 --- a/src/ASPHERE/fix_nvt_asphere.cpp +++ b/src/ASPHERE/fix_nvt_asphere.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nvt_asphere.h" +#include #include "group.h" #include "modify.h" #include "error.h" diff --git a/src/ASPHERE/pair_gayberne.cpp b/src/ASPHERE/pair_gayberne.cpp index 3d4ed3f183..7dbf11c5ea 100644 --- a/src/ASPHERE/pair_gayberne.cpp +++ b/src/ASPHERE/pair_gayberne.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_gayberne.h" #include #include #include #include -#include "pair_gayberne.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/ASPHERE/pair_line_lj.cpp b/src/ASPHERE/pair_line_lj.cpp index 4873b44dc4..0cb603c4fa 100644 --- a/src/ASPHERE/pair_line_lj.cpp +++ b/src/ASPHERE/pair_line_lj.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_line_lj.h" #include #include #include #include -#include "pair_line_lj.h" #include "atom.h" #include "atom_vec_line.h" #include "force.h" diff --git a/src/ASPHERE/pair_resquared.cpp b/src/ASPHERE/pair_resquared.cpp index b100a5f184..ba73c5ba0c 100644 --- a/src/ASPHERE/pair_resquared.cpp +++ b/src/ASPHERE/pair_resquared.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_resquared.h" #include #include #include #include -#include "pair_resquared.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/ASPHERE/pair_tri_lj.cpp b/src/ASPHERE/pair_tri_lj.cpp index cefd73f976..3dde2a4f44 100644 --- a/src/ASPHERE/pair_tri_lj.cpp +++ b/src/ASPHERE/pair_tri_lj.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_tri_lj.h" #include #include #include #include -#include "pair_tri_lj.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_tri.h" diff --git a/src/BODY/body_nparticle.cpp b/src/BODY/body_nparticle.cpp index b2d9dbaca3..353ce5550c 100644 --- a/src/BODY/body_nparticle.cpp +++ b/src/BODY/body_nparticle.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "body_nparticle.h" #include #include -#include "body_nparticle.h" #include "my_pool_chunk.h" #include "math_extra.h" #include "atom_vec_body.h" diff --git a/src/BODY/body_rounded_polygon.cpp b/src/BODY/body_rounded_polygon.cpp index 6e1e49319e..21f1d7e221 100644 --- a/src/BODY/body_rounded_polygon.cpp +++ b/src/BODY/body_rounded_polygon.cpp @@ -15,9 +15,9 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "body_rounded_polygon.h" #include #include -#include "body_rounded_polygon.h" #include "my_pool_chunk.h" #include "atom_vec_body.h" #include "atom.h" diff --git a/src/BODY/body_rounded_polyhedron.cpp b/src/BODY/body_rounded_polyhedron.cpp index 4b5208c397..15e1871e02 100644 --- a/src/BODY/body_rounded_polyhedron.cpp +++ b/src/BODY/body_rounded_polyhedron.cpp @@ -15,9 +15,9 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "body_rounded_polyhedron.h" #include #include -#include "body_rounded_polyhedron.h" #include "my_pool_chunk.h" #include "atom_vec_body.h" #include "atom.h" diff --git a/src/BODY/compute_body_local.cpp b/src/BODY/compute_body_local.cpp index 20f7d76708..f58b66c2ca 100644 --- a/src/BODY/compute_body_local.cpp +++ b/src/BODY/compute_body_local.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_body_local.h" #include #include -#include "compute_body_local.h" #include "atom.h" #include "atom_vec_body.h" #include "body.h" diff --git a/src/BODY/compute_temp_body.cpp b/src/BODY/compute_temp_body.cpp index 5446fb6d64..7beca36df8 100644 --- a/src/BODY/compute_temp_body.cpp +++ b/src/BODY/compute_temp_body.cpp @@ -16,9 +16,9 @@ based on ComputeTempAsphere ------------------------------------------------------------------------- */ +#include "compute_temp_body.h" #include #include -#include "compute_temp_body.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" diff --git a/src/BODY/fix_nh_body.cpp b/src/BODY/fix_nh_body.cpp index 9739842419..6064f1f9de 100644 --- a/src/BODY/fix_nh_body.cpp +++ b/src/BODY/fix_nh_body.cpp @@ -16,11 +16,11 @@ based on FixNHAsphere ------------------------------------------------------------------------- */ +#include "fix_nh_body.h" #include #include #include #include "math_extra.h" -#include "fix_nh_body.h" #include "atom.h" #include "atom_vec_body.h" #include "group.h" diff --git a/src/BODY/fix_nph_body.cpp b/src/BODY/fix_nph_body.cpp index e647488bce..a65c951c96 100644 --- a/src/BODY/fix_nph_body.cpp +++ b/src/BODY/fix_nph_body.cpp @@ -15,8 +15,8 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ -#include #include "fix_nph_body.h" +#include #include "modify.h" #include "error.h" diff --git a/src/BODY/fix_npt_body.cpp b/src/BODY/fix_npt_body.cpp index 3c30e9e4e9..7e8097486e 100644 --- a/src/BODY/fix_npt_body.cpp +++ b/src/BODY/fix_npt_body.cpp @@ -15,8 +15,8 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ -#include #include "fix_npt_body.h" +#include #include "modify.h" #include "error.h" diff --git a/src/BODY/fix_nve_body.cpp b/src/BODY/fix_nve_body.cpp index 0c74facf34..3f3bd41cbc 100644 --- a/src/BODY/fix_nve_body.cpp +++ b/src/BODY/fix_nve_body.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nve_body.h" #include #include #include -#include "fix_nve_body.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" diff --git a/src/BODY/fix_nvt_body.cpp b/src/BODY/fix_nvt_body.cpp index 273b5e7fff..efb05143a1 100644 --- a/src/BODY/fix_nvt_body.cpp +++ b/src/BODY/fix_nvt_body.cpp @@ -15,8 +15,8 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ -#include #include "fix_nvt_body.h" +#include #include "group.h" #include "modify.h" #include "error.h" diff --git a/src/BODY/fix_wall_body_polygon.cpp b/src/BODY/fix_wall_body_polygon.cpp index 221937461b..8f27a094cb 100644 --- a/src/BODY/fix_wall_body_polygon.cpp +++ b/src/BODY/fix_wall_body_polygon.cpp @@ -15,10 +15,10 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "fix_wall_body_polygon.h" #include #include #include -#include "fix_wall_body_polygon.h" #include "atom.h" #include "atom_vec_body.h" #include "body_rounded_polygon.h" diff --git a/src/BODY/fix_wall_body_polyhedron.cpp b/src/BODY/fix_wall_body_polyhedron.cpp index 24a9e51dad..37b542803f 100644 --- a/src/BODY/fix_wall_body_polyhedron.cpp +++ b/src/BODY/fix_wall_body_polyhedron.cpp @@ -15,10 +15,10 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "fix_wall_body_polyhedron.h" #include #include #include -#include "fix_wall_body_polyhedron.h" #include "atom.h" #include "atom_vec_body.h" #include "body_rounded_polyhedron.h" diff --git a/src/BODY/pair_body_nparticle.cpp b/src/BODY/pair_body_nparticle.cpp index f2eb2aa520..96a7af6255 100644 --- a/src/BODY/pair_body_nparticle.cpp +++ b/src/BODY/pair_body_nparticle.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_body_nparticle.h" #include #include #include #include -#include "pair_body_nparticle.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" diff --git a/src/BODY/pair_body_rounded_polygon.cpp b/src/BODY/pair_body_rounded_polygon.cpp index 69495ea57f..c818b5a2e6 100644 --- a/src/BODY/pair_body_rounded_polygon.cpp +++ b/src/BODY/pair_body_rounded_polygon.cpp @@ -18,11 +18,11 @@ the contact history for friction forces. ------------------------------------------------------------------------- */ +#include "pair_body_rounded_polygon.h" #include #include #include #include -#include "pair_body_rounded_polygon.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" diff --git a/src/BODY/pair_body_rounded_polyhedron.cpp b/src/BODY/pair_body_rounded_polyhedron.cpp index 60f6df3582..75caab88bd 100644 --- a/src/BODY/pair_body_rounded_polyhedron.cpp +++ b/src/BODY/pair_body_rounded_polyhedron.cpp @@ -20,11 +20,11 @@ the contact history for friction forces. ------------------------------------------------------------------------- */ +#include "pair_body_rounded_polyhedron.h" #include #include #include #include -#include "pair_body_rounded_polyhedron.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" diff --git a/src/CLASS2/angle_class2.cpp b/src/CLASS2/angle_class2.cpp index d550767e5e..340152abd4 100644 --- a/src/CLASS2/angle_class2.cpp +++ b/src/CLASS2/angle_class2.cpp @@ -15,10 +15,10 @@ Contributing author: Eric Simon (Cray) ------------------------------------------------------------------------- */ +#include "angle_class2.h" #include #include #include -#include "angle_class2.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/CLASS2/bond_class2.cpp b/src/CLASS2/bond_class2.cpp index 26c4e63a4d..945555f772 100644 --- a/src/CLASS2/bond_class2.cpp +++ b/src/CLASS2/bond_class2.cpp @@ -15,9 +15,9 @@ Contributing author: Eric Simon (Cray) ------------------------------------------------------------------------- */ +#include "bond_class2.h" #include #include -#include "bond_class2.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/CLASS2/dihedral_class2.cpp b/src/CLASS2/dihedral_class2.cpp index c471b1f353..c36d976525 100644 --- a/src/CLASS2/dihedral_class2.cpp +++ b/src/CLASS2/dihedral_class2.cpp @@ -15,10 +15,10 @@ Contributing author: Eric Simon (Cray) ------------------------------------------------------------------------- */ +#include "dihedral_class2.h" #include #include #include -#include "dihedral_class2.h" #include "atom.h" #include "neighbor.h" #include "update.h" diff --git a/src/CLASS2/improper_class2.cpp b/src/CLASS2/improper_class2.cpp index ccb81aebd9..aff37df318 100644 --- a/src/CLASS2/improper_class2.cpp +++ b/src/CLASS2/improper_class2.cpp @@ -15,10 +15,10 @@ Contributing author: Eric Simon (Cray) ------------------------------------------------------------------------- */ +#include "improper_class2.h" #include #include #include -#include "improper_class2.h" #include "atom.h" #include "neighbor.h" #include "update.h" diff --git a/src/CLASS2/pair_lj_class2.cpp b/src/CLASS2/pair_lj_class2.cpp index 60b988926a..9a67fafecb 100644 --- a/src/CLASS2/pair_lj_class2.cpp +++ b/src/CLASS2/pair_lj_class2.cpp @@ -9,11 +9,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_class2.h" #include #include #include #include -#include "pair_lj_class2.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CLASS2/pair_lj_class2_coul_cut.cpp b/src/CLASS2/pair_lj_class2_coul_cut.cpp index 8dc038b8fc..24620611c6 100644 --- a/src/CLASS2/pair_lj_class2_coul_cut.cpp +++ b/src/CLASS2/pair_lj_class2_coul_cut.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_class2_coul_cut.h" #include #include #include #include -#include "pair_lj_class2_coul_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CLASS2/pair_lj_class2_coul_long.cpp b/src/CLASS2/pair_lj_class2_coul_long.cpp index c92c7b78f1..cd11294327 100644 --- a/src/CLASS2/pair_lj_class2_coul_long.cpp +++ b/src/CLASS2/pair_lj_class2_coul_long.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_class2_coul_long.h" #include #include #include #include -#include "pair_lj_class2_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/COLLOID/fix_wall_colloid.cpp b/src/COLLOID/fix_wall_colloid.cpp index 095d01eef3..f2e895c4f3 100644 --- a/src/COLLOID/fix_wall_colloid.cpp +++ b/src/COLLOID/fix_wall_colloid.cpp @@ -15,9 +15,9 @@ Contributing authors: Jeremy Lechman (SNL) ------------------------------------------------------------------------- */ +#include "fix_wall_colloid.h" #include #include -#include "fix_wall_colloid.h" #include "atom.h" #include "atom_vec.h" #include "update.h" diff --git a/src/COLLOID/pair_brownian.cpp b/src/COLLOID/pair_brownian.cpp index aefa96b1fb..f9185264e0 100644 --- a/src/COLLOID/pair_brownian.cpp +++ b/src/COLLOID/pair_brownian.cpp @@ -15,11 +15,11 @@ Contributing authors: Amit Kumar and Michael Bybee (UIUC) ------------------------------------------------------------------------- */ +#include "pair_brownian.h" #include #include #include #include -#include "pair_brownian.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/COLLOID/pair_brownian_poly.cpp b/src/COLLOID/pair_brownian_poly.cpp index 389ae084b7..250dcef1fd 100644 --- a/src/COLLOID/pair_brownian_poly.cpp +++ b/src/COLLOID/pair_brownian_poly.cpp @@ -16,11 +16,11 @@ Dave Heine (Corning), polydispersity ------------------------------------------------------------------------- */ +#include "pair_brownian_poly.h" #include #include #include #include -#include "pair_brownian_poly.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/COLLOID/pair_colloid.cpp b/src/COLLOID/pair_colloid.cpp index 04c35a7c00..306cdfebdf 100644 --- a/src/COLLOID/pair_colloid.cpp +++ b/src/COLLOID/pair_colloid.cpp @@ -15,11 +15,11 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "pair_colloid.h" #include #include #include #include -#include "pair_colloid.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/COLLOID/pair_lubricate.cpp b/src/COLLOID/pair_lubricate.cpp index 4e629bd442..ee55c6cbf5 100644 --- a/src/COLLOID/pair_lubricate.cpp +++ b/src/COLLOID/pair_lubricate.cpp @@ -16,11 +16,11 @@ Amit Kumar and Michael Bybee (UIUC) ------------------------------------------------------------------------- */ +#include "pair_lubricate.h" #include #include #include #include -#include "pair_lubricate.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/COLLOID/pair_lubricateU.cpp b/src/COLLOID/pair_lubricateU.cpp index 3ea3d4fe4a..be589167c9 100644 --- a/src/COLLOID/pair_lubricateU.cpp +++ b/src/COLLOID/pair_lubricateU.cpp @@ -15,12 +15,12 @@ Contributing authors: Amit Kumar and Michael Bybee (UIUC) ------------------------------------------------------------------------- */ +#include "pair_lubricateU.h" #include #include #include #include #include -#include "pair_lubricateU.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/COLLOID/pair_lubricateU_poly.cpp b/src/COLLOID/pair_lubricateU_poly.cpp index 4fec95dcd8..ebcf939cff 100644 --- a/src/COLLOID/pair_lubricateU_poly.cpp +++ b/src/COLLOID/pair_lubricateU_poly.cpp @@ -17,12 +17,12 @@ Dave Heine (Corning), polydispersity ------------------------------------------------------------------------- */ +#include "pair_lubricateU_poly.h" #include #include #include #include #include -#include "pair_lubricateU_poly.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/COLLOID/pair_lubricate_poly.cpp b/src/COLLOID/pair_lubricate_poly.cpp index ffbe7fce3c..f1bfa0c695 100644 --- a/src/COLLOID/pair_lubricate_poly.cpp +++ b/src/COLLOID/pair_lubricate_poly.cpp @@ -17,11 +17,11 @@ Dave Heine (Corning), polydispersity ------------------------------------------------------------------------- */ +#include "pair_lubricate_poly.h" #include #include #include #include -#include "pair_lubricate_poly.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/COLLOID/pair_yukawa_colloid.cpp b/src/COLLOID/pair_yukawa_colloid.cpp index ab7d088508..98d0586925 100644 --- a/src/COLLOID/pair_yukawa_colloid.cpp +++ b/src/COLLOID/pair_yukawa_colloid.cpp @@ -15,9 +15,9 @@ Contributing authors: Randy Schunk (Sandia) ------------------------------------------------------------------------- */ +#include "pair_yukawa_colloid.h" #include #include -#include "pair_yukawa_colloid.h" #include "atom.h" #include "atom_vec.h" #include "force.h" diff --git a/src/CORESHELL/compute_temp_cs.cpp b/src/CORESHELL/compute_temp_cs.cpp index 03ebfa154d..4217fe3410 100644 --- a/src/CORESHELL/compute_temp_cs.cpp +++ b/src/CORESHELL/compute_temp_cs.cpp @@ -16,11 +16,11 @@ (hendrik.heenen at mytum.com) ------------------------------------------------------------------------- */ +#include "compute_temp_cs.h" #include #include #include #include -#include "compute_temp_cs.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/CORESHELL/pair_born_coul_dsf_cs.cpp b/src/CORESHELL/pair_born_coul_dsf_cs.cpp index f4d7447ade..cd932e560b 100644 --- a/src/CORESHELL/pair_born_coul_dsf_cs.cpp +++ b/src/CORESHELL/pair_born_coul_dsf_cs.cpp @@ -16,11 +16,11 @@ References: Fennell and Gezelter, JCP 124, 234104 (2006) ------------------------------------------------------------------------- */ +#include "pair_born_coul_dsf_cs.h" #include #include #include #include -#include "pair_born_coul_dsf_cs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CORESHELL/pair_born_coul_long_cs.cpp b/src/CORESHELL/pair_born_coul_long_cs.cpp index a19f8c34a8..2ef7fdb273 100644 --- a/src/CORESHELL/pair_born_coul_long_cs.cpp +++ b/src/CORESHELL/pair_born_coul_long_cs.cpp @@ -15,11 +15,11 @@ Contributing author: Hendrik Heenen (hendrik.heenen@mytum.de) ------------------------------------------------------------------------- */ +#include "pair_born_coul_long_cs.h" #include #include #include #include -#include "pair_born_coul_long_cs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CORESHELL/pair_born_coul_wolf_cs.cpp b/src/CORESHELL/pair_born_coul_wolf_cs.cpp index 7b52c28664..c0374e2ddb 100644 --- a/src/CORESHELL/pair_born_coul_wolf_cs.cpp +++ b/src/CORESHELL/pair_born_coul_wolf_cs.cpp @@ -12,11 +12,11 @@ ------------------------------------------------------------------------- */ +#include "pair_born_coul_wolf_cs.h" #include #include #include #include -#include "pair_born_coul_wolf_cs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CORESHELL/pair_buck_coul_long_cs.cpp b/src/CORESHELL/pair_buck_coul_long_cs.cpp index 8df91f39a3..6c897622fa 100644 --- a/src/CORESHELL/pair_buck_coul_long_cs.cpp +++ b/src/CORESHELL/pair_buck_coul_long_cs.cpp @@ -15,11 +15,11 @@ Contributing author: Hendrik Heenen (hendrik.heenen@mytum.de) ------------------------------------------------------------------------- */ +#include "pair_buck_coul_long_cs.h" #include #include #include #include -#include "pair_buck_coul_long_cs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CORESHELL/pair_coul_long_cs.cpp b/src/CORESHELL/pair_coul_long_cs.cpp index c8c8387d6d..6094ae072a 100644 --- a/src/CORESHELL/pair_coul_long_cs.cpp +++ b/src/CORESHELL/pair_coul_long_cs.cpp @@ -15,11 +15,11 @@ Contributing author: Hendrik Heenen (hendrik.heenen@mytum.de) ------------------------------------------------------------------------- */ +#include "pair_coul_long_cs.h" #include #include #include #include -#include "pair_coul_long_cs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CORESHELL/pair_coul_wolf_cs.cpp b/src/CORESHELL/pair_coul_wolf_cs.cpp index 36e037bfc8..40ade7bfe4 100644 --- a/src/CORESHELL/pair_coul_wolf_cs.cpp +++ b/src/CORESHELL/pair_coul_wolf_cs.cpp @@ -11,12 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ - +#include "pair_coul_wolf_cs.h" #include #include #include #include -#include "pair_coul_wolf_cs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp b/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp index 56c75f0f5d..3f20377cf1 100644 --- a/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp +++ b/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp @@ -15,11 +15,11 @@ Contributing author: Hendrik Heenen (hendrik.heenen@mytum.de) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_long_cs.h" #include #include #include #include -#include "pair_lj_cut_coul_long_cs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/DIPOLE/atom_vec_dipole.cpp b/src/DIPOLE/atom_vec_dipole.cpp index c304ae3bc6..67e5aa9e70 100644 --- a/src/DIPOLE/atom_vec_dipole.cpp +++ b/src/DIPOLE/atom_vec_dipole.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_dipole.h" #include #include -#include "atom_vec_dipole.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/DIPOLE/pair_lj_cut_dipole_cut.cpp b/src/DIPOLE/pair_lj_cut_dipole_cut.cpp index 18b78c55e0..44708edec9 100644 --- a/src/DIPOLE/pair_lj_cut_dipole_cut.cpp +++ b/src/DIPOLE/pair_lj_cut_dipole_cut.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_cut_dipole_cut.h" #include #include #include -#include "pair_lj_cut_dipole_cut.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/DIPOLE/pair_lj_cut_dipole_long.cpp b/src/DIPOLE/pair_lj_cut_dipole_long.cpp index 42446a3777..071dbaeb02 100644 --- a/src/DIPOLE/pair_lj_cut_dipole_long.cpp +++ b/src/DIPOLE/pair_lj_cut_dipole_long.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_cut_dipole_long.h" #include #include #include #include -#include "pair_lj_cut_dipole_long.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/DIPOLE/pair_lj_long_dipole_long.cpp b/src/DIPOLE/pair_lj_long_dipole_long.cpp index fbdc47a15b..1391cc1a1a 100644 --- a/src/DIPOLE/pair_lj_long_dipole_long.cpp +++ b/src/DIPOLE/pair_lj_long_dipole_long.cpp @@ -15,13 +15,13 @@ Contributing author: Pieter J. in 't Veld and Stan Moore (Sandia) ------------------------------------------------------------------------- */ +#include "pair_lj_long_dipole_long.h" #include #include #include #include #include "math_const.h" #include "math_vector.h" -#include "pair_lj_long_dipole_long.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/GPU/fix_gpu.cpp b/src/GPU/fix_gpu.cpp index f0558e6a02..d4397503dc 100644 --- a/src/GPU/fix_gpu.cpp +++ b/src/GPU/fix_gpu.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_gpu.h" #include #include -#include "fix_gpu.h" #include "atom.h" #include "force.h" #include "pair.h" diff --git a/src/GPU/pair_beck_gpu.cpp b/src/GPU/pair_beck_gpu.cpp index 9f76975ef1..d4d36a5837 100644 --- a/src/GPU/pair_beck_gpu.cpp +++ b/src/GPU/pair_beck_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_beck_gpu.h" #include #include #include #include -#include "pair_beck_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_born_coul_long_cs_gpu.cpp b/src/GPU/pair_born_coul_long_cs_gpu.cpp index 291ad8ad1f..7314024d71 100644 --- a/src/GPU/pair_born_coul_long_cs_gpu.cpp +++ b/src/GPU/pair_born_coul_long_cs_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (Northwestern) ------------------------------------------------------------------------- */ +#include "pair_born_coul_long_cs_gpu.h" #include #include #include #include -#include "pair_born_coul_long_cs_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_born_coul_long_gpu.cpp b/src/GPU/pair_born_coul_long_gpu.cpp index eb204691c7..79c0d5f147 100644 --- a/src/GPU/pair_born_coul_long_gpu.cpp +++ b/src/GPU/pair_born_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_born_coul_long_gpu.h" #include #include #include #include -#include "pair_born_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_born_coul_wolf_cs_gpu.cpp b/src/GPU/pair_born_coul_wolf_cs_gpu.cpp index 4877a442b5..5f74d3fc7c 100644 --- a/src/GPU/pair_born_coul_wolf_cs_gpu.cpp +++ b/src/GPU/pair_born_coul_wolf_cs_gpu.cpp @@ -15,11 +15,11 @@ Contributing authors: Trung Dac Nguyen (Northwestern) ------------------------------------------------------------------------- */ +#include "pair_born_coul_wolf_cs_gpu.h" #include #include #include #include -#include "pair_born_coul_wolf_cs_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_born_coul_wolf_gpu.cpp b/src/GPU/pair_born_coul_wolf_gpu.cpp index 851174988b..693c2abffb 100644 --- a/src/GPU/pair_born_coul_wolf_gpu.cpp +++ b/src/GPU/pair_born_coul_wolf_gpu.cpp @@ -15,11 +15,11 @@ Contributing authors: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_born_coul_wolf_gpu.h" #include #include #include #include -#include "pair_born_coul_wolf_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_born_gpu.cpp b/src/GPU/pair_born_gpu.cpp index 253d2d7282..e9edc4f1c2 100644 --- a/src/GPU/pair_born_gpu.cpp +++ b/src/GPU/pair_born_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_born_gpu.h" #include #include #include #include -#include "pair_born_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_buck_coul_cut_gpu.cpp b/src/GPU/pair_buck_coul_cut_gpu.cpp index ed602f9cab..182673fb0d 100644 --- a/src/GPU/pair_buck_coul_cut_gpu.cpp +++ b/src/GPU/pair_buck_coul_cut_gpu.cpp @@ -15,11 +15,11 @@ Contributing authors: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_buck_coul_cut_gpu.h" #include #include #include #include -#include "pair_buck_coul_cut_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_buck_coul_long_gpu.cpp b/src/GPU/pair_buck_coul_long_gpu.cpp index d6b9e53282..75e784fafa 100644 --- a/src/GPU/pair_buck_coul_long_gpu.cpp +++ b/src/GPU/pair_buck_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_buck_coul_long_gpu.h" #include #include #include #include -#include "pair_buck_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_buck_gpu.cpp b/src/GPU/pair_buck_gpu.cpp index 8c85407e6e..1559c45b88 100644 --- a/src/GPU/pair_buck_gpu.cpp +++ b/src/GPU/pair_buck_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_buck_gpu.h" #include #include #include #include -#include "pair_buck_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_colloid_gpu.cpp b/src/GPU/pair_colloid_gpu.cpp index 0ee8708b5b..4db18dbc52 100644 --- a/src/GPU/pair_colloid_gpu.cpp +++ b/src/GPU/pair_colloid_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_colloid_gpu.h" #include #include #include #include -#include "pair_colloid_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_coul_cut_gpu.cpp b/src/GPU/pair_coul_cut_gpu.cpp index fb50c446b1..8a3eb12f8d 100644 --- a/src/GPU/pair_coul_cut_gpu.cpp +++ b/src/GPU/pair_coul_cut_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen ------------------------------------------------------------------------- */ +#include "pair_coul_cut_gpu.h" #include #include #include #include -#include "pair_coul_cut_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_coul_debye_gpu.cpp b/src/GPU/pair_coul_debye_gpu.cpp index ec771a9935..1fc07f8dac 100644 --- a/src/GPU/pair_coul_debye_gpu.cpp +++ b/src/GPU/pair_coul_debye_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ndtrung@umich.edu) ------------------------------------------------------------------------- */ +#include "pair_coul_debye_gpu.h" #include #include #include #include -#include "pair_coul_debye_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_coul_dsf_gpu.cpp b/src/GPU/pair_coul_dsf_gpu.cpp index 1753b8a91c..408be036dd 100644 --- a/src/GPU/pair_coul_dsf_gpu.cpp +++ b/src/GPU/pair_coul_dsf_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_coul_dsf_gpu.h" #include #include #include #include -#include "pair_coul_dsf_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_coul_long_cs_gpu.cpp b/src/GPU/pair_coul_long_cs_gpu.cpp index 6ca00d6361..c70424e472 100644 --- a/src/GPU/pair_coul_long_cs_gpu.cpp +++ b/src/GPU/pair_coul_long_cs_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Nguyen (Northwestern) ------------------------------------------------------------------------- */ +#include "pair_coul_long_cs_gpu.h" #include #include #include #include -#include "pair_coul_long_cs_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_coul_long_gpu.cpp b/src/GPU/pair_coul_long_gpu.cpp index f75d10b6dd..9623c25f2f 100644 --- a/src/GPU/pair_coul_long_gpu.cpp +++ b/src/GPU/pair_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Axel Kohlmeyer (Temple) ------------------------------------------------------------------------- */ +#include "pair_coul_long_gpu.h" #include #include #include #include -#include "pair_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_dpd_gpu.cpp b/src/GPU/pair_dpd_gpu.cpp index b1e45fbecd..5fcad6a350 100644 --- a/src/GPU/pair_dpd_gpu.cpp +++ b/src/GPU/pair_dpd_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_dpd_gpu.h" #include #include #include #include -#include "pair_dpd_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_dpd_tstat_gpu.cpp b/src/GPU/pair_dpd_tstat_gpu.cpp index 0693a27344..2d6798a12d 100644 --- a/src/GPU/pair_dpd_tstat_gpu.cpp +++ b/src/GPU/pair_dpd_tstat_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_dpd_tstat_gpu.h" #include #include #include #include -#include "pair_dpd_tstat_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_eam_alloy_gpu.cpp b/src/GPU/pair_eam_alloy_gpu.cpp index 9b3412d3d1..bc55c66676 100644 --- a/src/GPU/pair_eam_alloy_gpu.cpp +++ b/src/GPU/pair_eam_alloy_gpu.cpp @@ -15,10 +15,10 @@ Contributing authors: Trung Dac Nguyen (ORNL), W. Michael Brown (ORNL) ------------------------------------------------------------------------- */ +#include "pair_eam_alloy_gpu.h" #include #include #include -#include "pair_eam_alloy_gpu.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/GPU/pair_eam_fs_gpu.cpp b/src/GPU/pair_eam_fs_gpu.cpp index 11ef28af3e..ac379a9ce6 100644 --- a/src/GPU/pair_eam_fs_gpu.cpp +++ b/src/GPU/pair_eam_fs_gpu.cpp @@ -15,10 +15,10 @@ Contributing authors: Trung Dac Nguyen (ORNL), W. Michael Brown (ORNL) ------------------------------------------------------------------------- */ +#include "pair_eam_fs_gpu.h" #include #include #include -#include "pair_eam_fs_gpu.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/GPU/pair_eam_gpu.cpp b/src/GPU/pair_eam_gpu.cpp index 4788a72417..57106f48a4 100644 --- a/src/GPU/pair_eam_gpu.cpp +++ b/src/GPU/pair_eam_gpu.cpp @@ -15,11 +15,11 @@ Contributing authors: Trung Dac Nguyen (ORNL), W. Michael Brown (ORNL) ------------------------------------------------------------------------- */ +#include "pair_eam_gpu.h" #include #include #include #include -#include "pair_eam_gpu.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/GPU/pair_gauss_gpu.cpp b/src/GPU/pair_gauss_gpu.cpp index c596a9d644..842b84acf2 100644 --- a/src/GPU/pair_gauss_gpu.cpp +++ b/src/GPU/pair_gauss_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_gauss_gpu.h" #include #include #include #include -#include "pair_gauss_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_gayberne_gpu.cpp b/src/GPU/pair_gayberne_gpu.cpp index 4ed2750e57..f00accda15 100644 --- a/src/GPU/pair_gayberne_gpu.cpp +++ b/src/GPU/pair_gayberne_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_gayberne_gpu.h" #include #include #include #include -#include "pair_gayberne_gpu.h" #include "math_extra.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/GPU/pair_lj96_cut_gpu.cpp b/src/GPU/pair_lj96_cut_gpu.cpp index 5bc30c809d..16b6b835c0 100644 --- a/src/GPU/pair_lj96_cut_gpu.cpp +++ b/src/GPU/pair_lj96_cut_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj96_cut_gpu.h" #include #include #include #include -#include "pair_lj96_cut_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_charmm_coul_long_gpu.cpp b/src/GPU/pair_lj_charmm_coul_long_gpu.cpp index 134295c69f..bacbb400b1 100644 --- a/src/GPU/pair_lj_charmm_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_charmm_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_long_gpu.h" #include #include #include #include -#include "pair_lj_charmm_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_class2_coul_long_gpu.cpp b/src/GPU/pair_lj_class2_coul_long_gpu.cpp index fdffb06a8d..e34dbb0f99 100644 --- a/src/GPU/pair_lj_class2_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_class2_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_class2_coul_long_gpu.h" #include #include #include #include -#include "pair_lj_class2_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_class2_gpu.cpp b/src/GPU/pair_lj_class2_gpu.cpp index bbb9168169..68f27598f3 100644 --- a/src/GPU/pair_lj_class2_gpu.cpp +++ b/src/GPU/pair_lj_class2_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_class2_gpu.h" #include #include #include #include -#include "pair_lj_class2_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cubic_gpu.cpp b/src/GPU/pair_lj_cubic_gpu.cpp index 95eee6ae8f..542de37840 100644 --- a/src/GPU/pair_lj_cubic_gpu.cpp +++ b/src/GPU/pair_lj_cubic_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "pair_lj_cubic_gpu.h" #include #include #include #include -#include "pair_lj_cubic_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_coul_cut_gpu.cpp b/src/GPU/pair_lj_cut_coul_cut_gpu.cpp index 69fefbcdea..cf3dd711dc 100644 --- a/src/GPU/pair_lj_cut_coul_cut_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_cut_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_cut_gpu.h" #include #include #include #include -#include "pair_lj_cut_coul_cut_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_coul_debye_gpu.cpp b/src/GPU/pair_lj_cut_coul_debye_gpu.cpp index de86c58647..20354e732c 100644 --- a/src/GPU/pair_lj_cut_coul_debye_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_debye_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_debye_gpu.h" #include #include #include #include -#include "pair_lj_cut_coul_debye_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp b/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp index 87eac52749..ccaf86efa6 100644 --- a/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_dsf_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_dsf_gpu.h" #include #include #include #include -#include "pair_lj_cut_coul_dsf_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_coul_long_gpu.cpp b/src/GPU/pair_lj_cut_coul_long_gpu.cpp index c854dab83d..36c72f1143 100644 --- a/src/GPU/pair_lj_cut_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_long_gpu.h" #include #include #include #include -#include "pair_lj_cut_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_coul_msm_gpu.cpp b/src/GPU/pair_lj_cut_coul_msm_gpu.cpp index f87dc0ec91..79ca90698a 100644 --- a/src/GPU/pair_lj_cut_coul_msm_gpu.cpp +++ b/src/GPU/pair_lj_cut_coul_msm_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_msm_gpu.h" #include #include #include #include -#include "pair_lj_cut_coul_msm_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp b/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp index d2c925d950..e2c8b8d686 100644 --- a/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp +++ b/src/GPU/pair_lj_cut_dipole_cut_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_dipole_cut_gpu.h" #include #include #include #include -#include "pair_lj_cut_dipole_cut_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_dipole_long_gpu.cpp b/src/GPU/pair_lj_cut_dipole_long_gpu.cpp index 774ff2fae4..fb76376d34 100644 --- a/src/GPU/pair_lj_cut_dipole_long_gpu.cpp +++ b/src/GPU/pair_lj_cut_dipole_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (Northwestern) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_dipole_long_gpu.h" #include #include #include #include -#include "pair_lj_cut_dipole_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_cut_gpu.cpp b/src/GPU/pair_lj_cut_gpu.cpp index 6dde9689f7..809e5cf05e 100644 --- a/src/GPU/pair_lj_cut_gpu.cpp +++ b/src/GPU/pair_lj_cut_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_gpu.h" #include #include #include #include -#include "pair_lj_cut_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_expand_coul_long_gpu.cpp b/src/GPU/pair_lj_expand_coul_long_gpu.cpp index 31f4fd651c..a530f7ff9a 100644 --- a/src/GPU/pair_lj_expand_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_expand_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Nguyen (Northwestern) ------------------------------------------------------------------------- */ +#include "pair_lj_expand_coul_long_gpu.h" #include #include #include #include -#include "pair_lj_expand_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_expand_gpu.cpp b/src/GPU/pair_lj_expand_gpu.cpp index a2e1cf54e3..86f8a76b52 100644 --- a/src/GPU/pair_lj_expand_gpu.cpp +++ b/src/GPU/pair_lj_expand_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Inderaj Bains (NVIDIA), ibains@nvidia.com ------------------------------------------------------------------------- */ +#include "pair_lj_expand_gpu.h" #include #include #include #include -#include "pair_lj_expand_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_gromacs_gpu.cpp b/src/GPU/pair_lj_gromacs_gpu.cpp index e03f4b2e50..78f8b8b461 100644 --- a/src/GPU/pair_lj_gromacs_gpu.cpp +++ b/src/GPU/pair_lj_gromacs_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_lj_gromacs_gpu.h" #include #include #include #include -#include "pair_lj_gromacs_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_sdk_coul_long_gpu.cpp b/src/GPU/pair_lj_sdk_coul_long_gpu.cpp index f5029df5dc..24ff8a4f28 100644 --- a/src/GPU/pair_lj_sdk_coul_long_gpu.cpp +++ b/src/GPU/pair_lj_sdk_coul_long_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_sdk_coul_long_gpu.h" #include #include #include #include -#include "pair_lj_sdk_coul_long_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_sdk_gpu.cpp b/src/GPU/pair_lj_sdk_gpu.cpp index 4797a34408..2621f49aeb 100644 --- a/src/GPU/pair_lj_sdk_gpu.cpp +++ b/src/GPU/pair_lj_sdk_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_sdk_gpu.h" #include #include #include #include -#include "pair_lj_sdk_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp b/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp index dd25a70eee..cf26cdf3b4 100644 --- a/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp +++ b/src/GPU/pair_lj_sf_dipole_sf_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_lj_sf_dipole_sf_gpu.h" #include #include #include #include -#include "pair_lj_sf_dipole_sf_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_mie_cut_gpu.cpp b/src/GPU/pair_mie_cut_gpu.cpp index 838d28033f..f3a384113f 100644 --- a/src/GPU/pair_mie_cut_gpu.cpp +++ b/src/GPU/pair_mie_cut_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_mie_cut_gpu.h" #include #include #include #include -#include "pair_mie_cut_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_morse_gpu.cpp b/src/GPU/pair_morse_gpu.cpp index 1f94643e3a..dcad227045 100644 --- a/src/GPU/pair_morse_gpu.cpp +++ b/src/GPU/pair_morse_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_morse_gpu.h" #include #include #include #include -#include "pair_morse_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_resquared_gpu.cpp b/src/GPU/pair_resquared_gpu.cpp index 5e90f788bf..b12a790c81 100644 --- a/src/GPU/pair_resquared_gpu.cpp +++ b/src/GPU/pair_resquared_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "pair_resquared_gpu.h" #include #include #include #include -#include "pair_resquared_gpu.h" #include "math_extra.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/GPU/pair_soft_gpu.cpp b/src/GPU/pair_soft_gpu.cpp index 42adb02553..0efcb20c8d 100644 --- a/src/GPU/pair_soft_gpu.cpp +++ b/src/GPU/pair_soft_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_soft_gpu.h" #include #include #include #include -#include "pair_soft_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_sw_gpu.cpp b/src/GPU/pair_sw_gpu.cpp index 0cc858e57d..8999cb6c47 100644 --- a/src/GPU/pair_sw_gpu.cpp +++ b/src/GPU/pair_sw_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (ORNL) ------------------------------------------------------------------------- */ +#include "pair_sw_gpu.h" #include #include #include #include -#include "pair_sw_gpu.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/GPU/pair_table_gpu.cpp b/src/GPU/pair_table_gpu.cpp index a0b6562e5e..4432265874 100644 --- a/src/GPU/pair_table_gpu.cpp +++ b/src/GPU/pair_table_gpu.cpp @@ -15,11 +15,11 @@ Contributing authors: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_table_gpu.h" #include #include #include #include -#include "pair_table_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_tersoff_gpu.cpp b/src/GPU/pair_tersoff_gpu.cpp index cd0c5e6693..e0dc021b57 100644 --- a/src/GPU/pair_tersoff_gpu.cpp +++ b/src/GPU/pair_tersoff_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "pair_tersoff_gpu.h" #include #include #include #include -#include "pair_tersoff_gpu.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/GPU/pair_tersoff_mod_gpu.cpp b/src/GPU/pair_tersoff_mod_gpu.cpp index fd55ddc6e6..a17efb55e8 100644 --- a/src/GPU/pair_tersoff_mod_gpu.cpp +++ b/src/GPU/pair_tersoff_mod_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "pair_tersoff_mod_gpu.h" #include #include #include #include -#include "pair_tersoff_mod_gpu.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/GPU/pair_tersoff_zbl_gpu.cpp b/src/GPU/pair_tersoff_zbl_gpu.cpp index d3828962e2..765d25f8e6 100644 --- a/src/GPU/pair_tersoff_zbl_gpu.cpp +++ b/src/GPU/pair_tersoff_zbl_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ndactrung@gmail.com) ------------------------------------------------------------------------- */ +#include "pair_tersoff_zbl_gpu.h" #include #include #include #include -#include "pair_tersoff_zbl_gpu.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/GPU/pair_ufm_gpu.cpp b/src/GPU/pair_ufm_gpu.cpp index 31422b0f4d..97c2eebf24 100644 --- a/src/GPU/pair_ufm_gpu.cpp +++ b/src/GPU/pair_ufm_gpu.cpp @@ -17,11 +17,11 @@ Maurice de Koning (Unicamp/Brazil) - dekoning@ifi.unicamp.br ------------------------------------------------------------------------- */ +#include "pair_ufm_gpu.h" #include #include #include #include -#include "pair_ufm_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_vashishta_gpu.cpp b/src/GPU/pair_vashishta_gpu.cpp index 5539653756..3b74e5685e 100644 --- a/src/GPU/pair_vashishta_gpu.cpp +++ b/src/GPU/pair_vashishta_gpu.cpp @@ -14,11 +14,12 @@ /* ---------------------------------------------------------------------- Contributing author: Anders Hafreager (UiO) ------------------------------------------------------------------------- */ + +#include "pair_vashishta_gpu.h" #include #include #include #include -#include "pair_vashishta_gpu.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/GPU/pair_yukawa_colloid_gpu.cpp b/src/GPU/pair_yukawa_colloid_gpu.cpp index 3645f392a2..51c7e683db 100644 --- a/src/GPU/pair_yukawa_colloid_gpu.cpp +++ b/src/GPU/pair_yukawa_colloid_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_yukawa_colloid_gpu.h" #include #include #include #include -#include "pair_yukawa_colloid_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_yukawa_gpu.cpp b/src/GPU/pair_yukawa_gpu.cpp index 90317fea34..5dc13c7750 100644 --- a/src/GPU/pair_yukawa_gpu.cpp +++ b/src/GPU/pair_yukawa_gpu.cpp @@ -15,11 +15,11 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_yukawa_gpu.h" #include #include #include #include -#include "pair_yukawa_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pair_zbl_gpu.cpp b/src/GPU/pair_zbl_gpu.cpp index 99471cbe90..5e24281145 100644 --- a/src/GPU/pair_zbl_gpu.cpp +++ b/src/GPU/pair_zbl_gpu.cpp @@ -15,12 +15,12 @@ Contributing author: Trung Dac Nguyen (ORNL) ------------------------------------------------------------------------- */ +#include "pair_zbl_gpu.h" #include "lmptype.h" #include #include #include #include -#include "pair_zbl_gpu.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/GPU/pppm_gpu.cpp b/src/GPU/pppm_gpu.cpp index 1bb1a39703..bbb270ff8e 100644 --- a/src/GPU/pppm_gpu.cpp +++ b/src/GPU/pppm_gpu.cpp @@ -15,12 +15,12 @@ Contributing authors: Mike Brown (ORNL), Axel Kohlmeyer (Temple) ------------------------------------------------------------------------- */ +#include "pppm_gpu.h" #include #include #include #include #include -#include "pppm_gpu.h" #include "atom.h" #include "comm.h" #include "gridcomm.h" diff --git a/src/GRANULAR/fix_freeze.cpp b/src/GRANULAR/fix_freeze.cpp index 73c1c9fc11..e2345bdf19 100644 --- a/src/GRANULAR/fix_freeze.cpp +++ b/src/GRANULAR/fix_freeze.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_freeze.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/GRANULAR/fix_pour.cpp b/src/GRANULAR/fix_pour.cpp index 3ffca8db9d..0fe7493127 100644 --- a/src/GRANULAR/fix_pour.cpp +++ b/src/GRANULAR/fix_pour.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_pour.h" #include #include #include -#include "fix_pour.h" #include "atom.h" #include "atom_vec.h" #include "force.h" diff --git a/src/GRANULAR/fix_wall_gran.cpp b/src/GRANULAR/fix_wall_gran.cpp index 8513fc702b..b0fbc0c2b8 100644 --- a/src/GRANULAR/fix_wall_gran.cpp +++ b/src/GRANULAR/fix_wall_gran.cpp @@ -16,10 +16,10 @@ Dan Bolintineanu (SNL) ------------------------------------------------------------------------- */ +#include "fix_wall_gran.h" #include #include #include -#include "fix_wall_gran.h" #include "atom.h" #include "domain.h" #include "update.h" diff --git a/src/GRANULAR/fix_wall_gran_region.cpp b/src/GRANULAR/fix_wall_gran_region.cpp index 72798bf7b7..97e889ddcc 100644 --- a/src/GRANULAR/fix_wall_gran_region.cpp +++ b/src/GRANULAR/fix_wall_gran_region.cpp @@ -15,10 +15,10 @@ Contributing authors: Dan Bolintineanu (SNL) ------------------------------------------------------------------------- */ +#include "fix_wall_gran_region.h" #include #include #include -#include "fix_wall_gran_region.h" #include "region.h" #include "atom.h" #include "domain.h" diff --git a/src/GRANULAR/pair_gran_hertz_history.cpp b/src/GRANULAR/pair_gran_hertz_history.cpp index 728491c17a..e303089e56 100644 --- a/src/GRANULAR/pair_gran_hertz_history.cpp +++ b/src/GRANULAR/pair_gran_hertz_history.cpp @@ -15,11 +15,11 @@ Contributing authors: Leo Silbert (SNL), Gary Grest (SNL) ------------------------------------------------------------------------- */ +#include "pair_gran_hertz_history.h" #include #include #include #include -#include "pair_gran_hertz_history.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/GRANULAR/pair_gran_hooke.cpp b/src/GRANULAR/pair_gran_hooke.cpp index cfcc2743ba..a30aa0bb6c 100644 --- a/src/GRANULAR/pair_gran_hooke.cpp +++ b/src/GRANULAR/pair_gran_hooke.cpp @@ -15,10 +15,10 @@ Contributing authors: Leo Silbert (SNL), Gary Grest (SNL) ------------------------------------------------------------------------- */ +#include "pair_gran_hooke.h" #include #include #include -#include "pair_gran_hooke.h" #include "atom.h" #include "force.h" #include "fix.h" diff --git a/src/GRANULAR/pair_gran_hooke_history.cpp b/src/GRANULAR/pair_gran_hooke_history.cpp index 5a78b9d79a..f832fdfac3 100644 --- a/src/GRANULAR/pair_gran_hooke_history.cpp +++ b/src/GRANULAR/pair_gran_hooke_history.cpp @@ -15,11 +15,11 @@ Contributing authors: Leo Silbert (SNL), Gary Grest (SNL) ------------------------------------------------------------------------- */ +#include "pair_gran_hooke_history.h" #include #include #include #include -#include "pair_gran_hooke_history.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/GRANULAR/pair_granular.cpp b/src/GRANULAR/pair_granular.cpp index 903ed303b0..942587a676 100644 --- a/src/GRANULAR/pair_granular.cpp +++ b/src/GRANULAR/pair_granular.cpp @@ -16,11 +16,11 @@ See the README file in the top-level LAMMPS directory. Leo Silbert (SNL), Gary Grest (SNL) ----------------------------------------------------------------------- */ +#include "pair_granular.h" #include #include #include #include -#include "pair_granular.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/KIM/kim_query.cpp b/src/KIM/kim_query.cpp index fedc976110..dce9c8761a 100644 --- a/src/KIM/kim_query.cpp +++ b/src/KIM/kim_query.cpp @@ -55,10 +55,10 @@ Designed for use with the kim-api-2.0.2 (and newer) package ------------------------------------------------------------------------- */ +#include "kim_query.h" #include #include #include -#include "kim_query.h" #include "comm.h" #include "error.h" #include "input.h" diff --git a/src/KIM/pair_kim.cpp b/src/KIM/pair_kim.cpp index a1c13ae81f..e107e4276f 100644 --- a/src/KIM/pair_kim.cpp +++ b/src/KIM/pair_kim.cpp @@ -53,11 +53,9 @@ Designed for use with the kim-api-2.0.2 (and newer) package ------------------------------------------------------------------------- */ +#include "pair_kim.h" #include #include - -// includes from LAMMPS -#include "pair_kim.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KOKKOS/angle_charmm_kokkos.cpp b/src/KOKKOS/angle_charmm_kokkos.cpp index 0f46c958d6..fd9757aab3 100644 --- a/src/KOKKOS/angle_charmm_kokkos.cpp +++ b/src/KOKKOS/angle_charmm_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "angle_charmm_kokkos.h" #include #include -#include "angle_charmm_kokkos.h" #include "atom_kokkos.h" #include "neighbor_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/angle_class2_kokkos.cpp b/src/KOKKOS/angle_class2_kokkos.cpp index 836714764d..809ce7e7dd 100644 --- a/src/KOKKOS/angle_class2_kokkos.cpp +++ b/src/KOKKOS/angle_class2_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Ray Shan (Materials Design) ------------------------------------------------------------------------- */ +#include "angle_class2_kokkos.h" #include #include -#include "angle_class2_kokkos.h" #include "atom_kokkos.h" #include "neighbor_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/angle_cosine_kokkos.cpp b/src/KOKKOS/angle_cosine_kokkos.cpp index 4a4866948f..da0ff398f1 100644 --- a/src/KOKKOS/angle_cosine_kokkos.cpp +++ b/src/KOKKOS/angle_cosine_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "angle_cosine_kokkos.h" #include #include -#include "angle_cosine_kokkos.h" #include "atom_kokkos.h" #include "neighbor_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/angle_harmonic_kokkos.cpp b/src/KOKKOS/angle_harmonic_kokkos.cpp index dbe705800c..fc274bb894 100644 --- a/src/KOKKOS/angle_harmonic_kokkos.cpp +++ b/src/KOKKOS/angle_harmonic_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "angle_harmonic_kokkos.h" #include #include -#include "angle_harmonic_kokkos.h" #include "atom_kokkos.h" #include "neighbor_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_kokkos.cpp b/src/KOKKOS/atom_kokkos.cpp index 813c5ddbf2..4637a9a21c 100644 --- a/src/KOKKOS/atom_kokkos.cpp +++ b/src/KOKKOS/atom_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_kokkos.h" +#include #include "atom_vec.h" #include "atom_vec_kokkos.h" #include "comm_kokkos.h" diff --git a/src/KOKKOS/atom_vec_angle_kokkos.cpp b/src/KOKKOS/atom_vec_angle_kokkos.cpp index e4f27e733a..3e66d813cf 100644 --- a/src/KOKKOS/atom_vec_angle_kokkos.cpp +++ b/src/KOKKOS/atom_vec_angle_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_angle_kokkos.h" +#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_vec_atomic_kokkos.cpp b/src/KOKKOS/atom_vec_atomic_kokkos.cpp index 95e4ddd72b..27aaa96b6d 100644 --- a/src/KOKKOS/atom_vec_atomic_kokkos.cpp +++ b/src/KOKKOS/atom_vec_atomic_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_atomic_kokkos.h" +#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_vec_bond_kokkos.cpp b/src/KOKKOS/atom_vec_bond_kokkos.cpp index 92311d5d09..ad6d5bd486 100644 --- a/src/KOKKOS/atom_vec_bond_kokkos.cpp +++ b/src/KOKKOS/atom_vec_bond_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_bond_kokkos.h" +#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_vec_charge_kokkos.cpp b/src/KOKKOS/atom_vec_charge_kokkos.cpp index 31a690f521..507e8170c5 100644 --- a/src/KOKKOS/atom_vec_charge_kokkos.cpp +++ b/src/KOKKOS/atom_vec_charge_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_charge_kokkos.h" +#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_vec_dpd_kokkos.cpp b/src/KOKKOS/atom_vec_dpd_kokkos.cpp index 4034efee9e..db857909bf 100644 --- a/src/KOKKOS/atom_vec_dpd_kokkos.cpp +++ b/src/KOKKOS/atom_vec_dpd_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_dpd_kokkos.h" +#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_vec_full_kokkos.cpp b/src/KOKKOS/atom_vec_full_kokkos.cpp index 034da88f73..486c4e4c4e 100644 --- a/src/KOKKOS/atom_vec_full_kokkos.cpp +++ b/src/KOKKOS/atom_vec_full_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_full_kokkos.h" +#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_vec_hybrid_kokkos.cpp b/src/KOKKOS/atom_vec_hybrid_kokkos.cpp index 03cbe1ee5e..39d88a0f38 100644 --- a/src/KOKKOS/atom_vec_hybrid_kokkos.cpp +++ b/src/KOKKOS/atom_vec_hybrid_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_hybrid_kokkos.h" #include #include -#include "atom_vec_hybrid_kokkos.h" #include "atom_kokkos.h" #include "domain.h" #include "modify.h" diff --git a/src/KOKKOS/atom_vec_molecular_kokkos.cpp b/src/KOKKOS/atom_vec_molecular_kokkos.cpp index 9ac8ecd264..49bc7bf3c0 100644 --- a/src/KOKKOS/atom_vec_molecular_kokkos.cpp +++ b/src/KOKKOS/atom_vec_molecular_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_molecular_kokkos.h" +#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/atom_vec_sphere_kokkos.cpp b/src/KOKKOS/atom_vec_sphere_kokkos.cpp index 9e8388488f..b2abbfe8c4 100644 --- a/src/KOKKOS/atom_vec_sphere_kokkos.cpp +++ b/src/KOKKOS/atom_vec_sphere_kokkos.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_sphere_kokkos.h" #include #include #include -#include "atom_vec_sphere_kokkos.h" #include "atom_kokkos.h" #include "atom_masks.h" #include "comm_kokkos.h" diff --git a/src/KOKKOS/bond_class2_kokkos.cpp b/src/KOKKOS/bond_class2_kokkos.cpp index 798fb41c92..04281bfdd2 100644 --- a/src/KOKKOS/bond_class2_kokkos.cpp +++ b/src/KOKKOS/bond_class2_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Ray Shan (Materials Design) ------------------------------------------------------------------------- */ +#include "bond_class2_kokkos.h" #include #include -#include "bond_class2_kokkos.h" #include "atom_kokkos.h" #include "neighbor_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/bond_fene_kokkos.cpp b/src/KOKKOS/bond_fene_kokkos.cpp index b5cdc1a05a..361bb61f7e 100644 --- a/src/KOKKOS/bond_fene_kokkos.cpp +++ b/src/KOKKOS/bond_fene_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "bond_fene_kokkos.h" #include #include -#include "bond_fene_kokkos.h" #include "atom_kokkos.h" #include "neighbor_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/bond_harmonic_kokkos.cpp b/src/KOKKOS/bond_harmonic_kokkos.cpp index 51a9fa4389..792d98fe88 100644 --- a/src/KOKKOS/bond_harmonic_kokkos.cpp +++ b/src/KOKKOS/bond_harmonic_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "bond_harmonic_kokkos.h" #include #include -#include "bond_harmonic_kokkos.h" #include "atom_kokkos.h" #include "neighbor_kokkos.h" #include "domain.h" diff --git a/src/KOKKOS/comm_tiled_kokkos.cpp b/src/KOKKOS/comm_tiled_kokkos.cpp index 81cf1f0563..fc6de0a0d7 100644 --- a/src/KOKKOS/comm_tiled_kokkos.cpp +++ b/src/KOKKOS/comm_tiled_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "comm_tiled_kokkos.h" +#include #include "comm_brick.h" #include "atom_kokkos.h" #include "atom_vec.h" diff --git a/src/KOKKOS/compute_temp_kokkos.cpp b/src/KOKKOS/compute_temp_kokkos.cpp index 7b76f54f57..a2fcf63125 100644 --- a/src/KOKKOS/compute_temp_kokkos.cpp +++ b/src/KOKKOS/compute_temp_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_temp_kokkos.h" #include #include -#include "compute_temp_kokkos.h" #include "atom_kokkos.h" #include "update.h" #include "force.h" diff --git a/src/KOKKOS/dihedral_charmm_kokkos.cpp b/src/KOKKOS/dihedral_charmm_kokkos.cpp index 61ddcc425a..94fd0b9bb7 100644 --- a/src/KOKKOS/dihedral_charmm_kokkos.cpp +++ b/src/KOKKOS/dihedral_charmm_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "dihedral_charmm_kokkos.h" #include #include -#include "dihedral_charmm_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "neighbor_kokkos.h" diff --git a/src/KOKKOS/dihedral_class2_kokkos.cpp b/src/KOKKOS/dihedral_class2_kokkos.cpp index 98436bc696..4b8d171f61 100644 --- a/src/KOKKOS/dihedral_class2_kokkos.cpp +++ b/src/KOKKOS/dihedral_class2_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Ray Shan (Materials Design) ------------------------------------------------------------------------- */ +#include "dihedral_class2_kokkos.h" #include #include -#include "dihedral_class2_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "neighbor_kokkos.h" diff --git a/src/KOKKOS/dihedral_opls_kokkos.cpp b/src/KOKKOS/dihedral_opls_kokkos.cpp index f50dea2c36..825d106e04 100644 --- a/src/KOKKOS/dihedral_opls_kokkos.cpp +++ b/src/KOKKOS/dihedral_opls_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "dihedral_opls_kokkos.h" #include #include -#include "dihedral_opls_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "neighbor_kokkos.h" diff --git a/src/KOKKOS/fix_deform_kokkos.cpp b/src/KOKKOS/fix_deform_kokkos.cpp index 7b9336ed3b..05eb1c22f6 100644 --- a/src/KOKKOS/fix_deform_kokkos.cpp +++ b/src/KOKKOS/fix_deform_kokkos.cpp @@ -15,10 +15,10 @@ Contributing author: Pieter in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "fix_deform_kokkos.h" #include #include #include -#include "fix_deform_kokkos.h" #include "atom_kokkos.h" #include "update.h" #include "comm.h" diff --git a/src/KOKKOS/fix_dpd_energy_kokkos.cpp b/src/KOKKOS/fix_dpd_energy_kokkos.cpp index d092cb4802..debad0407a 100644 --- a/src/KOKKOS/fix_dpd_energy_kokkos.cpp +++ b/src/KOKKOS/fix_dpd_energy_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_dpd_energy_kokkos.h" #include #include -#include "fix_dpd_energy_kokkos.h" #include "atom_masks.h" #include "atom_kokkos.h" #include "force.h" diff --git a/src/KOKKOS/fix_enforce2d_kokkos.cpp b/src/KOKKOS/fix_enforce2d_kokkos.cpp index 346e440f55..bf2a882539 100644 --- a/src/KOKKOS/fix_enforce2d_kokkos.cpp +++ b/src/KOKKOS/fix_enforce2d_kokkos.cpp @@ -15,11 +15,11 @@ Contributing authors: Stefan Paquay & Matthew Peterson (Brandeis University) ------------------------------------------------------------------------- */ +#include "fix_enforce2d_kokkos.h" #include "atom_masks.h" #include "atom_kokkos.h" #include "comm.h" #include "error.h" -#include "fix_enforce2d_kokkos.h" using namespace LAMMPS_NS; diff --git a/src/KOKKOS/fix_eos_table_rx_kokkos.cpp b/src/KOKKOS/fix_eos_table_rx_kokkos.cpp index 2f730d1193..d0280eeef0 100644 --- a/src/KOKKOS/fix_eos_table_rx_kokkos.cpp +++ b/src/KOKKOS/fix_eos_table_rx_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (Sandia) ------------------------------------------------------------------------- */ +#include "fix_eos_table_rx_kokkos.h" #include #include -#include "fix_eos_table_rx_kokkos.h" #include "atom_kokkos.h" #include "error.h" #include "force.h" diff --git a/src/KOKKOS/fix_langevin_kokkos.cpp b/src/KOKKOS/fix_langevin_kokkos.cpp index 0947fee693..23a43b38ef 100644 --- a/src/KOKKOS/fix_langevin_kokkos.cpp +++ b/src/KOKKOS/fix_langevin_kokkos.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_langevin_kokkos.h" #include #include #include -#include "fix_langevin_kokkos.h" #include "atom_masks.h" #include "atom_kokkos.h" #include "force.h" diff --git a/src/KOKKOS/fix_momentum_kokkos.cpp b/src/KOKKOS/fix_momentum_kokkos.cpp index 38500531ca..2d4911bfda 100644 --- a/src/KOKKOS/fix_momentum_kokkos.cpp +++ b/src/KOKKOS/fix_momentum_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_momentum_kokkos.h" #include #include -#include "fix_momentum_kokkos.h" #include "atom_kokkos.h" #include "atom_masks.h" #include "domain.h" diff --git a/src/KOKKOS/fix_nh_kokkos.cpp b/src/KOKKOS/fix_nh_kokkos.cpp index fae9ef8f30..578f2f5c70 100644 --- a/src/KOKKOS/fix_nh_kokkos.cpp +++ b/src/KOKKOS/fix_nh_kokkos.cpp @@ -15,10 +15,10 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "fix_nh_kokkos.h" #include #include #include -#include "fix_nh_kokkos.h" #include "math_extra.h" #include "atom.h" #include "force.h" diff --git a/src/KOKKOS/fix_nph_kokkos.cpp b/src/KOKKOS/fix_nph_kokkos.cpp index c5072e6ae9..3830860fd7 100644 --- a/src/KOKKOS/fix_nph_kokkos.cpp +++ b/src/KOKKOS/fix_nph_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nph_kokkos.h" +#include #include "modify.h" #include "error.h" diff --git a/src/KOKKOS/fix_npt_kokkos.cpp b/src/KOKKOS/fix_npt_kokkos.cpp index c488c8e4f3..5b751c9e4d 100644 --- a/src/KOKKOS/fix_npt_kokkos.cpp +++ b/src/KOKKOS/fix_npt_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_npt_kokkos.h" +#include #include "modify.h" #include "error.h" diff --git a/src/KOKKOS/fix_nve_kokkos.cpp b/src/KOKKOS/fix_nve_kokkos.cpp index 6db8ff8c0f..0ca01c589a 100644 --- a/src/KOKKOS/fix_nve_kokkos.cpp +++ b/src/KOKKOS/fix_nve_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nve_kokkos.h" #include #include -#include "fix_nve_kokkos.h" #include "atom_masks.h" #include "atom_kokkos.h" #include "force.h" diff --git a/src/KOKKOS/fix_nvt_kokkos.cpp b/src/KOKKOS/fix_nvt_kokkos.cpp index 4db42a62fb..66165dd7bc 100644 --- a/src/KOKKOS/fix_nvt_kokkos.cpp +++ b/src/KOKKOS/fix_nvt_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_nvt_kokkos.h" +#include #include "group.h" #include "modify.h" #include "error.h" diff --git a/src/KOKKOS/fix_property_atom_kokkos.cpp b/src/KOKKOS/fix_property_atom_kokkos.cpp index 6860676911..ff374b885f 100644 --- a/src/KOKKOS/fix_property_atom_kokkos.cpp +++ b/src/KOKKOS/fix_property_atom_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_property_atom_kokkos.h" #include #include -#include "fix_property_atom_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "memory_kokkos.h" diff --git a/src/KOKKOS/fix_qeq_reax_kokkos.cpp b/src/KOKKOS/fix_qeq_reax_kokkos.cpp index 12369261b3..6f8392ab16 100644 --- a/src/KOKKOS/fix_qeq_reax_kokkos.cpp +++ b/src/KOKKOS/fix_qeq_reax_kokkos.cpp @@ -16,11 +16,11 @@ Kamesh Arumugam (NVIDIA) ------------------------------------------------------------------------- */ +#include "fix_qeq_reax_kokkos.h" #include #include #include #include -#include "fix_qeq_reax_kokkos.h" #include "kokkos.h" #include "atom.h" #include "atom_masks.h" diff --git a/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp b/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp index 9aed0b9ae4..347c477476 100644 --- a/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp +++ b/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp @@ -15,9 +15,9 @@ Contributing author: Stan Moore (Sandia) ------------------------------------------------------------------------- */ +#include "fix_ave_atom.h" #include #include -#include "fix_ave_atom.h" #include "fix_reaxc_bonds_kokkos.h" #include "atom.h" #include "update.h" diff --git a/src/KOKKOS/fix_reaxc_species_kokkos.cpp b/src/KOKKOS/fix_reaxc_species_kokkos.cpp index bd92251960..71aacba68d 100644 --- a/src/KOKKOS/fix_reaxc_species_kokkos.cpp +++ b/src/KOKKOS/fix_reaxc_species_kokkos.cpp @@ -15,12 +15,12 @@ Contributing authors: Stan Moore (Sandia) ------------------------------------------------------------------------- */ +#include "fix_reaxc_species_kokkos.h" #include #include #include "atom.h" #include #include "fix_ave_atom.h" -#include "fix_reaxc_species_kokkos.h" #include "domain.h" #include "update.h" #include "pair_reaxc_kokkos.h" diff --git a/src/KOKKOS/fix_rx_kokkos.cpp b/src/KOKKOS/fix_rx_kokkos.cpp index 80333e1e9b..050dda2400 100644 --- a/src/KOKKOS/fix_rx_kokkos.cpp +++ b/src/KOKKOS/fix_rx_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_rx_kokkos.h" #include #include -#include "fix_rx_kokkos.h" #include "atom_masks.h" #include "atom_kokkos.h" #include "force.h" diff --git a/src/KOKKOS/fix_setforce_kokkos.cpp b/src/KOKKOS/fix_setforce_kokkos.cpp index 5d15b88d76..03cfd3afb2 100644 --- a/src/KOKKOS/fix_setforce_kokkos.cpp +++ b/src/KOKKOS/fix_setforce_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_setforce_kokkos.h" #include #include -#include "fix_setforce_kokkos.h" #include "atom_kokkos.h" #include "update.h" #include "modify.h" diff --git a/src/KOKKOS/fix_shardlow_kokkos.cpp b/src/KOKKOS/fix_shardlow_kokkos.cpp index 968f877abd..96f67ccb5e 100644 --- a/src/KOKKOS/fix_shardlow_kokkos.cpp +++ b/src/KOKKOS/fix_shardlow_kokkos.cpp @@ -33,10 +33,10 @@ 135, 204105. ------------------------------------------------------------------------- */ +#include "fix_shardlow_kokkos.h" #include #include #include -#include "fix_shardlow_kokkos.h" #include "atom.h" #include "atom_masks.h" #include "atom_kokkos.h" diff --git a/src/KOKKOS/fix_wall_lj93_kokkos.cpp b/src/KOKKOS/fix_wall_lj93_kokkos.cpp index 5dbb054175..61346144c8 100644 --- a/src/KOKKOS/fix_wall_lj93_kokkos.cpp +++ b/src/KOKKOS/fix_wall_lj93_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_wall_lj93_kokkos.h" +#include #include "atom_kokkos.h" #include "error.h" #include "atom_masks.h" diff --git a/src/KOKKOS/fix_wall_reflect_kokkos.cpp b/src/KOKKOS/fix_wall_reflect_kokkos.cpp index 75a5c1a81e..ba104d19a9 100644 --- a/src/KOKKOS/fix_wall_reflect_kokkos.cpp +++ b/src/KOKKOS/fix_wall_reflect_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_wall_reflect_kokkos.h" #include #include -#include "fix_wall_reflect_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "update.h" diff --git a/src/KOKKOS/gridcomm_kokkos.cpp b/src/KOKKOS/gridcomm_kokkos.cpp index 14b84a5733..1d0371c147 100644 --- a/src/KOKKOS/gridcomm_kokkos.cpp +++ b/src/KOKKOS/gridcomm_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "gridcomm_kokkos.h" +#include #include "comm.h" #include "kspace.h" #include "memory_kokkos.h" diff --git a/src/KOKKOS/improper_class2_kokkos.cpp b/src/KOKKOS/improper_class2_kokkos.cpp index ad32e6da4e..84b721bd2a 100644 --- a/src/KOKKOS/improper_class2_kokkos.cpp +++ b/src/KOKKOS/improper_class2_kokkos.cpp @@ -15,10 +15,10 @@ Contributing author: Ray Shan (Materials Design) ------------------------------------------------------------------------- */ +#include "improper_class2_kokkos.h" #include #include #include -#include "improper_class2_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "neighbor_kokkos.h" diff --git a/src/KOKKOS/improper_harmonic_kokkos.cpp b/src/KOKKOS/improper_harmonic_kokkos.cpp index bb397a2c2f..262ffe7700 100644 --- a/src/KOKKOS/improper_harmonic_kokkos.cpp +++ b/src/KOKKOS/improper_harmonic_kokkos.cpp @@ -15,10 +15,10 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "improper_harmonic_kokkos.h" #include #include #include -#include "improper_harmonic_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "neighbor_kokkos.h" diff --git a/src/KOKKOS/kokkos.cpp b/src/KOKKOS/kokkos.cpp index 3fa84d98b2..c269f69cdd 100644 --- a/src/KOKKOS/kokkos.cpp +++ b/src/KOKKOS/kokkos.cpp @@ -11,6 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "kokkos.h" #include #include #include @@ -18,7 +19,6 @@ #include #include #include -#include "kokkos.h" #include "lammps.h" #include "force.h" #include "neighbor_kokkos.h" diff --git a/src/KOKKOS/math_special_kokkos.cpp b/src/KOKKOS/math_special_kokkos.cpp index 127168ef8b..f5fc725347 100644 --- a/src/KOKKOS/math_special_kokkos.cpp +++ b/src/KOKKOS/math_special_kokkos.cpp @@ -1,7 +1,7 @@ +#include "math_special_kokkos.h" #include #include -#include "math_special_kokkos.h" using namespace LAMMPS_NS; diff --git a/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp b/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp index 57ac3a9c57..e3843262a5 100644 --- a/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_buck_coul_cut_kokkos.h" #include #include #include #include -#include "pair_buck_coul_cut_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_buck_coul_long_kokkos.cpp b/src/KOKKOS/pair_buck_coul_long_kokkos.cpp index 349c4c0601..7457a0988f 100644 --- a/src/KOKKOS/pair_buck_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_buck_coul_long_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_buck_coul_long_kokkos.h" #include #include #include #include -#include "pair_buck_coul_long_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_buck_kokkos.cpp b/src/KOKKOS/pair_buck_kokkos.cpp index 02c02c986e..131622cac5 100644 --- a/src/KOKKOS/pair_buck_kokkos.cpp +++ b/src/KOKKOS/pair_buck_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_buck_kokkos.h" #include #include #include #include -#include "pair_buck_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_coul_cut_kokkos.cpp b/src/KOKKOS/pair_coul_cut_kokkos.cpp index 54ba0b63ce..e79f103363 100644 --- a/src/KOKKOS/pair_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_coul_cut_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_coul_cut_kokkos.h" #include #include #include #include -#include "pair_coul_cut_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_coul_debye_kokkos.cpp b/src/KOKKOS/pair_coul_debye_kokkos.cpp index 8966e30394..0fe03af043 100644 --- a/src/KOKKOS/pair_coul_debye_kokkos.cpp +++ b/src/KOKKOS/pair_coul_debye_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_coul_debye_kokkos.h" #include #include #include #include -#include "pair_coul_debye_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_coul_dsf_kokkos.cpp b/src/KOKKOS/pair_coul_dsf_kokkos.cpp index 748fed71a7..e94aae4754 100644 --- a/src/KOKKOS/pair_coul_dsf_kokkos.cpp +++ b/src/KOKKOS/pair_coul_dsf_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_coul_dsf_kokkos.h" #include #include #include #include -#include "pair_coul_dsf_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_coul_long_kokkos.cpp b/src/KOKKOS/pair_coul_long_kokkos.cpp index a21cb050ff..67132e11f6 100644 --- a/src/KOKKOS/pair_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_coul_long_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_coul_long_kokkos.h" #include #include #include #include -#include "pair_coul_long_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_coul_wolf_kokkos.cpp b/src/KOKKOS/pair_coul_wolf_kokkos.cpp index 20391d9530..dbbb865961 100644 --- a/src/KOKKOS/pair_coul_wolf_kokkos.cpp +++ b/src/KOKKOS/pair_coul_wolf_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_coul_wolf_kokkos.h" #include #include #include #include -#include "pair_coul_wolf_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp index a44ef1790e..7a2fca47a0 100644 --- a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp +++ b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Stan Moore (Sandia) ------------------------------------------------------------------------- */ +#include "pair_dpd_fdt_energy_kokkos.h" #include #include #include #include -#include "atom_kokkos.h" #include "atom_vec.h" #include "comm.h" #include "update.h" @@ -30,7 +30,6 @@ #include "neigh_request.h" #include "memory_kokkos.h" #include "modify.h" -#include "pair_dpd_fdt_energy_kokkos.h" #include "error.h" #include "atom_masks.h" #include "kokkos.h" diff --git a/src/KOKKOS/pair_eam_alloy_kokkos.cpp b/src/KOKKOS/pair_eam_alloy_kokkos.cpp index b5442c0d29..aa33d44eee 100644 --- a/src/KOKKOS/pair_eam_alloy_kokkos.cpp +++ b/src/KOKKOS/pair_eam_alloy_kokkos.cpp @@ -15,13 +15,13 @@ Contributing authors: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_eam_alloy_kokkos.h" #include #include #include #include #include "kokkos.h" #include "pair_kokkos.h" -#include "pair_eam_alloy_kokkos.h" #include "atom_kokkos.h" #include "force.h" #include "comm.h" diff --git a/src/KOKKOS/pair_eam_fs_kokkos.cpp b/src/KOKKOS/pair_eam_fs_kokkos.cpp index 16701febd6..9832a16a73 100644 --- a/src/KOKKOS/pair_eam_fs_kokkos.cpp +++ b/src/KOKKOS/pair_eam_fs_kokkos.cpp @@ -15,13 +15,13 @@ Contributing authors: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_eam_fs_kokkos.h" #include #include #include #include #include "kokkos.h" #include "pair_kokkos.h" -#include "pair_eam_fs_kokkos.h" #include "atom_kokkos.h" #include "force.h" #include "comm.h" diff --git a/src/KOKKOS/pair_eam_kokkos.cpp b/src/KOKKOS/pair_eam_kokkos.cpp index d423f2c927..4c6fadfe92 100644 --- a/src/KOKKOS/pair_eam_kokkos.cpp +++ b/src/KOKKOS/pair_eam_kokkos.cpp @@ -15,13 +15,13 @@ Contributing authors: Stan Moore (SNL), Christian Trott (SNL) ------------------------------------------------------------------------- */ +#include "pair_eam_kokkos.h" #include #include #include #include #include "kokkos.h" #include "pair_kokkos.h" -#include "pair_eam_kokkos.h" #include "atom_kokkos.h" #include "force.h" #include "comm.h" diff --git a/src/KOKKOS/pair_exp6_rx_kokkos.cpp b/src/KOKKOS/pair_exp6_rx_kokkos.cpp index 3a857a6485..31a48fe154 100644 --- a/src/KOKKOS/pair_exp6_rx_kokkos.cpp +++ b/src/KOKKOS/pair_exp6_rx_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Stan Moore (Sandia) ------------------------------------------------------------------------- */ +#include "pair_exp6_rx_kokkos.h" #include #include #include #include -#include "pair_exp6_rx_kokkos.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KOKKOS/pair_hybrid_kokkos.cpp b/src/KOKKOS/pair_hybrid_kokkos.cpp index 00df4a8f3c..c767d9f470 100644 --- a/src/KOKKOS/pair_hybrid_kokkos.cpp +++ b/src/KOKKOS/pair_hybrid_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_hybrid_kokkos.h" #include #include #include #include -#include "pair_hybrid_kokkos.h" #include "atom_kokkos.h" #include "force.h" #include "pair.h" diff --git a/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp b/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp index a2c3edab65..cb1389d38e 100644 --- a/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp +++ b/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_hybrid_overlay_kokkos.h" #include #include #include -#include "pair_hybrid_overlay_kokkos.h" #include "atom.h" #include "force.h" #include "neighbor.h" diff --git a/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp index 510740112a..b7c3766d5f 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_charmm_implicit_kokkos.h" #include #include #include #include -#include "pair_lj_charmm_coul_charmm_implicit_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp index 51c96354f9..c6a1e3211d 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_charmm_kokkos.h" #include #include #include #include -#include "pair_lj_charmm_coul_charmm_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp index 22faa98935..4ba0651601 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_long_kokkos.h" #include #include #include #include -#include "pair_lj_charmm_coul_long_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp b/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp index 60d480188b..ef8fe7a128 100644 --- a/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_class2_coul_cut_kokkos.h" #include #include #include #include -#include "pair_lj_class2_coul_cut_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp index 4c8aea8e92..5a25d0250b 100644 --- a/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_class2_coul_long_kokkos.h" #include #include #include #include -#include "pair_lj_class2_coul_long_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_class2_kokkos.cpp b/src/KOKKOS/pair_lj_class2_kokkos.cpp index dd42baa4e0..6d673b2d01 100644 --- a/src/KOKKOS/pair_lj_class2_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_class2_kokkos.h" #include #include #include #include -#include "pair_lj_class2_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp index cb5ab96871..9201a116b5 100644 --- a/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_cut_kokkos.h" #include #include #include #include -#include "pair_lj_cut_coul_cut_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp index 800092a09b..8935333c74 100644 --- a/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_debye_kokkos.h" #include #include #include #include -#include "pair_lj_cut_coul_debye_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp index f793485b47..aea70faec4 100644 --- a/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_dsf_kokkos.h" #include #include #include #include -#include "pair_lj_cut_coul_dsf_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp index 02150586f4..53d27f2447 100644 --- a/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_long_kokkos.h" #include #include #include #include -#include "pair_lj_cut_coul_long_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_cut_kokkos.cpp b/src/KOKKOS/pair_lj_cut_kokkos.cpp index 4ba8c00f88..ee29e12322 100644 --- a/src/KOKKOS/pair_lj_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_cut_kokkos.h" #include #include #include #include -#include "pair_lj_cut_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_expand_kokkos.cpp b/src/KOKKOS/pair_lj_expand_kokkos.cpp index 5ea6c9e438..061fc205fb 100644 --- a/src/KOKKOS/pair_lj_expand_kokkos.cpp +++ b/src/KOKKOS/pair_lj_expand_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_expand_kokkos.h" #include #include #include #include -#include "pair_lj_expand_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp b/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp index 2421d059da..4df9fdea9e 100644 --- a/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp +++ b/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_gromacs_coul_gromacs_kokkos.h" #include #include #include #include -#include "pair_lj_gromacs_coul_gromacs_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_gromacs_kokkos.cpp b/src/KOKKOS/pair_lj_gromacs_kokkos.cpp index 09a0261ae1..2d395c39d5 100644 --- a/src/KOKKOS/pair_lj_gromacs_kokkos.cpp +++ b/src/KOKKOS/pair_lj_gromacs_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_gromacs_kokkos.h" #include #include #include #include -#include "pair_lj_gromacs_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_lj_sdk_kokkos.cpp b/src/KOKKOS/pair_lj_sdk_kokkos.cpp index c2375fa7a8..14c53c38bf 100644 --- a/src/KOKKOS/pair_lj_sdk_kokkos.cpp +++ b/src/KOKKOS/pair_lj_sdk_kokkos.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_sdk_kokkos.h" #include #include #include #include -#include "pair_lj_sdk_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_morse_kokkos.cpp b/src/KOKKOS/pair_morse_kokkos.cpp index b308330ead..d679477321 100644 --- a/src/KOKKOS/pair_morse_kokkos.cpp +++ b/src/KOKKOS/pair_morse_kokkos.cpp @@ -15,11 +15,11 @@ Contributing authors: Stefan Paquay (Eindhoven University of Technology) ------------------------------------------------------------------------- */ +#include "pair_morse_kokkos.h" #include #include #include #include -#include "pair_morse_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp b/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp index 7d17ac3f43..81a4aa7a82 100644 --- a/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp +++ b/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp @@ -21,12 +21,12 @@ The Journal of Chemical Physics, 2016, 144, 104501. ------------------------------------------------------------------------------------------- */ +#include "pair_multi_lucy_rx_kokkos.h" #include #include -#include "math_const.h" #include #include -#include "pair_multi_lucy_rx_kokkos.h" +#include "math_const.h" #include "atom_kokkos.h" #include "force.h" #include "comm.h" diff --git a/src/KOKKOS/pair_reaxc_kokkos.cpp b/src/KOKKOS/pair_reaxc_kokkos.cpp index 64651be270..ca897a377c 100644 --- a/src/KOKKOS/pair_reaxc_kokkos.cpp +++ b/src/KOKKOS/pair_reaxc_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL), Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_reaxc_kokkos.h" #include #include #include #include -#include "pair_reaxc_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_sw_kokkos.cpp b/src/KOKKOS/pair_sw_kokkos.cpp index da4737a2c1..dbd45747f0 100644 --- a/src/KOKKOS/pair_sw_kokkos.cpp +++ b/src/KOKKOS/pair_sw_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_sw_kokkos.h" #include #include #include #include -#include "pair_sw_kokkos.h" #include "kokkos.h" #include "pair_kokkos.h" #include "atom_kokkos.h" diff --git a/src/KOKKOS/pair_table_kokkos.cpp b/src/KOKKOS/pair_table_kokkos.cpp index 737d600d1e..01966d708a 100644 --- a/src/KOKKOS/pair_table_kokkos.cpp +++ b/src/KOKKOS/pair_table_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Christian Trott (SNL) ------------------------------------------------------------------------- */ +#include "pair_table_kokkos.h" #include #include #include #include -#include "pair_table_kokkos.h" #include "kokkos.h" #include "atom.h" #include "force.h" diff --git a/src/KOKKOS/pair_table_rx_kokkos.cpp b/src/KOKKOS/pair_table_rx_kokkos.cpp index ec7a2ffb94..7c2d20c68d 100644 --- a/src/KOKKOS/pair_table_rx_kokkos.cpp +++ b/src/KOKKOS/pair_table_rx_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Dan Ibanez (SNL) ------------------------------------------------------------------------- */ +#include "pair_table_rx_kokkos.h" #include #include #include #include -#include "pair_table_rx_kokkos.h" #include "kokkos.h" #include "atom.h" #include "force.h" diff --git a/src/KOKKOS/pair_tersoff_kokkos.cpp b/src/KOKKOS/pair_tersoff_kokkos.cpp index 9252e3de52..b68af84425 100644 --- a/src/KOKKOS/pair_tersoff_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) and Christian Trott (SNL) ------------------------------------------------------------------------- */ +#include "pair_tersoff_kokkos.h" #include #include #include #include -#include "pair_tersoff_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_tersoff_mod_kokkos.cpp b/src/KOKKOS/pair_tersoff_mod_kokkos.cpp index 585074b128..b6921179c0 100644 --- a/src/KOKKOS/pair_tersoff_mod_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_mod_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_tersoff_mod_kokkos.h" #include #include #include #include -#include "pair_tersoff_mod_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp b/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp index e1e2211ab5..60ff0a7269 100644 --- a/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (SNL) ------------------------------------------------------------------------- */ +#include "pair_tersoff_zbl_kokkos.h" #include #include #include #include -#include "pair_tersoff_zbl_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_vashishta_kokkos.cpp b/src/KOKKOS/pair_vashishta_kokkos.cpp index 4a1f291b17..febb171c83 100644 --- a/src/KOKKOS/pair_vashishta_kokkos.cpp +++ b/src/KOKKOS/pair_vashishta_kokkos.cpp @@ -15,11 +15,11 @@ Contributing author: Anders Hafreager (UiO), andershaf@gmail.com ------------------------------------------------------------------------- */ +#include "pair_vashishta_kokkos.h" #include #include #include #include -#include "pair_vashishta_kokkos.h" #include "kokkos.h" #include "pair_kokkos.h" #include "atom_kokkos.h" diff --git a/src/KOKKOS/pair_yukawa_kokkos.cpp b/src/KOKKOS/pair_yukawa_kokkos.cpp index 27e18533a2..acfeb2fbdc 100644 --- a/src/KOKKOS/pair_yukawa_kokkos.cpp +++ b/src/KOKKOS/pair_yukawa_kokkos.cpp @@ -14,9 +14,10 @@ /* ---------------------------------------------------------------------- Contributing authors: Stefan Paquay (Brandeis University) ------------------------------------------------------------------------- */ + +#include "pair_yukawa_kokkos.h" #include #include -#include "pair_yukawa_kokkos.h" #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" diff --git a/src/KOKKOS/pair_zbl_kokkos.cpp b/src/KOKKOS/pair_zbl_kokkos.cpp index 06c84e5189..0f21331266 100644 --- a/src/KOKKOS/pair_zbl_kokkos.cpp +++ b/src/KOKKOS/pair_zbl_kokkos.cpp @@ -15,11 +15,11 @@ Contributing authors: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_zbl_kokkos.h" #include #include #include #include -#include "pair_zbl_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "force.h" diff --git a/src/KOKKOS/pppm_kokkos.cpp b/src/KOKKOS/pppm_kokkos.cpp index 7c01adc510..1842524e23 100644 --- a/src/KOKKOS/pppm_kokkos.cpp +++ b/src/KOKKOS/pppm_kokkos.cpp @@ -15,12 +15,12 @@ Contributing author: Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pppm_kokkos.h" #include #include #include #include #include -#include "pppm_kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "gridcomm_kokkos.h" diff --git a/src/KOKKOS/rand_pool_wrap_kokkos.cpp b/src/KOKKOS/rand_pool_wrap_kokkos.cpp index 51ebcb154e..2d8865feb0 100644 --- a/src/KOKKOS/rand_pool_wrap_kokkos.cpp +++ b/src/KOKKOS/rand_pool_wrap_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include "comm.h" #include "rand_pool_wrap_kokkos.h" +#include "comm.h" #include "lammps.h" #include "kokkos.h" #include "random_mars.h" diff --git a/src/KOKKOS/region_block_kokkos.cpp b/src/KOKKOS/region_block_kokkos.cpp index 730ef81466..a5734f6ba7 100644 --- a/src/KOKKOS/region_block_kokkos.cpp +++ b/src/KOKKOS/region_block_kokkos.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "region_block_kokkos.h" #include #include -#include "region_block_kokkos.h" #include "domain.h" #include "force.h" #include "atom_kokkos.h" diff --git a/src/KOKKOS/verlet_kokkos.cpp b/src/KOKKOS/verlet_kokkos.cpp index b80d5e0646..d555b74d23 100644 --- a/src/KOKKOS/verlet_kokkos.cpp +++ b/src/KOKKOS/verlet_kokkos.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "verlet_kokkos.h" +#include #include "neighbor.h" #include "domain.h" #include "comm.h" diff --git a/src/KSPACE/ewald.cpp b/src/KSPACE/ewald.cpp index ccbb3ed708..aad0e364d0 100644 --- a/src/KSPACE/ewald.cpp +++ b/src/KSPACE/ewald.cpp @@ -18,12 +18,12 @@ triclinic added by Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "ewald.h" #include #include #include #include #include -#include "ewald.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/ewald_dipole.cpp b/src/KSPACE/ewald_dipole.cpp index 89ef7e39a8..53bac0637f 100644 --- a/src/KSPACE/ewald_dipole.cpp +++ b/src/KSPACE/ewald_dipole.cpp @@ -15,12 +15,12 @@ Contributing authors: Julien Tranchida (SNL), Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "ewald_dipole.h" #include #include #include #include #include -#include "ewald_dipole.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/ewald_dipole_spin.cpp b/src/KSPACE/ewald_dipole_spin.cpp index 698203c85c..2b6c95f174 100644 --- a/src/KSPACE/ewald_dipole_spin.cpp +++ b/src/KSPACE/ewald_dipole_spin.cpp @@ -15,12 +15,12 @@ Contributing authors: Julien Tranchida (SNL) ------------------------------------------------------------------------- */ +#include "ewald_dipole_spin.h" #include #include #include #include #include -#include "ewald_dipole_spin.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/ewald_disp.cpp b/src/KSPACE/ewald_disp.cpp index 0603d68eb2..c775056dd8 100644 --- a/src/KSPACE/ewald_disp.cpp +++ b/src/KSPACE/ewald_disp.cpp @@ -15,12 +15,12 @@ Contributing authors: Pieter in 't Veld (SNL), Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "ewald_disp.h" #include #include #include #include #include -#include "ewald_disp.h" #include "math_vector.h" #include "math_const.h" #include "math_special.h" diff --git a/src/KSPACE/fft3d.cpp b/src/KSPACE/fft3d.cpp index 7d3c8c83f2..e4c38a57f5 100644 --- a/src/KSPACE/fft3d.cpp +++ b/src/KSPACE/fft3d.cpp @@ -19,11 +19,11 @@ Paul Coffman (IBM) added MPI collectives remap ------------------------------------------------------------------------- */ +#include "fft3d.h" #include #include #include #include -#include "fft3d.h" #include "remap.h" #ifdef FFT_KISS diff --git a/src/KSPACE/fft3d_wrap.cpp b/src/KSPACE/fft3d_wrap.cpp index b9a6f0ae46..507b23d27d 100644 --- a/src/KSPACE/fft3d_wrap.cpp +++ b/src/KSPACE/fft3d_wrap.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fft3d_wrap.h" +#include #include "error.h" using namespace LAMMPS_NS; diff --git a/src/KSPACE/fix_tune_kspace.cpp b/src/KSPACE/fix_tune_kspace.cpp index 2b22b44340..cfd88609b3 100644 --- a/src/KSPACE/fix_tune_kspace.cpp +++ b/src/KSPACE/fix_tune_kspace.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "fix_tune_kspace.h" #include #include #include -#include "fix_tune_kspace.h" #include "update.h" #include "force.h" #include "kspace.h" diff --git a/src/KSPACE/gridcomm.cpp b/src/KSPACE/gridcomm.cpp index ba08c9be26..552d80daab 100644 --- a/src/KSPACE/gridcomm.cpp +++ b/src/KSPACE/gridcomm.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "gridcomm.h" +#include #include "comm.h" #include "kspace.h" #include "memory.h" diff --git a/src/KSPACE/msm.cpp b/src/KSPACE/msm.cpp index d7cc3f6876..bc5360dcd2 100644 --- a/src/KSPACE/msm.cpp +++ b/src/KSPACE/msm.cpp @@ -15,12 +15,12 @@ Contributing authors: Paul Crozier, Stan Moore, Stephen Bond, (all SNL) ------------------------------------------------------------------------- */ +#include "msm.h" #include #include #include #include #include -#include "msm.h" #include "atom.h" #include "comm.h" #include "gridcomm.h" diff --git a/src/KSPACE/msm_cg.cpp b/src/KSPACE/msm_cg.cpp index c7896db50c..22976b8442 100644 --- a/src/KSPACE/msm_cg.cpp +++ b/src/KSPACE/msm_cg.cpp @@ -15,6 +15,7 @@ Contributing authors: Paul Crozier, Stan Moore, Stephen Bond, (all SNL) ------------------------------------------------------------------------- */ +#include "msm_cg.h" #include #include #include @@ -27,7 +28,6 @@ #include "force.h" #include "neighbor.h" #include "memory.h" -#include "msm_cg.h" #include "math_const.h" diff --git a/src/KSPACE/pair_born_coul_long.cpp b/src/KSPACE/pair_born_coul_long.cpp index f12f5779d9..cb8360e401 100644 --- a/src/KSPACE/pair_born_coul_long.cpp +++ b/src/KSPACE/pair_born_coul_long.cpp @@ -15,11 +15,11 @@ Contributing author: Ahmed Ismail (SNL) ------------------------------------------------------------------------- */ +#include "pair_born_coul_long.h" #include #include #include #include -#include "pair_born_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_born_coul_msm.cpp b/src/KSPACE/pair_born_coul_msm.cpp index eaa1c116c1..deaf224334 100644 --- a/src/KSPACE/pair_born_coul_msm.cpp +++ b/src/KSPACE/pair_born_coul_msm.cpp @@ -15,11 +15,11 @@ Contributing author: Stan Moore (SNL), Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_born_coul_msm.h" #include #include #include #include -#include "pair_born_coul_msm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_buck_coul_long.cpp b/src/KSPACE/pair_buck_coul_long.cpp index a5427965dc..c97856fa3c 100644 --- a/src/KSPACE/pair_buck_coul_long.cpp +++ b/src/KSPACE/pair_buck_coul_long.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_buck_coul_long.h" #include #include #include -#include "pair_buck_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_buck_coul_msm.cpp b/src/KSPACE/pair_buck_coul_msm.cpp index 257d1b661f..3d7687df90 100644 --- a/src/KSPACE/pair_buck_coul_msm.cpp +++ b/src/KSPACE/pair_buck_coul_msm.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_buck_coul_msm.h" #include #include #include #include -#include "pair_buck_coul_msm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_buck_long_coul_long.cpp b/src/KSPACE/pair_buck_long_coul_long.cpp index bcd290891e..8127cbc127 100644 --- a/src/KSPACE/pair_buck_long_coul_long.cpp +++ b/src/KSPACE/pair_buck_long_coul_long.cpp @@ -15,11 +15,11 @@ Contributing author: Pieter J. in 't Veld (SNL) ------------------------------------------------------------------------- */ +#include "pair_buck_long_coul_long.h" #include #include #include #include "math_vector.h" -#include "pair_buck_long_coul_long.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/KSPACE/pair_coul_long.cpp b/src/KSPACE/pair_coul_long.cpp index ae268b9857..cb45b7a906 100644 --- a/src/KSPACE/pair_coul_long.cpp +++ b/src/KSPACE/pair_coul_long.cpp @@ -15,11 +15,11 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_coul_long.h" #include #include #include #include -#include "pair_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_coul_msm.cpp b/src/KSPACE/pair_coul_msm.cpp index 960505142c..2173171e79 100644 --- a/src/KSPACE/pair_coul_msm.cpp +++ b/src/KSPACE/pair_coul_msm.cpp @@ -15,11 +15,11 @@ Contributing authors: Stan Moore (SNL), Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_coul_msm.h" #include #include #include #include -#include "pair_coul_msm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_lj_charmm_coul_long.cpp b/src/KSPACE/pair_lj_charmm_coul_long.cpp index b40eab244b..3ad14c8ea7 100644 --- a/src/KSPACE/pair_lj_charmm_coul_long.cpp +++ b/src/KSPACE/pair_lj_charmm_coul_long.cpp @@ -15,11 +15,11 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_long.h" #include #include #include #include -#include "pair_lj_charmm_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_lj_charmm_coul_msm.cpp b/src/KSPACE/pair_lj_charmm_coul_msm.cpp index 72a8e340bc..2d1775802f 100644 --- a/src/KSPACE/pair_lj_charmm_coul_msm.cpp +++ b/src/KSPACE/pair_lj_charmm_coul_msm.cpp @@ -15,11 +15,11 @@ Contributing authors: Paul Crozier (SNL), Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_msm.h" #include #include #include #include -#include "pair_lj_charmm_coul_msm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp b/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp index cdde211157..7f32613cba 100644 --- a/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp +++ b/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp @@ -19,11 +19,11 @@ additional assistance from Robert A. Latour, Clemson University ------------------------------------------------------------------------- */ +#include "pair_lj_charmmfsw_coul_long.h" #include #include #include #include -#include "pair_lj_charmmfsw_coul_long.h" #include "atom.h" #include "update.h" #include "comm.h" diff --git a/src/KSPACE/pair_lj_cut_coul_long.cpp b/src/KSPACE/pair_lj_cut_coul_long.cpp index fde7fa8e35..59f4766fa3 100644 --- a/src/KSPACE/pair_lj_cut_coul_long.cpp +++ b/src/KSPACE/pair_lj_cut_coul_long.cpp @@ -15,11 +15,11 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_long.h" #include #include #include #include -#include "pair_lj_cut_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_lj_cut_coul_msm.cpp b/src/KSPACE/pair_lj_cut_coul_msm.cpp index c2e566a117..1305d485da 100644 --- a/src/KSPACE/pair_lj_cut_coul_msm.cpp +++ b/src/KSPACE/pair_lj_cut_coul_msm.cpp @@ -15,11 +15,11 @@ Contributing authors: Stan Moore (SNL), Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_coul_msm.h" #include #include #include #include -#include "pair_lj_cut_coul_msm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/KSPACE/pair_lj_cut_tip4p_long.cpp b/src/KSPACE/pair_lj_cut_tip4p_long.cpp index f5889fd520..cd9b3c032d 100644 --- a/src/KSPACE/pair_lj_cut_tip4p_long.cpp +++ b/src/KSPACE/pair_lj_cut_tip4p_long.cpp @@ -16,11 +16,11 @@ simpler force assignment added by Rolf Isele-Holder (Aachen University) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_tip4p_long.h" #include #include #include #include -#include "pair_lj_cut_tip4p_long.h" #include "angle.h" #include "atom.h" #include "bond.h" diff --git a/src/KSPACE/pair_lj_long_coul_long.cpp b/src/KSPACE/pair_lj_long_coul_long.cpp index 493866a895..46dbb60a96 100644 --- a/src/KSPACE/pair_lj_long_coul_long.cpp +++ b/src/KSPACE/pair_lj_long_coul_long.cpp @@ -17,12 +17,12 @@ University New Orleans) ------------------------------------------------------------------------- */ +#include "pair_lj_long_coul_long.h" #include #include #include #include #include "math_vector.h" -#include "pair_lj_long_coul_long.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/KSPACE/pair_lj_long_tip4p_long.cpp b/src/KSPACE/pair_lj_long_tip4p_long.cpp index 3137b9d79a..5a1e347c78 100644 --- a/src/KSPACE/pair_lj_long_tip4p_long.cpp +++ b/src/KSPACE/pair_lj_long_tip4p_long.cpp @@ -16,11 +16,11 @@ Rolf Isele-Holder (Aachen University) ------------------------------------------------------------------------- */ +#include "pair_lj_long_tip4p_long.h" #include #include #include #include -#include "pair_lj_long_tip4p_long.h" #include "angle.h" #include "atom.h" #include "bond.h" diff --git a/src/KSPACE/pair_tip4p_long.cpp b/src/KSPACE/pair_tip4p_long.cpp index 9419fdf196..deb8662a8b 100644 --- a/src/KSPACE/pair_tip4p_long.cpp +++ b/src/KSPACE/pair_tip4p_long.cpp @@ -16,11 +16,11 @@ simpler force assignment added by Rolf Isele-Holder (Aachen University) ------------------------------------------------------------------------- */ +#include "pair_tip4p_long.h" #include #include #include #include -#include "pair_tip4p_long.h" #include "angle.h" #include "atom.h" #include "bond.h" diff --git a/src/KSPACE/pppm.cpp b/src/KSPACE/pppm.cpp index 53c18804a5..ae545c5c27 100644 --- a/src/KSPACE/pppm.cpp +++ b/src/KSPACE/pppm.cpp @@ -18,12 +18,12 @@ triclinic added by Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pppm.h" #include #include #include #include #include -#include "pppm.h" #include "atom.h" #include "comm.h" #include "gridcomm.h" diff --git a/src/KSPACE/pppm_cg.cpp b/src/KSPACE/pppm_cg.cpp index 3285dba21c..f9bd7b0cb4 100644 --- a/src/KSPACE/pppm_cg.cpp +++ b/src/KSPACE/pppm_cg.cpp @@ -15,11 +15,11 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_cg.h" #include #include #include #include - #include "atom.h" #include "gridcomm.h" #include "domain.h" @@ -27,8 +27,6 @@ #include "force.h" #include "neighbor.h" #include "memory.h" -#include "pppm_cg.h" - #include "math_const.h" using namespace LAMMPS_NS; diff --git a/src/KSPACE/pppm_dipole.cpp b/src/KSPACE/pppm_dipole.cpp index 21a777dd75..ad03b8205a 100644 --- a/src/KSPACE/pppm_dipole.cpp +++ b/src/KSPACE/pppm_dipole.cpp @@ -15,12 +15,12 @@ Contributing authors: Stan Moore (SNL), Julien Tranchida (SNL) ------------------------------------------------------------------------- */ +#include "pppm_dipole.h" #include #include #include #include #include -#include "pppm_dipole.h" #include "atom.h" #include "comm.h" #include "gridcomm.h" diff --git a/src/KSPACE/pppm_dipole_spin.cpp b/src/KSPACE/pppm_dipole_spin.cpp index 878d40c82e..2c96eadde1 100644 --- a/src/KSPACE/pppm_dipole_spin.cpp +++ b/src/KSPACE/pppm_dipole_spin.cpp @@ -15,12 +15,12 @@ Contributing author: Julien Tranchida (SNL) ------------------------------------------------------------------------- */ +#include "pppm_dipole_spin.h" #include #include #include #include #include -#include "pppm_dipole_spin.h" #include "atom.h" #include "comm.h" #include "gridcomm.h" diff --git a/src/KSPACE/pppm_disp.cpp b/src/KSPACE/pppm_disp.cpp index 45dce0895b..22e570049c 100644 --- a/src/KSPACE/pppm_disp.cpp +++ b/src/KSPACE/pppm_disp.cpp @@ -16,12 +16,12 @@ Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pppm_disp.h" #include #include #include #include #include -#include "pppm_disp.h" #include "math_const.h" #include "atom.h" #include "comm.h" diff --git a/src/KSPACE/pppm_disp_tip4p.cpp b/src/KSPACE/pppm_disp_tip4p.cpp index 2bc63a84bb..36e6159131 100644 --- a/src/KSPACE/pppm_disp_tip4p.cpp +++ b/src/KSPACE/pppm_disp_tip4p.cpp @@ -16,8 +16,8 @@ Rolf Isele-Holder (Aachen University) ------------------------------------------------------------------------- */ -#include #include "pppm_disp_tip4p.h" +#include #include "pppm_disp.h" #include "atom.h" #include "domain.h" diff --git a/src/KSPACE/pppm_stagger.cpp b/src/KSPACE/pppm_stagger.cpp index a5ed6de626..5c2e2a6098 100644 --- a/src/KSPACE/pppm_stagger.cpp +++ b/src/KSPACE/pppm_stagger.cpp @@ -15,12 +15,12 @@ Contributing author: Stan Moore (Sandia) ------------------------------------------------------------------------- */ +#include "pppm_stagger.h" #include #include #include #include #include -#include "pppm_stagger.h" #include "atom.h" #include "gridcomm.h" #include "force.h" diff --git a/src/KSPACE/pppm_tip4p.cpp b/src/KSPACE/pppm_tip4p.cpp index b9fe3e6488..52a1fb3787 100644 --- a/src/KSPACE/pppm_tip4p.cpp +++ b/src/KSPACE/pppm_tip4p.cpp @@ -15,8 +15,8 @@ Contributing authors: Amalie Frischknecht and Ahmed Ismail (SNL) ------------------------------------------------------------------------- */ -#include #include "pppm_tip4p.h" +#include #include "atom.h" #include "domain.h" #include "force.h" diff --git a/src/KSPACE/remap.cpp b/src/KSPACE/remap.cpp index 26541f121e..85fe78c9d7 100644 --- a/src/KSPACE/remap.cpp +++ b/src/KSPACE/remap.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "remap.h" #include #include -#include "remap.h" #define PACK_DATA FFT_SCALAR diff --git a/src/KSPACE/remap_wrap.cpp b/src/KSPACE/remap_wrap.cpp index 8ea2918d7f..7929cd053c 100644 --- a/src/KSPACE/remap_wrap.cpp +++ b/src/KSPACE/remap_wrap.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "remap_wrap.h" +#include #include "error.h" using namespace LAMMPS_NS; From 6cf3bb3e4e5e5176b985fe820876e0d240e1159e Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 3 Jul 2019 21:56:29 -0400 Subject: [PATCH 34/79] recover compilation of KSPACE package --- src/KSPACE/fft3d.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/KSPACE/fft3d.h b/src/KSPACE/fft3d.h index a51818d986..8c3d2f27ad 100644 --- a/src/KSPACE/fft3d.h +++ b/src/KSPACE/fft3d.h @@ -11,6 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include + // User-settable FFT precision // FFT_PRECISION = 1 is single-precision complex (4-byte real, 4-byte imag) From 416911aa7e05a94328bfb9f1d7a580f40a450603 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 3 Jul 2019 21:57:39 -0400 Subject: [PATCH 35/79] more rearranging of include file order to put implementation headers first --- src/LATTE/fix_latte.cpp | 2 +- src/MANYBODY/fix_qeq_comb.cpp | 2 +- src/MANYBODY/pair_adp.cpp | 2 +- src/MANYBODY/pair_airebo.cpp | 2 +- src/MANYBODY/pair_atm.cpp | 2 +- src/MANYBODY/pair_bop.cpp | 2 +- src/MANYBODY/pair_comb.cpp | 2 +- src/MANYBODY/pair_comb3.cpp | 2 +- src/MANYBODY/pair_eam.cpp | 2 +- src/MANYBODY/pair_eam_alloy.cpp | 2 +- src/MANYBODY/pair_eam_cd.cpp | 2 +- src/MANYBODY/pair_eam_fs.cpp | 2 +- src/MANYBODY/pair_eim.cpp | 2 +- src/MANYBODY/pair_gw.cpp | 2 +- src/MANYBODY/pair_gw_zbl.cpp | 2 +- src/MANYBODY/pair_lcbop.cpp | 2 +- src/MANYBODY/pair_nb3b_harmonic.cpp | 2 +- src/MANYBODY/pair_polymorphic.cpp | 2 +- src/MANYBODY/pair_sw.cpp | 2 +- src/MANYBODY/pair_tersoff.cpp | 2 +- src/MANYBODY/pair_tersoff_mod.cpp | 2 +- src/MANYBODY/pair_tersoff_mod_c.cpp | 2 +- src/MANYBODY/pair_tersoff_zbl.cpp | 2 +- src/MANYBODY/pair_vashishta.cpp | 2 +- src/MANYBODY/pair_vashishta_table.cpp | 2 +- src/MC/fix_atom_swap.cpp | 2 +- src/MC/fix_bond_break.cpp | 2 +- src/MC/fix_bond_create.cpp | 2 +- src/MC/fix_bond_swap.cpp | 2 +- src/MC/fix_gcmc.cpp | 2 +- src/MC/pair_dsmc.cpp | 2 +- src/MESSAGE/fix_client_md.cpp | 2 +- src/MESSAGE/message.cpp | 2 +- src/MESSAGE/server.cpp | 2 +- src/MESSAGE/server_md.cpp | 2 +- src/MISC/compute_msd_nongauss.cpp | 2 +- src/MISC/compute_ti.cpp | 6 ++--- src/MISC/dump_xtc.cpp | 2 +- src/MISC/fix_deposit.cpp | 2 +- src/MISC/fix_efield.cpp | 2 +- src/MISC/fix_evaporate.cpp | 2 +- src/MISC/fix_gld.cpp | 2 +- src/MISC/fix_oneway.cpp | 2 +- src/MISC/fix_orient_bcc.cpp | 2 +- src/MISC/fix_orient_fcc.cpp | 2 +- src/MISC/fix_thermal_conductivity.cpp | 2 +- src/MISC/fix_ttm.cpp | 2 +- src/MISC/fix_viscosity.cpp | 2 +- src/MISC/pair_nm_cut.cpp | 2 +- src/MISC/pair_nm_cut_coul_cut.cpp | 2 +- src/MISC/pair_nm_cut_coul_long.cpp | 2 +- src/MISC/xdr_compat.cpp | 2 +- src/MOLECULE/angle_charmm.cpp | 2 +- src/MOLECULE/angle_cosine.cpp | 2 +- src/MOLECULE/angle_cosine_delta.cpp | 2 +- src/MOLECULE/angle_cosine_periodic.cpp | 2 +- src/MOLECULE/angle_cosine_squared.cpp | 2 +- src/MOLECULE/angle_harmonic.cpp | 2 +- src/MOLECULE/angle_table.cpp | 2 +- src/MOLECULE/atom_vec_angle.cpp | 2 +- src/MOLECULE/atom_vec_bond.cpp | 2 +- src/MOLECULE/atom_vec_full.cpp | 2 +- src/MOLECULE/atom_vec_molecular.cpp | 2 +- src/MOLECULE/atom_vec_template.cpp | 2 +- src/MOLECULE/bond_fene.cpp | 2 +- src/MOLECULE/bond_fene_expand.cpp | 2 +- src/MOLECULE/bond_gromos.cpp | 2 +- src/MOLECULE/bond_harmonic.cpp | 2 +- src/MOLECULE/bond_morse.cpp | 2 +- src/MOLECULE/bond_nonlinear.cpp | 2 +- src/MOLECULE/bond_quartic.cpp | 2 +- src/MOLECULE/bond_table.cpp | 2 +- src/MOLECULE/dihedral_charmm.cpp | 2 +- src/MOLECULE/dihedral_charmmfsw.cpp | 2 +- src/MOLECULE/dihedral_harmonic.cpp | 2 +- src/MOLECULE/dihedral_helix.cpp | 2 +- src/MOLECULE/dihedral_multi_harmonic.cpp | 2 +- src/MOLECULE/dihedral_opls.cpp | 2 +- src/MOLECULE/fix_cmap.cpp | 2 +- src/MOLECULE/improper_cvff.cpp | 2 +- src/MOLECULE/improper_harmonic.cpp | 2 +- src/MOLECULE/improper_umbrella.cpp | 2 +- src/MOLECULE/pair_hbond_dreiding_lj.cpp | 2 +- src/MOLECULE/pair_hbond_dreiding_morse.cpp | 2 +- src/MOLECULE/pair_lj_charmm_coul_charmm.cpp | 2 +- .../pair_lj_charmm_coul_charmm_implicit.cpp | 2 +- .../pair_lj_charmmfsw_coul_charmmfsh.cpp | 2 +- src/MOLECULE/pair_lj_cut_tip4p_cut.cpp | 2 +- src/MOLECULE/pair_tip4p_cut.cpp | 2 +- src/MPIIO/dump_atom_mpiio.cpp | 2 +- src/MPIIO/dump_cfg_mpiio.cpp | 2 +- src/MPIIO/dump_custom_mpiio.cpp | 2 +- src/MPIIO/dump_xyz_mpiio.cpp | 2 +- src/MPIIO/restart_mpiio.cpp | 2 +- src/MSCG/fix_mscg.cpp | 2 +- src/OPT/pair_eam_opt.cpp | 2 +- src/OPT/pair_lj_charmm_coul_long_opt.cpp | 2 +- src/OPT/pair_lj_cut_coul_long_opt.cpp | 2 +- src/OPT/pair_lj_cut_opt.cpp | 2 +- src/OPT/pair_lj_cut_tip4p_long_opt.cpp | 2 +- src/OPT/pair_lj_long_coul_long_opt.cpp | 2 +- src/OPT/pair_morse_opt.cpp | 2 +- src/OPT/pair_ufm_opt.cpp | 2 +- src/PERI/atom_vec_peri.cpp | 2 +- src/PERI/compute_damage_atom.cpp | 2 +- src/PERI/compute_dilatation_atom.cpp | 2 +- src/PERI/compute_plasticity_atom.cpp | 2 +- src/PERI/fix_peri_neigh.cpp | 2 +- src/PERI/pair_peri_eps.cpp | 2 +- src/PERI/pair_peri_lps.cpp | 2 +- src/PERI/pair_peri_pmb.cpp | 2 +- src/PERI/pair_peri_ves.cpp | 2 +- src/POEMS/fix_poems.cpp | 2 +- src/PYTHON/fix_python_invoke.cpp | 2 +- src/PYTHON/fix_python_move.cpp | 2 +- src/PYTHON/pair_python.cpp | 2 +- src/PYTHON/python_impl.cpp | 2 +- src/QEQ/fix_qeq.cpp | 2 +- src/QEQ/fix_qeq_dynamic.cpp | 2 +- src/QEQ/fix_qeq_fire.cpp | 2 +- src/QEQ/fix_qeq_point.cpp | 2 +- src/QEQ/fix_qeq_shielded.cpp | 2 +- src/QEQ/fix_qeq_slater.cpp | 2 +- src/REPLICA/compute_event_displace.cpp | 2 +- src/REPLICA/fix_event.cpp | 2 +- src/REPLICA/fix_event_hyper.cpp | 2 +- src/REPLICA/fix_event_prd.cpp | 2 +- src/REPLICA/fix_event_tad.cpp | 2 +- src/REPLICA/fix_hyper.cpp | 2 +- src/REPLICA/fix_hyper_global.cpp | 2 +- src/REPLICA/fix_hyper_local.cpp | 2 +- src/REPLICA/fix_neb.cpp | 2 +- src/REPLICA/hyper.cpp | 2 +- src/REPLICA/neb.cpp | 2 +- src/REPLICA/prd.cpp | 2 +- src/REPLICA/tad.cpp | 2 +- src/REPLICA/temper.cpp | 2 +- src/REPLICA/verlet_split.cpp | 2 +- src/RIGID/compute_erotate_rigid.cpp | 2 +- src/RIGID/compute_ke_rigid.cpp | 2 +- src/RIGID/compute_rigid_local.cpp | 2 +- src/RIGID/fix_ehex.cpp | 2 +- src/RIGID/fix_rattle.cpp | 2 +- src/RIGID/fix_rigid.cpp | 2 +- src/RIGID/fix_rigid_nh.cpp | 2 +- src/RIGID/fix_rigid_nh_small.cpp | 2 +- src/RIGID/fix_rigid_nph.cpp | 2 +- src/RIGID/fix_rigid_nph_small.cpp | 2 +- src/RIGID/fix_rigid_npt.cpp | 2 +- src/RIGID/fix_rigid_npt_small.cpp | 2 +- src/RIGID/fix_rigid_small.cpp | 2 +- src/RIGID/fix_shake.cpp | 2 +- src/SHOCK/fix_append_atoms.cpp | 2 +- src/SHOCK/fix_msst.cpp | 2 +- src/SHOCK/fix_nphug.cpp | 2 +- src/SHOCK/fix_wall_piston.cpp | 2 +- src/SNAP/compute_sna_atom.cpp | 5 ++-- src/SNAP/compute_snad_atom.cpp | 5 ++-- src/SNAP/compute_snav_atom.cpp | 3 ++- src/SNAP/pair_snap.cpp | 2 +- src/SNAP/sna.cpp | 2 +- src/SPIN/atom_vec_spin.cpp | 2 +- src/SPIN/compute_spin.cpp | 2 +- src/SPIN/fix_langevin_spin.cpp | 2 +- src/SPIN/fix_neb_spin.cpp | 2 +- src/SPIN/fix_nve_spin.cpp | 2 +- src/SPIN/fix_precession_spin.cpp | 2 +- src/SPIN/fix_setforce_spin.cpp | 2 +- src/SPIN/min_spin.cpp | 2 +- src/SPIN/neb_spin.cpp | 2 +- src/SPIN/pair_spin.cpp | 2 +- src/SPIN/pair_spin_dipole_cut.cpp | 2 +- src/SPIN/pair_spin_dipole_long.cpp | 2 +- src/SPIN/pair_spin_dmi.cpp | 2 +- src/SPIN/pair_spin_exchange.cpp | 2 +- src/SPIN/pair_spin_magelec.cpp | 2 +- src/SPIN/pair_spin_neel.cpp | 2 +- src/SRD/fix_srd.cpp | 2 +- src/SRD/fix_wall_srd.cpp | 2 +- src/USER-ADIOS/dump_atom_adios.cpp | 2 +- src/USER-ADIOS/dump_custom_adios.cpp | 4 +-- src/USER-ATC/fix_atc.cpp | 10 +++---- src/USER-AWPMD/atom_vec_wavepacket.cpp | 2 +- src/USER-AWPMD/fix_nve_awpmd.cpp | 2 +- src/USER-AWPMD/pair_awpmd_cut.cpp | 2 +- src/USER-BOCS/compute_pressure_bocs.cpp | 2 +- src/USER-BOCS/fix_bocs.cpp | 2 +- src/USER-CGDNA/bond_oxdna2_fene.cpp | 2 +- src/USER-CGDNA/bond_oxdna_fene.cpp | 2 +- src/USER-CGDNA/fix_nve_dot.cpp | 2 +- src/USER-CGDNA/fix_nve_dotc_langevin.cpp | 2 +- src/USER-CGDNA/pair_oxdna2_coaxstk.cpp | 2 +- src/USER-CGDNA/pair_oxdna2_dh.cpp | 2 +- src/USER-CGDNA/pair_oxdna2_excv.cpp | 2 +- src/USER-CGDNA/pair_oxdna2_stk.cpp | 2 +- src/USER-CGDNA/pair_oxdna_coaxstk.cpp | 2 +- src/USER-CGDNA/pair_oxdna_excv.cpp | 2 +- src/USER-CGDNA/pair_oxdna_hbond.cpp | 2 +- src/USER-CGDNA/pair_oxdna_stk.cpp | 2 +- src/USER-CGDNA/pair_oxdna_xstk.cpp | 2 +- src/USER-CGSDK/angle_sdk.cpp | 2 +- src/USER-CGSDK/pair_lj_sdk.cpp | 2 +- src/USER-CGSDK/pair_lj_sdk_coul_long.cpp | 2 +- src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp | 2 +- src/USER-COLVARS/colvarproxy_lammps.cpp | 26 +++++++++---------- src/USER-COLVARS/fix_colvars.cpp | 2 +- src/USER-COLVARS/group_ndx.cpp | 5 ++-- src/USER-COLVARS/ndx_group.cpp | 7 +++-- 208 files changed, 234 insertions(+), 235 deletions(-) diff --git a/src/LATTE/fix_latte.cpp b/src/LATTE/fix_latte.cpp index 645b298e09..7d4e89272d 100644 --- a/src/LATTE/fix_latte.cpp +++ b/src/LATTE/fix_latte.cpp @@ -15,9 +15,9 @@ Contributing author: Christian Negre (LANL) ------------------------------------------------------------------------- */ +#include "fix_latte.h" #include #include -#include "fix_latte.h" #include "atom.h" #include "comm.h" #include "update.h" diff --git a/src/MANYBODY/fix_qeq_comb.cpp b/src/MANYBODY/fix_qeq_comb.cpp index 5019e7711a..9e9bbcc9d6 100644 --- a/src/MANYBODY/fix_qeq_comb.cpp +++ b/src/MANYBODY/fix_qeq_comb.cpp @@ -15,13 +15,13 @@ Contributing authors: Ray Shan (Sandia, tnshan@sandia.gov) ------------------------------------------------------------------------- */ +#include "fix_qeq_comb.h" #include #include #include #include #include "pair_comb.h" #include "pair_comb3.h" -#include "fix_qeq_comb.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/MANYBODY/pair_adp.cpp b/src/MANYBODY/pair_adp.cpp index 68511b8709..8051f97634 100644 --- a/src/MANYBODY/pair_adp.cpp +++ b/src/MANYBODY/pair_adp.cpp @@ -16,11 +16,11 @@ Chandra Veer Singh (Cornell) ------------------------------------------------------------------------- */ +#include "pair_adp.h" #include #include #include #include -#include "pair_adp.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/MANYBODY/pair_airebo.cpp b/src/MANYBODY/pair_airebo.cpp index e3c5a1627b..fd2016b7a7 100644 --- a/src/MANYBODY/pair_airebo.cpp +++ b/src/MANYBODY/pair_airebo.cpp @@ -20,12 +20,12 @@ Thomas C. O'Connor (JHU) 2014 ------------------------------------------------------------------------- */ +#include "pair_airebo.h" #include #include #include #include #include -#include "pair_airebo.h" #include "atom.h" #include "neighbor.h" #include "force.h" diff --git a/src/MANYBODY/pair_atm.cpp b/src/MANYBODY/pair_atm.cpp index c157e0763c..ba68033721 100644 --- a/src/MANYBODY/pair_atm.cpp +++ b/src/MANYBODY/pair_atm.cpp @@ -15,8 +15,8 @@ Contributing author: Sergey Lishchuk ------------------------------------------------------------------------- */ -#include #include "pair_atm.h" +#include #include "atom.h" #include "citeme.h" #include "comm.h" diff --git a/src/MANYBODY/pair_bop.cpp b/src/MANYBODY/pair_bop.cpp index ac157e071c..27c24ce3d7 100644 --- a/src/MANYBODY/pair_bop.cpp +++ b/src/MANYBODY/pair_bop.cpp @@ -32,12 +32,12 @@ Rules"_http://lammps.sandia.gov/open_source.html ------------------------------------------------------------------------- */ +#include "pair_bop.h" #include #include #include #include #include -#include "pair_bop.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MANYBODY/pair_comb.cpp b/src/MANYBODY/pair_comb.cpp index 980aa84b2a..b9a17eeb35 100644 --- a/src/MANYBODY/pair_comb.cpp +++ b/src/MANYBODY/pair_comb.cpp @@ -18,11 +18,11 @@ and Aidan Thompson's Tersoff code in LAMMPS ------------------------------------------------------------------------- */ +#include "pair_comb.h" #include #include #include #include -#include "pair_comb.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MANYBODY/pair_comb3.cpp b/src/MANYBODY/pair_comb3.cpp index 097f235ff2..846ef7d4b9 100644 --- a/src/MANYBODY/pair_comb3.cpp +++ b/src/MANYBODY/pair_comb3.cpp @@ -17,11 +17,11 @@ Dundar Yilmaz (dundar.yilmaz@zirve.edu.tr) ------------------------------------------------------------------------- */ +#include "pair_comb3.h" #include #include #include #include -#include "pair_comb3.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MANYBODY/pair_eam.cpp b/src/MANYBODY/pair_eam.cpp index b7957349b6..e6476b78c5 100644 --- a/src/MANYBODY/pair_eam.cpp +++ b/src/MANYBODY/pair_eam.cpp @@ -15,11 +15,11 @@ Contributing authors: Stephen Foiles (SNL), Murray Daw (SNL) ------------------------------------------------------------------------- */ +#include "pair_eam.h" #include #include #include #include -#include "pair_eam.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/MANYBODY/pair_eam_alloy.cpp b/src/MANYBODY/pair_eam_alloy.cpp index c004030240..7aae786720 100644 --- a/src/MANYBODY/pair_eam_alloy.cpp +++ b/src/MANYBODY/pair_eam_alloy.cpp @@ -15,10 +15,10 @@ Contributing authors: Stephen Foiles (SNL), Murray Daw (SNL) ------------------------------------------------------------------------- */ +#include "pair_eam_alloy.h" #include #include #include -#include "pair_eam_alloy.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MANYBODY/pair_eam_cd.cpp b/src/MANYBODY/pair_eam_cd.cpp index c111c6d950..55ad597cce 100644 --- a/src/MANYBODY/pair_eam_cd.cpp +++ b/src/MANYBODY/pair_eam_cd.cpp @@ -17,11 +17,11 @@ Germany Department of Materials Science ------------------------------------------------------------------------- */ +#include "pair_eam_cd.h" #include #include #include #include -#include "pair_eam_cd.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/MANYBODY/pair_eam_fs.cpp b/src/MANYBODY/pair_eam_fs.cpp index bbda84fdf1..7b13988d0c 100644 --- a/src/MANYBODY/pair_eam_fs.cpp +++ b/src/MANYBODY/pair_eam_fs.cpp @@ -15,10 +15,10 @@ Contributing authors: Tim Lau (MIT) ------------------------------------------------------------------------- */ +#include "pair_eam_fs.h" #include #include #include -#include "pair_eam_fs.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MANYBODY/pair_eim.cpp b/src/MANYBODY/pair_eim.cpp index f1c028ef38..58cb1fd2e0 100644 --- a/src/MANYBODY/pair_eim.cpp +++ b/src/MANYBODY/pair_eim.cpp @@ -15,11 +15,11 @@ Contributing author: Xiaowang Zhou (SNL) ------------------------------------------------------------------------- */ +#include "pair_eim.h" #include #include #include #include -#include "pair_eim.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/MANYBODY/pair_gw.cpp b/src/MANYBODY/pair_gw.cpp index e4b74f7a29..07e9201f94 100644 --- a/src/MANYBODY/pair_gw.cpp +++ b/src/MANYBODY/pair_gw.cpp @@ -16,11 +16,11 @@ based on PairTersoff by Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "pair_gw.h" #include #include #include #include -#include "pair_gw.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/MANYBODY/pair_gw_zbl.cpp b/src/MANYBODY/pair_gw_zbl.cpp index f3dd1bc04b..cd83727ed3 100644 --- a/src/MANYBODY/pair_gw_zbl.cpp +++ b/src/MANYBODY/pair_gw_zbl.cpp @@ -16,11 +16,11 @@ Based on PairTersoffZBL by Aidan Thompson (SNL) and David Farrell (NWU) ------------------------------------------------------------------------- */ +#include "pair_gw_zbl.h" #include #include #include #include -#include "pair_gw_zbl.h" #include "atom.h" #include "update.h" #include "neighbor.h" diff --git a/src/MANYBODY/pair_lcbop.cpp b/src/MANYBODY/pair_lcbop.cpp index 05cdea8055..b0240978a9 100644 --- a/src/MANYBODY/pair_lcbop.cpp +++ b/src/MANYBODY/pair_lcbop.cpp @@ -16,12 +16,12 @@ based on pair_airebo by Ase Henry (MIT) ------------------------------------------------------------------------- */ +#include "pair_lcbop.h" #include #include #include #include #include -#include "pair_lcbop.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MANYBODY/pair_nb3b_harmonic.cpp b/src/MANYBODY/pair_nb3b_harmonic.cpp index a61b403459..ac20c3e61f 100644 --- a/src/MANYBODY/pair_nb3b_harmonic.cpp +++ b/src/MANYBODY/pair_nb3b_harmonic.cpp @@ -16,11 +16,11 @@ (based on Stillinger-Weber pair style) ------------------------------------------------------------------------- */ +#include "pair_nb3b_harmonic.h" #include #include #include #include -#include "pair_nb3b_harmonic.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MANYBODY/pair_polymorphic.cpp b/src/MANYBODY/pair_polymorphic.cpp index d3aca4e889..0cca50823d 100644 --- a/src/MANYBODY/pair_polymorphic.cpp +++ b/src/MANYBODY/pair_polymorphic.cpp @@ -16,11 +16,11 @@ This modifies from pair_tersoff.cpp by Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "pair_polymorphic.h" #include #include #include #include -#include "pair_polymorphic.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/MANYBODY/pair_sw.cpp b/src/MANYBODY/pair_sw.cpp index 5a148fb152..ea47fc97c3 100644 --- a/src/MANYBODY/pair_sw.cpp +++ b/src/MANYBODY/pair_sw.cpp @@ -15,11 +15,11 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "pair_sw.h" #include #include #include #include -#include "pair_sw.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MANYBODY/pair_tersoff.cpp b/src/MANYBODY/pair_tersoff.cpp index 213b1037bb..9d7f804f9a 100644 --- a/src/MANYBODY/pair_tersoff.cpp +++ b/src/MANYBODY/pair_tersoff.cpp @@ -15,11 +15,11 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "pair_tersoff.h" #include #include #include #include -#include "pair_tersoff.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/MANYBODY/pair_tersoff_mod.cpp b/src/MANYBODY/pair_tersoff_mod.cpp index e8fdecfe01..df3c41fc33 100644 --- a/src/MANYBODY/pair_tersoff_mod.cpp +++ b/src/MANYBODY/pair_tersoff_mod.cpp @@ -16,11 +16,11 @@ Vitaly Dozhdikov (JIHT of RAS) - MOD addition ------------------------------------------------------------------------- */ +#include "pair_tersoff_mod.h" #include #include #include #include -#include "pair_tersoff_mod.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/MANYBODY/pair_tersoff_mod_c.cpp b/src/MANYBODY/pair_tersoff_mod_c.cpp index 4a5904c106..d34291f6cd 100644 --- a/src/MANYBODY/pair_tersoff_mod_c.cpp +++ b/src/MANYBODY/pair_tersoff_mod_c.cpp @@ -15,11 +15,11 @@ Contributing author: Ganga P Purja Pun (George Mason University, Fairfax) ------------------------------------------------------------------------- */ +#include "pair_tersoff_mod_c.h" #include #include #include #include -#include "pair_tersoff_mod_c.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/MANYBODY/pair_tersoff_zbl.cpp b/src/MANYBODY/pair_tersoff_zbl.cpp index 353e3d2264..6a8aa40782 100644 --- a/src/MANYBODY/pair_tersoff_zbl.cpp +++ b/src/MANYBODY/pair_tersoff_zbl.cpp @@ -16,11 +16,11 @@ David Farrell (NWU) - ZBL addition ------------------------------------------------------------------------- */ +#include "pair_tersoff_zbl.h" #include #include #include #include -#include "pair_tersoff_zbl.h" #include "atom.h" #include "update.h" #include "neighbor.h" diff --git a/src/MANYBODY/pair_vashishta.cpp b/src/MANYBODY/pair_vashishta.cpp index 3d4b1d900e..5055dadfaf 100644 --- a/src/MANYBODY/pair_vashishta.cpp +++ b/src/MANYBODY/pair_vashishta.cpp @@ -16,11 +16,11 @@ Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "pair_vashishta.h" #include #include #include #include -#include "pair_vashishta.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MANYBODY/pair_vashishta_table.cpp b/src/MANYBODY/pair_vashishta_table.cpp index d4eaa59f1a..726e0f83f1 100644 --- a/src/MANYBODY/pair_vashishta_table.cpp +++ b/src/MANYBODY/pair_vashishta_table.cpp @@ -15,11 +15,11 @@ Contributing author: Anders Hafreager (UiO), andershaf@gmail.com ------------------------------------------------------------------------- */ +#include "pair_vashishta_table.h" #include #include #include #include -#include "pair_vashishta_table.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MC/fix_atom_swap.cpp b/src/MC/fix_atom_swap.cpp index 7d817ffbb1..c14efcca46 100644 --- a/src/MC/fix_atom_swap.cpp +++ b/src/MC/fix_atom_swap.cpp @@ -16,11 +16,11 @@ Alexander Stukowski ------------------------------------------------------------------------- */ +#include "fix_atom_swap.h" #include #include #include #include -#include "fix_atom_swap.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_hybrid.h" diff --git a/src/MC/fix_bond_break.cpp b/src/MC/fix_bond_break.cpp index 05edc0509e..1b07395f1e 100644 --- a/src/MC/fix_bond_break.cpp +++ b/src/MC/fix_bond_break.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_bond_break.h" #include #include #include #include -#include "fix_bond_break.h" #include "update.h" #include "respa.h" #include "atom.h" diff --git a/src/MC/fix_bond_create.cpp b/src/MC/fix_bond_create.cpp index e1dd18cb5b..d2d93b67f6 100644 --- a/src/MC/fix_bond_create.cpp +++ b/src/MC/fix_bond_create.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_bond_create.h" #include #include #include #include -#include "fix_bond_create.h" #include "update.h" #include "respa.h" #include "atom.h" diff --git a/src/MC/fix_bond_swap.cpp b/src/MC/fix_bond_swap.cpp index 5da2b845d6..187c552416 100644 --- a/src/MC/fix_bond_swap.cpp +++ b/src/MC/fix_bond_swap.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_bond_swap.h" #include #include #include -#include "fix_bond_swap.h" #include "atom.h" #include "force.h" #include "pair.h" diff --git a/src/MC/fix_gcmc.cpp b/src/MC/fix_gcmc.cpp index 4e48b71611..8fe6042c2e 100644 --- a/src/MC/fix_gcmc.cpp +++ b/src/MC/fix_gcmc.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Crozier, Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "fix_gcmc.h" #include #include #include -#include "fix_gcmc.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_hybrid.h" diff --git a/src/MC/pair_dsmc.cpp b/src/MC/pair_dsmc.cpp index c71eaa2295..cf48706133 100644 --- a/src/MC/pair_dsmc.cpp +++ b/src/MC/pair_dsmc.cpp @@ -15,12 +15,12 @@ Contributing authors: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_dsmc.h" #include #include #include #include #include -#include "pair_dsmc.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MESSAGE/fix_client_md.cpp b/src/MESSAGE/fix_client_md.cpp index 727481dcc0..7d4ae13f0f 100644 --- a/src/MESSAGE/fix_client_md.cpp +++ b/src/MESSAGE/fix_client_md.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_client_md.h" #include #include -#include "fix_client_md.h" #include "update.h" #include "atom.h" #include "comm.h" diff --git a/src/MESSAGE/message.cpp b/src/MESSAGE/message.cpp index 61221ca26e..f8fc349746 100644 --- a/src/MESSAGE/message.cpp +++ b/src/MESSAGE/message.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "message.h" +#include #include "error.h" // CSlib interface diff --git a/src/MESSAGE/server.cpp b/src/MESSAGE/server.cpp index f587fb76df..dbcec08488 100644 --- a/src/MESSAGE/server.cpp +++ b/src/MESSAGE/server.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "server.h" +#include #include "error.h" // customize by adding a new server protocol include and enum diff --git a/src/MESSAGE/server_md.cpp b/src/MESSAGE/server_md.cpp index bef327616e..e16095ad4c 100644 --- a/src/MESSAGE/server_md.cpp +++ b/src/MESSAGE/server_md.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "server_md.h" #include #include -#include "server_md.h" #include "atom.h" #include "atom_vec.h" #include "update.h" diff --git a/src/MISC/compute_msd_nongauss.cpp b/src/MISC/compute_msd_nongauss.cpp index f6291f4204..e02dd633cb 100644 --- a/src/MISC/compute_msd_nongauss.cpp +++ b/src/MISC/compute_msd_nongauss.cpp @@ -15,8 +15,8 @@ Contributing authors: Rob Hoy ------------------------------------------------------------------------- */ -#include #include "compute_msd_nongauss.h" +#include #include "atom.h" #include "update.h" #include "group.h" diff --git a/src/MISC/compute_ti.cpp b/src/MISC/compute_ti.cpp index d2e43a9f69..266263785f 100644 --- a/src/MISC/compute_ti.cpp +++ b/src/MISC/compute_ti.cpp @@ -15,10 +15,10 @@ Contributing author: Sai Jayaraman (University of Notre Dame) ------------------------------------------------------------------------- */ -#include -#include "atom.h" -#include #include "compute_ti.h" +#include +#include +#include "atom.h" #include "update.h" #include "modify.h" #include "domain.h" diff --git a/src/MISC/dump_xtc.cpp b/src/MISC/dump_xtc.cpp index a82cba20bd..7abe4c4093 100644 --- a/src/MISC/dump_xtc.cpp +++ b/src/MISC/dump_xtc.cpp @@ -22,12 +22,12 @@ support for groups ------------------------------------------------------------------------- */ +#include "dump_xtc.h" #include #include #include #include #include -#include "dump_xtc.h" #include "domain.h" #include "atom.h" #include "update.h" diff --git a/src/MISC/fix_deposit.cpp b/src/MISC/fix_deposit.cpp index 66aed34846..22a144da60 100644 --- a/src/MISC/fix_deposit.cpp +++ b/src/MISC/fix_deposit.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_deposit.h" #include #include #include -#include "fix_deposit.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/MISC/fix_efield.cpp b/src/MISC/fix_efield.cpp index 004c8ad7bc..87ece82f57 100644 --- a/src/MISC/fix_efield.cpp +++ b/src/MISC/fix_efield.cpp @@ -16,10 +16,10 @@ Stan Moore (Sandia) for dipole terms ------------------------------------------------------------------------- */ +#include "fix_efield.h" #include #include #include -#include "fix_efield.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/MISC/fix_evaporate.cpp b/src/MISC/fix_evaporate.cpp index 1bf7a15f1f..e2c7844853 100644 --- a/src/MISC/fix_evaporate.cpp +++ b/src/MISC/fix_evaporate.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_evaporate.h" #include #include #include -#include "fix_evaporate.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/MISC/fix_gld.cpp b/src/MISC/fix_gld.cpp index 2bf02889a5..265ee4fb09 100644 --- a/src/MISC/fix_gld.cpp +++ b/src/MISC/fix_gld.cpp @@ -16,10 +16,10 @@ Andrew Baczewski (Michigan State/SNL) ------------------------------------------------------------------------- */ +#include "fix_gld.h" #include #include #include -#include "fix_gld.h" #include "math_extra.h" #include "atom.h" #include "force.h" diff --git a/src/MISC/fix_oneway.cpp b/src/MISC/fix_oneway.cpp index 73853775a3..fcf5a7a0bd 100644 --- a/src/MISC/fix_oneway.cpp +++ b/src/MISC/fix_oneway.cpp @@ -15,8 +15,8 @@ Contributing author: Axel Kohlmeyer (ICTP, Italy) ------------------------------------------------------------------------- */ -#include #include "fix_oneway.h" +#include #include "atom.h" #include "domain.h" #include "error.h" diff --git a/src/MISC/fix_orient_bcc.cpp b/src/MISC/fix_orient_bcc.cpp index 02cce5a014..a300631658 100644 --- a/src/MISC/fix_orient_bcc.cpp +++ b/src/MISC/fix_orient_bcc.cpp @@ -18,11 +18,11 @@ (https://dx.doi.org/10.6084/m9.figshare.1488628.v1 ------------------------------------------------------------------------- */ +#include "fix_orient_bcc.h" #include #include #include #include -#include "fix_orient_bcc.h" #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/MISC/fix_orient_fcc.cpp b/src/MISC/fix_orient_fcc.cpp index fc827ceb8f..d898f95d2c 100644 --- a/src/MISC/fix_orient_fcc.cpp +++ b/src/MISC/fix_orient_fcc.cpp @@ -15,11 +15,11 @@ Contributing authors: Koenraad Janssens and David Olmsted (SNL) ------------------------------------------------------------------------- */ +#include "fix_orient_fcc.h" #include #include #include #include -#include "fix_orient_fcc.h" #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/MISC/fix_thermal_conductivity.cpp b/src/MISC/fix_thermal_conductivity.cpp index f1aec3ff69..8da303c8ab 100644 --- a/src/MISC/fix_thermal_conductivity.cpp +++ b/src/MISC/fix_thermal_conductivity.cpp @@ -16,11 +16,11 @@ for swapping atoms of different masses ------------------------------------------------------------------------- */ +#include "fix_thermal_conductivity.h" #include #include #include #include -#include "fix_thermal_conductivity.h" #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/MISC/fix_ttm.cpp b/src/MISC/fix_ttm.cpp index 170103b0d0..06de732de6 100644 --- a/src/MISC/fix_ttm.cpp +++ b/src/MISC/fix_ttm.cpp @@ -16,11 +16,11 @@ Carolyn Phillips (University of Michigan) ------------------------------------------------------------------------- */ +#include "fix_ttm.h" #include #include #include #include -#include "fix_ttm.h" #include "atom.h" #include "force.h" #include "update.h" diff --git a/src/MISC/fix_viscosity.cpp b/src/MISC/fix_viscosity.cpp index 8e33c1c614..52107954c2 100644 --- a/src/MISC/fix_viscosity.cpp +++ b/src/MISC/fix_viscosity.cpp @@ -16,11 +16,11 @@ for swapping atoms of different masses ------------------------------------------------------------------------- */ +#include "fix_viscosity.h" #include #include #include #include -#include "fix_viscosity.h" #include "atom.h" #include "domain.h" #include "modify.h" diff --git a/src/MISC/pair_nm_cut.cpp b/src/MISC/pair_nm_cut.cpp index 124832b63e..9b8c36da3a 100644 --- a/src/MISC/pair_nm_cut.cpp +++ b/src/MISC/pair_nm_cut.cpp @@ -15,11 +15,11 @@ Contributing Author: Julien Devemy (ICCF) ------------------------------------------------------------------------- */ +#include "pair_nm_cut.h" #include #include #include #include -#include "pair_nm_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MISC/pair_nm_cut_coul_cut.cpp b/src/MISC/pair_nm_cut_coul_cut.cpp index a8428ab980..069c363817 100644 --- a/src/MISC/pair_nm_cut_coul_cut.cpp +++ b/src/MISC/pair_nm_cut_coul_cut.cpp @@ -15,11 +15,11 @@ Contributing Author: Julien Devemy (ICCF) ------------------------------------------------------------------------- */ +#include "pair_nm_cut_coul_cut.h" #include #include #include #include -#include "pair_nm_cut_coul_cut.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MISC/pair_nm_cut_coul_long.cpp b/src/MISC/pair_nm_cut_coul_long.cpp index af21f02881..b3d42b05f8 100644 --- a/src/MISC/pair_nm_cut_coul_long.cpp +++ b/src/MISC/pair_nm_cut_coul_long.cpp @@ -15,11 +15,11 @@ Contributing Author: Julien Devemy (ICCF) ------------------------------------------------------------------------- */ +#include "pair_nm_cut_coul_long.h" #include #include #include #include -#include "pair_nm_cut_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MISC/xdr_compat.cpp b/src/MISC/xdr_compat.cpp index 2d8d0ce7e5..e124d52d7b 100644 --- a/src/MISC/xdr_compat.cpp +++ b/src/MISC/xdr_compat.cpp @@ -1,7 +1,7 @@ +#include "xdr_compat.h" #include #include #include -#include "xdr_compat.h" /* This file is needed for systems, that do not provide XDR support * in their system libraries. It was written for windows, but will diff --git a/src/MOLECULE/angle_charmm.cpp b/src/MOLECULE/angle_charmm.cpp index efd1c682f7..fb0afd78c3 100644 --- a/src/MOLECULE/angle_charmm.cpp +++ b/src/MOLECULE/angle_charmm.cpp @@ -15,9 +15,9 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "angle_charmm.h" #include #include -#include "angle_charmm.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_cosine.cpp b/src/MOLECULE/angle_cosine.cpp index 6e1b9fa2fb..aff5130323 100644 --- a/src/MOLECULE/angle_cosine.cpp +++ b/src/MOLECULE/angle_cosine.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "angle_cosine.h" #include #include -#include "angle_cosine.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_cosine_delta.cpp b/src/MOLECULE/angle_cosine_delta.cpp index eca10970f2..13ed00b327 100644 --- a/src/MOLECULE/angle_cosine_delta.cpp +++ b/src/MOLECULE/angle_cosine_delta.cpp @@ -15,9 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U), akohlmey at gmail.com ------------------------------------------------------------------------- */ +#include "angle_cosine_delta.h" #include #include -#include "angle_cosine_delta.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_cosine_periodic.cpp b/src/MOLECULE/angle_cosine_periodic.cpp index cb0a26871a..9f7c02cabc 100644 --- a/src/MOLECULE/angle_cosine_periodic.cpp +++ b/src/MOLECULE/angle_cosine_periodic.cpp @@ -15,9 +15,9 @@ Contributing author: Tod A Pascal (Caltech) ------------------------------------------------------------------------- */ +#include "angle_cosine_periodic.h" #include #include -#include "angle_cosine_periodic.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_cosine_squared.cpp b/src/MOLECULE/angle_cosine_squared.cpp index 28d63344a4..789a536c98 100644 --- a/src/MOLECULE/angle_cosine_squared.cpp +++ b/src/MOLECULE/angle_cosine_squared.cpp @@ -15,9 +15,9 @@ Contributing author: Naveen Michaud-Agrawal (Johns Hopkins U) ------------------------------------------------------------------------- */ +#include "angle_cosine_squared.h" #include #include -#include "angle_cosine_squared.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_harmonic.cpp b/src/MOLECULE/angle_harmonic.cpp index 48b493d9b2..b626bdfae5 100644 --- a/src/MOLECULE/angle_harmonic.cpp +++ b/src/MOLECULE/angle_harmonic.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "angle_harmonic.h" #include #include -#include "angle_harmonic.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_table.cpp b/src/MOLECULE/angle_table.cpp index c18b4c43b0..ce7fcdcaf2 100644 --- a/src/MOLECULE/angle_table.cpp +++ b/src/MOLECULE/angle_table.cpp @@ -15,10 +15,10 @@ Contributing author: Chuanfu Luo (luochuanfu@gmail.com) ------------------------------------------------------------------------- */ +#include "angle_table.h" #include #include #include -#include "angle_table.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/atom_vec_angle.cpp b/src/MOLECULE/atom_vec_angle.cpp index 6eb5b50fd2..f3c48aa87a 100644 --- a/src/MOLECULE/atom_vec_angle.cpp +++ b/src/MOLECULE/atom_vec_angle.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_angle.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/MOLECULE/atom_vec_bond.cpp b/src/MOLECULE/atom_vec_bond.cpp index 6a7b3585b4..b0f76adc45 100644 --- a/src/MOLECULE/atom_vec_bond.cpp +++ b/src/MOLECULE/atom_vec_bond.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_bond.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/MOLECULE/atom_vec_full.cpp b/src/MOLECULE/atom_vec_full.cpp index d682abf799..c9b2402062 100644 --- a/src/MOLECULE/atom_vec_full.cpp +++ b/src/MOLECULE/atom_vec_full.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_full.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/MOLECULE/atom_vec_molecular.cpp b/src/MOLECULE/atom_vec_molecular.cpp index cdd3f02505..524f7bcb0d 100644 --- a/src/MOLECULE/atom_vec_molecular.cpp +++ b/src/MOLECULE/atom_vec_molecular.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "atom_vec_molecular.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/MOLECULE/atom_vec_template.cpp b/src/MOLECULE/atom_vec_template.cpp index 3172804b95..6a12027b7b 100644 --- a/src/MOLECULE/atom_vec_template.cpp +++ b/src/MOLECULE/atom_vec_template.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "atom_vec_template.h" #include #include -#include "atom_vec_template.h" #include "atom.h" #include "molecule.h" #include "comm.h" diff --git a/src/MOLECULE/bond_fene.cpp b/src/MOLECULE/bond_fene.cpp index c023a7e81e..d4f2a4010e 100644 --- a/src/MOLECULE/bond_fene.cpp +++ b/src/MOLECULE/bond_fene.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "bond_fene.h" #include #include -#include "bond_fene.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/bond_fene_expand.cpp b/src/MOLECULE/bond_fene_expand.cpp index b1bfdc6a1b..3e4ceab42c 100644 --- a/src/MOLECULE/bond_fene_expand.cpp +++ b/src/MOLECULE/bond_fene_expand.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "bond_fene_expand.h" #include #include -#include "bond_fene_expand.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/bond_gromos.cpp b/src/MOLECULE/bond_gromos.cpp index f65adeb2cb..44e99d8fe0 100644 --- a/src/MOLECULE/bond_gromos.cpp +++ b/src/MOLECULE/bond_gromos.cpp @@ -15,10 +15,10 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "bond_gromos.h" #include #include #include -#include "bond_gromos.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/bond_harmonic.cpp b/src/MOLECULE/bond_harmonic.cpp index cb8434ce6e..bbbad4102d 100644 --- a/src/MOLECULE/bond_harmonic.cpp +++ b/src/MOLECULE/bond_harmonic.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "bond_harmonic.h" #include #include #include -#include "bond_harmonic.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/bond_morse.cpp b/src/MOLECULE/bond_morse.cpp index 91dd2dbc49..af476d6fe8 100644 --- a/src/MOLECULE/bond_morse.cpp +++ b/src/MOLECULE/bond_morse.cpp @@ -15,9 +15,9 @@ Contributing author: Jeff Greathouse (SNL) ------------------------------------------------------------------------- */ +#include "bond_morse.h" #include #include -#include "bond_morse.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/bond_nonlinear.cpp b/src/MOLECULE/bond_nonlinear.cpp index 9999ead47f..89ddb7b118 100644 --- a/src/MOLECULE/bond_nonlinear.cpp +++ b/src/MOLECULE/bond_nonlinear.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "bond_nonlinear.h" #include #include -#include "bond_nonlinear.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/bond_quartic.cpp b/src/MOLECULE/bond_quartic.cpp index 895202ff00..34b3ad8288 100644 --- a/src/MOLECULE/bond_quartic.cpp +++ b/src/MOLECULE/bond_quartic.cpp @@ -15,9 +15,9 @@ Contributing authors: Chris Lorenz and Mark Stevens (SNL) ------------------------------------------------------------------------- */ +#include "bond_quartic.h" #include #include -#include "bond_quartic.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/bond_table.cpp b/src/MOLECULE/bond_table.cpp index 10851774d7..e80baee6e8 100644 --- a/src/MOLECULE/bond_table.cpp +++ b/src/MOLECULE/bond_table.cpp @@ -15,10 +15,10 @@ Contributing author: Chuanfu Luo (luochuanfu@gmail.com) ------------------------------------------------------------------------- */ +#include "bond_table.h" #include #include #include -#include "bond_table.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/dihedral_charmm.cpp b/src/MOLECULE/dihedral_charmm.cpp index 68c62eb4fd..1905c14358 100644 --- a/src/MOLECULE/dihedral_charmm.cpp +++ b/src/MOLECULE/dihedral_charmm.cpp @@ -15,11 +15,11 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "dihedral_charmm.h" #include #include #include #include -#include "dihedral_charmm.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/MOLECULE/dihedral_charmmfsw.cpp b/src/MOLECULE/dihedral_charmmfsw.cpp index f65d01e9ed..9b02b908d6 100644 --- a/src/MOLECULE/dihedral_charmmfsw.cpp +++ b/src/MOLECULE/dihedral_charmmfsw.cpp @@ -18,11 +18,11 @@ with additional assistance from Robert A. Latour, Clemson University ------------------------------------------------------------------------- */ +#include "dihedral_charmmfsw.h" #include #include #include #include -#include "dihedral_charmmfsw.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/MOLECULE/dihedral_harmonic.cpp b/src/MOLECULE/dihedral_harmonic.cpp index ddb94dc571..159636ecd5 100644 --- a/src/MOLECULE/dihedral_harmonic.cpp +++ b/src/MOLECULE/dihedral_harmonic.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "dihedral_harmonic.h" #include #include #include -#include "dihedral_harmonic.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/MOLECULE/dihedral_helix.cpp b/src/MOLECULE/dihedral_helix.cpp index d19731c097..a7d2aba1d6 100644 --- a/src/MOLECULE/dihedral_helix.cpp +++ b/src/MOLECULE/dihedral_helix.cpp @@ -16,10 +16,10 @@ Mark Stevens (Sandia) ------------------------------------------------------------------------- */ +#include "dihedral_helix.h" #include #include #include -#include "dihedral_helix.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/dihedral_multi_harmonic.cpp b/src/MOLECULE/dihedral_multi_harmonic.cpp index 04e7bbb627..ba98cf6ddf 100644 --- a/src/MOLECULE/dihedral_multi_harmonic.cpp +++ b/src/MOLECULE/dihedral_multi_harmonic.cpp @@ -15,9 +15,9 @@ Contributing author: Mathias Puetz (SNL) and friends ------------------------------------------------------------------------- */ +#include "dihedral_multi_harmonic.h" #include #include -#include "dihedral_multi_harmonic.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/dihedral_opls.cpp b/src/MOLECULE/dihedral_opls.cpp index 293245e411..d68eba0bec 100644 --- a/src/MOLECULE/dihedral_opls.cpp +++ b/src/MOLECULE/dihedral_opls.cpp @@ -15,9 +15,9 @@ Contributing author: Mark Stevens (SNL) ------------------------------------------------------------------------- */ +#include "dihedral_opls.h" #include #include -#include "dihedral_opls.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/MOLECULE/fix_cmap.cpp b/src/MOLECULE/fix_cmap.cpp index 3395c7ef14..3d5bf90bdc 100644 --- a/src/MOLECULE/fix_cmap.cpp +++ b/src/MOLECULE/fix_cmap.cpp @@ -27,12 +27,12 @@ - MacKerell et al., J. Comput. Chem. 25(2004):1400-1415. ------------------------------------------------------------------------- */ +#include "fix_cmap.h" #include #include #include #include #include -#include "fix_cmap.h" #include "atom.h" #include "atom_vec.h" #include "update.h" diff --git a/src/MOLECULE/improper_cvff.cpp b/src/MOLECULE/improper_cvff.cpp index 01e9729e80..fd24ab69c3 100644 --- a/src/MOLECULE/improper_cvff.cpp +++ b/src/MOLECULE/improper_cvff.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "improper_cvff.h" #include #include #include -#include "improper_cvff.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/MOLECULE/improper_harmonic.cpp b/src/MOLECULE/improper_harmonic.cpp index c5421fffdb..936c22e94a 100644 --- a/src/MOLECULE/improper_harmonic.cpp +++ b/src/MOLECULE/improper_harmonic.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "improper_harmonic.h" #include #include #include -#include "improper_harmonic.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/MOLECULE/improper_umbrella.cpp b/src/MOLECULE/improper_umbrella.cpp index 3de46df0f3..2e41ac6493 100644 --- a/src/MOLECULE/improper_umbrella.cpp +++ b/src/MOLECULE/improper_umbrella.cpp @@ -15,10 +15,10 @@ Contributing author: Tod A Pascal (Caltech) ------------------------------------------------------------------------- */ +#include "improper_umbrella.h" #include #include #include -#include "improper_umbrella.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/MOLECULE/pair_hbond_dreiding_lj.cpp b/src/MOLECULE/pair_hbond_dreiding_lj.cpp index ddc1110081..58666f27d1 100644 --- a/src/MOLECULE/pair_hbond_dreiding_lj.cpp +++ b/src/MOLECULE/pair_hbond_dreiding_lj.cpp @@ -15,11 +15,11 @@ Contributing author: Tod A Pascal (Caltech) ------------------------------------------------------------------------- */ +#include "pair_hbond_dreiding_lj.h" #include #include #include #include -#include "pair_hbond_dreiding_lj.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/MOLECULE/pair_hbond_dreiding_morse.cpp b/src/MOLECULE/pair_hbond_dreiding_morse.cpp index 055f0ed46b..120a2d8d55 100644 --- a/src/MOLECULE/pair_hbond_dreiding_morse.cpp +++ b/src/MOLECULE/pair_hbond_dreiding_morse.cpp @@ -15,11 +15,11 @@ Contributing author: Tod A Pascal (Caltech) ------------------------------------------------------------------------- */ +#include "pair_hbond_dreiding_morse.h" #include #include #include #include -#include "pair_hbond_dreiding_morse.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp b/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp index af4611e014..c9becb75c3 100644 --- a/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp +++ b/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp @@ -15,11 +15,11 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_charmm.h" #include #include #include #include -#include "pair_lj_charmm_coul_charmm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp b/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp index d68d5e8f6d..a2be2936b2 100644 --- a/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp +++ b/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_charmm_implicit.h" #include #include -#include "pair_lj_charmm_coul_charmm_implicit.h" #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp b/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp index 0e1cbd85a5..f2f16c88ce 100644 --- a/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp +++ b/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp @@ -19,11 +19,11 @@ with additional assistance from Robert A. Latour, Clemson University ------------------------------------------------------------------------- */ +#include "pair_lj_charmmfsw_coul_charmmfsh.h" #include #include #include #include -#include "pair_lj_charmmfsw_coul_charmmfsh.h" #include "atom.h" #include "update.h" #include "comm.h" diff --git a/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp b/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp index 2b3d2c60f5..5bb82d7635 100644 --- a/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp +++ b/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp @@ -15,10 +15,10 @@ Contributing author: Pavel Elkind (Gothenburg University) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_tip4p_cut.h" #include #include #include -#include "pair_lj_cut_tip4p_cut.h" #include "atom.h" #include "force.h" #include "neighbor.h" diff --git a/src/MOLECULE/pair_tip4p_cut.cpp b/src/MOLECULE/pair_tip4p_cut.cpp index e6fb9aab99..1511c09384 100644 --- a/src/MOLECULE/pair_tip4p_cut.cpp +++ b/src/MOLECULE/pair_tip4p_cut.cpp @@ -15,9 +15,9 @@ Contributing author: Pavel Elkind (Gothenburg University) ------------------------------------------------------------------------- */ +#include "pair_tip4p_cut.h" #include #include -#include "pair_tip4p_cut.h" #include "atom.h" #include "force.h" #include "neighbor.h" diff --git a/src/MPIIO/dump_atom_mpiio.cpp b/src/MPIIO/dump_atom_mpiio.cpp index f2f2991442..cde5b6258b 100644 --- a/src/MPIIO/dump_atom_mpiio.cpp +++ b/src/MPIIO/dump_atom_mpiio.cpp @@ -15,8 +15,8 @@ Contributing author: Paul Coffman (IBM) ------------------------------------------------------------------------- */ -#include #include "dump_atom_mpiio.h" +#include #include "domain.h" #include "atom.h" #include "update.h" diff --git a/src/MPIIO/dump_cfg_mpiio.cpp b/src/MPIIO/dump_cfg_mpiio.cpp index c580d2e7af..90f92d094d 100644 --- a/src/MPIIO/dump_cfg_mpiio.cpp +++ b/src/MPIIO/dump_cfg_mpiio.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Coffman (IBM) ------------------------------------------------------------------------- */ +#include "dump_cfg_mpiio.h" #include #include #include -#include "dump_cfg_mpiio.h" #include "atom.h" #include "domain.h" #include "comm.h" diff --git a/src/MPIIO/dump_custom_mpiio.cpp b/src/MPIIO/dump_custom_mpiio.cpp index 3650ca994e..5838c61124 100644 --- a/src/MPIIO/dump_custom_mpiio.cpp +++ b/src/MPIIO/dump_custom_mpiio.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Coffman (IBM) ------------------------------------------------------------------------- */ +#include "dump_custom_mpiio.h" #include #include #include -#include "dump_custom_mpiio.h" #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/MPIIO/dump_xyz_mpiio.cpp b/src/MPIIO/dump_xyz_mpiio.cpp index f15d340cd1..7b647561bf 100644 --- a/src/MPIIO/dump_xyz_mpiio.cpp +++ b/src/MPIIO/dump_xyz_mpiio.cpp @@ -15,10 +15,10 @@ Contributing author: Paul Coffman (IBM) ------------------------------------------------------------------------- */ +#include "dump_xyz_mpiio.h" #include #include #include -#include "dump_xyz_mpiio.h" #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/MPIIO/restart_mpiio.cpp b/src/MPIIO/restart_mpiio.cpp index 804df211dc..e8ef5c6c4e 100644 --- a/src/MPIIO/restart_mpiio.cpp +++ b/src/MPIIO/restart_mpiio.cpp @@ -15,9 +15,9 @@ Contributing author: Paul Coffman (IBM) ------------------------------------------------------------------------- */ +#include "restart_mpiio.h" #include #include -#include "restart_mpiio.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/MSCG/fix_mscg.cpp b/src/MSCG/fix_mscg.cpp index b282595240..caa9a528a7 100644 --- a/src/MSCG/fix_mscg.cpp +++ b/src/MSCG/fix_mscg.cpp @@ -15,10 +15,10 @@ Contributing authors: Lauren Abbott (Sandia) ------------------------------------------------------------------------- */ +#include "fix_mscg.h" #include #include #include -#include "fix_mscg.h" #include "mscg.h" #include "atom.h" #include "comm.h" diff --git a/src/OPT/pair_eam_opt.cpp b/src/OPT/pair_eam_opt.cpp index fc2b6731ee..ad24aaee63 100644 --- a/src/OPT/pair_eam_opt.cpp +++ b/src/OPT/pair_eam_opt.cpp @@ -19,9 +19,9 @@ Vincent Natoli, Stone Ridge Technology ------------------------------------------------------------------------- */ +#include "pair_eam_opt.h" #include #include -#include "pair_eam_opt.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/OPT/pair_lj_charmm_coul_long_opt.cpp b/src/OPT/pair_lj_charmm_coul_long_opt.cpp index d80d3d1ec4..3dc6bdb6b4 100644 --- a/src/OPT/pair_lj_charmm_coul_long_opt.cpp +++ b/src/OPT/pair_lj_charmm_coul_long_opt.cpp @@ -18,9 +18,9 @@ Vincent Natoli, Stone Ridge Technology ------------------------------------------------------------------------- */ +#include "pair_lj_charmm_coul_long_opt.h" #include #include -#include "pair_lj_charmm_coul_long_opt.h" #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/OPT/pair_lj_cut_coul_long_opt.cpp b/src/OPT/pair_lj_cut_coul_long_opt.cpp index a25010cf1f..a1f97aaae9 100644 --- a/src/OPT/pair_lj_cut_coul_long_opt.cpp +++ b/src/OPT/pair_lj_cut_coul_long_opt.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "pair_lj_cut_coul_long_opt.h" +#include #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/OPT/pair_lj_cut_opt.cpp b/src/OPT/pair_lj_cut_opt.cpp index c6684461be..3b3a19a9e8 100644 --- a/src/OPT/pair_lj_cut_opt.cpp +++ b/src/OPT/pair_lj_cut_opt.cpp @@ -18,8 +18,8 @@ Vincent Natoli, Stone Ridge Technology ------------------------------------------------------------------------- */ -#include #include "pair_lj_cut_opt.h" +#include #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/OPT/pair_lj_cut_tip4p_long_opt.cpp b/src/OPT/pair_lj_cut_tip4p_long_opt.cpp index 92facca43e..f8181d69a6 100644 --- a/src/OPT/pair_lj_cut_tip4p_long_opt.cpp +++ b/src/OPT/pair_lj_cut_tip4p_long_opt.cpp @@ -15,8 +15,8 @@ OPT version: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_lj_cut_tip4p_long_opt.h" +#include #include "atom.h" #include "domain.h" #include "force.h" diff --git a/src/OPT/pair_lj_long_coul_long_opt.cpp b/src/OPT/pair_lj_long_coul_long_opt.cpp index 03853057f4..c323d078c4 100644 --- a/src/OPT/pair_lj_long_coul_long_opt.cpp +++ b/src/OPT/pair_lj_long_coul_long_opt.cpp @@ -15,9 +15,9 @@ OPT version: Wayne Mitchell (Loyola University New Orleans) ------------------------------------------------------------------------- */ +#include "pair_lj_long_coul_long_opt.h" #include #include -#include "pair_lj_long_coul_long_opt.h" #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/OPT/pair_morse_opt.cpp b/src/OPT/pair_morse_opt.cpp index c9c6bba355..1d2e226777 100644 --- a/src/OPT/pair_morse_opt.cpp +++ b/src/OPT/pair_morse_opt.cpp @@ -18,9 +18,9 @@ Vincent Natoli, Stone Ridge Technology ------------------------------------------------------------------------- */ +#include "pair_morse_opt.h" #include #include -#include "pair_morse_opt.h" #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/OPT/pair_ufm_opt.cpp b/src/OPT/pair_ufm_opt.cpp index f463dac3f1..eabb093b18 100644 --- a/src/OPT/pair_ufm_opt.cpp +++ b/src/OPT/pair_ufm_opt.cpp @@ -17,9 +17,9 @@ Maurice de Koning (Unicamp/Brazil) - dekoning@ifi.unicamp.br ------------------------------------------------------------------------- */ +#include "pair_ufm_opt.h" #include #include -#include "pair_ufm_opt.h" #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/PERI/atom_vec_peri.cpp b/src/PERI/atom_vec_peri.cpp index d78fe27c94..f677b24eb2 100644 --- a/src/PERI/atom_vec_peri.cpp +++ b/src/PERI/atom_vec_peri.cpp @@ -15,10 +15,10 @@ Contributing author: Mike Parks (SNL) ------------------------------------------------------------------------- */ +#include "atom_vec_peri.h" #include #include #include -#include "atom_vec_peri.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/PERI/compute_damage_atom.cpp b/src/PERI/compute_damage_atom.cpp index 4bf8fa17a5..f5a532cd0b 100644 --- a/src/PERI/compute_damage_atom.cpp +++ b/src/PERI/compute_damage_atom.cpp @@ -15,8 +15,8 @@ Contributing author: Mike Parks (SNL) ------------------------------------------------------------------------- */ -#include #include "compute_damage_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/PERI/compute_dilatation_atom.cpp b/src/PERI/compute_dilatation_atom.cpp index 990731a227..7a6607d65c 100644 --- a/src/PERI/compute_dilatation_atom.cpp +++ b/src/PERI/compute_dilatation_atom.cpp @@ -15,8 +15,8 @@ Contributing author: Rezwanur Rahman, John Foster (UTSA) ------------------------------------------------------------------------- */ -#include #include "compute_dilatation_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/PERI/compute_plasticity_atom.cpp b/src/PERI/compute_plasticity_atom.cpp index d08fb98e07..0b20bc5075 100644 --- a/src/PERI/compute_plasticity_atom.cpp +++ b/src/PERI/compute_plasticity_atom.cpp @@ -15,8 +15,8 @@ Contributing author: Rezwanur Rahman, John Foster (UTSA) ------------------------------------------------------------------------- */ -#include #include "compute_plasticity_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/PERI/fix_peri_neigh.cpp b/src/PERI/fix_peri_neigh.cpp index 66137e6a01..297936577f 100644 --- a/src/PERI/fix_peri_neigh.cpp +++ b/src/PERI/fix_peri_neigh.cpp @@ -15,8 +15,8 @@ Contributing authors: Mike Parks (SNL), Ezwanur Rahman, J.T. Foster (UTSA) ------------------------------------------------------------------------- */ -#include #include "fix_peri_neigh.h" +#include #include "pair_peri_pmb.h" #include "pair_peri_lps.h" #include "pair_peri_ves.h" diff --git a/src/PERI/pair_peri_eps.cpp b/src/PERI/pair_peri_eps.cpp index c00495ba4d..07314081da 100644 --- a/src/PERI/pair_peri_eps.cpp +++ b/src/PERI/pair_peri_eps.cpp @@ -15,10 +15,10 @@ Contributing author: Rezwanur Rahman, John Foster (UTSA) ------------------------------------------------------------------------- */ +#include "pair_peri_eps.h" #include #include #include -#include "pair_peri_eps.h" #include "atom.h" #include "domain.h" #include "lattice.h" diff --git a/src/PERI/pair_peri_lps.cpp b/src/PERI/pair_peri_lps.cpp index f0418c8c8d..660209f3f5 100644 --- a/src/PERI/pair_peri_lps.cpp +++ b/src/PERI/pair_peri_lps.cpp @@ -15,10 +15,10 @@ Contributing author: Mike Parks (SNL) ------------------------------------------------------------------------- */ +#include "pair_peri_lps.h" #include #include #include -#include "pair_peri_lps.h" #include "atom.h" #include "domain.h" #include "lattice.h" diff --git a/src/PERI/pair_peri_pmb.cpp b/src/PERI/pair_peri_pmb.cpp index ad2f3fb7c7..fa53efc344 100644 --- a/src/PERI/pair_peri_pmb.cpp +++ b/src/PERI/pair_peri_pmb.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Parks (SNL) ------------------------------------------------------------------------- */ +#include "pair_peri_pmb.h" #include #include #include #include -#include "pair_peri_pmb.h" #include "atom.h" #include "domain.h" #include "lattice.h" diff --git a/src/PERI/pair_peri_ves.cpp b/src/PERI/pair_peri_ves.cpp index 24a9f92a97..1687bed35d 100644 --- a/src/PERI/pair_peri_ves.cpp +++ b/src/PERI/pair_peri_ves.cpp @@ -15,10 +15,10 @@ Contributing authors: Rezwanur Rahman, J.T. Foster (UTSA) ------------------------------------------------------------------------- */ +#include "pair_peri_ves.h" #include #include #include -#include "pair_peri_ves.h" #include "atom.h" #include "domain.h" #include "lattice.h" diff --git a/src/POEMS/fix_poems.cpp b/src/POEMS/fix_poems.cpp index 41cfcede34..6d943a79db 100644 --- a/src/POEMS/fix_poems.cpp +++ b/src/POEMS/fix_poems.cpp @@ -17,13 +17,13 @@ Kurt Anderson (anderk5@rpi.edu) ------------------------------------------------------------------------- */ +#include "fix_poems.h" #include #include #include #include #include #include "workspace.h" -#include "fix_poems.h" #include "atom.h" #include "domain.h" #include "update.h" diff --git a/src/PYTHON/fix_python_invoke.cpp b/src/PYTHON/fix_python_invoke.cpp index 7fa9861c3f..57ea2e9148 100644 --- a/src/PYTHON/fix_python_invoke.cpp +++ b/src/PYTHON/fix_python_invoke.cpp @@ -15,9 +15,9 @@ Contributing author: Richard Berger (Temple U) ------------------------------------------------------------------------- */ +#include "fix_python_invoke.h" #include // IWYU pragma: keep #include -#include "fix_python_invoke.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/PYTHON/fix_python_move.cpp b/src/PYTHON/fix_python_move.cpp index b253df6828..be63b851a2 100644 --- a/src/PYTHON/fix_python_move.cpp +++ b/src/PYTHON/fix_python_move.cpp @@ -15,9 +15,9 @@ Contributing author: Richard Berger (Temple U) ------------------------------------------------------------------------- */ +#include "fix_python_move.h" #include // IWYU pragma: keep #include -#include "fix_python_move.h" #include "lmppython.h" #include "error.h" #include "python_compat.h" diff --git a/src/PYTHON/pair_python.cpp b/src/PYTHON/pair_python.cpp index 5b8f23400b..0d79a31946 100644 --- a/src/PYTHON/pair_python.cpp +++ b/src/PYTHON/pair_python.cpp @@ -15,10 +15,10 @@ Contributing authors: Axel Kohlmeyer and Richard Berger (Temple U) ------------------------------------------------------------------------- */ +#include "pair_python.h" #include // IWYU pragma: keep #include #include -#include "pair_python.h" #include "atom.h" #include "force.h" #include "memory.h" diff --git a/src/PYTHON/python_impl.cpp b/src/PYTHON/python_impl.cpp index 7456021675..1188942e75 100644 --- a/src/PYTHON/python_impl.cpp +++ b/src/PYTHON/python_impl.cpp @@ -15,10 +15,10 @@ Contributing author: Richard Berger and Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "python_impl.h" #include #include #include // IWYU pragma: keep -#include "python_impl.h" #include "force.h" #include "input.h" #include "variable.h" diff --git a/src/QEQ/fix_qeq.cpp b/src/QEQ/fix_qeq.cpp index 0ab010b7bb..2e0b7edbe5 100644 --- a/src/QEQ/fix_qeq.cpp +++ b/src/QEQ/fix_qeq.cpp @@ -16,11 +16,11 @@ Based on fix qeq/reax by H. Metin Aktulga ------------------------------------------------------------------------- */ +#include "fix_qeq.h" #include #include #include #include -#include "fix_qeq.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/QEQ/fix_qeq_dynamic.cpp b/src/QEQ/fix_qeq_dynamic.cpp index ba88f4f1c3..fb5fd2ddac 100644 --- a/src/QEQ/fix_qeq_dynamic.cpp +++ b/src/QEQ/fix_qeq_dynamic.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include "fix_qeq_dynamic.h" #include #include #include #include -#include "fix_qeq_dynamic.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/QEQ/fix_qeq_fire.cpp b/src/QEQ/fix_qeq_fire.cpp index 1e3686f99c..561a82b714 100644 --- a/src/QEQ/fix_qeq_fire.cpp +++ b/src/QEQ/fix_qeq_fire.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include "fix_qeq_fire.h" #include #include #include #include -#include "fix_qeq_fire.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/QEQ/fix_qeq_point.cpp b/src/QEQ/fix_qeq_point.cpp index 9517343974..bb3ce835fc 100644 --- a/src/QEQ/fix_qeq_point.cpp +++ b/src/QEQ/fix_qeq_point.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include "fix_qeq_point.h" #include #include #include #include -#include "fix_qeq_point.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/QEQ/fix_qeq_shielded.cpp b/src/QEQ/fix_qeq_shielded.cpp index a74eee7d29..60ff62ca07 100644 --- a/src/QEQ/fix_qeq_shielded.cpp +++ b/src/QEQ/fix_qeq_shielded.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include "fix_qeq_shielded.h" #include #include #include #include -#include "fix_qeq_shielded.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/QEQ/fix_qeq_slater.cpp b/src/QEQ/fix_qeq_slater.cpp index 3443a519a2..95105b5ef2 100644 --- a/src/QEQ/fix_qeq_slater.cpp +++ b/src/QEQ/fix_qeq_slater.cpp @@ -15,11 +15,11 @@ Contributing author: Ray Shan (Sandia) ------------------------------------------------------------------------- */ +#include "fix_qeq_slater.h" #include #include #include #include -#include "fix_qeq_slater.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/REPLICA/compute_event_displace.cpp b/src/REPLICA/compute_event_displace.cpp index df14221586..4c8d022d70 100644 --- a/src/REPLICA/compute_event_displace.cpp +++ b/src/REPLICA/compute_event_displace.cpp @@ -15,11 +15,11 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "compute_event_displace.h" #include #include #include #include -#include "compute_event_displace.h" #include "atom.h" #include "domain.h" #include "modify.h" diff --git a/src/REPLICA/fix_event.cpp b/src/REPLICA/fix_event.cpp index 8fc5de6b16..8cf1acba94 100644 --- a/src/REPLICA/fix_event.cpp +++ b/src/REPLICA/fix_event.cpp @@ -15,9 +15,9 @@ Contributing author: Mike Brown (SNL), Aidan Thompson (SNL) ------------------------------------------------------------------------- */ +#include "fix_event.h" #include #include -#include "fix_event.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/REPLICA/fix_event_hyper.cpp b/src/REPLICA/fix_event_hyper.cpp index eae1ad021d..3dd1a03eb9 100644 --- a/src/REPLICA/fix_event_hyper.cpp +++ b/src/REPLICA/fix_event_hyper.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_event_hyper.h" #include #include -#include "fix_event_hyper.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/REPLICA/fix_event_prd.cpp b/src/REPLICA/fix_event_prd.cpp index a311a6444a..63c9c2718b 100644 --- a/src/REPLICA/fix_event_prd.cpp +++ b/src/REPLICA/fix_event_prd.cpp @@ -15,9 +15,9 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "fix_event_prd.h" #include #include -#include "fix_event_prd.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/REPLICA/fix_event_tad.cpp b/src/REPLICA/fix_event_tad.cpp index 0916fdf493..b92bc1fd73 100644 --- a/src/REPLICA/fix_event_tad.cpp +++ b/src/REPLICA/fix_event_tad.cpp @@ -15,9 +15,9 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ +#include "fix_event_tad.h" #include #include -#include "fix_event_tad.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/REPLICA/fix_hyper.cpp b/src/REPLICA/fix_hyper.cpp index c86c00ad45..21a4fde04d 100644 --- a/src/REPLICA/fix_hyper.cpp +++ b/src/REPLICA/fix_hyper.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "fix_hyper.h" +#include using namespace LAMMPS_NS; diff --git a/src/REPLICA/fix_hyper_global.cpp b/src/REPLICA/fix_hyper_global.cpp index 0c76b29911..a58798a63e 100644 --- a/src/REPLICA/fix_hyper_global.cpp +++ b/src/REPLICA/fix_hyper_global.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_hyper_global.h" #include #include #include #include -#include "fix_hyper_global.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/REPLICA/fix_hyper_local.cpp b/src/REPLICA/fix_hyper_local.cpp index a6db4419f0..555c5234f6 100644 --- a/src/REPLICA/fix_hyper_local.cpp +++ b/src/REPLICA/fix_hyper_local.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_hyper_local.h" #include #include #include #include -#include "fix_hyper_local.h" #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/REPLICA/fix_neb.cpp b/src/REPLICA/fix_neb.cpp index e1b1e46a53..2803c37b23 100644 --- a/src/REPLICA/fix_neb.cpp +++ b/src/REPLICA/fix_neb.cpp @@ -16,11 +16,11 @@ new options for inter-replica forces, first/last replica treatment ------------------------------------------------------------------------- */ +#include "fix_neb.h" #include #include #include #include -#include "fix_neb.h" #include "universe.h" #include "update.h" #include "atom.h" diff --git a/src/REPLICA/hyper.cpp b/src/REPLICA/hyper.cpp index 00b91684e9..c400ae097d 100644 --- a/src/REPLICA/hyper.cpp +++ b/src/REPLICA/hyper.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "hyper.h" #include #include #include -#include "hyper.h" #include "update.h" #include "atom.h" #include "domain.h" diff --git a/src/REPLICA/neb.cpp b/src/REPLICA/neb.cpp index 6b68c52dbb..b670f3d8f1 100644 --- a/src/REPLICA/neb.cpp +++ b/src/REPLICA/neb.cpp @@ -15,12 +15,12 @@ // due to OpenMPI bug which sets INT64_MAX via its mpi.h // before lmptype.h can set flags to insure it is done correctly +#include "neb.h" #include "lmptype.h" #include #include #include #include -#include "neb.h" #include "universe.h" #include "atom.h" #include "update.h" diff --git a/src/REPLICA/prd.cpp b/src/REPLICA/prd.cpp index 6d450f48e3..19a12ddbbb 100644 --- a/src/REPLICA/prd.cpp +++ b/src/REPLICA/prd.cpp @@ -19,12 +19,12 @@ // due to OpenMPI bug which sets INT64_MAX via its mpi.h // before lmptype.h can set flags to insure it is done correctly +#include "prd.h" #include "lmptype.h" #include #include #include #include -#include "prd.h" #include "universe.h" #include "update.h" #include "atom.h" diff --git a/src/REPLICA/tad.cpp b/src/REPLICA/tad.cpp index da42ba6fae..90667b8865 100644 --- a/src/REPLICA/tad.cpp +++ b/src/REPLICA/tad.cpp @@ -19,12 +19,12 @@ // due to OpenMPI bug which sets INT64_MAX via its mpi.h // before lmptype.h can set flags to insure it is done correctly +#include "tad.h" #include "lmptype.h" #include #include #include #include -#include "tad.h" #include "universe.h" #include "update.h" #include "atom.h" diff --git a/src/REPLICA/temper.cpp b/src/REPLICA/temper.cpp index fe3e3fb993..6eb50c8d9f 100644 --- a/src/REPLICA/temper.cpp +++ b/src/REPLICA/temper.cpp @@ -15,10 +15,10 @@ Contributing author: Mark Sears (SNL) ------------------------------------------------------------------------- */ +#include "temper.h" #include #include #include -#include "temper.h" #include "universe.h" #include "domain.h" #include "atom.h" diff --git a/src/REPLICA/verlet_split.cpp b/src/REPLICA/verlet_split.cpp index 7042fc6993..f268afe7f8 100644 --- a/src/REPLICA/verlet_split.cpp +++ b/src/REPLICA/verlet_split.cpp @@ -15,8 +15,8 @@ Contributing authors: Yuxing Peng and Chris Knight (U Chicago) ------------------------------------------------------------------------- */ -#include #include "verlet_split.h" +#include #include "universe.h" #include "neighbor.h" #include "domain.h" diff --git a/src/RIGID/compute_erotate_rigid.cpp b/src/RIGID/compute_erotate_rigid.cpp index a3ddffd9ab..1a7236e263 100644 --- a/src/RIGID/compute_erotate_rigid.cpp +++ b/src/RIGID/compute_erotate_rigid.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_erotate_rigid.h" #include #include -#include "compute_erotate_rigid.h" #include "update.h" #include "force.h" #include "modify.h" diff --git a/src/RIGID/compute_ke_rigid.cpp b/src/RIGID/compute_ke_rigid.cpp index 4de13532b2..66b7a92566 100644 --- a/src/RIGID/compute_ke_rigid.cpp +++ b/src/RIGID/compute_ke_rigid.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_ke_rigid.h" #include #include -#include "compute_ke_rigid.h" #include "update.h" #include "force.h" #include "modify.h" diff --git a/src/RIGID/compute_rigid_local.cpp b/src/RIGID/compute_rigid_local.cpp index ec2799b6bc..75334bb759 100644 --- a/src/RIGID/compute_rigid_local.cpp +++ b/src/RIGID/compute_rigid_local.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_rigid_local.h" #include #include -#include "compute_rigid_local.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/RIGID/fix_ehex.cpp b/src/RIGID/fix_ehex.cpp index 0bbdea51c6..a5efc22d11 100644 --- a/src/RIGID/fix_ehex.cpp +++ b/src/RIGID/fix_ehex.cpp @@ -22,10 +22,10 @@ which implements the heat exchange (HEX) algorithm. ------------------------------------------------------------------------- */ +#include "fix_ehex.h" #include #include #include -#include "fix_ehex.h" #include "atom.h" #include "domain.h" #include "region.h" diff --git a/src/RIGID/fix_rattle.cpp b/src/RIGID/fix_rattle.cpp index db43b9e82d..93bf610e94 100644 --- a/src/RIGID/fix_rattle.cpp +++ b/src/RIGID/fix_rattle.cpp @@ -15,10 +15,10 @@ Contributing author: Peter Wirnsberger (University of Cambridge) ------------------------------------------------------------------------- */ +#include "fix_rattle.h" #include #include #include -#include "fix_rattle.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/RIGID/fix_rigid.cpp b/src/RIGID/fix_rigid.cpp index 19eb22a7fa..912f529403 100644 --- a/src/RIGID/fix_rigid.cpp +++ b/src/RIGID/fix_rigid.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_rigid.h" #include #include #include #include -#include "fix_rigid.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/RIGID/fix_rigid_nh.cpp b/src/RIGID/fix_rigid_nh.cpp index 2e1090ec88..4738e253f6 100644 --- a/src/RIGID/fix_rigid_nh.cpp +++ b/src/RIGID/fix_rigid_nh.cpp @@ -17,9 +17,9 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ +#include "fix_rigid_nh.h" #include #include -#include "fix_rigid_nh.h" #include "math_extra.h" #include "atom.h" #include "compute.h" diff --git a/src/RIGID/fix_rigid_nh_small.cpp b/src/RIGID/fix_rigid_nh_small.cpp index 8de588bd9b..1545e913c0 100644 --- a/src/RIGID/fix_rigid_nh_small.cpp +++ b/src/RIGID/fix_rigid_nh_small.cpp @@ -17,10 +17,10 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ +#include "fix_rigid_nh_small.h" #include #include #include -#include "fix_rigid_nh_small.h" #include "math_extra.h" #include "atom.h" #include "compute.h" diff --git a/src/RIGID/fix_rigid_nph.cpp b/src/RIGID/fix_rigid_nph.cpp index 6080fb05af..706e08ec12 100644 --- a/src/RIGID/fix_rigid_nph.cpp +++ b/src/RIGID/fix_rigid_nph.cpp @@ -17,8 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ -#include #include "fix_rigid_nph.h" +#include #include "modify.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_nph_small.cpp b/src/RIGID/fix_rigid_nph_small.cpp index 9b045eaf13..32ac58220d 100644 --- a/src/RIGID/fix_rigid_nph_small.cpp +++ b/src/RIGID/fix_rigid_nph_small.cpp @@ -17,8 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ -#include #include "fix_rigid_nph_small.h" +#include #include "modify.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_npt.cpp b/src/RIGID/fix_rigid_npt.cpp index 526fc8f614..1f19fb4ec7 100644 --- a/src/RIGID/fix_rigid_npt.cpp +++ b/src/RIGID/fix_rigid_npt.cpp @@ -17,8 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ -#include #include "fix_rigid_npt.h" +#include #include "modify.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_npt_small.cpp b/src/RIGID/fix_rigid_npt_small.cpp index fff338d687..e8924be79f 100644 --- a/src/RIGID/fix_rigid_npt_small.cpp +++ b/src/RIGID/fix_rigid_npt_small.cpp @@ -17,8 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ -#include #include "fix_rigid_npt_small.h" +#include #include "modify.h" #include "error.h" diff --git a/src/RIGID/fix_rigid_small.cpp b/src/RIGID/fix_rigid_small.cpp index 8c2feb6436..14e230ab9c 100644 --- a/src/RIGID/fix_rigid_small.cpp +++ b/src/RIGID/fix_rigid_small.cpp @@ -11,12 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_rigid_small.h" #include #include #include #include #include -#include "fix_rigid_small.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/RIGID/fix_shake.cpp b/src/RIGID/fix_shake.cpp index 5c202706af..48a08118c5 100644 --- a/src/RIGID/fix_shake.cpp +++ b/src/RIGID/fix_shake.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_shake.h" #include #include #include #include -#include "fix_shake.h" #include "atom.h" #include "atom_vec.h" #include "molecule.h" diff --git a/src/SHOCK/fix_append_atoms.cpp b/src/SHOCK/fix_append_atoms.cpp index 5e81b75c0d..5e85b39076 100644 --- a/src/SHOCK/fix_append_atoms.cpp +++ b/src/SHOCK/fix_append_atoms.cpp @@ -11,10 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_append_atoms.h" #include #include #include -#include "fix_append_atoms.h" #include "atom.h" #include "atom_vec.h" #include "comm.h" diff --git a/src/SHOCK/fix_msst.cpp b/src/SHOCK/fix_msst.cpp index 15ee4d370f..2e9f751824 100644 --- a/src/SHOCK/fix_msst.cpp +++ b/src/SHOCK/fix_msst.cpp @@ -17,10 +17,10 @@ see Reed, Fried, Joannopoulos, Phys Rev Lett, 90, 235503 (2003) ------------------------------------------------------------------------- */ +#include "fix_msst.h" #include #include #include -#include "fix_msst.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/SHOCK/fix_nphug.cpp b/src/SHOCK/fix_nphug.cpp index 5d5a1642c0..8ad787d759 100644 --- a/src/SHOCK/fix_nphug.cpp +++ b/src/SHOCK/fix_nphug.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_nphug.h" #include #include -#include "fix_nphug.h" #include "modify.h" #include "error.h" #include "update.h" diff --git a/src/SHOCK/fix_wall_piston.cpp b/src/SHOCK/fix_wall_piston.cpp index 31f70b4174..5a359d9f6f 100644 --- a/src/SHOCK/fix_wall_piston.cpp +++ b/src/SHOCK/fix_wall_piston.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_wall_piston.h" #include #include -#include "fix_wall_piston.h" #include "atom.h" #include "domain.h" #include "lattice.h" diff --git a/src/SNAP/compute_sna_atom.cpp b/src/SNAP/compute_sna_atom.cpp index cc7a84281e..7ca9d52467 100644 --- a/src/SNAP/compute_sna_atom.cpp +++ b/src/SNAP/compute_sna_atom.cpp @@ -10,10 +10,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include "sna.h" + +#include "compute_sna_atom.h" #include #include -#include "compute_sna_atom.h" +#include "sna.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/SNAP/compute_snad_atom.cpp b/src/SNAP/compute_snad_atom.cpp index 37587a0aae..7e71e4a556 100644 --- a/src/SNAP/compute_snad_atom.cpp +++ b/src/SNAP/compute_snad_atom.cpp @@ -10,10 +10,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include "sna.h" + +#include "compute_snad_atom.h" #include #include -#include "compute_snad_atom.h" +#include "sna.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/SNAP/compute_snav_atom.cpp b/src/SNAP/compute_snav_atom.cpp index 5faf7a1872..28c018b1cc 100644 --- a/src/SNAP/compute_snav_atom.cpp +++ b/src/SNAP/compute_snav_atom.cpp @@ -10,9 +10,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ + +#include "compute_snav_atom.h" #include #include -#include "compute_snav_atom.h" #include "sna.h" #include "atom.h" #include "update.h" diff --git a/src/SNAP/pair_snap.cpp b/src/SNAP/pair_snap.cpp index f0f3ef72c6..56f59c7fcc 100644 --- a/src/SNAP/pair_snap.cpp +++ b/src/SNAP/pair_snap.cpp @@ -11,11 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_snap.h" #include #include #include #include -#include "pair_snap.h" #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/SNAP/sna.cpp b/src/SNAP/sna.cpp index d7d9b5163d..9194e44c21 100644 --- a/src/SNAP/sna.cpp +++ b/src/SNAP/sna.cpp @@ -15,8 +15,8 @@ Contributing authors: Aidan Thompson, Christian Trott, SNL ------------------------------------------------------------------------- */ -#include #include "sna.h" +#include #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/SPIN/atom_vec_spin.cpp b/src/SPIN/atom_vec_spin.cpp index 37d6fb1e59..5810ecf85b 100644 --- a/src/SPIN/atom_vec_spin.cpp +++ b/src/SPIN/atom_vec_spin.cpp @@ -23,11 +23,11 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "atom_vec_spin.h" #include #include #include #include "atom.h" -#include "atom_vec_spin.h" #include "comm.h" #include "domain.h" #include "error.h" diff --git a/src/SPIN/compute_spin.cpp b/src/SPIN/compute_spin.cpp index ec11bc68f2..8dad128994 100644 --- a/src/SPIN/compute_spin.cpp +++ b/src/SPIN/compute_spin.cpp @@ -21,9 +21,9 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "compute_spin.h" #include #include -#include "compute_spin.h" #include "atom.h" #include "error.h" #include "force.h" diff --git a/src/SPIN/fix_langevin_spin.cpp b/src/SPIN/fix_langevin_spin.cpp index 6936c701c6..ec9c98c4f8 100644 --- a/src/SPIN/fix_langevin_spin.cpp +++ b/src/SPIN/fix_langevin_spin.cpp @@ -21,9 +21,9 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "fix_langevin_spin.h" #include #include -#include "fix_langevin_spin.h" #include "comm.h" #include "error.h" #include "force.h" diff --git a/src/SPIN/fix_neb_spin.cpp b/src/SPIN/fix_neb_spin.cpp index 7ed8967a24..5acbbf59e8 100644 --- a/src/SPIN/fix_neb_spin.cpp +++ b/src/SPIN/fix_neb_spin.cpp @@ -21,10 +21,10 @@ Computer Physics Communications, 196, 335-347. ------------------------------------------------------------------------- */ +#include "fix_neb_spin.h" #include #include #include -#include "fix_neb_spin.h" #include "universe.h" #include "update.h" #include "atom.h" diff --git a/src/SPIN/fix_nve_spin.cpp b/src/SPIN/fix_nve_spin.cpp index d35585c7a6..1165048723 100644 --- a/src/SPIN/fix_nve_spin.cpp +++ b/src/SPIN/fix_nve_spin.cpp @@ -21,8 +21,8 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ -#include #include "fix_nve_spin.h" +#include #include "atom.h" #include "citeme.h" #include "comm.h" diff --git a/src/SPIN/fix_precession_spin.cpp b/src/SPIN/fix_precession_spin.cpp index 7764bb0438..3296b28228 100644 --- a/src/SPIN/fix_precession_spin.cpp +++ b/src/SPIN/fix_precession_spin.cpp @@ -21,10 +21,10 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "fix_precession_spin.h" #include #include #include -#include "fix_precession_spin.h" #include "atom.h" #include "error.h" #include "force.h" diff --git a/src/SPIN/fix_setforce_spin.cpp b/src/SPIN/fix_setforce_spin.cpp index 1ab35c9663..15e5aacfb6 100644 --- a/src/SPIN/fix_setforce_spin.cpp +++ b/src/SPIN/fix_setforce_spin.cpp @@ -21,8 +21,8 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ -#include #include "fix_setforce_spin.h" +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/SPIN/min_spin.cpp b/src/SPIN/min_spin.cpp index 3a330f448a..2514645325 100644 --- a/src/SPIN/min_spin.cpp +++ b/src/SPIN/min_spin.cpp @@ -17,10 +17,10 @@ Please cite the related publication: ------------------------------------------------------------------------- */ +#include "min_spin.h" #include #include #include -#include "min_spin.h" #include "universe.h" #include "atom.h" #include "force.h" diff --git a/src/SPIN/neb_spin.cpp b/src/SPIN/neb_spin.cpp index 400ce3d363..2bcfe6573a 100644 --- a/src/SPIN/neb_spin.cpp +++ b/src/SPIN/neb_spin.cpp @@ -21,11 +21,11 @@ Computer Physics Communications, 196, 335-347. ------------------------------------------------------------------------- */ +#include "neb_spin.h" #include #include #include #include -#include "neb_spin.h" #include "citeme.h" #include "force.h" #include "universe.h" diff --git a/src/SPIN/pair_spin.cpp b/src/SPIN/pair_spin.cpp index 93d9a1e127..fef247c09b 100644 --- a/src/SPIN/pair_spin.cpp +++ b/src/SPIN/pair_spin.cpp @@ -21,8 +21,8 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ -#include #include "pair_spin.h" +#include #include "atom.h" #include "error.h" #include "fix.h" diff --git a/src/SPIN/pair_spin_dipole_cut.cpp b/src/SPIN/pair_spin_dipole_cut.cpp index 8d9b5b8f2b..fb0ec8bb20 100644 --- a/src/SPIN/pair_spin_dipole_cut.cpp +++ b/src/SPIN/pair_spin_dipole_cut.cpp @@ -21,10 +21,10 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "pair_spin_dipole_cut.h" #include #include #include -#include "pair_spin_dipole_cut.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/SPIN/pair_spin_dipole_long.cpp b/src/SPIN/pair_spin_dipole_long.cpp index 84c55a8c3c..670fccfce2 100644 --- a/src/SPIN/pair_spin_dipole_long.cpp +++ b/src/SPIN/pair_spin_dipole_long.cpp @@ -16,10 +16,10 @@ Stan Moore (SNL) ------------------------------------------------------------------------- */ +#include "pair_spin_dipole_long.h" #include #include #include -#include "pair_spin_dipole_long.h" #include "atom.h" #include "comm.h" #include "neighbor.h" diff --git a/src/SPIN/pair_spin_dmi.cpp b/src/SPIN/pair_spin_dmi.cpp index 651f4397bd..afd2deaa6a 100644 --- a/src/SPIN/pair_spin_dmi.cpp +++ b/src/SPIN/pair_spin_dmi.cpp @@ -21,10 +21,10 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "pair_spin_dmi.h" #include #include #include -#include "pair_spin_dmi.h" #include "atom.h" #include "comm.h" #include "error.h" diff --git a/src/SPIN/pair_spin_exchange.cpp b/src/SPIN/pair_spin_exchange.cpp index 059a8f5f34..cc28018ad0 100644 --- a/src/SPIN/pair_spin_exchange.cpp +++ b/src/SPIN/pair_spin_exchange.cpp @@ -21,10 +21,10 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "pair_spin_exchange.h" #include #include #include -#include "pair_spin_exchange.h" #include "atom.h" #include "comm.h" #include "error.h" diff --git a/src/SPIN/pair_spin_magelec.cpp b/src/SPIN/pair_spin_magelec.cpp index 55b96582c8..6756ebc3cc 100644 --- a/src/SPIN/pair_spin_magelec.cpp +++ b/src/SPIN/pair_spin_magelec.cpp @@ -21,10 +21,10 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "pair_spin_magelec.h" #include #include #include -#include "pair_spin_magelec.h" #include "atom.h" #include "comm.h" #include "error.h" diff --git a/src/SPIN/pair_spin_neel.cpp b/src/SPIN/pair_spin_neel.cpp index 4d68dbdc22..355ba20f39 100644 --- a/src/SPIN/pair_spin_neel.cpp +++ b/src/SPIN/pair_spin_neel.cpp @@ -21,10 +21,10 @@ and molecular dynamics. Journal of Computational Physics. ------------------------------------------------------------------------- */ +#include "pair_spin_neel.h" #include #include #include -#include "pair_spin_neel.h" #include "atom.h" #include "comm.h" #include "error.h" diff --git a/src/SRD/fix_srd.cpp b/src/SRD/fix_srd.cpp index a20ec212fd..d5eec91f50 100644 --- a/src/SRD/fix_srd.cpp +++ b/src/SRD/fix_srd.cpp @@ -15,10 +15,10 @@ Contributing authors: Jeremy Lechman (SNL), Pieter in 't Veld (BASF) ------------------------------------------------------------------------- */ +#include "fix_srd.h" #include #include #include -#include "fix_srd.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/SRD/fix_wall_srd.cpp b/src/SRD/fix_wall_srd.cpp index cb0f023640..ab113df28a 100644 --- a/src/SRD/fix_wall_srd.cpp +++ b/src/SRD/fix_wall_srd.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "fix_wall_srd.h" #include #include -#include "fix_wall_srd.h" #include "fix.h" #include "domain.h" #include "lattice.h" diff --git a/src/USER-ADIOS/dump_atom_adios.cpp b/src/USER-ADIOS/dump_atom_adios.cpp index 55d6c5fbf9..e711b8a583 100644 --- a/src/USER-ADIOS/dump_atom_adios.cpp +++ b/src/USER-ADIOS/dump_atom_adios.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "dump_atom_adios.h" +#include #include "atom.h" #include "domain.h" #include "error.h" @@ -23,7 +24,6 @@ #include "memory.h" #include "universe.h" #include "update.h" -#include #include "adios2.h" diff --git a/src/USER-ADIOS/dump_custom_adios.cpp b/src/USER-ADIOS/dump_custom_adios.cpp index 67f3deeb64..ee6d7d7e49 100644 --- a/src/USER-ADIOS/dump_custom_adios.cpp +++ b/src/USER-ADIOS/dump_custom_adios.cpp @@ -16,6 +16,8 @@ ------------------------------------------------------------------------- */ #include "dump_custom_adios.h" +#include +#include #include "atom.h" #include "compute.h" #include "domain.h" @@ -30,8 +32,6 @@ #include "universe.h" #include "update.h" #include "variable.h" -#include -#include #include "adios2.h" diff --git a/src/USER-ATC/fix_atc.cpp b/src/USER-ATC/fix_atc.cpp index f53343ced1..e2a1768f55 100644 --- a/src/USER-ATC/fix_atc.cpp +++ b/src/USER-ATC/fix_atc.cpp @@ -11,8 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -// LAMMPS #include "fix_atc.h" +#include +#include +#include #include "fix_nve.h" #include "atom.h" #include "force.h" @@ -24,7 +26,7 @@ #include "pointers.h" #include "comm.h" #include "group.h" -// ATC + #include "ATC_Method.h" #include "ATC_Transfer.h" #include "ATC_TransferKernel.h" @@ -34,10 +36,6 @@ #include "ATC_CouplingMass.h" #include "ATC_CouplingMomentumEnergy.h" #include "LammpsInterface.h" -// other -#include -#include -#include using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-AWPMD/atom_vec_wavepacket.cpp b/src/USER-AWPMD/atom_vec_wavepacket.cpp index 7556dd2c8e..bc70c0dbc2 100644 --- a/src/USER-AWPMD/atom_vec_wavepacket.cpp +++ b/src/USER-AWPMD/atom_vec_wavepacket.cpp @@ -15,10 +15,10 @@ Contributing author: Ilya Valuev (JIHT, Moscow, Russia) ------------------------------------------------------------------------- */ +#include "atom_vec_wavepacket.h" #include #include #include -#include "atom_vec_wavepacket.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/USER-AWPMD/fix_nve_awpmd.cpp b/src/USER-AWPMD/fix_nve_awpmd.cpp index 7722c93121..57ad17f3e6 100644 --- a/src/USER-AWPMD/fix_nve_awpmd.cpp +++ b/src/USER-AWPMD/fix_nve_awpmd.cpp @@ -15,10 +15,10 @@ Contributing author: Ilya Valuev (JIHT, Moscow, Russia) ------------------------------------------------------------------------- */ +#include "fix_nve_awpmd.h" #include #include #include -#include "fix_nve_awpmd.h" #include "atom.h" #include "force.h" #include "update.h" diff --git a/src/USER-AWPMD/pair_awpmd_cut.cpp b/src/USER-AWPMD/pair_awpmd_cut.cpp index 1b7bf35c28..ae2fbc59fa 100644 --- a/src/USER-AWPMD/pair_awpmd_cut.cpp +++ b/src/USER-AWPMD/pair_awpmd_cut.cpp @@ -15,11 +15,11 @@ Contributing author: Ilya Valuev (JIHT, Moscow, Russia) ------------------------------------------------------------------------- */ +#include "pair_awpmd_cut.h" #include #include #include #include -#include "pair_awpmd_cut.h" #include "atom.h" #include "update.h" #include "min.h" diff --git a/src/USER-BOCS/compute_pressure_bocs.cpp b/src/USER-BOCS/compute_pressure_bocs.cpp index fc24efab4c..33163f7aff 100644 --- a/src/USER-BOCS/compute_pressure_bocs.cpp +++ b/src/USER-BOCS/compute_pressure_bocs.cpp @@ -14,10 +14,10 @@ from The Pennsylvania State University ------------------------------------------------------------------------- */ +#include "compute_pressure_bocs.h" #include #include #include -#include "compute_pressure_bocs.h" #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/USER-BOCS/fix_bocs.cpp b/src/USER-BOCS/fix_bocs.cpp index 7bdb8933e3..e0952086dd 100644 --- a/src/USER-BOCS/fix_bocs.cpp +++ b/src/USER-BOCS/fix_bocs.cpp @@ -14,10 +14,10 @@ from The Pennsylvania State University ------------------------------------------------------------------------- */ +#include "fix_bocs.h" #include #include #include -#include "fix_bocs.h" #include "math_extra.h" #include "atom.h" #include "force.h" diff --git a/src/USER-CGDNA/bond_oxdna2_fene.cpp b/src/USER-CGDNA/bond_oxdna2_fene.cpp index 39cbb04f88..2cd7883600 100644 --- a/src/USER-CGDNA/bond_oxdna2_fene.cpp +++ b/src/USER-CGDNA/bond_oxdna2_fene.cpp @@ -14,9 +14,9 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "bond_oxdna2_fene.h" #include #include -#include "bond_oxdna2_fene.h" using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/bond_oxdna_fene.cpp b/src/USER-CGDNA/bond_oxdna_fene.cpp index 8271668e3f..8b94fd6a5a 100644 --- a/src/USER-CGDNA/bond_oxdna_fene.cpp +++ b/src/USER-CGDNA/bond_oxdna_fene.cpp @@ -14,9 +14,9 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "bond_oxdna_fene.h" #include #include -#include "bond_oxdna_fene.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-CGDNA/fix_nve_dot.cpp b/src/USER-CGDNA/fix_nve_dot.cpp index 72b3388793..3bf6757df7 100644 --- a/src/USER-CGDNA/fix_nve_dot.cpp +++ b/src/USER-CGDNA/fix_nve_dot.cpp @@ -14,10 +14,10 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "fix_nve_dot.h" #include #include #include -#include "fix_nve_dot.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/USER-CGDNA/fix_nve_dotc_langevin.cpp b/src/USER-CGDNA/fix_nve_dotc_langevin.cpp index c73801c97a..61e3552f11 100644 --- a/src/USER-CGDNA/fix_nve_dotc_langevin.cpp +++ b/src/USER-CGDNA/fix_nve_dotc_langevin.cpp @@ -15,10 +15,10 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "fix_nve_dotc_langevin.h" #include #include #include -#include "fix_nve_dotc_langevin.h" #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" diff --git a/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp b/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp index dfea97f0bf..1d0a2eb494 100644 --- a/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp +++ b/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna2_coaxstk.h" #include #include #include #include -#include "pair_oxdna2_coaxstk.h" #include "mf_oxdna.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-CGDNA/pair_oxdna2_dh.cpp b/src/USER-CGDNA/pair_oxdna2_dh.cpp index b4afad12db..22fc79dae4 100644 --- a/src/USER-CGDNA/pair_oxdna2_dh.cpp +++ b/src/USER-CGDNA/pair_oxdna2_dh.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna2_dh.h" #include #include #include #include -#include "pair_oxdna2_dh.h" #include "mf_oxdna.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-CGDNA/pair_oxdna2_excv.cpp b/src/USER-CGDNA/pair_oxdna2_excv.cpp index 4329fbe071..de4f8319b9 100644 --- a/src/USER-CGDNA/pair_oxdna2_excv.cpp +++ b/src/USER-CGDNA/pair_oxdna2_excv.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna2_excv.h" #include #include #include #include -#include "pair_oxdna2_excv.h" using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/pair_oxdna2_stk.cpp b/src/USER-CGDNA/pair_oxdna2_stk.cpp index f479572aa6..3b9480bff6 100644 --- a/src/USER-CGDNA/pair_oxdna2_stk.cpp +++ b/src/USER-CGDNA/pair_oxdna2_stk.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna2_stk.h" #include #include #include #include -#include "pair_oxdna2_stk.h" using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/pair_oxdna_coaxstk.cpp b/src/USER-CGDNA/pair_oxdna_coaxstk.cpp index 6f3fa4fa4e..7310f60ec3 100644 --- a/src/USER-CGDNA/pair_oxdna_coaxstk.cpp +++ b/src/USER-CGDNA/pair_oxdna_coaxstk.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna_coaxstk.h" #include #include #include #include -#include "pair_oxdna_coaxstk.h" #include "mf_oxdna.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-CGDNA/pair_oxdna_excv.cpp b/src/USER-CGDNA/pair_oxdna_excv.cpp index 82af5ed1c7..68091f4190 100644 --- a/src/USER-CGDNA/pair_oxdna_excv.cpp +++ b/src/USER-CGDNA/pair_oxdna_excv.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna_excv.h" #include #include #include #include -#include "pair_oxdna_excv.h" #include "mf_oxdna.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-CGDNA/pair_oxdna_hbond.cpp b/src/USER-CGDNA/pair_oxdna_hbond.cpp index 8cd28f10c8..2de05e66ae 100644 --- a/src/USER-CGDNA/pair_oxdna_hbond.cpp +++ b/src/USER-CGDNA/pair_oxdna_hbond.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna_hbond.h" #include #include #include #include -#include "pair_oxdna_hbond.h" #include "mf_oxdna.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-CGDNA/pair_oxdna_stk.cpp b/src/USER-CGDNA/pair_oxdna_stk.cpp index 93c65979ac..aaa25039ef 100644 --- a/src/USER-CGDNA/pair_oxdna_stk.cpp +++ b/src/USER-CGDNA/pair_oxdna_stk.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna_stk.h" #include #include #include #include -#include "pair_oxdna_stk.h" #include "mf_oxdna.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-CGDNA/pair_oxdna_xstk.cpp b/src/USER-CGDNA/pair_oxdna_xstk.cpp index 1365d0d2b2..806f8a42c6 100644 --- a/src/USER-CGDNA/pair_oxdna_xstk.cpp +++ b/src/USER-CGDNA/pair_oxdna_xstk.cpp @@ -14,11 +14,11 @@ Contributing author: Oliver Henrich (University of Strathclyde, Glasgow) ------------------------------------------------------------------------- */ +#include "pair_oxdna_xstk.h" #include #include #include #include -#include "pair_oxdna_xstk.h" #include "mf_oxdna.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-CGSDK/angle_sdk.cpp b/src/USER-CGSDK/angle_sdk.cpp index 823c725e07..575b0fae69 100644 --- a/src/USER-CGSDK/angle_sdk.cpp +++ b/src/USER-CGSDK/angle_sdk.cpp @@ -18,9 +18,9 @@ lj/sdk potential for coarse grained MD simulations. ------------------------------------------------------------------------- */ +#include "angle_sdk.h" #include #include -#include "angle_sdk.h" #include "atom.h" #include "neighbor.h" #include "pair.h" diff --git a/src/USER-CGSDK/pair_lj_sdk.cpp b/src/USER-CGSDK/pair_lj_sdk.cpp index 7dd6c04436..b22469566e 100644 --- a/src/USER-CGSDK/pair_lj_sdk.cpp +++ b/src/USER-CGSDK/pair_lj_sdk.cpp @@ -16,11 +16,11 @@ This style is a simplified re-implementation of the CG/CMM pair style ------------------------------------------------------------------------- */ +#include "pair_lj_sdk.h" #include #include #include #include -#include "pair_lj_sdk.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp b/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp index 33a1659df9..5fba8cde66 100644 --- a/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp +++ b/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp @@ -16,11 +16,11 @@ This style is a simplified re-implementation of the CG/CMM pair style ------------------------------------------------------------------------- */ +#include "pair_lj_sdk_coul_long.h" #include #include #include #include -#include "pair_lj_sdk_coul_long.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp b/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp index d26f8efcdc..b61ed5528f 100644 --- a/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp +++ b/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp @@ -16,11 +16,11 @@ This style is a simplified re-implementation of the CG/CMM pair style ------------------------------------------------------------------------- */ +#include "pair_lj_sdk_coul_msm.h" #include #include #include #include -#include "pair_lj_sdk_coul_msm.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-COLVARS/colvarproxy_lammps.cpp b/src/USER-COLVARS/colvarproxy_lammps.cpp index 651999f79c..685c698ab6 100644 --- a/src/USER-COLVARS/colvarproxy_lammps.cpp +++ b/src/USER-COLVARS/colvarproxy_lammps.cpp @@ -8,7 +8,20 @@ // Colvars repository at GitHub. +#include "colvarproxy_lammps.h" #include +#include +#include +#include + +#include +#include +#include + +#include +#include +#include + #include "lammps.h" #include "atom.h" #include "error.h" @@ -22,19 +35,6 @@ #include "colvarbias.h" #include "colvaratoms.h" #include "colvarproxy.h" -#include "colvarproxy_lammps.h" - -#include -#include -#include - -#include -#include -#include - -#include -#include -#include #define HASH_FAIL -1 diff --git a/src/USER-COLVARS/fix_colvars.cpp b/src/USER-COLVARS/fix_colvars.cpp index ff0e8fb334..9331fe7abb 100644 --- a/src/USER-COLVARS/fix_colvars.cpp +++ b/src/USER-COLVARS/fix_colvars.cpp @@ -24,13 +24,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_colvars.h" #include #include #include #include #include -#include "fix_colvars.h" #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/USER-COLVARS/group_ndx.cpp b/src/USER-COLVARS/group_ndx.cpp index 858336c9d5..7350712c40 100644 --- a/src/USER-COLVARS/group_ndx.cpp +++ b/src/USER-COLVARS/group_ndx.cpp @@ -17,15 +17,14 @@ ------------------------------------------------------------------------- */ #include "group_ndx.h" +#include +#include #include "atom.h" #include "comm.h" #include "group.h" #include "memory.h" #include "error.h" -#include -#include - using namespace LAMMPS_NS; /* ---------------------------------------------------------------------- diff --git a/src/USER-COLVARS/ndx_group.cpp b/src/USER-COLVARS/ndx_group.cpp index 7b46364f18..5436ba7b6b 100644 --- a/src/USER-COLVARS/ndx_group.cpp +++ b/src/USER-COLVARS/ndx_group.cpp @@ -17,6 +17,9 @@ ------------------------------------------------------------------------- */ #include "ndx_group.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "group.h" @@ -24,10 +27,6 @@ #include "force.h" #include "error.h" -#include -#include -#include - using namespace LAMMPS_NS; #define BUFLEN 4096 #define DELTA 16384 From 95cb995336e4c20211bd354067bdb199baadee07 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 3 Jul 2019 22:18:41 -0400 Subject: [PATCH 36/79] recover compilation of MANYBODY package --- src/MANYBODY/pair_polymorphic.h | 1 + 1 file changed, 1 insertion(+) diff --git a/src/MANYBODY/pair_polymorphic.h b/src/MANYBODY/pair_polymorphic.h index 32f1c5414a..e7c3cd0d26 100644 --- a/src/MANYBODY/pair_polymorphic.h +++ b/src/MANYBODY/pair_polymorphic.h @@ -22,6 +22,7 @@ PairStyle(polymorphic,PairPolymorphic) #include "pair.h" #include +#include namespace LAMMPS_NS { From e63fe1fe84e51c734c2170b4f6eb324d01abb58e Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 4 Jul 2019 00:09:01 -0400 Subject: [PATCH 37/79] please POEMS library in namespace POEMS and remove "using namespace" from headers --- lib/poems/POEMSChain.h | 99 +++--- lib/poems/SystemProcessor.h | 439 +++++++++++------------ lib/poems/body.cpp | 5 +- lib/poems/body.h | 3 +- lib/poems/body23joint.cpp | 3 + lib/poems/body23joint.h | 3 +- lib/poems/colmatmap.cpp | 2 + lib/poems/colmatmap.h | 3 +- lib/poems/colmatrix.cpp | 2 + lib/poems/colmatrix.h | 42 +-- lib/poems/defines.h | 7 +- lib/poems/eulerparameters.cpp | 42 +-- lib/poems/eulerparameters.h | 3 +- lib/poems/fastmatrixops.cpp | 130 +++---- lib/poems/fastmatrixops.h | 3 +- lib/poems/fixedpoint.cpp | 2 + lib/poems/fixedpoint.h | 3 +- lib/poems/freebodyjoint.cpp | 126 +++---- lib/poems/freebodyjoint.h | 8 +- lib/poems/inertialframe.cpp | 2 + lib/poems/inertialframe.h | 4 +- lib/poems/joint.cpp | 4 +- lib/poems/joint.h | 3 +- lib/poems/mat3x3.cpp | 2 + lib/poems/mat3x3.h | 14 +- lib/poems/mat4x4.cpp | 2 + lib/poems/mat4x4.h | 11 +- lib/poems/mat6x6.cpp | 2 + lib/poems/mat6x6.h | 3 +- lib/poems/matrices.h | 13 +- lib/poems/matrix.cpp | 2 + lib/poems/matrix.h | 8 +- lib/poems/matrixfun.cpp | 48 +-- lib/poems/matrixfun.h | 17 +- lib/poems/mixedjoint.cpp | 130 +++---- lib/poems/mixedjoint.h | 12 +- lib/poems/norm.cpp | 2 + lib/poems/norm.h | 7 +- lib/poems/onbody.cpp | 2 + lib/poems/onbody.h | 106 +++--- lib/poems/onfunctions.cpp | 40 ++- lib/poems/onfunctions.h | 3 +- lib/poems/onsolver.cpp | 2 + lib/poems/onsolver.h | 49 ++- lib/poems/particle.cpp | 2 + lib/poems/particle.h | 10 +- lib/poems/poemslist.h | 74 ++-- lib/poems/poemsnodelib.h | 11 +- lib/poems/poemsobject.cpp | 2 + lib/poems/poemsobject.h | 4 +- lib/poems/poemstree.h | 4 +- lib/poems/poemstreenode.cpp | 2 + lib/poems/poemstreenode.h | 39 ++- lib/poems/point.cpp | 4 +- lib/poems/point.h | 18 +- lib/poems/prismaticjoint.cpp | 2 + lib/poems/prismaticjoint.h | 5 +- lib/poems/revolutejoint.cpp | 2 + lib/poems/revolutejoint.h | 3 +- lib/poems/rigidbody.cpp | 2 + lib/poems/rigidbody.h | 3 +- lib/poems/rowmatrix.cpp | 2 + lib/poems/rowmatrix.h | 3 +- lib/poems/solver.cpp | 2 + lib/poems/solver.h | 19 +- lib/poems/sphericaljoint.cpp | 190 +++++----- lib/poems/sphericaljoint.h | 3 +- lib/poems/system.cpp | 615 +++++++++++++++++---------------- lib/poems/system.h | 33 +- lib/poems/vect3.cpp | 2 + lib/poems/vect3.h | 8 +- lib/poems/vect4.cpp | 2 + lib/poems/vect4.h | 9 +- lib/poems/vect6.cpp | 2 + lib/poems/vect6.h | 3 +- lib/poems/virtualcolmatrix.cpp | 2 + lib/poems/virtualcolmatrix.h | 38 +- lib/poems/virtualmatrix.cpp | 6 +- lib/poems/virtualmatrix.h | 3 +- lib/poems/virtualrowmatrix.cpp | 2 + lib/poems/virtualrowmatrix.h | 11 +- lib/poems/workspace.cpp | 2 + lib/poems/workspace.h | 67 ++-- src/POEMS/fix_poems.cpp | 4 +- src/POEMS/fix_poems.h | 3 +- 85 files changed, 1361 insertions(+), 1270 deletions(-) diff --git a/lib/poems/POEMSChain.h b/lib/poems/POEMSChain.h index 9f0db59333..8baa293dbd 100644 --- a/lib/poems/POEMSChain.h +++ b/lib/poems/POEMSChain.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: PoemsChain.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -19,56 +19,59 @@ #define POEMSCHAIN_H_ #include "poemslist.h" +#include +namespace POEMS { struct ChildRingData { - List * childRing; - int entranceNodeId; + List * childRing; + int entranceNodeId; }; struct POEMSChain{ - ~POEMSChain(){ - for(int i = 0; i < childChains.GetNumElements(); i++) - { - delete childChains(i); - } - listOfNodes.DeleteValues(); - } - //void printTreeStructure(int tabs); - //void getTreeAsList(List * temp); - List listOfNodes; - List childChains; - POEMSChain * parentChain; - List childRings; - - - void printTreeStructure(int tabs){ - for(int i = 0; i < tabs; i++) - { - cout << "\t"; - } - cout << "Chain: "; - for(int i = 0; i < listOfNodes.GetNumElements(); i++) - { - cout << *(listOfNodes(i)) << " "; - } - cout << endl; - for(int i = 0; i < childChains.GetNumElements(); i++) - { - childChains(i)->printTreeStructure(tabs + 1); - } - } - void getTreeAsList(List * temp) - { - for(int i = 0; i < listOfNodes.GetNumElements(); i++) - { - int * integer = new int; - *integer = *(listOfNodes(i)); - temp->Append(integer); - } - for(int i = 0; i < childChains.GetNumElements(); i++) - { - childChains(i)->getTreeAsList(temp); - } - } + ~POEMSChain(){ + for(int i = 0; i < childChains.GetNumElements(); i++) + { + delete childChains(i); + } + listOfNodes.DeleteValues(); + } + //void printTreeStructure(int tabs); + //void getTreeAsList(List * temp); + List listOfNodes; + List childChains; + POEMSChain * parentChain; + List childRings; + + + void printTreeStructure(int tabs){ + for(int i = 0; i < tabs; i++) + { + std::cout << "\t"; + } + std::cout << "Chain: "; + for(int i = 0; i < listOfNodes.GetNumElements(); i++) + { + std::cout << *(listOfNodes(i)) << " "; + } + std::cout << std::endl; + for(int i = 0; i < childChains.GetNumElements(); i++) + { + childChains(i)->printTreeStructure(tabs + 1); + } + } + void getTreeAsList(List * temp) + { + for(int i = 0; i < listOfNodes.GetNumElements(); i++) + { + int * integer = new int; + *integer = *(listOfNodes(i)); + temp->Append(integer); + } + for(int i = 0; i < childChains.GetNumElements(); i++) + { + childChains(i)->getTreeAsList(temp); + } + } }; +} #endif diff --git a/lib/poems/SystemProcessor.h b/lib/poems/SystemProcessor.h index 3be168c34d..a6001d96d0 100644 --- a/lib/poems/SystemProcessor.h +++ b/lib/poems/SystemProcessor.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: SystemProcessor.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,59 +11,61 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef _SYS_PROCESSOR_H_ #define _SYS_PROCESSOR_H_ +#include #include "poemslist.h" #include "poemstree.h" #include "POEMSChain.h" +namespace POEMS { struct POEMSNode { - List links; - List taken; - int idNumber; - bool visited; - - ~POEMSNode(){ - for(int i = 0; i < taken.GetNumElements(); i++) - { - delete taken(i); - } - }; + List links; + List taken; + int idNumber; + bool visited; + + ~POEMSNode(){ + for(int i = 0; i < taken.GetNumElements(); i++) + { + delete taken(i); + } + }; }; class SystemProcessor{ private: - Tree nodes; - static void POEMSNodeDelete_cb(void *node) { - delete (POEMSNode *) node; - } - List headsOfSystems; - List > ringsInSystem; - POEMSNode * findSingleLink(TreeNode * aNode); - POEMSChain * AddNewChain(POEMSNode * currentNode); - bool setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNode); + Tree nodes; + static void POEMSNodeDelete_cb(void *node) { + delete (POEMSNode *) node; + } + List headsOfSystems; + List > ringsInSystem; + POEMSNode * findSingleLink(TreeNode * aNode); + POEMSChain * AddNewChain(POEMSNode * currentNode); + bool setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNode); public: - SystemProcessor(void); - - ~SystemProcessor(void) { - headsOfSystems.DeleteValues(); - for(int i = 0; i < ringsInSystem.GetNumElements(); i++) - { - for(int k = 0; k < ringsInSystem(i)->GetNumElements(); i++) - { - delete (*ringsInSystem(i))(k); - } - } - }; - void processArray(int** links, int numLinks); - List * getSystemData(); - int getNumberOfHeadChains(); + SystemProcessor(void); + + ~SystemProcessor(void) { + headsOfSystems.DeleteValues(); + for(int i = 0; i < ringsInSystem.GetNumElements(); i++) + { + for(int k = 0; k < ringsInSystem(i)->GetNumElements(); i++) + { + delete (*ringsInSystem(i))(k); + } + } + }; + void processArray(int** links, int numLinks); + List * getSystemData(); + int getNumberOfHeadChains(); }; SystemProcessor::SystemProcessor(void){ @@ -73,145 +75,145 @@ SystemProcessor::SystemProcessor(void){ void SystemProcessor::processArray(int** links, int numLinks) { - bool * false_var; //holds the value false; needed because a constant cannot be put into a list; the list requires a - //reference. - for(int i = 0; i < numLinks; i++) //go through all the links in the input array - { - if(!nodes.Find(links[i][0])) //if the first node in the pair is not found in the storage tree - { - POEMSNode * newNode = new POEMSNode; //make a new node -// forDeletion.Append(newNode); - newNode->idNumber = links[i][0]; //set its ID to the value - newNode->visited = false; //set it to be unvisited - nodes.Insert(links[i][0], links[i][0], (void *) newNode); //and add it to the tree storage structure - } - if(!nodes.Find(links[i][1])) //repeat process for the other half of each link - { - POEMSNode * newNode = new POEMSNode; -// forDeletion.Append(newNode); - newNode->idNumber = links[i][1]; - newNode->visited = false; - nodes.Insert(links[i][1], links[i][1], (void *) newNode); - } - POEMSNode * firstNode = (POEMSNode *)nodes.Find(links[i][0]); //now that we are sure both nodes exist, - POEMSNode * secondNode = (POEMSNode *)nodes.Find(links[i][1]); //we can get both of them out of the tree - firstNode->links.Append(secondNode); //and add the link from the first to the second... - false_var = new bool; - *false_var = false; //make a new false boolean to note that the link between these two - firstNode->taken.Append(false_var); //has not already been taken, and append it to the taken list - secondNode->links.Append(firstNode); //repeat process for link from second node to first - false_var = new bool; - *false_var = false; - secondNode->taken.Append(false_var); - } - - TreeNode * temp = nodes.GetRoot(); //get the root node of the node storage tree - POEMSNode * currentNode; - do - { - currentNode = findSingleLink(temp); //find the start of the next available chain - if(currentNode != NULL) - { - headsOfSystems.Append(AddNewChain(currentNode)); //and add it to the headsOfSystems list of chains - } - } - while(currentNode != NULL); //repeat this until all chains have been added + bool * false_var; //holds the value false; needed because a constant cannot be put into a list; the list requires a + //reference. + for(int i = 0; i < numLinks; i++) //go through all the links in the input array + { + if(!nodes.Find(links[i][0])) //if the first node in the pair is not found in the storage tree + { + POEMSNode * newNode = new POEMSNode; //make a new node +// forDeletion.Append(newNode); + newNode->idNumber = links[i][0]; //set its ID to the value + newNode->visited = false; //set it to be unvisited + nodes.Insert(links[i][0], links[i][0], (void *) newNode); //and add it to the tree storage structure + } + if(!nodes.Find(links[i][1])) //repeat process for the other half of each link + { + POEMSNode * newNode = new POEMSNode; +// forDeletion.Append(newNode); + newNode->idNumber = links[i][1]; + newNode->visited = false; + nodes.Insert(links[i][1], links[i][1], (void *) newNode); + } + POEMSNode * firstNode = (POEMSNode *)nodes.Find(links[i][0]); //now that we are sure both nodes exist, + POEMSNode * secondNode = (POEMSNode *)nodes.Find(links[i][1]); //we can get both of them out of the tree + firstNode->links.Append(secondNode); //and add the link from the first to the second... + false_var = new bool; + *false_var = false; //make a new false boolean to note that the link between these two + firstNode->taken.Append(false_var); //has not already been taken, and append it to the taken list + secondNode->links.Append(firstNode); //repeat process for link from second node to first + false_var = new bool; + *false_var = false; + secondNode->taken.Append(false_var); + } + + TreeNode * temp = nodes.GetRoot(); //get the root node of the node storage tree + POEMSNode * currentNode; + do + { + currentNode = findSingleLink(temp); //find the start of the next available chain + if(currentNode != NULL) + { + headsOfSystems.Append(AddNewChain(currentNode)); //and add it to the headsOfSystems list of chains + } + } + while(currentNode != NULL); //repeat this until all chains have been added } POEMSChain * SystemProcessor::AddNewChain(POEMSNode * currentNode){ - if(currentNode == NULL) //Termination condition; if the currentNode is null, then return null - { - return NULL; - } - int * tmp; - POEMSNode * nextNode = NULL; //nextNode stores the proposed next node to add to the chain. this will be checked to make sure no backtracking is occuring before being assigned as the current node. - POEMSChain * newChain = new POEMSChain; //make a new POEMSChain object. This will be the object returned + if(currentNode == NULL) //Termination condition; if the currentNode is null, then return null + { + return NULL; + } + int * tmp; + POEMSNode * nextNode = NULL; //nextNode stores the proposed next node to add to the chain. this will be checked to make sure no backtracking is occuring before being assigned as the current node. + POEMSChain * newChain = new POEMSChain; //make a new POEMSChain object. This will be the object returned - if(currentNode->links.GetNumElements() == 0) //if we have no links from this node, then the whole chain is only one node. Add this node to the chain and return it; mark node as visited for future reference - { - currentNode->visited = true; - tmp = new int; - *tmp = currentNode->idNumber; - newChain->listOfNodes.Append(tmp); - return newChain; - } - while(currentNode->links.GetNumElements() <= 2) //we go until we get to a node that branches, or both branches have already been taken both branches can already be taken if a loop with no spurs is found in the input data - { - currentNode->visited = true; - tmp = new int; - *tmp = currentNode->idNumber; - newChain->listOfNodes.Append(tmp); //append the current node to the chain & mark as visited - //cout << "Appending node " << currentNode->idNumber << " to chain" << endl; - nextNode = currentNode->links.GetHeadElement()->value; //the next node is the first or second value stored in the links array - //of the current node. We get the first value... - if(!setLinkVisited(currentNode, nextNode)) //...and see if it points back to where we came from. If it does... - { //either way, we set this link as visited - if(currentNode->links.GetNumElements() == 1) //if it does, then if that is the only link to this node, we're done with the chain, so append the chain to the list and return the newly created chain - { -// headsOfSystems.Append(newChain); - return newChain; - } - nextNode = currentNode->links.GetHeadElement()->next->value;//follow the other link if there is one, so we go down the chain - if(!setLinkVisited(currentNode, nextNode)) //mark link as followed, so we know not to backtrack - { - // headsOfSystems.Append(newChain); - return newChain; //This condition, where no branches have occurred but both links have already - //been taken can only occur in a loop with no spurs; add this loop to the - //system (currently added as a chain for consistency), and return. - } - } - currentNode = nextNode; //set the current node to be the next node in the chain - } - currentNode->visited = true; - tmp = new int; - *tmp = currentNode->idNumber; - newChain->listOfNodes.Append(tmp); //append the last node before branch (node shared jointly with branch chains) - //re-mark as visited, just to make sure - ListElement * tempNode = currentNode->links.GetHeadElement(); //go through all of the links, one at a time that branch - POEMSChain * tempChain = NULL; //temporary variable to hold data - while(tempNode != NULL) //when we have followed all links, stop - { - if(setLinkVisited(tempNode->value, currentNode)) //dont backtrack, or create closed loops - { - tempChain = AddNewChain(tempNode->value); //Add a new chain created out of the next node down that link - tempChain->parentChain = newChain; //set the parent to be this chain - newChain->childChains.Append(tempChain); //append the chain to this chain's list of child chains - } - tempNode = tempNode->next; //go to process the next chain - } - //headsOfSystems.Append(newChain); //append this chain to the system list - return newChain; + if(currentNode->links.GetNumElements() == 0) //if we have no links from this node, then the whole chain is only one node. Add this node to the chain and return it; mark node as visited for future reference + { + currentNode->visited = true; + tmp = new int; + *tmp = currentNode->idNumber; + newChain->listOfNodes.Append(tmp); + return newChain; + } + while(currentNode->links.GetNumElements() <= 2) //we go until we get to a node that branches, or both branches have already been taken both branches can already be taken if a loop with no spurs is found in the input data + { + currentNode->visited = true; + tmp = new int; + *tmp = currentNode->idNumber; + newChain->listOfNodes.Append(tmp); //append the current node to the chain & mark as visited + //std::cout << "Appending node " << currentNode->idNumber << " to chain" << std::endl; + nextNode = currentNode->links.GetHeadElement()->value; //the next node is the first or second value stored in the links array + //of the current node. We get the first value... + if(!setLinkVisited(currentNode, nextNode)) //...and see if it points back to where we came from. If it does... + { //either way, we set this link as visited + if(currentNode->links.GetNumElements() == 1) //if it does, then if that is the only link to this node, we're done with the chain, so append the chain to the list and return the newly created chain + { +// headsOfSystems.Append(newChain); + return newChain; + } + nextNode = currentNode->links.GetHeadElement()->next->value;//follow the other link if there is one, so we go down the chain + if(!setLinkVisited(currentNode, nextNode)) //mark link as followed, so we know not to backtrack + { + // headsOfSystems.Append(newChain); + return newChain; //This condition, where no branches have occurred but both links have already + //been taken can only occur in a loop with no spurs; add this loop to the + //system (currently added as a chain for consistency), and return. + } + } + currentNode = nextNode; //set the current node to be the next node in the chain + } + currentNode->visited = true; + tmp = new int; + *tmp = currentNode->idNumber; + newChain->listOfNodes.Append(tmp); //append the last node before branch (node shared jointly with branch chains) + //re-mark as visited, just to make sure + ListElement * tempNode = currentNode->links.GetHeadElement(); //go through all of the links, one at a time that branch + POEMSChain * tempChain = NULL; //temporary variable to hold data + while(tempNode != NULL) //when we have followed all links, stop + { + if(setLinkVisited(tempNode->value, currentNode)) //dont backtrack, or create closed loops + { + tempChain = AddNewChain(tempNode->value); //Add a new chain created out of the next node down that link + tempChain->parentChain = newChain; //set the parent to be this chain + newChain->childChains.Append(tempChain); //append the chain to this chain's list of child chains + } + tempNode = tempNode->next; //go to process the next chain + } + //headsOfSystems.Append(newChain); //append this chain to the system list + return newChain; } POEMSNode * SystemProcessor::findSingleLink(TreeNode * aNode) //This function takes the root of a search tree containing POEMSNodes and returns a POEMSNode corresponding to the start of a chain in the //system. It finds a node that has not been visited before, and only has one link; this node will be used as the head of the chain. { - if(aNode == NULL) - { - return NULL; - } - POEMSNode * returnVal = (POEMSNode *)aNode->GetAuxData(); //get the poemsnode data out of the treenode - POEMSNode * detectLoneLoops = NULL; //is used to handle a loop that has no protruding chains - if(returnVal->visited == false) - { - detectLoneLoops = returnVal; //if we find any node that has not been visited yet, save it - } - if(returnVal->links.GetNumElements() == 1 && returnVal->visited == false) //see if it has one element and hasnt been visited already - { - return returnVal; //return the node is it meets this criteria - } - returnVal = findSingleLink(aNode->Left()); //otherwise, check the left subtree - if(returnVal == NULL) //and if we find nothing... - { - returnVal = findSingleLink(aNode->Right()); //check the right subtree - } - if(returnVal == NULL) //if we could not find any chains - { - returnVal = detectLoneLoops; //see if we found any nodes at all that havent been processed - } - return returnVal; //return what we find (will be NULL if no new chains are - //found) + if(aNode == NULL) + { + return NULL; + } + POEMSNode * returnVal = (POEMSNode *)aNode->GetAuxData(); //get the poemsnode data out of the treenode + POEMSNode * detectLoneLoops = NULL; //is used to handle a loop that has no protruding chains + if(returnVal->visited == false) + { + detectLoneLoops = returnVal; //if we find any node that has not been visited yet, save it + } + if(returnVal->links.GetNumElements() == 1 && returnVal->visited == false) //see if it has one element and hasnt been visited already + { + return returnVal; //return the node is it meets this criteria + } + returnVal = findSingleLink(aNode->Left()); //otherwise, check the left subtree + if(returnVal == NULL) //and if we find nothing... + { + returnVal = findSingleLink(aNode->Right()); //check the right subtree + } + if(returnVal == NULL) //if we could not find any chains + { + returnVal = detectLoneLoops; //see if we found any nodes at all that havent been processed + } + return returnVal; //return what we find (will be NULL if no new chains are + //found) } bool SystemProcessor::setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNode) @@ -223,65 +225,66 @@ bool SystemProcessor::setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNo //value for that particular link. Because each link is represented twice, (once at each node in the link), both of the boolean values need //to be set in the event that the link has to be set as visited. { - //cout << "Checking link between nodes " << firstNode->idNumber << " and " << secondNode->idNumber << "... "; - ListElement * tmp = firstNode->links.GetHeadElement(); //get the head element of the list of pointers for node 1 - ListElement * tmp2 = firstNode->taken.GetHeadElement(); //get the head element of the list of bool isVisited flags for node 1 - while(tmp->value != NULL || tmp2->value != NULL) //go through untill we reach the end of the lists - { - if(tmp->value == secondNode) //if we find the link to the other node - { - if(*(tmp2->value) == true) //if the link has already been visited - { - //cout << "visited already" << endl; - return false; //return false to indicate that the link has been visited before this attempt - } - else //otherwise, visit it - { - *tmp2->value = true; - } - break; - } - tmp = tmp->next; //go check next link - tmp2 = tmp2->next; - } + //std::cout << "Checking link between nodes " << firstNode->idNumber << " and " << secondNode->idNumber << "... "; + ListElement * tmp = firstNode->links.GetHeadElement(); //get the head element of the list of pointers for node 1 + ListElement * tmp2 = firstNode->taken.GetHeadElement(); //get the head element of the list of bool isVisited flags for node 1 + while(tmp->value != NULL || tmp2->value != NULL) //go through untill we reach the end of the lists + { + if(tmp->value == secondNode) //if we find the link to the other node + { + if(*(tmp2->value) == true) //if the link has already been visited + { + //std::cout << "visited already" << std::endl; + return false; //return false to indicate that the link has been visited before this attempt + } + else //otherwise, visit it + { + *tmp2->value = true; + } + break; + } + tmp = tmp->next; //go check next link + tmp2 = tmp2->next; + } - tmp = secondNode->links.GetHeadElement(); //now, if the link was unvisited, we need to go set the other node's list such that - //it also knows this link is being visited - tmp2 = secondNode->taken.GetHeadElement(); - while(tmp->value != NULL || tmp2->value != NULL) //go through the list - { - if(tmp->value == firstNode) //if we find the link - { - if(*(tmp2->value) == true) //and it has already been visited, then signal an error; this shouldnt ever happen - { - cout << "Error in parsing structure! Should never reach this condition! \n" << - "Record of visited links out of synch between two adjacent nodes.\n"; - return false; - } - else - { - *tmp2->value = true; //set the appropriate value to true to indicate this link has been visited - } - break; - } - tmp = tmp->next; - tmp2 = tmp2->next; - } - //cout << "not visited" << endl; - return true; //return true to indicate that this is the first time the link has been visited + tmp = secondNode->links.GetHeadElement(); //now, if the link was unvisited, we need to go set the other node's list such that + //it also knows this link is being visited + tmp2 = secondNode->taken.GetHeadElement(); + while(tmp->value != NULL || tmp2->value != NULL) //go through the list + { + if(tmp->value == firstNode) //if we find the link + { + if(*(tmp2->value) == true) //and it has already been visited, then signal an error; this shouldnt ever happen + { + std::cout << "Error in parsing structure! Should never reach this condition! \n" << + "Record of visited links out of synch between two adjacent nodes.\n"; + return false; + } + else + { + *tmp2->value = true; //set the appropriate value to true to indicate this link has been visited + } + break; + } + tmp = tmp->next; + tmp2 = tmp2->next; + } + //std::cout << "not visited" << std::endl; + return true; //return true to indicate that this is the first time the link has been visited } -List * SystemProcessor::getSystemData(void) //Gets the list of POEMSChains that comprise the system. Might eventually only - //return chains linked to the reference plane, but currently returns every chain - //in the system. +List * SystemProcessor::getSystemData(void) //Gets the list of POEMSChains that comprise the system. Might eventually only + //return chains linked to the reference plane, but currently returns every chain + //in the system. { - return &headsOfSystems; + return &headsOfSystems; } int SystemProcessor::getNumberOfHeadChains(void) //This function isnt implemented yet, and might be taken out entirely; this was a holdover - //from when I intended to return an array of chain pointers, rather than a list of chains - //It will probably be deleted once I finish figuring out exactly what needs to be returned + //from when I intended to return an array of chain pointers, rather than a list of chains + //It will probably be deleted once I finish figuring out exactly what needs to be returned { - return 0; + return 0; +} } #endif diff --git a/lib/poems/body.cpp b/lib/poems/body.cpp index 487d5e1ab7..6825941b93 100644 --- a/lib/poems/body.cpp +++ b/lib/poems/body.cpp @@ -26,9 +26,8 @@ #include "rigidbody.h" #include "vect3.h" -class Joint; - using namespace std; +using namespace POEMS; Body::Body() { @@ -132,7 +131,7 @@ void Body::AddPoint(Point* point){ // global body functions // -Body* NewBody(int type){ +Body* POEMS::NewBody(int type){ switch( BodyType(type) ) { case INERTIALFRAME : // The inertial reference frame diff --git a/lib/poems/body.h b/lib/poems/body.h index 06a9c72417..e2394b40aa 100644 --- a/lib/poems/body.h +++ b/lib/poems/body.h @@ -25,6 +25,7 @@ #include "mat3x3.h" #include "vect3.h" +namespace POEMS { // emumerated type enum BodyType { INERTIALFRAME = 0, @@ -75,5 +76,5 @@ public: // global body functions Body* NewBody(int type); - +} #endif diff --git a/lib/poems/body23joint.cpp b/lib/poems/body23joint.cpp index 7aa761fe2a..e3ef32b2a9 100644 --- a/lib/poems/body23joint.cpp +++ b/lib/poems/body23joint.cpp @@ -27,6 +27,9 @@ #include "vect3.h" #include "virtualmatrix.h" +using namespace std; +using namespace POEMS; + Body23Joint::Body23Joint(){ DimQandU(4,2); } diff --git a/lib/poems/body23joint.h b/lib/poems/body23joint.h index c47cdfb9de..43a727c815 100644 --- a/lib/poems/body23joint.h +++ b/lib/poems/body23joint.h @@ -22,6 +22,7 @@ #include "joint.h" #include "matrix.h" +namespace POEMS { class Body23Joint : public Joint { Matrix const_sP; public: @@ -38,5 +39,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; - +} #endif diff --git a/lib/poems/colmatmap.cpp b/lib/poems/colmatmap.cpp index 1954e7ff15..34a95feb03 100644 --- a/lib/poems/colmatmap.cpp +++ b/lib/poems/colmatmap.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + ColMatMap::ColMatMap(){ numrows = 0; diff --git a/lib/poems/colmatmap.h b/lib/poems/colmatmap.h index 6d84870046..5a12cf487f 100644 --- a/lib/poems/colmatmap.h +++ b/lib/poems/colmatmap.h @@ -24,6 +24,7 @@ #include "virtualcolmatrix.h" #include "virtualmatrix.h" +namespace POEMS { class ColMatrix; class ColMatMap : public VirtualColMatrix { @@ -64,5 +65,5 @@ public: friend void FastCKRK5(ColMatMap& X, ColMatrix& Xi, ColMatrix* f, double* c, double dt); friend void FastFRK5(ColMatMap& X, ColMatrix& Xi, ColMatrix* f, double* c, double dt); }; - +} #endif diff --git a/lib/poems/colmatrix.cpp b/lib/poems/colmatrix.cpp index e7ae98a368..0cc666645a 100644 --- a/lib/poems/colmatrix.cpp +++ b/lib/poems/colmatrix.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + ColMatrix::ColMatrix(){ numrows = 0; diff --git a/lib/poems/colmatrix.h b/lib/poems/colmatrix.h index 70f13356e2..bcfa86843a 100644 --- a/lib/poems/colmatrix.h +++ b/lib/poems/colmatrix.h @@ -23,12 +23,14 @@ #include "virtualcolmatrix.h" #include "virtualmatrix.h" +namespace POEMS { class Matrix; class Vect6; class Mat3x3; class Vect3; class ColMatrix : public VirtualColMatrix { +protected: double* elements; public: ColMatrix(); @@ -58,28 +60,28 @@ public: ColMatrix& operator=(const VirtualMatrix& A); // overloaded = ColMatrix& operator*=(double b); - void Abs(); - void BasicMax(double& value, int& index); - void BasicMin(double& value, int& index); + void Abs(); + void BasicMax(double& value, int& index); + void BasicMin(double& value, int& index); // fast matrix operations - friend void FastQuaternions(ColMatrix& q, Mat3x3& C); - friend void FastInvQuaternions(Mat3x3& C, ColMatrix& q); - friend void FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot); - friend void FastTMult(Matrix& A, Vect6& B, ColMatrix& C); - friend void FastMult(Matrix& A, ColMatrix& B, Vect6& C); - friend void FastAssign(ColMatrix& A, ColMatrix& C); + friend void FastQuaternions(ColMatrix& q, Mat3x3& C); + friend void FastInvQuaternions(Mat3x3& C, ColMatrix& q); + friend void FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot); + friend void FastTMult(Matrix& A, Vect6& B, ColMatrix& C); + friend void FastMult(Matrix& A, ColMatrix& B, Vect6& C); + friend void FastAssign(ColMatrix& A, ColMatrix& C); - friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); - friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); - friend void FastAssign(ColMatrix&A, Vect3& C); - - friend void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); - friend void EP_Transformation(ColMatrix& q, Mat3x3& C); - friend void EP_FromTransformation(ColMatrix& q, Mat3x3& C); - friend void EP_Normalize(ColMatrix& q); - friend void EPdotdot_udot(ColMatrix& Audot, ColMatrix& Aqdot, ColMatrix& Aq,ColMatrix& Aqddot); - friend void qdot_to_u(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); + friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); + friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); + friend void FastAssign(ColMatrix&A, Vect3& C); + + friend void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); + friend void EP_Transformation(ColMatrix& q, Mat3x3& C); + friend void EP_FromTransformation(ColMatrix& q, Mat3x3& C); + friend void EP_Normalize(ColMatrix& q); + friend void EPdotdot_udot(ColMatrix& Audot, ColMatrix& Aqdot, ColMatrix& Aq,ColMatrix& Aqddot); + friend void qdot_to_u(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); }; - +} #endif diff --git a/lib/poems/defines.h b/lib/poems/defines.h index 455bc298d5..877bc0fa0b 100644 --- a/lib/poems/defines.h +++ b/lib/poems/defines.h @@ -15,13 +15,14 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ -#ifndef _DEFINES_H_ -#define _DEFINES_H_ +#ifndef POEMS_DEFINES_H +#define POEMS_DEFINES_H +namespace POEMS { enum SolverType { ONSOLVER = 0, PARTICLESOLVER = 1 }; - +} #endif diff --git a/lib/poems/eulerparameters.cpp b/lib/poems/eulerparameters.cpp index f698c40b3a..bb8d676796 100644 --- a/lib/poems/eulerparameters.cpp +++ b/lib/poems/eulerparameters.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: eulerparameters.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -23,8 +23,10 @@ #include "mat3x3.h" using namespace std; +using namespace POEMS; -void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot){ + +void POEMS::EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot){ EP_Normalize(q); int num=u.GetNumRows(); if (3 @@ -28,10 +28,12 @@ #include "mat6x6.h" #include "vect3.h" #include "virtualmatrix.h" - + +using namespace POEMS; + FreeBodyJoint::FreeBodyJoint(){ - DimQandU(7,6); + DimQandU(7,6); } FreeBodyJoint::~FreeBodyJoint(){ @@ -49,112 +51,112 @@ void FreeBodyJoint::WriteOutJointData(std::ostream& out){ } void FreeBodyJoint::ComputeLocalTransform(){ - Mat3x3 ko_C_k; - EP_Transformation(q, ko_C_k); - FastMult(pk_C_ko,ko_C_k,pk_C_k); + Mat3x3 ko_C_k; + EP_Transformation(q, ko_C_k); + FastMult(pk_C_ko,ko_C_k,pk_C_k); } Matrix FreeBodyJoint::GetForward_sP(){ Mat6x6 sP; - //sP.Identity(); - - sP.Zeros(); + //sP.Identity(); + + sP.Zeros(); Mat3x3 temp0=T(pk_C_k); for(int i=1;i<4;i++){ sP(i,i)=1.0; for(int j=1;j<4;j++){ sP(3+i,3+j)=temp0(i,j); } - } - return sP; + } + return sP; } Matrix FreeBodyJoint::GetBackward_sP(){ Mat6x6 sP; - sP.Identity(); + sP.Identity(); sP =-1.0*sP; - cout<<"Did I come here in "<r); - - //COMMENT STEP3: CALCULATE QDOT + + FastAssign(r12,body2->r); + + //COMMENT STEP3: CALCULATE QDOT qdot_to_u(q, u, qdot); - - + + Vect3 WN; WN.BasicSet(0,u.BasicGet(0)); WN.BasicSet(1,u.BasicGet(1)); WN.BasicSet(2,u.BasicGet(2)); - - Vect3 VN; + + Vect3 VN; VN.BasicSet(0,u.BasicGet(3)); VN.BasicSet(1,u.BasicGet(4)); - VN.BasicSet(2,u.BasicGet(5)); - - FastAssign(WN,body2->omega_k); - - Vect3 pk_w_k; - FastMult(body2->n_C_k,WN,pk_w_k); - FastAssign(pk_w_k,body2->omega); - + VN.BasicSet(2,u.BasicGet(5)); + + FastAssign(WN,body2->omega_k); + + Vect3 pk_w_k; + FastMult(body2->n_C_k,WN,pk_w_k); + FastAssign(pk_w_k,body2->omega); + + + + //COMMENT STEP5: CALCULATE VELOCITES + FastAssign(VN,body2->v); + FastTMult(body2->n_C_k,body2->v,body2->v_k); + + + //CALCULATE KE - - //COMMENT STEP5: CALCULATE VELOCITES - FastAssign(VN,body2->v); - FastTMult(body2->n_C_k,body2->v,body2->v_k); - - - //CALCULATE KE - Matrix tempke; - tempke = T(body2->v)*(body2->v); + tempke = T(body2->v)*(body2->v); double ke = 0.0; - ke = body2->mass*tempke(1,1); + ke = body2->mass*tempke(1,1); FastMult(body2->inertia,body2->omega_k,result1); - tempke= T(body2->omega_k)*result1; + tempke= T(body2->omega_k)*result1; ke = 0.5*ke + 0.5*tempke(1,1); body2->KE=ke; - - + + //COMMENT STEP6: CALCULATE STATE EXPLICIT ANGULAR ACCELERATIONS body2->alpha_t.Zeros(); - - + + //COMMENT STEP7: CALCULATE STATE EXPLICIT ACCELERATIONS - body2->a_t.Zeros(); - + body2->a_t.Zeros(); + } void FreeBodyJoint::BackwardKinematics(){ -cout<<"Did I come here "< #include "virtualmatrix.h" +namespace POEMS { class Vect3; class Mat6x6; class ColMatrix; @@ -67,16 +68,15 @@ public: friend void FastMult(Mat3x3& A, Mat3x3& B, Mat3x3& C); friend void FastMultT(Mat3x3& A, Mat3x3& B, Mat3x3& C); friend void FastAssignT(Mat3x3& A, Mat3x3& C); - friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); - + friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); + friend void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC); friend void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI); friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); - + friend void EP_Transformation(ColMatrix& q, Mat3x3& C); friend void EP_FromTransformation(ColMatrix& q, Mat3x3& C); - }; - +} #endif diff --git a/lib/poems/mat4x4.cpp b/lib/poems/mat4x4.cpp index a6a587bc03..9a0e7b8d56 100644 --- a/lib/poems/mat4x4.cpp +++ b/lib/poems/mat4x4.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + Mat4x4::Mat4x4(){ numrows = numcols = 4; diff --git a/lib/poems/mat4x4.h b/lib/poems/mat4x4.h index a6ae232473..3f6d97ba15 100644 --- a/lib/poems/mat4x4.h +++ b/lib/poems/mat4x4.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: mat4x4.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,17 +21,18 @@ #include #include "virtualmatrix.h" +namespace POEMS { class Vect4; class Matrix; class Mat4x4 : public VirtualMatrix { double elements[4][4]; -public: +public: Mat4x4(); ~Mat4x4(); Mat4x4(const Mat4x4& A); // copy constructor Mat4x4(const VirtualMatrix& A); // copy constructor - + double& operator_2int (int i, int j); // array access double Get_2int(int i, int j) const; void Set_2int(int i, int j, double value); @@ -64,5 +65,5 @@ public: friend void FastMultT(Mat4x4& A, Mat4x4& B, Mat4x4& C); friend void FastAssignT(Mat4x4& A, Mat4x4& C); }; - +} #endif diff --git a/lib/poems/mat6x6.cpp b/lib/poems/mat6x6.cpp index fdc917e03d..e9dde2fe87 100644 --- a/lib/poems/mat6x6.cpp +++ b/lib/poems/mat6x6.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + Mat6x6::Mat6x6(){ numrows = numcols = 6; diff --git a/lib/poems/mat6x6.h b/lib/poems/mat6x6.h index 5eaa4f803b..a611bc8283 100644 --- a/lib/poems/mat6x6.h +++ b/lib/poems/mat6x6.h @@ -21,6 +21,7 @@ #include "virtualmatrix.h" +namespace POEMS { class Matrix; class Mat3x3; class Vect6; @@ -73,5 +74,5 @@ public: friend void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC); friend void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI); }; - +} #endif diff --git a/lib/poems/matrices.h b/lib/poems/matrices.h index 7a7e2c4b58..15f0d3ad23 100644 --- a/lib/poems/matrices.h +++ b/lib/poems/matrices.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: matrices.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -20,23 +20,14 @@ #define MATRICES_H #include "matrix.h" - #include "colmatrix.h" - #include "rowmatrix.h" - #include "mat3x3.h" - #include "vect3.h" - #include "mat4x4.h" - #include "vect4.h" - #include "mat6x6.h" - #include "vect6.h" - #include "colmatmap.h" #endif diff --git a/lib/poems/matrix.cpp b/lib/poems/matrix.cpp index f05d6f815c..f7b0c631f2 100644 --- a/lib/poems/matrix.cpp +++ b/lib/poems/matrix.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + Matrix::Matrix(){ numrows = numcols = 0; diff --git a/lib/poems/matrix.h b/lib/poems/matrix.h index 8bd8110760..c2ed92873c 100644 --- a/lib/poems/matrix.h +++ b/lib/poems/matrix.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: matrix.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -22,6 +22,7 @@ #include "virtualmatrix.h" +namespace POEMS { class Mat3x3; class Mat4x4; class Mat6x6; @@ -73,7 +74,6 @@ public: friend void FastMult(Mat6x6& A, Matrix& B, Matrix& C); friend void FastMult(Matrix& A, ColMatrix& B, Vect6& C); friend void FastMultT(Matrix& A, Matrix& B, Mat6x6& C); - }; - +} #endif diff --git a/lib/poems/matrixfun.cpp b/lib/poems/matrixfun.cpp index 99fbae4ca1..037e986a99 100644 --- a/lib/poems/matrixfun.cpp +++ b/lib/poems/matrixfun.cpp @@ -27,12 +27,14 @@ #include "virtualrowmatrix.h" using namespace std; +using namespace POEMS; + // // Create a new matrix // -VirtualMatrix* NewMatrix(int type){ +VirtualMatrix* POEMS::NewMatrix(int type){ switch( MatrixType(type) ) { case MATRIX : return new Matrix; @@ -50,7 +52,7 @@ VirtualMatrix* NewMatrix(int type){ // Transpose // -Matrix T(const VirtualMatrix& A){ +Matrix POEMS::T(const VirtualMatrix& A){ int numrows = A.GetNumRows(); int numcols = A.GetNumCols(); Matrix C(numcols,numrows); @@ -60,8 +62,8 @@ Matrix T(const VirtualMatrix& A){ return C; } -Mat3x3 T(const Mat3x3& A){ - Mat3x3 C; +Mat3x3 POEMS::T(const Mat3x3& A){ + Mat3x3 C; C.elements[0][0] = A.elements[0][0]; C.elements[1][1] = A.elements[1][1]; C.elements[2][2] = A.elements[2][2]; @@ -76,7 +78,7 @@ Mat3x3 T(const Mat3x3& A){ return C; } -Mat6x6 T(const Mat6x6& A){ +Mat6x6 POEMS::T(const Mat6x6& A){ Mat6x6 C; int i,j; for(i=0;i<6;i++) @@ -86,7 +88,7 @@ Mat6x6 T(const Mat6x6& A){ return C; } -Matrix T(const Vect3& A){ +Matrix POEMS::T(const Vect3& A){ Matrix C(1,3); C.BasicSet(0,0,A.elements[0]); C.BasicSet(0,1,A.elements[1]); @@ -95,7 +97,7 @@ Matrix T(const Vect3& A){ return C; } -Matrix T(const Vect6& A){ +Matrix POEMS::T(const Vect6& A){ Matrix C(1,6); C.BasicSet(0,0,A.elements[0]); C.BasicSet(0,1,A.elements[1]); @@ -107,7 +109,7 @@ Matrix T(const Vect6& A){ return C; } -RowMatrix T(const VirtualColMatrix &A){ +RowMatrix POEMS::T(const VirtualColMatrix &A){ int numele = A.GetNumRows(); RowMatrix C(numele); for(int i=0;i @@ -29,9 +29,11 @@ #include "vect3.h" #include "virtualmatrix.h" - +using namespace POEMS; +using namespace std; -MixedJoint::MixedJoint(){ + +MixedJoint::MixedJoint(){ } MixedJoint::~MixedJoint(){ @@ -54,23 +56,23 @@ void MixedJoint::SetsP(Matrix& sPr, Vect6& temp_dofs, int i, int j){ numrots = i; numtrans = j; if (numrots < 2) - DimQandU(numrots+numtrans,numrots+numtrans); - else - DimQandU((4+numtrans),(numrots+numtrans)); + DimQandU(numrots+numtrans,numrots+numtrans); + else + DimQandU((4+numtrans),(numrots+numtrans)); cout<<"Check "<<4+numtrans<<" "< 1) EP_Normalize(q); // COMMENT STEP1: CALCULATE ORIENTATIONS - ComputeForwardTransforms(); - - + ComputeForwardTransforms(); + + //COMMENT STEP2: CALCULATE POSITION VECTORS - Vect3 result1, result2, result3, result4; + Vect3 result1, result2, result3, result4; result1.Zeros(); for (int k=0; k<3; k++){ if( dofs(3+k) != 0.0 ){ @@ -116,32 +118,32 @@ void MixedJoint::ForwardKinematics(){ result1.BasicSet(k,q.BasicGet(4 + k)); else result1.BasicSet(k,q.BasicGet(numrots + k)); - } + } } - - - - FastAssign(result1,r12); // r12 in parents basis i.e. Newtonian - FastNegMult(k_C_pk,r12,r21); // r21 in body basis - - FastAssign(r12,body2->r); // This is right - - //COMMENT STEP3: CALCULATE QDOT + + + + FastAssign(result1,r12); // r12 in parents basis i.e. Newtonian + FastNegMult(k_C_pk,r12,r21); // r21 in body basis + + FastAssign(r12,body2->r); // This is right + + //COMMENT STEP3: CALCULATE QDOT int pp = 0; if (numrots > 1){ ColMatrix temp_u(3+numtrans); qdot_to_u(q,temp_u,qdot); for (int k=1;k<=6;k++){ if(dofs(k) != 0.0){ - u.BasicSet(pp,temp_u.BasicGet(k-1)); + u.BasicSet(pp,temp_u.BasicGet(k-1)); pp = pp+1; - } + } } } else u = qdot; - - + + Vect3 WN; WN.Zeros(); int p = 0; for (int k=0;k<3;k++){ @@ -151,51 +153,51 @@ void MixedJoint::ForwardKinematics(){ } }// WN is in body basis - - Vect3 VN; VN.Zeros(); + + Vect3 VN; VN.Zeros(); for (int k=0;k<3;k++){ if( dofs(3+k+1) != 0.0 ) { VN.BasicSet(k,u.BasicGet(p)); p=p+1; } }// VN is the vector of translational velocities in Newtonian basis - - FastAssign(WN,body2->omega_k); - // cout<<"Angular Velocity "<omega_k); + + // cout<<"Angular Velocity "<n_C_k,WN,pk_w_k); + FastMult(body2->n_C_k,WN,pk_w_k); FastAssign(pk_w_k,body2->omega); - - - - //COMMENT STEP5: CALCULATE VELOCITES - FastAssign(VN,body2->v); - FastTMult(body2->n_C_k,body2->v,body2->v_k); - - - //CALCULATE KE - + + + + //COMMENT STEP5: CALCULATE VELOCITES + FastAssign(VN,body2->v); + FastTMult(body2->n_C_k,body2->v,body2->v_k); + + + //CALCULATE KE + Matrix tempke; - tempke = T(body2->v)*(body2->v); + tempke = T(body2->v)*(body2->v); double ke = 0.0; - ke = body2->mass*tempke(1,1); + ke = body2->mass*tempke(1,1); FastMult(body2->inertia,body2->omega_k,result1); - tempke= T(body2->omega_k)*result1; + tempke= T(body2->omega_k)*result1; ke = 0.5*ke + 0.5*tempke(1,1); body2->KE=ke; - - + + //COMMENT STEP6: CALCULATE STATE EXPLICIT ANGULAR ACCELERATIONS body2->alpha_t.Zeros(); - - + + //COMMENT STEP7: CALCULATE STATE EXPLICIT ACCELERATIONS - body2->a_t.Zeros(); - + body2->a_t.Zeros(); + } void MixedJoint::BackwardKinematics(){ cout<<"Did I come here "< children; + Body* system_body; + Joint* system_joint; + OnBody* parent; + List children; - Direction joint_dir; - void (Joint::*kinfun)(); // kinematics function - void (Joint::*updatesP)(Matrix&); // sP update function - Vect3* gamma; // pointer to gamma vector - Mat3x3* pk_C_k; // pointer to transformation + Direction joint_dir; + void (Joint::*kinfun)(); // kinematics function + void (Joint::*updatesP)(Matrix&); // sP update function + Vect3* gamma; // pointer to gamma vector + Mat3x3* pk_C_k; // pointer to transformation - - Mat6x6 sI; // spatial inertias - Mat6x6 sIhat; // recursive spatial inertias - Mat6x6 sSC; // spatial shift - Mat6x6 sT; // spatial triangularization - Vect6 sF; // spatial forces - Vect6 sFhat; // recursive spatial forces - Vect6 sAhat; // recursive spatial acceleration + Mat6x6 sI; // spatial inertias + Mat6x6 sIhat; // recursive spatial inertias + Mat6x6 sSC; // spatial shift + Mat6x6 sT; // spatial triangularization - Matrix sP; // spatial partial velocities - Matrix sM; // triangularized mass matrix diagonal elements - Matrix sMinv; // inverse of sM - Matrix sPsMinv; - Matrix sIhatsP; + Vect6 sF; // spatial forces + Vect6 sFhat; // recursive spatial forces + Vect6 sAhat; // recursive spatial acceleration - // states and state derivatives - ColMatrix* q; - ColMatrix* u; - ColMatrix* qdot; - ColMatrix* udot; - ColMatrix* qdotdot; - - ColMatrix* r; - ColMatrix* acc; - ColMatrix* ang; + Matrix sP; // spatial partial velocities + Matrix sM; // triangularized mass matrix diagonal elements + Matrix sMinv; // inverse of sM + Matrix sPsMinv; + Matrix sIhatsP; + + // states and state derivatives + ColMatrix* q; + ColMatrix* u; + ColMatrix* qdot; + ColMatrix* udot; + ColMatrix* qdotdot; + + ColMatrix* r; + ColMatrix* acc; + ColMatrix* ang; // friend classes friend class OnSolver; - -public: - OnBody(); - ~OnBody(); - int RecursiveSetup(InertialFrame* basebody); - int RecursiveSetup(int ID, OnBody* parentbody, Joint* sys_joint); - void RecursiveKinematics(); - void RecursiveTriangularization(); - void RecursiveForwardSubstitution(); - Mat3x3 GetN_C_K(); - Vect3 LocalCart(); - int GetBodyID(); - void CalculateAcceleration(); - void Setup(); - void SetupInertialFrame(); - void LocalKinematics(); - void LocalTriangularization(Vect3& Torque, Vect3& Force); - void LocalForwardSubstitution(); +public: + OnBody(); + ~OnBody(); + int RecursiveSetup(InertialFrame* basebody); + int RecursiveSetup(int ID, OnBody* parentbody, Joint* sys_joint); + void RecursiveKinematics(); + void RecursiveTriangularization(); + void RecursiveForwardSubstitution(); + Mat3x3 GetN_C_K(); + Vect3 LocalCart(); + int GetBodyID(); + void CalculateAcceleration(); + void Setup(); + void SetupInertialFrame(); + void LocalKinematics(); + void LocalTriangularization(Vect3& Torque, Vect3& Force); + void LocalForwardSubstitution(); }; - +} #endif diff --git a/lib/poems/onfunctions.cpp b/lib/poems/onfunctions.cpp index 1d91dbf378..cfc0c60936 100644 --- a/lib/poems/onfunctions.cpp +++ b/lib/poems/onfunctions.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: onfunction.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,10 +11,10 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #include "onfunctions.h" @@ -25,9 +25,11 @@ #include "virtualmatrix.h" using namespace std; +using namespace POEMS; + // friend of Vect3 & Vect6 -void OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV){ +void POEMS::OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV){ sV.elements[0] = angular.elements[0]; sV.elements[1] = angular.elements[1]; sV.elements[2] = angular.elements[2]; @@ -37,38 +39,38 @@ void OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV){ } // friend of Vect3, Mat3x3, & Mat6x6 -void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC){ +void POEMS::OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC){ // the block diagonals - + // the gamma cross with transform Mat3x3 temp; Mat3x3 temp2; SC.Zeros(); - temp.Zeros(); + temp.Zeros(); temp2.Zeros(); - //FastTMult(C,gamma,temp); + //FastTMult(C,gamma,temp); temp(1,2)= -gamma(3); temp(1,3)= gamma(2); temp(2,1)= gamma(3); - temp(2,3)= -gamma(1); temp(3,1)= -gamma(2); temp(3,2)= gamma(1); + temp(2,3)= -gamma(1); temp(3,1)= -gamma(2); temp(3,2)= gamma(1); FastMult(temp,C,temp2); - + SC(1,4)=temp2(1,1); SC(2,4)=temp2(2,1); SC(3,4)=temp2(3,1); SC(1,5)=temp2(1,2); SC(2,5)=temp2(2,2); SC(3,5)=temp2(3,2); SC(1,6)=temp2(1,3); SC(2,6)=temp2(2,3); SC(3,6)=temp2(3,3); - + SC(1,1)=C(1,1); SC(2,1)=C(2,1); SC(3,1)=C(3,1); SC(1,2)=C(1,2); SC(2,2)=C(2,2); SC(3,2)=C(3,2); SC(1,3)=C(1,3); SC(2,3)=C(2,3); SC(3,3)=C(3,3); SC(4,4)=C(1,1); SC(5,4)=C(2,1); SC(6,4)=C(3,1); SC(4,5)=C(1,2); SC(5,5)=C(2,2); SC(6,5)=C(3,2); - SC(4,6)=C(1,3); SC(5,6)=C(2,3); SC(6,6)=C(3,3); - + SC(4,6)=C(1,3); SC(5,6)=C(2,3); SC(6,6)=C(3,3); + } // friend of Mat3x3 & Mat6x6 -void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI){ - - sI(4,4)=mass; sI(5,5)=mass; sI(6,6)=mass; - sI(1,1)=inertia(1,1); sI(1,2)=inertia(1,2); sI(1,3)=inertia(1,3); - sI(2,1)=inertia(2,1); sI(2,2)=inertia(2,2); sI(2,3)=inertia(2,3); - sI(3,1)=inertia(3,1); sI(3,2)=inertia(3,2); sI(3,3)=inertia(3,3); +void POEMS::OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI){ + + sI(4,4)=mass; sI(5,5)=mass; sI(6,6)=mass; + sI(1,1)=inertia(1,1); sI(1,2)=inertia(1,2); sI(1,3)=inertia(1,3); + sI(2,1)=inertia(2,1); sI(2,2)=inertia(2,2); sI(2,3)=inertia(2,3); + sI(3,1)=inertia(3,1); sI(3,2)=inertia(3,2); sI(3,3)=inertia(3,3); } diff --git a/lib/poems/onfunctions.h b/lib/poems/onfunctions.h index 42d0f4ac1c..bb07425b85 100644 --- a/lib/poems/onfunctions.h +++ b/lib/poems/onfunctions.h @@ -18,6 +18,7 @@ #ifndef ONFUNCTIONS_H #define ONFUNCTIONS_H +namespace POEMS { class Mat3x3; class Mat6x6; class Vect3; @@ -30,5 +31,5 @@ void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI); void Create_Map(int MM); int ICELL(int IX,int IY,int IZ, int MM); - +} #endif diff --git a/lib/poems/onsolver.cpp b/lib/poems/onsolver.cpp index dd94c9c7ad..609ef32613 100644 --- a/lib/poems/onsolver.cpp +++ b/lib/poems/onsolver.cpp @@ -33,6 +33,8 @@ #include "virtualmatrix.h" using namespace std; +using namespace POEMS; + OnSolver::OnSolver(){ numbodies = 0; diff --git a/lib/poems/onsolver.h b/lib/poems/onsolver.h index b4bbd5e25d..1e850b8fc1 100644 --- a/lib/poems/onsolver.h +++ b/lib/poems/onsolver.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: onsolver.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -22,32 +22,31 @@ #include "solver.h" #include "onbody.h" +namespace POEMS { class ColMatrix; class Matrix; - - class OnSolver : public Solver { - OnBody inertialframe; - int numbodies; - OnBody** bodyarray; - ColMatrix** q; - ColMatrix** qdot; - ColMatrix** qdotdot; - ColMatrix** u; - ColMatrix** udot; - - - - void DeleteModel(); - int CreateTopologyArray(int i, OnBody* body); - void CreateStateMatrixMaps(); - void GetType(); -public: - OnSolver(); - ~OnSolver(); - void CreateModel(); - void Solve(double time, Matrix& FF); -}; + OnBody inertialframe; + int numbodies; + OnBody** bodyarray; + ColMatrix** q; + ColMatrix** qdot; + ColMatrix** qdotdot; + ColMatrix** u; + ColMatrix** udot; + + + void DeleteModel(); + int CreateTopologyArray(int i, OnBody* body); + void CreateStateMatrixMaps(); + void GetType(); +public: + OnSolver(); + ~OnSolver(); + void CreateModel(); + void Solve(double time, Matrix& FF); +}; +} #endif diff --git a/lib/poems/particle.cpp b/lib/poems/particle.cpp index 0d953e00f6..37ec790666 100644 --- a/lib/poems/particle.cpp +++ b/lib/poems/particle.cpp @@ -18,6 +18,8 @@ #include "particle.h" +using namespace POEMS; + Particle::Particle(){ } diff --git a/lib/poems/particle.h b/lib/poems/particle.h index 0f13252f99..8a7a521451 100644 --- a/lib/poems/particle.h +++ b/lib/poems/particle.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: particle.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -23,14 +23,14 @@ #include "body.h" - +namespace POEMS { class Particle : public Body { -public: +public: Particle(); ~Particle(); BodyType GetType(); bool ReadInBodyData(std::istream& in); void WriteOutBodyData(std::ostream& out); }; - +} #endif diff --git a/lib/poems/poemslist.h b/lib/poems/poemslist.h index 9882af013a..bd0c1456b4 100644 --- a/lib/poems/poemslist.h +++ b/lib/poems/poemslist.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: poemslist.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,8 +21,7 @@ #include #include -using namespace std; - +namespace POEMS { template class ListElement{ public: ListElement* prev; @@ -51,7 +50,7 @@ public: S* operator()(int id); void Append(List * listToAppend); void DeleteValues(); - void RemoveElementAndDeleteValue(ListElement* ele); + void RemoveElementAndDeleteValue(ListElement* ele); void PrintList(); }; @@ -90,9 +89,9 @@ template List::~List(){ template void List::Append(List * listToAppend) { - tail->next = listToAppend->head; - listToAppend->head->prev = tail; - tail = listToAppend->tail; + tail->next = listToAppend->head; + listToAppend->head->prev = tail; + tail = listToAppend->tail; } template int List::GetNumElements(){ @@ -104,17 +103,17 @@ template ListElement* List::GetHeadElement(){ } template ListElement* List::GetTailElement(){ - return tail; + return tail; } template void List::Remove(ListElement* ele){ if(!ele){ - cerr << "ERROR: ListElement to be removed not defined" << endl; + std::cerr << "ERROR: ListElement to be removed not defined" << std::endl; exit(0); } if(!numelements){ - cerr << "ERROR: List is empty" << endl; + std::cerr << "ERROR: List is empty" << std::endl; exit(0); } @@ -135,7 +134,7 @@ template void List::Remove(ListElement* ele){ template ListElement* List::Append(S* v){ if(!v){ - cerr << "ERROR: cannot add null Body to list" << endl; + std::cerr << "ERROR: cannot add null Body to list" << std::endl; exit(0); } @@ -145,22 +144,22 @@ template ListElement* List::Append(S* v){ if(numelements==1) head = tail = ele; else{ - /* + /* tail->next = ele; ele->prev = tail; - tail = ele;*/ - - ele->prev = tail; - tail = ele; - ele->prev->next = ele; - - } + tail = ele;*/ + + ele->prev = tail; + tail = ele; + ele->prev->next = ele; + + } return ele; } template ListElement* List::Prepend(S* v){ if(!v){ - cerr << "ERROR: cannot add null Body to list" << endl; + std::cerr << "ERROR: cannot add null Body to list" << std::endl; exit(0); } @@ -170,9 +169,9 @@ template ListElement* List::Prepend(S* v){ if(numelements==1) head = tail = ele; else{ - ele->next = head; - head = ele; - ele->next->prev = ele; + ele->next = head; + head = ele; + ele->next->prev = ele; } return ele; } @@ -190,15 +189,15 @@ template S** List::CreateArray(){ template S* List::operator()(int id){ if(id >= numelements){ - cerr << "ERROR: subscript out of bounds" << endl; + std::cerr << "ERROR: subscript out of bounds" << std::endl; exit(0); } - + ListElement* ele = head; for(int i=0;inext; } - + return ele->value; } @@ -214,16 +213,15 @@ template void List::RemoveElementAndDeleteValue(ListElement* ele) } template void List::PrintList(){ - cout<<"Printing List "<* ele = head; - cout<<*(ele->value)<<" "; - ele = ele->next; - for(int k =2; kvalue)<<" "; - ele = ele->next; - } - cout<<*(ele->value)<* ele = head; + std::cout << *(ele->value) << " "; + ele = ele->next; + for(int k =2; kvalue) << " "; + ele = ele->next; + } + std::cout << *(ele->value) << std::endl; +} } - - #endif diff --git a/lib/poems/poemsnodelib.h b/lib/poems/poemsnodelib.h index 06cf4530d2..d323b701b0 100644 --- a/lib/poems/poemsnodelib.h +++ b/lib/poems/poemsnodelib.h @@ -20,9 +20,7 @@ #include -using namespace std; - - +namespace POEMS { TreeNode *GetTreeNode(int item,TreeNode *lptr = NULL,TreeNode *rptr =NULL); void FreeTreeNode(TreeNode *p); @@ -81,7 +79,7 @@ TreeNode *GetTreeNode(int item,TreeNode *lptr,TreeNode *rptr) // if insufficient memory, terminatewith an error message if (p == NULL) { - cerr << "Memory allocation failure!\n"; + std::cerr << "Memory allocation failure!\n"; exit(1); } @@ -140,7 +138,7 @@ void IndentBlanks(int num) // const int indentblock = 6; for(int i = 0; i < num; i++) - cout << " "; + std::cout << " "; } void PrintTree (TreeNode *t, int level) @@ -153,10 +151,11 @@ void PrintTree (TreeNode *t, int level) PrintTree(t->Right(),level + 1); // indent to current level; output node data IndentBlanks(indentUnit*level); - cout << t->GetData() << endl; + std::cout << t->GetData() << std::endl; // print left branch of tree t PrintTree(t->Left(),level + 1); } } +} #endif diff --git a/lib/poems/poemsobject.cpp b/lib/poems/poemsobject.cpp index 7c3f1ca872..dfdd95953e 100644 --- a/lib/poems/poemsobject.cpp +++ b/lib/poems/poemsobject.cpp @@ -19,6 +19,8 @@ #include "poemsobject.h" #include +using namespace POEMS; + POEMSObject::POEMSObject(){ name = 0; ChangeName((const char*)"unnamed"); diff --git a/lib/poems/poemsobject.h b/lib/poems/poemsobject.h index 63b2915638..173d9da7ab 100644 --- a/lib/poems/poemsobject.h +++ b/lib/poems/poemsobject.h @@ -19,7 +19,7 @@ #ifndef POEMSOBJECT_H #define POEMSOBJECT_H - +namespace POEMS { class POEMSObject { char* name; int ID; @@ -31,5 +31,5 @@ public: int GetID(); void SetID(int id); }; - +} #endif diff --git a/lib/poems/poemstree.h b/lib/poems/poemstree.h index 8f8e80ab66..d49a0d0a88 100644 --- a/lib/poems/poemstree.h +++ b/lib/poems/poemstree.h @@ -21,7 +21,7 @@ #include "poemstreenode.h" #include "poemsnodelib.h" - +namespace POEMS { // constants to indicate the balance factor of a node const int leftheavy = -1; const int balanced = 0; @@ -609,5 +609,5 @@ void Tree::ClearList(void) delete current; size = 0; } - +} #endif diff --git a/lib/poems/poemstreenode.cpp b/lib/poems/poemstreenode.cpp index 051e13d6e0..ca4307f69f 100644 --- a/lib/poems/poemstreenode.cpp +++ b/lib/poems/poemstreenode.cpp @@ -17,6 +17,8 @@ #include "poemstreenode.h" +using namespace POEMS; + // constructor; initialize the data and pointer fields // The pointer value NULL assigns a empty subtree TreeNode::TreeNode (const int & item, TreeNode *lptr,TreeNode *rptr, diff --git a/lib/poems/poemstreenode.h b/lib/poems/poemstreenode.h index e22bd9b97d..69f3caf958 100644 --- a/lib/poems/poemstreenode.h +++ b/lib/poems/poemstreenode.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: poemstreenode.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,36 +11,37 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef TREENODE_H #define TREENODE_H +namespace POEMS { // declares a tree node object for a binary tree class TreeNode{ private: // points to the left and right children of the node - TreeNode *left; - TreeNode *right; + TreeNode *left; + TreeNode *right; - int balanceFactor; - int data; - void * aux_data; -public: - // make Tree a friend because it needs access to left and right pointer fields of a node - friend class Tree; - TreeNode * Left(); - TreeNode * Right(); - int GetData(); - void * GetAuxData() {return aux_data;}; - void SetAuxData(void * AuxData) {aux_data = AuxData;}; - int GetBalanceFactor(); - TreeNode(const int &item, TreeNode *lptr, TreeNode *rptr, int balfac = 0); - //friend class DCASolver; + int balanceFactor; + int data; + void * aux_data; +public: + // make Tree a friend because it needs access to left and right pointer fields of a node + friend class Tree; + TreeNode * Left(); + TreeNode * Right(); + int GetData(); + void * GetAuxData() {return aux_data;}; + void SetAuxData(void * AuxData) {aux_data = AuxData;}; + int GetBalanceFactor(); + TreeNode(const int &item, TreeNode *lptr, TreeNode *rptr, int balfac = 0); + //friend class DCASolver; }; - +} #endif diff --git a/lib/poems/point.cpp b/lib/poems/point.cpp index d7eed94efd..f648b58d3d 100644 --- a/lib/poems/point.cpp +++ b/lib/poems/point.cpp @@ -20,6 +20,8 @@ #include "point.h" #include "vect3.h" +using namespace POEMS; + Point::Point(){ position.Zeros(); } @@ -35,7 +37,7 @@ void Point::WriteOut(std::ostream& out){ WriteOutPointData(out); } -Point* NewPoint(int type){ +Point* POEMS::NewPoint(int type){ switch( PointType(type) ) { case FIXEDPOINT : // A Fixed Point diff --git a/lib/poems/point.h b/lib/poems/point.h index 746a527cd7..c08e92db0d 100644 --- a/lib/poems/point.h +++ b/lib/poems/point.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: point.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -22,21 +22,21 @@ #include "poemsobject.h" #include "vect3.h" - +namespace POEMS { // emumerated type enum PointType { FIXEDPOINT = 0 }; class Point : public POEMSObject { -public: +public: Vect3 position; - Point(); - bool ReadIn(std::istream& in); + Point(); + bool ReadIn(std::istream& in); void WriteOut(std::ostream& out); - - virtual ~Point(); + + virtual ~Point(); virtual PointType GetType() = 0; virtual Vect3 GetPoint() = 0; virtual bool ReadInPointData(std::istream& in) = 0; @@ -45,5 +45,5 @@ public: // global point functions Point* NewPoint(int type); - +} #endif diff --git a/lib/poems/prismaticjoint.cpp b/lib/poems/prismaticjoint.cpp index c7d4bed568..3e649f0d22 100644 --- a/lib/poems/prismaticjoint.cpp +++ b/lib/poems/prismaticjoint.cpp @@ -25,6 +25,8 @@ #include "mat3x3.h" #include "virtualmatrix.h" +using namespace POEMS; + PrismaticJoint::PrismaticJoint(){ q.Dim(1); qdot.Dim(1); diff --git a/lib/poems/prismaticjoint.h b/lib/poems/prismaticjoint.h index c17be350cb..df3ab3195c 100644 --- a/lib/poems/prismaticjoint.h +++ b/lib/poems/prismaticjoint.h @@ -24,8 +24,7 @@ #include "vect3.h" #include "matrix.h" - - +namespace POEMS { class PrismaticJoint : public Joint { Vect3 axis_pk; // unit vector in body1 basis Vect3 axis_k; // unit vector in body2 basis @@ -45,5 +44,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; - +} #endif diff --git a/lib/poems/revolutejoint.cpp b/lib/poems/revolutejoint.cpp index 955a2f0dea..6b11acbf0f 100644 --- a/lib/poems/revolutejoint.cpp +++ b/lib/poems/revolutejoint.cpp @@ -25,6 +25,8 @@ #include "mat3x3.h" #include "virtualmatrix.h" +using namespace POEMS; + RevoluteJoint::RevoluteJoint(){ DimQandU(1); Vect3 axis; diff --git a/lib/poems/revolutejoint.h b/lib/poems/revolutejoint.h index ac1c06d5c5..10a38114df 100644 --- a/lib/poems/revolutejoint.h +++ b/lib/poems/revolutejoint.h @@ -23,6 +23,7 @@ #include "vect3.h" #include "matrix.h" +namespace POEMS { class VirtualMatrix; class RevoluteJoint : public Joint { @@ -44,5 +45,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; - +} #endif diff --git a/lib/poems/rigidbody.cpp b/lib/poems/rigidbody.cpp index 53acfa8bd4..a7d4f9f19f 100644 --- a/lib/poems/rigidbody.cpp +++ b/lib/poems/rigidbody.cpp @@ -20,6 +20,8 @@ #include "virtualmatrix.h" using namespace std; +using namespace POEMS; + RigidBody::RigidBody(){ } diff --git a/lib/poems/rigidbody.h b/lib/poems/rigidbody.h index 2f4430e264..d4be92ebcf 100644 --- a/lib/poems/rigidbody.h +++ b/lib/poems/rigidbody.h @@ -22,6 +22,7 @@ #include "body.h" +namespace POEMS { class RigidBody : public Body { public: RigidBody(); @@ -30,5 +31,5 @@ public: bool ReadInBodyData(std::istream& in); void WriteOutBodyData(std::ostream& out); }; - +} #endif diff --git a/lib/poems/rowmatrix.cpp b/lib/poems/rowmatrix.cpp index 9fa57e773f..eac8fbef5d 100644 --- a/lib/poems/rowmatrix.cpp +++ b/lib/poems/rowmatrix.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + RowMatrix::RowMatrix(){ numcols = 0; diff --git a/lib/poems/rowmatrix.h b/lib/poems/rowmatrix.h index 1dbb3d11e0..8e8d7b5f99 100644 --- a/lib/poems/rowmatrix.h +++ b/lib/poems/rowmatrix.h @@ -24,6 +24,7 @@ #include "virtualrowmatrix.h" #include "virtualmatrix.h" +namespace POEMS { class RowMatrix : public VirtualRowMatrix { double* elements; public: @@ -52,5 +53,5 @@ public: RowMatrix& operator=(const VirtualMatrix& A); // overloaded = RowMatrix& operator*=(double b); }; - +} #endif diff --git a/lib/poems/solver.cpp b/lib/poems/solver.cpp index 9d2245149f..04afb27945 100644 --- a/lib/poems/solver.cpp +++ b/lib/poems/solver.cpp @@ -20,6 +20,8 @@ #include "system.h" #include "onsolver.h" +using namespace POEMS; + Solver::Solver(){ } diff --git a/lib/poems/solver.h b/lib/poems/solver.h index 6a2debf497..489e6d41f1 100644 --- a/lib/poems/solver.h +++ b/lib/poems/solver.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: solver.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,6 +21,7 @@ #include "colmatmap.h" #include "defines.h" +namespace POEMS { class System; class Matrix; @@ -28,11 +29,11 @@ class Solver{ protected: System* system; - + double time; ColMatMap state; ColMatMap statedot; - ColMatMap statedoubledot; + ColMatMap statedoubledot; SolverType type; @@ -47,13 +48,13 @@ public: virtual void DeleteModel() = 0; virtual void CreateModel() = 0; - virtual void Solve(double time, Matrix& FF) = 0; - - - + virtual void Solve(double time, Matrix& FF) = 0; + + + ColMatMap* GetState(); ColMatMap* GetStateDerivative(); ColMatMap* GetStateDerivativeDerivative(); }; - +} #endif diff --git a/lib/poems/sphericaljoint.cpp b/lib/poems/sphericaljoint.cpp index cba6d00a6e..996bb5a887 100644 --- a/lib/poems/sphericaljoint.cpp +++ b/lib/poems/sphericaljoint.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: sphericaljoint.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,10 +11,10 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #include "sphericaljoint.h" @@ -30,6 +30,8 @@ #include "vect3.h" #include "virtualmatrix.h" +using namespace std; +using namespace POEMS; SphericalJoint::SphericalJoint(){ DimQandU(4,3); @@ -48,24 +50,24 @@ bool SphericalJoint::ReadInJointData(std::istream& in){ void SphericalJoint::WriteOutJointData(std::ostream& out){ } -Matrix SphericalJoint::GetForward_sP(){ +Matrix SphericalJoint::GetForward_sP(){ Mat3x3 sPa,sPl; Matrix sP(6,3); - sPa.Identity(); + sPa.Identity(); sPl.Zeros(); - Vect3 temp = -(point2->position); - + Vect3 temp = -(point2->position); + sPl(1,2) = temp(3); sPl(1,3) = -temp(2); - + sPl(2,1) = -temp(3); sPl(2,3) = temp(1); - - sPl(3,1) = temp(2); + + sPl(3,1) = temp(2); sPl(3,2) = -temp(1); - - sP=Stack(sPa,sPl); - return sP; + + sP=Stack(sPa,sPl); + return sP; } void SphericalJoint::UpdateForward_sP( Matrix& sP){ @@ -79,15 +81,15 @@ Matrix SphericalJoint::GetBackward_sP(){ cout<<" -----------"<position(1)); - sPl(2,3)=-(point2->position(1)); + sPa.Identity(); + sPl.Zeros(); + sPl(3,2)=(point2->position(1)); + sPl(2,3)=-(point2->position(1)); sP=Stack(sPa,sPl); - return sP; + return sP; } -void SphericalJoint::UpdateBackward_sP( Matrix& sP){ +void SphericalJoint::UpdateBackward_sP( Matrix& sP){ // sP is constant, do nothing. } @@ -96,106 +98,106 @@ void SphericalJoint::ComputeLocalTransform(){ // Obtain the transformation matrix from euler parameters EP_Transformation(q, ko_C_k); FastMult(pk_C_ko,ko_C_k,pk_C_k); - } + } void SphericalJoint::ForwardKinematics(){ Vect3 result1,result2,result3,result4,result5; Vect3 pk_w_k; - + //cout<<"Check in spherical "<position,result1); // parents basis - FastAdd(result1,point1->position,r12); - - // compute position vector r21 - FastNegMult(k_C_pk,r12,r21); + // COMPUTE POSITION VECTOR R12 aka GAMMA + + FastNegMult(pk_C_k,point2->position,result1); // parents basis + FastAdd(result1,point1->position,r12); + + // compute position vector r21 + FastNegMult(k_C_pk,r12,r21); + + - - //----------------------------------// - // COMPUTE GLOBAL LOCATION - FastMult(body1->n_C_k,(body1->GetPoint(2))->position,result1); - FastAdd(result1,body1->r,result1); - FastNegMult(body2->n_C_k,(body2->GetPoint(1))->position,result2); - FastAdd(result1,result2,body2->r); - - qdot_to_u(q, u, qdot); - + // COMPUTE GLOBAL LOCATION + FastMult(body1->n_C_k,(body1->GetPoint(2))->position,result1); + FastAdd(result1,body1->r,result1); + FastNegMult(body2->n_C_k,(body2->GetPoint(1))->position,result2); + FastAdd(result1,result2,body2->r); + + qdot_to_u(q, u, qdot); + + + //----------------------------------- + // angular velocities - //----------------------------------- - // angular velocities - FastAssign(u,pk_w_k); - FastTMult(pk_C_k,body1->omega_k,result1); + FastTMult(pk_C_k,body1->omega_k,result1); FastAdd(result1,pk_w_k,body2->omega_k); - FastMult(body2->n_C_k,body2->omega_k,body2->omega); + FastMult(body2->n_C_k,body2->omega_k,body2->omega); - - - //----------------------------------- - - // compute velocities - FastCross(body1->omega_k,(body1->GetPoint(2))->position,result1); + + + //----------------------------------- + + // compute velocities + FastCross(body1->omega_k,(body1->GetPoint(2))->position,result1); FastAdd(body1->v_k,result1,result2); - FastTMult(pk_C_k,result2,result1); // In body basis - - FastCross((body2->GetPoint(1))->position,body2->omega_k,result2); - FastAdd(result1,result2,body2->v_k); // In body basis - FastMult(body2->n_C_k,body2->v_k,body2->v); - - + FastTMult(pk_C_k,result2,result1); // In body basis + + FastCross((body2->GetPoint(1))->position,body2->omega_k,result2); + FastAdd(result1,result2,body2->v_k); // In body basis + FastMult(body2->n_C_k,body2->v_k,body2->v); + + //------------------------------------------ - //Compute the KE + //Compute the KE Matrix tempke; - tempke = T(body2->v)*(body2->v); + tempke = T(body2->v)*(body2->v); double ke = 0.0; - ke = body2->mass*tempke(1,1); + ke = body2->mass*tempke(1,1); FastMult(body2->inertia,body2->omega_k,result1); - tempke= T(body2->omega_k)*result1; + tempke= T(body2->omega_k)*result1; ke = 0.5*ke + 0.5*tempke(1,1); body2->KE=ke; - //----------------------------------- - // compute state explicit angular acceleration // Has to be in body basis - FastTMult(pk_C_k,body1->alpha_t,result2); + //----------------------------------- + // compute state explicit angular acceleration // Has to be in body basis + FastTMult(pk_C_k,body1->alpha_t,result2); FastCross(body2->omega_k,pk_w_k,result1); - FastAdd(result1,result2,body2->alpha_t); - - //----------------------------------- - // compute state explicit acceleration - // NEED TO DO THIS COMPLETELY IN BODY BASIS - + FastAdd(result1,result2,body2->alpha_t); + + //----------------------------------- + // compute state explicit acceleration + // NEED TO DO THIS COMPLETELY IN BODY BASIS + FastCross(body1->omega_k,(body1->GetPoint(2))->position,result1); - FastCross(body1->omega_k,result1,result2); - FastTMult(pk_C_k,result2,result1); - - //FastCross(body2->omega_k,-(body2->GetPoint(1))->position,result3); - FastCross((body2->GetPoint(1))->position,body2->omega_k,result3); - FastCross(body2->omega_k,result3,result2); - FastAdd(result1,result2,result3); //wxwxr in body basis - - FastCross(body1->alpha_t,(body1->GetPoint(2))->position,result4); - FastTMult(pk_C_k,result4,result5); + FastCross(body1->omega_k,result1,result2); + FastTMult(pk_C_k,result2,result1); + + //FastCross(body2->omega_k,-(body2->GetPoint(1))->position,result3); + FastCross((body2->GetPoint(1))->position,body2->omega_k,result3); + FastCross(body2->omega_k,result3,result2); + FastAdd(result1,result2,result3); //wxwxr in body basis + + FastCross(body1->alpha_t,(body1->GetPoint(2))->position,result4); + FastTMult(pk_C_k,result4,result5); FastAssign(result5,result4); - - FastCross((body2->GetPoint(1))->position,body2->alpha_t,result2); - FastAdd(result2,result4,result1); //alphaxr in body basis - + + FastCross((body2->GetPoint(1))->position,body2->alpha_t,result2); + FastAdd(result2,result4,result1); //alphaxr in body basis + FastTMult(pk_C_k,body1->a_t,result2); - FastTripleSum(result3,result1,result2,body2->a_t); // in body basis - - - //----------------------------------- + FastTripleSum(result3,result1,result2,body2->a_t); // in body basis + + + //----------------------------------- } // NOTE: NOT USING BACKWARDKINEMATICS AT PRESENT @@ -206,13 +208,13 @@ void SphericalJoint::BackwardKinematics(){ // orientations ComputeBackwardTransforms(); - + // compute position vector r21 //r21 = point2->position - k_C_pk * point1->position; FastMult(k_C_pk,point1->position,result1); FastSubt(point2->position,result1,r21); - + // compute position vector r21 FastNegMult(pk_C_k,r21,r12); @@ -231,7 +233,7 @@ void SphericalJoint::BackwardKinematics(){ EP_Derivatives(q,u,qdot); // angular velocities - + FastMult(body2->n_C_k,u,result2); FastAdd(body2->omega,result2,body1->omega); FastAssign(u,k_w_pk); @@ -251,7 +253,7 @@ void SphericalJoint::BackwardKinematics(){ FastCross(body1->omega_k,k_w_pk,result1); FastMult(pk_C_k,body2->alpha_t,result2); FastAdd(result1,result2,body1->alpha_t); - + // compute state explicit acceleration FastCross(body2->alpha_t,point2->position,result1); FastCross(body2->omega_k,point2->position,result2); @@ -264,5 +266,5 @@ void SphericalJoint::BackwardKinematics(){ FastCross(body1->omega_k,result2,result3); FastTripleSum(result5,result1,result3,body1->a_t); - + } diff --git a/lib/poems/sphericaljoint.h b/lib/poems/sphericaljoint.h index 90f1547873..db048e5544 100644 --- a/lib/poems/sphericaljoint.h +++ b/lib/poems/sphericaljoint.h @@ -22,6 +22,7 @@ #include "joint.h" #include "matrix.h" +namespace POEMS { class SphericalJoint : public Joint { Matrix const_sP; public: @@ -38,5 +39,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; - +} #endif diff --git a/lib/poems/system.cpp b/lib/poems/system.cpp index 1ac9ce1236..8515588424 100644 --- a/lib/poems/system.cpp +++ b/lib/poems/system.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: system.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -36,11 +36,12 @@ #include "vect3.h" #include "virtualmatrix.h" -class Point; - +namespace POEMS { class Point; } +using namespace std; +using namespace POEMS; System::System(){ - mappings = NULL; + mappings = NULL; } System::~System(){ @@ -59,7 +60,7 @@ int System::GetNumBodies(){ int * System::GetMappings() { - return mappings; + return mappings; } void System::AddBody(Body* body){ @@ -78,16 +79,16 @@ double System::GetTime(){ return time; } -void System::ComputeForces(){ - // NOT DOING ANYTHING AT THIS TIME - } - +void System::ComputeForces(){ + // NOT DOING ANYTHING AT THIS TIME + } + bool System::ReadIn(istream& in){ int numbodies; Body* body; int bodytype; char bodyname[256]; - int index; + int index; // get number of bodies in >> numbodies; @@ -165,12 +166,12 @@ bool System::ReadIn(istream& in){ delete [] bodyarray; return false; } - + joint->SetBodies(bodyarray[body1], bodyarray[body2]); bodyarray[body1]->AddJoint(joint); bodyarray[body2]->AddJoint(joint); - + in >> point1 >> point2; joint->SetPoints(bodyarray[body1]->GetPoint(point1),bodyarray[body2]->GetPoint(point2)); @@ -203,7 +204,7 @@ void System::WriteOut(ostream& out){ // set the body ID for later identification body->SetID(i); - + // write out the data body->WriteOut(out); @@ -211,7 +212,7 @@ void System::WriteOut(ostream& out){ } // number of joints - out << joints.GetNumElements() << endl; + out << joints.GetNumElements() << endl; // joints loop i = 0; @@ -226,7 +227,7 @@ void System::WriteOut(ostream& out){ // write out the data joint->WriteOut(out); - + i++; j_ele = j_ele->next; } } @@ -252,68 +253,68 @@ void System::ClearJointIDs(){ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space){ - //-------------------------------------------------------------------------// - // Declaring Temporary Entities - //-------------------------------------------------------------------------// + //-------------------------------------------------------------------------// + // Declaring Temporary Entities + //-------------------------------------------------------------------------// Body* body = NULL; Body* prev; Body* Inertial; Point* origin; Joint* joint; - Point* point_CM; - Point* point_p; - Point* point_k; + Point* point_CM; + Point* point_p; + Point* point_k; Point* point_ch = NULL; - Vect3 r1,r2,r3,v1,v2,v3; + Vect3 r1,r2,r3,v1,v2,v3; Mat3x3 IM, N, PKCK,PKCN ; ColMatrix qo, uo, q, qdot,w; - - mappings = new int[nfree]; - for(int i = 0; i < nfree; i++) - { - mappings[i] = freelist[i]; - } + + mappings = new int[nfree]; + for(int i = 0; i < nfree; i++) + { + mappings[i] = freelist[i]; + } qo.Dim(4); uo.Dim(3); q.Dim(4); - qdot.Dim(4); + qdot.Dim(4); PKCN.Identity(); PKCK.Identity(); w.Dim(3); - -//-------------------------------------------------------------------------// - // Setting up Inertial Frame, gravity and Origin - //-------------------------------------------------------------------------// - Inertial= new InertialFrame; - AddBody(Inertial); - - Vect3 temp1; - temp1.Zeros(); - ((InertialFrame*) Inertial)->SetGravity(temp1); - origin= new FixedPoint(temp1); - Inertial->AddPoint(origin); + +//-------------------------------------------------------------------------// + // Setting up Inertial Frame, gravity and Origin + //-------------------------------------------------------------------------// + Inertial= new InertialFrame; + AddBody(Inertial); + + Vect3 temp1; + temp1.Zeros(); + ((InertialFrame*) Inertial)->SetGravity(temp1); + origin= new FixedPoint(temp1); + Inertial->AddPoint(origin); +//-------------------------------------------------------------------------// + double ** xh1 = new double*[nfree]; + double ** xh2 = new double*[nfree]; + + for (int i=0; imass=masstotal[mappings[i]-1]; IM(1,1)=inertia[mappings[i]-1][0]; IM(2,2)=inertia[mappings[i]-1][1]; @@ -324,49 +325,49 @@ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstota IM(2,1)=IM(1,2); IM(3,1)=IM(1,3); IM(3,2)=IM(2,3); - body->inertia = IM; + body->inertia = IM; + +//-------------------------------------------------------// + + + for (int k=0;k<3;k++){ + r1(k+1)=xh1[i][k]-xcm[mappings[i]-1][k]; + r3(k+1) = xcm[mappings[i]-1][k]; + r3(k+1)=xh2[i][k]-xcm[mappings[i]-1][k]; + } + + r2.Zeros(); + + for (int k=1;k<=3;k++){ + N(k,1)=ex_space[mappings[i]-1][k-1]; + N(k,2)=ey_space[mappings[i]-1][k-1]; + N(k,3)=ez_space[mappings[i]-1][k-1]; + } -//-------------------------------------------------------// - - - for (int k=0;k<3;k++){ - r1(k+1)=xh1[i][k]-xcm[mappings[i]-1][k]; - r3(k+1) = xcm[mappings[i]-1][k]; - r3(k+1)=xh2[i][k]-xcm[mappings[i]-1][k]; - } - - r2.Zeros(); - - for (int k=1;k<=3;k++){ - N(k,1)=ex_space[mappings[i]-1][k-1]; - N(k,2)=ey_space[mappings[i]-1][k-1]; - N(k,3)=ez_space[mappings[i]-1][k-1]; - } - PKCK=T(N); PKCN=T(N); - - q.Zeros(); + + q.Zeros(); EP_FromTransformation(q,N); - + r1=PKCN*r1; r3=PKCN*r3; - + for (int k=1;k<=3;k++){ - w(k)=omega[mappings[i]-1][k-1]; - } - + w(k)=omega[mappings[i]-1][k-1]; + } + Vect3 cart_r, cart_v; for (int k=1;k<=3;k++){ - cart_r(k)=xcm[mappings[i]-1][k-1]; - cart_v(k)=vcm[mappings[i]-1][k-1]; - } - - w=PKCN*w; - EP_Derivatives(q,w,qdot); - - -//-------------------------------------------------------------------------// + cart_r(k)=xcm[mappings[i]-1][k-1]; + cart_v(k)=vcm[mappings[i]-1][k-1]; + } + + w=PKCN*w; + EP_Derivatives(q,w,qdot); + + +//-------------------------------------------------------------------------// // Create bodies and joints with associated properties for POEMS //-------------------------------------------------------------------------// @@ -376,12 +377,12 @@ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstota body->AddPoint(point_CM); body->AddPoint(point_k); body->AddPoint(point_ch); - AddBody(body); - + AddBody(body); + Mat3x3 One; - One.Identity(); - ColMatrix qq=Stack(q,cart_r); - ColMatrix vv=Stack(qdot,cart_v); + One.Identity(); + ColMatrix qq=Stack(q,cart_r); + ColMatrix vv=Stack(qdot,cart_v); joint=new FreeBodyJoint; AddJoint(joint); joint->SetBodies(prev,body); @@ -391,225 +392,225 @@ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstota joint->SetZeroOrientation(One); joint->DimQandU(7,6); joint->SetInitialState(qq,vv); - joint->ForwardKinematics(); + joint->ForwardKinematics(); } for(int i = 0; i < nfree; i++) { - delete [] xh1[i]; - delete [] xh2[i]; + delete [] xh1[i]; + delete [] xh2[i]; } delete [] xh1; - delete [] xh2; + delete [] xh2; } void System::Create_System_LAMMPS(int numbodies, double *mass,double **inertia, double ** xcm, double ** xjoint,double **vcm,double **omega,double **ex_space, double **ey_space, double **ez_space, int b, int * mapping, int count){ - //-------------------------------------------------------------------------// - // Declaring Temporary Entities - //-------------------------------------------------------------------------// - - Body* body = NULL; - Body* prev; - Body* Inertial; - Point* origin; - Joint* joint; - Point* point_CM; - Point* point_p; - Point* point_k; - Point* point_ch = NULL; - Vect3 r1,r2,r3,v1,v2,v3; - Mat3x3 IM, N, PKCK,PKCN ; - ColMatrix qo, uo, q, qdot,w; - Vect3 cart_r, cart_v; - mappings = new int[b]; - for(int i = 0; i < b; i++){ - mappings[i] = mapping[i]; - } - - - qo.Dim(4); - uo.Dim(3); - q.Dim(4); - qdot.Dim(4); - PKCN.Identity(); - PKCK.Identity(); - w.Dim(3); - - //-------------------------------------------------------------------------// - // Setting up Inertial Frame, gravity and Origin - //-------------------------------------------------------------------------// - Inertial= new InertialFrame; - AddBody(Inertial); - - Vect3 temp1; - temp1.Zeros(); - ((InertialFrame*) Inertial)->SetGravity(temp1); - origin= new FixedPoint(temp1); - Inertial->AddPoint(origin); - //-------------------------------------------------------------------------// + //-------------------------------------------------------------------------// + // Declaring Temporary Entities + //-------------------------------------------------------------------------// - double ** xh1; - double ** xh2; - - xh1 = new double*[b]; - xh2 = new double*[b]; - - - for (int i=0; iSetGravity(temp1); + origin= new FixedPoint(temp1); + Inertial->AddPoint(origin); + //-------------------------------------------------------------------------// + + double ** xh1; + double ** xh2; + + xh1 = new double*[b]; + xh2 = new double*[b]; + + + for (int i=0; imass=mass[mapping[i]-1]; - IM(1,1)=inertia[mapping[i]-1][0]; - IM(2,2)=inertia[mapping[i]-1][1]; - IM(3,3)=inertia[mapping[i]-1][2]; - IM(1,2)=0.0; - IM(1,3)=0.0; - IM(2,3)=0.0; - IM(2,1)=IM(1,2); - IM(3,1)=IM(1,3); - IM(3,2)=IM(2,3); - body->inertia = IM; - - //-------------------------------------------------------// - - for (int k=0;k<3;k++){ - r1(k+1)=xh1[i][k]-xcm[mapping[i]-1][k]; - r3(k+1)=xh2[i][k]-xcm[mapping[i]-1][k]; - } - r2.Zeros(); - - for (int k=1;k<=3;k++){ - N(k,1)=ex_space[mapping[i]-1][k-1]; - N(k,2)=ey_space[mapping[i]-1][k-1]; - N(k,3)=ez_space[mapping[i]-1][k-1]; - } - - - if (i==0){ - PKCK=T(N); - PKCN=T(N); - - q.Zeros(); - EP_FromTransformation(q,N); - - r1=PKCN*r1; - r3=PKCN*r3; - - for (int k=1;k<=3;k++){ - w(k)=omega[mappings[i]-1][k-1]; - } - - for (int k=1;k<=3;k++){ - cart_r(k)=xcm[mappings[i]-1][k-1]; - cart_v(k)=vcm[mappings[i]-1][k-1]; - } - w=PKCN*w; - EP_Derivatives(q,w,qdot); - - } - else{ - PKCK=PKCN*N; - PKCN=T(N); - - q.Zeros(); - EP_FromTransformation(q,PKCK); - - r1=PKCN*r1; - r3=PKCN*r3; - - for (int k=1;k<=3;k++){ - w(k)=omega[mapping[i]-1][k-1]-omega[mapping[i-1]-1][k-1]; - } - - w=PKCN*w; - EP_Derivatives(q, w, qdot); - } - - - //-------------------------------------------------------------------------// -// Create bodies and joints with associated properties for POEMS - //-------------------------------------------------------------------------// + //-------------------------------------------------------------------------// + for(int i=0;imass=mass[mapping[i]-1]; + IM(1,1)=inertia[mapping[i]-1][0]; + IM(2,2)=inertia[mapping[i]-1][1]; + IM(3,3)=inertia[mapping[i]-1][2]; + IM(1,2)=0.0; + IM(1,3)=0.0; + IM(2,3)=0.0; + IM(2,1)=IM(1,2); + IM(3,1)=IM(1,3); + IM(3,2)=IM(2,3); + body->inertia = IM; + + //-------------------------------------------------------// + + for (int k=0;k<3;k++){ + r1(k+1)=xh1[i][k]-xcm[mapping[i]-1][k]; + r3(k+1)=xh2[i][k]-xcm[mapping[i]-1][k]; + } + r2.Zeros(); + + for (int k=1;k<=3;k++){ + N(k,1)=ex_space[mapping[i]-1][k-1]; + N(k,2)=ey_space[mapping[i]-1][k-1]; + N(k,3)=ez_space[mapping[i]-1][k-1]; + } + + + if (i==0){ + PKCK=T(N); + PKCN=T(N); + + q.Zeros(); + EP_FromTransformation(q,N); + + r1=PKCN*r1; + r3=PKCN*r3; + + for (int k=1;k<=3;k++){ + w(k)=omega[mappings[i]-1][k-1]; + } + + for (int k=1;k<=3;k++){ + cart_r(k)=xcm[mappings[i]-1][k-1]; + cart_v(k)=vcm[mappings[i]-1][k-1]; + } + w=PKCN*w; + EP_Derivatives(q,w,qdot); + + } + else{ + PKCK=PKCN*N; + PKCN=T(N); + + q.Zeros(); + EP_FromTransformation(q,PKCK); + + r1=PKCN*r1; + r3=PKCN*r3; + + for (int k=1;k<=3;k++){ + w(k)=omega[mapping[i]-1][k-1]-omega[mapping[i-1]-1][k-1]; + } + + w=PKCN*w; + EP_Derivatives(q, w, qdot); + } + + + //-------------------------------------------------------------------------// +// Create bodies and joints with associated properties for POEMS + //-------------------------------------------------------------------------// + + point_CM = new FixedPoint(r2); + point_k = new FixedPoint(r1); + point_ch = new FixedPoint(r3); + body->AddPoint(point_CM); + body->AddPoint(point_k); + body->AddPoint(point_ch); + AddBody(body); + + Mat3x3 One; + One.Identity(); + if (i==0){ + ColMatrix qq=Stack(q,cart_r); + ColMatrix vv=Stack(qdot,cart_v); + joint=new FreeBodyJoint; + AddJoint(joint); + joint->SetBodies(prev,body); + body->AddJoint(joint); + prev->AddJoint(joint); + joint->SetPoints(point_p,point_k); + joint->SetZeroOrientation(One); + joint->DimQandU(7,6); + joint->SetInitialState(qq,vv); + joint->ForwardKinematics(); + } + else{ + joint= new SphericalJoint; + AddJoint(joint); + joint->SetBodies(prev,body); + body->AddJoint(joint); + prev->AddJoint(joint); + joint->SetPoints(point_p,point_k); + joint->SetZeroOrientation(One); + joint->DimQandU(4,3); + joint->SetInitialState(q,qdot); + joint->ForwardKinematics(); + } + } + for(int i = 0; i < b; i++) + { + delete [] xh1[i]; + delete [] xh2[i]; + } + delete [] xh1; + delete [] xh2; - point_CM = new FixedPoint(r2); - point_k = new FixedPoint(r1); - point_ch = new FixedPoint(r3); - body->AddPoint(point_CM); - body->AddPoint(point_k); - body->AddPoint(point_ch); - AddBody(body); - - Mat3x3 One; - One.Identity(); - if (i==0){ - ColMatrix qq=Stack(q,cart_r); - ColMatrix vv=Stack(qdot,cart_v); - joint=new FreeBodyJoint; - AddJoint(joint); - joint->SetBodies(prev,body); - body->AddJoint(joint); - prev->AddJoint(joint); - joint->SetPoints(point_p,point_k); - joint->SetZeroOrientation(One); - joint->DimQandU(7,6); - joint->SetInitialState(qq,vv); - joint->ForwardKinematics(); - } - else{ - joint= new SphericalJoint; - AddJoint(joint); - joint->SetBodies(prev,body); - body->AddJoint(joint); - prev->AddJoint(joint); - joint->SetPoints(point_p,point_k); - joint->SetZeroOrientation(One); - joint->DimQandU(4,3); - joint->SetInitialState(q,qdot); - joint->ForwardKinematics(); - } - } - for(int i = 0; i < b; i++) - { - delete [] xh1[i]; - delete [] xh2[i]; - } - delete [] xh1; - delete [] xh2; - } diff --git a/lib/poems/system.h b/lib/poems/system.h index e5ce27194b..2402e5852f 100644 --- a/lib/poems/system.h +++ b/lib/poems/system.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: system.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -22,6 +22,7 @@ #include #include "poemslist.h" +namespace POEMS { class Body; class Joint; @@ -33,37 +34,37 @@ double time; List bodies; List joints; - + System(); ~System(); void Delete(); - + int GetNumBodies(); - + int * GetMappings(); void AddBody(Body* body); - + void AddJoint(Joint* joint); - + void SetTime(double t); - + double GetTime(); - + void ComputeForces(); - + bool ReadIn(std::istream& in); - + void WriteOut(std::ostream& out); - + void ClearBodyIDs(); - - void ClearJointIDs(); + + void ClearJointIDs(); void Create_System_LAMMPS(int numbodies, double *mass,double **inertia, double ** xcm, double ** xjoint,double **vh1,double **omega,double **ex_space, double **ey_space, double **ez_space, int b, int * mapping, int count); - + void Create_DegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space); }; - +} #endif diff --git a/lib/poems/vect3.cpp b/lib/poems/vect3.cpp index 7ce3230238..66c2f902d5 100644 --- a/lib/poems/vect3.cpp +++ b/lib/poems/vect3.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + Vect3::Vect3(){ numrows = 3; numcols = 1; diff --git a/lib/poems/vect3.h b/lib/poems/vect3.h index a28832db6c..6b0efc371a 100644 --- a/lib/poems/vect3.h +++ b/lib/poems/vect3.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: vect3.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -23,6 +23,7 @@ #include "virtualcolmatrix.h" #include "virtualmatrix.h" +namespace POEMS { class Matrix; class Mat3x3; class Mat6x6; @@ -82,7 +83,6 @@ public: friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); friend void FastAssign(ColMatrix&A, Vect3& C); friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); - }; - +} #endif diff --git a/lib/poems/vect4.cpp b/lib/poems/vect4.cpp index b045998017..8e903d57bd 100644 --- a/lib/poems/vect4.cpp +++ b/lib/poems/vect4.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + Vect4::Vect4(){ numrows = 4; numcols = 1; diff --git a/lib/poems/vect4.h b/lib/poems/vect4.h index 0b28994043..754706f10a 100644 --- a/lib/poems/vect4.h +++ b/lib/poems/vect4.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: vect4.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -23,6 +23,7 @@ #include "virtualcolmatrix.h" #include "virtualmatrix.h" +namespace POEMS { class Matrix; class Mat4x4; @@ -41,7 +42,7 @@ public: void BasicSet_1int(int i, double value); void BasicIncrement_1int(int i, double value); - + void Const(double value); MatrixType GetType() const; std::ostream& WriteData(std::ostream& c) const; @@ -69,5 +70,5 @@ public: friend void FastAdd(Vect4& A, Vect4& B, Vect4& C); friend void FastSubt(Vect4& A, Vect4& B, Vect4& C); }; - +} #endif diff --git a/lib/poems/vect6.cpp b/lib/poems/vect6.cpp index 5baadafc34..5aabe520e1 100644 --- a/lib/poems/vect6.cpp +++ b/lib/poems/vect6.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + Vect6::Vect6(){ numrows = 6; numcols = 1; diff --git a/lib/poems/vect6.h b/lib/poems/vect6.h index 8047c1bbf8..5def4c6b1b 100644 --- a/lib/poems/vect6.h +++ b/lib/poems/vect6.h @@ -23,6 +23,7 @@ #include "virtualcolmatrix.h" #include "virtualmatrix.h" +namespace POEMS { class Matrix; class Mat6x6; class ColMatrix; @@ -69,5 +70,5 @@ public: friend void OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV); }; - +} #endif diff --git a/lib/poems/virtualcolmatrix.cpp b/lib/poems/virtualcolmatrix.cpp index 3a6c6e22cd..fa430b81f7 100644 --- a/lib/poems/virtualcolmatrix.cpp +++ b/lib/poems/virtualcolmatrix.cpp @@ -20,6 +20,8 @@ #include using namespace std; +using namespace POEMS; + VirtualColMatrix::VirtualColMatrix(){ numcols = 1; diff --git a/lib/poems/virtualcolmatrix.h b/lib/poems/virtualcolmatrix.h index 1548794ca0..040fce051e 100644 --- a/lib/poems/virtualcolmatrix.h +++ b/lib/poems/virtualcolmatrix.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: virtualcolmatrix.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,25 +21,25 @@ #include "virtualmatrix.h" - +namespace POEMS { class VirtualColMatrix : public VirtualMatrix { -public: - VirtualColMatrix(); - ~VirtualColMatrix(); - double& operator_2int (int i, int j); // array access - double Get_2int (int i, int j) const; - void Set_2int (int i, int j, double value); - double BasicGet_2int(int i, int j) const; - void BasicSet_2int(int i, int j, double value); - void BasicIncrement_2int(int i, int j, double value); +public: + VirtualColMatrix(); + ~VirtualColMatrix(); + double& operator_2int (int i, int j); // array access + double Get_2int (int i, int j) const; + void Set_2int (int i, int j, double value); + double BasicGet_2int(int i, int j) const; + void BasicSet_2int(int i, int j, double value); + void BasicIncrement_2int(int i, int j, double value); - virtual double& operator_1int (int i) = 0; // array access - virtual double Get_1int(int i) const = 0; - virtual void Set_1int(int i, double value) = 0; - virtual double BasicGet_1int(int i) const = 0; - virtual void BasicSet_1int(int i, double value) = 0; - virtual void BasicIncrement_1int(int i, double value) = 0; + virtual double& operator_1int (int i) = 0; // array access + virtual double Get_1int(int i) const = 0; + virtual void Set_1int(int i, double value) = 0; + virtual double BasicGet_1int(int i) const = 0; + virtual void BasicSet_1int(int i, double value) = 0; + virtual void BasicIncrement_1int(int i, double value) = 0; }; - +} #endif diff --git a/lib/poems/virtualmatrix.cpp b/lib/poems/virtualmatrix.cpp index 19d5946961..bfffeb3d74 100644 --- a/lib/poems/virtualmatrix.cpp +++ b/lib/poems/virtualmatrix.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + VirtualMatrix::VirtualMatrix(){ numrows = numcols = 0; @@ -140,14 +142,14 @@ istream& VirtualMatrix::ReadData(istream& c){ // operators and functions // -ostream& operator<< (ostream& c, const VirtualMatrix& A){ //output +ostream& POEMS::operator<< (ostream& c, const VirtualMatrix& A){ //output c << A.GetType() << ' '; A.WriteData(c); c << endl; return c; } -istream& operator>> (istream& c, VirtualMatrix& A){ //input +istream& POEMS::operator>> (istream& c, VirtualMatrix& A){ //input VirtualMatrix* vm; int matrixtype; c >> matrixtype; diff --git a/lib/poems/virtualmatrix.h b/lib/poems/virtualmatrix.h index a27c7de047..706b943d66 100644 --- a/lib/poems/virtualmatrix.h +++ b/lib/poems/virtualmatrix.h @@ -20,6 +20,7 @@ #define VIRTUALMATRIX_H #include +namespace POEMS { enum MatrixType { MATRIX = 0, COLMATRIX = 1, @@ -83,5 +84,5 @@ protected: // overloaded operators std::ostream& operator<< (std::ostream& c, const VirtualMatrix& A); // output std::istream& operator>> (std::istream& c, VirtualMatrix& A); // input - +} #endif diff --git a/lib/poems/virtualrowmatrix.cpp b/lib/poems/virtualrowmatrix.cpp index 1a12cfbfd9..740c747407 100644 --- a/lib/poems/virtualrowmatrix.cpp +++ b/lib/poems/virtualrowmatrix.cpp @@ -21,6 +21,8 @@ #include using namespace std; +using namespace POEMS; + VirtualRowMatrix::VirtualRowMatrix(){ numrows = 1; diff --git a/lib/poems/virtualrowmatrix.h b/lib/poems/virtualrowmatrix.h index 68b39f137d..0a3c877f64 100644 --- a/lib/poems/virtualrowmatrix.h +++ b/lib/poems/virtualrowmatrix.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: virtualrowmatrix.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,8 +21,9 @@ #include "virtualmatrix.h" +namespace POEMS { class VirtualRowMatrix : public VirtualMatrix { -public: +public: VirtualRowMatrix(); ~VirtualRowMatrix(); double& operator_2int (int i, int j); // array access @@ -31,7 +32,7 @@ public: double BasicGet_2int(int i, int j) const; void BasicSet_2int(int i, int j, double value); void BasicIncrement_2int(int i, int j, double value); - + virtual double& operator_1int (int i) = 0; // array access virtual double Get_1int(int i) const = 0; virtual void Set_1int(int i, double value) = 0; @@ -39,5 +40,5 @@ public: virtual void BasicSet_1int(int i, double value) = 0; virtual void BasicIncrement_1int(int i, double value) = 0; }; - +} #endif diff --git a/lib/poems/workspace.cpp b/lib/poems/workspace.cpp index 29a1c95832..03f18a7895 100644 --- a/lib/poems/workspace.cpp +++ b/lib/poems/workspace.cpp @@ -38,6 +38,8 @@ using namespace std; +using namespace POEMS; + void Workspace::allocateNewSystem() { currentIndex++; diff --git a/lib/poems/workspace.h b/lib/poems/workspace.h index 6213815d81..2510b2fc3a 100644 --- a/lib/poems/workspace.h +++ b/lib/poems/workspace.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: workspace.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -19,61 +19,62 @@ #ifndef WORKSPACE_H #define WORKSPACE_H +namespace POEMS { class System; class Solver; struct SysData{ - System * system; - int solver; - int integrator; + System * system; + int solver; + int integrator; }; class Workspace { - SysData * system; // the multibody systems data - int currentIndex; - int maxAlloc; - + SysData * system; // the multibody systems data + int currentIndex; + int maxAlloc; + public: Workspace(); ~Workspace(); - + double Thalf; double Tfull; double ConFac; double KE_val; - int FirstTime; - + int FirstTime; + bool LoadFile(char* filename); - + bool SaveFile(char* filename, int index = -1); System* GetSystem(int index = -1); - - void AddSolver(Solver* s, int index = -1); - - void LobattoOne(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); - - void LobattoTwo(double **&vcm,double **&omega,double **&torque, double **&fcm); - - + void AddSolver(Solver* s, int index = -1); + + + void LobattoOne(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); + + void LobattoTwo(double **&vcm,double **&omega,double **&torque, double **&fcm); + + bool MakeSystem(int& nbody, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space, int &njoint, int **&jointbody, double **&xjoint, int& nfree, int*freelist, double dthalf, double dtv, double tempcon, double KE); - - - bool SaveSystem(int& nbody, double *&masstotal, double **&inertia, double **&xcm, double **&xjoint, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space, double **&acm, double **&alpha, double **&torque, double **&fcm, int **&jointbody, int &njoint); - - bool MakeDegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space); + + + bool SaveSystem(int& nbody, double *&masstotal, double **&inertia, double **&xcm, double **&xjoint, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space, double **&acm, double **&alpha, double **&torque, double **&fcm, int **&jointbody, int &njoint); + + bool MakeDegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space); int getNumberOfSystems(); - + void SetLammpsValues(double dtv, double dthalf, double tempcon); void SetKE(int temp, double SysKE); - - void RKStep(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); - - void WriteFile(char* filename); + + void RKStep(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); + + void WriteFile(char* filename); private: - void allocateNewSystem(); //helper function to handle vector resizing and such for the array of system pointers + void allocateNewSystem(); //helper function to handle vector resizing and such for the array of system pointers }; - +} #endif diff --git a/src/POEMS/fix_poems.cpp b/src/POEMS/fix_poems.cpp index 6d943a79db..21c12f700b 100644 --- a/src/POEMS/fix_poems.cpp +++ b/src/POEMS/fix_poems.cpp @@ -20,7 +20,6 @@ #include "fix_poems.h" #include #include -#include #include #include #include "workspace.h" @@ -30,7 +29,6 @@ #include "respa.h" #include "modify.h" #include "force.h" -#include "output.h" #include "group.h" #include "comm.h" #include "citeme.h" @@ -265,7 +263,7 @@ FixPOEMS::FixPOEMS(LAMMPS *lmp, int narg, char **arg) : // create POEMS instance - poems = new Workspace; + poems = new POEMS::Workspace; // compute per body forces and torques inside final_integrate() by default diff --git a/src/POEMS/fix_poems.h b/src/POEMS/fix_poems.h index 7b2c77a1bd..87f9557ac0 100644 --- a/src/POEMS/fix_poems.h +++ b/src/POEMS/fix_poems.h @@ -22,6 +22,7 @@ FixStyle(poems,FixPOEMS) #include "fix.h" +namespace POEMS { class Workspace; } namespace LAMMPS_NS { class FixPOEMS : public Fix { @@ -94,7 +95,7 @@ class FixPOEMS : public Fix { // POEMS object - class Workspace *poems; + POEMS::Workspace *poems; // internal class functions From fa15bf5edd552cafcfb5cfd28edc2ad327015921 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 4 Jul 2019 00:25:33 -0400 Subject: [PATCH 38/79] recover compilation of USER-COLVARS package --- src/USER-COLVARS/colvarproxy_lammps.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/USER-COLVARS/colvarproxy_lammps.h b/src/USER-COLVARS/colvarproxy_lammps.h index c3d9dbb35f..3243a14fbd 100644 --- a/src/USER-COLVARS/colvarproxy_lammps.h +++ b/src/USER-COLVARS/colvarproxy_lammps.h @@ -38,6 +38,12 @@ inline std::ostream & operator<< (std::ostream &out, const commdata &cd) return out; } +// forward declarations +namespace LAMMPS_NS { + class LAMMPS; + class RanPark; +} + /// \brief Communication between colvars and LAMMPS /// (implementation of \link colvarproxy \endlink) class colvarproxy_lammps : public colvarproxy { @@ -46,8 +52,8 @@ class colvarproxy_lammps : public colvarproxy { protected: // pointers to LAMMPS class instances - class LAMMPS_NS::LAMMPS *_lmp; - class LAMMPS_NS::RanPark *_random; + LAMMPS_NS::LAMMPS *_lmp; + LAMMPS_NS::RanPark *_random; // state of LAMMPS properties double t_target, my_timestep, my_boltzmann, my_angstrom; From 732bd937e0416d46be708778bd234cd3e0c9ba97 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 4 Jul 2019 01:16:56 -0400 Subject: [PATCH 39/79] clean up includes in USER-COLVARS package --- src/USER-COLVARS/colvarproxy_lammps.cpp | 13 +------- src/USER-COLVARS/colvarproxy_lammps.h | 41 ++++++++----------------- src/USER-COLVARS/fix_colvars.cpp | 25 ++++++++++++--- src/USER-COLVARS/fix_colvars.h | 5 ++- src/USER-COLVARS/group_ndx.cpp | 3 +- src/USER-COLVARS/ndx_group.cpp | 4 +-- 6 files changed, 37 insertions(+), 54 deletions(-) diff --git a/src/USER-COLVARS/colvarproxy_lammps.cpp b/src/USER-COLVARS/colvarproxy_lammps.cpp index 685c698ab6..2c43a3fb26 100644 --- a/src/USER-COLVARS/colvarproxy_lammps.cpp +++ b/src/USER-COLVARS/colvarproxy_lammps.cpp @@ -10,30 +10,19 @@ #include "colvarproxy_lammps.h" #include -#include #include -#include - #include -#include #include - #include -#include +#include #include #include "lammps.h" -#include "atom.h" #include "error.h" #include "output.h" #include "random_park.h" -#include "fix_colvars.h" - #include "colvarmodule.h" -#include "colvar.h" -#include "colvarbias.h" -#include "colvaratoms.h" #include "colvarproxy.h" #define HASH_FAIL -1 diff --git a/src/USER-COLVARS/colvarproxy_lammps.h b/src/USER-COLVARS/colvarproxy_lammps.h index 3243a14fbd..8ed03309a3 100644 --- a/src/USER-COLVARS/colvarproxy_lammps.h +++ b/src/USER-COLVARS/colvarproxy_lammps.h @@ -10,39 +10,22 @@ #ifndef COLVARPROXY_LAMMPS_H #define COLVARPROXY_LAMMPS_H -#include "colvarproxy_lammps_version.h" +#include "colvarproxy_lammps_version.h" // IWYU pragma: export + +#include +#include +#include +#include #include "colvarmodule.h" #include "colvarproxy.h" -#include "colvarvalue.h" +#include "colvartypes.h" -#include "lammps.h" -#include "domain.h" -#include "force.h" -#include "update.h" - -#include -#include -#include - -/* struct for packed data communication of coordinates and forces. */ -struct commdata { - int tag,type; - double x,y,z,m,q; -}; - -inline std::ostream & operator<< (std::ostream &out, const commdata &cd) -{ - out << " (" << cd.tag << "/" << cd.type << ": " - << cd.x << ", " << cd.y << ", " << cd.z << ") "; - return out; -} - -// forward declarations -namespace LAMMPS_NS { - class LAMMPS; - class RanPark; -} +#include "random_park.h" +#include "lammps.h" // IWYU pragma: keep +#include "domain.h" // IWYU pragma: keep +#include "force.h" // IWYU pragma: keep +#include "update.h" // IWYU pragma: keep /// \brief Communication between colvars and LAMMPS /// (implementation of \link colvarproxy \endlink) diff --git a/src/USER-COLVARS/fix_colvars.cpp b/src/USER-COLVARS/fix_colvars.cpp index 9331fe7abb..4a57e59fbd 100644 --- a/src/USER-COLVARS/fix_colvars.cpp +++ b/src/USER-COLVARS/fix_colvars.cpp @@ -25,26 +25,28 @@ ------------------------------------------------------------------------- */ #include "fix_colvars.h" -#include -#include +#include #include #include -#include +#include +#include +#include +#include #include "atom.h" #include "comm.h" #include "domain.h" #include "error.h" -#include "group.h" +#include "force.h" #include "memory.h" #include "modify.h" -#include "random_park.h" #include "respa.h" #include "universe.h" #include "update.h" #include "citeme.h" #include "colvarproxy_lammps.h" +#include "colvarmodule.h" static const char colvars_pub[] = "fix colvars command:\n\n" @@ -57,6 +59,19 @@ static const char colvars_pub[] = " note = {doi: 10.1080/00268976.2013.813594}\n" "}\n\n"; +/* struct for packed data communication of coordinates and forces. */ +struct LAMMPS_NS::commdata { + int tag,type; + double x,y,z,m,q; +}; + +inline std::ostream & operator<< (std::ostream &out, const LAMMPS_NS::commdata &cd) +{ + out << " (" << cd.tag << "/" << cd.type << ": " + << cd.x << ", " << cd.y << ", " << cd.z << ") "; + return out; +} + /* re-usable integer hash table code with static linkage. */ /** hash table top level data structure */ diff --git a/src/USER-COLVARS/fix_colvars.h b/src/USER-COLVARS/fix_colvars.h index a0c197fca4..985457e746 100644 --- a/src/USER-COLVARS/fix_colvars.h +++ b/src/USER-COLVARS/fix_colvars.h @@ -34,10 +34,9 @@ FixStyle(colvars,FixColvars) #define LMP_FIX_COLVARS_H #include "fix.h" +#include -// forward declaration class colvarproxy_lammps; -struct commdata; namespace LAMMPS_NS { @@ -64,7 +63,7 @@ class FixColvars : public Fix { virtual void restart(char *); protected: - class colvarproxy_lammps *proxy; // pointer to the colvars proxy class + colvarproxy_lammps *proxy; // pointer to the colvars proxy class char *conf_file; // name of colvars config file char *inp_name; // name/prefix of colvars restart file char *out_name; // prefix string for all output files diff --git a/src/USER-COLVARS/group_ndx.cpp b/src/USER-COLVARS/group_ndx.cpp index 7350712c40..1e37e2de9c 100644 --- a/src/USER-COLVARS/group_ndx.cpp +++ b/src/USER-COLVARS/group_ndx.cpp @@ -17,12 +17,11 @@ ------------------------------------------------------------------------- */ #include "group_ndx.h" -#include +#include #include #include "atom.h" #include "comm.h" #include "group.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-COLVARS/ndx_group.cpp b/src/USER-COLVARS/ndx_group.cpp index 5436ba7b6b..a1369df2fb 100644 --- a/src/USER-COLVARS/ndx_group.cpp +++ b/src/USER-COLVARS/ndx_group.cpp @@ -17,14 +17,12 @@ ------------------------------------------------------------------------- */ #include "ndx_group.h" -#include +#include #include #include #include "atom.h" #include "comm.h" #include "group.h" -#include "memory.h" -#include "force.h" #include "error.h" using namespace LAMMPS_NS; From b4cf4b1ed7d976dba74536659bd59c1887f1f546 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 4 Jul 2019 06:51:52 -0400 Subject: [PATCH 40/79] recover compilation of KOKKOS package --- src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp index 7a2fca47a0..27a7a59c2a 100644 --- a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp +++ b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp @@ -20,6 +20,7 @@ #include #include #include +#include "atom_kokkos.h" #include "atom_vec.h" #include "comm.h" #include "update.h" From ce6fa0118ab69fd09fa19410f6bbfec3608f0f73 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 4 Jul 2019 07:23:01 -0400 Subject: [PATCH 41/79] continuing to clean up include file lists --- src/pair_lj_cut_coul_wolf.cpp | 7 +------ src/pair_lj_expand.cpp | 3 +-- src/pair_lj_gromacs.cpp | 5 +---- src/pair_lj_gromacs_coul_gromacs.cpp | 4 +--- src/pair_lj_smooth.cpp | 3 +-- src/pair_lj_smooth_linear.cpp | 3 +-- src/pair_mie_cut.cpp | 4 +--- src/pair_morse.cpp | 3 +-- src/pair_soft.cpp | 4 +--- src/pair_table.cpp | 1 + src/pair_ufm.cpp | 10 +--------- src/pair_yukawa.cpp | 2 +- src/pair_zbl.cpp | 10 ---------- src/pair_zero.cpp | 4 +--- src/procmap.cpp | 8 +++++--- src/rcb.cpp | 1 - src/read_data.cpp | 4 ---- src/read_dump.cpp | 8 +------- src/read_restart.cpp | 2 -- src/reader.cpp | 1 - src/reader_xyz.cpp | 2 -- src/region.cpp | 1 - src/region_block.cpp | 1 - src/region_cone.cpp | 1 - src/region_cylinder.cpp | 1 - src/region_intersect.cpp | 1 - src/region_plane.cpp | 2 -- src/region_prism.cpp | 2 -- src/region_sphere.cpp | 1 - src/region_union.cpp | 1 - src/replicate.cpp | 3 +-- src/rerun.cpp | 1 - src/reset_ids.cpp | 1 + src/respa.cpp | 4 +--- src/run.cpp | 1 - src/set.cpp | 4 +--- src/special.cpp | 2 -- src/thermo.cpp | 5 ----- src/thermo.h | 3 --- 39 files changed, 23 insertions(+), 101 deletions(-) diff --git a/src/pair_lj_cut_coul_wolf.cpp b/src/pair_lj_cut_coul_wolf.cpp index fb641f7d24..00a5832529 100644 --- a/src/pair_lj_cut_coul_wolf.cpp +++ b/src/pair_lj_cut_coul_wolf.cpp @@ -16,18 +16,13 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_coul_wolf.h" +#include #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/pair_lj_expand.cpp b/src/pair_lj_expand.cpp index 60593fd01d..a5184bc2f5 100644 --- a/src/pair_lj_expand.cpp +++ b/src/pair_lj_expand.cpp @@ -12,9 +12,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_expand.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/pair_lj_gromacs.cpp b/src/pair_lj_gromacs.cpp index 4796c288d7..baef482ef9 100644 --- a/src/pair_lj_gromacs.cpp +++ b/src/pair_lj_gromacs.cpp @@ -16,14 +16,11 @@ ------------------------------------------------------------------------- */ #include "pair_lj_gromacs.h" +#include #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/pair_lj_gromacs_coul_gromacs.cpp b/src/pair_lj_gromacs_coul_gromacs.cpp index 45beeb1daf..c62944b6a1 100644 --- a/src/pair_lj_gromacs_coul_gromacs.cpp +++ b/src/pair_lj_gromacs_coul_gromacs.cpp @@ -16,10 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_gromacs_coul_gromacs.h" +#include #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_smooth.cpp b/src/pair_lj_smooth.cpp index d89fee1148..7c7eb51b53 100644 --- a/src/pair_lj_smooth.cpp +++ b/src/pair_lj_smooth.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_smooth.h" +#include #include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_lj_smooth_linear.cpp b/src/pair_lj_smooth_linear.cpp index 6ed19a452f..a3e4aed2fe 100644 --- a/src/pair_lj_smooth_linear.cpp +++ b/src/pair_lj_smooth_linear.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_smooth_linear.h" +#include #include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/pair_mie_cut.cpp b/src/pair_mie_cut.cpp index d2b0c20cd5..46657687f6 100644 --- a/src/pair_mie_cut.cpp +++ b/src/pair_mie_cut.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_mie_cut.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" @@ -27,7 +26,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory.h" diff --git a/src/pair_morse.cpp b/src/pair_morse.cpp index 47102932db..d088f98bf4 100644 --- a/src/pair_morse.cpp +++ b/src/pair_morse.cpp @@ -12,9 +12,8 @@ ------------------------------------------------------------------------- */ #include "pair_morse.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/pair_soft.cpp b/src/pair_soft.cpp index f3d7423b04..6f821e684b 100644 --- a/src/pair_soft.cpp +++ b/src/pair_soft.cpp @@ -12,14 +12,12 @@ ------------------------------------------------------------------------- */ #include "pair_soft.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" #include "force.h" -#include "update.h" #include "neigh_list.h" #include "math_const.h" #include "memory.h" diff --git a/src/pair_table.cpp b/src/pair_table.cpp index 63cda78c67..9fcbc3ee9f 100644 --- a/src/pair_table.cpp +++ b/src/pair_table.cpp @@ -20,6 +20,7 @@ #include #include #include +#include #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/pair_ufm.cpp b/src/pair_ufm.cpp index 40b72136ff..8cc4d2796f 100644 --- a/src/pair_ufm.cpp +++ b/src/pair_ufm.cpp @@ -18,25 +18,17 @@ ------------------------------------------------------------------------- */ #include "pair_ufm.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/pair_yukawa.cpp b/src/pair_yukawa.cpp index 4a2cf23952..e8775c9668 100644 --- a/src/pair_yukawa.cpp +++ b/src/pair_yukawa.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include "pair_yukawa.h" +#include #include -#include #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/pair_zbl.cpp b/src/pair_zbl.cpp index b01c301785..199e4f0907 100644 --- a/src/pair_zbl.cpp +++ b/src/pair_zbl.cpp @@ -17,19 +17,10 @@ #include "pair_zbl.h" #include -#include -#include -#include #include "atom.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" -#include "math_const.h" #include "memory.h" #include "error.h" @@ -37,7 +28,6 @@ // "The Stopping and Range of Ions in Matter" volume 1, Pergamon, 1985. using namespace LAMMPS_NS; -using namespace MathConst; using namespace PairZBLConstants; /* ---------------------------------------------------------------------- */ diff --git a/src/pair_zero.cpp b/src/pair_zero.cpp index 2692710e20..403bd73944 100644 --- a/src/pair_zero.cpp +++ b/src/pair_zero.cpp @@ -16,9 +16,7 @@ ------------------------------------------------------------------------- */ #include "pair_zero.h" -#include -#include -#include +#include #include #include "atom.h" #include "comm.h" diff --git a/src/procmap.cpp b/src/procmap.cpp index 47afb76da9..69585aa453 100644 --- a/src/procmap.cpp +++ b/src/procmap.cpp @@ -16,7 +16,12 @@ ------------------------------------------------------------------------- */ #include "procmap.h" +#include +#include #include +#include +#include +#include #include "universe.h" #include "comm.h" #include "domain.h" @@ -24,9 +29,6 @@ #include "memory.h" #include "error.h" -#include -#include - using namespace LAMMPS_NS; #define MAXLINE 128 diff --git a/src/rcb.cpp b/src/rcb.cpp index b19beae3c5..f1a6377046 100644 --- a/src/rcb.cpp +++ b/src/rcb.cpp @@ -16,7 +16,6 @@ #include #include "irregular.h" #include "memory.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/read_data.cpp b/src/read_data.cpp index a50d41b498..dad48110f7 100644 --- a/src/read_data.cpp +++ b/src/read_data.cpp @@ -16,18 +16,14 @@ // before lmptype.h can set flags to insure it is done correctly #include "read_data.h" -#include "lmptype.h" #include -#include #include -#include #include #include "atom.h" #include "atom_vec.h" #include "atom_vec_ellipsoid.h" #include "atom_vec_line.h" #include "atom_vec_tri.h" -#include "force.h" #include "molecule.h" #include "group.h" #include "comm.h" diff --git a/src/read_dump.cpp b/src/read_dump.cpp index 49f96db680..d83a96f0fa 100644 --- a/src/read_dump.cpp +++ b/src/read_dump.cpp @@ -20,24 +20,18 @@ // before lmptype.h can set flags to insure it is done correctly #include "read_dump.h" -#include "lmptype.h" #include #include -#include +#include #include "reader.h" #include "style_reader.h" #include "atom.h" #include "atom_vec.h" #include "update.h" -#include "modify.h" -#include "fix.h" -#include "compute.h" #include "domain.h" #include "comm.h" #include "force.h" #include "irregular.h" -#include "input.h" -#include "variable.h" #include "error.h" #include "memory.h" #include "utils.h" diff --git a/src/read_restart.cpp b/src/read_restart.cpp index 17b313bfa2..3d2e2b6592 100644 --- a/src/read_restart.cpp +++ b/src/read_restart.cpp @@ -14,7 +14,6 @@ #include "read_restart.h" #include #include -#include #include #include "atom.h" #include "atom_vec.h" @@ -23,7 +22,6 @@ #include "irregular.h" #include "update.h" #include "modify.h" -#include "fix.h" #include "fix_read_restart.h" #include "group.h" #include "force.h" diff --git a/src/reader.cpp b/src/reader.cpp index a1fe51f662..b2751662e2 100644 --- a/src/reader.cpp +++ b/src/reader.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "reader.h" -#include #include #include "error.h" diff --git a/src/reader_xyz.cpp b/src/reader_xyz.cpp index fa553dc30f..81aaba77bc 100644 --- a/src/reader_xyz.cpp +++ b/src/reader_xyz.cpp @@ -16,9 +16,7 @@ ------------------------------------------------------------------------- */ #include "reader_xyz.h" -#include #include -#include "atom.h" #include "memory.h" #include "error.h" #include "force.h" diff --git a/src/region.cpp b/src/region.cpp index 0c4bec16e0..7a676de1af 100644 --- a/src/region.cpp +++ b/src/region.cpp @@ -13,7 +13,6 @@ #include "region.h" #include -#include #include #include "update.h" #include "domain.h" diff --git a/src/region_block.cpp b/src/region_block.cpp index bc52fcd7cf..8ea8b3f202 100644 --- a/src/region_block.cpp +++ b/src/region_block.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "region_block.h" -#include #include #include "force.h" #include "domain.h" diff --git a/src/region_cone.cpp b/src/region_cone.cpp index 345c9fa8e2..3c7d0a29d8 100644 --- a/src/region_cone.cpp +++ b/src/region_cone.cpp @@ -17,7 +17,6 @@ #include "region_cone.h" #include -#include #include #include "domain.h" #include "error.h" diff --git a/src/region_cylinder.cpp b/src/region_cylinder.cpp index 968453cf37..b2c06270d0 100644 --- a/src/region_cylinder.cpp +++ b/src/region_cylinder.cpp @@ -13,7 +13,6 @@ #include "region_cylinder.h" #include -#include #include #include "update.h" #include "domain.h" diff --git a/src/region_intersect.cpp b/src/region_intersect.cpp index c6c11cf35c..fe074a6b4c 100644 --- a/src/region_intersect.cpp +++ b/src/region_intersect.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "region_intersect.h" -#include #include #include "domain.h" #include "error.h" diff --git a/src/region_plane.cpp b/src/region_plane.cpp index 950c0a4b53..85671357ef 100644 --- a/src/region_plane.cpp +++ b/src/region_plane.cpp @@ -13,8 +13,6 @@ #include "region_plane.h" #include -#include -#include #include "error.h" #include "force.h" diff --git a/src/region_prism.cpp b/src/region_prism.cpp index 38fc23da21..b6c54c2fb9 100644 --- a/src/region_prism.cpp +++ b/src/region_prism.cpp @@ -16,8 +16,6 @@ ------------------------------------------------------------------------- */ #include "region_prism.h" -#include -#include #include #include "domain.h" #include "force.h" diff --git a/src/region_sphere.cpp b/src/region_sphere.cpp index 9c478960e3..bf874ad311 100644 --- a/src/region_sphere.cpp +++ b/src/region_sphere.cpp @@ -13,7 +13,6 @@ #include "region_sphere.h" #include -#include #include #include "update.h" #include "input.h" diff --git a/src/region_union.cpp b/src/region_union.cpp index f4e30f5b94..be1fe6eeff 100644 --- a/src/region_union.cpp +++ b/src/region_union.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "region_union.h" -#include #include #include "domain.h" #include "error.h" diff --git a/src/replicate.cpp b/src/replicate.cpp index 6f8c94238a..1617ab0313 100644 --- a/src/replicate.cpp +++ b/src/replicate.cpp @@ -12,11 +12,10 @@ ------------------------------------------------------------------------- */ #include "replicate.h" -#include +#include #include #include "atom.h" #include "atom_vec.h" -#include "atom_vec_hybrid.h" #include "force.h" #include "domain.h" #include "comm.h" diff --git a/src/rerun.cpp b/src/rerun.cpp index e75779ccc0..3cd1c53628 100644 --- a/src/rerun.cpp +++ b/src/rerun.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "rerun.h" -#include #include #include "read_dump.h" #include "domain.h" diff --git a/src/reset_ids.cpp b/src/reset_ids.cpp index b68b7ca797..857738e841 100644 --- a/src/reset_ids.cpp +++ b/src/reset_ids.cpp @@ -12,6 +12,7 @@ ------------------------------------------------------------------------- */ #include "reset_ids.h" +#include #include "atom.h" #include "atom_vec.h" #include "domain.h" diff --git a/src/respa.cpp b/src/respa.cpp index 867662b3c2..a184756335 100644 --- a/src/respa.cpp +++ b/src/respa.cpp @@ -16,13 +16,13 @@ ------------------------------------------------------------------------- */ #include "respa.h" -#include #include #include "neighbor.h" #include "atom.h" #include "atom_vec.h" #include "domain.h" #include "comm.h" +#include "fix.h" #include "force.h" #include "pair.h" #include "bond.h" @@ -33,10 +33,8 @@ #include "output.h" #include "update.h" #include "modify.h" -#include "compute.h" #include "fix_respa.h" #include "timer.h" -#include "memory.h" #include "error.h" #include "utils.h" #include "pair_hybrid.h" diff --git a/src/run.cpp b/src/run.cpp index 60861ad3b9..2c2f00a7a8 100644 --- a/src/run.cpp +++ b/src/run.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "run.h" -#include #include #include "domain.h" #include "update.h" diff --git a/src/set.cpp b/src/set.cpp index d34aa7753a..3bf00063c5 100644 --- a/src/set.cpp +++ b/src/set.cpp @@ -14,8 +14,8 @@ #include "set.h" #include #include -#include #include +#include #include "atom.h" #include "atom_vec.h" #include "atom_vec_ellipsoid.h" @@ -26,9 +26,7 @@ #include "region.h" #include "group.h" #include "comm.h" -#include "neighbor.h" #include "force.h" -#include "pair.h" #include "input.h" #include "variable.h" #include "random_park.h" diff --git a/src/special.cpp b/src/special.cpp index f8661e238c..b64aa96e2b 100644 --- a/src/special.cpp +++ b/src/special.cpp @@ -13,7 +13,6 @@ #include "special.h" #include -#include #include "atom.h" #include "atom_vec.h" #include "force.h" @@ -23,7 +22,6 @@ #include "accelerator_kokkos.h" #include "atom_masks.h" #include "memory.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/thermo.cpp b/src/thermo.cpp index d267ea260c..be725d907b 100644 --- a/src/thermo.cpp +++ b/src/thermo.cpp @@ -16,10 +16,8 @@ // before lmptype.h can set flags to insure it is done correctly #include "thermo.h" -#include "lmptype.h" #include #include -#include #include #include "atom.h" #include "update.h" @@ -43,11 +41,8 @@ #include "kspace.h" #include "output.h" #include "timer.h" -#include "math_const.h" #include "memory.h" #include "error.h" -#include "universe.h" - #include "math_const.h" using namespace LAMMPS_NS; diff --git a/src/thermo.h b/src/thermo.h index 8c32f24d3c..f2384e0ac3 100644 --- a/src/thermo.h +++ b/src/thermo.h @@ -18,9 +18,6 @@ namespace LAMMPS_NS { -class DumpNetCDF; -class DumpNetCDFMPIIO; - class Thermo : protected Pointers { friend class MinCG; // accesses compute_pe friend class DumpNetCDF; // accesses thermo properties From d07a49aeea8a13cb83eb1da6096877d0e6b53ea5 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 5 Jul 2019 11:37:21 -0400 Subject: [PATCH 42/79] add missing prototypes --- lib/poems/fastmatrixops.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/poems/fastmatrixops.h b/lib/poems/fastmatrixops.h index 4c3c1353bd..45573c3eab 100644 --- a/lib/poems/fastmatrixops.h +++ b/lib/poems/fastmatrixops.h @@ -32,6 +32,7 @@ class Vect6; void FastCross(Vect3& a, Vect3& b, Vect3& c); void FastSimpleRotation(Vect3& v, double q, Mat3x3& C); void FastQuaternions(ColMatrix& q, Mat3x3& C); +void FastInvQuaternions(Mat3x3& C, ColMatrix& q); void FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot); void FastLDLT(Matrix& A, Matrix& LD); // C is the LDL^T decomposition of A (SPD) void FastLDLT(Mat6x6& A, Mat6x6& LD); // C is the LDL^T decomposition of A (SPD) @@ -54,6 +55,7 @@ void FastTripleSumPPM(Vect3& a, Vect3& b, Vect3& c, Vect3& d); // d = a+b-c void FastMult(Matrix& A, Matrix& B, Matrix& C); // C = A*B void FastTMult(Matrix& A, Matrix& B, Matrix& C); // C = A^T*B +void FastTMult(Mat3x3& A, Vect3& B, Vect3& C); void FastMult(Mat3x3& A, Vect3& B, Vect3& C); // C = A*B void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); // C = A*B @@ -90,6 +92,7 @@ void FastAdd(Vect3& A, Vect3& B, Vect3& C); // C = A+B void FastAdd(Vect4& A, Vect4& B, Vect3& C); // C = A+B void FastAdd(Mat6x6& A, Mat6x6& B, Mat6x6& C); // C = A+B void FastAdd(Vect6& A, Vect6& B, Vect6& C); // C = A+B +void FastAdd(Vect4& A, Vect4& B, Vect4& C); void FastSubt(Vect3& A, Vect3& B, Vect3& C); // C = A-B void FastSubt(Vect4& A, Vect4& B, Vect4& C); // C = A-B From 5fffccb076fd350cf0bf6c80374bccee87c210a1 Mon Sep 17 00:00:00 2001 From: Anne Gunn Date: Fri, 5 Jul 2019 12:08:57 -0600 Subject: [PATCH 43/79] Apply minor line editing to new documentation file. --- doc/include-file-conventions.md | 44 ++++++++++++++++----------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/doc/include-file-conventions.md b/doc/include-file-conventions.md index 1f206c8f88..c9f8bd5cb1 100644 --- a/doc/include-file-conventions.md +++ b/doc/include-file-conventions.md @@ -3,7 +3,7 @@ This purpose of this document is to provide a point of reference for LAMMPS developers and contributors as to what include files and definitions to put where into LAMMPS source. -Last change 2019-06-27 +Last change 2019-07-05 ## Table of Contents @@ -14,43 +14,43 @@ Last change 2019-06-27 ## Motivation -The conventions outlined in this document are supposed to help making +The conventions outlined in this document are supposed to help make maintenance of the LAMMPS software easier. By trying to achieve consistency across files contributed by different developers, it will -become easier to modify and adjust files by the code maintainers, and -overall the chance for errors or portability issues will be reduced. -Also the rules employed are supposed to minimize naming conflicts and -simplify dependencies between files (and thus speed up compilation), as -well as make otherwise hidden dependencies visible. +become easier for the code maintainers to modify and adjust files and, +overall, the chance for errors or portability issues will be reduced. +The rules employed are supposed to minimize naming conflicts and +simplify dependencies between files and thus speed up compilation. They +may, as well, make otherwise hidden dependencies visible. ## Rules Below are the various rules that are applied. Not all are enforced strictly and automatically. If there are no significant side effects, -exceptions may be possible for cases, where a full compliance to the +exceptions may be possible for cases where a full compliance to the rules may require a large effort compared to the benefit. ### Core Files Versus Package Files -All rules listed below are most strictly observed for core LAMMPS files. -Which are the files that are not part of a package and files of the +All rules listed below are most strictly observed for core LAMMPS files, +which are the files that are not part of a package, and the files of the packages MOLECULE, MANYBODY, KSPACE, and RIGID. On the other end of the spectrum are USER packages and legacy packages that predate these -rules and thus may not be fully compliant. Also new contributions -will be checked more closely, while existing code is incrementally +rules and thus may not be fully compliant. Also, new contributions +will be checked more closely, while existing code will be incrementally adapted to the rules as time and required effort permits. ### System Versus Local Header Files -All system or library provided include files are included with angular +All system- or library-provided include files are included with angular brackets (examples: `#include ` or `#include `) while include files provided with LAMMPS are included with double quotes (examples: `#include "pointers.h"` or `#include "compute_temp.h"`). For headers declaring functions of the C-library, the corresponding C++ versions should be included (examples: `#include ` or -`#include `). However, those are limited to those defined -in the C++98 standard. Some files thus must use the older style unless +`#include `). However, these includes are limited to those defined +in the C++98 standard. Some files thus must use the older style until the minimum C++ standard requirement of LAMMPS is lifted to C++11 or even beyond (examples: `#include ` versus `#include ` or `#include ` versus `#include `). @@ -60,7 +60,7 @@ or `#include ` versus `#include `). LAMMPS core files currently correspond to the C++98 standard. Files requiring C++11 or later are only permitted in (optional) packages and particularly packages that are not part of the list of commonly -used packages like MOLECULE, KSPACE, MANYBODY, or RIGID. +used packages such as MOLECULE, KSPACE, MANYBODY, or RIGID. Also, LAMMPS uses the C-style stdio library for I/O instead of iostreams. Since using both at the same time can cause problems, iostreams should @@ -72,8 +72,8 @@ Header files will typically contain the definition of a (single) class. These header files should have as few include statements as possible. This is particularly important for classes that implement a "style" and thus use a macro of the kind `SomeStyle(some/name,SomeName)`. These will -be all included in the auto-generated `"some_style.h"` files which will -result in a high potential for direct or indirect symbol name clashes. +all be included in the auto-generated `"some_style.h"` files which +results in a high potential for direct or indirect symbol name clashes. In the ideal case, the header would only include one file defining the parent class. That would typically be either `#include "pointers.h"` for @@ -85,7 +85,7 @@ be employed. The full definition will then be included into the corresponding implementation file. In the given example from above, the header file would be called `some_name.h` and the implementation `some_name.cpp` (all lower case with underscores, while the class itself would be in camel case -and no underscores, and the style name with lower case names separated by +and no underscores `SomeName`, and the style name with lower case names separated by a forward slash). ### Implementation Files @@ -124,9 +124,9 @@ which include files should be added or removed. ## Legacy Code -A lot of code predates the application of the rules in this document, -and those rules are a moving target as well. So there is going to be -significant chunks of code, that does not fully comply. This applies +A lot of code predates the application of the rules in this document +and the rules themselves are a moving target. So there are going to be +significant chunks of code that do not fully comply. This applies for example to the USER-REAXC, or the USER-ATC package. The LAMMPS developers are dedicated to make an effort to improve the compliance and welcome volunteers wanting to help with the process. From 5d4016c285a1ff930a1e2dfaea055a0bc9f6e74b Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 5 Jul 2019 14:42:46 -0400 Subject: [PATCH 44/79] cleaning up includes of ASPHERE package --- src/ASPHERE/compute_erotate_asphere.cpp | 1 - src/ASPHERE/compute_temp_asphere.cpp | 1 - src/ASPHERE/fix_nh_asphere.cpp | 5 ----- src/ASPHERE/fix_nve_asphere.cpp | 6 ------ src/ASPHERE/fix_nve_asphere_noforce.cpp | 6 ------ src/ASPHERE/fix_nve_line.cpp | 3 --- src/ASPHERE/fix_nve_tri.cpp | 3 --- src/ASPHERE/pair_gayberne.cpp | 5 +---- 8 files changed, 1 insertion(+), 29 deletions(-) diff --git a/src/ASPHERE/compute_erotate_asphere.cpp b/src/ASPHERE/compute_erotate_asphere.cpp index 665506acdf..3cf23b87eb 100644 --- a/src/ASPHERE/compute_erotate_asphere.cpp +++ b/src/ASPHERE/compute_erotate_asphere.cpp @@ -20,7 +20,6 @@ #include "atom_vec_tri.h" #include "update.h" #include "force.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/ASPHERE/compute_temp_asphere.cpp b/src/ASPHERE/compute_temp_asphere.cpp index 32773b2925..d591e2ca81 100644 --- a/src/ASPHERE/compute_temp_asphere.cpp +++ b/src/ASPHERE/compute_temp_asphere.cpp @@ -26,7 +26,6 @@ #include "domain.h" #include "modify.h" #include "group.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/ASPHERE/fix_nh_asphere.cpp b/src/ASPHERE/fix_nh_asphere.cpp index 9e8e9d73d9..2f8f11978e 100644 --- a/src/ASPHERE/fix_nh_asphere.cpp +++ b/src/ASPHERE/fix_nh_asphere.cpp @@ -16,14 +16,9 @@ ------------------------------------------------------------------------- */ #include "fix_nh_asphere.h" -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" -#include "group.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/ASPHERE/fix_nve_asphere.cpp b/src/ASPHERE/fix_nve_asphere.cpp index 05219e442f..93ccf008f4 100644 --- a/src/ASPHERE/fix_nve_asphere.cpp +++ b/src/ASPHERE/fix_nve_asphere.cpp @@ -16,15 +16,9 @@ ------------------------------------------------------------------------- */ #include "fix_nve_asphere.h" -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" -#include "force.h" -#include "update.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/ASPHERE/fix_nve_asphere_noforce.cpp b/src/ASPHERE/fix_nve_asphere_noforce.cpp index 015cc8cfb6..3a7d7e86e9 100644 --- a/src/ASPHERE/fix_nve_asphere_noforce.cpp +++ b/src/ASPHERE/fix_nve_asphere_noforce.cpp @@ -12,15 +12,9 @@ ------------------------------------------------------------------------- */ #include "fix_nve_asphere_noforce.h" -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" -#include "group.h" -#include "update.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/ASPHERE/fix_nve_line.cpp b/src/ASPHERE/fix_nve_line.cpp index 57335f22e0..5e17cb355f 100644 --- a/src/ASPHERE/fix_nve_line.cpp +++ b/src/ASPHERE/fix_nve_line.cpp @@ -12,9 +12,6 @@ ------------------------------------------------------------------------- */ #include "fix_nve_line.h" -#include -#include -#include #include "atom.h" #include "atom_vec_line.h" #include "domain.h" diff --git a/src/ASPHERE/fix_nve_tri.cpp b/src/ASPHERE/fix_nve_tri.cpp index b1f7667d06..797fea1c5b 100644 --- a/src/ASPHERE/fix_nve_tri.cpp +++ b/src/ASPHERE/fix_nve_tri.cpp @@ -12,9 +12,6 @@ ------------------------------------------------------------------------- */ #include "fix_nve_tri.h" -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_tri.h" diff --git a/src/ASPHERE/pair_gayberne.cpp b/src/ASPHERE/pair_gayberne.cpp index 7dbf11c5ea..93b164c503 100644 --- a/src/ASPHERE/pair_gayberne.cpp +++ b/src/ASPHERE/pair_gayberne.cpp @@ -16,10 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_gayberne.h" +#include #include -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" @@ -27,7 +25,6 @@ #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "integrate.h" #include "citeme.h" #include "memory.h" #include "error.h" From 2c0eeeb976075e6df3fc5362d2e06566cc20821c Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 5 Jul 2019 14:43:20 -0400 Subject: [PATCH 45/79] one more chunk of files in src folder to be cleaned up --- src/universe.cpp | 1 - src/update.cpp | 5 ----- src/utils.cpp | 1 - src/velocity.cpp | 4 ---- src/verlet.cpp | 3 --- src/write_coeff.cpp | 1 + src/write_data.cpp | 1 - src/write_dump.cpp | 4 +--- 8 files changed, 2 insertions(+), 18 deletions(-) diff --git a/src/universe.cpp b/src/universe.cpp index 2a7117da51..a36b67d115 100644 --- a/src/universe.cpp +++ b/src/universe.cpp @@ -16,7 +16,6 @@ #include #include #include -#include #include "version.h" #include "error.h" #include "force.h" diff --git a/src/update.cpp b/src/update.cpp index e83f4d9f72..8a3e6f0d1d 100644 --- a/src/update.cpp +++ b/src/update.cpp @@ -13,21 +13,16 @@ #include "update.h" #include -#include #include "integrate.h" #include "min.h" #include "style_integrate.h" #include "style_minimize.h" #include "neighbor.h" -#include "neigh_list.h" #include "force.h" #include "modify.h" #include "fix.h" -#include "domain.h" -#include "region.h" #include "compute.h" #include "output.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/utils.cpp b/src/utils.cpp index ea2ab57f6f..f45a834bec 100644 --- a/src/utils.cpp +++ b/src/utils.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "utils.h" -#include #include #include "lammps.h" #include "error.h" diff --git a/src/velocity.cpp b/src/velocity.cpp index 1a03f71128..e5985884f8 100644 --- a/src/velocity.cpp +++ b/src/velocity.cpp @@ -12,13 +12,9 @@ ------------------------------------------------------------------------- */ #include "velocity.h" -#include #include -#include -#include #include #include "atom.h" -#include "update.h" #include "domain.h" #include "lattice.h" #include "input.h" diff --git a/src/verlet.cpp b/src/verlet.cpp index 5ccef36259..8cd6fe940d 100644 --- a/src/verlet.cpp +++ b/src/verlet.cpp @@ -28,10 +28,7 @@ #include "output.h" #include "update.h" #include "modify.h" -#include "compute.h" -#include "fix.h" #include "timer.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/write_coeff.cpp b/src/write_coeff.cpp index 08ff964e7c..8e5b4fcb71 100644 --- a/src/write_coeff.cpp +++ b/src/write_coeff.cpp @@ -14,6 +14,7 @@ #include "write_coeff.h" #include #include +#include #include #include "pair.h" #include "bond.h" diff --git a/src/write_data.cpp b/src/write_data.cpp index b78e701d35..3d788b9665 100644 --- a/src/write_data.cpp +++ b/src/write_data.cpp @@ -16,7 +16,6 @@ #include #include "atom.h" #include "atom_vec.h" -#include "group.h" #include "force.h" #include "pair.h" #include "bond.h" diff --git a/src/write_dump.cpp b/src/write_dump.cpp index 903f0e0cdd..31ceb4cbbf 100644 --- a/src/write_dump.cpp +++ b/src/write_dump.cpp @@ -17,13 +17,11 @@ #include "write_dump.h" #include +#include #include "style_dump.h" #include "dump.h" #include "dump_image.h" -#include "atom.h" #include "comm.h" -#include "group.h" -#include "input.h" #include "update.h" #include "error.h" #include "utils.h" From 4db483339504396f084bf269db6b06862f2025cb Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 5 Jul 2019 21:11:06 -0400 Subject: [PATCH 46/79] fix up includes for BODY package --- src/BODY/body_rounded_polygon.cpp | 2 +- src/BODY/body_rounded_polyhedron.cpp | 2 +- src/BODY/compute_body_local.cpp | 4 +--- src/BODY/compute_temp_body.cpp | 1 - src/BODY/fix_nh_body.cpp | 5 ----- src/BODY/fix_nve_body.cpp | 6 ------ src/BODY/fix_wall_body_polygon.cpp | 4 ---- src/BODY/fix_wall_body_polyhedron.cpp | 4 ---- src/BODY/pair_body_nparticle.cpp | 2 -- src/BODY/pair_body_rounded_polygon.cpp | 3 +-- src/BODY/pair_body_rounded_polyhedron.cpp | 5 +---- 11 files changed, 5 insertions(+), 33 deletions(-) diff --git a/src/BODY/body_rounded_polygon.cpp b/src/BODY/body_rounded_polygon.cpp index 21f1d7e221..caf7e4bb8c 100644 --- a/src/BODY/body_rounded_polygon.cpp +++ b/src/BODY/body_rounded_polygon.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "body_rounded_polygon.h" +#include #include -#include #include "my_pool_chunk.h" #include "atom_vec_body.h" #include "atom.h" diff --git a/src/BODY/body_rounded_polyhedron.cpp b/src/BODY/body_rounded_polyhedron.cpp index 15e1871e02..98f7913859 100644 --- a/src/BODY/body_rounded_polyhedron.cpp +++ b/src/BODY/body_rounded_polyhedron.cpp @@ -16,13 +16,13 @@ ------------------------------------------------------------------------- */ #include "body_rounded_polyhedron.h" +#include #include #include #include "my_pool_chunk.h" #include "atom_vec_body.h" #include "atom.h" #include "force.h" -#include "domain.h" #include "math_extra.h" #include "memory.h" #include "error.h" diff --git a/src/BODY/compute_body_local.cpp b/src/BODY/compute_body_local.cpp index f58b66c2ca..c12502df42 100644 --- a/src/BODY/compute_body_local.cpp +++ b/src/BODY/compute_body_local.cpp @@ -12,15 +12,13 @@ ------------------------------------------------------------------------- */ #include "compute_body_local.h" -#include +#include #include #include "atom.h" #include "atom_vec_body.h" #include "body.h" #include "update.h" -#include "domain.h" #include "force.h" -#include "bond.h" #include "memory.h" #include "error.h" diff --git a/src/BODY/compute_temp_body.cpp b/src/BODY/compute_temp_body.cpp index 7beca36df8..d9007f573d 100644 --- a/src/BODY/compute_temp_body.cpp +++ b/src/BODY/compute_temp_body.cpp @@ -27,7 +27,6 @@ #include "domain.h" #include "modify.h" #include "group.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/BODY/fix_nh_body.cpp b/src/BODY/fix_nh_body.cpp index 6064f1f9de..b9a0c81e15 100644 --- a/src/BODY/fix_nh_body.cpp +++ b/src/BODY/fix_nh_body.cpp @@ -17,14 +17,9 @@ ------------------------------------------------------------------------- */ #include "fix_nh_body.h" -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" -#include "group.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/BODY/fix_nve_body.cpp b/src/BODY/fix_nve_body.cpp index 3f3bd41cbc..185e397540 100644 --- a/src/BODY/fix_nve_body.cpp +++ b/src/BODY/fix_nve_body.cpp @@ -12,15 +12,9 @@ ------------------------------------------------------------------------- */ #include "fix_nve_body.h" -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" -#include "force.h" -#include "update.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/BODY/fix_wall_body_polygon.cpp b/src/BODY/fix_wall_body_polygon.cpp index 8f27a094cb..e51476de60 100644 --- a/src/BODY/fix_wall_body_polygon.cpp +++ b/src/BODY/fix_wall_body_polygon.cpp @@ -17,7 +17,6 @@ #include "fix_wall_body_polygon.h" #include -#include #include #include "atom.h" #include "atom_vec_body.h" @@ -25,9 +24,6 @@ #include "domain.h" #include "update.h" #include "force.h" -#include "pair.h" -#include "modify.h" -#include "respa.h" #include "math_const.h" #include "math_extra.h" #include "memory.h" diff --git a/src/BODY/fix_wall_body_polyhedron.cpp b/src/BODY/fix_wall_body_polyhedron.cpp index 37b542803f..42c62de436 100644 --- a/src/BODY/fix_wall_body_polyhedron.cpp +++ b/src/BODY/fix_wall_body_polyhedron.cpp @@ -17,7 +17,6 @@ #include "fix_wall_body_polyhedron.h" #include -#include #include #include "atom.h" #include "atom_vec_body.h" @@ -25,9 +24,6 @@ #include "domain.h" #include "update.h" #include "force.h" -#include "pair.h" -#include "modify.h" -#include "respa.h" #include "math_const.h" #include "math_extra.h" #include "memory.h" diff --git a/src/BODY/pair_body_nparticle.cpp b/src/BODY/pair_body_nparticle.cpp index 96a7af6255..bd7aba5455 100644 --- a/src/BODY/pair_body_nparticle.cpp +++ b/src/BODY/pair_body_nparticle.cpp @@ -13,8 +13,6 @@ #include "pair_body_nparticle.h" #include -#include -#include #include #include "math_extra.h" #include "atom.h" diff --git a/src/BODY/pair_body_rounded_polygon.cpp b/src/BODY/pair_body_rounded_polygon.cpp index c818b5a2e6..f5e18e9d89 100644 --- a/src/BODY/pair_body_rounded_polygon.cpp +++ b/src/BODY/pair_body_rounded_polygon.cpp @@ -19,9 +19,8 @@ ------------------------------------------------------------------------- */ #include "pair_body_rounded_polygon.h" +#include #include -#include -#include #include #include "math_extra.h" #include "atom.h" diff --git a/src/BODY/pair_body_rounded_polyhedron.cpp b/src/BODY/pair_body_rounded_polyhedron.cpp index 75caab88bd..2df58d45cd 100644 --- a/src/BODY/pair_body_rounded_polyhedron.cpp +++ b/src/BODY/pair_body_rounded_polyhedron.cpp @@ -21,11 +21,9 @@ ------------------------------------------------------------------------- */ #include "pair_body_rounded_polyhedron.h" +#include #include -#include -#include #include -#include "math_extra.h" #include "atom.h" #include "atom_vec_body.h" #include "body_rounded_polyhedron.h" @@ -41,7 +39,6 @@ #include "math_const.h" using namespace LAMMPS_NS; -using namespace MathExtra; using namespace MathConst; #define DELTA 10000 From a00d38572e425f7734cfd651959b760b36eb6b12 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sat, 6 Jul 2019 06:29:22 -0400 Subject: [PATCH 47/79] clean up includes in packages CLASS2, COLLOID, COMPRESS, and CORESHELL --- src/CLASS2/angle_class2.cpp | 2 +- src/CLASS2/bond_class2.cpp | 3 +-- src/CLASS2/dihedral_class2.cpp | 3 +-- src/CLASS2/improper_class2.cpp | 3 +-- src/CLASS2/pair_lj_class2.cpp | 4 +--- src/CLASS2/pair_lj_class2_coul_cut.cpp | 3 +-- src/CLASS2/pair_lj_class2_coul_long.cpp | 4 +--- src/COLLOID/fix_wall_colloid.cpp | 4 +--- src/COLLOID/pair_brownian.cpp | 6 +----- src/COLLOID/pair_brownian_poly.cpp | 7 +------ src/COLLOID/pair_colloid.cpp | 5 +---- src/COLLOID/pair_lubricate.cpp | 6 +----- src/COLLOID/pair_lubricateU.cpp | 5 ----- src/COLLOID/pair_lubricateU_poly.cpp | 5 ----- src/COLLOID/pair_lubricate_poly.cpp | 6 +----- src/COLLOID/pair_yukawa_colloid.cpp | 3 --- src/COMPRESS/dump_xyz_gz.cpp | 1 - src/CORESHELL/compute_temp_cs.cpp | 3 --- src/CORESHELL/pair_born_coul_dsf_cs.cpp | 6 ------ src/CORESHELL/pair_born_coul_long_cs.cpp | 9 --------- src/CORESHELL/pair_born_coul_wolf_cs.cpp | 8 -------- src/CORESHELL/pair_buck_coul_long_cs.cpp | 10 ---------- src/CORESHELL/pair_coul_long_cs.cpp | 11 ----------- src/CORESHELL/pair_coul_wolf_cs.cpp | 8 -------- src/CORESHELL/pair_lj_cut_coul_long_cs.cpp | 14 -------------- 25 files changed, 13 insertions(+), 126 deletions(-) diff --git a/src/CLASS2/angle_class2.cpp b/src/CLASS2/angle_class2.cpp index 340152abd4..99e1b39c9d 100644 --- a/src/CLASS2/angle_class2.cpp +++ b/src/CLASS2/angle_class2.cpp @@ -16,9 +16,9 @@ ------------------------------------------------------------------------- */ #include "angle_class2.h" +#include #include #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/CLASS2/bond_class2.cpp b/src/CLASS2/bond_class2.cpp index 945555f772..cfc1a93bde 100644 --- a/src/CLASS2/bond_class2.cpp +++ b/src/CLASS2/bond_class2.cpp @@ -16,11 +16,10 @@ ------------------------------------------------------------------------- */ #include "bond_class2.h" +#include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/CLASS2/dihedral_class2.cpp b/src/CLASS2/dihedral_class2.cpp index c36d976525..725228666e 100644 --- a/src/CLASS2/dihedral_class2.cpp +++ b/src/CLASS2/dihedral_class2.cpp @@ -16,13 +16,12 @@ ------------------------------------------------------------------------- */ #include "dihedral_class2.h" +#include #include #include -#include #include "atom.h" #include "neighbor.h" #include "update.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "math_const.h" diff --git a/src/CLASS2/improper_class2.cpp b/src/CLASS2/improper_class2.cpp index aff37df318..ca7ac95239 100644 --- a/src/CLASS2/improper_class2.cpp +++ b/src/CLASS2/improper_class2.cpp @@ -16,13 +16,12 @@ ------------------------------------------------------------------------- */ #include "improper_class2.h" +#include #include #include -#include #include "atom.h" #include "neighbor.h" #include "update.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "math_const.h" diff --git a/src/CLASS2/pair_lj_class2.cpp b/src/CLASS2/pair_lj_class2.cpp index 9a67fafecb..a0088e52b7 100644 --- a/src/CLASS2/pair_lj_class2.cpp +++ b/src/CLASS2/pair_lj_class2.cpp @@ -10,9 +10,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_class2.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" @@ -21,7 +20,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory.h" diff --git a/src/CLASS2/pair_lj_class2_coul_cut.cpp b/src/CLASS2/pair_lj_class2_coul_cut.cpp index 24620611c6..e999a3682e 100644 --- a/src/CLASS2/pair_lj_class2_coul_cut.cpp +++ b/src/CLASS2/pair_lj_class2_coul_cut.cpp @@ -12,9 +12,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_class2_coul_cut.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/CLASS2/pair_lj_class2_coul_long.cpp b/src/CLASS2/pair_lj_class2_coul_long.cpp index cd11294327..b56c076996 100644 --- a/src/CLASS2/pair_lj_class2_coul_long.cpp +++ b/src/CLASS2/pair_lj_class2_coul_long.cpp @@ -12,16 +12,14 @@ ------------------------------------------------------------------------- */ #include "pair_lj_class2_coul_long.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/COLLOID/fix_wall_colloid.cpp b/src/COLLOID/fix_wall_colloid.cpp index f2e895c4f3..58593a99b1 100644 --- a/src/COLLOID/fix_wall_colloid.cpp +++ b/src/COLLOID/fix_wall_colloid.cpp @@ -16,12 +16,10 @@ ------------------------------------------------------------------------- */ #include "fix_wall_colloid.h" +#include #include -#include #include "atom.h" #include "atom_vec.h" -#include "update.h" -#include "respa.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/COLLOID/pair_brownian.cpp b/src/COLLOID/pair_brownian.cpp index f9185264e0..71a5f8c056 100644 --- a/src/COLLOID/pair_brownian.cpp +++ b/src/COLLOID/pair_brownian.cpp @@ -16,22 +16,18 @@ ------------------------------------------------------------------------- */ #include "pair_brownian.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "domain.h" #include "update.h" #include "modify.h" #include "fix.h" -#include "fix_deform.h" #include "fix_wall.h" #include "input.h" #include "variable.h" diff --git a/src/COLLOID/pair_brownian_poly.cpp b/src/COLLOID/pair_brownian_poly.cpp index 250dcef1fd..c3eb4f28a5 100644 --- a/src/COLLOID/pair_brownian_poly.cpp +++ b/src/COLLOID/pair_brownian_poly.cpp @@ -17,13 +17,10 @@ ------------------------------------------------------------------------- */ #include "pair_brownian_poly.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" @@ -32,14 +29,12 @@ #include "update.h" #include "modify.h" #include "fix.h" -#include "fix_deform.h" #include "fix_wall.h" #include "input.h" #include "variable.h" #include "random_mars.h" #include "math_const.h" #include "math_special.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/COLLOID/pair_colloid.cpp b/src/COLLOID/pair_colloid.cpp index 306cdfebdf..ad25184181 100644 --- a/src/COLLOID/pair_colloid.cpp +++ b/src/COLLOID/pair_colloid.cpp @@ -16,14 +16,11 @@ ------------------------------------------------------------------------- */ #include "pair_colloid.h" +#include #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "math_special.h" #include "memory.h" diff --git a/src/COLLOID/pair_lubricate.cpp b/src/COLLOID/pair_lubricate.cpp index ee55c6cbf5..4492de3cbb 100644 --- a/src/COLLOID/pair_lubricate.cpp +++ b/src/COLLOID/pair_lubricate.cpp @@ -17,17 +17,14 @@ ------------------------------------------------------------------------- */ #include "pair_lubricate.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "domain.h" #include "modify.h" #include "fix.h" @@ -35,7 +32,6 @@ #include "fix_wall.h" #include "input.h" #include "variable.h" -#include "random_mars.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/COLLOID/pair_lubricateU.cpp b/src/COLLOID/pair_lubricateU.cpp index be589167c9..4f7e3917e8 100644 --- a/src/COLLOID/pair_lubricateU.cpp +++ b/src/COLLOID/pair_lubricateU.cpp @@ -18,22 +18,17 @@ #include "pair_lubricateU.h" #include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "domain.h" #include "update.h" #include "math_const.h" #include "modify.h" #include "fix.h" -#include "fix_deform.h" #include "fix_wall.h" #include "input.h" #include "variable.h" diff --git a/src/COLLOID/pair_lubricateU_poly.cpp b/src/COLLOID/pair_lubricateU_poly.cpp index ebcf939cff..0f16d94300 100644 --- a/src/COLLOID/pair_lubricateU_poly.cpp +++ b/src/COLLOID/pair_lubricateU_poly.cpp @@ -20,21 +20,16 @@ #include "pair_lubricateU_poly.h" #include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "domain.h" -#include "update.h" #include "modify.h" #include "fix.h" -#include "fix_deform.h" #include "fix_wall.h" #include "input.h" #include "variable.h" diff --git a/src/COLLOID/pair_lubricate_poly.cpp b/src/COLLOID/pair_lubricate_poly.cpp index f1bfa0c695..e347441cf4 100644 --- a/src/COLLOID/pair_lubricate_poly.cpp +++ b/src/COLLOID/pair_lubricate_poly.cpp @@ -18,12 +18,10 @@ ------------------------------------------------------------------------- */ #include "pair_lubricate_poly.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "force.h" #include "neighbor.h" @@ -33,8 +31,6 @@ #include "modify.h" #include "fix.h" #include "fix_deform.h" -#include "memory.h" -#include "random_mars.h" #include "fix_wall.h" #include "input.h" #include "variable.h" diff --git a/src/COLLOID/pair_yukawa_colloid.cpp b/src/COLLOID/pair_yukawa_colloid.cpp index 98d0586925..1866fa60b5 100644 --- a/src/COLLOID/pair_yukawa_colloid.cpp +++ b/src/COLLOID/pair_yukawa_colloid.cpp @@ -17,14 +17,11 @@ #include "pair_yukawa_colloid.h" #include -#include #include "atom.h" #include "atom_vec.h" #include "force.h" -#include "comm.h" #include "neighbor.h" #include "neigh_list.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/COMPRESS/dump_xyz_gz.cpp b/src/COMPRESS/dump_xyz_gz.cpp index 7be1a10fe2..c76b7afa17 100644 --- a/src/COMPRESS/dump_xyz_gz.cpp +++ b/src/COMPRESS/dump_xyz_gz.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "dump_xyz_gz.h" -#include "domain.h" #include "error.h" #include "update.h" diff --git a/src/CORESHELL/compute_temp_cs.cpp b/src/CORESHELL/compute_temp_cs.cpp index 4217fe3410..cccccaf254 100644 --- a/src/CORESHELL/compute_temp_cs.cpp +++ b/src/CORESHELL/compute_temp_cs.cpp @@ -18,9 +18,7 @@ #include "compute_temp_cs.h" #include -#include #include -#include #include "atom.h" #include "atom_vec.h" #include "domain.h" @@ -28,7 +26,6 @@ #include "force.h" #include "group.h" #include "modify.h" -#include "fix.h" #include "fix_store.h" #include "comm.h" #include "memory.h" diff --git a/src/CORESHELL/pair_born_coul_dsf_cs.cpp b/src/CORESHELL/pair_born_coul_dsf_cs.cpp index cd932e560b..9440bca109 100644 --- a/src/CORESHELL/pair_born_coul_dsf_cs.cpp +++ b/src/CORESHELL/pair_born_coul_dsf_cs.cpp @@ -18,17 +18,11 @@ #include "pair_born_coul_dsf_cs.h" #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "math_const.h" -#include "memory.h" -#include "error.h" #include "math_special.h" using namespace LAMMPS_NS; diff --git a/src/CORESHELL/pair_born_coul_long_cs.cpp b/src/CORESHELL/pair_born_coul_long_cs.cpp index 2ef7fdb273..f6262fa9e7 100644 --- a/src/CORESHELL/pair_born_coul_long_cs.cpp +++ b/src/CORESHELL/pair_born_coul_long_cs.cpp @@ -17,21 +17,12 @@ #include "pair_born_coul_long_cs.h" #include -#include -#include #include #include "atom.h" -#include "comm.h" #include "force.h" -#include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" -#include "math_const.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; #define EWALD_F 1.12837917 #define EWALD_P 9.95473818e-1 diff --git a/src/CORESHELL/pair_born_coul_wolf_cs.cpp b/src/CORESHELL/pair_born_coul_wolf_cs.cpp index c0374e2ddb..398c2ba1ee 100644 --- a/src/CORESHELL/pair_born_coul_wolf_cs.cpp +++ b/src/CORESHELL/pair_born_coul_wolf_cs.cpp @@ -14,22 +14,14 @@ #include "pair_born_coul_wolf_cs.h" #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "math_const.h" -#include "math_special.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; using namespace MathConst; -using namespace MathSpecial; #define EPSILON 1.0e-20 diff --git a/src/CORESHELL/pair_buck_coul_long_cs.cpp b/src/CORESHELL/pair_buck_coul_long_cs.cpp index 6c897622fa..1392ec1880 100644 --- a/src/CORESHELL/pair_buck_coul_long_cs.cpp +++ b/src/CORESHELL/pair_buck_coul_long_cs.cpp @@ -17,21 +17,11 @@ #include "pair_buck_coul_long_cs.h" #include -#include -#include -#include #include "atom.h" -#include "comm.h" #include "force.h" -#include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" -#include "math_const.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; #define EWALD_F 1.12837917 #define EWALD_P 9.95473818e-1 diff --git a/src/CORESHELL/pair_coul_long_cs.cpp b/src/CORESHELL/pair_coul_long_cs.cpp index 6094ae072a..8280799389 100644 --- a/src/CORESHELL/pair_coul_long_cs.cpp +++ b/src/CORESHELL/pair_coul_long_cs.cpp @@ -17,20 +17,9 @@ #include "pair_coul_long_cs.h" #include -#include -#include -#include #include "atom.h" -#include "comm.h" #include "force.h" -#include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/CORESHELL/pair_coul_wolf_cs.cpp b/src/CORESHELL/pair_coul_wolf_cs.cpp index 40ade7bfe4..20b7339480 100644 --- a/src/CORESHELL/pair_coul_wolf_cs.cpp +++ b/src/CORESHELL/pair_coul_wolf_cs.cpp @@ -13,22 +13,14 @@ #include "pair_coul_wolf_cs.h" #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "math_const.h" -#include "math_special.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; using namespace MathConst; -using namespace MathSpecial; #define EPSILON 1.0e-20 diff --git a/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp b/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp index 3f20377cf1..7ad544051a 100644 --- a/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp +++ b/src/CORESHELL/pair_lj_cut_coul_long_cs.cpp @@ -17,25 +17,11 @@ #include "pair_lj_cut_coul_long_cs.h" #include -#include -#include -#include #include "atom.h" -#include "comm.h" #include "force.h" -#include "kspace.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "math_const.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; #define EWALD_F 1.12837917 #define EWALD_P 9.95473818e-1 From 316554297c15d1a5dc62f7d0649c6c5d8a6e9bae Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sat, 6 Jul 2019 10:00:24 -0400 Subject: [PATCH 48/79] clean up includes in packages DIPOLE and GRANULAR --- src/DIPOLE/pair_lj_cut_dipole_cut.cpp | 2 +- src/DIPOLE/pair_lj_cut_dipole_long.cpp | 3 +-- src/DIPOLE/pair_lj_long_dipole_long.cpp | 6 +----- src/GRANULAR/fix_freeze.cpp | 2 +- src/GRANULAR/fix_pour.cpp | 2 +- src/GRANULAR/fix_wall_gran.cpp | 2 -- src/GRANULAR/fix_wall_gran_region.cpp | 7 ------- src/GRANULAR/pair_gran_hertz_history.cpp | 2 -- src/GRANULAR/pair_gran_hooke.cpp | 2 -- src/GRANULAR/pair_gran_hooke_history.cpp | 5 +---- src/GRANULAR/pair_granular.cpp | 5 +---- 11 files changed, 7 insertions(+), 31 deletions(-) diff --git a/src/DIPOLE/pair_lj_cut_dipole_cut.cpp b/src/DIPOLE/pair_lj_cut_dipole_cut.cpp index 44708edec9..14c511c100 100644 --- a/src/DIPOLE/pair_lj_cut_dipole_cut.cpp +++ b/src/DIPOLE/pair_lj_cut_dipole_cut.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_dipole_cut.h" +#include #include -#include #include #include "atom.h" #include "neighbor.h" diff --git a/src/DIPOLE/pair_lj_cut_dipole_long.cpp b/src/DIPOLE/pair_lj_cut_dipole_long.cpp index 071dbaeb02..fe020ed2e6 100644 --- a/src/DIPOLE/pair_lj_cut_dipole_long.cpp +++ b/src/DIPOLE/pair_lj_cut_dipole_long.cpp @@ -12,9 +12,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_dipole_long.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/DIPOLE/pair_lj_long_dipole_long.cpp b/src/DIPOLE/pair_lj_long_dipole_long.cpp index 1391cc1a1a..5e7819c2f4 100644 --- a/src/DIPOLE/pair_lj_long_dipole_long.cpp +++ b/src/DIPOLE/pair_lj_long_dipole_long.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_long_dipole_long.h" +#include #include -#include -#include #include #include "math_const.h" #include "math_vector.h" @@ -26,12 +25,9 @@ #include "comm.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" -#include "respa.h" #include "memory.h" #include "error.h" diff --git a/src/GRANULAR/fix_freeze.cpp b/src/GRANULAR/fix_freeze.cpp index e2345bdf19..1df5c9d0a8 100644 --- a/src/GRANULAR/fix_freeze.cpp +++ b/src/GRANULAR/fix_freeze.cpp @@ -12,11 +12,11 @@ ------------------------------------------------------------------------- */ #include "fix_freeze.h" +#include #include #include "atom.h" #include "update.h" #include "modify.h" -#include "comm.h" #include "respa.h" #include "error.h" diff --git a/src/GRANULAR/fix_pour.cpp b/src/GRANULAR/fix_pour.cpp index 0fe7493127..3b1bbcef35 100644 --- a/src/GRANULAR/fix_pour.cpp +++ b/src/GRANULAR/fix_pour.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include "fix_pour.h" +#include #include -#include #include #include "atom.h" #include "atom_vec.h" diff --git a/src/GRANULAR/fix_wall_gran.cpp b/src/GRANULAR/fix_wall_gran.cpp index b0fbc0c2b8..e7464a78a9 100644 --- a/src/GRANULAR/fix_wall_gran.cpp +++ b/src/GRANULAR/fix_wall_gran.cpp @@ -18,13 +18,11 @@ #include "fix_wall_gran.h" #include -#include #include #include "atom.h" #include "domain.h" #include "update.h" #include "force.h" -#include "pair.h" #include "modify.h" #include "respa.h" #include "math_const.h" diff --git a/src/GRANULAR/fix_wall_gran_region.cpp b/src/GRANULAR/fix_wall_gran_region.cpp index 97e889ddcc..a4b798d6aa 100644 --- a/src/GRANULAR/fix_wall_gran_region.cpp +++ b/src/GRANULAR/fix_wall_gran_region.cpp @@ -16,18 +16,12 @@ ------------------------------------------------------------------------- */ #include "fix_wall_gran_region.h" -#include -#include #include #include "region.h" #include "atom.h" #include "domain.h" #include "update.h" -#include "force.h" #include "pair.h" -#include "modify.h" -#include "respa.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "comm.h" @@ -35,7 +29,6 @@ using namespace LAMMPS_NS; using namespace FixConst; -using namespace MathConst; // same as FixWallGran diff --git a/src/GRANULAR/pair_gran_hertz_history.cpp b/src/GRANULAR/pair_gran_hertz_history.cpp index e303089e56..4a362c0928 100644 --- a/src/GRANULAR/pair_gran_hertz_history.cpp +++ b/src/GRANULAR/pair_gran_hertz_history.cpp @@ -17,8 +17,6 @@ #include "pair_gran_hertz_history.h" #include -#include -#include #include #include "atom.h" #include "update.h" diff --git a/src/GRANULAR/pair_gran_hooke.cpp b/src/GRANULAR/pair_gran_hooke.cpp index a30aa0bb6c..d4be320554 100644 --- a/src/GRANULAR/pair_gran_hooke.cpp +++ b/src/GRANULAR/pair_gran_hooke.cpp @@ -17,8 +17,6 @@ #include "pair_gran_hooke.h" #include -#include -#include #include "atom.h" #include "force.h" #include "fix.h" diff --git a/src/GRANULAR/pair_gran_hooke_history.cpp b/src/GRANULAR/pair_gran_hooke_history.cpp index f832fdfac3..771a5566df 100644 --- a/src/GRANULAR/pair_gran_hooke_history.cpp +++ b/src/GRANULAR/pair_gran_hooke_history.cpp @@ -16,13 +16,10 @@ ------------------------------------------------------------------------- */ #include "pair_gran_hooke_history.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" -#include "domain.h" #include "force.h" #include "update.h" #include "modify.h" diff --git a/src/GRANULAR/pair_granular.cpp b/src/GRANULAR/pair_granular.cpp index 942587a676..e7b4c01f5e 100644 --- a/src/GRANULAR/pair_granular.cpp +++ b/src/GRANULAR/pair_granular.cpp @@ -17,13 +17,10 @@ See the README file in the top-level LAMMPS directory. ----------------------------------------------------------------------- */ #include "pair_granular.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" -#include "domain.h" #include "force.h" #include "update.h" #include "modify.h" From 61ed3b65b75c3781bce511cc00ff298b023965ab Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sat, 6 Jul 2019 10:20:13 -0400 Subject: [PATCH 49/79] clean up includes in KSPACE package --- src/KSPACE/ewald.cpp | 3 --- src/KSPACE/ewald_dipole.cpp | 5 ----- src/KSPACE/ewald_dipole_spin.cpp | 7 ------- src/KSPACE/ewald_disp.cpp | 2 -- src/KSPACE/gridcomm.cpp | 2 -- src/KSPACE/msm.cpp | 2 -- src/KSPACE/msm_cg.cpp | 5 ----- src/KSPACE/pair_born_coul_long.cpp | 2 -- src/KSPACE/pair_born_coul_msm.cpp | 6 ------ src/KSPACE/pair_coul_long.cpp | 6 +----- src/KSPACE/pair_coul_msm.cpp | 7 ------- src/KSPACE/pair_lj_charmm_coul_long.cpp | 3 --- src/KSPACE/pair_lj_charmm_coul_msm.cpp | 7 ------- src/KSPACE/pair_lj_charmmfsw_coul_long.cpp | 4 ---- src/KSPACE/pair_lj_cut_coul_long.cpp | 3 --- src/KSPACE/pair_lj_cut_coul_msm.cpp | 9 --------- src/KSPACE/pair_lj_cut_tip4p_long.cpp | 7 +------ src/KSPACE/pair_lj_long_coul_long.cpp | 4 +--- src/KSPACE/pair_lj_long_tip4p_long.cpp | 7 +------ src/KSPACE/pair_tip4p_long.cpp | 7 +------ src/KSPACE/pppm.cpp | 2 -- src/KSPACE/pppm_cg.cpp | 2 +- src/KSPACE/pppm_dipole.cpp | 5 ----- src/KSPACE/pppm_dipole_spin.cpp | 10 ---------- src/KSPACE/pppm_disp.cpp | 2 -- src/KSPACE/pppm_disp_tip4p.cpp | 1 - src/KSPACE/pppm_stagger.cpp | 3 --- src/KSPACE/pppm_tip4p.cpp | 2 +- src/KSPACE/remap.cpp | 1 + 29 files changed, 8 insertions(+), 118 deletions(-) diff --git a/src/KSPACE/ewald.cpp b/src/KSPACE/ewald.cpp index aad0e364d0..d74d90b0d6 100644 --- a/src/KSPACE/ewald.cpp +++ b/src/KSPACE/ewald.cpp @@ -20,9 +20,6 @@ #include "ewald.h" #include -#include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/KSPACE/ewald_dipole.cpp b/src/KSPACE/ewald_dipole.cpp index 53bac0637f..c3442beef5 100644 --- a/src/KSPACE/ewald_dipole.cpp +++ b/src/KSPACE/ewald_dipole.cpp @@ -17,8 +17,6 @@ #include "ewald_dipole.h" #include -#include -#include #include #include #include "atom.h" @@ -32,9 +30,6 @@ #include "error.h" #include "update.h" -#include "math_const.h" -#include "math_special.h" - using namespace LAMMPS_NS; using namespace MathConst; using namespace MathSpecial; diff --git a/src/KSPACE/ewald_dipole_spin.cpp b/src/KSPACE/ewald_dipole_spin.cpp index 2b6c95f174..e7d67680a1 100644 --- a/src/KSPACE/ewald_dipole_spin.cpp +++ b/src/KSPACE/ewald_dipole_spin.cpp @@ -17,8 +17,6 @@ #include "ewald_dipole_spin.h" #include -#include -#include #include #include #include "atom.h" @@ -27,17 +25,12 @@ #include "pair.h" #include "domain.h" #include "math_const.h" -#include "math_special.h" #include "memory.h" #include "error.h" #include "update.h" -#include "math_const.h" -#include "math_special.h" - using namespace LAMMPS_NS; using namespace MathConst; -using namespace MathSpecial; #define SMALL 0.00001 diff --git a/src/KSPACE/ewald_disp.cpp b/src/KSPACE/ewald_disp.cpp index c775056dd8..a7ac66fdd3 100644 --- a/src/KSPACE/ewald_disp.cpp +++ b/src/KSPACE/ewald_disp.cpp @@ -18,8 +18,6 @@ #include "ewald_disp.h" #include #include -#include -#include #include #include "math_vector.h" #include "math_const.h" diff --git a/src/KSPACE/gridcomm.cpp b/src/KSPACE/gridcomm.cpp index 552d80daab..368e7370fe 100644 --- a/src/KSPACE/gridcomm.cpp +++ b/src/KSPACE/gridcomm.cpp @@ -13,10 +13,8 @@ #include "gridcomm.h" #include -#include "comm.h" #include "kspace.h" #include "memory.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/KSPACE/msm.cpp b/src/KSPACE/msm.cpp index bc5360dcd2..81dbabdbbd 100644 --- a/src/KSPACE/msm.cpp +++ b/src/KSPACE/msm.cpp @@ -18,8 +18,6 @@ #include "msm.h" #include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/KSPACE/msm_cg.cpp b/src/KSPACE/msm_cg.cpp index 22976b8442..9119d51878 100644 --- a/src/KSPACE/msm_cg.cpp +++ b/src/KSPACE/msm_cg.cpp @@ -18,8 +18,6 @@ #include "msm_cg.h" #include #include -#include -#include #include #include "atom.h" #include "gridcomm.h" @@ -29,10 +27,7 @@ #include "neighbor.h" #include "memory.h" -#include "math_const.h" - using namespace LAMMPS_NS; -using namespace MathConst; #define OFFSET 16384 #define SMALLQ 0.00001 diff --git a/src/KSPACE/pair_born_coul_long.cpp b/src/KSPACE/pair_born_coul_long.cpp index cb8360e401..e248a24ef7 100644 --- a/src/KSPACE/pair_born_coul_long.cpp +++ b/src/KSPACE/pair_born_coul_long.cpp @@ -17,8 +17,6 @@ #include "pair_born_coul_long.h" #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/KSPACE/pair_born_coul_msm.cpp b/src/KSPACE/pair_born_coul_msm.cpp index deaf224334..7300cd92e0 100644 --- a/src/KSPACE/pair_born_coul_msm.cpp +++ b/src/KSPACE/pair_born_coul_msm.cpp @@ -17,21 +17,15 @@ #include "pair_born_coul_msm.h" #include -#include -#include #include #include "atom.h" -#include "comm.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/KSPACE/pair_coul_long.cpp b/src/KSPACE/pair_coul_long.cpp index cb45b7a906..7cedf3d003 100644 --- a/src/KSPACE/pair_coul_long.cpp +++ b/src/KSPACE/pair_coul_long.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_coul_long.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" @@ -26,9 +25,6 @@ #include "kspace.h" #include "neighbor.h" #include "neigh_list.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pair_coul_msm.cpp b/src/KSPACE/pair_coul_msm.cpp index 2173171e79..0917bb9275 100644 --- a/src/KSPACE/pair_coul_msm.cpp +++ b/src/KSPACE/pair_coul_msm.cpp @@ -17,18 +17,11 @@ #include "pair_coul_msm.h" #include -#include -#include #include #include "atom.h" -#include "comm.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pair_lj_charmm_coul_long.cpp b/src/KSPACE/pair_lj_charmm_coul_long.cpp index 3ad14c8ea7..751ee77388 100644 --- a/src/KSPACE/pair_lj_charmm_coul_long.cpp +++ b/src/KSPACE/pair_lj_charmm_coul_long.cpp @@ -17,15 +17,12 @@ #include "pair_lj_charmm_coul_long.h" #include -#include -#include #include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/KSPACE/pair_lj_charmm_coul_msm.cpp b/src/KSPACE/pair_lj_charmm_coul_msm.cpp index 2d1775802f..804ae5919d 100644 --- a/src/KSPACE/pair_lj_charmm_coul_msm.cpp +++ b/src/KSPACE/pair_lj_charmm_coul_msm.cpp @@ -17,19 +17,12 @@ #include "pair_lj_charmm_coul_msm.h" #include -#include -#include #include #include "atom.h" -#include "comm.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp b/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp index 7f32613cba..494a349768 100644 --- a/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp +++ b/src/KSPACE/pair_lj_charmmfsw_coul_long.cpp @@ -21,16 +21,12 @@ #include "pair_lj_charmmfsw_coul_long.h" #include -#include -#include #include #include "atom.h" -#include "update.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/KSPACE/pair_lj_cut_coul_long.cpp b/src/KSPACE/pair_lj_cut_coul_long.cpp index 59f4766fa3..7921c814c3 100644 --- a/src/KSPACE/pair_lj_cut_coul_long.cpp +++ b/src/KSPACE/pair_lj_cut_coul_long.cpp @@ -17,15 +17,12 @@ #include "pair_lj_cut_coul_long.h" #include -#include -#include #include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/KSPACE/pair_lj_cut_coul_msm.cpp b/src/KSPACE/pair_lj_cut_coul_msm.cpp index 1305d485da..f8021cc180 100644 --- a/src/KSPACE/pair_lj_cut_coul_msm.cpp +++ b/src/KSPACE/pair_lj_cut_coul_msm.cpp @@ -17,25 +17,16 @@ #include "pair_lj_cut_coul_msm.h" #include -#include -#include #include #include "atom.h" -#include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" -#include "respa.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/KSPACE/pair_lj_cut_tip4p_long.cpp b/src/KSPACE/pair_lj_cut_tip4p_long.cpp index cd9b3c032d..c98092f19b 100644 --- a/src/KSPACE/pair_lj_cut_tip4p_long.cpp +++ b/src/KSPACE/pair_lj_cut_tip4p_long.cpp @@ -17,9 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_tip4p_long.h" +#include #include -#include -#include #include #include "angle.h" #include "atom.h" @@ -27,12 +26,8 @@ #include "comm.h" #include "domain.h" #include "force.h" -#include "kspace.h" -#include "update.h" -#include "respa.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pair_lj_long_coul_long.cpp b/src/KSPACE/pair_lj_long_coul_long.cpp index 46dbb60a96..610fc4e89b 100644 --- a/src/KSPACE/pair_lj_long_coul_long.cpp +++ b/src/KSPACE/pair_lj_long_coul_long.cpp @@ -18,9 +18,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_long_coul_long.h" +#include #include -#include -#include #include #include "math_vector.h" #include "atom.h" @@ -31,7 +30,6 @@ #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pair_lj_long_tip4p_long.cpp b/src/KSPACE/pair_lj_long_tip4p_long.cpp index 5a1e347c78..08409dce72 100644 --- a/src/KSPACE/pair_lj_long_tip4p_long.cpp +++ b/src/KSPACE/pair_lj_long_tip4p_long.cpp @@ -17,9 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_long_tip4p_long.h" +#include #include -#include -#include #include #include "angle.h" #include "atom.h" @@ -27,12 +26,8 @@ #include "comm.h" #include "domain.h" #include "force.h" -#include "kspace.h" -#include "update.h" -#include "respa.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pair_tip4p_long.cpp b/src/KSPACE/pair_tip4p_long.cpp index deb8662a8b..2c47f42beb 100644 --- a/src/KSPACE/pair_tip4p_long.cpp +++ b/src/KSPACE/pair_tip4p_long.cpp @@ -17,9 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_tip4p_long.h" +#include #include -#include -#include #include #include "angle.h" #include "atom.h" @@ -27,12 +26,8 @@ #include "comm.h" #include "domain.h" #include "force.h" -#include "kspace.h" -#include "update.h" -#include "respa.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pppm.cpp b/src/KSPACE/pppm.cpp index ae545c5c27..90db943750 100644 --- a/src/KSPACE/pppm.cpp +++ b/src/KSPACE/pppm.cpp @@ -21,8 +21,6 @@ #include "pppm.h" #include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/KSPACE/pppm_cg.cpp b/src/KSPACE/pppm_cg.cpp index f9bd7b0cb4..bd23dedef1 100644 --- a/src/KSPACE/pppm_cg.cpp +++ b/src/KSPACE/pppm_cg.cpp @@ -18,7 +18,6 @@ #include "pppm_cg.h" #include #include -#include #include #include "atom.h" #include "gridcomm.h" @@ -28,6 +27,7 @@ #include "neighbor.h" #include "memory.h" #include "math_const.h" +#include "remap.h" using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/KSPACE/pppm_dipole.cpp b/src/KSPACE/pppm_dipole.cpp index ad03b8205a..0eb761d9be 100644 --- a/src/KSPACE/pppm_dipole.cpp +++ b/src/KSPACE/pppm_dipole.cpp @@ -18,17 +18,12 @@ #include "pppm_dipole.h" #include #include -#include -#include #include #include "atom.h" #include "comm.h" #include "gridcomm.h" -#include "neighbor.h" #include "force.h" #include "pair.h" -#include "bond.h" -#include "angle.h" #include "domain.h" #include "fft3d_wrap.h" #include "remap_wrap.h" diff --git a/src/KSPACE/pppm_dipole_spin.cpp b/src/KSPACE/pppm_dipole_spin.cpp index 2c96eadde1..9e9f07322c 100644 --- a/src/KSPACE/pppm_dipole_spin.cpp +++ b/src/KSPACE/pppm_dipole_spin.cpp @@ -18,30 +18,20 @@ #include "pppm_dipole_spin.h" #include #include -#include -#include -#include #include "atom.h" #include "comm.h" #include "gridcomm.h" -#include "neighbor.h" #include "force.h" #include "pair.h" -#include "bond.h" -#include "angle.h" #include "domain.h" -#include "fft3d_wrap.h" -#include "remap_wrap.h" #include "memory.h" #include "error.h" #include "update.h" #include "math_const.h" -#include "math_special.h" using namespace LAMMPS_NS; using namespace MathConst; -using namespace MathSpecial; #define MAXORDER 7 #define OFFSET 16384 diff --git a/src/KSPACE/pppm_disp.cpp b/src/KSPACE/pppm_disp.cpp index 22e570049c..d936025d04 100644 --- a/src/KSPACE/pppm_disp.cpp +++ b/src/KSPACE/pppm_disp.cpp @@ -19,8 +19,6 @@ #include "pppm_disp.h" #include #include -#include -#include #include #include "math_const.h" #include "atom.h" diff --git a/src/KSPACE/pppm_disp_tip4p.cpp b/src/KSPACE/pppm_disp_tip4p.cpp index 36e6159131..bc46152e2b 100644 --- a/src/KSPACE/pppm_disp_tip4p.cpp +++ b/src/KSPACE/pppm_disp_tip4p.cpp @@ -22,7 +22,6 @@ #include "atom.h" #include "domain.h" #include "force.h" -#include "memory.h" #include "error.h" #include "math_const.h" diff --git a/src/KSPACE/pppm_stagger.cpp b/src/KSPACE/pppm_stagger.cpp index 5c2e2a6098..7b708d0355 100644 --- a/src/KSPACE/pppm_stagger.cpp +++ b/src/KSPACE/pppm_stagger.cpp @@ -18,12 +18,9 @@ #include "pppm_stagger.h" #include #include -#include -#include #include #include "atom.h" #include "gridcomm.h" -#include "force.h" #include "domain.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pppm_tip4p.cpp b/src/KSPACE/pppm_tip4p.cpp index 52a1fb3787..f664a0dca3 100644 --- a/src/KSPACE/pppm_tip4p.cpp +++ b/src/KSPACE/pppm_tip4p.cpp @@ -16,11 +16,11 @@ ------------------------------------------------------------------------- */ #include "pppm_tip4p.h" +#include #include #include "atom.h" #include "domain.h" #include "force.h" -#include "memory.h" #include "error.h" #include "math_const.h" diff --git a/src/KSPACE/remap.cpp b/src/KSPACE/remap.cpp index 85fe78c9d7..d4cfdea2b0 100644 --- a/src/KSPACE/remap.cpp +++ b/src/KSPACE/remap.cpp @@ -12,6 +12,7 @@ ------------------------------------------------------------------------- */ #include "remap.h" +#include #include #include From 35e2401099f2332e1a65d3a26c23fe685e1b06e5 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 7 Jul 2019 03:56:44 -0400 Subject: [PATCH 50/79] clean up includes in MANYBODY package --- src/MANYBODY/fix_qeq_comb.cpp | 3 - src/MANYBODY/pair_adp.cpp | 2 +- src/MANYBODY/pair_airebo.cpp | 5 -- src/MANYBODY/pair_airebo.h | 1 - src/MANYBODY/pair_airebo_morse.cpp | 2 - src/MANYBODY/pair_atm.cpp | 1 + src/MANYBODY/pair_bop.cpp | 7 +- src/MANYBODY/pair_bop.h | 100 +++++++++++--------------- src/MANYBODY/pair_comb.cpp | 3 +- src/MANYBODY/pair_comb.h | 1 - src/MANYBODY/pair_comb3.cpp | 4 +- src/MANYBODY/pair_comb3.h | 1 - src/MANYBODY/pair_eam.cpp | 2 +- src/MANYBODY/pair_eam_alloy.cpp | 3 +- src/MANYBODY/pair_eam_cd.cpp | 3 +- src/MANYBODY/pair_eam_fs.cpp | 3 +- src/MANYBODY/pair_eim.cpp | 3 +- src/MANYBODY/pair_gw.cpp | 2 +- src/MANYBODY/pair_gw_zbl.cpp | 5 +- src/MANYBODY/pair_lcbop.cpp | 23 +----- src/MANYBODY/pair_lcbop.h | 1 - src/MANYBODY/pair_nb3b_harmonic.cpp | 4 +- src/MANYBODY/pair_polymorphic.cpp | 5 +- src/MANYBODY/pair_rebo.cpp | 2 +- src/MANYBODY/pair_sw.cpp | 10 ++- src/MANYBODY/pair_tersoff.cpp | 2 +- src/MANYBODY/pair_tersoff_mod.cpp | 8 +-- src/MANYBODY/pair_tersoff_mod_c.cpp | 8 +-- src/MANYBODY/pair_tersoff_zbl.cpp | 7 +- src/MANYBODY/pair_vashishta.cpp | 10 ++- src/MANYBODY/pair_vashishta_table.cpp | 9 +-- 31 files changed, 76 insertions(+), 164 deletions(-) diff --git a/src/MANYBODY/fix_qeq_comb.cpp b/src/MANYBODY/fix_qeq_comb.cpp index 9e9bbcc9d6..2f324bf097 100644 --- a/src/MANYBODY/fix_qeq_comb.cpp +++ b/src/MANYBODY/fix_qeq_comb.cpp @@ -18,13 +18,10 @@ #include "fix_qeq_comb.h" #include #include -#include #include #include "pair_comb.h" #include "pair_comb3.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/MANYBODY/pair_adp.cpp b/src/MANYBODY/pair_adp.cpp index 8051f97634..64c778659c 100644 --- a/src/MANYBODY/pair_adp.cpp +++ b/src/MANYBODY/pair_adp.cpp @@ -17,8 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_adp.h" +#include #include -#include #include #include #include "atom.h" diff --git a/src/MANYBODY/pair_airebo.cpp b/src/MANYBODY/pair_airebo.cpp index fd2016b7a7..818663222f 100644 --- a/src/MANYBODY/pair_airebo.cpp +++ b/src/MANYBODY/pair_airebo.cpp @@ -22,26 +22,21 @@ #include "pair_airebo.h" #include -#include -#include #include #include #include "atom.h" #include "neighbor.h" #include "force.h" #include "comm.h" -#include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "my_page.h" -#include "math_const.h" #include "math_special.h" #include "memory.h" #include "error.h" #include "utils.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace MathSpecial; #define MAXLINE 1024 diff --git a/src/MANYBODY/pair_airebo.h b/src/MANYBODY/pair_airebo.h index 8e92807afb..04d3fc399f 100644 --- a/src/MANYBODY/pair_airebo.h +++ b/src/MANYBODY/pair_airebo.h @@ -21,7 +21,6 @@ PairStyle(airebo,PairAIREBO) #define LMP_PAIR_AIREBO_H #include "pair.h" -#include "my_page.h" #include #include "math_const.h" diff --git a/src/MANYBODY/pair_airebo_morse.cpp b/src/MANYBODY/pair_airebo_morse.cpp index a39f7df82e..121f9557fd 100644 --- a/src/MANYBODY/pair_airebo_morse.cpp +++ b/src/MANYBODY/pair_airebo_morse.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "pair_airebo_morse.h" -#include "force.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/MANYBODY/pair_atm.cpp b/src/MANYBODY/pair_atm.cpp index ba68033721..e604f44003 100644 --- a/src/MANYBODY/pair_atm.cpp +++ b/src/MANYBODY/pair_atm.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "pair_atm.h" +#include #include #include "atom.h" #include "citeme.h" diff --git a/src/MANYBODY/pair_bop.cpp b/src/MANYBODY/pair_bop.cpp index 27c24ce3d7..38c33e5963 100644 --- a/src/MANYBODY/pair_bop.cpp +++ b/src/MANYBODY/pair_bop.cpp @@ -34,22 +34,17 @@ #include "pair_bop.h" #include -#include -#include #include +#include #include #include "atom.h" #include "neighbor.h" #include "neigh_request.h" #include "force.h" #include "comm.h" -#include "domain.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" -#include using namespace LAMMPS_NS; diff --git a/src/MANYBODY/pair_bop.h b/src/MANYBODY/pair_bop.h index 3bd9b8cea9..eca0ec52b8 100644 --- a/src/MANYBODY/pair_bop.h +++ b/src/MANYBODY/pair_bop.h @@ -26,8 +26,6 @@ PairStyle(bop,PairBOP) #define LMP_PAIR_BOP_H #include "pair.h" -#include -#include "update.h" namespace LAMMPS_NS { @@ -44,20 +42,20 @@ class PairBOP : public Pair { private: int me; - int maxneigh; // maximum size of neighbor list on this processor - int maxneigh3; // maximum size of neighbor list on this processor - int update_list; // check for changing maximum size of neighbor list - int maxbopn; // maximum size of bop neighbor list for allocation - int maxnall; // maximum size of bop neighbor list for allocation - int *map; // mapping from atom types to elements - int nelements; // # of unique elments - int nr; // increments for the BOP pair potential - int ntheta; // increments for the angle function - int npower; // power of the angular function - int nBOt; // second BO increments - int bop_types; // number of elments in potential - int npairs; // number of element pairs - char **elements; // names of unique elements + int maxneigh; // maximum size of neighbor list on this processor + int maxneigh3; // maximum size of neighbor list on this processor + int update_list; // check for changing maximum size of neighbor list + int maxbopn; // maximum size of bop neighbor list for allocation + int maxnall; // maximum size of bop neighbor list for allocation + int *map; // mapping from atom types to elements + int nelements; // # of unique elments + int nr; // increments for the BOP pair potential + int ntheta; // increments for the angle function + int npower; // power of the angular function + int nBOt; // second BO increments + int bop_types; // number of elments in potential + int npairs; // number of element pairs + char **elements; // names of unique elements int ***elem2param; int nparams; int bop_step; @@ -66,23 +64,22 @@ class PairBOP : public Pair { int allocate_neigh; int nb_pi,nb_sg; int ago1; -// int cnt1; - int *BOP_index; // index for neighbor list position - int *BOP_total; // index for neighbor list position - int *BOP_index3; // index for neighbor list position - int *BOP_total3; // index for neighbor list position - int *neigh_index; // index for neighbor list position - int *neigh_index3; // index for neighbor list position - int neigh_total; // total number of neighbors stored - int neigh_total3; // total number of neighbors stored - int *cos_index; // index for neighbor cosine if not using on the fly - int *neigh_flag; // index for neighbor cosine if not using on the fly - int *neigh_flag3; // index for neighbor cosine if not using on the fly - int cos_total; // number of cosines stored if not using on the fly - int neigh_ct; // limit for large arrays + int *BOP_index; // index for neighbor list position + int *BOP_total; // index for neighbor list position + int *BOP_index3; // index for neighbor list position + int *BOP_total3; // index for neighbor list position + int *neigh_index; // index for neighbor list position + int *neigh_index3; // index for neighbor list position + int neigh_total; // total number of neighbors stored + int neigh_total3; // total number of neighbors stored + int *cos_index; // index for neighbor cosine if not using on the fly + int *neigh_flag; // index for neighbor cosine if not using on the fly + int *neigh_flag3; // index for neighbor cosine if not using on the fly + int cos_total; // number of cosines stored if not using on the fly + int neigh_ct; // limit for large arrays -/*Parameters variables*/ + // Parameters variables int ncutoff,nfunc; int a_flag; @@ -98,51 +95,50 @@ class PairBOP : public Pair { double beta3,rsmall,rbig,rcore; char **words; - double cutmax; //max cutoff for all elements - int otfly; //Defines whether to do on the fly - //calculations of angles and distances - //on the fly will slow down calculations - //but requires less memory on = 1, off=0 + double cutmax; // max cutoff for all elements + int otfly; // Defines whether to do on the fly + // calculations of angles and distances + // on the fly will slow down calculations + // but requires less memory on = 1, off=0 -/* Neigh variables */ + // Neigh variables double *rcut,*rcut3,*dr,*rdr,*dr3,*rdr3; double *rcutsq,*rcutsq3; double **disij,*rij; double rcutall,rctroot; -/*Triple variables */ + // Triple variables double *cosAng,***dcosAng,***dcAng; -/*Double variables */ + // Double variables double *betaS,*dBetaS,*betaP; double *dBetaP,*repul,*dRepul; -/*Sigma variables */ + // Sigma variables int *itypeSigBk,nSigBk; double sigB,sigB_0; double sigB1; - -/*Pi variables */ + // Pi variables int *itypePiBk,nPiBk; double piB,piB_0; -/*Grids1 variables */ + // Grids1 variables double **pBetaS,**pBetaS1,**pBetaS2,**pBetaS3; double **pBetaS4,**pBetaS5,**pBetaS6; -/*Grids2 variables */ + // Grids2 variables double **pBetaP,**pBetaP1,**pBetaP2,**pBetaP3; double **pBetaP4,**pBetaP5,**pBetaP6; -/*Grids3 variables */ + // Grids3 variables double **pRepul,**pRepul1,**pRepul2,**pRepul3; double **pRepul4,**pRepul5,**pRepul6; @@ -155,13 +151,13 @@ class PairBOP : public Pair { double ****gfunc4,****gfunc5,****gfunc6; double dtheta,rdtheta; -/*Grids4 variables */ + // Grids4 variables double **FsigBO,**FsigBO1,**FsigBO2,**FsigBO3; double **FsigBO4,**FsigBO5,**FsigBO6; double dBO,rdBO; -/* End of BOP variables */ + // End of BOP variables double **rcmin,**rcmax,**rcmaxp; struct B_PI{ @@ -211,14 +207,6 @@ class PairBOP : public Pair { void memory_theta_destroy(); void memory_theta_grow(); double cutoff(double, double, int, double); -/* - double betaSfunc(int, double); - double dBetaSfunc(int, double, double, double); - double betaPfunc(int, double); - double dBetaPfunc(int, double, double, double); - double repulfunc(int, double); - double dRepulfunc(int, double, double, double); -*/ void read_table(char *); void allocate(); @@ -229,9 +217,7 @@ class PairBOP : public Pair { void grow_pi(int,int); void grow_sigma(int,int); }; - } - #endif #endif diff --git a/src/MANYBODY/pair_comb.cpp b/src/MANYBODY/pair_comb.cpp index b9a17eeb35..2fc4caec7b 100644 --- a/src/MANYBODY/pair_comb.cpp +++ b/src/MANYBODY/pair_comb.cpp @@ -19,8 +19,8 @@ ------------------------------------------------------------------------- */ #include "pair_comb.h" +#include #include -#include #include #include #include "atom.h" @@ -30,7 +30,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "group.h" -#include "update.h" #include "my_page.h" #include "math_const.h" #include "memory.h" diff --git a/src/MANYBODY/pair_comb.h b/src/MANYBODY/pair_comb.h index c798d5f347..19788dfab1 100644 --- a/src/MANYBODY/pair_comb.h +++ b/src/MANYBODY/pair_comb.h @@ -21,7 +21,6 @@ PairStyle(comb,PairComb) #define LMP_PAIR_COMB_H #include "pair.h" -#include "my_page.h" namespace LAMMPS_NS { diff --git a/src/MANYBODY/pair_comb3.cpp b/src/MANYBODY/pair_comb3.cpp index 846ef7d4b9..6f1732dbb7 100644 --- a/src/MANYBODY/pair_comb3.cpp +++ b/src/MANYBODY/pair_comb3.cpp @@ -18,18 +18,18 @@ ------------------------------------------------------------------------- */ #include "pair_comb3.h" +#include #include -#include #include #include #include "atom.h" #include "comm.h" #include "force.h" +#include "my_page.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "group.h" -#include "update.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/MANYBODY/pair_comb3.h b/src/MANYBODY/pair_comb3.h index 5d7e5d6beb..210f843139 100644 --- a/src/MANYBODY/pair_comb3.h +++ b/src/MANYBODY/pair_comb3.h @@ -21,7 +21,6 @@ PairStyle(comb3,PairComb3) #define LMP_PAIR_COMB3_H #include "pair.h" -#include "my_page.h" namespace LAMMPS_NS { diff --git a/src/MANYBODY/pair_eam.cpp b/src/MANYBODY/pair_eam.cpp index e6476b78c5..acb0e654d8 100644 --- a/src/MANYBODY/pair_eam.cpp +++ b/src/MANYBODY/pair_eam.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_eam.h" +#include #include -#include #include #include #include "atom.h" diff --git a/src/MANYBODY/pair_eam_alloy.cpp b/src/MANYBODY/pair_eam_alloy.cpp index 7aae786720..5b7f9877d7 100644 --- a/src/MANYBODY/pair_eam_alloy.cpp +++ b/src/MANYBODY/pair_eam_alloy.cpp @@ -16,8 +16,7 @@ ------------------------------------------------------------------------- */ #include "pair_eam_alloy.h" -#include -#include +#include #include #include "atom.h" #include "comm.h" diff --git a/src/MANYBODY/pair_eam_cd.cpp b/src/MANYBODY/pair_eam_cd.cpp index 55ad597cce..28004eae7f 100644 --- a/src/MANYBODY/pair_eam_cd.cpp +++ b/src/MANYBODY/pair_eam_cd.cpp @@ -18,14 +18,13 @@ ------------------------------------------------------------------------- */ #include "pair_eam_cd.h" +#include #include -#include #include #include #include "atom.h" #include "force.h" #include "comm.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/MANYBODY/pair_eam_fs.cpp b/src/MANYBODY/pair_eam_fs.cpp index 7b13988d0c..7e00783922 100644 --- a/src/MANYBODY/pair_eam_fs.cpp +++ b/src/MANYBODY/pair_eam_fs.cpp @@ -16,8 +16,7 @@ ------------------------------------------------------------------------- */ #include "pair_eam_fs.h" -#include -#include +#include #include #include "atom.h" #include "comm.h" diff --git a/src/MANYBODY/pair_eim.cpp b/src/MANYBODY/pair_eim.cpp index 58cb1fd2e0..dd65d92cdd 100644 --- a/src/MANYBODY/pair_eim.cpp +++ b/src/MANYBODY/pair_eim.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_eim.h" +#include #include -#include -#include #include #include "atom.h" #include "force.h" diff --git a/src/MANYBODY/pair_gw.cpp b/src/MANYBODY/pair_gw.cpp index 07e9201f94..667311812b 100644 --- a/src/MANYBODY/pair_gw.cpp +++ b/src/MANYBODY/pair_gw.cpp @@ -17,8 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_gw.h" +#include #include -#include #include #include #include "atom.h" diff --git a/src/MANYBODY/pair_gw_zbl.cpp b/src/MANYBODY/pair_gw_zbl.cpp index cd83727ed3..d39bf53b99 100644 --- a/src/MANYBODY/pair_gw_zbl.cpp +++ b/src/MANYBODY/pair_gw_zbl.cpp @@ -17,15 +17,12 @@ ------------------------------------------------------------------------- */ #include "pair_gw_zbl.h" +#include #include -#include #include #include #include "atom.h" #include "update.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "comm.h" #include "memory.h" diff --git a/src/MANYBODY/pair_lcbop.cpp b/src/MANYBODY/pair_lcbop.cpp index b0240978a9..873a675cd9 100644 --- a/src/MANYBODY/pair_lcbop.cpp +++ b/src/MANYBODY/pair_lcbop.cpp @@ -17,26 +17,20 @@ ------------------------------------------------------------------------- */ #include "pair_lcbop.h" -#include -#include -#include -#include #include +#include +#include #include "atom.h" -#include "neighbor.h" -#include "neigh_request.h" #include "force.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "my_page.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; #define MAXLINE 1024 #define TOL 1.0e-9 @@ -1099,19 +1093,6 @@ void PairLCBOP::read_file(char *filename) init coefficients for TF_conj ------------------------------------------------------------------------- */ -#include -#include -#include -template< class function > void print_function( double x_0, double x_1, size_t n, function f, std::ostream &stream ) { - double dx = (x_1-x_0)/n; - for( double x=x_0; x<=x_1+0.0001; x+=dx ) { - double f_val, df; - f_val = f(x, &df); - stream << x << " " << f_val << " " << df << std::endl; - } - stream << std::endl; -} - void PairLCBOP::spline_init() { for( size_t N_conj_ij=0; N_conj_ij<2; N_conj_ij++ ) // N_conj_ij for( size_t N_ij=0; N_ij<4-1; N_ij++ ) diff --git a/src/MANYBODY/pair_lcbop.h b/src/MANYBODY/pair_lcbop.h index 0d7c7a51b1..c7a7fab46d 100644 --- a/src/MANYBODY/pair_lcbop.h +++ b/src/MANYBODY/pair_lcbop.h @@ -21,7 +21,6 @@ PairStyle(lcbop,PairLCBOP) #define LMP_PAIR_LCBOP_H #include "pair.h" -#include "my_page.h" #include #include "math_const.h" diff --git a/src/MANYBODY/pair_nb3b_harmonic.cpp b/src/MANYBODY/pair_nb3b_harmonic.cpp index ac20c3e61f..92456790cc 100644 --- a/src/MANYBODY/pair_nb3b_harmonic.cpp +++ b/src/MANYBODY/pair_nb3b_harmonic.cpp @@ -17,8 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_nb3b_harmonic.h" +#include #include -#include #include #include #include "atom.h" @@ -26,8 +26,6 @@ #include "neigh_request.h" #include "force.h" #include "comm.h" -#include "memory.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/MANYBODY/pair_polymorphic.cpp b/src/MANYBODY/pair_polymorphic.cpp index 0cca50823d..d3964b292c 100644 --- a/src/MANYBODY/pair_polymorphic.cpp +++ b/src/MANYBODY/pair_polymorphic.cpp @@ -17,8 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_polymorphic.h" +#include #include -#include #include #include #include "atom.h" @@ -30,10 +30,7 @@ #include "memory.h" #include "error.h" -#include "math_const.h" - using namespace LAMMPS_NS; -using namespace MathConst; #define MAXLINE 1024 #define DELTA 4 diff --git a/src/MANYBODY/pair_rebo.cpp b/src/MANYBODY/pair_rebo.cpp index e07a1b3495..06357d8368 100644 --- a/src/MANYBODY/pair_rebo.cpp +++ b/src/MANYBODY/pair_rebo.cpp @@ -26,7 +26,7 @@ PairREBO::PairREBO(LAMMPS *lmp) : PairAIREBO(lmp) { global settings ------------------------------------------------------------------------- */ -void PairREBO::settings(int narg, char **/*arg*/) +void PairREBO::settings(int narg, char ** /* arg */) { if (narg != 0) error->all(FLERR,"Illegal pair_style command"); diff --git a/src/MANYBODY/pair_sw.cpp b/src/MANYBODY/pair_sw.cpp index ea47fc97c3..f1d1a6fa9f 100644 --- a/src/MANYBODY/pair_sw.cpp +++ b/src/MANYBODY/pair_sw.cpp @@ -16,20 +16,18 @@ ------------------------------------------------------------------------- */ #include "pair_sw.h" +#include #include -#include #include #include #include "atom.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "force.h" #include "comm.h" +#include "error.h" +#include "force.h" #include "memory.h" #include "neighbor.h" #include "neigh_list.h" -#include "memory.h" -#include "error.h" +#include "neigh_request.h" using namespace LAMMPS_NS; diff --git a/src/MANYBODY/pair_tersoff.cpp b/src/MANYBODY/pair_tersoff.cpp index 9d7f804f9a..62c74576e0 100644 --- a/src/MANYBODY/pair_tersoff.cpp +++ b/src/MANYBODY/pair_tersoff.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_tersoff.h" +#include #include -#include #include #include #include "atom.h" diff --git a/src/MANYBODY/pair_tersoff_mod.cpp b/src/MANYBODY/pair_tersoff_mod.cpp index df3c41fc33..698dd8fa03 100644 --- a/src/MANYBODY/pair_tersoff_mod.cpp +++ b/src/MANYBODY/pair_tersoff_mod.cpp @@ -17,21 +17,17 @@ ------------------------------------------------------------------------- */ #include "pair_tersoff_mod.h" +#include #include -#include #include #include #include "atom.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "comm.h" +#include "math_const.h" #include "memory.h" #include "error.h" -#include "math_const.h" - using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/MANYBODY/pair_tersoff_mod_c.cpp b/src/MANYBODY/pair_tersoff_mod_c.cpp index d34291f6cd..6c2c4f4e7a 100644 --- a/src/MANYBODY/pair_tersoff_mod_c.cpp +++ b/src/MANYBODY/pair_tersoff_mod_c.cpp @@ -16,23 +16,17 @@ ------------------------------------------------------------------------- */ #include "pair_tersoff_mod_c.h" +#include #include -#include #include #include #include "atom.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "comm.h" #include "memory.h" #include "error.h" -#include "math_const.h" - using namespace LAMMPS_NS; -using namespace MathConst; #define MAXLINE 1024 #define DELTA 4 diff --git a/src/MANYBODY/pair_tersoff_zbl.cpp b/src/MANYBODY/pair_tersoff_zbl.cpp index 6a8aa40782..ab06e6ec31 100644 --- a/src/MANYBODY/pair_tersoff_zbl.cpp +++ b/src/MANYBODY/pair_tersoff_zbl.cpp @@ -17,21 +17,18 @@ ------------------------------------------------------------------------- */ #include "pair_tersoff_zbl.h" +#include #include -#include #include #include #include "atom.h" #include "update.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "force.h" #include "comm.h" #include "memory.h" #include "error.h" - #include "math_const.h" + using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/MANYBODY/pair_vashishta.cpp b/src/MANYBODY/pair_vashishta.cpp index 5055dadfaf..13b44c58a4 100644 --- a/src/MANYBODY/pair_vashishta.cpp +++ b/src/MANYBODY/pair_vashishta.cpp @@ -17,20 +17,18 @@ ------------------------------------------------------------------------- */ #include "pair_vashishta.h" +#include #include -#include #include #include #include "atom.h" -#include "neighbor.h" -#include "neigh_request.h" -#include "force.h" #include "comm.h" +#include "error.h" +#include "force.h" #include "memory.h" #include "neighbor.h" #include "neigh_list.h" -#include "memory.h" -#include "error.h" +#include "neigh_request.h" using namespace LAMMPS_NS; diff --git a/src/MANYBODY/pair_vashishta_table.cpp b/src/MANYBODY/pair_vashishta_table.cpp index 726e0f83f1..bf39183b9d 100644 --- a/src/MANYBODY/pair_vashishta_table.cpp +++ b/src/MANYBODY/pair_vashishta_table.cpp @@ -16,20 +16,13 @@ ------------------------------------------------------------------------- */ #include "pair_vashishta_table.h" -#include #include -#include -#include #include "atom.h" -#include "neighbor.h" -#include "neigh_request.h" +#include "error.h" #include "force.h" #include "comm.h" #include "memory.h" -#include "neighbor.h" #include "neigh_list.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; From e5af9db84c7aee6f86e8cb1598fd99e65c4689d0 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 7 Jul 2019 11:49:13 -0400 Subject: [PATCH 51/79] clean up includes in MC and MISC package --- src/MC/fix_atom_swap.cpp | 11 ++--------- src/MC/fix_bond_break.cpp | 4 ---- src/MC/fix_bond_create.cpp | 3 --- src/MC/fix_gcmc.cpp | 1 - src/MC/fix_tfmc.cpp | 1 - src/MC/pair_dsmc.cpp | 4 +--- src/MISC/compute_msd_nongauss.cpp | 3 +-- src/MISC/compute_ti.cpp | 1 - src/MISC/dump_xtc.cpp | 1 - src/MISC/fix_deposit.cpp | 2 +- src/MISC/fix_efield.cpp | 3 +-- src/MISC/fix_evaporate.cpp | 4 +--- src/MISC/fix_gld.cpp | 5 +---- src/MISC/fix_oneway.cpp | 1 - src/MISC/fix_orient_bcc.cpp | 1 - src/MISC/fix_orient_fcc.cpp | 1 - src/MISC/fix_thermal_conductivity.cpp | 2 -- src/MISC/fix_ttm.cpp | 2 -- src/MISC/fix_viscosity.cpp | 3 +-- src/MISC/pair_nm_cut.cpp | 3 +-- src/MISC/pair_nm_cut_coul_cut.cpp | 3 +-- src/MISC/pair_nm_cut_coul_long.cpp | 6 +----- src/MISC/xdr_compat.cpp | 1 - src/MISC/xdr_compat.h | 1 - 24 files changed, 12 insertions(+), 55 deletions(-) diff --git a/src/MC/fix_atom_swap.cpp b/src/MC/fix_atom_swap.cpp index c14efcca46..9a4a0b6a7f 100644 --- a/src/MC/fix_atom_swap.cpp +++ b/src/MC/fix_atom_swap.cpp @@ -17,13 +17,12 @@ ------------------------------------------------------------------------- */ #include "fix_atom_swap.h" +#include #include +#include #include -#include #include #include "atom.h" -#include "atom_vec.h" -#include "atom_vec_hybrid.h" #include "update.h" #include "modify.h" #include "fix.h" @@ -40,18 +39,12 @@ #include "dihedral.h" #include "improper.h" #include "kspace.h" -#include "math_const.h" #include "memory.h" #include "error.h" -#include "thermo.h" -#include "output.h" #include "neighbor.h" -#include -using namespace std; using namespace LAMMPS_NS; using namespace FixConst; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/MC/fix_bond_break.cpp b/src/MC/fix_bond_break.cpp index 1b07395f1e..2ff0e4126f 100644 --- a/src/MC/fix_bond_break.cpp +++ b/src/MC/fix_bond_break.cpp @@ -12,18 +12,14 @@ ------------------------------------------------------------------------- */ #include "fix_bond_break.h" -#include #include #include -#include #include "update.h" #include "respa.h" #include "atom.h" -#include "atom_vec.h" #include "force.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "random_mars.h" #include "memory.h" #include "error.h" diff --git a/src/MC/fix_bond_create.cpp b/src/MC/fix_bond_create.cpp index d2d93b67f6..3f63a22d60 100644 --- a/src/MC/fix_bond_create.cpp +++ b/src/MC/fix_bond_create.cpp @@ -12,14 +12,11 @@ ------------------------------------------------------------------------- */ #include "fix_bond_create.h" -#include #include #include -#include #include "update.h" #include "respa.h" #include "atom.h" -#include "atom_vec.h" #include "force.h" #include "pair.h" #include "comm.h" diff --git a/src/MC/fix_gcmc.cpp b/src/MC/fix_gcmc.cpp index 8fe6042c2e..1050fd4712 100644 --- a/src/MC/fix_gcmc.cpp +++ b/src/MC/fix_gcmc.cpp @@ -21,7 +21,6 @@ #include #include "atom.h" #include "atom_vec.h" -#include "atom_vec_hybrid.h" #include "molecule.h" #include "update.h" #include "modify.h" diff --git a/src/MC/fix_tfmc.cpp b/src/MC/fix_tfmc.cpp index 46c5e592ae..e57f1cdf4a 100644 --- a/src/MC/fix_tfmc.cpp +++ b/src/MC/fix_tfmc.cpp @@ -22,7 +22,6 @@ #include #include "atom.h" #include "force.h" -#include "update.h" #include "group.h" #include "random_mars.h" #include "comm.h" diff --git a/src/MC/pair_dsmc.cpp b/src/MC/pair_dsmc.cpp index cf48706133..43bffa7e8d 100644 --- a/src/MC/pair_dsmc.cpp +++ b/src/MC/pair_dsmc.cpp @@ -16,10 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_dsmc.h" +#include #include -#include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/MISC/compute_msd_nongauss.cpp b/src/MISC/compute_msd_nongauss.cpp index e02dd633cb..6123bf49af 100644 --- a/src/MISC/compute_msd_nongauss.cpp +++ b/src/MISC/compute_msd_nongauss.cpp @@ -16,13 +16,12 @@ ------------------------------------------------------------------------- */ #include "compute_msd_nongauss.h" -#include +#include #include "atom.h" #include "update.h" #include "group.h" #include "domain.h" #include "fix_store.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/MISC/compute_ti.cpp b/src/MISC/compute_ti.cpp index 266263785f..06188de238 100644 --- a/src/MISC/compute_ti.cpp +++ b/src/MISC/compute_ti.cpp @@ -20,7 +20,6 @@ #include #include "atom.h" #include "update.h" -#include "modify.h" #include "domain.h" #include "force.h" #include "pair.h" diff --git a/src/MISC/dump_xtc.cpp b/src/MISC/dump_xtc.cpp index 7abe4c4093..1a2b71ab6d 100644 --- a/src/MISC/dump_xtc.cpp +++ b/src/MISC/dump_xtc.cpp @@ -24,7 +24,6 @@ #include "dump_xtc.h" #include -#include #include #include #include diff --git a/src/MISC/fix_deposit.cpp b/src/MISC/fix_deposit.cpp index 22a144da60..c9d4958594 100644 --- a/src/MISC/fix_deposit.cpp +++ b/src/MISC/fix_deposit.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include "fix_deposit.h" +#include #include -#include #include #include "atom.h" #include "atom_vec.h" diff --git a/src/MISC/fix_efield.cpp b/src/MISC/fix_efield.cpp index 87ece82f57..5a13b93b91 100644 --- a/src/MISC/fix_efield.cpp +++ b/src/MISC/fix_efield.cpp @@ -17,9 +17,8 @@ ------------------------------------------------------------------------- */ #include "fix_efield.h" -#include +#include #include -#include #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/MISC/fix_evaporate.cpp b/src/MISC/fix_evaporate.cpp index e2c7844853..d868254c50 100644 --- a/src/MISC/fix_evaporate.cpp +++ b/src/MISC/fix_evaporate.cpp @@ -12,8 +12,7 @@ ------------------------------------------------------------------------- */ #include "fix_evaporate.h" -#include -#include +#include #include #include "atom.h" #include "atom_vec.h" @@ -25,7 +24,6 @@ #include "force.h" #include "group.h" #include "random_park.h" -#include "random_mars.h" #include "memory.h" #include "error.h" diff --git a/src/MISC/fix_gld.cpp b/src/MISC/fix_gld.cpp index 265ee4fb09..380c038e4a 100644 --- a/src/MISC/fix_gld.cpp +++ b/src/MISC/fix_gld.cpp @@ -17,17 +17,14 @@ ------------------------------------------------------------------------- */ #include "fix_gld.h" +#include #include -#include #include -#include "math_extra.h" #include "atom.h" #include "force.h" #include "update.h" #include "respa.h" #include "comm.h" -#include "input.h" -#include "variable.h" #include "random_mars.h" #include "memory.h" #include "error.h" diff --git a/src/MISC/fix_oneway.cpp b/src/MISC/fix_oneway.cpp index fcf5a7a0bd..68a27b68be 100644 --- a/src/MISC/fix_oneway.cpp +++ b/src/MISC/fix_oneway.cpp @@ -22,7 +22,6 @@ #include "error.h" #include "force.h" #include "region.h" -#include "error.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/MISC/fix_orient_bcc.cpp b/src/MISC/fix_orient_bcc.cpp index a300631658..1453ceb317 100644 --- a/src/MISC/fix_orient_bcc.cpp +++ b/src/MISC/fix_orient_bcc.cpp @@ -30,7 +30,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "comm.h" -#include "output.h" #include "force.h" #include "math_const.h" #include "citeme.h" diff --git a/src/MISC/fix_orient_fcc.cpp b/src/MISC/fix_orient_fcc.cpp index d898f95d2c..082ecaf459 100644 --- a/src/MISC/fix_orient_fcc.cpp +++ b/src/MISC/fix_orient_fcc.cpp @@ -27,7 +27,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "comm.h" -#include "output.h" #include "force.h" #include "math_const.h" #include "citeme.h" diff --git a/src/MISC/fix_thermal_conductivity.cpp b/src/MISC/fix_thermal_conductivity.cpp index 8da303c8ab..d0add6fecb 100644 --- a/src/MISC/fix_thermal_conductivity.cpp +++ b/src/MISC/fix_thermal_conductivity.cpp @@ -17,10 +17,8 @@ ------------------------------------------------------------------------- */ #include "fix_thermal_conductivity.h" -#include #include #include -#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/MISC/fix_ttm.cpp b/src/MISC/fix_ttm.cpp index 06de732de6..eb9eb2620d 100644 --- a/src/MISC/fix_ttm.cpp +++ b/src/MISC/fix_ttm.cpp @@ -20,12 +20,10 @@ #include #include #include -#include #include "atom.h" #include "force.h" #include "update.h" #include "domain.h" -#include "region.h" #include "respa.h" #include "comm.h" #include "random_mars.h" diff --git a/src/MISC/fix_viscosity.cpp b/src/MISC/fix_viscosity.cpp index 52107954c2..d5a97cd4b0 100644 --- a/src/MISC/fix_viscosity.cpp +++ b/src/MISC/fix_viscosity.cpp @@ -17,10 +17,9 @@ ------------------------------------------------------------------------- */ #include "fix_viscosity.h" -#include #include +#include #include -#include #include "atom.h" #include "domain.h" #include "modify.h" diff --git a/src/MISC/pair_nm_cut.cpp b/src/MISC/pair_nm_cut.cpp index 9b8c36da3a..a084491a78 100644 --- a/src/MISC/pair_nm_cut.cpp +++ b/src/MISC/pair_nm_cut.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_nm_cut.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/MISC/pair_nm_cut_coul_cut.cpp b/src/MISC/pair_nm_cut_coul_cut.cpp index 069c363817..df8a34062a 100644 --- a/src/MISC/pair_nm_cut_coul_cut.cpp +++ b/src/MISC/pair_nm_cut_coul_cut.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_nm_cut_coul_cut.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/MISC/pair_nm_cut_coul_long.cpp b/src/MISC/pair_nm_cut_coul_long.cpp index b3d42b05f8..4109fb0d9e 100644 --- a/src/MISC/pair_nm_cut_coul_long.cpp +++ b/src/MISC/pair_nm_cut_coul_long.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "pair_nm_cut_coul_long.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "integrate.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/MISC/xdr_compat.cpp b/src/MISC/xdr_compat.cpp index e124d52d7b..9806b0bbd2 100644 --- a/src/MISC/xdr_compat.cpp +++ b/src/MISC/xdr_compat.cpp @@ -1,6 +1,5 @@ #include "xdr_compat.h" #include -#include #include /* This file is needed for systems, that do not provide XDR support diff --git a/src/MISC/xdr_compat.h b/src/MISC/xdr_compat.h index 3062235080..5dfa01e0e8 100644 --- a/src/MISC/xdr_compat.h +++ b/src/MISC/xdr_compat.h @@ -3,7 +3,6 @@ #include #include -#include #ifdef __cplusplus extern "C" { From 57a558854908efe838e9da312389b49080149862 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 7 Jul 2019 15:46:34 -0400 Subject: [PATCH 52/79] cleaning up include file handling in packages MOLECULE and PERI --- src/MOLECULE/angle_charmm.cpp | 2 +- src/MOLECULE/angle_cosine.cpp | 2 +- src/MOLECULE/angle_cosine_delta.cpp | 4 ---- src/MOLECULE/angle_cosine_periodic.cpp | 2 +- src/MOLECULE/angle_cosine_squared.cpp | 2 +- src/MOLECULE/angle_harmonic.cpp | 2 +- src/MOLECULE/angle_table.cpp | 1 + src/MOLECULE/atom_vec_template.cpp | 1 - src/MOLECULE/bond_fene.cpp | 3 +-- src/MOLECULE/bond_fene_expand.cpp | 3 +-- src/MOLECULE/bond_gromos.cpp | 4 +--- src/MOLECULE/bond_harmonic.cpp | 3 +-- src/MOLECULE/bond_morse.cpp | 3 +-- src/MOLECULE/bond_nonlinear.cpp | 3 +-- src/MOLECULE/bond_quartic.cpp | 4 +--- src/MOLECULE/bond_table.cpp | 2 +- src/MOLECULE/dihedral_charmm.cpp | 2 -- src/MOLECULE/dihedral_charmmfsw.cpp | 2 -- src/MOLECULE/dihedral_harmonic.cpp | 2 -- src/MOLECULE/dihedral_helix.cpp | 2 -- src/MOLECULE/dihedral_multi_harmonic.cpp | 3 +-- src/MOLECULE/dihedral_opls.cpp | 3 +-- src/MOLECULE/fix_cmap.cpp | 4 ---- src/MOLECULE/improper_cvff.cpp | 2 -- src/MOLECULE/improper_harmonic.cpp | 2 -- src/MOLECULE/improper_umbrella.cpp | 2 -- src/MOLECULE/pair_hbond_dreiding_lj.cpp | 3 --- src/MOLECULE/pair_hbond_dreiding_morse.cpp | 3 --- src/MOLECULE/pair_lj_charmm_coul_charmm.cpp | 3 +-- .../pair_lj_charmm_coul_charmm_implicit.cpp | 2 -- .../pair_lj_charmmfsw_coul_charmmfsh.cpp | 3 +-- src/MOLECULE/pair_lj_cut_tip4p_cut.cpp | 2 +- src/MOLECULE/pair_tip4p_cut.cpp | 4 +--- src/PERI/compute_damage_atom.cpp | 2 -- src/PERI/compute_dilatation_atom.cpp | 4 +--- src/PERI/compute_plasticity_atom.cpp | 3 +-- src/PERI/fix_peri_neigh.cpp | 3 +-- src/PERI/pair_peri_eps.cpp | 16 +++++++--------- src/PERI/pair_peri_lps.cpp | 4 +--- src/PERI/pair_peri_pmb.cpp | 4 +--- src/PERI/pair_peri_ves.cpp | 16 ++++++++-------- 41 files changed, 40 insertions(+), 97 deletions(-) diff --git a/src/MOLECULE/angle_charmm.cpp b/src/MOLECULE/angle_charmm.cpp index fb0afd78c3..8a45f29368 100644 --- a/src/MOLECULE/angle_charmm.cpp +++ b/src/MOLECULE/angle_charmm.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "angle_charmm.h" +#include #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_cosine.cpp b/src/MOLECULE/angle_cosine.cpp index aff5130323..645cf66ff2 100644 --- a/src/MOLECULE/angle_cosine.cpp +++ b/src/MOLECULE/angle_cosine.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include "angle_cosine.h" +#include #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_cosine_delta.cpp b/src/MOLECULE/angle_cosine_delta.cpp index 13ed00b327..679a8deb0e 100644 --- a/src/MOLECULE/angle_cosine_delta.cpp +++ b/src/MOLECULE/angle_cosine_delta.cpp @@ -17,14 +17,10 @@ #include "angle_cosine_delta.h" #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" -#include "comm.h" #include "force.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/MOLECULE/angle_cosine_periodic.cpp b/src/MOLECULE/angle_cosine_periodic.cpp index 9f7c02cabc..22c2f7ce8b 100644 --- a/src/MOLECULE/angle_cosine_periodic.cpp +++ b/src/MOLECULE/angle_cosine_periodic.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_periodic.h" +#include #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_cosine_squared.cpp b/src/MOLECULE/angle_cosine_squared.cpp index 789a536c98..56b3ee58cf 100644 --- a/src/MOLECULE/angle_cosine_squared.cpp +++ b/src/MOLECULE/angle_cosine_squared.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_squared.h" +#include #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_harmonic.cpp b/src/MOLECULE/angle_harmonic.cpp index b626bdfae5..2e96884c9d 100644 --- a/src/MOLECULE/angle_harmonic.cpp +++ b/src/MOLECULE/angle_harmonic.cpp @@ -12,8 +12,8 @@ ------------------------------------------------------------------------- */ #include "angle_harmonic.h" +#include #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/MOLECULE/angle_table.cpp b/src/MOLECULE/angle_table.cpp index ce7fcdcaf2..f05a8c6a4e 100644 --- a/src/MOLECULE/angle_table.cpp +++ b/src/MOLECULE/angle_table.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "angle_table.h" +#include #include #include #include diff --git a/src/MOLECULE/atom_vec_template.cpp b/src/MOLECULE/atom_vec_template.cpp index 6a12027b7b..4c5f576943 100644 --- a/src/MOLECULE/atom_vec_template.cpp +++ b/src/MOLECULE/atom_vec_template.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "atom_vec_template.h" -#include #include #include "atom.h" #include "molecule.h" diff --git a/src/MOLECULE/bond_fene.cpp b/src/MOLECULE/bond_fene.cpp index d4f2a4010e..776291701b 100644 --- a/src/MOLECULE/bond_fene.cpp +++ b/src/MOLECULE/bond_fene.cpp @@ -12,11 +12,10 @@ ------------------------------------------------------------------------- */ #include "bond_fene.h" +#include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "update.h" #include "force.h" diff --git a/src/MOLECULE/bond_fene_expand.cpp b/src/MOLECULE/bond_fene_expand.cpp index 3e4ceab42c..d03dfd9125 100644 --- a/src/MOLECULE/bond_fene_expand.cpp +++ b/src/MOLECULE/bond_fene_expand.cpp @@ -12,11 +12,10 @@ ------------------------------------------------------------------------- */ #include "bond_fene_expand.h" +#include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "update.h" #include "force.h" diff --git a/src/MOLECULE/bond_gromos.cpp b/src/MOLECULE/bond_gromos.cpp index 44e99d8fe0..284c9202fd 100644 --- a/src/MOLECULE/bond_gromos.cpp +++ b/src/MOLECULE/bond_gromos.cpp @@ -16,12 +16,10 @@ ------------------------------------------------------------------------- */ #include "bond_gromos.h" -#include -#include +#include #include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/MOLECULE/bond_harmonic.cpp b/src/MOLECULE/bond_harmonic.cpp index bbbad4102d..7b19034629 100644 --- a/src/MOLECULE/bond_harmonic.cpp +++ b/src/MOLECULE/bond_harmonic.cpp @@ -12,12 +12,11 @@ ------------------------------------------------------------------------- */ #include "bond_harmonic.h" +#include #include -#include #include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/MOLECULE/bond_morse.cpp b/src/MOLECULE/bond_morse.cpp index af476d6fe8..6e16070cae 100644 --- a/src/MOLECULE/bond_morse.cpp +++ b/src/MOLECULE/bond_morse.cpp @@ -16,11 +16,10 @@ ------------------------------------------------------------------------- */ #include "bond_morse.h" +#include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/MOLECULE/bond_nonlinear.cpp b/src/MOLECULE/bond_nonlinear.cpp index 89ddb7b118..e06b1b9aac 100644 --- a/src/MOLECULE/bond_nonlinear.cpp +++ b/src/MOLECULE/bond_nonlinear.cpp @@ -12,11 +12,10 @@ ------------------------------------------------------------------------- */ #include "bond_nonlinear.h" +#include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/MOLECULE/bond_quartic.cpp b/src/MOLECULE/bond_quartic.cpp index 34b3ad8288..352b642bbe 100644 --- a/src/MOLECULE/bond_quartic.cpp +++ b/src/MOLECULE/bond_quartic.cpp @@ -16,13 +16,11 @@ ------------------------------------------------------------------------- */ #include "bond_quartic.h" +#include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" -#include "update.h" #include "force.h" #include "pair.h" #include "memory.h" diff --git a/src/MOLECULE/bond_table.cpp b/src/MOLECULE/bond_table.cpp index e80baee6e8..137690d002 100644 --- a/src/MOLECULE/bond_table.cpp +++ b/src/MOLECULE/bond_table.cpp @@ -16,12 +16,12 @@ ------------------------------------------------------------------------- */ #include "bond_table.h" +#include #include #include #include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/MOLECULE/dihedral_charmm.cpp b/src/MOLECULE/dihedral_charmm.cpp index 1905c14358..8cc0713024 100644 --- a/src/MOLECULE/dihedral_charmm.cpp +++ b/src/MOLECULE/dihedral_charmm.cpp @@ -18,12 +18,10 @@ #include "dihedral_charmm.h" #include #include -#include #include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "pair.h" #include "update.h" diff --git a/src/MOLECULE/dihedral_charmmfsw.cpp b/src/MOLECULE/dihedral_charmmfsw.cpp index 9b02b908d6..f384c4cd36 100644 --- a/src/MOLECULE/dihedral_charmmfsw.cpp +++ b/src/MOLECULE/dihedral_charmmfsw.cpp @@ -21,12 +21,10 @@ #include "dihedral_charmmfsw.h" #include #include -#include #include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "pair.h" #include "update.h" diff --git a/src/MOLECULE/dihedral_harmonic.cpp b/src/MOLECULE/dihedral_harmonic.cpp index 159636ecd5..f1e5811a84 100644 --- a/src/MOLECULE/dihedral_harmonic.cpp +++ b/src/MOLECULE/dihedral_harmonic.cpp @@ -18,11 +18,9 @@ #include "dihedral_harmonic.h" #include #include -#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "memory.h" diff --git a/src/MOLECULE/dihedral_helix.cpp b/src/MOLECULE/dihedral_helix.cpp index a7d2aba1d6..56f7a3b5e8 100644 --- a/src/MOLECULE/dihedral_helix.cpp +++ b/src/MOLECULE/dihedral_helix.cpp @@ -19,10 +19,8 @@ #include "dihedral_helix.h" #include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "update.h" diff --git a/src/MOLECULE/dihedral_multi_harmonic.cpp b/src/MOLECULE/dihedral_multi_harmonic.cpp index ba98cf6ddf..eda7cede3e 100644 --- a/src/MOLECULE/dihedral_multi_harmonic.cpp +++ b/src/MOLECULE/dihedral_multi_harmonic.cpp @@ -16,11 +16,10 @@ ------------------------------------------------------------------------- */ #include "dihedral_multi_harmonic.h" +#include #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "update.h" diff --git a/src/MOLECULE/dihedral_opls.cpp b/src/MOLECULE/dihedral_opls.cpp index d68eba0bec..556efd850a 100644 --- a/src/MOLECULE/dihedral_opls.cpp +++ b/src/MOLECULE/dihedral_opls.cpp @@ -16,12 +16,11 @@ ------------------------------------------------------------------------- */ #include "dihedral_opls.h" +#include #include -#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "memory.h" diff --git a/src/MOLECULE/fix_cmap.cpp b/src/MOLECULE/fix_cmap.cpp index 3d5bf90bdc..fb0a550898 100644 --- a/src/MOLECULE/fix_cmap.cpp +++ b/src/MOLECULE/fix_cmap.cpp @@ -32,15 +32,11 @@ #include #include #include -#include #include "atom.h" -#include "atom_vec.h" #include "update.h" #include "respa.h" -#include "modify.h" #include "domain.h" #include "force.h" -#include "group.h" #include "comm.h" #include "math_const.h" #include "memory.h" diff --git a/src/MOLECULE/improper_cvff.cpp b/src/MOLECULE/improper_cvff.cpp index fd24ab69c3..abd2d4e11e 100644 --- a/src/MOLECULE/improper_cvff.cpp +++ b/src/MOLECULE/improper_cvff.cpp @@ -14,11 +14,9 @@ #include "improper_cvff.h" #include #include -#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "memory.h" diff --git a/src/MOLECULE/improper_harmonic.cpp b/src/MOLECULE/improper_harmonic.cpp index 936c22e94a..778fe646e1 100644 --- a/src/MOLECULE/improper_harmonic.cpp +++ b/src/MOLECULE/improper_harmonic.cpp @@ -14,11 +14,9 @@ #include "improper_harmonic.h" #include #include -#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "math_const.h" diff --git a/src/MOLECULE/improper_umbrella.cpp b/src/MOLECULE/improper_umbrella.cpp index 2e41ac6493..d3adf19993 100644 --- a/src/MOLECULE/improper_umbrella.cpp +++ b/src/MOLECULE/improper_umbrella.cpp @@ -18,11 +18,9 @@ #include "improper_umbrella.h" #include #include -#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "math_const.h" diff --git a/src/MOLECULE/pair_hbond_dreiding_lj.cpp b/src/MOLECULE/pair_hbond_dreiding_lj.cpp index 58666f27d1..53c3101708 100644 --- a/src/MOLECULE/pair_hbond_dreiding_lj.cpp +++ b/src/MOLECULE/pair_hbond_dreiding_lj.cpp @@ -17,13 +17,10 @@ #include "pair_hbond_dreiding_lj.h" #include -#include -#include #include #include "atom.h" #include "atom_vec.h" #include "molecule.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MOLECULE/pair_hbond_dreiding_morse.cpp b/src/MOLECULE/pair_hbond_dreiding_morse.cpp index 120a2d8d55..3039a662e6 100644 --- a/src/MOLECULE/pair_hbond_dreiding_morse.cpp +++ b/src/MOLECULE/pair_hbond_dreiding_morse.cpp @@ -17,13 +17,10 @@ #include "pair_hbond_dreiding_morse.h" #include -#include -#include #include #include "atom.h" #include "atom_vec.h" #include "molecule.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_request.h" diff --git a/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp b/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp index c9becb75c3..5ebfe0a110 100644 --- a/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp +++ b/src/MOLECULE/pair_lj_charmm_coul_charmm.cpp @@ -16,9 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_charmm.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp b/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp index a2be2936b2..ff7dbb290b 100644 --- a/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp +++ b/src/MOLECULE/pair_lj_charmm_coul_charmm_implicit.cpp @@ -12,8 +12,6 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_charmm_implicit.h" -#include -#include #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp b/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp index f2f16c88ce..4fb7cc5229 100644 --- a/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp +++ b/src/MOLECULE/pair_lj_charmmfsw_coul_charmmfsh.cpp @@ -20,9 +20,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmmfsw_coul_charmmfsh.h" +#include #include -#include -#include #include #include "atom.h" #include "update.h" diff --git a/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp b/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp index 5bb82d7635..e5f25a511b 100644 --- a/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp +++ b/src/MOLECULE/pair_lj_cut_tip4p_cut.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_tip4p_cut.h" +#include #include -#include #include #include "atom.h" #include "force.h" diff --git a/src/MOLECULE/pair_tip4p_cut.cpp b/src/MOLECULE/pair_tip4p_cut.cpp index 1511c09384..3a6702c9b2 100644 --- a/src/MOLECULE/pair_tip4p_cut.cpp +++ b/src/MOLECULE/pair_tip4p_cut.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_tip4p_cut.h" +#include #include -#include #include "atom.h" #include "force.h" #include "neighbor.h" @@ -26,12 +26,10 @@ #include "angle.h" #include "bond.h" #include "comm.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/PERI/compute_damage_atom.cpp b/src/PERI/compute_damage_atom.cpp index f5a532cd0b..230b766725 100644 --- a/src/PERI/compute_damage_atom.cpp +++ b/src/PERI/compute_damage_atom.cpp @@ -21,8 +21,6 @@ #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" -#include "pair_peri_pmb.h" #include "fix_peri_neigh.h" #include "memory.h" #include "error.h" diff --git a/src/PERI/compute_dilatation_atom.cpp b/src/PERI/compute_dilatation_atom.cpp index 7a6607d65c..095f619838 100644 --- a/src/PERI/compute_dilatation_atom.cpp +++ b/src/PERI/compute_dilatation_atom.cpp @@ -21,13 +21,11 @@ #include "update.h" #include "modify.h" #include "comm.h" +#include "fix.h" #include "force.h" -#include "pair.h" #include "pair_peri_lps.h" -#include "pair_peri_pmb.h" #include "pair_peri_ves.h" #include "pair_peri_eps.h" -#include "fix_peri_neigh.h" #include "memory.h" #include "error.h" diff --git a/src/PERI/compute_plasticity_atom.cpp b/src/PERI/compute_plasticity_atom.cpp index 0b20bc5075..e312630b62 100644 --- a/src/PERI/compute_plasticity_atom.cpp +++ b/src/PERI/compute_plasticity_atom.cpp @@ -21,9 +21,8 @@ #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" -#include "pair_peri_pmb.h" #include "fix_peri_neigh.h" +#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/PERI/fix_peri_neigh.cpp b/src/PERI/fix_peri_neigh.cpp index 297936577f..70f46dcdc1 100644 --- a/src/PERI/fix_peri_neigh.cpp +++ b/src/PERI/fix_peri_neigh.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "fix_peri_neigh.h" +#include #include -#include "pair_peri_pmb.h" #include "pair_peri_lps.h" #include "pair_peri_ves.h" #include "pair_peri_eps.h" @@ -25,7 +25,6 @@ #include "domain.h" #include "force.h" #include "comm.h" -#include "update.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/PERI/pair_peri_eps.cpp b/src/PERI/pair_peri_eps.cpp index 07314081da..2579a9b75a 100644 --- a/src/PERI/pair_peri_eps.cpp +++ b/src/PERI/pair_peri_eps.cpp @@ -16,14 +16,13 @@ ------------------------------------------------------------------------- */ #include "pair_peri_eps.h" +#include #include -#include #include #include "atom.h" #include "domain.h" #include "lattice.h" #include "force.h" -#include "update.h" #include "modify.h" #include "fix.h" #include "fix_peri_neigh.h" @@ -32,7 +31,6 @@ #include "neigh_list.h" #include "memory.h" #include "error.h" -#include "update.h" using namespace LAMMPS_NS; @@ -451,12 +449,12 @@ void PairPeriEPS::coeff(int narg, char **arg) force->bounds(FLERR,arg[0],atom->ntypes,ilo,ihi); force->bounds(FLERR,arg[1],atom->ntypes,jlo,jhi); - double bulkmodulus_one = atof(arg[2]); - double shearmodulus_one = atof(arg[3]); - double cut_one = atof(arg[4]); - double s00_one = atof(arg[5]); - double alpha_one = atof(arg[6]); - double myieldstress_one = atof(arg[7]); + double bulkmodulus_one = force->numeric(FLERR,arg[2]); + double shearmodulus_one = force->numeric(FLERR,arg[3]); + double cut_one = force->numeric(FLERR,arg[4]); + double s00_one = force->numeric(FLERR,arg[5]); + double alpha_one = force->numeric(FLERR,arg[6]); + double myieldstress_one = force->numeric(FLERR,arg[7]); int count = 0; for (int i = ilo; i <= ihi; i++) { diff --git a/src/PERI/pair_peri_lps.cpp b/src/PERI/pair_peri_lps.cpp index 660209f3f5..f32ce5fb1c 100644 --- a/src/PERI/pair_peri_lps.cpp +++ b/src/PERI/pair_peri_lps.cpp @@ -16,14 +16,13 @@ ------------------------------------------------------------------------- */ #include "pair_peri_lps.h" +#include #include -#include #include #include "atom.h" #include "domain.h" #include "lattice.h" #include "force.h" -#include "update.h" #include "modify.h" #include "fix.h" #include "fix_peri_neigh.h" @@ -32,7 +31,6 @@ #include "neigh_list.h" #include "memory.h" #include "error.h" -#include "update.h" #include "math_const.h" using namespace LAMMPS_NS; diff --git a/src/PERI/pair_peri_pmb.cpp b/src/PERI/pair_peri_pmb.cpp index fa53efc344..ceab40d88d 100644 --- a/src/PERI/pair_peri_pmb.cpp +++ b/src/PERI/pair_peri_pmb.cpp @@ -16,22 +16,20 @@ ------------------------------------------------------------------------- */ #include "pair_peri_pmb.h" +#include #include #include -#include #include #include "atom.h" #include "domain.h" #include "lattice.h" #include "force.h" -#include "update.h" #include "modify.h" #include "fix.h" #include "fix_peri_neigh.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" diff --git a/src/PERI/pair_peri_ves.cpp b/src/PERI/pair_peri_ves.cpp index 1687bed35d..930ecc6812 100644 --- a/src/PERI/pair_peri_ves.cpp +++ b/src/PERI/pair_peri_ves.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "pair_peri_ves.h" +#include #include #include #include @@ -23,7 +24,6 @@ #include "domain.h" #include "lattice.h" #include "force.h" -#include "update.h" #include "modify.h" #include "fix.h" #include "fix_peri_neigh.h" @@ -428,13 +428,13 @@ void PairPeriVES::coeff(int narg, char **arg) force->bounds(FLERR,arg[0],atom->ntypes,ilo,ihi); force->bounds(FLERR,arg[1],atom->ntypes,jlo,jhi); - double bulkmodulus_one = atof(arg[2]); - double shearmodulus_one = atof(arg[3]); - double cut_one = atof(arg[4]); - double s00_one = atof(arg[5]); - double alpha_one = atof(arg[6]); - double mlambdai_one = atof(arg[7]); - double mtaui_one = atof(arg[8]); + double bulkmodulus_one = force->numeric(FLERR,arg[2]); + double shearmodulus_one = force->numeric(FLERR,arg[3]); + double cut_one = force->numeric(FLERR,arg[4]); + double s00_one = force->numeric(FLERR,arg[5]); + double alpha_one = force->numeric(FLERR,arg[6]); + double mlambdai_one = force->numeric(FLERR,arg[7]); + double mtaui_one = force->numeric(FLERR,arg[8]); int count = 0; for (int i = ilo; i <= ihi; i++) { From 13d4fbdcfbad171fd83ac74d7dcc66170979cd05 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 7 Jul 2019 16:23:36 -0400 Subject: [PATCH 53/79] clean up includes in QEQ, REPLICA, and RIGID packages --- src/PERI/pair_peri_ves.cpp | 1 - src/QEQ/fix_qeq.cpp | 12 +----------- src/QEQ/fix_qeq_dynamic.cpp | 5 +---- src/QEQ/fix_qeq_fire.cpp | 5 +---- src/QEQ/fix_qeq_point.cpp | 3 --- src/QEQ/fix_qeq_shielded.cpp | 3 --- src/QEQ/fix_qeq_slater.cpp | 3 --- src/REPLICA/compute_event_displace.cpp | 3 --- src/REPLICA/fix_event.cpp | 8 +------- src/REPLICA/fix_event_hyper.cpp | 9 +-------- src/REPLICA/fix_event_prd.cpp | 9 +-------- src/REPLICA/fix_event_tad.cpp | 9 +-------- src/REPLICA/fix_hyper_global.cpp | 2 -- src/REPLICA/fix_hyper_local.cpp | 3 +-- src/REPLICA/fix_hyper_local.h | 1 - src/REPLICA/fix_neb.cpp | 1 - src/REPLICA/hyper.cpp | 4 +--- src/REPLICA/neb.cpp | 5 ----- src/REPLICA/prd.cpp | 9 --------- src/REPLICA/tad.cpp | 12 ------------ src/REPLICA/temper.cpp | 4 ---- src/REPLICA/verlet_split.cpp | 1 - src/RIGID/compute_erotate_rigid.cpp | 1 - src/RIGID/compute_ke_rigid.cpp | 1 - src/RIGID/compute_rigid_local.cpp | 1 - 25 files changed, 9 insertions(+), 106 deletions(-) diff --git a/src/PERI/pair_peri_ves.cpp b/src/PERI/pair_peri_ves.cpp index 930ecc6812..bd1eaa5fd2 100644 --- a/src/PERI/pair_peri_ves.cpp +++ b/src/PERI/pair_peri_ves.cpp @@ -18,7 +18,6 @@ #include "pair_peri_ves.h" #include #include -#include #include #include "atom.h" #include "domain.h" diff --git a/src/QEQ/fix_qeq.cpp b/src/QEQ/fix_qeq.cpp index 2e0b7edbe5..7768c01a41 100644 --- a/src/QEQ/fix_qeq.cpp +++ b/src/QEQ/fix_qeq.cpp @@ -17,28 +17,18 @@ ------------------------------------------------------------------------- */ #include "fix_qeq.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" -#include "domain.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "update.h" #include "force.h" -#include "kspace.h" -#include "group.h" -#include "pair.h" -#include "respa.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace FixConst; #define MAXLINE 1024 diff --git a/src/QEQ/fix_qeq_dynamic.cpp b/src/QEQ/fix_qeq_dynamic.cpp index fb5fd2ddac..a2cc683b56 100644 --- a/src/QEQ/fix_qeq_dynamic.cpp +++ b/src/QEQ/fix_qeq_dynamic.cpp @@ -16,23 +16,20 @@ ------------------------------------------------------------------------- */ #include "fix_qeq_dynamic.h" +#include #include -#include #include #include #include "atom.h" #include "comm.h" -#include "domain.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" #include "force.h" #include "group.h" -#include "pair.h" #include "kspace.h" #include "respa.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/QEQ/fix_qeq_fire.cpp b/src/QEQ/fix_qeq_fire.cpp index 561a82b714..265528a089 100644 --- a/src/QEQ/fix_qeq_fire.cpp +++ b/src/QEQ/fix_qeq_fire.cpp @@ -16,25 +16,22 @@ ------------------------------------------------------------------------- */ #include "fix_qeq_fire.h" +#include #include -#include #include #include #include "atom.h" #include "comm.h" -#include "domain.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" #include "force.h" #include "group.h" -#include "pair.h" #include "pair_comb.h" #include "pair_comb3.h" #include "kspace.h" #include "respa.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/QEQ/fix_qeq_point.cpp b/src/QEQ/fix_qeq_point.cpp index bb3ce835fc..8fb9fd3273 100644 --- a/src/QEQ/fix_qeq_point.cpp +++ b/src/QEQ/fix_qeq_point.cpp @@ -17,12 +17,9 @@ #include "fix_qeq_point.h" #include -#include -#include #include #include "atom.h" #include "comm.h" -#include "domain.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/QEQ/fix_qeq_shielded.cpp b/src/QEQ/fix_qeq_shielded.cpp index 60ff62ca07..13e25475ae 100644 --- a/src/QEQ/fix_qeq_shielded.cpp +++ b/src/QEQ/fix_qeq_shielded.cpp @@ -17,12 +17,9 @@ #include "fix_qeq_shielded.h" #include -#include -#include #include #include "atom.h" #include "comm.h" -#include "domain.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/QEQ/fix_qeq_slater.cpp b/src/QEQ/fix_qeq_slater.cpp index 95105b5ef2..4f5369eb87 100644 --- a/src/QEQ/fix_qeq_slater.cpp +++ b/src/QEQ/fix_qeq_slater.cpp @@ -17,12 +17,10 @@ #include "fix_qeq_slater.h" #include -#include #include #include #include "atom.h" #include "comm.h" -#include "domain.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" @@ -33,7 +31,6 @@ #include "kspace.h" #include "respa.h" #include "math_const.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/REPLICA/compute_event_displace.cpp b/src/REPLICA/compute_event_displace.cpp index 4c8d022d70..a6abcce85d 100644 --- a/src/REPLICA/compute_event_displace.cpp +++ b/src/REPLICA/compute_event_displace.cpp @@ -17,14 +17,11 @@ #include "compute_event_displace.h" #include -#include -#include #include #include "atom.h" #include "domain.h" #include "modify.h" #include "fix_event.h" -#include "memory.h" #include "error.h" #include "force.h" #include "update.h" diff --git a/src/REPLICA/fix_event.cpp b/src/REPLICA/fix_event.cpp index 8cf1acba94..41f91332cb 100644 --- a/src/REPLICA/fix_event.cpp +++ b/src/REPLICA/fix_event.cpp @@ -16,16 +16,10 @@ ------------------------------------------------------------------------- */ #include "fix_event.h" -#include -#include #include "atom.h" -#include "update.h" #include "domain.h" -#include "neighbor.h" -#include "comm.h" -#include "universe.h" -#include "memory.h" #include "error.h" +#include "memory.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/REPLICA/fix_event_hyper.cpp b/src/REPLICA/fix_event_hyper.cpp index 3dd1a03eb9..0d32516dee 100644 --- a/src/REPLICA/fix_event_hyper.cpp +++ b/src/REPLICA/fix_event_hyper.cpp @@ -12,16 +12,9 @@ ------------------------------------------------------------------------- */ #include "fix_event_hyper.h" -#include -#include -#include "atom.h" -#include "update.h" -#include "domain.h" -#include "neighbor.h" #include "comm.h" -#include "universe.h" -#include "memory.h" #include "error.h" +#include "update.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/REPLICA/fix_event_prd.cpp b/src/REPLICA/fix_event_prd.cpp index 63c9c2718b..19a89e988c 100644 --- a/src/REPLICA/fix_event_prd.cpp +++ b/src/REPLICA/fix_event_prd.cpp @@ -16,16 +16,9 @@ ------------------------------------------------------------------------- */ #include "fix_event_prd.h" -#include -#include -#include "atom.h" -#include "update.h" -#include "domain.h" -#include "neighbor.h" #include "comm.h" -#include "universe.h" -#include "memory.h" #include "error.h" +#include "update.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/REPLICA/fix_event_tad.cpp b/src/REPLICA/fix_event_tad.cpp index b92bc1fd73..d0b94a216b 100644 --- a/src/REPLICA/fix_event_tad.cpp +++ b/src/REPLICA/fix_event_tad.cpp @@ -16,16 +16,9 @@ ------------------------------------------------------------------------- */ #include "fix_event_tad.h" -#include -#include -#include "atom.h" -#include "update.h" -#include "domain.h" -#include "neighbor.h" #include "comm.h" -#include "universe.h" -#include "memory.h" #include "error.h" +#include "update.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/REPLICA/fix_hyper_global.cpp b/src/REPLICA/fix_hyper_global.cpp index a58798a63e..5e9da02768 100644 --- a/src/REPLICA/fix_hyper_global.cpp +++ b/src/REPLICA/fix_hyper_global.cpp @@ -14,7 +14,6 @@ #include "fix_hyper_global.h" #include #include -#include #include #include "atom.h" #include "update.h" @@ -24,7 +23,6 @@ #include "neighbor.h" #include "neigh_request.h" #include "neigh_list.h" -#include "modify.h" #include "math_extra.h" #include "memory.h" #include "error.h" diff --git a/src/REPLICA/fix_hyper_local.cpp b/src/REPLICA/fix_hyper_local.cpp index 555c5234f6..e8773095d1 100644 --- a/src/REPLICA/fix_hyper_local.cpp +++ b/src/REPLICA/fix_hyper_local.cpp @@ -14,7 +14,6 @@ #include "fix_hyper_local.h" #include #include -#include #include #include "atom.h" #include "update.h" @@ -22,10 +21,10 @@ #include "pair.h" #include "domain.h" #include "comm.h" +#include "my_page.h" #include "neighbor.h" #include "neigh_request.h" #include "neigh_list.h" -#include "modify.h" #include "math_extra.h" #include "memory.h" #include "error.h" diff --git a/src/REPLICA/fix_hyper_local.h b/src/REPLICA/fix_hyper_local.h index 6f13acb606..8fb3a445c2 100644 --- a/src/REPLICA/fix_hyper_local.h +++ b/src/REPLICA/fix_hyper_local.h @@ -21,7 +21,6 @@ FixStyle(hyper/local,FixHyperLocal) #define LMP_FIX_HYPER_LOCAL_H #include "fix_hyper.h" -#include "my_page.h" namespace LAMMPS_NS { diff --git a/src/REPLICA/fix_neb.cpp b/src/REPLICA/fix_neb.cpp index 2803c37b23..7b377ae9ec 100644 --- a/src/REPLICA/fix_neb.cpp +++ b/src/REPLICA/fix_neb.cpp @@ -19,7 +19,6 @@ #include "fix_neb.h" #include #include -#include #include #include "universe.h" #include "update.h" diff --git a/src/REPLICA/hyper.cpp b/src/REPLICA/hyper.cpp index c400ae097d..af2a963616 100644 --- a/src/REPLICA/hyper.cpp +++ b/src/REPLICA/hyper.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "hyper.h" -#include -#include +#include #include #include "update.h" -#include "atom.h" #include "domain.h" #include "region.h" #include "integrate.h" diff --git a/src/REPLICA/neb.cpp b/src/REPLICA/neb.cpp index b670f3d8f1..84337ce8ae 100644 --- a/src/REPLICA/neb.cpp +++ b/src/REPLICA/neb.cpp @@ -11,12 +11,7 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -// lmptype.h must be first b/c this file uses MAXBIGINT and includes mpi.h -// due to OpenMPI bug which sets INT64_MAX via its mpi.h -// before lmptype.h can set flags to insure it is done correctly - #include "neb.h" -#include "lmptype.h" #include #include #include diff --git a/src/REPLICA/prd.cpp b/src/REPLICA/prd.cpp index 19a12ddbbb..f631cc6a0a 100644 --- a/src/REPLICA/prd.cpp +++ b/src/REPLICA/prd.cpp @@ -15,15 +15,8 @@ Contributing author: Mike Brown (SNL) ------------------------------------------------------------------------- */ -// lmptype.h must be first b/c this file uses MAXBIGINT and includes mpi.h -// due to OpenMPI bug which sets INT64_MAX via its mpi.h -// before lmptype.h can set flags to insure it is done correctly - #include "prd.h" -#include "lmptype.h" #include -#include -#include #include #include "universe.h" #include "update.h" @@ -40,11 +33,9 @@ #include "fix.h" #include "fix_event_prd.h" #include "force.h" -#include "pair.h" #include "random_park.h" #include "random_mars.h" #include "output.h" -#include "dump.h" #include "finish.h" #include "timer.h" #include "memory.h" diff --git a/src/REPLICA/tad.cpp b/src/REPLICA/tad.cpp index 90667b8865..8a51f6d00e 100644 --- a/src/REPLICA/tad.cpp +++ b/src/REPLICA/tad.cpp @@ -15,36 +15,24 @@ Contributing author: Aidan Thompson (SNL) ------------------------------------------------------------------------- */ -// lmptype.h must be first b/c this file uses MAXBIGINT and includes mpi.h -// due to OpenMPI bug which sets INT64_MAX via its mpi.h -// before lmptype.h can set flags to insure it is done correctly - #include "tad.h" -#include "lmptype.h" #include #include -#include #include #include "universe.h" #include "update.h" #include "atom.h" #include "domain.h" -#include "region.h" -#include "comm.h" -#include "velocity.h" #include "integrate.h" #include "min.h" #include "neighbor.h" #include "modify.h" #include "neb.h" #include "compute.h" -#include "fix.h" #include "fix_event_tad.h" #include "fix_store.h" #include "force.h" -#include "pair.h" #include "output.h" -#include "dump.h" #include "finish.h" #include "timer.h" #include "memory.h" diff --git a/src/REPLICA/temper.cpp b/src/REPLICA/temper.cpp index 6eb50c8d9f..46fc3af649 100644 --- a/src/REPLICA/temper.cpp +++ b/src/REPLICA/temper.cpp @@ -17,7 +17,6 @@ #include "temper.h" #include -#include #include #include "universe.h" #include "domain.h" @@ -27,13 +26,10 @@ #include "modify.h" #include "compute.h" #include "force.h" -#include "output.h" -#include "thermo.h" #include "fix.h" #include "random_park.h" #include "finish.h" #include "timer.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/REPLICA/verlet_split.cpp b/src/REPLICA/verlet_split.cpp index f268afe7f8..a5ed1a671d 100644 --- a/src/REPLICA/verlet_split.cpp +++ b/src/REPLICA/verlet_split.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include "verlet_split.h" -#include #include "universe.h" #include "neighbor.h" #include "domain.h" diff --git a/src/RIGID/compute_erotate_rigid.cpp b/src/RIGID/compute_erotate_rigid.cpp index 1a7236e263..e15c0deb82 100644 --- a/src/RIGID/compute_erotate_rigid.cpp +++ b/src/RIGID/compute_erotate_rigid.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "compute_erotate_rigid.h" -#include #include #include "update.h" #include "force.h" diff --git a/src/RIGID/compute_ke_rigid.cpp b/src/RIGID/compute_ke_rigid.cpp index 66b7a92566..031919b7a9 100644 --- a/src/RIGID/compute_ke_rigid.cpp +++ b/src/RIGID/compute_ke_rigid.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "compute_ke_rigid.h" -#include #include #include "update.h" #include "force.h" diff --git a/src/RIGID/compute_rigid_local.cpp b/src/RIGID/compute_rigid_local.cpp index 75334bb759..57f69a64e2 100644 --- a/src/RIGID/compute_rigid_local.cpp +++ b/src/RIGID/compute_rigid_local.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "compute_rigid_local.h" -#include #include #include "atom.h" #include "update.h" From 5b7ae3713b5722fc87871b716f6107885fd6cbe5 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 7 Jul 2019 21:02:51 -0400 Subject: [PATCH 54/79] clean up include handling for VORONOI package --- src/VORONOI/compute_voronoi_atom.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/VORONOI/compute_voronoi_atom.cpp b/src/VORONOI/compute_voronoi_atom.cpp index 860126fa77..27252fae89 100644 --- a/src/VORONOI/compute_voronoi_atom.cpp +++ b/src/VORONOI/compute_voronoi_atom.cpp @@ -15,16 +15,14 @@ Contributing author: Daniel Schwen ------------------------------------------------------------------------- */ +#include "compute_voronoi_atom.h" #include #include #include -#include #include "voro++.hh" -#include "compute_voronoi_atom.h" #include "atom.h" #include "group.h" #include "update.h" -#include "modify.h" #include "domain.h" #include "memory.h" #include "error.h" From 03418be6452b62299638122a183f016751c19cf3 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 8 Jul 2019 15:43:57 -0400 Subject: [PATCH 55/79] minor tweaks to already processed files --- src/ASPHERE/pair_line_lj.cpp | 3 --- src/ASPHERE/pair_resquared.cpp | 5 +---- src/ASPHERE/pair_tri_lj.cpp | 3 --- src/CORESHELL/pair_born_coul_long_cs.cpp | 1 - src/GRANULAR/fix_wall_gran_region.cpp | 1 - src/KSPACE/msm.h | 3 --- src/KSPACE/pair_coul_msm.cpp | 1 - src/angle.h | 2 +- src/dump.h | 1 - src/kspace.h | 3 +-- src/mpiio.h | 2 +- src/region.h | 2 +- src/timer.cpp | 1 - src/write_restart.cpp | 1 - 14 files changed, 5 insertions(+), 24 deletions(-) diff --git a/src/ASPHERE/pair_line_lj.cpp b/src/ASPHERE/pair_line_lj.cpp index 0cb603c4fa..fdeb09aac4 100644 --- a/src/ASPHERE/pair_line_lj.cpp +++ b/src/ASPHERE/pair_line_lj.cpp @@ -13,9 +13,6 @@ #include "pair_line_lj.h" #include -#include -#include -#include #include "atom.h" #include "atom_vec_line.h" #include "force.h" diff --git a/src/ASPHERE/pair_resquared.cpp b/src/ASPHERE/pair_resquared.cpp index ba73c5ba0c..f139564320 100644 --- a/src/ASPHERE/pair_resquared.cpp +++ b/src/ASPHERE/pair_resquared.cpp @@ -16,10 +16,8 @@ ------------------------------------------------------------------------- */ #include "pair_resquared.h" +#include #include -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" @@ -27,7 +25,6 @@ #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "integrate.h" #include "memory.h" #include "error.h" diff --git a/src/ASPHERE/pair_tri_lj.cpp b/src/ASPHERE/pair_tri_lj.cpp index 3dde2a4f44..0984b0a30c 100644 --- a/src/ASPHERE/pair_tri_lj.cpp +++ b/src/ASPHERE/pair_tri_lj.cpp @@ -13,9 +13,6 @@ #include "pair_tri_lj.h" #include -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_tri.h" diff --git a/src/CORESHELL/pair_born_coul_long_cs.cpp b/src/CORESHELL/pair_born_coul_long_cs.cpp index f6262fa9e7..b56389e180 100644 --- a/src/CORESHELL/pair_born_coul_long_cs.cpp +++ b/src/CORESHELL/pair_born_coul_long_cs.cpp @@ -17,7 +17,6 @@ #include "pair_born_coul_long_cs.h" #include -#include #include "atom.h" #include "force.h" #include "neigh_list.h" diff --git a/src/GRANULAR/fix_wall_gran_region.cpp b/src/GRANULAR/fix_wall_gran_region.cpp index a4b798d6aa..95553b83b7 100644 --- a/src/GRANULAR/fix_wall_gran_region.cpp +++ b/src/GRANULAR/fix_wall_gran_region.cpp @@ -21,7 +21,6 @@ #include "atom.h" #include "domain.h" #include "update.h" -#include "pair.h" #include "memory.h" #include "error.h" #include "comm.h" diff --git a/src/KSPACE/msm.h b/src/KSPACE/msm.h index 0f81eb9c3f..bf393473e7 100644 --- a/src/KSPACE/msm.h +++ b/src/KSPACE/msm.h @@ -20,9 +20,6 @@ KSpaceStyle(msm,MSM) #ifndef LMP_MSM_H #define LMP_MSM_H -#include "lmptype.h" -#include - #include "kspace.h" namespace LAMMPS_NS { diff --git a/src/KSPACE/pair_coul_msm.cpp b/src/KSPACE/pair_coul_msm.cpp index 0917bb9275..5d42e1f046 100644 --- a/src/KSPACE/pair_coul_msm.cpp +++ b/src/KSPACE/pair_coul_msm.cpp @@ -22,7 +22,6 @@ #include "force.h" #include "kspace.h" #include "neigh_list.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/angle.h b/src/angle.h index 3e6812c4fd..7a008f7ca7 100644 --- a/src/angle.h +++ b/src/angle.h @@ -14,7 +14,7 @@ #ifndef LMP_ANGLE_H #define LMP_ANGLE_H -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/dump.h b/src/dump.h index 0173aa3112..bc7fd2d5a5 100644 --- a/src/dump.h +++ b/src/dump.h @@ -14,7 +14,6 @@ #ifndef LMP_DUMP_H #define LMP_DUMP_H -#include #include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/kspace.h b/src/kspace.h index 83ce19cd87..c04a0db989 100644 --- a/src/kspace.h +++ b/src/kspace.h @@ -14,8 +14,7 @@ #ifndef LMP_KSPACE_H #define LMP_KSPACE_H -#include -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export #ifdef FFT_SINGLE typedef float FFT_SCALAR; diff --git a/src/mpiio.h b/src/mpiio.h index 4953ade185..0098fca0e1 100644 --- a/src/mpiio.h +++ b/src/mpiio.h @@ -23,7 +23,7 @@ #error "The MPIIO package cannot be compiled in serial with MPI STUBS" #endif -#include "restart_mpiio.h" +#include "restart_mpiio.h" // IWYU pragma: export #else diff --git a/src/region.h b/src/region.h index 6a3806fed7..0dce004a5b 100644 --- a/src/region.h +++ b/src/region.h @@ -14,7 +14,7 @@ #ifndef LMP_REGION_H #define LMP_REGION_H -#include "pointers.h" +#include "pointers.h" // IWYU pragma: export namespace LAMMPS_NS { diff --git a/src/timer.cpp b/src/timer.cpp index 0dad8fb756..0a5e56ab35 100644 --- a/src/timer.cpp +++ b/src/timer.cpp @@ -18,7 +18,6 @@ #include "comm.h" #include "error.h" #include "force.h" -#include "memory.h" #ifdef _WIN32 #include diff --git a/src/write_restart.cpp b/src/write_restart.cpp index 5adb39067c..4b84e790b8 100644 --- a/src/write_restart.cpp +++ b/src/write_restart.cpp @@ -16,7 +16,6 @@ #include #include "atom.h" #include "atom_vec.h" -#include "atom_vec_hybrid.h" #include "group.h" #include "force.h" #include "pair.h" From 31e19e0824893165038f096313c5fe069c53c94a Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 8 Jul 2019 16:23:49 -0400 Subject: [PATCH 56/79] complete cleaning includes in some more packages --- src/KSPACE/pair_buck_coul_msm.cpp | 6 ------ src/KSPACE/pair_lj_charmm_coul_msm.cpp | 1 - src/KSPACE/pair_lj_cut_coul_long.cpp | 1 + src/KSPACE/pair_lj_cut_coul_msm.cpp | 1 - src/MPIIO/dump_atom_mpiio.cpp | 4 ++-- src/MPIIO/dump_atom_mpiio.h | 1 - src/MPIIO/dump_cfg_mpiio.cpp | 6 ------ src/MPIIO/dump_custom_mpiio.cpp | 5 ----- src/MPIIO/dump_xyz_mpiio.cpp | 7 ------- src/USER-BOCS/fix_bocs.cpp | 1 - src/USER-CGDNA/bond_oxdna2_fene.cpp | 2 -- src/USER-CGDNA/bond_oxdna_fene.cpp | 2 -- src/USER-CGDNA/fix_nve_dot.cpp | 5 ----- src/USER-CGDNA/fix_nve_dotc_langevin.cpp | 2 -- src/USER-CGDNA/pair_oxdna2_coaxstk.cpp | 6 +----- src/USER-CGDNA/pair_oxdna2_dh.cpp | 10 +--------- src/USER-CGDNA/pair_oxdna2_excv.cpp | 4 ---- src/USER-CGDNA/pair_oxdna2_stk.cpp | 4 ---- src/USER-CGDNA/pair_oxdna_coaxstk.cpp | 6 +----- src/USER-CGDNA/pair_oxdna_excv.cpp | 8 +------- src/USER-CGDNA/pair_oxdna_hbond.cpp | 8 +------- src/USER-CGDNA/pair_oxdna_stk.cpp | 10 ++-------- src/USER-CGDNA/pair_oxdna_xstk.cpp | 6 +----- src/USER-DPD/pair_dpd_fdt_energy.cpp | 7 ++----- src/USER-DPD/pair_exp6_rx.cpp | 6 ++---- src/USER-MESO/atom_vec_tdpd.cpp | 1 - src/USER-MESO/compute_edpd_temp_atom.cpp | 3 +-- src/USER-MESO/fix_edpd_source.cpp | 11 ++--------- src/USER-MESO/fix_mvv_edpd.cpp | 4 +--- src/USER-MESO/fix_mvv_tdpd.cpp | 4 +--- src/VORONOI/compute_voronoi_atom.cpp | 2 +- 31 files changed, 21 insertions(+), 123 deletions(-) diff --git a/src/KSPACE/pair_buck_coul_msm.cpp b/src/KSPACE/pair_buck_coul_msm.cpp index 3d7687df90..1355a2f13a 100644 --- a/src/KSPACE/pair_buck_coul_msm.cpp +++ b/src/KSPACE/pair_buck_coul_msm.cpp @@ -13,21 +13,15 @@ #include "pair_buck_coul_msm.h" #include -#include -#include #include #include "atom.h" -#include "comm.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/KSPACE/pair_lj_charmm_coul_msm.cpp b/src/KSPACE/pair_lj_charmm_coul_msm.cpp index 804ae5919d..a93a1275f4 100644 --- a/src/KSPACE/pair_lj_charmm_coul_msm.cpp +++ b/src/KSPACE/pair_lj_charmm_coul_msm.cpp @@ -21,7 +21,6 @@ #include "atom.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/KSPACE/pair_lj_cut_coul_long.cpp b/src/KSPACE/pair_lj_cut_coul_long.cpp index 7921c814c3..fb79451b37 100644 --- a/src/KSPACE/pair_lj_cut_coul_long.cpp +++ b/src/KSPACE/pair_lj_cut_coul_long.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_coul_long.h" +#include #include #include #include "atom.h" diff --git a/src/KSPACE/pair_lj_cut_coul_msm.cpp b/src/KSPACE/pair_lj_cut_coul_msm.cpp index f8021cc180..4ebbcb9a3f 100644 --- a/src/KSPACE/pair_lj_cut_coul_msm.cpp +++ b/src/KSPACE/pair_lj_cut_coul_msm.cpp @@ -21,7 +21,6 @@ #include "atom.h" #include "force.h" #include "kspace.h" -#include "update.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/MPIIO/dump_atom_mpiio.cpp b/src/MPIIO/dump_atom_mpiio.cpp index cde5b6258b..2b663554cc 100644 --- a/src/MPIIO/dump_atom_mpiio.cpp +++ b/src/MPIIO/dump_atom_mpiio.cpp @@ -16,11 +16,11 @@ ------------------------------------------------------------------------- */ #include "dump_atom_mpiio.h" +#include +#include #include #include "domain.h" -#include "atom.h" #include "update.h" -#include "group.h" #include "memory.h" #include "error.h" diff --git a/src/MPIIO/dump_atom_mpiio.h b/src/MPIIO/dump_atom_mpiio.h index ad49fa1182..36b43e3f08 100644 --- a/src/MPIIO/dump_atom_mpiio.h +++ b/src/MPIIO/dump_atom_mpiio.h @@ -21,7 +21,6 @@ DumpStyle(atom/mpiio,DumpAtomMPIIO) #define LMP_DUMP_ATOM_MPIIO_H #include "dump_atom.h" -#include namespace LAMMPS_NS { diff --git a/src/MPIIO/dump_cfg_mpiio.cpp b/src/MPIIO/dump_cfg_mpiio.cpp index 90f92d094d..31848b550c 100644 --- a/src/MPIIO/dump_cfg_mpiio.cpp +++ b/src/MPIIO/dump_cfg_mpiio.cpp @@ -21,12 +21,6 @@ #include #include "atom.h" #include "domain.h" -#include "comm.h" -#include "modify.h" -#include "compute.h" -#include "input.h" -#include "fix.h" -#include "variable.h" #include "update.h" #include "memory.h" #include "error.h" diff --git a/src/MPIIO/dump_custom_mpiio.cpp b/src/MPIIO/dump_custom_mpiio.cpp index 5838c61124..dca5833c5b 100644 --- a/src/MPIIO/dump_custom_mpiio.cpp +++ b/src/MPIIO/dump_custom_mpiio.cpp @@ -19,16 +19,11 @@ #include #include #include -#include "atom.h" -#include "force.h" #include "domain.h" -#include "region.h" -#include "group.h" #include "input.h" #include "variable.h" #include "update.h" #include "modify.h" -#include "compute.h" #include "fix.h" #include "memory.h" #include "error.h" diff --git a/src/MPIIO/dump_xyz_mpiio.cpp b/src/MPIIO/dump_xyz_mpiio.cpp index 7b647561bf..ee0532399a 100644 --- a/src/MPIIO/dump_xyz_mpiio.cpp +++ b/src/MPIIO/dump_xyz_mpiio.cpp @@ -19,17 +19,10 @@ #include #include #include -#include "atom.h" -#include "force.h" #include "domain.h" -#include "region.h" -#include "group.h" -#include "input.h" -#include "variable.h" #include "update.h" #include "modify.h" #include "compute.h" -#include "fix.h" #include "memory.h" #include "error.h" diff --git a/src/USER-BOCS/fix_bocs.cpp b/src/USER-BOCS/fix_bocs.cpp index e0952086dd..936e5ff58e 100644 --- a/src/USER-BOCS/fix_bocs.cpp +++ b/src/USER-BOCS/fix_bocs.cpp @@ -18,7 +18,6 @@ #include #include #include -#include "math_extra.h" #include "atom.h" #include "force.h" #include "group.h" diff --git a/src/USER-CGDNA/bond_oxdna2_fene.cpp b/src/USER-CGDNA/bond_oxdna2_fene.cpp index 2cd7883600..97005ef5f9 100644 --- a/src/USER-CGDNA/bond_oxdna2_fene.cpp +++ b/src/USER-CGDNA/bond_oxdna2_fene.cpp @@ -15,8 +15,6 @@ ------------------------------------------------------------------------- */ #include "bond_oxdna2_fene.h" -#include -#include using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/bond_oxdna_fene.cpp b/src/USER-CGDNA/bond_oxdna_fene.cpp index 8b94fd6a5a..8314576d63 100644 --- a/src/USER-CGDNA/bond_oxdna_fene.cpp +++ b/src/USER-CGDNA/bond_oxdna_fene.cpp @@ -16,10 +16,8 @@ #include "bond_oxdna_fene.h" #include -#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "update.h" #include "force.h" diff --git a/src/USER-CGDNA/fix_nve_dot.cpp b/src/USER-CGDNA/fix_nve_dot.cpp index 3bf6757df7..ff8e1c0ee2 100644 --- a/src/USER-CGDNA/fix_nve_dot.cpp +++ b/src/USER-CGDNA/fix_nve_dot.cpp @@ -15,15 +15,10 @@ ------------------------------------------------------------------------- */ #include "fix_nve_dot.h" -#include -#include -#include #include "math_extra.h" #include "atom.h" #include "atom_vec_ellipsoid.h" -#include "force.h" #include "update.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/fix_nve_dotc_langevin.cpp b/src/USER-CGDNA/fix_nve_dotc_langevin.cpp index 61e3552f11..59def4c812 100644 --- a/src/USER-CGDNA/fix_nve_dotc_langevin.cpp +++ b/src/USER-CGDNA/fix_nve_dotc_langevin.cpp @@ -17,7 +17,6 @@ #include "fix_nve_dotc_langevin.h" #include -#include #include #include "math_extra.h" #include "atom.h" @@ -26,7 +25,6 @@ #include "update.h" #include "comm.h" #include "random_mars.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp b/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp index 1d0a2eb494..b96da3fa4a 100644 --- a/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp +++ b/src/USER-CGDNA/pair_oxdna2_coaxstk.cpp @@ -15,9 +15,8 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna2_coaxstk.h" +#include #include -#include -#include #include #include "mf_oxdna.h" #include "atom.h" @@ -25,9 +24,6 @@ #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/USER-CGDNA/pair_oxdna2_dh.cpp b/src/USER-CGDNA/pair_oxdna2_dh.cpp index 22fc79dae4..ea1f4f84f4 100644 --- a/src/USER-CGDNA/pair_oxdna2_dh.cpp +++ b/src/USER-CGDNA/pair_oxdna2_dh.cpp @@ -15,28 +15,20 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna2_dh.h" +#include #include -#include -#include #include -#include "mf_oxdna.h" #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "atom_vec_ellipsoid.h" #include "math_extra.h" using namespace LAMMPS_NS; -using namespace MathConst; -using namespace MFOxdna; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-CGDNA/pair_oxdna2_excv.cpp b/src/USER-CGDNA/pair_oxdna2_excv.cpp index de4f8319b9..0a7da8e81a 100644 --- a/src/USER-CGDNA/pair_oxdna2_excv.cpp +++ b/src/USER-CGDNA/pair_oxdna2_excv.cpp @@ -15,10 +15,6 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna2_excv.h" -#include -#include -#include -#include using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/pair_oxdna2_stk.cpp b/src/USER-CGDNA/pair_oxdna2_stk.cpp index 3b9480bff6..26bae766e1 100644 --- a/src/USER-CGDNA/pair_oxdna2_stk.cpp +++ b/src/USER-CGDNA/pair_oxdna2_stk.cpp @@ -15,10 +15,6 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna2_stk.h" -#include -#include -#include -#include using namespace LAMMPS_NS; diff --git a/src/USER-CGDNA/pair_oxdna_coaxstk.cpp b/src/USER-CGDNA/pair_oxdna_coaxstk.cpp index 7310f60ec3..6e37352ef0 100644 --- a/src/USER-CGDNA/pair_oxdna_coaxstk.cpp +++ b/src/USER-CGDNA/pair_oxdna_coaxstk.cpp @@ -15,9 +15,8 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna_coaxstk.h" +#include #include -#include -#include #include #include "mf_oxdna.h" #include "atom.h" @@ -25,9 +24,6 @@ #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/USER-CGDNA/pair_oxdna_excv.cpp b/src/USER-CGDNA/pair_oxdna_excv.cpp index 68091f4190..9fb3dd041a 100644 --- a/src/USER-CGDNA/pair_oxdna_excv.cpp +++ b/src/USER-CGDNA/pair_oxdna_excv.cpp @@ -15,9 +15,8 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna_excv.h" +#include #include -#include -#include #include #include "mf_oxdna.h" #include "atom.h" @@ -25,17 +24,12 @@ #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "atom_vec_ellipsoid.h" #include "math_extra.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace MFOxdna; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-CGDNA/pair_oxdna_hbond.cpp b/src/USER-CGDNA/pair_oxdna_hbond.cpp index 2de05e66ae..12e4b08c46 100644 --- a/src/USER-CGDNA/pair_oxdna_hbond.cpp +++ b/src/USER-CGDNA/pair_oxdna_hbond.cpp @@ -15,9 +15,8 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna_hbond.h" +#include #include -#include -#include #include #include "mf_oxdna.h" #include "atom.h" @@ -25,17 +24,12 @@ #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "atom_vec_ellipsoid.h" #include "math_extra.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace MFOxdna; // sequence-specific base-pairing strength diff --git a/src/USER-CGDNA/pair_oxdna_stk.cpp b/src/USER-CGDNA/pair_oxdna_stk.cpp index aaa25039ef..022d94f935 100644 --- a/src/USER-CGDNA/pair_oxdna_stk.cpp +++ b/src/USER-CGDNA/pair_oxdna_stk.cpp @@ -15,27 +15,21 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna_stk.h" +#include #include -#include -#include #include +#include #include "mf_oxdna.h" #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "atom_vec_ellipsoid.h" #include "math_extra.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace MFOxdna; // sequence-specific stacking strength diff --git a/src/USER-CGDNA/pair_oxdna_xstk.cpp b/src/USER-CGDNA/pair_oxdna_xstk.cpp index 806f8a42c6..384a7768bd 100644 --- a/src/USER-CGDNA/pair_oxdna_xstk.cpp +++ b/src/USER-CGDNA/pair_oxdna_xstk.cpp @@ -15,9 +15,8 @@ ------------------------------------------------------------------------- */ #include "pair_oxdna_xstk.h" +#include #include -#include -#include #include #include "mf_oxdna.h" #include "atom.h" @@ -25,9 +24,6 @@ #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/USER-DPD/pair_dpd_fdt_energy.cpp b/src/USER-DPD/pair_dpd_fdt_energy.cpp index 12e6989c00..22741a055d 100644 --- a/src/USER-DPD/pair_dpd_fdt_energy.cpp +++ b/src/USER-DPD/pair_dpd_fdt_energy.cpp @@ -15,23 +15,20 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ +#include "pair_dpd_fdt_energy.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "update.h" #include "fix.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "random_mars.h" #include "memory.h" #include "modify.h" -#include "pair_dpd_fdt_energy.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-DPD/pair_exp6_rx.cpp b/src/USER-DPD/pair_exp6_rx.cpp index 13521b52b1..5cf2859ae3 100644 --- a/src/USER-DPD/pair_exp6_rx.cpp +++ b/src/USER-DPD/pair_exp6_rx.cpp @@ -11,17 +11,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "pair_exp6_rx.h" +#include #include -#include #include #include #include -#include "pair_exp6_rx.h" #include "atom.h" #include "comm.h" #include "force.h" #include "neigh_list.h" -#include "math_const.h" #include "math_special.h" #include "memory.h" #include "error.h" @@ -29,7 +28,6 @@ #include "fix.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace MathSpecial; #define MAXLINE 1024 diff --git a/src/USER-MESO/atom_vec_tdpd.cpp b/src/USER-MESO/atom_vec_tdpd.cpp index aa0dc93809..0db5437c4a 100644 --- a/src/USER-MESO/atom_vec_tdpd.cpp +++ b/src/USER-MESO/atom_vec_tdpd.cpp @@ -23,7 +23,6 @@ #include "update.h" #include "memory.h" #include "error.h" -#include "input.h" using namespace LAMMPS_NS; diff --git a/src/USER-MESO/compute_edpd_temp_atom.cpp b/src/USER-MESO/compute_edpd_temp_atom.cpp index 119e0079d1..9eb6e9752b 100644 --- a/src/USER-MESO/compute_edpd_temp_atom.cpp +++ b/src/USER-MESO/compute_edpd_temp_atom.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_edpd_temp_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MESO/fix_edpd_source.cpp b/src/USER-MESO/fix_edpd_source.cpp index 24bef2b1f7..e62d9a8a79 100644 --- a/src/USER-MESO/fix_edpd_source.cpp +++ b/src/USER-MESO/fix_edpd_source.cpp @@ -11,17 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "fix_edpd_source.h" +#include +#include #include "atom.h" -#include "comm.h" -#include "update.h" -#include "modify.h" -#include "domain.h" -#include "lattice.h" -#include "input.h" -#include "variable.h" #include "error.h" #include "force.h" diff --git a/src/USER-MESO/fix_mvv_edpd.cpp b/src/USER-MESO/fix_mvv_edpd.cpp index 8719d0d262..bd9cd9cc2a 100644 --- a/src/USER-MESO/fix_mvv_edpd.cpp +++ b/src/USER-MESO/fix_mvv_edpd.cpp @@ -29,13 +29,11 @@ Communications, 2015, 51: 11038-11040. ------------------------------------------------------------------------- */ -#include -#include #include "fix_mvv_edpd.h" +#include #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-MESO/fix_mvv_tdpd.cpp b/src/USER-MESO/fix_mvv_tdpd.cpp index 24b1bbcf48..b7fe37d7ee 100644 --- a/src/USER-MESO/fix_mvv_tdpd.cpp +++ b/src/USER-MESO/fix_mvv_tdpd.cpp @@ -25,13 +25,11 @@ -reaction problems". The Journal of Chemical Physics, 2015, 143: 014101. ------------------------------------------------------------------------- */ -#include -#include #include "fix_mvv_tdpd.h" +#include #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/VORONOI/compute_voronoi_atom.cpp b/src/VORONOI/compute_voronoi_atom.cpp index 27252fae89..d5976f85d3 100644 --- a/src/VORONOI/compute_voronoi_atom.cpp +++ b/src/VORONOI/compute_voronoi_atom.cpp @@ -19,7 +19,7 @@ #include #include #include -#include "voro++.hh" +#include #include "atom.h" #include "group.h" #include "update.h" From c2dc624ec90575027328f0b3b9ab52fff2b00631 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Tue, 9 Jul 2019 15:04:41 -0400 Subject: [PATCH 57/79] update packages USER-SPH, USER-SMTBQ, USER-SDPD, USER-TALLY, USER-UEF, USER-YAFF --- src/USER-SDPD/pair_sdpd_taitwater_isothermal.cpp | 3 +-- src/USER-SMTBQ/pair_smtbq.cpp | 7 +++---- src/USER-SPH/compute_meso_e_atom.cpp | 3 +-- src/USER-SPH/compute_meso_rho_atom.cpp | 3 +-- src/USER-SPH/compute_meso_t_atom.cpp | 3 +-- src/USER-SPH/fix_meso.cpp | 12 ------------ src/USER-SPH/fix_meso_stationary.cpp | 12 ------------ src/USER-SPH/pair_sph_heatconduction.cpp | 4 +--- src/USER-SPH/pair_sph_idealgas.cpp | 4 +--- src/USER-SPH/pair_sph_lj.cpp | 4 +--- src/USER-SPH/pair_sph_rhosum.cpp | 2 -- src/USER-SPH/pair_sph_taitwater.cpp | 3 +-- src/USER-SPH/pair_sph_taitwater_morris.cpp | 3 +-- src/USER-TALLY/compute_force_tally.cpp | 4 ++-- src/USER-TALLY/compute_heat_flux_tally.cpp | 2 +- src/USER-TALLY/compute_pe_mol_tally.cpp | 3 +-- src/USER-TALLY/compute_pe_tally.cpp | 2 +- src/USER-TALLY/compute_stress_tally.cpp | 2 +- src/USER-UEF/compute_pressure_uef.cpp | 9 +-------- src/USER-UEF/compute_temp_uef.cpp | 4 +--- src/USER-UEF/dump_cfg_uef.cpp | 8 ++------ src/USER-UEF/fix_nh_uef.cpp | 7 ++----- src/USER-YAFF/angle_cross.cpp | 4 +--- src/USER-YAFF/angle_cross.h | 1 - src/USER-YAFF/angle_mm3.cpp | 5 ++--- src/USER-YAFF/angle_mm3.h | 1 - src/USER-YAFF/bond_mm3.cpp | 5 ++--- src/USER-YAFF/bond_mm3.h | 1 - src/USER-YAFF/improper_distharm.cpp | 6 ++---- src/USER-YAFF/improper_distharm.h | 1 - src/USER-YAFF/improper_sqdistharm.cpp | 6 ++---- src/USER-YAFF/improper_sqdistharm.h | 1 - src/USER-YAFF/pair_lj_switch3_coulgauss_long.cpp | 8 +++----- src/USER-YAFF/pair_mm3_switch3_coulgauss_long.cpp | 8 +++----- 34 files changed, 39 insertions(+), 112 deletions(-) diff --git a/src/USER-SDPD/pair_sdpd_taitwater_isothermal.cpp b/src/USER-SDPD/pair_sdpd_taitwater_isothermal.cpp index db80debe51..d799869db3 100644 --- a/src/USER-SDPD/pair_sdpd_taitwater_isothermal.cpp +++ b/src/USER-SDPD/pair_sdpd_taitwater_isothermal.cpp @@ -18,9 +18,8 @@ references: Espanol and Revenga, Phys Rev E 67, 026705 (2003) ------------------------------------------------------------------------- */ -#include -#include #include "pair_sdpd_taitwater_isothermal.h" +#include #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/USER-SMTBQ/pair_smtbq.cpp b/src/USER-SMTBQ/pair_smtbq.cpp index ba7f8eb88c..f61fc1a72e 100644 --- a/src/USER-SMTBQ/pair_smtbq.cpp +++ b/src/USER-SMTBQ/pair_smtbq.cpp @@ -38,25 +38,24 @@ . ------------------------------------------------------------------------- */ +#include "pair_smtbq.h" +#include #include -#include #include #include +#include #include -#include "pair_smtbq.h" #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "group.h" #include "update.h" #include "math_const.h" #include "math_special.h" #include "memory.h" #include "error.h" -#include "domain.h" #include #include diff --git a/src/USER-SPH/compute_meso_e_atom.cpp b/src/USER-SPH/compute_meso_e_atom.cpp index e39dee2b5f..c56243e5ed 100644 --- a/src/USER-SPH/compute_meso_e_atom.cpp +++ b/src/USER-SPH/compute_meso_e_atom.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_meso_e_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SPH/compute_meso_rho_atom.cpp b/src/USER-SPH/compute_meso_rho_atom.cpp index eeb3f987bc..b2fbd2d70a 100644 --- a/src/USER-SPH/compute_meso_rho_atom.cpp +++ b/src/USER-SPH/compute_meso_rho_atom.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_meso_rho_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SPH/compute_meso_t_atom.cpp b/src/USER-SPH/compute_meso_t_atom.cpp index dc4f3407f1..bab96468dd 100644 --- a/src/USER-SPH/compute_meso_t_atom.cpp +++ b/src/USER-SPH/compute_meso_t_atom.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_meso_t_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SPH/fix_meso.cpp b/src/USER-SPH/fix_meso.cpp index b688eccfea..4f4e532291 100644 --- a/src/USER-SPH/fix_meso.cpp +++ b/src/USER-SPH/fix_meso.cpp @@ -11,23 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_meso.h" #include "atom.h" -#include "comm.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "update.h" -#include "integrate.h" -#include "respa.h" -#include "memory.h" #include "error.h" -#include "pair.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-SPH/fix_meso_stationary.cpp b/src/USER-SPH/fix_meso_stationary.cpp index 29e8a1554c..b7f0675ef8 100644 --- a/src/USER-SPH/fix_meso_stationary.cpp +++ b/src/USER-SPH/fix_meso_stationary.cpp @@ -11,23 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_meso_stationary.h" #include "atom.h" -#include "comm.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "update.h" -#include "integrate.h" -#include "respa.h" -#include "memory.h" #include "error.h" -#include "pair.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-SPH/pair_sph_heatconduction.cpp b/src/USER-SPH/pair_sph_heatconduction.cpp index bafa26be89..cff9009015 100644 --- a/src/USER-SPH/pair_sph_heatconduction.cpp +++ b/src/USER-SPH/pair_sph_heatconduction.cpp @@ -11,12 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "pair_sph_heatconduction.h" +#include #include "atom.h" #include "force.h" -#include "comm.h" #include "memory.h" #include "error.h" #include "neigh_list.h" diff --git a/src/USER-SPH/pair_sph_idealgas.cpp b/src/USER-SPH/pair_sph_idealgas.cpp index db5ec964bc..f206bf68f5 100644 --- a/src/USER-SPH/pair_sph_idealgas.cpp +++ b/src/USER-SPH/pair_sph_idealgas.cpp @@ -11,12 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "pair_sph_idealgas.h" +#include #include "atom.h" #include "force.h" -#include "comm.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SPH/pair_sph_lj.cpp b/src/USER-SPH/pair_sph_lj.cpp index 7d315c975c..3173e2a47d 100644 --- a/src/USER-SPH/pair_sph_lj.cpp +++ b/src/USER-SPH/pair_sph_lj.cpp @@ -11,12 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "pair_sph_lj.h" +#include #include "atom.h" #include "force.h" -#include "comm.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SPH/pair_sph_rhosum.cpp b/src/USER-SPH/pair_sph_rhosum.cpp index 842dddc744..fa51dc3781 100644 --- a/src/USER-SPH/pair_sph_rhosum.cpp +++ b/src/USER-SPH/pair_sph_rhosum.cpp @@ -11,8 +11,6 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "pair_sph_rhosum.h" #include "atom.h" #include "force.h" diff --git a/src/USER-SPH/pair_sph_taitwater.cpp b/src/USER-SPH/pair_sph_taitwater.cpp index cf3c0e914b..f2a34d4edd 100644 --- a/src/USER-SPH/pair_sph_taitwater.cpp +++ b/src/USER-SPH/pair_sph_taitwater.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "pair_sph_taitwater.h" +#include #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/USER-SPH/pair_sph_taitwater_morris.cpp b/src/USER-SPH/pair_sph_taitwater_morris.cpp index 5cbaa5959f..9ca03e3476 100644 --- a/src/USER-SPH/pair_sph_taitwater_morris.cpp +++ b/src/USER-SPH/pair_sph_taitwater_morris.cpp @@ -11,9 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "pair_sph_taitwater_morris.h" +#include #include "atom.h" #include "force.h" #include "comm.h" diff --git a/src/USER-TALLY/compute_force_tally.cpp b/src/USER-TALLY/compute_force_tally.cpp index 3339e0555b..9d15fbc441 100644 --- a/src/USER-TALLY/compute_force_tally.cpp +++ b/src/USER-TALLY/compute_force_tally.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "compute_force_tally.h" +#include +#include #include "atom.h" #include "group.h" #include "pair.h" diff --git a/src/USER-TALLY/compute_heat_flux_tally.cpp b/src/USER-TALLY/compute_heat_flux_tally.cpp index 2a5f724953..350bc4b4b6 100644 --- a/src/USER-TALLY/compute_heat_flux_tally.cpp +++ b/src/USER-TALLY/compute_heat_flux_tally.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_heat_flux_tally.h" +#include #include "atom.h" #include "group.h" #include "pair.h" diff --git a/src/USER-TALLY/compute_pe_mol_tally.cpp b/src/USER-TALLY/compute_pe_mol_tally.cpp index 5fabd4a77b..ce647a04c3 100644 --- a/src/USER-TALLY/compute_pe_mol_tally.cpp +++ b/src/USER-TALLY/compute_pe_mol_tally.cpp @@ -11,13 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_pe_mol_tally.h" +#include #include "atom.h" #include "group.h" #include "pair.h" #include "update.h" -#include "memory.h" #include "error.h" #include "force.h" #include "comm.h" diff --git a/src/USER-TALLY/compute_pe_tally.cpp b/src/USER-TALLY/compute_pe_tally.cpp index 8e6703bde1..edfa49b1b1 100644 --- a/src/USER-TALLY/compute_pe_tally.cpp +++ b/src/USER-TALLY/compute_pe_tally.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_pe_tally.h" +#include #include "atom.h" #include "group.h" #include "pair.h" diff --git a/src/USER-TALLY/compute_stress_tally.cpp b/src/USER-TALLY/compute_stress_tally.cpp index 07d685a9c2..1ea096e286 100644 --- a/src/USER-TALLY/compute_stress_tally.cpp +++ b/src/USER-TALLY/compute_stress_tally.cpp @@ -11,8 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_stress_tally.h" +#include #include "atom.h" #include "group.h" #include "pair.h" diff --git a/src/USER-UEF/compute_pressure_uef.cpp b/src/USER-UEF/compute_pressure_uef.cpp index 8b62853042..adb9970c12 100644 --- a/src/USER-UEF/compute_pressure_uef.cpp +++ b/src/USER-UEF/compute_pressure_uef.cpp @@ -13,21 +13,14 @@ Contributing author: David Nicholson (MIT) ------------------------------------------------------------------------- */ -#include -#include -#include #include "compute_pressure_uef.h" +#include #include "fix_nh_uef.h" #include "update.h" #include "domain.h" #include "modify.h" #include "fix.h" #include "force.h" -#include "pair.h" -#include "bond.h" -#include "angle.h" -#include "dihedral.h" -#include "improper.h" #include "kspace.h" #include "error.h" diff --git a/src/USER-UEF/compute_temp_uef.cpp b/src/USER-UEF/compute_temp_uef.cpp index 999296ec7e..698c4452c2 100644 --- a/src/USER-UEF/compute_temp_uef.cpp +++ b/src/USER-UEF/compute_temp_uef.cpp @@ -13,11 +13,9 @@ Contributing author: David Nicholson (MIT) ------------------------------------------------------------------------- */ -#include -#include #include "compute_temp_uef.h" +#include #include "fix_nh_uef.h" -#include "update.h" #include "modify.h" #include "fix.h" #include "error.h" diff --git a/src/USER-UEF/dump_cfg_uef.cpp b/src/USER-UEF/dump_cfg_uef.cpp index 58b3ec5a1f..5e3733f422 100644 --- a/src/USER-UEF/dump_cfg_uef.cpp +++ b/src/USER-UEF/dump_cfg_uef.cpp @@ -13,15 +13,11 @@ Contributing Author: David Nicholson (MIT) ------------------------------------------------------------------------- */ - -#include -#include -#include #include "dump_cfg.h" +#include +#include #include "atom.h" -#include "domain.h" #include "modify.h" -#include "compute.h" #include "fix.h" #include "error.h" #include "uef_utils.h" diff --git a/src/USER-UEF/fix_nh_uef.cpp b/src/USER-UEF/fix_nh_uef.cpp index bffcd7849f..8873688eb7 100644 --- a/src/USER-UEF/fix_nh_uef.cpp +++ b/src/USER-UEF/fix_nh_uef.cpp @@ -13,19 +13,16 @@ Contributing author: David Nicholson (MIT) ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_nh_uef.h" +#include +#include #include "atom.h" #include "force.h" -#include "group.h" #include "comm.h" #include "citeme.h" #include "irregular.h" #include "modify.h" #include "compute.h" -#include "kspace.h" #include "update.h" #include "domain.h" #include "error.h" diff --git a/src/USER-YAFF/angle_cross.cpp b/src/USER-YAFF/angle_cross.cpp index 2e6731f494..2ebb08f56b 100644 --- a/src/USER-YAFF/angle_cross.cpp +++ b/src/USER-YAFF/angle_cross.cpp @@ -15,10 +15,8 @@ Contributing author: Steven Vandenbrande ------------------------------------------------------------------------- */ -#include -#include -#include #include "angle_cross.h" +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-YAFF/angle_cross.h b/src/USER-YAFF/angle_cross.h index 7709c10414..ba958f98ec 100644 --- a/src/USER-YAFF/angle_cross.h +++ b/src/USER-YAFF/angle_cross.h @@ -20,7 +20,6 @@ AngleStyle(cross,AngleCross) #ifndef LMP_ANGLE_CROSS_H #define LMP_ANGLE_CROSS_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-YAFF/angle_mm3.cpp b/src/USER-YAFF/angle_mm3.cpp index 53cb11b5df..24ce8229ba 100644 --- a/src/USER-YAFF/angle_mm3.cpp +++ b/src/USER-YAFF/angle_mm3.cpp @@ -15,10 +15,9 @@ Contributing author: Steven Vandenbrande ------------------------------------------------------------------------- */ -#include -#include -#include #include "angle_mm3.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-YAFF/angle_mm3.h b/src/USER-YAFF/angle_mm3.h index 2d19b4d1b4..985c4bb9b4 100644 --- a/src/USER-YAFF/angle_mm3.h +++ b/src/USER-YAFF/angle_mm3.h @@ -20,7 +20,6 @@ AngleStyle(mm3,AngleMM3) #ifndef LMP_ANGLE_MM3_H #define LMP_ANGLE_MM3_H -#include #include "angle.h" namespace LAMMPS_NS { diff --git a/src/USER-YAFF/bond_mm3.cpp b/src/USER-YAFF/bond_mm3.cpp index ee1ebcdd61..2a7d5d1843 100644 --- a/src/USER-YAFF/bond_mm3.cpp +++ b/src/USER-YAFF/bond_mm3.cpp @@ -15,12 +15,11 @@ Contributing author: Steven Vandenbrande ------------------------------------------------------------------------- */ -#include -#include #include "bond_mm3.h" +#include +#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/USER-YAFF/bond_mm3.h b/src/USER-YAFF/bond_mm3.h index 9711d89529..56f3136ea8 100644 --- a/src/USER-YAFF/bond_mm3.h +++ b/src/USER-YAFF/bond_mm3.h @@ -20,7 +20,6 @@ BondStyle(mm3,BondMM3) #ifndef LMP_BOND_MM3_H #define LMP_BOND_MM3_H -#include #include "bond.h" namespace LAMMPS_NS { diff --git a/src/USER-YAFF/improper_distharm.cpp b/src/USER-YAFF/improper_distharm.cpp index b45087a9ab..2b62f827e7 100644 --- a/src/USER-YAFF/improper_distharm.cpp +++ b/src/USER-YAFF/improper_distharm.cpp @@ -16,16 +16,14 @@ improper_distance code by Paolo Raiteri (Curtin University) ------------------------------------------------------------------------- */ -#include -#include -#include #include "improper_distharm.h" +#include +#include #include "atom.h" #include "comm.h" #include "neighbor.h" #include "domain.h" #include "force.h" -#include "update.h" #include "memory.h" #include "error.h" diff --git a/src/USER-YAFF/improper_distharm.h b/src/USER-YAFF/improper_distharm.h index b8b9ae780e..0a8d34ac44 100644 --- a/src/USER-YAFF/improper_distharm.h +++ b/src/USER-YAFF/improper_distharm.h @@ -20,7 +20,6 @@ ImproperStyle(distharm,ImproperDistHarm) #ifndef LMP_IMPROPER_DISTHARM_H #define LMP_IMPROPER_DISTHARM_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/USER-YAFF/improper_sqdistharm.cpp b/src/USER-YAFF/improper_sqdistharm.cpp index ae702820cb..bcc0549f7e 100644 --- a/src/USER-YAFF/improper_sqdistharm.cpp +++ b/src/USER-YAFF/improper_sqdistharm.cpp @@ -16,16 +16,14 @@ improper_distance code by Paolo Raiteri (Curtin University) ------------------------------------------------------------------------- */ -#include -#include -#include #include "improper_sqdistharm.h" +#include +#include #include "atom.h" #include "comm.h" #include "neighbor.h" #include "domain.h" #include "force.h" -#include "update.h" #include "memory.h" #include "error.h" diff --git a/src/USER-YAFF/improper_sqdistharm.h b/src/USER-YAFF/improper_sqdistharm.h index 301b5066cb..3aceb01a03 100644 --- a/src/USER-YAFF/improper_sqdistharm.h +++ b/src/USER-YAFF/improper_sqdistharm.h @@ -20,7 +20,6 @@ ImproperStyle(sqdistharm,ImproperSQDistHarm) #ifndef LMP_IMPROPER_SQDISTHARM_H #define LMP_IMPROPER_SQDISTHARM_H -#include #include "improper.h" namespace LAMMPS_NS { diff --git a/src/USER-YAFF/pair_lj_switch3_coulgauss_long.cpp b/src/USER-YAFF/pair_lj_switch3_coulgauss_long.cpp index f37dcc3ed1..ab983a78bc 100644 --- a/src/USER-YAFF/pair_lj_switch3_coulgauss_long.cpp +++ b/src/USER-YAFF/pair_lj_switch3_coulgauss_long.cpp @@ -15,17 +15,15 @@ Contributing author: Steven Vandenbrande ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_switch3_coulgauss_long.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-YAFF/pair_mm3_switch3_coulgauss_long.cpp b/src/USER-YAFF/pair_mm3_switch3_coulgauss_long.cpp index 931ed1d116..4175ef915d 100644 --- a/src/USER-YAFF/pair_mm3_switch3_coulgauss_long.cpp +++ b/src/USER-YAFF/pair_mm3_switch3_coulgauss_long.cpp @@ -15,17 +15,15 @@ Contributing author: Steven Vandenbrande ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_mm3_switch3_coulgauss_long.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" From 39315268e885fba886a0ff30eccc619ffaa64c5f Mon Sep 17 00:00:00 2001 From: Steve Plimpton Date: Tue, 9 Jul 2019 16:53:19 -0600 Subject: [PATCH 58/79] new versions of jacobi() method --- src/math_extra.cpp | 227 +++++++++++++++++++++++++++++++++------------ src/math_extra.h | 9 +- 2 files changed, 174 insertions(+), 62 deletions(-) diff --git a/src/math_extra.cpp b/src/math_extra.cpp index f7e5bb646b..e72b3d3997 100644 --- a/src/math_extra.cpp +++ b/src/math_extra.cpp @@ -13,6 +13,7 @@ /* ---------------------------------------------------------------------- Contributing author: Mike Brown (SNL) + Arno Mayrhofer (DCS Computing), jacobi() functions ------------------------------------------------------------------------- */ #include @@ -95,83 +96,189 @@ int mldivide3(const double m[3][3], const double *v, double *ans) /* ---------------------------------------------------------------------- compute evalues and evectors of 3x3 real symmetric matrix based on Jacobi rotations - adapted from Numerical Recipes jacobi() function + two variants for passing in matrix + + procedure jacobi(S ∈ Rn×n; out e ∈ Rn; out E ∈ Rn×n) + var + i, k, l, m, state ∈ N + s, c, t, p, y, d, r ∈ R + ind ∈ Nn + changed ∈ Ln + ! init e, E, and arrays ind, changed + E := I; state := n + for k := 1 to n do indk := maxind(k); ek := Skk; changedk := true endfor + while state≠0 do ! next rotation + m := 1 ! find index (k,l) of pivot p + for k := 2 to n−1 do + if │Sk indk│ > │Sm indm│ then m := k endif + endfor + k := m; l := indm; p := Skl + ! calculate c = cos φ, s = sin φ + y := (el−ek)/2; d := │y│+√(p2+y2) + r := √(p2+d2); c := d/r; s := p/r; t := p2/d + if y<0 then s := −s; t := −t endif + Skl := 0.0; update(k,−t); update(l,t) + ! rotate rows and columns k and l + for i := 1 to k−1 do rotate(i,k,i,l) endfor + for i := k+1 to l−1 do rotate(k,i,i,l) endfor + for i := l+1 to n do rotate(k,i,l,i) endfor + ! rotate eigenvectors + for i := 1 to n do + ┌ ┐ ┌ ┐┌ ┐ + │Eik│ │c −s││Eik│ + │ │ := │ ││ │ + │Eil│ │s c││Eil│ + └ ┘ └ ┘└ ┘ + endfor + ! rows k, l have changed, update rows indk, indl + indk := maxind(k); indl := maxind(l) + loop + endproc ------------------------------------------------------------------------- */ int jacobi(double matrix[3][3], double *evalues, double evectors[3][3]) { - int i,j,k; - double tresh,theta,tau,t,sm,s,h,g,c,b[3],z[3]; + evectors[0][0] = 1.0; evectors[0][1] = 0.0; evectors[0][2] = 0.0; + evectors[1][0] = 0.0; evectors[1][1] = 1.0; evectors[1][2] = 0.0; + evectors[2][0] = 0.0; evectors[2][1] = 0.0; evectors[2][2] = 1.0; + evalues[0] = 0.0; evalues[1] = 0.0; evalues[2] = 0.0; + double threshold = 0.0; - for (i = 0; i < 3; i++) { - for (j = 0; j < 3; j++) evectors[i][j] = 0.0; - evectors[i][i] = 1.0; - } - for (i = 0; i < 3; i++) { - b[i] = evalues[i] = matrix[i][i]; - z[i] = 0.0; - } + for (int i = 0; i < 3; i++) + for (int j = i; j < 3; j++) + threshold += fabs(matrix[i][j]); - for (int iter = 1; iter <= MAXJACOBI; iter++) { - sm = 0.0; - for (i = 0; i < 2; i++) - for (j = i+1; j < 3; j++) - sm += fabs(matrix[i][j]); - if (sm == 0.0) return 0; + if (threshold < 1.0e-200) return 0; + threshold *= 1.0e-12; + int state = 2; + bool changed[3] = {true, true, true}; - if (iter < 4) tresh = 0.2*sm/(3*3); - else tresh = 0.0; - - for (i = 0; i < 2; i++) { - for (j = i+1; j < 3; j++) { - g = 100.0*fabs(matrix[i][j]); - if (iter > 4 && fabs(evalues[i])+g == fabs(evalues[i]) - && fabs(evalues[j])+g == fabs(evalues[j])) - matrix[i][j] = 0.0; - else if (fabs(matrix[i][j]) > tresh) { - h = evalues[j]-evalues[i]; - if (fabs(h)+g == fabs(h)) t = (matrix[i][j])/h; - else { - theta = 0.5*h/(matrix[i][j]); - t = 1.0/(fabs(theta)+sqrt(1.0+theta*theta)); - if (theta < 0.0) t = -t; - } - c = 1.0/sqrt(1.0+t*t); - s = t*c; - tau = s/(1.0+c); - h = t*matrix[i][j]; - z[i] -= h; - z[j] += h; - evalues[i] -= h; - evalues[j] += h; - matrix[i][j] = 0.0; - for (k = 0; k < i; k++) rotate(matrix,k,i,k,j,s,tau); - for (k = i+1; k < j; k++) rotate(matrix,i,k,k,j,s,tau); - for (k = j+1; k < 3; k++) rotate(matrix,i,k,j,k,s,tau); - for (k = 0; k < 3; k++) rotate(evectors,k,i,k,j,s,tau); + int iteration = 0; + while (state > 0 && iteration < MAXJACOBI) { + for (int k = 0; k < 2; k++) { + for (int l = k+1; l < 3; l++) { + const double p = matrix[k][l]; + const double y = (matrix[l][l]-matrix[k][k])*0.5; + const double d = fabs(y)+sqrt(p*p + y*y); + const double r = sqrt(p*p + d*d); + const double c = r > threshold ? d/r : 1.0; + double s = r > threshold ? p/r : 0.0; + double t = d > threshold ? p*p/d : 0.0; + if (y < 0.0) { + s *= -1.0; + t *= -1.0; } + matrix[k][l] = 0.0; + update_eigenvalue(matrix[k][k], changed[k], state, -t, threshold); + update_eigenvalue(matrix[l][l], changed[l], state, t, threshold); + for (int i = 0; i < k; i++) + rotate(matrix[i][k], matrix[i][l],c,s); + for (int i = k+1; i < l; i++) + rotate(matrix[k][i], matrix[i][l],c,s); + for (int i = l+1; i < 3; i++) + rotate(matrix[k][i], matrix[l][i],c,s); + for (int i = 0; i < 3; i++) + rotate(evectors[i][k], evectors[i][l],c,s); } } - - for (i = 0; i < 3; i++) { - evalues[i] = b[i] += z[i]; - z[i] = 0.0; - } + iteration++; } - return 1; + + for (int i = 0; i < 3; i++) + evalues[i] = matrix[i][i]; + + if (iteration == MAXJACOBI) return 1; + return 0; +} + +int jacobi(double **matrix, double *evalues, double **evectors) +{ + evectors[0][0] = 1.0; evectors[0][1] = 0.0; evectors[0][2] = 0.0; + evectors[1][0] = 0.0; evectors[1][1] = 1.0; evectors[1][2] = 0.0; + evectors[2][0] = 0.0; evectors[2][1] = 0.0; evectors[2][2] = 1.0; + evalues[0] = 0.0; evalues[1] = 0.0; evalues[2] = 0.0; + double threshold = 0.0; + + for (int i = 0; i < 3; i++) + for (int j = i; j < 3; j++) + threshold += fabs(matrix[i][j]); + + if (threshold < 1.0e-200) return 0; + threshold *= 1.0e-12; + int state = 2; + bool changed[3] = {true, true, true}; + + int iteration = 0; + while (state > 0 && iteration < MAXJACOBI) { + for (int k = 0; k < 2; k++) { + for (int l = k+1; l < 3; l++) { + const double p = matrix[k][l]; + const double y = (matrix[l][l]-matrix[k][k])*0.5; + const double d = fabs(y)+sqrt(p*p + y*y); + const double r = sqrt(p*p + d*d); + const double c = r > threshold ? d/r : 1.0; + double s = r > threshold ? p/r : 0.0; + double t = d > threshold ? p*p/d : 0.0; + if (y < 0.0) { + s *= -1.0; + t *= -1.0; + } + matrix[k][l] = 0.0; + update_eigenvalue(matrix[k][k], changed[k], state, -t, threshold); + update_eigenvalue(matrix[l][l], changed[l], state, t, threshold); + for (int i = 0; i < k; i++) + rotate(matrix[i][k], matrix[i][l],c,s); + for (int i = k+1; i < l; i++) + rotate(matrix[k][i], matrix[i][l],c,s); + for (int i = l+1; i < 3; i++) + rotate(matrix[k][i], matrix[l][i],c,s); + for (int i = 0; i < 3; i++) + rotate(evectors[i][k], evectors[i][l],c,s); + } + } + iteration++; + } + + for (int i = 0; i < 3; i++) + evalues[i] = matrix[i][i]; + + if (iteration == MAXJACOBI) return 1; + return 0; } /* ---------------------------------------------------------------------- - perform a single Jacobi rotation + perform a single Jacobi rotation of Sij, Skl + ┌ ┐ ┌ ┐┌ ┐ + │Skl│ │c −s││Skl│ + │ │ := │ ││ │ + │Sij│ │s c││Sij│ + └ ┘ └ ┘└ ┘ ------------------------------------------------------------------------- */ -void rotate(double matrix[3][3], int i, int j, int k, int l, - double s, double tau) +void rotate(double &matrix_kl, double &matrix_ij, + const double c, const double s) { - double g = matrix[i][j]; - double h = matrix[k][l]; - matrix[i][j] = g-s*(h+g*tau); - matrix[k][l] = h+s*(g-h*tau); + const double tmp_kl = matrix_kl; + matrix_kl = c*matrix_kl - s*matrix_ij; + matrix_ij = s*tmp_kl + c*matrix_ij; +} + +/* ---------------------------------------------------------------------- + update eigenvalue and its status +------------------------------------------------------------------------- */ + +void update_eigenvalue(double &eigenvalue, bool &changed, int &state, + const double t, const double threshold) +{ + eigenvalue += t; + + if (changed && fabs(t) < threshold) { + changed = false; + state--; + } else if (!changed && fabs(t) > threshold) { + changed = true; + state++; + } } /* ---------------------------------------------------------------------- diff --git a/src/math_extra.h b/src/math_extra.h index 85f57224cf..2befc7ee97 100644 --- a/src/math_extra.h +++ b/src/math_extra.h @@ -77,9 +77,14 @@ namespace MathExtra { void write3(const double mat[3][3]); int mldivide3(const double mat[3][3], const double *vec, double *ans); + int jacobi(double matrix[3][3], double *evalues, double evectors[3][3]); - void rotate(double matrix[3][3], int i, int j, int k, int l, - double s, double tau); + int jacobi(double **matrix, double *evalues, double **evectors); + void rotate(double &matrix_kl, double &matrix_ij, + const double c, const double s); + void update_eigenvalue(double &eigenvalue, bool &changed, int &state, + const double t, const double threshold); + void richardson(double *q, double *m, double *w, double *moments, double dtq); void no_squish_rotate(int k, double *p, double *q, double *inertia, double dt); From 93748a18ae4fd370e43244fed4c5e3b07eae4e4f Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 10 Jul 2019 00:22:03 -0400 Subject: [PATCH 59/79] further clean up of AtomVec classes after merging PR #1552 to master --- src/DIPOLE/atom_vec_dipole.cpp | 2 -- src/KOKKOS/atom_vec_angle_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_atomic_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_bond_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_charge_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_dpd_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_full_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_hybrid_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_molecular_kokkos.cpp | 2 -- src/KOKKOS/atom_vec_sphere_kokkos.cpp | 2 -- src/MOLECULE/atom_vec_angle.cpp | 2 -- src/MOLECULE/atom_vec_bond.cpp | 2 -- src/MOLECULE/atom_vec_full.cpp | 2 -- src/MOLECULE/atom_vec_molecular.cpp | 2 -- src/MOLECULE/atom_vec_template.cpp | 2 -- src/PERI/atom_vec_peri.cpp | 2 -- src/SPIN/atom_vec_spin.cpp | 2 -- src/USER-AWPMD/atom_vec_wavepacket.cpp | 2 -- src/USER-DPD/atom_vec_dpd.cpp | 2 -- src/USER-EFF/atom_vec_electron.cpp | 3 +-- src/USER-MESO/atom_vec_edpd.cpp | 4 +--- src/USER-MESO/atom_vec_mdpd.cpp | 4 +--- src/USER-MESO/atom_vec_tdpd.cpp | 8 +++----- src/USER-SMD/atom_vec_smd.cpp | 6 ++---- src/USER-SPH/atom_vec_meso.cpp | 4 +--- src/atom_vec.cpp | 1 - src/atom_vec_atomic.cpp | 2 -- src/atom_vec_body.cpp | 1 - src/atom_vec_charge.cpp | 2 -- src/atom_vec_ellipsoid.cpp | 1 - src/atom_vec_hybrid.cpp | 2 -- src/atom_vec_line.cpp | 1 - src/atom_vec_sphere.cpp | 1 - src/atom_vec_tri.cpp | 1 - 34 files changed, 9 insertions(+), 70 deletions(-) diff --git a/src/DIPOLE/atom_vec_dipole.cpp b/src/DIPOLE/atom_vec_dipole.cpp index 945732f74b..a3ff3fd0f5 100644 --- a/src/DIPOLE/atom_vec_dipole.cpp +++ b/src/DIPOLE/atom_vec_dipole.cpp @@ -13,11 +13,9 @@ #include "atom_vec_dipole.h" #include -#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/KOKKOS/atom_vec_angle_kokkos.cpp b/src/KOKKOS/atom_vec_angle_kokkos.cpp index b8f5634fa0..736e1c1fca 100644 --- a/src/KOKKOS/atom_vec_angle_kokkos.cpp +++ b/src/KOKKOS/atom_vec_angle_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_angle_kokkos.h" -#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "atom_masks.h" diff --git a/src/KOKKOS/atom_vec_atomic_kokkos.cpp b/src/KOKKOS/atom_vec_atomic_kokkos.cpp index f65f34419a..4fec5740d6 100644 --- a/src/KOKKOS/atom_vec_atomic_kokkos.cpp +++ b/src/KOKKOS/atom_vec_atomic_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_atomic_kokkos.h" -#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "atom_masks.h" diff --git a/src/KOKKOS/atom_vec_bond_kokkos.cpp b/src/KOKKOS/atom_vec_bond_kokkos.cpp index c36b084637..74c05a506c 100644 --- a/src/KOKKOS/atom_vec_bond_kokkos.cpp +++ b/src/KOKKOS/atom_vec_bond_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_bond_kokkos.h" -#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "atom_masks.h" diff --git a/src/KOKKOS/atom_vec_charge_kokkos.cpp b/src/KOKKOS/atom_vec_charge_kokkos.cpp index 631c4b237c..3f26b1e9ea 100644 --- a/src/KOKKOS/atom_vec_charge_kokkos.cpp +++ b/src/KOKKOS/atom_vec_charge_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_charge_kokkos.h" -#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "atom_masks.h" diff --git a/src/KOKKOS/atom_vec_dpd_kokkos.cpp b/src/KOKKOS/atom_vec_dpd_kokkos.cpp index e7123037ca..4162b71374 100644 --- a/src/KOKKOS/atom_vec_dpd_kokkos.cpp +++ b/src/KOKKOS/atom_vec_dpd_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_dpd_kokkos.h" -#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "atom_masks.h" diff --git a/src/KOKKOS/atom_vec_full_kokkos.cpp b/src/KOKKOS/atom_vec_full_kokkos.cpp index 4b6e413b64..1fdbcbec8c 100644 --- a/src/KOKKOS/atom_vec_full_kokkos.cpp +++ b/src/KOKKOS/atom_vec_full_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_full_kokkos.h" -#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "atom_masks.h" diff --git a/src/KOKKOS/atom_vec_hybrid_kokkos.cpp b/src/KOKKOS/atom_vec_hybrid_kokkos.cpp index 630648b3a6..318e79d955 100644 --- a/src/KOKKOS/atom_vec_hybrid_kokkos.cpp +++ b/src/KOKKOS/atom_vec_hybrid_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_hybrid_kokkos.h" -#include #include #include "atom_kokkos.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory_kokkos.h" diff --git a/src/KOKKOS/atom_vec_molecular_kokkos.cpp b/src/KOKKOS/atom_vec_molecular_kokkos.cpp index 8790f0bdbc..f3b4ae98ca 100644 --- a/src/KOKKOS/atom_vec_molecular_kokkos.cpp +++ b/src/KOKKOS/atom_vec_molecular_kokkos.cpp @@ -12,13 +12,11 @@ ------------------------------------------------------------------------- */ #include "atom_vec_molecular_kokkos.h" -#include #include "atom_kokkos.h" #include "comm_kokkos.h" #include "domain.h" #include "modify.h" #include "fix.h" -#include "force.h" #include "atom_masks.h" #include "memory_kokkos.h" #include "error.h" diff --git a/src/KOKKOS/atom_vec_sphere_kokkos.cpp b/src/KOKKOS/atom_vec_sphere_kokkos.cpp index 0f69cc9c5a..d93b98a4b0 100644 --- a/src/KOKKOS/atom_vec_sphere_kokkos.cpp +++ b/src/KOKKOS/atom_vec_sphere_kokkos.cpp @@ -13,14 +13,12 @@ #include "atom_vec_sphere_kokkos.h" #include -#include #include #include "atom_kokkos.h" #include "atom_masks.h" #include "comm_kokkos.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "fix_adapt.h" #include "math_const.h" diff --git a/src/MOLECULE/atom_vec_angle.cpp b/src/MOLECULE/atom_vec_angle.cpp index c8053266ca..b6f5a013cb 100644 --- a/src/MOLECULE/atom_vec_angle.cpp +++ b/src/MOLECULE/atom_vec_angle.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_angle.h" -#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/MOLECULE/atom_vec_bond.cpp b/src/MOLECULE/atom_vec_bond.cpp index 0d267d10cc..b9d4177b4f 100644 --- a/src/MOLECULE/atom_vec_bond.cpp +++ b/src/MOLECULE/atom_vec_bond.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_bond.h" -#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/MOLECULE/atom_vec_full.cpp b/src/MOLECULE/atom_vec_full.cpp index 167edde18f..e71e23a661 100644 --- a/src/MOLECULE/atom_vec_full.cpp +++ b/src/MOLECULE/atom_vec_full.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_full.h" -#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/MOLECULE/atom_vec_molecular.cpp b/src/MOLECULE/atom_vec_molecular.cpp index 5ccf5529b4..1bafb6dc43 100644 --- a/src/MOLECULE/atom_vec_molecular.cpp +++ b/src/MOLECULE/atom_vec_molecular.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_molecular.h" -#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/MOLECULE/atom_vec_template.cpp b/src/MOLECULE/atom_vec_template.cpp index ae31870fd0..27c6ab4183 100644 --- a/src/MOLECULE/atom_vec_template.cpp +++ b/src/MOLECULE/atom_vec_template.cpp @@ -12,10 +12,8 @@ ------------------------------------------------------------------------- */ #include "atom_vec_template.h" -#include #include "atom.h" #include "molecule.h" -#include "force.h" #include "comm.h" #include "domain.h" #include "modify.h" diff --git a/src/PERI/atom_vec_peri.cpp b/src/PERI/atom_vec_peri.cpp index 0829dfb1c0..47b88995b8 100644 --- a/src/PERI/atom_vec_peri.cpp +++ b/src/PERI/atom_vec_peri.cpp @@ -17,12 +17,10 @@ #include "atom_vec_peri.h" #include -#include #include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "citeme.h" diff --git a/src/SPIN/atom_vec_spin.cpp b/src/SPIN/atom_vec_spin.cpp index 345a2d6c04..f5560b6ee9 100644 --- a/src/SPIN/atom_vec_spin.cpp +++ b/src/SPIN/atom_vec_spin.cpp @@ -25,14 +25,12 @@ #include "atom_vec_spin.h" #include -#include #include #include "atom.h" #include "comm.h" #include "domain.h" #include "error.h" #include "fix.h" -#include "force.h" #include "memory.h" #include "modify.h" #include "utils.h" diff --git a/src/USER-AWPMD/atom_vec_wavepacket.cpp b/src/USER-AWPMD/atom_vec_wavepacket.cpp index bafd172254..c12798688e 100644 --- a/src/USER-AWPMD/atom_vec_wavepacket.cpp +++ b/src/USER-AWPMD/atom_vec_wavepacket.cpp @@ -17,13 +17,11 @@ #include "atom_vec_wavepacket.h" #include -#include #include #include "atom.h" #include "comm.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "memory.h" #include "error.h" diff --git a/src/USER-DPD/atom_vec_dpd.cpp b/src/USER-DPD/atom_vec_dpd.cpp index 2aef55ff9f..bf11840d1e 100644 --- a/src/USER-DPD/atom_vec_dpd.cpp +++ b/src/USER-DPD/atom_vec_dpd.cpp @@ -15,12 +15,10 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ -#include #include "atom_vec_dpd.h" #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/USER-EFF/atom_vec_electron.cpp b/src/USER-EFF/atom_vec_electron.cpp index cca71545f4..707a75c7c1 100644 --- a/src/USER-EFF/atom_vec_electron.cpp +++ b/src/USER-EFF/atom_vec_electron.cpp @@ -15,9 +15,8 @@ Contributing author: Andres Jaramillo-Botero (Caltech) ------------------------------------------------------------------------- */ -#include -#include #include "atom_vec_electron.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/USER-MESO/atom_vec_edpd.cpp b/src/USER-MESO/atom_vec_edpd.cpp index ff8515abc6..dccc8b9efa 100644 --- a/src/USER-MESO/atom_vec_edpd.cpp +++ b/src/USER-MESO/atom_vec_edpd.cpp @@ -10,13 +10,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "atom_vec_edpd.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "update.h" diff --git a/src/USER-MESO/atom_vec_mdpd.cpp b/src/USER-MESO/atom_vec_mdpd.cpp index 965891a283..0aa6aedcee 100644 --- a/src/USER-MESO/atom_vec_mdpd.cpp +++ b/src/USER-MESO/atom_vec_mdpd.cpp @@ -11,13 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "atom_vec_mdpd.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "update.h" diff --git a/src/USER-MESO/atom_vec_tdpd.cpp b/src/USER-MESO/atom_vec_tdpd.cpp index f19758f884..278baa2024 100644 --- a/src/USER-MESO/atom_vec_tdpd.cpp +++ b/src/USER-MESO/atom_vec_tdpd.cpp @@ -11,12 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "atom_vec_tdpd.h" +#include #include "atom.h" #include "comm.h" -#include "force.h" #include "domain.h" #include "modify.h" #include "fix.h" @@ -65,7 +63,7 @@ void AtomVecTDPD::process_args(int narg, char **arg) { if (narg < 1) error->all(FLERR,"Invalid atom_style tdpd command"); - atom->cc_species = force->inumeric(FLERR,arg[0]); + atom->cc_species = utils::inumeric(FLERR,arg[0],false,lmp); cc_species = atom->cc_species; // reset sizes that depend on cc_species @@ -801,7 +799,7 @@ void AtomVecTDPD::data_atom(double *coord, imageint imagetmp, char **values) x[nlocal][2] = coord[2]; for(int k = 0; k < cc_species; k++) - cc[nlocal][k] = atof( values[5+k] ); + cc[nlocal][k] = utils::numeric(FLERR,values[5+k],true,lmp); image[nlocal] = imagetmp; diff --git a/src/USER-SMD/atom_vec_smd.cpp b/src/USER-SMD/atom_vec_smd.cpp index 278652bf43..5cc411a832 100644 --- a/src/USER-SMD/atom_vec_smd.cpp +++ b/src/USER-SMD/atom_vec_smd.cpp @@ -22,15 +22,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include #include "atom_vec_smd.h" +#include +#include #include "atom.h" #include "comm.h" #include "domain.h" #include "modify.h" -#include "force.h" #include "fix.h" #include "fix_adapt.h" #include "math_const.h" diff --git a/src/USER-SPH/atom_vec_meso.cpp b/src/USER-SPH/atom_vec_meso.cpp index 0960141ae2..59e6638f16 100644 --- a/src/USER-SPH/atom_vec_meso.cpp +++ b/src/USER-SPH/atom_vec_meso.cpp @@ -11,13 +11,11 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "atom_vec_meso.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/atom_vec.cpp b/src/atom_vec.cpp index 146a503221..1ea085b869 100644 --- a/src/atom_vec.cpp +++ b/src/atom_vec.cpp @@ -13,7 +13,6 @@ #include "atom_vec.h" #include -#include #include "atom.h" #include "force.h" #include "domain.h" diff --git a/src/atom_vec_atomic.cpp b/src/atom_vec_atomic.cpp index f1583ab8cc..3cf037f182 100644 --- a/src/atom_vec_atomic.cpp +++ b/src/atom_vec_atomic.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_atomic.h" -#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/atom_vec_body.cpp b/src/atom_vec_body.cpp index 622b698bd9..53ed708c4e 100644 --- a/src/atom_vec_body.cpp +++ b/src/atom_vec_body.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "atom_vec_body.h" -#include #include #include #include "my_pool_chunk.h" diff --git a/src/atom_vec_charge.cpp b/src/atom_vec_charge.cpp index da863f0949..923d892acd 100644 --- a/src/atom_vec_charge.cpp +++ b/src/atom_vec_charge.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_charge.h" -#include #include "atom.h" #include "comm.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/atom_vec_ellipsoid.cpp b/src/atom_vec_ellipsoid.cpp index 44cd818c9d..586e6a80ff 100644 --- a/src/atom_vec_ellipsoid.cpp +++ b/src/atom_vec_ellipsoid.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include "atom_vec_ellipsoid.h" -#include #include #include "math_extra.h" #include "atom.h" diff --git a/src/atom_vec_hybrid.cpp b/src/atom_vec_hybrid.cpp index 25c85b2e3d..9ad07b9032 100644 --- a/src/atom_vec_hybrid.cpp +++ b/src/atom_vec_hybrid.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "atom_vec_hybrid.h" -#include #include #include "atom.h" #include "domain.h" -#include "force.h" #include "modify.h" #include "fix.h" #include "memory.h" diff --git a/src/atom_vec_line.cpp b/src/atom_vec_line.cpp index f9feb9b046..30736c02c9 100644 --- a/src/atom_vec_line.cpp +++ b/src/atom_vec_line.cpp @@ -13,7 +13,6 @@ #include "atom_vec_line.h" #include -#include #include #include "atom.h" #include "comm.h" diff --git a/src/atom_vec_sphere.cpp b/src/atom_vec_sphere.cpp index 1defcf8d01..9d52d005ba 100644 --- a/src/atom_vec_sphere.cpp +++ b/src/atom_vec_sphere.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "atom_vec_sphere.h" -#include #include #include "atom.h" #include "comm.h" diff --git a/src/atom_vec_tri.cpp b/src/atom_vec_tri.cpp index 8835255591..640e0fcb34 100644 --- a/src/atom_vec_tri.cpp +++ b/src/atom_vec_tri.cpp @@ -13,7 +13,6 @@ #include "atom_vec_tri.h" #include -#include #include #include "math_extra.h" #include "atom.h" From 0f691de031b8000f91e451172d72f329c937c428 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 10 Jul 2019 00:50:34 -0400 Subject: [PATCH 60/79] include file cleanup in some more packages --- src/SPIN/fix_setforce_spin.cpp | 1 - src/USER-CGDNA/bond_oxdna_fene.cpp | 1 + src/USER-CGSDK/angle_sdk.cpp | 2 +- src/USER-CGSDK/pair_lj_sdk.cpp | 7 +------ src/USER-CGSDK/pair_lj_sdk_coul_long.cpp | 8 +------- src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp | 9 --------- src/USER-DIFFRACTION/compute_saed.cpp | 3 +-- src/USER-DIFFRACTION/compute_xrd.cpp | 3 +-- src/USER-DIFFRACTION/fix_saed_vtk.cpp | 5 +---- src/USER-DPD/compute_dpd.cpp | 5 +---- src/USER-DPD/compute_dpd_atom.cpp | 8 +------- src/USER-DPD/fix_dpd_energy.cpp | 4 ---- src/USER-DPD/fix_eos_cv.cpp | 2 -- src/USER-DPD/fix_eos_table.cpp | 3 ++- src/USER-DPD/fix_eos_table_rx.cpp | 3 ++- src/USER-DPD/fix_rx.cpp | 4 ++-- src/USER-DPD/fix_shardlow.cpp | 5 +---- src/USER-DPD/nbin_ssa.cpp | 2 -- src/USER-DPD/npair_half_bin_newton_ssa.cpp | 2 -- src/USER-DPD/nstencil_half_bin_2d_newton_ssa.cpp | 2 -- src/USER-DPD/nstencil_half_bin_3d_newton_ssa.cpp | 2 -- src/USER-DPD/pair_dpd_fdt.cpp | 7 ++----- src/USER-DPD/pair_table_rx.cpp | 4 +--- src/USER-DRUDE/compute_temp_drude.cpp | 10 +++------- src/USER-DRUDE/compute_temp_drude.h | 3 +-- src/USER-DRUDE/fix_drude.cpp | 5 +++-- src/USER-DRUDE/fix_drude_transform.cpp | 4 ++-- src/USER-DRUDE/fix_drude_transform.h | 3 +-- src/USER-DRUDE/fix_langevin_drude.cpp | 7 +++---- src/USER-DRUDE/fix_langevin_drude.h | 3 +-- src/USER-DRUDE/pair_lj_cut_thole_long.cpp | 11 ++++------- src/USER-DRUDE/pair_lj_cut_thole_long.h | 3 +-- src/USER-DRUDE/pair_thole.cpp | 9 ++++----- src/USER-DRUDE/pair_thole.h | 3 +-- src/USER-EFF/compute_temp_eff.cpp | 3 +-- src/USER-FEP/compute_fep.cpp | 3 +-- src/USER-FEP/fix_adapt_fep.cpp | 4 +--- src/USER-FEP/pair_coul_cut_soft.cpp | 7 +++---- src/USER-FEP/pair_coul_long_soft.cpp | 9 +++------ src/USER-FEP/pair_lj_charmm_coul_long_soft.cpp | 8 +++----- src/USER-FEP/pair_lj_class2_coul_cut_soft.cpp | 7 +++---- src/USER-FEP/pair_lj_class2_coul_long_soft.cpp | 7 +++---- src/USER-FEP/pair_lj_class2_soft.cpp | 7 +++---- src/USER-FEP/pair_lj_cut_coul_cut_soft.cpp | 7 +++---- src/USER-FEP/pair_lj_cut_coul_long_soft.cpp | 8 +++----- src/USER-FEP/pair_lj_cut_soft.cpp | 8 +++----- src/USER-FEP/pair_lj_cut_tip4p_long_soft.cpp | 11 +++-------- src/USER-FEP/pair_morse_soft.cpp | 7 +++---- src/USER-FEP/pair_tip4p_long_soft.cpp | 11 +++-------- src/USER-MESO/fix_mvv_dpd.cpp | 4 +--- src/USER-MESO/fix_tdpd_source.cpp | 11 ++--------- src/USER-MESO/pair_edpd.cpp | 6 ++---- src/USER-MESO/pair_mdpd.cpp | 8 +++----- src/USER-MESO/pair_mdpd_rhosum.cpp | 5 +---- src/USER-MESO/pair_tdpd.cpp | 7 ++----- 55 files changed, 93 insertions(+), 208 deletions(-) diff --git a/src/SPIN/fix_setforce_spin.cpp b/src/SPIN/fix_setforce_spin.cpp index 15e5aacfb6..e36a9d260d 100644 --- a/src/SPIN/fix_setforce_spin.cpp +++ b/src/SPIN/fix_setforce_spin.cpp @@ -22,7 +22,6 @@ ------------------------------------------------------------------------- */ #include "fix_setforce_spin.h" -#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/USER-CGDNA/bond_oxdna_fene.cpp b/src/USER-CGDNA/bond_oxdna_fene.cpp index 8314576d63..2f76e67ef4 100644 --- a/src/USER-CGDNA/bond_oxdna_fene.cpp +++ b/src/USER-CGDNA/bond_oxdna_fene.cpp @@ -15,6 +15,7 @@ ------------------------------------------------------------------------- */ #include "bond_oxdna_fene.h" +#include #include #include "atom.h" #include "neighbor.h" diff --git a/src/USER-CGSDK/angle_sdk.cpp b/src/USER-CGSDK/angle_sdk.cpp index 575b0fae69..862c165bbd 100644 --- a/src/USER-CGSDK/angle_sdk.cpp +++ b/src/USER-CGSDK/angle_sdk.cpp @@ -19,8 +19,8 @@ ------------------------------------------------------------------------- */ #include "angle_sdk.h" +#include #include -#include #include "atom.h" #include "neighbor.h" #include "pair.h" diff --git a/src/USER-CGSDK/pair_lj_sdk.cpp b/src/USER-CGSDK/pair_lj_sdk.cpp index b22469566e..6ad77a6183 100644 --- a/src/USER-CGSDK/pair_lj_sdk.cpp +++ b/src/USER-CGSDK/pair_lj_sdk.cpp @@ -17,18 +17,13 @@ ------------------------------------------------------------------------- */ #include "pair_lj_sdk.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp b/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp index 5fba8cde66..62acf00d27 100644 --- a/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp +++ b/src/USER-CGSDK/pair_lj_sdk_coul_long.cpp @@ -17,9 +17,8 @@ ------------------------------------------------------------------------- */ #include "pair_lj_sdk_coul_long.h" +#include #include -#include -#include #include #include "atom.h" #include "comm.h" @@ -27,10 +26,6 @@ #include "kspace.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "math_const.h" #include "memory.h" #include "error.h" @@ -38,7 +33,6 @@ #include "lj_sdk_common.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace LJSDKParms; #define EWALD_F 1.12837917 diff --git a/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp b/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp index b61ed5528f..1095521de3 100644 --- a/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp +++ b/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp @@ -18,26 +18,17 @@ #include "pair_lj_sdk_coul_msm.h" #include -#include -#include #include #include "atom.h" -#include "comm.h" #include "force.h" #include "kspace.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "lj_sdk_common.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace LJSDKParms; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-DIFFRACTION/compute_saed.cpp b/src/USER-DIFFRACTION/compute_saed.cpp index dcafe57ba8..971d9bd380 100644 --- a/src/USER-DIFFRACTION/compute_saed.cpp +++ b/src/USER-DIFFRACTION/compute_saed.cpp @@ -15,13 +15,12 @@ Contributing authors: Shawn Coleman & Douglas Spearot (Arkansas) ------------------------------------------------------------------------- */ +#include "compute_saed.h" #include #include #include -#include #include #include "math_const.h" -#include "compute_saed.h" #include "compute_saed_consts.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-DIFFRACTION/compute_xrd.cpp b/src/USER-DIFFRACTION/compute_xrd.cpp index d6b7549272..f48951f1ff 100644 --- a/src/USER-DIFFRACTION/compute_xrd.cpp +++ b/src/USER-DIFFRACTION/compute_xrd.cpp @@ -16,13 +16,12 @@ Updated: 06/17/2015-2 ------------------------------------------------------------------------- */ +#include "compute_xrd.h" #include #include #include -#include #include #include "math_const.h" -#include "compute_xrd.h" #include "compute_xrd_consts.h" #include "atom.h" #include "comm.h" diff --git a/src/USER-DIFFRACTION/fix_saed_vtk.cpp b/src/USER-DIFFRACTION/fix_saed_vtk.cpp index 4d9af66818..c3a72e494b 100644 --- a/src/USER-DIFFRACTION/fix_saed_vtk.cpp +++ b/src/USER-DIFFRACTION/fix_saed_vtk.cpp @@ -16,17 +16,14 @@ Incorporating SAED: Shawn Coleman (Arkansas) ------------------------------------------------------------------------- */ +#include "fix_saed_vtk.h" #include #include #include -#include "fix_saed_vtk.h" #include "update.h" #include "modify.h" #include "compute.h" #include "compute_saed.h" -#include "group.h" -#include "input.h" -#include "variable.h" #include "memory.h" #include "error.h" #include "force.h" diff --git a/src/USER-DPD/compute_dpd.cpp b/src/USER-DPD/compute_dpd.cpp index 08aa19bcdf..0ef7868164 100644 --- a/src/USER-DPD/compute_dpd.cpp +++ b/src/USER-DPD/compute_dpd.cpp @@ -15,13 +15,10 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ -#include #include "compute_dpd.h" +#include #include "atom.h" #include "update.h" -#include "force.h" -#include "domain.h" -#include "group.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-DPD/compute_dpd_atom.cpp b/src/USER-DPD/compute_dpd_atom.cpp index 78f842a68f..0fd732f669 100644 --- a/src/USER-DPD/compute_dpd_atom.cpp +++ b/src/USER-DPD/compute_dpd_atom.cpp @@ -15,21 +15,15 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ -#include -#include -#include #include "compute_dpd_atom.h" +#include #include "atom.h" #include "update.h" #include "modify.h" -#include "domain.h" -#include "group.h" #include "memory.h" #include "error.h" #include "comm.h" -#include - using namespace LAMMPS_NS; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-DPD/fix_dpd_energy.cpp b/src/USER-DPD/fix_dpd_energy.cpp index 5759a164f5..6ee88ea88a 100644 --- a/src/USER-DPD/fix_dpd_energy.cpp +++ b/src/USER-DPD/fix_dpd_energy.cpp @@ -11,14 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "fix_dpd_energy.h" #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" -#include "modify.h" #include "error.h" #include "pair_dpd_fdt_energy.h" diff --git a/src/USER-DPD/fix_eos_cv.cpp b/src/USER-DPD/fix_eos_cv.cpp index 919e6829f3..5b25519a40 100644 --- a/src/USER-DPD/fix_eos_cv.cpp +++ b/src/USER-DPD/fix_eos_cv.cpp @@ -15,8 +15,6 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ -#include -#include #include "fix_eos_cv.h" #include "atom.h" #include "error.h" diff --git a/src/USER-DPD/fix_eos_table.cpp b/src/USER-DPD/fix_eos_table.cpp index 7d701f5fb8..ff9a186c47 100644 --- a/src/USER-DPD/fix_eos_table.cpp +++ b/src/USER-DPD/fix_eos_table.cpp @@ -15,9 +15,10 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ +#include "fix_eos_table.h" +#include #include #include -#include "fix_eos_table.h" #include "atom.h" #include "error.h" #include "force.h" diff --git a/src/USER-DPD/fix_eos_table_rx.cpp b/src/USER-DPD/fix_eos_table_rx.cpp index 779cee0e8b..9f1bd6a3bb 100644 --- a/src/USER-DPD/fix_eos_table_rx.cpp +++ b/src/USER-DPD/fix_eos_table_rx.cpp @@ -15,10 +15,11 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ +#include "fix_eos_table_rx.h" +#include #include #include #include -#include "fix_eos_table_rx.h" #include "atom.h" #include "error.h" #include "force.h" diff --git a/src/USER-DPD/fix_rx.cpp b/src/USER-DPD/fix_rx.cpp index cb8349786f..03e8ae49a4 100644 --- a/src/USER-DPD/fix_rx.cpp +++ b/src/USER-DPD/fix_rx.cpp @@ -11,12 +11,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include "fix_rx.h" +#include #include #include #include #include // DBL_EPSILON -#include "fix_rx.h" #include "atom.h" #include "error.h" #include "group.h" diff --git a/src/USER-DPD/fix_shardlow.cpp b/src/USER-DPD/fix_shardlow.cpp index 4e133480ad..f181436f91 100644 --- a/src/USER-DPD/fix_shardlow.cpp +++ b/src/USER-DPD/fix_shardlow.cpp @@ -33,15 +33,13 @@ 135, 204105. ------------------------------------------------------------------------- */ -#include +#include "fix_shardlow.h" #include #include #include -#include "fix_shardlow.h" #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" #include "atom_vec.h" #include "comm.h" @@ -53,7 +51,6 @@ #include "modify.h" #include "pair_dpd_fdt.h" #include "pair_dpd_fdt_energy.h" -#include "pair.h" #include "npair_half_bin_newton_ssa.h" #include "citeme.h" diff --git a/src/USER-DPD/nbin_ssa.cpp b/src/USER-DPD/nbin_ssa.cpp index dcd434cb4a..e3fa71aedf 100644 --- a/src/USER-DPD/nbin_ssa.cpp +++ b/src/USER-DPD/nbin_ssa.cpp @@ -21,8 +21,6 @@ #include "update.h" #include "group.h" #include "domain.h" -#include "memory.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-DPD/npair_half_bin_newton_ssa.cpp b/src/USER-DPD/npair_half_bin_newton_ssa.cpp index ba90ebc465..2139173d47 100644 --- a/src/USER-DPD/npair_half_bin_newton_ssa.cpp +++ b/src/USER-DPD/npair_half_bin_newton_ssa.cpp @@ -17,7 +17,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_bin_newton_ssa.h" -#include "neighbor.h" #include "nstencil_ssa.h" #include "nbin_ssa.h" #include "neigh_list.h" @@ -25,7 +24,6 @@ #include "atom_vec.h" #include "molecule.h" #include "domain.h" -#include "group.h" #include "memory.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-DPD/nstencil_half_bin_2d_newton_ssa.cpp b/src/USER-DPD/nstencil_half_bin_2d_newton_ssa.cpp index 451381c104..9953fca62c 100644 --- a/src/USER-DPD/nstencil_half_bin_2d_newton_ssa.cpp +++ b/src/USER-DPD/nstencil_half_bin_2d_newton_ssa.cpp @@ -17,8 +17,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_2d_newton_ssa.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/USER-DPD/nstencil_half_bin_3d_newton_ssa.cpp b/src/USER-DPD/nstencil_half_bin_3d_newton_ssa.cpp index cdd3b8856f..4dd3c4a5fe 100644 --- a/src/USER-DPD/nstencil_half_bin_3d_newton_ssa.cpp +++ b/src/USER-DPD/nstencil_half_bin_3d_newton_ssa.cpp @@ -17,8 +17,6 @@ ------------------------------------------------------------------------- */ #include "nstencil_half_bin_3d_newton_ssa.h" -#include "neighbor.h" -#include "neigh_list.h" using namespace LAMMPS_NS; diff --git a/src/USER-DPD/pair_dpd_fdt.cpp b/src/USER-DPD/pair_dpd_fdt.cpp index 07ef8190f0..1cb9d68d06 100644 --- a/src/USER-DPD/pair_dpd_fdt.cpp +++ b/src/USER-DPD/pair_dpd_fdt.cpp @@ -15,23 +15,20 @@ Contributing author: James Larentzos (U.S. Army Research Laboratory) ------------------------------------------------------------------------- */ +#include "pair_dpd_fdt.h" +#include #include -#include -#include #include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "update.h" #include "fix.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "random_mars.h" #include "memory.h" #include "modify.h" -#include "pair_dpd_fdt.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-DPD/pair_table_rx.cpp b/src/USER-DPD/pair_table_rx.cpp index f2d0d7b1fb..e767f93367 100644 --- a/src/USER-DPD/pair_table_rx.cpp +++ b/src/USER-DPD/pair_table_rx.cpp @@ -15,14 +15,12 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_table_rx.h" #include #include -#include #include -#include "pair_table_rx.h" #include "atom.h" #include "force.h" -#include "comm.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/USER-DRUDE/compute_temp_drude.cpp b/src/USER-DRUDE/compute_temp_drude.cpp index 4830e950d0..a12c248680 100644 --- a/src/USER-DRUDE/compute_temp_drude.cpp +++ b/src/USER-DRUDE/compute_temp_drude.cpp @@ -11,19 +11,15 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include #include "compute_temp_drude.h" +#include +#include #include "atom.h" #include "update.h" #include "force.h" -#include "group.h" #include "modify.h" -#include "fix.h" +#include "fix_drude.h" #include "domain.h" -#include "lattice.h" -#include "memory.h" #include "error.h" #include "comm.h" diff --git a/src/USER-DRUDE/compute_temp_drude.h b/src/USER-DRUDE/compute_temp_drude.h index 88d767f8b7..530c84ce3d 100644 --- a/src/USER-DRUDE/compute_temp_drude.h +++ b/src/USER-DRUDE/compute_temp_drude.h @@ -21,7 +21,6 @@ ComputeStyle(temp/drude,ComputeTempDrude) #define LMP_COMPUTE_TEMP_DRUDE_H #include "compute.h" -#include "fix_drude.h" namespace LAMMPS_NS { @@ -37,7 +36,7 @@ class ComputeTempDrude : public Compute { private: int fix_dof; - FixDrude * fix_drude; + class FixDrude * fix_drude; char *id_temp; class Compute *temperature; bigint dof_core, dof_drude; diff --git a/src/USER-DRUDE/fix_drude.cpp b/src/USER-DRUDE/fix_drude.cpp index 7800efe7ff..080408459c 100644 --- a/src/USER-DRUDE/fix_drude.cpp +++ b/src/USER-DRUDE/fix_drude.cpp @@ -11,9 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "fix_drude.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "modify.h" diff --git a/src/USER-DRUDE/fix_drude_transform.cpp b/src/USER-DRUDE/fix_drude_transform.cpp index 34742a0683..8e85f1dffd 100644 --- a/src/USER-DRUDE/fix_drude_transform.cpp +++ b/src/USER-DRUDE/fix_drude_transform.cpp @@ -12,15 +12,15 @@ ------------------------------------------------------------------------- */ /** Fix Drude Transform ******************************************************/ +#include "fix_drude_transform.h" #include #include -#include "fix_drude_transform.h" +#include "fix_drude.h" #include "atom.h" #include "domain.h" #include "comm.h" #include "error.h" #include "modify.h" -#include "force.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-DRUDE/fix_drude_transform.h b/src/USER-DRUDE/fix_drude_transform.h index 41f4e147ed..b74a500c95 100644 --- a/src/USER-DRUDE/fix_drude_transform.h +++ b/src/USER-DRUDE/fix_drude_transform.h @@ -22,7 +22,6 @@ FixStyle(drude/transform/inverse,FixDrudeTransform) #define LMP_FIX_DRUDE_TRANSFORM_H #include "fix.h" -#include "fix_drude.h" namespace LAMMPS_NS { @@ -42,7 +41,7 @@ class FixDrudeTransform : public Fix { void unpack_forward_comm(int n, int first, double *buf); protected: double * mcoeff; - FixDrude * fix_drude; + class FixDrude * fix_drude; }; } diff --git a/src/USER-DRUDE/fix_langevin_drude.cpp b/src/USER-DRUDE/fix_langevin_drude.cpp index b9d1139f83..1a16c3df96 100644 --- a/src/USER-DRUDE/fix_langevin_drude.cpp +++ b/src/USER-DRUDE/fix_langevin_drude.cpp @@ -11,17 +11,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_langevin_drude.h" +#include +#include +#include "fix_drude.h" #include "atom.h" #include "force.h" #include "comm.h" #include "input.h" #include "variable.h" #include "random_mars.h" -#include "group.h" #include "update.h" #include "modify.h" #include "compute.h" diff --git a/src/USER-DRUDE/fix_langevin_drude.h b/src/USER-DRUDE/fix_langevin_drude.h index d65440582c..9437883ba3 100644 --- a/src/USER-DRUDE/fix_langevin_drude.h +++ b/src/USER-DRUDE/fix_langevin_drude.h @@ -21,7 +21,6 @@ FixStyle(langevin/drude,FixLangevinDrude) #define LMP_FIX_LANGEVIN_DRUDE_H #include "fix.h" -#include "fix_drude.h" namespace LAMMPS_NS { @@ -51,7 +50,7 @@ class FixLangevinDrude : public Fix { class RanMars *random_core, *random_drude; int zero; bigint ncore; - FixDrude * fix_drude; + class FixDrude * fix_drude; class Compute *temperature; char *id_temp; }; diff --git a/src/USER-DRUDE/pair_lj_cut_thole_long.cpp b/src/USER-DRUDE/pair_lj_cut_thole_long.cpp index 1ebe4a4c2d..851effd89c 100644 --- a/src/USER-DRUDE/pair_lj_cut_thole_long.cpp +++ b/src/USER-DRUDE/pair_lj_cut_thole_long.cpp @@ -15,20 +15,17 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_cut_thole_long.h" +#include +#include +#include +#include "fix_drude.h" #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" -#include "update.h" -#include "integrate.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/USER-DRUDE/pair_lj_cut_thole_long.h b/src/USER-DRUDE/pair_lj_cut_thole_long.h index 27a917c737..4c3a883064 100644 --- a/src/USER-DRUDE/pair_lj_cut_thole_long.h +++ b/src/USER-DRUDE/pair_lj_cut_thole_long.h @@ -21,7 +21,6 @@ PairStyle(lj/cut/thole/long,PairLJCutTholeLong) #define LMP_PAIR_LJ_CUT_THOLE_LONG_H #include "pair.h" -#include "fix_drude.h" namespace LAMMPS_NS { @@ -58,7 +57,7 @@ class PairLJCutTholeLong : public Pair { double cut_global; double **cut,**scale; double **polar,**thole,**ascreen; - FixDrude *fix_drude; + class FixDrude *fix_drude; virtual void allocate(); }; diff --git a/src/USER-DRUDE/pair_thole.cpp b/src/USER-DRUDE/pair_thole.cpp index 1bb75af825..1f81263e95 100644 --- a/src/USER-DRUDE/pair_thole.cpp +++ b/src/USER-DRUDE/pair_thole.cpp @@ -11,11 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_thole.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" @@ -24,7 +23,7 @@ #include "memory.h" #include "error.h" #include "fix.h" -#include "fix_store.h" +#include "fix_drude.h" #include "domain.h" #include "modify.h" diff --git a/src/USER-DRUDE/pair_thole.h b/src/USER-DRUDE/pair_thole.h index 2c462b431a..88c00b6d20 100644 --- a/src/USER-DRUDE/pair_thole.h +++ b/src/USER-DRUDE/pair_thole.h @@ -21,7 +21,6 @@ PairStyle(thole,PairThole) #define LMP_PAIR_THOLE_H #include "pair.h" -#include "fix_drude.h" namespace LAMMPS_NS { @@ -46,7 +45,7 @@ class PairThole : public Pair { double cut_global; double **cut,**scale; double **polar,**thole,**ascreen; - FixDrude * fix_drude; + class FixDrude * fix_drude; virtual void allocate(); }; diff --git a/src/USER-EFF/compute_temp_eff.cpp b/src/USER-EFF/compute_temp_eff.cpp index d745269ff5..8e07e390fa 100644 --- a/src/USER-EFF/compute_temp_eff.cpp +++ b/src/USER-EFF/compute_temp_eff.cpp @@ -15,9 +15,8 @@ Contributing author: Andres Jaramillo-Botero (Caltech) ------------------------------------------------------------------------- */ -#include -#include #include "compute_temp_eff.h" +#include #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/USER-FEP/compute_fep.cpp b/src/USER-FEP/compute_fep.cpp index dc0b71e71b..1853828db3 100644 --- a/src/USER-FEP/compute_fep.cpp +++ b/src/USER-FEP/compute_fep.cpp @@ -15,7 +15,7 @@ Contributing author: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include +#include "compute_fep.h" #include #include #include @@ -34,7 +34,6 @@ #include "timer.h" #include "memory.h" #include "error.h" -#include "compute_fep.h" using namespace LAMMPS_NS; diff --git a/src/USER-FEP/fix_adapt_fep.cpp b/src/USER-FEP/fix_adapt_fep.cpp index 7304bc4ef6..46cf32cf0b 100644 --- a/src/USER-FEP/fix_adapt_fep.cpp +++ b/src/USER-FEP/fix_adapt_fep.cpp @@ -15,10 +15,8 @@ Charges by type and after option: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_adapt_fep.h" +#include #include "atom.h" #include "update.h" #include "group.h" diff --git a/src/USER-FEP/pair_coul_cut_soft.cpp b/src/USER-FEP/pair_coul_cut_soft.cpp index 86a6d02819..a4ff3ca846 100644 --- a/src/USER-FEP/pair_coul_cut_soft.cpp +++ b/src/USER-FEP/pair_coul_cut_soft.cpp @@ -15,11 +15,10 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_coul_cut_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-FEP/pair_coul_long_soft.cpp b/src/USER-FEP/pair_coul_long_soft.cpp index 9d3ffc0da1..c0030f8935 100644 --- a/src/USER-FEP/pair_coul_long_soft.cpp +++ b/src/USER-FEP/pair_coul_long_soft.cpp @@ -16,19 +16,16 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_coul_long_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "neighbor.h" #include "neigh_list.h" -#include "update.h" -#include "integrate.h" #include "memory.h" #include "error.h" diff --git a/src/USER-FEP/pair_lj_charmm_coul_long_soft.cpp b/src/USER-FEP/pair_lj_charmm_coul_long_soft.cpp index ac6f1e6384..4c3be6addb 100644 --- a/src/USER-FEP/pair_lj_charmm_coul_long_soft.cpp +++ b/src/USER-FEP/pair_lj_charmm_coul_long_soft.cpp @@ -16,17 +16,15 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_charmm_coul_long_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-FEP/pair_lj_class2_coul_cut_soft.cpp b/src/USER-FEP/pair_lj_class2_coul_cut_soft.cpp index ae79515488..bbe67e4ff3 100644 --- a/src/USER-FEP/pair_lj_class2_coul_cut_soft.cpp +++ b/src/USER-FEP/pair_lj_class2_coul_cut_soft.cpp @@ -11,11 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_class2_coul_cut_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-FEP/pair_lj_class2_coul_long_soft.cpp b/src/USER-FEP/pair_lj_class2_coul_long_soft.cpp index 275486d1e2..a3e0f732a2 100644 --- a/src/USER-FEP/pair_lj_class2_coul_long_soft.cpp +++ b/src/USER-FEP/pair_lj_class2_coul_long_soft.cpp @@ -11,11 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_class2_coul_long_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-FEP/pair_lj_class2_soft.cpp b/src/USER-FEP/pair_lj_class2_soft.cpp index d22cd53883..d98a5db5f3 100644 --- a/src/USER-FEP/pair_lj_class2_soft.cpp +++ b/src/USER-FEP/pair_lj_class2_soft.cpp @@ -11,11 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_class2_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-FEP/pair_lj_cut_coul_cut_soft.cpp b/src/USER-FEP/pair_lj_cut_coul_cut_soft.cpp index 35c9162dbc..38fcb6fc07 100644 --- a/src/USER-FEP/pair_lj_cut_coul_cut_soft.cpp +++ b/src/USER-FEP/pair_lj_cut_coul_cut_soft.cpp @@ -15,11 +15,10 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_cut_coul_cut_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-FEP/pair_lj_cut_coul_long_soft.cpp b/src/USER-FEP/pair_lj_cut_coul_long_soft.cpp index 79253d2b9c..740daabf62 100644 --- a/src/USER-FEP/pair_lj_cut_coul_long_soft.cpp +++ b/src/USER-FEP/pair_lj_cut_coul_long_soft.cpp @@ -16,17 +16,15 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_cut_coul_long_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-FEP/pair_lj_cut_soft.cpp b/src/USER-FEP/pair_lj_cut_soft.cpp index 4192d6546b..5e9a77877e 100644 --- a/src/USER-FEP/pair_lj_cut_soft.cpp +++ b/src/USER-FEP/pair_lj_cut_soft.cpp @@ -16,11 +16,10 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_cut_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" @@ -28,7 +27,6 @@ #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory.h" diff --git a/src/USER-FEP/pair_lj_cut_tip4p_long_soft.cpp b/src/USER-FEP/pair_lj_cut_tip4p_long_soft.cpp index 8ac28f9fa9..d4f6dcb910 100644 --- a/src/USER-FEP/pair_lj_cut_tip4p_long_soft.cpp +++ b/src/USER-FEP/pair_lj_cut_tip4p_long_soft.cpp @@ -17,23 +17,18 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_cut_tip4p_long_soft.h" +#include +#include +#include #include "angle.h" #include "atom.h" #include "bond.h" #include "comm.h" #include "domain.h" #include "force.h" -#include "kspace.h" -#include "update.h" -#include "respa.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" diff --git a/src/USER-FEP/pair_morse_soft.cpp b/src/USER-FEP/pair_morse_soft.cpp index 21f616a082..2803e7df49 100644 --- a/src/USER-FEP/pair_morse_soft.cpp +++ b/src/USER-FEP/pair_morse_soft.cpp @@ -11,11 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_morse_soft.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-FEP/pair_tip4p_long_soft.cpp b/src/USER-FEP/pair_tip4p_long_soft.cpp index 9b6a6841fe..9cea5b54c5 100644 --- a/src/USER-FEP/pair_tip4p_long_soft.cpp +++ b/src/USER-FEP/pair_tip4p_long_soft.cpp @@ -17,23 +17,18 @@ Soft-core version: Agilio Padua (Univ Blaise Pascal & CNRS) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_tip4p_long_soft.h" +#include +#include +#include #include "angle.h" #include "atom.h" #include "bond.h" #include "comm.h" #include "domain.h" #include "force.h" -#include "kspace.h" -#include "update.h" -#include "respa.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MESO/fix_mvv_dpd.cpp b/src/USER-MESO/fix_mvv_dpd.cpp index f663165f78..116bbf506a 100644 --- a/src/USER-MESO/fix_mvv_dpd.cpp +++ b/src/USER-MESO/fix_mvv_dpd.cpp @@ -20,13 +20,11 @@ Email: zhen_li@brown.edu ------------------------------------------------------------------------- */ -#include -#include #include "fix_mvv_dpd.h" +#include #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-MESO/fix_tdpd_source.cpp b/src/USER-MESO/fix_tdpd_source.cpp index 89e8005b43..990f6a5b78 100644 --- a/src/USER-MESO/fix_tdpd_source.cpp +++ b/src/USER-MESO/fix_tdpd_source.cpp @@ -11,17 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "fix_tdpd_source.h" +#include +#include #include "atom.h" -#include "comm.h" -#include "update.h" -#include "modify.h" -#include "domain.h" -#include "lattice.h" -#include "input.h" -#include "variable.h" #include "error.h" #include "force.h" diff --git a/src/USER-MESO/pair_edpd.cpp b/src/USER-MESO/pair_edpd.cpp index e428b02822..f72b6d6b93 100644 --- a/src/USER-MESO/pair_edpd.cpp +++ b/src/USER-MESO/pair_edpd.cpp @@ -16,14 +16,12 @@ Email: zhen_li@brown.edu ------------------------------------------------------------------------- */ +#include "pair_edpd.h" +#include #include -#include -#include #include #include -#include "pair_edpd.h" #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "update.h" #include "force.h" diff --git a/src/USER-MESO/pair_mdpd.cpp b/src/USER-MESO/pair_mdpd.cpp index 4102499d46..56adad26ce 100644 --- a/src/USER-MESO/pair_mdpd.cpp +++ b/src/USER-MESO/pair_mdpd.cpp @@ -16,13 +16,11 @@ Email: zhen_li@brown.edu ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_mdpd.h" +#include +#include +#include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "update.h" #include "force.h" diff --git a/src/USER-MESO/pair_mdpd_rhosum.cpp b/src/USER-MESO/pair_mdpd_rhosum.cpp index 2fd238088c..05cb123f61 100644 --- a/src/USER-MESO/pair_mdpd_rhosum.cpp +++ b/src/USER-MESO/pair_mdpd_rhosum.cpp @@ -19,9 +19,8 @@ Contributing author: Zhen Li (Brown University) ------------------------------------------------------------------------- */ -#include -#include #include "pair_mdpd_rhosum.h" +#include #include "atom.h" #include "force.h" #include "comm.h" @@ -30,8 +29,6 @@ #include "memory.h" #include "error.h" #include "neighbor.h" -#include "update.h" -#include "domain.h" using namespace LAMMPS_NS; diff --git a/src/USER-MESO/pair_tdpd.cpp b/src/USER-MESO/pair_tdpd.cpp index 7df9d6d163..346401b1ba 100644 --- a/src/USER-MESO/pair_tdpd.cpp +++ b/src/USER-MESO/pair_tdpd.cpp @@ -16,13 +16,10 @@ Email: zhen_li@brown.edu ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_tdpd.h" +#include +#include #include "atom.h" -#include "atom_vec.h" #include "comm.h" #include "update.h" #include "force.h" From 872d43f02f8e9cc274344baba158366106c338c0 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 10 Jul 2019 07:29:29 -0400 Subject: [PATCH 61/79] recover compilation of USER-OMP package --- src/USER-OMP/pair_lj_cut_thole_long_omp.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp b/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp index 85cab4fe7b..d0db6262b1 100644 --- a/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp +++ b/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp @@ -15,13 +15,14 @@ Contributing author: Paul Crozier (SNL) ------------------------------------------------------------------------- */ +#include "pair_lj_cut_thole_long_omp.h" #include #include #include #include -#include "pair_lj_cut_thole_long_omp.h" #include "atom.h" #include "comm.h" +#include "fix_drude.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" From c5044d648463ae307bcbd1aa90565077489442df Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 10 Jul 2019 08:49:16 -0400 Subject: [PATCH 62/79] continuing include file handling cleanup --- src/USER-MANIFOLD/fix_manifoldforce.cpp | 5 +- src/USER-MANIFOLD/fix_manifoldforce.h | 2 +- src/USER-MANIFOLD/fix_nve_manifold_rattle.cpp | 10 +- src/USER-MANIFOLD/fix_nve_manifold_rattle.h | 6 +- src/USER-MANIFOLD/fix_nvt_manifold_rattle.cpp | 9 +- src/USER-MANIFOLD/manifold_factory.h | 11 +- src/USER-MANIFOLD/manifold_thylakoid.cpp | 2 +- src/USER-MANIFOLD/manifold_thylakoid.h | 4 +- src/USER-MEAMC/meam.h | 2 +- src/USER-MEAMC/meam_dens_final.cpp | 1 - src/USER-MEAMC/meam_dens_init.cpp | 2 + src/USER-MEAMC/meam_force.cpp | 3 +- src/USER-MEAMC/meam_impl.cpp | 1 + src/USER-MEAMC/meam_setup_done.cpp | 6 +- src/USER-MEAMC/pair_meamc.cpp | 6 +- src/USER-MEAMC/pair_meamc.h | 1 - src/USER-MGPT/mgpt_linalg.cpp | 2 - src/USER-MGPT/mgpt_readpot.h | 4 +- src/USER-MGPT/pair_mgpt.cpp | 5 +- src/USER-MGPT/pair_mgpt.h | 375 +++++++++--------- src/USER-MISC/angle_cosine_shift.cpp | 4 +- src/USER-MISC/angle_cosine_shift_exp.cpp | 4 +- src/USER-MISC/angle_dipole.cpp | 4 +- src/USER-MISC/angle_fourier.cpp | 4 +- src/USER-MISC/angle_fourier_simple.cpp | 4 +- src/USER-MISC/angle_quartic.cpp | 4 +- src/USER-MISC/bond_harmonic_shift.cpp | 5 +- src/USER-MISC/bond_harmonic_shift_cut.cpp | 5 +- src/USER-MISC/compute_cnp_atom.cpp | 7 +- src/USER-MISC/compute_entropy_atom.cpp | 5 +- src/USER-MISC/compute_pressure_cylinder.cpp | 6 +- src/USER-MISC/compute_pressure_grem.cpp | 6 +- src/USER-MISC/compute_stress_mop.cpp | 6 +- src/USER-MISC/compute_stress_mop_profile.cpp | 6 +- src/USER-MISC/compute_temp_rotate.cpp | 5 +- src/USER-MISC/dihedral_cosine_shift_exp.cpp | 4 +- src/USER-MISC/dihedral_fourier.cpp | 5 +- src/USER-MISC/dihedral_nharmonic.cpp | 5 +- src/USER-MISC/dihedral_quadratic.cpp | 5 +- src/USER-MISC/dihedral_spherical.cpp | 5 +- src/USER-MISC/dihedral_table.cpp | 9 +- src/USER-MISC/dihedral_table_cut.cpp | 14 +- src/USER-MISC/fix_addtorque.cpp | 5 +- src/USER-MISC/fix_ave_correlate_long.cpp | 3 +- src/USER-MISC/fix_bond_react.cpp | 3 +- src/USER-MISC/fix_electron_stopping.cpp | 6 +- src/USER-MISC/fix_ffl.cpp | 14 +- src/USER-MISC/fix_filter_corotate.cpp | 17 +- src/USER-MISC/fix_flow_gauss.cpp | 5 +- src/USER-MISC/fix_gle.cpp | 11 +- src/USER-MISC/fix_grem.cpp | 7 +- src/USER-MISC/fix_ipi.cpp | 9 +- src/USER-MISC/fix_nvk.cpp | 8 +- src/USER-MISC/fix_pimd.cpp | 3 +- src/USER-MISC/fix_rhok.cpp | 5 +- src/USER-MISC/fix_smd.cpp | 6 +- src/USER-MISC/fix_srp.cpp | 9 +- src/USER-MISC/fix_ti_spring.cpp | 4 +- src/USER-MISC/fix_ttm_mod.cpp | 5 +- src/USER-MISC/fix_wall_ees.cpp | 10 +- src/USER-MISC/fix_wall_region_ees.cpp | 9 +- 61 files changed, 305 insertions(+), 413 deletions(-) diff --git a/src/USER-MANIFOLD/fix_manifoldforce.cpp b/src/USER-MANIFOLD/fix_manifoldforce.cpp index 00293bfec7..74a9a1833f 100644 --- a/src/USER-MANIFOLD/fix_manifoldforce.cpp +++ b/src/USER-MANIFOLD/fix_manifoldforce.cpp @@ -11,9 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include "fix_manifoldforce.h" // For stuff +#include #include -#include #include "atom.h" #include "update.h" #include "respa.h" @@ -21,7 +21,6 @@ #include "force.h" #include "manifold.h" -#include "fix_manifoldforce.h" // For stuff #include "manifold_factory.h" // For constructing manifold diff --git a/src/USER-MANIFOLD/fix_manifoldforce.h b/src/USER-MANIFOLD/fix_manifoldforce.h index 527bee3f86..1d5afc7afc 100644 --- a/src/USER-MANIFOLD/fix_manifoldforce.h +++ b/src/USER-MANIFOLD/fix_manifoldforce.h @@ -43,9 +43,9 @@ FixStyle(manifoldforce,FixManifoldForce) #define LMP_FIX_MANIFOLDFORCE_H #include "fix.h" -#include "manifold.h" namespace LAMMPS_NS { +namespace user_manifold { class manifold; } class FixManifoldForce : public Fix { public: diff --git a/src/USER-MANIFOLD/fix_nve_manifold_rattle.cpp b/src/USER-MANIFOLD/fix_nve_manifold_rattle.cpp index de134e32ed..7f8d9d5675 100644 --- a/src/USER-MANIFOLD/fix_nve_manifold_rattle.cpp +++ b/src/USER-MANIFOLD/fix_nve_manifold_rattle.cpp @@ -32,24 +32,18 @@ ------------------------------------------------------------------------- */ -#include -#include +#include "fix_nve_manifold_rattle.h" +#include #include #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" -#include "group.h" -#include #include "input.h" #include "variable.h" #include "citeme.h" -#include "memory.h" #include "comm.h" - -#include "fix_nve_manifold_rattle.h" #include "manifold_factory.h" #include "manifold.h" diff --git a/src/USER-MANIFOLD/fix_nve_manifold_rattle.h b/src/USER-MANIFOLD/fix_nve_manifold_rattle.h index 2bc821ab04..581ecf36d3 100644 --- a/src/USER-MANIFOLD/fix_nve_manifold_rattle.h +++ b/src/USER-MANIFOLD/fix_nve_manifold_rattle.h @@ -42,12 +42,10 @@ FixStyle(nve/manifold/rattle,FixNVEManifoldRattle) #define LMP_FIX_NVE_MANIFOLD_RATTLE_H #include "fix.h" -#include "manifold.h" - namespace LAMMPS_NS { -// namespace user_manifold { +namespace user_manifold { class manifold; } class FixNVEManifoldRattle : public Fix { public: @@ -98,9 +96,7 @@ namespace LAMMPS_NS { user_manifold::manifold *ptr_m; - void print_stats( const char * ); - int was_var( const char * ); virtual void update_var_params(); diff --git a/src/USER-MANIFOLD/fix_nvt_manifold_rattle.cpp b/src/USER-MANIFOLD/fix_nvt_manifold_rattle.cpp index a4eed66336..2789f8738a 100644 --- a/src/USER-MANIFOLD/fix_nvt_manifold_rattle.cpp +++ b/src/USER-MANIFOLD/fix_nvt_manifold_rattle.cpp @@ -32,25 +32,18 @@ ------------------------------------------------------------------------- */ -#include -#include +#include "fix_nvt_manifold_rattle.h" #include #include #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" #include "group.h" -#include "input.h" -#include "variable.h" #include "citeme.h" -#include "memory.h" -#include "comm.h" #include "modify.h" #include "compute.h" -#include "fix_nvt_manifold_rattle.h" #include "manifold.h" diff --git a/src/USER-MANIFOLD/manifold_factory.h b/src/USER-MANIFOLD/manifold_factory.h index cc3e1245bf..ac2aee8a26 100644 --- a/src/USER-MANIFOLD/manifold_factory.h +++ b/src/USER-MANIFOLD/manifold_factory.h @@ -35,8 +35,7 @@ #ifndef LMP_MANIFOLD_FACTORY_H #define LMP_MANIFOLD_FACTORY_H - -#include "manifold.h" +#include #include /* @@ -79,14 +78,16 @@ static FILE *screen = fopen("/dev/stdout","w"); #define FLERR __FILE__,__LINE__ // Equivalent to definition in pointers.h #endif // USE_PHONY_LAMMPS - - /* Here the actual implementation of LAMMPS-related functions begins. */ namespace LAMMPS_NS { +class LAMMPS; namespace user_manifold { +// forward declaration +class manifold; + // Templated, so needs to be in header. template void make_manifold_if( manifold **man_ptr, const char *name, @@ -103,8 +104,6 @@ namespace user_manifold { int , char ** ); } // namespace user_manifold - } // namespace LAMMPS_NS - #endif // LMP_MANIFOLD_FACTORY_H diff --git a/src/USER-MANIFOLD/manifold_thylakoid.cpp b/src/USER-MANIFOLD/manifold_thylakoid.cpp index 530e0a876d..e4ef039832 100644 --- a/src/USER-MANIFOLD/manifold_thylakoid.cpp +++ b/src/USER-MANIFOLD/manifold_thylakoid.cpp @@ -1,6 +1,6 @@ #include "manifold_thylakoid.h" #include - +#include "manifold_thylakoid_shared.h" #include "comm.h" #include "domain.h" // For some checks regarding the simulation box. #include "error.h" diff --git a/src/USER-MANIFOLD/manifold_thylakoid.h b/src/USER-MANIFOLD/manifold_thylakoid.h index d8ebe2e94f..35ad4dfd9c 100644 --- a/src/USER-MANIFOLD/manifold_thylakoid.h +++ b/src/USER-MANIFOLD/manifold_thylakoid.h @@ -4,12 +4,10 @@ #include "manifold.h" #include -#include "manifold_thylakoid_shared.h" - namespace LAMMPS_NS { namespace user_manifold { - + struct thyla_part; class manifold_thylakoid : public manifold { public: diff --git a/src/USER-MEAMC/meam.h b/src/USER-MEAMC/meam.h index 74b1eb0e54..da55805790 100644 --- a/src/USER-MEAMC/meam.h +++ b/src/USER-MEAMC/meam.h @@ -1,12 +1,12 @@ #ifndef LMP_MEAM_H #define LMP_MEAM_H -#include "memory.h" #include #define maxelt 5 namespace LAMMPS_NS { +class Memory; typedef enum { FCC, BCC, HCP, DIM, DIA, B1, C11, L12, B2 } lattice_t; diff --git a/src/USER-MEAMC/meam_dens_final.cpp b/src/USER-MEAMC/meam_dens_final.cpp index c55b1b45c4..867106df88 100644 --- a/src/USER-MEAMC/meam_dens_final.cpp +++ b/src/USER-MEAMC/meam_dens_final.cpp @@ -1,5 +1,4 @@ #include "meam.h" -#include "math_special.h" using namespace LAMMPS_NS; diff --git a/src/USER-MEAMC/meam_dens_init.cpp b/src/USER-MEAMC/meam_dens_init.cpp index 3bb9328142..155941422c 100644 --- a/src/USER-MEAMC/meam_dens_init.cpp +++ b/src/USER-MEAMC/meam_dens_init.cpp @@ -1,4 +1,6 @@ #include "meam.h" +#include +#include "memory.h" #include "math_special.h" using namespace LAMMPS_NS; diff --git a/src/USER-MEAMC/meam_force.cpp b/src/USER-MEAMC/meam_force.cpp index 06fbb57adb..09aad90111 100644 --- a/src/USER-MEAMC/meam_force.cpp +++ b/src/USER-MEAMC/meam_force.cpp @@ -1,6 +1,7 @@ #include "meam.h" -#include "math_special.h" +#include #include +#include "math_special.h" using namespace LAMMPS_NS; diff --git a/src/USER-MEAMC/meam_impl.cpp b/src/USER-MEAMC/meam_impl.cpp index b099ead8d5..3b40a2b612 100644 --- a/src/USER-MEAMC/meam_impl.cpp +++ b/src/USER-MEAMC/meam_impl.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "meam.h" +#include #include "memory.h" using namespace LAMMPS_NS; diff --git a/src/USER-MEAMC/meam_setup_done.cpp b/src/USER-MEAMC/meam_setup_done.cpp index 2a762d1204..7000eac6ae 100644 --- a/src/USER-MEAMC/meam_setup_done.cpp +++ b/src/USER-MEAMC/meam_setup_done.cpp @@ -1,6 +1,10 @@ #include "meam.h" -#include "math_special.h" +#include +#include #include +#include "math_special.h" +#include "memory.h" + using namespace LAMMPS_NS; void diff --git a/src/USER-MEAMC/pair_meamc.cpp b/src/USER-MEAMC/pair_meamc.cpp index 7c96fadb44..a9034a1af3 100644 --- a/src/USER-MEAMC/pair_meamc.cpp +++ b/src/USER-MEAMC/pair_meamc.cpp @@ -15,16 +15,14 @@ Contributing author: Greg Wagner (SNL) ------------------------------------------------------------------------- */ -#include -#include +#include "pair_meamc.h" +#include #include #include #include "meam.h" -#include "pair_meamc.h" #include "atom.h" #include "force.h" #include "comm.h" -#include "memory.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/USER-MEAMC/pair_meamc.h b/src/USER-MEAMC/pair_meamc.h index a006e70bdb..31dd8ba022 100644 --- a/src/USER-MEAMC/pair_meamc.h +++ b/src/USER-MEAMC/pair_meamc.h @@ -24,7 +24,6 @@ PairStyle(meam,PairMEAMC) #include "pair.h" namespace LAMMPS_NS { -class MEAM; class PairMEAMC : public Pair { public: diff --git a/src/USER-MGPT/mgpt_linalg.cpp b/src/USER-MGPT/mgpt_linalg.cpp index 68701037f4..bc15873739 100644 --- a/src/USER-MGPT/mgpt_linalg.cpp +++ b/src/USER-MGPT/mgpt_linalg.cpp @@ -20,8 +20,6 @@ #include #include -#include -#include #define restrict __restrict__ diff --git a/src/USER-MGPT/mgpt_readpot.h b/src/USER-MGPT/mgpt_readpot.h index 62f66883b6..8f46592e8a 100644 --- a/src/USER-MGPT/mgpt_readpot.h +++ b/src/USER-MGPT/mgpt_readpot.h @@ -19,7 +19,9 @@ #ifndef READPOT__ #define READPOT__ - +#include +#include +#include #include "mgpt_splinetab.h" struct potdata { diff --git a/src/USER-MGPT/pair_mgpt.cpp b/src/USER-MGPT/pair_mgpt.cpp index 91c624eec5..0634872c70 100644 --- a/src/USER-MGPT/pair_mgpt.cpp +++ b/src/USER-MGPT/pair_mgpt.cpp @@ -21,17 +21,16 @@ (2011). See LLNL copyright notice at bottom of this file. ------------------------------------------------------------------------- */ +#include "pair_mgpt.h" +#include #include -#include #include #include #include -#include "pair_mgpt.h" #include "atom.h" #include "force.h" #include "comm.h" -#include "memory.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/USER-MGPT/pair_mgpt.h b/src/USER-MGPT/pair_mgpt.h index 70b36364b1..3e861a0198 100644 --- a/src/USER-MGPT/pair_mgpt.h +++ b/src/USER-MGPT/pair_mgpt.h @@ -32,6 +32,7 @@ PairStyle(mgpt,PairMGPT) #include #include +#include #include #include "pair.h" @@ -77,29 +78,29 @@ public: Link(const K &k,Link *n) : next(n),key(k),hits(1) {} static void *operator new(std::size_t sz) { - const size_t align = 32; - size_t x = (size_t) (void *) ::operator new(sz+align); - size_t y = (x + align) - ((x+align)&(align-1)); - assert(sizeof(void *) <= align); - assert((x & (sizeof(void *)-1)) == 0); - ((void **) y)[-1] = (void *) x; - return (void *) y; + const size_t align = 32; + size_t x = (size_t) (void *) ::operator new(sz+align); + size_t y = (x + align) - ((x+align)&(align-1)); + assert(sizeof(void *) <= align); + assert((x & (sizeof(void *)-1)) == 0); + ((void **) y)[-1] = (void *) x; + return (void *) y; } static void operator delete(void *ptr) { - ::operator delete(((void **) ptr)[-1]); + ::operator delete(((void **) ptr)[-1]); } }; int isprime(int x) { if(x%2 == 0) - return 0; + return 0; else { - int k = 3; - while(k*k <= x) { - if(x%k == 0) return 0; - k = k+2; - } - return 1; + int k = 3; + while(k*k <= x) { + if(x%k == 0) return 0; + k = k+2; + } + return 1; } } @@ -117,25 +118,25 @@ public: Iterator(Hash &HH) : H(HH),idx(-1),p(0) { next(); } Iterator(Hash &HH,int iidx,Link *pp) : H(HH),idx(iidx),p(pp) {} void next() { - if(idx >= H.Size()) return; - if(p != 0) p = p->next; - if(p == 0) { - do { - idx = idx+1; - if(idx >= H.Size()) return; - p = H.table[idx]; - } while(p == 0); - } + if(idx >= H.Size()) return; + if(p != 0) p = p->next; + if(p == 0) { + do { + idx = idx+1; + if(idx >= H.Size()) return; + p = H.table[idx]; + } while(p == 0); + } } K *key() { return &p->key; } T *data() { return &p->data; } Link *link() { return p; } int operator==(const Iterator &a) { - return idx==a.idx && p==a.p; + return idx==a.idx && p==a.p; } int operator!=(const Iterator &a) { - return !(*this == a); + return !(*this == a); } }; @@ -147,7 +148,7 @@ public: table = new Link *[size]; for(int i = 0; inext; - delete p; - p = q; - } + Link *p = table[i]; + while(p != 0) { + Link *q = p->next; + delete p; + p = q; + } } delete[] table; } @@ -179,24 +180,24 @@ public: int idx = key.hash() % size; if(idx < 0) idx = idx + size; if(idx >= size || idx < 0) { - printf("(1) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size); - exit(1); + printf("(1) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size); + exit(1); } used = used + 1; if(1) { - table[idx] = new Link(key,table[idx]); - return &table[idx]->data; + table[idx] = new Link(key,table[idx]); + return &table[idx]->data; } else { /* This is for threading... and incomplete */ - typedef Link *LinkPtr; - LinkPtr ptr = table[idx],last = 0,dataptr = new Link(key,0); + typedef Link *LinkPtr; + LinkPtr ptr = table[idx],last = 0,dataptr = new Link(key,0); - while(ptr != 0) { - last = ptr; - ptr = ptr->next; - } - *((volatile LinkPtr *) &(last->next)) = dataptr; - return &(dataptr->data); + while(ptr != 0) { + last = ptr; + ptr = ptr->next; + } + *((volatile LinkPtr *) &(last->next)) = dataptr; + return &(dataptr->data); } } void Remove(const K &key) { @@ -205,28 +206,28 @@ public: int count = 1; if(idx < 0) idx = idx + size; if(idx >= size || idx < 0) { - printf("(2) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size); - exit(1); + printf("(2) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size); + exit(1); } p = table[idx]; while(p != 0 && !(p->key == key)) { - last = p; - p = p->next; - count = count + 1; + last = p; + p = p->next; + count = count + 1; } if(p != 0) { - used = used - 1; - if(last == 0) - table[idx] = p->next; - else - last->next = p->next; - delete p; + used = used - 1; + if(last == 0) + table[idx] = p->next; + else + last->next = p->next; + delete p; } if(count > maxlength) - maxlength = count; + maxlength = count; nsearch = nsearch + 1; nstep = nstep + count; } @@ -236,19 +237,19 @@ public: int count = 1; if(idx < 0) idx = idx + size; if(idx >= size || idx < 0) { - printf("(3) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size); - exit(1); + printf("(3) Damn... key = %d, idx = %d, size = %d\n",key.hash(),idx,size); + exit(1); } p = table[idx]; while(p != 0 && !(p->key == key)) { - p = p->next; - count = count + 1; + p = p->next; + count = count + 1; } if(count > maxlength) - maxlength = count; + maxlength = count; nsearch = nsearch + 1; nstep = nstep + count; @@ -283,46 +284,46 @@ public: } void zero() { for(int i = 0; i<8; i++) - for(int j = 0; j<8; j++) - m[i][j] = 0.0; + for(int j = 0; j<8; j++) + m[i][j] = 0.0; } void operator=(const Matrix &A) { for(int i = 1; i<=sz; i++) - for(int j = 1; j<=sz; j++) - m[i][j] = A.m[i][j]; + for(int j = 1; j<=sz; j++) + m[i][j] = A.m[i][j]; } void operator=(double x) { for(int i = 1; i<=sz; i++) - for(int j = 1; j<=sz; j++) - m[i][j] = x; + for(int j = 1; j<=sz; j++) + m[i][j] = x; } Matrix operator+(const Matrix &B) const { Matrix s; for(int i = 1; i<=sz; i++) - for(int j = 1; j<=sz; j++) - s.m[i][j] = m[i][j] + B.m[i][j]; + for(int j = 1; j<=sz; j++) + s.m[i][j] = m[i][j] + B.m[i][j]; return s; } Matrix operator-(const Matrix &B) const { Matrix s; for(int i = 1; i<=sz; i++) - for(int j = 1; j<=sz; j++) - s.m[i][j] = m[i][j] - B.m[i][j]; + for(int j = 1; j<=sz; j++) + s.m[i][j] = m[i][j] - B.m[i][j]; return s; } Matrix operator-() const { Matrix s; for(int i = 1; i<=sz; i++) - for(int j = 1; j<=sz; j++) - s.m[i][j] = -m[i][j]; + for(int j = 1; j<=sz; j++) + s.m[i][j] = -m[i][j]; return s; } Matrix operator*(double x) const { Matrix P; for(int i = 1; i<=sz; i++) - for(int j = 0; j<=sz; j++) - P.m[i][j] = m[i][j] * x; + for(int j = 0; j<=sz; j++) + P.m[i][j] = m[i][j] * x; return P; } Matrix operator/(double x) const { @@ -331,8 +332,8 @@ public: Matrix transpose() const { Matrix T; for(int i = 1; i<=sz; i++) - for(int j = 1; j<=sz; j++) - T.m[j][i] = m[i][j]; + for(int j = 1; j<=sz; j++) + T.m[j][i] = m[i][j]; return T; } }; @@ -374,13 +375,13 @@ public: int align_check() { return - (H1H2.align_check() << 0) | - (H1xH2.align_check() << 1) | - (H1yH2.align_check() << 2) | - (H1zH2.align_check() << 3) | - (H1H2x.align_check() << 4) | - (H1H2y.align_check() << 5) | - (H1H2z.align_check() << 6) ; + (H1H2.align_check() << 0) | + (H1xH2.align_check() << 1) | + (H1yH2.align_check() << 2) | + (H1zH2.align_check() << 3) | + (H1H2x.align_check() << 4) | + (H1H2y.align_check() << 5) | + (H1H2z.align_check() << 6) ; } void zero() { @@ -396,18 +397,18 @@ public: void make_bond(const double xx[][3],int i,int j,bond_data *bptr); void make_triplet(bond_data *ij_bond,bond_data *ik_bond,triplet_data *triptr); triplet_data *get_triplet(const double xx[][3],int i,int j,int k, - Hash *bhash,triplet_data *twork, - double *dvir_ij_p,double *dvir_ik_p); + Hash *bhash,triplet_data *twork, + double *dvir_ij_p,double *dvir_ik_p); int c1_outside(const double a[3], - int triclinic,const double alpha[3]) { + int triclinic,const double alpha[3]) { const double stol = 1e-5; if(triclinic) { for(int p = 0; p<3; p++) { - double cog = a[p]; - if(cog < domain->sublo_lamda[p]-0.5*rmax*alpha[p]-stol) return 1; - if(cog > domain->subhi_lamda[p]+0.5*rmax*alpha[p]+stol) return 1; + double cog = a[p]; + if(cog < domain->sublo_lamda[p]-0.5*rmax*alpha[p]-stol) return 1; + if(cog > domain->subhi_lamda[p]+0.5*rmax*alpha[p]+stol) return 1; } } else { @@ -415,63 +416,63 @@ public: for(int p = 0; p<3; p++) { - double cog = a[p]; - if(cog < domain->sublo[p]-0.5*rmax-stol) return 1; - if(cog > domain->subhi[p]+0.5*rmax+stol) return 1; + double cog = a[p]; + if(cog < domain->sublo[p]-0.5*rmax-stol) return 1; + if(cog > domain->subhi[p]+0.5*rmax+stol) return 1; - if(cog < domain->sublo[p]-stol) { - double t = cog - (domain->sublo[p]-stol); - rout = rout + t*t; - } else if(cog > domain->subhi[p]+stol) { - double t = cog - (domain->subhi[p]+stol); - rout = rout + t*t; - } + if(cog < domain->sublo[p]-stol) { + double t = cog - (domain->sublo[p]-stol); + rout = rout + t*t; + } else if(cog > domain->subhi[p]+stol) { + double t = cog - (domain->subhi[p]+stol); + rout = rout + t*t; + } } if(rout > 0.25*rmax*rmax) - return 1; + return 1; } return 0; } int c2_outside(const double a[3],const double b[3], - int triclinic,const double alpha[3]) { + int triclinic,const double alpha[3]) { const double stol = 1e-5; if(triclinic) { for(int p = 0; p<3; p++) { - double cog = 0.5*(a[p] + b[p]); - if(cog < domain->sublo_lamda[p]-0.5*rcrit*alpha[p]-stol) return 1; - if(cog > domain->subhi_lamda[p]+0.5*rcrit*alpha[p]+stol) return 1; + double cog = 0.5*(a[p] + b[p]); + if(cog < domain->sublo_lamda[p]-0.5*rcrit*alpha[p]-stol) return 1; + if(cog > domain->subhi_lamda[p]+0.5*rcrit*alpha[p]+stol) return 1; } } else { double rout = 0.0; for(int p = 0; p<3; p++) { - double cog = 0.5*(a[p] + b[p]); - if(cog < domain->sublo[p]-0.5*rcrit-stol) return 1; - if(cog > domain->subhi[p]+0.5*rcrit+stol) return 1; + double cog = 0.5*(a[p] + b[p]); + if(cog < domain->sublo[p]-0.5*rcrit-stol) return 1; + if(cog > domain->subhi[p]+0.5*rcrit+stol) return 1; - if(cog < domain->sublo[p]-stol) { - double t = cog - (domain->sublo[p]-stol); - rout = rout + t*t; - } else if(cog > domain->subhi[p]+stol) { - double t = cog - (domain->subhi[p]+stol); - rout = rout + t*t; - } + if(cog < domain->sublo[p]-stol) { + double t = cog - (domain->sublo[p]-stol); + rout = rout + t*t; + } else if(cog > domain->subhi[p]+stol) { + double t = cog - (domain->subhi[p]+stol); + rout = rout + t*t; + } } if(rout > 0.25*rcrit*rcrit) - return 1; + return 1; } return 0; } double get_weight(const int triclinic, - const double a[3] = 0,const double b[3] = 0, - const double c[3] = 0,const double d[3] = 0) { + const double a[3] = 0,const double b[3] = 0, + const double c[3] = 0,const double d[3] = 0) { const double *s0 = triclinic ? domain->sublo_lamda : domain->sublo, *s1 = triclinic ? domain->subhi_lamda : domain->subhi; @@ -498,46 +499,46 @@ public: } void force_debug_3t(double xx[][3], - int i0,int j0,int k0, - int i ,int j ,int k , - double dfix,double dfiy,double dfiz, - double dfjx,double dfjy,double dfjz, - double dfkx,double dfky,double dfkz); + int i0,int j0,int k0, + int i ,int j ,int k , + double dfix,double dfiy,double dfiz, + double dfjx,double dfjy,double dfjz, + double dfkx,double dfky,double dfkz); void force_debug_3v(double xx[][3], - int i0,int j0,int k0, - int i ,int j ,int k , - double dfix,double dfiy,double dfiz, - double dfjx,double dfjy,double dfjz, - double dfkx,double dfky,double dfkz); + int i0,int j0,int k0, + int i ,int j ,int k , + double dfix,double dfiy,double dfiz, + double dfjx,double dfjy,double dfjz, + double dfkx,double dfky,double dfkz); void force_debug_4(double xx[][3], - int i0,int j0,int k0,int m0, - int i ,int j ,int k ,int m , - double dfix,double dfiy,double dfiz, - double dfjx,double dfjy,double dfjz, - double dfkx,double dfky,double dfkz, - double dfmx,double dfmy,double dfmz); + int i0,int j0,int k0,int m0, + int i ,int j ,int k ,int m , + double dfix,double dfiy,double dfiz, + double dfjx,double dfjy,double dfjz, + double dfkx,double dfky,double dfkz, + double dfmx,double dfmy,double dfmz); double numderiv3t(double xx[][3],int i,int j,int k,int p); double numderiv3v(double xx[][3],int i,int j,int k,int p,int ipert); double numderiv4(double xx[][3],int i,int j,int k,int m,int p); void compute_x(const int *nnei,const int * const *nlist, - double *e_s,double *e_p,double *e_t,double *e_q, - int evflag,int newton_pair); + double *e_s,double *e_p,double *e_t,double *e_q, + int evflag,int newton_pair); /* Reimplementation of bond matrix computation */ void fl_deriv_new(double r,double ri,double xhat,double yhat,double zhat, - double &fl_0,double &fl_x,double &fl_y,double &fl_z, - double &fl_rp,double &fl_p1,double &fl_r0,double &fl_al); + double &fl_0,double &fl_x,double &fl_y,double &fl_z, + double &fl_rp,double &fl_p1,double &fl_r0,double &fl_al); void hamltn_5_raw(const double xin,const double yin,const double zin, - double M [8][8],double Mx[8][8], - double My[8][8],double Mz[8][8], - double *fl_deriv_sum_p); + double M [8][8],double Mx[8][8], + double My[8][8],double Mz[8][8], + double *fl_deriv_sum_p); void hamltn_7_raw(const double xin,const double yin,const double zin, - double M [8][8],double Mx[8][8], - double My[8][8],double Mz[8][8], - double *fl_deriv_sum_p); + double M [8][8],double Mx[8][8], + double My[8][8],double Mz[8][8], + double *fl_deriv_sum_p); /* * */ // Old matrix routines, only used in force debug routines. @@ -546,9 +547,9 @@ public: Matrix h; for(int l = 1; l <= lmax; l++) { for(int n = 1; n <= lmax; n++) { - h.m[l][n] = 0.0; - for(int m = 1; m <= lmax; m++) - h.m[l][n] += ha.m[l][m] * hb.m[m][n]; + h.m[l][n] = 0.0; + for(int m = 1; m <= lmax; m++) + h.m[l][n] += ha.m[l][m] * hb.m[m][n]; } } return h; @@ -560,7 +561,7 @@ public: for(int n = 1; n <= lmax; n++) { double cquan = 0.0; for(int m = 1; m <= lmax; m++) - cquan += ha.m[n][m] * hb.m[m][n]; + cquan += ha.m[n][m] * hb.m[m][n]; zquan += cquan; } return zquan; @@ -572,32 +573,32 @@ public: int i,j,k; if(lmax == 5) { - const int n = 5; - for(i = 1; i<=n; i++) - for(j = 1; j<=n; j++) { - double s = 0.0; - for(k = 1; k<=n; k++) - s = s + a.m[i][k]*b.m[j][k]; - c.m[i][j] = s; - } + const int n = 5; + for(i = 1; i<=n; i++) + for(j = 1; j<=n; j++) { + double s = 0.0; + for(k = 1; k<=n; k++) + s = s + a.m[i][k]*b.m[j][k]; + c.m[i][j] = s; + } } else if(lmax == 7) { - const int n = 7; - for(i = 1; i<=n; i++) - for(j = 1; j<=n; j++) { - double s = 0.0; - for(k = 1; k<=n; k++) - s = s + a.m[i][k]*b.m[j][k]; - c.m[i][j] = s; - } + const int n = 7; + for(i = 1; i<=n; i++) + for(j = 1; j<=n; j++) { + double s = 0.0; + for(k = 1; k<=n; k++) + s = s + a.m[i][k]*b.m[j][k]; + c.m[i][j] = s; + } } else { - const int n = lmax; - for(i = 1; i<=n; i++) - for(j = 1; j<=n; j++) { - double s = 0.0; - for(k = 1; k<=n; k++) - s = s + a.m[i][k]*b.m[j][k]; - c.m[i][j] = s; - } + const int n = lmax; + for(i = 1; i<=n; i++) + for(j = 1; j<=n; j++) { + double s = 0.0; + for(k = 1; k<=n; k++) + s = s + a.m[i][k]*b.m[j][k]; + c.m[i][j] = s; + } } } @@ -608,7 +609,7 @@ public: for(i = 0; i -#include #include "angle_cosine_shift.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-MISC/angle_cosine_shift_exp.cpp b/src/USER-MISC/angle_cosine_shift_exp.cpp index 8c6282de20..79cb0fea7c 100644 --- a/src/USER-MISC/angle_cosine_shift_exp.cpp +++ b/src/USER-MISC/angle_cosine_shift_exp.cpp @@ -15,9 +15,9 @@ Contributing author: Carsten Svaneborg, science@zqex.dk ------------------------------------------------------------------------- */ -#include -#include #include "angle_cosine_shift_exp.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-MISC/angle_dipole.cpp b/src/USER-MISC/angle_dipole.cpp index 781da46869..0956ba3b8f 100644 --- a/src/USER-MISC/angle_dipole.cpp +++ b/src/USER-MISC/angle_dipole.cpp @@ -15,9 +15,9 @@ Contributing authors: Mario Orsi & Wei Ding (QMUL), m.orsi@qmul.ac.uk ------------------------------------------------------------------------- */ -#include -#include #include "angle_dipole.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-MISC/angle_fourier.cpp b/src/USER-MISC/angle_fourier.cpp index 8f5074ff5d..dcf5080431 100644 --- a/src/USER-MISC/angle_fourier.cpp +++ b/src/USER-MISC/angle_fourier.cpp @@ -16,9 +16,9 @@ [ based on angle_cosine_squared.cpp Naveen Michaud-Agrawal (Johns Hopkins U)] ------------------------------------------------------------------------- */ -#include -#include #include "angle_fourier.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-MISC/angle_fourier_simple.cpp b/src/USER-MISC/angle_fourier_simple.cpp index 615556bbe7..bbe3f8520b 100644 --- a/src/USER-MISC/angle_fourier_simple.cpp +++ b/src/USER-MISC/angle_fourier_simple.cpp @@ -16,9 +16,9 @@ [ based on angle_cosine_squared.cpp Naveen Michaud-Agrawal (Johns Hopkins U)] ------------------------------------------------------------------------- */ -#include -#include #include "angle_fourier_simple.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-MISC/angle_quartic.cpp b/src/USER-MISC/angle_quartic.cpp index 21a96100aa..5c5f3411e4 100644 --- a/src/USER-MISC/angle_quartic.cpp +++ b/src/USER-MISC/angle_quartic.cpp @@ -16,9 +16,9 @@ [ based on angle_harmonic.cpp] ------------------------------------------------------------------------- */ -#include -#include #include "angle_quartic.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-MISC/bond_harmonic_shift.cpp b/src/USER-MISC/bond_harmonic_shift.cpp index c7e4444cce..fdd3111783 100644 --- a/src/USER-MISC/bond_harmonic_shift.cpp +++ b/src/USER-MISC/bond_harmonic_shift.cpp @@ -15,12 +15,11 @@ Contributing author: Carsten Svaneborg, science@zqex.dk ------------------------------------------------------------------------- */ -#include -#include #include "bond_harmonic_shift.h" +#include +#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/USER-MISC/bond_harmonic_shift_cut.cpp b/src/USER-MISC/bond_harmonic_shift_cut.cpp index 5b396f5d72..0688cb428a 100644 --- a/src/USER-MISC/bond_harmonic_shift_cut.cpp +++ b/src/USER-MISC/bond_harmonic_shift_cut.cpp @@ -15,12 +15,11 @@ Contributing author: Carsten Svaneborg, science@zqex.dk ------------------------------------------------------------------------- */ -#include -#include #include "bond_harmonic_shift_cut.h" +#include +#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "memory.h" diff --git a/src/USER-MISC/compute_cnp_atom.cpp b/src/USER-MISC/compute_cnp_atom.cpp index 6fa16f1a9a..ba97be25d4 100644 --- a/src/USER-MISC/compute_cnp_atom.cpp +++ b/src/USER-MISC/compute_cnp_atom.cpp @@ -21,11 +21,10 @@ branicio@usc.edu ------------------------------------------------------------------------- */ -#include -#include -#include - #include "compute_cnp_atom.h" +#include +#include +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/USER-MISC/compute_entropy_atom.cpp b/src/USER-MISC/compute_entropy_atom.cpp index 0367d7fe6d..00f7e6dc8b 100644 --- a/src/USER-MISC/compute_entropy_atom.cpp +++ b/src/USER-MISC/compute_entropy_atom.cpp @@ -15,10 +15,9 @@ Contributing author: Pablo Piaggi (EPFL Lausanne) ------------------------------------------------------------------------- */ +#include "compute_entropy_atom.h" #include #include -#include -#include "compute_entropy_atom.h" #include "atom.h" #include "update.h" #include "modify.h" @@ -28,13 +27,11 @@ #include "force.h" #include "pair.h" #include "comm.h" -#include "math_extra.h" #include "math_const.h" #include "memory.h" #include "error.h" #include "domain.h" - using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/USER-MISC/compute_pressure_cylinder.cpp b/src/USER-MISC/compute_pressure_cylinder.cpp index c250eaf677..6d2509d685 100644 --- a/src/USER-MISC/compute_pressure_cylinder.cpp +++ b/src/USER-MISC/compute_pressure_cylinder.cpp @@ -11,10 +11,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include #include "compute_pressure_cylinder.h" +#include +#include #include "atom.h" #include "update.h" #include "force.h" @@ -22,7 +21,6 @@ #include "neighbor.h" #include "neigh_request.h" #include "neigh_list.h" -#include "group.h" #include "memory.h" #include "error.h" #include "citeme.h" diff --git a/src/USER-MISC/compute_pressure_grem.cpp b/src/USER-MISC/compute_pressure_grem.cpp index 087c01bd8e..ba949727b0 100644 --- a/src/USER-MISC/compute_pressure_grem.cpp +++ b/src/USER-MISC/compute_pressure_grem.cpp @@ -11,17 +11,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include #include "compute_pressure_grem.h" -#include "atom.h" +#include #include "update.h" #include "domain.h" #include "modify.h" #include "fix.h" #include "force.h" -#include "pair.h" #include "kspace.h" #include "error.h" diff --git a/src/USER-MISC/compute_stress_mop.cpp b/src/USER-MISC/compute_stress_mop.cpp index cb2a0b9713..2f932321e1 100644 --- a/src/USER-MISC/compute_stress_mop.cpp +++ b/src/USER-MISC/compute_stress_mop.cpp @@ -15,18 +15,14 @@ Contributing Authors : Romain Vermorel (LFCR), Laurent Joly (ULyon) --------------------------------------------------------------------------*/ +#include "compute_stress_mop.h" #include #include #include -#include -#include "compute_stress_mop.h" #include "atom.h" #include "update.h" #include "domain.h" -#include "group.h" -#include "modify.h" -#include "fix.h" #include "neighbor.h" #include "force.h" #include "pair.h" diff --git a/src/USER-MISC/compute_stress_mop_profile.cpp b/src/USER-MISC/compute_stress_mop_profile.cpp index 5499a37a46..5f6d0a36b2 100644 --- a/src/USER-MISC/compute_stress_mop_profile.cpp +++ b/src/USER-MISC/compute_stress_mop_profile.cpp @@ -15,18 +15,14 @@ Contributing Authors : Romain Vermorel (LFCR), Laurent Joly (ULyon) --------------------------------------------------------------------------*/ +#include "compute_stress_mop_profile.h" #include #include #include -#include -#include "compute_stress_mop_profile.h" #include "atom.h" #include "update.h" #include "domain.h" -#include "group.h" -#include "modify.h" -#include "fix.h" #include "neighbor.h" #include "force.h" #include "pair.h" diff --git a/src/USER-MISC/compute_temp_rotate.cpp b/src/USER-MISC/compute_temp_rotate.cpp index 36093bd1e1..94c6115186 100644 --- a/src/USER-MISC/compute_temp_rotate.cpp +++ b/src/USER-MISC/compute_temp_rotate.cpp @@ -15,16 +15,13 @@ Contributing author: Laurent Joly (U Lyon, France), ljoly.ulyon@gmail.com ------------------------------------------------------------------------- */ -#include -#include -#include #include "compute_temp_rotate.h" +#include #include "atom.h" #include "update.h" #include "force.h" #include "group.h" #include "domain.h" -#include "lattice.h" #include "error.h" #include "memory.h" diff --git a/src/USER-MISC/dihedral_cosine_shift_exp.cpp b/src/USER-MISC/dihedral_cosine_shift_exp.cpp index c411ea8150..820dfabdeb 100644 --- a/src/USER-MISC/dihedral_cosine_shift_exp.cpp +++ b/src/USER-MISC/dihedral_cosine_shift_exp.cpp @@ -15,14 +15,12 @@ Contributing author: Carsten Svaneborg, science@zqex.dk ------------------------------------------------------------------------- */ +#include "dihedral_cosine_shift_exp.h" #include #include -#include -#include "dihedral_cosine_shift_exp.h" #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "memory.h" diff --git a/src/USER-MISC/dihedral_fourier.cpp b/src/USER-MISC/dihedral_fourier.cpp index af86259c01..7cc250b1a8 100644 --- a/src/USER-MISC/dihedral_fourier.cpp +++ b/src/USER-MISC/dihedral_fourier.cpp @@ -16,16 +16,13 @@ [ based on dihedral_charmm.cpp Paul Crozier (SNL) ] ------------------------------------------------------------------------- */ +#include "dihedral_fourier.h" #include #include -#include -#include "dihedral_fourier.h" #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" -#include "pair.h" #include "update.h" #include "math_const.h" #include "memory.h" diff --git a/src/USER-MISC/dihedral_nharmonic.cpp b/src/USER-MISC/dihedral_nharmonic.cpp index ea2b76f415..f1e0018689 100644 --- a/src/USER-MISC/dihedral_nharmonic.cpp +++ b/src/USER-MISC/dihedral_nharmonic.cpp @@ -16,12 +16,11 @@ [ based on dihedral_multi_harmonic.cpp Mathias Puetz (SNL) and friends ] ------------------------------------------------------------------------- */ -#include -#include #include "dihedral_nharmonic.h" +#include +#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "update.h" diff --git a/src/USER-MISC/dihedral_quadratic.cpp b/src/USER-MISC/dihedral_quadratic.cpp index 8436e73c5c..02effc2f4f 100644 --- a/src/USER-MISC/dihedral_quadratic.cpp +++ b/src/USER-MISC/dihedral_quadratic.cpp @@ -16,12 +16,11 @@ [ based on dihedral_helix.cpp Paul Crozier (SNL) ] ------------------------------------------------------------------------- */ -#include -#include #include "dihedral_quadratic.h" +#include +#include #include "atom.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "update.h" diff --git a/src/USER-MISC/dihedral_spherical.cpp b/src/USER-MISC/dihedral_spherical.cpp index 3b30121551..78d45f923d 100644 --- a/src/USER-MISC/dihedral_spherical.cpp +++ b/src/USER-MISC/dihedral_spherical.cpp @@ -17,22 +17,19 @@ and Paul Crozier (SNL) ] ------------------------------------------------------------------------- */ +#include "dihedral_spherical.h" #include #include -#include #include #include "atom.h" #include "comm.h" #include "neighbor.h" #include "domain.h" #include "force.h" -#include "pair.h" -#include "update.h" #include "math_const.h" #include "math_extra.h" #include "memory.h" #include "error.h" -#include "dihedral_spherical.h" using namespace std; using namespace LAMMPS_NS; diff --git a/src/USER-MISC/dihedral_table.cpp b/src/USER-MISC/dihedral_table.cpp index a97ae3649f..7fa871d3be 100644 --- a/src/USER-MISC/dihedral_table.cpp +++ b/src/USER-MISC/dihedral_table.cpp @@ -17,21 +17,20 @@ the "tridiag.c" written by Gerard Jungman for GSL ------------------------------------------------------------------------- */ +#include +#include #include #include #include -#include #include -#include -#include -#include +#include // IWYU pragma: keep +#include // IWYU pragma: keep #include "atom.h" #include "comm.h" #include "neighbor.h" #include "domain.h" #include "force.h" -#include "update.h" #include "memory.h" #include "error.h" #include "dihedral_table.h" diff --git a/src/USER-MISC/dihedral_table_cut.cpp b/src/USER-MISC/dihedral_table_cut.cpp index 18a645cd75..71f9ea0df1 100644 --- a/src/USER-MISC/dihedral_table_cut.cpp +++ b/src/USER-MISC/dihedral_table_cut.cpp @@ -16,25 +16,23 @@ Based on tabulated dihedral (dihedral_table.cpp) by Andrew Jewett ------------------------------------------------------------------------- */ +#include "dihedral_table_cut.h" +#include +#include #include #include #include -#include #include -#include -#include -#include +#include // IWYU pragma: keep +#include // IWYU pragma: keep -#include "dihedral_table_cut.h" #include "atom.h" #include "neighbor.h" #include "update.h" -#include "domain.h" #include "comm.h" #include "force.h" #include "citeme.h" #include "math_const.h" -#include "math_extra.h" #include "memory.h" #include "error.h" #include "utils.h" @@ -42,8 +40,6 @@ using namespace LAMMPS_NS; using namespace MathConst; using namespace std; -using namespace MathExtra; - static const char cite_dihedral_tablecut[] = "dihedral_style table/cut command:\n\n" diff --git a/src/USER-MISC/fix_addtorque.cpp b/src/USER-MISC/fix_addtorque.cpp index 2cd1ac7527..665f1d4a60 100644 --- a/src/USER-MISC/fix_addtorque.cpp +++ b/src/USER-MISC/fix_addtorque.cpp @@ -15,9 +15,9 @@ Contributing author: Laurent Joly (U Lyon, France), ljoly.ulyon@gmail.com ------------------------------------------------------------------------- */ -#include -#include #include "fix_addtorque.h" +#include +#include #include "atom.h" #include "update.h" #include "modify.h" @@ -25,7 +25,6 @@ #include "respa.h" #include "input.h" #include "variable.h" -#include "memory.h" #include "error.h" #include "group.h" #include "force.h" diff --git a/src/USER-MISC/fix_ave_correlate_long.cpp b/src/USER-MISC/fix_ave_correlate_long.cpp index dc52d94b14..b1bcc07fa7 100644 --- a/src/USER-MISC/fix_ave_correlate_long.cpp +++ b/src/USER-MISC/fix_ave_correlate_long.cpp @@ -21,11 +21,12 @@ see J. Chem. Phys. 133, 154103 (2010) ------------------------------------------------------------------------- */ +#include "fix_ave_correlate_long.h" +#include #include #include #include #include -#include "fix_ave_correlate_long.h" #include "update.h" #include "modify.h" #include "compute.h" diff --git a/src/USER-MISC/fix_bond_react.cpp b/src/USER-MISC/fix_bond_react.cpp index c641912db6..ef23f98d64 100644 --- a/src/USER-MISC/fix_bond_react.cpp +++ b/src/USER-MISC/fix_bond_react.cpp @@ -15,11 +15,10 @@ See the README file in the top-level LAMMPS directory. Contributing Author: Jacob Gissinger (jacob.gissinger@colorado.edu) ------------------------------------------------------------------------- */ +#include "fix_bond_react.h" #include #include #include -#include -#include "fix_bond_react.h" #include "update.h" #include "modify.h" #include "respa.h" diff --git a/src/USER-MISC/fix_electron_stopping.cpp b/src/USER-MISC/fix_electron_stopping.cpp index 0831ebcf89..2130f07420 100644 --- a/src/USER-MISC/fix_electron_stopping.cpp +++ b/src/USER-MISC/fix_electron_stopping.cpp @@ -16,16 +16,14 @@ Information: k.avchachov@gmail.com ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_electron_stopping.h" +#include +#include #include "mpi.h" #include "atom.h" #include "update.h" #include "domain.h" #include "region.h" -#include "group.h" #include "force.h" #include "fix.h" #include "memory.h" diff --git a/src/USER-MISC/fix_ffl.cpp b/src/USER-MISC/fix_ffl.cpp index 9ab113aeaa..a245b6b4e5 100644 --- a/src/USER-MISC/fix_ffl.cpp +++ b/src/USER-MISC/fix_ffl.cpp @@ -18,31 +18,21 @@ /* ---------------------------------------------------------------------- Contributing authors: Lionel Constantin (EPFL), David M. Wilkins (EPFL), - Michele Ceriotti (EPFL) + Michele Ceriotti (EPFL) ------------------------------------------------------------------------- */ +#include "fix_ffl.h" #include #include #include -#include -#include "fix_ffl.h" -#include "math_extra.h" #include "atom.h" -#include "atom_vec_ellipsoid.h" #include "force.h" #include "update.h" -#include "modify.h" -#include "compute.h" -#include "domain.h" -#include "region.h" #include "respa.h" #include "comm.h" -#include "input.h" -#include "variable.h" #include "random_mars.h" #include "memory.h" #include "error.h" -#include "group.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-MISC/fix_filter_corotate.cpp b/src/USER-MISC/fix_filter_corotate.cpp index f6cc1c435f..bfc5f58f93 100644 --- a/src/USER-MISC/fix_filter_corotate.cpp +++ b/src/USER-MISC/fix_filter_corotate.cpp @@ -16,30 +16,25 @@ some subroutines are from fix_shake.cpp ------------------------------------------------------------------------- */ +#include "fix_filter_corotate.h" #include +#include +#include #include #include -#include "fix_filter_corotate.h" #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "bond.h" +#include "comm.h" +#include "domain.h" #include "angle.h" +#include "bond.h" #include "math_const.h" #include "update.h" #include "modify.h" -#include "domain.h" -#include "region.h" #include "memory.h" #include "error.h" #include "force.h" -#include "comm.h" -#include "error.h" -#include "memory.h" -#include "domain.h" -#include "integrate.h" #include "respa.h" -#include "neighbor.h" #include "citeme.h" using namespace LAMMPS_NS; diff --git a/src/USER-MISC/fix_flow_gauss.cpp b/src/USER-MISC/fix_flow_gauss.cpp index b6366ec509..70be1f1e45 100644 --- a/src/USER-MISC/fix_flow_gauss.cpp +++ b/src/USER-MISC/fix_flow_gauss.cpp @@ -16,13 +16,12 @@ Joel.Eaves@Colorado.edu ------------------------------------------------------------------------- */ -#include -#include #include "fix_flow_gauss.h" +#include +#include #include "atom.h" #include "force.h" #include "group.h" -#include "comm.h" #include "update.h" #include "domain.h" #include "error.h" diff --git a/src/USER-MISC/fix_gle.cpp b/src/USER-MISC/fix_gle.cpp index 01da7f87cf..b8bdc66d08 100644 --- a/src/USER-MISC/fix_gle.cpp +++ b/src/USER-MISC/fix_gle.cpp @@ -16,28 +16,19 @@ Axel Kohylmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_gle.h" #include #include #include #include -#include "fix_gle.h" -#include "math_extra.h" #include "atom.h" -#include "atom_vec_ellipsoid.h" #include "force.h" #include "update.h" -#include "modify.h" -#include "compute.h" -#include "domain.h" -#include "region.h" #include "respa.h" #include "comm.h" -#include "input.h" -#include "variable.h" #include "random_mars.h" #include "memory.h" #include "error.h" -#include "group.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-MISC/fix_grem.cpp b/src/USER-MISC/fix_grem.cpp index 635acf705c..4272740068 100644 --- a/src/USER-MISC/fix_grem.cpp +++ b/src/USER-MISC/fix_grem.cpp @@ -22,19 +22,14 @@ Tom Keyes (Boston University) ------------------------------------------------------------------------- */ -#include -#include -#include -#include "comm.h" #include "fix_grem.h" +#include #include "atom.h" #include "force.h" #include "update.h" #include "modify.h" #include "domain.h" -#include "input.h" #include "compute.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-MISC/fix_ipi.cpp b/src/USER-MISC/fix_ipi.cpp index 32892d87a8..08b39ee89b 100644 --- a/src/USER-MISC/fix_ipi.cpp +++ b/src/USER-MISC/fix_ipi.cpp @@ -15,15 +15,12 @@ Contributing author: Michele Ceriotti (EPFL), Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_ipi.h" +#include +#include #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" #include "kspace.h" #include "modify.h" @@ -32,8 +29,6 @@ #include "neighbor.h" #include "irregular.h" #include "domain.h" -#include "compute_pressure.h" -#include using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-MISC/fix_nvk.cpp b/src/USER-MISC/fix_nvk.cpp index 2ac2a7c9fc..410a269f8c 100644 --- a/src/USER-MISC/fix_nvk.cpp +++ b/src/USER-MISC/fix_nvk.cpp @@ -15,18 +15,16 @@ Contributing author: Efrem Braun (UC Berkeley) ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_nvk.h" +#include +#include +#include #include "atom.h" #include "force.h" #include "update.h" #include "respa.h" #include "error.h" -#include "compute.h" #include "math_extra.h" -#include "domain.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-MISC/fix_pimd.cpp b/src/USER-MISC/fix_pimd.cpp index 3929d47d6b..8f790f0a59 100644 --- a/src/USER-MISC/fix_pimd.cpp +++ b/src/USER-MISC/fix_pimd.cpp @@ -21,10 +21,11 @@ Version 1.0 ------------------------------------------------------------------------- */ +#include "fix_pimd.h" +#include #include #include #include -#include "fix_pimd.h" #include "universe.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/fix_rhok.cpp b/src/USER-MISC/fix_rhok.cpp index 6a6e71ebaa..c638adf6a4 100644 --- a/src/USER-MISC/fix_rhok.cpp +++ b/src/USER-MISC/fix_rhok.cpp @@ -13,12 +13,11 @@ Contributing author: Ulf R. Pedersen, ulf@urp.dk ------------------------------------------------------------------------- */ -#include -#include +#include "fix_rhok.h" +#include #include #include -#include "fix_rhok.h" #include "atom.h" #include "domain.h" #include "error.h" diff --git a/src/USER-MISC/fix_smd.cpp b/src/USER-MISC/fix_smd.cpp index cbebdebdbf..32c040c2b4 100644 --- a/src/USER-MISC/fix_smd.cpp +++ b/src/USER-MISC/fix_smd.cpp @@ -16,10 +16,10 @@ based on fix spring by: Paul Crozier (SNL) ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_smd.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "update.h" diff --git a/src/USER-MISC/fix_srp.cpp b/src/USER-MISC/fix_srp.cpp index ebc161ff99..c0db252db4 100644 --- a/src/USER-MISC/fix_srp.cpp +++ b/src/USER-MISC/fix_srp.cpp @@ -15,9 +15,10 @@ Contributing authors: Timothy Sirk (ARL), Pieter in't Veld (BASF) ------------------------------------------------------------------------- */ -#include -#include #include "fix_srp.h" +#include +#include +#include #include "atom.h" #include "force.h" #include "domain.h" @@ -635,11 +636,11 @@ void FixSRP::restart(char *buf) int FixSRP::modify_param(int /*narg*/, char **arg) { if (strcmp(arg[0],"btype") == 0) { - btype = atoi(arg[1]); + btype = force->inumeric(FLERR,arg[1]); return 2; } if (strcmp(arg[0],"bptype") == 0) { - bptype = atoi(arg[1]); + bptype = force->inumeric(FLERR,arg[1]); return 2; } return 0; diff --git a/src/USER-MISC/fix_ti_spring.cpp b/src/USER-MISC/fix_ti_spring.cpp index 305e29e033..8481b34a6b 100644 --- a/src/USER-MISC/fix_ti_spring.cpp +++ b/src/USER-MISC/fix_ti_spring.cpp @@ -18,9 +18,9 @@ Maurice de Koning (Unicamp/Brazil) - dekoning@ifi.unicamp.br ------------------------------------------------------------------------- */ -#include -#include #include "fix_ti_spring.h" +#include +#include #include "atom.h" #include "update.h" #include "domain.h" diff --git a/src/USER-MISC/fix_ttm_mod.cpp b/src/USER-MISC/fix_ttm_mod.cpp index a34c2eb42f..55526a9149 100644 --- a/src/USER-MISC/fix_ttm_mod.cpp +++ b/src/USER-MISC/fix_ttm_mod.cpp @@ -17,17 +17,14 @@ Vasily Pisarev (Joint Institute for High Temperatures of RAS) ------------------------------------------------------------------------- */ -#include "lmptype.h" +#include "fix_ttm_mod.h" #include #include #include -#include -#include "fix_ttm_mod.h" #include "atom.h" #include "force.h" #include "update.h" #include "domain.h" -#include "region.h" #include "respa.h" #include "comm.h" #include "random_mars.h" diff --git a/src/USER-MISC/fix_wall_ees.cpp b/src/USER-MISC/fix_wall_ees.cpp index 5ca16ebdad..bd7e230472 100644 --- a/src/USER-MISC/fix_wall_ees.cpp +++ b/src/USER-MISC/fix_wall_ees.cpp @@ -15,21 +15,13 @@ Contributing author: Abdoreza Ershadinia, a.ershadinia at gmail.com ------------------------------------------------------------------------- */ +#include "fix_wall_ees.h" #include #include "math_extra.h" -#include "fix_wall_ees.h" #include "atom.h" #include "atom_vec.h" #include "atom_vec_ellipsoid.h" -#include "domain.h" -#include "region.h" -#include "force.h" -#include "lattice.h" -#include "update.h" -#include "output.h" -#include "respa.h" #include "error.h" -#include "math_extra.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-MISC/fix_wall_region_ees.cpp b/src/USER-MISC/fix_wall_region_ees.cpp index 33bf636e64..5c6bb1874b 100644 --- a/src/USER-MISC/fix_wall_region_ees.cpp +++ b/src/USER-MISC/fix_wall_region_ees.cpp @@ -15,19 +15,16 @@ Contributing author: Abdoreza Ershadinia, a.ershadinia at gmail.com ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_wall_region_ees.h" +#include +#include +#include #include "atom.h" -#include "atom_vec.h" #include "atom_vec_ellipsoid.h" #include "domain.h" #include "region.h" #include "force.h" -#include "lattice.h" #include "update.h" -#include "output.h" #include "respa.h" #include "error.h" #include "math_extra.h" From 956d21ec0ead2d94220c22dd5ba97c0bbe45189f Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Wed, 10 Jul 2019 15:38:41 -0400 Subject: [PATCH 63/79] update include lists in packages USER-MISC, USER-MOFF, USER-PTM, and USER-SMD --- src/USER-MISC/fix_imd.cpp | 2 -- src/USER-MISC/improper_cossq.cpp | 4 +--- src/USER-MISC/improper_distance.cpp | 4 +--- src/USER-MISC/improper_fourier.cpp | 5 +---- src/USER-MISC/improper_ring.cpp | 5 +---- src/USER-MISC/pair_agni.cpp | 6 ++---- src/USER-MISC/pair_buck_mdf.cpp | 9 +++------ src/USER-MISC/pair_coul_diel.cpp | 6 ++---- src/USER-MISC/pair_coul_shield.cpp | 5 +---- src/USER-MISC/pair_drip.cpp | 6 ++---- src/USER-MISC/pair_drip.h | 2 -- src/USER-MISC/pair_e3b.cpp | 10 ++++------ src/USER-MISC/pair_edip.cpp | 4 ++-- src/USER-MISC/pair_edip_multi.cpp | 5 ++--- src/USER-MISC/pair_extep.cpp | 4 ++-- src/USER-MISC/pair_extep.h | 1 - src/USER-MISC/pair_gauss_cut.cpp | 9 ++------- src/USER-MISC/pair_ilp_graphene_hbn.cpp | 3 +-- src/USER-MISC/pair_ilp_graphene_hbn.h | 2 -- src/USER-MISC/pair_kolmogorov_crespi_full.cpp | 3 +-- src/USER-MISC/pair_kolmogorov_crespi_full.h | 2 -- src/USER-MISC/pair_kolmogorov_crespi_z.cpp | 4 ++-- src/USER-MISC/pair_lebedeva_z.cpp | 4 ++-- src/USER-MISC/pair_lennard_mdf.cpp | 8 +++----- src/USER-MISC/pair_list.cpp | 16 ++++++---------- src/USER-MISC/pair_lj_expand_coul_long.cpp | 8 +++----- src/USER-MISC/pair_lj_mdf.cpp | 8 +++----- src/USER-MISC/pair_lj_sf_dipole_sf.cpp | 6 +++--- src/USER-MISC/pair_meam_spline.cpp | 4 +--- src/USER-MISC/pair_meam_sw_spline.cpp | 4 +--- src/USER-MISC/pair_momb.cpp | 5 ++--- src/USER-MISC/pair_morse_smooth_linear.cpp | 7 +++---- src/USER-MISC/pair_srp.cpp | 4 +++- src/USER-MISC/pair_tersoff_table.cpp | 4 ++-- src/USER-MISC/temper_grem.cpp | 9 ++------- src/USER-MISC/temper_npt.cpp | 8 ++------ src/USER-MOFFF/angle_class2_p6.cpp | 4 ++-- src/USER-MOFFF/angle_cosine_buck6d.cpp | 6 ++---- src/USER-MOFFF/improper_inversion_harmonic.cpp | 6 +----- src/USER-MOFFF/pair_buck6d_coul_gauss_dsf.cpp | 6 ++---- src/USER-MOFFF/pair_buck6d_coul_gauss_long.cpp | 9 +++------ src/USER-PTM/compute_ptm_atom.cpp | 4 +--- src/USER-PTM/ptm_convex_hull_incremental.cpp | 1 - src/USER-PTM/ptm_index.cpp | 4 ---- src/USER-PTM/ptm_initialize_data.cpp | 8 +------- src/USER-PTM/ptm_neighbour_ordering.cpp | 5 ++--- src/USER-PTM/ptm_polar.h | 1 - src/USER-PTM/ptm_quat.cpp | 2 +- src/USER-PTM/ptm_voronoi_cell.cpp | 2 +- src/USER-PTM/ptm_voronoi_cell.h | 3 --- src/USER-SMD/atom_vec_smd.cpp | 5 +---- src/USER-SMD/compute_smd_contact_radius.cpp | 3 +-- src/USER-SMD/compute_smd_damage.cpp | 3 +-- src/USER-SMD/compute_smd_internal_energy.cpp | 1 - src/USER-SMD/compute_smd_plastic_strain.cpp | 3 +-- .../compute_smd_plastic_strain_rate.cpp | 3 +-- src/USER-SMD/compute_smd_rho.cpp | 3 +-- src/USER-SMD/compute_smd_tlsph_defgrad.cpp | 10 +++------- src/USER-SMD/compute_smd_tlsph_shape.cpp | 8 ++------ src/USER-SMD/compute_smd_tlsph_strain.cpp | 7 ++----- src/USER-SMD/compute_smd_tlsph_stress.cpp | 3 ++- src/USER-SMD/compute_smd_triangle_vertices.cpp | 9 +-------- src/USER-SMD/compute_smd_ulsph_strain.cpp | 9 +-------- src/USER-SMD/compute_smd_ulsph_stress.cpp | 3 ++- src/USER-SMD/compute_smd_vol.cpp | 4 ++-- src/USER-SMD/fix_smd_adjust_dt.cpp | 11 ++--------- src/USER-SMD/fix_smd_integrate_tlsph.cpp | 12 +++--------- src/USER-SMD/fix_smd_integrate_ulsph.cpp | 11 +---------- .../fix_smd_move_triangulated_surface.cpp | 16 +++------------- src/USER-SMD/fix_smd_setvel.cpp | 4 ++-- .../fix_smd_tlsph_reference_configuration.cpp | 8 ++------ .../fix_smd_tlsph_reference_configuration.h | 1 - src/USER-SMD/fix_smd_wall_surface.cpp | 14 ++++---------- src/USER-SMD/pair_smd_hertz.cpp | 7 ++----- src/USER-SMD/pair_smd_tlsph.cpp | 17 ++++++----------- src/USER-SMD/pair_smd_triangulated_surface.cpp | 9 ++------- src/USER-SMD/pair_smd_ulsph.cpp | 10 ++-------- src/USER-SMD/smd_material_models.cpp | 4 ++++ 78 files changed, 136 insertions(+), 319 deletions(-) diff --git a/src/USER-MISC/fix_imd.cpp b/src/USER-MISC/fix_imd.cpp index 1c3eafdc46..10aaa285a5 100644 --- a/src/USER-MISC/fix_imd.cpp +++ b/src/USER-MISC/fix_imd.cpp @@ -58,8 +58,6 @@ negotiate an appropriate license for such distribution." #include "group.h" #include "memory.h" -#include -#include #include #include diff --git a/src/USER-MISC/improper_cossq.cpp b/src/USER-MISC/improper_cossq.cpp index c8eb0808fb..2ea804b95d 100644 --- a/src/USER-MISC/improper_cossq.cpp +++ b/src/USER-MISC/improper_cossq.cpp @@ -16,14 +16,12 @@ gvog@chemeng.ntua.gr ------------------------------------------------------------------------- */ +#include "improper_cossq.h" #include #include -#include -#include "improper_cossq.h" #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "memory.h" diff --git a/src/USER-MISC/improper_distance.cpp b/src/USER-MISC/improper_distance.cpp index 50babcc84e..2efab8b5f8 100644 --- a/src/USER-MISC/improper_distance.cpp +++ b/src/USER-MISC/improper_distance.cpp @@ -15,16 +15,14 @@ Contributing author: Paolo Raiteri (Curtin University) ------------------------------------------------------------------------- */ +#include "improper_distance.h" #include #include -#include -#include "improper_distance.h" #include "atom.h" #include "comm.h" #include "neighbor.h" #include "domain.h" #include "force.h" -#include "update.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MISC/improper_fourier.cpp b/src/USER-MISC/improper_fourier.cpp index 288d888d12..a0ef3a2058 100644 --- a/src/USER-MISC/improper_fourier.cpp +++ b/src/USER-MISC/improper_fourier.cpp @@ -16,15 +16,12 @@ [ based on improper_umbrella.cpp Tod A Pascal (Caltech) ] ------------------------------------------------------------------------- */ +#include "improper_fourier.h" #include #include -#include -#include -#include "improper_fourier.h" #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "memory.h" diff --git a/src/USER-MISC/improper_ring.cpp b/src/USER-MISC/improper_ring.cpp index 36ba73af0f..48db5a41e9 100644 --- a/src/USER-MISC/improper_ring.cpp +++ b/src/USER-MISC/improper_ring.cpp @@ -36,16 +36,13 @@ of j. ------------------------------------------------------------------------- */ +#include "improper_ring.h" #include #include -#include -#include "improper_ring.h" #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" -#include "update.h" #include "math_const.h" #include "math_special.h" #include "memory.h" diff --git a/src/USER-MISC/pair_agni.cpp b/src/USER-MISC/pair_agni.cpp index 21a6f1deee..b3abc647ef 100644 --- a/src/USER-MISC/pair_agni.cpp +++ b/src/USER-MISC/pair_agni.cpp @@ -15,18 +15,16 @@ Contributing authors: Axel Kohlmeyer (Temple U), Venkatesh Botu ------------------------------------------------------------------------- */ +#include "pair_agni.h" +#include #include -#include #include #include -#include "pair_agni.h" #include "atom.h" #include "neighbor.h" #include "neigh_request.h" #include "force.h" #include "comm.h" -#include "memory.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MISC/pair_buck_mdf.cpp b/src/USER-MISC/pair_buck_mdf.cpp index afd15d7fdb..e977197522 100644 --- a/src/USER-MISC/pair_buck_mdf.cpp +++ b/src/USER-MISC/pair_buck_mdf.cpp @@ -15,21 +15,18 @@ Contributing author: Paolo Raiteri (Curtin University) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_buck_mdf.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neigh_list.h" -#include "math_const.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; -using namespace MathConst; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-MISC/pair_coul_diel.cpp b/src/USER-MISC/pair_coul_diel.cpp index a86921d296..a375901ecd 100644 --- a/src/USER-MISC/pair_coul_diel.cpp +++ b/src/USER-MISC/pair_coul_diel.cpp @@ -14,11 +14,9 @@ Contributiong authors: Arben Jusufi, Axel Kohlmeyer (Temple U.) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_coul_diel.h" +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_coul_shield.cpp b/src/USER-MISC/pair_coul_shield.cpp index f74dcfe7d8..9264e51287 100644 --- a/src/USER-MISC/pair_coul_shield.cpp +++ b/src/USER-MISC/pair_coul_shield.cpp @@ -18,11 +18,8 @@ [Maaravi et al, J. Phys. Chem. C 121, 22826-22835 (2017)] ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_coul_shield.h" +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_drip.cpp b/src/USER-MISC/pair_drip.cpp index 118c033b5c..20ec3abcf9 100644 --- a/src/USER-MISC/pair_drip.cpp +++ b/src/USER-MISC/pair_drip.cpp @@ -20,19 +20,17 @@ Phys. Rev. B, 98, 235404 (2018). ------------------------------------------------------------------------- */ +#include "pair_drip.h" +#include #include -#include #include #include -#include -#include "pair_drip.h" #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "my_page.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MISC/pair_drip.h b/src/USER-MISC/pair_drip.h index 0a8f90dfc2..3ea6c735a6 100644 --- a/src/USER-MISC/pair_drip.h +++ b/src/USER-MISC/pair_drip.h @@ -31,8 +31,6 @@ PairStyle(drip, PairDRIP) #define LMP_PAIR_DRIP_H #include "pair.h" -#include "my_page.h" -#include namespace LAMMPS_NS { diff --git a/src/USER-MISC/pair_e3b.cpp b/src/USER-MISC/pair_e3b.cpp index 43b472594a..aa19849baa 100644 --- a/src/USER-MISC/pair_e3b.cpp +++ b/src/USER-MISC/pair_e3b.cpp @@ -14,16 +14,14 @@ contact: stevene.strong at gmail dot com ------------------------------------------------------------------------- */ -#include -#include -#include -#include - #include "pair_e3b.h" +#include +#include +#include +#include #include "atom.h" #include "neighbor.h" -#include "neigh_request.h" #include "neigh_list.h" #include "force.h" #include "comm.h" diff --git a/src/USER-MISC/pair_edip.cpp b/src/USER-MISC/pair_edip.cpp index 0b5220fdfd..8dee4a606b 100644 --- a/src/USER-MISC/pair_edip.cpp +++ b/src/USER-MISC/pair_edip.cpp @@ -21,12 +21,12 @@ Phys. Rev. B 58, 2539 (1998) ------------------------------------------------------------------------- */ +#include "pair_edip.h" +#include #include #include -#include #include #include -#include "pair_edip.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-MISC/pair_edip_multi.cpp b/src/USER-MISC/pair_edip_multi.cpp index ab48fbaa73..9f953610de 100644 --- a/src/USER-MISC/pair_edip_multi.cpp +++ b/src/USER-MISC/pair_edip_multi.cpp @@ -17,12 +17,11 @@ Contributing author: Chao Jiang ------------------------------------------------------------------------- */ +#include "pair_edip_multi.h" +#include #include -#include -#include #include #include -#include "pair_edip_multi.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-MISC/pair_extep.cpp b/src/USER-MISC/pair_extep.cpp index bd5da71f4a..8507fd49f6 100644 --- a/src/USER-MISC/pair_extep.cpp +++ b/src/USER-MISC/pair_extep.cpp @@ -15,12 +15,12 @@ Contributing author: Jan Los ------------------------------------------------------------------------- */ +#include "pair_extep.h" +#include #include -#include #include #include #include -#include "pair_extep.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-MISC/pair_extep.h b/src/USER-MISC/pair_extep.h index 535e7261e3..1f127b71e0 100644 --- a/src/USER-MISC/pair_extep.h +++ b/src/USER-MISC/pair_extep.h @@ -21,7 +21,6 @@ PairStyle(extep,PairExTeP) #define LMP_PAIR_EXTEP_H #include "pair.h" -#include "my_page.h" #define MAXTYPES 8 #define NSPLINE 5 diff --git a/src/USER-MISC/pair_gauss_cut.cpp b/src/USER-MISC/pair_gauss_cut.cpp index 24d0b191d8..e6cfc02f63 100644 --- a/src/USER-MISC/pair_gauss_cut.cpp +++ b/src/USER-MISC/pair_gauss_cut.cpp @@ -15,18 +15,13 @@ Contributing authors: Arben Jusufi, Axel Kohlmeyer (Temple U.) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_gauss_cut.h" +#include +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" -#include "update.h" -#include "integrate.h" #include "memory.h" #include "error.h" #include "math_const.h" diff --git a/src/USER-MISC/pair_ilp_graphene_hbn.cpp b/src/USER-MISC/pair_ilp_graphene_hbn.cpp index a41c660b7b..b94db6a871 100644 --- a/src/USER-MISC/pair_ilp_graphene_hbn.cpp +++ b/src/USER-MISC/pair_ilp_graphene_hbn.cpp @@ -20,12 +20,11 @@ [Kolmogorov & Crespi, Phys. Rev. B 71, 235415 (2005)] ------------------------------------------------------------------------- */ +#include "pair_ilp_graphene_hbn.h" #include #include -#include #include #include -#include "pair_ilp_graphene_hbn.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_ilp_graphene_hbn.h b/src/USER-MISC/pair_ilp_graphene_hbn.h index 07c3b2e97b..ae4662cdc5 100644 --- a/src/USER-MISC/pair_ilp_graphene_hbn.h +++ b/src/USER-MISC/pair_ilp_graphene_hbn.h @@ -21,8 +21,6 @@ PairStyle(ilp/graphene/hbn,PairILPGrapheneHBN) #define LMP_PAIR_ILP_GRAPHENE_HBN_H #include "pair.h" -#include "my_page.h" -#include namespace LAMMPS_NS { diff --git a/src/USER-MISC/pair_kolmogorov_crespi_full.cpp b/src/USER-MISC/pair_kolmogorov_crespi_full.cpp index e73278968d..0009531ca8 100644 --- a/src/USER-MISC/pair_kolmogorov_crespi_full.cpp +++ b/src/USER-MISC/pair_kolmogorov_crespi_full.cpp @@ -20,12 +20,11 @@ [Kolmogorov & Crespi, Phys. Rev. B 71, 235415 (2005)] ------------------------------------------------------------------------- */ +#include "pair_kolmogorov_crespi_full.h" #include -#include #include #include #include -#include "pair_kolmogorov_crespi_full.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_kolmogorov_crespi_full.h b/src/USER-MISC/pair_kolmogorov_crespi_full.h index 9923b409a7..68dede0dd5 100644 --- a/src/USER-MISC/pair_kolmogorov_crespi_full.h +++ b/src/USER-MISC/pair_kolmogorov_crespi_full.h @@ -21,8 +21,6 @@ PairStyle(kolmogorov/crespi/full,PairKolmogorovCrespiFull) #define LMP_PAIR_KolmogorovCrespi_FULL_H #include "pair.h" -#include "my_page.h" -#include namespace LAMMPS_NS { diff --git a/src/USER-MISC/pair_kolmogorov_crespi_z.cpp b/src/USER-MISC/pair_kolmogorov_crespi_z.cpp index 79d6aa3daf..61c326ac87 100644 --- a/src/USER-MISC/pair_kolmogorov_crespi_z.cpp +++ b/src/USER-MISC/pair_kolmogorov_crespi_z.cpp @@ -21,11 +21,11 @@ The simplification is that all normals are taken along the z-direction ------------------------------------------------------------------------- */ +#include "pair_kolmogorov_crespi_z.h" +#include #include -#include #include #include -#include "pair_kolmogorov_crespi_z.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_lebedeva_z.cpp b/src/USER-MISC/pair_lebedeva_z.cpp index c9d90e2850..8930042cef 100644 --- a/src/USER-MISC/pair_lebedeva_z.cpp +++ b/src/USER-MISC/pair_lebedeva_z.cpp @@ -22,11 +22,11 @@ [Lebedeva et al., Physica E, 44(6), 949-954, 2012.] ------------------------------------------------------------------------- */ +#include "pair_lebedeva_z.h" +#include #include -#include #include #include -#include "pair_lebedeva_z.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_lennard_mdf.cpp b/src/USER-MISC/pair_lennard_mdf.cpp index e2e81e4943..50f59107a0 100644 --- a/src/USER-MISC/pair_lennard_mdf.cpp +++ b/src/USER-MISC/pair_lennard_mdf.cpp @@ -16,15 +16,13 @@ Contributing author: Paolo Raiteri (Curtin University) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lennard_mdf.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MISC/pair_list.cpp b/src/USER-MISC/pair_list.cpp index 562a60aa99..2f4e886a61 100644 --- a/src/USER-MISC/pair_list.cpp +++ b/src/USER-MISC/pair_list.cpp @@ -16,18 +16,14 @@ ------------------------------------------------------------------------- */ #include "pair_list.h" -#include "atom.h" -#include "comm.h" -#include "domain.h" -#include "force.h" -#include "memory.h" - -#include "error.h" - -#include -#include +#include #include #include +#include "atom.h" +#include "comm.h" +#include "force.h" +#include "memory.h" +#include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-MISC/pair_lj_expand_coul_long.cpp b/src/USER-MISC/pair_lj_expand_coul_long.cpp index fe21538f2d..ffa828826f 100644 --- a/src/USER-MISC/pair_lj_expand_coul_long.cpp +++ b/src/USER-MISC/pair_lj_expand_coul_long.cpp @@ -15,17 +15,15 @@ Contributing author: Trung Nguyen (Northwestern) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_expand_coul_long.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "kspace.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-MISC/pair_lj_mdf.cpp b/src/USER-MISC/pair_lj_mdf.cpp index cfe125f21f..3fe0fa6bf9 100644 --- a/src/USER-MISC/pair_lj_mdf.cpp +++ b/src/USER-MISC/pair_lj_mdf.cpp @@ -16,15 +16,13 @@ Contributing author: Paolo Raiteri (Curtin University) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_lj_mdf.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MISC/pair_lj_sf_dipole_sf.cpp b/src/USER-MISC/pair_lj_sf_dipole_sf.cpp index af7d23370d..758962ce29 100644 --- a/src/USER-MISC/pair_lj_sf_dipole_sf.cpp +++ b/src/USER-MISC/pair_lj_sf_dipole_sf.cpp @@ -16,10 +16,10 @@ Samuel Genheden (University of Southampton) ------------------------------------------------------------------------- */ -#include -#include -#include #include "pair_lj_sf_dipole_sf.h" +#include +#include +#include #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-MISC/pair_meam_spline.cpp b/src/USER-MISC/pair_meam_spline.cpp index f09919ce0f..79e7ac7e09 100644 --- a/src/USER-MISC/pair_meam_spline.cpp +++ b/src/USER-MISC/pair_meam_spline.cpp @@ -31,15 +31,13 @@ conform with pairing, updated to LAMMPS style ------------------------------------------------------------------------- */ +#include "pair_meam_spline.h" #include -#include #include #include -#include "pair_meam_spline.h" #include "atom.h" #include "force.h" #include "comm.h" -#include "memory.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/USER-MISC/pair_meam_sw_spline.cpp b/src/USER-MISC/pair_meam_sw_spline.cpp index af1e8788bd..eeadacf33a 100644 --- a/src/USER-MISC/pair_meam_sw_spline.cpp +++ b/src/USER-MISC/pair_meam_sw_spline.cpp @@ -23,15 +23,13 @@ * 01-Aug-12 - RER: First code version. ------------------------------------------------------------------------- */ +#include "pair_meam_sw_spline.h" #include -#include #include #include -#include "pair_meam_sw_spline.h" #include "atom.h" #include "force.h" #include "comm.h" -#include "memory.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/USER-MISC/pair_momb.cpp b/src/USER-MISC/pair_momb.cpp index 1716149a98..29d5715302 100644 --- a/src/USER-MISC/pair_momb.cpp +++ b/src/USER-MISC/pair_momb.cpp @@ -16,10 +16,9 @@ Ya Zhou (Penn State University) ------------------------------------------------------------------------- */ -#include -#include -#include #include "pair_momb.h" +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_morse_smooth_linear.cpp b/src/USER-MISC/pair_morse_smooth_linear.cpp index 7c7973f830..c3cbe39db7 100644 --- a/src/USER-MISC/pair_morse_smooth_linear.cpp +++ b/src/USER-MISC/pair_morse_smooth_linear.cpp @@ -11,11 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_morse_smooth_linear.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_srp.cpp b/src/USER-MISC/pair_srp.cpp index 01deaf0fbe..416ace8132 100644 --- a/src/USER-MISC/pair_srp.cpp +++ b/src/USER-MISC/pair_srp.cpp @@ -25,9 +25,11 @@ There is an example script for this package in examples/USER/srp. Please contact Timothy Sirk for questions (tim.sirk@us.army.mil). ------------------------------------------------------------------------- */ +#include "pair_srp.h" +#include +#include #include #include -#include "pair_srp.h" #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MISC/pair_tersoff_table.cpp b/src/USER-MISC/pair_tersoff_table.cpp index e0985d1dce..5c4f60f354 100644 --- a/src/USER-MISC/pair_tersoff_table.cpp +++ b/src/USER-MISC/pair_tersoff_table.cpp @@ -20,11 +20,11 @@ 1) Tersoff, Phys. Rev. B 39, 5566 (1988) ------------------------------------------------------------------------- */ +#include "pair_tersoff_table.h" +#include #include -#include #include #include -#include "pair_tersoff_table.h" #include "atom.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-MISC/temper_grem.cpp b/src/USER-MISC/temper_grem.cpp index 031a449689..d0e2fa5606 100644 --- a/src/USER-MISC/temper_grem.cpp +++ b/src/USER-MISC/temper_grem.cpp @@ -15,26 +15,21 @@ Contributing author: David Stelter (BU) ------------------------------------------------------------------------- */ -#include -#include -#include #include "temper_grem.h" +#include +#include #include "fix_grem.h" #include "universe.h" #include "domain.h" -#include "atom.h" #include "update.h" #include "integrate.h" #include "modify.h" #include "compute.h" #include "force.h" -#include "output.h" -#include "thermo.h" #include "fix.h" #include "random_park.h" #include "finish.h" #include "timer.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-MISC/temper_npt.cpp b/src/USER-MISC/temper_npt.cpp index 7cf8fbab9b..9fd4bd6d06 100644 --- a/src/USER-MISC/temper_npt.cpp +++ b/src/USER-MISC/temper_npt.cpp @@ -17,10 +17,9 @@ Contact Email: amulyapervaje@gmail.com ------------------------------------------------------------------------- */ -#include -#include -#include #include "temper_npt.h" +#include +#include #include "universe.h" #include "domain.h" #include "atom.h" @@ -29,13 +28,10 @@ #include "modify.h" #include "compute.h" #include "force.h" -#include "output.h" -#include "thermo.h" #include "fix.h" #include "random_park.h" #include "finish.h" #include "timer.h" -#include "memory.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-MOFFF/angle_class2_p6.cpp b/src/USER-MOFFF/angle_class2_p6.cpp index e8e6f279de..bb0a01d546 100644 --- a/src/USER-MOFFF/angle_class2_p6.cpp +++ b/src/USER-MOFFF/angle_class2_p6.cpp @@ -16,10 +16,10 @@ and Rochus Schmid (Ruhr-Universitaet Bochum) ------------------------------------------------------------------------- */ +#include "angle_class2_p6.h" +#include #include #include -#include -#include "angle_class2_p6.h" #include "atom.h" #include "neighbor.h" #include "domain.h" diff --git a/src/USER-MOFFF/angle_cosine_buck6d.cpp b/src/USER-MOFFF/angle_cosine_buck6d.cpp index 3829d2b8dc..c17b2a1dba 100644 --- a/src/USER-MOFFF/angle_cosine_buck6d.cpp +++ b/src/USER-MOFFF/angle_cosine_buck6d.cpp @@ -16,9 +16,9 @@ and Rochus Schmid (Ruhr-Universitaet Bochum) ------------------------------------------------------------------------- */ -#include -#include #include "angle_cosine_buck6d.h" +#include +#include #include "atom.h" #include "neighbor.h" #include "domain.h" @@ -26,13 +26,11 @@ #include "force.h" #include "pair.h" #include "math_const.h" -#include "math_special.h" #include "memory.h" #include "error.h" using namespace LAMMPS_NS; using namespace MathConst; -using namespace MathSpecial; #define SMALL 0.001 diff --git a/src/USER-MOFFF/improper_inversion_harmonic.cpp b/src/USER-MOFFF/improper_inversion_harmonic.cpp index 3f1e61e54a..12f7062ccc 100644 --- a/src/USER-MOFFF/improper_inversion_harmonic.cpp +++ b/src/USER-MOFFF/improper_inversion_harmonic.cpp @@ -19,17 +19,13 @@ [ abbreviated from and verified via DLPOLY2.0 ] ------------------------------------------------------------------------- */ +#include "improper_inversion_harmonic.h" #include #include -#include -#include -#include "improper_inversion_harmonic.h" #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" -#include "update.h" #include "math_const.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MOFFF/pair_buck6d_coul_gauss_dsf.cpp b/src/USER-MOFFF/pair_buck6d_coul_gauss_dsf.cpp index 282bb0c58f..9c917d1c19 100644 --- a/src/USER-MOFFF/pair_buck6d_coul_gauss_dsf.cpp +++ b/src/USER-MOFFF/pair_buck6d_coul_gauss_dsf.cpp @@ -18,11 +18,9 @@ Fennell and Gezelter, JCP 124, 234104 (2006) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_buck6d_coul_gauss_dsf.h" +#include +#include #include "atom.h" #include "comm.h" #include "force.h" diff --git a/src/USER-MOFFF/pair_buck6d_coul_gauss_long.cpp b/src/USER-MOFFF/pair_buck6d_coul_gauss_long.cpp index d6a4121d21..953507ce21 100644 --- a/src/USER-MOFFF/pair_buck6d_coul_gauss_long.cpp +++ b/src/USER-MOFFF/pair_buck6d_coul_gauss_long.cpp @@ -17,11 +17,10 @@ References: Bureekaew and Schmid, Phys. Status Solidi B 250, 1128 (2013) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "pair_buck6d_coul_gauss_long.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" @@ -29,12 +28,10 @@ #include "neighbor.h" #include "neigh_list.h" #include "memory.h" -#include "math_const.h" #include "error.h" #include "math_special.h" using namespace LAMMPS_NS; -using namespace MathConst; #define EWALD_F 1.12837917 diff --git a/src/USER-PTM/compute_ptm_atom.cpp b/src/USER-PTM/compute_ptm_atom.cpp index 41e6540b97..ad3d3facdb 100644 --- a/src/USER-PTM/compute_ptm_atom.cpp +++ b/src/USER-PTM/compute_ptm_atom.cpp @@ -16,15 +16,14 @@ under Contributing author: PM Larsen (MIT) ------------------------------------------------------------------------- */ +#include "compute_ptm_atom.h" #include #include -#include #include #include #include "atom.h" #include "comm.h" -#include "compute_ptm_atom.h" #include "error.h" #include "force.h" #include "memory.h" @@ -32,7 +31,6 @@ under #include "neigh_list.h" #include "neigh_request.h" #include "neighbor.h" -#include "pair.h" #include "update.h" #include "ptm_functions.h" diff --git a/src/USER-PTM/ptm_convex_hull_incremental.cpp b/src/USER-PTM/ptm_convex_hull_incremental.cpp index 45643ec515..8dd06e8168 100644 --- a/src/USER-PTM/ptm_convex_hull_incremental.cpp +++ b/src/USER-PTM/ptm_convex_hull_incremental.cpp @@ -11,7 +11,6 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #include #include #include -#include #include "ptm_convex_hull_incremental.h" #include "ptm_constants.h" diff --git a/src/USER-PTM/ptm_index.cpp b/src/USER-PTM/ptm_index.cpp index 3068e7a7f6..b50e5c4333 100644 --- a/src/USER-PTM/ptm_index.cpp +++ b/src/USER-PTM/ptm_index.cpp @@ -12,19 +12,15 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #include "ptm_convex_hull_incremental.h" #include "ptm_deformation_gradient.h" #include "ptm_functions.h" -#include "ptm_graph_data.h" #include "ptm_initialize_data.h" #include "ptm_neighbour_ordering.h" #include "ptm_normalize_vertices.h" #include "ptm_polar.h" #include "ptm_quat.h" #include "ptm_structure_matcher.h" -#include #include -#include #include #include -#include #include static double calculate_interatomic_distance(int type, double scale) { diff --git a/src/USER-PTM/ptm_initialize_data.cpp b/src/USER-PTM/ptm_initialize_data.cpp index 49dc6f2323..1f0a5c94af 100644 --- a/src/USER-PTM/ptm_initialize_data.cpp +++ b/src/USER-PTM/ptm_initialize_data.cpp @@ -7,14 +7,8 @@ The above copyright notice and this permission notice shall be included in all c THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -#include -#include -#include -#include -#include -#include -#include #include "ptm_initialize_data.h" +#include static void make_facets_clockwise(int num_facets, int8_t (*facets)[3], const double (*points)[3]) diff --git a/src/USER-PTM/ptm_neighbour_ordering.cpp b/src/USER-PTM/ptm_neighbour_ordering.cpp index cb72a43711..1332b8819b 100644 --- a/src/USER-PTM/ptm_neighbour_ordering.cpp +++ b/src/USER-PTM/ptm_neighbour_ordering.cpp @@ -9,16 +9,15 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI //todo: normalize vertices -#include +#include "ptm_neighbour_ordering.h" #include #include #include #include #include +#include #include "ptm_constants.h" #include "ptm_voronoi_cell.h" -#include "ptm_neighbour_ordering.h" -#include "ptm_normalize_vertices.h" namespace ptm { diff --git a/src/USER-PTM/ptm_polar.h b/src/USER-PTM/ptm_polar.h index e03963048b..f11dd98ee9 100644 --- a/src/USER-PTM/ptm_polar.h +++ b/src/USER-PTM/ptm_polar.h @@ -11,7 +11,6 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #define PTM_POLAR_H #include -#include namespace ptm { diff --git a/src/USER-PTM/ptm_quat.cpp b/src/USER-PTM/ptm_quat.cpp index 4a93499b3a..527f4d1116 100644 --- a/src/USER-PTM/ptm_quat.cpp +++ b/src/USER-PTM/ptm_quat.cpp @@ -7,9 +7,9 @@ The above copyright notice and this permission notice shall be included in all c THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +#include "ptm_quat.h" #include #include -#include #include diff --git a/src/USER-PTM/ptm_voronoi_cell.cpp b/src/USER-PTM/ptm_voronoi_cell.cpp index dfe61eb24f..dc4ce4e747 100644 --- a/src/USER-PTM/ptm_voronoi_cell.cpp +++ b/src/USER-PTM/ptm_voronoi_cell.cpp @@ -52,7 +52,7 @@ such enhancements or derivative works thereof, in binary and source code form. * \brief Function implementations for the voronoicell and related classes. */ #include -#include +#include #include #include "ptm_voronoi_config.h" #include "ptm_voronoi_cell.h" diff --git a/src/USER-PTM/ptm_voronoi_cell.h b/src/USER-PTM/ptm_voronoi_cell.h index eb091dd36b..69e3b5bdc4 100644 --- a/src/USER-PTM/ptm_voronoi_cell.h +++ b/src/USER-PTM/ptm_voronoi_cell.h @@ -56,9 +56,6 @@ such enhancements or derivative works thereof, in binary and source code form. #define PTM_VOROPP_CELL_HH #include -#include - -#include "ptm_voronoi_config.h" namespace ptm_voro { diff --git a/src/USER-SMD/atom_vec_smd.cpp b/src/USER-SMD/atom_vec_smd.cpp index 93a6f1308f..604504c5a7 100644 --- a/src/USER-SMD/atom_vec_smd.cpp +++ b/src/USER-SMD/atom_vec_smd.cpp @@ -23,21 +23,18 @@ ------------------------------------------------------------------------- */ #include "atom_vec_smd.h" -#include #include #include "atom.h" #include "comm.h" #include "domain.h" #include "modify.h" #include "fix.h" -#include "fix_adapt.h" -#include "math_const.h" #include "memory.h" #include "error.h" #include "utils.h" using namespace LAMMPS_NS; -using namespace MathConst; + #define NMAT_FULL 9 #define NMAT_SYMM 6 diff --git a/src/USER-SMD/compute_smd_contact_radius.cpp b/src/USER-SMD/compute_smd_contact_radius.cpp index 8193ad6ccf..46cbc602f2 100644 --- a/src/USER-SMD/compute_smd_contact_radius.cpp +++ b/src/USER-SMD/compute_smd_contact_radius.cpp @@ -23,13 +23,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_smd_contact_radius.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/compute_smd_damage.cpp b/src/USER-SMD/compute_smd_damage.cpp index 9603fd5c64..96a936cd82 100644 --- a/src/USER-SMD/compute_smd_damage.cpp +++ b/src/USER-SMD/compute_smd_damage.cpp @@ -23,13 +23,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_smd_damage.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/compute_smd_internal_energy.cpp b/src/USER-SMD/compute_smd_internal_energy.cpp index d937aa98a4..f88da8bc33 100644 --- a/src/USER-SMD/compute_smd_internal_energy.cpp +++ b/src/USER-SMD/compute_smd_internal_energy.cpp @@ -29,7 +29,6 @@ #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/compute_smd_plastic_strain.cpp b/src/USER-SMD/compute_smd_plastic_strain.cpp index 67466ebb72..c1c001a5dd 100644 --- a/src/USER-SMD/compute_smd_plastic_strain.cpp +++ b/src/USER-SMD/compute_smd_plastic_strain.cpp @@ -23,13 +23,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_smd_plastic_strain.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/compute_smd_plastic_strain_rate.cpp b/src/USER-SMD/compute_smd_plastic_strain_rate.cpp index 20dfa64edd..272a2c59e5 100644 --- a/src/USER-SMD/compute_smd_plastic_strain_rate.cpp +++ b/src/USER-SMD/compute_smd_plastic_strain_rate.cpp @@ -23,13 +23,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_smd_plastic_strain_rate.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/compute_smd_rho.cpp b/src/USER-SMD/compute_smd_rho.cpp index 5c78e604b6..d9c0a99b07 100644 --- a/src/USER-SMD/compute_smd_rho.cpp +++ b/src/USER-SMD/compute_smd_rho.cpp @@ -22,13 +22,12 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_smd_rho.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/compute_smd_tlsph_defgrad.cpp b/src/USER-SMD/compute_smd_tlsph_defgrad.cpp index 37ad78dcea..09aeeea74a 100644 --- a/src/USER-SMD/compute_smd_tlsph_defgrad.cpp +++ b/src/USER-SMD/compute_smd_tlsph_defgrad.cpp @@ -22,20 +22,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include #include "compute_smd_tlsph_defgrad.h" +#include +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" -#include "pair.h" + using namespace Eigen; using namespace std; using namespace LAMMPS_NS; diff --git a/src/USER-SMD/compute_smd_tlsph_shape.cpp b/src/USER-SMD/compute_smd_tlsph_shape.cpp index bbab274b5c..ba1a9306ef 100644 --- a/src/USER-SMD/compute_smd_tlsph_shape.cpp +++ b/src/USER-SMD/compute_smd_tlsph_shape.cpp @@ -22,13 +22,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include -#include #include "compute_smd_tlsph_shape.h" +#include +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/USER-SMD/compute_smd_tlsph_strain.cpp b/src/USER-SMD/compute_smd_tlsph_strain.cpp index a94a3cd511..f0061bf7a1 100644 --- a/src/USER-SMD/compute_smd_tlsph_strain.cpp +++ b/src/USER-SMD/compute_smd_tlsph_strain.cpp @@ -23,12 +23,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include #include "compute_smd_tlsph_strain.h" +#include +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/USER-SMD/compute_smd_tlsph_stress.cpp b/src/USER-SMD/compute_smd_tlsph_stress.cpp index a54b07dd1e..9c78b192ce 100644 --- a/src/USER-SMD/compute_smd_tlsph_stress.cpp +++ b/src/USER-SMD/compute_smd_tlsph_stress.cpp @@ -22,9 +22,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_smd_tlsph_stress.h" +#include #include #include -#include "compute_smd_tlsph_stress.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/USER-SMD/compute_smd_triangle_vertices.cpp b/src/USER-SMD/compute_smd_triangle_vertices.cpp index b24223b8b5..06706a85ad 100644 --- a/src/USER-SMD/compute_smd_triangle_vertices.cpp +++ b/src/USER-SMD/compute_smd_triangle_vertices.cpp @@ -23,22 +23,15 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include #include "compute_smd_triangle_vertices.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" -#include "pair.h" -using namespace Eigen; using namespace std; using namespace LAMMPS_NS; diff --git a/src/USER-SMD/compute_smd_ulsph_strain.cpp b/src/USER-SMD/compute_smd_ulsph_strain.cpp index 89b85f7bc1..cf1535759c 100644 --- a/src/USER-SMD/compute_smd_ulsph_strain.cpp +++ b/src/USER-SMD/compute_smd_ulsph_strain.cpp @@ -23,22 +23,15 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include #include "compute_smd_ulsph_strain.h" +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" -#include "pair.h" -using namespace Eigen; using namespace std; using namespace LAMMPS_NS; diff --git a/src/USER-SMD/compute_smd_ulsph_stress.cpp b/src/USER-SMD/compute_smd_ulsph_stress.cpp index 7f1bbc4c29..ea477375ce 100644 --- a/src/USER-SMD/compute_smd_ulsph_stress.cpp +++ b/src/USER-SMD/compute_smd_ulsph_stress.cpp @@ -22,9 +22,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "compute_smd_ulsph_stress.h" +#include #include #include -#include "compute_smd_ulsph_stress.h" #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/USER-SMD/compute_smd_vol.cpp b/src/USER-SMD/compute_smd_vol.cpp index 17a6b556e8..eb1f144275 100644 --- a/src/USER-SMD/compute_smd_vol.cpp +++ b/src/USER-SMD/compute_smd_vol.cpp @@ -22,13 +22,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "compute_smd_vol.h" +#include +#include #include "atom.h" #include "update.h" #include "modify.h" #include "comm.h" -#include "force.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/fix_smd_adjust_dt.cpp b/src/USER-SMD/fix_smd_adjust_dt.cpp index f015c6c4df..ab6dd5ef5c 100644 --- a/src/USER-SMD/fix_smd_adjust_dt.cpp +++ b/src/USER-SMD/fix_smd_adjust_dt.cpp @@ -22,21 +22,14 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_smd_adjust_dt.h" -#include "atom.h" +#include +#include #include "update.h" -#include "integrate.h" -#include "domain.h" -#include "lattice.h" #include "force.h" #include "pair.h" #include "modify.h" #include "fix.h" -#include "output.h" -#include "dump.h" #include "comm.h" #include "error.h" diff --git a/src/USER-SMD/fix_smd_integrate_tlsph.cpp b/src/USER-SMD/fix_smd_integrate_tlsph.cpp index f931ae94ff..8464bed609 100644 --- a/src/USER-SMD/fix_smd_integrate_tlsph.cpp +++ b/src/USER-SMD/fix_smd_integrate_tlsph.cpp @@ -22,22 +22,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include #include "fix_smd_integrate_tlsph.h" +#include +#include +#include #include "atom.h" #include "force.h" #include "update.h" #include "error.h" #include "pair.h" -#include "neigh_list.h" -#include "domain.h" -#include "neighbor.h" #include "comm.h" -#include "modify.h" using namespace Eigen; using namespace LAMMPS_NS; diff --git a/src/USER-SMD/fix_smd_integrate_ulsph.cpp b/src/USER-SMD/fix_smd_integrate_ulsph.cpp index 6c4705eb96..0f0d224f95 100644 --- a/src/USER-SMD/fix_smd_integrate_ulsph.cpp +++ b/src/USER-SMD/fix_smd_integrate_ulsph.cpp @@ -22,25 +22,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include +#include "fix_smd_integrate_ulsph.h" #include -#include #include #include -#include "fix_smd_integrate_ulsph.h" #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "update.h" -#include "integrate.h" -#include "respa.h" -#include "memory.h" #include "error.h" #include "pair.h" -#include "domain.h" using namespace Eigen; using namespace LAMMPS_NS; diff --git a/src/USER-SMD/fix_smd_move_triangulated_surface.cpp b/src/USER-SMD/fix_smd_move_triangulated_surface.cpp index fe8695b23e..cbaad9ac4c 100644 --- a/src/USER-SMD/fix_smd_move_triangulated_surface.cpp +++ b/src/USER-SMD/fix_smd_move_triangulated_surface.cpp @@ -22,25 +22,15 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include #include "fix_smd_move_triangulated_surface.h" +#include +#include +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" #include "update.h" -#include "integrate.h" -#include "respa.h" -#include "memory.h" #include "error.h" -#include "pair.h" -#include "domain.h" #include "math_const.h" using namespace Eigen; diff --git a/src/USER-SMD/fix_smd_setvel.cpp b/src/USER-SMD/fix_smd_setvel.cpp index 4bc8b5127b..2964ded544 100644 --- a/src/USER-SMD/fix_smd_setvel.cpp +++ b/src/USER-SMD/fix_smd_setvel.cpp @@ -23,9 +23,9 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "fix_smd_setvel.h" +#include +#include #include "atom.h" #include "update.h" #include "modify.h" diff --git a/src/USER-SMD/fix_smd_tlsph_reference_configuration.cpp b/src/USER-SMD/fix_smd_tlsph_reference_configuration.cpp index a2813cc3ca..6aa23fe3b2 100644 --- a/src/USER-SMD/fix_smd_tlsph_reference_configuration.cpp +++ b/src/USER-SMD/fix_smd_tlsph_reference_configuration.cpp @@ -24,20 +24,16 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_smd_tlsph_reference_configuration.h" +#include +#include #include "atom.h" #include "comm.h" -#include "neighbor.h" #include "neigh_list.h" #include "lattice.h" #include "force.h" #include "pair.h" #include "update.h" -#include "modify.h" #include "memory.h" #include "error.h" #include "domain.h" diff --git a/src/USER-SMD/fix_smd_tlsph_reference_configuration.h b/src/USER-SMD/fix_smd_tlsph_reference_configuration.h index 8549621c2f..5f952bde93 100644 --- a/src/USER-SMD/fix_smd_tlsph_reference_configuration.h +++ b/src/USER-SMD/fix_smd_tlsph_reference_configuration.h @@ -35,7 +35,6 @@ FixStyle(SMD_TLSPH_NEIGHBORS,FixSMD_TLSPH_ReferenceConfiguration) #define LMP_FIX_SMD_TLSPH_REFERENCE_H #include "fix.h" -#include "my_page.h" namespace LAMMPS_NS { diff --git a/src/USER-SMD/fix_smd_wall_surface.cpp b/src/USER-SMD/fix_smd_wall_surface.cpp index a37ba67a80..9183bcd9ea 100644 --- a/src/USER-SMD/fix_smd_wall_surface.cpp +++ b/src/USER-SMD/fix_smd_wall_surface.cpp @@ -15,21 +15,15 @@ Contributing authors: Mike Parks (SNL), Ezwanur Rahman, J.T. Foster (UTSA) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_smd_wall_surface.h" +#include +#include +#include +#include #include "atom.h" #include "domain.h" #include "force.h" #include "comm.h" -#include "update.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "pair.h" -#include "lattice.h" #include "memory.h" #include "error.h" #include "atom_vec.h" diff --git a/src/USER-SMD/pair_smd_hertz.cpp b/src/USER-SMD/pair_smd_hertz.cpp index 541be9f05c..97be94d833 100644 --- a/src/USER-SMD/pair_smd_hertz.cpp +++ b/src/USER-SMD/pair_smd_hertz.cpp @@ -26,17 +26,14 @@ Contributing author: Mike Parks (SNL) ------------------------------------------------------------------------- */ +#include "pair_smd_hertz.h" +#include #include -#include #include #include -#include "pair_smd_hertz.h" #include "atom.h" #include "domain.h" #include "force.h" -#include "update.h" -#include "modify.h" -#include "fix.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-SMD/pair_smd_tlsph.cpp b/src/USER-SMD/pair_smd_tlsph.cpp index 1d7bbca780..0dff905962 100644 --- a/src/USER-SMD/pair_smd_tlsph.cpp +++ b/src/USER-SMD/pair_smd_tlsph.cpp @@ -22,15 +22,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include -#include -#include -#include #include "pair_smd_tlsph.h" +#include +#include +#include +#include +#include +#include #include "fix_smd_tlsph_reference_configuration.h" #include "atom.h" #include "domain.h" @@ -41,12 +39,9 @@ #include "fix.h" #include "comm.h" #include "neighbor.h" -#include "neigh_list.h" #include "neigh_request.h" #include "memory.h" #include "error.h" -#include "math_special.h" -#include "update.h" #include "smd_material_models.h" #include "smd_kernels.h" #include "smd_math.h" diff --git a/src/USER-SMD/pair_smd_triangulated_surface.cpp b/src/USER-SMD/pair_smd_triangulated_surface.cpp index d3a4983379..f9052be087 100644 --- a/src/USER-SMD/pair_smd_triangulated_surface.cpp +++ b/src/USER-SMD/pair_smd_triangulated_surface.cpp @@ -26,20 +26,15 @@ Contributing author: Mike Parks (SNL) ------------------------------------------------------------------------- */ +#include "pair_smd_triangulated_surface.h" +#include #include -#include #include #include -#include -#include #include -#include "pair_smd_triangulated_surface.h" #include "atom.h" #include "domain.h" #include "force.h" -#include "update.h" -#include "modify.h" -#include "fix.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-SMD/pair_smd_ulsph.cpp b/src/USER-SMD/pair_smd_ulsph.cpp index 2c4a2de989..9e824ded3c 100644 --- a/src/USER-SMD/pair_smd_ulsph.cpp +++ b/src/USER-SMD/pair_smd_ulsph.cpp @@ -22,19 +22,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include -#include -#include -#include #include "pair_smd_ulsph.h" +#include +#include #include "atom.h" #include "domain.h" #include "force.h" #include "update.h" -#include "modify.h" -#include "fix.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" diff --git a/src/USER-SMD/smd_material_models.cpp b/src/USER-SMD/smd_material_models.cpp index 4213428872..5ee67fbb4e 100644 --- a/src/USER-SMD/smd_material_models.cpp +++ b/src/USER-SMD/smd_material_models.cpp @@ -21,6 +21,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ +#include "smd_material_models.h" +#include +#include +#include #include #include #include "math_special.h" From d05787ab99994e3cb6533280265026e55679e8aa Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 07:16:53 -0400 Subject: [PATCH 64/79] clean up include in USER-REAXC --- src/USER-REAXC/compute_spec_atom.cpp | 8 +------- src/USER-REAXC/compute_spec_atom.h | 1 - src/USER-REAXC/fix_qeq_reax.cpp | 9 ++++----- src/USER-REAXC/fix_reaxc.cpp | 2 -- src/USER-REAXC/fix_reaxc_bonds.cpp | 12 ++---------- src/USER-REAXC/fix_reaxc_bonds.h | 1 - src/USER-REAXC/fix_reaxc_species.cpp | 12 ++++-------- src/USER-REAXC/fix_reaxc_species.h | 5 ----- src/USER-REAXC/pair_reaxc.cpp | 9 ++++++--- src/USER-REAXC/reaxc_allocate.cpp | 7 +++---- src/USER-REAXC/reaxc_bond_orders.cpp | 6 ++++-- src/USER-REAXC/reaxc_bonds.cpp | 7 +++---- src/USER-REAXC/reaxc_control.cpp | 4 ++-- src/USER-REAXC/reaxc_ffield.cpp | 8 +++++--- src/USER-REAXC/reaxc_ffield.h | 1 + src/USER-REAXC/reaxc_forces.cpp | 9 +++------ src/USER-REAXC/reaxc_hydrogen_bonds.cpp | 5 +++-- src/USER-REAXC/reaxc_init_md.cpp | 9 +++++---- src/USER-REAXC/reaxc_init_md.h | 2 +- src/USER-REAXC/reaxc_io_tools.cpp | 10 +++------- src/USER-REAXC/reaxc_list.cpp | 2 +- src/USER-REAXC/reaxc_lookup.cpp | 5 +++-- src/USER-REAXC/reaxc_lookup.h | 6 ++++-- src/USER-REAXC/reaxc_multi_body.cpp | 8 ++++---- src/USER-REAXC/reaxc_nonbonded.cpp | 7 ++++--- src/USER-REAXC/reaxc_reset_tools.cpp | 4 ++-- src/USER-REAXC/reaxc_system_props.cpp | 6 ++---- src/USER-REAXC/reaxc_system_props.h | 1 + src/USER-REAXC/reaxc_tool_box.cpp | 6 ++++-- src/USER-REAXC/reaxc_tool_box.h | 2 +- src/USER-REAXC/reaxc_torsion_angles.cpp | 6 +++--- src/USER-REAXC/reaxc_traj.cpp | 8 +++++--- src/USER-REAXC/reaxc_valence_angles.cpp | 5 +++-- src/USER-REAXC/reaxc_vector.cpp | 4 ++-- src/USER-REAXC/reaxc_vector.h | 2 -- 35 files changed, 89 insertions(+), 110 deletions(-) diff --git a/src/USER-REAXC/compute_spec_atom.cpp b/src/USER-REAXC/compute_spec_atom.cpp index 77b82b3e55..bc5b26b699 100644 --- a/src/USER-REAXC/compute_spec_atom.cpp +++ b/src/USER-REAXC/compute_spec_atom.cpp @@ -11,19 +11,13 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "compute_spec_atom.h" -#include "math_extra.h" +#include #include "atom.h" #include "update.h" #include "force.h" -#include "domain.h" #include "memory.h" #include "error.h" - -#include "reaxc_defs.h" -#include "reaxc_types.h" #include "pair_reaxc.h" using namespace LAMMPS_NS; diff --git a/src/USER-REAXC/compute_spec_atom.h b/src/USER-REAXC/compute_spec_atom.h index 4d5cb86d71..cf0aa0215d 100644 --- a/src/USER-REAXC/compute_spec_atom.h +++ b/src/USER-REAXC/compute_spec_atom.h @@ -21,7 +21,6 @@ ComputeStyle(SPEC/ATOM,ComputeSpecAtom) #define LMP_COMPUTE_SPEC_ATOM_H #include "compute.h" -#include "pointers.h" namespace LAMMPS_NS { diff --git a/src/USER-REAXC/fix_qeq_reax.cpp b/src/USER-REAXC/fix_qeq_reax.cpp index faa0632608..be6eccf764 100644 --- a/src/USER-REAXC/fix_qeq_reax.cpp +++ b/src/USER-REAXC/fix_qeq_reax.cpp @@ -18,15 +18,13 @@ Hybrid and sub-group capabilities: Ray Shan (Sandia) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_qeq_reax.h" +#include +#include +#include #include "pair_reaxc.h" #include "atom.h" #include "comm.h" -#include "domain.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" @@ -39,6 +37,7 @@ #include "citeme.h" #include "error.h" #include "reaxc_defs.h" +#include "reaxc_types.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-REAXC/fix_reaxc.cpp b/src/USER-REAXC/fix_reaxc.cpp index dc67ad6ffb..c98adf5b45 100644 --- a/src/USER-REAXC/fix_reaxc.cpp +++ b/src/USER-REAXC/fix_reaxc.cpp @@ -23,8 +23,6 @@ #include "fix_reaxc.h" #include "atom.h" -#include "pair.h" -#include "comm.h" #include "memory.h" using namespace LAMMPS_NS; diff --git a/src/USER-REAXC/fix_reaxc_bonds.cpp b/src/USER-REAXC/fix_reaxc_bonds.cpp index 9dc347826f..f7ad7ed6d4 100644 --- a/src/USER-REAXC/fix_reaxc_bonds.cpp +++ b/src/USER-REAXC/fix_reaxc_bonds.cpp @@ -15,22 +15,14 @@ Contributing author: Ray Shan (Sandia, tnshan@sandia.gov) ------------------------------------------------------------------------- */ -#include -#include -#include "fix_ave_atom.h" #include "fix_reaxc_bonds.h" +#include +#include #include "atom.h" #include "update.h" #include "pair_reaxc.h" -#include "modify.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" -#include "comm.h" #include "force.h" -#include "compute.h" -#include "input.h" -#include "variable.h" #include "memory.h" #include "error.h" #include "reaxc_list.h" diff --git a/src/USER-REAXC/fix_reaxc_bonds.h b/src/USER-REAXC/fix_reaxc_bonds.h index 60f41beb02..e83e01f1d5 100644 --- a/src/USER-REAXC/fix_reaxc_bonds.h +++ b/src/USER-REAXC/fix_reaxc_bonds.h @@ -21,7 +21,6 @@ FixStyle(reax/c/bonds,FixReaxCBonds) #define LMP_FIX_REAXC_BONDS_H #include "fix.h" -#include "pointers.h" namespace LAMMPS_NS { diff --git a/src/USER-REAXC/fix_reaxc_species.cpp b/src/USER-REAXC/fix_reaxc_species.cpp index 46426d484a..74692f1c9b 100644 --- a/src/USER-REAXC/fix_reaxc_species.cpp +++ b/src/USER-REAXC/fix_reaxc_species.cpp @@ -16,27 +16,23 @@ Oleg Sergeev (VNIIA, sergeev@vniia.ru) ------------------------------------------------------------------------- */ +#include "fix_reaxc_species.h" +#include #include -#include #include #include "fix_ave_atom.h" -#include "fix_reaxc_species.h" #include "atom.h" #include "domain.h" #include "update.h" -#include "pair_reaxc.h" #include "modify.h" #include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "comm.h" #include "force.h" -#include "compute.h" -#include "input.h" -#include "variable.h" #include "memory.h" #include "error.h" -#include "reaxc_list.h" +#include "pair_reaxc.h" +#include "reaxc_defs.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-REAXC/fix_reaxc_species.h b/src/USER-REAXC/fix_reaxc_species.h index 23a470fd0a..937af98527 100644 --- a/src/USER-REAXC/fix_reaxc_species.h +++ b/src/USER-REAXC/fix_reaxc_species.h @@ -21,11 +21,6 @@ FixStyle(reax/c/species,FixReaxCSpecies) #define LMP_FIX_REAXC_SPECIES_H #include "fix.h" -#include "pointers.h" - -#include "pair_reaxc.h" -#include "reaxc_types.h" -#include "reaxc_defs.h" #define BUFLEN 1000 diff --git a/src/USER-REAXC/pair_reaxc.cpp b/src/USER-REAXC/pair_reaxc.cpp index 224f3e2568..959405576e 100644 --- a/src/USER-REAXC/pair_reaxc.cpp +++ b/src/USER-REAXC/pair_reaxc.cpp @@ -20,8 +20,12 @@ Hybrid and hybrid/overlay compatibility added by Ray Shan (Sandia) ------------------------------------------------------------------------- */ -#include #include "pair_reaxc.h" +#include +#include +#include +#include +#include #include "atom.h" #include "update.h" #include "force.h" @@ -36,6 +40,7 @@ #include "memory.h" #include "error.h" +#include "reaxc_defs.h" #include "reaxc_types.h" #include "reaxc_allocate.h" #include "reaxc_control.h" @@ -46,9 +51,7 @@ #include "reaxc_list.h" #include "reaxc_lookup.h" #include "reaxc_reset_tools.h" -#include "reaxc_traj.h" #include "reaxc_vector.h" -#include "fix_reaxc_bonds.h" using namespace LAMMPS_NS; diff --git a/src/USER-REAXC/reaxc_allocate.cpp b/src/USER-REAXC/reaxc_allocate.cpp index 460f8aeb6a..6303db5619 100644 --- a/src/USER-REAXC/reaxc_allocate.cpp +++ b/src/USER-REAXC/reaxc_allocate.cpp @@ -24,14 +24,13 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_allocate.h" +#include +#include "reaxc_defs.h" #include "reaxc_list.h" -#include "reaxc_reset_tools.h" #include "reaxc_tool_box.h" -#include "reaxc_vector.h" -#if defined(_OPENMP) +#if defined(LMP_USER_OMP) && defined(_OPENMP) #include #endif diff --git a/src/USER-REAXC/reaxc_bond_orders.cpp b/src/USER-REAXC/reaxc_bond_orders.cpp index 1ed58a0bfd..869e796661 100644 --- a/src/USER-REAXC/reaxc_bond_orders.cpp +++ b/src/USER-REAXC/reaxc_bond_orders.cpp @@ -24,9 +24,11 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" -#include "reaxc_types.h" #include "reaxc_bond_orders.h" +#include +#include "pair.h" +#include "reaxc_defs.h" +#include "reaxc_types.h" #include "reaxc_list.h" #include "reaxc_vector.h" diff --git a/src/USER-REAXC/reaxc_bonds.cpp b/src/USER-REAXC/reaxc_bonds.cpp index 48fb872324..4cfd2a3c3a 100644 --- a/src/USER-REAXC/reaxc_bonds.cpp +++ b/src/USER-REAXC/reaxc_bonds.cpp @@ -24,12 +24,11 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_bonds.h" -#include "reaxc_bond_orders.h" +#include +#include "pair.h" +#include "reaxc_defs.h" #include "reaxc_list.h" -#include "reaxc_tool_box.h" -#include "reaxc_vector.h" void Bonds( reax_system *system, control_params * /*control*/, simulation_data *data, storage *workspace, reax_list **lists, diff --git a/src/USER-REAXC/reaxc_control.cpp b/src/USER-REAXC/reaxc_control.cpp index 060c1a0342..12aa989fa2 100644 --- a/src/USER-REAXC/reaxc_control.cpp +++ b/src/USER-REAXC/reaxc_control.cpp @@ -24,10 +24,10 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_control.h" #include #include -#include "pair_reaxc.h" -#include "reaxc_control.h" +#include "reaxc_defs.h" #include "reaxc_tool_box.h" #include "error.h" diff --git a/src/USER-REAXC/reaxc_ffield.cpp b/src/USER-REAXC/reaxc_ffield.cpp index 2160d180cf..e3a6645fc2 100644 --- a/src/USER-REAXC/reaxc_ffield.cpp +++ b/src/USER-REAXC/reaxc_ffield.cpp @@ -24,14 +24,16 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_ffield.h" +#include +#include +#include #include #include -#include "pair_reaxc.h" +#include "reaxc_defs.h" #include "error.h" -#include "reaxc_ffield.h" #include "reaxc_tool_box.h" - char Read_Force_Field( FILE *fp, reax_interaction *reax, control_params *control ) { diff --git a/src/USER-REAXC/reaxc_ffield.h b/src/USER-REAXC/reaxc_ffield.h index 7cef730f91..b6fe1c9ea9 100644 --- a/src/USER-REAXC/reaxc_ffield.h +++ b/src/USER-REAXC/reaxc_ffield.h @@ -28,6 +28,7 @@ #define __FFIELD_H_ #include "reaxc_types.h" +#include char Read_Force_Field( FILE*, reax_interaction*, control_params* ); diff --git a/src/USER-REAXC/reaxc_forces.cpp b/src/USER-REAXC/reaxc_forces.cpp index 79094ece43..6cd627f05d 100644 --- a/src/USER-REAXC/reaxc_forces.cpp +++ b/src/USER-REAXC/reaxc_forces.cpp @@ -24,25 +24,22 @@ . ----------------------------------------------------------------------*/ -#include -#include "pair_reaxc.h" #include "reaxc_forces.h" +#include +#include +#include #include "reaxc_bond_orders.h" #include "reaxc_bonds.h" #include "reaxc_hydrogen_bonds.h" -#include "reaxc_io_tools.h" #include "reaxc_list.h" -#include "reaxc_lookup.h" #include "reaxc_multi_body.h" #include "reaxc_nonbonded.h" -#include "reaxc_tool_box.h" #include "reaxc_torsion_angles.h" #include "reaxc_valence_angles.h" #include "reaxc_vector.h" #include "error.h" - interaction_function Interaction_Functions[NUM_INTRS]; void Dummy_Interaction( reax_system * /*system*/, control_params * /*control*/, diff --git a/src/USER-REAXC/reaxc_hydrogen_bonds.cpp b/src/USER-REAXC/reaxc_hydrogen_bonds.cpp index be34df7571..5929703bad 100644 --- a/src/USER-REAXC/reaxc_hydrogen_bonds.cpp +++ b/src/USER-REAXC/reaxc_hydrogen_bonds.cpp @@ -24,9 +24,10 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_hydrogen_bonds.h" -#include "reaxc_bond_orders.h" +#include +#include "pair.h" +#include "reaxc_defs.h" #include "reaxc_list.h" #include "reaxc_valence_angles.h" #include "reaxc_vector.h" diff --git a/src/USER-REAXC/reaxc_init_md.cpp b/src/USER-REAXC/reaxc_init_md.cpp index a0e15e98f5..966ad78c34 100644 --- a/src/USER-REAXC/reaxc_init_md.cpp +++ b/src/USER-REAXC/reaxc_init_md.cpp @@ -24,18 +24,19 @@ . ----------------------------------------------------------------------*/ -#include -#include "pair_reaxc.h" #include "reaxc_init_md.h" +#include +#include +#include +#include +#include "reaxc_defs.h" #include "reaxc_allocate.h" #include "reaxc_forces.h" #include "reaxc_io_tools.h" #include "reaxc_list.h" #include "reaxc_lookup.h" #include "reaxc_reset_tools.h" -#include "reaxc_system_props.h" #include "reaxc_tool_box.h" -#include "reaxc_vector.h" #include "error.h" diff --git a/src/USER-REAXC/reaxc_init_md.h b/src/USER-REAXC/reaxc_init_md.h index ab519a4c72..5d593f50ea 100644 --- a/src/USER-REAXC/reaxc_init_md.h +++ b/src/USER-REAXC/reaxc_init_md.h @@ -28,7 +28,7 @@ #define __INIT_MD_H_ #include "reaxc_types.h" - +#include void Initialize( reax_system*, control_params*, simulation_data*, storage*, reax_list**, output_controls*, mpi_datatypes*, MPI_Comm ); diff --git a/src/USER-REAXC/reaxc_io_tools.cpp b/src/USER-REAXC/reaxc_io_tools.cpp index f4a1486c48..f68a2a2abb 100644 --- a/src/USER-REAXC/reaxc_io_tools.cpp +++ b/src/USER-REAXC/reaxc_io_tools.cpp @@ -24,16 +24,12 @@ . ----------------------------------------------------------------------*/ -#include -#include "pair_reaxc.h" -#include "update.h" #include "reaxc_io_tools.h" -#include "reaxc_list.h" -#include "reaxc_reset_tools.h" +#include +#include +#include "reaxc_defs.h" #include "reaxc_system_props.h" -#include "reaxc_tool_box.h" #include "reaxc_traj.h" -#include "reaxc_vector.h" int Init_Output_Files( reax_system *system, control_params *control, output_controls *out_control, mpi_datatypes *mpi_data, diff --git a/src/USER-REAXC/reaxc_list.cpp b/src/USER-REAXC/reaxc_list.cpp index cd4f815286..53bd05bc8d 100644 --- a/src/USER-REAXC/reaxc_list.cpp +++ b/src/USER-REAXC/reaxc_list.cpp @@ -24,8 +24,8 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_list.h" +#include "reaxc_defs.h" #include "reaxc_tool_box.h" #include "error.h" diff --git a/src/USER-REAXC/reaxc_lookup.cpp b/src/USER-REAXC/reaxc_lookup.cpp index 8d33a33fba..622483fdc9 100644 --- a/src/USER-REAXC/reaxc_lookup.cpp +++ b/src/USER-REAXC/reaxc_lookup.cpp @@ -24,12 +24,13 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_lookup.h" +#include +#include +#include "reaxc_defs.h" #include "reaxc_nonbonded.h" #include "reaxc_tool_box.h" - void Tridiagonal_Solve( const double *a, const double *b, double *c, double *d, double *x, unsigned int n){ int i; diff --git a/src/USER-REAXC/reaxc_lookup.h b/src/USER-REAXC/reaxc_lookup.h index 3fd0c2581a..3aae7e0b63 100644 --- a/src/USER-REAXC/reaxc_lookup.h +++ b/src/USER-REAXC/reaxc_lookup.h @@ -28,6 +28,7 @@ #define __LOOKUP_H_ #include "reaxc_types.h" +namespace LAMMPS_NS { class Error; } void Tridiagonal_Solve( const double *a, const double *b, double *c, double *d, double *x, unsigned int n); @@ -35,8 +36,9 @@ void Tridiagonal_Solve( const double *a, const double *b, void Natural_Cubic_Spline( LAMMPS_NS::Error*, const double *h, const double *f, cubic_spline_coef *coef, unsigned int n ); -void Complete_Cubic_Spline( LAMMPS_NS::Error*, const double *h, const double *f, double v0, double vlast, - cubic_spline_coef *coef, unsigned int n ); +void Complete_Cubic_Spline( LAMMPS_NS::Error*, const double *h, const double *f, + double v0, double vlast, cubic_spline_coef *coef, + unsigned int n ); int Init_Lookup_Tables( reax_system*, control_params*, storage*, mpi_datatypes*, char* ); diff --git a/src/USER-REAXC/reaxc_multi_body.cpp b/src/USER-REAXC/reaxc_multi_body.cpp index 371b8ed65e..ed1a3d5ac1 100644 --- a/src/USER-REAXC/reaxc_multi_body.cpp +++ b/src/USER-REAXC/reaxc_multi_body.cpp @@ -24,12 +24,12 @@ . ----------------------------------------------------------------------*/ -#include -#include "pair_reaxc.h" #include "reaxc_multi_body.h" -#include "reaxc_bond_orders.h" +#include +#include +#include "pair.h" +#include "reaxc_defs.h" #include "reaxc_list.h" -#include "reaxc_vector.h" void Atom_Energy( reax_system *system, control_params *control, simulation_data *data, storage *workspace, reax_list **lists, diff --git a/src/USER-REAXC/reaxc_nonbonded.cpp b/src/USER-REAXC/reaxc_nonbonded.cpp index b0fea8c1b9..497a1a0ebe 100644 --- a/src/USER-REAXC/reaxc_nonbonded.cpp +++ b/src/USER-REAXC/reaxc_nonbonded.cpp @@ -24,10 +24,11 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" -#include "reaxc_types.h" #include "reaxc_nonbonded.h" -#include "reaxc_bond_orders.h" +#include +#include "pair.h" +#include "reaxc_defs.h" +#include "reaxc_types.h" #include "reaxc_list.h" #include "reaxc_vector.h" diff --git a/src/USER-REAXC/reaxc_reset_tools.cpp b/src/USER-REAXC/reaxc_reset_tools.cpp index c72ccbadcd..91b1a9e14f 100644 --- a/src/USER-REAXC/reaxc_reset_tools.cpp +++ b/src/USER-REAXC/reaxc_reset_tools.cpp @@ -24,9 +24,9 @@ . ----------------------------------------------------------------------*/ -#include -#include "pair_reaxc.h" #include "reaxc_reset_tools.h" +#include +#include "reaxc_defs.h" #include "reaxc_list.h" #include "reaxc_tool_box.h" #include "reaxc_vector.h" diff --git a/src/USER-REAXC/reaxc_system_props.cpp b/src/USER-REAXC/reaxc_system_props.cpp index 5024feffcf..166f070be6 100644 --- a/src/USER-REAXC/reaxc_system_props.cpp +++ b/src/USER-REAXC/reaxc_system_props.cpp @@ -24,11 +24,9 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_system_props.h" -#include "reaxc_tool_box.h" -#include "reaxc_vector.h" - +#include +#include "reaxc_defs.h" void Compute_System_Energy( reax_system *system, simulation_data *data, MPI_Comm comm ) diff --git a/src/USER-REAXC/reaxc_system_props.h b/src/USER-REAXC/reaxc_system_props.h index 161060e184..4d80e22966 100644 --- a/src/USER-REAXC/reaxc_system_props.h +++ b/src/USER-REAXC/reaxc_system_props.h @@ -28,6 +28,7 @@ #define __SYSTEM_PROP_H_ #include "reaxc_types.h" +#include void Compute_System_Energy( reax_system*, simulation_data*, MPI_Comm ); diff --git a/src/USER-REAXC/reaxc_tool_box.cpp b/src/USER-REAXC/reaxc_tool_box.cpp index 2cf66d8655..811c2ed0ee 100644 --- a/src/USER-REAXC/reaxc_tool_box.cpp +++ b/src/USER-REAXC/reaxc_tool_box.cpp @@ -24,9 +24,11 @@ . ----------------------------------------------------------------------*/ -#include -#include "pair_reaxc.h" #include "reaxc_tool_box.h" +#include +#include +#include +#include "reaxc_defs.h" #if !defined(_MSC_VER) #include diff --git a/src/USER-REAXC/reaxc_tool_box.h b/src/USER-REAXC/reaxc_tool_box.h index 0465376dba..b325819265 100644 --- a/src/USER-REAXC/reaxc_tool_box.h +++ b/src/USER-REAXC/reaxc_tool_box.h @@ -28,7 +28,7 @@ #define __TOOL_BOX_H_ #include "reaxc_types.h" -#include "reaxc_defs.h" +namespace LAMMPS_NS { class Error; } /* from system_props.h */ double Get_Time( ); diff --git a/src/USER-REAXC/reaxc_torsion_angles.cpp b/src/USER-REAXC/reaxc_torsion_angles.cpp index ed76368d68..ce944b217f 100644 --- a/src/USER-REAXC/reaxc_torsion_angles.cpp +++ b/src/USER-REAXC/reaxc_torsion_angles.cpp @@ -24,11 +24,11 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_torsion_angles.h" -#include "reaxc_bond_orders.h" +#include +#include "pair.h" +#include "reaxc_defs.h" #include "reaxc_list.h" -#include "reaxc_tool_box.h" #include "reaxc_vector.h" #define MIN_SINE 1e-10 diff --git a/src/USER-REAXC/reaxc_traj.cpp b/src/USER-REAXC/reaxc_traj.cpp index a536445113..fb493feae5 100644 --- a/src/USER-REAXC/reaxc_traj.cpp +++ b/src/USER-REAXC/reaxc_traj.cpp @@ -24,11 +24,13 @@ . ----------------------------------------------------------------------*/ -#include -#include "pair_reaxc.h" #include "reaxc_traj.h" +#include +#include +#include +#include +#include "reaxc_defs.h" #include "reaxc_list.h" -#include "reaxc_tool_box.h" #include "error.h" diff --git a/src/USER-REAXC/reaxc_valence_angles.cpp b/src/USER-REAXC/reaxc_valence_angles.cpp index 4ba870b6d9..560955fa9d 100644 --- a/src/USER-REAXC/reaxc_valence_angles.cpp +++ b/src/USER-REAXC/reaxc_valence_angles.cpp @@ -24,9 +24,10 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_valence_angles.h" -#include "reaxc_bond_orders.h" +#include +#include "pair.h" +#include "reaxc_defs.h" #include "reaxc_list.h" #include "reaxc_vector.h" diff --git a/src/USER-REAXC/reaxc_vector.cpp b/src/USER-REAXC/reaxc_vector.cpp index b54d329ce9..207d745df3 100644 --- a/src/USER-REAXC/reaxc_vector.cpp +++ b/src/USER-REAXC/reaxc_vector.cpp @@ -24,9 +24,9 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc.h" #include "reaxc_vector.h" - +#include +#include "reaxc_defs.h" void rvec_Copy( rvec dest, rvec src ) { diff --git a/src/USER-REAXC/reaxc_vector.h b/src/USER-REAXC/reaxc_vector.h index 906b200dc9..549c1f927c 100644 --- a/src/USER-REAXC/reaxc_vector.h +++ b/src/USER-REAXC/reaxc_vector.h @@ -27,9 +27,7 @@ #ifndef __VECTOR_H_ #define __VECTOR_H_ -#include "pair.h" #include "reaxc_types.h" -#include "reaxc_defs.h" void rvec_Copy( rvec, rvec ); void rvec_Scale( rvec, double, rvec ); From ca4b26ddf8e0c0a6f7060387c999b21c3f13c9db Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 07:22:41 -0400 Subject: [PATCH 65/79] fix up some leftover include issues that got overlooked in previous changes --- src/USER-PTM/ptm_structure_matcher.cpp | 8 ++------ src/USER-PTM/ptm_structure_matcher.h | 2 +- src/USER-QTB/fix_qbmsst.cpp | 11 +---------- src/USER-QTB/fix_qtb.cpp | 9 +-------- src/USER-SDPD/fix_meso_move.cpp | 3 +-- src/USER-SDPD/fix_rigid_meso.cpp | 7 ------- src/USER-SMD/pair_smd_ulsph.cpp | 3 +++ src/USER-UEF/dump_cfg_uef.cpp | 1 - src/USER-YAFF/angle_cross.cpp | 1 + src/USER-YAFF/angle_mm3.cpp | 2 +- 10 files changed, 11 insertions(+), 36 deletions(-) diff --git a/src/USER-PTM/ptm_structure_matcher.cpp b/src/USER-PTM/ptm_structure_matcher.cpp index d50676a3c1..b587ad225f 100644 --- a/src/USER-PTM/ptm_structure_matcher.cpp +++ b/src/USER-PTM/ptm_structure_matcher.cpp @@ -7,20 +7,16 @@ The above copyright notice and this permission notice shall be included in all c THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -#include -#include +#include "ptm_structure_matcher.h" #include #include -#include -#include -#include +#include #include "ptm_convex_hull_incremental.h" #include "ptm_canonical_coloured.h" #include "ptm_graph_data.h" #include "ptm_graph_tools.h" #include "ptm_normalize_vertices.h" #include "ptm_polar.h" -#include "ptm_structure_matcher.h" #include "ptm_constants.h" diff --git a/src/USER-PTM/ptm_structure_matcher.h b/src/USER-PTM/ptm_structure_matcher.h index e75892f8cb..63bc5ed1fe 100644 --- a/src/USER-PTM/ptm_structure_matcher.h +++ b/src/USER-PTM/ptm_structure_matcher.h @@ -12,7 +12,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #include "ptm_initialize_data.h" #include "ptm_constants.h" - +#include "ptm_convex_hull_incremental.h" namespace ptm { diff --git a/src/USER-QTB/fix_qbmsst.cpp b/src/USER-QTB/fix_qbmsst.cpp index b9b07664d2..abbf1701b8 100644 --- a/src/USER-QTB/fix_qbmsst.cpp +++ b/src/USER-QTB/fix_qbmsst.cpp @@ -16,31 +16,22 @@ Implementation of the Multi-Scale Shock Method with quantum nuclear effects ------------------------------------------------------------------------- */ +#include "fix_qbmsst.h" #include #include #include #include -#include "fix_qbmsst.h" -#include "math_extra.h" #include "atom.h" -#include "atom_vec_ellipsoid.h" #include "force.h" #include "update.h" #include "modify.h" #include "compute.h" #include "domain.h" -#include "region.h" -#include "respa.h" #include "comm.h" -#include "input.h" -#include "output.h" -#include "variable.h" #include "random_mars.h" #include "memory.h" #include "error.h" -#include "group.h" #include "kspace.h" -#include "thermo.h" #include "utils.h" using namespace LAMMPS_NS; diff --git a/src/USER-QTB/fix_qtb.cpp b/src/USER-QTB/fix_qtb.cpp index 015f953b8e..593ca31006 100644 --- a/src/USER-QTB/fix_qtb.cpp +++ b/src/USER-QTB/fix_qtb.cpp @@ -16,28 +16,21 @@ Implementation of the colored thermostat for quantum nuclear effects ------------------------------------------------------------------------- */ +#include "fix_qtb.h" #include #include #include #include -#include "fix_qtb.h" -#include "math_extra.h" #include "atom.h" -#include "atom_vec_ellipsoid.h" #include "force.h" #include "update.h" #include "modify.h" #include "compute.h" -#include "domain.h" -#include "region.h" #include "respa.h" #include "comm.h" -#include "input.h" -#include "variable.h" #include "random_mars.h" #include "memory.h" #include "error.h" -#include "group.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-SDPD/fix_meso_move.cpp b/src/USER-SDPD/fix_meso_move.cpp index 85b08a2af7..176cd8b895 100644 --- a/src/USER-SDPD/fix_meso_move.cpp +++ b/src/USER-SDPD/fix_meso_move.cpp @@ -16,11 +16,10 @@ Morteza Jalalvand (IASBS) jalalvand.m AT gmail.com ------------------------------------------------------------------------- */ +#include "fix_meso_move.h" #include #include -#include "fix_meso_move.h" #include "atom.h" -#include "group.h" #include "update.h" #include "modify.h" #include "force.h" diff --git a/src/USER-SDPD/fix_rigid_meso.cpp b/src/USER-SDPD/fix_rigid_meso.cpp index 49c9ca8614..e93c543e72 100644 --- a/src/USER-SDPD/fix_rigid_meso.cpp +++ b/src/USER-SDPD/fix_rigid_meso.cpp @@ -27,17 +27,10 @@ and all codes relevant to that has been removed ------------------------------------------------------------------------- */ -#include #include "fix_rigid_meso.h" #include "math_extra.h" #include "atom.h" -#include "compute.h" #include "domain.h" -#include "update.h" -#include "modify.h" -#include "group.h" -#include "force.h" -#include "output.h" #include "memory.h" #include "error.h" diff --git a/src/USER-SMD/pair_smd_ulsph.cpp b/src/USER-SMD/pair_smd_ulsph.cpp index 9e824ded3c..b53eb779de 100644 --- a/src/USER-SMD/pair_smd_ulsph.cpp +++ b/src/USER-SMD/pair_smd_ulsph.cpp @@ -23,8 +23,11 @@ ------------------------------------------------------------------------- */ #include "pair_smd_ulsph.h" +#include #include #include +#include +#include #include "atom.h" #include "domain.h" #include "force.h" diff --git a/src/USER-UEF/dump_cfg_uef.cpp b/src/USER-UEF/dump_cfg_uef.cpp index 5e3733f422..8e6268eee6 100644 --- a/src/USER-UEF/dump_cfg_uef.cpp +++ b/src/USER-UEF/dump_cfg_uef.cpp @@ -14,7 +14,6 @@ ------------------------------------------------------------------------- */ #include "dump_cfg.h" -#include #include #include "atom.h" #include "modify.h" diff --git a/src/USER-YAFF/angle_cross.cpp b/src/USER-YAFF/angle_cross.cpp index 2ebb08f56b..0f8861cdf5 100644 --- a/src/USER-YAFF/angle_cross.cpp +++ b/src/USER-YAFF/angle_cross.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "angle_cross.h" +#include #include #include "atom.h" #include "neighbor.h" diff --git a/src/USER-YAFF/angle_mm3.cpp b/src/USER-YAFF/angle_mm3.cpp index 24ce8229ba..b90db37afa 100644 --- a/src/USER-YAFF/angle_mm3.cpp +++ b/src/USER-YAFF/angle_mm3.cpp @@ -16,8 +16,8 @@ ------------------------------------------------------------------------- */ #include "angle_mm3.h" +#include #include -#include #include "atom.h" #include "neighbor.h" #include "domain.h" From 01524d9850ab0896adb905d8c64d6b72a99cf1de Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 08:13:03 -0400 Subject: [PATCH 66/79] recover compilation of USER-OMP --- src/USER-OMP/reaxc_bond_orders_omp.cpp | 3 ++- src/USER-OMP/reaxc_bonds_omp.cpp | 5 +++-- src/USER-OMP/reaxc_forces_omp.cpp | 3 ++- src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp | 4 ++-- src/USER-OMP/reaxc_init_md_omp.cpp | 3 ++- src/USER-OMP/reaxc_multi_body_omp.cpp | 3 ++- src/USER-OMP/reaxc_nonbonded_omp.cpp | 1 + src/USER-OMP/reaxc_torsion_angles_omp.cpp | 3 ++- src/USER-OMP/reaxc_valence_angles_omp.cpp | 3 ++- 9 files changed, 18 insertions(+), 10 deletions(-) diff --git a/src/USER-OMP/reaxc_bond_orders_omp.cpp b/src/USER-OMP/reaxc_bond_orders_omp.cpp index 33780f5e3f..17715c6e26 100644 --- a/src/USER-OMP/reaxc_bond_orders_omp.cpp +++ b/src/USER-OMP/reaxc_bond_orders_omp.cpp @@ -26,9 +26,10 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_bond_orders_omp.h" +#include "reaxc_defs.h" #include "pair_reaxc_omp.h" #include "reaxc_types.h" -#include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_vector.h" diff --git a/src/USER-OMP/reaxc_bonds_omp.cpp b/src/USER-OMP/reaxc_bonds_omp.cpp index 5160c6f55d..12ba1dcbfe 100644 --- a/src/USER-OMP/reaxc_bonds_omp.cpp +++ b/src/USER-OMP/reaxc_bonds_omp.cpp @@ -26,10 +26,11 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_bonds_omp.h" +#include "reaxc_defs.h" +#include "reaxc_bond_orders_omp.h" #include "pair_reaxc_omp.h" -#include "reaxc_bonds_omp.h" -#include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_tool_box.h" #include "reaxc_vector.h" diff --git a/src/USER-OMP/reaxc_forces_omp.cpp b/src/USER-OMP/reaxc_forces_omp.cpp index 0a08bd6a46..1ada5e7e71 100644 --- a/src/USER-OMP/reaxc_forces_omp.cpp +++ b/src/USER-OMP/reaxc_forces_omp.cpp @@ -26,10 +26,11 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_forces_omp.h" +#include "reaxc_defs.h" #include "pair_reaxc_omp.h" #include "thr_data.h" -#include "reaxc_forces_omp.h" #include "reaxc_bond_orders_omp.h" #include "reaxc_bonds_omp.h" #include "reaxc_hydrogen_bonds_omp.h" diff --git a/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp b/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp index 7acf26262e..e3c034a12e 100644 --- a/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp +++ b/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp @@ -26,9 +26,9 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc_omp.h" - #include "reaxc_hydrogen_bonds_omp.h" +#include "pair_reaxc_omp.h" +#include "reaxc_defs.h" #include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_valence_angles.h" // To access Calculate_Theta() diff --git a/src/USER-OMP/reaxc_init_md_omp.cpp b/src/USER-OMP/reaxc_init_md_omp.cpp index fe7682d035..847e916666 100644 --- a/src/USER-OMP/reaxc_init_md_omp.cpp +++ b/src/USER-OMP/reaxc_init_md_omp.cpp @@ -26,8 +26,9 @@ . ----------------------------------------------------------------------*/ -#include "pair_reaxc_omp.h" #include "reaxc_init_md_omp.h" +#include "pair_reaxc_omp.h" +#include "reaxc_defs.h" #include "reaxc_allocate.h" #include "reaxc_forces.h" #include "reaxc_forces_omp.h" diff --git a/src/USER-OMP/reaxc_multi_body_omp.cpp b/src/USER-OMP/reaxc_multi_body_omp.cpp index d791f945a8..164999b986 100644 --- a/src/USER-OMP/reaxc_multi_body_omp.cpp +++ b/src/USER-OMP/reaxc_multi_body_omp.cpp @@ -26,11 +26,12 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_multi_body_omp.h" #include #include "pair_reaxc_omp.h" #include "thr_data.h" +#include "reaxc_defs.h" -#include "reaxc_multi_body_omp.h" #include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_vector.h" diff --git a/src/USER-OMP/reaxc_nonbonded_omp.cpp b/src/USER-OMP/reaxc_nonbonded_omp.cpp index ea92e0c210..564088880a 100644 --- a/src/USER-OMP/reaxc_nonbonded_omp.cpp +++ b/src/USER-OMP/reaxc_nonbonded_omp.cpp @@ -29,6 +29,7 @@ #include "pair_reaxc_omp.h" #include "thr_data.h" +#include "reaxc_defs.h" #include "reaxc_types.h" #include "reaxc_nonbonded.h" diff --git a/src/USER-OMP/reaxc_torsion_angles_omp.cpp b/src/USER-OMP/reaxc_torsion_angles_omp.cpp index d290dc264f..9cd716b594 100644 --- a/src/USER-OMP/reaxc_torsion_angles_omp.cpp +++ b/src/USER-OMP/reaxc_torsion_angles_omp.cpp @@ -26,11 +26,12 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_torsion_angles_omp.h" #include "pair_reaxc_omp.h" #include "thr_data.h" +#include "reaxc_defs.h" #include "reaxc_types.h" -#include "reaxc_torsion_angles_omp.h" #include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_tool_box.h" diff --git a/src/USER-OMP/reaxc_valence_angles_omp.cpp b/src/USER-OMP/reaxc_valence_angles_omp.cpp index 195f16a75d..7fbe87d6e5 100644 --- a/src/USER-OMP/reaxc_valence_angles_omp.cpp +++ b/src/USER-OMP/reaxc_valence_angles_omp.cpp @@ -26,12 +26,13 @@ . ----------------------------------------------------------------------*/ +#include "reaxc_valence_angles_omp.h" #include "pair_reaxc_omp.h" #include "thr_data.h" +#include "reaxc_defs.h" #include "reaxc_types.h" #include "reaxc_valence_angles.h" -#include "reaxc_valence_angles_omp.h" #include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_vector.h" From b5fea1f4a7528776cf1944508b7ce445c97e0217 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 09:19:26 -0400 Subject: [PATCH 67/79] no need to zero out Ec_meam twice --- src/USER-MEAMC/meam_impl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/USER-MEAMC/meam_impl.cpp b/src/USER-MEAMC/meam_impl.cpp index 3b40a2b612..74e8af1cde 100644 --- a/src/USER-MEAMC/meam_impl.cpp +++ b/src/USER-MEAMC/meam_impl.cpp @@ -44,7 +44,7 @@ MEAM::MEAM(Memory* mem) rho_ref_meam[i] = ibar_meam[i] = ielt_meam[i] = 0.0; for (int j = 0; j < maxelt; j++) { lattce_meam[i][j] = FCC; - Ec_meam[i][j] = re_meam[i][j] = alpha_meam[i][j] = delta_meam[i][j] = Ec_meam[i][j] = ebound_meam[i][j] = attrac_meam[i][j] = repuls_meam[i][j] = 0.0; + Ec_meam[i][j] = re_meam[i][j] = alpha_meam[i][j] = delta_meam[i][j] = ebound_meam[i][j] = attrac_meam[i][j] = repuls_meam[i][j] = 0.0; nn2_meam[i][j] = zbl_meam[i][j] = eltind[i][j] = 0; } } From b1f8c3f38acd9490fe4a17977428c31d20558e00 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 11:25:44 -0400 Subject: [PATCH 68/79] silence some compiler warnings --- src/MANYBODY/pair_airebo.cpp | 161 ++++++++++++++++++----------------- 1 file changed, 81 insertions(+), 80 deletions(-) diff --git a/src/MANYBODY/pair_airebo.cpp b/src/MANYBODY/pair_airebo.cpp index 818663222f..fcc3a3efd2 100644 --- a/src/MANYBODY/pair_airebo.cpp +++ b/src/MANYBODY/pair_airebo.cpp @@ -3193,6 +3193,7 @@ double PairAIREBO::piRCSpline(double Nij, double Nji, double Nijconj, dN3[0]=0.0; dN3[1]=0.0; dN3[2]=0.0; + piRC=0.0; if (typei==0 && typej==0) { @@ -4343,70 +4344,70 @@ void PairAIREBO::Sptricubic_patch_coeffs( ) { const double C_inv[64][32] = { // output_matrix(2, 8*4, get_matrix(3)) - 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, - -3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -2, -1, 0, 0, 0, 0, 0, 0, - 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -3, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -2, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 3, 0, 0, 0, 0, 0, - 9, -9, -9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, -6, 3, -3, 0, 0, 0, 0, 6, 3, -6, -3, 0, 0, 0, 0, - -6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -4, 4, -2, 2, 0, 0, 0, 0, -3, -3, 3, 3, 0, 0, 0, 0, - 2, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, -2, 0, 0, 0, 0, 0, - -6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 3, -3, 3, 0, 0, 0, 0, -4, -2, 4, 2, 0, 0, 0, 0, - 4, -4, -4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, -2, 2, -2, 0, 0, 0, 0, 2, 2, -2, -2, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, -3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 9, -9, -9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 4, -4, -4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -3, 0, 0, 0, 3, 0, 0, 0, -2, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 0, 0, 3, 0, 0, 0, - 9, -9, 0, 0, -9, 9, 0, 0, 6, -6, 0, 0, 3, -3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 3, 0, 0, -6, -3, 0, 0, - -6, 6, 0, 0, 6, -6, 0, 0, -4, 4, 0, 0, -2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, -3, 0, 0, 3, 3, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, -9, 0, 0, -9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 0, 0, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 9, 0, -9, 0, -9, 0, 9, 0, 6, 0, -6, 0, 3, 0, -3, 0, 6, 0, 3, 0, -6, 0, -3, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, -9, 0, -9, 0, 9, 0, - -27, 27, 27,-27, 27,-27,-27, 27,-18, 18, 18,-18, -9, 9, 9, -9,-18, 18, -9, 9, 18,-18, 9, -9,-18, -9, 18, 9, 18, 9,-18, -9, - 18,-18,-18, 18,-18, 18, 18,-18, 12,-12,-12, 12, 6, -6, -6, 6, 12,-12, 6, -6,-12, 12, -6, 6, 9, 9, -9, -9, -9, -9, 9, 9, - -6, 0, 6, 0, 6, 0, -6, 0, -4, 0, 4, 0, -2, 0, 2, 0, -3, 0, -3, 0, 3, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 0, 6, 0, 6, 0, -6, 0, - 18,-18,-18, 18,-18, 18, 18,-18, 12,-12,-12, 12, 6, -6, -6, 6, 9, -9, 9, -9, -9, 9, -9, 9, 12, 6,-12, -6,-12, -6, 12, 6, - -12, 12, 12,-12, 12,-12,-12, 12, -8, 8, 8, -8, -4, 4, 4, -4, -6, 6, -6, 6, 6, -6, 6, -6, -6, -6, 6, 6, 6, 6, -6, -6, - 2, 0, 0, 0, -2, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, -2, 0, 0, 0, - -6, 6, 0, 0, 6, -6, 0, 0, -3, 3, 0, 0, -3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -4, -2, 0, 0, 4, 2, 0, 0, - 4, -4, 0, 0, -4, 4, 0, 0, 2, -2, 0, 0, 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 0, 0, -2, -2, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 0, 0, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, -4, 0, 0, -4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - -6, 0, 6, 0, 6, 0, -6, 0, -3, 0, 3, 0, -3, 0, 3, 0, -4, 0, -2, 0, 4, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 0, 6, 0, 6, 0, -6, 0, - 18,-18,-18, 18,-18, 18, 18,-18, 9, -9, -9, 9, 9, -9, -9, 9, 12,-12, 6, -6,-12, 12, -6, 6, 12, 6,-12, -6,-12, -6, 12, 6, - -12, 12, 12,-12, 12,-12,-12, 12, -6, 6, 6, -6, -6, 6, 6, -6, -8, 8, -4, 4, 8, -8, 4, -4, -6, -6, 6, 6, 6, 6, -6, -6, - 4, 0, -4, 0, -4, 0, 4, 0, 2, 0, -2, 0, 2, 0, -2, 0, 2, 0, 2, 0, -2, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, -4, 0, -4, 0, 4, 0, - -12, 12, 12,-12, 12,-12,-12, 12, -6, 6, 6, -6, -6, 6, 6, -6, -6, 6, -6, 6, 6, -6, 6, -6, -8, -4, 8, 4, 8, 4, -8, -4, - 8, -8, -8, 8, -8, 8, 8, -8, 4, -4, -4, 4, 4, -4, -4, 4, 4, -4, 4, -4, -4, 4, -4, 4, 4, 4, -4, -4, -4, -4, 4, 4, + { 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0}, + {-3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -2, -1, 0, 0, 0, 0, 0, 0}, + { 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + {-3, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -2, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 3, 0, 0, 0, 0, 0}, + { 9, -9, -9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, -6, 3, -3, 0, 0, 0, 0, 6, 3, -6, -3, 0, 0, 0, 0}, + {-6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -4, 4, -2, 2, 0, 0, 0, 0, -3, -3, 3, 3, 0, 0, 0, 0}, + { 2, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, -2, 0, 0, 0, 0, 0}, + {-6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 3, -3, 3, 0, 0, 0, 0, -4, -2, 4, 2, 0, 0, 0, 0}, + { 4, -4, -4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, -2, 2, -2, 0, 0, 0, 0, 2, 2, -2, -2, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, -3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 9, -9, -9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 4, -4, -4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + {-3, 0, 0, 0, 3, 0, 0, 0, -2, 0, 0, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 0, 0, 3, 0, 0, 0}, + { 9, -9, 0, 0, -9, 9, 0, 0, 6, -6, 0, 0, 3, -3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 3, 0, 0, -6, -3, 0, 0}, + {-6, 6, 0, 0, 6, -6, 0, 0, -4, 4, 0, 0, -2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, -3, 0, 0, 3, 3, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -3, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, -9, 0, 0, -9, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 0, 0, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 9, 0, -9, 0, -9, 0, 9, 0, 6, 0, -6, 0, 3, 0, -3, 0, 6, 0, 3, 0, -6, 0, -3, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 0, -9, 0, -9, 0, 9, 0}, + {-27,27, 27,-27, 27,-27,-27, 27,-18, 18, 18,-18, -9, 9, 9, -9,-18, 18, -9, 9, 18,-18, 9, -9,-18, -9, 18, 9, 18, 9,-18, -9}, + {18,-18,-18, 18,-18, 18, 18,-18, 12,-12,-12, 12, 6, -6, -6, 6, 12,-12, 6, -6,-12, 12, -6, 6, 9, 9, -9, -9, -9, -9, 9, 9}, + {-6, 0, 6, 0, 6, 0, -6, 0, -4, 0, 4, 0, -2, 0, 2, 0, -3, 0, -3, 0, 3, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 0, 6, 0, 6, 0, -6, 0}, + {18,-18,-18, 18,-18, 18, 18,-18, 12,-12,-12, 12, 6, -6, -6, 6, 9, -9, 9, -9, -9, 9, -9, 9, 12, 6,-12, -6,-12, -6, 12, 6}, + {-12,12, 12,-12, 12,-12,-12, 12, -8, 8, 8, -8, -4, 4, 4, -4, -6, 6, -6, 6, 6, -6, 6, -6, -6, -6, 6, 6, 6, 6, -6, -6}, + { 2, 0, 0, 0, -2, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, -2, 0, 0, 0}, + {-6, 6, 0, 0, 6, -6, 0, 0, -3, 3, 0, 0, -3, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -4, -2, 0, 0, 4, 2, 0, 0}, + { 4, -4, 0, 0, -4, 4, 0, 0, 2, -2, 0, 0, 2, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 0, 0, -2, -2, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 6, 0, 0, 6, -6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, -4, 0, 0, -4, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + {-6, 0, 6, 0, 6, 0, -6, 0, -3, 0, 3, 0, -3, 0, 3, 0, -4, 0, -2, 0, 4, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -6, 0, 6, 0, 6, 0, -6, 0}, + {18,-18,-18, 18,-18, 18, 18,-18, 9, -9, -9, 9, 9, -9, -9, 9, 12,-12, 6, -6,-12, 12, -6, 6, 12, 6,-12, -6,-12, -6, 12, 6}, + {-12,12, 12,-12, 12,-12,-12, 12, -6, 6, 6, -6, -6, 6, 6, -6, -8, 8, -4, 4, 8, -8, 4, -4, -6, -6, 6, 6, 6, 6, -6, -6}, + { 4, 0, -4, 0, -4, 0, 4, 0, 2, 0, -2, 0, 2, 0, -2, 0, 2, 0, 2, 0, -2, 0, -2, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, -4, 0, -4, 0, 4, 0}, + {-12,12, 12,-12, 12,-12,-12, 12, -6, 6, 6, -6, -6, 6, 6, -6, -6, 6, -6, 6, 6, -6, 6, -6, -8, -4, 8, 4, 8, 4, -8, -4}, + { 8, -8, -8, 8, -8, 8, 8, -8, 4, -4, -4, 4, 4, -4, -4, 4, 4, -4, 4, -4, -4, 4, -4, 4, 4, 4, -4, -4, -4, -4, 4, 4} }; double dx = xmax - xmin; double dy = ymax - ymin; @@ -4456,22 +4457,22 @@ void PairAIREBO::Spbicubic_patch_coeffs( ) { const double C_inv[16][12] = { // output_matrix(1, 4*3, get_matrix(2)) - 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, - -3, 3, 0, 0, 0, 0, 0, 0,-2,-1, 0, 0, - 2,-2, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, - 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0,-3, 3, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 2,-2, 0, 0, 0, 0, 0, 0, - -3, 0, 3, 0,-2, 0,-1, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0,-3, 0, 3, 0, - 9,-9,-9, 9, 6,-6, 3,-3, 6, 3,-6,-3, - -6, 6, 6,-6,-4, 4,-2, 2,-3,-3, 3, 3, - 2, 0,-2, 0, 1, 0, 1, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 2, 0,-2, 0, - -6, 6, 6,-6,-3, 3,-3, 3,-4,-2, 4, 2, - 4,-4,-4, 4, 2,-2, 2,-2, 2, 2,-2,-2, + { 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0}, + {-3, 3, 0, 0, 0, 0, 0, 0,-2,-1, 0, 0}, + { 2,-2, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0}, + { 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0,-3, 3, 0, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 2,-2, 0, 0, 0, 0, 0, 0}, + {-3, 0, 3, 0,-2, 0,-1, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0,-3, 0, 3, 0}, + { 9,-9,-9, 9, 6,-6, 3,-3, 6, 3,-6,-3}, + {-6, 6, 6,-6,-4, 4,-2, 2,-3,-3, 3, 3}, + { 2, 0,-2, 0, 1, 0, 1, 0, 0, 0, 0, 0}, + { 0, 0, 0, 0, 0, 0, 0, 0, 2, 0,-2, 0}, + {-6, 6, 6,-6,-3, 3,-3, 3,-4,-2, 4, 2}, + { 4,-4,-4, 4, 2,-2, 2,-2, 2, 2,-2,-2} }; double dx = xmax - xmin; double dy = ymax - ymin; From 9f6bbe1d8e390a3614a10413dee95deb4d3c55cd Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 14:21:55 -0400 Subject: [PATCH 69/79] recover compilation of KOKKOS package --- src/KOKKOS/fix_reaxc_species_kokkos.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/KOKKOS/fix_reaxc_species_kokkos.cpp b/src/KOKKOS/fix_reaxc_species_kokkos.cpp index 71aacba68d..f32bea2c67 100644 --- a/src/KOKKOS/fix_reaxc_species_kokkos.cpp +++ b/src/KOKKOS/fix_reaxc_species_kokkos.cpp @@ -23,6 +23,7 @@ #include "fix_ave_atom.h" #include "domain.h" #include "update.h" +#include "reaxc_defs.h" #include "pair_reaxc_kokkos.h" #include "modify.h" #include "neighbor.h" From 48c73567436964589dd0a99d741be7e49530e53d Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 16:51:48 -0400 Subject: [PATCH 70/79] starting to work on includes in USER-OMP --- src/USER-OMP/angle_charmm_omp.cpp | 8 ++------ src/USER-OMP/angle_class2_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_delta_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_periodic_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_shift_exp_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_shift_omp.cpp | 2 +- src/USER-OMP/angle_cosine_squared_omp.cpp | 8 ++------ src/USER-OMP/angle_dipole_omp.cpp | 8 ++------ src/USER-OMP/angle_fourier_omp.cpp | 2 +- src/USER-OMP/angle_fourier_simple_omp.cpp | 8 ++------ src/USER-OMP/angle_harmonic_omp.cpp | 8 ++------ src/USER-OMP/angle_quartic_omp.cpp | 2 +- src/USER-OMP/angle_sdk_omp.cpp | 8 ++------ src/USER-OMP/angle_table_omp.cpp | 8 ++------ src/USER-OMP/bond_class2_omp.cpp | 2 +- src/USER-OMP/bond_fene_expand_omp.cpp | 2 +- src/USER-OMP/bond_fene_omp.cpp | 2 +- src/USER-OMP/bond_gromos_omp.cpp | 2 +- src/USER-OMP/bond_harmonic_omp.cpp | 2 +- src/USER-OMP/bond_harmonic_shift_cut_omp.cpp | 2 +- src/USER-OMP/bond_harmonic_shift_omp.cpp | 2 +- src/USER-OMP/bond_morse_omp.cpp | 2 +- src/USER-OMP/bond_nonlinear_omp.cpp | 2 +- src/USER-OMP/bond_quartic_omp.cpp | 2 +- src/USER-OMP/bond_table_omp.cpp | 2 +- src/USER-OMP/dihedral_charmm_omp.cpp | 2 +- src/USER-OMP/dihedral_class2_omp.cpp | 2 +- src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp | 2 +- src/USER-OMP/dihedral_fourier_omp.cpp | 2 +- src/USER-OMP/dihedral_harmonic_omp.cpp | 2 +- src/USER-OMP/dihedral_helix_omp.cpp | 2 +- src/USER-OMP/dihedral_multi_harmonic_omp.cpp | 2 +- src/USER-OMP/dihedral_nharmonic_omp.cpp | 2 +- src/USER-OMP/dihedral_opls_omp.cpp | 2 +- src/USER-OMP/dihedral_quadratic_omp.cpp | 2 +- src/USER-OMP/dihedral_table_omp.cpp | 3 ++- src/USER-OMP/domain_omp.cpp | 1 - src/USER-OMP/fix_gravity_omp.cpp | 2 +- src/USER-OMP/fix_nh_omp.cpp | 4 +--- src/USER-OMP/fix_nh_sphere_omp.cpp | 3 --- src/USER-OMP/fix_nvt_sllod_omp.cpp | 5 +++-- src/USER-OMP/fix_omp.cpp | 10 +++++----- src/USER-OMP/fix_qeq_reax_omp.cpp | 2 +- src/USER-OMP/fix_rigid_nh_omp.cpp | 5 ++--- src/USER-OMP/fix_rigid_nph_omp.cpp | 2 +- src/USER-OMP/fix_rigid_npt_omp.cpp | 2 +- src/USER-OMP/fix_rigid_omp.cpp | 7 +++---- src/USER-OMP/fix_rigid_small_omp.cpp | 1 + src/USER-OMP/improper_class2_omp.cpp | 2 +- src/USER-OMP/improper_cossq_omp.cpp | 2 +- src/USER-OMP/improper_cvff_omp.cpp | 2 +- src/USER-OMP/improper_fourier_omp.cpp | 2 +- src/USER-OMP/improper_harmonic_omp.cpp | 2 +- src/USER-OMP/improper_ring_omp.cpp | 2 +- src/USER-OMP/improper_umbrella_omp.cpp | 2 +- src/USER-OMP/msm_cg_omp.cpp | 4 ++-- src/USER-OMP/msm_omp.cpp | 3 ++- src/USER-OMP/npair_full_bin_atomonly_omp.cpp | 1 + src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp | 2 +- src/USER-OMP/npair_halffull_newtoff_omp.cpp | 2 +- src/USER-OMP/npair_halffull_newton_omp.cpp | 2 +- src/USER-OMP/pair_brownian_omp.cpp | 3 ++- src/USER-OMP/pair_brownian_poly_omp.cpp | 2 +- src/USER-OMP/pair_lj_cut_thole_long_omp.cpp | 3 ++- src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp | 2 +- src/USER-OMP/pair_lubricate_poly_omp.cpp | 2 +- src/USER-OMP/pppm_cg_omp.cpp | 3 ++- src/USER-OMP/pppm_disp_omp.cpp | 3 ++- src/USER-OMP/pppm_disp_tip4p_omp.cpp | 3 ++- src/USER-OMP/pppm_omp.cpp | 3 ++- src/USER-OMP/respa_omp.cpp | 3 ++- src/USER-OMP/thr_data.h | 8 ++------ src/USER-OMP/thr_omp.cpp | 2 -- src/USER-OMP/thr_omp.h | 9 +++++---- src/special.cpp | 2 +- 76 files changed, 109 insertions(+), 158 deletions(-) diff --git a/src/USER-OMP/angle_charmm_omp.cpp b/src/USER-OMP/angle_charmm_omp.cpp index 118ba00226..f135446915 100644 --- a/src/USER-OMP/angle_charmm_omp.cpp +++ b/src/USER-OMP/angle_charmm_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_charmm_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_class2_omp.cpp b/src/USER-OMP/angle_class2_omp.cpp index e072d136e1..0cf5489663 100644 --- a/src/USER-OMP/angle_class2_omp.cpp +++ b/src/USER-OMP/angle_class2_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_class2_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_delta_omp.cpp b/src/USER-OMP/angle_cosine_delta_omp.cpp index a6dfb20433..7f4d994c4f 100644 --- a/src/USER-OMP/angle_cosine_delta_omp.cpp +++ b/src/USER-OMP/angle_cosine_delta_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_delta_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_omp.cpp b/src/USER-OMP/angle_cosine_omp.cpp index 9097c8569c..0543c94799 100644 --- a/src/USER-OMP/angle_cosine_omp.cpp +++ b/src/USER-OMP/angle_cosine_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_periodic_omp.cpp b/src/USER-OMP/angle_cosine_periodic_omp.cpp index 3fcea7ad1d..907315f83b 100644 --- a/src/USER-OMP/angle_cosine_periodic_omp.cpp +++ b/src/USER-OMP/angle_cosine_periodic_omp.cpp @@ -16,20 +16,16 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_periodic_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" +#include "timer.h" #include "math_special.h" -#include - #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace MathSpecial; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_shift_exp_omp.cpp b/src/USER-OMP/angle_cosine_shift_exp_omp.cpp index 6bd2feb023..6c42319905 100644 --- a/src/USER-OMP/angle_cosine_shift_exp_omp.cpp +++ b/src/USER-OMP/angle_cosine_shift_exp_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_shift_exp_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_shift_omp.cpp b/src/USER-OMP/angle_cosine_shift_omp.cpp index 56486faac1..2eea790595 100644 --- a/src/USER-OMP/angle_cosine_shift_omp.cpp +++ b/src/USER-OMP/angle_cosine_shift_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "math_const.h" diff --git a/src/USER-OMP/angle_cosine_squared_omp.cpp b/src/USER-OMP/angle_cosine_squared_omp.cpp index 6dd2a3bb3b..27c47b90d8 100644 --- a/src/USER-OMP/angle_cosine_squared_omp.cpp +++ b/src/USER-OMP/angle_cosine_squared_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_squared_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_dipole_omp.cpp b/src/USER-OMP/angle_dipole_omp.cpp index da2e819ee2..6af5b44a03 100644 --- a/src/USER-OMP/angle_dipole_omp.cpp +++ b/src/USER-OMP/angle_dipole_omp.cpp @@ -16,20 +16,16 @@ ------------------------------------------------------------------------- */ #include "angle_dipole_omp.h" +#include #include "atom.h" #include "comm.h" #include "error.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_fourier_omp.cpp b/src/USER-OMP/angle_fourier_omp.cpp index b2f9b47e05..52736ca60f 100644 --- a/src/USER-OMP/angle_fourier_omp.cpp +++ b/src/USER-OMP/angle_fourier_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "math_const.h" diff --git a/src/USER-OMP/angle_fourier_simple_omp.cpp b/src/USER-OMP/angle_fourier_simple_omp.cpp index 93532a30e5..71d0197b72 100644 --- a/src/USER-OMP/angle_fourier_simple_omp.cpp +++ b/src/USER-OMP/angle_fourier_simple_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_fourier_simple_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_harmonic_omp.cpp b/src/USER-OMP/angle_harmonic_omp.cpp index 824b254287..ee08bbd8ad 100644 --- a/src/USER-OMP/angle_harmonic_omp.cpp +++ b/src/USER-OMP/angle_harmonic_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_harmonic_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_quartic_omp.cpp b/src/USER-OMP/angle_quartic_omp.cpp index fff08ddb39..f97f39b16a 100644 --- a/src/USER-OMP/angle_quartic_omp.cpp +++ b/src/USER-OMP/angle_quartic_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "math_const.h" diff --git a/src/USER-OMP/angle_sdk_omp.cpp b/src/USER-OMP/angle_sdk_omp.cpp index e8c762092c..e0b1da0baf 100644 --- a/src/USER-OMP/angle_sdk_omp.cpp +++ b/src/USER-OMP/angle_sdk_omp.cpp @@ -16,20 +16,16 @@ ------------------------------------------------------------------------- */ #include "angle_sdk_omp.h" +#include #include "atom.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "comm.h" #include "force.h" -#include "math_const.h" - -#include - #include "lj_sdk_common.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace LJSDKParms; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_table_omp.cpp b/src/USER-OMP/angle_table_omp.cpp index d9d80b744d..4f6edf2073 100644 --- a/src/USER-OMP/angle_table_omp.cpp +++ b/src/USER-OMP/angle_table_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_table_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/bond_class2_omp.cpp b/src/USER-OMP/bond_class2_omp.cpp index fdd73c20b0..7d1b693faf 100644 --- a/src/USER-OMP/bond_class2_omp.cpp +++ b/src/USER-OMP/bond_class2_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_fene_expand_omp.cpp b/src/USER-OMP/bond_fene_expand_omp.cpp index a8eec11760..aefae6dcf7 100644 --- a/src/USER-OMP/bond_fene_expand_omp.cpp +++ b/src/USER-OMP/bond_fene_expand_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "error.h" #include "update.h" diff --git a/src/USER-OMP/bond_fene_omp.cpp b/src/USER-OMP/bond_fene_omp.cpp index be7dcd4b49..2b579114ba 100644 --- a/src/USER-OMP/bond_fene_omp.cpp +++ b/src/USER-OMP/bond_fene_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "error.h" #include "update.h" diff --git a/src/USER-OMP/bond_gromos_omp.cpp b/src/USER-OMP/bond_gromos_omp.cpp index 8f0926c0e9..88ef1dc23e 100644 --- a/src/USER-OMP/bond_gromos_omp.cpp +++ b/src/USER-OMP/bond_gromos_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_harmonic_omp.cpp b/src/USER-OMP/bond_harmonic_omp.cpp index a3bb69c53c..5515284f9a 100644 --- a/src/USER-OMP/bond_harmonic_omp.cpp +++ b/src/USER-OMP/bond_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp b/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp index 5c16e27a32..a871fa8c04 100644 --- a/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp +++ b/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_harmonic_shift_omp.cpp b/src/USER-OMP/bond_harmonic_shift_omp.cpp index 39e957c137..4117da9159 100644 --- a/src/USER-OMP/bond_harmonic_shift_omp.cpp +++ b/src/USER-OMP/bond_harmonic_shift_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_morse_omp.cpp b/src/USER-OMP/bond_morse_omp.cpp index c0203de0d6..e6526dc8dc 100644 --- a/src/USER-OMP/bond_morse_omp.cpp +++ b/src/USER-OMP/bond_morse_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_nonlinear_omp.cpp b/src/USER-OMP/bond_nonlinear_omp.cpp index 8fa3daf8ab..0d1a648415 100644 --- a/src/USER-OMP/bond_nonlinear_omp.cpp +++ b/src/USER-OMP/bond_nonlinear_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_quartic_omp.cpp b/src/USER-OMP/bond_quartic_omp.cpp index fd0ccaf79d..60d3a5601c 100644 --- a/src/USER-OMP/bond_quartic_omp.cpp +++ b/src/USER-OMP/bond_quartic_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "pair.h" #include diff --git a/src/USER-OMP/bond_table_omp.cpp b/src/USER-OMP/bond_table_omp.cpp index 1616988385..8e1e792c73 100644 --- a/src/USER-OMP/bond_table_omp.cpp +++ b/src/USER-OMP/bond_table_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/dihedral_charmm_omp.cpp b/src/USER-OMP/dihedral_charmm_omp.cpp index b09863613e..49dbd54035 100644 --- a/src/USER-OMP/dihedral_charmm_omp.cpp +++ b/src/USER-OMP/dihedral_charmm_omp.cpp @@ -21,7 +21,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "pair.h" #include "update.h" diff --git a/src/USER-OMP/dihedral_class2_omp.cpp b/src/USER-OMP/dihedral_class2_omp.cpp index 03ac9d9bab..6c2bc02ff4 100644 --- a/src/USER-OMP/dihedral_class2_omp.cpp +++ b/src/USER-OMP/dihedral_class2_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp b/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp index c64cad9fc3..d77e9d6b3e 100644 --- a/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp +++ b/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_fourier_omp.cpp b/src/USER-OMP/dihedral_fourier_omp.cpp index 94bdae3795..e853f56051 100644 --- a/src/USER-OMP/dihedral_fourier_omp.cpp +++ b/src/USER-OMP/dihedral_fourier_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_harmonic_omp.cpp b/src/USER-OMP/dihedral_harmonic_omp.cpp index 10ccbd3d9f..84aa584d9e 100644 --- a/src/USER-OMP/dihedral_harmonic_omp.cpp +++ b/src/USER-OMP/dihedral_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_helix_omp.cpp b/src/USER-OMP/dihedral_helix_omp.cpp index 8c8e29cac0..51b07754e2 100644 --- a/src/USER-OMP/dihedral_helix_omp.cpp +++ b/src/USER-OMP/dihedral_helix_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "math_const.h" diff --git a/src/USER-OMP/dihedral_multi_harmonic_omp.cpp b/src/USER-OMP/dihedral_multi_harmonic_omp.cpp index 38961e1746..4cb6919a96 100644 --- a/src/USER-OMP/dihedral_multi_harmonic_omp.cpp +++ b/src/USER-OMP/dihedral_multi_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_nharmonic_omp.cpp b/src/USER-OMP/dihedral_nharmonic_omp.cpp index e74238265d..203884531b 100644 --- a/src/USER-OMP/dihedral_nharmonic_omp.cpp +++ b/src/USER-OMP/dihedral_nharmonic_omp.cpp @@ -20,10 +20,10 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "error.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/dihedral_opls_omp.cpp b/src/USER-OMP/dihedral_opls_omp.cpp index 64eaffe6fe..af12bb866e 100644 --- a/src/USER-OMP/dihedral_opls_omp.cpp +++ b/src/USER-OMP/dihedral_opls_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_quadratic_omp.cpp b/src/USER-OMP/dihedral_quadratic_omp.cpp index 8df622b847..8cea62aaea 100644 --- a/src/USER-OMP/dihedral_quadratic_omp.cpp +++ b/src/USER-OMP/dihedral_quadratic_omp.cpp @@ -20,10 +20,10 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "error.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/dihedral_table_omp.cpp b/src/USER-OMP/dihedral_table_omp.cpp index 792ee90c26..928af079e8 100644 --- a/src/USER-OMP/dihedral_table_omp.cpp +++ b/src/USER-OMP/dihedral_table_omp.cpp @@ -22,11 +22,12 @@ #include "dihedral_table_omp.h" #include "atom.h" #include "comm.h" -#include "neighbor.h" #include "domain.h" +#include "neighbor.h" #include "force.h" #include "update.h" #include "error.h" +#include "timer.h" #include "math_const.h" #include "math_extra.h" diff --git a/src/USER-OMP/domain_omp.cpp b/src/USER-OMP/domain_omp.cpp index 584e56b1f0..a18931c551 100644 --- a/src/USER-OMP/domain_omp.cpp +++ b/src/USER-OMP/domain_omp.cpp @@ -15,7 +15,6 @@ Contributing author : Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include "domain.h" #include "accelerator_omp.h" #include "atom.h" diff --git a/src/USER-OMP/fix_gravity_omp.cpp b/src/USER-OMP/fix_gravity_omp.cpp index eae918ec52..ae00c44ffb 100644 --- a/src/USER-OMP/fix_gravity_omp.cpp +++ b/src/USER-OMP/fix_gravity_omp.cpp @@ -22,7 +22,7 @@ #include "fix_gravity_omp.h" #include "atom.h" #include "update.h" -#include "domain.h" +#include "timer.h" #include "input.h" #include "modify.h" #include "respa.h" diff --git a/src/USER-OMP/fix_nh_omp.cpp b/src/USER-OMP/fix_nh_omp.cpp index 76a47b71fd..2abd739f71 100644 --- a/src/USER-OMP/fix_nh_omp.cpp +++ b/src/USER-OMP/fix_nh_omp.cpp @@ -16,15 +16,13 @@ ------------------------------------------------------------------------- */ #include "fix_nh_omp.h" +#include #include "atom.h" #include "compute.h" #include "domain.h" #include "error.h" #include "modify.h" -#include -#include - using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_nh_sphere_omp.cpp b/src/USER-OMP/fix_nh_sphere_omp.cpp index a32f0f8b51..64bc536bb0 100644 --- a/src/USER-OMP/fix_nh_sphere_omp.cpp +++ b/src/USER-OMP/fix_nh_sphere_omp.cpp @@ -15,12 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "fix_nh_sphere_omp.h" #include "atom.h" -#include "atom_vec.h" #include "compute.h" -#include "group.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/fix_nvt_sllod_omp.cpp b/src/USER-OMP/fix_nvt_sllod_omp.cpp index e439647c12..6944cf15af 100644 --- a/src/USER-OMP/fix_nvt_sllod_omp.cpp +++ b/src/USER-OMP/fix_nvt_sllod_omp.cpp @@ -15,18 +15,19 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_nvt_sllod_omp.h" #include #include -#include "fix_nvt_sllod_omp.h" #include "math_extra.h" #include "atom.h" -#include "domain.h" #include "group.h" #include "modify.h" #include "fix.h" #include "fix_deform.h" #include "compute.h" #include "error.h" +#include "domain.h" +#include "timer.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_omp.cpp b/src/USER-OMP/fix_omp.cpp index a4587b1c14..1fca1e739b 100644 --- a/src/USER-OMP/fix_omp.cpp +++ b/src/USER-OMP/fix_omp.cpp @@ -24,13 +24,10 @@ #include "neigh_request.h" #include "universe.h" #include "update.h" -#include "integrate.h" -#include "min.h" #include "timer.h" #include "fix_omp.h" #include "thr_data.h" -#include "thr_omp.h" #include "pair_hybrid.h" #include "bond_hybrid.h" @@ -40,8 +37,11 @@ #include "kspace.h" #include -#include -#include + +#if defined(_OPENMP) +#include +#endif + #include "suffix.h" diff --git a/src/USER-OMP/fix_qeq_reax_omp.cpp b/src/USER-OMP/fix_qeq_reax_omp.cpp index 45da91305d..5c50c54bff 100644 --- a/src/USER-OMP/fix_qeq_reax_omp.cpp +++ b/src/USER-OMP/fix_qeq_reax_omp.cpp @@ -39,7 +39,7 @@ #include "pair_reaxc_omp.h" #include "atom.h" #include "comm.h" -#include "domain.h" +#include "timer.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/USER-OMP/fix_rigid_nh_omp.cpp b/src/USER-OMP/fix_rigid_nh_omp.cpp index e6a6e065bf..74b2a92775 100644 --- a/src/USER-OMP/fix_rigid_nh_omp.cpp +++ b/src/USER-OMP/fix_rigid_nh_omp.cpp @@ -15,11 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_rigid_nh_omp.h" #include #include - -#include "fix_rigid_nh_omp.h" - #include "atom.h" #include "atom_vec_ellipsoid.h" #include "atom_vec_line.h" @@ -32,6 +30,7 @@ #include "kspace.h" #include "modify.h" #include "update.h" +#include "timer.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/fix_rigid_nph_omp.cpp b/src/USER-OMP/fix_rigid_nph_omp.cpp index 7db45ed9bf..af59b65996 100644 --- a/src/USER-OMP/fix_rigid_nph_omp.cpp +++ b/src/USER-OMP/fix_rigid_nph_omp.cpp @@ -19,7 +19,7 @@ #include #include "fix_rigid_nph_omp.h" -#include "domain.h" +#include "timer.h" #include "modify.h" #include "error.h" diff --git a/src/USER-OMP/fix_rigid_npt_omp.cpp b/src/USER-OMP/fix_rigid_npt_omp.cpp index a041706f38..744b27ce01 100644 --- a/src/USER-OMP/fix_rigid_npt_omp.cpp +++ b/src/USER-OMP/fix_rigid_npt_omp.cpp @@ -19,7 +19,7 @@ #include #include "fix_rigid_npt_omp.h" -#include "domain.h" +#include "timer.h" #include "modify.h" #include "error.h" diff --git a/src/USER-OMP/fix_rigid_omp.cpp b/src/USER-OMP/fix_rigid_omp.cpp index 20478b3ca1..2e97adab35 100644 --- a/src/USER-OMP/fix_rigid_omp.cpp +++ b/src/USER-OMP/fix_rigid_omp.cpp @@ -15,18 +15,17 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_rigid_omp.h" #include #include - -#include "fix_rigid_omp.h" - #include "atom.h" #include "atom_vec_ellipsoid.h" #include "atom_vec_line.h" #include "atom_vec_tri.h" #include "comm.h" -#include "domain.h" #include "error.h" +#include "domain.h" +#include "timer.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/fix_rigid_small_omp.cpp b/src/USER-OMP/fix_rigid_small_omp.cpp index 1f6173497d..f8fea815c8 100644 --- a/src/USER-OMP/fix_rigid_small_omp.cpp +++ b/src/USER-OMP/fix_rigid_small_omp.cpp @@ -25,6 +25,7 @@ #include "atom_vec_tri.h" #include "comm.h" #include "domain.h" +#include "timer.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/improper_class2_omp.cpp b/src/USER-OMP/improper_class2_omp.cpp index c2b493f425..3bff179b44 100644 --- a/src/USER-OMP/improper_class2_omp.cpp +++ b/src/USER-OMP/improper_class2_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_cossq_omp.cpp b/src/USER-OMP/improper_cossq_omp.cpp index 3b328e5b78..0f99f2732f 100644 --- a/src/USER-OMP/improper_cossq_omp.cpp +++ b/src/USER-OMP/improper_cossq_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_cvff_omp.cpp b/src/USER-OMP/improper_cvff_omp.cpp index fe1fc45bec..fdc29c74b1 100644 --- a/src/USER-OMP/improper_cvff_omp.cpp +++ b/src/USER-OMP/improper_cvff_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_fourier_omp.cpp b/src/USER-OMP/improper_fourier_omp.cpp index b5af428cb9..b49b895c78 100644 --- a/src/USER-OMP/improper_fourier_omp.cpp +++ b/src/USER-OMP/improper_fourier_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_harmonic_omp.cpp b/src/USER-OMP/improper_harmonic_omp.cpp index 6e02d0968e..32e837fdfe 100644 --- a/src/USER-OMP/improper_harmonic_omp.cpp +++ b/src/USER-OMP/improper_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_ring_omp.cpp b/src/USER-OMP/improper_ring_omp.cpp index e198b99337..6d6c1094ec 100644 --- a/src/USER-OMP/improper_ring_omp.cpp +++ b/src/USER-OMP/improper_ring_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_umbrella_omp.cpp b/src/USER-OMP/improper_umbrella_omp.cpp index ceaca35074..f3fdf4570f 100644 --- a/src/USER-OMP/improper_umbrella_omp.cpp +++ b/src/USER-OMP/improper_umbrella_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/msm_cg_omp.cpp b/src/USER-OMP/msm_cg_omp.cpp index 8a920e05d5..94c64cd0cf 100644 --- a/src/USER-OMP/msm_cg_omp.cpp +++ b/src/USER-OMP/msm_cg_omp.cpp @@ -16,6 +16,7 @@ Original MSM class by: Paul Crozier, Stan Moore, Stephen Bond, (all SNL) ------------------------------------------------------------------------- */ +#include "msm_cg_omp.h" #include #include #include @@ -29,9 +30,8 @@ #include "force.h" #include "neighbor.h" #include "memory.h" -#include "msm_cg_omp.h" - #include "math_const.h" +#include "timer.h" using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/USER-OMP/msm_omp.cpp b/src/USER-OMP/msm_omp.cpp index 74cbb56be7..51aaa35d63 100644 --- a/src/USER-OMP/msm_omp.cpp +++ b/src/USER-OMP/msm_omp.cpp @@ -16,6 +16,7 @@ ------------------------------------------------------------------------- */ #include "msm_omp.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" @@ -23,8 +24,8 @@ #include "force.h" #include "memory.h" #include "math_const.h" +#include "timer.h" -#include #if defined(_OPENMP) #include diff --git a/src/USER-OMP/npair_full_bin_atomonly_omp.cpp b/src/USER-OMP/npair_full_bin_atomonly_omp.cpp index d9e0fb9297..a6a3f3e748 100644 --- a/src/USER-OMP/npair_full_bin_atomonly_omp.cpp +++ b/src/USER-OMP/npair_full_bin_atomonly_omp.cpp @@ -20,6 +20,7 @@ #include "domain.h" #include "my_page.h" #include "error.h" +#include "timer.h" using namespace LAMMPS_NS; using namespace NeighConst; diff --git a/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp b/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp index 02d98ff6ab..5a87ad1ea6 100644 --- a/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp +++ b/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp @@ -18,7 +18,7 @@ #include "atom.h" #include "atom_vec.h" #include "molecule.h" -#include "domain.h" +#include "timer.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/npair_halffull_newtoff_omp.cpp b/src/USER-OMP/npair_halffull_newtoff_omp.cpp index 947e4e1ad2..6f90f82752 100644 --- a/src/USER-OMP/npair_halffull_newtoff_omp.cpp +++ b/src/USER-OMP/npair_halffull_newtoff_omp.cpp @@ -18,7 +18,7 @@ #include "atom.h" #include "atom_vec.h" #include "molecule.h" -#include "domain.h" +#include "timer.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/npair_halffull_newton_omp.cpp b/src/USER-OMP/npair_halffull_newton_omp.cpp index 6e158d372d..6cf8ab8ac2 100644 --- a/src/USER-OMP/npair_halffull_newton_omp.cpp +++ b/src/USER-OMP/npair_halffull_newton_omp.cpp @@ -18,7 +18,7 @@ #include "atom.h" #include "atom_vec.h" #include "molecule.h" -#include "domain.h" +#include "timer.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/pair_brownian_omp.cpp b/src/USER-OMP/pair_brownian_omp.cpp index cef9fb0955..6367976c7d 100644 --- a/src/USER-OMP/pair_brownian_omp.cpp +++ b/src/USER-OMP/pair_brownian_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_brownian_omp.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" @@ -26,6 +26,7 @@ #include "random_mars.h" #include "math_const.h" #include "math_special.h" +#include "timer.h" #include "fix_wall.h" diff --git a/src/USER-OMP/pair_brownian_poly_omp.cpp b/src/USER-OMP/pair_brownian_poly_omp.cpp index 239a820242..dcb4124634 100644 --- a/src/USER-OMP/pair_brownian_poly_omp.cpp +++ b/src/USER-OMP/pair_brownian_poly_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_brownian_poly_omp.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp b/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp index d0db6262b1..87d637e80d 100644 --- a/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp +++ b/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp @@ -22,6 +22,7 @@ #include #include "atom.h" #include "comm.h" +#include "domain.h" #include "fix_drude.h" #include "force.h" #include "neighbor.h" @@ -30,7 +31,7 @@ #include "math_const.h" #include "error.h" #include "suffix.h" -#include "domain.h" +#include "timer.h" using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp b/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp index e2c1da1a89..18fc207015 100644 --- a/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp +++ b/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_lj_cut_tip4p_long_omp.h" +#include #include "atom.h" #include "domain.h" #include "comm.h" diff --git a/src/USER-OMP/pair_lubricate_poly_omp.cpp b/src/USER-OMP/pair_lubricate_poly_omp.cpp index 3a5f03364d..04ac59b121 100644 --- a/src/USER-OMP/pair_lubricate_poly_omp.cpp +++ b/src/USER-OMP/pair_lubricate_poly_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_lubricate_poly_omp.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/USER-OMP/pppm_cg_omp.cpp b/src/USER-OMP/pppm_cg_omp.cpp index 2b4619f685..f20fa37683 100644 --- a/src/USER-OMP/pppm_cg_omp.cpp +++ b/src/USER-OMP/pppm_cg_omp.cpp @@ -15,9 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_cg_omp.h" #include #include -#include "pppm_cg_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" @@ -28,6 +28,7 @@ #include "memory.h" #include "math_const.h" #include "math_special.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pppm_disp_omp.cpp b/src/USER-OMP/pppm_disp_omp.cpp index 435341a31c..295bd66266 100644 --- a/src/USER-OMP/pppm_disp_omp.cpp +++ b/src/USER-OMP/pppm_disp_omp.cpp @@ -16,15 +16,16 @@ Rolf Isele-Holder (RWTH Aachen University) ------------------------------------------------------------------------- */ +#include "pppm_disp_omp.h" #include #include -#include "pppm_disp_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" #include "force.h" #include "memory.h" #include "math_const.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pppm_disp_tip4p_omp.cpp b/src/USER-OMP/pppm_disp_tip4p_omp.cpp index a53c5b2ac5..04dec7365e 100644 --- a/src/USER-OMP/pppm_disp_tip4p_omp.cpp +++ b/src/USER-OMP/pppm_disp_tip4p_omp.cpp @@ -15,9 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_disp_tip4p_omp.h" #include #include -#include "pppm_disp_tip4p_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" @@ -27,6 +27,7 @@ #include "memory.h" #include "math_const.h" #include "math_special.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pppm_omp.cpp b/src/USER-OMP/pppm_omp.cpp index 66190b3f51..73b257efa9 100644 --- a/src/USER-OMP/pppm_omp.cpp +++ b/src/USER-OMP/pppm_omp.cpp @@ -15,9 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_omp.h" #include #include -#include "pppm_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" @@ -27,6 +27,7 @@ #include "memory.h" #include "math_const.h" #include "math_special.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/respa_omp.cpp b/src/USER-OMP/respa_omp.cpp index 9c8555c66d..4a7757723f 100644 --- a/src/USER-OMP/respa_omp.cpp +++ b/src/USER-OMP/respa_omp.cpp @@ -19,9 +19,9 @@ #include #include "respa_omp.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "atom.h" +#include "domain.h" #include "force.h" #include "pair.h" #include "bond.h" @@ -37,6 +37,7 @@ #include "timer.h" #include "memory.h" #include "error.h" +#include "timer.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/thr_data.h b/src/USER-OMP/thr_data.h index 3cea1b0018..edff17cad3 100644 --- a/src/USER-OMP/thr_data.h +++ b/src/USER-OMP/thr_data.h @@ -18,10 +18,6 @@ #ifndef LMP_THR_DATA_H #define LMP_THR_DATA_H -#if defined(_OPENMP) -#include -#endif - #include "timer.h" namespace LAMMPS_NS { @@ -35,7 +31,7 @@ class ThrData { public: ThrData(int tid, class Timer *t); - ~ThrData() { delete _timer; _timer = NULL; }; + ~ThrData() { delete _timer; _timer = nullptr; }; void check_tid(int); // thread id consistency check int get_tid() const { return _tid; }; // our thread id. @@ -140,7 +136,7 @@ class ThrData { // disabled default methods private: - ThrData() : _tid(-1), _timer(NULL) {}; + ThrData() : _tid(-1), _timer(nullptr) {}; }; //////////////////////////////////////////////////////////////////////// diff --git a/src/USER-OMP/thr_omp.cpp b/src/USER-OMP/thr_omp.cpp index 22f751e6c0..51030358d3 100644 --- a/src/USER-OMP/thr_omp.cpp +++ b/src/USER-OMP/thr_omp.cpp @@ -22,7 +22,6 @@ #include "comm.h" #include "error.h" #include "force.h" -#include "memory.h" #include "modify.h" #include "neighbor.h" #include "timer.h" @@ -34,7 +33,6 @@ #include "angle.h" #include "dihedral.h" #include "improper.h" -#include "kspace.h" #include "compute.h" #include "math_const.h" diff --git a/src/USER-OMP/thr_omp.h b/src/USER-OMP/thr_omp.h index 87d921290e..062d77bc0e 100644 --- a/src/USER-OMP/thr_omp.h +++ b/src/USER-OMP/thr_omp.h @@ -18,10 +18,13 @@ #ifndef LMP_THR_OMP_H #define LMP_THR_OMP_H +#if defined(_OPENMP) +#include +#endif #include "pointers.h" #include "error.h" -#include "fix_omp.h" -#include "thr_data.h" +#include "fix_omp.h" // IWYU pragma: export +#include "thr_data.h" // IWYU pragma: export namespace LAMMPS_NS { @@ -31,8 +34,6 @@ class Bond; class Angle; class Dihedral; class Improper; -class KSpace; -class Fix; class ThrOMP { diff --git a/src/special.cpp b/src/special.cpp index b64aa96e2b..3dd817bc7f 100644 --- a/src/special.cpp +++ b/src/special.cpp @@ -19,7 +19,7 @@ #include "comm.h" #include "modify.h" #include "fix.h" -#include "accelerator_kokkos.h" +#include "accelerator_kokkos.h" // IWYU pragma: export #include "atom_masks.h" #include "memory.h" From b4f60ef477d86cf541bb10d7e3262e03c3fed036 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 16:51:48 -0400 Subject: [PATCH 71/79] starting to work on includes in USER-OMP --- src/USER-OMP/angle_charmm_omp.cpp | 8 ++------ src/USER-OMP/angle_class2_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_delta_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_periodic_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_shift_exp_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_shift_omp.cpp | 8 ++------ src/USER-OMP/angle_cosine_squared_omp.cpp | 8 ++------ src/USER-OMP/angle_dipole_omp.cpp | 8 ++------ src/USER-OMP/angle_fourier_omp.cpp | 8 ++------ src/USER-OMP/angle_fourier_simple_omp.cpp | 8 ++------ src/USER-OMP/angle_harmonic_omp.cpp | 8 ++------ src/USER-OMP/angle_quartic_omp.cpp | 8 ++------ src/USER-OMP/angle_sdk_omp.cpp | 8 ++------ src/USER-OMP/angle_table_omp.cpp | 8 ++------ src/USER-OMP/bond_class2_omp.cpp | 2 +- src/USER-OMP/bond_fene_expand_omp.cpp | 2 +- src/USER-OMP/bond_fene_omp.cpp | 2 +- src/USER-OMP/bond_gromos_omp.cpp | 4 +--- src/USER-OMP/bond_harmonic_omp.cpp | 2 +- src/USER-OMP/bond_harmonic_shift_cut_omp.cpp | 2 +- src/USER-OMP/bond_harmonic_shift_omp.cpp | 2 +- src/USER-OMP/bond_morse_omp.cpp | 2 +- src/USER-OMP/bond_nonlinear_omp.cpp | 2 +- src/USER-OMP/bond_quartic_omp.cpp | 2 +- src/USER-OMP/bond_table_omp.cpp | 2 +- src/USER-OMP/dihedral_charmm_omp.cpp | 5 ++--- src/USER-OMP/dihedral_class2_omp.cpp | 2 +- .../dihedral_cosine_shift_exp_omp.cpp | 2 +- src/USER-OMP/dihedral_fourier_omp.cpp | 6 ++---- src/USER-OMP/dihedral_harmonic_omp.cpp | 2 +- src/USER-OMP/dihedral_helix_omp.cpp | 2 +- src/USER-OMP/dihedral_multi_harmonic_omp.cpp | 2 +- src/USER-OMP/dihedral_nharmonic_omp.cpp | 2 +- src/USER-OMP/dihedral_opls_omp.cpp | 2 +- src/USER-OMP/dihedral_quadratic_omp.cpp | 2 +- src/USER-OMP/dihedral_table_omp.cpp | 11 +++-------- src/USER-OMP/domain_omp.cpp | 1 - src/USER-OMP/ewald_omp.cpp | 7 +++---- src/USER-OMP/fix_gravity_omp.cpp | 7 ------- src/USER-OMP/fix_neigh_history_omp.cpp | 7 +------ src/USER-OMP/fix_nh_omp.cpp | 4 +--- src/USER-OMP/fix_nh_sphere_omp.cpp | 3 --- src/USER-OMP/fix_nve_omp.cpp | 1 - src/USER-OMP/fix_nve_sphere_omp.cpp | 8 +------- src/USER-OMP/fix_nvt_sllod_omp.cpp | 5 ++--- src/USER-OMP/fix_omp.cpp | 10 +++++----- src/USER-OMP/fix_qeq_comb_omp.cpp | 8 ++------ src/USER-OMP/fix_qeq_reax_omp.cpp | 19 +++++++------------ src/USER-OMP/fix_rigid_nh_omp.cpp | 5 ++--- src/USER-OMP/fix_rigid_nph_omp.cpp | 3 +-- src/USER-OMP/fix_rigid_npt_omp.cpp | 3 +-- src/USER-OMP/fix_rigid_omp.cpp | 9 ++++----- src/USER-OMP/fix_rigid_small_omp.cpp | 4 +--- src/USER-OMP/improper_class2_omp.cpp | 2 +- src/USER-OMP/improper_cossq_omp.cpp | 2 +- src/USER-OMP/improper_cvff_omp.cpp | 2 +- src/USER-OMP/improper_fourier_omp.cpp | 2 +- src/USER-OMP/improper_harmonic_omp.cpp | 2 +- src/USER-OMP/improper_ring_omp.cpp | 6 ++---- src/USER-OMP/improper_umbrella_omp.cpp | 2 +- src/USER-OMP/msm_cg_omp.cpp | 10 ++++++---- src/USER-OMP/msm_omp.cpp | 8 ++------ src/USER-OMP/npair_full_bin_atomonly_omp.cpp | 2 -- src/USER-OMP/npair_full_bin_ghost_omp.cpp | 1 - src/USER-OMP/npair_full_multi_omp.cpp | 1 - src/USER-OMP/npair_full_nsq_ghost_omp.cpp | 1 - src/USER-OMP/npair_full_nsq_omp.cpp | 1 - .../npair_half_bin_atomonly_newton_omp.cpp | 3 --- .../npair_half_bin_newtoff_ghost_omp.cpp | 1 - src/USER-OMP/npair_half_bin_newtoff_omp.cpp | 1 - src/USER-OMP/npair_half_bin_newton_omp.cpp | 2 -- .../npair_half_bin_newton_tri_omp.cpp | 1 - src/USER-OMP/npair_half_multi_newtoff_omp.cpp | 1 - src/USER-OMP/npair_half_multi_newton_omp.cpp | 1 - src/USER-OMP/npair_halffull_newtoff_omp.cpp | 2 +- src/USER-OMP/npair_halffull_newton_omp.cpp | 2 +- src/USER-OMP/pair_brownian_omp.cpp | 3 ++- src/USER-OMP/pair_brownian_poly_omp.cpp | 2 +- src/USER-OMP/pair_lj_cut_thole_long_omp.cpp | 3 ++- src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp | 2 +- src/USER-OMP/pair_lubricate_poly_omp.cpp | 2 +- src/USER-OMP/pppm_cg_omp.cpp | 12 ++++++------ src/USER-OMP/pppm_disp_omp.cpp | 9 +++++++-- src/USER-OMP/pppm_disp_tip4p_omp.cpp | 11 +++++------ src/USER-OMP/pppm_omp.cpp | 11 +++++++---- src/USER-OMP/pppm_tip4p_omp.cpp | 9 ++++++--- src/USER-OMP/reaxc_multi_body_omp.cpp | 7 +++---- src/USER-OMP/reaxc_valence_angles_omp.cpp | 6 ++++-- src/USER-OMP/respa_omp.cpp | 9 ++------- src/USER-OMP/thr_data.h | 8 ++------ src/USER-OMP/thr_omp.cpp | 2 -- src/USER-OMP/thr_omp.h | 9 +++++---- src/USER-SMD/pair_smd_tlsph.cpp | 8 +++----- src/special.cpp | 2 +- 95 files changed, 163 insertions(+), 294 deletions(-) diff --git a/src/USER-OMP/angle_charmm_omp.cpp b/src/USER-OMP/angle_charmm_omp.cpp index 118ba00226..f135446915 100644 --- a/src/USER-OMP/angle_charmm_omp.cpp +++ b/src/USER-OMP/angle_charmm_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_charmm_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_class2_omp.cpp b/src/USER-OMP/angle_class2_omp.cpp index e072d136e1..0cf5489663 100644 --- a/src/USER-OMP/angle_class2_omp.cpp +++ b/src/USER-OMP/angle_class2_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_class2_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_delta_omp.cpp b/src/USER-OMP/angle_cosine_delta_omp.cpp index a6dfb20433..7f4d994c4f 100644 --- a/src/USER-OMP/angle_cosine_delta_omp.cpp +++ b/src/USER-OMP/angle_cosine_delta_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_delta_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_omp.cpp b/src/USER-OMP/angle_cosine_omp.cpp index 9097c8569c..0543c94799 100644 --- a/src/USER-OMP/angle_cosine_omp.cpp +++ b/src/USER-OMP/angle_cosine_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_periodic_omp.cpp b/src/USER-OMP/angle_cosine_periodic_omp.cpp index 3fcea7ad1d..907315f83b 100644 --- a/src/USER-OMP/angle_cosine_periodic_omp.cpp +++ b/src/USER-OMP/angle_cosine_periodic_omp.cpp @@ -16,20 +16,16 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_periodic_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" +#include "timer.h" #include "math_special.h" -#include - #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace MathSpecial; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_shift_exp_omp.cpp b/src/USER-OMP/angle_cosine_shift_exp_omp.cpp index 6bd2feb023..6c42319905 100644 --- a/src/USER-OMP/angle_cosine_shift_exp_omp.cpp +++ b/src/USER-OMP/angle_cosine_shift_exp_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_shift_exp_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_shift_omp.cpp b/src/USER-OMP/angle_cosine_shift_omp.cpp index 56486faac1..5c0afcf316 100644 --- a/src/USER-OMP/angle_cosine_shift_omp.cpp +++ b/src/USER-OMP/angle_cosine_shift_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_shift_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_cosine_squared_omp.cpp b/src/USER-OMP/angle_cosine_squared_omp.cpp index 6dd2a3bb3b..27c47b90d8 100644 --- a/src/USER-OMP/angle_cosine_squared_omp.cpp +++ b/src/USER-OMP/angle_cosine_squared_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_cosine_squared_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_dipole_omp.cpp b/src/USER-OMP/angle_dipole_omp.cpp index da2e819ee2..6af5b44a03 100644 --- a/src/USER-OMP/angle_dipole_omp.cpp +++ b/src/USER-OMP/angle_dipole_omp.cpp @@ -16,20 +16,16 @@ ------------------------------------------------------------------------- */ #include "angle_dipole_omp.h" +#include #include "atom.h" #include "comm.h" #include "error.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_fourier_omp.cpp b/src/USER-OMP/angle_fourier_omp.cpp index b2f9b47e05..98527c2028 100644 --- a/src/USER-OMP/angle_fourier_omp.cpp +++ b/src/USER-OMP/angle_fourier_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_fourier_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_fourier_simple_omp.cpp b/src/USER-OMP/angle_fourier_simple_omp.cpp index 93532a30e5..71d0197b72 100644 --- a/src/USER-OMP/angle_fourier_simple_omp.cpp +++ b/src/USER-OMP/angle_fourier_simple_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_fourier_simple_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_harmonic_omp.cpp b/src/USER-OMP/angle_harmonic_omp.cpp index 824b254287..ee08bbd8ad 100644 --- a/src/USER-OMP/angle_harmonic_omp.cpp +++ b/src/USER-OMP/angle_harmonic_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_harmonic_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_quartic_omp.cpp b/src/USER-OMP/angle_quartic_omp.cpp index fff08ddb39..5745948222 100644 --- a/src/USER-OMP/angle_quartic_omp.cpp +++ b/src/USER-OMP/angle_quartic_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_quartic_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_sdk_omp.cpp b/src/USER-OMP/angle_sdk_omp.cpp index e8c762092c..e0b1da0baf 100644 --- a/src/USER-OMP/angle_sdk_omp.cpp +++ b/src/USER-OMP/angle_sdk_omp.cpp @@ -16,20 +16,16 @@ ------------------------------------------------------------------------- */ #include "angle_sdk_omp.h" +#include #include "atom.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "comm.h" #include "force.h" -#include "math_const.h" - -#include - #include "lj_sdk_common.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace LJSDKParms; #define SMALL 0.001 diff --git a/src/USER-OMP/angle_table_omp.cpp b/src/USER-OMP/angle_table_omp.cpp index d9d80b744d..4f6edf2073 100644 --- a/src/USER-OMP/angle_table_omp.cpp +++ b/src/USER-OMP/angle_table_omp.cpp @@ -16,19 +16,15 @@ ------------------------------------------------------------------------- */ #include "angle_table_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include "math_const.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define SMALL 0.001 diff --git a/src/USER-OMP/bond_class2_omp.cpp b/src/USER-OMP/bond_class2_omp.cpp index fdd73c20b0..7d1b693faf 100644 --- a/src/USER-OMP/bond_class2_omp.cpp +++ b/src/USER-OMP/bond_class2_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_fene_expand_omp.cpp b/src/USER-OMP/bond_fene_expand_omp.cpp index a8eec11760..aefae6dcf7 100644 --- a/src/USER-OMP/bond_fene_expand_omp.cpp +++ b/src/USER-OMP/bond_fene_expand_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "error.h" #include "update.h" diff --git a/src/USER-OMP/bond_fene_omp.cpp b/src/USER-OMP/bond_fene_omp.cpp index be7dcd4b49..2b579114ba 100644 --- a/src/USER-OMP/bond_fene_omp.cpp +++ b/src/USER-OMP/bond_fene_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "error.h" #include "update.h" diff --git a/src/USER-OMP/bond_gromos_omp.cpp b/src/USER-OMP/bond_gromos_omp.cpp index 8f0926c0e9..ba23217a1f 100644 --- a/src/USER-OMP/bond_gromos_omp.cpp +++ b/src/USER-OMP/bond_gromos_omp.cpp @@ -20,9 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" - -#include +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/bond_harmonic_omp.cpp b/src/USER-OMP/bond_harmonic_omp.cpp index a3bb69c53c..5515284f9a 100644 --- a/src/USER-OMP/bond_harmonic_omp.cpp +++ b/src/USER-OMP/bond_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp b/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp index 5c16e27a32..a871fa8c04 100644 --- a/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp +++ b/src/USER-OMP/bond_harmonic_shift_cut_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_harmonic_shift_omp.cpp b/src/USER-OMP/bond_harmonic_shift_omp.cpp index 39e957c137..4117da9159 100644 --- a/src/USER-OMP/bond_harmonic_shift_omp.cpp +++ b/src/USER-OMP/bond_harmonic_shift_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_morse_omp.cpp b/src/USER-OMP/bond_morse_omp.cpp index c0203de0d6..e6526dc8dc 100644 --- a/src/USER-OMP/bond_morse_omp.cpp +++ b/src/USER-OMP/bond_morse_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_nonlinear_omp.cpp b/src/USER-OMP/bond_nonlinear_omp.cpp index 8fa3daf8ab..0d1a648415 100644 --- a/src/USER-OMP/bond_nonlinear_omp.cpp +++ b/src/USER-OMP/bond_nonlinear_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/bond_quartic_omp.cpp b/src/USER-OMP/bond_quartic_omp.cpp index fd0ccaf79d..60d3a5601c 100644 --- a/src/USER-OMP/bond_quartic_omp.cpp +++ b/src/USER-OMP/bond_quartic_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "pair.h" #include diff --git a/src/USER-OMP/bond_table_omp.cpp b/src/USER-OMP/bond_table_omp.cpp index 1616988385..8e1e792c73 100644 --- a/src/USER-OMP/bond_table_omp.cpp +++ b/src/USER-OMP/bond_table_omp.cpp @@ -20,7 +20,7 @@ #include "comm.h" #include "force.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include diff --git a/src/USER-OMP/dihedral_charmm_omp.cpp b/src/USER-OMP/dihedral_charmm_omp.cpp index b09863613e..95ad9af6a6 100644 --- a/src/USER-OMP/dihedral_charmm_omp.cpp +++ b/src/USER-OMP/dihedral_charmm_omp.cpp @@ -15,13 +15,12 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include -#include #include "dihedral_charmm_omp.h" +#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "pair.h" #include "update.h" diff --git a/src/USER-OMP/dihedral_class2_omp.cpp b/src/USER-OMP/dihedral_class2_omp.cpp index 03ac9d9bab..6c2bc02ff4 100644 --- a/src/USER-OMP/dihedral_class2_omp.cpp +++ b/src/USER-OMP/dihedral_class2_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp b/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp index c64cad9fc3..d77e9d6b3e 100644 --- a/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp +++ b/src/USER-OMP/dihedral_cosine_shift_exp_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_fourier_omp.cpp b/src/USER-OMP/dihedral_fourier_omp.cpp index 94bdae3795..93dbd773ca 100644 --- a/src/USER-OMP/dihedral_fourier_omp.cpp +++ b/src/USER-OMP/dihedral_fourier_omp.cpp @@ -15,20 +15,18 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "dihedral_fourier_omp.h" +#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" -#include "math_const.h" #include "suffix.h" using namespace LAMMPS_NS; -using namespace MathConst; #define TOLERANCE 0.05 diff --git a/src/USER-OMP/dihedral_harmonic_omp.cpp b/src/USER-OMP/dihedral_harmonic_omp.cpp index 10ccbd3d9f..84aa584d9e 100644 --- a/src/USER-OMP/dihedral_harmonic_omp.cpp +++ b/src/USER-OMP/dihedral_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_helix_omp.cpp b/src/USER-OMP/dihedral_helix_omp.cpp index 8c8e29cac0..51b07754e2 100644 --- a/src/USER-OMP/dihedral_helix_omp.cpp +++ b/src/USER-OMP/dihedral_helix_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "math_const.h" diff --git a/src/USER-OMP/dihedral_multi_harmonic_omp.cpp b/src/USER-OMP/dihedral_multi_harmonic_omp.cpp index 38961e1746..4cb6919a96 100644 --- a/src/USER-OMP/dihedral_multi_harmonic_omp.cpp +++ b/src/USER-OMP/dihedral_multi_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_nharmonic_omp.cpp b/src/USER-OMP/dihedral_nharmonic_omp.cpp index e74238265d..203884531b 100644 --- a/src/USER-OMP/dihedral_nharmonic_omp.cpp +++ b/src/USER-OMP/dihedral_nharmonic_omp.cpp @@ -20,10 +20,10 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "error.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/dihedral_opls_omp.cpp b/src/USER-OMP/dihedral_opls_omp.cpp index 64eaffe6fe..af12bb866e 100644 --- a/src/USER-OMP/dihedral_opls_omp.cpp +++ b/src/USER-OMP/dihedral_opls_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/dihedral_quadratic_omp.cpp b/src/USER-OMP/dihedral_quadratic_omp.cpp index 8df622b847..8cea62aaea 100644 --- a/src/USER-OMP/dihedral_quadratic_omp.cpp +++ b/src/USER-OMP/dihedral_quadratic_omp.cpp @@ -20,10 +20,10 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" #include "force.h" #include "update.h" #include "error.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/dihedral_table_omp.cpp b/src/USER-OMP/dihedral_table_omp.cpp index 792ee90c26..6b10027b9d 100644 --- a/src/USER-OMP/dihedral_table_omp.cpp +++ b/src/USER-OMP/dihedral_table_omp.cpp @@ -15,19 +15,14 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include -#include -#include - #include "dihedral_table_omp.h" +#include #include "atom.h" #include "comm.h" -#include "neighbor.h" #include "domain.h" +#include "neighbor.h" #include "force.h" -#include "update.h" -#include "error.h" - +#include "timer.h" #include "math_const.h" #include "math_extra.h" diff --git a/src/USER-OMP/domain_omp.cpp b/src/USER-OMP/domain_omp.cpp index 584e56b1f0..a18931c551 100644 --- a/src/USER-OMP/domain_omp.cpp +++ b/src/USER-OMP/domain_omp.cpp @@ -15,7 +15,6 @@ Contributing author : Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include "domain.h" #include "accelerator_omp.h" #include "atom.h" diff --git a/src/USER-OMP/ewald_omp.cpp b/src/USER-OMP/ewald_omp.cpp index b56fc25142..aadf63741d 100644 --- a/src/USER-OMP/ewald_omp.cpp +++ b/src/USER-OMP/ewald_omp.cpp @@ -15,15 +15,14 @@ Contributing authors: Roy Pollock (LLNL), Paul Crozier (SNL) ------------------------------------------------------------------------- */ -#include #include "ewald_omp.h" +#include +#include #include "atom.h" #include "comm.h" #include "force.h" #include "memory.h" - -#include - +#include "timer.h" #include "math_const.h" #include "suffix.h" diff --git a/src/USER-OMP/fix_gravity_omp.cpp b/src/USER-OMP/fix_gravity_omp.cpp index eae918ec52..fa6b698821 100644 --- a/src/USER-OMP/fix_gravity_omp.cpp +++ b/src/USER-OMP/fix_gravity_omp.cpp @@ -15,19 +15,12 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_gravity_omp.h" #include "atom.h" #include "update.h" -#include "domain.h" #include "input.h" #include "modify.h" -#include "respa.h" #include "variable.h" -#include "error.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_neigh_history_omp.cpp b/src/USER-OMP/fix_neigh_history_omp.cpp index be03e1d8f2..c2bc8af5e0 100644 --- a/src/USER-OMP/fix_neigh_history_omp.cpp +++ b/src/USER-OMP/fix_neigh_history_omp.cpp @@ -11,19 +11,14 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include #include "fix_neigh_history_omp.h" +#include #include "my_page.h" #include "atom.h" #include "comm.h" -#include "neighbor.h" #include "neigh_list.h" -#include "force.h" #include "pair.h" -#include "update.h" #include "memory.h" -#include "modify.h" #include "error.h" #if defined(_OPENMP) diff --git a/src/USER-OMP/fix_nh_omp.cpp b/src/USER-OMP/fix_nh_omp.cpp index 76a47b71fd..2abd739f71 100644 --- a/src/USER-OMP/fix_nh_omp.cpp +++ b/src/USER-OMP/fix_nh_omp.cpp @@ -16,15 +16,13 @@ ------------------------------------------------------------------------- */ #include "fix_nh_omp.h" +#include #include "atom.h" #include "compute.h" #include "domain.h" #include "error.h" #include "modify.h" -#include -#include - using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_nh_sphere_omp.cpp b/src/USER-OMP/fix_nh_sphere_omp.cpp index a32f0f8b51..64bc536bb0 100644 --- a/src/USER-OMP/fix_nh_sphere_omp.cpp +++ b/src/USER-OMP/fix_nh_sphere_omp.cpp @@ -15,12 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "fix_nh_sphere_omp.h" #include "atom.h" -#include "atom_vec.h" #include "compute.h" -#include "group.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/fix_nve_omp.cpp b/src/USER-OMP/fix_nve_omp.cpp index c61ad7155c..61ed82b16f 100644 --- a/src/USER-OMP/fix_nve_omp.cpp +++ b/src/USER-OMP/fix_nve_omp.cpp @@ -13,7 +13,6 @@ #include "fix_nve_omp.h" #include "atom.h" -#include "force.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_nve_sphere_omp.cpp b/src/USER-OMP/fix_nve_sphere_omp.cpp index 2286120bee..ccdd654874 100644 --- a/src/USER-OMP/fix_nve_sphere_omp.cpp +++ b/src/USER-OMP/fix_nve_sphere_omp.cpp @@ -11,16 +11,10 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_nve_sphere_omp.h" +#include #include "atom.h" -#include "atom_vec.h" -#include "update.h" -#include "respa.h" #include "force.h" -#include "error.h" #include "math_vector.h" #include "math_extra.h" diff --git a/src/USER-OMP/fix_nvt_sllod_omp.cpp b/src/USER-OMP/fix_nvt_sllod_omp.cpp index e439647c12..208dfb9432 100644 --- a/src/USER-OMP/fix_nvt_sllod_omp.cpp +++ b/src/USER-OMP/fix_nvt_sllod_omp.cpp @@ -15,18 +15,17 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include -#include #include "fix_nvt_sllod_omp.h" +#include #include "math_extra.h" #include "atom.h" -#include "domain.h" #include "group.h" #include "modify.h" #include "fix.h" #include "fix_deform.h" #include "compute.h" #include "error.h" +#include "domain.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_omp.cpp b/src/USER-OMP/fix_omp.cpp index a4587b1c14..1fca1e739b 100644 --- a/src/USER-OMP/fix_omp.cpp +++ b/src/USER-OMP/fix_omp.cpp @@ -24,13 +24,10 @@ #include "neigh_request.h" #include "universe.h" #include "update.h" -#include "integrate.h" -#include "min.h" #include "timer.h" #include "fix_omp.h" #include "thr_data.h" -#include "thr_omp.h" #include "pair_hybrid.h" #include "bond_hybrid.h" @@ -40,8 +37,11 @@ #include "kspace.h" #include -#include -#include + +#if defined(_OPENMP) +#include +#endif + #include "suffix.h" diff --git a/src/USER-OMP/fix_qeq_comb_omp.cpp b/src/USER-OMP/fix_qeq_comb_omp.cpp index 2f0a90a790..b0573dfa97 100644 --- a/src/USER-OMP/fix_qeq_comb_omp.cpp +++ b/src/USER-OMP/fix_qeq_comb_omp.cpp @@ -15,24 +15,20 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_qeq_comb_omp.h" #include #include #include -#include "fix_qeq_comb_omp.h" -#include "fix_omp.h" +#include "pair_comb.h" #include "atom.h" #include "comm.h" #include "force.h" #include "group.h" #include "memory.h" -#include "modify.h" #include "error.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "respa.h" #include "update.h" -#include "pair_comb_omp.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_qeq_reax_omp.cpp b/src/USER-OMP/fix_qeq_reax_omp.cpp index 45da91305d..55e2b73812 100644 --- a/src/USER-OMP/fix_qeq_reax_omp.cpp +++ b/src/USER-OMP/fix_qeq_reax_omp.cpp @@ -31,27 +31,22 @@ High Performance Computing Applications, to appear. ------------------------------------------------------------------------- */ -#include -#include -#include -#include #include "fix_qeq_reax_omp.h" -#include "pair_reaxc_omp.h" +#include +#include +#include "pair_reaxc.h" #include "atom.h" #include "comm.h" -#include "domain.h" -#include "neighbor.h" #include "neigh_list.h" -#include "neigh_request.h" #include "update.h" -#include "force.h" -#include "group.h" -#include "pair.h" -#include "respa.h" #include "memory.h" #include "error.h" #include "reaxc_defs.h" +#if defined(_OPENMP) +#include +#endif + using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-OMP/fix_rigid_nh_omp.cpp b/src/USER-OMP/fix_rigid_nh_omp.cpp index e6a6e065bf..74b2a92775 100644 --- a/src/USER-OMP/fix_rigid_nh_omp.cpp +++ b/src/USER-OMP/fix_rigid_nh_omp.cpp @@ -15,11 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "fix_rigid_nh_omp.h" #include #include - -#include "fix_rigid_nh_omp.h" - #include "atom.h" #include "atom_vec_ellipsoid.h" #include "atom_vec_line.h" @@ -32,6 +30,7 @@ #include "kspace.h" #include "modify.h" #include "update.h" +#include "timer.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/fix_rigid_nph_omp.cpp b/src/USER-OMP/fix_rigid_nph_omp.cpp index 7db45ed9bf..31d53868c8 100644 --- a/src/USER-OMP/fix_rigid_nph_omp.cpp +++ b/src/USER-OMP/fix_rigid_nph_omp.cpp @@ -17,9 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ -#include #include "fix_rigid_nph_omp.h" -#include "domain.h" +#include #include "modify.h" #include "error.h" diff --git a/src/USER-OMP/fix_rigid_npt_omp.cpp b/src/USER-OMP/fix_rigid_npt_omp.cpp index a041706f38..1e7c139d52 100644 --- a/src/USER-OMP/fix_rigid_npt_omp.cpp +++ b/src/USER-OMP/fix_rigid_npt_omp.cpp @@ -17,9 +17,8 @@ Miller et al., J Chem Phys. 116, 8649-8659 (2002) ------------------------------------------------------------------------- */ -#include #include "fix_rigid_npt_omp.h" -#include "domain.h" +#include #include "modify.h" #include "error.h" diff --git a/src/USER-OMP/fix_rigid_omp.cpp b/src/USER-OMP/fix_rigid_omp.cpp index 20478b3ca1..b807ddba7c 100644 --- a/src/USER-OMP/fix_rigid_omp.cpp +++ b/src/USER-OMP/fix_rigid_omp.cpp @@ -15,18 +15,17 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include -#include - #include "fix_rigid_omp.h" - +#include +#include +#include #include "atom.h" #include "atom_vec_ellipsoid.h" #include "atom_vec_line.h" #include "atom_vec_tri.h" #include "comm.h" -#include "domain.h" #include "error.h" +#include "domain.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/fix_rigid_small_omp.cpp b/src/USER-OMP/fix_rigid_small_omp.cpp index 1f6173497d..0aa15ee408 100644 --- a/src/USER-OMP/fix_rigid_small_omp.cpp +++ b/src/USER-OMP/fix_rigid_small_omp.cpp @@ -15,10 +15,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include - #include "fix_rigid_small_omp.h" - +#include #include "atom.h" #include "atom_vec_ellipsoid.h" #include "atom_vec_line.h" diff --git a/src/USER-OMP/improper_class2_omp.cpp b/src/USER-OMP/improper_class2_omp.cpp index c2b493f425..3bff179b44 100644 --- a/src/USER-OMP/improper_class2_omp.cpp +++ b/src/USER-OMP/improper_class2_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_cossq_omp.cpp b/src/USER-OMP/improper_cossq_omp.cpp index 3b328e5b78..0f99f2732f 100644 --- a/src/USER-OMP/improper_cossq_omp.cpp +++ b/src/USER-OMP/improper_cossq_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_cvff_omp.cpp b/src/USER-OMP/improper_cvff_omp.cpp index fe1fc45bec..fdc29c74b1 100644 --- a/src/USER-OMP/improper_cvff_omp.cpp +++ b/src/USER-OMP/improper_cvff_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_fourier_omp.cpp b/src/USER-OMP/improper_fourier_omp.cpp index b5af428cb9..b49b895c78 100644 --- a/src/USER-OMP/improper_fourier_omp.cpp +++ b/src/USER-OMP/improper_fourier_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_harmonic_omp.cpp b/src/USER-OMP/improper_harmonic_omp.cpp index 6e02d0968e..32e837fdfe 100644 --- a/src/USER-OMP/improper_harmonic_omp.cpp +++ b/src/USER-OMP/improper_harmonic_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/improper_ring_omp.cpp b/src/USER-OMP/improper_ring_omp.cpp index e198b99337..c8fe685faa 100644 --- a/src/USER-OMP/improper_ring_omp.cpp +++ b/src/USER-OMP/improper_ring_omp.cpp @@ -15,15 +15,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "improper_ring_omp.h" +#include #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" -#include "update.h" -#include "error.h" #include "math_special.h" #include "suffix.h" diff --git a/src/USER-OMP/improper_umbrella_omp.cpp b/src/USER-OMP/improper_umbrella_omp.cpp index ceaca35074..f3fdf4570f 100644 --- a/src/USER-OMP/improper_umbrella_omp.cpp +++ b/src/USER-OMP/improper_umbrella_omp.cpp @@ -20,7 +20,7 @@ #include "atom.h" #include "comm.h" #include "neighbor.h" -#include "domain.h" +#include "timer.h" #include "force.h" #include "update.h" #include "error.h" diff --git a/src/USER-OMP/msm_cg_omp.cpp b/src/USER-OMP/msm_cg_omp.cpp index 8a920e05d5..3c5439db5d 100644 --- a/src/USER-OMP/msm_cg_omp.cpp +++ b/src/USER-OMP/msm_cg_omp.cpp @@ -16,10 +16,10 @@ Original MSM class by: Paul Crozier, Stan Moore, Stephen Bond, (all SNL) ------------------------------------------------------------------------- */ +#include "msm_cg_omp.h" #include #include #include -#include #include #include "atom.h" @@ -29,12 +29,14 @@ #include "force.h" #include "neighbor.h" #include "memory.h" -#include "msm_cg_omp.h" +#include "thr_omp.h" +#include "timer.h" -#include "math_const.h" +#if defined(_OPENMP) +#include +#endif using namespace LAMMPS_NS; -using namespace MathConst; #define OFFSET 16384 #define SMALLQ 0.00001 diff --git a/src/USER-OMP/msm_omp.cpp b/src/USER-OMP/msm_omp.cpp index 74cbb56be7..81f84e8f6f 100644 --- a/src/USER-OMP/msm_omp.cpp +++ b/src/USER-OMP/msm_omp.cpp @@ -16,15 +16,11 @@ ------------------------------------------------------------------------- */ #include "msm_omp.h" -#include "atom.h" +#include #include "comm.h" #include "domain.h" #include "error.h" -#include "force.h" -#include "memory.h" -#include "math_const.h" - -#include +#include "timer.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/npair_full_bin_atomonly_omp.cpp b/src/USER-OMP/npair_full_bin_atomonly_omp.cpp index d9e0fb9297..0f791e204d 100644 --- a/src/USER-OMP/npair_full_bin_atomonly_omp.cpp +++ b/src/USER-OMP/npair_full_bin_atomonly_omp.cpp @@ -13,11 +13,9 @@ #include "npair_full_bin_atomonly_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/npair_full_bin_ghost_omp.cpp b/src/USER-OMP/npair_full_bin_ghost_omp.cpp index b915aca002..d541381143 100644 --- a/src/USER-OMP/npair_full_bin_ghost_omp.cpp +++ b/src/USER-OMP/npair_full_bin_ghost_omp.cpp @@ -13,7 +13,6 @@ #include "npair_full_bin_ghost_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_full_multi_omp.cpp b/src/USER-OMP/npair_full_multi_omp.cpp index 9bc196e17a..57b60f665b 100644 --- a/src/USER-OMP/npair_full_multi_omp.cpp +++ b/src/USER-OMP/npair_full_multi_omp.cpp @@ -13,7 +13,6 @@ #include "npair_full_multi_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_full_nsq_ghost_omp.cpp b/src/USER-OMP/npair_full_nsq_ghost_omp.cpp index b33f76bb22..242c4e300c 100644 --- a/src/USER-OMP/npair_full_nsq_ghost_omp.cpp +++ b/src/USER-OMP/npair_full_nsq_ghost_omp.cpp @@ -13,7 +13,6 @@ #include "npair_full_nsq_ghost_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_full_nsq_omp.cpp b/src/USER-OMP/npair_full_nsq_omp.cpp index 1d0f26d638..08a034d5ab 100644 --- a/src/USER-OMP/npair_full_nsq_omp.cpp +++ b/src/USER-OMP/npair_full_nsq_omp.cpp @@ -13,7 +13,6 @@ #include "npair_full_nsq_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp b/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp index 02d98ff6ab..a69779d96d 100644 --- a/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp +++ b/src/USER-OMP/npair_half_bin_atomonly_newton_omp.cpp @@ -13,12 +13,9 @@ #include "npair_half_bin_atomonly_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "domain.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/npair_half_bin_newtoff_ghost_omp.cpp b/src/USER-OMP/npair_half_bin_newtoff_ghost_omp.cpp index 24fe75ec55..5f8ffdab29 100644 --- a/src/USER-OMP/npair_half_bin_newtoff_ghost_omp.cpp +++ b/src/USER-OMP/npair_half_bin_newtoff_ghost_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_bin_newtoff_ghost_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_bin_newtoff_omp.cpp b/src/USER-OMP/npair_half_bin_newtoff_omp.cpp index ff74b54d7d..35807645cf 100644 --- a/src/USER-OMP/npair_half_bin_newtoff_omp.cpp +++ b/src/USER-OMP/npair_half_bin_newtoff_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_bin_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_bin_newton_omp.cpp b/src/USER-OMP/npair_half_bin_newton_omp.cpp index f7d969ba27..2700d6863b 100644 --- a/src/USER-OMP/npair_half_bin_newton_omp.cpp +++ b/src/USER-OMP/npair_half_bin_newton_omp.cpp @@ -13,11 +13,9 @@ #include "npair_half_bin_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "group.h" #include "molecule.h" #include "domain.h" #include "my_page.h" diff --git a/src/USER-OMP/npair_half_bin_newton_tri_omp.cpp b/src/USER-OMP/npair_half_bin_newton_tri_omp.cpp index c843d623cd..d94845898c 100644 --- a/src/USER-OMP/npair_half_bin_newton_tri_omp.cpp +++ b/src/USER-OMP/npair_half_bin_newton_tri_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_bin_newton_tri_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_multi_newtoff_omp.cpp b/src/USER-OMP/npair_half_multi_newtoff_omp.cpp index 705d1b8d9f..c06737dc1c 100644 --- a/src/USER-OMP/npair_half_multi_newtoff_omp.cpp +++ b/src/USER-OMP/npair_half_multi_newtoff_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_multi_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_multi_newton_omp.cpp b/src/USER-OMP/npair_half_multi_newton_omp.cpp index f16dd027a0..50df756be4 100644 --- a/src/USER-OMP/npair_half_multi_newton_omp.cpp +++ b/src/USER-OMP/npair_half_multi_newton_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_multi_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_halffull_newtoff_omp.cpp b/src/USER-OMP/npair_halffull_newtoff_omp.cpp index 947e4e1ad2..6f90f82752 100644 --- a/src/USER-OMP/npair_halffull_newtoff_omp.cpp +++ b/src/USER-OMP/npair_halffull_newtoff_omp.cpp @@ -18,7 +18,7 @@ #include "atom.h" #include "atom_vec.h" #include "molecule.h" -#include "domain.h" +#include "timer.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/npair_halffull_newton_omp.cpp b/src/USER-OMP/npair_halffull_newton_omp.cpp index 6e158d372d..6cf8ab8ac2 100644 --- a/src/USER-OMP/npair_halffull_newton_omp.cpp +++ b/src/USER-OMP/npair_halffull_newton_omp.cpp @@ -18,7 +18,7 @@ #include "atom.h" #include "atom_vec.h" #include "molecule.h" -#include "domain.h" +#include "timer.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/pair_brownian_omp.cpp b/src/USER-OMP/pair_brownian_omp.cpp index cef9fb0955..6367976c7d 100644 --- a/src/USER-OMP/pair_brownian_omp.cpp +++ b/src/USER-OMP/pair_brownian_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_brownian_omp.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" @@ -26,6 +26,7 @@ #include "random_mars.h" #include "math_const.h" #include "math_special.h" +#include "timer.h" #include "fix_wall.h" diff --git a/src/USER-OMP/pair_brownian_poly_omp.cpp b/src/USER-OMP/pair_brownian_poly_omp.cpp index 239a820242..dcb4124634 100644 --- a/src/USER-OMP/pair_brownian_poly_omp.cpp +++ b/src/USER-OMP/pair_brownian_poly_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_brownian_poly_omp.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp b/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp index d0db6262b1..87d637e80d 100644 --- a/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp +++ b/src/USER-OMP/pair_lj_cut_thole_long_omp.cpp @@ -22,6 +22,7 @@ #include #include "atom.h" #include "comm.h" +#include "domain.h" #include "fix_drude.h" #include "force.h" #include "neighbor.h" @@ -30,7 +31,7 @@ #include "math_const.h" #include "error.h" #include "suffix.h" -#include "domain.h" +#include "timer.h" using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp b/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp index e2c1da1a89..18fc207015 100644 --- a/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp +++ b/src/USER-OMP/pair_lj_cut_tip4p_long_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_lj_cut_tip4p_long_omp.h" +#include #include "atom.h" #include "domain.h" #include "comm.h" diff --git a/src/USER-OMP/pair_lubricate_poly_omp.cpp b/src/USER-OMP/pair_lubricate_poly_omp.cpp index 3a5f03364d..04ac59b121 100644 --- a/src/USER-OMP/pair_lubricate_poly_omp.cpp +++ b/src/USER-OMP/pair_lubricate_poly_omp.cpp @@ -12,8 +12,8 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_lubricate_poly_omp.h" +#include #include "atom.h" #include "comm.h" #include "domain.h" diff --git a/src/USER-OMP/pppm_cg_omp.cpp b/src/USER-OMP/pppm_cg_omp.cpp index 2b4619f685..1117979f1f 100644 --- a/src/USER-OMP/pppm_cg_omp.cpp +++ b/src/USER-OMP/pppm_cg_omp.cpp @@ -15,20 +15,20 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_cg_omp.h" +#include #include #include -#include "pppm_cg_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" -#include "error.h" -#include "fix_omp.h" #include "force.h" -#include "neighbor.h" -#include "memory.h" #include "math_const.h" #include "math_special.h" - +#include "timer.h" +#if defined(_OPENMP) +#include +#endif #include "suffix.h" using namespace LAMMPS_NS; using namespace MathConst; diff --git a/src/USER-OMP/pppm_disp_omp.cpp b/src/USER-OMP/pppm_disp_omp.cpp index 435341a31c..de902b1a57 100644 --- a/src/USER-OMP/pppm_disp_omp.cpp +++ b/src/USER-OMP/pppm_disp_omp.cpp @@ -16,15 +16,20 @@ Rolf Isele-Holder (RWTH Aachen University) ------------------------------------------------------------------------- */ +#include "pppm_disp_omp.h" +#include #include #include -#include "pppm_disp_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" +#include "error.h" #include "force.h" -#include "memory.h" #include "math_const.h" +#include "timer.h" +#if defined(_OPENMP) +#include +#endif #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pppm_disp_tip4p_omp.cpp b/src/USER-OMP/pppm_disp_tip4p_omp.cpp index a53c5b2ac5..fc9466e395 100644 --- a/src/USER-OMP/pppm_disp_tip4p_omp.cpp +++ b/src/USER-OMP/pppm_disp_tip4p_omp.cpp @@ -15,23 +15,22 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_disp_tip4p_omp.h" +#include #include #include -#include "pppm_disp_tip4p_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" #include "error.h" -#include "fix_omp.h" #include "force.h" -#include "memory.h" #include "math_const.h" -#include "math_special.h" - +#if defined(_OPENMP) +#include +#endif #include "suffix.h" using namespace LAMMPS_NS; using namespace MathConst; -using namespace MathSpecial; #ifdef FFT_SINGLE #define ZEROF 0.0f diff --git a/src/USER-OMP/pppm_omp.cpp b/src/USER-OMP/pppm_omp.cpp index 66190b3f51..3ef3de1ab7 100644 --- a/src/USER-OMP/pppm_omp.cpp +++ b/src/USER-OMP/pppm_omp.cpp @@ -15,18 +15,21 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_omp.h" +#include #include #include -#include "pppm_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" -#include "error.h" -#include "fix_omp.h" #include "force.h" -#include "memory.h" #include "math_const.h" #include "math_special.h" +#include "timer.h" + +#if defined(_OPENMP) +#include +#endif #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pppm_tip4p_omp.cpp b/src/USER-OMP/pppm_tip4p_omp.cpp index 5fe44d2b71..d7c12613d9 100644 --- a/src/USER-OMP/pppm_tip4p_omp.cpp +++ b/src/USER-OMP/pppm_tip4p_omp.cpp @@ -15,18 +15,21 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ +#include "pppm_tip4p_omp.h" +#include #include #include -#include "pppm_tip4p_omp.h" #include "atom.h" #include "comm.h" #include "domain.h" #include "error.h" -#include "fix_omp.h" #include "force.h" -#include "memory.h" #include "math_const.h" #include "math_special.h" +#include "timer.h" +#if defined(_OPENMP) +#include +#endif #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/reaxc_multi_body_omp.cpp b/src/USER-OMP/reaxc_multi_body_omp.cpp index 164999b986..5f4b6d4eb0 100644 --- a/src/USER-OMP/reaxc_multi_body_omp.cpp +++ b/src/USER-OMP/reaxc_multi_body_omp.cpp @@ -27,14 +27,13 @@ ----------------------------------------------------------------------*/ #include "reaxc_multi_body_omp.h" +#include +#include +#include "fix_omp.h" #include #include "pair_reaxc_omp.h" -#include "thr_data.h" #include "reaxc_defs.h" - -#include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" -#include "reaxc_vector.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/reaxc_valence_angles_omp.cpp b/src/USER-OMP/reaxc_valence_angles_omp.cpp index 7fbe87d6e5..104fadbbae 100644 --- a/src/USER-OMP/reaxc_valence_angles_omp.cpp +++ b/src/USER-OMP/reaxc_valence_angles_omp.cpp @@ -27,13 +27,15 @@ ----------------------------------------------------------------------*/ #include "reaxc_valence_angles_omp.h" +#include +#include #include "pair_reaxc_omp.h" -#include "thr_data.h" +#include "fix_omp.h" +#include "error.h" #include "reaxc_defs.h" #include "reaxc_types.h" #include "reaxc_valence_angles.h" -#include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_vector.h" diff --git a/src/USER-OMP/respa_omp.cpp b/src/USER-OMP/respa_omp.cpp index 9c8555c66d..5add419253 100644 --- a/src/USER-OMP/respa_omp.cpp +++ b/src/USER-OMP/respa_omp.cpp @@ -15,13 +15,11 @@ Contributing authors: Mark Stevens (SNL), Paul Crozier (SNL) ------------------------------------------------------------------------- */ -#include -#include #include "respa_omp.h" #include "neighbor.h" -#include "domain.h" #include "comm.h" #include "atom.h" +#include "domain.h" #include "force.h" #include "pair.h" #include "bond.h" @@ -32,11 +30,8 @@ #include "output.h" #include "update.h" #include "modify.h" -#include "compute.h" -#include "fix_respa.h" -#include "timer.h" -#include "memory.h" #include "error.h" +#include "timer.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/thr_data.h b/src/USER-OMP/thr_data.h index 3cea1b0018..edff17cad3 100644 --- a/src/USER-OMP/thr_data.h +++ b/src/USER-OMP/thr_data.h @@ -18,10 +18,6 @@ #ifndef LMP_THR_DATA_H #define LMP_THR_DATA_H -#if defined(_OPENMP) -#include -#endif - #include "timer.h" namespace LAMMPS_NS { @@ -35,7 +31,7 @@ class ThrData { public: ThrData(int tid, class Timer *t); - ~ThrData() { delete _timer; _timer = NULL; }; + ~ThrData() { delete _timer; _timer = nullptr; }; void check_tid(int); // thread id consistency check int get_tid() const { return _tid; }; // our thread id. @@ -140,7 +136,7 @@ class ThrData { // disabled default methods private: - ThrData() : _tid(-1), _timer(NULL) {}; + ThrData() : _tid(-1), _timer(nullptr) {}; }; //////////////////////////////////////////////////////////////////////// diff --git a/src/USER-OMP/thr_omp.cpp b/src/USER-OMP/thr_omp.cpp index 22f751e6c0..51030358d3 100644 --- a/src/USER-OMP/thr_omp.cpp +++ b/src/USER-OMP/thr_omp.cpp @@ -22,7 +22,6 @@ #include "comm.h" #include "error.h" #include "force.h" -#include "memory.h" #include "modify.h" #include "neighbor.h" #include "timer.h" @@ -34,7 +33,6 @@ #include "angle.h" #include "dihedral.h" #include "improper.h" -#include "kspace.h" #include "compute.h" #include "math_const.h" diff --git a/src/USER-OMP/thr_omp.h b/src/USER-OMP/thr_omp.h index 87d921290e..062d77bc0e 100644 --- a/src/USER-OMP/thr_omp.h +++ b/src/USER-OMP/thr_omp.h @@ -18,10 +18,13 @@ #ifndef LMP_THR_OMP_H #define LMP_THR_OMP_H +#if defined(_OPENMP) +#include +#endif #include "pointers.h" #include "error.h" -#include "fix_omp.h" -#include "thr_data.h" +#include "fix_omp.h" // IWYU pragma: export +#include "thr_data.h" // IWYU pragma: export namespace LAMMPS_NS { @@ -31,8 +34,6 @@ class Bond; class Angle; class Dihedral; class Improper; -class KSpace; -class Fix; class ThrOMP { diff --git a/src/USER-SMD/pair_smd_tlsph.cpp b/src/USER-SMD/pair_smd_tlsph.cpp index 0dff905962..82b7c8ff9d 100644 --- a/src/USER-SMD/pair_smd_tlsph.cpp +++ b/src/USER-SMD/pair_smd_tlsph.cpp @@ -1776,9 +1776,8 @@ void PairTlsph::init_style() { optional granular history list ------------------------------------------------------------------------- */ -void PairTlsph::init_list(int id, NeighList *ptr) { - if (id == 0) - list = ptr; +void PairTlsph::init_list(int id, class NeighList *ptr) { + if (id == 0) list = ptr; } /* ---------------------------------------------------------------------- @@ -1786,8 +1785,7 @@ void PairTlsph::init_list(int id, NeighList *ptr) { ------------------------------------------------------------------------- */ double PairTlsph::memory_usage() { - - return 118 * nmax * sizeof(double); + return 118.0 * nmax * sizeof(double); } /* ---------------------------------------------------------------------- diff --git a/src/special.cpp b/src/special.cpp index b64aa96e2b..3dd817bc7f 100644 --- a/src/special.cpp +++ b/src/special.cpp @@ -19,7 +19,7 @@ #include "comm.h" #include "modify.h" #include "fix.h" -#include "accelerator_kokkos.h" +#include "accelerator_kokkos.h" // IWYU pragma: export #include "atom_masks.h" #include "memory.h" From 2f646150873b170cbbd4318bc937967effc0d195 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Thu, 11 Jul 2019 22:31:16 -0400 Subject: [PATCH 72/79] more work on includes in USER-OMP --- src/USER-OMP/npair_full_bin_atomonly_omp.cpp | 2 -- src/USER-OMP/npair_full_bin_ghost_omp.cpp | 1 - src/USER-OMP/npair_full_bin_omp.cpp | 2 -- src/USER-OMP/npair_full_multi_omp.cpp | 1 - src/USER-OMP/npair_full_nsq_ghost_omp.cpp | 1 - src/USER-OMP/npair_full_nsq_omp.cpp | 1 - src/USER-OMP/npair_half_multi_newton_tri_omp.cpp | 1 - src/USER-OMP/npair_half_nsq_newtoff_ghost_omp.cpp | 1 - src/USER-OMP/npair_half_nsq_newtoff_omp.cpp | 1 - src/USER-OMP/npair_half_nsq_newton_omp.cpp | 1 - src/USER-OMP/npair_half_respa_bin_newtoff_omp.cpp | 1 - src/USER-OMP/npair_half_respa_bin_newton_omp.cpp | 1 - src/USER-OMP/npair_half_respa_bin_newton_tri_omp.cpp | 1 - src/USER-OMP/npair_half_respa_nsq_newtoff_omp.cpp | 1 - src/USER-OMP/npair_half_respa_nsq_newton_omp.cpp | 1 - src/USER-OMP/npair_half_size_bin_newtoff_omp.cpp | 2 -- src/USER-OMP/npair_half_size_bin_newton_omp.cpp | 2 -- src/USER-OMP/npair_half_size_bin_newton_tri_omp.cpp | 1 - src/USER-OMP/npair_half_size_nsq_newtoff_omp.cpp | 2 -- src/USER-OMP/npair_half_size_nsq_newton_omp.cpp | 2 -- src/USER-OMP/npair_halffull_newtoff_omp.cpp | 4 ---- src/USER-OMP/npair_halffull_newton_omp.cpp | 3 --- src/USER-OMP/pair_beck_omp.cpp | 4 ++-- src/USER-OMP/pair_born_coul_wolf_omp.cpp | 4 ++-- src/USER-OMP/pair_born_omp.cpp | 4 ++-- src/USER-OMP/pair_buck_omp.cpp | 4 ++-- src/USER-OMP/pair_coul_cut_omp.cpp | 4 ++-- src/USER-OMP/pair_coul_debye_omp.cpp | 4 ++-- src/USER-OMP/pair_coul_dsf_omp.cpp | 5 ++--- src/USER-OMP/pair_coul_wolf_omp.cpp | 4 ++-- src/USER-OMP/pair_dpd_omp.cpp | 4 ++-- 31 files changed, 18 insertions(+), 52 deletions(-) diff --git a/src/USER-OMP/npair_full_bin_atomonly_omp.cpp b/src/USER-OMP/npair_full_bin_atomonly_omp.cpp index 09c4f2d78d..3bda2e4c5a 100644 --- a/src/USER-OMP/npair_full_bin_atomonly_omp.cpp +++ b/src/USER-OMP/npair_full_bin_atomonly_omp.cpp @@ -18,10 +18,8 @@ #include "atom_vec.h" #include "my_page.h" #include "error.h" -#include "timer.h" using namespace LAMMPS_NS; -using namespace NeighConst; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-OMP/npair_full_bin_ghost_omp.cpp b/src/USER-OMP/npair_full_bin_ghost_omp.cpp index d541381143..b0b0070df5 100644 --- a/src/USER-OMP/npair_full_bin_ghost_omp.cpp +++ b/src/USER-OMP/npair_full_bin_ghost_omp.cpp @@ -22,7 +22,6 @@ #include "error.h" using namespace LAMMPS_NS; -using namespace NeighConst; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-OMP/npair_full_bin_omp.cpp b/src/USER-OMP/npair_full_bin_omp.cpp index e1f75c06e2..d3e30b4932 100644 --- a/src/USER-OMP/npair_full_bin_omp.cpp +++ b/src/USER-OMP/npair_full_bin_omp.cpp @@ -13,7 +13,6 @@ #include "npair_full_bin_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" @@ -23,7 +22,6 @@ #include "error.h" using namespace LAMMPS_NS; -using namespace NeighConst; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-OMP/npair_full_multi_omp.cpp b/src/USER-OMP/npair_full_multi_omp.cpp index 57b60f665b..707db2edcf 100644 --- a/src/USER-OMP/npair_full_multi_omp.cpp +++ b/src/USER-OMP/npair_full_multi_omp.cpp @@ -22,7 +22,6 @@ #include "error.h" using namespace LAMMPS_NS; -using namespace NeighConst; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-OMP/npair_full_nsq_ghost_omp.cpp b/src/USER-OMP/npair_full_nsq_ghost_omp.cpp index 242c4e300c..527df58fd6 100644 --- a/src/USER-OMP/npair_full_nsq_ghost_omp.cpp +++ b/src/USER-OMP/npair_full_nsq_ghost_omp.cpp @@ -22,7 +22,6 @@ #include "error.h" using namespace LAMMPS_NS; -using namespace NeighConst; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-OMP/npair_full_nsq_omp.cpp b/src/USER-OMP/npair_full_nsq_omp.cpp index 08a034d5ab..2719f5dc2c 100644 --- a/src/USER-OMP/npair_full_nsq_omp.cpp +++ b/src/USER-OMP/npair_full_nsq_omp.cpp @@ -23,7 +23,6 @@ #include "error.h" using namespace LAMMPS_NS; -using namespace NeighConst; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-OMP/npair_half_multi_newton_tri_omp.cpp b/src/USER-OMP/npair_half_multi_newton_tri_omp.cpp index ce93e85485..8b78b311dd 100644 --- a/src/USER-OMP/npair_half_multi_newton_tri_omp.cpp +++ b/src/USER-OMP/npair_half_multi_newton_tri_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_multi_newton_tri_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_nsq_newtoff_ghost_omp.cpp b/src/USER-OMP/npair_half_nsq_newtoff_ghost_omp.cpp index add4c44d9e..f0eb211425 100644 --- a/src/USER-OMP/npair_half_nsq_newtoff_ghost_omp.cpp +++ b/src/USER-OMP/npair_half_nsq_newtoff_ghost_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_nsq_newtoff_ghost_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_nsq_newtoff_omp.cpp b/src/USER-OMP/npair_half_nsq_newtoff_omp.cpp index 01da73cf1e..55b9f9e512 100644 --- a/src/USER-OMP/npair_half_nsq_newtoff_omp.cpp +++ b/src/USER-OMP/npair_half_nsq_newtoff_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_nsq_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_nsq_newton_omp.cpp b/src/USER-OMP/npair_half_nsq_newton_omp.cpp index 3815b1b85b..223da622e8 100644 --- a/src/USER-OMP/npair_half_nsq_newton_omp.cpp +++ b/src/USER-OMP/npair_half_nsq_newton_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_nsq_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_respa_bin_newtoff_omp.cpp b/src/USER-OMP/npair_half_respa_bin_newtoff_omp.cpp index f094691b71..9bb4d277fe 100644 --- a/src/USER-OMP/npair_half_respa_bin_newtoff_omp.cpp +++ b/src/USER-OMP/npair_half_respa_bin_newtoff_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_respa_bin_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_respa_bin_newton_omp.cpp b/src/USER-OMP/npair_half_respa_bin_newton_omp.cpp index de7ef5f7d5..9ed0ae482d 100644 --- a/src/USER-OMP/npair_half_respa_bin_newton_omp.cpp +++ b/src/USER-OMP/npair_half_respa_bin_newton_omp.cpp @@ -12,7 +12,6 @@ ------------------------------------------------------------------------- */ #include "npair_half_respa_bin_newton_omp.h" -#include "neighbor.h" #include "npair_omp.h" #include "neigh_list.h" #include "atom.h" diff --git a/src/USER-OMP/npair_half_respa_bin_newton_tri_omp.cpp b/src/USER-OMP/npair_half_respa_bin_newton_tri_omp.cpp index f20d101bc9..cd03684940 100644 --- a/src/USER-OMP/npair_half_respa_bin_newton_tri_omp.cpp +++ b/src/USER-OMP/npair_half_respa_bin_newton_tri_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_respa_bin_newton_tri_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_respa_nsq_newtoff_omp.cpp b/src/USER-OMP/npair_half_respa_nsq_newtoff_omp.cpp index 0f726cdd7f..b1e7467ec7 100644 --- a/src/USER-OMP/npair_half_respa_nsq_newtoff_omp.cpp +++ b/src/USER-OMP/npair_half_respa_nsq_newtoff_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_respa_nsq_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_respa_nsq_newton_omp.cpp b/src/USER-OMP/npair_half_respa_nsq_newton_omp.cpp index 2783e1255e..c22965895d 100644 --- a/src/USER-OMP/npair_half_respa_nsq_newton_omp.cpp +++ b/src/USER-OMP/npair_half_respa_nsq_newton_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_respa_nsq_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_size_bin_newtoff_omp.cpp b/src/USER-OMP/npair_half_size_bin_newtoff_omp.cpp index dff2a762d5..1b437482c4 100644 --- a/src/USER-OMP/npair_half_size_bin_newtoff_omp.cpp +++ b/src/USER-OMP/npair_half_size_bin_newtoff_omp.cpp @@ -11,10 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_bin_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_size_bin_newton_omp.cpp b/src/USER-OMP/npair_half_size_bin_newton_omp.cpp index 3053b81594..8e0581d4ce 100644 --- a/src/USER-OMP/npair_half_size_bin_newton_omp.cpp +++ b/src/USER-OMP/npair_half_size_bin_newton_omp.cpp @@ -11,10 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_bin_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_size_bin_newton_tri_omp.cpp b/src/USER-OMP/npair_half_size_bin_newton_tri_omp.cpp index b02bfa345e..38a2c0d61f 100644 --- a/src/USER-OMP/npair_half_size_bin_newton_tri_omp.cpp +++ b/src/USER-OMP/npair_half_size_bin_newton_tri_omp.cpp @@ -13,7 +13,6 @@ #include "npair_half_size_bin_newton_tri_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_size_nsq_newtoff_omp.cpp b/src/USER-OMP/npair_half_size_nsq_newtoff_omp.cpp index 717012b226..d1505e1b2e 100644 --- a/src/USER-OMP/npair_half_size_nsq_newtoff_omp.cpp +++ b/src/USER-OMP/npair_half_size_nsq_newtoff_omp.cpp @@ -11,10 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_nsq_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_half_size_nsq_newton_omp.cpp b/src/USER-OMP/npair_half_size_nsq_newton_omp.cpp index 5a55029d30..9027b0728d 100644 --- a/src/USER-OMP/npair_half_size_nsq_newton_omp.cpp +++ b/src/USER-OMP/npair_half_size_nsq_newton_omp.cpp @@ -11,10 +11,8 @@ See the README file in the top-level LAMMPS directory. ------------------------------------------------------------------------- */ -#include #include "npair_half_size_nsq_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" diff --git a/src/USER-OMP/npair_halffull_newtoff_omp.cpp b/src/USER-OMP/npair_halffull_newtoff_omp.cpp index 6f90f82752..7d2fe4f109 100644 --- a/src/USER-OMP/npair_halffull_newtoff_omp.cpp +++ b/src/USER-OMP/npair_halffull_newtoff_omp.cpp @@ -13,12 +13,8 @@ #include "npair_halffull_newtoff_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" -#include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "timer.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/npair_halffull_newton_omp.cpp b/src/USER-OMP/npair_halffull_newton_omp.cpp index 6cf8ab8ac2..3fcc8c2e98 100644 --- a/src/USER-OMP/npair_halffull_newton_omp.cpp +++ b/src/USER-OMP/npair_halffull_newton_omp.cpp @@ -13,12 +13,9 @@ #include "npair_halffull_newton_omp.h" #include "npair_omp.h" -#include "neighbor.h" #include "neigh_list.h" #include "atom.h" #include "atom_vec.h" -#include "molecule.h" -#include "timer.h" #include "my_page.h" #include "error.h" diff --git a/src/USER-OMP/pair_beck_omp.cpp b/src/USER-OMP/pair_beck_omp.cpp index 90c3777932..8d0605fae9 100644 --- a/src/USER-OMP/pair_beck_omp.cpp +++ b/src/USER-OMP/pair_beck_omp.cpp @@ -12,14 +12,14 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_beck_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "math_special.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_born_coul_wolf_omp.cpp b/src/USER-OMP/pair_born_coul_wolf_omp.cpp index 567eddc9cb..55da972c4e 100644 --- a/src/USER-OMP/pair_born_coul_wolf_omp.cpp +++ b/src/USER-OMP/pair_born_coul_wolf_omp.cpp @@ -12,14 +12,14 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_born_coul_wolf_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "math_const.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_born_omp.cpp b/src/USER-OMP/pair_born_omp.cpp index fce2013745..35ad4fcb48 100644 --- a/src/USER-OMP/pair_born_omp.cpp +++ b/src/USER-OMP/pair_born_omp.cpp @@ -12,13 +12,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_born_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_buck_omp.cpp b/src/USER-OMP/pair_buck_omp.cpp index cc7e81b9c5..8d5c80513a 100644 --- a/src/USER-OMP/pair_buck_omp.cpp +++ b/src/USER-OMP/pair_buck_omp.cpp @@ -12,13 +12,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_buck_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_coul_cut_omp.cpp b/src/USER-OMP/pair_coul_cut_omp.cpp index 056daf210a..267beeecbd 100644 --- a/src/USER-OMP/pair_coul_cut_omp.cpp +++ b/src/USER-OMP/pair_coul_cut_omp.cpp @@ -12,13 +12,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_coul_cut_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_coul_debye_omp.cpp b/src/USER-OMP/pair_coul_debye_omp.cpp index d202e314bf..4d3f92c495 100644 --- a/src/USER-OMP/pair_coul_debye_omp.cpp +++ b/src/USER-OMP/pair_coul_debye_omp.cpp @@ -12,13 +12,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_coul_debye_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_coul_dsf_omp.cpp b/src/USER-OMP/pair_coul_dsf_omp.cpp index 217fb844c3..bd7f5cfed2 100644 --- a/src/USER-OMP/pair_coul_dsf_omp.cpp +++ b/src/USER-OMP/pair_coul_dsf_omp.cpp @@ -12,14 +12,13 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_coul_dsf_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" - +#include "timer.h" #include "suffix.h" #include "math_const.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_coul_wolf_omp.cpp b/src/USER-OMP/pair_coul_wolf_omp.cpp index 0913a2b188..92d5bd7b15 100644 --- a/src/USER-OMP/pair_coul_wolf_omp.cpp +++ b/src/USER-OMP/pair_coul_wolf_omp.cpp @@ -12,14 +12,14 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_coul_wolf_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "math_const.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; diff --git a/src/USER-OMP/pair_dpd_omp.cpp b/src/USER-OMP/pair_dpd_omp.cpp index 77db3d9183..b7f3a7f4d4 100644 --- a/src/USER-OMP/pair_dpd_omp.cpp +++ b/src/USER-OMP/pair_dpd_omp.cpp @@ -12,15 +12,15 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include #include "pair_dpd_omp.h" +#include #include "atom.h" #include "comm.h" #include "force.h" -#include "neighbor.h" #include "neigh_list.h" #include "update.h" #include "random_mars.h" +#include "timer.h" #include "suffix.h" using namespace LAMMPS_NS; From a1f0c0079de6d0c7d94fc63f6d9cd76e70b5ce2b Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 12 Jul 2019 15:40:24 -0400 Subject: [PATCH 73/79] some cleanup for missed steps in previous change sets --- src/KSPACE/pppm.h | 5 +---- src/KSPACE/pppm_disp.h | 5 +---- src/MPIIO/dump_xyz_mpiio.cpp | 1 - src/USER-AWPMD/atom_vec_wavepacket.cpp | 1 - src/USER-AWPMD/fix_nve_awpmd.cpp | 7 +++---- src/USER-AWPMD/fix_nve_awpmd.h | 3 +-- src/USER-AWPMD/pair_awpmd_cut.cpp | 8 ++++++-- src/USER-BOCS/compute_pressure_bocs.cpp | 1 + src/USER-CGSDK/pair_lj_sdk.cpp | 2 -- src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp | 1 - src/USER-DPD/fix_shardlow.cpp | 3 ++- src/USER-OMP/pair_reaxc_omp.cpp | 11 ++++------- src/accelerator_kokkos.h | 16 ++++++++-------- src/finish.cpp | 4 ++-- 14 files changed, 29 insertions(+), 39 deletions(-) diff --git a/src/KSPACE/pppm.h b/src/KSPACE/pppm.h index 1ce1a0d666..b84dfe26c4 100644 --- a/src/KSPACE/pppm.h +++ b/src/KSPACE/pppm.h @@ -20,8 +20,7 @@ KSpaceStyle(pppm,PPPM) #ifndef LMP_PPPM_H #define LMP_PPPM_H -#include "lmptype.h" -#include +#include "kspace.h" #ifdef FFT_SINGLE typedef float FFT_SCALAR; @@ -31,8 +30,6 @@ typedef double FFT_SCALAR; #define MPI_FFT_SCALAR MPI_DOUBLE #endif -#include "kspace.h" - namespace LAMMPS_NS { class PPPM : public KSpace { diff --git a/src/KSPACE/pppm_disp.h b/src/KSPACE/pppm_disp.h index ccbeb60f3c..8582e98acd 100644 --- a/src/KSPACE/pppm_disp.h +++ b/src/KSPACE/pppm_disp.h @@ -20,8 +20,7 @@ KSpaceStyle(pppm/disp,PPPMDisp) #ifndef LMP_PPPM_DISP_H #define LMP_PPPM_DISP_H -#include "lmptype.h" -#include +#include "kspace.h" #ifdef FFT_SINGLE typedef float FFT_SCALAR; @@ -31,8 +30,6 @@ typedef double FFT_SCALAR; #define MPI_FFT_SCALAR MPI_DOUBLE #endif -#include "kspace.h" - namespace LAMMPS_NS { diff --git a/src/MPIIO/dump_xyz_mpiio.cpp b/src/MPIIO/dump_xyz_mpiio.cpp index ee0532399a..f5caab3a9c 100644 --- a/src/MPIIO/dump_xyz_mpiio.cpp +++ b/src/MPIIO/dump_xyz_mpiio.cpp @@ -21,7 +21,6 @@ #include #include "domain.h" #include "update.h" -#include "modify.h" #include "compute.h" #include "memory.h" #include "error.h" diff --git a/src/USER-AWPMD/atom_vec_wavepacket.cpp b/src/USER-AWPMD/atom_vec_wavepacket.cpp index 3dc624e4b8..bce334a7b3 100644 --- a/src/USER-AWPMD/atom_vec_wavepacket.cpp +++ b/src/USER-AWPMD/atom_vec_wavepacket.cpp @@ -16,7 +16,6 @@ ------------------------------------------------------------------------- */ #include "atom_vec_wavepacket.h" -#include #include #include "atom.h" #include "comm.h" diff --git a/src/USER-AWPMD/fix_nve_awpmd.cpp b/src/USER-AWPMD/fix_nve_awpmd.cpp index 57ad17f3e6..a147a11081 100644 --- a/src/USER-AWPMD/fix_nve_awpmd.cpp +++ b/src/USER-AWPMD/fix_nve_awpmd.cpp @@ -16,14 +16,13 @@ ------------------------------------------------------------------------- */ #include "fix_nve_awpmd.h" -#include -#include -#include +#include "pair_awpmd_cut.h" #include "atom.h" #include "force.h" #include "update.h" #include "respa.h" #include "error.h" +#include "utils.h" #include "TCP/wpmd_split.h" @@ -62,7 +61,7 @@ void FixNVEAwpmd::init() dtv = update->dt; dtf = 0.5 * update->dt * force->ftm2v; - if (strstr(update->integrate_style,"respa")) + if (utils::strmatch(update->integrate_style,"^respa")) step_respa = ((Respa *) update->integrate)->step; awpmd_pair=(PairAWPMDCut *)force->pair; diff --git a/src/USER-AWPMD/fix_nve_awpmd.h b/src/USER-AWPMD/fix_nve_awpmd.h index 140d234308..832f5821a3 100644 --- a/src/USER-AWPMD/fix_nve_awpmd.h +++ b/src/USER-AWPMD/fix_nve_awpmd.h @@ -25,7 +25,6 @@ FixStyle(nve/awpmd,FixNVEAwpmd) #define LMP_FIX_NVE_awpmd_H #include "fix.h" -#include "pair_awpmd_cut.h" namespace LAMMPS_NS { @@ -45,7 +44,7 @@ class FixNVEAwpmd : public Fix { double *step_respa; int mass_require; - PairAWPMDCut *awpmd_pair; + class PairAWPMDCut *awpmd_pair; }; } diff --git a/src/USER-AWPMD/pair_awpmd_cut.cpp b/src/USER-AWPMD/pair_awpmd_cut.cpp index ae2fbc59fa..75ebb0e251 100644 --- a/src/USER-AWPMD/pair_awpmd_cut.cpp +++ b/src/USER-AWPMD/pair_awpmd_cut.cpp @@ -16,10 +16,11 @@ ------------------------------------------------------------------------- */ #include "pair_awpmd_cut.h" +#include #include -#include -#include #include +#include +#include #include "atom.h" #include "update.h" #include "min.h" @@ -32,6 +33,9 @@ #include "memory.h" #include "error.h" +#include "logexc.h" +#include "vector_3.h" +#include "TCP/wpmd.h" #include "TCP/wpmd_split.h" using namespace LAMMPS_NS; diff --git a/src/USER-BOCS/compute_pressure_bocs.cpp b/src/USER-BOCS/compute_pressure_bocs.cpp index ee1ad33f88..d0a24b99a3 100644 --- a/src/USER-BOCS/compute_pressure_bocs.cpp +++ b/src/USER-BOCS/compute_pressure_bocs.cpp @@ -16,6 +16,7 @@ #include "compute_pressure_bocs.h" #include +#include #include #include #include "atom.h" diff --git a/src/USER-CGSDK/pair_lj_sdk.cpp b/src/USER-CGSDK/pair_lj_sdk.cpp index 6ad77a6183..1301dc4155 100644 --- a/src/USER-CGSDK/pair_lj_sdk.cpp +++ b/src/USER-CGSDK/pair_lj_sdk.cpp @@ -24,7 +24,6 @@ #include "comm.h" #include "force.h" #include "neigh_list.h" -#include "math_const.h" #include "memory.h" #include "error.h" @@ -32,7 +31,6 @@ #include "lj_sdk_common.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace LJSDKParms; /* ---------------------------------------------------------------------- */ diff --git a/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp b/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp index 1095521de3..f168089fae 100644 --- a/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp +++ b/src/USER-CGSDK/pair_lj_sdk_coul_msm.cpp @@ -23,7 +23,6 @@ #include "force.h" #include "kspace.h" #include "neigh_list.h" -#include "memory.h" #include "error.h" #include "lj_sdk_common.h" diff --git a/src/USER-DPD/fix_shardlow.cpp b/src/USER-DPD/fix_shardlow.cpp index f181436f91..b0efeb634d 100644 --- a/src/USER-DPD/fix_shardlow.cpp +++ b/src/USER-DPD/fix_shardlow.cpp @@ -37,15 +37,16 @@ #include #include #include +#include #include "atom.h" #include "force.h" #include "update.h" #include "error.h" -#include "atom_vec.h" #include "comm.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" +#include "npair.h" #include "memory.h" #include "domain.h" #include "modify.h" diff --git a/src/USER-OMP/pair_reaxc_omp.cpp b/src/USER-OMP/pair_reaxc_omp.cpp index 2f17515130..aedd438066 100644 --- a/src/USER-OMP/pair_reaxc_omp.cpp +++ b/src/USER-OMP/pair_reaxc_omp.cpp @@ -34,6 +34,8 @@ ------------------------------------------------------------------------- */ #include "pair_reaxc_omp.h" +#include +#include #include "atom.h" #include "update.h" #include "force.h" @@ -42,32 +44,27 @@ #include "neigh_list.h" #include "neigh_request.h" #include "modify.h" -#include "fix.h" #include "fix_reaxc.h" #include "citeme.h" #include "memory.h" #include "error.h" #include "timer.h" +#include "reaxc_defs.h" #include "reaxc_types.h" #include "reaxc_allocate.h" -#include "reaxc_control.h" -#include "reaxc_ffield.h" #include "reaxc_forces_omp.h" #include "reaxc_init_md_omp.h" #include "reaxc_io_tools.h" #include "reaxc_list.h" -#include "reaxc_lookup.h" #include "reaxc_reset_tools.h" #include "reaxc_tool_box.h" -#include "reaxc_traj.h" -#include "reaxc_vector.h" -#include "fix_reaxc_bonds.h" #if defined(_OPENMP) #include #endif +#include "suffix.h" using namespace LAMMPS_NS; #ifdef OMP_TIMING diff --git a/src/accelerator_kokkos.h b/src/accelerator_kokkos.h index 74bd470572..a3fff2fe16 100644 --- a/src/accelerator_kokkos.h +++ b/src/accelerator_kokkos.h @@ -19,14 +19,14 @@ #ifdef LMP_KOKKOS -#include "kokkos.h" -#include "atom_kokkos.h" -#include "comm_kokkos.h" -#include "comm_tiled_kokkos.h" -#include "domain_kokkos.h" -#include "neighbor_kokkos.h" -#include "memory_kokkos.h" -#include "modify_kokkos.h" +#include "kokkos.h" // IWYU pragma: export +#include "atom_kokkos.h" // IWYU pragma: export +#include "comm_kokkos.h" // IWYU pragma: export +#include "comm_tiled_kokkos.h" // IWYU pragma: export +#include "domain_kokkos.h" // IWYU pragma: export +#include "neighbor_kokkos.h" // IWYU pragma: export +#include "memory_kokkos.h" // IWYU pragma: export +#include "modify_kokkos.h" // IWYU pragma: export #define LAMMPS_INLINE KOKKOS_INLINE_FUNCTION diff --git a/src/finish.cpp b/src/finish.cpp index bef3ae89eb..9ab97ae410 100644 --- a/src/finish.cpp +++ b/src/finish.cpp @@ -16,8 +16,6 @@ #include #include #include -#include "timer.h" -#include "universe.h" #include "accelerator_kokkos.h" #include "atom.h" #include "atom_vec.h" @@ -32,6 +30,8 @@ #include "neigh_request.h" #include "memory.h" #include "error.h" +#include "timer.h" +#include "universe.h" #ifdef LMP_USER_OMP #include "modify.h" From 3d157e5ab4c7f8481ec2170ff3d557f0bd1b37cc Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 12 Jul 2019 18:00:59 -0400 Subject: [PATCH 74/79] more include handling cleanup in USER packages --- src/USER-DRUDE/fix_drude_transform.cpp | 1 + src/USER-DRUDE/fix_langevin_drude.cpp | 1 + src/USER-EFF/compute_temp_eff.cpp | 1 + src/USER-LB/fix_lb_fluid.cpp | 5 ++--- src/USER-LB/fix_lb_momentum.cpp | 5 ++--- src/USER-LB/fix_lb_pc.cpp | 7 ++----- src/USER-LB/fix_lb_rigid_pc_sphere.cpp | 7 ++----- src/USER-LB/fix_lb_viscous.cpp | 4 +--- src/USER-MGPT/pair_mgpt.h | 2 -- src/USER-MOLFILE/dump_molfile.cpp | 5 ++--- src/USER-MOLFILE/reader_molfile.cpp | 4 +--- src/USER-OMP/fix_qeq_reax_omp.cpp | 1 + src/USER-OMP/pair_reaxc_omp.h | 1 - src/USER-OMP/reaxc_bond_orders_omp.cpp | 3 +++ src/USER-OMP/reaxc_bonds_omp.cpp | 7 +++---- src/USER-OMP/reaxc_forces_omp.cpp | 7 +++---- src/USER-OMP/reaxc_forces_omp.h | 1 - src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp | 4 +++- src/USER-OMP/reaxc_init_md_omp.cpp | 7 ++----- src/USER-OMP/reaxc_torsion_angles_omp.cpp | 5 ++--- src/USER-PTM/ptm_index.cpp | 1 + src/USER-PTM/ptm_initialize_data.cpp | 4 ++++ src/USER-PTM/ptm_initialize_data.h | 4 ---- 23 files changed, 37 insertions(+), 50 deletions(-) diff --git a/src/USER-DRUDE/fix_drude_transform.cpp b/src/USER-DRUDE/fix_drude_transform.cpp index 8e85f1dffd..4128c508d6 100644 --- a/src/USER-DRUDE/fix_drude_transform.cpp +++ b/src/USER-DRUDE/fix_drude_transform.cpp @@ -13,6 +13,7 @@ /** Fix Drude Transform ******************************************************/ #include "fix_drude_transform.h" +#include #include #include #include "fix_drude.h" diff --git a/src/USER-DRUDE/fix_langevin_drude.cpp b/src/USER-DRUDE/fix_langevin_drude.cpp index 1a16c3df96..d413c31bd7 100644 --- a/src/USER-DRUDE/fix_langevin_drude.cpp +++ b/src/USER-DRUDE/fix_langevin_drude.cpp @@ -12,6 +12,7 @@ ------------------------------------------------------------------------- */ #include "fix_langevin_drude.h" +#include #include #include #include "fix_drude.h" diff --git a/src/USER-EFF/compute_temp_eff.cpp b/src/USER-EFF/compute_temp_eff.cpp index 8e07e390fa..e9295ea680 100644 --- a/src/USER-EFF/compute_temp_eff.cpp +++ b/src/USER-EFF/compute_temp_eff.cpp @@ -17,6 +17,7 @@ #include "compute_temp_eff.h" #include +#include #include "atom.h" #include "update.h" #include "force.h" diff --git a/src/USER-LB/fix_lb_fluid.cpp b/src/USER-LB/fix_lb_fluid.cpp index 31c54aee76..8ad3dbe33e 100644 --- a/src/USER-LB/fix_lb_fluid.cpp +++ b/src/USER-LB/fix_lb_fluid.cpp @@ -20,15 +20,14 @@ #include #include #include -#include #include +#include +#include #include "comm.h" #include "memory.h" #include "error.h" #include "domain.h" #include "atom.h" -#include -#include #include "group.h" #include "random_mars.h" #include "update.h" diff --git a/src/USER-LB/fix_lb_momentum.cpp b/src/USER-LB/fix_lb_momentum.cpp index df17561380..10fffed018 100644 --- a/src/USER-LB/fix_lb_momentum.cpp +++ b/src/USER-LB/fix_lb_momentum.cpp @@ -18,16 +18,15 @@ Contributing author: Naveen Michaud-Agrawal (Johns Hopkins U) ------------------------------------------------------------------------- */ +#include "fix_lb_momentum.h" +#include #include #include -#include "fix_lb_momentum.h" #include "atom.h" -#include "domain.h" #include "group.h" #include "error.h" #include "fix_lb_fluid.h" #include "modify.h" -#include "comm.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/USER-LB/fix_lb_pc.cpp b/src/USER-LB/fix_lb_pc.cpp index ce6ca0c9a1..d61692419a 100644 --- a/src/USER-LB/fix_lb_pc.cpp +++ b/src/USER-LB/fix_lb_pc.cpp @@ -15,17 +15,14 @@ Contributing authors: Frances Mackay, Santtu Ollila, Colin Denniston (UWO) ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_lb_pc.h" +#include +#include #include "atom.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" #include "memory.h" -#include "comm.h" #include "domain.h" #include "fix_lb_fluid.h" #include "modify.h" diff --git a/src/USER-LB/fix_lb_rigid_pc_sphere.cpp b/src/USER-LB/fix_lb_rigid_pc_sphere.cpp index 83dc751631..af1b01043d 100644 --- a/src/USER-LB/fix_lb_rigid_pc_sphere.cpp +++ b/src/USER-LB/fix_lb_rigid_pc_sphere.cpp @@ -16,21 +16,18 @@ Based on fix_rigid (version from 2008). ------------------------------------------------------------------------- */ +#include "fix_lb_rigid_pc_sphere.h" +#include #include -#include #include #include -#include "fix_lb_rigid_pc_sphere.h" #include "atom.h" -#include "atom_vec.h" #include "domain.h" #include "update.h" -#include "respa.h" #include "modify.h" #include "group.h" #include "comm.h" #include "force.h" -#include "output.h" #include "memory.h" #include "error.h" #include "fix_lb_fluid.h" diff --git a/src/USER-LB/fix_lb_viscous.cpp b/src/USER-LB/fix_lb_viscous.cpp index afe23477be..59fddebd67 100644 --- a/src/USER-LB/fix_lb_viscous.cpp +++ b/src/USER-LB/fix_lb_viscous.cpp @@ -15,10 +15,8 @@ Contributing authors: Frances Mackay, Santtu Ollila, Colin Denniston (UWO) ------------------------------------------------------------------------- */ -#include -#include -#include #include "fix_lb_viscous.h" +#include #include "atom.h" #include "update.h" #include "respa.h" diff --git a/src/USER-MGPT/pair_mgpt.h b/src/USER-MGPT/pair_mgpt.h index 3e861a0198..ff71edc9f3 100644 --- a/src/USER-MGPT/pair_mgpt.h +++ b/src/USER-MGPT/pair_mgpt.h @@ -30,8 +30,6 @@ PairStyle(mgpt,PairMGPT) #ifndef LMP_PAIR_MGPT_H #define LMP_PAIR_MGPT_H -#include -#include #include #include diff --git a/src/USER-MOLFILE/dump_molfile.cpp b/src/USER-MOLFILE/dump_molfile.cpp index 732fea74bd..d9d8ec3c97 100644 --- a/src/USER-MOLFILE/dump_molfile.cpp +++ b/src/USER-MOLFILE/dump_molfile.cpp @@ -15,15 +15,14 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include +#include "dump_molfile.h" +#include #include #include -#include "dump_molfile.h" #include "domain.h" #include "atom.h" #include "comm.h" #include "update.h" -#include "output.h" #include "group.h" #include "memory.h" #include "error.h" diff --git a/src/USER-MOLFILE/reader_molfile.cpp b/src/USER-MOLFILE/reader_molfile.cpp index ca1a61850c..5cff56753b 100644 --- a/src/USER-MOLFILE/reader_molfile.cpp +++ b/src/USER-MOLFILE/reader_molfile.cpp @@ -15,11 +15,9 @@ Contributing author: Axel Kohlmeyer (Temple U) ------------------------------------------------------------------------- */ -#include +#include "reader_molfile.h" #include #include -#include "reader_molfile.h" -#include "atom.h" #include "comm.h" #include "memory.h" #include "error.h" diff --git a/src/USER-OMP/fix_qeq_reax_omp.cpp b/src/USER-OMP/fix_qeq_reax_omp.cpp index 55e2b73812..f7945b5579 100644 --- a/src/USER-OMP/fix_qeq_reax_omp.cpp +++ b/src/USER-OMP/fix_qeq_reax_omp.cpp @@ -42,6 +42,7 @@ #include "memory.h" #include "error.h" #include "reaxc_defs.h" +#include "reaxc_types.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/pair_reaxc_omp.h b/src/USER-OMP/pair_reaxc_omp.h index ad8c368aaf..0cae28f56b 100644 --- a/src/USER-OMP/pair_reaxc_omp.h +++ b/src/USER-OMP/pair_reaxc_omp.h @@ -22,7 +22,6 @@ PairStyle(reax/c/omp,PairReaxCOMP) #include "pair_reaxc.h" #include "thr_omp.h" -#include "suffix.h" namespace LAMMPS_NS { diff --git a/src/USER-OMP/reaxc_bond_orders_omp.cpp b/src/USER-OMP/reaxc_bond_orders_omp.cpp index 17715c6e26..d581819e00 100644 --- a/src/USER-OMP/reaxc_bond_orders_omp.cpp +++ b/src/USER-OMP/reaxc_bond_orders_omp.cpp @@ -27,6 +27,9 @@ ----------------------------------------------------------------------*/ #include "reaxc_bond_orders_omp.h" +#include +#include +#include "fix_omp.h" #include "reaxc_defs.h" #include "pair_reaxc_omp.h" #include "reaxc_types.h" diff --git a/src/USER-OMP/reaxc_bonds_omp.cpp b/src/USER-OMP/reaxc_bonds_omp.cpp index 12ba1dcbfe..b6a76b3f3a 100644 --- a/src/USER-OMP/reaxc_bonds_omp.cpp +++ b/src/USER-OMP/reaxc_bonds_omp.cpp @@ -27,13 +27,12 @@ ----------------------------------------------------------------------*/ #include "reaxc_bonds_omp.h" +#include +#include +#include "fix_omp.h" #include "reaxc_defs.h" -#include "reaxc_bond_orders_omp.h" #include "pair_reaxc_omp.h" - #include "reaxc_list.h" -#include "reaxc_tool_box.h" -#include "reaxc_vector.h" #if defined(_OPENMP) #include diff --git a/src/USER-OMP/reaxc_forces_omp.cpp b/src/USER-OMP/reaxc_forces_omp.cpp index 1ada5e7e71..971667cc2d 100644 --- a/src/USER-OMP/reaxc_forces_omp.cpp +++ b/src/USER-OMP/reaxc_forces_omp.cpp @@ -27,19 +27,18 @@ ----------------------------------------------------------------------*/ #include "reaxc_forces_omp.h" +#include +#include +#include "fix_omp.h" #include "reaxc_defs.h" #include "pair_reaxc_omp.h" -#include "thr_data.h" #include "reaxc_bond_orders_omp.h" #include "reaxc_bonds_omp.h" #include "reaxc_hydrogen_bonds_omp.h" -#include "reaxc_io_tools.h" #include "reaxc_list.h" -#include "reaxc_lookup.h" #include "reaxc_multi_body_omp.h" #include "reaxc_nonbonded_omp.h" -#include "reaxc_tool_box.h" #include "reaxc_torsion_angles_omp.h" #include "reaxc_valence_angles_omp.h" #include "reaxc_vector.h" diff --git a/src/USER-OMP/reaxc_forces_omp.h b/src/USER-OMP/reaxc_forces_omp.h index d1e2a5c65a..6df0288656 100644 --- a/src/USER-OMP/reaxc_forces_omp.h +++ b/src/USER-OMP/reaxc_forces_omp.h @@ -30,7 +30,6 @@ #define __FORCES_OMP_H_ #include "reaxc_types.h" -#include "reaxc_defs.h" void Init_Force_FunctionsOMP( control_params* ); void Compute_ForcesOMP( reax_system*, control_params*, simulation_data*, diff --git a/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp b/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp index e3c034a12e..d06966a92d 100644 --- a/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp +++ b/src/USER-OMP/reaxc_hydrogen_bonds_omp.cpp @@ -27,9 +27,11 @@ ----------------------------------------------------------------------*/ #include "reaxc_hydrogen_bonds_omp.h" +#include +#include +#include "fix_omp.h" #include "pair_reaxc_omp.h" #include "reaxc_defs.h" -#include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" #include "reaxc_valence_angles.h" // To access Calculate_Theta() #include "reaxc_valence_angles_omp.h" // To access Calculate_dCos_ThetaOMP() diff --git a/src/USER-OMP/reaxc_init_md_omp.cpp b/src/USER-OMP/reaxc_init_md_omp.cpp index 847e916666..9d40479ddf 100644 --- a/src/USER-OMP/reaxc_init_md_omp.cpp +++ b/src/USER-OMP/reaxc_init_md_omp.cpp @@ -27,18 +27,15 @@ ----------------------------------------------------------------------*/ #include "reaxc_init_md_omp.h" -#include "pair_reaxc_omp.h" +#include #include "reaxc_defs.h" -#include "reaxc_allocate.h" #include "reaxc_forces.h" #include "reaxc_forces_omp.h" #include "reaxc_io_tools.h" #include "reaxc_list.h" #include "reaxc_lookup.h" -#include "reaxc_reset_tools.h" -#include "reaxc_system_props.h" #include "reaxc_tool_box.h" -#include "reaxc_vector.h" +#include "error.h" // Functions defined in reaxc_init_md.cpp extern int Init_MPI_Datatypes(reax_system*, storage*, mpi_datatypes*, MPI_Comm, char*); diff --git a/src/USER-OMP/reaxc_torsion_angles_omp.cpp b/src/USER-OMP/reaxc_torsion_angles_omp.cpp index 9cd716b594..68bacb7202 100644 --- a/src/USER-OMP/reaxc_torsion_angles_omp.cpp +++ b/src/USER-OMP/reaxc_torsion_angles_omp.cpp @@ -27,14 +27,13 @@ ----------------------------------------------------------------------*/ #include "reaxc_torsion_angles_omp.h" +#include +#include "fix_omp.h" #include "pair_reaxc_omp.h" -#include "thr_data.h" #include "reaxc_defs.h" #include "reaxc_types.h" -#include "reaxc_bond_orders_omp.h" #include "reaxc_list.h" -#include "reaxc_tool_box.h" #include "reaxc_vector.h" #if defined(_OPENMP) diff --git a/src/USER-PTM/ptm_index.cpp b/src/USER-PTM/ptm_index.cpp index b50e5c4333..cedd35126d 100644 --- a/src/USER-PTM/ptm_index.cpp +++ b/src/USER-PTM/ptm_index.cpp @@ -22,6 +22,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #include #include #include +#include static double calculate_interatomic_distance(int type, double scale) { assert(type >= 1 && type <= 8); diff --git a/src/USER-PTM/ptm_initialize_data.cpp b/src/USER-PTM/ptm_initialize_data.cpp index 1f0a5c94af..ff8245fe44 100644 --- a/src/USER-PTM/ptm_initialize_data.cpp +++ b/src/USER-PTM/ptm_initialize_data.cpp @@ -8,6 +8,10 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI */ #include "ptm_initialize_data.h" +#include "ptm_canonical_coloured.h" +#include "ptm_convex_hull_incremental.h" +#include "ptm_graph_tools.h" +#include "ptm_neighbour_ordering.h" #include diff --git a/src/USER-PTM/ptm_initialize_data.h b/src/USER-PTM/ptm_initialize_data.h index 20c9921962..4e7f3e8f0a 100644 --- a/src/USER-PTM/ptm_initialize_data.h +++ b/src/USER-PTM/ptm_initialize_data.h @@ -12,12 +12,8 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #include "ptm_graph_data.h" -#include "ptm_graph_tools.h" #include "ptm_deformation_gradient.h" #include "ptm_fundamental_mappings.h" -#include "ptm_neighbour_ordering.h" -#include "ptm_canonical_coloured.h" -#include "ptm_convex_hull_incremental.h" #include "ptm_alt_templates.h" From 2b5a6d3b7fe4cd96240c9970aa0ce089c318f8f5 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 15 Jul 2019 18:05:20 -0400 Subject: [PATCH 75/79] clean up (some) includes in KOKKOS package --- src/KOKKOS/fix_dpd_energy_kokkos.cpp | 5 ----- src/KOKKOS/fix_eos_table_rx_kokkos.cpp | 3 --- src/KOKKOS/fix_langevin_kokkos.cpp | 7 ++----- src/KOKKOS/fix_qeq_reax_kokkos.cpp | 7 ------- src/KOKKOS/fix_reaxc_bonds_kokkos.cpp | 13 ------------- src/KOKKOS/fix_reaxc_species_kokkos.cpp | 10 ---------- src/KOKKOS/fix_rx_kokkos.cpp | 2 -- src/KOKKOS/fix_setforce_kokkos.cpp | 4 +--- src/KOKKOS/fix_setforce_kokkos.h | 3 +-- src/KOKKOS/fix_shardlow_kokkos.cpp | 10 +--------- src/KOKKOS/improper_class2_kokkos.cpp | 7 ------- src/KOKKOS/improper_harmonic_kokkos.cpp | 6 ------ src/KOKKOS/nbin_ssa_kokkos.cpp | 3 --- src/KOKKOS/npair_copy_kokkos.cpp | 7 ------- src/KOKKOS/npair_skip_kokkos.cpp | 4 ---- src/KOKKOS/pair_buck_coul_cut_kokkos.cpp | 4 ---- src/KOKKOS/pair_buck_coul_long_kokkos.cpp | 6 ------ src/KOKKOS/pair_buck_kokkos.cpp | 6 ------ src/KOKKOS/pair_coul_cut_kokkos.cpp | 9 --------- src/KOKKOS/pair_coul_debye_kokkos.cpp | 6 ------ src/KOKKOS/pair_coul_dsf_kokkos.cpp | 7 ------- src/KOKKOS/pair_coul_long_kokkos.cpp | 6 ------ src/KOKKOS/pair_coul_wolf_kokkos.cpp | 7 ------- src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp | 6 ------ src/KOKKOS/pair_eam_alloy_kokkos.cpp | 2 -- src/KOKKOS/pair_eam_fs_kokkos.cpp | 2 -- src/KOKKOS/pair_eam_kokkos.cpp | 3 --- src/KOKKOS/pair_exp6_rx_kokkos.cpp | 4 ---- src/KOKKOS/pair_hybrid_kokkos.cpp | 5 ----- src/KOKKOS/pair_hybrid_overlay_kokkos.cpp | 3 --- .../pair_lj_charmm_coul_charmm_implicit_kokkos.cpp | 7 ------- src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp | 5 ----- src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_class2_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp | 4 ---- src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp | 4 ---- src/KOKKOS/pair_lj_cut_kokkos.cpp | 7 ------- src/KOKKOS/pair_lj_expand_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_gromacs_kokkos.cpp | 6 ------ src/KOKKOS/pair_lj_sdk_kokkos.cpp | 5 ----- src/KOKKOS/pair_morse_kokkos.cpp | 4 ---- src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp | 5 ----- src/KOKKOS/pair_reaxc_kokkos.cpp | 5 ----- src/KOKKOS/pair_sw_kokkos.cpp | 4 ---- src/KOKKOS/pair_table_kokkos.cpp | 4 ---- src/KOKKOS/pair_table_rx_kokkos.cpp | 1 - src/KOKKOS/pair_tersoff_kokkos.cpp | 6 ------ src/KOKKOS/pair_tersoff_mod_kokkos.cpp | 6 ------ src/KOKKOS/pair_tersoff_zbl_kokkos.cpp | 4 ---- src/KOKKOS/pair_vashishta_kokkos.cpp | 4 ---- src/KOKKOS/pair_yukawa_kokkos.cpp | 5 ----- src/KOKKOS/pair_zbl_kokkos.cpp | 6 ------ src/KOKKOS/pppm_kokkos.cpp | 5 ----- src/KOKKOS/region_block_kokkos.cpp | 4 ---- src/KOKKOS/verlet_kokkos.cpp | 7 ------- 60 files changed, 5 insertions(+), 318 deletions(-) diff --git a/src/KOKKOS/fix_dpd_energy_kokkos.cpp b/src/KOKKOS/fix_dpd_energy_kokkos.cpp index debad0407a..20579a6dc5 100644 --- a/src/KOKKOS/fix_dpd_energy_kokkos.cpp +++ b/src/KOKKOS/fix_dpd_energy_kokkos.cpp @@ -12,14 +12,9 @@ ------------------------------------------------------------------------- */ #include "fix_dpd_energy_kokkos.h" -#include -#include #include "atom_masks.h" #include "atom_kokkos.h" -#include "force.h" #include "update.h" -#include "respa.h" -#include "modify.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/KOKKOS/fix_eos_table_rx_kokkos.cpp b/src/KOKKOS/fix_eos_table_rx_kokkos.cpp index d0280eeef0..89561c9a92 100644 --- a/src/KOKKOS/fix_eos_table_rx_kokkos.cpp +++ b/src/KOKKOS/fix_eos_table_rx_kokkos.cpp @@ -16,15 +16,12 @@ ------------------------------------------------------------------------- */ #include "fix_eos_table_rx_kokkos.h" -#include -#include #include "atom_kokkos.h" #include "error.h" #include "force.h" #include "memory_kokkos.h" #include "comm.h" #include -#include "modify.h" #include "atom_masks.h" #define MAXLINE 1024 diff --git a/src/KOKKOS/fix_langevin_kokkos.cpp b/src/KOKKOS/fix_langevin_kokkos.cpp index 23a43b38ef..651f790a25 100644 --- a/src/KOKKOS/fix_langevin_kokkos.cpp +++ b/src/KOKKOS/fix_langevin_kokkos.cpp @@ -13,21 +13,18 @@ #include "fix_langevin_kokkos.h" #include -#include -#include #include "atom_masks.h" #include "atom_kokkos.h" #include "force.h" +#include "group.h" #include "update.h" -#include "respa.h" #include "error.h" #include "memory_kokkos.h" -#include "group.h" -#include "random_mars.h" #include "compute.h" #include "comm.h" #include "modify.h" #include "input.h" +#include "region.h" #include "variable.h" using namespace LAMMPS_NS; diff --git a/src/KOKKOS/fix_qeq_reax_kokkos.cpp b/src/KOKKOS/fix_qeq_reax_kokkos.cpp index 6f8392ab16..e51fbacaaf 100644 --- a/src/KOKKOS/fix_qeq_reax_kokkos.cpp +++ b/src/KOKKOS/fix_qeq_reax_kokkos.cpp @@ -18,24 +18,17 @@ #include "fix_qeq_reax_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "atom.h" #include "atom_masks.h" #include "atom_kokkos.h" #include "comm.h" #include "force.h" -#include "group.h" -#include "modify.h" #include "neighbor.h" #include "neigh_list_kokkos.h" #include "neigh_request.h" #include "update.h" #include "integrate.h" -#include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "pair_reaxc_kokkos.h" diff --git a/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp b/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp index 347c477476..51702bc603 100644 --- a/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp +++ b/src/KOKKOS/fix_reaxc_bonds_kokkos.cpp @@ -15,26 +15,13 @@ Contributing author: Stan Moore (Sandia) ------------------------------------------------------------------------- */ -#include "fix_ave_atom.h" -#include -#include #include "fix_reaxc_bonds_kokkos.h" #include "atom.h" -#include "update.h" #include "pair_reaxc_kokkos.h" -#include "modify.h" -#include "neighbor.h" -#include "neigh_list.h" -#include "neigh_request.h" -#include "comm.h" #include "force.h" #include "compute.h" -#include "input.h" -#include "variable.h" #include "memory_kokkos.h" #include "error.h" -#include "reaxc_list.h" -#include "reaxc_types.h" #include "reaxc_defs.h" #include "atom_masks.h" diff --git a/src/KOKKOS/fix_reaxc_species_kokkos.cpp b/src/KOKKOS/fix_reaxc_species_kokkos.cpp index f32bea2c67..f3bce2f9c0 100644 --- a/src/KOKKOS/fix_reaxc_species_kokkos.cpp +++ b/src/KOKKOS/fix_reaxc_species_kokkos.cpp @@ -16,27 +16,17 @@ ------------------------------------------------------------------------- */ #include "fix_reaxc_species_kokkos.h" -#include -#include #include "atom.h" -#include #include "fix_ave_atom.h" -#include "domain.h" -#include "update.h" #include "reaxc_defs.h" #include "pair_reaxc_kokkos.h" -#include "modify.h" -#include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "comm.h" #include "force.h" -#include "compute.h" #include "input.h" -#include "variable.h" #include "memory_kokkos.h" #include "error.h" -#include "reaxc_list.h" #include "atom_masks.h" using namespace LAMMPS_NS; diff --git a/src/KOKKOS/fix_rx_kokkos.cpp b/src/KOKKOS/fix_rx_kokkos.cpp index 050dda2400..e06fc14585 100644 --- a/src/KOKKOS/fix_rx_kokkos.cpp +++ b/src/KOKKOS/fix_rx_kokkos.cpp @@ -12,14 +12,12 @@ ------------------------------------------------------------------------- */ #include "fix_rx_kokkos.h" -#include #include #include "atom_masks.h" #include "atom_kokkos.h" #include "force.h" #include "memory_kokkos.h" #include "update.h" -#include "respa.h" #include "modify.h" #include "neighbor.h" #include "neigh_list_kokkos.h" diff --git a/src/KOKKOS/fix_setforce_kokkos.cpp b/src/KOKKOS/fix_setforce_kokkos.cpp index 03cfd3afb2..4165b100f5 100644 --- a/src/KOKKOS/fix_setforce_kokkos.cpp +++ b/src/KOKKOS/fix_setforce_kokkos.cpp @@ -13,20 +13,18 @@ #include "fix_setforce_kokkos.h" #include -#include #include "atom_kokkos.h" #include "update.h" #include "modify.h" #include "domain.h" #include "region.h" -#include "respa.h" #include "input.h" #include "variable.h" #include "memory_kokkos.h" #include "error.h" -#include "force.h" #include "atom_masks.h" #include "kokkos_base.h" +#include "region.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/KOKKOS/fix_setforce_kokkos.h b/src/KOKKOS/fix_setforce_kokkos.h index 3cbf3d3720..ecbfd71e36 100644 --- a/src/KOKKOS/fix_setforce_kokkos.h +++ b/src/KOKKOS/fix_setforce_kokkos.h @@ -23,7 +23,6 @@ FixStyle(setforce/kk/host,FixSetForceKokkos) #define LMP_FIX_SET_FORCE_KOKKOS_H #include "fix_setforce.h" -#include "region.h" #include "kokkos_type.h" namespace LAMMPS_NS { @@ -82,7 +81,7 @@ class FixSetForceKokkos : public FixSetForce { typename AT::t_f_array f; typename AT::t_int_1d_randomread mask; - Region* region; + class Region* region; }; } diff --git a/src/KOKKOS/fix_shardlow_kokkos.cpp b/src/KOKKOS/fix_shardlow_kokkos.cpp index 96f67ccb5e..9bd8594341 100644 --- a/src/KOKKOS/fix_shardlow_kokkos.cpp +++ b/src/KOKKOS/fix_shardlow_kokkos.cpp @@ -34,30 +34,22 @@ ------------------------------------------------------------------------- */ #include "fix_shardlow_kokkos.h" -#include +#include #include -#include #include "atom.h" #include "atom_masks.h" #include "atom_kokkos.h" #include "force.h" #include "update.h" -#include "respa.h" #include "error.h" -#include -#include "atom_vec.h" #include "comm.h" #include "neighbor.h" #include "neigh_list_kokkos.h" #include "neigh_request.h" #include "memory_kokkos.h" #include "domain.h" -#include "modify.h" -// #include "pair_dpd_fdt.h" #include "pair_dpd_fdt_energy_kokkos.h" -#include "pair.h" #include "npair_ssa_kokkos.h" -#include "citeme.h" using namespace LAMMPS_NS; using namespace FixConst; diff --git a/src/KOKKOS/improper_class2_kokkos.cpp b/src/KOKKOS/improper_class2_kokkos.cpp index 84b721bd2a..defd5e16f5 100644 --- a/src/KOKKOS/improper_class2_kokkos.cpp +++ b/src/KOKKOS/improper_class2_kokkos.cpp @@ -16,22 +16,15 @@ ------------------------------------------------------------------------- */ #include "improper_class2_kokkos.h" -#include #include -#include #include "atom_kokkos.h" -#include "comm.h" #include "neighbor_kokkos.h" -#include "domain.h" #include "force.h" -#include "update.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define TOLERANCE 0.05 #define SMALL 0.001 diff --git a/src/KOKKOS/improper_harmonic_kokkos.cpp b/src/KOKKOS/improper_harmonic_kokkos.cpp index 262ffe7700..7d6437dbf5 100644 --- a/src/KOKKOS/improper_harmonic_kokkos.cpp +++ b/src/KOKKOS/improper_harmonic_kokkos.cpp @@ -16,22 +16,16 @@ ------------------------------------------------------------------------- */ #include "improper_harmonic_kokkos.h" -#include #include -#include #include "atom_kokkos.h" #include "comm.h" #include "neighbor_kokkos.h" -#include "domain.h" #include "force.h" -#include "update.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define TOLERANCE 0.05 #define SMALL 0.001 diff --git a/src/KOKKOS/nbin_ssa_kokkos.cpp b/src/KOKKOS/nbin_ssa_kokkos.cpp index ecf0e08535..0e46f7fc61 100644 --- a/src/KOKKOS/nbin_ssa_kokkos.cpp +++ b/src/KOKKOS/nbin_ssa_kokkos.cpp @@ -19,11 +19,8 @@ #include "nbin_ssa_kokkos.h" #include "neighbor.h" #include "atom_kokkos.h" -#include "group.h" #include "domain.h" -#include "comm.h" #include "update.h" -#include "error.h" #include "atom_masks.h" // #include "memory_kokkos.h" diff --git a/src/KOKKOS/npair_copy_kokkos.cpp b/src/KOKKOS/npair_copy_kokkos.cpp index 7dde05745c..0ce0f4d3ff 100644 --- a/src/KOKKOS/npair_copy_kokkos.cpp +++ b/src/KOKKOS/npair_copy_kokkos.cpp @@ -12,14 +12,7 @@ ------------------------------------------------------------------------- */ #include "npair_copy_kokkos.h" -#include "neighbor.h" #include "neigh_list_kokkos.h" -#include "atom.h" -#include "atom_vec.h" -#include "molecule.h" -#include "domain.h" -#include "my_page.h" -#include "error.h" using namespace LAMMPS_NS; diff --git a/src/KOKKOS/npair_skip_kokkos.cpp b/src/KOKKOS/npair_skip_kokkos.cpp index e614e624c9..bb393c9b95 100644 --- a/src/KOKKOS/npair_skip_kokkos.cpp +++ b/src/KOKKOS/npair_skip_kokkos.cpp @@ -12,13 +12,9 @@ ------------------------------------------------------------------------- */ #include "npair_skip_kokkos.h" -#include "neighbor.h" #include "neigh_list_kokkos.h" #include "atom_kokkos.h" #include "atom_vec.h" -#include "molecule.h" -#include "domain.h" -#include "my_page.h" #include "error.h" #include "atom_masks.h" diff --git a/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp b/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp index e3843262a5..2a72617525 100644 --- a/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_buck_coul_cut_kokkos.cpp @@ -17,18 +17,14 @@ #include "pair_buck_coul_cut_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory_kokkos.h" diff --git a/src/KOKKOS/pair_buck_coul_long_kokkos.cpp b/src/KOKKOS/pair_buck_coul_long_kokkos.cpp index 7457a0988f..fdf395684a 100644 --- a/src/KOKKOS/pair_buck_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_buck_coul_long_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_buck_coul_long_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_buck_kokkos.cpp b/src/KOKKOS/pair_buck_kokkos.cpp index 131622cac5..375d0dc1ea 100644 --- a/src/KOKKOS/pair_buck_kokkos.cpp +++ b/src/KOKKOS/pair_buck_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_buck_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_coul_cut_kokkos.cpp b/src/KOKKOS/pair_coul_cut_kokkos.cpp index e79f103363..5a1a6eefac 100644 --- a/src/KOKKOS/pair_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_coul_cut_kokkos.cpp @@ -13,26 +13,17 @@ #include "pair_coul_cut_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_coul_debye_kokkos.cpp b/src/KOKKOS/pair_coul_debye_kokkos.cpp index 0fe03af043..8dd7e4f3d2 100644 --- a/src/KOKKOS/pair_coul_debye_kokkos.cpp +++ b/src/KOKKOS/pair_coul_debye_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_coul_debye_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_coul_dsf_kokkos.cpp b/src/KOKKOS/pair_coul_dsf_kokkos.cpp index e94aae4754..836b12ba39 100644 --- a/src/KOKKOS/pair_coul_dsf_kokkos.cpp +++ b/src/KOKKOS/pair_coul_dsf_kokkos.cpp @@ -17,20 +17,13 @@ #include "pair_coul_dsf_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list_kokkos.h" #include "neigh_request.h" #include "memory_kokkos.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "math_const.h" #include "error.h" #include "atom_masks.h" diff --git a/src/KOKKOS/pair_coul_long_kokkos.cpp b/src/KOKKOS/pair_coul_long_kokkos.cpp index 67132e11f6..84b89c6373 100644 --- a/src/KOKKOS/pair_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_coul_long_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_coul_long_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_coul_wolf_kokkos.cpp b/src/KOKKOS/pair_coul_wolf_kokkos.cpp index dbbb865961..3ca8f16a79 100644 --- a/src/KOKKOS/pair_coul_wolf_kokkos.cpp +++ b/src/KOKKOS/pair_coul_wolf_kokkos.cpp @@ -17,19 +17,12 @@ #include "pair_coul_wolf_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list_kokkos.h" #include "neigh_request.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "math_const.h" #include "memory_kokkos.h" #include "error.h" diff --git a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp index 27a7a59c2a..21fd32a2c8 100644 --- a/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp +++ b/src/KOKKOS/pair_dpd_fdt_energy_kokkos.cpp @@ -17,20 +17,14 @@ #include "pair_dpd_fdt_energy_kokkos.h" #include -#include -#include -#include #include "atom_kokkos.h" -#include "atom_vec.h" #include "comm.h" #include "update.h" -#include "fix.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "memory_kokkos.h" -#include "modify.h" #include "error.h" #include "atom_masks.h" #include "kokkos.h" diff --git a/src/KOKKOS/pair_eam_alloy_kokkos.cpp b/src/KOKKOS/pair_eam_alloy_kokkos.cpp index aa33d44eee..48bf63386a 100644 --- a/src/KOKKOS/pair_eam_alloy_kokkos.cpp +++ b/src/KOKKOS/pair_eam_alloy_kokkos.cpp @@ -17,8 +17,6 @@ #include "pair_eam_alloy_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "pair_kokkos.h" diff --git a/src/KOKKOS/pair_eam_fs_kokkos.cpp b/src/KOKKOS/pair_eam_fs_kokkos.cpp index 9832a16a73..6536dd745a 100644 --- a/src/KOKKOS/pair_eam_fs_kokkos.cpp +++ b/src/KOKKOS/pair_eam_fs_kokkos.cpp @@ -17,8 +17,6 @@ #include "pair_eam_fs_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "pair_kokkos.h" diff --git a/src/KOKKOS/pair_eam_kokkos.cpp b/src/KOKKOS/pair_eam_kokkos.cpp index 4c6fadfe92..f6eef5b53c 100644 --- a/src/KOKKOS/pair_eam_kokkos.cpp +++ b/src/KOKKOS/pair_eam_kokkos.cpp @@ -17,9 +17,6 @@ #include "pair_eam_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "pair_kokkos.h" #include "atom_kokkos.h" diff --git a/src/KOKKOS/pair_exp6_rx_kokkos.cpp b/src/KOKKOS/pair_exp6_rx_kokkos.cpp index 31a48fe154..8698687377 100644 --- a/src/KOKKOS/pair_exp6_rx_kokkos.cpp +++ b/src/KOKKOS/pair_exp6_rx_kokkos.cpp @@ -17,18 +17,15 @@ #include "pair_exp6_rx_kokkos.h" #include -#include #include #include #include "atom.h" #include "comm.h" #include "force.h" #include "neigh_list.h" -#include "math_const.h" #include "math_special_kokkos.h" #include "memory_kokkos.h" #include "error.h" -#include "modify.h" #include "fix.h" #include #include "atom_masks.h" @@ -41,7 +38,6 @@ #endif using namespace LAMMPS_NS; -using namespace MathConst; using namespace MathSpecialKokkos; #define MAXLINE 1024 diff --git a/src/KOKKOS/pair_hybrid_kokkos.cpp b/src/KOKKOS/pair_hybrid_kokkos.cpp index c767d9f470..b5b0a9d02b 100644 --- a/src/KOKKOS/pair_hybrid_kokkos.cpp +++ b/src/KOKKOS/pair_hybrid_kokkos.cpp @@ -12,19 +12,14 @@ ------------------------------------------------------------------------- */ #include "pair_hybrid_kokkos.h" -#include -#include #include -#include #include "atom_kokkos.h" #include "force.h" #include "pair.h" #include "neighbor.h" #include "neigh_request.h" #include "update.h" -#include "comm.h" #include "memory_kokkos.h" -#include "error.h" #include "respa.h" #include "atom_masks.h" #include "kokkos.h" diff --git a/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp b/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp index cb1389d38e..0cebd79c88 100644 --- a/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp +++ b/src/KOKKOS/pair_hybrid_overlay_kokkos.cpp @@ -12,13 +12,10 @@ ------------------------------------------------------------------------- */ #include "pair_hybrid_overlay_kokkos.h" -#include #include #include #include "atom.h" #include "force.h" -#include "neighbor.h" -#include "neigh_request.h" #include "error.h" using namespace LAMMPS_NS; diff --git a/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp index b7c3766d5f..ae6cb61b60 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_charmm_implicit_kokkos.cpp @@ -16,27 +16,20 @@ ------------------------------------------------------------------------- */ #include "pair_lj_charmm_coul_charmm_implicit_kokkos.h" -#include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp index c6a1e3211d..9cdef267e2 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_charmm_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_lj_charmm_coul_charmm_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp index 4ba0651601..441070248d 100644 --- a/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_charmm_coul_long_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_lj_charmm_coul_long_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp b/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp index ef8fe7a128..1f7642e965 100644 --- a/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_coul_cut_kokkos.cpp @@ -13,8 +13,6 @@ #include "pair_lj_class2_coul_cut_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" @@ -24,15 +22,12 @@ #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp index 5a25d0250b..c88ff9378e 100644 --- a/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_coul_long_kokkos.cpp @@ -13,26 +13,20 @@ #include "pair_lj_class2_coul_long_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_class2_kokkos.cpp b/src/KOKKOS/pair_lj_class2_kokkos.cpp index 6d673b2d01..9900e7361f 100644 --- a/src/KOKKOS/pair_lj_class2_kokkos.cpp +++ b/src/KOKKOS/pair_lj_class2_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_lj_class2_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp index 9201a116b5..1601e4a4b2 100644 --- a/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_cut_kokkos.cpp @@ -13,26 +13,20 @@ #include "pair_lj_cut_coul_cut_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp index 8935333c74..6e7d1eeb8b 100644 --- a/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_debye_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_lj_cut_coul_debye_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp index aea70faec4..b7dc7cc26d 100644 --- a/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_dsf_kokkos.cpp @@ -17,18 +17,14 @@ #include "pair_lj_cut_coul_dsf_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory_kokkos.h" diff --git a/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp b/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp index 53d27f2447..122d59af82 100644 --- a/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_coul_long_kokkos.cpp @@ -13,18 +13,14 @@ #include "pair_lj_cut_coul_long_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory_kokkos.h" diff --git a/src/KOKKOS/pair_lj_cut_kokkos.cpp b/src/KOKKOS/pair_lj_cut_kokkos.cpp index ee29e12322..df750b7524 100644 --- a/src/KOKKOS/pair_lj_cut_kokkos.cpp +++ b/src/KOKKOS/pair_lj_cut_kokkos.cpp @@ -12,27 +12,20 @@ ------------------------------------------------------------------------- */ #include "pair_lj_cut_kokkos.h" -#include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_expand_kokkos.cpp b/src/KOKKOS/pair_lj_expand_kokkos.cpp index 061fc205fb..38bebc364f 100644 --- a/src/KOKKOS/pair_lj_expand_kokkos.cpp +++ b/src/KOKKOS/pair_lj_expand_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_lj_expand_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp b/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp index 4df9fdea9e..a46a5c0441 100644 --- a/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp +++ b/src/KOKKOS/pair_lj_gromacs_coul_gromacs_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_lj_gromacs_coul_gromacs_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_gromacs_kokkos.cpp b/src/KOKKOS/pair_lj_gromacs_kokkos.cpp index 2d395c39d5..23ed5e5595 100644 --- a/src/KOKKOS/pair_lj_gromacs_kokkos.cpp +++ b/src/KOKKOS/pair_lj_gromacs_kokkos.cpp @@ -17,26 +17,20 @@ #include "pair_lj_gromacs_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_lj_sdk_kokkos.cpp b/src/KOKKOS/pair_lj_sdk_kokkos.cpp index 14c53c38bf..25f081d255 100644 --- a/src/KOKKOS/pair_lj_sdk_kokkos.cpp +++ b/src/KOKKOS/pair_lj_sdk_kokkos.cpp @@ -14,19 +14,15 @@ #include "pair_lj_sdk_kokkos.h" #include #include -#include #include #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" #include "force.h" #include "neighbor.h" -#include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" @@ -34,7 +30,6 @@ #include "lj_sdk_common.h" using namespace LAMMPS_NS; -using namespace MathConst; using namespace LJSDKParms; #define KOKKOS_CUDA_MAX_THREADS 256 diff --git a/src/KOKKOS/pair_morse_kokkos.cpp b/src/KOKKOS/pair_morse_kokkos.cpp index d679477321..d3e3042a34 100644 --- a/src/KOKKOS/pair_morse_kokkos.cpp +++ b/src/KOKKOS/pair_morse_kokkos.cpp @@ -17,18 +17,14 @@ #include "pair_morse_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" #include "math_const.h" #include "memory_kokkos.h" diff --git a/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp b/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp index 81a4aa7a82..75247859ed 100644 --- a/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp +++ b/src/KOKKOS/pair_multi_lucy_rx_kokkos.cpp @@ -22,9 +22,7 @@ ------------------------------------------------------------------------------------------- */ #include "pair_multi_lucy_rx_kokkos.h" -#include #include -#include #include #include "math_const.h" #include "atom_kokkos.h" @@ -33,9 +31,6 @@ #include "neigh_list.h" #include "memory_kokkos.h" #include "error.h" -#include "citeme.h" -#include "modify.h" -#include "fix.h" #include "atom_masks.h" #include "neigh_request.h" #include "kokkos.h" diff --git a/src/KOKKOS/pair_reaxc_kokkos.cpp b/src/KOKKOS/pair_reaxc_kokkos.cpp index ca897a377c..d0ad1f1b09 100644 --- a/src/KOKKOS/pair_reaxc_kokkos.cpp +++ b/src/KOKKOS/pair_reaxc_kokkos.cpp @@ -17,7 +17,6 @@ #include "pair_reaxc_kokkos.h" #include -#include #include #include #include "kokkos.h" @@ -27,9 +26,6 @@ #include "neighbor.h" #include "neigh_request.h" #include "neigh_list_kokkos.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "math_const.h" #include "math_special.h" #include "memory_kokkos.h" @@ -38,7 +34,6 @@ #include "reaxc_defs.h" #include "reaxc_lookup.h" #include "reaxc_tool_box.h" -#include "modify.h" #define TEAMSIZE 128 diff --git a/src/KOKKOS/pair_sw_kokkos.cpp b/src/KOKKOS/pair_sw_kokkos.cpp index dbd45747f0..e85afa362f 100644 --- a/src/KOKKOS/pair_sw_kokkos.cpp +++ b/src/KOKKOS/pair_sw_kokkos.cpp @@ -17,9 +17,6 @@ #include "pair_sw_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "pair_kokkos.h" #include "atom_kokkos.h" @@ -30,7 +27,6 @@ #include "memory_kokkos.h" #include "neighbor.h" #include "neigh_list_kokkos.h" -#include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" #include "math_const.h" diff --git a/src/KOKKOS/pair_table_kokkos.cpp b/src/KOKKOS/pair_table_kokkos.cpp index 01966d708a..5ee24ad479 100644 --- a/src/KOKKOS/pair_table_kokkos.cpp +++ b/src/KOKKOS/pair_table_kokkos.cpp @@ -16,14 +16,10 @@ ------------------------------------------------------------------------- */ #include "pair_table_kokkos.h" -#include -#include -#include #include #include "kokkos.h" #include "atom.h" #include "force.h" -#include "comm.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" diff --git a/src/KOKKOS/pair_table_rx_kokkos.cpp b/src/KOKKOS/pair_table_rx_kokkos.cpp index 7c2d20c68d..daebeda8db 100644 --- a/src/KOKKOS/pair_table_rx_kokkos.cpp +++ b/src/KOKKOS/pair_table_rx_kokkos.cpp @@ -18,7 +18,6 @@ #include "pair_table_rx_kokkos.h" #include #include -#include #include #include "kokkos.h" #include "atom.h" diff --git a/src/KOKKOS/pair_tersoff_kokkos.cpp b/src/KOKKOS/pair_tersoff_kokkos.cpp index b68af84425..b360b20ef3 100644 --- a/src/KOKKOS/pair_tersoff_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_kokkos.cpp @@ -17,9 +17,6 @@ #include "pair_tersoff_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" @@ -27,9 +24,6 @@ #include "neighbor.h" #include "neigh_request.h" #include "neigh_list_kokkos.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "math_const.h" #include "memory_kokkos.h" #include "error.h" diff --git a/src/KOKKOS/pair_tersoff_mod_kokkos.cpp b/src/KOKKOS/pair_tersoff_mod_kokkos.cpp index b6921179c0..81ef486999 100644 --- a/src/KOKKOS/pair_tersoff_mod_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_mod_kokkos.cpp @@ -17,9 +17,6 @@ #include "pair_tersoff_mod_kokkos.h" #include -#include -#include -#include #include "kokkos.h" #include "atom_kokkos.h" #include "comm.h" @@ -27,9 +24,6 @@ #include "neighbor.h" #include "neigh_request.h" #include "neigh_list_kokkos.h" -#include "update.h" -#include "integrate.h" -#include "respa.h" #include "math_const.h" #include "memory_kokkos.h" #include "error.h" diff --git a/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp b/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp index 60ff0a7269..4593f32e36 100644 --- a/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp +++ b/src/KOKKOS/pair_tersoff_zbl_kokkos.cpp @@ -17,8 +17,6 @@ #include "pair_tersoff_zbl_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "atom_kokkos.h" @@ -28,8 +26,6 @@ #include "neigh_request.h" #include "neigh_list_kokkos.h" #include "update.h" -#include "integrate.h" -#include "respa.h" #include "math_const.h" #include "memory_kokkos.h" #include "error.h" diff --git a/src/KOKKOS/pair_vashishta_kokkos.cpp b/src/KOKKOS/pair_vashishta_kokkos.cpp index febb171c83..614d3334d5 100644 --- a/src/KOKKOS/pair_vashishta_kokkos.cpp +++ b/src/KOKKOS/pair_vashishta_kokkos.cpp @@ -17,8 +17,6 @@ #include "pair_vashishta_kokkos.h" #include -#include -#include #include #include "kokkos.h" #include "pair_kokkos.h" @@ -28,9 +26,7 @@ #include "force.h" #include "comm.h" #include "memory_kokkos.h" -#include "neighbor.h" #include "neigh_list_kokkos.h" -#include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" #include "math_const.h" diff --git a/src/KOKKOS/pair_yukawa_kokkos.cpp b/src/KOKKOS/pair_yukawa_kokkos.cpp index acfeb2fbdc..6dfffd4a54 100644 --- a/src/KOKKOS/pair_yukawa_kokkos.cpp +++ b/src/KOKKOS/pair_yukawa_kokkos.cpp @@ -17,24 +17,19 @@ #include "pair_yukawa_kokkos.h" #include -#include #include "kokkos.h" #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" using namespace LAMMPS_NS; -using namespace MathConst; #define KOKKOS_CUDA_MAX_THREADS 256 #define KOKKOS_CUDA_MIN_BLOCKS 8 diff --git a/src/KOKKOS/pair_zbl_kokkos.cpp b/src/KOKKOS/pair_zbl_kokkos.cpp index 0f21331266..5697dd5b00 100644 --- a/src/KOKKOS/pair_zbl_kokkos.cpp +++ b/src/KOKKOS/pair_zbl_kokkos.cpp @@ -17,19 +17,14 @@ #include "pair_zbl_kokkos.h" #include -#include -#include #include #include "atom_kokkos.h" -#include "comm.h" #include "force.h" #include "neighbor.h" #include "neigh_list.h" #include "neigh_request.h" #include "update.h" -#include "integrate.h" #include "respa.h" -#include "math_const.h" #include "memory_kokkos.h" #include "error.h" #include "atom_masks.h" @@ -39,7 +34,6 @@ // "The Stopping and Range of Ions in Matter" volume 1, Pergamon, 1985. using namespace LAMMPS_NS; -using namespace MathConst; using namespace PairZBLConstants; /* ---------------------------------------------------------------------- */ diff --git a/src/KOKKOS/pppm_kokkos.cpp b/src/KOKKOS/pppm_kokkos.cpp index 1842524e23..3e70602f67 100644 --- a/src/KOKKOS/pppm_kokkos.cpp +++ b/src/KOKKOS/pppm_kokkos.cpp @@ -17,9 +17,6 @@ #include "pppm_kokkos.h" #include -#include -#include -#include #include #include "atom_kokkos.h" #include "comm.h" @@ -27,8 +24,6 @@ #include "neighbor.h" #include "force.h" #include "pair.h" -#include "bond.h" -#include "angle.h" #include "domain.h" #include "fft3d_wrap.h" #include "remap_wrap.h" diff --git a/src/KOKKOS/region_block_kokkos.cpp b/src/KOKKOS/region_block_kokkos.cpp index a5734f6ba7..b28230290e 100644 --- a/src/KOKKOS/region_block_kokkos.cpp +++ b/src/KOKKOS/region_block_kokkos.cpp @@ -12,10 +12,6 @@ ------------------------------------------------------------------------- */ #include "region_block_kokkos.h" -#include -#include -#include "domain.h" -#include "force.h" #include "atom_kokkos.h" #include "atom_masks.h" diff --git a/src/KOKKOS/verlet_kokkos.cpp b/src/KOKKOS/verlet_kokkos.cpp index d555b74d23..2d2f0a9815 100644 --- a/src/KOKKOS/verlet_kokkos.cpp +++ b/src/KOKKOS/verlet_kokkos.cpp @@ -12,11 +12,9 @@ ------------------------------------------------------------------------- */ #include "verlet_kokkos.h" -#include #include "neighbor.h" #include "domain.h" #include "comm.h" -#include "atom.h" #include "atom_kokkos.h" #include "atom_masks.h" #include "force.h" @@ -29,15 +27,10 @@ #include "output.h" #include "update.h" #include "modify.h" -#include "compute.h" -#include "fix.h" #include "timer.h" #include "memory_kokkos.h" -#include "error.h" #include "kokkos.h" -#include - using namespace LAMMPS_NS; template From 320be3bcef1b9e08a9a6c4b184fe6b1f687509da Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 22 Jul 2019 14:22:36 -0400 Subject: [PATCH 76/79] undo changes to poems library and package as they fail regression testing --- lib/poems/POEMSChain.h | 99 +++--- lib/poems/SystemProcessor.h | 439 ++++++++++++----------- lib/poems/body.cpp | 15 +- lib/poems/body.h | 23 +- lib/poems/body23joint.cpp | 19 +- lib/poems/body23joint.h | 9 +- lib/poems/colmatmap.cpp | 2 - lib/poems/colmatmap.h | 6 +- lib/poems/colmatrix.cpp | 5 +- lib/poems/colmatrix.h | 45 ++- lib/poems/defines.h | 7 +- lib/poems/eulerparameters.cpp | 46 ++- lib/poems/eulerparameters.h | 9 +- lib/poems/fastmatrixops.cpp | 143 ++++---- lib/poems/fastmatrixops.h | 17 +- lib/poems/fixedpoint.cpp | 5 - lib/poems/fixedpoint.h | 5 +- lib/poems/freebodyjoint.cpp | 134 ++++--- lib/poems/freebodyjoint.h | 11 +- lib/poems/inertialframe.cpp | 6 +- lib/poems/inertialframe.h | 7 +- lib/poems/joint.cpp | 23 +- lib/poems/joint.h | 12 +- lib/poems/mat3x3.cpp | 5 +- lib/poems/mat3x3.h | 17 +- lib/poems/mat4x4.cpp | 4 - lib/poems/mat4x4.h | 15 +- lib/poems/mat6x6.cpp | 4 - lib/poems/mat6x6.h | 6 +- lib/poems/matrices.h | 13 +- lib/poems/matrix.cpp | 2 - lib/poems/matrix.h | 10 +- lib/poems/matrixfun.cpp | 58 ++- lib/poems/matrixfun.h | 35 +- lib/poems/mixedjoint.cpp | 141 ++++---- lib/poems/mixedjoint.h | 16 +- lib/poems/norm.cpp | 8 - lib/poems/norm.h | 14 +- lib/poems/onbody.cpp | 9 +- lib/poems/onbody.h | 118 +++---- lib/poems/onfunctions.cpp | 49 ++- lib/poems/onfunctions.h | 8 +- lib/poems/onsolver.cpp | 16 +- lib/poems/onsolver.h | 51 ++- lib/poems/particle.cpp | 3 +- lib/poems/particle.h | 12 +- lib/poems/poemslist.h | 74 ++-- lib/poems/poemsnodelib.h | 11 +- lib/poems/poemsobject.cpp | 2 - lib/poems/poemsobject.h | 4 +- lib/poems/poemstree.h | 4 +- lib/poems/poemstreenode.cpp | 2 - lib/poems/poemstreenode.h | 45 +-- lib/poems/point.cpp | 8 +- lib/poems/point.h | 18 +- lib/poems/prismaticjoint.cpp | 6 - lib/poems/prismaticjoint.h | 9 +- lib/poems/revolutejoint.cpp | 6 - lib/poems/revolutejoint.h | 8 +- lib/poems/rigidbody.cpp | 5 +- lib/poems/rigidbody.h | 5 +- lib/poems/rowmatrix.cpp | 4 +- lib/poems/rowmatrix.h | 6 +- lib/poems/solver.cpp | 5 +- lib/poems/solver.h | 23 +- lib/poems/sphericaljoint.cpp | 200 +++++------ lib/poems/sphericaljoint.h | 9 +- lib/poems/system.cpp | 622 ++++++++++++++++----------------- lib/poems/system.h | 62 ++-- lib/poems/vect3.cpp | 11 - lib/poems/vect3.h | 12 +- lib/poems/vect4.cpp | 4 - lib/poems/vect4.h | 13 +- lib/poems/vect6.cpp | 4 - lib/poems/vect6.h | 6 +- lib/poems/virtualcolmatrix.cpp | 2 - lib/poems/virtualcolmatrix.h | 40 +-- lib/poems/virtualmatrix.cpp | 6 +- lib/poems/virtualmatrix.h | 3 +- lib/poems/virtualrowmatrix.cpp | 2 - lib/poems/virtualrowmatrix.h | 11 +- lib/poems/workspace.cpp | 21 +- lib/poems/workspace.h | 76 ++-- src/POEMS/fix_poems.cpp | 2 +- src/POEMS/fix_poems.h | 3 +- 85 files changed, 1399 insertions(+), 1656 deletions(-) diff --git a/lib/poems/POEMSChain.h b/lib/poems/POEMSChain.h index 8baa293dbd..9f0db59333 100644 --- a/lib/poems/POEMSChain.h +++ b/lib/poems/POEMSChain.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: PoemsChain.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -19,59 +19,56 @@ #define POEMSCHAIN_H_ #include "poemslist.h" -#include -namespace POEMS { struct ChildRingData { - List * childRing; - int entranceNodeId; + List * childRing; + int entranceNodeId; }; struct POEMSChain{ - ~POEMSChain(){ - for(int i = 0; i < childChains.GetNumElements(); i++) - { - delete childChains(i); - } - listOfNodes.DeleteValues(); - } - //void printTreeStructure(int tabs); - //void getTreeAsList(List * temp); - List listOfNodes; - List childChains; - POEMSChain * parentChain; - List childRings; - - - void printTreeStructure(int tabs){ - for(int i = 0; i < tabs; i++) - { - std::cout << "\t"; - } - std::cout << "Chain: "; - for(int i = 0; i < listOfNodes.GetNumElements(); i++) - { - std::cout << *(listOfNodes(i)) << " "; - } - std::cout << std::endl; - for(int i = 0; i < childChains.GetNumElements(); i++) - { - childChains(i)->printTreeStructure(tabs + 1); - } - } - void getTreeAsList(List * temp) - { - for(int i = 0; i < listOfNodes.GetNumElements(); i++) - { - int * integer = new int; - *integer = *(listOfNodes(i)); - temp->Append(integer); - } - for(int i = 0; i < childChains.GetNumElements(); i++) - { - childChains(i)->getTreeAsList(temp); - } - } + ~POEMSChain(){ + for(int i = 0; i < childChains.GetNumElements(); i++) + { + delete childChains(i); + } + listOfNodes.DeleteValues(); + } + //void printTreeStructure(int tabs); + //void getTreeAsList(List * temp); + List listOfNodes; + List childChains; + POEMSChain * parentChain; + List childRings; + + + void printTreeStructure(int tabs){ + for(int i = 0; i < tabs; i++) + { + cout << "\t"; + } + cout << "Chain: "; + for(int i = 0; i < listOfNodes.GetNumElements(); i++) + { + cout << *(listOfNodes(i)) << " "; + } + cout << endl; + for(int i = 0; i < childChains.GetNumElements(); i++) + { + childChains(i)->printTreeStructure(tabs + 1); + } + } + void getTreeAsList(List * temp) + { + for(int i = 0; i < listOfNodes.GetNumElements(); i++) + { + int * integer = new int; + *integer = *(listOfNodes(i)); + temp->Append(integer); + } + for(int i = 0; i < childChains.GetNumElements(); i++) + { + childChains(i)->getTreeAsList(temp); + } + } }; -} #endif diff --git a/lib/poems/SystemProcessor.h b/lib/poems/SystemProcessor.h index a6001d96d0..3be168c34d 100644 --- a/lib/poems/SystemProcessor.h +++ b/lib/poems/SystemProcessor.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: SystemProcessor.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,61 +11,59 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef _SYS_PROCESSOR_H_ #define _SYS_PROCESSOR_H_ -#include #include "poemslist.h" #include "poemstree.h" #include "POEMSChain.h" -namespace POEMS { struct POEMSNode { - List links; - List taken; - int idNumber; - bool visited; - - ~POEMSNode(){ - for(int i = 0; i < taken.GetNumElements(); i++) - { - delete taken(i); - } - }; + List links; + List taken; + int idNumber; + bool visited; + + ~POEMSNode(){ + for(int i = 0; i < taken.GetNumElements(); i++) + { + delete taken(i); + } + }; }; class SystemProcessor{ private: - Tree nodes; - static void POEMSNodeDelete_cb(void *node) { - delete (POEMSNode *) node; - } - List headsOfSystems; - List > ringsInSystem; - POEMSNode * findSingleLink(TreeNode * aNode); - POEMSChain * AddNewChain(POEMSNode * currentNode); - bool setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNode); + Tree nodes; + static void POEMSNodeDelete_cb(void *node) { + delete (POEMSNode *) node; + } + List headsOfSystems; + List > ringsInSystem; + POEMSNode * findSingleLink(TreeNode * aNode); + POEMSChain * AddNewChain(POEMSNode * currentNode); + bool setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNode); public: - SystemProcessor(void); - - ~SystemProcessor(void) { - headsOfSystems.DeleteValues(); - for(int i = 0; i < ringsInSystem.GetNumElements(); i++) - { - for(int k = 0; k < ringsInSystem(i)->GetNumElements(); i++) - { - delete (*ringsInSystem(i))(k); - } - } - }; - void processArray(int** links, int numLinks); - List * getSystemData(); - int getNumberOfHeadChains(); + SystemProcessor(void); + + ~SystemProcessor(void) { + headsOfSystems.DeleteValues(); + for(int i = 0; i < ringsInSystem.GetNumElements(); i++) + { + for(int k = 0; k < ringsInSystem(i)->GetNumElements(); i++) + { + delete (*ringsInSystem(i))(k); + } + } + }; + void processArray(int** links, int numLinks); + List * getSystemData(); + int getNumberOfHeadChains(); }; SystemProcessor::SystemProcessor(void){ @@ -75,145 +73,145 @@ SystemProcessor::SystemProcessor(void){ void SystemProcessor::processArray(int** links, int numLinks) { - bool * false_var; //holds the value false; needed because a constant cannot be put into a list; the list requires a - //reference. - for(int i = 0; i < numLinks; i++) //go through all the links in the input array - { - if(!nodes.Find(links[i][0])) //if the first node in the pair is not found in the storage tree - { - POEMSNode * newNode = new POEMSNode; //make a new node -// forDeletion.Append(newNode); - newNode->idNumber = links[i][0]; //set its ID to the value - newNode->visited = false; //set it to be unvisited - nodes.Insert(links[i][0], links[i][0], (void *) newNode); //and add it to the tree storage structure - } - if(!nodes.Find(links[i][1])) //repeat process for the other half of each link - { - POEMSNode * newNode = new POEMSNode; -// forDeletion.Append(newNode); - newNode->idNumber = links[i][1]; - newNode->visited = false; - nodes.Insert(links[i][1], links[i][1], (void *) newNode); - } - POEMSNode * firstNode = (POEMSNode *)nodes.Find(links[i][0]); //now that we are sure both nodes exist, - POEMSNode * secondNode = (POEMSNode *)nodes.Find(links[i][1]); //we can get both of them out of the tree - firstNode->links.Append(secondNode); //and add the link from the first to the second... - false_var = new bool; - *false_var = false; //make a new false boolean to note that the link between these two - firstNode->taken.Append(false_var); //has not already been taken, and append it to the taken list - secondNode->links.Append(firstNode); //repeat process for link from second node to first - false_var = new bool; - *false_var = false; - secondNode->taken.Append(false_var); - } - - TreeNode * temp = nodes.GetRoot(); //get the root node of the node storage tree - POEMSNode * currentNode; - do - { - currentNode = findSingleLink(temp); //find the start of the next available chain - if(currentNode != NULL) - { - headsOfSystems.Append(AddNewChain(currentNode)); //and add it to the headsOfSystems list of chains - } - } - while(currentNode != NULL); //repeat this until all chains have been added + bool * false_var; //holds the value false; needed because a constant cannot be put into a list; the list requires a + //reference. + for(int i = 0; i < numLinks; i++) //go through all the links in the input array + { + if(!nodes.Find(links[i][0])) //if the first node in the pair is not found in the storage tree + { + POEMSNode * newNode = new POEMSNode; //make a new node +// forDeletion.Append(newNode); + newNode->idNumber = links[i][0]; //set its ID to the value + newNode->visited = false; //set it to be unvisited + nodes.Insert(links[i][0], links[i][0], (void *) newNode); //and add it to the tree storage structure + } + if(!nodes.Find(links[i][1])) //repeat process for the other half of each link + { + POEMSNode * newNode = new POEMSNode; +// forDeletion.Append(newNode); + newNode->idNumber = links[i][1]; + newNode->visited = false; + nodes.Insert(links[i][1], links[i][1], (void *) newNode); + } + POEMSNode * firstNode = (POEMSNode *)nodes.Find(links[i][0]); //now that we are sure both nodes exist, + POEMSNode * secondNode = (POEMSNode *)nodes.Find(links[i][1]); //we can get both of them out of the tree + firstNode->links.Append(secondNode); //and add the link from the first to the second... + false_var = new bool; + *false_var = false; //make a new false boolean to note that the link between these two + firstNode->taken.Append(false_var); //has not already been taken, and append it to the taken list + secondNode->links.Append(firstNode); //repeat process for link from second node to first + false_var = new bool; + *false_var = false; + secondNode->taken.Append(false_var); + } + + TreeNode * temp = nodes.GetRoot(); //get the root node of the node storage tree + POEMSNode * currentNode; + do + { + currentNode = findSingleLink(temp); //find the start of the next available chain + if(currentNode != NULL) + { + headsOfSystems.Append(AddNewChain(currentNode)); //and add it to the headsOfSystems list of chains + } + } + while(currentNode != NULL); //repeat this until all chains have been added } POEMSChain * SystemProcessor::AddNewChain(POEMSNode * currentNode){ - if(currentNode == NULL) //Termination condition; if the currentNode is null, then return null - { - return NULL; - } - int * tmp; - POEMSNode * nextNode = NULL; //nextNode stores the proposed next node to add to the chain. this will be checked to make sure no backtracking is occuring before being assigned as the current node. - POEMSChain * newChain = new POEMSChain; //make a new POEMSChain object. This will be the object returned + if(currentNode == NULL) //Termination condition; if the currentNode is null, then return null + { + return NULL; + } + int * tmp; + POEMSNode * nextNode = NULL; //nextNode stores the proposed next node to add to the chain. this will be checked to make sure no backtracking is occuring before being assigned as the current node. + POEMSChain * newChain = new POEMSChain; //make a new POEMSChain object. This will be the object returned - if(currentNode->links.GetNumElements() == 0) //if we have no links from this node, then the whole chain is only one node. Add this node to the chain and return it; mark node as visited for future reference - { - currentNode->visited = true; - tmp = new int; - *tmp = currentNode->idNumber; - newChain->listOfNodes.Append(tmp); - return newChain; - } - while(currentNode->links.GetNumElements() <= 2) //we go until we get to a node that branches, or both branches have already been taken both branches can already be taken if a loop with no spurs is found in the input data - { - currentNode->visited = true; - tmp = new int; - *tmp = currentNode->idNumber; - newChain->listOfNodes.Append(tmp); //append the current node to the chain & mark as visited - //std::cout << "Appending node " << currentNode->idNumber << " to chain" << std::endl; - nextNode = currentNode->links.GetHeadElement()->value; //the next node is the first or second value stored in the links array - //of the current node. We get the first value... - if(!setLinkVisited(currentNode, nextNode)) //...and see if it points back to where we came from. If it does... - { //either way, we set this link as visited - if(currentNode->links.GetNumElements() == 1) //if it does, then if that is the only link to this node, we're done with the chain, so append the chain to the list and return the newly created chain - { -// headsOfSystems.Append(newChain); - return newChain; - } - nextNode = currentNode->links.GetHeadElement()->next->value;//follow the other link if there is one, so we go down the chain - if(!setLinkVisited(currentNode, nextNode)) //mark link as followed, so we know not to backtrack - { - // headsOfSystems.Append(newChain); - return newChain; //This condition, where no branches have occurred but both links have already - //been taken can only occur in a loop with no spurs; add this loop to the - //system (currently added as a chain for consistency), and return. - } - } - currentNode = nextNode; //set the current node to be the next node in the chain - } - currentNode->visited = true; - tmp = new int; - *tmp = currentNode->idNumber; - newChain->listOfNodes.Append(tmp); //append the last node before branch (node shared jointly with branch chains) - //re-mark as visited, just to make sure - ListElement * tempNode = currentNode->links.GetHeadElement(); //go through all of the links, one at a time that branch - POEMSChain * tempChain = NULL; //temporary variable to hold data - while(tempNode != NULL) //when we have followed all links, stop - { - if(setLinkVisited(tempNode->value, currentNode)) //dont backtrack, or create closed loops - { - tempChain = AddNewChain(tempNode->value); //Add a new chain created out of the next node down that link - tempChain->parentChain = newChain; //set the parent to be this chain - newChain->childChains.Append(tempChain); //append the chain to this chain's list of child chains - } - tempNode = tempNode->next; //go to process the next chain - } - //headsOfSystems.Append(newChain); //append this chain to the system list - return newChain; + if(currentNode->links.GetNumElements() == 0) //if we have no links from this node, then the whole chain is only one node. Add this node to the chain and return it; mark node as visited for future reference + { + currentNode->visited = true; + tmp = new int; + *tmp = currentNode->idNumber; + newChain->listOfNodes.Append(tmp); + return newChain; + } + while(currentNode->links.GetNumElements() <= 2) //we go until we get to a node that branches, or both branches have already been taken both branches can already be taken if a loop with no spurs is found in the input data + { + currentNode->visited = true; + tmp = new int; + *tmp = currentNode->idNumber; + newChain->listOfNodes.Append(tmp); //append the current node to the chain & mark as visited + //cout << "Appending node " << currentNode->idNumber << " to chain" << endl; + nextNode = currentNode->links.GetHeadElement()->value; //the next node is the first or second value stored in the links array + //of the current node. We get the first value... + if(!setLinkVisited(currentNode, nextNode)) //...and see if it points back to where we came from. If it does... + { //either way, we set this link as visited + if(currentNode->links.GetNumElements() == 1) //if it does, then if that is the only link to this node, we're done with the chain, so append the chain to the list and return the newly created chain + { +// headsOfSystems.Append(newChain); + return newChain; + } + nextNode = currentNode->links.GetHeadElement()->next->value;//follow the other link if there is one, so we go down the chain + if(!setLinkVisited(currentNode, nextNode)) //mark link as followed, so we know not to backtrack + { + // headsOfSystems.Append(newChain); + return newChain; //This condition, where no branches have occurred but both links have already + //been taken can only occur in a loop with no spurs; add this loop to the + //system (currently added as a chain for consistency), and return. + } + } + currentNode = nextNode; //set the current node to be the next node in the chain + } + currentNode->visited = true; + tmp = new int; + *tmp = currentNode->idNumber; + newChain->listOfNodes.Append(tmp); //append the last node before branch (node shared jointly with branch chains) + //re-mark as visited, just to make sure + ListElement * tempNode = currentNode->links.GetHeadElement(); //go through all of the links, one at a time that branch + POEMSChain * tempChain = NULL; //temporary variable to hold data + while(tempNode != NULL) //when we have followed all links, stop + { + if(setLinkVisited(tempNode->value, currentNode)) //dont backtrack, or create closed loops + { + tempChain = AddNewChain(tempNode->value); //Add a new chain created out of the next node down that link + tempChain->parentChain = newChain; //set the parent to be this chain + newChain->childChains.Append(tempChain); //append the chain to this chain's list of child chains + } + tempNode = tempNode->next; //go to process the next chain + } + //headsOfSystems.Append(newChain); //append this chain to the system list + return newChain; } POEMSNode * SystemProcessor::findSingleLink(TreeNode * aNode) //This function takes the root of a search tree containing POEMSNodes and returns a POEMSNode corresponding to the start of a chain in the //system. It finds a node that has not been visited before, and only has one link; this node will be used as the head of the chain. { - if(aNode == NULL) - { - return NULL; - } - POEMSNode * returnVal = (POEMSNode *)aNode->GetAuxData(); //get the poemsnode data out of the treenode - POEMSNode * detectLoneLoops = NULL; //is used to handle a loop that has no protruding chains - if(returnVal->visited == false) - { - detectLoneLoops = returnVal; //if we find any node that has not been visited yet, save it - } - if(returnVal->links.GetNumElements() == 1 && returnVal->visited == false) //see if it has one element and hasnt been visited already - { - return returnVal; //return the node is it meets this criteria - } - returnVal = findSingleLink(aNode->Left()); //otherwise, check the left subtree - if(returnVal == NULL) //and if we find nothing... - { - returnVal = findSingleLink(aNode->Right()); //check the right subtree - } - if(returnVal == NULL) //if we could not find any chains - { - returnVal = detectLoneLoops; //see if we found any nodes at all that havent been processed - } - return returnVal; //return what we find (will be NULL if no new chains are - //found) + if(aNode == NULL) + { + return NULL; + } + POEMSNode * returnVal = (POEMSNode *)aNode->GetAuxData(); //get the poemsnode data out of the treenode + POEMSNode * detectLoneLoops = NULL; //is used to handle a loop that has no protruding chains + if(returnVal->visited == false) + { + detectLoneLoops = returnVal; //if we find any node that has not been visited yet, save it + } + if(returnVal->links.GetNumElements() == 1 && returnVal->visited == false) //see if it has one element and hasnt been visited already + { + return returnVal; //return the node is it meets this criteria + } + returnVal = findSingleLink(aNode->Left()); //otherwise, check the left subtree + if(returnVal == NULL) //and if we find nothing... + { + returnVal = findSingleLink(aNode->Right()); //check the right subtree + } + if(returnVal == NULL) //if we could not find any chains + { + returnVal = detectLoneLoops; //see if we found any nodes at all that havent been processed + } + return returnVal; //return what we find (will be NULL if no new chains are + //found) } bool SystemProcessor::setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNode) @@ -225,66 +223,65 @@ bool SystemProcessor::setLinkVisited(POEMSNode * firstNode, POEMSNode * secondNo //value for that particular link. Because each link is represented twice, (once at each node in the link), both of the boolean values need //to be set in the event that the link has to be set as visited. { - //std::cout << "Checking link between nodes " << firstNode->idNumber << " and " << secondNode->idNumber << "... "; - ListElement * tmp = firstNode->links.GetHeadElement(); //get the head element of the list of pointers for node 1 - ListElement * tmp2 = firstNode->taken.GetHeadElement(); //get the head element of the list of bool isVisited flags for node 1 - while(tmp->value != NULL || tmp2->value != NULL) //go through untill we reach the end of the lists - { - if(tmp->value == secondNode) //if we find the link to the other node - { - if(*(tmp2->value) == true) //if the link has already been visited - { - //std::cout << "visited already" << std::endl; - return false; //return false to indicate that the link has been visited before this attempt - } - else //otherwise, visit it - { - *tmp2->value = true; - } - break; - } - tmp = tmp->next; //go check next link - tmp2 = tmp2->next; - } + //cout << "Checking link between nodes " << firstNode->idNumber << " and " << secondNode->idNumber << "... "; + ListElement * tmp = firstNode->links.GetHeadElement(); //get the head element of the list of pointers for node 1 + ListElement * tmp2 = firstNode->taken.GetHeadElement(); //get the head element of the list of bool isVisited flags for node 1 + while(tmp->value != NULL || tmp2->value != NULL) //go through untill we reach the end of the lists + { + if(tmp->value == secondNode) //if we find the link to the other node + { + if(*(tmp2->value) == true) //if the link has already been visited + { + //cout << "visited already" << endl; + return false; //return false to indicate that the link has been visited before this attempt + } + else //otherwise, visit it + { + *tmp2->value = true; + } + break; + } + tmp = tmp->next; //go check next link + tmp2 = tmp2->next; + } - tmp = secondNode->links.GetHeadElement(); //now, if the link was unvisited, we need to go set the other node's list such that - //it also knows this link is being visited - tmp2 = secondNode->taken.GetHeadElement(); - while(tmp->value != NULL || tmp2->value != NULL) //go through the list - { - if(tmp->value == firstNode) //if we find the link - { - if(*(tmp2->value) == true) //and it has already been visited, then signal an error; this shouldnt ever happen - { - std::cout << "Error in parsing structure! Should never reach this condition! \n" << - "Record of visited links out of synch between two adjacent nodes.\n"; - return false; - } - else - { - *tmp2->value = true; //set the appropriate value to true to indicate this link has been visited - } - break; - } - tmp = tmp->next; - tmp2 = tmp2->next; - } - //std::cout << "not visited" << std::endl; - return true; //return true to indicate that this is the first time the link has been visited + tmp = secondNode->links.GetHeadElement(); //now, if the link was unvisited, we need to go set the other node's list such that + //it also knows this link is being visited + tmp2 = secondNode->taken.GetHeadElement(); + while(tmp->value != NULL || tmp2->value != NULL) //go through the list + { + if(tmp->value == firstNode) //if we find the link + { + if(*(tmp2->value) == true) //and it has already been visited, then signal an error; this shouldnt ever happen + { + cout << "Error in parsing structure! Should never reach this condition! \n" << + "Record of visited links out of synch between two adjacent nodes.\n"; + return false; + } + else + { + *tmp2->value = true; //set the appropriate value to true to indicate this link has been visited + } + break; + } + tmp = tmp->next; + tmp2 = tmp2->next; + } + //cout << "not visited" << endl; + return true; //return true to indicate that this is the first time the link has been visited } -List * SystemProcessor::getSystemData(void) //Gets the list of POEMSChains that comprise the system. Might eventually only - //return chains linked to the reference plane, but currently returns every chain - //in the system. +List * SystemProcessor::getSystemData(void) //Gets the list of POEMSChains that comprise the system. Might eventually only + //return chains linked to the reference plane, but currently returns every chain + //in the system. { - return &headsOfSystems; + return &headsOfSystems; } int SystemProcessor::getNumberOfHeadChains(void) //This function isnt implemented yet, and might be taken out entirely; this was a holdover - //from when I intended to return an array of chain pointers, rather than a list of chains - //It will probably be deleted once I finish figuring out exactly what needs to be returned + //from when I intended to return an array of chain pointers, rather than a list of chains + //It will probably be deleted once I finish figuring out exactly what needs to be returned { - return 0; -} + return 0; } #endif diff --git a/lib/poems/body.cpp b/lib/poems/body.cpp index 6825941b93..4ef05dd1e6 100644 --- a/lib/poems/body.cpp +++ b/lib/poems/body.cpp @@ -14,20 +14,11 @@ * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - -#include - -#include "body.h" -#include "inertialframe.h" -#include "mat3x3.h" -#include "particle.h" -#include "poemslist.h" + +#include "bodies.h" #include "point.h" -#include "rigidbody.h" -#include "vect3.h" using namespace std; -using namespace POEMS; Body::Body() { @@ -131,7 +122,7 @@ void Body::AddPoint(Point* point){ // global body functions // -Body* POEMS::NewBody(int type){ +Body* NewBody(int type){ switch( BodyType(type) ) { case INERTIALFRAME : // The inertial reference frame diff --git a/lib/poems/body.h b/lib/poems/body.h index e2394b40aa..f8e0f6a5a3 100644 --- a/lib/poems/body.h +++ b/lib/poems/body.h @@ -19,29 +19,30 @@ #ifndef BODY_H #define BODY_H -#include #include "poemslist.h" +#include #include "poemsobject.h" -#include "mat3x3.h" -#include "vect3.h" -namespace POEMS { +#include "matrices.h" + + + // emumerated type enum BodyType { INERTIALFRAME = 0, PARTICLE = 1, RIGIDBODY = 2 }; - + class Point; class Joint; - +class CompBody; class Body : public POEMSObject { public: double mass; Mat3x3 inertia; - + Vect3 r; Vect3 v; Vect3 v_k; @@ -53,13 +54,13 @@ public: Vect3 alpha; Vect3 alpha_t; double KE; - + List joints; List points; Body(); - + bool ReadIn(std::istream& in); void WriteOut(std::ostream& out); bool ReadInPoints(std::istream& in); @@ -67,7 +68,7 @@ public: Point* GetPoint(int p); void AddJoint(Joint* joint); void AddPoint(Point* point); - + virtual bool ReadInBodyData(std::istream& in) = 0; virtual void WriteOutBodyData(std::ostream& out) = 0; virtual ~Body(); @@ -76,5 +77,5 @@ public: // global body functions Body* NewBody(int type); -} + #endif diff --git a/lib/poems/body23joint.cpp b/lib/poems/body23joint.cpp index e3ef32b2a9..8cd0a95bca 100644 --- a/lib/poems/body23joint.cpp +++ b/lib/poems/body23joint.cpp @@ -14,21 +14,18 @@ * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ + -#include #include "body23joint.h" -#include "body.h" -#include "colmatrix.h" -#include "eulerparameters.h" -#include "fastmatrixops.h" -#include "mat3x3.h" -#include "matrixfun.h" #include "point.h" -#include "vect3.h" -#include "virtualmatrix.h" +#include "matrixfun.h" +#include "body.h" +#include "fastmatrixops.h" +#include "norm.h" +#include "eulerparameters.h" +#include "matrices.h" +#include -using namespace std; -using namespace POEMS; Body23Joint::Body23Joint(){ DimQandU(4,2); diff --git a/lib/poems/body23joint.h b/lib/poems/body23joint.h index 43a727c815..60253ac8a4 100644 --- a/lib/poems/body23joint.h +++ b/lib/poems/body23joint.h @@ -18,11 +18,12 @@ #ifndef BODY23JOINT_H #define BODY23JOINT_H -#include #include "joint.h" -#include "matrix.h" +#include "vect3.h" +#include "mat3x3.h" + + -namespace POEMS { class Body23Joint : public Joint { Matrix const_sP; public: @@ -39,5 +40,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; -} + #endif diff --git a/lib/poems/colmatmap.cpp b/lib/poems/colmatmap.cpp index 34a95feb03..1954e7ff15 100644 --- a/lib/poems/colmatmap.cpp +++ b/lib/poems/colmatmap.cpp @@ -21,8 +21,6 @@ #include using namespace std; -using namespace POEMS; - ColMatMap::ColMatMap(){ numrows = 0; diff --git a/lib/poems/colmatmap.h b/lib/poems/colmatmap.h index 5a12cf487f..3a6267a247 100644 --- a/lib/poems/colmatmap.h +++ b/lib/poems/colmatmap.h @@ -19,12 +19,8 @@ #ifndef COLMATMAP_H #define COLMATMAP_H -#include - #include "virtualcolmatrix.h" -#include "virtualmatrix.h" -namespace POEMS { class ColMatrix; class ColMatMap : public VirtualColMatrix { @@ -65,5 +61,5 @@ public: friend void FastCKRK5(ColMatMap& X, ColMatrix& Xi, ColMatrix* f, double* c, double dt); friend void FastFRK5(ColMatMap& X, ColMatrix& Xi, ColMatrix* f, double* c, double dt); }; -} + #endif diff --git a/lib/poems/colmatrix.cpp b/lib/poems/colmatrix.cpp index 0cc666645a..dc6f49be2b 100644 --- a/lib/poems/colmatrix.cpp +++ b/lib/poems/colmatrix.cpp @@ -16,13 +16,12 @@ *_________________________________________________________________________*/ #include "colmatrix.h" - +#include "rowmatrix.h" #include +#include #include using namespace std; -using namespace POEMS; - ColMatrix::ColMatrix(){ numrows = 0; diff --git a/lib/poems/colmatrix.h b/lib/poems/colmatrix.h index bcfa86843a..11fd85a928 100644 --- a/lib/poems/colmatrix.h +++ b/lib/poems/colmatrix.h @@ -19,18 +19,15 @@ #ifndef COLMATRIX_H #define COLMATRIX_H -#include #include "virtualcolmatrix.h" -#include "virtualmatrix.h" +#include "colmatmap.h" -namespace POEMS { class Matrix; class Vect6; class Mat3x3; class Vect3; class ColMatrix : public VirtualColMatrix { -protected: double* elements; public: ColMatrix(); @@ -60,28 +57,28 @@ public: ColMatrix& operator=(const VirtualMatrix& A); // overloaded = ColMatrix& operator*=(double b); - void Abs(); - void BasicMax(double& value, int& index); - void BasicMin(double& value, int& index); + void Abs(); + void BasicMax(double& value, int& index); + void BasicMin(double& value, int& index); // fast matrix operations - friend void FastQuaternions(ColMatrix& q, Mat3x3& C); - friend void FastInvQuaternions(Mat3x3& C, ColMatrix& q); - friend void FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot); - friend void FastTMult(Matrix& A, Vect6& B, ColMatrix& C); - friend void FastMult(Matrix& A, ColMatrix& B, Vect6& C); - friend void FastAssign(ColMatrix& A, ColMatrix& C); + friend void FastQuaternions(ColMatrix& q, Mat3x3& C); + friend void FastInvQuaternions(Mat3x3& C, ColMatrix& q); + friend void FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot); + friend void FastTMult(Matrix& A, Vect6& B, ColMatrix& C); + friend void FastMult(Matrix& A, ColMatrix& B, Vect6& C); + friend void FastAssign(ColMatrix& A, ColMatrix& C); - friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); - friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); - friend void FastAssign(ColMatrix&A, Vect3& C); - - friend void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); - friend void EP_Transformation(ColMatrix& q, Mat3x3& C); - friend void EP_FromTransformation(ColMatrix& q, Mat3x3& C); - friend void EP_Normalize(ColMatrix& q); - friend void EPdotdot_udot(ColMatrix& Audot, ColMatrix& Aqdot, ColMatrix& Aq,ColMatrix& Aqddot); - friend void qdot_to_u(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); + friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); + friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); + friend void FastAssign(ColMatrix&A, Vect3& C); + + friend void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); + friend void EP_Transformation(ColMatrix& q, Mat3x3& C); + friend void EP_FromTransformation(ColMatrix& q, Mat3x3& C); + friend void EP_Normalize(ColMatrix& q); + friend void EPdotdot_udot(ColMatrix& Audot, ColMatrix& Aqdot, ColMatrix& Aq,ColMatrix& Aqddot); + friend void qdot_to_u(ColMatrix& q, ColMatrix& u, ColMatrix& qdot); }; -} + #endif diff --git a/lib/poems/defines.h b/lib/poems/defines.h index 877bc0fa0b..455bc298d5 100644 --- a/lib/poems/defines.h +++ b/lib/poems/defines.h @@ -15,14 +15,13 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ -#ifndef POEMS_DEFINES_H -#define POEMS_DEFINES_H +#ifndef _DEFINES_H_ +#define _DEFINES_H_ -namespace POEMS { enum SolverType { ONSOLVER = 0, PARTICLESOLVER = 1 }; -} + #endif diff --git a/lib/poems/eulerparameters.cpp b/lib/poems/eulerparameters.cpp index bb8d676796..032bc7da82 100644 --- a/lib/poems/eulerparameters.cpp +++ b/lib/poems/eulerparameters.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: eulerparameters.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,22 +11,16 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #include "eulerparameters.h" - #include -#include "colmatrix.h" -#include "mat3x3.h" - using namespace std; -using namespace POEMS; - -void POEMS::EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot){ +void EP_Derivatives(ColMatrix& q, ColMatrix& u, ColMatrix& qdot){ EP_Normalize(q); int num=u.GetNumRows(); if (3 +#include "fastmatrixops.h" #include -#include "fastmatrixops.h" -#include "colmatmap.h" -#include "colmatrix.h" -#include "mat3x3.h" -#include "mat4x4.h" -#include "mat6x6.h" -#include "matrix.h" -#include "vect3.h" -#include "vect4.h" -#include "vect6.h" - using namespace std; -using namespace POEMS; - // // Cross Product (friend of Vect3) // -void POEMS::FastCross(Vect3& a, Vect3& b, Vect3& c){ +void FastCross(Vect3& a, Vect3& b, Vect3& c){ c.elements[0] = a.elements[1]*b.elements[2] - a.elements[2]*b.elements[1]; c.elements[1] = a.elements[2]*b.elements[0] - a.elements[0]*b.elements[2]; c.elements[2] = a.elements[0]*b.elements[1] - a.elements[1]*b.elements[0]; @@ -46,7 +35,7 @@ void POEMS::FastCross(Vect3& a, Vect3& b, Vect3& c){ // Simple Rotation (friend of Vect3 and Mat3x3) // -void POEMS::FastSimpleRotation(Vect3& v, double q, Mat3x3& C){ +void FastSimpleRotation(Vect3& v, double q, Mat3x3& C){ // intermediate quantities double cq = cos(q); double sq = sin(q); @@ -71,7 +60,7 @@ void POEMS::FastSimpleRotation(Vect3& v, double q, Mat3x3& C){ // Quaternion Functions // -void POEMS::FastQuaternions(ColMatrix& q, Mat3x3& C){ +void FastQuaternions(ColMatrix& q, Mat3x3& C){ double* e = q.elements; // normalize the quaternions @@ -96,7 +85,7 @@ void POEMS::FastQuaternions(ColMatrix& q, Mat3x3& C){ C.elements[2][1] = 2 * (e[2]*e[3] + e[0]*e[1]); } -void POEMS::FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot){ +void FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot){ double* w = omega.elements; double* e = q.elements; @@ -106,7 +95,7 @@ void POEMS::FastQuaternionDerivatives(ColMatrix& q, ColMatrix& omega, ColMatrix& qdot.elements[3] = 0.5 * ( w[2]*e[0] + w[1]*e[1] - w[0]*e[2]); } -void POEMS::FastInvQuaternions(Mat3x3& C, ColMatrix& q){ +void FastInvQuaternions(Mat3x3& C, ColMatrix& q){ } // @@ -123,7 +112,7 @@ void POEMS::FastInvQuaternions(Mat3x3& C, ColMatrix& q){ // // friend of Matrix -void POEMS::FastLDLT(Matrix& A, Matrix& C){ // C is the LD of the LDL^T decomposition of A (SPD) +void FastLDLT(Matrix& A, Matrix& C){ // C is the LD of the LDL^T decomposition of A (SPD) double Lv; int n = A.numrows; @@ -145,7 +134,7 @@ void POEMS::FastLDLT(Matrix& A, Matrix& C){ // C is the LD of the LDL^T decompos // friend of Mat6x6 -void POEMS::FastLDLT(Mat6x6& A, Mat6x6& C){ // C is the LD of the LDL^T decomposition of A (SPD) +void FastLDLT(Mat6x6& A, Mat6x6& C){ // C is the LD of the LDL^T decomposition of A (SPD) double v[6]; double Lv; @@ -167,7 +156,7 @@ void POEMS::FastLDLT(Mat6x6& A, Mat6x6& C){ // C is the LD of the LDL^T decompos } // friend of Matrix -void POEMS::FastLDLTSubs(Matrix& LD, Matrix& B, Matrix& C){ +void FastLDLTSubs(Matrix& LD, Matrix& B, Matrix& C){ int n = B.numrows; int c = B.numcols; double temp; @@ -192,7 +181,7 @@ void POEMS::FastLDLTSubs(Matrix& LD, Matrix& B, Matrix& C){ } // friend of Matrix -void POEMS::FastLDLTSubsLH(Matrix& B, Matrix& LD, Matrix& C){ +void FastLDLTSubsLH(Matrix& B, Matrix& LD, Matrix& C){ int n = B.numcols; int c = B.numrows; double temp; @@ -217,7 +206,7 @@ void POEMS::FastLDLTSubsLH(Matrix& B, Matrix& LD, Matrix& C){ } // friend of Mat6x6 -void POEMS::FastLDLTSubs(Mat6x6& LD, Mat6x6& B, Mat6x6& C){ +void FastLDLTSubs(Mat6x6& LD, Mat6x6& B, Mat6x6& C){ double temp; for(int k=0;k<6;k++){ @@ -240,7 +229,7 @@ void POEMS::FastLDLTSubs(Mat6x6& LD, Mat6x6& B, Mat6x6& C){ } // friend of Mat6x6 & Vect6 -void POEMS::FastLDLTSubs(Mat6x6& LD, Vect6& B, Vect6& C){ +void FastLDLTSubs(Mat6x6& LD, Vect6& B, Vect6& C){ double temp; for(int i=0;i<6;i++){ @@ -261,7 +250,7 @@ void POEMS::FastLDLTSubs(Mat6x6& LD, Vect6& B, Vect6& C){ } // friend of Matrix -void POEMS::FastLU(Matrix& A, Matrix& LU, int *indx){ // LU is the LU decomposition of A +void FastLU(Matrix& A, Matrix& LU, int *indx){ // LU is the LU decomposition of A int i,imax=0,j,k; int n = A.numrows; double big, dum, sum, temp; @@ -311,7 +300,7 @@ void POEMS::FastLU(Matrix& A, Matrix& LU, int *indx){ // LU is the LU decomposit } // friend of Mat3x3 -void POEMS::FastLU(Mat3x3& A, Mat3x3& LU, int *indx){ // LU is the LU decomposition of A +void FastLU(Mat3x3& A, Mat3x3& LU, int *indx){ // LU is the LU decomposition of A int i,imax=0,j,k; double big, dum, sum, temp; double vv[10000]; @@ -359,7 +348,7 @@ void POEMS::FastLU(Mat3x3& A, Mat3x3& LU, int *indx){ // LU is the LU decomposit } // friend of Mat4x4 -void POEMS::FastLU(Mat4x4& A, Mat4x4& LU, int *indx){ // LU is the LU decomposition of A +void FastLU(Mat4x4& A, Mat4x4& LU, int *indx){ // LU is the LU decomposition of A int i,imax=0,j,k; double big, dum, sum, temp; double vv[10000]; @@ -407,7 +396,7 @@ void POEMS::FastLU(Mat4x4& A, Mat4x4& LU, int *indx){ // LU is the LU decomposit } // friend of Mat6x6 -void POEMS::FastLU(Mat6x6& A, Mat6x6& LU, int *indx){ // LU is the LU decomposition of A +void FastLU(Mat6x6& A, Mat6x6& LU, int *indx){ // LU is the LU decomposition of A int i,imax=0,j,k; double big, dum, sum, temp; double vv[10000]; @@ -455,7 +444,7 @@ void POEMS::FastLU(Mat6x6& A, Mat6x6& LU, int *indx){ // LU is the LU decomposit } // friend of Matrix -void POEMS::FastLUSubs(Matrix& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution +void FastLUSubs(Matrix& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution int i,ip,j,k; int n = B.numrows; int c = B.numcols; @@ -479,7 +468,7 @@ void POEMS::FastLUSubs(Matrix& LU, Matrix& B, Matrix& C, int *indx){ // Appropri } // friend of Matrix and Mat3x3 -void POEMS::FastLUSubs(Mat3x3& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution +void FastLUSubs(Mat3x3& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution int i,ip,j,k; int n = B.numrows; int c = B.numcols; @@ -503,7 +492,7 @@ void POEMS::FastLUSubs(Mat3x3& LU, Matrix& B, Matrix& C, int *indx){ // Appropri } // friend of Matrix and Mat4x4 -void POEMS::FastLUSubs(Mat4x4& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution +void FastLUSubs(Mat4x4& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution int i,ip,j,k; int n = B.numrows; int c = B.numcols; @@ -527,7 +516,7 @@ void POEMS::FastLUSubs(Mat4x4& LU, Matrix& B, Matrix& C, int *indx){ // Appropri } // friend of Matrix and Mat6x6 -void POEMS::FastLUSubs(Mat6x6& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution +void FastLUSubs(Mat6x6& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution int i,ip,j,k; int n = B.numrows; int c = B.numcols; @@ -553,7 +542,7 @@ void POEMS::FastLUSubs(Mat6x6& LU, Matrix& B, Matrix& C, int *indx){ // Appropri // The following LUSubsLH routine is incomplete at the moment. // friend of Matrix -void POEMS::FastLUSubsLH(Matrix& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution +void FastLUSubsLH(Matrix& LU, Matrix& B, Matrix& C, int *indx){ // Appropriate Forward and Back Substitution int i,ip,j,k; int n = B.numcols; int c = B.numrows; @@ -584,13 +573,13 @@ void POEMS::FastLUSubsLH(Matrix& LU, Matrix& B, Matrix& C, int *indx){ // Approp // Triple sum // -void POEMS::FastTripleSum(Vect3& a, Vect3& b, Vect3& c, Vect3& d){ // d = a+b+c +void FastTripleSum(Vect3& a, Vect3& b, Vect3& c, Vect3& d){ // d = a+b+c d.elements[0] = a.elements[0]+b.elements[0]+c.elements[0]; d.elements[1] = a.elements[1]+b.elements[1]+c.elements[1]; d.elements[2] = a.elements[2]+b.elements[2]+c.elements[2]; } -void POEMS::FastTripleSumPPM(Vect3& a, Vect3& b, Vect3& c, Vect3& d){ // d = a+b-c +void FastTripleSumPPM(Vect3& a, Vect3& b, Vect3& c, Vect3& d){ // d = a+b-c d.elements[0] = a.elements[0]+b.elements[0]-c.elements[0]; d.elements[1] = a.elements[1]+b.elements[1]-c.elements[1]; d.elements[2] = a.elements[2]+b.elements[2]-c.elements[2]; @@ -601,7 +590,7 @@ void POEMS::FastTripleSumPPM(Vect3& a, Vect3& b, Vect3& c, Vect3& d){ // d = a+b // // friend of matrix -void POEMS::FastMult(Matrix& A, Matrix& B, Matrix& C){ // C = A*B +void FastMult(Matrix& A, Matrix& B, Matrix& C){ // C = A*B // assumes dimensions are already correct! int r = A.numrows; int ca = A.numcols; @@ -617,7 +606,7 @@ void POEMS::FastMult(Matrix& A, Matrix& B, Matrix& C){ // C = A*B } // friend of matrix -void POEMS::FastTMult(Matrix& A, Matrix& B, Matrix& C){ // C = A*B +void FastTMult(Matrix& A, Matrix& B, Matrix& C){ // C = A*B // assumes dimensions are already correct! int r = A.numcols; int ca = A.numrows; @@ -633,14 +622,14 @@ void POEMS::FastTMult(Matrix& A, Matrix& B, Matrix& C){ // C = A*B } // friend of Mat3x3 & Vect3 -void POEMS::FastMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = A*B +void FastMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = A*B C.elements[0] = A.elements[0][0]*B.elements[0] + A.elements[0][1]*B.elements[1] + A.elements[0][2]*B.elements[2]; C.elements[1] = A.elements[1][0]*B.elements[0] + A.elements[1][1]*B.elements[1] + A.elements[1][2]*B.elements[2]; C.elements[2] = A.elements[2][0]*B.elements[0] + A.elements[2][1]*B.elements[1] + A.elements[2][2]*B.elements[2]; } // friend of Mat3x3, ColMatrix, & Vect3 -void POEMS::FastMult(Mat3x3& A, ColMatrix& B, Vect3& C){ // C = A*B +void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C){ // C = A*B C.elements[0] = A.elements[0][0]*B.elements[0] + A.elements[0][1]*B.elements[1] + A.elements[0][2]*B.elements[2]; C.elements[1] = A.elements[1][0]*B.elements[0] + A.elements[1][1]*B.elements[1] + A.elements[1][2]*B.elements[2]; C.elements[2] = A.elements[2][0]*B.elements[0] + A.elements[2][1]*B.elements[1] + A.elements[2][2]*B.elements[2]; @@ -648,42 +637,42 @@ void POEMS::FastMult(Mat3x3& A, ColMatrix& B, Vect3& C){ // C = A*B // friend of Mat3x3, ColMatrix, & Vect3 -void POEMS::FastMult(Mat3x3& A, Vect3& B, ColMatrix& C){ // C = A*B +void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C){ // C = A*B C.elements[0] = A.elements[0][0]*B.elements[0] + A.elements[0][1]*B.elements[1] + A.elements[0][2]*B.elements[2]; C.elements[1] = A.elements[1][0]*B.elements[0] + A.elements[1][1]*B.elements[1] + A.elements[1][2]*B.elements[2]; C.elements[2] = A.elements[2][0]*B.elements[0] + A.elements[2][1]*B.elements[1] + A.elements[2][2]*B.elements[2]; } // friend of Mat3x3 & Vect3 -void POEMS::FastTMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = A^T*B +void FastTMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = A^T*B C.elements[0] = A.elements[0][0]*B.elements[0] + A.elements[1][0]*B.elements[1] + A.elements[2][0]*B.elements[2]; C.elements[1] = A.elements[0][1]*B.elements[0] + A.elements[1][1]*B.elements[1] + A.elements[2][1]*B.elements[2]; C.elements[2] = A.elements[0][2]*B.elements[0] + A.elements[1][2]*B.elements[1] + A.elements[2][2]*B.elements[2]; } // friend of Mat3x3 & Vect3 -void POEMS::FastNegMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = -A*B +void FastNegMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = -A*B C.elements[0] = -A.elements[0][0]*B.elements[0] - A.elements[0][1]*B.elements[1] - A.elements[0][2]*B.elements[2]; C.elements[1] = -A.elements[1][0]*B.elements[0] - A.elements[1][1]*B.elements[1] - A.elements[1][2]*B.elements[2]; C.elements[2] = -A.elements[2][0]*B.elements[0] - A.elements[2][1]*B.elements[1] - A.elements[2][2]*B.elements[2]; } // friend of Mat3x3 & Vect3 -void POEMS::FastNegTMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = -A^T*B +void FastNegTMult(Mat3x3& A, Vect3& B, Vect3& C){ // C = -A^T*B C.elements[0] = -A.elements[0][0]*B.elements[0] - A.elements[1][0]*B.elements[1] - A.elements[2][0]*B.elements[2]; C.elements[1] = -A.elements[0][1]*B.elements[0] - A.elements[1][1]*B.elements[1] - A.elements[2][1]*B.elements[2]; C.elements[2] = -A.elements[0][2]*B.elements[0] - A.elements[1][2]*B.elements[1] - A.elements[2][2]*B.elements[2]; } // friend of Vect3 -void POEMS::FastMult(double a, Vect3& B, Vect3& C){ // C = a*B +void FastMult(double a, Vect3& B, Vect3& C){ // C = a*B C.elements[0] = a*B.elements[0]; C.elements[1] = a*B.elements[1]; C.elements[2] = a*B.elements[2]; } // friend of Mat4x4 & Vect4 -void POEMS::FastMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = A*B +void FastMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = A*B C.elements[0] = A.elements[0][0]*B.elements[0] + A.elements[0][1]*B.elements[1] + A.elements[0][2]*B.elements[2] + A.elements[0][3]*B.elements[3]; C.elements[1] = A.elements[1][0]*B.elements[0] + A.elements[1][1]*B.elements[1] + A.elements[1][2]*B.elements[2] + A.elements[1][3]*B.elements[3]; C.elements[2] = A.elements[2][0]*B.elements[0] + A.elements[2][1]*B.elements[1] + A.elements[2][2]*B.elements[2] + A.elements[2][3]*B.elements[3]; @@ -691,7 +680,7 @@ void POEMS::FastMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = A*B } // friend of Mat4x4 & Vect4 -void POEMS::FastTMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = A^T*B +void FastTMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = A^T*B C.elements[0] = A.elements[0][0]*B.elements[0] + A.elements[1][0]*B.elements[1] + A.elements[2][0]*B.elements[2] + A.elements[3][0]*B.elements[3]; C.elements[1] = A.elements[0][1]*B.elements[0] + A.elements[1][1]*B.elements[1] + A.elements[2][1]*B.elements[2] + A.elements[3][1]*B.elements[3]; C.elements[2] = A.elements[0][2]*B.elements[0] + A.elements[1][2]*B.elements[1] + A.elements[2][2]*B.elements[2] + A.elements[3][2]*B.elements[3]; @@ -699,7 +688,7 @@ void POEMS::FastTMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = A^T*B } // friend of Mat4x4 & Vect4 -void POEMS::FastNegMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = -A*B +void FastNegMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = -A*B C.elements[0] = -A.elements[0][0]*B.elements[0] - A.elements[0][1]*B.elements[1] - A.elements[0][2]*B.elements[2] - A.elements[0][3]*B.elements[3]; C.elements[1] = -A.elements[1][0]*B.elements[0] - A.elements[1][1]*B.elements[1] - A.elements[1][2]*B.elements[2] - A.elements[1][3]*B.elements[3]; C.elements[2] = -A.elements[2][0]*B.elements[0] - A.elements[2][1]*B.elements[1] - A.elements[2][2]*B.elements[2] - A.elements[2][3]*B.elements[3]; @@ -707,7 +696,7 @@ void POEMS::FastNegMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = -A*B } // friend of Mat4x4 & Vect4 -void POEMS::FastNegTMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = -A^T*B +void FastNegTMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = -A^T*B C.elements[0] = -A.elements[0][0]*B.elements[0] - A.elements[1][0]*B.elements[1] - A.elements[2][0]*B.elements[2] - A.elements[3][0]*B.elements[3]; C.elements[1] = -A.elements[0][1]*B.elements[0] - A.elements[1][1]*B.elements[1] - A.elements[2][1]*B.elements[2] - A.elements[3][1]*B.elements[3]; C.elements[2] = -A.elements[0][2]*B.elements[0] - A.elements[1][2]*B.elements[1] - A.elements[2][2]*B.elements[2] - A.elements[3][2]*B.elements[3]; @@ -715,7 +704,7 @@ void POEMS::FastNegTMult(Mat4x4& A, Vect4& B, Vect4& C){ // C = -A^T*B } // friend of Vect4 -void POEMS::FastMult(double a, Vect4& B, Vect4& C){ // C = a*B +void FastMult(double a, Vect4& B, Vect4& C){ // C = a*B C.elements[0] = a*B.elements[0]; C.elements[1] = a*B.elements[1]; C.elements[2] = a*B.elements[2]; @@ -723,7 +712,7 @@ void POEMS::FastMult(double a, Vect4& B, Vect4& C){ // C = a*B } // friend of Matrix & Mat6x6 -void POEMS::FastMultT(Matrix& A, Matrix& B, Mat6x6& C){ // C = A*B^T +void FastMultT(Matrix& A, Matrix& B, Mat6x6& C){ // C = A*B^T int i,j,k,n; n = A.numcols; @@ -736,7 +725,7 @@ void POEMS::FastMultT(Matrix& A, Matrix& B, Mat6x6& C){ // C = A*B^T } // friend Matrix, Vect6, ColMatrix -void POEMS::FastMult(Matrix& A, ColMatrix& B, Vect6& C){ +void FastMult(Matrix& A, ColMatrix& B, Vect6& C){ int ca = A.numcols; int i,k; @@ -748,7 +737,7 @@ void POEMS::FastMult(Matrix& A, ColMatrix& B, Vect6& C){ } // friend of Matrix & Mat6x6 -void POEMS::FastMult(Mat6x6& A, Matrix& B, Matrix& C){ // C = A*B +void FastMult(Mat6x6& A, Matrix& B, Matrix& C){ // C = A*B // assumes dimensions are already correct! int cb = B.numcols; @@ -762,7 +751,7 @@ void POEMS::FastMult(Mat6x6& A, Matrix& B, Matrix& C){ // C = A*B } // friend Matrix, Vect6, ColMatrix -void POEMS::FastTMult(Matrix& A, Vect6& B, ColMatrix& C){ // C = A^T*B +void FastTMult(Matrix& A, Vect6& B, ColMatrix& C){ // C = A^T*B int n = C.numrows; int i,k; for(i=0;i #include -#include "virtualmatrix.h" - using namespace std; -using namespace POEMS; - FixedPoint::FixedPoint(){ } diff --git a/lib/poems/fixedpoint.h b/lib/poems/fixedpoint.h index 5da1d6d69c..b5ecb23906 100644 --- a/lib/poems/fixedpoint.h +++ b/lib/poems/fixedpoint.h @@ -19,12 +19,9 @@ #ifndef FIXEDPOINT_H #define FIXEDPOINT_H -#include - #include "point.h" #include "vect3.h" -namespace POEMS { class FixedPoint : public Point { public: FixedPoint(); @@ -36,5 +33,5 @@ public: bool ReadInPointData(std::istream& in); void WriteOutPointData(std::ostream& out); }; -} + #endif diff --git a/lib/poems/freebodyjoint.cpp b/lib/poems/freebodyjoint.cpp index 0022ebd9ff..d00f0bdb98 100644 --- a/lib/poems/freebodyjoint.cpp +++ b/lib/poems/freebodyjoint.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: freebodyjoint.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,29 +11,23 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #include "freebodyjoint.h" - -#include - +#include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" +#include "norm.h" #include "eulerparameters.h" -#include "colmatrix.h" -#include "mat3x3.h" -#include "mat6x6.h" -#include "vect3.h" -#include "virtualmatrix.h" - -using namespace POEMS; - +#include "matrices.h" +#include + FreeBodyJoint::FreeBodyJoint(){ - DimQandU(7,6); + DimQandU(7,6); } FreeBodyJoint::~FreeBodyJoint(){ @@ -51,112 +45,112 @@ void FreeBodyJoint::WriteOutJointData(std::ostream& out){ } void FreeBodyJoint::ComputeLocalTransform(){ - Mat3x3 ko_C_k; - EP_Transformation(q, ko_C_k); - FastMult(pk_C_ko,ko_C_k,pk_C_k); + Mat3x3 ko_C_k; + EP_Transformation(q, ko_C_k); + FastMult(pk_C_ko,ko_C_k,pk_C_k); } Matrix FreeBodyJoint::GetForward_sP(){ Mat6x6 sP; - //sP.Identity(); - - sP.Zeros(); + //sP.Identity(); + + sP.Zeros(); Mat3x3 temp0=T(pk_C_k); for(int i=1;i<4;i++){ sP(i,i)=1.0; for(int j=1;j<4;j++){ sP(3+i,3+j)=temp0(i,j); } - } - return sP; + } + return sP; } Matrix FreeBodyJoint::GetBackward_sP(){ Mat6x6 sP; - sP.Identity(); + sP.Identity(); sP =-1.0*sP; - std::cout<<"Did I come here in "<r); - - //COMMENT STEP3: CALCULATE QDOT + + FastAssign(r12,body2->r); + + //COMMENT STEP3: CALCULATE QDOT qdot_to_u(q, u, qdot); - - + + Vect3 WN; WN.BasicSet(0,u.BasicGet(0)); WN.BasicSet(1,u.BasicGet(1)); WN.BasicSet(2,u.BasicGet(2)); - - Vect3 VN; + + Vect3 VN; VN.BasicSet(0,u.BasicGet(3)); VN.BasicSet(1,u.BasicGet(4)); - VN.BasicSet(2,u.BasicGet(5)); - - FastAssign(WN,body2->omega_k); - + VN.BasicSet(2,u.BasicGet(5)); + + FastAssign(WN,body2->omega_k); + Vect3 pk_w_k; - FastMult(body2->n_C_k,WN,pk_w_k); + FastMult(body2->n_C_k,WN,pk_w_k); FastAssign(pk_w_k,body2->omega); + - - - //COMMENT STEP5: CALCULATE VELOCITES - FastAssign(VN,body2->v); - FastTMult(body2->n_C_k,body2->v,body2->v_k); - - - //CALCULATE KE - + + //COMMENT STEP5: CALCULATE VELOCITES + FastAssign(VN,body2->v); + FastTMult(body2->n_C_k,body2->v,body2->v_k); + + + //CALCULATE KE + Matrix tempke; - tempke = T(body2->v)*(body2->v); + tempke = T(body2->v)*(body2->v); double ke = 0.0; - ke = body2->mass*tempke(1,1); + ke = body2->mass*tempke(1,1); FastMult(body2->inertia,body2->omega_k,result1); - tempke= T(body2->omega_k)*result1; + tempke= T(body2->omega_k)*result1; ke = 0.5*ke + 0.5*tempke(1,1); body2->KE=ke; - - + + //COMMENT STEP6: CALCULATE STATE EXPLICIT ANGULAR ACCELERATIONS body2->alpha_t.Zeros(); - - + + //COMMENT STEP7: CALCULATE STATE EXPLICIT ACCELERATIONS - body2->a_t.Zeros(); - + body2->a_t.Zeros(); + } void FreeBodyJoint::BackwardKinematics(){ -std::cout<<"Did I come here "< - #include "joint.h" -#include "matrix.h" -namespace POEMS { + class FreeBodyJoint : public Joint{ -public: +public: FreeBodyJoint(); ~FreeBodyJoint(); - + JointType GetType(); bool ReadInJointData(std::istream& in); void WriteOutJointData(std::ostream& out); @@ -40,5 +37,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; -} + #endif diff --git a/lib/poems/inertialframe.cpp b/lib/poems/inertialframe.cpp index 19ca7cdb0b..6c97b2f584 100644 --- a/lib/poems/inertialframe.cpp +++ b/lib/poems/inertialframe.cpp @@ -16,13 +16,9 @@ *_________________________________________________________________________*/ #include "inertialframe.h" - -#include "mat3x3.h" -#include "virtualmatrix.h" +#include "fixedpoint.h" using namespace std; -using namespace POEMS; - InertialFrame::InertialFrame(){ gravity.Zeros(); diff --git a/lib/poems/inertialframe.h b/lib/poems/inertialframe.h index ae987cdc56..08d0279a1e 100644 --- a/lib/poems/inertialframe.h +++ b/lib/poems/inertialframe.h @@ -19,12 +19,9 @@ #ifndef INERTIALFRAME_H #define INERTIALFRAME_H -#include - #include "body.h" -#include "vect3.h" -namespace POEMS { + class InertialFrame : public Body { Vect3 gravity; public: @@ -36,5 +33,5 @@ public: bool ReadInBodyData(std::istream& in); void WriteOutBodyData(std::ostream& out); }; -} + #endif diff --git a/lib/poems/joint.cpp b/lib/poems/joint.cpp index 3e356337cb..3bdd7b5fcd 100644 --- a/lib/poems/joint.cpp +++ b/lib/poems/joint.cpp @@ -16,28 +16,15 @@ *_________________________________________________________________________*/ -#include -#include -#include - +#include "joints.h" #include "body.h" #include "point.h" +#include +#include "matrixfun.h" #include "fastmatrixops.h" -#include "body23joint.h" -#include "colmatrix.h" -#include "freebodyjoint.h" -#include "joint.h" -#include "mat3x3.h" -#include "matrix.h" -#include "mixedjoint.h" -#include "prismaticjoint.h" -#include "revolutejoint.h" -#include "sphericaljoint.h" -#include "virtualmatrix.h" +#include using namespace std; -using namespace POEMS; - Joint::Joint(){ body1 = body2 = 0; @@ -247,7 +234,7 @@ void Joint::ComputeBackwardGlobalTransform(){ // global joint functions // -Joint* POEMS::NewJoint(int type){ +Joint* NewJoint(int type){ switch( JointType(type) ) { case FREEBODYJOINT : return new FreeBodyJoint; diff --git a/lib/poems/joint.h b/lib/poems/joint.h index fa9b6826a7..17122af775 100644 --- a/lib/poems/joint.h +++ b/lib/poems/joint.h @@ -18,15 +18,9 @@ #ifndef JOINT_H #define JOINT_H -#include #include "poemsobject.h" -#include "colmatrix.h" -#include "mat3x3.h" -#include "matrix.h" -#include "vect3.h" - -namespace POEMS { -class VirtualMatrix; +#include +#include "matrices.h" enum JointType { XYZJOINT = 0, @@ -125,5 +119,5 @@ public: // global joint functions Joint* NewJoint(int type); -} + #endif diff --git a/lib/poems/mat3x3.cpp b/lib/poems/mat3x3.cpp index 8a5098ff59..df24d4b108 100644 --- a/lib/poems/mat3x3.cpp +++ b/lib/poems/mat3x3.cpp @@ -16,13 +16,10 @@ *_________________________________________________________________________*/ -#include -#include #include "mat3x3.h" +#include using namespace std; -using namespace POEMS; - Mat3x3::Mat3x3(){ numrows = numcols = 3; diff --git a/lib/poems/mat3x3.h b/lib/poems/mat3x3.h index bc38e6d393..4362b3ad9c 100644 --- a/lib/poems/mat3x3.h +++ b/lib/poems/mat3x3.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: mat3x3.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,19 +11,19 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef MAT3X3_H #define MAT3X3_H -#include #include "virtualmatrix.h" -namespace POEMS { + class Vect3; class Mat6x6; +class Matrix; class ColMatrix; class Mat3x3 : public VirtualMatrix { @@ -68,15 +68,16 @@ public: friend void FastMult(Mat3x3& A, Mat3x3& B, Mat3x3& C); friend void FastMultT(Mat3x3& A, Mat3x3& B, Mat3x3& C); friend void FastAssignT(Mat3x3& A, Mat3x3& C); - friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); - + friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); + friend void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC); friend void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI); friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); - + friend void EP_Transformation(ColMatrix& q, Mat3x3& C); friend void EP_FromTransformation(ColMatrix& q, Mat3x3& C); + }; -} + #endif diff --git a/lib/poems/mat4x4.cpp b/lib/poems/mat4x4.cpp index 9a0e7b8d56..4a611a6796 100644 --- a/lib/poems/mat4x4.cpp +++ b/lib/poems/mat4x4.cpp @@ -16,13 +16,9 @@ *_________________________________________________________________________*/ #include "mat4x4.h" - #include -#include using namespace std; -using namespace POEMS; - Mat4x4::Mat4x4(){ numrows = numcols = 4; diff --git a/lib/poems/mat4x4.h b/lib/poems/mat4x4.h index 3f6d97ba15..d7942b248e 100644 --- a/lib/poems/mat4x4.h +++ b/lib/poems/mat4x4.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: mat4x4.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,28 +11,27 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef MAT4X4_H #define MAT4X4_H -#include #include "virtualmatrix.h" +#include "matrix.h" + -namespace POEMS { class Vect4; -class Matrix; class Mat4x4 : public VirtualMatrix { double elements[4][4]; -public: +public: Mat4x4(); ~Mat4x4(); Mat4x4(const Mat4x4& A); // copy constructor Mat4x4(const VirtualMatrix& A); // copy constructor - + double& operator_2int (int i, int j); // array access double Get_2int(int i, int j) const; void Set_2int(int i, int j, double value); @@ -65,5 +64,5 @@ public: friend void FastMultT(Mat4x4& A, Mat4x4& B, Mat4x4& C); friend void FastAssignT(Mat4x4& A, Mat4x4& C); }; -} + #endif diff --git a/lib/poems/mat6x6.cpp b/lib/poems/mat6x6.cpp index e9dde2fe87..16bffc5026 100644 --- a/lib/poems/mat6x6.cpp +++ b/lib/poems/mat6x6.cpp @@ -16,13 +16,9 @@ *_________________________________________________________________________*/ #include "mat6x6.h" - #include -#include using namespace std; -using namespace POEMS; - Mat6x6::Mat6x6(){ numrows = numcols = 6; diff --git a/lib/poems/mat6x6.h b/lib/poems/mat6x6.h index a611bc8283..11951b0442 100644 --- a/lib/poems/mat6x6.h +++ b/lib/poems/mat6x6.h @@ -17,11 +17,9 @@ #ifndef MAT6X6_H #define MAT6X6_H -#include - #include "virtualmatrix.h" -namespace POEMS { + class Matrix; class Mat3x3; class Vect6; @@ -74,5 +72,5 @@ public: friend void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC); friend void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI); }; -} + #endif diff --git a/lib/poems/matrices.h b/lib/poems/matrices.h index 15f0d3ad23..7a7e2c4b58 100644 --- a/lib/poems/matrices.h +++ b/lib/poems/matrices.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: matrices.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -20,14 +20,23 @@ #define MATRICES_H #include "matrix.h" + #include "colmatrix.h" + #include "rowmatrix.h" + #include "mat3x3.h" + #include "vect3.h" + #include "mat4x4.h" + #include "vect4.h" + #include "mat6x6.h" + #include "vect6.h" + #include "colmatmap.h" #endif diff --git a/lib/poems/matrix.cpp b/lib/poems/matrix.cpp index f7b0c631f2..f05d6f815c 100644 --- a/lib/poems/matrix.cpp +++ b/lib/poems/matrix.cpp @@ -21,8 +21,6 @@ #include using namespace std; -using namespace POEMS; - Matrix::Matrix(){ numrows = numcols = 0; diff --git a/lib/poems/matrix.h b/lib/poems/matrix.h index c2ed92873c..63699b9835 100644 --- a/lib/poems/matrix.h +++ b/lib/poems/matrix.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: matrix.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,18 +11,15 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef MATRIX_H #define MATRIX_H -#include - #include "virtualmatrix.h" -namespace POEMS { class Mat3x3; class Mat4x4; class Mat6x6; @@ -74,6 +71,7 @@ public: friend void FastMult(Mat6x6& A, Matrix& B, Matrix& C); friend void FastMult(Matrix& A, ColMatrix& B, Vect6& C); friend void FastMultT(Matrix& A, Matrix& B, Mat6x6& C); + }; -} + #endif diff --git a/lib/poems/matrixfun.cpp b/lib/poems/matrixfun.cpp index 037e986a99..d193114679 100644 --- a/lib/poems/matrixfun.cpp +++ b/lib/poems/matrixfun.cpp @@ -16,25 +16,17 @@ *_________________________________________________________________________*/ #include "matrixfun.h" - -#include -#include - +#include #include "fastmatrixops.h" -#include "vect4.h" -#include "virtualcolmatrix.h" -#include "virtualmatrix.h" -#include "virtualrowmatrix.h" +#include using namespace std; -using namespace POEMS; - // // Create a new matrix // -VirtualMatrix* POEMS::NewMatrix(int type){ +VirtualMatrix* NewMatrix(int type){ switch( MatrixType(type) ) { case MATRIX : return new Matrix; @@ -52,7 +44,7 @@ VirtualMatrix* POEMS::NewMatrix(int type){ // Transpose // -Matrix POEMS::T(const VirtualMatrix& A){ +Matrix T(const VirtualMatrix& A){ int numrows = A.GetNumRows(); int numcols = A.GetNumCols(); Matrix C(numcols,numrows); @@ -62,8 +54,8 @@ Matrix POEMS::T(const VirtualMatrix& A){ return C; } -Mat3x3 POEMS::T(const Mat3x3& A){ - Mat3x3 C; +Mat3x3 T(const Mat3x3& A){ + Mat3x3 C; C.elements[0][0] = A.elements[0][0]; C.elements[1][1] = A.elements[1][1]; C.elements[2][2] = A.elements[2][2]; @@ -78,7 +70,7 @@ Mat3x3 POEMS::T(const Mat3x3& A){ return C; } -Mat6x6 POEMS::T(const Mat6x6& A){ +Mat6x6 T(const Mat6x6& A){ Mat6x6 C; int i,j; for(i=0;i<6;i++) @@ -88,7 +80,7 @@ Mat6x6 POEMS::T(const Mat6x6& A){ return C; } -Matrix POEMS::T(const Vect3& A){ +Matrix T(const Vect3& A){ Matrix C(1,3); C.BasicSet(0,0,A.elements[0]); C.BasicSet(0,1,A.elements[1]); @@ -97,7 +89,7 @@ Matrix POEMS::T(const Vect3& A){ return C; } -Matrix POEMS::T(const Vect6& A){ +Matrix T(const Vect6& A){ Matrix C(1,6); C.BasicSet(0,0,A.elements[0]); C.BasicSet(0,1,A.elements[1]); @@ -109,7 +101,7 @@ Matrix POEMS::T(const Vect6& A){ return C; } -RowMatrix POEMS::T(const VirtualColMatrix &A){ +RowMatrix T(const VirtualColMatrix &A){ int numele = A.GetNumRows(); RowMatrix C(numele); for(int i=0;i - +#include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" +#include "norm.h" #include "eulerparameters.h" -#include "colmatrix.h" -#include "mat3x3.h" -#include "mat6x6.h" -#include "vect3.h" -#include "virtualmatrix.h" +#include "matrices.h" -using namespace POEMS; -using namespace std; + - -MixedJoint::MixedJoint(){ +MixedJoint::MixedJoint(){ } MixedJoint::~MixedJoint(){ @@ -56,23 +49,23 @@ void MixedJoint::SetsP(Matrix& sPr, Vect6& temp_dofs, int i, int j){ numrots = i; numtrans = j; if (numrots < 2) - DimQandU(numrots+numtrans,numrots+numtrans); - else - DimQandU((4+numtrans),(numrots+numtrans)); + DimQandU(numrots+numtrans,numrots+numtrans); + else + DimQandU((4+numtrans),(numrots+numtrans)); cout<<"Check "<<4+numtrans<<" "< 1) EP_Normalize(q); // COMMENT STEP1: CALCULATE ORIENTATIONS - ComputeForwardTransforms(); - - + ComputeForwardTransforms(); + + //COMMENT STEP2: CALCULATE POSITION VECTORS - Vect3 result1, result2, result3, result4; + Vect3 result1, result2, result3, result4; result1.Zeros(); for (int k=0; k<3; k++){ if( dofs(3+k) != 0.0 ){ @@ -118,32 +111,32 @@ void MixedJoint::ForwardKinematics(){ result1.BasicSet(k,q.BasicGet(4 + k)); else result1.BasicSet(k,q.BasicGet(numrots + k)); - } + } } - - - - FastAssign(result1,r12); // r12 in parents basis i.e. Newtonian - FastNegMult(k_C_pk,r12,r21); // r21 in body basis - - FastAssign(r12,body2->r); // This is right - - //COMMENT STEP3: CALCULATE QDOT + + + + FastAssign(result1,r12); // r12 in parents basis i.e. Newtonian + FastNegMult(k_C_pk,r12,r21); // r21 in body basis + + FastAssign(r12,body2->r); // This is right + + //COMMENT STEP3: CALCULATE QDOT int pp = 0; if (numrots > 1){ ColMatrix temp_u(3+numtrans); qdot_to_u(q,temp_u,qdot); for (int k=1;k<=6;k++){ if(dofs(k) != 0.0){ - u.BasicSet(pp,temp_u.BasicGet(k-1)); + u.BasicSet(pp,temp_u.BasicGet(k-1)); pp = pp+1; - } + } } } else u = qdot; - - + + Vect3 WN; WN.Zeros(); int p = 0; for (int k=0;k<3;k++){ @@ -153,51 +146,51 @@ void MixedJoint::ForwardKinematics(){ } }// WN is in body basis - - Vect3 VN; VN.Zeros(); + + Vect3 VN; VN.Zeros(); for (int k=0;k<3;k++){ if( dofs(3+k+1) != 0.0 ) { VN.BasicSet(k,u.BasicGet(p)); p=p+1; } }// VN is the vector of translational velocities in Newtonian basis + + FastAssign(WN,body2->omega_k); - FastAssign(WN,body2->omega_k); - - // cout<<"Angular Velocity "<n_C_k,WN,pk_w_k); + FastMult(body2->n_C_k,WN,pk_w_k); FastAssign(pk_w_k,body2->omega); - - - - //COMMENT STEP5: CALCULATE VELOCITES - FastAssign(VN,body2->v); - FastTMult(body2->n_C_k,body2->v,body2->v_k); - - - //CALCULATE KE - + + + + //COMMENT STEP5: CALCULATE VELOCITES + FastAssign(VN,body2->v); + FastTMult(body2->n_C_k,body2->v,body2->v_k); + + + //CALCULATE KE + Matrix tempke; - tempke = T(body2->v)*(body2->v); + tempke = T(body2->v)*(body2->v); double ke = 0.0; - ke = body2->mass*tempke(1,1); + ke = body2->mass*tempke(1,1); FastMult(body2->inertia,body2->omega_k,result1); - tempke= T(body2->omega_k)*result1; + tempke= T(body2->omega_k)*result1; ke = 0.5*ke + 0.5*tempke(1,1); body2->KE=ke; - - + + //COMMENT STEP6: CALCULATE STATE EXPLICIT ANGULAR ACCELERATIONS body2->alpha_t.Zeros(); - - + + //COMMENT STEP7: CALCULATE STATE EXPLICIT ACCELERATIONS - body2->a_t.Zeros(); - + body2->a_t.Zeros(); + } void MixedJoint::BackwardKinematics(){ cout<<"Did I come here "< - #include "joint.h" -#include "matrix.h" -#include "vect6.h" -namespace POEMS { + class MixedJoint : public Joint{ Matrix const_sP; int numrots; int numtrans; Vect6 dofs; -public: +public: MixedJoint(); ~MixedJoint(); - + JointType GetType(); bool ReadInJointData(std::istream& in); void WriteOutJointData(std::ostream& out); @@ -46,5 +42,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; -} + #endif diff --git a/lib/poems/norm.cpp b/lib/poems/norm.cpp index 6c983dd06f..0f918cf968 100644 --- a/lib/poems/norm.cpp +++ b/lib/poems/norm.cpp @@ -16,15 +16,7 @@ *_________________________________________________________________________*/ #include - #include "norm.h" -#include "colmatrix.h" -#include "rowmatrix.h" -#include "vect3.h" -#include "vect4.h" -#include "vect6.h" - -using namespace POEMS; double Magnitude(ColMatrix& A){ double G; diff --git a/lib/poems/norm.h b/lib/poems/norm.h index 808be609e8..963a2ec5b2 100644 --- a/lib/poems/norm.h +++ b/lib/poems/norm.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: norm.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,24 +11,20 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef NORM_H #define NORM_H -namespace POEMS { -class ColMatrix; -class RowMatrix; -class Vect3; -class Vect4; -class Vect6; +#include "matrices.h" + double Magnitude(ColMatrix& A); double Magnitude(RowMatrix& A); double Magnitude(Vect3& A); double Magnitude(Vect4& A); double Magnitude(Vect6& A); -} + #endif diff --git a/lib/poems/onbody.cpp b/lib/poems/onbody.cpp index 7cea2d2f25..102900df8d 100644 --- a/lib/poems/onbody.cpp +++ b/lib/poems/onbody.cpp @@ -16,22 +16,17 @@ *_________________________________________________________________________*/ #include "onbody.h" - -#include -#include - #include "body.h" #include "inertialframe.h" #include "joint.h" #include "onfunctions.h" #include "virtualmatrix.h" #include "matrixfun.h" +#include +#include "norm.h" #include "eulerparameters.h" -#include "colmatrix.h" using namespace std; -using namespace POEMS; - OnBody::OnBody(){ diff --git a/lib/poems/onbody.h b/lib/poems/onbody.h index df82709ad5..d9923773c7 100644 --- a/lib/poems/onbody.h +++ b/lib/poems/onbody.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: onbody.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -22,14 +22,6 @@ #include "matrix.h" #include "vect6.h" #include "mat6x6.h" -#include "joint.h" -#include "mat3x3.h" -#include "vect3.h" - -namespace POEMS { -class Body; -class ColMatrix; -class InertialFrame; // emumerated type enum Direction { @@ -37,65 +29,71 @@ enum Direction { FORWARD= 1 }; +class Body; +class InertialFrame; +class Joint; +class OnSolver; + class OnBody { - Body* system_body; - Joint* system_joint; - OnBody* parent; - List children; + Body* system_body; + Joint* system_joint; + OnBody* parent; + List children; - Direction joint_dir; - void (Joint::*kinfun)(); // kinematics function - void (Joint::*updatesP)(Matrix&); // sP update function - Vect3* gamma; // pointer to gamma vector - Mat3x3* pk_C_k; // pointer to transformation + Direction joint_dir; + void (Joint::*kinfun)(); // kinematics function + void (Joint::*updatesP)(Matrix&); // sP update function + Vect3* gamma; // pointer to gamma vector + Mat3x3* pk_C_k; // pointer to transformation + + Mat6x6 sI; // spatial inertias + Mat6x6 sIhat; // recursive spatial inertias + Mat6x6 sSC; // spatial shift + Mat6x6 sT; // spatial triangularization - Mat6x6 sI; // spatial inertias - Mat6x6 sIhat; // recursive spatial inertias - Mat6x6 sSC; // spatial shift - Mat6x6 sT; // spatial triangularization + Vect6 sF; // spatial forces + Vect6 sFhat; // recursive spatial forces + Vect6 sAhat; // recursive spatial acceleration - Vect6 sF; // spatial forces - Vect6 sFhat; // recursive spatial forces - Vect6 sAhat; // recursive spatial acceleration + Matrix sP; // spatial partial velocities + Matrix sM; // triangularized mass matrix diagonal elements + Matrix sMinv; // inverse of sM + Matrix sPsMinv; + Matrix sIhatsP; - Matrix sP; // spatial partial velocities - Matrix sM; // triangularized mass matrix diagonal elements - Matrix sMinv; // inverse of sM - Matrix sPsMinv; - Matrix sIhatsP; - - // states and state derivatives - ColMatrix* q; - ColMatrix* u; - ColMatrix* qdot; - ColMatrix* udot; - ColMatrix* qdotdot; - - ColMatrix* r; - ColMatrix* acc; - ColMatrix* ang; + // states and state derivatives + ColMatrix* q; + ColMatrix* u; + ColMatrix* qdot; + ColMatrix* udot; + ColMatrix* qdotdot; + + ColMatrix* r; + ColMatrix* acc; + ColMatrix* ang; // friend classes friend class OnSolver; + -public: - OnBody(); - ~OnBody(); - int RecursiveSetup(InertialFrame* basebody); - int RecursiveSetup(int ID, OnBody* parentbody, Joint* sys_joint); - void RecursiveKinematics(); - void RecursiveTriangularization(); - void RecursiveForwardSubstitution(); - Mat3x3 GetN_C_K(); - Vect3 LocalCart(); - int GetBodyID(); - void CalculateAcceleration(); - void Setup(); - void SetupInertialFrame(); - void LocalKinematics(); - void LocalTriangularization(Vect3& Torque, Vect3& Force); - void LocalForwardSubstitution(); +public: + OnBody(); + ~OnBody(); + int RecursiveSetup(InertialFrame* basebody); + int RecursiveSetup(int ID, OnBody* parentbody, Joint* sys_joint); + void RecursiveKinematics(); + void RecursiveTriangularization(); + void RecursiveForwardSubstitution(); + Mat3x3 GetN_C_K(); + Vect3 LocalCart(); + int GetBodyID(); + void CalculateAcceleration(); + void Setup(); + void SetupInertialFrame(); + void LocalKinematics(); + void LocalTriangularization(Vect3& Torque, Vect3& Force); + void LocalForwardSubstitution(); }; -} + #endif diff --git a/lib/poems/onfunctions.cpp b/lib/poems/onfunctions.cpp index cfc0c60936..582ab8cf8b 100644 --- a/lib/poems/onfunctions.cpp +++ b/lib/poems/onfunctions.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: onfunction.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,25 +11,18 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #include "onfunctions.h" - -#include "mat3x3.h" -#include "mat6x6.h" -#include "vect3.h" -#include "vect6.h" -#include "virtualmatrix.h" - +#include "matrixfun.h" +#include using namespace std; -using namespace POEMS; - // friend of Vect3 & Vect6 -void POEMS::OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV){ +void OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV){ sV.elements[0] = angular.elements[0]; sV.elements[1] = angular.elements[1]; sV.elements[2] = angular.elements[2]; @@ -39,38 +32,38 @@ void POEMS::OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV){ } // friend of Vect3, Mat3x3, & Mat6x6 -void POEMS::OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC){ +void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC){ // the block diagonals - + // the gamma cross with transform Mat3x3 temp; Mat3x3 temp2; SC.Zeros(); - temp.Zeros(); + temp.Zeros(); temp2.Zeros(); - //FastTMult(C,gamma,temp); + //FastTMult(C,gamma,temp); temp(1,2)= -gamma(3); temp(1,3)= gamma(2); temp(2,1)= gamma(3); - temp(2,3)= -gamma(1); temp(3,1)= -gamma(2); temp(3,2)= gamma(1); + temp(2,3)= -gamma(1); temp(3,1)= -gamma(2); temp(3,2)= gamma(1); FastMult(temp,C,temp2); - + SC(1,4)=temp2(1,1); SC(2,4)=temp2(2,1); SC(3,4)=temp2(3,1); SC(1,5)=temp2(1,2); SC(2,5)=temp2(2,2); SC(3,5)=temp2(3,2); SC(1,6)=temp2(1,3); SC(2,6)=temp2(2,3); SC(3,6)=temp2(3,3); - + SC(1,1)=C(1,1); SC(2,1)=C(2,1); SC(3,1)=C(3,1); SC(1,2)=C(1,2); SC(2,2)=C(2,2); SC(3,2)=C(3,2); SC(1,3)=C(1,3); SC(2,3)=C(2,3); SC(3,3)=C(3,3); SC(4,4)=C(1,1); SC(5,4)=C(2,1); SC(6,4)=C(3,1); SC(4,5)=C(1,2); SC(5,5)=C(2,2); SC(6,5)=C(3,2); - SC(4,6)=C(1,3); SC(5,6)=C(2,3); SC(6,6)=C(3,3); - + SC(4,6)=C(1,3); SC(5,6)=C(2,3); SC(6,6)=C(3,3); + } // friend of Mat3x3 & Mat6x6 -void POEMS::OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI){ - - sI(4,4)=mass; sI(5,5)=mass; sI(6,6)=mass; - sI(1,1)=inertia(1,1); sI(1,2)=inertia(1,2); sI(1,3)=inertia(1,3); - sI(2,1)=inertia(2,1); sI(2,2)=inertia(2,2); sI(2,3)=inertia(2,3); - sI(3,1)=inertia(3,1); sI(3,2)=inertia(3,2); sI(3,3)=inertia(3,3); +void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI){ + + sI(4,4)=mass; sI(5,5)=mass; sI(6,6)=mass; + sI(1,1)=inertia(1,1); sI(1,2)=inertia(1,2); sI(1,3)=inertia(1,3); + sI(2,1)=inertia(2,1); sI(2,2)=inertia(2,2); sI(2,3)=inertia(2,3); + sI(3,1)=inertia(3,1); sI(3,2)=inertia(3,2); sI(3,3)=inertia(3,3); } diff --git a/lib/poems/onfunctions.h b/lib/poems/onfunctions.h index bb07425b85..8a69694095 100644 --- a/lib/poems/onfunctions.h +++ b/lib/poems/onfunctions.h @@ -18,11 +18,7 @@ #ifndef ONFUNCTIONS_H #define ONFUNCTIONS_H -namespace POEMS { -class Mat3x3; -class Mat6x6; -class Vect3; -class Vect6; +#include "matrices.h" void OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV); void OnPopulateSC(Vect3& gamma, Mat3x3& C, Mat6x6& SC); @@ -31,5 +27,5 @@ void OnPopulateSI(Mat3x3& inertia, double mass, Mat6x6& sI); void Create_Map(int MM); int ICELL(int IX,int IY,int IZ, int MM); -} + #endif diff --git a/lib/poems/onsolver.cpp b/lib/poems/onsolver.cpp index 609ef32613..ad04d7e9e3 100644 --- a/lib/poems/onsolver.cpp +++ b/lib/poems/onsolver.cpp @@ -16,25 +16,15 @@ *_________________________________________________________________________*/ -#include -#include - #include "onsolver.h" #include "system.h" #include "onbody.h" #include "body.h" -#include "colmatmap.h" -#include "colmatrix.h" -#include "defines.h" -#include "inertialframe.h" -#include "matrix.h" -#include "poemslist.h" -#include "vect3.h" -#include "virtualmatrix.h" +#include "matrixfun.h" +#include + using namespace std; -using namespace POEMS; - OnSolver::OnSolver(){ numbodies = 0; diff --git a/lib/poems/onsolver.h b/lib/poems/onsolver.h index 1e850b8fc1..f32b5880a9 100644 --- a/lib/poems/onsolver.h +++ b/lib/poems/onsolver.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: onsolver.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,32 +21,31 @@ #include "solver.h" #include "onbody.h" +#include -namespace POEMS { -class ColMatrix; -class Matrix; + class OnSolver : public Solver { - OnBody inertialframe; - int numbodies; - OnBody** bodyarray; - ColMatrix** q; - ColMatrix** qdot; - ColMatrix** qdotdot; - ColMatrix** u; - ColMatrix** udot; - - - - void DeleteModel(); - int CreateTopologyArray(int i, OnBody* body); - void CreateStateMatrixMaps(); - void GetType(); -public: - OnSolver(); - ~OnSolver(); - void CreateModel(); - void Solve(double time, Matrix& FF); + OnBody inertialframe; + int numbodies; + OnBody** bodyarray; + ColMatrix** q; + ColMatrix** qdot; + ColMatrix** qdotdot; + ColMatrix** u; + ColMatrix** udot; + + + + void DeleteModel(); + int CreateTopologyArray(int i, OnBody* body); + void CreateStateMatrixMaps(); + void GetType(); +public: + OnSolver(); + ~OnSolver(); + void CreateModel(); + void Solve(double time, Matrix& FF); }; -} + #endif diff --git a/lib/poems/particle.cpp b/lib/poems/particle.cpp index 37ec790666..3496bc1906 100644 --- a/lib/poems/particle.cpp +++ b/lib/poems/particle.cpp @@ -17,8 +17,7 @@ #include "particle.h" - -using namespace POEMS; +#include "fixedpoint.h" Particle::Particle(){ } diff --git a/lib/poems/particle.h b/lib/poems/particle.h index 8a7a521451..20aa4831ea 100644 --- a/lib/poems/particle.h +++ b/lib/poems/particle.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: particle.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -19,18 +19,16 @@ #ifndef PARTICLE_H #define PARTICLE_H -#include - #include "body.h" -namespace POEMS { + class Particle : public Body { -public: +public: Particle(); ~Particle(); BodyType GetType(); bool ReadInBodyData(std::istream& in); void WriteOutBodyData(std::ostream& out); }; -} + #endif diff --git a/lib/poems/poemslist.h b/lib/poems/poemslist.h index bd0c1456b4..9882af013a 100644 --- a/lib/poems/poemslist.h +++ b/lib/poems/poemslist.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: poemslist.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,7 +21,8 @@ #include #include -namespace POEMS { +using namespace std; + template class ListElement{ public: ListElement* prev; @@ -50,7 +51,7 @@ public: S* operator()(int id); void Append(List * listToAppend); void DeleteValues(); - void RemoveElementAndDeleteValue(ListElement* ele); + void RemoveElementAndDeleteValue(ListElement* ele); void PrintList(); }; @@ -89,9 +90,9 @@ template List::~List(){ template void List::Append(List * listToAppend) { - tail->next = listToAppend->head; - listToAppend->head->prev = tail; - tail = listToAppend->tail; + tail->next = listToAppend->head; + listToAppend->head->prev = tail; + tail = listToAppend->tail; } template int List::GetNumElements(){ @@ -103,17 +104,17 @@ template ListElement* List::GetHeadElement(){ } template ListElement* List::GetTailElement(){ - return tail; + return tail; } template void List::Remove(ListElement* ele){ if(!ele){ - std::cerr << "ERROR: ListElement to be removed not defined" << std::endl; + cerr << "ERROR: ListElement to be removed not defined" << endl; exit(0); } if(!numelements){ - std::cerr << "ERROR: List is empty" << std::endl; + cerr << "ERROR: List is empty" << endl; exit(0); } @@ -134,7 +135,7 @@ template void List::Remove(ListElement* ele){ template ListElement* List::Append(S* v){ if(!v){ - std::cerr << "ERROR: cannot add null Body to list" << std::endl; + cerr << "ERROR: cannot add null Body to list" << endl; exit(0); } @@ -144,22 +145,22 @@ template ListElement* List::Append(S* v){ if(numelements==1) head = tail = ele; else{ - /* + /* tail->next = ele; ele->prev = tail; - tail = ele;*/ - - ele->prev = tail; - tail = ele; - ele->prev->next = ele; - - } + tail = ele;*/ + + ele->prev = tail; + tail = ele; + ele->prev->next = ele; + + } return ele; } template ListElement* List::Prepend(S* v){ if(!v){ - std::cerr << "ERROR: cannot add null Body to list" << std::endl; + cerr << "ERROR: cannot add null Body to list" << endl; exit(0); } @@ -169,9 +170,9 @@ template ListElement* List::Prepend(S* v){ if(numelements==1) head = tail = ele; else{ - ele->next = head; - head = ele; - ele->next->prev = ele; + ele->next = head; + head = ele; + ele->next->prev = ele; } return ele; } @@ -189,15 +190,15 @@ template S** List::CreateArray(){ template S* List::operator()(int id){ if(id >= numelements){ - std::cerr << "ERROR: subscript out of bounds" << std::endl; + cerr << "ERROR: subscript out of bounds" << endl; exit(0); } - + ListElement* ele = head; for(int i=0;inext; } - + return ele->value; } @@ -213,15 +214,16 @@ template void List::RemoveElementAndDeleteValue(ListElement* ele) } template void List::PrintList(){ - std::cout << "Printing List " << std::endl; - ListElement* ele = head; - std::cout << *(ele->value) << " "; - ele = ele->next; - for(int k =2; kvalue) << " "; - ele = ele->next; - } - std::cout << *(ele->value) << std::endl; -} + cout<<"Printing List "<* ele = head; + cout<<*(ele->value)<<" "; + ele = ele->next; + for(int k =2; kvalue)<<" "; + ele = ele->next; + } + cout<<*(ele->value)< -namespace POEMS { +using namespace std; + + TreeNode *GetTreeNode(int item,TreeNode *lptr = NULL,TreeNode *rptr =NULL); void FreeTreeNode(TreeNode *p); @@ -79,7 +81,7 @@ TreeNode *GetTreeNode(int item,TreeNode *lptr,TreeNode *rptr) // if insufficient memory, terminatewith an error message if (p == NULL) { - std::cerr << "Memory allocation failure!\n"; + cerr << "Memory allocation failure!\n"; exit(1); } @@ -138,7 +140,7 @@ void IndentBlanks(int num) // const int indentblock = 6; for(int i = 0; i < num; i++) - std::cout << " "; + cout << " "; } void PrintTree (TreeNode *t, int level) @@ -151,11 +153,10 @@ void PrintTree (TreeNode *t, int level) PrintTree(t->Right(),level + 1); // indent to current level; output node data IndentBlanks(indentUnit*level); - std::cout << t->GetData() << std::endl; + cout << t->GetData() << endl; // print left branch of tree t PrintTree(t->Left(),level + 1); } } -} #endif diff --git a/lib/poems/poemsobject.cpp b/lib/poems/poemsobject.cpp index dfdd95953e..7c3f1ca872 100644 --- a/lib/poems/poemsobject.cpp +++ b/lib/poems/poemsobject.cpp @@ -19,8 +19,6 @@ #include "poemsobject.h" #include -using namespace POEMS; - POEMSObject::POEMSObject(){ name = 0; ChangeName((const char*)"unnamed"); diff --git a/lib/poems/poemsobject.h b/lib/poems/poemsobject.h index 173d9da7ab..63b2915638 100644 --- a/lib/poems/poemsobject.h +++ b/lib/poems/poemsobject.h @@ -19,7 +19,7 @@ #ifndef POEMSOBJECT_H #define POEMSOBJECT_H -namespace POEMS { + class POEMSObject { char* name; int ID; @@ -31,5 +31,5 @@ public: int GetID(); void SetID(int id); }; -} + #endif diff --git a/lib/poems/poemstree.h b/lib/poems/poemstree.h index d49a0d0a88..8f8e80ab66 100644 --- a/lib/poems/poemstree.h +++ b/lib/poems/poemstree.h @@ -21,7 +21,7 @@ #include "poemstreenode.h" #include "poemsnodelib.h" -namespace POEMS { + // constants to indicate the balance factor of a node const int leftheavy = -1; const int balanced = 0; @@ -609,5 +609,5 @@ void Tree::ClearList(void) delete current; size = 0; } -} + #endif diff --git a/lib/poems/poemstreenode.cpp b/lib/poems/poemstreenode.cpp index ca4307f69f..051e13d6e0 100644 --- a/lib/poems/poemstreenode.cpp +++ b/lib/poems/poemstreenode.cpp @@ -17,8 +17,6 @@ #include "poemstreenode.h" -using namespace POEMS; - // constructor; initialize the data and pointer fields // The pointer value NULL assigns a empty subtree TreeNode::TreeNode (const int & item, TreeNode *lptr,TreeNode *rptr, diff --git a/lib/poems/poemstreenode.h b/lib/poems/poemstreenode.h index 69f3caf958..b8f46031a5 100644 --- a/lib/poems/poemstreenode.h +++ b/lib/poems/poemstreenode.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: poemstreenode.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,37 +11,42 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef TREENODE_H #define TREENODE_H -namespace POEMS { +//#define NULL 0 + + +//Tree depends on TreeNode +class Tree; + // declares a tree node object for a binary tree class TreeNode{ private: // points to the left and right children of the node - TreeNode *left; - TreeNode *right; + TreeNode *left; + TreeNode *right; - int balanceFactor; - int data; - void * aux_data; -public: - // make Tree a friend because it needs access to left and right pointer fields of a node - friend class Tree; - TreeNode * Left(); - TreeNode * Right(); - int GetData(); - void * GetAuxData() {return aux_data;}; - void SetAuxData(void * AuxData) {aux_data = AuxData;}; - int GetBalanceFactor(); - TreeNode(const int &item, TreeNode *lptr, TreeNode *rptr, int balfac = 0); - //friend class DCASolver; + int balanceFactor; + int data; + void * aux_data; +public: + // make Tree a friend because it needs access to left and right pointer fields of a node + friend class Tree; + TreeNode * Left(); + TreeNode * Right(); + int GetData(); + void * GetAuxData() {return aux_data;}; + void SetAuxData(void * AuxData) {aux_data = AuxData;}; + int GetBalanceFactor(); + TreeNode(const int &item, TreeNode *lptr, TreeNode *rptr, int balfac = 0); + //friend class DCASolver; }; -} + #endif diff --git a/lib/poems/point.cpp b/lib/poems/point.cpp index f648b58d3d..4383844736 100644 --- a/lib/poems/point.cpp +++ b/lib/poems/point.cpp @@ -16,11 +16,7 @@ *_________________________________________________________________________*/ -#include "fixedpoint.h" -#include "point.h" -#include "vect3.h" - -using namespace POEMS; +#include "points.h" Point::Point(){ position.Zeros(); @@ -37,7 +33,7 @@ void Point::WriteOut(std::ostream& out){ WriteOutPointData(out); } -Point* POEMS::NewPoint(int type){ +Point* NewPoint(int type){ switch( PointType(type) ) { case FIXEDPOINT : // A Fixed Point diff --git a/lib/poems/point.h b/lib/poems/point.h index c08e92db0d..746a527cd7 100644 --- a/lib/poems/point.h +++ b/lib/poems/point.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: point.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -22,21 +22,21 @@ #include "poemsobject.h" #include "vect3.h" -namespace POEMS { + // emumerated type enum PointType { FIXEDPOINT = 0 }; class Point : public POEMSObject { -public: +public: Vect3 position; - Point(); - bool ReadIn(std::istream& in); + Point(); + bool ReadIn(std::istream& in); void WriteOut(std::ostream& out); - - virtual ~Point(); + + virtual ~Point(); virtual PointType GetType() = 0; virtual Vect3 GetPoint() = 0; virtual bool ReadInPointData(std::istream& in) = 0; @@ -45,5 +45,5 @@ public: // global point functions Point* NewPoint(int type); -} + #endif diff --git a/lib/poems/prismaticjoint.cpp b/lib/poems/prismaticjoint.cpp index 3e649f0d22..7c01667a86 100644 --- a/lib/poems/prismaticjoint.cpp +++ b/lib/poems/prismaticjoint.cpp @@ -16,16 +16,10 @@ *_________________________________________________________________________*/ #include "prismaticjoint.h" - #include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" -#include "colmatrix.h" -#include "mat3x3.h" -#include "virtualmatrix.h" - -using namespace POEMS; PrismaticJoint::PrismaticJoint(){ q.Dim(1); diff --git a/lib/poems/prismaticjoint.h b/lib/poems/prismaticjoint.h index df3ab3195c..17cf050a78 100644 --- a/lib/poems/prismaticjoint.h +++ b/lib/poems/prismaticjoint.h @@ -18,13 +18,12 @@ #ifndef PRISMATICJOINT_H #define PRISMATICJOINT_H -#include - #include "joint.h" #include "vect3.h" -#include "matrix.h" +#include "mat3x3.h" + + -namespace POEMS { class PrismaticJoint : public Joint { Vect3 axis_pk; // unit vector in body1 basis Vect3 axis_k; // unit vector in body2 basis @@ -44,5 +43,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; -} + #endif diff --git a/lib/poems/revolutejoint.cpp b/lib/poems/revolutejoint.cpp index 6b11acbf0f..ec5b1bec02 100644 --- a/lib/poems/revolutejoint.cpp +++ b/lib/poems/revolutejoint.cpp @@ -16,16 +16,10 @@ *_________________________________________________________________________*/ #include "revolutejoint.h" - #include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" -#include "colmatrix.h" -#include "mat3x3.h" -#include "virtualmatrix.h" - -using namespace POEMS; RevoluteJoint::RevoluteJoint(){ DimQandU(1); diff --git a/lib/poems/revolutejoint.h b/lib/poems/revolutejoint.h index 10a38114df..478d48dbb9 100644 --- a/lib/poems/revolutejoint.h +++ b/lib/poems/revolutejoint.h @@ -18,13 +18,11 @@ #ifndef REVOLUTEJOINT_H #define REVOLUTEJOINT_H -#include #include "joint.h" #include "vect3.h" -#include "matrix.h" +#include "mat3x3.h" + -namespace POEMS { -class VirtualMatrix; class RevoluteJoint : public Joint { Vect3 axis_pk; // unit vector in body1 basis @@ -45,5 +43,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; -} + #endif diff --git a/lib/poems/rigidbody.cpp b/lib/poems/rigidbody.cpp index a7d4f9f19f..3ac424f9e9 100644 --- a/lib/poems/rigidbody.cpp +++ b/lib/poems/rigidbody.cpp @@ -16,12 +16,9 @@ *_________________________________________________________________________*/ #include "rigidbody.h" -#include "mat3x3.h" -#include "virtualmatrix.h" +#include "fixedpoint.h" using namespace std; -using namespace POEMS; - RigidBody::RigidBody(){ } diff --git a/lib/poems/rigidbody.h b/lib/poems/rigidbody.h index d4be92ebcf..0bb2a3ece2 100644 --- a/lib/poems/rigidbody.h +++ b/lib/poems/rigidbody.h @@ -18,11 +18,8 @@ #ifndef RIGIDBODY_H #define RIGIDBODY_H -#include - #include "body.h" -namespace POEMS { class RigidBody : public Body { public: RigidBody(); @@ -31,5 +28,5 @@ public: bool ReadInBodyData(std::istream& in); void WriteOutBodyData(std::ostream& out); }; -} + #endif diff --git a/lib/poems/rowmatrix.cpp b/lib/poems/rowmatrix.cpp index eac8fbef5d..feb185070e 100644 --- a/lib/poems/rowmatrix.cpp +++ b/lib/poems/rowmatrix.cpp @@ -16,13 +16,11 @@ *_________________________________________________________________________*/ #include "rowmatrix.h" - +#include "colmatrix.h" #include #include using namespace std; -using namespace POEMS; - RowMatrix::RowMatrix(){ numcols = 0; diff --git a/lib/poems/rowmatrix.h b/lib/poems/rowmatrix.h index 8e8d7b5f99..b04113e8ed 100644 --- a/lib/poems/rowmatrix.h +++ b/lib/poems/rowmatrix.h @@ -19,12 +19,8 @@ #ifndef ROWMATRIX_H #define ROWMATRIX_H -#include - #include "virtualrowmatrix.h" -#include "virtualmatrix.h" -namespace POEMS { class RowMatrix : public VirtualRowMatrix { double* elements; public: @@ -53,5 +49,5 @@ public: RowMatrix& operator=(const VirtualMatrix& A); // overloaded = RowMatrix& operator*=(double b); }; -} + #endif diff --git a/lib/poems/solver.cpp b/lib/poems/solver.cpp index 04afb27945..67f5b607e3 100644 --- a/lib/poems/solver.cpp +++ b/lib/poems/solver.cpp @@ -15,12 +15,9 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ -#include #include "solver.h" #include "system.h" -#include "onsolver.h" - -using namespace POEMS; +#include "matrices.h" Solver::Solver(){ diff --git a/lib/poems/solver.h b/lib/poems/solver.h index 489e6d41f1..45564dd1ef 100644 --- a/lib/poems/solver.h +++ b/lib/poems/solver.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: solver.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,29 +11,28 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef SOLVER_H #define SOLVER_H - +#include #include "colmatmap.h" +#include "matrices.h" #include "defines.h" -namespace POEMS { class System; -class Matrix; class Solver{ protected: System* system; - + double time; ColMatMap state; ColMatMap statedot; - ColMatMap statedoubledot; + ColMatMap statedoubledot; SolverType type; @@ -48,13 +47,13 @@ public: virtual void DeleteModel() = 0; virtual void CreateModel() = 0; - virtual void Solve(double time, Matrix& FF) = 0; - - - + virtual void Solve(double time, Matrix& FF) = 0; + + + ColMatMap* GetState(); ColMatMap* GetStateDerivative(); ColMatMap* GetStateDerivativeDerivative(); }; -} + #endif diff --git a/lib/poems/sphericaljoint.cpp b/lib/poems/sphericaljoint.cpp index 996bb5a887..fb5330db17 100644 --- a/lib/poems/sphericaljoint.cpp +++ b/lib/poems/sphericaljoint.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: sphericaljoint.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,27 +11,21 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #include "sphericaljoint.h" - -#include - #include "point.h" #include "matrixfun.h" #include "body.h" #include "fastmatrixops.h" +#include "norm.h" #include "eulerparameters.h" -#include "colmatrix.h" -#include "mat3x3.h" -#include "vect3.h" -#include "virtualmatrix.h" +#include "matrices.h" +#include -using namespace std; -using namespace POEMS; SphericalJoint::SphericalJoint(){ DimQandU(4,3); @@ -50,24 +44,24 @@ bool SphericalJoint::ReadInJointData(std::istream& in){ void SphericalJoint::WriteOutJointData(std::ostream& out){ } -Matrix SphericalJoint::GetForward_sP(){ +Matrix SphericalJoint::GetForward_sP(){ Mat3x3 sPa,sPl; Matrix sP(6,3); - sPa.Identity(); + sPa.Identity(); sPl.Zeros(); - Vect3 temp = -(point2->position); - + Vect3 temp = -(point2->position); + sPl(1,2) = temp(3); sPl(1,3) = -temp(2); - + sPl(2,1) = -temp(3); sPl(2,3) = temp(1); - - sPl(3,1) = temp(2); + + sPl(3,1) = temp(2); sPl(3,2) = -temp(1); - - sP=Stack(sPa,sPl); - return sP; + + sP=Stack(sPa,sPl); + return sP; } void SphericalJoint::UpdateForward_sP( Matrix& sP){ @@ -81,15 +75,15 @@ Matrix SphericalJoint::GetBackward_sP(){ cout<<" -----------"<position(1)); - sPl(2,3)=-(point2->position(1)); + sPa.Identity(); + sPl.Zeros(); + sPl(3,2)=(point2->position(1)); + sPl(2,3)=-(point2->position(1)); sP=Stack(sPa,sPl); - return sP; + return sP; } -void SphericalJoint::UpdateBackward_sP( Matrix& sP){ +void SphericalJoint::UpdateBackward_sP( Matrix& sP){ // sP is constant, do nothing. } @@ -98,106 +92,106 @@ void SphericalJoint::ComputeLocalTransform(){ // Obtain the transformation matrix from euler parameters EP_Transformation(q, ko_C_k); FastMult(pk_C_ko,ko_C_k,pk_C_k); - } + } void SphericalJoint::ForwardKinematics(){ Vect3 result1,result2,result3,result4,result5; Vect3 pk_w_k; - + //cout<<"Check in spherical "<position,result1); // parents basis - FastAdd(result1,point1->position,r12); - - // compute position vector r21 - FastNegMult(k_C_pk,r12,r21); - - + // COMPUTE POSITION VECTOR R12 aka GAMMA + + FastNegMult(pk_C_k,point2->position,result1); // parents basis + FastAdd(result1,point1->position,r12); + + // compute position vector r21 + FastNegMult(k_C_pk,r12,r21); + + //----------------------------------// - // COMPUTE GLOBAL LOCATION - FastMult(body1->n_C_k,(body1->GetPoint(2))->position,result1); - FastAdd(result1,body1->r,result1); - FastNegMult(body2->n_C_k,(body2->GetPoint(1))->position,result2); - FastAdd(result1,result2,body2->r); - - qdot_to_u(q, u, qdot); - - - //----------------------------------- - // angular velocities + // COMPUTE GLOBAL LOCATION + FastMult(body1->n_C_k,(body1->GetPoint(2))->position,result1); + FastAdd(result1,body1->r,result1); + FastNegMult(body2->n_C_k,(body2->GetPoint(1))->position,result2); + FastAdd(result1,result2,body2->r); + + qdot_to_u(q, u, qdot); + + //----------------------------------- + // angular velocities + FastAssign(u,pk_w_k); - FastTMult(pk_C_k,body1->omega_k,result1); + FastTMult(pk_C_k,body1->omega_k,result1); FastAdd(result1,pk_w_k,body2->omega_k); - FastMult(body2->n_C_k,body2->omega_k,body2->omega); + FastMult(body2->n_C_k,body2->omega_k,body2->omega); - - - //----------------------------------- - - // compute velocities - FastCross(body1->omega_k,(body1->GetPoint(2))->position,result1); + + + //----------------------------------- + + // compute velocities + FastCross(body1->omega_k,(body1->GetPoint(2))->position,result1); FastAdd(body1->v_k,result1,result2); - FastTMult(pk_C_k,result2,result1); // In body basis - - FastCross((body2->GetPoint(1))->position,body2->omega_k,result2); - FastAdd(result1,result2,body2->v_k); // In body basis - FastMult(body2->n_C_k,body2->v_k,body2->v); - - + FastTMult(pk_C_k,result2,result1); // In body basis + + FastCross((body2->GetPoint(1))->position,body2->omega_k,result2); + FastAdd(result1,result2,body2->v_k); // In body basis + FastMult(body2->n_C_k,body2->v_k,body2->v); + + //------------------------------------------ - //Compute the KE + //Compute the KE Matrix tempke; - tempke = T(body2->v)*(body2->v); + tempke = T(body2->v)*(body2->v); double ke = 0.0; - ke = body2->mass*tempke(1,1); + ke = body2->mass*tempke(1,1); FastMult(body2->inertia,body2->omega_k,result1); - tempke= T(body2->omega_k)*result1; + tempke= T(body2->omega_k)*result1; ke = 0.5*ke + 0.5*tempke(1,1); body2->KE=ke; - //----------------------------------- - // compute state explicit angular acceleration // Has to be in body basis - FastTMult(pk_C_k,body1->alpha_t,result2); + //----------------------------------- + // compute state explicit angular acceleration // Has to be in body basis + FastTMult(pk_C_k,body1->alpha_t,result2); FastCross(body2->omega_k,pk_w_k,result1); - FastAdd(result1,result2,body2->alpha_t); - - //----------------------------------- - // compute state explicit acceleration - // NEED TO DO THIS COMPLETELY IN BODY BASIS - + FastAdd(result1,result2,body2->alpha_t); + + //----------------------------------- + // compute state explicit acceleration + // NEED TO DO THIS COMPLETELY IN BODY BASIS + FastCross(body1->omega_k,(body1->GetPoint(2))->position,result1); - FastCross(body1->omega_k,result1,result2); - FastTMult(pk_C_k,result2,result1); - - //FastCross(body2->omega_k,-(body2->GetPoint(1))->position,result3); - FastCross((body2->GetPoint(1))->position,body2->omega_k,result3); - FastCross(body2->omega_k,result3,result2); - FastAdd(result1,result2,result3); //wxwxr in body basis - - FastCross(body1->alpha_t,(body1->GetPoint(2))->position,result4); - FastTMult(pk_C_k,result4,result5); + FastCross(body1->omega_k,result1,result2); + FastTMult(pk_C_k,result2,result1); + + //FastCross(body2->omega_k,-(body2->GetPoint(1))->position,result3); + FastCross((body2->GetPoint(1))->position,body2->omega_k,result3); + FastCross(body2->omega_k,result3,result2); + FastAdd(result1,result2,result3); //wxwxr in body basis + + FastCross(body1->alpha_t,(body1->GetPoint(2))->position,result4); + FastTMult(pk_C_k,result4,result5); FastAssign(result5,result4); - - FastCross((body2->GetPoint(1))->position,body2->alpha_t,result2); - FastAdd(result2,result4,result1); //alphaxr in body basis - + + FastCross((body2->GetPoint(1))->position,body2->alpha_t,result2); + FastAdd(result2,result4,result1); //alphaxr in body basis + FastTMult(pk_C_k,body1->a_t,result2); - FastTripleSum(result3,result1,result2,body2->a_t); // in body basis - - - //----------------------------------- + FastTripleSum(result3,result1,result2,body2->a_t); // in body basis + + + //----------------------------------- } // NOTE: NOT USING BACKWARDKINEMATICS AT PRESENT @@ -208,13 +202,13 @@ void SphericalJoint::BackwardKinematics(){ // orientations ComputeBackwardTransforms(); - + // compute position vector r21 //r21 = point2->position - k_C_pk * point1->position; FastMult(k_C_pk,point1->position,result1); FastSubt(point2->position,result1,r21); - + // compute position vector r21 FastNegMult(pk_C_k,r21,r12); @@ -233,7 +227,7 @@ void SphericalJoint::BackwardKinematics(){ EP_Derivatives(q,u,qdot); // angular velocities - + FastMult(body2->n_C_k,u,result2); FastAdd(body2->omega,result2,body1->omega); FastAssign(u,k_w_pk); @@ -253,7 +247,7 @@ void SphericalJoint::BackwardKinematics(){ FastCross(body1->omega_k,k_w_pk,result1); FastMult(pk_C_k,body2->alpha_t,result2); FastAdd(result1,result2,body1->alpha_t); - + // compute state explicit acceleration FastCross(body2->alpha_t,point2->position,result1); FastCross(body2->omega_k,point2->position,result2); @@ -266,5 +260,5 @@ void SphericalJoint::BackwardKinematics(){ FastCross(body1->omega_k,result2,result3); FastTripleSum(result5,result1,result3,body1->a_t); - + } diff --git a/lib/poems/sphericaljoint.h b/lib/poems/sphericaljoint.h index db048e5544..ef29f8e38e 100644 --- a/lib/poems/sphericaljoint.h +++ b/lib/poems/sphericaljoint.h @@ -18,11 +18,12 @@ #ifndef SPHERICALJOINT_H #define SPHERICALJOINT_H -#include #include "joint.h" -#include "matrix.h" +#include "vect3.h" +#include "mat3x3.h" + + -namespace POEMS { class SphericalJoint : public Joint { Matrix const_sP; public: @@ -39,5 +40,5 @@ public: void ForwardKinematics(); void BackwardKinematics(); }; -} + #endif diff --git a/lib/poems/system.cpp b/lib/poems/system.cpp index 8515588424..369213f7d0 100644 --- a/lib/poems/system.cpp +++ b/lib/poems/system.cpp @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: system.cpp * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,37 +11,19 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #include "system.h" - -#include -#include - #include "body.h" #include "joint.h" -#include "colmatrix.h" -#include "eulerparameters.h" -#include "fixedpoint.h" -#include "freebodyjoint.h" -#include "inertialframe.h" -#include "mat3x3.h" -#include "matrix.h" -#include "matrixfun.h" -#include "rigidbody.h" -#include "sphericaljoint.h" -#include "vect3.h" -#include "virtualmatrix.h" +#include -namespace POEMS { class Point; } -using namespace std; -using namespace POEMS; System::System(){ - mappings = NULL; + mappings = NULL; } System::~System(){ @@ -60,7 +42,7 @@ int System::GetNumBodies(){ int * System::GetMappings() { - return mappings; + return mappings; } void System::AddBody(Body* body){ @@ -79,16 +61,16 @@ double System::GetTime(){ return time; } -void System::ComputeForces(){ - // NOT DOING ANYTHING AT THIS TIME - } - +void System::ComputeForces(){ + // NOT DOING ANYTHING AT THIS TIME + } + bool System::ReadIn(istream& in){ int numbodies; Body* body; int bodytype; char bodyname[256]; - int index; + int index; // get number of bodies in >> numbodies; @@ -166,12 +148,12 @@ bool System::ReadIn(istream& in){ delete [] bodyarray; return false; } - + joint->SetBodies(bodyarray[body1], bodyarray[body2]); bodyarray[body1]->AddJoint(joint); bodyarray[body2]->AddJoint(joint); - + in >> point1 >> point2; joint->SetPoints(bodyarray[body1]->GetPoint(point1),bodyarray[body2]->GetPoint(point2)); @@ -204,7 +186,7 @@ void System::WriteOut(ostream& out){ // set the body ID for later identification body->SetID(i); - + // write out the data body->WriteOut(out); @@ -212,7 +194,7 @@ void System::WriteOut(ostream& out){ } // number of joints - out << joints.GetNumElements() << endl; + out << joints.GetNumElements() << endl; // joints loop i = 0; @@ -227,7 +209,7 @@ void System::WriteOut(ostream& out){ // write out the data joint->WriteOut(out); - + i++; j_ele = j_ele->next; } } @@ -253,68 +235,68 @@ void System::ClearJointIDs(){ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space){ - //-------------------------------------------------------------------------// - // Declaring Temporary Entities - //-------------------------------------------------------------------------// + //-------------------------------------------------------------------------// + // Declaring Temporary Entities + //-------------------------------------------------------------------------// Body* body = NULL; Body* prev; Body* Inertial; Point* origin; Joint* joint; - Point* point_CM; - Point* point_p; - Point* point_k; + Point* point_CM; + Point* point_p; + Point* point_k; Point* point_ch = NULL; - Vect3 r1,r2,r3,v1,v2,v3; + Vect3 r1,r2,r3,v1,v2,v3; Mat3x3 IM, N, PKCK,PKCN ; ColMatrix qo, uo, q, qdot,w; - - mappings = new int[nfree]; - for(int i = 0; i < nfree; i++) - { - mappings[i] = freelist[i]; - } + + mappings = new int[nfree]; + for(int i = 0; i < nfree; i++) + { + mappings[i] = freelist[i]; + } qo.Dim(4); uo.Dim(3); q.Dim(4); - qdot.Dim(4); + qdot.Dim(4); PKCN.Identity(); PKCK.Identity(); w.Dim(3); - -//-------------------------------------------------------------------------// - // Setting up Inertial Frame, gravity and Origin + +//-------------------------------------------------------------------------// + // Setting up Inertial Frame, gravity and Origin //-------------------------------------------------------------------------// - Inertial= new InertialFrame; + Inertial= new InertialFrame; AddBody(Inertial); - - Vect3 temp1; - temp1.Zeros(); - ((InertialFrame*) Inertial)->SetGravity(temp1); + + Vect3 temp1; + temp1.Zeros(); + ((InertialFrame*) Inertial)->SetGravity(temp1); origin= new FixedPoint(temp1); - Inertial->AddPoint(origin); -//-------------------------------------------------------------------------// - double ** xh1 = new double*[nfree]; - double ** xh2 = new double*[nfree]; - - for (int i=0; iAddPoint(origin); //-------------------------------------------------------------------------// + double ** xh1 = new double*[nfree]; + double ** xh2 = new double*[nfree]; + + for (int i=0; imass=masstotal[mappings[i]-1]; IM(1,1)=inertia[mappings[i]-1][0]; IM(2,2)=inertia[mappings[i]-1][1]; @@ -325,49 +307,49 @@ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstota IM(2,1)=IM(1,2); IM(3,1)=IM(1,3); IM(3,2)=IM(2,3); - body->inertia = IM; - -//-------------------------------------------------------// - - - for (int k=0;k<3;k++){ - r1(k+1)=xh1[i][k]-xcm[mappings[i]-1][k]; - r3(k+1) = xcm[mappings[i]-1][k]; - r3(k+1)=xh2[i][k]-xcm[mappings[i]-1][k]; - } - - r2.Zeros(); - - for (int k=1;k<=3;k++){ - N(k,1)=ex_space[mappings[i]-1][k-1]; - N(k,2)=ey_space[mappings[i]-1][k-1]; - N(k,3)=ez_space[mappings[i]-1][k-1]; - } + body->inertia = IM; +//-------------------------------------------------------// + + + for (int k=0;k<3;k++){ + r1(k+1)=xh1[i][k]-xcm[mappings[i]-1][k]; + r3(k+1) = xcm[mappings[i]-1][k]; + r3(k+1)=xh2[i][k]-xcm[mappings[i]-1][k]; + } + + r2.Zeros(); + + for (int k=1;k<=3;k++){ + N(k,1)=ex_space[mappings[i]-1][k-1]; + N(k,2)=ey_space[mappings[i]-1][k-1]; + N(k,3)=ez_space[mappings[i]-1][k-1]; + } + PKCK=T(N); PKCN=T(N); - - q.Zeros(); + + q.Zeros(); EP_FromTransformation(q,N); - + r1=PKCN*r1; r3=PKCN*r3; - + for (int k=1;k<=3;k++){ - w(k)=omega[mappings[i]-1][k-1]; - } - + w(k)=omega[mappings[i]-1][k-1]; + } + Vect3 cart_r, cart_v; for (int k=1;k<=3;k++){ - cart_r(k)=xcm[mappings[i]-1][k-1]; - cart_v(k)=vcm[mappings[i]-1][k-1]; - } - - w=PKCN*w; - EP_Derivatives(q,w,qdot); - - -//-------------------------------------------------------------------------// + cart_r(k)=xcm[mappings[i]-1][k-1]; + cart_v(k)=vcm[mappings[i]-1][k-1]; + } + + w=PKCN*w; + EP_Derivatives(q,w,qdot); + + +//-------------------------------------------------------------------------// // Create bodies and joints with associated properties for POEMS //-------------------------------------------------------------------------// @@ -377,12 +359,12 @@ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstota body->AddPoint(point_CM); body->AddPoint(point_k); body->AddPoint(point_ch); - AddBody(body); - + AddBody(body); + Mat3x3 One; - One.Identity(); - ColMatrix qq=Stack(q,cart_r); - ColMatrix vv=Stack(qdot,cart_v); + One.Identity(); + ColMatrix qq=Stack(q,cart_r); + ColMatrix vv=Stack(qdot,cart_v); joint=new FreeBodyJoint; AddJoint(joint); joint->SetBodies(prev,body); @@ -392,225 +374,225 @@ void System::Create_DegenerateSystem(int& nfree, int*freelist, double *&masstota joint->SetZeroOrientation(One); joint->DimQandU(7,6); joint->SetInitialState(qq,vv); - joint->ForwardKinematics(); + joint->ForwardKinematics(); } for(int i = 0; i < nfree; i++) { - delete [] xh1[i]; - delete [] xh2[i]; + delete [] xh1[i]; + delete [] xh2[i]; } delete [] xh1; - delete [] xh2; + delete [] xh2; } void System::Create_System_LAMMPS(int numbodies, double *mass,double **inertia, double ** xcm, double ** xjoint,double **vcm,double **omega,double **ex_space, double **ey_space, double **ez_space, int b, int * mapping, int count){ - //-------------------------------------------------------------------------// - // Declaring Temporary Entities - //-------------------------------------------------------------------------// + //-------------------------------------------------------------------------// + // Declaring Temporary Entities + //-------------------------------------------------------------------------// + + Body* body = NULL; + Body* prev; + Body* Inertial; + Point* origin; + Joint* joint; + Point* point_CM; + Point* point_p; + Point* point_k; + Point* point_ch = NULL; + Vect3 r1,r2,r3,v1,v2,v3; + Mat3x3 IM, N, PKCK,PKCN ; + ColMatrix qo, uo, q, qdot,w; + Vect3 cart_r, cart_v; + mappings = new int[b]; + for(int i = 0; i < b; i++){ + mappings[i] = mapping[i]; + } + + + qo.Dim(4); + uo.Dim(3); + q.Dim(4); + qdot.Dim(4); + PKCN.Identity(); + PKCK.Identity(); + w.Dim(3); + + //-------------------------------------------------------------------------// + // Setting up Inertial Frame, gravity and Origin + //-------------------------------------------------------------------------// + Inertial= new InertialFrame; + AddBody(Inertial); + + Vect3 temp1; + temp1.Zeros(); + ((InertialFrame*) Inertial)->SetGravity(temp1); + origin= new FixedPoint(temp1); + Inertial->AddPoint(origin); + //-------------------------------------------------------------------------// - Body* body = NULL; - Body* prev; - Body* Inertial; - Point* origin; - Joint* joint; - Point* point_CM; - Point* point_p; - Point* point_k; - Point* point_ch = NULL; - Vect3 r1,r2,r3,v1,v2,v3; - Mat3x3 IM, N, PKCK,PKCN ; - ColMatrix qo, uo, q, qdot,w; - Vect3 cart_r, cart_v; - mappings = new int[b]; - for(int i = 0; i < b; i++){ - mappings[i] = mapping[i]; - } + double ** xh1; + double ** xh2; + + xh1 = new double*[b]; + xh2 = new double*[b]; + + + for (int i=0; iSetGravity(temp1); - origin= new FixedPoint(temp1); - Inertial->AddPoint(origin); - //-------------------------------------------------------------------------// - - double ** xh1; - double ** xh2; - - xh1 = new double*[b]; - xh2 = new double*[b]; - - - for (int i=0; imass=mass[mapping[i]-1]; - IM(1,1)=inertia[mapping[i]-1][0]; - IM(2,2)=inertia[mapping[i]-1][1]; - IM(3,3)=inertia[mapping[i]-1][2]; - IM(1,2)=0.0; - IM(1,3)=0.0; - IM(2,3)=0.0; - IM(2,1)=IM(1,2); - IM(3,1)=IM(1,3); - IM(3,2)=IM(2,3); - body->inertia = IM; - - //-------------------------------------------------------// - - for (int k=0;k<3;k++){ - r1(k+1)=xh1[i][k]-xcm[mapping[i]-1][k]; - r3(k+1)=xh2[i][k]-xcm[mapping[i]-1][k]; - } - r2.Zeros(); - - for (int k=1;k<=3;k++){ - N(k,1)=ex_space[mapping[i]-1][k-1]; - N(k,2)=ey_space[mapping[i]-1][k-1]; - N(k,3)=ez_space[mapping[i]-1][k-1]; - } - - - if (i==0){ - PKCK=T(N); - PKCN=T(N); - - q.Zeros(); - EP_FromTransformation(q,N); - - r1=PKCN*r1; - r3=PKCN*r3; - - for (int k=1;k<=3;k++){ - w(k)=omega[mappings[i]-1][k-1]; - } - - for (int k=1;k<=3;k++){ - cart_r(k)=xcm[mappings[i]-1][k-1]; - cart_v(k)=vcm[mappings[i]-1][k-1]; - } - w=PKCN*w; - EP_Derivatives(q,w,qdot); - - } - else{ - PKCK=PKCN*N; - PKCN=T(N); - - q.Zeros(); - EP_FromTransformation(q,PKCK); - - r1=PKCN*r1; - r3=PKCN*r3; - - for (int k=1;k<=3;k++){ - w(k)=omega[mapping[i]-1][k-1]-omega[mapping[i-1]-1][k-1]; - } - - w=PKCN*w; - EP_Derivatives(q, w, qdot); - } - - - //-------------------------------------------------------------------------// + //-------------------------------------------------------------------------// + for(int i=0;imass=mass[mapping[i]-1]; + IM(1,1)=inertia[mapping[i]-1][0]; + IM(2,2)=inertia[mapping[i]-1][1]; + IM(3,3)=inertia[mapping[i]-1][2]; + IM(1,2)=0.0; + IM(1,3)=0.0; + IM(2,3)=0.0; + IM(2,1)=IM(1,2); + IM(3,1)=IM(1,3); + IM(3,2)=IM(2,3); + body->inertia = IM; + + //-------------------------------------------------------// + + for (int k=0;k<3;k++){ + r1(k+1)=xh1[i][k]-xcm[mapping[i]-1][k]; + r3(k+1)=xh2[i][k]-xcm[mapping[i]-1][k]; + } + r2.Zeros(); + + for (int k=1;k<=3;k++){ + N(k,1)=ex_space[mapping[i]-1][k-1]; + N(k,2)=ey_space[mapping[i]-1][k-1]; + N(k,3)=ez_space[mapping[i]-1][k-1]; + } + + + if (i==0){ + PKCK=T(N); + PKCN=T(N); + + q.Zeros(); + EP_FromTransformation(q,N); + + r1=PKCN*r1; + r3=PKCN*r3; + + for (int k=1;k<=3;k++){ + w(k)=omega[mappings[i]-1][k-1]; + } + + for (int k=1;k<=3;k++){ + cart_r(k)=xcm[mappings[i]-1][k-1]; + cart_v(k)=vcm[mappings[i]-1][k-1]; + } + w=PKCN*w; + EP_Derivatives(q,w,qdot); + + } + else{ + PKCK=PKCN*N; + PKCN=T(N); + + q.Zeros(); + EP_FromTransformation(q,PKCK); + + r1=PKCN*r1; + r3=PKCN*r3; + + for (int k=1;k<=3;k++){ + w(k)=omega[mapping[i]-1][k-1]-omega[mapping[i-1]-1][k-1]; + } + + w=PKCN*w; + EP_Derivatives(q, w, qdot); + } + + + //-------------------------------------------------------------------------// // Create bodies and joints with associated properties for POEMS - //-------------------------------------------------------------------------// - - point_CM = new FixedPoint(r2); - point_k = new FixedPoint(r1); - point_ch = new FixedPoint(r3); - body->AddPoint(point_CM); - body->AddPoint(point_k); - body->AddPoint(point_ch); - AddBody(body); - - Mat3x3 One; - One.Identity(); - if (i==0){ - ColMatrix qq=Stack(q,cart_r); - ColMatrix vv=Stack(qdot,cart_v); - joint=new FreeBodyJoint; - AddJoint(joint); - joint->SetBodies(prev,body); - body->AddJoint(joint); - prev->AddJoint(joint); - joint->SetPoints(point_p,point_k); - joint->SetZeroOrientation(One); - joint->DimQandU(7,6); - joint->SetInitialState(qq,vv); - joint->ForwardKinematics(); - } - else{ - joint= new SphericalJoint; - AddJoint(joint); - joint->SetBodies(prev,body); - body->AddJoint(joint); - prev->AddJoint(joint); - joint->SetPoints(point_p,point_k); - joint->SetZeroOrientation(One); - joint->DimQandU(4,3); - joint->SetInitialState(q,qdot); - joint->ForwardKinematics(); - } - } - for(int i = 0; i < b; i++) - { - delete [] xh1[i]; - delete [] xh2[i]; - } - delete [] xh1; - delete [] xh2; + //-------------------------------------------------------------------------// + point_CM = new FixedPoint(r2); + point_k = new FixedPoint(r1); + point_ch = new FixedPoint(r3); + body->AddPoint(point_CM); + body->AddPoint(point_k); + body->AddPoint(point_ch); + AddBody(body); + + Mat3x3 One; + One.Identity(); + if (i==0){ + ColMatrix qq=Stack(q,cart_r); + ColMatrix vv=Stack(qdot,cart_v); + joint=new FreeBodyJoint; + AddJoint(joint); + joint->SetBodies(prev,body); + body->AddJoint(joint); + prev->AddJoint(joint); + joint->SetPoints(point_p,point_k); + joint->SetZeroOrientation(One); + joint->DimQandU(7,6); + joint->SetInitialState(qq,vv); + joint->ForwardKinematics(); + } + else{ + joint= new SphericalJoint; + AddJoint(joint); + joint->SetBodies(prev,body); + body->AddJoint(joint); + prev->AddJoint(joint); + joint->SetPoints(point_p,point_k); + joint->SetZeroOrientation(One); + joint->DimQandU(4,3); + joint->SetInitialState(q,qdot); + joint->ForwardKinematics(); + } + } + for(int i = 0; i < b; i++) + { + delete [] xh1[i]; + delete [] xh2[i]; + } + delete [] xh1; + delete [] xh2; + } diff --git a/lib/poems/system.h b/lib/poems/system.h index 2402e5852f..1b59395de7 100644 --- a/lib/poems/system.h +++ b/lib/poems/system.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: system.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,18 +11,40 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - + #ifndef SYSTEM_H #define SYSTEM_H -#include -#include "poemslist.h" -namespace POEMS { +#include +#include +#include +#include +#include + +#include "poemslist.h" +#include "matrices.h" +#include "workspace.h" +#include "matrixfun.h" +#include "onsolver.h" +#include "system.h" +#include "inertialframe.h" +#include "rigidbody.h" +#include "revolutejoint.h" +#include "fixedpoint.h" +#include "freebodyjoint.h" +#include "sphericaljoint.h" +#include "body23joint.h" +#include "mixedjoint.h" +#include "eulerparameters.h" +#include "matrices.h" +#include "norm.h" + + class Body; class Joint; @@ -34,37 +56,37 @@ namespace POEMS { double time; List bodies; List joints; - + System(); ~System(); void Delete(); - + int GetNumBodies(); - + int * GetMappings(); void AddBody(Body* body); - + void AddJoint(Joint* joint); - + void SetTime(double t); - + double GetTime(); - + void ComputeForces(); - + bool ReadIn(std::istream& in); - + void WriteOut(std::ostream& out); - + void ClearBodyIDs(); - - void ClearJointIDs(); + + void ClearJointIDs(); void Create_System_LAMMPS(int numbodies, double *mass,double **inertia, double ** xcm, double ** xjoint,double **vh1,double **omega,double **ex_space, double **ey_space, double **ez_space, int b, int * mapping, int count); - + void Create_DegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space); }; -} + #endif diff --git a/lib/poems/vect3.cpp b/lib/poems/vect3.cpp index 66c2f902d5..03c5d7bc00 100644 --- a/lib/poems/vect3.cpp +++ b/lib/poems/vect3.cpp @@ -16,13 +16,9 @@ *_________________________________________________________________________*/ #include "vect3.h" - #include -#include using namespace std; -using namespace POEMS; - Vect3::Vect3(){ numrows = 3; numcols = 1; @@ -145,13 +141,6 @@ Vect3& Vect3::operator+=(const Vect3& A){ return *this; } -Vect3& Vect3::operator-(){ - elements[0] = -elements[0]; - elements[1] = -elements[1]; - elements[2] = -elements[2]; - return *this; -} - Vect3& Vect3::operator-=(const Vect3& A){ elements[0] -= A.elements[0]; elements[1] -= A.elements[1]; diff --git a/lib/poems/vect3.h b/lib/poems/vect3.h index 6b0efc371a..ababe18e51 100644 --- a/lib/poems/vect3.h +++ b/lib/poems/vect3.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: vect3.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,19 +11,15 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef VECT3_H #define VECT3_H -#include - #include "virtualcolmatrix.h" -#include "virtualmatrix.h" -namespace POEMS { class Matrix; class Mat3x3; class Mat6x6; @@ -56,7 +52,6 @@ public: Vect3& operator*=(double b); Vect3& operator+=(const Vect3& A); Vect3& operator-=(const Vect3& A); - Vect3& operator-(); friend Matrix T(const Vect3& A); // a wasteful transpose friend Mat3x3 CrossMat(Vect3& a); // a wasteful cross matrix implementation @@ -83,6 +78,7 @@ public: friend void FastMult(Mat3x3& A, ColMatrix& B, Vect3& C); friend void FastAssign(ColMatrix&A, Vect3& C); friend void FastMult(Mat3x3& A, Vect3& B, ColMatrix& C); + }; -} + #endif diff --git a/lib/poems/vect4.cpp b/lib/poems/vect4.cpp index 8e903d57bd..3b5afddc50 100644 --- a/lib/poems/vect4.cpp +++ b/lib/poems/vect4.cpp @@ -16,13 +16,9 @@ *_________________________________________________________________________*/ #include "vect4.h" - #include -#include using namespace std; -using namespace POEMS; - Vect4::Vect4(){ numrows = 4; numcols = 1; diff --git a/lib/poems/vect4.h b/lib/poems/vect4.h index 754706f10a..695f5e158a 100644 --- a/lib/poems/vect4.h +++ b/lib/poems/vect4.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: vect4.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,19 +11,16 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ #ifndef VECT4_H #define VECT4_H -#include - #include "virtualcolmatrix.h" -#include "virtualmatrix.h" -namespace POEMS { + class Matrix; class Mat4x4; @@ -42,7 +39,7 @@ public: void BasicSet_1int(int i, double value); void BasicIncrement_1int(int i, double value); - + void Const(double value); MatrixType GetType() const; std::ostream& WriteData(std::ostream& c) const; @@ -70,5 +67,5 @@ public: friend void FastAdd(Vect4& A, Vect4& B, Vect4& C); friend void FastSubt(Vect4& A, Vect4& B, Vect4& C); }; -} + #endif diff --git a/lib/poems/vect6.cpp b/lib/poems/vect6.cpp index 5aabe520e1..eb65d24f16 100644 --- a/lib/poems/vect6.cpp +++ b/lib/poems/vect6.cpp @@ -16,13 +16,9 @@ *_________________________________________________________________________*/ #include "vect6.h" - #include -#include using namespace std; -using namespace POEMS; - Vect6::Vect6(){ numrows = 6; numcols = 1; diff --git a/lib/poems/vect6.h b/lib/poems/vect6.h index 5def4c6b1b..c346c852ef 100644 --- a/lib/poems/vect6.h +++ b/lib/poems/vect6.h @@ -18,12 +18,8 @@ #ifndef VECT6_H #define VECT6_H -#include - #include "virtualcolmatrix.h" -#include "virtualmatrix.h" -namespace POEMS { class Matrix; class Mat6x6; class ColMatrix; @@ -70,5 +66,5 @@ public: friend void OnPopulateSVect(Vect3& angular, Vect3& linear, Vect6& sV); }; -} + #endif diff --git a/lib/poems/virtualcolmatrix.cpp b/lib/poems/virtualcolmatrix.cpp index fa430b81f7..3a6c6e22cd 100644 --- a/lib/poems/virtualcolmatrix.cpp +++ b/lib/poems/virtualcolmatrix.cpp @@ -20,8 +20,6 @@ #include using namespace std; -using namespace POEMS; - VirtualColMatrix::VirtualColMatrix(){ numcols = 1; diff --git a/lib/poems/virtualcolmatrix.h b/lib/poems/virtualcolmatrix.h index 040fce051e..1548794ca0 100644 --- a/lib/poems/virtualcolmatrix.h +++ b/lib/poems/virtualcolmatrix.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: virtualcolmatrix.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,25 +21,25 @@ #include "virtualmatrix.h" -namespace POEMS { -class VirtualColMatrix : public VirtualMatrix { -public: - VirtualColMatrix(); - ~VirtualColMatrix(); - double& operator_2int (int i, int j); // array access - double Get_2int (int i, int j) const; - void Set_2int (int i, int j, double value); - double BasicGet_2int(int i, int j) const; - void BasicSet_2int(int i, int j, double value); - void BasicIncrement_2int(int i, int j, double value); - virtual double& operator_1int (int i) = 0; // array access - virtual double Get_1int(int i) const = 0; - virtual void Set_1int(int i, double value) = 0; - virtual double BasicGet_1int(int i) const = 0; - virtual void BasicSet_1int(int i, double value) = 0; - virtual void BasicIncrement_1int(int i, double value) = 0; +class VirtualColMatrix : public VirtualMatrix { +public: + VirtualColMatrix(); + ~VirtualColMatrix(); + double& operator_2int (int i, int j); // array access + double Get_2int (int i, int j) const; + void Set_2int (int i, int j, double value); + double BasicGet_2int(int i, int j) const; + void BasicSet_2int(int i, int j, double value); + void BasicIncrement_2int(int i, int j, double value); + + virtual double& operator_1int (int i) = 0; // array access + virtual double Get_1int(int i) const = 0; + virtual void Set_1int(int i, double value) = 0; + virtual double BasicGet_1int(int i) const = 0; + virtual void BasicSet_1int(int i, double value) = 0; + virtual void BasicIncrement_1int(int i, double value) = 0; }; -} + #endif diff --git a/lib/poems/virtualmatrix.cpp b/lib/poems/virtualmatrix.cpp index bfffeb3d74..19d5946961 100644 --- a/lib/poems/virtualmatrix.cpp +++ b/lib/poems/virtualmatrix.cpp @@ -21,8 +21,6 @@ #include using namespace std; -using namespace POEMS; - VirtualMatrix::VirtualMatrix(){ numrows = numcols = 0; @@ -142,14 +140,14 @@ istream& VirtualMatrix::ReadData(istream& c){ // operators and functions // -ostream& POEMS::operator<< (ostream& c, const VirtualMatrix& A){ //output +ostream& operator<< (ostream& c, const VirtualMatrix& A){ //output c << A.GetType() << ' '; A.WriteData(c); c << endl; return c; } -istream& POEMS::operator>> (istream& c, VirtualMatrix& A){ //input +istream& operator>> (istream& c, VirtualMatrix& A){ //input VirtualMatrix* vm; int matrixtype; c >> matrixtype; diff --git a/lib/poems/virtualmatrix.h b/lib/poems/virtualmatrix.h index 706b943d66..a27c7de047 100644 --- a/lib/poems/virtualmatrix.h +++ b/lib/poems/virtualmatrix.h @@ -20,7 +20,6 @@ #define VIRTUALMATRIX_H #include -namespace POEMS { enum MatrixType { MATRIX = 0, COLMATRIX = 1, @@ -84,5 +83,5 @@ protected: // overloaded operators std::ostream& operator<< (std::ostream& c, const VirtualMatrix& A); // output std::istream& operator>> (std::istream& c, VirtualMatrix& A); // input -} + #endif diff --git a/lib/poems/virtualrowmatrix.cpp b/lib/poems/virtualrowmatrix.cpp index 740c747407..1a12cfbfd9 100644 --- a/lib/poems/virtualrowmatrix.cpp +++ b/lib/poems/virtualrowmatrix.cpp @@ -21,8 +21,6 @@ #include using namespace std; -using namespace POEMS; - VirtualRowMatrix::VirtualRowMatrix(){ numrows = 1; diff --git a/lib/poems/virtualrowmatrix.h b/lib/poems/virtualrowmatrix.h index 0a3c877f64..68b39f137d 100644 --- a/lib/poems/virtualrowmatrix.h +++ b/lib/poems/virtualrowmatrix.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: virtualrowmatrix.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -21,9 +21,8 @@ #include "virtualmatrix.h" -namespace POEMS { class VirtualRowMatrix : public VirtualMatrix { -public: +public: VirtualRowMatrix(); ~VirtualRowMatrix(); double& operator_2int (int i, int j); // array access @@ -32,7 +31,7 @@ public: double BasicGet_2int(int i, int j) const; void BasicSet_2int(int i, int j, double value); void BasicIncrement_2int(int i, int j, double value); - + virtual double& operator_1int (int i) = 0; // array access virtual double Get_1int(int i) const = 0; virtual void Set_1int(int i, double value) = 0; @@ -40,5 +39,5 @@ public: virtual void BasicSet_1int(int i, double value) = 0; virtual void BasicIncrement_1int(int i, double value) = 0; }; -} + #endif diff --git a/lib/poems/workspace.cpp b/lib/poems/workspace.cpp index 03f18a7895..2b3257b0dd 100644 --- a/lib/poems/workspace.cpp +++ b/lib/poems/workspace.cpp @@ -15,31 +15,18 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ -#include -#include // IWYU pragma: keep -#include #include "workspace.h" #include "system.h" #include "solver.h" #include "SystemProcessor.h" -#include "POEMSChain.h" -#include "body.h" -#include "colmatmap.h" -#include "colmatrix.h" -#include "defines.h" -#include "joint.h" -#include "mat3x3.h" -#include "matrix.h" -#include "matrixfun.h" -#include "poemslist.h" -#include "vect3.h" -#include "virtualmatrix.h" +#include +#include +#include +#include using namespace std; -using namespace POEMS; - void Workspace::allocateNewSystem() { currentIndex++; diff --git a/lib/poems/workspace.h b/lib/poems/workspace.h index 2510b2fc3a..5faaf904dc 100644 --- a/lib/poems/workspace.h +++ b/lib/poems/workspace.h @@ -3,7 +3,7 @@ * POEMS: PARALLELIZABLE OPEN SOURCE EFFICIENT MULTIBODY SOFTWARE * * DESCRIPTION: SEE READ-ME * * FILE NAME: workspace.h * - * AUTHORS: See Author List * + * AUTHORS: See Author List * * GRANTS: See Grants List * * COPYRIGHT: (C) 2005 by Authors as listed in Author's List * * LICENSE: Please see License Agreement * @@ -11,7 +11,7 @@ * ADMINISTRATOR: Prof. Kurt Anderson * * Computational Dynamics Lab * * Rensselaer Polytechnic Institute * - * 110 8th St. Troy NY 12180 * + * 110 8th St. Troy NY 12180 * * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ @@ -19,62 +19,70 @@ #ifndef WORKSPACE_H #define WORKSPACE_H -namespace POEMS { +#include "matrices.h" +#include +#include +#include +#include +#include +#include + + class System; class Solver; struct SysData{ - System * system; - int solver; - int integrator; + System * system; + int solver; + int integrator; }; class Workspace { - SysData * system; // the multibody systems data - int currentIndex; - int maxAlloc; - + SysData * system; // the multibody systems data + int currentIndex; + int maxAlloc; + public: Workspace(); ~Workspace(); - + double Thalf; double Tfull; double ConFac; double KE_val; - int FirstTime; - + int FirstTime; + bool LoadFile(char* filename); - + bool SaveFile(char* filename, int index = -1); System* GetSystem(int index = -1); + + void AddSolver(Solver* s, int index = -1); + - void AddSolver(Solver* s, int index = -1); - - - void LobattoOne(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); - - void LobattoTwo(double **&vcm,double **&omega,double **&torque, double **&fcm); - - + void LobattoOne(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); + + void LobattoTwo(double **&vcm,double **&omega,double **&torque, double **&fcm); + + bool MakeSystem(int& nbody, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space, int &njoint, int **&jointbody, double **&xjoint, int& nfree, int*freelist, double dthalf, double dtv, double tempcon, double KE); - - - bool SaveSystem(int& nbody, double *&masstotal, double **&inertia, double **&xcm, double **&xjoint, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space, double **&acm, double **&alpha, double **&torque, double **&fcm, int **&jointbody, int &njoint); - - bool MakeDegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space); + + + bool SaveSystem(int& nbody, double *&masstotal, double **&inertia, double **&xcm, double **&xjoint, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space, double **&acm, double **&alpha, double **&torque, double **&fcm, int **&jointbody, int &njoint); + + bool MakeDegenerateSystem(int& nfree, int*freelist, double *&masstotal, double **&inertia, double **&xcm, double **&vcm, double **&omega, double **&ex_space, double **&ey_space, double **&ez_space); int getNumberOfSystems(); - + void SetLammpsValues(double dtv, double dthalf, double tempcon); void SetKE(int temp, double SysKE); - - void RKStep(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); - - void WriteFile(char* filename); + + void RKStep(double **&xcm, double **&vcm,double **&omega,double **&torque, double **&fcm, double **&ex_space, double **&ey_space, double **&ez_space); + + void WriteFile(char* filename); private: - void allocateNewSystem(); //helper function to handle vector resizing and such for the array of system pointers + void allocateNewSystem(); //helper function to handle vector resizing and such for the array of system pointers }; -} + #endif diff --git a/src/POEMS/fix_poems.cpp b/src/POEMS/fix_poems.cpp index 21c12f700b..c8646f5b14 100644 --- a/src/POEMS/fix_poems.cpp +++ b/src/POEMS/fix_poems.cpp @@ -263,7 +263,7 @@ FixPOEMS::FixPOEMS(LAMMPS *lmp, int narg, char **arg) : // create POEMS instance - poems = new POEMS::Workspace; + poems = new Workspace; // compute per body forces and torques inside final_integrate() by default diff --git a/src/POEMS/fix_poems.h b/src/POEMS/fix_poems.h index 87f9557ac0..7b2c77a1bd 100644 --- a/src/POEMS/fix_poems.h +++ b/src/POEMS/fix_poems.h @@ -22,7 +22,6 @@ FixStyle(poems,FixPOEMS) #include "fix.h" -namespace POEMS { class Workspace; } namespace LAMMPS_NS { class FixPOEMS : public Fix { @@ -95,7 +94,7 @@ class FixPOEMS : public Fix { // POEMS object - POEMS::Workspace *poems; + class Workspace *poems; // internal class functions From b6b802d0b11d75f1dd5cd58f76f3392fcb8a04c2 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Mon, 22 Jul 2019 14:36:09 -0400 Subject: [PATCH 77/79] correct forward declaration of POEMS workspace class --- src/POEMS/fix_poems.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/POEMS/fix_poems.h b/src/POEMS/fix_poems.h index 7b2c77a1bd..6892c51d7e 100644 --- a/src/POEMS/fix_poems.h +++ b/src/POEMS/fix_poems.h @@ -22,6 +22,8 @@ FixStyle(poems,FixPOEMS) #include "fix.h" +class Workspace; + namespace LAMMPS_NS { class FixPOEMS : public Fix { @@ -94,7 +96,7 @@ class FixPOEMS : public Fix { // POEMS object - class Workspace *poems; + Workspace *poems; // internal class functions From 8d4f1896994e50d7f66ab1f66a7bf8bd306f48e0 Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 26 Jul 2019 09:38:32 -0400 Subject: [PATCH 78/79] Revert "new versions of jacobi() method" This reverts commit 39315268e885fba886a0ff30eccc619ffaa64c5f. --- src/math_extra.cpp | 223 ++++++++++++--------------------------------- src/math_extra.h | 9 +- 2 files changed, 60 insertions(+), 172 deletions(-) diff --git a/src/math_extra.cpp b/src/math_extra.cpp index 4184e84b59..797d210d0e 100644 --- a/src/math_extra.cpp +++ b/src/math_extra.cpp @@ -13,7 +13,6 @@ /* ---------------------------------------------------------------------- Contributing author: Mike Brown (SNL) - Arno Mayrhofer (DCS Computing), jacobi() functions ------------------------------------------------------------------------- */ #include "math_extra.h" @@ -96,189 +95,83 @@ int mldivide3(const double m[3][3], const double *v, double *ans) /* ---------------------------------------------------------------------- compute evalues and evectors of 3x3 real symmetric matrix based on Jacobi rotations - two variants for passing in matrix - - procedure jacobi(S ∈ Rn×n; out e ∈ Rn; out E ∈ Rn×n) - var - i, k, l, m, state ∈ N - s, c, t, p, y, d, r ∈ R - ind ∈ Nn - changed ∈ Ln - ! init e, E, and arrays ind, changed - E := I; state := n - for k := 1 to n do indk := maxind(k); ek := Skk; changedk := true endfor - while state≠0 do ! next rotation - m := 1 ! find index (k,l) of pivot p - for k := 2 to n−1 do - if │Sk indk│ > │Sm indm│ then m := k endif - endfor - k := m; l := indm; p := Skl - ! calculate c = cos φ, s = sin φ - y := (el−ek)/2; d := │y│+√(p2+y2) - r := √(p2+d2); c := d/r; s := p/r; t := p2/d - if y<0 then s := −s; t := −t endif - Skl := 0.0; update(k,−t); update(l,t) - ! rotate rows and columns k and l - for i := 1 to k−1 do rotate(i,k,i,l) endfor - for i := k+1 to l−1 do rotate(k,i,i,l) endfor - for i := l+1 to n do rotate(k,i,l,i) endfor - ! rotate eigenvectors - for i := 1 to n do - ┌ ┐ ┌ ┐┌ ┐ - │Eik│ │c −s││Eik│ - │ │ := │ ││ │ - │Eil│ │s c││Eil│ - └ ┘ └ ┘└ ┘ - endfor - ! rows k, l have changed, update rows indk, indl - indk := maxind(k); indl := maxind(l) - loop - endproc + adapted from Numerical Recipes jacobi() function ------------------------------------------------------------------------- */ int jacobi(double matrix[3][3], double *evalues, double evectors[3][3]) { - evectors[0][0] = 1.0; evectors[0][1] = 0.0; evectors[0][2] = 0.0; - evectors[1][0] = 0.0; evectors[1][1] = 1.0; evectors[1][2] = 0.0; - evectors[2][0] = 0.0; evectors[2][1] = 0.0; evectors[2][2] = 1.0; - evalues[0] = 0.0; evalues[1] = 0.0; evalues[2] = 0.0; - double threshold = 0.0; + int i,j,k; + double tresh,theta,tau,t,sm,s,h,g,c,b[3],z[3]; - for (int i = 0; i < 3; i++) - for (int j = i; j < 3; j++) - threshold += fabs(matrix[i][j]); - - if (threshold < 1.0e-200) return 0; - threshold *= 1.0e-12; - int state = 2; - bool changed[3] = {true, true, true}; - - int iteration = 0; - while (state > 0 && iteration < MAXJACOBI) { - for (int k = 0; k < 2; k++) { - for (int l = k+1; l < 3; l++) { - const double p = matrix[k][l]; - const double y = (matrix[l][l]-matrix[k][k])*0.5; - const double d = fabs(y)+sqrt(p*p + y*y); - const double r = sqrt(p*p + d*d); - const double c = r > threshold ? d/r : 1.0; - double s = r > threshold ? p/r : 0.0; - double t = d > threshold ? p*p/d : 0.0; - if (y < 0.0) { - s *= -1.0; - t *= -1.0; - } - matrix[k][l] = 0.0; - update_eigenvalue(matrix[k][k], changed[k], state, -t, threshold); - update_eigenvalue(matrix[l][l], changed[l], state, t, threshold); - for (int i = 0; i < k; i++) - rotate(matrix[i][k], matrix[i][l],c,s); - for (int i = k+1; i < l; i++) - rotate(matrix[k][i], matrix[i][l],c,s); - for (int i = l+1; i < 3; i++) - rotate(matrix[k][i], matrix[l][i],c,s); - for (int i = 0; i < 3; i++) - rotate(evectors[i][k], evectors[i][l],c,s); - } - } - iteration++; + for (i = 0; i < 3; i++) { + for (j = 0; j < 3; j++) evectors[i][j] = 0.0; + evectors[i][i] = 1.0; + } + for (i = 0; i < 3; i++) { + b[i] = evalues[i] = matrix[i][i]; + z[i] = 0.0; } - for (int i = 0; i < 3; i++) - evalues[i] = matrix[i][i]; + for (int iter = 1; iter <= MAXJACOBI; iter++) { + sm = 0.0; + for (i = 0; i < 2; i++) + for (j = i+1; j < 3; j++) + sm += fabs(matrix[i][j]); + if (sm == 0.0) return 0; - if (iteration == MAXJACOBI) return 1; - return 0; -} + if (iter < 4) tresh = 0.2*sm/(3*3); + else tresh = 0.0; -int jacobi(double **matrix, double *evalues, double **evectors) -{ - evectors[0][0] = 1.0; evectors[0][1] = 0.0; evectors[0][2] = 0.0; - evectors[1][0] = 0.0; evectors[1][1] = 1.0; evectors[1][2] = 0.0; - evectors[2][0] = 0.0; evectors[2][1] = 0.0; evectors[2][2] = 1.0; - evalues[0] = 0.0; evalues[1] = 0.0; evalues[2] = 0.0; - double threshold = 0.0; - - for (int i = 0; i < 3; i++) - for (int j = i; j < 3; j++) - threshold += fabs(matrix[i][j]); - - if (threshold < 1.0e-200) return 0; - threshold *= 1.0e-12; - int state = 2; - bool changed[3] = {true, true, true}; - - int iteration = 0; - while (state > 0 && iteration < MAXJACOBI) { - for (int k = 0; k < 2; k++) { - for (int l = k+1; l < 3; l++) { - const double p = matrix[k][l]; - const double y = (matrix[l][l]-matrix[k][k])*0.5; - const double d = fabs(y)+sqrt(p*p + y*y); - const double r = sqrt(p*p + d*d); - const double c = r > threshold ? d/r : 1.0; - double s = r > threshold ? p/r : 0.0; - double t = d > threshold ? p*p/d : 0.0; - if (y < 0.0) { - s *= -1.0; - t *= -1.0; + for (i = 0; i < 2; i++) { + for (j = i+1; j < 3; j++) { + g = 100.0*fabs(matrix[i][j]); + if (iter > 4 && fabs(evalues[i])+g == fabs(evalues[i]) + && fabs(evalues[j])+g == fabs(evalues[j])) + matrix[i][j] = 0.0; + else if (fabs(matrix[i][j]) > tresh) { + h = evalues[j]-evalues[i]; + if (fabs(h)+g == fabs(h)) t = (matrix[i][j])/h; + else { + theta = 0.5*h/(matrix[i][j]); + t = 1.0/(fabs(theta)+sqrt(1.0+theta*theta)); + if (theta < 0.0) t = -t; + } + c = 1.0/sqrt(1.0+t*t); + s = t*c; + tau = s/(1.0+c); + h = t*matrix[i][j]; + z[i] -= h; + z[j] += h; + evalues[i] -= h; + evalues[j] += h; + matrix[i][j] = 0.0; + for (k = 0; k < i; k++) rotate(matrix,k,i,k,j,s,tau); + for (k = i+1; k < j; k++) rotate(matrix,i,k,k,j,s,tau); + for (k = j+1; k < 3; k++) rotate(matrix,i,k,j,k,s,tau); + for (k = 0; k < 3; k++) rotate(evectors,k,i,k,j,s,tau); } - matrix[k][l] = 0.0; - update_eigenvalue(matrix[k][k], changed[k], state, -t, threshold); - update_eigenvalue(matrix[l][l], changed[l], state, t, threshold); - for (int i = 0; i < k; i++) - rotate(matrix[i][k], matrix[i][l],c,s); - for (int i = k+1; i < l; i++) - rotate(matrix[k][i], matrix[i][l],c,s); - for (int i = l+1; i < 3; i++) - rotate(matrix[k][i], matrix[l][i],c,s); - for (int i = 0; i < 3; i++) - rotate(evectors[i][k], evectors[i][l],c,s); } } - iteration++; + + for (i = 0; i < 3; i++) { + evalues[i] = b[i] += z[i]; + z[i] = 0.0; + } } - - for (int i = 0; i < 3; i++) - evalues[i] = matrix[i][i]; - - if (iteration == MAXJACOBI) return 1; - return 0; + return 1; } /* ---------------------------------------------------------------------- - perform a single Jacobi rotation of Sij, Skl - ┌ ┐ ┌ ┐┌ ┐ - │Skl│ │c −s││Skl│ - │ │ := │ ││ │ - │Sij│ │s c││Sij│ - └ ┘ └ ┘└ ┘ + perform a single Jacobi rotation ------------------------------------------------------------------------- */ -void rotate(double &matrix_kl, double &matrix_ij, - const double c, const double s) +void rotate(double matrix[3][3], int i, int j, int k, int l, + double s, double tau) { - const double tmp_kl = matrix_kl; - matrix_kl = c*matrix_kl - s*matrix_ij; - matrix_ij = s*tmp_kl + c*matrix_ij; -} - -/* ---------------------------------------------------------------------- - update eigenvalue and its status -------------------------------------------------------------------------- */ - -void update_eigenvalue(double &eigenvalue, bool &changed, int &state, - const double t, const double threshold) -{ - eigenvalue += t; - - if (changed && fabs(t) < threshold) { - changed = false; - state--; - } else if (!changed && fabs(t) > threshold) { - changed = true; - state++; - } + double g = matrix[i][j]; + double h = matrix[k][l]; + matrix[i][j] = g-s*(h+g*tau); + matrix[k][l] = h+s*(g-h*tau); } /* ---------------------------------------------------------------------- diff --git a/src/math_extra.h b/src/math_extra.h index ad8105d271..09b135c641 100644 --- a/src/math_extra.h +++ b/src/math_extra.h @@ -74,14 +74,9 @@ namespace MathExtra { void write3(const double mat[3][3]); int mldivide3(const double mat[3][3], const double *vec, double *ans); - int jacobi(double matrix[3][3], double *evalues, double evectors[3][3]); - int jacobi(double **matrix, double *evalues, double **evectors); - void rotate(double &matrix_kl, double &matrix_ij, - const double c, const double s); - void update_eigenvalue(double &eigenvalue, bool &changed, int &state, - const double t, const double threshold); - + void rotate(double matrix[3][3], int i, int j, int k, int l, + double s, double tau); void richardson(double *q, double *m, double *w, double *moments, double dtq); void no_squish_rotate(int k, double *p, double *q, double *inertia, double dt); From 0f10c55c1cbc693491c6d180807a7ca40f61b18a Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Fri, 26 Jul 2019 17:26:59 -0400 Subject: [PATCH 79/79] avoid recursive header inclusion --- lib/poems/system.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/poems/system.h b/lib/poems/system.h index 1b59395de7..573044ce33 100644 --- a/lib/poems/system.h +++ b/lib/poems/system.h @@ -15,7 +15,6 @@ * CONTACT: anderk5@rpi.edu * *_________________________________________________________________________*/ - #ifndef SYSTEM_H #define SYSTEM_H @@ -31,7 +30,6 @@ #include "workspace.h" #include "matrixfun.h" #include "onsolver.h" -#include "system.h" #include "inertialframe.h" #include "rigidbody.h" #include "revolutejoint.h"