Invalid atom type in Atoms section of data file

Dear Lammps-users,

I keep running into the above error suddenly. The code had worked before, I am modeling a graphene sheet using the AIREBO potential. The data file looks like:

Long armchair graphene

4176 atoms
1 atom types

-20.0 20.0 xlo xhi
0.0 51.15096 ylo yhi
0.0 214.107148808 zlo zhi

Masses

1 12.011

Atoms

1 1 0 0.00000000 0.00000000 0.00000000
2 1 0 0.00000000 1.42086000 0.00000000
3 1 0 0.00000000 2.13129000 1.23050086
4 1 0 0.00000000 3.55215000 1.23050086
5 1 0 0.00000000 4.26258000 0.00000000
6 1 0 0.00000000 5.68344000 0.00000000
7 1 0 0.00000000 6.39387000 1.23050086
8 1 0 0.00000000 7.81473000 1.23050086
9 1 0 0.00000000 8.52516000 0.00000000
10 1 0 0.00000000 9.94602000 0.00000000
11 1 0 0.00000000 10.65645000 1.23050086
12 1 0 0.00000000 12.07731000 1.23050086
13 1 0 0.00000000 12.78774000 0.00000000
14 1 0 0.00000000 14.20860000 0.00000000
15 1 0 0.00000000 14.91903000 1.23050086
16 1 0 0.00000000 16.33989000 1.23050086
17 1 0 0.00000000 17.05032000 0.00000000
18 1 0 0.00000000 18.47118000 0.00000000

…and so on.

I followed the given format for atom_style charge

Regards,
Yeo Jingjie
Ph.D. Student

School of Mechanical and Aerospace Engineering
Nanyang Technological University, Singapore

Do any of your 4000+ atoms have a type bigger than 1?

Steve

I’m not sure whether this is a bug or not, but I resolved the problem by simply using atom_style atomic instead since all charge is zero, and removed the column for charges in the data file. Apparently it is not possible to simply use atom_style charge and specify zero charge for all atoms?

Regards,
Yeo Jingjie
Ph.D. Student

School of Mechanical and Aerospace Engineering
Nanyang Technological University, Singapore

Using style charge with all-zero charge should be fine.
Can you post an example input script/data file
that breaks with the error?

Steve

I tried again with the charge style and it managed to work again. I think it might have been an issue with my computer, something just screwed up somewhere. I apologise for the trouble.

Regards,
Yeo Jingjie
Ph.D. Student

School of Mechanical and Aerospace Engineering
Nanyang Technological University, Singapore