Dear developers,
As I mentioned earlier (viewtopic.php?f=10&t=1153), I found that ABINIT (both 6.2.2 and 6.8.1) gives wrong linear optical spectrum in several 1D systems by using the usual procedures. Here I elaborate this issue with a simple example of carbon chain.
The known procedures to get linear optical spectrum are as follows: (1) SCF calculation to get the electron density of ground state; (2) NSCF calculation to get wavefunction with denser k-point grid and more empty bands; (3) ddk calculation to get the derivatives of wavefunction with respect to k, and then using optic program to get the dielectric function.
In the case of carbon chain system, I find that the (2)-step must be SCF to get correct optical results, which are confirmed by calculations of YAMBO and CASTEP. To simplify the explanation, I did the following tests: (a) generate the KSS by using ABINIT, which also outputs WFK; (b) calculate the ddk and spectrum by using both ABINIT and YAMBO. I find that YAMBO gives correct spectrum whether the (a)-step is NSCF or SCF, while ABINIT give wrong result when the (a)-step is NSCF. This clearly shows that there must be some problem. Test files and comparison graph are attached for your confirmation.
An interesting phenomenon possibly indicates the cause: only 1 SCF step in (a) is enough for ABINIT to get correct result, though I also tried 1000 steps! Maybe the ddk calculation or optic analysis does get correct information from a NSCF wavefunction.
Because this ddk calculation and optic analysis are relevant to several other RF calculations, like IR and Raman, this issue really matters. I am looking forward to detail analyses from you.
Sincerely,
Guangfu Luo
P.S. I checked the file-header of the NSCF and SCF WFK and did find differences: in the NSCF WFK, there are 2 fully occupied bands (4 electrons) according to “occ”, while in the SCF WFK, there are 3 fully occupied bands (6 electrons). The unit cell contains only 1 carbon atom.
[SOLVED]Probable bug in the ddk calculation or optic analysi
Moderators: mverstra, joaocarloscabreu
[SOLVED]Probable bug in the ddk calculation or optic analysi
- Attachments
-
Carbon-chain-test.tar.bz2.in
- remove the suffix .in
- (207.9 KiB) Downloaded 296 times
Last edited by Robin on Fri Sep 02, 2011 3:39 am, edited 6 times in total.
Re: Probable bug in the ddk calculation
I'm not sure I understand your post fully. You suggest that you think that there is a problem in the ddk calculation, but as I read your post your tests involve how you determine the GS wavefunctions (SCF followed by NSCF, or SCF followed by a second SCF run). Concerning the DDK calculation itself, the equation being solved is a Sternheimer equation in which self-consistency is not an issue (right hand side is a constant, thus the calculation is inherently "non-self-consistent"). The DDK output has been checked quite thoroughly in both the norm-conserving and PAW cases against finite difference calculations. You can repeat these checks for your system, see test V3/test_09 for an example of how to do it.
Josef W. Zwanziger
Professor, Department of Chemistry
Canada Research Chair in NMR Studies of Materials
Dalhousie University
Halifax, NS B3H 4J3 Canada
jzwanzig@gmail.com
Professor, Department of Chemistry
Canada Research Chair in NMR Studies of Materials
Dalhousie University
Halifax, NS B3H 4J3 Canada
jzwanzig@gmail.com
Re: Probable bug in the ddk calculation
Dear Prof. Zwanziger,
Thanks for your reply. Actually, I followed the same procedures to do ddk calculation as the tutorials, and did get correct results for many systems. But in the 1D chain systems, I happened to notice that the usual procedure gave wrong results, which are confirmed by other programs. So I did lots of tests to locate the cause. Finally, after comparing the calculations by using YAMBO and ABINIT (since Yambo can use the wavefunction from ABINIT), I find that the ddk calculation probably does not get correct information from a NSCF (but SCF) wavefunction, at least in my case.
If you like, you can calculate the imaginary part of the dielectric function of the 1D carbon chain system in your own way. The structure is extremely simple: a carbon atom in the center of 10 x 10 x 1.2801 (angstrom) box.
Sincerely,
Guangfu Luo
Thanks for your reply. Actually, I followed the same procedures to do ddk calculation as the tutorials, and did get correct results for many systems. But in the 1D chain systems, I happened to notice that the usual procedure gave wrong results, which are confirmed by other programs. So I did lots of tests to locate the cause. Finally, after comparing the calculations by using YAMBO and ABINIT (since Yambo can use the wavefunction from ABINIT), I find that the ddk calculation probably does not get correct information from a NSCF (but SCF) wavefunction, at least in my case.
If you like, you can calculate the imaginary part of the dielectric function of the 1D carbon chain system in your own way. The structure is extremely simple: a carbon atom in the center of 10 x 10 x 1.2801 (angstrom) box.
Sincerely,
Guangfu Luo
Re: Probable bug in the ddk calculation
Yes, but did you do a finite difference check of the DDK output?
Josef W. Zwanziger
Professor, Department of Chemistry
Canada Research Chair in NMR Studies of Materials
Dalhousie University
Halifax, NS B3H 4J3 Canada
jzwanzig@gmail.com
Professor, Department of Chemistry
Canada Research Chair in NMR Studies of Materials
Dalhousie University
Halifax, NS B3H 4J3 Canada
jzwanzig@gmail.com
Re: Probable bug in the ddk calculation or optic analysis
Dear Prof. Zwanziger,
Thanks for your suggestion. But it is embarrassing that I do not know how to easily do a finite difference check on the ddk of wavefunction.
However, I did another test and find that the problem could be in the final optic analysis code rather than the ddk calculation. Since in optic analysis step, using ddk-from-NSCF-WFK and the SCF-WFK can also get the correct result.
Sincerely,
Guangfu Luo
Thanks for your suggestion. But it is embarrassing that I do not know how to easily do a finite difference check on the ddk of wavefunction.
However, I did another test and find that the problem could be in the final optic analysis code rather than the ddk calculation. Since in optic analysis step, using ddk-from-NSCF-WFK and the SCF-WFK can also get the correct result.
Sincerely,
Guangfu Luo
Re: [SOLVED]Probable bug in the ddk calculation or optic ana
Dear All,
I disscussed the problem with Matthieu in another post, and as him pointed out, the occupations in SCF and NSCF WFK are different. After switching iscf=-2 to iscf=-3 (the later initializes occ and wtk), I got correct optical spectra.
The cause could be the incorrect band filling in the WFK from iscf=-2, which subsequently causes incorrect electron transition in the optic analysis.
Sincerely,
Guangfu Luo
I disscussed the problem with Matthieu in another post, and as him pointed out, the occupations in SCF and NSCF WFK are different. After switching iscf=-2 to iscf=-3 (the later initializes occ and wtk), I got correct optical spectra.
The cause could be the incorrect band filling in the WFK from iscf=-2, which subsequently causes incorrect electron transition in the optic analysis.
Sincerely,
Guangfu Luo