Advertisement
Guest User

LAMMPS cylindrical wall/srd

a guest
Nov 24th, 2011
221
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.06 KB | None | 0 0
  1. # 3d srd in a cylinder with gravity acting along it, starting from stationary
  2.  
  3. units lj
  4. atom_style atomic
  5. atom_modify first empty
  6. dimension 3
  7. boundary f f p
  8.  
  9. # set simulation size variables
  10.  
  11. variable xlength equal 10
  12. variable ylength equal 10
  13. variable zlength equal 10
  14.  
  15. variable x0 equal v_xlength/2
  16. variable y0 equal v_ylength/2
  17.  
  18. variable radius equal 4.5
  19.  
  20. variable WallSRDxlo equal v_x0-sqrt(v_radius*v_radius-(y-v_y0)*(y-v_y0))
  21. variable WallSRDxhi equal v_x0+sqrt(v_radius*v_radius-(y-v_y0)*(y-v_y0))
  22. variable WallSRDylo equal v_y0-sqrt(v_radius*v_radius-(x-v_x0)*(x-v_x0))
  23. variable WallSRDyhi equal v_y0+sqrt(v_radius*v_radius-(x-v_x0)*(x-v_x0))
  24.  
  25. # create box with big lattice
  26.  
  27. lattice sc 0.4
  28. region box block 0 10 0 10 0 10
  29. create_box 1 box
  30.  
  31. #print "${WallSRDxlo} ${WallSRDxhi} ${WallSRDylo} ${WallSRDyhi}"
  32.  
  33. # create cylinder along z-axis across sim box, centre at x=5,y=5, radius 4
  34.  
  35. region tube cylinder z 5 5 4 EDGE EDGE side in
  36.  
  37. # add SRD particles as hi density lattice
  38.  
  39. lattice sc 250.0
  40. create_atoms 1 region tube
  41.  
  42. group srdparticles type 1
  43. group empty type 2
  44.  
  45. mass 1 0.01
  46. velocity all create 1.0 593849 loop geom
  47.  
  48. # settings - need dummy empty group to enable no communication
  49.  
  50. neighbor 0.3 bin
  51. neigh_modify delay 1 every 1 check no
  52.  
  53. communicate single group empty
  54.  
  55. # timestep is big and SRD frequency is 1
  56.  
  57. timestep 0.02
  58.  
  59. fix 1 all srd 1 NULL 1.0 0.3 49894 &
  60. collision noslip overlap yes inside ignore
  61. fix 2 all gravity 1.0 vector 0 0 1
  62. #fix 3 all wall/region tubewall lj126 1 1 0.5
  63. #fix 4 all wall/srd xlo 0.5 xhi 9.5 ylo 0.5 yhi 9.5
  64. fix 4 all wall/srd &
  65. xlo WallSRDxlo xhi WallSRDxhi &
  66. ylo WallSRDylo yhi WallSRDyhi
  67.  
  68. # diagnostics
  69.  
  70. #thermo_style custom step temp f_1[7] etotal press f_1[3] f_1[4] f_1[6]
  71. #thermo 100
  72. thermo_modify lost warn
  73. #dump 1 all atom 250 dump.srd.pure.cylinder
  74. #dump 1 all custom 1 dump.srd.pure.cylinder id x y z vx vy vz
  75. dump 1 all atom 1 dump.srd.pure.cylinder
  76.  
  77. #dump_modify 1 format "%d %12.8g %12.8g %12.8g %12.8g %12.8g %12.8g"
  78.  
  79. run 200
  80. #run 5000
  81.  
  82.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement