From 5d99bf664efbc93820c30e82873f03ccaeb43f0f Mon Sep 17 00:00:00 2001 From: sjplimp Date: Sat, 23 Jan 2016 00:49:10 +0000 Subject: [PATCH] git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@14479 f3b2605a-c512-4ea7-a41b-209d697bcdaa --- src/pair.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/pair.h b/src/pair.h index 86b07ece46..9927c04237 100644 --- a/src/pair.h +++ b/src/pair.h @@ -116,6 +116,7 @@ class Pair : protected Pointers { void init(); virtual void reinit(); + virtual void setup() {} double mix_energy(double, double, double, double); double mix_distance(double, double); void write_file(int, char **); @@ -237,6 +238,17 @@ class Pair : protected Pointers { double, double, double, double, double, double); void virial_fdotr_compute(); + // union data struct for packing 32-bit and 64-bit ints into double bufs + // see atom_vec.h for documentation + + union ubuf { + double d; + int64_t i; + ubuf(double arg) : d(arg) {} + ubuf(int64_t arg) : i(arg) {} + ubuf(int arg) : i(arg) {} + }; + inline int sbmask(int j) { return j >> SBBITS & 3; }