Reading data file

Also if you are equilibrating the system it is better to minimize the system potential energy using the minimize command as this will eliminate close contacts


Following is the input file to LAMMPS, the data file which reads and the output when I run the input file.

Input file -

units lj
atom_style hybrid bond sphere

read_data data.bucky

comm_modify vel yes
region container block -25 75 -25 75 -25 75 units box
fix container all wall/gran/region hooke/history &
4000.0 NULL 100.0 NULL 0.5 1 region container

store the information of neighbor

neighbor 0.3 bin
neigh_modify delay 0 every 1 check yes

apply gravity to spheres

fix 2 all nve/sphere
fix 3 all gravity 1.0 vector 0 0 -1

mass * 1.0
#mass 2 1.0
#mass 3 1.0

pair_style lj/smooth 8.0 10
pair_coeff * * 10.0 1.5
#pair_coeff 3 3 0.0 60.0 7.0

#bond_style harmonic
#bond_coeff * 1060.0 1.2

create bonds between atoms

#create_bonds * * 1 1.0 1.2

timestep 0.012

compute 1 all temp
compute_modify 1 dynamic yes

compute 2 all temp/sphere
compute_modify 2 dynamic yes

thermo 100
thermo_style custom step atoms temp c_1 c_2 press
thermo_modify lost ignore
compute_modify thermo_temp dynamic yes

run 10000

dump 1 all atom 10000 tmp.dump
dump_modify 1 image yes

The problem is that you’re using hybrid. Hybrid expects the first five columns of the data file to be id, type, x, y, z, and then the following columns should be the ones specific to sphere and bond.

Because you wrongfully assumed you had to include the molecule id in the first five columns, they are treated as the x-coordinate, and hence some atoms are in the same position in space, leading to bad dynamics.

See here on how to use read_data with atom_style hybrid:

Thanks, that worked!