judging convergence through residuals
I am using Fluent, and as many users do, I often monitor convergence (at least partially) by monitoring the residuals. I think that many CFD users can get confused about exactly what the residuals mean. I am occasionally one of those users.
In theory, residuals are just the change from one iteration to the next. As a solution converges one would expect the residuals to drop such that there is no change from iteration n to n+1. But that can be misleading. For example, as you drop the under-relaxation factors, residuals drop. At first glance one could say "it is converging better!" without that being the case. Taking this to the extreme... If UR factors are dropped to 0.001, the solution simply isnt progressing, almost at all. Therefore the residuals will drop to approx. machine precision. My ultimate point is that, residuals can mean many things, from "the solution is converged" to "the solution is not progressing". Or, when the residuals are constant at a higher value, that "the solution is changing consistently or oscillating". So my ultimate question is, are there any good ways to weed out some of these issues? Yes, I like most people set surface monitors and judge those for convergence, but I want this conversation to remain about residuals. Are there any experts out there with some insight into this matter? I would be interested in having some discussion. |
Good issue!
Assuming for example a system in the form A.x = q, x is the exact solution, at a generic iteration k you have: rk = A . xk - q while you can see that xk+1 - xk = A^-1 . (rk+1 - rk ) Therefore, the conclusion is that one must never use the difference xk+1 - xk ... |
Thank you both so much for your replies! They both help clarify this issue quite a bit for me. I have used CFD for some time, and now I am really trying to get back into understanding the mathematics as I think that will really help my quality of results. Thanks again!
|
I suggest that in addition the residual monitoring you'll also check global balances (e.g., mass, momentum and energy over the entire domain). This will help you to see if your solution is reasonable and not just frozen due to low relaxation. Another measure is indeed the change between subsequent iterations.
|
So that is what I was looking for, additional checks to deterine whether it is converged or not progressing. When you say check global mass balance and energy etc, is there a good way to do that? Is it simple checking mass flow at inlet and outlet? Or is there some sort of volume integral. As well, is there a way to check difference in flow solution between iterations? I know Fluent is doing some normalization, would it be beneficial to stop it from doing this? I have run into slight issues where *I thought* I was not getting a good convergence on residuals, but it was just that I had used an fmg initialization, so my initial condition was very good.
Thanks again for your help, this has been extremely informative. Merry Christmas! |
In Fluent you can report the net mass flow through all inlets and outlets, which should sum to something near zero. Look for this under the monitors menu. You can also get it not to normalize residuals under the same menu by opening up the residuals panel. In general the normalization is good, otherwise residual levels are completely problem dependent. When they are normalized they are only somewhat problem dependent.
|
I am not an expert in Fluent ... but for me the balance between inlet and outlet is of lesser meaning in checking the real convergence ..
|
All times are GMT -4. The time now is 11:38. |