Pressure gradient, channelFoam
I am doing simulations for a pipe with an obstacle inside using LES in openFOAM. I have recently got some results for pressure and velocity. Velocity data looks fine but pressure changes linearly from inlet to the outlet which for sure is not correct. :confused:
I am wondering if channelFoam assumes a constant pressure gradient.
I would appreciate any comment about this problem.
channelFoam adds a constant (in space) pressure gradient to the momentum equation and corrects it every time step to ensure the flow rate desired. For a periodic channel without obstacles the pressure have to vary linearly from inlet to outlet. Therefore this pressure contribute tends to be the only one in the average.
Of course, when turbulence develops, the computed pressure (from the elliptic equation) have to equilibrate the flow, so that proper fluctuations have to appear in the computed pressure field.
However I can expect that the intensities of these fluctuations are much smaller than the average pressure variation.
Are you sure you are not missing your pressure variations just because of the way you observe them ?
Thanks for your reply. As you said pressure gradient should be corrected for every time step. But it seems that it has not happened in my case. :confused:
I checked pressure data for some time steps in paraFoam and for all of them pressure gradient has a constant value. :confused:
I have started running my case with paraFoam and I do not have such a problem when using this solver.
I'm still wondering why my pressure data is like this. :confused:
Thank you again.
it is not easy to help with so few info. I will try.
paraFoam is just a postprocessing utility, so I do not understand what exactly you mean when you say that you had no problems computing the pressure with this application.
In the first message you noticed that velocity data looks fine. Now velocity cannot be good if pressure is not correctly solved. Maybe your problem is just to correctly visualize your results.
I would try to use foamToVTK to transform all your time data in the native format of Paraview and then use paraview directly to load and animate all time steps you saved of your computation.
For more help, more details about your case and setup and some images of results are needed.
Thanks again for your reply. :) Actually I think the problem is not about the visualization. There is sth wrong with the data I have got after sampling. As you know after you sample across a line you get this file "line_p_k.xy" that contains the pressure data. Even if I plot the pressure data across the pipe just for one time step, I will get a line!!! :confused: Actually this is obvious when I look at the data.
I have attached a view of my case. I have got a long pipe with a half-disk obstacle inside. I also attached this file "line_p_k.xy" for one time step.
In this file the first column is the coordinate on the center line from the inlet to the outlet. As you see if you plot the second column (P) vs. the first column you will get a line. :confused: :(
I will appreciate any comment.
Thanks a lot.
|All times are GMT -4. The time now is 10:35.|