Error in moving an object using gravity

Dear users,

I am loading a hybrid (sphere and bond) object from a data file. After loading the object, I am creating harmonic bonds between them so that spheres remain intact. I have put the object in a box and trying to move the object using gravity and also by moving the box, but I get ‘Too many wall/gran/region contacts for one particle’ error. Sometimes, I also get the error that some atoms are missing. Below is the input file-

units lj
atom_style hybrid bond sphere

read_data data1.bucky

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

group atoms type 1

store the information of neighbor

neighbor 0.3 bin
neigh_modify delay 0 every 1 check yes

mass * 1.0

pair_style lj/smooth 8.0 10

pair_coeff * * 10.0 1.5

bond_style harmonic
bond_coeff * 160.0 1.2

#create bonds between atoms
create_bonds atoms atoms 1 1.0 1.2

timestep 0.012

apply gravity to spheres

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

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 5000

dump 3 all movie 50 movie.mpg type type axes yes 0.8 0.02 view 80 -30
dump_modify 3 acolor 1 green

run 5000

rotate the box

region container delete
variable theta equal (step-5000)(4.0PI/5000)
region container block 0 36 0 36 0 36 units box &
rotate v_theta 0 0 0 0 0 1
run 5000

region container delete
region container block 0 36 0 36 0 36 units box
run 5000

region container delete
variable theta equal (step-15000)(4.0PI/5000)
region container block 0 36 0 36 0 36 units box &
rotate v_theta 0 0 0 1 1 1
run 5000

region container delete
region container block 0 36 0 36 0 36 units box
run 5000

Why are these two errors coming?

Thank You,
Dushyant Sahoo

Dear users,

I am loading a hybrid (sphere and bond) object from a data file. After
loading the object, I am creating harmonic bonds between them so that
spheres remain intact. I have put the object in a box and trying to move
the object using gravity and also by moving the box, but I get 'Too many
wall/gran/region contacts for one particle' error. Sometimes, I also get
the error that some atoms are missing. Below is the input file-

​[...]​

Why are these two errors coming?

​these errors are coming because your input deck is riddled with commands
and settings that don't make any sense and some of them look rather
unphysical and incorrect.

i am adding some comments below, but primarily you need to get some proper
help from somebody (local) in person that can train, tutor, and supervise
you. for the most part the advice, that i've just posted in a different
thread applies to you as well. after observing your struggling for some
time, it is obvious that you don't posses the necessary training in MD
fundamentals and also in performing computer simulations in general. you
already seem to have difficulties even describing your system what you are
trying to do in a comprehensible way. at the same time, you are not
employing the necessary care and diligence to teach yourself just from the
LAMMPS documentation. if you continue like you do, you will end up wasting
lots of time, annoy people with useless questions, embarrass yourself
publicly, have nothing of scientific value to show for, and make people
that look at your work shake their heads.

here is the reference to that other e-mail, that you should read and follow
the advice given
https://sourceforge.net/p/lammps/mailman/message/35811054/

units lj
atom_style hybrid bond sphere

​you are using an atom style for extended particles (sphere), but don't use
a potential below that uses that.​ why?

read_data data1.bucky
comm_modify vel yes

​why communicate the particle velocities?

region container block -20 60 -20 60 -20 60 units box
fix container all wall/gran/region hooke/history &
4000.0 NULL 100.0 NULL 0.5 1 region container

​you are​ using a wall fix for granular particles, but don't have any
granular particle potential. why?
also, try a simpler wall potential first. or better yet, start with a
simulation without a wall and make sure your fundamental simulation
parameters are suitable. it is always a bad idea to build a complex input
without having tested and validated individual parts independently.

group atoms type 1
# store the information of neighbor
neighbor 0.3 bin
neigh_modify delay 0 every 1 check yes
mass * 1.0

pair_style lj/smooth 8.0 10

​a cutoff of 10 sigma is quite excessive for reduced units. where did you
find this parameter?

pair_coeff * * 10.0 1.5

​why set parameters to values different from 1.0, when you have only one
type of particle and are using reduced units?
you are just changing the unit of properties that depend on energy and
length, e.g. time. the major point of reduced units is that you describe
things in ratios of energy and length. but since all your particles have
the same parameters, what is the point?

bond_style harmonic
bond_coeff * 160.0 1.2
#create bonds between atoms
create_bonds atoms atoms 1 1.0 1.2
timestep 0.012

​this value for the size of the timestep looks large in relation of your
choice of mass and potential parameters. have you checked for energy
conservation? do you actually have a numerically stable time integration?​

# apply gravity to spheres
fix 2 all nve/sphere

​you define an integrator for extended particles, but there is nothing
​actually computing torque, so what is the point of this?

fix 3 all gravity 1.0 vector 0 0 -1

with all the other issues that you are troubled with, why don't you first
build a simpler simulation? also, at the atomic scale (and it appears you
are trying to simulate something on the atomic scale) gravity is generally
not relevant compared to the typical magnitude of forces (atoms are far too
light).

compute 1 all temp
compute_modify 1 dynamic yes

​why flag this as dynamic when you are not adding or removing atoms?​

compute 2 all temp/sphere
compute_modify 2 dynamic yes

​what is the point of these? you are not ​ simulating extended particles?

thermo 100
thermo_style custom step atoms temp c_1 c_2 press
thermo_modify lost ignore

​you should only ignore lost atoms, if it is required by your model (e.g.
if you have a fixed boundary and want to drop atoms that go beyond that
boundary, e.g. after a sputtering simulation)​. however, you have periodic
boundaries and under those circumstances, lost atoms are extremely
worrisome, as they indicate a bad model and/or bad settings. such problems
are not solved by ignoring them. MD is "garbage in - garbage out".

compute_modify thermo_temp dynamic yes

​another pointless command.​..

run 5000
dump 3 all movie 50 movie.mpg type type axes yes 0.8 0.02 view 80 -30
dump_modify 3 acolor 1 green
run 5000

​overall, please do yourself a favor and take the advice in that e-mail, i
pointed out at the top of this mail, and spend a few weeks learning the
basics and get proper training before even attempting to continue this
project. you will spare yourself a lot of frustration and embarrassment.

axel.