CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Am getting very strange pressure/velocity problems at the inlet after a while (https://www.cfd-online.com/Forums/openfoam-solving/219411-am-getting-very-strange-pressure-velocity-problems-inlet-after-while.html)

avc18 July 25, 2019 16:53

Am getting very strange pressure/velocity problems at the inlet after a while
 
5 Attachment(s)
Dear all,

I have been trying for a while now to simulate a 2D incompressible flow past a square cylinder using k-omega model and to obtain convergency. After creating the blockMesh and 0 files and system directories, I have managed to get the simulation started and it works fine for a while, but then it starts working wrong.

avc18 July 25, 2019 16:55

part_2
 
5 Attachment(s)
Here are the rest of the files from OpenFoam.

Thank you very much.

anon_q July 25, 2019 17:18

What is goining wrong?

avc18 July 25, 2019 18:00

5 Attachment(s)
First of all, thank you for your reply. I will upload some screenshots with the flow development for U,p and k in order to show you exactly what i get.

wyldckat July 25, 2019 18:51

Quick answers:
  1. Velocity and pressure are both being enforced on the inlet boundary, which can result in an inconsistent resolution of the equations. Usually we set the velocity at the inlet and the pressure at the outlet.
  2. Pressure is set to 1e5, but the solver simpleFoam seems to be used. You should not use total pressure, you should use the pressure value in reference to 1e5... in other words, use pressure field initially set to 0.

avc18 July 25, 2019 19:01

Ahhhh, i didn't think about total pressure. Thank you very much, I will start the simulation again, hopefully this time works.



In addition to my previous question, is it possible to define the inlet as a single patch? Instead of doing it block by block, just define the upper and lower edger for the whole inlet.

wyldckat July 25, 2019 19:45

Quick answers:
Quote:

Originally Posted by avc18 (Post 740060)
In addition to my previous question, is it possible to define the inlet as a single patch? Instead of doing it block by block, just define the upper and lower edger for the whole inlet.

Either you would have to use snappyHexMesh or use topoSet+subsetMesh+createPatch.

If you want to use only blockMesh... uh... Maybe use Blender with the SwiftBlock add-on? https://openfoamwiki.net/index.php/Contrib/SwiftBlock

avc18 July 26, 2019 18:48

Thank you for your reply.



I have tried what you said about total pressure and the simulation is still not working. I get the same problem after a number of iterations.

sheaker July 27, 2019 03:26

Hello.


Why You are using those velocity and pressure inlets and outlets?


I think Your simulation crashes when pressure wave reach inlet.



Try to use different velocity and pressure inlet BC.
https://www.openfoam.com/documentati...conditions.php


Search for Inlet and Outlet BC.


For example:
Quote:

outletInlet
This boundary condition provides a generic inflow condition, with specified outflow for the case of reverse flow

wyldckat July 27, 2019 09:29

Quick suggestion: This blog post has a ton of information on how to set-up these kinds of simulations: http://matveichev.blogspot.com/2014/...ex-street.html


All times are GMT -4. The time now is 16:03.