CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

TJunctionFan tutorial & fanPressureJump BC

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 9, 2019, 13:01
Default TJunctionFan tutorial & fanPressureJump BC
  #1
New Member
 
Lorenzo
Join Date: Jul 2018
Posts: 14
Rep Power: 7
wilove is on a distinguished road
Hello,

I want to integrate a fan in a complex simulation. The fan will be positioned after a porous media in a duct.

In order to undestand fanPressureJump BC I looked into TJunctionFan tutorial.

I see that I have to set
  • Fan, selecting some faces
  • "Slave cells", selecting the cells in in front of the fan

Indeed this is how the topoSetDict looks like:
Code:
/*--------------------------------*- C++ -*----------------------------------*\
  =========                 |
  \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
   \\    /   O peration     | Website:  https://openfoam.org
    \\  /    A nd           | Version:  7
     \\/     M anipulation  |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      topoSetDict;
}

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

actions
(
    {
        name    cyclicFacesFaceSet;
        type    faceSet;
        action  new;
        source  boxToFace; //  Select all face with faceCentre within bounding box
        sourceInfo
        {
            box (0.099 -0.006 0.004)(0.101 0.006 0.016);
        }
    }

    {
        name    cyclicFacesSlaveCells;
        type    cellSet;
        action  new;
        source  boxToCell; // Select all cells with cellCentre within bounding box
        sourceInfo
        {
            box (-10 -10 -10)(0.1 10 10);
        }
    }

    {
        name    cyclicFaces;
        type    faceZoneSet;
        action  new;
        source  setsToFaceZone;
        sourceInfo
        {
            faceSet cyclicFacesFaceSet;
            cellSet cyclicFacesSlaveCells;
        }
    }
);

The red box is the one connected with "cyclicFacesSlaveCells", therefore it selects all the cells in front of the domain.


My real problem is that I don't understand what "slave cells" are.
And in addition, should I select all faces in front of the fan in my case too? Dose it makes any sense to define cells "in front" of the fan when, outside the duct, cells behind are direcly connected to cells in front?

I tested different box dimensions that select only part of the domain in front of the fan. The results are very different.
From the left:
  • Simulation without the fan
  • Simulation with fan (default)
  • Simulation with fan (half of the domain in front of the fan is selected for "slave cells" definition)
  • Simulation with fan (nearly all the domain in front of the fan -but not the whole - is selected for "slave cells" definition)

What do you suggest?
Are there easier BC to use?
wilove is offline   Reply With Quote

Old   December 10, 2019, 05:56
Default
  #2
Senior Member
 
anonymous
Join Date: Jan 2016
Posts: 416
Rep Power: 14
simrego is on a distinguished road
Hi!
As I remember you can just use snappy for example, and create the faceZone for that baffle. Than use the createBaffles utility and you have your patches. This tutorial collects the cells near the face to explicitly determine the orientation of the cyclic faceZone (If I'm correct). This orientation will determine the the master and slave face (which new patch will be the master and which is the slave) after you create the cyclic patches ("split the mesh" with createBaffles). Sadly I don'T remember which will be the master and slave side, but you can easily test it.
simrego is offline   Reply With Quote

Old   December 12, 2019, 16:11
Default
  #3
New Member
 
Lorenzo
Join Date: Jul 2018
Posts: 14
Rep Power: 7
wilove is on a distinguished road
Thank you for your fast response!

So I have to select all the domain in front of the car? (like in the picture)
wilove is offline   Reply With Quote

Old   December 13, 2019, 02:46
Default
  #4
Senior Member
 
anonymous
Join Date: Jan 2016
Posts: 416
Rep Power: 14
simrego is on a distinguished road
How do you generate the mesh? snappyHexMesh?


First of all you just need a faceZone on the fan. Collect the faces where you have the fan into a faceZone. You don't need any cells (at least yet).
Then on this faceZone you can use the createBaffles utility which will create 2 cyclic patches from this faceZone. And on these patches you can define the fan BC.
The same as in the tutorial.
If it works, than you should care about the orientation of the faceZone.
I suggest that always do only small steps if you do something which is new for you, because you wont find the problem (probably there will be a user error )



In the tutorial they select cells, because they set the orientation of the faceZone with this method. But if you are using sHM, you don't need that. And also it is pretty difficult on a more sophisticated geometry.
simrego is offline   Reply With Quote

Old   April 28, 2020, 12:17
Default
  #5
New Member
 
Lorenzo
Join Date: Jul 2018
Posts: 14
Rep Power: 7
wilove is on a distinguished road
I solly I disappeared but I had to "pause" my project.
Now I'm back on it.

I managed to create 2 baffle patch (master & slave) and then I obtained the cyclic boundary with createPatch.
By doing so I also have the faceZones defined by snappy.

Now I really don't know how to determine the orientation of the master and slave faces.
wilove is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
tutorial files KITetima FLUENT 8 November 23, 2019 16:05
AMI - Propeller Tutorial diverging kingmaker OpenFOAM Running, Solving & CFD 2 November 4, 2016 02:57
[Other] TJunctionFan tutorial question about changing baffle/outlet? massive_turbulence OpenFOAM Meshing & Mesh Conversion 1 April 17, 2014 00:07
Fluent Tutorial Guide Ch. 17: Non-Premixed Combust, THTR MAE7509 FLUENT 0 January 22, 2014 20:59
STAR-CD Tutorial shekhar aryal STAR-CD 4 March 22, 2010 03:25


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