CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Pre-Processing

splitMeshRegions doesn't find my regions.

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 13, 2013, 10:06
Default splitMeshRegions doesn't find my regions.
  #1
New Member
 
Join Date: Apr 2013
Posts: 24
Rep Power: 13
GPesch is on a distinguished road
Hi,

I am trying to set up a very simple multi region case to test a solver I am working on.
The problem is that when I run "splitMeshRegions -cellZones -overwrite" I will always get the output

"Only one region. Doing nothing".

I defined a cubic block with blockMesh, which worked fine. Here's the blockMeshDict:

Code:
convertToMeters 1;

vertices
(
    (0 0 0)
    (1 0 0)
    (1 1 0)
    (0 1 0)
    (0 0 1)
    (1 0 1)
    (1 1 1)
    (0 1 1)
);

blocks
(
    hex (0 1 2 3 4 5 6 7) (10 10 10) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
    maxY
    {
        type wall;
        faces
        (
            (3 7 6 2)
        );
    }
    minX
    {
        type patch;
        faces
        (
            (0 4 7 3)
        );
    }
    maxX
    {
        type patch;
        faces
        (
            (2 6 5 1)
        );
    }
    minY
    {
        type wall;
        faces
        (
            (1 5 4 0)
        );
    }
    minZ
    {
        type wall;
        faces
        (
            (0 3 2 1)
        );
    }
    maxZ
    {
        type wall;
        faces
        (
            (4 5 6 7)
        );
    }
);

mergePatchPairs
(
);
after running "blockMesh" I ran "topoSet" with the following topoSetDict:

Code:
actions
(
    // Left
    {
        name    left;
        type    cellSet;
        action    new;
        source    boxToCell;
        sourceInfo
        {
            box (0 0 0) (0.5 1 1)
        }
    }
    {
        name    left;
        type    cellZoneSet;
        action    new;
        source    setToCellZone;
        sourceInfo
        {
            set left;
        }
    }


    // Right
    {
        name    right;
        type    cellSet;
        action    new;
        source    boxToCell;
        sourceInfo
        {
            box (0.5 0 0) (1 1 1)
        }
    }
    {
        name    right;
        type    cellZoneSet;
        action    new;
        source    setToCellZone;
        sourceInfo
        {
            set right;
        }
    }
);
So actually I just want to divide it into two parts, "left" and "right". The border should be in the middle of the volume at "x = 0.5".
After doing so I get the two files "polyMesh/sets/left" and "right". Both containing 500 different numbers, I'm assuming that are the cellIds. Okay, so far so good.
But when I run "splitMeshRegions -cellZones -overwrite" I will receive the following output:

Code:
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create mesh for time = 0

Creating single patch per inter-region interface.

Trying to match regions to existing cell zones.


Number of regions:1

Writing region per cell file (for manual decomposition) to "/home/gp/OpenFOAM/gp-2.1.1/run/multiRegionElectrostatics/constant/cellToRegion"

Writing region per cell as volScalarField to "/home/gp/OpenFOAM/gp-2.1.1/run/multiRegionElectrostatics/0/cellToRegion"

Region    Cells
------    -----
0    1000

Region    Zone    Name
------    ----    ----
0    -1    domain0

Sizes of interfaces between regions:

Interface    Region    Region    Faces
---------    ------    ------    -----

Reading volScalarField phi
Reading volScalarField cellToRegion

Only one region. Doing nothing.
End
I am wondering—am I missing something? Is there a simple explanation why splitMeshRegions doesn't detect the two specified regions?
I am running on OF 2.1.1. if that matters.

Thank you so much for the time to read this thread and for your answer in advance.

Best regards
Georg
GPesch is offline   Reply With Quote

Old   November 13, 2013, 16:39
Default
  #2
Member
 
Jace
Join Date: Oct 2012
Posts: 77
Rep Power: 16
zhengzh5 is on a distinguished road
hey, not sure if that's causing trouble but your definition of right zone should be
sourceInfo
{
box (0.5 1 1) (1 1 1)
}

and not
sourceInfo
{
box (0.5 0 0) (1 1 1)
}?

Quote:
Originally Posted by GPesch View Post
Hi,

I am trying to set up a very simple multi region case to test a solver I am working on.
The problem is that when I run "splitMeshRegions -cellZones -overwrite" I will always get the output

"Only one region. Doing nothing".

I defined a cubic block with blockMesh, which worked fine. Here's the blockMeshDict:

Code:
convertToMeters 1;

vertices
(
    (0 0 0)
    (1 0 0)
    (1 1 0)
    (0 1 0)
    (0 0 1)
    (1 0 1)
    (1 1 1)
    (0 1 1)
);

blocks
(
    hex (0 1 2 3 4 5 6 7) (10 10 10) simpleGrading (1 1 1)
);

edges
(
);

boundary
(
    maxY
    {
        type wall;
        faces
        (
            (3 7 6 2)
        );
    }
    minX
    {
        type patch;
        faces
        (
            (0 4 7 3)
        );
    }
    maxX
    {
        type patch;
        faces
        (
            (2 6 5 1)
        );
    }
    minY
    {
        type wall;
        faces
        (
            (1 5 4 0)
        );
    }
    minZ
    {
        type wall;
        faces
        (
            (0 3 2 1)
        );
    }
    maxZ
    {
        type wall;
        faces
        (
            (4 5 6 7)
        );
    }
);

mergePatchPairs
(
);
after running "blockMesh" I ran "topoSet" with the following topoSetDict:

Code:
actions
(
    // Left
    {
        name    left;
        type    cellSet;
        action    new;
        source    boxToCell;
        sourceInfo
        {
            box (0 0 0) (0.5 1 1)
        }
    }
    {
        name    left;
        type    cellZoneSet;
        action    new;
        source    setToCellZone;
        sourceInfo
        {
            set left;
        }
    }


    // Right
    {
        name    right;
        type    cellSet;
        action    new;
        source    boxToCell;
        sourceInfo
        {
            box (0.5 0 0) (1 1 1)
        }
    }
    {
        name    right;
        type    cellZoneSet;
        action    new;
        source    setToCellZone;
        sourceInfo
        {
            set right;
        }
    }
);
So actually I just want to divide it into two parts, "left" and "right". The border should be in the middle of the volume at "x = 0.5".
After doing so I get the two files "polyMesh/sets/left" and "right". Both containing 500 different numbers, I'm assuming that are the cellIds. Okay, so far so good.
But when I run "splitMeshRegions -cellZones -overwrite" I will receive the following output:

Code:
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Create mesh for time = 0

Creating single patch per inter-region interface.

Trying to match regions to existing cell zones.


Number of regions:1

Writing region per cell file (for manual decomposition) to "/home/gp/OpenFOAM/gp-2.1.1/run/multiRegionElectrostatics/constant/cellToRegion"

Writing region per cell as volScalarField to "/home/gp/OpenFOAM/gp-2.1.1/run/multiRegionElectrostatics/0/cellToRegion"

Region    Cells
------    -----
0    1000

Region    Zone    Name
------    ----    ----
0    -1    domain0

Sizes of interfaces between regions:

Interface    Region    Region    Faces
---------    ------    ------    -----

Reading volScalarField phi
Reading volScalarField cellToRegion

Only one region. Doing nothing.
End
I am wondering—am I missing something? Is there a simple explanation why splitMeshRegions doesn't detect the two specified regions?
I am running on OF 2.1.1. if that matters.

Thank you so much for the time to read this thread and for your answer in advance.

Best regards
Georg
zhengzh5 is offline   Reply With Quote

Old   November 14, 2013, 06:20
Default
  #3
New Member
 
Join Date: Apr 2013
Posts: 24
Rep Power: 13
GPesch is on a distinguished road
Quote:
Originally Posted by zhengzh5 View Post
hey, not sure if that's causing trouble but your definition of right zone should be
sourceInfo
{
box (0.5 1 1) (1 1 1)
}

and not
sourceInfo
{
box (0.5 0 0) (1 1 1)
}?
Are you sure? box(0.5 1 1) (1 1 1) is defining a flat area, not a box—or am I mistaking?
GPesch 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
[OpenFOAM] Paraview 3.98.0 does not update list of mesh regions letzel ParaView 6 April 19, 2021 16:57
[snappyHexMesh] multiple regions Tobi OpenFOAM Meshing & Mesh Conversion 56 March 29, 2020 05:53
OpenFOAM 1.6-ext git installation on Ubuntu 11.10 x64 Attesz OpenFOAM Installation 45 January 13, 2012 13:38
Problem Building OF on Centos cluster (no admin rights) CKH OpenFOAM Installation 5 November 13, 2011 07:32
refinement causes composite regions, how to solve? Harry CFX 4 December 8, 2004 06:13


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