CH4 Molecule file

Hello. I am trying to create a CH4 molecule file. I read through LAMMPS documentation and previous posts in the forum on molecule files. My current approach to this is to create a CH4 molecule file using a information in my CH4 data file manually. Currently, I have to put it in LAMMPS however, there seems to be an “invalid line” error under my Coords section.

Im not sure why this happens when I extracted the information from the data file correctly. The same goes to when I try to include the “Bonds” section for my molecule file. I previously created the data file through Material Studios. Would appreciate if there can be any feedback on this. This is my data file and my molecule file. Thanks

Data file
LAMMPS data file. msi2lmp v3.9.9 / 05 Nov 2018 / CGCMM for ch4_run1

  5 atoms
  4 bonds
  6 angles

2 atom types
1 bond types
1 angle types

-1.039900005     1.509899974 xlo xhi
-0.504100000     1.963099957 ylo yhi
-1.375100017     1.404799998 zlo zhi

Masses

1 1.008 # H_
2 12.001 # C_1

Pair Coeffs # lj/cut/coul/long

1 0.03 2.5 # H_
2 0.066 3.5 # C_1

Bond Coeffs # harmonic

1 580 1.09 # H_-C_1

Angle Coeffs # harmonic

1 66.00 107.8 # H_-C_1-H_

Atoms # full

  1      1   1  0.000000     0.002100000    -0.004100000     0.002000000   0   0   0 # H_
  2      1   2  0.000000    -0.012700000     1.085800052     0.008000000   0   0   0 # C_1
  3      1   1  0.000000     1.009899974     1.463099957     0.000300000   0   0   0 # H_
  4      1   1  0.000000    -0.539900005     1.446900010    -0.875100017   0   0   0 # H_
  5      1   1  0.000000    -0.522899985     1.437299967     0.904799998   0   0   0 # H_

Bonds

 1   1      1      2
 2   1      3      2
 3   1      4      2
 4   1      5      2

Angles

 1   1      1      2      3
 2   1      1      2      4
 3   1      1      2      5
 4   1      3      2      4
 5   1      3      2      5
 6   1      4      2      5

Molecule file
#CH4 molecule file

5 atoms
4 bonds
6 angles

Coords
1 0.002100000 -0.004100000 0.002000000 #H
2 -0.012700000 1.085800052 0.008000000 #C
3 1.009899974 1.463099957 0.000300000 #H
4 -0.539900005 1.446900010 -0.875100017 #H
5 -0.522899985 1.437299967 0.904799998 #H

Types
1 1 #H
2 2 #C
3 1 #H
4 1 #H
5 1 #H

Charges
1 0.06 #H
2 -0.24 #C
3 0.06 #H
4 0.06 #H
5 0.06 #H

Bonds
1 1 1 2
2 1 3 2
3 1 4 2
4 1 5 2

Angles
1 1 1 2 3
2 1 1 2 4
3 1 1 2 5
4 1 3 2 4
5 1 3 2 5
6 1 4 2 5

Hi.

You need one empty line after Coords, same for the other sections:

#CH4 molecule file

5 atoms
4 bonds
6 angles

Coords

1 0.002100000 -0.004100000 0.002000000 #H
2 -0.012700000 1.085800052 0.008000000 #C
3 1.009899974 1.463099957 0.000300000 #H
4 -0.539900005 1.446900010 -0.875100017 #H
5 -0.522899985 1.437299967 0.904799998 #H

Types

1 1 #H
2 2 #C
3 1 #H
4 1 #H
5 1 #H

Charges

1 0.06 #H
2 -0.24 #C
3 0.06 #H
4 0.06 #H
5 0.06 #H

Bonds

1 1 1 2
2 1 3 2
3 1 4 2
4 1 5 2

Angles

1 1 1 2 3
2 1 1 2 4
3 1 1 2 5
4 1 3 2 4
5 1 3 2 5
6 1 4 2 5

Simon

2 Likes

Hello,
It works now. I adjusted the spacing for the Coords section as well and now LAMMPS reads it. Thank you