Jun 21, 2010 - Main activity: software development for very specific CFD problems ..... offer problem specific adaptive
enGits GmbH – Hauptstraße 20 – 79674 Todtnau Deutschland / Germany / Allemagne http://engits.eu
[email protected]
enGrid: Open-Source Pre-Processing
Fifth OpenFOAM® Workshop June 21-24 2010 Gothenburg Sweden (OPENFOAM® is a registered trade mark of OpenCFD Limited)
Oliver Gloth enGrid: Open-Source Pre-Processing
Overview • Motivation and state • Detailed example • General an-isotropic layers/refinement • A few showcase examples • Future developments – What is planned? – What is envisaged? Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 2
Oliver Gloth enGrid: Open-Source Pre-Processing
Motivation for Open-Source Meshing • enGits started in October 2006 – Main activity: software development for very specific CFD problems – To extend business a reliable CFD solution was desired • Commercial codes too expensive (no guaranteed business coming in) • Open-source, as well as in-house, solver and post-processing available • Meshing situation not sufficient for commercial CFD work
• Expertise and a few ideas on how to improve unstructured mesh generation – Write own meshing software … Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 3
Oliver Gloth enGrid: Open-Source Pre-Processing
Motivation for Open-Source Meshing • Open-source or proprietary software? • Decision was made rather quickly in favour of OSS • As a small company it would be extremely difficult to compete with the commercial codes • Funding available for an open-source development (funded by the European Space Agency)
• Possibility to generate business with support and customisation of the software Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 4
Oliver Gloth enGrid: Open-Source Pre-Processing
open-source „process chain“ ●
●
●
●
geometry modelling ●
Blender
●
Salome
geometry import and surface meshing ●
Gmsh
●
NETGEN
isentropic volume meshing (tetras) ●
NETGEN
●
Tetgen → ATTENTION: not allowed for commercial applications, NOT OPEN-SOURCE
an-isotropic boundary layer grids ●
●
●
… → enGrid
solver ●
OpenFOAM
●
Code Saturne
●
Elmer
visualisation ●
ParaView
●
Open Data Explorer
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 5
Oliver Gloth enGrid: Open-Source Pre-Processing
Current Status of ENGRID • Capable to create unstructured hybrid grids for CFD (prisms & tetras) • Reliable support for prismatic boundary layers • Requires a triangulated surface (not a proper surface mesh) as input – STL files like for snappyHexMesh – NETGEN could be used as IGES/STEP → STL converter
• Exports OpenFOAM cases (native format) • Experimental support for polyhedral grids • Basic modification tools (e.g. extrusion, rotation)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 6
Oliver Gloth enGrid: Open-Source Pre-Processing
Overview • Motivation and state • Detailed example • General an-isotropic layers/refinement • A few showcase examples • Future developments – What is planned? – What is envisaged? Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 7
Oliver Gloth enGrid: Open-Source Pre-Processing
Example: wing with NACA0012 profile (Re = 1·106)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 8
Oliver Gloth enGrid: Open-Source Pre-Processing
Geometry inside Blender with defined boundary patches
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 9
Oliver Gloth enGrid: Open-Source Pre-Processing
Geometry inside Blender (exploded view)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 10
Oliver Gloth enGrid: Open-Source Pre-Processing
Geometry inside Blender (exploded view)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 11
Oliver Gloth enGrid: Open-Source Pre-Processing
Direct export from Blender to enGrid
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 12
Oliver Gloth enGrid: Open-Source Pre-Processing
After import into enGrid
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 13
Oliver Gloth enGrid: Open-Source Pre-Processing
Save as enGrid case file(s) •
enGrid stores two files per case: –
*.egc file with the description (patch names, boundary conditions, volume definitions, …)
–
*.vtu file with actual grid information (this file can be loaded into ParaView)
•
It proved useful to save different steps of the mesh generation process. For example: –
*_S0.egc: all definitions done
–
*_S1.egc: surface meshing done
–
*_S2.egc: first volume mesh
–
*_S3.egc: refined boundary layer
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 14
Oliver Gloth enGrid: Open-Source Pre-Processing
Select visible patches
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 15
Oliver Gloth enGrid: Open-Source Pre-Processing
Zoom in to view wing only
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 16
Oliver Gloth enGrid: Open-Source Pre-Processing
Define boundary and solver parameters
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 17
Oliver Gloth enGrid: Open-Source Pre-Processing
Define boundary (patch) types
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 18
Oliver Gloth enGrid: Open-Source Pre-Processing
Assign boundary types to patches
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 19
Oliver Gloth enGrid: Open-Source Pre-Processing
Define solver parameters
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 20
Oliver Gloth enGrid: Open-Source Pre-Processing
Enter parameters for surface meshing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 21
Oliver Gloth enGrid: Open-Source Pre-Processing
Select patches for meshing (typically all)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 22
Oliver Gloth enGrid: Open-Source Pre-Processing
Define mesh size constraints for patches
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 23
Oliver Gloth enGrid: Open-Source Pre-Processing
Define maximal edge size (global)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 24
Oliver Gloth enGrid: Open-Source Pre-Processing
Define cell growth
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 25
Oliver Gloth enGrid: Open-Source Pre-Processing
Save and then save under a different name
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 26
Oliver Gloth enGrid: Open-Source Pre-Processing
Start the surface meshing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 27
Oliver Gloth enGrid: Open-Source Pre-Processing
Watch the progress in the output window
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 28
Oliver Gloth enGrid: Open-Source Pre-Processing
Monitor the number of inserted and deleted nodes
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 29
Oliver Gloth enGrid: Open-Source Pre-Processing
After 5 iterations: display symmetry plane and check progress
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 30
Oliver Gloth enGrid: Open-Source Pre-Processing
After 15 iterations the mesh looks good
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 31
Oliver Gloth enGrid: Open-Source Pre-Processing
Save and then save under a different name
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 32
Oliver Gloth enGrid: Open-Source Pre-Processing
Select wall patches and volume to create prismatic boundary layer
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 33
Oliver Gloth enGrid: Open-Source Pre-Processing
After a few minutes the boundary layer is ready
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 34
Oliver Gloth enGrid: Open-Source Pre-Processing
Clipping and which cell types are displayed can be controlled
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 35
Oliver Gloth enGrid: Open-Source Pre-Processing
One iteration to improve the tetra far-field
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 36
Oliver Gloth enGrid: Open-Source Pre-Processing
Mesh is ready for boundary layer refinement
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 37
Oliver Gloth enGrid: Open-Source Pre-Processing
Save and then save under a different name
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 38
Oliver Gloth enGrid: Open-Source Pre-Processing
Refine prismatic layer
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 39
Oliver Gloth enGrid: Open-Source Pre-Processing
Refine prismatic layer
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 40
Oliver Gloth enGrid: Open-Source Pre-Processing
Refined boundary layer mesh
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 41
Oliver Gloth enGrid: Open-Source Pre-Processing
Export mesh to OpenFOAM case
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 42
Oliver Gloth enGrid: Open-Source Pre-Processing
Solver can be run from within enGrid
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 43
Oliver Gloth enGrid: Open-Source Pre-Processing
Solver output can be monitored in the enGrid output window
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 44
Oliver Gloth enGrid: Open-Source Pre-Processing
Results: pressure
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 45
Oliver Gloth enGrid: Open-Source Pre-Processing
Results: y+
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 46
Oliver Gloth enGrid: Open-Source Pre-Processing
Overview • Motivation and state • Detailed example • General an-isotropic layers/refinement • A few showcase examples • Future developments – What is planned? – What is envisaged? Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 47
Oliver Gloth enGrid: Open-Source Pre-Processing
An-isotropic refinement • “coloured” water is injected into a laminar channel flow
• very low diffusive transport (high Schmidt number)
• interface shall be captured by refinement Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 48
Oliver Gloth enGrid: Open-Source Pre-Processing
• “coloured” water is injected into a laminar channel flow
• very low diffusive transport (high Schmidt number)
• interface shall be captured by refinement Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 49
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 50
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 51
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 52
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 53
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 54
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 55
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 56
Oliver Gloth enGrid: Open-Source Pre-Processing
“Side effects” of the development • usage of Blender as geometry tool – definition of boundary conditions – import/export of surface grids • usage of, for example, iso-surfaces as meshing geometry • improved prismatic boundary layer generation • support for multiple volumes (e.g. for conjugate heat transfer simulations)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 57
Oliver Gloth enGrid: Open-Source Pre-Processing
Ariane-5 at max Q (pressure)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 58
Oliver Gloth enGrid: Open-Source Pre-Processing
Ariane-5 at max Q (Mach number)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 59
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 60
Oliver Gloth enGrid: Open-Source Pre-Processing
isotropic (equivalent to 1:5) an-isotropic (aspect ratio 1:100)
tetras
tetras prisms total
isotropic (equivalent to 1:100)
: 393,078 : 136,790 : 529,868
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
tetras
: 2,243,414
: 16,000,000,000 page 61
Oliver Gloth enGrid: Open-Source Pre-Processing
Overview • Motivation and state • Detailed example • General an-isotropic layers/refinement • A few showcase examples • Future developments – What is planned? – What is envisaged? Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 62
Oliver Gloth enGrid: Open-Source Pre-Processing
Tunnel ventilation
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 63
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 64
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 65
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 66
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 67
Oliver Gloth enGrid: Open-Source Pre-Processing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 68
Oliver Gloth enGrid: Open-Source Pre-Processing
Sloshing • Time from “discussed geometry” to “ready to run” grid: appr. 3 hours • Initial condition, 0.01m/s2 from left to right. • 2 minutes of 0.05 m/s2 in y direction Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 69
Oliver Gloth enGrid: Open-Source Pre-Processing
Sloshing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 70
Oliver Gloth enGrid: Open-Source Pre-Processing
Sloshing
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 71
Oliver Gloth enGrid: Open-Source Pre-Processing
Overview • Motivation and state • Detailed example • General an-isotropic layers/refinement • A few showcase examples • Future developments – What is planned? – What is envisaged? Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 72
Oliver Gloth enGrid: Open-Source Pre-Processing
Current development (use snappyHexMesh to recover bad STL geometries)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 73
Oliver Gloth enGrid: Open-Source Pre-Processing
Current development (use snappyHexMesh to recover bad STL geometries)
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 74
Oliver Gloth enGrid: Open-Source Pre-Processing
Future developments (funding confirmed) • Isotropic refinement (solution based discrete refinement)
• y+ based boundary layer adaptation • Improved export function for polyhedral grids
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 75
Oliver Gloth enGrid: Open-Source Pre-Processing
Future developments (ideas) •
Automatic solution based layer generation – unique capability – offer problem specific adaptive meshing solutions
•
Hex far-fields – possibly interfacing with snappyHexMesh
•
Scripting interface – automatise tedious tasks – enable automatic re-meshing with different solvers
•
Include post-processing into GUI – VTK is already used for mesh visualisation → implementation efforts would be manageable – offer a “universal” interface for open-source CFD
Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 76
Oliver Gloth enGrid: Open-Source Pre-Processing
Thank you for your attention! http://engits.eu/engrid • enGrid is licensed under GPL v3 • A number of openSUSE 11.2 live DVDs with enGrid and OpenFOAM are available right here • enGrid is also available on the workshop USB stick (although a slightly older version) Fifth OpenFOAM Workshop, June 21-24 2010, Gothenburg, Sweden
page 77