lecture 4 unstructured volume meshing -...
TRANSCRIPT
© 2012 ANSYS, Inc. April 1, 2013 1 Release 14.5
14.5 Release
Lecture 4 Unstructured Volume Meshing
Introduction to ANSYS ICEM CFD
© 2012 ANSYS, Inc. April 1, 2013 2 Release 14.5
Introduction to Volume Meshing
• To create 3D elements to fill volumetric domain
– Generally termed “unstructured” mesh
• Mainly tetra
– Full 3D analysis
• Where 2D approximations don’t tell the full story
– Internal/External flow simulation
– Structural solid modeling
– Thermal stress
– Electromagnetics
– Many more!
© 2012 ANSYS, Inc. April 1, 2013 3 Release 14.5
Mesh Input Sources • Input sources for tetra/mixed meshing modules
– Start from just geometry
• Octree tetra
– Robust
– Can “walk” over small features and gaps/holes
• Cartesian
– Stair step
– Body Fitted Cartesian
• Mesh sizes set on geometry or globally
– Start from a closed, watertight shell mesh
• Delaunay and T-Grid
– Quick
• Advancing Front
– Slow mesh size growth for several layers (6 or so) from surface, then fast growth after that into volume
• Hexa Core
• Hex Dominant
– Both geometry and shell mesh
• Octree tetra only
– Portions of model already shell meshed
– Shell meshed section may not be 100% respected (may adjust shell mesh some)
– Set mesh sizes on geometry of unmesh portions
Volume filling methods
© 2012 ANSYS, Inc. April 1, 2013 4 Release 14.5
General Procedure • Load/create surface mesh
– As in Shell Meshing chapter
– For Delauney, Advancing Front, ANSYS TGrid, Hex-Dominant
• Either of these types run from geometry will automatically create surface mesh using global and local Shell Mesh settings without any user input/editing
• If in doubt, run Shell Mesh first, then from “existing mesh”
• Compute Mesh
– Mesh > Compute Mesh > Volume Mesh
• Define density regions (optional)
• Applying mesh size within volume where geometry doesn’t exist
• First decide global volume mesh parameters – Global Mesh Setup >
Volume Meshing Parameters
– Select Mesh Type
– Select Mesh Method for selected Type
– Set options for specific Methods
• Set mesh sizes – Globally
– Locally
• Part/Surface/Curve Mesh Setup
• For From geometry:
– Octree
– Cartesian
• Define volumetric region – Material points
– Typically for octree on complex models
– Multiple volumes possible
• Compute Prism (optional)
– As separate process
– Also option to run automatically with tetra creation
© 2012 ANSYS, Inc. April 1, 2013 5 Release 14.5
Body/Material Point
• Define Volumetric Domain – Mainly used for tetra octree (optional)
• Recommended for complex geometries
• Or multiple volumes
– Geometry -> Create Body
– Material Point
• Centroid of 2 points
– Select any two locations whose mid-point is within volume
– Preferred, because more robust than By Topology method
• At specified point
– Define volume region at a “point” within volume
– By Topology
• Defines volume region by set of closed surfaces
• Must first Build Diagnostic Topology to determine connectivity
– Will fail if gaps/holes in body
• Entire model
– Automatically define all volumes
• Selected surfaces
– User selects surfaces that form a closed volume
© 2012 ANSYS, Inc. April 1, 2013 6 Release 14.5
Mesh Types • Tetra/mixed
– Most used type
1. Pure tetra
2. Tetra with prism layers
• Prism is discussed in a later presentation
• Prisms from tri surface mesh
• Hexas from quad surface mesh
• Pyramids to cap off any quad faces from prism sides or hex prism layers
3. Tetra with hex core
• Can also have prisms
• Hexa filling majority of volume
• Tetra (from Delaunay algorithm) used to fill between surface mesh or top of prism layers and hex core
• Pyramids to make conformal between tetra and hexa quad faces
– A Hybrid mesh can be created by merging a tetra mesh with a structured hex mesh
Pure tetra
Tetra/Prism
Tetra/Prism/
Hexcore
© 2012 ANSYS, Inc. April 1, 2013 7 Release 14.5
Mesh Types - Continued • Hexa-Dominant
– Uses existing quad mesh
– Good quality hex near surface
– Typically poor interior quality
– Typically not suited for CFD, but good enough for static structural analysis
– Not covered in detail here
• Cartesian
– Methods available in Cartesian
– Body fitted
– Staircase
– Hexa-Core
– Automatic pure Hexa
– Rectilinear mesh
– Fastest method for creating volume mesh
– Not covered in detail here
Poor quality interior
© 2012 ANSYS, Inc. April 1, 2013 8 Release 14.5
Mesh Methods - Octree
• Type - Tetra/Mixed
– Method - Robust (Octree)
• Same as Shell Meshing > Patch Independent
– Except volumetric tetras are kept
• Good choice for complex and/or dirty geometry
• Good if you don’t want to spend too much time with geometry cleanup
• Good if you don’t want to spend too much time with detailed shell meshing
• Good if you don’t want to spend time defeaturing geometry
• Just set appropriate mesh sizes on geometry
– Global sizes (max size, curvature/proximity based)
– By parts (Part mesh setup spreadsheet)
– Surfaces
– Curves
– Review Shell Meshing chapter
•Part/Surface/Curve Mesh Setup
© 2012 ANSYS, Inc. April 1, 2013 9 Release 14.5
Octree Method Characteristics
Geometry
Mesh detail
Mesh
• Octree process
– Volume first generated independent of surface model
– Tetras divided near regions where sizes are set smaller
– Nodes are projected to model surfaces, curves and points
– Surface mesh is created when outside tetras are cut away
• Resulting mesh is independent of the underlying
arrangement of surfaces
– Not all surface edges need to be captured!
– Surfaces edges only captured if curve exists there
• Delete curves to ignore hard edges
• Or filter points/curves under Build Diagnostic
Topology
Sliver ignored
© 2012 ANSYS, Inc. April 1, 2013 10 Release 14.5
Octree Tetra Process
The Octree process creates an initial mesh of
“Maximum size” elements which fills a bounding
region completely encapsulating the geometry.
Initial conditions
– Geometry including surfaces, curves and points (from Build Topology)
– Mesh size set globally and/or on surfaces/curves/densities
– Optional material point could also be created
– All saved in the tetin file
© 2012 ANSYS, Inc. April 1, 2013 11 Release 14.5
Tetra Process, Cont’d
• Mesh then subdivided to meet the entity size parameters
– Factor of 2 in 3-dimensions, hence the name Octree
• Nodes are adjusted (projected) and edges are split/swapped to conform to the geometry
• Automatic “flood fill” process finds volume boundaries
– Initial element assigned to part name of material point
– Adjacent layers added to same part until boundary surfaces are reached
– Multiple volumes are supported for multi-region or multi-material problems
– Elements outside the domain are marked into a reserve part name called ORFN, then deleted
Flood fill
•User defined
volumes kept
•ORFN region
is discarded
Material point
2:1 growth ratio because edges get split in half
© 2012 ANSYS, Inc. April 1, 2013 12 Release 14.5
Tetra Process, Cont’d
• Smooth
– Octree mesh is initially composed of regular right angle tetras
– Since nodes are simply moved to nearest geometry, smoothing is necessary
– Smoother can be set to run automatically to improve quality in Global Mesh Setup
– Or run afterwards:
Edit Mesh -> Smooth Mesh Globally
© 2012 ANSYS, Inc. April 1, 2013 13 Release 14.5
Geometry Requirements for Octree Tetra • Tetra requires a reasonably enclosed
surface model
– Run Build Diagnostic Topology to find gaps/holes
– Octree can tolerate gaps smaller then the local element size (approximately 1/10th the element size or less)
• Keep points and curves at key features and hard edges
– Filter curves and points by angle with Build Diagnostic Topology
• Create Material points to define volumes
– Will material point(s) if none exists (named CREATED_MATERIAL#)
• Set Global, Part, Surface, Curve Size Parameters
– Similar to Shell Meshing section
Missing inlet surface
Geometry Repair
tools quickly locate
and fix these
problems.
Hole highlighted by
yellow single edge curve
© 2012 ANSYS, Inc. April 1, 2013 14 Release 14.5
Using Points and Curves with Tetra Octree
Coarse mesh ‘walks over’ detail
in surface model
Mesh captures detail
• Curves and points not included
• Mesh size specified only on surfaces
• Curves and points included
• Mesh size specified on curves
and surfaces
• Curves and points
affect which
features are
captured by the
mesh!
• Build Topology
easily creates the
necessary points
and curves easily
with filter by angle
© 2012 ANSYS, Inc. April 1, 2013 15 Release 14.5
Tetra Octree - Options • Global Mesh Setup > Volume Meshing parameters
– Run as batch process • Runs as a separate process (tetra.exe). GUI will stay interactive.
– Fast Transition • Allows for a slightly faster transition in element size from finer
to coarser • Reduced element count
– Edge Criterion • Split elements at a factor greater than set value to better
capture geometry – Define Thin cuts
• Tool for resolving thin gaps, sharp angles • User selects pairs of opposing parts • Resolves elements jumping from one side to another
– Smooth • Automatically smoothes after grid generation process
– Coarsen – Fix Non-manifold
• Automatically tries to fix elements that jump from surface to another surface
– For a more detailed description go to Help > Help Topics > Help Manual > Mesh > Global Mesh Setup > Volume Meshing Parameters > Tetra/Mixed > Robust (Octree)
© 2012 ANSYS, Inc. April 1, 2013 16 Release 14.5
Compute Mesh – Tetra Octree
• Run options: Compute Mesh > Volume Meshing Parameters – Create Prism Layers
• Will create prisms marked under Part Mesh Setup • Immediately after tetra calculation • Prism layers grown into existing tetra mesh
– Create Hexa-Core • Will retain tri surface mesh (or tri and prisms), throw away
tetra mesh and regenerate volume • Fill volume interior with Cartesian hexas • Cap off hexas with pyramids • Map tetra to tri or top prism face with Delaunay filling
algorithm – Input
• Select Geometry – All, Visible – Part by Part
•Meshes each part separately •Mesh not conformal between parts
– From file •Select tetin file (save memory by not loading it)
– Use Existing Mesh Parts • Select Parts that are already surface meshed • Uses Make Consistent to match octree volume mesh to
existing surface mesh
© 2012 ANSYS, Inc. April 1, 2013 17 Release 14.5
Curvature/Proximity Based Refinement • Curvature/Proximity Based Refinement
– Octree and Patch Independent Surface Mesher
– Automatically subdivides to create elements that are smaller than the prescribed entity size in order to capture finer features
– Min size limit value entered is multiplied by the global Scale Factor and is the minimum size allowed for the automatic subdivision
– Used primarily to avoid setting up meshing parameters specifically for individual entities thus allowing the geometry to determine the mesh size
– Convenient for geometry with many fillets of varying curvature
Prescribed size
is adequate here
Prescribed element size: Surface/Curve Max. Element
Size times Scale Factor
Auto subdivision
at tighter radius
of curvature
Min Size Limit: multiplied by
Scale Factor = global minimum
© 2012 ANSYS, Inc. April 1, 2013 18 Release 14.5
Curvature Based Refinement • Refinement
– Approximate number of elements along curvature if extrapolated to 360o
– To avoid subdivision always to global minimum which would otherwise result in too many elements
– Subdivision will stop once number of elements along curvature is reached
– Approx max number of edges along 360o
– Won’t exceed global minimum set by min size limit value
• Example – Specified refinement achieved
with larger elements
– Global minimum (min size limit) not realized, not necessary to capture curvature
Prescribed size Min size limit
Refinement = 12
© 2012 ANSYS, Inc. April 1, 2013 19 Release 14.5
Proximity Based Refinement • Elements in Gap
– Number of cells desired in narrow gaps
– The default is one element in the gap to just model the feature
• Can specify more than one element in gaps
– Will not make elements smaller than the Min size limit
• Example
– Only one element in gap
– Can’t go smaller than Min size limit
– Have to set smaller Min size limit to allow the 5 elements in gap
Prescribed size Min size limit
Cells in Gap = 5
Prescribed size Min size limit (1/5th smaller)
Cells in Gap = 5
© 2012 ANSYS, Inc. April 1, 2013 20 Release 14.5 9/16/05
Inventory #002281
C1-20
Thin Cuts
B
A
c
If the face of a tetra
element has a
surface/line node on
part “A” then it may
not have a surface/line
node on part “B”
Note: If the surfaces
of the two parts, A
and B, meet, then the
contact curve must be
in a third part, C, or
the thin cut will fail.
• Only works with Tetra Octree
• To avoid ‘holes’ in thin solids/narrow gaps when mesh size is much larger than gap (can handle up to 10 times gap distance)
• Define thin cuts by selecting two parts and then Add them to the list of defined Thin cuts
– The two sides of the thin cut must be in different parts
• 2 types:
– Offset surfaces with a gap between
– Small angle (< 30o)
© 2012 ANSYS, Inc. April 1, 2013 21 Release 14.5
Edge Criterion • Edge criterion
– For tetra octree only
– A number 0 – 1
– 0.2 (the default) means if more than 20% of an edge crosses a surface or curve, then split the edge
– Has an effect similar to globally applying a thin cut
– Smaller numbers will cause more splitting. The closest node will be projected to the surface, modeling smaller features
– Use prudently. Too small a number can result in random clusters of refined mesh
> 0.2 Split edge and project new node to surface
© 2012 ANSYS, Inc. April 1, 2013 22 Release 14.5
Tetra Octree Workflow Recommendation 1. Check geometry accuracy and integrity
– Visually scan surfaces to see if curvature is too choppy or if gaps are large
– Can use build diagnostic topology with no “filtering” to indicate gaps and holes by the yellow curves
• Must use a reasonable tolerance, indicating a maximum allowable gap
– Large gaps also show after running tetra if leakage is reported
2. Move surfaces into intended part names
– Possibly move curves and points later, but surfaces are most important
3. Obtain necessary curves and points
– Needed for nodes to align at hard corners
– Build topology with “filtering” feature angle (30 - 45) or extract curves from surfaces and points from curves, then delete excess
– Scan model and delete curves/points at more gradual angles where surfaces meet
4. Create material point(s)
– Defines volumes to keep mesh (all regions initially meshed)
– Material point must be INSIDE volume, not on surfaces
– ORFN point is a reserved name which instructs to cut away that region
© 2012 ANSYS, Inc. April 1, 2013 23 Release 14.5
Tetra Octree Workflow Recommendation 5. Set mesh sizes
‒ Globally first
• Maximum size
• Curvature/proximity refinement
‒ Locally
• Part mesh setup spreadsheet
• Surface mesh setup
• Curve Mesh setup
• Densities
6. Compute mesh
7. Smooth
‒ Approximately 0.2 minimum quality for tetra
8. Check errors and possible problems
‒ See ICEM CFD help for descriptions of each check
‒ Also discussed in Mesh Preparation presentation
‒ Edit mesh directly to fix problems or change a mesh size and remesh
© 2012 ANSYS, Inc. April 1, 2013 24 Release 14.5
Mesh Methods - Delaunay • Type - Tetra/Mixed
– Method - Quick (Delauney)
• Start from a good quality, closed surface mesh
– Can be quad and tri elements
– From Shell Mesh
– From Octree
– From imported surface mesh
• Setup Options:
– Delaunay Scheme
• Standard: Delaunay scheme with a skewness-based refinement
• TGlib: TGrid Delaunay volume grid generation algorithm that
utilizes a more gradual transition rate near the surface and faster
towards the interior
– Use AF: TGrid Advancing Front Delaunay algorithm which has smoother transitions than the pure Delaunay algorithm.
– Memory Scaling Factor: To allocate more memory than originally
– Spacing Scaling Factor: Growth ratio from surface (1 – 1.5 typically)
– Fill holes in volume mesh: Use to fill holes/voids in existing volume mesh . E.g. if bad quality region is deleted
– Mesh internal domains: For multiple sets of closed volumes in one model
– Flood fill after completion: For multiple volumes – Will assign tetras within closed volume to Part designated by Body or Material Point
– Verbose output: For troubleshooting
Initially distributes
nodes so as the centroid
of any tetra is outside
the circumsphere of any neighboring tetra
© 2012 ANSYS, Inc. April 1, 2013 25 Release 14.5
Mesh Methods – Advancing Front
• Type - Tetra/Mixed – Method - Smooth (Advancing Front)
• Same as Quick (Delauney) but
• Uses advancing front method that marches tetras from surface into interior
• Algorithm from GE/CFX
• Results in more gradual change in element size – “Better” but finer mesh, more elements than Delaunay
– Elements grow slowly for first few layers from surface, then growth rate increases into volume more
– Input surface mesh has to be of fairly high quality
• Setup Options: Do Proximity Checking
– Check to properly fill small gaps
– Longer run time
• Can create pyramids from quads
– Quads need to be a 10 aspect ratio or less
– Delaunay can handle much higher quad aspect ratios
• Respects densities
© 2012 ANSYS, Inc. April 1, 2013 26 Release 14.5
Mesh Methods – ANSYS TGrid
• Tetra/Mixed – ANSYS TGrid
• Runs Tgrid through an extension module
• Good mesh quality
• Fast mesh generation
• Setup Options:
• Flood fill after completion: Same as octree Flood fill
• Verbose output: This option writes more messages to help in debugging any potential problem
• Will not respect densities
• Will not mesh to quads. It converts them to triangles
• Similar to Advancing Front, but does not group elements as close near surface
© 2012 ANSYS, Inc. April 1, 2013 27 Release 14.5
Compute Mesh – Delaunay, Adv. Front, TGrid
• Run Options: – Similar options as octree except cannot mesh to partial
geometry and partial mesh (option: Use existing mesh parts)
– Create Prism Layers available for both
– Hexa-Core not available for Advancing Front
– Volume Part Name
• For newly created tetras
• Can choose Inherited to use material points
– Input
• All Geometry
– Will run shell mesh first with no user input/editing
– Using parameters from Model/Part/Surface/Curve Mesh Setup
– Review Shell Meshing chapter
– If doubtful as to shell mesh quality, run Shell Mesh first, then use Existing Mesh Input method
• Existing Mesh
– Most common method. Surfaces already meshed
• Part by Part
– Meshes each part separately. Nodes are not connected
• From File
– Saves memory. Surface mesh does not need to be loaded
© 2012 ANSYS, Inc. April 1, 2013 28 Release 14.5
Comparison O
ctr
ee
D
ela
un
ey
Ad
v.f
ron
t A
NS
YS
TG
rid
Note the 2:1 growth ratio and square volume elements of the octree method
The 3 filling methods (Delaunay, Adv Front, Tgrid) allow a smoother growth (< 2:1) than octree
© 2012 ANSYS, Inc. April 1, 2013 29 Release 14.5
Density Region • Create Mesh Density
–Define volumetric region with smaller mesh size where no geometry exists, e.g. wake region behind a wing
–Not actual geometry!
•Mesh nodes not constrained to density object
•Can intersect geometry
–Can create densities within densities
•Always subdivides to smallest set size
–Set Size
•Max size within – multiplied by global Scale Factor
•Ratio – expansion ratio away from density object
•Width – Number of layers from object before mesh size is allowed to growth
–Type
•Points – Select any number of points
–Size and Width (number of layers) will determine “thickness” of volume if number of points selected is 1-3
–4-8 creates polyhedral volume
•Entity bounds – define region by bounding box of selected entities
Density from 2 points makes a line. The width defines the radius of the cylinder
© 2012 ANSYS, Inc. April 1, 2013 30 Release 14.5
Periodicity • Define Periodicity • Forces mesh alignment across periodic sides
• For meshing only one section of symmetrically repeatable geometry – Rotational Periodic
• Enter Base, Axis, and Angle
– Translational Periodic
• Enter dX, dY, dZ offset
Tip: Placing
material point
close to mid-plane
makes tetra
octree obey
periodictiy easier
• For tetra octree and hexa blocking only
© 2012 ANSYS, Inc. April 1, 2013 31 Release 14.5
Workshops Workshop 4.1 – Engine Block Model • Build diagnostic topology
• Octree mesh
• Mesh with surface sizes
• Smooth mesh
• View cut plane
• Curvature/proximity refinement
• Delaunay mesh
Workshop 4.2 – Valve Model • Build diagnostic topology
• Create parts, Create material point
• Set sizes – Global, Surface, Curves, density
• Octree mesh
• Compare density to width setting
© 2012 ANSYS, Inc. April 1, 2013 32 Release 14.5
Workshops
Workshop 4.3 – Body Fitted Cartesian • Import Design Modeler file into ICEM
• Create Parts from Subsets
• Global, Part mesh set up
• Using ANSYS ICEM CFD Hexa to create a Cartesian initial grid with biasing
• Computing the mesh
• Viewing cut-planes