VASP Computing Elastic Constants of Au: Difference between revisions

From Micro and Nano Mechanics Group
Jump to navigation Jump to search
Line 85: Line 85:


E=`tail -1 OSZICAR`
E=`tail -1 OSZICAR`
echo $a $E | sed -s 's/F=//; s/E0=//; s/d E =//;' >> Elatt.B.dat
echo $a $E | sed -s 's/F=//; s/E0=//; s/d E =//;' >> Elatt.C11.dat


p=`grep pressure OUTCAR | cut -b 25-34`
p=`grep pressure OUTCAR | cut -b 25-34`
echo $a $p >> platt.B.dat
echo $a $p >> platt.C11.dat


done
done

Revision as of 02:43, 26 August 2015

VASP: Computing Elastic Constants of Au


Input files

(Under construction!!!)

Here we give an example of how to use VASP to compute the elastic constants C11 and C44 of LDA-Au. We performed this calculation on MC-CC in PARALLEL model in the ~/Codes/VASP/runs/Au/LDA/perfect.21x21x21 directory. This directory contains the following files.

INCAR

ENCUT  =  400 or 500??
ISIF = 2 ! It relaxes atoms but keep cell volme fixed!
ISMEAR  = 1
SIGMA = 0.1

KPOINTS

21x21x21
0        0 = automatic generation of k-points
Monkhorst
21 21 21
0 0 0

POSCAR

POSCAR for FCC Au (created manually)
 POSCAR for FCC Au
4.062241         from acurate VASP lattice calculation
 1.000  0.0 0.0     first  Bravais lattice vector
 0.0 1.0 0.0     second Bravais lattice vector
 0.0 0.0 1.0     third  Bravais lattice vector
 4               number of atoms per species
selective dynamics
direct           direct or cart (only first letter is significant)
  0.00000  0.00000  0.00000 T T T
  0.50000  0.50000  0.00000 T T T
  0.00000  0.50000  0.50000 T T T
  0.50000  0.00000  0.50000 T T T

To do this calculation, you also need to put the LDA pseudopotential file as POTCAR in this directory.

Run VASP

Now we are ready to run

vasp

To compute the elastic constants we use the following script auto.B.serial to run vasp repeated with different values for the first C11 component of the first Bravais lattice vector. Make sure you have previously calculated the euqilibrium lattice constant for this supercell with 4 atoms, otherwise error in the calculations could arise.

#!/bin/bash
rm WAVECAR 
for a in 0.997 0.998 0.999 1.000 1.001 1.002 1.003
do
cat > POSCAR << FIN
POSCAR for FCC Au
4.062241         from acurate VASP lattice calculation
 $a  0.0 0.0     first  Bravais lattice vector
 0.0 1.0 0.0     second Bravais lattice vector
 0.0 0.0 1.0     third  Bravais lattice vector
 4               number of atoms per species
selective dynamics
direct           direct or cart (only first letter is significant)
  0.00000  0.00000  0.00000 T T T
  0.50000  0.50000  0.00000 T T T
  0.00000  0.50000  0.50000 T T T
  0.50000  0.00000  0.50000 T T T
FIN

echo "a=$a"
./vasp

E=`tail -1 OSZICAR`
echo $a $E | sed -s 's/F=//; s/E0=//; s/d E =//;' >> Elatt.C11.dat

p=`grep pressure OUTCAR | cut -b 25-34`
echo $a $p >> platt.C11.dat

done

Analyze data

After running it as ./auto.B.serial, it will create data files Elatt.C11.dat and platt.C11.dat.

Launch octave and run the following functions fit_a0EB.m and fit_a0B.m,

fit_a0EB('Elatt.B.dat');
fit_a0B ('platt.B.dat');

The first line fits the energy data to a quadratic curve and computes the equilibrium lattice constant, cohesive energy and bulk modulus. (Refer to previous calculation?!) The second and third lines compute the elastic constants C11 and C44 which the results 214 GPa and 42 GPa respectively.

Parallel computation

To run vasp in parallel, you need to submit vasp.pbs as

qsub vasp.pbs


You will need the following two files to do this calculation in parallel on SU-AHPCRC: auto.B.par and B.pbs.