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/)
-   -   Simple heat transfer in tube case (https://www.cfd-online.com/Forums/openfoam-solving/119864-simple-heat-transfer-tube-case.html)

Gimlas June 26, 2013 08:17

Simple heat transfer in tube case
 
1 Attachment(s)
Dear Forum Users,

I would like to ask you for your help with a simple case of air cooling in a pipe. The geometry i very simple: it's a pipe of a diameter D which narrows to a smaller diameter and then goes straight up. I can't upload the mesh file due to its size which results from the viscous layer on the walls. But you can assume that its a simple straight pipe. Warm air (238 K) enters through the bottom inlet and it flows out through the top outlet. Meanwhile it is cooled by cold walls (283 K).

I am learning how to prepare a simulation in openFOAM therefore I try to modify existing cases. In my calculation I've used the tutorial case of buoyantBoussinesqSimpleFoam hotRoom. All modified files are attached to this post. Unfortunatelly I do not understand some of the code therefore I had to improvise.

For the initial conditions I have generated velocity field U using potentialFoam (in other case the calculations of p_rgh crashed after few iterations). The oryginal U file is also attached.

But I have encontured a weird problem. Everything looks fine except the outlet where static pressure fluctuations appeared. The boundary conditions for outlet is set to 0. However there are small regions wher this pressure goes below 0 Pa and there is no reason for that. I have followed an advice from this forum and changed the boundary conditions for:

Code:

    Outlet
    {
        type            fixedMean;
        meanValue      0;
        value        uniform 0;
    }

But the results didn't change. There are still pressure fluctuations (small regions which drops well below 0 Pa).

I have made a similar simulations without heat exchange using SimpleFoamWizard from CAELinuks and everything looks normal.

Could you help me to solve this problem?

Gimlas July 2, 2013 08:52

3 Attachment(s)
Dear forum users,

I have managed to enhance some of the boundary conditions but still there is one problem that has to be solved, i.e. static pressure. All parameters are predicted properly:
- p_rgh
- U
- T

The pressure difference between inlet and outlet seems to be ok to. But my intention was to set the static pressure at the outlet (pipe top) to 0 so the openfoam determine the overpressure at the inlet (bottom). Dou you have any ideas how to achieve that? I'm attaching new case files and contour graphs.

cfdonline2mohsen July 2, 2013 15:05

Dear Gimlas
I quote the section 4.5.3.1 of the user guide
4.5.3 PISO and SIMPLE algorithms :
Quote:

In a closed incompressible system, pressure is relative: it is the pressure range that matters not the absolute values. In these cases, the solver sets a reference level of pRefValue in cell pRefCell where p is the name of the pressure solution variable. Where the pressure is p rgh, the names are p rhgRefValue and p rhgRefCell respectively.


you can fix your reference value for pressure in system/fvSolution inside your case folder.
just add the two below lines inside PIMPLE (or PISO):

Code:

pRefValue          0;
pRefPoint          (1.3 0.15 0.325) //the coordinates of your outlet

see the user guide for more help.



All times are GMT -4. The time now is 15:50.