Making 3D mesh from 2D outline (by rotational extrusion)

OpenFOAM 4.x

Case directory

$FOAM_TUTORIALS/mesh/foamyQuadMesh/square

Summary

First, we create 2D meshes from outline geometry with foamyQuadMesh, and then extrude the meshes rotationally to create 3D meshes with extrude2DMesh.

The outline geometry is defined in the file constant/triSurface/unit_cube.stl.

The outline geometry defined in unit_cube.stl The outline geometry defined in unit_cube.stl

The settings for 2D mesh creation are specified in the file system/foamyQuadMeshDict. In addition to the shape in the geometry file, the mesh coarseness is specified by the refinementBox region as shown below.

geometry
{
    unit_cube.stl
    {
        name cube;
        type triSurfaceMesh;
    }
    refinementBox
    {
        type searchableBox;
        min (0.25 0.25 -1000);
        max (0.75 0.75 1000);
    }
}		

The extrusion method is specified in the file system/extrude2DMeshDict as shown below, and the rotational extrusion is performed by setting "wedge" as the extrudeModel.

extrudeModel        wedge;
patchInfo
{}
patchType           wedge;
sectorCoeffs
{
    axisPt          (0 0 0);
    axis            (1 0 0);
    angle           10;
}

The meshes are as follows, and the number of mesh is 80365.

Outline definition and 3D meshes Outline definition and 3D meshes
2D meshes 2D meshes
2D meshes (zoomed) 2D meshes (zoomed)
3D meshes 3D meshes
3D meshes (zoomed) 3D meshes (zoomed)

Commands

cp -r $FOAM_TUTORIALS/mesh/foamyQuadMesh/square square
cd square

surfaceFeatureExtract
foamyQuadMesh -overwrite
extrude2DMesh -overwrite polyMesh2D
checkMesh -allGeometry -allTopology -constant -noZero

paraFoam

Calculation time

11.86 seconds *Single, Inter(R) Core(TM) i7-2600 CPU @ 3.40GHz 3.40GHz