Dear LAMMPS community,
I have written a new pair style for shifted-force lennard-jones. When I
attempt to convert my binary restart files with the restart2data tool, I get
the error “Unknown pair style” for obvious reasons. I can’t seem to figure
out how to edit restart2data to do my new potential, which is equivalent to
lj/cut for the purposes of restart2data (same number of arguments, etc).
i don't quite get what is so difficult in making a change like this?
--- restart2data.cpp 2010-03-10 18:05:42.000000000 -0500
+++ restart2data.cpp 2010-03-10 18:07:03.000000000 -0500
@@ -1697,6 +1697,7 @@
}
} else if ((strcmp(style,"lj/cut") == 0) ||
+ (strcmp(style,"lj/sf") == 0) ||
(strcmp(style,"lj/cut/opt") == 0) ||
(strcmp(style,"lj/cut/coul/cut") == 0) ||
(strcmp(style,"lj/cut/coul/debye") == 0) ||
@@ -1704,7 +1705,7 @@
(strcmp(style,"lj/cut/coul/long/tip4p") == 0) ||
(strcmp(style,"lj/coul") == 0)) {
- if ((strcmp(style,"lj/cut") == 0) || (strcmp(style,"lj/cut/opt") == 0)) {
+ if ((strcmp(style,"lj/cut") == 0) || (strcmp(style,"lj/sf") == 0)
(strcmp(style,"lj/cut/opt") == 0)) {
m = 0;
double cut_lj_global = read_double(fp);
int offset_flag = read_int(fp);
@@ -2716,6 +2717,7 @@
pair_class2_epsilon[i],pair_class2_sigma[i]);
} else if ((strcmp(pair_style,"lj/cut") == 0) ||
+ (strcmp(pair_style,"lj/sf") == 0) ||
(strcmp(pair_style,"lj/cut/opt") == 0) ||
(strcmp(pair_style,"lj/cut/coul/cut") == 0) ||
(strcmp(pair_style,"lj/cut/coul/debye") == 0) ||
cheers,
axel.
restart2data-ljsf.diff (1.09 KB)