NAN result in the half of the simulation at high angle of attack

Hi everyone, I simulate the flow over NACA0012 airfoil with Reynold number of 150000, which use the system of ac-navier-stokes. I’ve already got convergent solution at low angle of attack. However, when just increase the angle of attack in the ini file to 10 degree or more, the simulation gets NAN values after a quite long time. When I check the residual, I found that the residual converge to 0.03-0.04 at first. However, it did’t decrease but increase extremely slowly which maintain 0.1-0.2 for a long time before divergence. And finally, it suddenly diverged in a very short time.
Does anyone encounter the same situation? Any ideas on why this is happening? Is the result calculated before divergence valuable? Looking forward to your help.

It sounds like you might need to reduce the tolerences on the pseudo-time stepper. What generally happens when the tolerence isn’t low enough is you get a slow acumulation of error until a point where the pseudo stepper is no longer able to converge the system at all and then the error will rapidly grow until it NaNs.

At higher angles of attack you will probably see separated flow and these are harder to solve with more elements with large gradients, which is why I think you’re only seeing this in the higher angle case.

Thanks, Will. Do you mean to adjust the parameters of atol or pseudo-resid-tol or both? Is there any tips to choose the appropriate tolerances?

I mean you need to tweak pseudo-resid-tol.

You can actually set the tollerence of each parameter individually e.g. by using pseudo-resid-tol-p. The pressure tolerence is the most critical as it dictates how divergence free the veloicty field is. What value to use is dependent on the zeta and the simulation, but have a look at the output from the residual plugin. When you plot it, if you see the pressure residual creeping up over time, then you need to reduce it.

Hi,Will. I’ve already reduce the pseudo-resid-tol. And the residual can actually decrease more to approximately 0.01-0.02. However, it still creeps up slowly after that, even though I modify the pseudo-resid-tol to 1e-30 or lower.Are there any other parameters I should also modify to ensure convergence?

What have you set the maximum number of pseudo iterations to be? Are you using P-multigrid? Are you using variable local pseudo time stepping

Hi,Will. I set the maximum number of pseudo iterations to 15-20. I’m not using P-multigrid, just simple O-grid.There’s no variable local pseudo time stepping. Because I’m new to PyFR. The ini file is very similar to the example of 2D-cylinder-flow. Should I use the variable local pseudo time stepping?

So if I’m not mistaken, O-grid is a way of generatng a mesh of a domain. P-multigrid is a converngence accleration method when solving systems of equations. Checkout this paper:

If you are just using pseudo-time stepping without P-multigrid or variable local time stepping, then a maximum of 15-20 pseudo iteraions is unlikely to be enough, again you can see this from the residual tolerence. Have a look to see if you are actaully going below the tolerence you set.

You should really enable P-multigrid and variable local time stepping.