|
[Sponsors] |
[TUTORIAL] Implementing porous zones to PisoFOAM |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
September 1, 2014, 14:04 |
[TUTORIAL] Implementing porous zones to PisoFOAM
|
#1 |
Senior Member
anonymous
Join Date: Aug 2014
Posts: 205
Rep Power: 13 |
Code:
cp -r $WM_PROJECT_DIR/applications/solvers/incompressible/pisoFoam/ $WM_PROJECT_USER_DIR/applications/solvers/my_pisoFoamPOROUS
Code:
cd $WM_PROJECT_USER_DIR/applications/solvers/my_pisoFoamPOROUS Code:
mv pisoFoam.C my_pisoFoamPOROUS.C
Code:
my_pisoFoamPOROUS.C EXE = $(FOAM_USER_APPBIN)/my_pisoFoamPOROUS Change Make/options to: Code:
EXE_INC = \ -I$(LIB_SRC)/turbulenceModels/incompressible/turbulenceModel \ -I$(LIB_SRC)/transportModels \ -I$(LIB_SRC)/transportModels/incompressible/singlePhaseTransportModel \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(LIB_SRC)/meshTools/lnInclude EXE_LIBS = \ -lincompressibleTurbulenceModel \ -lincompressibleRASModels \ -lincompressibleLESModels \ -lincompressibleTransportModels \ -lfiniteVolume \ -lmeshTools
Code:
rm -rf Make/linux* pisoFoam.dep
Code:
touch createPorousZones.H Code:
porousZones pZones(mesh); //creates the object porousZones from the mesh object Switch pressureImplicitPorosity(false);// Sets the pressure solver as explicit
Code:
... #include "porousZones.H" // object porousZone int main(){ ... }
Code:
int main(){ #include "CourantNo.H" #include "createPorousZones.H" // PISO LOOP .... }
Code:
//PISO corrector { fvVectorMatrix UEqn ( fvm::ddt(U) + fvm::div(phi, U) + turbulence->divDevReff(U) ); pZones.addResistance(UEqn); ... }
Code:
wmake
Code:
topoSet Code:
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.1.0 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class dictionary; object topoSetDict; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // actions ( { name porosity; type cellSet; action new; source boxToCell; sourceInfo { box (10 0 0) (35 2 0.5); //box (minVertex) (maxVertex) } } Code:
setsToZones At last call Code:
my_pisoFoamPOROUS Hope you found it helpful. |
|
October 30, 2016, 22:58 |
|
#2 |
Member
Anirudh Kulkarni
Join Date: May 2016
Posts: 62
Rep Power: 10 |
I get the error "fatal error: porousZones.H: No such file or directory
compilation terminated". What can be the possible reasons?> |
|
November 2, 2016, 18:16 |
|
#3 |
Senior Member
Wouter van der Meer
Join Date: May 2009
Location: Elahuizen, Netherlands
Posts: 203
Rep Power: 18 |
Hello
To make this work you either need to have the same version as OF that is used by ssss or get the right name of the include file for porousSimpleFoam. #include "IOporosityModelList.H" in stead of #include "porousZones.H" This change also needs to be made in the code exchange porousZones by IOporosityModelList. ( I tried this with OF-dev and I had to change the tutorial also quite a lot because there are links to files that I could not copy) Hope this helps Wouter |
|
November 2, 2016, 22:00 |
|
#4 |
Member
Anirudh Kulkarni
Join Date: May 2016
Posts: 62
Rep Power: 10 |
Yeah I figured that out.
To add porous zones in any solver: 1. Create createPorousZones.H file. Add IOporosityModelList pZones(mesh); //creates the object porousZones from the mesh object Switch pressureImplicitPorosity(false);// Sets the pressure solver as explicit 2. Add #include "IOporosityModelList.H" in header of .C #include "createPorousZones.H" in main prog. 3. Add pZones.addResistance(UEqn); after the governing equations. Peace! |
|
November 25, 2016, 22:44 |
|
#5 | |
Member
Anirudh Kulkarni
Join Date: May 2016
Posts: 62
Rep Power: 10 |
Quote:
|
||
September 26, 2017, 13:55 |
|
#6 |
Member
Ashish Magar
Join Date: Jul 2016
Location: Mumbai, India
Posts: 81
Rep Power: 10 |
Hello everyone.
Is there a similar method for including cellzones inside a solver, maybe icofoam or simplefoam?? |
|
July 31, 2018, 15:23 |
|
#7 |
New Member
naufal
Join Date: May 2018
Posts: 11
Rep Power: 8 |
what is the different if i want to implement porous zones to icoFoam? thanks
|
|
Tags |
piso, pisofoam, porous |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Direction vectors and adsorption in porous zones | Toplaa | FLUENT | 0 | August 16, 2013 15:22 |
Wall between porous zones | roupcik | FLUENT | 0 | April 15, 2013 08:10 |
Wall between porous zones | roupcik | FLUENT | 1 | April 15, 2013 08:06 |
Wall between porous zones | roupcik | Main CFD Forum | 1 | April 15, 2013 08:05 |
Help:What's wrong with my porous zones setting!!? | jjw | FLUENT | 2 | August 26, 2005 06:16 |