Dear Lammpser,
I am permanently facing with this error. please let me know you can help
me or not. Actually, I am sure about lattice and pair_style commands as I
selected their parameters from text books.
i just ran your input and - as expected - there are lots of issues, that
can be easily detected by carefully examining the output and applying
elementary testing/debugging steps. please find comments inline.
dimension 3
units real
atom_style charge
boundary p p p
#simulation box
region box block 0 10 0 10 0 10 units lattice
so this will use the default lattice (simple cubic with 1.0 1.0 1.0
spacing, i.e. it will create a 10x10x10 \AA box. not likely want you want).
create_box 2 box
and now create a periodic box for that.
lattice custom 1 a1 3.786 0.00000 0.00000 a2 0.0000 3.786 0.00000
a3 1.8925 1.8925 4.7570 &
basis 0.1250 0.8750 0.7500 &
basis 0.1250 0.1250 0.2500 &
basis 0.0816 0.3316 0.8368 &
basis 0.9184 0.6684 0.1632 &
basis 0.3316 0.0816 0.3368 &
basis 0.6684 0.9184 0.6632
mass 1 47.86
mass 2 16.00
lattice spacing will be 3.786 3.786 4.7570
#cube
region substrate block 0 37.86 0 37.86 0 47.570 units lattice
this now creates a region using the lattice spacing from above while you
obviously don't want that as the resulting region should have dimensions
that - by far - exceed the size of the box (even with units box).
create_atoms 2 region substrate &
basis 1 1 &
basis 2 1 &
basis 3 2 &
basis 4 2 &
basis 5 2 &
basis 6 2
set type 1 charge 2.196
set type 2 charge -1.098
group substrate region substrate
#--Phase 2----------------------------------------Buckingham
Potential-----------------------------------------------
# Potential
pair_style buck/coul/long 10.0
pair_coeff 1 1 717647.40 0.154 121.067
pair_coeff 1 2 391049.10 0.194 290.331
pair_coeff 2 2 271716.30 0.234 696.888
kspace_style pppm 0.0001
timestep 5
this looks like a rather aggressive choice of time step for this kind of
system. specifically if you are having problems, it is usually a good idea
to reduce it.
if you want to confirm, that you have create a proper geometry it is always
a good idea to write out a data or dump file at this point and a) visualize
them and check for correctness, especially with periodicity added and b)
manually check a few coordinates for correctness.
next step should be to run a minimization. if your geometry is good, then
there should not be significant changes. however, your system changes
*massively* and starts with a gigantic positive pressure that turns into a
gigantic negative pressure after minimization. that is a strong indication
that something is seriously wrong here.
you should also see that your system is not neutral. that doesn't make
sense for entering a crystal structure. it *should* be neutral.
velocity all create 300 12345 mom yes rot no
fix 1 all nvt temp 300.0 300.0 0.01
thermo 100
thermo_style custom step temp
turning off useful diagonostics like energies and pressure is a bad idea.
you are essentially running your simulation "blind". ignoring bad news does
not make it go away.
dump 1 all image 500 image.*.png type type adiam 1.0 axes yes 0.8 0.02
zoom 1.5 view 80 -30
dump_modify 1 backcolor white boxcolor white acolor 1*2
blue/red/orange/green/cyan/aqua/yellow/red
run 10000
at this point having the pppm error is inevitable. the GI-GO principle
applies. unless you feed LAMMPS meaningful input, it will not be able to
compute meaningful results.
all of the above should be standard protocol when setting up a new system.
claiming, that you took data from a textbook is no proof that you are
setting up your system correctly. as shown above, there are many obvious
issues. you need to improve your skills of how to confirm that commands are
actually producing the correct effect.
axel.