TABLE OF CONTENTS
35a-pdos-CaF2
DESCRIPTION
This example shows how to calculate and plot PDOSes and LDOSes. The structure considered is a bulk CaF2.
The meaning of LDOS & PDOS is taken from projwfc.x, i.e.:
- PDOS = DOS projected to a given atomic orbital
- LDOS = \sum_i PDOS_i, where PDOS_i are orbital-projected DOSes in the pdos_atm file, e.g., LDOS(p) = PDOS(px) + PDOS(py) + PDOS(pz)
EXAMPLE SOURCE FILE
SOURCE
# the pw.x input data CONTROL { pseudo_dir = './pseudo' } SYSTEM { A = 5.511 ibrav = 2 nat = 3 ntyp = 2 nbnd = 16 ecutwfc = 40 ecutrho = 320 } ELECTRONS { conv_thr = 1e-8 } ATOMIC_SPECIES { Ca 1.0 Ca.pbe-spn-kjpaw_psl.1.0.0.UPF F 1.0 F.pbe-n-kjpaw_psl.1.0.0.UPF } ATOMIC_POSITIONS alat { Ca 0.0 0.0 0.0 F 1/4 1/4 1/4 F 3/4 3/4 3/4 } K_POINTS automatic {4 4 4 1 1 1} # the projwcf.x specs PROJWFC { ngauss = 0 degauss = 0.01 DeltaE = 0.05 } # calculate Projected DOSes (PDOSes) with the ::pwtk::pdos_run workflow; # calculated PDOSes and LDOSes will be plotted into a default window terminal (-t win) # # Options: # * the -scf option requests the SCF pw.x calculation # * the -nscf {8 8 8} requests the NSCF pw.x calculation with a denser non-shifted 8x8x8 k-mesh pdos_run -scf -nscf {8 8 8} -t win CaF2 # with the above command, the projwfc.x has created the following PDOS files: # CaF2.pdos_atm#1(Ca)_wfc#1(s) --> projection to Ca 3s # CaF2.pdos_atm#1(Ca)_wfc#2(s) --> projection to Ca 4s # CaF2.pdos_atm#1(Ca)_wfc#3(p) --> projection to Ca 3p # CaF2.pdos_atm#1(Ca)_wfc#4(p) --> projection to Ca 4p # CaF2.pdos_atm#2(F)_wfc#1(s) --> projection to 1st F 2s # CaF2.pdos_atm#2(F)_wfc#2(p) --> projection to 1st F 2p # CaF2.pdos_atm#3(F)_wfc#1(s) --> projection to 2nd F 2s # CaF2.pdos_atm#3(F)_wfc#2(p) --> projection to 2nd F 2p # whereas total DOS was written to: # CaF2.pdos_tot # Summing PDOS files: # we can sum PDOS files using convenient ::pwtk::sumldos and ::pwtk::sumpdos # or explicit ::pwtk::sumldosFiles and ::pwtk::sumpdosFiles # to get DOS projected to Ca, we need to sum the following files: # CaF2.pdos_atm#1(Ca)_wfc#1(s) # CaF2.pdos_atm#1(Ca)_wfc#2(s) # CaF2.pdos_atm#1(Ca)_wfc#3(p) # CaF2.pdos_atm#1(Ca)_wfc#4(p) # this can be achieved with the following ::pwtk::sumldos command: sumldos -s Ca Ca; # the result will be written to the 'Ca' file # likewise for F-projected DOS, we need to sum: # CaF2.pdos_atm#2(F)_wfc#1(s) # CaF2.pdos_atm#2(F)_wfc#2(p) # CaF2.pdos_atm#3(F)_wfc#1(s) # CaF2.pdos_atm#3(F)_wfc#2(p) # which can be achieved with: sumldos -s F F # # let's also obtain DOS projected to Ca 3s, 3p, 4s, 4p and F 2s, 2p states # # DOS projected to Ca states: # the following commands are not really needed, they are used to # get simpler and more readable filenames sumldosFiles CaF2.pdos_atm#1(Ca)_wfc#1(s) Ca-3s; # this only copy CaF2.pdos_atm#1(Ca)_wfc#1(s) to Ca-3s sumldosFiles CaF2.pdos_atm#1(Ca)_wfc#2(s) Ca-4s sumldosFiles CaF2.pdos_atm#1(Ca)_wfc#3(p) Ca-3p sumldosFiles CaF2.pdos_atm#1(Ca)_wfc#4(p) Ca-4p # DOS projected to F states: # there are two F ions, hence we need to sum them; this can be # aschieved either with ::pwtk::sumldosFiles or ::pwtk::sumldos sumldosFiles { CaF2.pdos_atm#2(F)_wfc#1(s) CaF2.pdos_atm#3(F)_wfc#1(s) } F-s ## the equivalent command using ::pwtk::sumldos is: sumldos -s F -l s F-s sumldosFiles { CaF2.pdos_atm#2(F)_wfc#2(p) CaF2.pdos_atm#3(F)_wfc#2(p) } F-p ## the equivalent command using ::pwtk::sumldos is: sumldos -s F -l p F-p # we have summed the files above, now let's plot these LDOSes in a # multi-plot using ::pwtk::ldos_multiplot # # (the Fermi energy, i.e. the highest occupied level in this case, # will be taken from the pw.CaF2.nscf.out file, -e pw.CaF2.nscf.out) ldos_multiplot -e pw.CaF2.nscf.out -t win { CaF2.pdos_tot {Ca F} {Ca-3s Ca-4s Ca-3p Ca-4p} {F-s F-p} } CaF2 # to plot into a PDF, use -t pdf ldos_multiplot -e pw.CaF2.nscf.out -t pdf { CaF2.pdos_tot {Ca F} {Ca-3s Ca-4s Ca-3p Ca-4p} {F-s F-p} } CaF2