Hello all,
I am running molecular dynamics simulations in lammps and trying to calculate how polydispersity affects the pressure. To start, I ran MD simulations with the repulsive part of the Morse potential with a small damping factor, with the goal of replicating Brownian Dynamics.
If I run the simulations (in LJ units) with a size of 1 and a volume fraction of 30%, I get close to the Carnahan Starling value as expected. However, when I say double the size, the pressure gets reduced by 1/8. This makes sense given the LJ units are P*sigma^3/epsilon. This observation holds across multiple pressure calculation commands:
compute myPress all pressure NULL virial
thermo_style custom step temp c_myPress[1] c_myPress[2] c_myPress[3] c_myPress[4] c_myPress[5] c_myPress[6] pe ke
thermo_style custom step temp c_myPress[1] c_myPress[2] c_myPress[3] c_myPress[4] c_myPress[5] c_myPress[6] press pe ke c_msd[4]
My questions are:
- Is my interpretation that if we want to get a dimensionless pressure that depends only on volume fraction, you would scale with the particle size cubed?
- How would this translate to a bidisperse case? It is not immediately obvious to me how to extend this because I have calculated the stress on each atom and then taken the average for each type and output that, but the relation no longer holds (in fact sometimes the trend reverses and the larger particles have a higher stress output). I’ve tried also normalizing by the Voronoi volume but couldn’t make sense of that output either.
I realize I might be overlooking something very simple, and thank you for your help and patience. Below is my code in case its helpful:
create_atoms 1 random n_part_1 seed1 simulation_box
create_atoms 2 random n_part_2 seed2 simulation_boxgroup group1 type 1
group group2 type 2variable size1 equal .51
variable size2 equal 21variable mass1 equal size1^3
variable mass2 equal size2^3
mass 1 mass1
mass 2 mass2variable pot_depth equal 10.0
variable pot_steep equal 30.0variable cutoff_11 equal size1
variable cutoff_12 equal (size1+size2)/2.0
variable cutoff_22 equal size2variable pot_steep_11 equal pot_steep/size1
variable pot_steep_12 equal 2*pot_steep/(size1+size2)
variable pot_steep_22 equal pot_steep/size2pair_coeff 1 1 pot_depth pot_steep_11 cutoff_11 cutoff_11
pair_coeff 1 2 pot_depth pot_steep_12 cutoff_12 cutoff_12
pair_coeff 2 2 pot_depth pot_steep_22 cutoff_22 cutoff_22variable dt equal 0.0005
timestep dtvariable damp equal 10dt
variable damp1 equal dampsize1^2
variable damp2 equal damp*size2^2minimize 1.0e-10 1.0e-12 100000 1000000
compute myPress all pressure NULL virial
compute perAtomStress all stress/atom NULL virial
compute myStress1 group1 reduce sum c_perAtomStress[1] c_perAtomStress[2] c_perAtomStress[3]
compute myStress2 group2 reduce sum c_perAtomStress[1] c_perAtomStress[2] c_perAtomStress[3]variable press1 equal c_myStress1[1]/n_part_1
variable press2 equal c_myStress2[1]/n_part_2compute msd1 group1 msd com yes
compute msd2 group2 msd com yesthermo 100
thermo_style custom step temp press v_press1 v_press2 c_myPress[1] c_myPress[2] c_myPress[3] c_msd1[4] c_msd2[4]
fix nve all nve
fix mylangevin1 group1 langevin 1.0 1.0 damp1 seed
fix mylangevin2 group2 langevin 1.0 1.0 damp2 seed2
variable prod_steps equal 50000
run prod_steps