Error in Setting Pair Coeffs for Pair_Style Hybrid

Dear LAMMPS Users,

Hello LAMMPS Users. I would like to ask a question in regards to defining the coefficients for pair_styles

I have a simulation box consisting of Type 1 and Type 2 atoms.

Lennard-Jones potential with cutoff distance of 2.5 is applied between Type 1 atoms.
Likewise, DPD potential is applied between Type 1 and Type 2 atoms.
I run this initial stage for 50000 timesteps.

After 50000 timesteps, I would like to switch the DPD potential applied between Type 1 and Type 2 atoms to DPD thermostat and Lennard-Jones potential with a cutoff distance of 1.122462 and run this second stage for 10000 timesteps.

The LJ potential between Type 1 atoms will remain as it is throughout the entire simulation.

I have displayed a portion of my input script:

pair_style hybrid lj/cut 2.5 dpd 1.0 1.0 122347

read_data DataFile

pair_coeff 1 1 lj/cut 1.0 1.0 2.5
pair_coeff 1 2 dpd 25 4.5 1.0

pair_modify shift yes

timestep 0.010
reset_timestep 0

fix 1 all nve
fix 2 all press/berendsen iso 0.0 0.0 10.0

group mol type 2
velocity mol create 1.0 17786140
run 50000

pair_style hybrid/overlay lj/cut 1.122462 dpd/tstat 1.0 1.0 1.122462 122347
pair_modify shift yes
pair_coeff 1 2 lj/cut 1.0 1.0 1.122462
pair_coeff 1 2 dpd/tstat 4.5 1.122462

run 10000

However, I am obtaining an error occurring at run 50000 which states "All pair coeffs are not set.’

Observing the portion of the input script that I have displayed above, I believe that all pair coefficients are specified by the pair_coeff command. Therefore, I am not sure where the source of the error is.

I tried another way by re-specifying the pair_coeffs in the my external DataFile via read-data command:

Pair Coeffs

1 lj/cut 1.0 1.0 2.5
2 dpd 25 4.5 1.0
2 dpd/tstat 4.5 1.122462

In this case, my simulation ran for the first 50000 timesteps, but I received an error at the start of the second stage:

Unknown identifier in data file: 2 dpd/tstat 4.5 1.122462

I have referred to the manual but I am not finding the source of the error. I would greatly appreciate if anyone could provide me with any advice or comments. Thank you so much for your time.

Sincerely,

Masato Koizumi

Dear LAMMPS Users,

Hello LAMMPS Users. I would like to ask a question in regards to defining the coefficients for pair_styles

I have a simulation box consisting of Type 1 and Type 2 atoms.

Lennard-Jones potential with cutoff distance of 2.5 is applied between Type 1 atoms.
Likewise, DPD potential is applied between Type 1 and Type 2 atoms.
I run this initial stage for 50000 timesteps.

After 50000 timesteps, I would like to switch the DPD potential applied between Type 1 and Type 2 atoms to DPD thermostat and Lennard-Jones potential with a cutoff distance of 1.122462 and run this second stage for 10000 timesteps.

The LJ potential between Type 1 atoms will remain as it is throughout the entire simulation.

I have displayed a portion of my input script:

pair_style hybrid lj/cut 2.5 dpd 1.0 1.0 122347

read_data DataFile

pair_coeff 1 1 lj/cut 1.0 1.0 2.5
pair_coeff 1 2 dpd 25 4.5 1.0

pair_modify shift yes

timestep 0.010
reset_timestep 0

fix 1 all nve
fix 2 all press/berendsen iso 0.0 0.0 10.0

group mol type 2
velocity mol create 1.0 17786140
run 50000

pair_style hybrid/overlay lj/cut 1.122462 dpd/tstat 1.0 1.0 1.122462 122347
pair_modify shift yes
pair_coeff 1 2 lj/cut 1.0 1.0 1.122462

Should it not be
pair_coeff 1 1
instead of
pair_coeff 1 2
?

Julien

there are 3 major blunders here and all are well documented in the manual.
so all of those blunders are due to a failure to read the documentation with sufficient care.

  1. it makes no sense to overlay dpd and dpd/tstat. dpd/tstat is included in dpd. when overlaying both, the thermostat would be applied twice and the resulting trajectories are garbage

  2. any new pair_style command defining a different pair style or respecifying a hybrid or hybrid/overlay style will wipe out all previous pair_coeff settings, so all coeffs need to be provided

  3. the PairCoeff section of a data file requires exactly as many lines as there are atom types. thus it is not compatible with pair style hybrid/overlay. it also requires that mixing is available, which is not given for the data file example. so that will fail even if the (bogus) dpd/tstat entry would be removed. in that kind of case, a PairCoeffIJ section must be provided (yet, even that is not fully compatible with hybrid overlay, as it also requires a fixed number of lines (=N*(N-1) instead of N).

axel.