2 2

Next: Model setting without an Up: Alternative formulation Previous: Alternative formulation   Contents   Index

Edge Mesh Creation - Rotor Region

Edge meshing is important part of meshing using snappyHexMesh. The SnappyHexMesh utility provides automatic mesh generation and sometimes may have problems with catching sharp edges of objects or intersections between boundaries. Edge meshing feature helps a lot to eliminate this problem. Utility surfaceFeatureExtract can extract sharp edges from .STL surfaces. This utility reads settings from its dictionary file surfaceFeatureExtractDict located in system subdirectory.

Let us view content of an example surfaceFeatureExtractDict extracting sharp edges from file t-wheel.stl:

/*--------------------------------*- C++ -*----------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  2.2.2                                 |
|   \\  /    A nd           | Web:      www.OpenFOAM.org                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
FoamFile
{
    version     2.0;
    format      ascii;
    class       dictionary;
    object      surfaceFeatureExtractDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

t-wheel.stl
{
    extractionMethod    extractFromSurface;

    extractFromSurfaceCoeffs
    {
        includedAngle   100;
    }

    writeObj                yes;
}

// ************************************************************************* //

It extracts edge features and saves it to a new file t-wheel.eMesh located in the constant/triSurface subdirectory. Parameter includedAngle specifies an angle in degrees. Edges having lower angle between its faces are written down. Parameter writeObj set to yes means the output will also be written in the .obj format to the constant/extendedFeatureEdgeMesh subdirectory. This format can be viewed directly in paraview. To run the utility, use following command:
$ \color{white} \gg$ surfaceFeatureExtract

Different situation follows when two surfaces (t-housing.stl and interface-t1.stl) have their common intersection to be caught. Utility surfaceBooleanFeatures can extract the intersection between two .stl surfaces.
$ \color{white} \gg$ surfaceBooleanFeatures intersection constant/triSurface/t-housing.stl
constant/triSurface/interface-t1.stl

Several .obj files were created in the case directory. The one we need in order to view the result in paraview is called t-housing_interface-t1_intersection_edgeMesh.obj. The result was also written to the triSurface directory as the .eMesh file. In order to get rid off the files that are no longer needed, one can type and run the following:
$ \color{white} \gg$ rm -rf *.obj

edgesTrotorWheel 1

Figure: Feature edges of turbine wheel (black) and intersections (red).