include-what-you-use updates
This commit is contained in:
@ -25,7 +25,6 @@
|
||||
#include "error.h"
|
||||
#include "force.h"
|
||||
#include "input.h"
|
||||
#include "lammps.h"
|
||||
#include "math_const.h"
|
||||
#include "update.h"
|
||||
|
||||
|
||||
@ -19,8 +19,6 @@
|
||||
#include "math_const.h"
|
||||
#include "modify.h"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace MathConst;
|
||||
|
||||
|
||||
@ -31,7 +31,6 @@
|
||||
#include "update.h"
|
||||
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
|
||||
@ -25,7 +25,6 @@
|
||||
#include "update.h"
|
||||
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
|
||||
@ -29,7 +29,6 @@
|
||||
#include "update.h"
|
||||
|
||||
#include <cmath>
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
|
||||
@ -14,12 +14,12 @@
|
||||
#include "compute_count_type.h"
|
||||
|
||||
#include "atom.h"
|
||||
#include "domain.h"
|
||||
#include "error.h"
|
||||
#include "force.h"
|
||||
#include "group.h"
|
||||
#include "update.h"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
enum { ATOM, BOND, ANGLE, DIHEDRAL, IMPROPER };
|
||||
|
||||
@ -23,7 +23,6 @@ ComputeStyle(dipole/chunk,ComputeDipoleChunk);
|
||||
#include "compute_chunk.h"
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
class Fix;
|
||||
|
||||
class ComputeDipoleChunk : public ComputeChunk {
|
||||
public:
|
||||
@ -43,8 +42,6 @@ class ComputeDipoleChunk : public ComputeChunk {
|
||||
|
||||
void allocate() override;
|
||||
};
|
||||
|
||||
} // namespace LAMMPS_NS
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@ -12,14 +12,14 @@
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "compute_erotate_sphere_atom.h"
|
||||
#include <cstring>
|
||||
|
||||
#include "atom.h"
|
||||
#include "update.h"
|
||||
#include "modify.h"
|
||||
#include "comm.h"
|
||||
#include "error.h"
|
||||
#include "force.h"
|
||||
#include "memory.h"
|
||||
#include "error.h"
|
||||
#include "modify.h"
|
||||
#include "update.h"
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
@ -27,13 +27,10 @@ static constexpr double INERTIA = 0.4; // moment of inertia prefactor f
|
||||
|
||||
/* ---------------------------------------------------------------------- */
|
||||
|
||||
ComputeErotateSphereAtom::
|
||||
ComputeErotateSphereAtom(LAMMPS *lmp, int narg, char **arg) :
|
||||
Compute(lmp, narg, arg),
|
||||
erot(nullptr)
|
||||
ComputeErotateSphereAtom::ComputeErotateSphereAtom(LAMMPS *lmp, int narg, char **arg) :
|
||||
Compute(lmp, narg, arg), erot(nullptr)
|
||||
{
|
||||
if (narg != 3)
|
||||
error->all(FLERR,"Illegal compute erotate/sphere//atom command");
|
||||
if (narg != 3) error->all(FLERR, "Illegal compute erotate/sphere//atom command");
|
||||
|
||||
peratom_flag = 1;
|
||||
size_peratom_cols = 0;
|
||||
@ -41,9 +38,9 @@ ComputeErotateSphereAtom(LAMMPS *lmp, int narg, char **arg) :
|
||||
// error check
|
||||
|
||||
if (!atom->omega_flag)
|
||||
error->all(FLERR,"Compute erotate/sphere/atom requires atom attribute omega");
|
||||
error->all(FLERR, "Compute erotate/sphere/atom requires atom attribute omega");
|
||||
if (!atom->radius_flag)
|
||||
error->all(FLERR,"Compute erotate/sphere/atom requires atom attribute radius");
|
||||
error->all(FLERR, "Compute erotate/sphere/atom requires atom attribute radius");
|
||||
|
||||
nmax = 0;
|
||||
}
|
||||
@ -76,7 +73,7 @@ void ComputeErotateSphereAtom::compute_peratom()
|
||||
if (atom->nmax > nmax) {
|
||||
memory->destroy(erot);
|
||||
nmax = atom->nmax;
|
||||
memory->create(erot,nmax,"erotate/sphere/atom:erot");
|
||||
memory->create(erot, nmax, "erotate/sphere/atom:erot");
|
||||
vector_atom = erot;
|
||||
}
|
||||
|
||||
@ -91,10 +88,12 @@ void ComputeErotateSphereAtom::compute_peratom()
|
||||
|
||||
for (int i = 0; i < nlocal; i++) {
|
||||
if (mask[i] & groupbit) {
|
||||
erot[i] = (omega[i][0]*omega[i][0] + omega[i][1]*omega[i][1] +
|
||||
omega[i][2]*omega[i][2]) * radius[i]*radius[i]*rmass[i];
|
||||
erot[i] =
|
||||
(omega[i][0] * omega[i][0] + omega[i][1] * omega[i][1] + omega[i][2] * omega[i][2]) *
|
||||
radius[i] * radius[i] * rmass[i];
|
||||
erot[i] *= pfactor;
|
||||
} else erot[i] = 0.0;
|
||||
} else
|
||||
erot[i] = 0.0;
|
||||
}
|
||||
}
|
||||
|
||||
@ -104,6 +103,6 @@ void ComputeErotateSphereAtom::compute_peratom()
|
||||
|
||||
double ComputeErotateSphereAtom::memory_usage()
|
||||
{
|
||||
double bytes = (double)nmax * sizeof(double);
|
||||
double bytes = (double) nmax * sizeof(double);
|
||||
return bytes;
|
||||
}
|
||||
|
||||
@ -12,6 +12,7 @@
|
||||
------------------------------------------------------------------------- */
|
||||
|
||||
#include "compute_ke_atom.h"
|
||||
|
||||
#include "atom.h"
|
||||
#include "comm.h"
|
||||
#include "error.h"
|
||||
@ -19,7 +20,6 @@
|
||||
#include "memory.h"
|
||||
#include "modify.h"
|
||||
#include "update.h"
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
|
||||
@ -25,7 +25,6 @@
|
||||
#include "error.h"
|
||||
#include "force.h"
|
||||
#include "input.h"
|
||||
#include "lammps.h"
|
||||
#include "math_const.h"
|
||||
#include "update.h"
|
||||
|
||||
|
||||
@ -23,7 +23,6 @@
|
||||
#include "grid3d.h"
|
||||
#include "memory.h"
|
||||
#include "modify.h"
|
||||
#include "region.h"
|
||||
#include "update.h"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
@ -36,7 +36,6 @@
|
||||
#include <cstring>
|
||||
#include <unordered_map>
|
||||
#include <unordered_set>
|
||||
#include <vector>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
@ -17,7 +17,6 @@
|
||||
#include "atom.h"
|
||||
#include "domain.h"
|
||||
#include "error.h"
|
||||
#include "modify.h"
|
||||
#include "respa.h"
|
||||
#include "update.h"
|
||||
|
||||
|
||||
@ -23,6 +23,8 @@
|
||||
#include "update.h"
|
||||
#include "fmt/format.h"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
|
||||
@ -24,7 +24,6 @@
|
||||
#include "error.h"
|
||||
#include "fix_deform.h"
|
||||
#include "force.h"
|
||||
#include "group.h"
|
||||
#include "irregular.h"
|
||||
#include "kspace.h"
|
||||
#include "modify.h"
|
||||
|
||||
@ -22,6 +22,8 @@
|
||||
#include "update.h"
|
||||
#include "variable.h"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace FixConst;
|
||||
|
||||
|
||||
@ -17,8 +17,6 @@
|
||||
#include "error.h"
|
||||
#include "math_special.h"
|
||||
|
||||
#include <cmath>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using MathSpecial::powint;
|
||||
|
||||
|
||||
@ -17,8 +17,6 @@
|
||||
#include "error.h"
|
||||
#include "math_special.h"
|
||||
|
||||
#include <cmath>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using MathSpecial::powint;
|
||||
|
||||
|
||||
@ -23,6 +23,8 @@
|
||||
#include "memory.h"
|
||||
#include "pair.h"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
static constexpr int DELTA = 16;
|
||||
|
||||
@ -24,6 +24,8 @@
|
||||
#include "math_extra.h"
|
||||
#include "memory.h"
|
||||
|
||||
#include <cstring>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
|
||||
static constexpr int DELTA = 16;
|
||||
|
||||
@ -15,9 +15,9 @@
|
||||
#define LMP_INTEGRATE_H
|
||||
|
||||
#include "pointers.h"
|
||||
#include "compute.h"
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
class Compute;
|
||||
|
||||
class Integrate : protected Pointers {
|
||||
public:
|
||||
|
||||
@ -66,7 +66,6 @@
|
||||
|
||||
#include "lmpinstalledpkgs.h"
|
||||
#include "lmpgitversion.h"
|
||||
#include "lmpfftsettings.h"
|
||||
|
||||
#if defined(LAMMPS_UPDATE)
|
||||
#define UPDATE_STRING " - " LAMMPS_UPDATE
|
||||
|
||||
@ -15,9 +15,9 @@
|
||||
#define LMP_MIN_H
|
||||
|
||||
#include "pointers.h" // IWYU pragma: export
|
||||
#include "compute.h"
|
||||
|
||||
namespace LAMMPS_NS {
|
||||
class Compute;
|
||||
|
||||
class Min : protected Pointers {
|
||||
public:
|
||||
@ -116,7 +116,7 @@ class Min : protected Pointers {
|
||||
int narray; // # of arrays stored by fix_minimize
|
||||
class FixMinimize *fix_minimize; // fix that stores auxiliary data
|
||||
|
||||
class Compute *pe_compute; // compute for potential energy
|
||||
Compute *pe_compute; // compute for potential energy
|
||||
double ecurrent; // current potential energy
|
||||
|
||||
bigint ndoftotal; // total dof for entire problem
|
||||
|
||||
@ -23,6 +23,8 @@
|
||||
#include "neigh_list.h"
|
||||
#include "neighbor.h"
|
||||
|
||||
#include <cmath>
|
||||
|
||||
using namespace LAMMPS_NS;
|
||||
using namespace NeighConst;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user