QuantumATK Forum

QuantumATK => General Questions and Answers => Topic started by: svollebregt on September 1, 2010, 09:33

Title: Very slow Ni convergence
Post by: svollebregt on September 1, 2010, 09:33
I have problems with the convergence of a Ni system consisting of 90 atoms configured in a two layer slab model with some vacuum space in between. I'm using the double zeta polarized basis set (also tried the double zeta double polarized set, without improvement) and tried several different values for the k point sampling (from 4, 4, 1 to 10, 10, 1 with increments of 2). I also tried extending the cut-off energy from the default 75 Hartree to 150 Hartree. Decreasing the electron temperature to 10 K gave no improvement. However, when I increased the temperature to 1000 K for the first time the system converged within 100 steps (to be precise: in 98 steps using k=661 and a cut-off of 150 Hartree). When I increased the k points to 8, 8, 1 the system didn't convergence within 100 steps, however.

Are there more settings I could try to speed up convergence? I used a similar system for Cu, Pd and Al and none of those materials had convergence issues (although Pd took about 60 steps to convergence vs ~30 for Cu and Al). I want to optimize the geometry of this system, and that is going to take ages if the system converges this slow.

I attached the configuration to my post.
Title: Re: Very slow Ni convergence
Post by: Anders Blom on September 1, 2010, 10:02
Ni is naturally spin-polarized, so I would run it as such ;)
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 1, 2010, 13:37
Is the attached script the correct way to run spin-polarized calculations? Is there a procedure in setting the initial spin?
Title: Re: Very slow Ni convergence
Post by: Anders Blom on September 1, 2010, 14:00
Check the isolated Ni atom first, that gives you an idea of the initial spin. But starting at 1. should normally work fine, it should relax quite fast.

You can make the script a bit more clever by using

Code: python
initial_spin = InitialSpin(scaled_spins=[1.0,]*len(elements))
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 1, 2010, 14:17
I'm currently running the above script, but after 84 steps there is still no sign of convergence.
Title: Re: Very slow Ni convergence
Post by: Anders Blom on September 1, 2010, 14:32
Try reducing the number of history steps to 4. We had some success with that for Cu, perhaps Ni has a similar feature, which is that the atomic and "configuration" electronic structure is very different. Having a long mixing history makes it harder to "forget" the atomic structure.
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 2, 2010, 09:26
Unfortunately reducing the history to 4 didn't help either, would changing the damping factor help (now 0.2)? It seems from the output that the system gets close to the total energy, but keeps oscillating quite extensively around it (dE is  the order of eV and also the dH term is big, in the order of 10^1).

I will now try to see what happens when I increase the history, comparing the output to the standard history it seems that the shorter history actually worsened the convergence. At default I could see the delta terms go down, but at a sudden point increase again.
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 2, 2010, 14:34
Increasing the history to 15 seems to improve, as the dE term now actually manages to reach the set limit of 1e-06. However, the dH term keeps oscillating and doesn't become smaller than the set limit.
Title: Re: Very slow Ni convergence
Post by: nori on September 3, 2010, 06:04
Please try attached.
I could get the system converged with it in 69 steps.

Please note that exchange_correlation(LSDA or SGGA) must be designated explicitly in the script in order to do spin-polarized calculation properly.
Title: Re: Very slow Ni convergence
Post by: Nordland on September 3, 2010, 19:50
I have also tried to create a Nickel 3x3 slap and it converges as well for me using just LDA.
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 7, 2010, 09:39
This is strange... I ran the 3x3_slap file and it didn't converge on my system. I'm running ATK 10.8.0 on 3 systems, each 2 cores. I attached the output to this post. It seems that the dE term gets small enough, however the dH term never reaches the default accuracy.
Title: Re: Very slow Ni convergence
Post by: Anders Blom on September 7, 2010, 12:29
My suspicion is that this is related to MPI. You run your calculations in parallel, while Nordland ran in serial, am I right?

If so, a fix is both identified and implemented, and will be released later this week, hopefully.
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 7, 2010, 16:48
Running a non-threaded simulation now. Will take some time but tomorrow I will know the outcome.
Title: Re: Very slow Ni convergence
Post by: Anders Blom on September 7, 2010, 16:50
Threading is not the issue, the bug is in the MPI code. So you need to run it in serial, without any mpiexec.
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 8, 2010, 09:20
I ran it only on my main node, so without mpiexec, and still Nordlands configuration doesn't converge within 100 steps. The output is again attached.
Title: Re: Very slow Ni convergence
Post by: Nordland on September 8, 2010, 09:58
Hmm... I will try to rerun it.
Title: Re: Very slow Ni convergence
Post by: Nordland on September 8, 2010, 13:44
I have found the problem. The 3x3 slap attached to my original post, is the same configuration as you used.
Here I have build the system from scratch in VNL to make the same system as you have done.
Using all default parameters and 3x3x1 kpoints it converged in 94 steps. I have attached the output and input.
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 8, 2010, 16:36
It is running (there is a small error in the file regarding the PulayMixer which was set as a function (so I removed the () behind the setting), lets see if I get the same results.

Are those orbital settings the default ones, or did you customize them for a specific reason? Also I seem to get an ' isabs' related error when I try to view the configuration using the VNL Viewer. Any idea where that is comming from?
Title: Re: Very slow Ni convergence
Post by: Anders Blom on September 8, 2010, 16:54
The isabs error comes from VNL trying to resolve the location of the pseudopotential; the only way to avoid it is to remove the whole basis set definition. However, I'm happy to tell you that the error has been resolved in version 10.8.1, scheduled for release very soon (this week if we're not unlucky in testing it).
Title: Re: Very slow Ni convergence
Post by: Nordland on September 8, 2010, 18:27
It is running (there is a small error in the file regarding the PulayMixer which was set as a function (so I removed the () behind the setting), lets see if I get the same results.

Are those orbital settings the default ones, or did you customize them for a specific reason?
Good spotted. In the new version the () is allowed on the PulayMixer. The orbital is default settings - doublezetapolarized - I just exported all the detail from the scripter in order to be sure that I could control all things exactly, if it did not work as intended. However the only parameter I adjusted was the k-points.

In general I think it is important to always using a k-point sampling that will included the gamma point so I always use odd numbers.
Title: Re: Very slow Ni convergence
Post by: svollebregt on September 10, 2010, 09:10
Strangely enough the script '3x3slap.py'  again doesn't converge within 100 steps, both for parallel as serial calculations.