[lammps-users] About hybrid pair style

Hi Steve and all users,

My model has two atom types, both are carbon (atom type 1, 2), each of themselves are modeled with tersoff potentail, but the interaction of type 1 and 2 are modeled with lj, so I was trying to use the following set, but LAMMPS told me the error message: " ERROR: Pair coeff for hybrid has invalid style "
How can I deal with this? Thanks in advance.

pair_style hybrid tersoff lj/cut 20.0
pair_coeff * * SiC.tersoff C C C NULL
pair_coeff 1 2 lj/cut 0.00286 3.468

Best,

AC

pair_coeff * * SiC.tersoff C C C NULL

should be
pair_coeff * * tersoff SiC.tersoff C C C NULL

Steve

Steve, thanks for your reply. But the problem is not fixed. I changed the input according to your suggestion but still have problem;

pair_style hybrid tersoff lj/cut 20.0
pair_coeff * * tersoff SiC.tersoff C C C NULL
pair_coeff 1 2 lj/cut 0.00286 3.468 20.0

The error is:
ERROR: Incorrect args for pair coefficients

what is your opinion?

Best,

AC

You may wish to use 'hybrid/overlay' instead of 'hybrid' since you
have two kinds of pair interaction (Tersoff and LJ) between type 1 and
type 2 atoms.

Regards,
Zhun-Yong

zhun-yong,

Thanks for your advice, but maybe i didn’t specify my model well. The interaction between type 1 and 2 is only lj not involved tersoff at all. I think the tricky part is the tersoff, which I specify 4 types of atoms, but I have no idea why I need 4 types of atoms and how to define these atom types.

Hope steve can solve this for me…

Best,

AC

If your model has 2 atom types why are you specifying
C C C NULL?

Please read the doc page for pair_style tersoff. It explains
all the args in great detail.

Steve

Hi Ajing.

If you want to have type 1 atoms interacting amongst themselves with a
Tersoff potential, the same with type 2 atoms and a LJ interaction
between type 1 and 2 atoms, then the only way this can work, that I
can think of, is to have a Tersoff potential file (carbon.tersoff) for
the two type of atoms with the following eight entries:

C(1) C(1) C(1) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 346.7 1.95 0.15 3.4879 1393.6
C(2) C(2) C(2) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 346.7 1.95 0.15 3.4879 1393.6
C(1) C(2) C(2) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 0 1.95 0.15 3.4879 0
C(1) C(2) C(1) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 0 1.95 0.15 3.4879 0
C(1) C(1) C(2) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 0 1.95 0.15 3.4879 0
C(2) C(1) C(1) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 0 1.95 0.15 3.4879 0
C(2) C(1) C(2) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 0 1.95 0.15 3.4879 0
C(2) C(2) C(1) 3.0 1.0 0.0 3.8049e4 4.3484 -0.57058 0.72751
1.5724e-7 2.2119 0 1.95 0.15 3.4879 0

where you set to zero the repulsive and attractive terms between type
1 and 2 atoms. That way, there is no Tersoff interaction between type
1 and type 2 atoms.

Also, use the command
pair_coeff * * tersoff carbon.tersoff C(1) C(2)

Regards,
Zhun-Yong

Hi, Zhunyong,

I figured out that I can just use the following commands:

pair_style hybrid tersoff lj/cut 20.0
pair_coeff * * tersoff SiC.tersoff C C
pair_coeff 1 2 lj/cut 0.00286 3.468 20.0

and it works. I didn’t try your method (complicated to me) but thank you anyway.

Best,

AC

Hi zhunyong,

Thanks for your suggestion. Of course, the means your decribed is good at solving my problem.
I just want to make sure if my understanding is correct regarding the “pair_style hybrid” command.

pair_style hybrid tersoff lj/cut 20.0
pair_coeff * * tersoff SiC.tersoff C C
pair_coeff 1 2 lj/cut 0.00286 3.468 20.0

This is based on the document saying:

"For the hybrid style, each atom type pair I,J is assigned to exactly one sub-style. Just as with a simulation using a single pair style, if you specify the same atom type pair in a second pair_coeff command, the previous assignment will be overwritten. "

So pair 1,2 are respecified as lj potential and no tersoff interaction between 1 and 2 (previously described) exists. Am I understanding right? Thanks!

Best,

AC

yes - that should work

Steve