a bunch refactoring changes in the python pair style and the examples

- make all python potential classes derived from LAMMPSPairPotential
  which contains shared functionality. We currently don't check
  for supported atom types. may want to add that again later.
- keep track of skipped atom types in the C++ code.
- add test against units setting. must set self.units='...' in constructor
- make compute_force method consistent with Pair::single() in LAMMPS and return force/r instead of force.
- rename potentials.py to py_pot.py
- update test runs. some small tweaks.
This commit is contained in:
Axel Kohlmeyer
2017-05-17 20:55:48 -04:00
parent 1d48f287f0
commit 67962b15fc
18 changed files with 521 additions and 316 deletions

View File

@ -12,12 +12,12 @@ mass * 1.0
velocity all create 3.0 87287
pair_style python 2.5
pair_coeff * * potentials.LJCutMelt lj
pair_coeff * * py_pot.LJCutMelt lj
# generate tabulated potential from python variant
pair_write 1 1 10000 rsq 0.01 2.5 lj_1_1.table LJ
pair_write 1 1 2000 rsq 0.01 2.5 lj_1_1.table LJ
pair_style table linear 10000
pair_style table linear 2000
pair_coeff 1 1 lj_1_1.table LJ
neighbor 0.3 bin