# Atomify commands start with #/

# Move camera to a nice position
#/camera position 20 85 55
#/camera viewcenter 20 20 10

# Set atom size and color
#/atom 1 1.0 #ffffff
#/atom 2 1.0 #ff0000

variable L equal 10.0
variable Lhalf equal 5.0
variable thickness equal 1.0

units lj
atom_style atomic
lattice fcc 0.3
variable T equal 1.3

# Create regions to place atoms
variable left equal 0.5*$L-0.5*${thickness}
variable right equal 0.5*$L+0.5*${thickness}
region system block 0 $L 0 $L 0 ${Lhalf}
region boxinside block ${left} ${right} 0 $L 0 ${Lhalf}
region boxoutside block ${left} ${right} 0 $L 0 ${Lhalf} side out

# Create a box with 2 atom types in the region system
create_box 2 system
# Create atoms of type 1 inside the inner region
create_atoms 1 region boxinside
# Create atoms of type 2 inside the outer region
create_atoms 2 region boxoutside

# Set atom masses 
mass 1 1.0
mass 2 10.0

# Give initial velocity, T=3.00, seed = 1337
velocity all create $T 1337 loop geom

# Choose LJ with 2.5sigma cutoff
pair_style lj/cut 2.5
pair_coeff * * 1.0 1.0 2.5
#pair_coeff 2 2 1.0 2.0 5.0
#pair_coeff 1 2 1.0 1.5 3.8
# Create two groups for computing diffusion coefficients
group light type 1
group heavy type 2

# 
compute msd_light light msd com yes
variable diffusion_coeff_light equal c_msd_light[4]/6/(step*dt+1.0e-6)

compute msd_heavy heavy msd com yes
variable diffusion_coeff_heavy equal c_msd_heavy[4]/6/(step*dt+1.0e-6)


fix 1 all nve
run 10000