pair coeffs with hybrid/overlay pair style

Dear LAMMPS Users,

I am running simulations with a pairwise force field composed of a combination of (up to) 5 gaussian function and a r12 repulsion. For this I use the pair_style hybrid/overlay:

pair_style hybrid/overlay lj/cut/coul/cut 15.0 gauss/cut 15.0 gauss/cut 15.0 gauss/cut 15.0 gauss/cut 15.0 gauss/cut 15.0

Followed by the pair coefficients:

1 1 lj/cut/coul/cut 7.253484e+05 1
1 1 gauss/cut 1 -4.858088e-01 4.594137 5.655362e-01
1 1 gauss/cut 2 3.860048e-01 6.773912 6.827464e-01
1 1 gauss/cut 3 1.928422e-01 10.612959 9.192791e-01
1 2 lj/cut/coul/cut 1.813008e+06 1
1 2 gauss/cut 1 2.577609e-01 7.202817 5.013672e-01
1 2 gauss/cut 2 -1.029851e+00 5.160473 7.161932e-01
1 2 gauss/cut 3 1.899216e-01 10.383490 7.565813e-01
1 2 gauss/cut 4 -4.852090e-01 4.220978 4.020288e-01
1 2 gauss/cut 5 5.214207e-02 12.734010 3.953330e-01

etc...

Because this is long and messy (I can have up to 32 types in one single simulation), I wanted to move this section to the data file in a "PairIJ Coeffs" section:

PairIJ Coeffs

1 1 lj/cut/coul/cut 7.253484e+05 1
1 1 gauss/cut 1 -4.858088e-01 4.594137 5.655362e-01
1 1 gauss/cut 2 3.860048e-01 6.773912 6.827464e-01
1 1 gauss/cut 3 1.928422e-01 10.612959 9.192791e-01
1 2 lj/cut/coul/cut 1.813008e+06 1
1 2 gauss/cut 1 2.577609e-01 7.202817 5.013672e-01
1 2 gauss/cut 2 -1.029851e+00 5.160473 7.161932e-01
1 2 gauss/cut 3 1.899216e-01 10.383490 7.565813e-01
1 2 gauss/cut 4 -4.852090e-01 4.220978 4.020288e-01
1 2 gauss/cut 5 5.214207e-02 12.734010 3.953330e-01

etc...

When I run LAMMPS, I get the following error:

ERROR: Unknown identifier in data file: 2 6 lj/cut/coul/cut 2.091260e+06 1 (../read_data.cpp:464)

Which corresponds to pair coefficient line #106. Since I have 14 types in this simulation, I have indeed 105 possible combinations. Does it mean that read_data cannot properly interpret the hybrid/overlay pair_style and that I have to keep all those pair coefficient in the body of the run input file or is there something I am missing?

Thank you in advance for your help!

BW

Aymeric

Dear LAMMPS Users,

I am running simulations with a pairwise force field composed of a
combination of (up to) 5 gaussian function and a r12 repulsion. For
this I use the pair_style hybrid/overlay:

pair_style hybrid/overlay lj/cut/coul/cut 15.0 gauss/cut 15.0
gauss/cut 15.0 gauss/cut 15.0 gauss/cut 15.0 gauss/cut 15.0

Followed by the pair coefficients:

1 1 lj/cut/coul/cut 7.253484e+05 1
1 1 gauss/cut 1 -4.858088e-01 4.594137 5.655362e-01
1 1 gauss/cut 2 3.860048e-01 6.773912 6.827464e-01
1 1 gauss/cut 3 1.928422e-01 10.612959 9.192791e-01
1 2 lj/cut/coul/cut 1.813008e+06 1
1 2 gauss/cut 1 2.577609e-01 7.202817 5.013672e-01
1 2 gauss/cut 2 -1.029851e+00 5.160473 7.161932e-01
1 2 gauss/cut 3 1.899216e-01 10.383490 7.565813e-01
1 2 gauss/cut 4 -4.852090e-01 4.220978 4.020288e-01
1 2 gauss/cut 5 5.214207e-02 12.734010 3.953330e-01

etc...

Because this is long and messy (I can have up to 32 types in one
single simulation), I wanted to move this section to the data file in
a "PairIJ Coeffs" section:

if it is just about keeping this away from the main input file, you
can just write the coefficients to a second file and use the "include
name_of_second_file" syntax.

PairIJ Coeffs

1 1 lj/cut/coul/cut 7.253484e+05 1
1 1 gauss/cut 1 -4.858088e-01 4.594137 5.655362e-01
1 1 gauss/cut 2 3.860048e-01 6.773912 6.827464e-01
1 1 gauss/cut 3 1.928422e-01 10.612959 9.192791e-01
1 2 lj/cut/coul/cut 1.813008e+06 1
1 2 gauss/cut 1 2.577609e-01 7.202817 5.013672e-01
1 2 gauss/cut 2 -1.029851e+00 5.160473 7.161932e-01
1 2 gauss/cut 3 1.899216e-01 10.383490 7.565813e-01
1 2 gauss/cut 4 -4.852090e-01 4.220978 4.020288e-01
1 2 gauss/cut 5 5.214207e-02 12.734010 3.953330e-01

etc...

When I run LAMMPS, I get the following error:

ERROR: Unknown identifier in data file: 2 6 lj/cut/coul/cut
2.091260e+06 1 (../read_data.cpp:464)

Which corresponds to pair coefficient line #106. Since I have 14 types
in this simulation, I have indeed 105 possible combinations. Does it
mean that read_data cannot properly interpret the hybrid/overlay
pair_style and that I have to keep all those pair coefficient in the
body of the run input file or is there something I am missing?

there is indeed currently is no way for read_data to read an arbitrary
amount of lines followed by the coeff keyword, as required by pair
style hybrid/overlay. the whole parsing of input is based on knowing
how many lines have to follow a specific section header keyword, which
is not possible here.

axel.