read_data or input script?

Dear lammps users,

So sorry for disturbing you, I’m new in lammps and I have a problem, I checked mail list and manual but I cant solve it. could you please tell me what is difference between these to scripts? (I get different results from them)

script one:

units cgs
dimension 2
atom_style sphere
boundary p f p
newton off
read_data datasphere.txt #### !!! ####
neighbor 0.0125 bin
compute 1 all erotate/sphere
set group all density 1.05
set group all diameter 0.025
fix 1 all nve/sphere
fix 2 all gravity 14 vector 0 -1 0
fix 4 all viscous 0.0066
fix 5 all wall/gran 24487562190 29670922496 8688783570 1000000 0.9 1 yplane 0.0 NULL
fix 6 all enforce2d #
pair_style gran/hertz/history 24487562190 29670922496 868878350 1000000 0.0 1
pair_coeff * *
comm_modify vel yes
dump 2 all image 500000 image.*.jpg type type zoom 1.6 adiam 0.025
dump_modify 2 pad 5
timestep 0.00000001
run_style verlet
run 900000000

datasphere.txt file

dimer granular molecule

1 atoms
1 atom types
0.0 1. xlo xhi
0.0 1. ylo yhi
-0.5 0.5 zlo zhi

Atoms

1 1 0.025 1.05 0.5 0.99 0.0

Velocities

1 0.0 0.0 0.0 0.0 0.0 0.0

Dear lammps users,

So sorry for disturbing you, I'm new in lammps and I have a problem, I
checked mail list and manual but I cant solve it. could you please tell me
what is difference between these to scripts? (I get different results from
them)

​what do you mean by *different result*?
*totally* different or just slowly diverging?

axel.​

Dear lammps users,
So sorry for disturbing you, I'm new in lammps and I have a problem, I checked mail list and manual but I cant solve it. could you please tell me what is difference between these to scripts? (I get different results from them)

Try typing this into the shell

   diff -b file1.in file2.in

(change "file1.in", "file2.in" to the names of your input script files).

When I do this with your input scripts (after changing the line order) I see:

   file1.in:
fix 5 all wall/gran 24487562190 29670922496 8688783570 1000000 0.9 1
yplane 0.0 NULL
pair_style gran/hertz/history 24487562190 29670922496 868878350 1000000 0.0 1

   file2.in:
fix 5 all wall/gran 24487562190 29670922496 8688783570 1000000 0.9 1
yplane 0 1.0
pair_style gran/hertz/history 24487562190 29670922496 868878350 1000000 0.1 1

   I don't know what effect these changes would have on your system.

Additionally, one of the script reads a data file and the other does
not. You will have to visualize the system with VMD to make sure the
data file you are reading is equivalent to the input script commands
you were using. (Attached file has instructions for viewing data
files with VMD&topotools.)

Andrew

README_visualize.txt (2.42 KB)