[lammps-users] Error: Angles defined but no angle types

Hello All,

I am constructing an H2O model data file with bonds and angles. I typed the headers as below:

LAMMPS Description

9216 atoms
6144 bonds
3072 angles

2 atom types
1 bond types
1 angle types

-50.3425 40.9055 xlo xhi
-4.23577 48.4463 ylo yhi
-28.5905 -0.0185 zlo zhi
-30.416 -0.01851 3.03E-15 xy xz yz

Masses

1 1.008
2 15.9994

Bond Coeffs

1 0 0.9572

Angle Coeffs

1 0 104.52

Then, I read it with the code:

read_data H2O1.data add append offset 3 0 0 0 0

However, the error occurs as “Angles defined but no angle types”. Could someone give me some ideas why this happened? My data file obviously defined the angle type.

Great thanks

Please always report which LAMMPS version you are using.

you must reserve sufficient space for types when you create the simulation cell.
when using read_data with “add” this is too late, the cell is already created, so the angle types setting in your data file is ignored.
this is explained in the read_data documentation, please have a closer look.