week1/ 0000755 0057645 0005735 00000000000 11231410403 012165 5 ustar democritos guest week1/day1/ 0000755 0057645 0005735 00000000000 11231410256 013031 5 ustar democritos guest week1/day1/exercise2/ 0000755 0057645 0005735 00000000000 11230010103 014704 5 ustar democritos guest week1/day1/exercise2/k-point-path 0000644 0057645 0005735 00000001213 11230010103 017137 0 ustar democritos guest 36 0.5 0.5 0.5 1 0.4 0.4 0.4 2 0.3 0.3 0.3 3 0.2 0.2 0.2 4 0.1 0.1 0.1 5 0.0 0.0 0.0 6 0.0 0.0 0.1 7 0.0 0.0 0.2 8 0.0 0.0 0.3 9 0.0 0.0 0.4 10 0.0 0.0 0.5 11 0.0 0.0 0.6 12 0.0 0.0 0.7 13 0.0 0.0 0.8 14 0.0 0.0 0.9 15 0.0 0.0 1.0 16 0.0 0.1 1.0 17 0.0 0.2 1.0 18 0.0 0.3 1.0 19 0.0 0.4 1.0 20 0.0 0.5 1.0 21 0.0 0.6 1.0 22 0.0 0.7 1.0 23 0.0 0.8 1.0 24 0.0 0.9 1.0 25 0.0 1.0 1.0 26 0.0 0.9 0.9 27 0.0 0.8 0.8 28 0.0 0.7 0.7 29 0.0 0.6 0.6 30 0.0 0.5 0.5 31 0.0 0.4 0.4 32 0.0 0.3 0.3 33 0.0 0.2 0.2 34 0.0 0.1 0.1 35 0.0 0.0 0.0 36 week1/day1/exercise2/dos.in 0000644 0057645 0005735 00000000156 11230010103 016023 0 ustar democritos guest &INPUTPP prefix = 'Si_exc2' Emin = -6.00, Emax = 10.00 DeltaE = 0.001, fildos = 'dos.dat' / week1/day1/exercise2/day1_exercise2_instructions.html 0000644 0057645 0005735 00000062676 11230010103 023246 0 ustar democritos guest
INSTRUCTIONS FOR DAY 1, EXERCISE 2
Note that the following color code has been used in this instruction sheet:
Broad headings are in red.
File names are in magenta,
Phrases to be typed into the command line are in blue.
Input parameters are in dark green.
In this exercise, we will examine some of the 'post-processing' that you can do once you have run your scf calculations.
In the previous exercise, there was only one output quantity that we cared about ...the total energy. Here we will see some other things that we can extract from the files produced when one does a PW calculation...e.g., charge densities, and eigenvalues (which we will use to get band structure plots and densities of states). We will continue to work with Si,
which was the subject of exercise1.
Go to the directory day1/exercise2 (if you are not already there!)
You will see the following files:
day1_exercise2_instructions.html this file!
Si.scf.in this is an input file for scf calculations.
bands.in this is an input file for collecting bands.
k-point-path this is a file containing list of k-points along symmetry directions in Brillouin zone.
Si.plotband.in this is an input file for putting band structure data into a plottable format.
Si.pp_rho.in this is an input file to extract charge density using post-processing.
Si.plotrho.in this is an input file to plot charge density.
dos.in this is an input file to calculate density of states.
Self-consistent (scf) calculations for Si
Open and read the sample file Si.scf.in
We chose values of celldm(1) , ecutwfc, nk1, nk2 and nk3 based upon our results for exercise1. You may choose the same values as these, or substitute your values.
Run the scf calculation:
$pw.x < Si.scf.in > Si.scf.out
A) Band structure of Si -
Calculations for bands
Copy Si.scf.in to Si.band.in
Edit Si.band.in to perform non-self consistent calculations that will be used to obtain band structure, by setting calculation='bands'.
Add the parameter in &SYSTEM namelist called nbnd = 8 to specify the number of bands computed. Note that for a 2-atom Si cell, we have 8 electrons and therefore only 4 occupied bands, but we are going to compute some extra (empty) bands.
Define the K_POINTS card to specify the path along symmetry directions in Brillouin zone. In order to this, you can use the information supplied in the file called k-point-path, which contains a list of k-points along high symmetry directions in the BZ, i.e., L (½, ½, ½) to Gamma (0, 0, 0) to X (0, 0, 1) to W (0, ½, 1) to X (0, 1, 1) to Gamma (0, 0, 0). You can paste that file to Si.band.in after the K_POINTS card.
Run a 'bands' calculation:
$pw.x < Si.band.in > Si.band.out
What differences do you see between the output file you obtain here, and the output file that you obtained from your scf calculation?
Collect band results for plotting
Open bands.in
Note that you have to use the same prefix in this calculation as was used in scf AND bands calculations.
The flag filband defines the name of the file in which bands data is stored.
Run:
$bands.x < bands.in > bands.out
Have a look at bands.out and bands.dat and note the minimum and maximum energy eigenvalues at different k-points.
Get the data in a format to plot
Open Si.plotband.in
The first line contains (a) input file (= bands.dat obtained in the earlier step).
Then (b) Emin and Emax (= -6.00 and 10.00).
(c) output file in xmgrace format (bands.xmgr)
(d) output file in ps format (bands.ps)
(e) Fermi energy (= 6.337 eV)
(f) deltaE and reference energy (= 1.00 6.337)
Run the plotting program:
$plotband.x < Si.plotband.in > Si.plotband.out
You can view the plotted band structure written in ps format (bands.ps) using a postscript viewer (e.g., ghostview or ggv).
B) Charge density for Si -
Post-processing to extract charge density
Open Si.pp_rho.in
Make sure that the value of prefix is the same as the values as were used in scf calculations.
filplot = 'Si.charge' saves the extracted charge density and is used for plotting by defining filepp(1) = 'Si.charge' and the data to be plotted in written in fileout='Si.rho.dat'.
plotnum = 0 indicatesthat the quantity to be extracted is the charge denisty (for other possible options, see INPUT_PP.* in the directory Doc in the espresso package).
iflag and output_format specify the dimensionality for the plot.
e1(i) and e2(i) (i = x, y and z) are 3D vectors that determine the plotting plane and must be orthogonal to eact other.
nx and ny are number of points in the plane.
Run post-processing code:
$pp.x < Si.pp_rho.in > Si.pp_rho.out
Plot the extracted charge density
Open Si.plotrho.in
The first line contains the name of the output file from the earlier step (Si.rho.dat)
The second line contains the name of the file to which output is to be written, that is Si.rho.ps (in ps format).
Run the plotting code:
$plotrho.x < Si.plotrho.in > Si.plotrho.out
Use ghostview or ggv to view the charge density of Si.
C) Density of states plot for Si -
nscf calculations for DOS
Copy Si.scf.in to Si.nscf.in
Change the flag calculation='nscf'
Change the number of bands to add a few empty states in the namelist &SYSTEM (nbnd = 8).
Define occupations='tetrahedra' in the namelist &SYSTEM.
Modify the K_POINTS card from “6 6 6 1 1 1” to “12 12 12 1 1 1”, this is because we now want to compute eigenvalues on a finer mesh in k-space.
Remember that the same wavefunctions (as obtained from scf calculations) have to be used, so do NOT change prefix.
Run the nscf calculations:
$pw.x < Si.nscf.in > Si.nscf.out
DOS calculations
Open dos.in
Make sure that it has the same prefix as used in the scf calculations.
The DOS results are written in fildos = (dos.dat)
Run density of states calculations:
$dos.x < dos.in > dos.out
Have a look at dos.out and the data file dos.dat.
Plot dos.dat to see the DOS plot (you can use gnuplot or xmgrace programs).