[CP2K-user] [CP2K:10804] Re: Problem in the preconditioner when using UKS
Krack Matthias (PSI)
matthia... at psi.ch
Thu Oct 4 13:09:51 UTC 2018
Dear Daniele
I am not aware of any control key to stop an SCF run as soon as the electron count becomes unreasonable. It shouldn’t be too difficult, however, to implement such a control. The use of an outer SCF should converge faster in most cases. Did you try already a different preconditioner like FULL_SINGLE_INVERSE with OT CG and an outer SCF? If such choice does not result in a robust convergence behaviour then you are dealing with problematic systems which you can hardly run in a black-box manner.
Best,
Matthias
From: cp... at googlegroups.com <cp... at googlegroups.com> On Behalf Of Daniele Ongari
Sent: Donnerstag, 4. Oktober 2018 14:47
To: cp2k <cp... at googlegroups.com>
Subject: Re: [CP2K:10804] Re: Problem in the preconditioner when using UKS
Thank you a lot!
This was a very good hint. Indeed, it is clear from the "Total charge density on r-space grids" that something is going weird with the count of electron as soon as the energy starts to diverge!
$egrep 'outer SCF|Total charge density on r-space grids' diis.out
diis.out: Total charge density on r-space grids: 0.0000001146
diis.out: outer SCF iter = 1 RMS gradient = 0.47E-04 energy = -1301.1851926636
diis.out: Total charge density on r-space grids: 0.0000001146
diis.out: outer SCF iter = 2 RMS gradient = 0.42E-04 energy = -1301.2195780393
diis.out: Total charge density on r-space grids: 0.0000001047
diis.out: outer SCF iter = 3 RMS gradient = 0.14E-05 energy = -1301.2275937198
diis.out: Total charge density on r-space grids: 0.0003332641
diis.out: outer SCF iter = 4 RMS gradient = 0.62E-05 energy = -1301.2754195817
diis.out: Total charge density on r-space grids: -0.0424028684
diis.out: outer SCF iter = 5 RMS gradient = 0.96E-04 energy = -1318.9753098223
diis.out: Total charge density on r-space grids: 0.5522536311
diis.out: outer SCF iter = 6 RMS gradient = 0.13E-03 energy = -1317.2906799313
diis.out: Total charge density on r-space grids: 3.4918015156
diis.out: outer SCF iter = 7 RMS gradient = 0.52E-03 energy = -1315.3866686940
diis.out: Total charge density on r-space grids: 4.3723629910
diis.out: outer SCF iter = 8 RMS gradient = 0.97E-03 energy = -1298.6196710054
diis.out: Total charge density on r-space grids: 9.1128313578
diis.out: outer SCF iter = 9 RMS gradient = 0.20E-02 energy = -1284.6336624946
diis.out: Total charge density on r-space grids: 8.4010321552
diis.out: outer SCF iter = 10 RMS gradient = 0.20E-02 energy = -1278.9516795867
diis.out: Total charge density on r-space grids: 7.2155551466
diis.out: outer SCF iter = 11 RMS gradient = 0.20E-02 energy = -1285.4339788964
diis.out: outer SCF loop FAILED to converge after 11 iterations or 550 steps
I'm now wondering: is there a way to stop CP2K as soon as the "Total charge density on r-space grids" exceeds a threshold (let's say 1.0) to avoid wasting time and switch to the CG algorithm without outer SCF?
I'm using this 2 step protocol for high-throughput DFT calculations, therefore it would be helpful not to waste time!
Regards,
Daniele
Il giorno mercoledì 3 ottobre 2018 21:45:20 UTC+2, Matthias Krack ha scritto:
Dear Daniele
You should take note of the electron count in the OT DIIS output and ask yourself, if the corresponding energy has any meaning.
The OT CG run converged to some state at least.
HTH
Matthias
Von: cp... at googlegroups.com<javascript:> <cp... at googlegroups.com<javascript:>> Im Auftrag von Daniele Ongari
Gesendet: Mittwoch, 3. Oktober 2018 19:47
An: cp2k <cp... at googlegroups.com<javascript:>>
Betreff: [CP2K:10799] Re: Problem in the preconditioner when using UKS
[Screenshot from 2018-10-03 19-42-55.png]
Hi,
here I come with a similar problem for Co-MOF-74 using different settings.
In the legend of the figure:
"diis" is using OT DIIS with 50 inner and 10 outer SCF cycles
"cg" is using OT CG with 2000 inner and no outer SCF cycles
I think the problem is related to the bandgap going close to zero and making the preconditioner to diverge, but this time the energy assumes even lower energies than the final ones.
Does it makes sense to have a lower energy being DFT not strictly variational, and this should be seen as a merely mathematical mess?
The calculation is converging when I run the OT CG minimization without outer steps: can I consider the final result of this calculation as reliable?
Thanks
Daniele
Il giorno mercoledì 19 settembre 2018 12:50:34 UTC+2, Daniele Ongari ha scritto:
Dear CP2K developers,
I want to report a serious problem with the preconditioner when computing the energy of Fe-MOF-74 with UKS settings.
Long story short the energy goes down, it is close to convergence but then, after recomputing the preconditioner in the outer step it starts to diverge: see the image.
[image.png]
Now, I attached the input and the output, but I already tried very different settings:
-smearing
-diagonalization without smearing
-different BS
-UKS false (converged, but to a higher energy, forcing the closed shell)
- starting magnetization on metals
- CG minimizer
- lower multiplicity
- 2x and 3x replicated unit cell in the shortest dimension
- lowering ENERGY_GAP to 0.001
These calculation ALL failed (I made 16 attempts in total, changing settings!).
And at the end the only one working (the 17th attempt, ironically the unlucky number for Italians!) was to use CG minimizer with no outer SCF, hence not recomputing the preconditioner. It converged after ~600 inner steps, to:
HOMO - LUMO gap [eV] : 1.917671
HOMO - LUMO gap [eV] : 0.235602
ENERGY| Total FORCE_EVAL ( QS ) energy (a.u.): -1170.045288008604075
Please let me know what was the problem, if it is a known issue of the preconditioner and how to circumvent it: for the moment I'm using no outer steps to have a robust convergence, but I know that this may cause the convergence to a local miniimum!
Thanks a lot!
Daniele
PhD candidate, LSMO, EPFL Sion
--
You received this message because you are subscribed to the Google Groups "cp2k" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cp2k+... at googlegroups.com<javascript:>.
To post to this group, send email to cp... at googlegroups.com<javascript:>.
Visit this group at https://groups.google.com/group/cp2k.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "cp2k" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cp2k+uns... at googlegroups.com<mailto:cp2k+uns... at googlegroups.com>.
To post to this group, send email to cp... at googlegroups.com<mailto:cp... at googlegroups.com>.
Visit this group at https://groups.google.com/group/cp2k.
For more options, visit https://groups.google.com/d/optout.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.cp2k.org/archives/cp2k-user/attachments/20181004/10a0f0d1/attachment.htm>
More information about the CP2K-user
mailing list