[TUTORIAL] Implementing porous zones to PisoFOAM
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 Change Make/options to: Code:
EXE_INC = \
Code:
rm -rf Make/linux* pisoFoam.dep
Code:
touch createPorousZones.H Code:
porousZones pZones(mesh); //creates the object porousZones from the mesh object
Code:
...
Code:
int main(){
Code:
//PISO corrector
Code:
wmake
Code:
topoSet Code:
/*--------------------------------*- C++ -*----------------------------------*\ Code:
setsToZones At last call Code:
my_pisoFoamPOROUS Hope you found it helpful. |
I get the error "fatal error: porousZones.H: No such file or directory
compilation terminated". What can be the possible reasons?> |
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 |
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! |
Quote:
|
Hello everyone.
Is there a similar method for including cellzones inside a solver, maybe icofoam or simplefoam?? |
what is the different if i want to implement porous zones to icoFoam? thanks
|
All times are GMT -4. The time now is 09:43. |