Openfoam optimization question
I've been doing some simulations in openfoam using the rhoSimpleFoam solver. The geometry is a convergent-divergent nozzle with approximate dimensions of 20 mm by 4 mm by 2 mm. Air is blown in through the inlet on one side and there is an outlet on the other side and I observe the results.
The issue I am having is that with a mesh of a million cells, it takes four days for my simulation to give good results. That's far too long. I know that the same simulation takes 8 hours in solidWorks using 8 processors. I am also using 8 processors using the 'simple' decomposition scheme. Can anybody think of any optimizations I can make? Or Is there a general consensus that OF is slower than solidWorks or other CFD packages?
Any help of comments would be appreciated. Please let me know if you would like me to post additional information.
You are doing something seriously wrong.
First off, I would decompose it with scotch.
Even 8 hours sounds a bit long to me, but then again I dont know your hardware.
Thanks for saying that, It gives me a lot more hope. I'm using the mac port of openfoam (OF 1.7.x) so I'm not quite sure how I'll get the scotch decomposition scheme running here, but I think I should be able to figure it out.
What I just did that was a little eye opening was that I increased my relaxation factors by a lot and it gave me an improvement by a factor of ~ 300!!!
Now I just have to figure out how to chose optimal relaxation factors for different mesh sizes. Any suggestions?
Thanks again! :)
depends on scheme, flow and mesh quality how aggressive you can be.
I prefer slow convergence before the oscillating behavior you get with too high under-relaxation.
I usally use
and the rest 0.3
check the convergence history with
set logscale y
plot "logs/p_0" using 1:2 with lines
|All times are GMT -4. The time now is 10:23.|