Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Meshing]: Refinement regions #59

Closed
TheodoreGalanos opened this issue Aug 30, 2016 · 3 comments
Closed

[Meshing]: Refinement regions #59

TheodoreGalanos opened this issue Aug 30, 2016 · 3 comments

Comments

@TheodoreGalanos
Copy link
Collaborator

TheodoreGalanos commented Aug 30, 2016

Considering the discussions, and issues, we have been having with meshing I thought it would be a good idea to allow for an additional functionality.

OpenFOAM allows the user to identify refinement regions within a mesh to which then he/she can assign a prefered refinement level (e.g. around the building simulated). OF does that with one of two methods: a utility using shapes to assign refinement regions (called searchablebox, sphere, etc.) and an user provided .stl file. The fact that we are operating inside Rhino/GH environment make I feel the second option an extremely powerfull tool.

This could be either an extra input in the snappyHexMesh component or an additional component of it's own, very similar to the one we are using to create BF surfaces. Usually, the basic shape used for a refinement region is the box but using the .stl method gives users the possibility to use any type of shape they can draw in Rhino or GH. The brep can then be connected to the component and refinement level set.

The component should add two pieces of text in the snappyHexMeshDict:

1.First one right inside the geometry part, after the list of BF surfaces:

geometry
{

              someExample.stl
             {
                         ....
              }

             someRefinementRegion.stl
            }
             type          triSurfaceMesh;
             name        someRefinementRegion; 
             }
}

And the second one inside the refinement region part of castellated mesh:

someRefinementRegion //this has to be the same as the name input above.
{
       mode inside;  //this refines inside the stl, also takes outside or distance as inputs.
       levels ((1E15 X));   //1E15 is just a default place holder, X is the refinement level chosen by the user.
}

Sorry for the long message, it's getting late here!

Kind regards,
Theodore.

@mostaphaRoudsari
Copy link
Member

@TheodoreGalanos thank you for posting this. Can't agree more. This will also provide a hell of a freedom for parametric studies where the geometries will move around and refinement regions can move accordingly.

I would go with the stl approach. The user really doesn't need to know who is it done in the background as far as it does the job correctly.

@mostaphaRoudsari
Copy link
Member

Getting there!

image

@sfakhim
Copy link

sfakhim commented Mar 4, 2019

I have a problem in visualization all mesh regions in para view. As you can see I have defined all parts of my case in SnappyHexMeshDict file both in geometry and refinementSurfaces :
geometry
{
media-1.stl
{
type triSurfaceMesh;
name media-1;
}
media-2.stl
{
type triSurfaceMesh;
name media-2;
}
media-3.stl
{
type triSurfaceMesh;
name media-3;
}
media-4.stl
{
type triSurfaceMesh;
name media-4;
}
media-5.stl
{
type triSurfaceMesh;
name media-5;
}
media-6.stl
{
type triSurfaceMesh;
name media-6;
}
media-7.stl
{
type triSurfaceMesh;
name media-7;
}
media-8.stl
{
type triSurfaceMesh;
name media-8;
}
frame.stl
{
type triSurfaceMesh;
name frame;
}

refinementBox
{
    type searchableBox;
    min (-300 -300 -300);
    max ( 3000 300 300);
}

};

PROBLEM is that Paraview does not show these parts and only shows boundaries that is defined in BlockMeshDict. How can I solve the problem?
Thank you,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants