CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (http://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Strange Result for Versteeg Testcase (2D, convection only, steady state) (http://www.cfd-online.com/Forums/openfoam-solving/91578-strange-result-versteeg-testcase-2d-convection-only-steady-state.html)

caramelo August 16, 2011 03:42

Strange Result for Versteeg Testcase (2D, convection only, steady state)
 
Hi everybody,

I'm new to OpenFOAM and tried to implement a testcase from the Versteeg and Malalasekera book[1]. GoogleBooks

To solve the problem I used the scalarTransportFoam solver and set DT = 0 as it is a convection only problem. I used the boundary condition from the book except for the two outlet patches, where I used zeroGradient for phi.

The result I get are quite normal as long as I don't reach a certain number of cells. For example if my domain is 1 x 1 m and I use more than 21 cells in the x_1 and the x_2 direction the result is completely instable and has nothing to do with the analytic solution. I solved the div(phi,T) term with Gauss linear. But the solution doesn't converge either if I use QUICK or vanLeer to compute the gradient. Only upwind always give a reasonable but not really accurate solution.

Does anybody have an idea what problem is?

Thanks in advance.

caramelo

santiagomarquezd August 16, 2011 14:16

Can you post an sketch of the problem and BC's used?

Regards.

caramelo August 16, 2011 15:45

1 Attachment(s)
You can see a sketch in the GoogleBooks links i posted. I just added the whole case as an attachment. With this setting you will get a reasonable result. If you now increase the numbers of cells in the blockMeshDict, no reasonable result will be received any more.

l_r_mcglashan August 16, 2011 17:17

When you get finer grid cells, I think there's an issue with the Courant number for non-upwind schemes. Try changing ddtSchemes to Euler and make the endTime in controlDict something like 2; I get 'better' results with that.

I note that:

"At the first and last nodes where the diagonal intersects the boundary a value of 50 is assigned to \phi."

Might that be an issue?

alberto August 17, 2011 17:55

It is simply a question of conditioning of the linear problem you are trying to solve. You would need under-relaxation (have to modified the code adding T.relax()) to use the code as steady state.

Alternatively, simply perform a pseudo-transient simulation, as suggested by Laurence, since the effect is the same as under-relaxing.

P.S. It is not a problem in the schemes ;-)

Best,


All times are GMT -4. The time now is 08:19.