CFD Online Discussion Forums

CFD Online Discussion Forums (
-   OpenFOAM Pre-Processing (
-   -   Multiple cell zones definition (

ciberbob1987 February 26, 2012 15:36

Multiple cell zones definition
Hi everybody,
I'm using porousSimpleFoam and I need to define multiple porous zones.

The computational domain is composed by 6 porous petals (similar to 6 pipes), each one twisted with other around a central hole (see attached image).

At the moment, the porous region (isotropic) is defined by the setSet command and the batch file:

cellSet porousCylinder new surfaceToCell "porousCylinderInlets.stl" ( (0 0 0) (-0.017 0 0) ) true true false -1 -100
a render of porousCylinderInlets.stl is shown in the image below:

I need to define an anisotropic porosity along the axial and radial directions of each petal.
I think that the right way is:
  1. define various sections for each petal, of fixed thickness along the z axe (an example is given in the image)
  2. group in a set the cells of every section
  3. create a cellZones from the sets
  4. define a local axes and porosity for each zone in porousZones file

I can generate sections (only surface!) with the script attached. A render of the sections extracted is shown below:

Now, I want to ask if is it possible to generate the cellSets and CellZones (points 1, 2, 3 of above list) by a script.

Many thanks to all.

ciberbob1987 February 26, 2012 15:49

1 Attachment(s)
I forgot the script to generate the section surfaces :D

All times are GMT -4. The time now is 20:46.