Difference between revisions of "Calculating optical spectra including excitonic effects: a step-by-step guide"
(→Links) |
|||
(42 intermediate revisions by 6 users not shown) | |||
Line 1: | Line 1: | ||
This tutorial guides you through the workflow of a calculation of the optical spectrum of a given material by solving the Bethe-Salpeter equation. | |||
Specifically, we will use [[Bulk material: h-BN|bulk h-BN]] as an example. | |||
[[File:HBN-bulk-3x3-annotated.png|x200px|center|Atomic structure of bulk hBN]] | |||
Before starting, you need to obtain the tarballs for hBN. See instructions on the [[Tutorials|main tutorials page]]. | |||
The target quantity in a Bethe-Salpeter calculation is the macroscopic dielectric matrix ε<sub>M</sub>. The following quantities/steps are needed to obtain ε<sub>M</sub>: | |||
[[File:Scheme1b.png|500px|center|BSE calculation scheme]] | |||
The optical absorption spectrum corresponds to Imε<sub>M</sub>(ω). Following this scheme we go through the flow of a calculation: | |||
__TOC__ | __TOC__ | ||
===Step 1: Static screening=== | |||
Use the ''SAVE'' folders that are already provided and type: | |||
$ cd YAMBO_TUTORIALS/hBN/YAMBO | |||
Follow the '''[[Static screening]]''' module and then '''return to this tutorial ''' | |||
===Step 2: Bethe-Salpeter kernel=== | |||
Follow the module on '''[[Bethe-Salpeter kernel]]''' and '''return to this tutorial''' | |||
===Step 3: Diagonalisation of the excitonic Hamiltonian === | |||
This is the step in which you obtain the spectra. Mathematically this implies solving a large eigenvalue problem. In this tutorial, we diagonalise the whole Bethe-Salpeter matrix, but there are other numerical approaches available in Yambo. The difference between these approaches and when they should be used is the object of [[BSE solvers overview|one of the next tutorials]]. | |||
Follow the module on '''[[Bethe-Salpeter solver: diagonalization]]''' then '''return to this tutorial''' | |||
===Step 4: Include previous quasiparticle (GW) results === | |||
In Step 3, we included the quasiparticle corrections to the Kohn-sham energies as a scissor operator. An alternative is to use the results from a previous run of Yambo. | |||
Follow the module on '''[[Bethe-Salpeter on top of quasiparticle energies]]''' and '''return to this tutorial''' | |||
==Links== | |||
* Back to [[Rome 2023#Tutorials]] | |||
* [[Modules|Back to technical modules menu]] | |||
* [[Tutorials|Back to tutorials menu]] | |||
<!-- | |||
= Calculating the effective two-particle Hamiltonian = | = Calculating the effective two-particle Hamiltonian = | ||
Line 40: | Line 62: | ||
1 | 40 | | 1 | 40 | | ||
% | % | ||
[[Variables#NGsBlkXs|NGsBlkXs]]= | [[Variables#NGsBlkXs|NGsBlkXs]]= 4 Ry | ||
The first variable gives how many bands are included in the sum to calculate the static response function. The second is a cutoff for the dimension of the static dielectric matrix. | The first variable gives how many bands are included in the sum to calculate the static response function. The second is a cutoff for the dimension of the static dielectric matrix. | ||
Line 53: | Line 75: | ||
Run the calculation by invoking yambo: | Run the calculation by invoking yambo: | ||
$ yambo | $ yambo -F 01_3D_BSE_screening.in -J 3D_BSE | ||
In the log (l_em1s) of the calculation you can see that after calculating the dipole matrix elements, for each q vector yambo calculates the IP response function and by inversion the RPA response function | In the log (l_em1s) of the calculation you can see that after calculating the dipole matrix elements, for each q vector yambo calculates the IP response function and by inversion the RPA response function | ||
Line 88: | Line 110: | ||
[[Variables#BSENGexx|BSENGexx]] = 30 Ry | [[Variables#BSENGexx|BSENGexx]] = 30 Ry | ||
[[Variables#BSENGBlk|BSENGBlk]] = | [[Variables#BSENGBlk|BSENGBlk]] = 4 Ry | ||
% [[Variables#BSEBands|BSEBands]] | % [[Variables#BSEBands|BSEBands]] | ||
6 | 10 | | 6 | 10 | | ||
Line 112: | Line 134: | ||
Run the calculation by invoking yambo in the command line: | Run the calculation by invoking yambo in the command line: | ||
$ yambo | $ yambo -F 02_3D_BSE_kernel.in -J 3D_BSE | ||
In the log (either in standard output or in l_optics_bse_bsk), after various setup/loading, the kernel is calculated: | In the log (either in standard output or in l_optics_bse_bsk), after various setup/loading, the kernel is calculated: | ||
Line 140: | Line 162: | ||
(1) diagonalize the full Hamiltonian (diagonalization solver) | (1) diagonalize the full Hamiltonian (diagonalization solver) | ||
(2) use the subspace iterative [https://en.wikipedia.org/wiki/Lanczos_algorithm| Lanczos algorithm] and by-pass diagonalization with the Haydock approach<ref>R. Haydock, in | (2) use the subspace iterative [https://en.wikipedia.org/wiki/Lanczos_algorithm | Lanczos algorithm] and by-pass diagonalization with the Haydock approach<ref>R. Haydock, in | ||
''Solid State Phys.'', '''35''' 215 (1980) | ''Solid State Phys.'', '''35''' 215 (1980) | ||
edited by H. Ehrenfest, F. Seitz, and D. Turnbull, Academic Press</ref> (Lanczos-Haydock solver) | edited by H. Ehrenfest, F. Seitz, and D. Turnbull, Academic Press</ref> (Lanczos-Haydock solver) | ||
Line 237: | Line 259: | ||
<01s> [06.01] Haydock solver | <01s> [06.01] Haydock solver | ||
<01s> [Haydock] Iteration 1 | <01s> [Haydock] Iteration 1 | ||
<03s> [Haydock] Iteration | <03s> [Haydock] Iteration 21 Accuracy : 0.01647| -0.02000 | ||
... | ... | ||
The Lanczos-Haydock iterative procedure converged to the desired accuracy in | The Lanczos-Haydock iterative procedure converged to the desired accuracy in 21 iterations. | ||
This runs only produces human readable files. That means that if you changes the input parameters (such as the broadening or the energy range) the Lanczos-Haydock procedure has to be repeated. | This runs only produces human readable files. That means that if you changes the input parameters (such as the broadening or the energy range) the Lanczos-Haydock procedure has to be repeated. | ||
Line 272: | Line 294: | ||
<01s> [06.01] Haydock solver | <01s> [06.01] Haydock solver | ||
<01s> [Haydock] Iteration 1 | <01s> [Haydock] Iteration 1 | ||
<06s> [Haydock] Iteration | <06s> [Haydock] Iteration 45 Accuracy : 0.0098| 0.02000 | ||
... | ... | ||
Now | Now 45 iterations, rather than 21, were needed to reach the desired accuracy. | ||
By plotting these results: | By plotting these results: | ||
$ gnuplot | $ gnuplot | ||
Line 284: | Line 306: | ||
==Reading the QP corrections from a previous ''GW'' calculation== | ==Reading the QP corrections from a previous ''GW'' calculation== | ||
In the above calculation we have used a simple scissor operator to correct the Kohn-Sam DFT energies. In this part we see how we can instead take the corrections from a previous Yambo Gw calculation. | |||
We create and edit the input. This time instead of proceeding in three steps as before, we create one input performing all three steps: | |||
$yambo -o b -k sex -y d -V qp -F Ins/05_3D_QP_BSE.in | |||
We set all parameters as in the previous calculation, except for the part regarding the QP correction: | |||
[[Variables#KfnQPdb|KfnQPdb]]= "E < 3D_QP_BSE/ndb.QP" # [EXTQP BSK BSS] Database | |||
[[Variables#KfnQP_N|KfnQP_N]]= 1 # [EXTQP BSK BSS] Interpolation neighbours | |||
% [[Variables#KfnQP_E|KfnQP_E]] | |||
0.000000 | 1.000000 | 1.000000 | # [EXTQP BSK BSS] E parameters (c/v) eV|adim|adim | |||
% | |||
Instead of setting the values for the scissor, we give the path to a database (3D_QP_BSE/ndb.QP) which contains the QP corrections. This has been created by running a GW calculation as in the [[How to obtain the quasi-particle band structure of a bulk material: h-BN |GW tutorial]]. | |||
Run Yambo: | |||
$ yambo -F Ins/05_3D_QP_BSE.in -J "3D_QP_BSE,3D_BSE" | |||
This produces the following log in the standard output. Note Section 4 (regarding external QP corrections to the kernel): | |||
<01s> [04.01] External QP corrections (K) | |||
<01s> [QP@K] E<3D_QP_BSE/ndb.QP[ PPA XG:39 Xb:1 40 Scb:1 40] | |||
<01s> [QP] Kpts covered exactly [o/o]: 100.0000 | |||
This tells you that the file was found, read correctly and that the '''k''' points found in the file matched the ones you are using for the current calculation (otherwise interpolation would be needed). | |||
It is crucial to check that the file has been read, since if not Yambo gives a warning but continues the calculation (with no QP corrections at all!). | |||
As in the previous calculation the final results of the calculation are the files with the spectral functions. Let's compare the results for the optical absorption spectrum with those obtained previously with a simple scissor: | |||
$ gnuplot | |||
... | |||
plot 'o-3D_QP_BSE.eps_q1_diago_bse' u 1:2 w l t 'Explicit QP', 'o-3D_BSE.eps_q1_diago_bse' u 1:2 w l t 'Scissor' | |||
[[File:03 bse diago qp.png|none|600px]] | |||
It is clear that this makes a difference in the peak distribution and intensity. Note that beside a simple shift you can renormalise as well the bandwidth of the valence and conduction bands in KfnQP_E (respectively the third and second value). You can try as an exercise to set up a new calculation using e.g. 1.440000 | 1.200000 | 0.900000 | for KfnQP_E. | |||
=References = | =References = | ||
<references /> | <references /> | ||
--> |
Latest revision as of 14:08, 19 May 2023
This tutorial guides you through the workflow of a calculation of the optical spectrum of a given material by solving the Bethe-Salpeter equation. Specifically, we will use bulk h-BN as an example.
Before starting, you need to obtain the tarballs for hBN. See instructions on the main tutorials page.
The target quantity in a Bethe-Salpeter calculation is the macroscopic dielectric matrix εM. The following quantities/steps are needed to obtain εM:
The optical absorption spectrum corresponds to ImεM(ω). Following this scheme we go through the flow of a calculation:
Step 1: Static screening
Use the SAVE folders that are already provided and type:
$ cd YAMBO_TUTORIALS/hBN/YAMBO
Follow the Static screening module and then return to this tutorial
Step 2: Bethe-Salpeter kernel
Follow the module on Bethe-Salpeter kernel and return to this tutorial
Step 3: Diagonalisation of the excitonic Hamiltonian
This is the step in which you obtain the spectra. Mathematically this implies solving a large eigenvalue problem. In this tutorial, we diagonalise the whole Bethe-Salpeter matrix, but there are other numerical approaches available in Yambo. The difference between these approaches and when they should be used is the object of one of the next tutorials.
Follow the module on Bethe-Salpeter solver: diagonalization then return to this tutorial
Step 4: Include previous quasiparticle (GW) results
In Step 3, we included the quasiparticle corrections to the Kohn-sham energies as a scissor operator. An alternative is to use the results from a previous run of Yambo.
Follow the module on Bethe-Salpeter on top of quasiparticle energies and return to this tutorial
Links