1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
/* -*- c++ -*- ----------------------------------------------------------
LAMMPS - Large-scale Atomic/Molecular Massively Parallel Simulator
http://lammps.sandia.gov, Sandia National Laboratories
Steve Plimpton, sjplimp@sandia.gov
Copyright (2003) Sandia Corporation. Under the terms of Contract
DE-AC04-94AL85000 with Sandia Corporation, the U.S. Government retains
certain rights in this software. This software is distributed under
the GNU General Public License.
See the README file in the top-level LAMMPS directory.
------------------------------------------------------------------------- */
#ifndef LMP_NBIN_H
#define LMP_NBIN_H
#include "pointers.h"
namespace LAMMPS_NS {
class NBin : protected Pointers {
public:
int istyle; // 1-N index into binnames
bigint last_bin; // last timestep atoms were binned
int nbinx,nbiny,nbinz; // # of global bins
int mbins; // # of local bins and offset on this proc
int mbinx,mbiny,mbinz;
int mbinxlo,mbinylo,mbinzlo;
double binsizex,binsizey,binsizez; // bin sizes and inverse sizes
double bininvx,bininvy,bininvz;
int *binhead; // index of first atom in each bin
int *bins; // index of next atom in same bin
int *atom2bin; // bin assignment for each atom (local+ghost)
double cutoff_custom; // cutoff set by requestor
NBin(class LAMMPS *);
~NBin();
void post_constructor(class NeighRequest *);
virtual void copy_neighbor_info();
virtual void bin_atoms_setup(int);
bigint memory_usage();
virtual void setup_bins(int) = 0;
virtual void bin_atoms() = 0;
// Kokkos package
int kokkos; // 1 if class stores Kokkos data
protected:
// data from Neighbor class
int includegroup;
double cutneighmin;
double cutneighmax;
int binsizeflag;
double binsize_user;
double *bboxlo,*bboxhi;
// data common to all NBin variants
int dimension;
int triclinic;
int maxbin; // size of binhead array
int maxatom; // size of bins array
// methods
int coord2bin(double *);
};
}
#endif
/* ERROR/WARNING messages:
E: Non-numeric positions - simulation unstable
UNDOCUMENTED
*/