Files
lammps/examples/bd_sphere/in2d.bd
2020-12-08 11:16:42 +00:00

77 lines
1.5 KiB
Plaintext

# 2d overdamped brownian dynamics
variable rng string gaussian
variable gamma_t equal 4.0
variable gamma_r equal 1.0
variable D_t equal 7.0
variable D_r equal 13.0
variable seed equal 1974019
variable params string ${rng}_${gamma_t}_${gamma_r}_${D_t}_${D_r}
log log_${params}_2d.lammps.log
units lj
atom_style hybrid dipole sphere
dimension 2
newton off
lattice sq 0.4
region box block -16 16 -16 16 -0.2 0.2
create_box 1 box
create_atoms 1 box
mass * 1.0
set type * dipole/random ${seed} 1.0
velocity all create 1.0 1 loop geom
neighbor 1.0 bin
neigh_modify every 1 delay 1 check yes
pair_style none
#compute d all property/atom mux muy muz
fix 1 all bd/sphere ${gamma_t} ${gamma_r} ${D_t} ${D_r} ${seed} rng ${rng}
fix 2 all enforce2d
compute press all pressure NULL virial
thermo_style custom step temp epair c_press
#equilibration
timestep 0.0000000001
thermo 50001
run 50000
reset_timestep 0
#initialisation for the main run
# MSD
compute msd all msd
thermo_style custom step temp epair c_msd[*] c_press
# write trajectory and thermo in a log-scale frequency
# uncomment next three lines for dump output
#dump 1 all custom 2000 dump_${params}_2d.lammpstrj id type &
# x y xu yu mux muy muz fx fy fz
#dump_modify 1 first yes sort id
timestep 0.00001
thermo 1000
# main run
run 120000