[lammps-users] Constant pressure minimization for alpha quartz

Hi,

I’ve been getting to grips with Lammps and I’ve been trying to minimize a unit cell of alpha quartz under constant pressure to obtain optimum lattice parameters and atom coordinates. I am using the Lammps code released on 9th February 2011. I have tried various minimization techniques and using a barostat but to no avail. My input files are along the lines…

Calculation of properties of alpha quartz using BKS potential and minimization

units metal
newton on
atom_style charge
dimension 3
boundary p p p

lattice custom 5.4054 origin 0.0 0.0 0.0 &
a1 0.90950000 0.00000000 .00000000 &
a2 0.00000000 0.78760000 .00000000 &
a3 .00000000 .00000000 1.00000000 &
basis 0.46990000 0.00000000 0.66666667 &
basis 0.00000000 0.46990000 0.33333333 &
basis 0.53010000 0.53010000 0.00000000 &
basis 0.41410000 0.26810000 0.78540000 &
basis 0.73190000 0.14600000 0.45206667 &
basis 0.85390000 0.58589999 0.11873333 &
basis 0.26810000 0.41410000 0.21460000 &
basis 0.58589999 0.85399999 0.88127777 &
basis 0.14600000 0.73190000 0.54793333

region box prism 0 1 0 1 0 1 -0.4547 0 0

create_box 2 box
create_atoms 1 box &
basis 1 1 &
basis 2 1 &
basis 3 1 &
basis 4 2 &
basis 5 2 &
basis 6 2 &
basis 7 2 &
basis 8 2 &
basis 9 2

mass 1 28.09
mass 2 16.0

group siliconatoms type 1
group oxygenatoms type 2

set group siliconatoms charge 2.4
set group oxygenatoms charge -1.2

kspace_style ewald/n 1.0e-4
pair_style buck/coul/long 10.0
pair_coeff 1 1 0.0 0.0001 0.0
pair_coeff 1 2 18003.7572 0.205205 133.5381
pair_coeff 2 2 1338.7730 0.362319 175.0000

variable density equal “(mass(all)*1.660538782) / (vol)”

thermo 1
thermo_style custom step temp etotal pe evdwl ecoul press vol lx ly lz v_density xy yz xz
dump 1 all xyz 1 alpha_quartz_bks.xyz

fix 1 all box/relax tri 0.0

#min_modify line quadratic
minimize 0 1.0e-1000 1000 1000

min_style hftn
minimize 0 1.0e-100 100000 100000

The minimizations give me a density of 2.75 g/cm^3 when it should be 2.65g/cm^3. The energies I get, however, are similar to the results I get from minimizations using BKS in other codes. I get -172.26397eV from Lammps and -175eV from other codes. I have tried minimizing with constant volume then, minimizing with fix box/relax and my results are getting much closer (energy:-174eV, density: 2.68g/cm^3). I was wondering if anyone has any reccomnmendations for doing constant pressure minimizations and could help me get the results I need.

Many thanks,
Tassem El-Sayed

Aidan may have some advice. But how do
you know the answer you are getting is "wrong"?
There is nothing that guarantees a particular force
field will produce a specific lattice constant, e.g.
one that matches experiment.

Steve

It sounds like you are getting numbers that are pretty close in both codes.
I would expect some variation with the choice of cut-off and kspace
accuracy. Instead of doing box relaxation, which is quite complicated, why
not compare the energy and stress tensor from both codes for a single
geometry. Make sure the geometries that you input to both codes match to
high precision.

Aidan

From: Steve Plimpton <[email protected]>
Date: Wed, 2 Mar 2011 07:05:52 -0700
To: Al-Moatasem El-Sayed <[email protected]...>, Aidan Thompson
<[email protected]>
Cc: "[email protected]" <[email protected]>
Subject: Re: [lammps-users] Constant pressure minimization for alpha quartz

Aidan may have some advice. But how do
you know the answer you are getting is "wrong"?
There is nothing that guarantees a particular force
field will produce a specific lattice constant, e.g.
one that matches experiment.

Steve

Hi,

I've been getting to grips with Lammps and I've been trying to minimize a
unit cell of alpha quartz under constant pressure to obtain optimum lattice
parameters and atom coordinates. I am using the Lammps code released on 9th
February 2011. I have tried various minimization techniques and using a
barostat but to no avail. My input files are along the lines...

# Calculation of properties of alpha quartz using BKS potential and
minimization

units metal
newton on
atom_style charge
dimension 3
boundary p p p

lattice custom 5.4054 origin 0.0 0.0 0.0 &
a1 0.90950000 0.00000000 .00000000 &
a2 0.00000000 0.78760000 .00000000 &
a3 .00000000 .00000000 1.00000000 &
basis 0.46990000 0.00000000 0.66666667 &
basis 0.00000000 0.46990000 0.33333333 &
basis 0.53010000 0.53010000 0.00000000 &
basis 0.41410000 0.26810000 0.78540000 &
basis 0.73190000 0.14600000 0.45206667 &
basis 0.85390000 0.58589999 0.11873333 &
basis 0.26810000 0.41410000 0.21460000 &
basis 0.58589999 0.85399999 0.88127777 &
basis 0.14600000 0.73190000 0.54793333

region box prism 0 1 0 1 0 1 -0.4547 0 0

create_box 2 box
create_atoms 1 box &
basis 1 1 &
basis 2 1 &
basis 3 1 &
basis 4 2 &
basis 5 2 &
basis 6 2 &
basis 7 2 &
basis 8 2 &
basis 9 2

mass 1 28.09
mass 2 16.0

group siliconatoms type 1
group oxygenatoms type 2

set group siliconatoms charge 2.4
set group oxygenatoms charge -1.2

kspace_style ewald/n 1.0e-4
pair_style buck/coul/long 10.0
pair_coeff 1 1 0.0 0.0001 0.0
pair_coeff 1 2 18003.7572 0.205205 133.5381
pair_coeff 2 2 1338.7730 0.362319 175.0000

variable density equal "(mass(all)*1.660538782) / (vol)"

thermo 1
thermo_style custom step temp etotal pe evdwl ecoul press vol lx ly lz
v_density xy yz xz
dump 1 all xyz 1 alpha_quartz_bks.xyz

fix 1 all box/relax tri 0.0

#min_modify line quadratic
minimize 0 1.0e-1000 1000 1000

min_style hftn
minimize 0 1.0e-100 100000 100000

The minimizations give me a density of 2.75 g/cm^3 when it should be
2.65g/cm^3. The energies I get, however, are similar to the results I get
from minimizations using BKS in other codes. I get -172.26397eV from Lammps
and -175eV from other codes. I have tried minimizing with constant volume
then, minimizing with fix box/relax and my results are getting much closer
(energy:-174eV, density: 2.68g/cm^3). I was wondering if anyone has any
reccomnmendations for doing constant pressure minimizations and could help
me get the results I need.

Many thanks,
Tassem El-Sayed

----------------------------------------------------------------------------->>