# The static QSGW self-energy editor and some Applications of it

This tutorial presents various applications of the editor for the QS*GW* static derived from the dynamical one. Note that QS*GW* has two forms of the self-energy, the “quasiparticlized” form , which is a nonlocal but static, and which corresponds to a one-particle approximation to the full interacting self-energy. In the QS*GW* context there is a fully dynamical self-energy from which the static QS*GW* is derived. To see how to make and analyze the dynamical self-energy, see this page.

This tutorial documents the static Σ^{0}(**k**) editor, and presents applications that require its use.

In more detail, Questaal has two self-energy editors corresponding to the two forms of self energy in QS*GW*:

a static self-energy Σ

^{0}(**k**) that substitutes for the exchange-correlation potential in LDA, GGA, Hartree-Fock or LDA+*U*theory. Σ^{0}(**k**) is static and hermitian, and generates a noninteracting hamiltonian*H*_{0}and a corresponding noninteracting Green’s function*G*_{0}. This potential is the primary output of the the QS*GW*cycle and Σ^{0}(**k**) (actually ) is saved on disk, usually in file*sigm.ext*. There are numerous ways to use and transform Σ^{0}; most are accomplished through the Σ^{0}(**k**) editor described here.a frequency-dependent, nonhermitian self energy Σ(

**k**,ω). The ω-dependence broadens the states; the non-hermitian part gives the quasiparticle a finite lifetime. This is not generated automatically, but must be done using a special setup, as described in this tutorial. Once the dynamical Σ(**k**,ω) is made, there is a corresponding dynamical self-energy editor to facilitate analysis.

*Note:* this page is under construction.

**Sheared GaSb**

Follow the steps that create input files and carry out QSGW self-consistency in the Command Summary of the superlattice tutorial.

The do:

lmscell gasb -vz=11.5/11.43 --stack~scale=1/z~stretch=z^3~wsitex@short lmf ctrl.gasb --wsig:fbz cp sigm2.gasb sigm.gasb cp sites.gasb site.gasb lmf ctrl.gasb --rsig:fbz:rlxkp --iactiv --wsig:newkp cp sigm2.gasb sigm.gasb lmgwsc --wt --insul=14 --mpi=12,12 --tol=2e-5 --sym --getsigp --save= gasb-shear gasb > out.job mpix -n 16 lmf-MPIK ctrl.gasb > out.lmf

### Table of Contents

- Preliminaries
- Change in sigma on Shearing Zincblende GaSb
- Reading and writing Real-Space sigm Files
- Spin Orbit Coupling in Fe
- As Antisite Defect
- Static Sigma Editor instructions
- Additional Exercises

### Preliminaries

This tutorial uses the MPI parallel form of *lmf*. It assumes a script *mpix* is present in your path that runs an MPI job with **#** processors as follows:

mpix -n # MPI-job

*mpix* can be simply *mpirun*.

If you have compiled *lmf* in serial mode, you can run the tutorials here in serial mode, by omitting the `mpix -n #`

.

### Change in sigma on Shearing Zincblende GaSb

Here we demonstrate how to modify the static self-energy in the presence of a lattice shear. The shear reduces the symmetry, and must be adapted accordingly. For demonstration purposes we build on the tutorial on building superlattices, and shear GaSb in the manner used in that tutorial.

Here we modify calculated for the zincblende lattice, using it as a starting point for a new QS*GW* with the sheared lattice. Of course the entire QS*GW* calculation could be redone from scratch, but with small shears like this one it is a reasonable approximation that the matrix elements of remain invariant under the shear. Here we will check how good that ansatz is. In any case the ansatz gives a good estimate for the self-consistent , avoiding the need to start from scratch.

To set up input conditions of the original zincblende structure, cut and paste the *init* file designed for InAs and GaSb shown in the superlattice tutorial and name it *init.gasb*. Then build the input file and carry out both LDA and QS*GW* self-consistency as described in detail in that tutorial. If you don’t want to read the tutorial, follow the instructions for Zincblende GaSb in the Command Summary, skipping the last part about drawing energy bands.

Assuming you followed instructions you will have run this step

```
mpix -n 16 lmf-MPIK ctrl.gasb > out.lmf
```

Find the gap :

```
grep gap out.lmf
```

You should find that the gap is 1.29 eV.

Now we are ready to make the shear. Use the superlattice editor built into *lmscell* to scale and stretch the lattice, so that (1) the basal plane matches that of InAs and (2) the shear conserves volume.

```
$ lmscell gasb -vz=11.5/11.43 --stack~scale=1/z~stretch=z^3~wsitex@short
```

In this instruction preprocessor variable ** z** is set to the ratio of GaSb and InAs lattice constants and:

**~scale=1/z**scales the lattice constant by**1/***z***~stretch=z^3**stretches the third lattice vector by*z*^{3}**~wsitex@short**saves the modified structure into into*site*file*sites.gasb*

The two scalings together preserve the volume.

Compare *sites.gasb* to *site.gasb* and note that that the lattice constant has been reduced while the third lattice vector **p3** has been stretched.

The shear reduces the symmetry. To obtain for reduced symmetry, first write for points in the full Brillouin zone. Then for the sheared lattice, read this and write it again under reduced symmetry.

```
lmf ctrl.gasb --wsig:fbz
cp sigm2.gasb sigm.gasb
cp sites.gasb site.gasb
lmf ctrl.gasb --rsig:fbz:rlxkp --iactiv --wsig:newkp
cp sigm2.gasb sigm.gasb
```

- Steps (1) and (2) generate a
*sigm.gasb*without any symmetry operations. - Step (3) replaces the
*site*containing the zincblende structure with the sheared structure - Steps (4) and (5) read
*sigm.gasb*for the full BZ and writes it for the reduced symmetry operations of the sheared lattice. Switch**--rsig:fbz:rlxkp**tells*lmf*that contains**k**points for the full Brillouin zone, and also to ignore the mismatch in the**k**sought and file values of**k**(**k**points are shifted because the lattice is sheared). Switch**--wsig:newkp**tells*lmf*to write for the symmetry of the sheared mesh.

Try running

```
mpix -n 16 lmf-MPIK ctrl.gasb --rs=1,0 -vnit=1 > out &
```

This segment of output shows the symmetry operations of the sheared lattice is much reduced from the 24 point group operations of the Zincblende lattice:

GROUPG: the following are sufficient to generate the space group: m(1,-1,0) m(1,-1,0)

This segment of output

iors : read restart file (binary, mesh density) remesh density from 20 * 20 * 20 to 20 * 20 * 21 use from restart file: ef window, pos(sheared), pnu ignore in restart file: *

indicates the given lattice is sheared relative to the contents in the restart file, *rst.gasb*. *lmf* can nevertheless read the file.

Look a little farther down can you can see the bandgap

VBmax = 0.097372 CBmin = 0.182519 gap = 0.085147 Ry = 1.15799 eV

With this ansatz for the gap is reduced from 1.29 eV to 1.16 eV.

Now make it self-consistent

```
lmgwsc --wt --insul=14 --mpi=12,12 --tol=2e-5 --sym --getsigp --save= gasb-shear gasb > out.job
mpix -n 16 lmf-MPIK ctrl.gasb > out.lmf
```

You should find that the ansatz for is very close to the self-consistent one:

```
$ grep more out.job
lmgwsc : iter 1 of 999 RMS change in sigma = 2.53E-05 Tolerance = 2e-5 more=T ...
lmgwsc : iter 2 of 999 RMS change in sigma = 5.58E-06 Tolerance = 2e-5 more=F ...
```

Run *lmf* with the self-consistent and find the gap once again

```
mpix -n 16 lmf-MPIK ctrl.gasb --rs=1,0 -vnit=1 > out.lmf &
grep gap out.lmf
```

It should be essentially unchanged from the 1.16 eV found earlier. See also Additional Exercises.

### Reading and writing Real-Space sigm Files

Files associated with this tutorial are too large to be included with the basic distribution. Download and unpack the tarball *FeTutorial.tar.gz* and change to directory * fetutorial*.

cp input/* . cp bas2.tppc3.tpd4.sep12/rst.fe . cp bas2.tppc3.tpd4.sep12/nk12/* . ln -s -f sigm sigm.fe

If your computer hardware does not not-use-ieee-conventions-for-binary-files, see here before proceeding.

Verify that the input conditions result in a self-consistent potential.

rm -f mixm.fe log.fe mpix -n 12 lmf -vnit=1 --rs=1,0 ctrl.fe `cat switches-for-lm` > out.noso.001

If you want to carry out a corresponding LDA calculation, do:

cp bas2.tppc3.tpd4.sep12/rst.lda rst.fe rm -f mixm.fe log.fe mpix -n 12 lmf -vsig=0 -vnit=1 --rs=1,0 ctrl.fe `cat switches-for-lm` > out.noso.lda.001

Problems arise if you try to include use the given self-energy in a calculation with lower symmetry, e.g. a shear distortion or the addition of spin-orbit coupling. It immediately appears if you repeat the calculation *lmf* with spin-orbit coupling on (note tag **SO** in the input file!):

lmf -vso=1 -vnit=1 --rs=1,0 ctrl.fe `cat switches-for-lm`

This is because by the given Σ^{0}_{xc} is stored on a mesh of *k*-points. SO coupling reduces symmetry and requires that Σ^{0} be available on a different *k*-mesh.

You can work around this by saving Σ^{0} in a real space form; that is, map Σ^{0}_{RL,R′L′}(**k**) to Σ^{0}_{RL,R′L′}(**T**) = Σ^{0}_{R+TL,R′L′}. **T** is a crystal lattice translation vector; there are as many **T**-points as **k** points in *k*-space. The transformation is exact and no information is lost. (It is accomplished in practice using FFT techniques, and the original Σ^{0}_{RL,R′L′}(**k**) can be recovered by a Bloch sum.) Once generated Σ^{0}(**T**) doesn’t depend on the number of *k*-points, so it is preferable in this context even while it is less compact.

### Spin Orbit Coupling in Fe

### As Antisite Defect

*Note:* Other delimiters may be used in place of ** @ ** assumed below,

Here we build

### Static Sigma Editor instructions

This section documents the instruction set of static self-energy editor, built into *lmf*. You can operate it in interactive mode or in batch mode, or a mix, as described below.

Instructions are separated by a delimiter, the first character after the instruction (assumed in this documentation to be **”~”**).\

Instructions are separated by a delimiter, the first character after **--wsig** (assumed in this documentation to be **”~”**). Instructions often have optional arguments, also separated by a delimiter, the first character after the instruction (assumed in this documentation to be **”@”**).\

*Note:* if you are operating the editor in batch mode, take care to differentiate the delimiters separating instructions from those separating optional arguments to an instruction.

**Interactive mode**- To operate
*lmscell*in interactive mode, invoke`lmf --wsig~edit`

You should see:

Welcome to the static self-energy file editor. Enter '?' to see options. Option :

The editor operates interactively. It reads a command from standard input, executes the command, and returns to the

**Option**prompt waiting for another instruction.

The editor will print a short summary of instructions if you type**? <RET>**.

**Batch mode**- You can also run the editor in batch mode by stringing instructions together separated by a delimiter, e.g.
`lmf --wsig~edit~spin@zers~q`

The delimiter (

**~**in this case), as the first character following**--wsig**.*lmf*will parse through all the commands sequentially until it encounters “quit” instruction (**~q**) which causes it to exit. If no such instruction is encountered,*lmf*returns to the interactive mode.

**Preliminaries**

The real space form of the static Σ^{0}(**R,R’**) is accessible to edits. This consists of blocks connecting one site to another, given by the neighbor table. The neighbor table consists of a long list of pairs (pair-list) connecting two sites. Sites ib and jb are used below to denote the first and second sites in pair-list.

You can edit subsets of pair-list or the all of of them Σ^{0}. There are various ways to specify the subset: they are given by specifying a set of conditions, called **CONDITION** below. For each pair if **CONDITION** is met, the pair is included in the subset.

**CONDITION** appears as an argument to several of the instructions.

Use ‘*****’ or ‘**−**’ to specify all pairs, or choose some combination of the following:

- Either (or neither) of:
- ib=site-list must be in cluster centered at site ib
- ip=pair-list must be in pair-list

With this option you can additionally impose: - jb=site-list site for 2nd element in pair must be jb
- jbx=site-list site for 2nd element in pair must not be jb

- Any (or none) of:
- onsite connecting vector must be zero
- offsite complement of onsite
- ib==jb center and neighbor have same site index
- ib<>jb complement of ib==jb

- Tags r< and r> impose constraints on range:
`r<#1 [p<#2 p1,p2,p3]`

pairs separated by distance r<#1`r>#1 [p<#2 p1,p2,p3]`

pairs separated by distance r>#1

Optional`p<#2 p1,p2,p3`

Both sites in the pair must be within neighborhood of fixed (p1,p2,p3), i.e. for each site, d = |(px-p1,py-p2,pz-p3)| where (px,py,pz) = site position.

- Conjugate pairs are assigned the status of the original

noconj suppresses this constraint

*Example:* `ib=2,3 r<.45 p<.45 -.25,-.25,-.25`

**Instructions**

**sum [#[,#]]**: summarizes site pair table. Optional [#,#] gives detailed information about a specific range of pairs**sum ib=#1,#2**: shows hamiltonian subblocks for sites in (#1,#2)**sum ib**: summarizes hamiltonian subblocks for all sites**scell[options] snam**: map Σ^{0}into a supercell specified by site file*snam*.

Options:**@sigq**writes sigma(k)**@sigrs**writes sigma(T)**@range=#**limits the range of sigma(T) when matching**@nq=#,#,#**sets the supercell k mesh

**sigbar #1 [#2]**set avg sigma for high-lying states. Use argument #2 in spin polarized case**rssave [fn]**write rs sigma Σ^{0}to file. If not specified, file name is*rssigm*.**readx [fn]**read rs sigma and associated files to auxilliary storage for subsequent pasting into Σ^{0}. If not specified, file name is*rssigm*.**merge [sigbar] site-list**merge pairs in Σ^{0}x to corrresponding pairs in Σ^{0}for all pairs connected to sites in site-list**merge [sigbar] 0**merge Σ^{0}x into Σ^{0}for all pairs in common. Optional ‘-sigbar’ imports avg sigma from auxilliary filereducing size of rs sigma

The following instructions use **CONDITION** noted above. **pairc** is used to create a permanent list which becomes the default for other instructions. For any instruction you can create a temporary list. If you don’t specify a temporary list, the permanent list is used if it is defined; otherwise the list becomes the entire pair list.

**pair[options] [CONDITION]**

Set permanent pair list according to**CONDITION**. If**CONDITION**is absent all pairs are included.**shows[options] r1,r2,c1,c2 [CONDITION]**

Shows r1,r2,c1,c2 orbital subblock of sigma, for a range of pairs. Substitute ‘-‘ for r1,r2,c1,c2 to print entire orbital block.**spin[options] [CONDITION]**

For spin manipulations. Select one of the following options:**@flip[=list]**exchanges (up,down) spins**@zers[=list]**zero out spin-up - spin-dn**@zerq[=list]**zero out spin-up + spin-dn

Optional**list**performs function for pairs in list

**zero[options] [CONDITION]**

Zero Σ^{0}for pairs specified by**CONDITION**

Options:**@short**reduce size of pair table and Σ^{0}

**showp[options] [CONDITION]**

List attributes of pairs satisfying**CONDITION**

Options:**@rms**also print rms sum of elements for each pair**@sum**print summary information only

#### Computers that do not use IEEE conventions for binary files.

Files *sigm._ext* and *rst._ext* are stored in binary form following IEEE conventions. If your computer doesn’t read binary files in this format, do the following additional steps:

cp bas2.tppc3.tpd4.sep12/rsta.fe.gz . gunzip rsta.fe.gz gunzip sigma.fe.gz lmf -vnit=0 --rs=2,1 ctrl.fe `cat switches-for-lm` lmf ctrl.fe `cat switches-for-lm` --rsig:ascii --wsig cp sigm2.fe sigm

### Additional Exercises

For the GaSb shear demo, compare energy bnds for the ansatz and the self-consistent one. You should find them nearly identical.