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/)
-   -   Pressure in Channel with simpleFoam and cyclic (https://www.cfd-online.com/Forums/openfoam-solving/143786-pressure-channel-simplefoam-cyclic.html)

ArathoN November 2, 2014 18:30

Pressure in Channel with simpleFoam and cyclic
 
4 Attachment(s)
I've done some simulations over a channel using RANS models first with pimpleFoam however because of some problems i switched to simpleFoam (here the thread i created for pimple link)with cyclic Boundaries. I noticed:
  1. it's hard to lower the residuals of pressure and Uy. Tightening the fvsolution tolerances and lowering aspect ratio may help. For Re=15000 this approach worked and the residual decrease to 1e-6 however for Re=64000 i couldn't accomplish this no matter what scheme or IC i've put.
  2. the profile of the Uy and p residuals present an oscillatory behavior they systematically have peaks.
  3. The pressure field is weird (see pictures LS stand for launderSharmaKE and SSY for kOmegaSST) i don't know why it is like that
  4. tHe pressure gradient at the first step is always high and Ubar is alway low after some time they will stabilize.

Does any of you have an explanation about this p field? I'm really lost here.

For the info on the flow i'll link the other thread link

RodriguezFatz November 4, 2014 07:23

2 Attachment(s)
Hey,

I see the same for a periodic pipe, LaunderSharmaKE
Attachment 34802
Attachment 34801
This is a cut through the (short) pipe. Upper profile is "U", flow goes in "x"-direction. X-direction is very poorly resolved by the mesh (see the lower pressure profile). Here you also see the wiggles.

ArathoN November 4, 2014 17:40

I refined the mesh along x and y direction but the pressure still had that same behavior. I searched more on the forum and in the net but didn't find anything useful. Maybe The pressure gradient source is bugged with simpleFoam, I'll check my case with pimplefoam and report back.

rolloblues November 7, 2014 10:08

2 Attachment(s)
This is what my residuals and middle plane profiles of velocity and pressure look like (simpleFoam, Re=44000 approx)

The inlet patch is at the bottom and it is mapped with the top outlet patch.
I didn't use cyclic boundary conditions for inlet and outlet since it would have killed the pressure gradient between in and out.

If you did maybe that's the reason for those strange behaviours. Infact especially in ArathoN's there is barely any pressure gradient at all

ArathoN November 14, 2014 12:41

Can you upload your /0 folder, I tried to use mappedBC but I had very bad residual. The mapped variable oscillates around 0.01-0.1 almost like your U. In my case I mapped all the field variables except for nut and I mapped to the nearest cell of the outlet (I've put the offset a Lil bit away from the inlet position, I've read that it can cause problems if you put it at the exact position of the outlet). I'll try to do the simulation again and I'll report, for now the u-profile is quite good.

rolloblues November 14, 2014 13:04

1 Attachment(s)
There you go :)

ArathoN November 14, 2014 13:23

Quote:

Originally Posted by rolloblues (Post 519208)
There you go :)

Interesting you set average values to 0. Is this right? I usually set that flag to false. What interpolation did you use in block mesh dictionary for mappedPatch.

rolloblues November 14, 2014 14:00

I can't give you reference about the zero value for the average. To be honest since the thing worked I didn't pay much attention to it.

Regarding block mesh dictionary I used:

sampleRegion region0;
sampleMode nearestPatchFace;
samplePatch top_end;

ArathoN November 14, 2014 17:10

Quote:

Originally Posted by rolloblues (Post 519216)
I can't give you reference about the zero value for the average. To be honest since the thing worked I didn't pay much attention to it.

Regarding block mesh dictionary I used:

sampleRegion region0;
sampleMode nearestPatchFace;
samplePatch top_end;

Ah interesting didn't know you can directly specify the patch from which to sample. I usually used the offset option. Thanks I'll try tonight with mappedPatch and I'll report tomorrow.

ArathoN November 21, 2014 22:25

Quote:

Originally Posted by rolloblues (Post 519216)
I can't give you reference about the zero value for the average. To be honest since the thing worked I didn't pay much attention to it.

Regarding block mesh dictionary I used:

sampleRegion region0;
sampleMode nearestPatchFace;
samplePatch top_end;

I confirm with mapped patch the pressure field is perfect however the residuals will have an oscillatory behaviour and they will not converge to 1e-6. I compared the U-profile of the mappedpatch and cyclic cases and they are identical.

So in the end the pressure field behavior with cyclic is a problem of how the fvOption works with the solver simpleFoam. In my opinion it is needed a pressure correction loop to reassess the continuity.

P. S ah because I made the same error in blockmeshdict it is needed to set the offset value for mappedPatch otherwise it will not work. Moreover if setaverage is 0 there is no averaging.

be_inspired December 8, 2018 06:25

Quote:

Originally Posted by ArathoN (Post 520476)

So in the end the pressure field behavior with cyclic is a problem of how the fvOption works with the solver simpleFoam. In my opinion it is needed a pressure correction loop to reassess the continuity.

Could you explain this point?
I am facing convergence problem in the pressure equation when using cyclic bc


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