Do any DFT codes (for example, QE ABINIT, Fleur, ....) provide the availability of getting the DOS that produced by each iteration? If no, so, how can I get them?
Thanks in advance!
Matter Modeling Stack Exchange is a question and answer site for materials modelers and data scientists. It only takes a minute to sign up.Sign up to join this community
Since FLEUR was mentioned in the question I give an answer for that DFT code...
In FLEUR we distinguish between SCF calculations and calculations on the DOS for a density that is already available. In DOS calculations we therefore don't create a new charge density. The reason for the different treatment is that one typically has different demands on certain parameters for DOS and for SCF calculations. Most importantly for creating a (high-quality) DOS it may be required to use a finer k-point sampling or a different Brillouin zone integration method. I sketched the special requirements for DOS calculations in the FLEUR user documentation.
On the other hand, the calculation of the DOS in FLEUR only requires the presence of some density. This may even be the initial starting density (in the case of FLEUR this is a superposition of atomic densities). The density does not necessarily have to be self-consistent. If a DOS in every iteration is wanted, one could thus create a workflow around the actual FLEUR calculation to achieve this task. This is similar to the other answer by XYZ CIF for the TURBOMOLE code. More specifically one could either write a simple script that executes FLEUR repeatedly with alternating input files to perform a single SCF iteration, followed by a DOS calculation, or one could integrate such an approach into an AiiDA workflow. For this we offer an AiiDA-FLEUR interface.
Usually, the density of states (DOS) is calculated for the converged SCF calculation. However, to address your unique goal you might try TURBOMOLE. Since you mentioned QE, ABINIT, etc. I assume you want to do it for periodic systems.
[riper] module allows to perform periodic DFT calculations.
This module considers the density of states as a property calculation. What this means is that given the files of a previous SCF calculation, it can read the bands information and calculate the density of states from that.
Keeping this in mind you can employ the following trick to calculate the DOS at each iteration of the SCF.
Set the maximum number of SCF iterations to 1 (
Run DFT calculation (
nohup riper > output_iter_1).
Run DOS calculation with the command line argument
nohup riper -proper > riper.out &).
This will give you the DOS for the first SCF iteration.
Next, repeat the above process with
$scfiterlimit 2. The good thing about
riper is that it will restart automatically from where the previous calculation left off.
So ultimately, you can keep increasing the max SCF iterations and you will be able to achieve what you wanted.
I assume, that something similar can be achieved with Quantum ESPRESSO as well, because as far as I can recall, the SCF is performed with
pw.x while DOS calculations is done with another binary.