Dear LAMMPS users,
I am trying to simulate ideal gas flow through a microchannel. I am using the SPH module for solving the problem.
Regarding the implementation, i am using the deposit-Kill approach: where i deposit particles before the inlet region and delete them after the outlet region, with fixed boundary in the flow direction. This would ensure a continuous time simulation. The added particles should have initial velocity before it begin integrated and interact with each other.
I do not know how to deposit the particles with initial velocity, so that they propagate only according to the specified pair interactions, and not that velocity anymore.
When i use fix-deposit command, it seems the velocity have the same magnitude and direction at all time integration. Thus i am not sure whether such command is not useful or i just can not use it properly.
Also, using fix-move command with variable equals the velocity seems good, in the sense that it can drives the particles at the following regions, but this approach will not ensure a long-time simulation, and thus it is not useful to my case.
I would be highly appreciated if you encountered similar simulations, to let me know how to handle.
INPUT file:
dimension 2
units si
atom_style meso
boundary f p p
region geometry block -3500.0e-6 3500.0e-6 -750.0e-6 750.0e-6 -10.0e-6 10.0e-6 side in
create_box 2 geometry
region delete_in block EDGE -3001.0e-6 EDGE EDGE EDGE EDGE units box
delete_atoms region delete_in
region generate_in block -3000.0e-6 -2500.0e-6 EDGE EDGE EDGE EDGE units box
lattice hex 50.0e-6
region fluid_in block -2000.0e-6 -500.0e-6 EDGE EDGE EDGE EDGE units box
create_atoms 1 region fluid_in
lattice hex 50.0e-6
region fluid_channel block 0.0e-6 1000.0e-6 -150.0e-6 150.0e-6 EDGE EDGE units box
create_atoms 1 region fluid_channel
lattice sq2 20.0e-6
region upper_wall block 0.0e-6 1000.0e-6 150.0e-6 EDGE EDGE EDGE units box
create_atoms 2 region upper_wall
lattice sq2 20.0e-6
region lower_wall block 0.0e-6 1000.0e-6 EDGE -150.0e-6 EDGE EDGE units box
create_atoms 2 region lower_wall
lattice hex 50.0e-6
region fluid_out block 1500.0e-6 3000.0e-6 EDGE EDGE EDGE EDGE units box
create_atoms 1 region fluid_out
region delete_out block 3001.0e-6 EDGE EDGE EDGE EDGE EDGE units box
delete_atoms region delete_out
region walls union 2 upper_wall lower_wall units box
group fluid type 1
group walls type 2
mass 1 4.112e-9
mass 2 2.29787234e-10
set type 1 meso/rho 1.17
set type 2 meso/rho 1.17
set type 1 meso/e 0.8650571e-3
set type 2 meso/e 0.048341259e-3
pair_style hybrid/overlay sph/rhosum 1 sph/idealgas
pair_coeff 1 1 sph/rhosum 150.0e-6
pair_coeff 1 1 sph/idealgas 0.5 150.0e-6
pair_coeff 1 2 sph/idealgas 0.5 20.0e-6
pair_coeff 2 2 sph/idealgas 0.5 20.0e-6
compute rho_peratom all meso/rho/atom
compute e_peratom all meso/e/atom
compute ke_peratom all ke/atom
compute esph all reduce sum c_e_peratom
compute ke all ke
variable etot equal c_ke+c_esph
neighbor 25.0e-6 nsq
neigh_modify every 1 delay 0 check yes
fix fix_deposit fluid deposit 999999999 1 100 13572468 region fluid_in vx 1.9 2.1 near 25.0e-6 attempt 10000 units box
fix fix_integrate fluid meso
fix fix_walls walls meso/stationary
dump dump_id all custom 10 dump_gas.out id type x y z vx vy c_rho_peratom c_e_peratom
dump_modify dump_id first yes
thermo 10
thermo_style custom step c_esph v_etot
thermo_modify norm no lost ignore
timestep 0.5e-8
run 400000
Thanks in advance
Ali Gad
MSc Mathematical engineering,
BSc Mechanical engineering