Sie sind auf Seite 1von 259

User Manual

HEXPRESS™v3.1
Unstructured Grid Generator

- September 2013 -

NUMERICAL MECHANICS APPLICATIONS


User Manual
HEXPRESS™ v3.1
Documentation v3.1a

NUMECA International
Chaussée de la Hulpe, 189, Terhulpsesteenweg
B-1170 Brussels
BELGIUM

Tel: +32 2 647.83.11


Fax: +32 2 647.93.98
Web: http://www.numeca.com

NUMERICAL MECHANICS APPLICATIONS


Contents

CHAPTER 1: Getting Started 1-1

1-1 Overview 1-1


1-2 Introduction 1-1
What is HEXPRESS™ 1-1
Features 1-1
Structured vs. Unstructured 1-2
Approach 1-3
Project Management 1-4
1-3 How to Use This Manual 1-4
Outline 1-4
Conventions 1-5
1-4 First Time Use 1-5
Basic Installation 1-5
Expert Graphics Options 1-6
Graphics Driver 1-6
1-5 How to Start HEXPRESS™ Interface 1-6
1-6 Required Licenses 1-7
Standard HEXPRESS™ License 1-7
Additional Licenses 1-7

CHAPTER 2: User Interface 2-1

2-1 Overview 2-1


2-2 Welcome Dialog Box 2-2
2-3 Menu Bar 2-3
Project Menu 2-4
Project/New 2-4
Project/Open 2-4
Importing a structured project 2-4
Project/Save 2-5
Project/Save as... 2-6
Project/Import... 2-7
Project/Import.../Project 2-7
Project/Import.../Domain 2-7
Project/Import.../Parasolid 2-7
Project/Import.../STL triangulation 2-7
Project/Import.../CATIA v5 model 2-7
Project/Import.../ANSYS mesh 2-7
Project/Import.../CGNS mesh 2-8
Project/Import.../HEXPRESS/Hybrid mesh 2-8
Project/Export 2-8
Project/Export.../StarCD 2-8
Project/Export.../Fluent 2-10
Project/Export.../Samcef-Bacon 2-12
Project/Export.../CGNS 2-13
Project/Export.../NASTRAN 2-14
Project/Export.../OpenFOAM 2-15
Project/Export.../CEDRE 2-15
Project/Export.../CEDRE (short names) 2-16
Project/Clear cache... 2-16
Project/Script... 2-16
Project/Print/As PNG 2-17
Project/Preferences... 2-17

HEXPRESS™ iii
Contents

Project/Quit 2-19
Internal Surface 2-19
Internal Surface/Edit 2-19
Edit->Copy 2-20
Edit->Translate 2-20
Edit->Rotate 2-20
Edit->Scale 2-20
Edit->Mirror 2-21
Internal Surface/Modify Curve 2-21
Modify Curve->Add Control Point 2-21
Modify Curve->Remove Control Point 2-21
Modify Curve->Modify Point 2-22
Modify Curve->Modify Point On Surface 2-22
Modify Curve->Discretization 2-22
Modify Curve->Divide 2-23
Modify Curve->Reverse Orientation 2-23
Modify Curve -> Set Name 2-23
Internal Surface/Modify Surface 2-23
Modify Surface-> Set Name 2-23
Internal Surface/Select 2-23
Select->Cartesian Points 2-24
Select->Curves 2-24
Select->Surfaces 2-24
Internal Surface/View 2-25
View->Points 2-25
View->Curves 2-26
View->Surfaces 2-26
View->Hide Selected Cartesian Points 2-27
View->Hide Selected Curves 2-27
View->Hide Selected Surfaces 2-27
View->Control Points 2-27
View->Curve Orientation 2-27
Internal Surface/Delete 2-27
Delete Cartesian Points 2-28
Delete->Curves 2-28
Delete->Surfaces 2-28
Grid Menu 2-28
Grid/Periodicity... 2-28
Grid/Boundary Conditions... 2-30
Face selection 2-31
Filters 2-33
Face grouping 2-33
Face type specification 2-34
Face name 2-34
Blank/Unblank 2-34
Periodic BC search 2-34
Grid/Non Matching Connections... 2-35
Full Non Matching Connections 2-35
Rotor/Stator Connections 2-40
Grid/Mesh Quality... 2-42
Negative cells 2-43
Concave and twisted cells 2-43

iv HEXPRESS™
Contents

Orthogonality quality criterion 2-44


Aspect ratio quality criterion 2-44
Volume criterion 2-44
The equi-angular skewness 2-44
The adjacent cell volume ratio 2-45
The mesh expansion ratio 2-45
Surface Mesh Quality 2-45
Relaxed Cells 2-46
Manual Correction 2-46
Grid/Mesh transformation... 2-48
Rotate 2-48
Translate 2-48
Scale 2-49
Axisymmetric 2-49
Mirror and Copy 2-50
Grid/Multigrid levels... 2-51
View Menu 2-51
Face Viewer 2-51
View/Cells... 2-52
View/Face Displacement 2-52
View/Insert Text 2-53
View/Delete Text 2-53
View/Perspective 2-53
View/Repetition... 2-54
STL 2-54
Tools 2-54
STARCD->STL 2-54
Domain->ASCII STL or binary STL 2-54
Tools/Distance 2-55
Plugins 2-56
Concept 2-56
How to activate them? 2-56
Marine Plugins 2-57
Domain and mesh setup (only for 3D) 2-57
Domhydro 2-60
Assumptions 2-60
Modes Description 2-61
How to use the tool 2-62
How to launch the tool 2-63
Examples 2-65
Mesh quality check 2-67
Set type II on mirror faces 2-69
Z constant internal surface 2-69
2-4 Toolbar 2-69
2-5 Quick Access Pad 2-70
CAD Manipulation 2-70
Internal Surface 2-71
Point page 2-71
Cartesian Point 2-71
Curve-Plane Inters 2-72
Curve page 2-72
Polyline 2-72
CSpline 2-72
Arc 2-73

HEXPRESS™ v
Contents

Surface page 2-77


Lofted 2-77
Coons 2-77
Import 2-78
Export 2-78
Domain Manipulation 2-78
Mesh Wizard 2-79
View 2-80
Domains 2-80
Display Options 2-80
Material 2-84
Mesh 2-86
Background 2-87
Camera Position 2-87
Control Area 2-88
Message area 2-88
Keyboard input area 2-88
Mouse coordinates 2-88
Information area 2-88
Grid parameters area 2-89
Viewing buttons 2-89
X, Y, and Z projection buttons 2-89
Coordinate axis 2-89
Scrolling 2-90
3D viewing button 2-90
Rotate about x, y or z axis 2-90
Zoom in/out 2-90
Region zoom 2-91
Fit button 2-91
Original button 2-91
Cutting Plane 2-91
Cylindrical cutting tool 2-93
Box cutting tool 2-94
Spherical cutting tool 2-94
Graphics Area & Views 2-95
2-6 GUI interaction 2-95
Keyboard shortcuts 2-95

CHAPTER 3: Meshing Fundamentals 3-1

3-1 Overview 3-1


3-2 Mesh Domain Definition 3-2
3-3 Mesh Generation Steps 3-4
Initial Mesh 3-4
Adapt to geometry 3-4
Refinement 3-4
Trimming 3-5
Snap to geometry 3-6
Optimization 3-6
Viscous layers 3-7
3-4 Mesh Quality 3-7
3-5 Multi-Domain 3-7
3-6 Batch Mode 3-8

vi HEXPRESS™
Contents

CHAPTER 4: Geometry Definition 4-1

4-1 Overview 4-1


4-2 CAD Model 4-4
Import Solid Models 4-4
Import PARASOLID™ models 4-4
Import CATIA V5 models 4-4
Editing 4-5
Create Box 4-5
Dialog box 4-5
Interactive creation 4-6
Create Cylinder 4-6
Dialog box 4-6
Interactive creation 4-7
Create Cone 4-7
Dialog box 4-7
Interactive creation 4-8
Create Plane 4-8
Dialog box 4-8
Interactive creation 4-9
Create Sphere 4-10
Dialog box 4-10
Interactive creation 4-10
Subtract 4-11
Overview 4-11
Body picking description 4-11
How to substract bodies? 4-11
Unite 4-11
Overview 4-11
Body picking description 4-12
How to unite bodies? 4-12
Intersect 4-13
Overview 4-13
Body picking description 4-13
How to intersect bodies? 4-13
Delete 4-14
Overview 4-14
Body picking description 4-14
How to delete bodies? 4-14
Transform 4-14
Undo 4-15
Create Domain 4-15
Faceting 4-16
Discretized CAD manipulation 4-17
Export parameters 4-17
Save 4-18
Visualization/Selection 4-19
Selection 4-19
Pop-up Menu 4-19
4-3 STL Model 4-21
Introduction 4-21
What is STL? 4-21
STL representation of the computational domain 4-21
Import 4-21
STL Manipulation 4-21

HEXPRESS™ vii
Contents

STL Group Tool 4-21


STL Manipulation Menu 4-22
Viewing/Selection 4-22
Manipulation 4-25
STL/Edit 4-25
Mirror geometry 4-25
Translate geometry 4-25
Rotate geometry 4-26
Clear all 4-26
Information 4-26
STL/Export... 4-27
Ascii stl format 4-27
Binary stl format 4-27
4-4 StarCD Surface Mesh 4-28
4-5 Internal Surface Geometry 4-28

CHAPTER 5: Domain Manipulation 5-1

5-1 Overview 5-1


5-2 Domain Definition 5-1
5-3 Domain Manipulation 5-2

CHAPTER 6: Mesh Wizard 6-1

6-1 Overview 6-1


6-2 Mesh Wizard Actions 6-2
Check Action 6-2
Execute Action 6-3
Common Action Buttons 6-4
6-3 2D/3D Mesh Generation 6-4
Geometry Constraints for 2D projects 6-4
Geometry Constraints for axi-symmetric project 6-5
6-4 Imposing Boundary Conditions 6-7
6-5 Initial Mesh 6-7
Overview 6-7
Domain Bounding Box Subdivision 6-8
Description 6-8
Specify maximum total number of cells 6-8
Auto button 6-8
Specify divisions of the bounding box 6-8
Cylindrical Mesh 6-9
Description 6-9
Sector Parameters 6-9
Number of Divisions 6-9
Import Mesh File 6-10
6-6 Adapt To Geometry 6-10
Overview 6-10
Refinement 6-12
Trimming 6-13
Global Parameters 6-13
Maximum number of refinements 6-14
Advanced parameters 6-14
Enable refinement 6-14
Enable trimming 6-14
Refinement diffusion 6-14

viii HEXPRESS™
Contents

Number of cells in gaps 6-15


Minimum cell size 6-16
Maximum cell size 6-16
Prevent refinement of exterior cells 6-16
Impose isotropic refinement near domain corners 6-16
Apply trimming by distance 6-17
Curve Refinement 6-17
Surface Refinement 6-18
Surface Selection 6-19
Using surfaces list 6-19
By picking 6-20
Rectangle Selection 6-20
Select Identical 6-20
Using Select button 6-20
Zoom In 6-21
Blank/Unblank 6-21
Invert Selection 6-21
Undo Selection 6-21
Different settings highlight 6-21
Surface Grouping 6-22
Active 6-22
Refinement 6-22
Adaptation Criteria 6-23
Distance criterion 6-23
Curvature criterion 6-24
Target cell sizes criterion 6-25
Combining refinement criteria 6-26
Advanced parameters 6-26
Aspect ratio 6-26
Curvature ref factor (R/C) 6-26
Anisotropic extent 6-27
Refinement diffusion 6-28
Box Refinement 6-28
Volume Box 6-29
Cylindrical Sector 6-29
Active 6-29
Parameters 6-30
Target Cell Sizes 6-30
Volumic refinement 6-30
Refinement Diffusion 6-30
Interaction Volume-Surface Criteria 6-31
Trimming Parameters 6-31
Best Practice 6-33
Using distance surface criterion 6-33
No cell in domain after trimming 6-33
6-7 Snap to geometry 6-33
Overview 6-33
Advanced flags 6-34
Snap on surfaces 6-34
Capture corners 6-34
Capture curves 6-34
Projection on surfaces 6-35
Buffer insertion 6-35
Mesh smoothing 6-35
Partial Curve Snapping 6-36

HEXPRESS™ ix
Contents

Buffer Insertion 6-37


Best Practice 6-38
Which entity has not been snapped correctly? 6-38
How to locate them? 6-38
How to handle these issues? 6-39
6-8 Optimization 6-41
Overview 6-41
Advanced 6-42
Relaxing Geometry 6-43
Other Parameters 6-44
6-9 Viscous Layers 6-44
Overview 6-44
Global Menu 6-45
Global parameters 6-45
Fixed first layer thickness 6-45
Fixed stretching ratio 6-46
Control parameters 6-46
Fixed first layer thickness method 6-46
Variable first layer thickness method 6-48
Surface Settings 6-49
Surface Selection 6-49
Using surfaces list 6-49
By picking 6-49
Rectangle Selection 6-50
Enable/Disable 6-50
Select Identical 6-50
Zoom In 6-50
Invert Selection 6-50
Undo Selection 6-50
Different settings highlight 6-50
Surface Grouping 6-51
Active 6-51
Parameters 6-51
For fixed first layer thickness method 6-51
For variable first layer thickness method 6-52
Troubleshooting 6-53

CHAPTER 7: Python Scripts and Plugins 7-1

7-1 Overview 7-1


7-2 Project Commands 7-2
7-3 Viewing Commands 7-3
Camera position 7-3
7-4 Geometry Commands 7-3
Global Functions 7-3
CAD Commands 7-4
STL Commands 7-6
Domain Commands 7-6
CartesianPoint class 7-6
Curve Construction 7-6
Member functions 7-7
Internal Surface Commands 7-7
Member functions 7-7

x HEXPRESS™
Contents

Body Class 7-8


Member functions 7-8
BodyFace Class 7-8
Member functions 7-8
BodyEdge Class 7-8
Member functions 7-8
Domain Class 7-8
Member functions 7-9
7-5 Mesh Generation Commands 7-11
Global Functions 7-11
DomainFace Class 7-14
Member functions 7-14
DomainEdge Class 7-15
Member functions 7-15
SurfaceAdaptationGroup class 7-16
EdgeAdaptationGroup class 7-17
VLGroup class 7-18
FNMB class 7-18
7-6 Dialogue box creation 7-18
Classes 7-19
Variable class 7-19
Command class 7-19
DialogueBox class 7-20
Frame class 7-20
LabelFrame class 7-20
PanedWindow class 7-20
NoteBook class 7-20
Label class 7-20
Button class 7-20
CheckButton class 7-20
RadioButton class 7-21
Entry class 7-21
List class 7-22
ComboBox class 7-22
Additional commands for all widgets 7-22
Additional commands for container widgets 7-22
Example: Z-constant internal surface 7-23

APPENDIX A: File Format A-1

A-1 What is STL? A-1


A-2 ’.stl’ file format specification A-1
Ascii file format A-1
Binary file format A-2
A-3 ’.prop’ file format specification A-2
A-4 ’.dom’ file format specification A-2

HEXPRESS™ xi
Contents

xii HEXPRESS™
CHAPTER 1: Getting Started

1-1 Overview
Welcome to the HEXPRESS™ User’s Guide, a presentation of NUMECA’s fully automatic hexa-
hedral grid generator. This chapter presents the basic concepts of HEXPRESS™ and shows how to
get started with the program by describing:
• what is HEXPRESS
• how to use this guide,
• how to start HEXPRESS™.

1-2 Introduction
1-2.1 What is HEXPRESS™
HEXPRESSis an automatic unstructured hexahedral mesh generator software designed to auto-
matically generate meshes in complex 2D and 3D geometries.
HEXPRESS generates, following a top-down revolutionary approach, meshes only containing
hexahedral elements.

1-2.2 Features
The advanced unstructured code of HEXPRESS™ enables to create mesh for a large range of
industrial machines designed for internal, external or turbomachinery flow.
HEXPRESS features:
— A direct interface to Parasolid™ models. HEXPRESScan automatically import Para-
solid™ models involving solid bodies. The models can be visualized in wireframe and solid
modes. HEXPRESSprovides simple CAD manipulations functions:
— Unite, Subtract, Intersect, Delete, Transform solid bodies.

HEXPRESS ™ 1-1
Getting Started Introduction

— Create simple Box, Cylinder, Cone bodies and Planes.


— Export a discretized computational domain to be meshed by HEXPRESSby con-
verting an automatically triangulated solid bodies.
— Importation of STL models. HEXPRESScan import triangulations in colored STL for-
mat. HEXPRESScreates, starting from STL files, an additional file storing a geometry
attribute for each triangle of the STL triangulation. The geometry attributes allow HEX-
PRESSto reconstruct topology information without the need of using sophisticated and
error prone feature detection algorithms. HEXPRESSoffers merging, splitting and dele-
tion functions to manipulate and simplify triangulated models.
— Importation of CATIA models. HEXPRESS™ enables the direct importation of CATIA
v5 files (*.CATPart) up to R21, possibly including several solid bodies. Importation of
CATIA v5 files is subjected to specific feature in the NUMECA license file and is only
available on LINUX (64bits) and Windows (32 or 64bits) platforms.
— Mesh Wizard. HEXPRESS is organized around a very easy-to-use mesh wizard which
drives the user through the various steps of the meshing process:
— Initial mesh
— Adapt to geometry
— Snap to geometry
— Optimize
— Viscous layers
— Automation. HEXPRESS has been designed for automation. User interaction is essen-
tially reduced at the strict minimum. User partly interacts with adaptation step by specifying
the criteria on surfaces driving the cell refinements.
— Mesh optimization. HEXPRESS implements new algorithms for mesh optimization
which guarantee that a very large percentage of cells, if not all of them, are convex and of
high quality (success rate if ~ 99.998% of convex cells).
— Viscous layers. HEXPRESS proposes robust high aspect ratio cell layers insertion for
boundary layers resolution.
— Export. HEXPRESScan export meshes in StarCD, Fluent, Nastran, CGNS and Samcef/
Bacon compliant file format.
— Graphical User Interface. HEXPRESSinvolves a state-of-the-art graphical user inter-
face with world class mesh visualization and project management functions.

1-2.3 Structured vs. Unstructured


Depending on the geometry complexity, the user should define the requested mesh type: structured
or unstructured. Structured meshes are to be preferred for reasons of accuracy in cases of aligned
flow even if their generation can sometimes be difficult and cumbersome. Unstructured meshes can
be easily generated independently of the geometrical complexity and owing to their nature gener-
ally tend to generate less points than in the structured case. For turbomachinery design, because of a
request of high accuracy, it is recommended to use AutoGrid5™ which enables to provide struc-
tured meshes.
Users requiring an unstructured mesh may consider the use of the NUMECA’s automatic hexahe-
dral mesh generation software HEXPRESS™.

1-2 HEXPRESS™
Introduction Getting Started

1-2.4 Approach

FIGURE 1.2.4-1 Meshing process in five steps

HEXPRESS is based on a top-down revolutionary approach. HEXPRESS involves five differ-


ent steps for the meshing process.
1. Initial Mesh: HEXPRESSgenerates automatically an initial hexahedral mesh of the bound-
ing box of the computational domain. The system computes an isotropic subdivision of the
domain with a minimum amount of cells.
2. Adapt to Geometry: HEXPRESS successively adapts the mesh by cell anisotropic subdivi-
sion until the cell sizes match some specific geometry criteria. The adaptation criteria are either
fully automated or depend on user specification:
— HEXPRESS relies on surface criteria which automatically compute cell sizes to fill nar-
row gaps between surfaces with a sufficient amount of cells and refine cells locally close to
high geometry curvature regions. The user can also specify his own cell size requirements.
— HEXPRESS also uses volume box refinement to refine cells in some volumes specified by
the user.

HEXPRESS™ 1-3
Getting Started How to Use This Manual

— HEXPRESS removes all cells located outside the computational domain or intersecting
the geometry.
3. Snap to Geometry: HEXPRESS projects the mesh on the geometry and recovers lower
dimensional geometry features by some very specific corner and curve capturing. The robust-
ness and accuracy of these algorithms are unique to HEXPRESS
4. Optimize: HEXPRESS optimizes the mesh to ensure that all cells are convex and of high
quality. The optimization algorithms are unique to HEXPRESS
5. Viscous Layers: HEXPRESSinserts additional layers of high aspect ratio cells in the mesh
by further anisotropic cell subdivisions in order to generate a mesh suitable for resolving highly
sheared flows.

1-2.5 Project Management


To manage complete mesh generation, HEXPRESS™ integrates the concept of project. An HEX-
PRESS™ project involves template files and mesh files. The mesh files contains the multiblock
mesh topology, geometry and grid points and the boundary condition types:
• "project_name.bcs": boundary conditions files,
• "project_name.dom": geometry files,
• "project_name.igg": template file containing all parameters used to create the mesh,
• "project_name.hex": grid points files (CGNS format),
• "project_name.hxp": extra information for the mesh generation,
• "project_name.rep": report file,
• "project_name.log": mesh generation information,
• "project_name.dist": distance file,
• "project_name.fnmb": FNMB connections,
• "project_name.qualityReport": quality report file.
These files can be loaded into the unstructured multiblock grid generation system HEXPRESS
and by the CFD integrated environment FINE/Open and FINE/Marine.
To generate again an HEXPRESS™ project, the ".dom", ".bcs" and ".igg" files are necessary. They
correspond to the template files.
The report file is saved at the end of the grid generation. If the new project has not yet been saved
before launching the 3D generation, no report file will be saved because the system is not able to
determine automatically the file location.
The quality report file is created by HEXPRESS after the optimization and viscous layers inser-
tion. It stores some information about the project definition and the mesh quality criteria for the cur-
rent mesh (see section 2-3.3.4 for more information).

1-3 How to Use This Manual


1-3.1 Outline
This manual consists of five distinct parts:

1-4 HEXPRESS™
First Time Use Getting Started

• Chapters 1and 2: introduction and description of the interface,


• Chapters 3: mesh fundamentals,
• Chapters 4 and 5: geometry definition and domain manipulation,
• Chapter 6: mesh wizard,
• Chapter 7: Python scripts.
At first time use of HEXPRESS™ it is recommended to read this first chapter carefully and cer-
tainly section 1-4 to section 1-6. Chapter 2 and Chapter 3 give a general overview of the HEX-
PRESS™ interface and the way to manage a project. Chapter 4 and Chapter 5 give information on
how to prepare a domain for the mesh generation. For every mesh generation, the input parameters
can be defined as described in the Chapter 6.

1-3.2 Conventions
Some conventions are used to ease information access throughout this guide:
• Commands to type in are in italics.
• Keys to press are in italics and surrounded by <> (e.g.: press <Ctrl>).
• Names of menu or sub-menu items are in bold.
• Names of buttons that appear in dialog boxes are in italic.
• Numbered sentences are steps to follow to complete a task. Sentences that follow a step and are
preceded with a dot (•) are substeps; they describe in detail how to accomplish the step.

The hand indicates an important note.

 The pair of scissors indicates a keyboard shortcut.

A light bulb in the margin indicates a section with a description of expert parameters.

1-4 First Time Use


1-4.1 Basic Installation
First of all, HEXPRESS™ should be properly installed according to the installation note. The
installation note provided with the software should be read carefully and the following points are
specifically important:
• Hardware and operating system requirements should be verified to see whether the chosen
machine is supported.
• Installation of HEXPRESS™ according to the described procedure in a directory chosen by the
user and referenced in the installation note as ‘NUMECA_INSTALLATION_DIRECTORY’.
• A license should be requested that allows for the use of HEXPRESS™ and the desired compo-
nent and modules (see section 1-6 for all available licenses). The license should be installed
according to the described procedure in the installation note.

HEXPRESS™ 1-5
Getting Started How to Start HEXPRESS™ Interface

• Each user willing to use HEXPRESS™ or any other NUMECA software must perform a user
configuration as described in the installation note.
When these points are checked the software can be started as described in the installation note or
section 1-5 of this users guide.

1-4.2 Expert Graphics Options


1-4.2.1 Graphics Driver
The Graphics area of HEXPRESS™ interface uses by default an OPENGL driver that takes advan-
tage of the available graphics card. When the activation of OPENGL is causing problems, HEX-
PRESS™ uses an X11 driver (on UNIX) or MSW driver (for Windows) instead.
It is possible to explicitly change the driver used by HEXPRESS™ in the following ways:
On UNIX:
in csh, tcsh or bash shell:
setenv NI_DRIVER X11
in korn shell:
NI_DRIVER=X11
export NI_DRIVER
The selection will take effect at the next session.
On Windows:
• Log in as Administrator.
• Launch regedit from the Start/Run menu.
• Go to the HKEY_LOCAL_MACHINE/SOFTWARE/NUMECA International/Hexpress31_#
or HKEY_LOCAL_MACHINE/SOFTWARE/NUMECA International/FineOpen31_# or
HKEY_LOCAL_MACHINE/SOFTWARE/NUMECA International/FineMarine31_# register.
• Modify or add (right-click & New/String Value) the DRIVER entry to either OPENGL or
MSW.
The selection will take effect at the next session.

1-5 How to Start HEXPRESS™ Interface


In order to run HEXPRESS™ standalone version, the following command should be executed:
• On UNIX and LINUX platforms type: hexpress -niversion 31_# <Enter> or hexpress31_#
<Enter>
In order to use HEXPRESS™ included in FINE™/Marine or FINE™/Open package, "31_#"
should be replaced by "marine31_#" or "open31_#".
• On Windows click on the HEXPRESS icon in Start/Programs/NUMECA software/
Hexpress31_#/ or Start/Programs/NUMECA software/FineOpen31_#/ or Start/Programs/
NUMECA software/FineMarine31_#/. Alternatively HEXPRESS™ (32bits) can be launched
from a Dos shell by typing:
<NUMECA_INSTALLATION_DIRECTORY>\Hexpress31_#\bin\hexpress.exe <Enter> or
<NUMECA_INSTALLATION_DIRECTORY>\FineOpen31_#\bin\hexpress.exe <Enter> or

1-6 HEXPRESS™
Required Licenses Getting Started

<NUMECA_INSTALLATION_DIRECTORY>\FineMarine31_#\bin\hexpress.exe <Enter>.
where NUMECA_INSTALLATION_DIRECTORY is the directory indicated in section 1-4.1.
And HEXPRESS™ (64bits) can be launched from a Dos shell by typing:
<NUMECA_INSTALLATION_DIRECTORY>\Hexpress31_#\bin64\hexpressx86_64.exe <Enter> or
<NUMECA_INSTALLATION_DIRECTORY>\FineOpen31_#\bin64\hexpressx86_64.exe <Enter> or
<NUMECA_INSTALLATION_DIRECTORY>\FineMarine31_#\bin64\hexpressx86_64.exe <Enter>.
where NUMECA_INSTALLATION_DIRECTORY is the directory indicated in section 1-4.1.

1-6 Required Licenses


1-6.1 Standard HEXPRESS™ License
The standard license for HEXPRESS™ allows for the use of all basic features of HEXPRESS™ includ-
ing:
• CAD importation and geometry management (except CATIA v5),
• multi-domain capability and FNMB connections,
• mesh periodicity and rotor/stator capabilities.

1-6.2 Additional Licenses


Next to HEXPRESS™ other products are available and require separate licenses:
• FINE™/Turbo (structured mesh generator - solver - visualization software) dedicated to turboma-
chinery applications,
• FINE™/Design 3D (3D inverse design) dedicated to design,
• IGG™ (structured mesh generator),
• AutoGrid5™ (automatic structured mesh generator for turbomachinery),
• HEXPRESS™/Hybrid (unstructured mesh generator),
• FINE™/Open (unstructured mesh generator - solver - visualization software) dedicated to aerody-
namics and turbomachinery applications,
• FINE™/Marine (unstructured mesh generator - solver - visualization software) dedicated to marine
applications.

HEXPRESS™ 1-7
Getting Started Required Licenses

1-8 HEXPRESS™
CHAPTER 2: User Interface

2-1 Overview
This section describes the appearance and use of the HEXPRESS Graphical User Interface
(GUI).

FIGURE 2.1.0-1 HEXPRESS™ Interface

The HEXPRESS GUI is divided into several main components as shown in Figure 2.1.0-2:
• Menu bar
• Toolbar

HEXPRESS ™ 2-1
User Interface Welcome Dialog Box

• Quick Access Pad


• Control area
• Graphics area
Current project name

Menu Bar

Toolbar

Graphics Area

Quick Access Pad

Message area
Keyboard input area Viewing buttons
Grid parameters area Mouse coordinates Control Area Information area

FIGURE 2.1.0-2 HEXPRESS GUI

The following sections describe these components as well as one additional important features:
keyboard shortcuts.

2-2 Welcome Dialog Box


The welcome dialog box (Figure 2.2.0-1) is displayed at start-up or when the Project/New menu is
selected or when the Toolbar/New button ( ) is pressed. Several choices are available to the
user:
— Open an existing HEXPRESS, HEXPRESS/Hybrid, IGG or AutoGrid5 project, i.e.
a file with extension ".igg". Please refer to section 2-3.1.2 on page 2-4 for more details;
— Import a valid computational domain, i.e. a file with extension ".dom". Please refer to sec-
tion on page 4-3.

2-2 HEXPRESS™
Menu Bar User Interface

— Import a Stereo Lithography Triangulation (STL), i.e. a file with extension ".stl". Please
refer to section 4-3 on page 4-21.
— Import a CAD model in Parasolid™ format, i.e. a file with extension ".xt" or ".xt_txt".
Please refer to section 4-2 on page 4-4.
— Import ANSYS mesh (see 7)
— Import CGNS mesh (see 7)
— Execute a python script
— Quit to exit HEXPRESS

FIGURE 2.2.0-1 Welcome to HEXPRESS dialog box

2-3 Menu Bar


The menu bar contains several menus which can be activated using mouse click and drag or mouse
click and release modes.
This section describes all available menus:
• Project,
• Internal Surface,
• Grid,
• View,
• STL,
• Tools,
• Plugins.

HEXPRESS™ 2-3
User Interface Menu Bar

2-3.1 Project Menu


2-3.1.1 Project/New
Project/New closes the current project and opens up the HEXPRESSwelcome dialog box. The
old project is not automatically saved before being closed. Therefore, be sure that the current work
is saved before using this option. All system parameters are reset to their default values and a new
3D project is initialized. All curves and surfaces are removed from the working memory.

2-3.1.2 Project/Open
Project/Open is used to open an existing project, previously created by HEXPRESS. A file
chooser window (Figure 2.3.1-1) is opened to enable selection of an existing HEXPRESS project
file with an ".igg" extension.

FIGURE 2.3.1-1 HEXPRESS project file chooser

Upon selection of a valid project, HEXPRESS closes the current project and opens the new one.
The old project is not automatically saved before being closed. Therefore, be sure that the current
work is saved before this option is used.
An unstructured project from HEXPRESS™/Hybrid or a multiblock structured project from IGG™
or AutoGrid5™ can also be loaded into HEXPRESS.

a) Importing a structured project


HEXPRESSautomatically converts the multiblock structured mesh into an unstructured hexahe-
dral mesh in HEXPRESS format. Upon importing the structured mesh, the user is given the
choice to keep or remove all the Non matching connections (NMB), Periodic matching connections
(PER) and Partially non matching connections (PERNM) before converting it into HEXPRESS
format. See Figure 2.3.1-2. By default all the connections will be kept.

2-4 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.1-2 Dialogue shown upon loading a structured mesh

User is also allowed to convert the structured mesh with the desired multigrid level through mesh
converter dialog box. If the option Keep finest grid only is activated, it saves the project by keep-
ing the finest grid only.

FIGURE 2.3.1-3 Mesh converter dialog box

The user is then requested to specify a new project name for the converted project. The converter
defines a new HEXPRESS computational domain by triangulating the surfaces of the quadrilat-
eral multiblock grid. Boundary conditions are exported into the new HEXPRESS project. All
blocks connected by matching mesh faces (CON boundary condition) are concatenated to define
single computational domain.

When the multiblock structured project from IGG™ contains a butterfly mesh, they
all have to be split inside IGG™ before loading into HEXPRESS.
When the structured project from IGG™ or AutoGrid5™ contains undefined patches
(UND), they all have to be changed in another type (for example CON if at the connec-
tion between blocks) before loading into HEXPRESS™ otherwise the concerned patches
will be considered as an internal surface in the converted mesh.

2-3.1.3 Project/Save
Project/Save saves the current project. When saving for the first time, a new file name must be
specified, through a file chooser, by the user with the extension ".igg". The saving procedure writes
information in the following files:

HEXPRESS™ 2-5
User Interface Menu Bar

FIGURE 2.3.1-4 Project files

• "project_name.bcs": boundary conditions files,


• "project_name.dom": geometry files,
• "project_name.igg": template file containing all parameters used to create the mesh,
• "project_name.hex": grid points files (CGNS format),
• "project_name.hxp": extra information for the mesh generation,
• "project_name.rep": report file,
• "project_name.log": mesh generation information,
• "project_name.dist": distance file,
• "project_name.nmb": NMB, PER and PERNM connections,
• "project_name.fnmb": FNMB connections,
• "project_name.qualityReport": quality report file.
Thanks to the files stored in the folder called "cache", the user can come back to whichever inter-
mediate step without starting the mesh generation again from the beginning:
• "project_name_step.hex" (or ".hxp"): grid points file (CGNS format) after a step between init,
adapt, snap or regularize corresponding to Initial, Adaptation, Snapping and Optimization step
respectively.
• "project_name_step.fnmb": FNMB connections file after a step between init, adapt, snap or
regularize corresponding to Initial, Adaptation, Snapping and Optimization step respectively.
The files stored in the "cache" folder can be removed when the project is over and they
are not needed to generate the mesh again. To remove them, please read chapter 2-3.1.7.

2-3.1.4 Project/Save as...


Project/Save as saves an existing HEXPRESS project under a user defined name. Different grids
created by using the same boundary data can be saved separately for further comparison.

2-6 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.1-5 Project / Save as...

2-3.1.5 Project/Import...
Following files can be imported:

a) Project/Import.../Project
Project/Import.../Project reads an external mesh file ".igg". Several mesh files can be opened.
This enables multiblock computations within FINE™/Open or FINE™/Marine.

b) Project/Import.../Domain
Project/Import.../Domain reads an external geometry domain file ".dom". Several domains files
can be opened. This enables multiblock computations within FINE™/Open or FINE™/Marine.

c) Project/Import.../Parasolid
Project/Import.../Parasolid reads external geometry files in Parasolid™ format ".x_t". Several
Parasolid™ files (Parasolid™ and CATIA v5) can be opened when defining the geometry before
the domain creation. Versions up to 24.0.193 are supported.

d) Project/Import.../STL triangulation
Project/Import.../STL triangulation reads external geometry files in STL format ".stl". Several
STL files can be opened when defining the geometry before the domain creation.

HEXPRESS™ also supports colored STL formats.


e) Project/Import.../CATIA v5 model
Project/Import.../CATIA v5 model reads external geometry files in CATIA format ".CATPart".
Several Parasolid™ files (Parasolid™ and CATIA v5) can be opened when defining the geometry
before the domain creation. Versions up to R21 are supported.

f) Project/Import.../ANSYS mesh
Project/Import.../ANSYS mesh reads external mesh files in ANSYS format ".cdb" v8.0.

HEXPRESS™ 2-7
User Interface Menu Bar

g) Project/Import.../CGNS mesh
Project/Import.../CGNS mesh reads unstructured 3D mesh stored in a CGNS format and converts
it to its native mesh format. The input mesh is not necessary pure hexahedral, i.e. it might contain
tetrahedron, prism, pyramid cells and can contain hanging nodes.
When converting the mesh, the boundary conditions will be recovered and corresponding HEX-
PRESS™ boundary conditions will be set. In addition for pure hexahedral input meshes, the opti-
mization and the viscous layer insertion can be performed in HEXPRESS™ on these meshes.

The option does not import CGNS mesh including multiple blocks. It only imports
single block mesh.

h) Project/Import.../HEXPRESS/Hybrid mesh
Project/Import.../HEXPRESS/Hybrid mesh allows to read unstructured volume meshes created
by HEXPRESS™/Hybrid and saved in HEX format.

Before loading the mesh in HEXPRESS™, the boundary conditions have to be


defined in HEXPRESS™/Hybrid.

2-3.1.6 Project/Export

a) Project/Export.../StarCD
The StarCD export functionality is available to the user via menu Project/Export.../StarCD. Four
files are saved in the directory and with the project name specified by the user through a file
chooser:
— ’project_name.cel’ contains the cells definition in terms of nodes
— ’project_name.vrt’ contains the coordinates of the vertices
— ’project_name.cpl’ contains the coupling definitions between cells through faces presenting
hanging nodes (Figure 2.3.1-6)
— ’project_name.bnd’ contains the list of boundary faces with boundary condition information

FIGURE 2.3.1-6 Definition of hanging node at cells connection

Exporting multiblock domains is not available in StarCD format.


The StarCD file format output by HEXPRESS complies with the STARCD User Guide, Version
3.05, 1998. For STARCCM+ users, it is mandatory to use the "ngeom" command to convert mesh
data from STARCD to STARCCM+. This tool is provided in the STARCD package v3.26.
• The file "project_name.cel" stores the connectivity between the cells and the nodes.
Figure 2.3.1-7 presents the connectivity of the NUMECA and StarCD hexahedron cell.

2-8 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.1-7 StarCD, HEXPRESS hexahedra

The connectivity file is written using the following FORTRAN ASCII format:
I9 6X 9I9 1X I4
Cell number, eight vertices, cell type number, cell key
where:
— cell type number is the region of the cell. HEXPRESS currently outputs all cells in the
same region with index 1.
— cell key defines the type of the cell:
1. Fluid cell
2. Solid cell
3. Baffle
4. Shell
5. Line
6. Point
All cells currently exported by HEXPRESS are fluid cells (cell key is equal to 1).
• The file "project_name.vrt" stores the nodes coordinates which are exported with the following
FORTRAN format:
I9 6X 3G16.9
Vertex number, three coordinates
• The file "project_name.bnd" stores the list of boundary facets. A boundary in StarCD is a mesh
facet connected to a geometry surface. Boundaries are grouped in regions. Boundary mesh fac-
ets are exported with the following FORTRAN format statement:
I8 6X 4I9 2I7 A
Boundary number, four vertices, region number, patch number, region type, (characters)
where:
— The region number corresponds to the ID of a topological face of the HEXPRESScompu-
tational domain.
— The patch number is set to 0 in HEXPRESS.
— The region type defines the type of boundary condition. HEXPRESS exports the follow-
ing StarCD boundary condition:

HEXPRESS™ 2-9
User Interface Menu Bar

INLE: inlet
OUTL: outlet
WALL: wall
• The cell to cell connection referred to as “couple” in StarCD defines the transition between
coarse and fine mesh cells with hanging nodes. A couple allows the faces of several (small) cell
slaves to be connected to one master (large face). Couples are exported with the following FOR-
TRAN format in the file "project_name.cpl":
I8 1X I5 1X I8/7(I9,I2)
Couple number, number of cells, type of coupling, CELL1, FACE1, CELL2, FACE2....
where:
— The type of coupling is set to 1 by default in 3D
— CELL1: the index of the master cell
— CELL2: the index of a slave cell
— FACE1, FACE2: the number of the face in the cell (0->5)

b) Project/Export.../Fluent
This Fluent export functionality is available to the user via menu Project/Export.../Fluent. An
ASCII file is saved in the directory and with the project name specified by the user as
"project_name.msh". The format of this exportation complies with Fluent 6.3.
A Fluent mesh file contains certain partitions of information called zones. Each zone is a separate
block that contains information about objects of one type: faces, cells, nodes, hierarchy tree, com-
ments, etc. Each zone must be enclosed in parentheses.
The content of a zone depends on the particular type of the zone. Each zone has an ID needed for
successful referencing the information stored in the zone. Each zone has a header including general
information related to the zone: initial and final indices of the elements described in the zone, com-
ment text, etc. This header must be enclosed in parentheses as well. The header of a zone of a cer-
tain type must be followed by the zone body. It includes detailed information about the mesh
objects described in the zone. The body must be enclosed in parentheses. Zones may be either
optional or required (zones 0, 1 and 2 are optional, all other zones are required). Below is a short
description of the zone types that are used for exportation by HEXPRESS

TABLE 1. Fluent format zone types used by HEXPRESS

Index Name Description

0 Comment Comments for blocks of the file

1 Header Information about the code that wrote the file

2 Dimensions Dimensionality

10 Nodes The total number of nodes in the mesh or the


coordinates of the mesh nodes

12 Cells The total number of cells in the mesh or the


number of cells of a certain type

2-10 HEXPRESS™
Menu Bar User Interface

TABLE 1. Fluent format zone types used by HEXPRESS

Index Name Description

13 Faces The total number of faces in the mesh or full


information about mesh faces - nodes and adja-
cent cells

59 Face tree Parent-to-child dependency among mesh faces

Remarks:
1. The mesh generation strategy of Fluent is essentially conformal. Non-conformity is the result of
mesh adaptation by the Fluent flow solver. HEXPRESS exports only leaf cells1 on finest level
to the Fluent file, because the cell hierarchy supported in HEXPRESS cannot be correctly
described in terms of the Fluent mesh file format. Face hierarchy is preserved only partially. As
only leaf cells are exported, only their faces must be exported in order to preserve consistency
between cells and faces (only faces or nodes referenced by leaf cells must be exported). Thus,
the face hierarchy is preserved for exported faces only: if one leaf cell references a face and
another one references its child face (generated face), then the parent-child dependency is
exported to a Fluent file.
2. Fluent mesh generator does not officially support anisotropic refinement. HEXPRESS, on the
contrary, is able to generate fully or partially anisotropic meshes. Fluent flow solver however
accepts meshes that contain anisotropicity and behaves properly during computations. However,
it is not recommended to perform a mesh check (via Fluent’s menu Grid/Check) because it will
result in multiple warnings reporting incorrect number of child faces encountered in zones with
index 59.
3. As ASCII mode is used to export file into FLUENT format, the floating point values such as
coordinates of mesh nodes should be written in a fixed format with a certain fixed number of
digits after decimal point. The current version supports exportation with 12 digits, unlike ver-
sion 1.1 where only 6 digits were written.
The table below lists the dependency between Fluent and HEXPRESS boundary condition types.
Any of the Fluent boundary conditions is applied by selecting the appropriate boundary condition
type of HEXPRESS. The correspondence is not unique because of the large number of boundary
conditions available in Fluent. Moreover, groups and set up of boundary conditions are also
exported to Fluent.
HEXPRESS™ type Fluent type ID Fluent type description
EXT 9 pressure-far-field
INL 10 velocity-inlet
OUT 36 outflow
MIR 7 symmetry
PER 12 or 8 periodic or periodic-shadow
SOL 3 wall
ROT 4 or 5 (or 3) pressure-inlet or pressure-outlet (or wall)

For patches defining rotor-stator, they will be exported as "pressure-inlet", "pressure-

1. A leaf cell is a cell having no child.

HEXPRESS™ 2-11
User Interface Menu Bar

outlet" or "wall" if their name is respectively containing the keyword "inlet_rotor-stator",


"outlet_rotor-stator" or none of the previous keywords.
When periodic (PER) boundary conditions are set into HEXPRESS™ and the mesh
exported to Fluent, there is an access violation error when building the grid. The worka-
round is to switch PER to mirror (MIR) boundary condition, then export and rework in
Fluent.
 The FNMB concept does not exist in Fluent. FNMB created in HEXPRESS™ are
thus ignored.
 Fluent may present poor results at the periodic boundary conditions but its get better
the finer (better resolution) the mesh is at the periodic connection.
The quality of all HEXPRESS™ mesh files exported to Fluent (with suffix) ".msh"
cannot be checked in T-GRID. Nevertheless, the check is possible directly in Fluent: /
Grid/Check.
Files with suffix ".msh" must be imported in Fluent 6.0 (or more) rather than simply opened like in
Fluent 5.3 and 5.4.
Fluent 6.0 then automatically performs checks on the imported mesh and typically displays a set of
warnings referring to the presence of anisotropic subdivisions in the mesh as explained in the above
mentioned remark. These warnings are indicative and have not been reported to hinder the conver-
gence or the accuracy of the simulation.

c) Project/Export.../Samcef-Bacon
HEXPRESS exports conformal hexahedral meshes in the Samcef/Bacon ASCII mesh file format.
This option is available to the user via menu Project/Export.../Samcef-Bacon. An ASCII file is
exported in the user-defined directory and denoted "project_name.bacon".

Exporting multiblock domains is not available in Samcef-Bacon format.


The file contains a region defining the node coordinates. The region starts by a tag .NOE, then each
node is listed with the following format:
I node index X x y z
The cell connectivity is exported in a region beginning with the tag .MAI. Cells are listed as fol-
lows:
I cell index N n1 n2 n3 n4 0 n5 n6 n7 n8
The following correspondence exists between the NUMECA hexahedron (see Table 2) numbering
and the Samcef/Bacon one:

TABLE 2. NUMECA-Samcef/Bacon hexahedron nodal numbering

HEXPRESS Samcef/Bacon
0 0
1 1
2 2
3 3
4 5
5 4

2-12 HEXPRESS™
Menu Bar User Interface

TABLE 2. NUMECA-Samcef/Bacon hexahedron nodal numbering

HEXPRESS Samcef/Bacon
6 7
7 6
This file format is only compatible with fully conformal meshes (mesh presenting no hanging nodes
- see Figure 2.3.1-6).

d) Project/Export.../CGNS
The menu Project/Export…/CGNS offers the possibility to export meshes generated by HEX-
PRESS in standard CGNS format. The CGNS file will contain coordinates of mesh vertices, cell
connectivity, parent-child information of mesh faces and edges, boundary faces connectivity and
boundary conditions.
The CFD General Notation System (CGNS) provides a general, portable, and extensible standard
for the storage and retrieval of computational fluid dynamics (CFD) analysis data. It consists of a
collection of conventions, and free and open software implementing those conventions.
The CGNS system is designed to facilitate the exchange of data between sites and applications, and
to help stabilize the archiving of aerodynamic data. The data are stored in a compact, binary format
and are accessible through a complete and extensible library of functions.
The finest mesh for all domains will be exported and the following data will be stored in the file:
• Coordinates of nodes
• Connectivity of cells
• Connectivity of cell faces on the boundary (surface mesh)
• Boundary conditions
General information such as file structure on CGNS web site: www.cgns.org
The CGNS file will contain one base. The name of this base is “Unstructured data”. The base will
be divided into zones. One zone corresponds to one domain. Here is the description of each zone:
• Zone type: Unstructured
• Zone name: name of the domain
— Vertex coordinates
Only the finest grid is considered. The vertex Cartesian coordinates are stored under the node
‘GridCoordinates_t’. The names of each component are respectively “CoordinateX”, “Coordi-
nateY”, and “CoordinateZ”.
— Cell connectivity

HEXPRESS™ 2-13
User Interface Menu Bar

The cell connectivity is stored under the node ‘Elements_t’. All the cells generated by HEXPRESS are
hexahedral, with no internal vertex, so the CGNS cell type ‘HEXA_8’ has been chosen to define them.
Moreover the cell connectivity definition in HEXPRESS differs from the CGNS definition:

FIGURE 2.3.1-8 HEXPRESS (left picture) and CGNS (right picture) connectivities

— Face cell connectivity on the boundary


The boundary elements are separately listed in the CGNS file. This is useful for assigning boundary con-
ditions.
So there are as many additional ‘Elements_t’ nodes as topological surfaces. Each of these additional
nodes lists the corresponding faces as elements, which CGNS type is ‘QUAD_4’.
— Boundary conditions
The boundary conditions are stored under the node ‘BC_t’. The name of this node is the name of the
BCData.
The boundary conditions can be applied either on nodes, either on boundary faces. Here, each boundary
condition is defined by a list of boundary elements. The lists have been defined previously in the “Face
cell connectivity on the boundary” section.
The boundary condition type is set for each boundary element. Here is the correspondence between
CGNS and HEXPRESS boundary condition types:

TABLE 3. CGNS/HEXPRESS correspondence

CGNS designation HEXPRESSdesignation


BCExtrapolate EXTERNAL
BCInflow INLET
BCSymmetryPlane MIRROR
BCOutflow OUTLET
BCWall SOLID

e) Project/Export.../NASTRAN
HEXPRESS can export mesh files to NASTRAN format (".bdf") in single or double precision (the
choice is asked during exportation). The selection between single and double precision is done after
clicking on Nastran menu.

2-14 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.1-9 Precision for Nastran export

f) Project/Export.../OpenFOAM
The mesh is converted into polymesh representation accepted by OpenFOAM1. The latter is based
around faces. Internal cells connect 2 cells. Boundary faces address a cell and a boundary patch.
Each face is assigned an ‘owner’ cell and ‘neighbour’ cell so that the connectivity across a given
face can simply be described by the owner and neighbour cell labels. In the case of boundaries, the
connected cell is the owner and the neighbour is assigned the label ‘-1’. The I/O specification con-
sists of the following files:
1) points a list of vectors describing the cell vertices, where the first vector in the list represents ver-
tex 0, the second vector represents vertex 1, etc.;
2) faces a list of faces, each face being a list of indices to vertices in the points list, where, the first
entry in the list represents face 0, etc.;
3) owner a list of owner cell labels, the index of entry relating directly to the index of the face, so
that the first entry in the list is the owner label for face 0, the second entry is the owner label for face
1, etc;
4) neighbour a list of neighbour cell labels;
5) boundary a list of patches, containing a dictionary entry for each patch, declared using the patch
name.
To know how many cells are in their domain, there is a note in the FoamFile header of the owner
file that contains an entry for nCells.

 When exporting an imported structured mesh (converted in unstructured) only the
finest grid level is supported. It is not possible to export in OpenFOAM a coarser grid
level.

g) Project/Export.../CEDRE
HEXPRESS can export mesh files to CEDRE format (".dat" and "_bcs.dat"). The file is com-
posed by five sections including generality, node coordinates, connectivity: faces to nodes, connec-
tivity: face to cells and marked faces (for boundary conditions).

Full Non Matching connections (FNMB) are not supported by CEDRE.

1. [1] OpenFOAM , User Guide , Version 1.6 , 2009 and [2] OpenFOAM , Programmer’s Guide, Version 1.6 ,
2009.

HEXPRESS™ 2-15
User Interface Menu Bar

h) Project/Export.../CEDRE (short names)


HEXPRESS can export mesh files to CEDRE format (".dat" and "_bcs.dat"). The file is com-
posed by five sections including generality, node coordinates, connectivity: faces to nodes, connec-
tivity: face to cells and marked faces (for boundary conditions). In both files, the face names are
automatically adapted to maximum 13 characters.

Full Non Matching connections (FNMB) are not supported by CEDRE.


2-3.1.7 Project/Clear cache...
The menu Project/Clear cache... offers the possibility to clear the mesh stored in the cache sub-
folder after each generation step is completed or at the end of a mesh generation for instance. This
can free a significant disk space but will no longer allow to re-load a previous step from the mesh
wizard.

2-3.1.8 Project/Script...
Actions executed by the user through the HEXPRESS™ interface are recorded in a Python-like
script giving added flexibility for automation of geometry creation and mesh generation.

More information about Python scripts are given in chapter 7.


Project/Script.../Edit... opens a dialog box displaying all the commands performed by the user
since the beginning of its session. The user can easily edit this script (add, remove and modify com-
mands). The dialog box contains two pull-down menus. File menu allows to open a script in a sepa-
rate dialog box and to save the script in a file. Run menu allows to run the script shown in the
window under the current session ("Rerun on top").

FIGURE 2.3.1-10 Script Recording

Project/Script.../Save All... is used to save the dynamic recording of all commands performed by
the user since the beginning of its session.
Project/Script.../Execute... is used to run a python script file containing HEXPRESS™ com-
mands. A file chooser is opened to select a file with a ".py" extension. Upon selection of a valid file,
the script is executed in the current session and the result is visualized in the graphical window.
Depending on the content of the script, operations will be added to the current project or a new
project will be automatically opened before operations are performed (the previous project is
closed). If the script being run contains a syntactical error it will be aborted and a message will
appear in the shell.

2-16 HEXPRESS™
Menu Bar User Interface

Project/Script.../Re-execute Last can be used to rerun the last script that was run using the
Project/Script.../Execute... command. This option is most useful when writing own scripts manu-
ally to rapidly test it on the fly.

2-3.1.9 Project/Print/As PNG


Project/Print/As PNG is used to specify a file name in which a snapshot of the graphical area is
saved as a PNG formatted picture. A file chooser is opened and when a valid file name is selected,
click on Ok to perform the picture output.

2-3.1.10 Project/Preferences...
Graphic tab gives choices for the graphics driver.

Only drivers (X11 and/or OPEN_GL) usable on the platform are present.
On Windows platform, this thumbnail is not available.

FIGURE 2.3.1-11 Project / Preferences... - Graphics

Mesh generation tab allows expert users to modify the memory allocation and the preference for
multigrid level.
• Chunksize. The default memory value is set to 40,000 (no units) and usually is unchanged. It
specifies the amount of memory to reserve (pre-allocation) before complex object initialization.
If this amount of memory is too small, the memory will be over-fragmented, and we can reach a
bottleneck. At the contrary, if it is too large, there won't be memory limitation, but the software
will be slower. There is no specific recommendation about the value to set, it depends on the
size of the generated mesh.
Suggestion: increase the chunksize by 150,000 until the software can allocate all the
necessary memory. For information, the chunksize has been set to 700,000 to allocate 3.5
Gb on a SGI platform.

HEXPRESS™ 2-17
User Interface Menu Bar

FIGURE 2.3.1-12 Project / Preferences... - Mesh generation

• The parameter Keep finest grid only saves the project by keeping the finest grid only.

Loading tab allows users to choose if they want to load the mesh when opening the project or not.

FIGURE 2.3.1-13 Project / Preferences... - Loading

By default this parameter is not activated, i.e. mesh will not be loaded. The mesh will be loaded
automatically when actions requiring manipulations of mesh are activated. For instances:
• Mesh visualization using the mesh icon
• All mesh cutting tools
• Cell viewer
• All mesh export options
• All mesh quality check options
• Mesh transformation
• FNMB computation
• Delete block option
• Multiblock option

2-18 HEXPRESS™
Menu Bar User Interface

— If a mesh generation step of one block is done/undone (e.g. executing a mesh generation step
or deleting the previous step), the whole mesh will be reloaded first. This is mandatory since
when saving the project, the whole .hex file containing the mesh of each block, needs to be
rewritten.

The message shown in Figure 2.3.1-14 appears at bottom left of the GUI when a project is loaded
in HEXPRESS.

FIGURE 2.3.1-14 Message shown upon loading a project

When executing python scripts or opening a project in batch mode, the mesh is always
loaded.

2-3.1.11 Project/Quit
Project/Quit ends the interactive session. A dialog box opens up to confirm the end of the session.
Please notice that the current work is not automatically saved when exiting HEXPRESS.

FIGURE 2.3.1-15 Project/Quit

Press <Ctrl-q> to directly access this menu item.


2-3.2 Internal Surface
Basic geometrical operations are available in HEXPRESS™, with the objective to create/edit/delete
internal surfaces and allow subsequent local mesh refinement nearby these surfaces during the
adaptation step (see chapter 6). These operations are not dedicated to geometry creation and thus,
we suggest using CAD software. The options proposed are identical to the ones available in IGG™
and can be reached within the menu Internal Surface and the Quick Access Pad/Internal Surface
access.

2-3.2.1 Internal Surface/Edit


Several operations can be performed for editing. This includes copy, translation, rotation, scaling
and mirroring of existing entities. Conversion to C-spline can also be accessed.

HEXPRESS™ 2-19
User Interface Menu Bar

a) Edit->Copy
Internal Surface/Edit /Copy is used to create new curves and surfaces by cloning the selected
geometry curves and surfaces.
After the cloning, new entities can be transformed directly through this tool:
Translation(t), Rotation(r), Scale(s), Mirror(m), None(q)
To perform a simple copy, enter <q> and press <Enter>. Other operations are strictly equivalent to
the corresponding ones of the Edit menu.
After the cloning, all currently selected geometry entities are unselected and the new created enti-
ties are selected. This allows to perform other editing operations on these entities without having to
manually select them.

b) Edit->Translate
Internal Surface/Edit /Translate is used to translate all the selected geometry entities (curves and
surfaces) along a user-defined vector. The following prompt is given to specify the translation vec-
tor:
Translation vector (q)
>> 1 1 1
A curve used in the definition of a surface (i.e. lofting curve) cannot be freely translated, since it
would implicitly change the definition of the surface. To translate such a curve a copy must first be
made (see 20. The copy can then be freely translated.
To quit this option, enter <q> and press <Enter>.

c) Edit->Rotate
Internal Surface/Edit /Rotate is used to rotate all the selected geometry entities (curves and sur-
faces) around a user-defined line. The following prompts are given to specify the rotation line:
Rotation axis vector (q)
>> 0 0 1
Rotation axis origin (q)
>> 0 0 0
Rotation angle (degree) (q)
>> 90
A curve used in the definition of a surface (i.e. lofting curve) cannot be freely rotated, since it
would implicitly change the definition of the surface. To rotate such a curve a copy must first be
made (see 20. The copy can then be freely rotated.
To quit this option, enter <q> and press <Enter>.

d) Edit->Scale
Internal Surface/Edit /Scale is used to scale all the selected geometry entities (curves and sur-
faces) with a user-defined scale factor. The following prompt is given to specify the scaling factor
in the three directions:
Scale factor (x y z) (q)
>> 1 1 1
A curve used in the definition of a surface (i.e. lofting curve) cannot be freely scaled, since it would
implicitly change the definition of the surface. To scale such a curve a copy must first be made (see
20. The copy can then be freely scaled.

2-20 HEXPRESS™
Menu Bar User Interface

To quit this option, enter <q> and press <Enter>.

e) Edit->Mirror
Internal Surface/Edit /Mirror is used to mirror all the selected geometry entities (curves and sur-
faces) according to a mirror plane. The following prompts are given to specify the mirror plane:
Mirror Plane Normal (q) ?
>> 0 0 1
Mirror Plane Origin (q) ?
>> 0 0 0

A curve used in the definition of a surface (i.e. lofting curve) cannot be freely mirrored, since it
would implicitly change the definition of the surface. To mirror such a curve a copy must first be
made (see 20. The copy can then be freely mirrored.
To quit this option, enter <q> and press <Enter>.

2-3.2.2 Internal Surface/Modify Curve


Curves underlying anticipated surfaces can be manipulated in different ways, including the intro-
duction/removal of control points, division, projection, naming, orientation,...

a) Modify Curve->Add Control Point


Internal Surface/Modify Curve/Add Control Point is used to add control points to the selected
curves. The following prompt is given:
Select a point (a = attraction, q = quit) a:Off
The control points are displayed as markers (cross surrounded by a circle). New point is also visual-
ized as marker under the cursor and is simply specified by left-clicking.
The attraction to edges grid points can be activated by simply pressing <a> repeatedly, while the
cursor is in the graphics area.
Control points cannot be added to circles or circular arcs.
To quit the option, press <q> or the right mouse button.

b) Modify Curve->Remove Control Point


Internal Surface/Modify Curve/Remove Control Point is used to remove one or more control
points of the selected curves. The following prompt is given:
Select a point (q)
The control points are displayed as markers (cross surrounded by a circle). To remove a control
point, move the cursor on it and press the left mouse button. If a curve has more than two control
points, the removal of the start or end control point will also remove the curve part between this
extremity control point and the next control point.

Obviously, if a curve has only two control points, these ones cannot be removed.
To quit the option, press <q> or the right mouse button.

HEXPRESS™ 2-21
User Interface Menu Bar

c) Modify Curve->Modify Point


Internal Surface/Modify Curve/Modify Point is used to modify the shape of a curve by modify-
ing one or more control points and/or tangents of the curve. Modification is only possible on the
curves selected by the user.
After selecting this option, the control points and tangents of all selected curves are displayed and a
prompt appears to select a point for modification:
Select a point (a = attraction, q = quit) a:Off
The operations needed to modify a point are as follows:
•Select the point to be modified with the left mouse button.
•Move the selected point to a new location. The new position of the point can be entered from
the keyboard by typing the new coordinates ’x y z’ in the graphics area and pressing
<Enter>.
•Repeat the operation with other points.
•Quit the option with the right mouse button or by pressing <q>.
During the modification, it is possible to attract the current point to other existing points by ena-
bling the attraction mode. Attraction to points is activated or deactivated by pressing <a> within the
graphics area (toggle). The message in the message area is updated accordingly.
The attraction works on all control points of the curves and on the grid points of the grid edges,
when they are visible.

Modification of tangents is only possible for cspline curves. In this case, select the
tangent to be modified with the left mouse button and move the cursor to indicate the
new tangent direction. The new direction of the tangent can be entered from the key-
board by typing the new coordinates ’x y z’ in the graphics area and pressing <Enter>.
Attraction is also available by still pressing <a>.

d) Modify Curve->Modify Point On Surface


Internal Surface/Modify Curve/Modify Point On Surface is used to modify the control points
and the tangents of the selected curves and project them onto the selected surfaces. The modifica-
tion is done in the same way as for the Modify Curve/Modify Point menu. At the end of the mod-
ification of a control point, the point is projected on the selected surfaces.
The curve modified in this way does not in general completely lie in the surfaces. Only the control
points are guaranteed to be on the surfaces.

e) Modify Curve->Discretization
Internal Surface/Modify Curve/Discretization allows the user to change the number of points
used to discretize the curve. These points are used to draw the curve on the screen. This command
applies to all the selected curves.
The following prompt is given to enter the number of intermediate points between two consecutive
control points of the curve:
Number of discretization points between control points (q) ?
>> 10
Enter <q> and press <Enter> to quit this command.

2-22 HEXPRESS™
Menu Bar User Interface

f) Modify Curve->Divide
Internal Surface/Modify Curve/Divide allows the user to divide a selected curve. After the divi-
sion the old curve is removed from the geometry repository and two new curves (bsplines) are cre-
ated. The following prompt is given when activating the option:
Select the division point (a = attraction, q = quit) a:On
The division point is displayed as marker (cross surrounded by a circle) and can be specified by
selecting a point with the mouse within the limits of the curve or it can be entered with the key-
board.
It is possible to attract the division point to edges grid points by enabling the attraction mode.
Attraction to points is activated or deactivated by pressing <a> within the graphics area.
To quit this command, press <q> or the right mouse button.

g) Modify Curve->Reverse Orientation


Internal Surface/Modify Curve/Reverse Orientation is used to reverse the orientation of the
selected curves. Recall that the orientation of curves is important when creating surfaces using
these curves (i.e. Coons patch or lofted surface).

h) Modify Curve -> Set Name


Internal Surface/Modify Curve/Set Name... is used to change the name assigned to a curve. It
opens a dialog box allowing to enter a new name for a curve. The name specified must be a unique
name, not already used by another curve. When pressing on the Apply button, HEXPRESS
assigns the specified name to the first selected curve.
The current name of a curve can be at any time known by activating the curve selection option
(<s>) and by moving the mouse on top of the curve. The curve name will appear in the information
area.

2-3.2.3 Internal Surface/Modify Surface


Name can be changed for internal surfaces.

a) Modify Surface-> Set Name


Internal Surface/Modify Surface/Set Name... is used to change the name assigned to a surface. It
opens a dialog box allowing to enter a new name for the selected surface. The name specified must
be a unique name, not already used by another surface. When pressing on the Apply button, HEX-
PRESS assigns the specified name to the first selected surface.
The current name of a surface can be at any time known by activating the surface selection option
(<Ctrl-s>) and by moving the mouse on top of the surface. The surface name will appear in the
information area.

2-3.2.4 Internal Surface/Select


Several operations can be performed for geometry selection. This includes selection of Cartesian
points, control points, curves and surfaces. Additional shortcuts are proposed.

HEXPRESS™ 2-23
User Interface Menu Bar

a) Select->Cartesian Points
Internal Surface/Select/Cartesian Points allows the user to select or unselect one or more visible
Cartesian points with the mouse. When selected, the Cartesian points appear highlighted in blue
(default) else they appear in white. The following prompt appears when selecting this option:
Select Cartesian Point(s) (a = all, q = quit)
Subsequent operations are done with the mouse in the graphics area:
•moving the mouse over a non-selected point highlights it,
•pressing the left mouse button selects it,
•pressing one more time unselects it,
•pressing the right button or <q> terminates the selection process.

It is possible to select or unselect all points at once by pressing <a> in the graphics
area. The first time <a> is pressed all the points are unselected. The next time, <a> acts
as a toggle.

b) Select->Curves
Internal Surface/Select/Curves allows the user to select or unselect one or more visible curves
with the mouse for subsequent operations in geometry modelling or grid generation. When selected,
the curves appear highlighted in yellow (default). The following prompt appears when selecting
this option:
<1> Select curve(s), <1 Drag> Area selection, <3> quit, (a = all)

<1> corresponds to left mouse button, <2> to middle mouse button, <3> to right
mouse button.
Subsequent operations are done with the mouse in the graphics area:
•moving the mouse over a non-selected curve highlights it,
•pressing the left mouse button selects it,
•pressing one more time unselects it,
•pressing the left mouse button without releasing it and dragging the mouse draw a rectangle.
Releasing the left button selects all the curves having a part in this rectangle,
•pressing the right button or <q> terminates the selection process.

It is possible to select or unselect all curves at once by pressing <a> in the graphics
area. The first time <a> is pressed all the curves are unselected. The next time, <a> acts
as a toggle.
During the selection, the information area is used to display information about the current curve.
Typical information is: curve name, arc length of the discretization curve,...

c) Select->Surfaces
Internal Surface/Select/Surfaces allows the user to select or unselect one or more visible surfaces
with the mouse for subsequent operations in geometry modelling (i.e surf-surf intersection) or grid
generation (i.e face grid generation). When selected, the boundary curves of the selected surfaces
appear highlighted in red (default) else they appear in blue.
Surface selection is possible by simple positioning of the mouse over the surface. When several sur-
faces are stacked on top of each other, HEXPRESS provides a way to sweep through the surfaces
before selecting the desired one.
The following prompt appears when selecting this option:

2-24 HEXPRESS™
Menu Bar User Interface

<1> Select surface(s), <Ctr-1> Select more, <Ctr-a> Select/Unselect all

<1> corresponds to left mouse button, <2> to middle mouse button, <3> to right
mouse button.
Subsequent operations are done with the mouse in the graphics area:
• Move the mouse to a surface to select (unselect). The surface is ready for selection (unse-
lection) when it becomes highlighted.
• Left-click to select (or unselect) the surface. The surface changes its highlight to reflect its
new selection status.
• It is possible to select several surfaces at once by successive <Ctrl> + left-clicks.
• When several surfaces are stacked on top of each other, HEXPRESS takes by default, the
closest surface to the user in the direction of the user’s eyes. The user can sweep through
the surfaces by middle-clicking the mouse, until the desired surface is highlighted. Left-
click then allows to select the highlighted surface.

It is possible to select or unselect all surfaces at once by pressing <Ctrl> + <a> in the
graphics area. The first time <Ctrl> + <a> is pressed all the surfaces are unselected. The
next time, <Ctrl> + <a> acts as a toggle.
During the selection, the information area is used to display information about the current surface,
such as its name.

2-3.2.5 Internal Surface/View


Similarly, large possibilities are offered to visualize the different geometrical elements.

a) View->Points
Internal Surface/View/Points allows the user to choose which Cartesian points are displayed. A
point chooser (Figure 2.3.2-2), showing all the points in the geometry repository, is opened to select
the points. The visible points are highlighted. To make one or more points visible, select them with
the left mouse button in the chooser, then press Apply. The points are automatically displayed in the
graphics area.

FIGURE 2.3.2-1 Point chooser

HEXPRESS™ 2-25
User Interface Menu Bar

The <Ctrl> key is used in combination with the left mouse button to select several points in the
chooser.
The <Shift> key is used in combination with the left mouse button to select a range of points in the
chooser. A range of points can also be selected by pressing the left button, dragging the mouse and
releasing the left button.
A filter, using regular expression search, is provided to select or unselect points by their name.

b) View->Curves
Internal Surface/View/Curves allows the user to choose which curves are displayed. A curve
chooser (Figure 2.3.2-2), showing all the curves in the geometry repository, is opened to select the
curves. The visible curves are highlighted. To make one or more curves visible, select them with the
left mouse button in the chooser, then press Apply. The curves are automatically displayed in the
graphics area.

FIGURE 2.3.2-2 Curve chooser

The <Ctrl> key is used in combination with the left mouse button to select several curves in the
chooser.
The <Shift> key is used in combination with the left mouse button to select a range of curves in the
chooser. A range of curves can also be selected by pressing the left button, dragging the mouse and
releasing the left button.
A filter, using regular expression search, is provided to select or unselect curves by their name.

c) View->Surfaces
Internal Surface/View/Surfaces allows the user to choose which surfaces are displayed. A surface
chooser (Figure 2.3.2-3), showing all the surfaces in the geometry repository, is opened to select the
surfaces. The visible surfaces are highlighted. To make one or more surfaces visible, select them
with the left mouse button in the chooser, then press Apply. The wireframe of the surfaces are auto-
matically displayed in the graphics area.

2-26 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.2-3 Surface chooser

The <Ctrl> key is used in combination with the mouse to select several surfaces in the chooser.
The <Shift> key is used in combination with the mouse to select a range of surfaces in the chooser.
A range of surfaces can also be selected by pressing the left button, dragging the mouse and releas-
ing the left button.
A filter, using regular expression search, is provided to select or unselect surfaces by their name.

d) View->Hide Selected Cartesian Points


Internal Surface/View/Hide Selected Cartesian Points is used to hide all the selected Cartesian
points.

e) View->Hide Selected Curves


Internal Surface/View/Hide Selected Curves is used to hide all the selected curves.

f) View->Hide Selected Surfaces


Internal Surface/View/Hide Selected Surfaces is used to hide all the selected surfaces.

g) View->Control Points
Internal Surface/View/Control Points acts as a toggle to show or hide the control points of all
selected curves.

h) View->Curve Orientation
Internal Surface/View/Curve Orientation acts as a toggle to show or hide the orientation of the
selected curves. An arrow is displayed indicating the orientation of the curve.

2-3.2.6 Internal Surface/Delete


Points, curves and surfaces can be deleted, as indicated in the menu here below. Shortcuts are addi-
tionally proposed.

HEXPRESS™ 2-27
User Interface Menu Bar

a) Delete Cartesian Points


Internal Surface/Delete/Cartesian Points is used to delete selected Cartesian points from the
geometry repository.

There is no undo associated with the delete operation.


b) Delete->Curves
Internal Surface/Delete/Curves is used to delete selected curves from the geometry repository. A
curve cannot be deleted while it is used in the definition of the surface. To delete it, the surface itself
must first be deleted.

There is no undo associated with the delete operation.


c) Delete->Surfaces
Internal Surface/Delete/Surfaces is used to delete selected surfaces from the geometry repository,
if not used by other entities. When deleting a surface all the curves which belong to it are automati-
cally deleted. Typical curves belonging to a surface are uv curves, created with the Internal Sur-
face/Modify Surface/Representation menu.

There is no undo associated with the delete operation.


2-3.3 Grid Menu
2-3.3.1 Grid/Periodicity...
Mesh periodicity can be applied separately to each domain (block), through access to the Grid/
Periodicity... dialog box.
A first window proposes to manage all the mesh periodicities

FIGURE 2.3.3-1 Mesh Periodicity dialog box

Multiple actions are executable:


— New: allows to create a new mesh periodicity.
— Delete: delete the selected periodicity.
— Delete all: allows to delete all mesh periodicities at the same time.
— Edit: opens a new dialog box to modify the settings of the selected mesh periodicity.

2-28 HEXPRESS™
Menu Bar User Interface

— Propagate: allows to apply the same settings from the selected block to all the other ones.

FIGURE 2.3.3-2 Periodicity Edition dialog box

In the Periodicity - Edition dialog box (Figure 2.3.3-2), the following inputs can be specified:
Periodicity name - The user can change the name of the mesh periodicity.
Periodicity types - Periodicity can be specified through rotation, translation and mirror conditions.
— Rotation: domains are rotated by a specified angle around a selected axis (Figure 2.3.3-3).
The rotation axis is defined by the rotation axis direction (axis) and the anchor point (origin).
The number of repetitions is defined indirectly by imposing the number of periodicities for
the domain considered (i.e. a compressor including 36 blades passages should have a
number of periodicities of 36).

FIGURE 2.3.3-3 Mesh before (left) and after (right) rotation repetition

— Translation: domains can be translated by a specified translation vector, defined both in


magnitude and direction. This for instance applies in the definition of a turbomachinery cas-
cade.

HEXPRESS™ 2-29
User Interface Menu Bar

FIGURE 2.3.3-4 Mesh before (left) and after (right) translation repetition

— Mirror: domains can be mirrored with respect to a mirror plane, defined by an origin and the
axis (normal to that plane).

FIGURE 2.3.3-5 Mesh before (left) and after (right) mirroring

The Apply button accepts and apply the current settings to the specified domain(s) while the Clear
button resets all parameters to default values.
Periodic boundary conditions at the domain faces can either be matching (PER) or full non-match-
ing (FNMB). The matching PER connections can be automatically found by using the "Search Peri-
odic BC" button shown in Figure 2.3.3-6. Non matching connections (NMB), Periodic matching
connections (PER) and Partially non matching connections (PERNM) can be preserved from
IGG™ or AutoGrid5™ meshes.

Repeated domains can be displayed accessing View/Repetition... menu.


2-3.3.2 Grid/Boundary Conditions...
The purpose of this menu is to specify the boundary conditions. In practice, boundary conditions
are defined on the surfaces of the computational domain (section 6-5 on page 6-7 for information on
how to define surfaces in the domain). They are therefore independent of the mesh. Since facets of
the mesh are connected to the computational domain, boundary condition information can be easily

2-30 HEXPRESS™
Menu Bar User Interface

retrieved for the mesh entities. When invoking the menu item or pressing the icon in the icon
bar, the following dialog box (Figure 2.3.3-6) is opened:

Face type specified


Set name for patches
Face grouping allows or groups of patches
patches grouping and
upgrouping Filters for selective
visualization in the
patch list

Face browser allows


the selection of
patches and group of
patches

Face selection tool


Periodic BC search

FIGURE 2.3.3-6 Boundary Conditions dialog box

Boundary conditions menu allows to define the type of boundary condition imposed on a patch or
a group of patches. The type of boundary condition for a patch can influence the mesh generation
process. For instance, a box from the Box adaptation will refine only Solid surfaces (SOL). The
other menu influenced by this choice is the Viscous layers menu: it will only list patches flagged as
Solid (SOL). In any case, they are mandatory for the flow solvers and should be correctly defined.

a) Face selection
The boundary condition settings dialog box lists all the faces of the domain, according to the cur-
rent Name, Type or Block filters. A face can be selected by left-clicking in the face browser or inter-
actively in the graphics area. This face is then automatically visualized in the graphics area. It is
possible to select several faces at once in the following ways:
1. While holding the <Ctrl> key down, select the desired faces in the browser.
2. While holding the <Shift> key down, select two faces delimitating a range of faces.
3. While pressing the left mouse button, drag the mouse and release the left button to select a range
of faces.
4. Pressing <Ctrl> + <a> keys down will select all patches.
5. Interactively in the graphics area depending of the selection options (shortcut <o>):
• <Ctrl> + left-click or left-click on successive faces,

HEXPRESS™ 2-31
User Interface Menu Bar

• Draw a rectangle in the graphics area to select all surfaces which are completely or partly
inside the rectangle. For this purpose, hold <Ctrl> key and drag the mouse with the left-
click.

6. Clicking on Select button and move mouse and left-click in the popup menu to select the type of
face selection.

• Select All Blanked allows to select all blanked faces in the graphics area.
• Select Face By Area allows to select all the faces with an area in the range specified by the
user.

• Select Face By Name allows to select all the faces whose name match the input name. A
dialog box is provided to input the name. The name can be a regular expression (i.e. if the
input is "channel*" all the faces whose name begins with channel will be selected)
• Select Geometrically Similar Faces allows to select all the faces with an area and a perim-
eter (under a tolerance of 0.03) identical to the selected face in the list.
• Select Tangent Faces allows to select all the faces tangent to each other (neighbouring
faces presenting an angle above the specified angle), starting from the list of selected faces.

The shortcut <t> can be used to select the option directly.


By right-clicking on a face or a group of faces in the menu or in the graphics area, a popup menu
allows to:

2-32 HEXPRESS™
Menu Bar User Interface

• blank all selected faces (Blank/Unblank),


• group all selected faces (Group),
• set name to all selected faces (Set Name),
• zoom to all selected faces (Zoom in),
• invert selection (Invert Selection),
• undo successive selections of faces (Undo Selection).

The shortcut <h> in the graphics area will display hints. There are information about mouse button
bindings and shortcuts.

b) Filters
The different filters allow the display of specific faces in the browser while hiding the other faces.
The Name filter displays faces by name. Enter or choose an expression and all faces whose name
contains this expression will be listed.
The Type filter lists all faces of a given type (e.g. SOL, INL, OUT, MIR, EXT, NMB, PER, PERNM
etc).
The Block filter lists all faces of a given block (interesting for multi-domain project).

A multiblock structured project from IGG™ or AutoGrid5™ can also be loaded into
HEXPRESS. In this case, full matching (CON) are concatenated to define a single
computational domain.
FNMB connections are flagged as SOL*.
Rotor-stator interfaces are flagged as ROT.
c) Face grouping
The face grouping allows to group together selected patches with the same kind of boundary condi-
tions. It is possible to select them from the boundary conditions dialog box by selecting patches and
licking on Group button but also with the picking method by clicking on them in the graphics area
and then on Group item in the right-click menu.

HEXPRESS™ 2-33
User Interface Menu Bar

d) Face type specification


A menu allows the setting of the boundary condition type for the selected face(s). Available bound-
ary condition types are the following:
• UND: undefined type.
• INL: inlet.
• OUT: outlet.
• EXT: external used to impose farfield conditions.
• SOL: solid used for walls.
• MIR: mirror used to impose a symmetry plane.
To set a type, left-click on the Set face type button of the dialog box; a list with all the types that can
be set manually appears. Move the cursor to the desired type and release the left button to set the
selected boundary condition type on the selected face(s). However, if the selected patches are of
type NMB, PER and PERNM, a message will appear to warn the user that the corresponding con-
nections of the selected patch will be lost.

FIGURE 2.3.3-7 Warning for users about losing NMB, PER and PERNM connections

Users can also set the BC type interactively for face or group of faces in the graphics
area through the right-click menu.

e) Face name
This option allows to set a name to a geometrical face. This name is used further in all the other
menus of the unstructured mesh generator to reference this face.

The Set name action is also available by right-clicking on the face or group of faces in
the menu but as well in the graphics area.

f) Blank/Unblank
It is possible to completely hide faces and make them unselectable, by using the Blank/Unblank
functionality (right-click in the menu or in the graphics area) or by double clicking on the check
box on the left of the surface name. The check box actually shows the state of the surface: unblank
(ticked) or blank (unticked).

g) Periodic BC search
This option allows automatic search among SOL and UND patches for periodic matching faces
(PER). After the search is performed, the corresponding faces will be set to PER automatically as
shown in Figure 2.3.3-8. Only one of the periodic faces will be trimmed. After the trimming step, a
pair of staircase-like faces will be obtained and matching connections is established for the vertices
belonging to the periodic faces.

2-34 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.3-8 Periodic BC for Rotor 37

To disable the usage of periodic connections, users must set the periodic patches from PER to non
PER boundary condition type. The Search periodic BC button will be hidden from the interface if
no rotational periodicity is defined in the project.

This approach works only with cylindrical initial mesh.


Non-periodic domain curves must not share a periodic domain corner, i.e. only one
non-periodic curve can start from some periodic domain vertices.

2-3.3.3 Grid/Non Matching Connections...


The purpose of this menu is to allow the user to define full non matching connections or rotor/stator
interfaces.

a) Full Non Matching Connections


In practice, the full non matching type of connection allows to connect several patches of several
blocks with non matching boundaries. The definition of such connection consists of the following:
• A connection name.
• A list of “left” patches defining one side of the connection.
• A list of “right” patches defining the other side of the connection.
The patches in one list are not restricted to belong to the same face or same block.

It is to be noticed that before defining a full non matching connections, the concerned
patches should have a valid type. The type should still be undefined (UND) or set to
solid (SOL) otherwise the patch won’t appear in the Non Matching Connections Defini-
tion dialog window. When creating the full non matching connection, the related patch
type is set to SOL*. Then when deleting the full non matching connection, the type of the

HEXPRESS™ 2-35
User Interface Menu Bar

related patches is reset to undefined (UND).


Following rules must be respected when performing FNMB connections:
1. A patch can be contained in only one list (either the left patches list or the right one) and
one FNMB connection. It is illustrated in the following figure.

First FNMB Patch 1


connection

Patch 3 Patch 2
Second FNMB
connection

2. A patch closed on itself cannot be used if the connection region includes the closing part. In
this case, the patch must be divided in two patches.

Closing part of the patch

3. Two patch points cannot be coincident. For example, a O-type patch with a singular line or
a triangular patch cannot be used in a FNMB connection.

2-36 HEXPRESS™
Menu Bar User Interface

4. In case of periodic FNMB connections, all the patches defining the connection must have
the same periodicity information (section 2-3.3.1 on page 2-28) and the button Periodic
has to be activated (Figure 2.3.3-9 - right side).

FIGURE 2.3.3-9 Full Non Matching Connections dialog box

Select the menu Grid/Non Matching Connections.... It opens the dialog box shown on
Figure 2.3.3-9 - left side. This dialog box is showing all FNMB and rotor/stator connections already
set.

Clicking on Show by Domain will classify the connections list by domain.


For instance, it allows to manually add a new one by clicking on the button Add. This button opens
a new dialog box (Figure 2.3.3-9 - right side.). It contains two patch browsers to define the left and
right patches lists. The use of the patch browsers is the same as for the Boundary Conditions dialog
box.
To define an FNMB connection:
• Enter a name for the connection.
• Select the patches defining the "left" side. These patches are highlighted in light blue the
graphics area.
• Select the patches defining the "right" side. These patches are highlighted in dark blue in
the graphics area.

HEXPRESS™ 2-37
User Interface Menu Bar

FIGURE 2.3.3-10 Manual addition of a Full Non Matching Connection

• Select the type of connection: Full non matching.


• Select the Periodic button to define a periodic FNMB connection.
• Press on the Ok button to define the FNMB connection.
• This connection will appear in the connection list.
Once a connection is created, patches can be added and/or removed from it. Simply update patches
lists by clicking on Edit and modify the patches.

The process of the computation involves that one side of the connection is triangulated whereas the
other side is projected on it. Default values should normally be used. If the computation fails,
parameters can be tuned. These parameters are local to each connection and saved into it, therefore
to be taken into account they must be set before creating the connection or the button Compute must
be pressed once a parameter is modified.
Maximum projection distance: when the projection distance of a point is greater than this value,
it is rejected.
Minimum projection distance: when all the points of a patch (contained in the projected side of
the connection) have a projection distance greater than this value, the patch projection is
rejected.
Number of smoothing iterations: before projection, some smoothing steps are done on the pro-
jection normals.
Periodic: when one or more periodicities have been defined in the Grid/Periodicity menu, the
connection should be defined accordingly. The periodicity and the number of repetition should
be entered to allow periodic FNMB connection that is not covering the same area. This value is
"1" in case of a classic periodicity and "2" or more in case of a periodicity by repetition.

2-38 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.3-11 FNMB by repetition

Reverse triangulated side: to reverse the triangulated side which is by default the one containing
the greater number of points.

Clicking on Search Connections will perform an automated search of all the full non
matching connections (a limitation is still present for axi-symmetric configuration)
If the two faces to detect are flat and represented by too few triangles, the detection
may fail. The workaround is to discretize the domain with more triangles.
To compute a FNMB connection:
Once a connection is defined, it is possible to visualize the triangulation of the common region by
pressing the Compute button. This triangulation is not directly used in HEXPRESS but only
serves to visualize and compute the triangulation that will be used by the solver and to verify that
the connection is correctly performed.

Select all the desired connections with <Ctrl> and click on the Compute button: all the
connections are computed sequentially. It is also possible to select them by dragging the
mouse in the list or by selecting a group using the <Shift> button of the keyboard.
To view and/or delete an existing FNMB connection:
• Left-click on the desired connection in the connection list to select it.
• If the connection is already performed, the concerned patches (blue) and the resulting con-
nection (red and yellow) are highlighted in the graphics area.

HEXPRESS™ 2-39
User Interface Menu Bar

• To list only the patches involved in the desired connection, click on Edit button.
• Press the Delete button to remove the selected FNMB connection (the type of the corre-
sponding patches is unchanged).

b) Rotor/Stator Connections
In practice, the rotor/stator connection allows to connect two domains presenting different periodic-
ity and/or different rotation speed (i.e. multistage turbomachine). The definition of such connection
consists of the following:
• A connection name.
• A list of "left" patches defining one side of the connection.
• A list of "right" patches defining the other side of the connection.
The patches in one list are not restricted to belong to the same face or same block.

It is to be noticed that before defining a rotor/stator connections, the concerned


patches should have a valid type. The type should still be undefined (UND) or set to
solid (SOL) otherwise the patch won’t appear in the Non Matching Connections Defini-
tion dialog window. When creating the rotor/stator connection, the related patch type is
set to ROT. Then when deleting the rotor/stator connection, the type of the related
patches is reset to undefined (UND).

The patches defining the Rotor and the Stator should be divided in two parts at least:
four different points are required by the algorithm.
The rotor/stator patches should not include regions where R=0.
Select the menu Grid/Non Matching Connections.... It opens the dialog box shown on
Figure 2.3.3-9 - left side. This dialog box is showing all FNMB and rotor/stator connections already
set and allows the user to add a new one by clicking on the button Add. This button opens a new
dialog box (Figure 2.3.3-9 - right side.). It contains two patch browsers to define the left and right
patches lists. The use of the patch browsers is the same as for the Boundary Conditions dialog box.
To define a rotor/stator connection:
• Enter a name for the connection.

2-40 HEXPRESS™
Menu Bar User Interface

• Select the patches defining the "left" side. These patches are highlighted in light blue the
graphics area.
• Select the patches defining the "right" side. These patches are highlighted in dark blue in
the graphics area.
• Select the type of connection: Rotor/stator. Once this is selected, the parameters for rotor/
stator connections will appear as shown in Figure 2.3.3-12.

FIGURE 2.3.3-12 Non Matching Connections - Rotor/stator

• Adapt relative vertex tolerance under expert computing parameters if gaps/overlaps


with a relative distance higher than the tolerance are detected between vertices of connected
patches of one side ("left" or "right") of the connection.
• By default the parameter Align mesh at R/S interface is not activated. It should be acti-
vated if a mismatch between R/S interface is detected. Then, the mesh will be aligned on
both side of the R/S interface.
Only R/S interfaces of type r = const, or z = const, or r/z = const will be treated (the
evolution curve is a straight line).
For non-structured external meshes, only points on hub and shroud lines will be
aligned at Rmin, Rmax (Zmin, Zmax).
If one side of the R/S interface includes more than one block, the correction cannot be
made.
• Press on the Ok button to define the rotor/stator connection.
• This connection will appear in the connection list.

Once a connection is created, patches can be added and/or removed from it. Simply update patches
lists by clicking on Edit and modify the patches.

Click on Search Connections performs an automated search for full non matching

HEXPRESS™ 2-41
User Interface Menu Bar

connections. Clicking on Yes in the confirmation dialogue if the search for Rotor/Stator
connections is also desired. Please take note that this action may take a long time.

FIGURE 2.3.3-13 Confirmation dialogue

To compute a rotor/stator connection:


Once a connection is defined, it is possible to visualize the triangulation of the common region by
pressing the Compute button. This triangulation is not directly used in HEXPRESS but only
serves to visualize and compute the triangulation that will be used by the solver and to verify that
the connection is correctly performed.

Select all the desired connections with <Ctrl> and click on the Compute button: all the
connections are computed sequentially. It is also possible to select them by dragging the
mouse in the list or by selecting a group using the <Shift> button of the keyboard.
To view and/or delete an existing rotor/stator connection:
• Left-click on the desired connection in the connection list to select it.
• If the connection is already performed, the concerned patches and the resulting connection
are highlighted in the graphics area.
• To list only the patches involved in the desired connection, click on Edit button.
• Press the Delete button to remove the selected rotor/stator connection (the type of the corre-
sponding patches is unchanged).

2-3.3.4 Grid/Mesh Quality...


This item opens a tool for analyzing the grid quality. The dialog box provides a histogram present-
ing the cell quality distribution for the selected quality criterion. Different criteria, described in
more details on next pages, are available for assessing the quality of the mesh:
— the negative cells,
— the concave cells,
— the twisted cells,
— the relaxed cells.
— the cell aspect ratio,
— the cell orthogonality,
— the volume,
— the equi-angular skewness,
— the adjacent cell volume ratio,
— the mesh expansion ratio,
All these values are stored in the ".qualityReport" file. But this file also contain more
information: the generation date, block name, the optimization and viscous layer inser-
tion times (seconds), the entire mesh quality (including surface mesh quality), the
number of negative, twisted and concave cells, the total number of points and cells.

2-42 HEXPRESS™
Menu Bar User Interface

Three parameters of the histogram display may be adjusted for the six last criteria of this list
(Figure 2.3.3-14):
• Minimum value, the lower bound of the displayed criterion interval (From:)
• Maximum value, the upper bound of the displayed criterion interval (To:)
• Number of intervals determines the number of bars of the histogram (Number of steps:)
Each bar represents the number of cells whose criterion value is included in the bar interval. By
left-clicking on one of the bars, the corresponding cells are displayed in the HEXPRESSgraphic
area. Cells are displayed in a color varying depending on the value of the quality criterion.

FIGURE 2.3.3-14 Grid/Mesh Quality... dialog box

The dialog box allows also to detect the negative, concave, twisted and relaxed cells. They can be
selected from the Criterion pop down menu. When one of these criteria is selected, no histogram is
displayed and the Manual Correction button can be selected (when cells detected) for an interactive
correction of the mesh (see next section for more details).
The Show markers check button activates the circle markers display of for each vertex of displayed
cells, which facilitates small cells localization of in the computational domain.

a) Negative cells
An important check of the mesh quality is to detect the presence of negative cells, i.e. cells with a
negative volume. The criterion is available for hexahedral, tetrahedral, prism and pyramidal cells.
The number of negative cells is displayed when negative cells is selected as criterion.

b) Concave and twisted cells


Concave and twisted cells are less likely to present robustness or stability issues for numerical solv-
ers, however they should be prohibited from the mesh as they can lead to negative cells through cell
subdivision (h-adaptation); section 6-8.1 on page 6-41 provides more details about these cells types.
The concave and twisted cell criteria are available for hexahedral, tetrahedral, prism and pyramidal
cells.

HEXPRESS™ 2-43
User Interface Menu Bar

c) Orthogonality quality criterion


Orthogonality is defined only for hexahedral cells by an angle in degrees. An angle close to 90
degrees means a completely orthogonal cell. An angle per cell is computed as follows. Let h 1 , h 2
and h 3 be the unit vectors linking the centroids of two opposite faces of a hexahedral cell as pre-
sented in Figure 2.3.3-15.

h3

h1 h2

FIGURE 2.3.3-15 Orthogonality criterion

The following three mixed products are computed:

 ijk = h i   h j  h k   i  j  k 

The measure of orthogonality is then given by:

Ortho = 90 – acos  min   ijk  

d) Aspect ratio quality criterion


The aspect ratio of only hexahedral cell is defined as the ratio of the longest to shortest edge length:

h max
AR = ----------
h min

where h min and h max are respectively the shortest and longest cell edges.

e) Volume criterion
Volume criterion available for hexahedral, tetrahedral, prism and pyramidal cells, corresponds to
the histogram of the cell volume distribution in the whole computational domain. The volume units
are linked to the units of the domain used to perform the mesh within HEXPRESS™.

f) The equi-angular skewness


The equi-angular skewness only for hexahedral cells is defined by a value include in [0,1]:

 T max – T e   T e – T min 
EquiAngularSkewness = max  ---------------------------
- ---------------------------
 180 – T e Te 

T min and T max are respectively the minimum and the maximum angle of a face or cell

T e is the angle for an equiangular face or cell (60 for triangular face, 90 for quadrilateral face and
90 for hexahedral cells)

2-44 HEXPRESS™
Menu Bar User Interface

g) The adjacent cell volume ratio


The volume jump only for hexahedral cells is given by:

V V
AdjacentCellVolumeRatio i = max  ------j ------i 
 V i V j

i is the cell number


j is the face no locally, from 1 to 5
th
V i is the volume of the i cell

V j is the volume of the neighboring cell to the face j other than cell i .

h) The mesh expansion ratio


The expansion ratio is a measure of the size variation between two adjacent hexahedral cells. It is
direction
dependant and thus computed in each direction.

D D
ExpansionRatio j = max  ------i  ------j
 D j Di 

j is the face no locally


th
D i is the distance between face centroid for the i cell

D j is the distance between face centroid for neighboring cell to the face j other than cell i

The maximum value of the three directions is assigned mesh expansion ratio for the cell.
For the faces having children faces (see Figure 2.3.3-10), expansion ratio is calculated using the
formula:.
2x 1 x 2 + x 3
MeshExpansionRatio = max  ----------------  ----------------
 x 2 + x 3 2x 1 

FIGURE 2.3.3-16 Face having children faces

i) Surface Mesh Quality


A surface mesh quality is also computed by HEXPRESS™ but not shown in the Mesh Quality
menu. It is stored in the ".qualityReport" file only. The computed values are slightly different from
volume mesh quality:

HEXPRESS™ 2-45
User Interface Menu Bar

• Minimum/Maximum/Average/Standard deviation of face size expansion ratio,

Expansion ratio for face F0 = Max(L0/((L1+L2)/2) , ((L1+


Expansion ratio for face F0 = Max(L1/L0, L0/L1)
Expansion ratio for face F1 = Max(L0/L1,L1/L0)
Expansion ratio for face F1 = Max(L0/L1, L1/L0)
Expansion ratio for face F2 = Max(L0/L2,L2/L0)

• Minimum/Maximum/Average/Standard deviation of face orthogonality. The orthogonality for


the face F0 is the angle between two vectors V1 and V2 created by the center points of opposite
edges of the face. If this angle is greater than 90 then the computed angle will be subtracted
from 180 to compute correct orthogonality.

j) Relaxed Cells
In case the relaxing geometry option has been used during optimization step (see 43), by clicking
on the Relaxed cells criteria, it is possible to check the number of relaxed cells and visualize them in
the graphics area at the same time.

k) Manual Correction
When the negative or concave cells criteria is selected in the Mesh Quality dialog box, the button
Manual Correction is clicked to open the interactive mesh modification dialog box (see
Figure 2.3.3-17).
To perform an interactive mesh correction, proceed as follows:
1. In the Mesh Quality dialog box, select the criteria corresponding to the cells to be corrected
(negative or concave cells).
2. Select the Manual Correction button (if there are negative or concave cells appearing in the
Graphics area), the message "<1> Select Cell, <3> quit" appears in the message area.

<1> corresponds to left mouse button, <2> to middle mouse button, <3> to right
mouse button.
3. Click on the cell to be corrected with the left mouse button, the Manual Mesh Correction dia-
log box appears (see Figure 2.3.3-17). The dialog box is made of four main parts:

2-46 HEXPRESS™
Menu Bar User Interface

• On the left, the list of the nodes from the selected cell. When a node is selected in this list,
the other parts are updated and the selected node appears in red in the graphics area.
• On the right side, the cells around the selected node are listed, with the currently selected
cell highlighted in green. In this list, the first column contains the cell number, the second
column indicates if the cell is currently represented in the graphical area (in that case, it is a
"1" otherwise it is a "2") and the third column indicates the quality value of the cell. This
value represents the energy of deformation: greater the value is, more deformed the cell
becomes. If the volume is negative, then the volume is written; and if the cell is concave or
twisted, the menu will display "Concave" or "Twisted".
• In the lower middle part, the coordinates of the currently selected node are displayed and
small arrows can be used to move the node along the X, Y or Z axis. Each click on an arrow
button moves the node by a step that can be controlled in the step entry situated below the
node coordinates.
• In the upper middle part, the gradient of the quality value is displayed. The gradient is com-
puted as the partial derivative of the quality value with respect to a displacement of the cur-
rent node in the X, Y or Z direction.

FIGURE 2.3.3-17 Manual mesh correction dialog box

4. When a cell node is moved, the quality values are updated. The quality value is interpreted as
follows:
• A negative value indicates a negative cell. The quality value is then the volume of the cell.
• A B character indicates that the cell is concave in the slow mode.
• A positive value indicates that the cell is neither negative nor concave. Small values indi-
cate cells with good quality. The higher the value is, the worse is its quality.
5. Representation of a cell in the graphical area can be added or removed by selecting the desired
cell in the cell list (on the right side of the dialog box) and by clicking on the Show/Hide button.
6. The cell that is selected for modification can be changed in two different ways:
• by selecting the desired cell in the cell list (on the right side of the dialog box) and by click-
ing on the Select button.
• When the message "<1> Select Cell, <3> quit" is present, by left-clicking on any of the
cells represented in the graphical area in order to update the dialog box to the selected cell.

<1> corresponds to left mouse button, <2> to middle mouse button, <3> to right
mouse button.
7. During the interactive correction, the initial position of all the nodes may be restored by select-
ing the Reset button.

HEXPRESS™ 2-47
User Interface Menu Bar

8. When the interactive modification is finished, press the Ok button to validate the modification
or press Cancel to discard all the modifications and close the dialog box.

When a node is displaced, HEXPRESS™ is always verifying if the node is con-


strained (e.g. projected on the geometry) or if other node constraints are depending on
the displaced node (e.g. hanging nodes), the constraints remain verified.

2-3.3.5 Grid/Mesh transformation...


Many options to transform the mesh (and the domain) are proposed: rotation, translation, mirroring,
scaling, axisymmetric, and mirroring and copying. The operations can be performed on the active
blocks or on all the blocks. They are applied on the mesh points as well as on the domain.
This menu item Grid/Mesh transformation... opens a dialog box allowing to select the type of
operation and to enter the required data to perform the operation.
Two radio buttons are present to perform the transformation on the active block or on all blocks.

The transformations can only be performed if the mesh has been fist snapped.
a) Rotate
The following dialog box appears when selecting the Rotate thumbnail. It allows to specify the ori-
gin and direction of the rotation axis as well as the angle of rotation in degree.
The Apply button allows to perform the transformation on the active block or on all the blocks.

FIGURE 2.3.3-18 Rotate transformation

b) Translate
The following dialog box appears when selecting the Translate thumbnail. It allows to specify both
direction and magnitude of the translation vector.

2-48 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.3-19 Translate transformation

The Apply button allows to perform the transformation on the active block or on all the blocks.

c) Scale
It is possible to scale a mesh with the following dialog box. The scaling factor must be specified for
each direction.

FIGURE 2.3.3-20 Scale transformation

The Apply button allows to perform the transformation on the active block or on all the blocks.

d) Axisymmetric
The following dialog box appears when selecting the Axisymmetric thumbnail. It allows to specify
the angle of the axisymmetric transformation. It is also possible to impose the number of cells
equally spaced in theta direction (Nb of layers in theta).

HEXPRESS™ 2-49
User Interface Menu Bar

FIGURE 2.3.3-21 Axisymmetric transformation

The transformation from 2D to Axisymmetric is applied on the active block or all blocks when
clicking on Apply button.

Axisymmetric transformation is applied on a generated 2D mesh rotated so as to be in


the Oxz plane with rotation axis along z.
A singular line is not allowed. To avoid singular line, the 2D mesh can be slightly
move from the origin but this may affect the mass flow if for instance the velocity is
imposed at the inlet and the mesh is too far from origin.
When imposing to small angle, that may introduce stiffness in the flow solver. While
imposing a too high angle may introduce error. Usually an angle of 5 degrees seems to be
a good compromise.

e) Mirror and Copy


The following dialog box appears when selecting the Mirror and Copy thumbnail. It allows to
specify the mirror plane: XY, YZ or ZX. Once this plane is specified, the mesh mirroring operation
takes place in two steps: mirroring of the domain and mirroring of the mesh.
At the end of the operation, the user gets a new domain (which is a merged product of the original
domain and its mirror image, with the mirror planes removed from in between the two portions) and
a mesh for the new domain.

The mirror plane must be aligned with Cartesian axis including the point (0,0,0).

2-50 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.3-22 Mirror and Copy transformation

The Apply button allows to perform the transformation on the active block or on all the blocks.

The mesh used for mirroring is considered as final and can not be further refined or
modified in the current session. In case refinement or modification are really needed,
save the mesh project and open it again in a new session.

2-3.3.6 Grid/Multigrid levels...


This option allows the user to specify the number of grid levels he wants to use within FINE™/
Open when saving the grid. If the Number of level(s) to keep is set to 3, it means that 3 grid levels
will be available when linking the mesh to a FINE™/Open project (refer to FINE™/Open User
Manual for more details on the multigrid process).

FIGURE 2.3.3-23 Multigrid levels

This option is present for backward compatibility only with projects before v2.5-4.
2-3.4 View Menu
2-3.4.1 Face Viewer
This menu provides the opportunity to decide how to represent the patches one by one, or by group
if any. Shading, edges, color or mesh can be represented or not. Please read section 2-5.5.2 on page
2-80 to know more about this menu.

HEXPRESS™ 2-51
User Interface Menu Bar

2-3.4.2 View/Cells...
View/Cells... menu allows to display a list of cells specified by their indices.

FIGURE 2.3.4-1 View/Cells... dialog box

The list of cells is specified as a comma (or a space) separated list. Each item is a single number or
a set of two numbers separated by a "-" symbol. A "-" separating pair of numbers is used to specify
a range of element numbers. The first cell in the list is referred to "0".
A shrink factor can be specified. A value of 0.0 indicates that the element is displayed with its true
geometric size. A factor higher than 0.0 indicates that the element is reduced in size following the
formula:
Pi = Pc +  1 – SF    Pi – Pc 

where,

Pi: Coordinates of the cell ith point = (Xi, Yi, Zi)


Pc: Coordinates of the cell center

SF: Shrink factor. If SF=0, no shrink. If SF=1, full shrink. 0.0  SF  1.0

2-3.4.3 View/Face Displacement


View/Face Displacement menu allows to adapt the view if interferences are appearing between the
grid lines and the shading.
When the block face grids are visualized, in both wireframe and solid modes (shading), visual inter-
ference may be produced between the grid lines and the shading. For this reason, HEXPRESS
slightly shifts the grid lines towards the user to get a correct picture.
This shift is controlled by the Face displacement. This parameter represents the amount by which
the grid is shifted along the view plane normal vector (normal to the screen), and is used to correct
the display when combining wireframe and solid representations.
The following window is shown to enter the face displacement (higher or equal to 0).

2-52 HEXPRESS™
Menu Bar User Interface

FIGURE 2.3.4-2 Face displacement parameter

Apply and Close to respectively apply the new parameter and close the window.

2-3.4.4 View/Insert Text


View/Insert Text can be used to insert a descriptive text in the view. The position of the text must
be specified by left-clicking at the desired position in the graphics area. The following prompt
allows entry of text which is displayed at the specified position:
Text description (q)
>> Enter your text here
Press <Enter> to validate and display the text. It can be erased from the view by using the View/
Delete Text menu.
To quit this option, enter <q> and press <Enter>.

2-3.4.5 View/Delete Text


View/Delete Text is used to delete all texts displayed in the graphics area.

2-3.4.6 View/Perspective
View/Perspective is used as a toggle to switch between orthogonal and perspective projection in
the graphics area. By default, orthogonal projection is used.

When using a perspective projection, the selection of curves and edges and the render-
ing of hidden surfaces may not succeed.

HEXPRESS™ 2-53
User Interface Menu Bar

2-3.4.7 View/Repetition...
In order to display grid repetitions, the mesh periodicity has to be defined (section 2-3.3.1 on page
2-28). The View/Repetition... menu allows to repeat the domain and mesh (Figure 2.3.3-3 on
page 2-29.) by specifying the number of repetitions.

FIGURE 2.3.4-3 View/Repetition... dialog box

2-3.5 STL
The STL menu allows to adapt STL geometry files before creating the domain. Please refer to sec-
tion 4-3 on page 4-21 for a description of this menu.

2-3.6 Tools
2-3.6.1 STARCD->STL
The STARCD->STL command is used to convert a surface mesh from StarCD format to a ".stl"
file and its associated ".stl.prop" file. These files can then be imported in HEXPRESS. The mesh
to convert is selected by the user using a file chooser. Either the ".vrt" or the ".cel" file may be
selected. However, the tool expects to find both ".vrt" and ".cel" files. The surface mesh may con-
tain triangles and/or quadrilaterals. In the last case, a quadrilateral is exported as two triangles in the
resulting ".stl" file. The associated property file ".stl.prop" is built based on the information con-
tained in the ".cel" file.

2-3.6.2 Domain->ASCII STL or binary STL


Exports the current selected domain to STL format (ASCII or BIN format), for further treatment in
a separate CAD software or to import in HEXPRESS/Hybrid.
Exporting to ASCII STL creates an ".stl" file and the associated property file ".stl.prop". Exporting
to binary STL, created an ".stl." file only.

2-54 HEXPRESS™
Menu Bar User Interface

2-3.6.3 Tools/Distance
Tools/Distance is useful to measure the distance between two points or between a point and a line.
The following dialog box will appear, showing the distances computed along principal directions
between the two points:

FIGURE 2.3.6-1 Distance Tool

The following prompt appears, asking to enter the first point:


Enter first point (toggle selection: a = points, c = curves, l =distance to line)
Once the first point (or line) is entered, a second prompt appears, asking to enter the second point:
Enter second point (toggle selection: a = points, c = curves, l =distance to line)
To measure the distance between two points, simply select the points with the mouse or enter the
coordinates with the keyboard. For example, to measure the distance between (0,0,0) and (1,1,1),
enter the sequence ’0 0 0’ in the graphics area, followed by <Enter>. Then enter ’1 1 1’ followed by
<Enter>. The distance is indicated in the graphics area and in the information area.
To select an existing point, attraction features are available, allowing attraction to points, curves
and surfaces. To activate the attraction to points, press <a> in the graphics area, then move the cur-
sor to the desired point. Similarly, to activate the attraction to curves, press <c>, then move the cur-
sor to the desired curve. The attraction works on:
• end points of the curves,
• visible Cartesian points,
• visible curves,
• block vertices and fixed points.
In this last case, the attraction cannot be deactivated. When there is attraction, the corresponding
point is highlighted. Simply press the left mouse button to select it.
To measure the distance between a point and a line, press <l> in the graphics area. Then enter a line
origin (with the mouse or the keyboard) and direction (this one must be entered with the keyboard).
The attraction features are also available for the line origin.
Enter line origin (toggle selection: a = points, c = curves)
Enter line direction (keyboard only)
>> 1 1 1
This option can be activated before or after having entered the first point. The distance is measured
perpendicularly to the line.
Once a distance is calculated, another distance can be measured by selecting other points.
To quit this tool, press <q> or the right mouse button.

HEXPRESS™ 2-55
User Interface Menu Bar

2-3.7 Plugins
2-3.7.1 Concept
The purpose of this menu is to provide a plugin mechanism where users can put their own python
scripts and access them through the interface, via a Plugins menu. NUMECA will also provide
some python scripts that users can load.

FIGURE 2.3.7-1 Plugins menu

In the above example, the Marine module has been loaded from the installation package of
FINE/Marine, and the hexpress module is a user-defined folder which contains personal scripts.

2-3.7.2 How to activate them?


The menu contains by default two sub-menus: Load Module Directory... and Save As Default.
The Load Module Directory... opens a directory chooser to select a directory containing users
scripts. When the directory is selected:
• a sub menu, under the Plugins menu is added, with the name of the directory,
• HEXPRESS looks for all ".py" files in the specified directory, except files starting with under-
score ('_'),
• for each ".py" file an item is added to the above-mentioned sub-menu. The name of the item is
the name of the python script, without the ".py" extension.
If a directory is not selected, a dialog box appears with the text "You must select a
directory".
The Save As Default option saves all currently loaded menus in the file "~/.numeca/
hexpress_default_plugins". The file is an ASCII file that looks like:
Marine
/usr/local/MyPlugins/
When launching HEXPRESS, it always looks for the file hexpress_default_plugins. For each
line, HEXPRESS interprets it as a directory and loads all the ".py" files it contains, except those
starting with underscore. If no directory is found HEXPRESS interprets the line as the name of a
default module provided with the package (i.e "Marine" for instance) and loads the related scripts
from the installation package. Indeed, depending on the package, HEXPRESS may come with
predefined scripts, grouped by modules. A module is simply a directory containing a set of python
scripts. These modules are centralized under the directory "_python/_hexpress_plugins" in the
installation folder. For instance, "Marine" is the name given to the FINE/Marine module, hence
all the related scripts will be under the "_python/_hexpress_plugins/Marine" directory.

Under Linux, it is also possible to activate a module from the command line by
launching HEXPRESS in the following way:
hexpress -module <module_name> -niversion ...

2-56 HEXPRESS™
Menu Bar User Interface

A user can create his own python scripts with HEXPRESS macro commands pro-
vided in Chapter 7.

2-3.7.3 Marine Plugins


Marine dedicated plugins are available in the FINE™/Marine package only. This section describes
the plugins directly proposed through the interface of HEXPRESS™ under the sub-menu "Marine".
They can be found in the folder from the installation under "_python\_hexpress_plugins\Marine"
under the form of a python script. Users are free to modify these scripts but any modification might
not be supported.

FIGURE 2.3.7-2 Marine plugins

a) Domain and mesh setup (only for 3D)


The plugin allows to create automatically a domain and mesh settings based on a given Parasolid or
CATIA v5 file with different inputs. (See Figure 2.3.7-3)
Explanations of inputs:
• Clean project: closes current project.
• Load parasolid file: allows to open a parasolid file.
• Load CATPart file: allows to open a CATIA v5 file.
• Application: we usually assume that the domain size can be defined according to the type of
application, the Froude number and based on the Lpp of the boat. Hence default number of Lpp
are given per application but the users are free to enter their own values using the "user-defined"
application.
— Resistance:
LppBefore = 1
LppBelow = 1.5
LppAbove = 0.5
LppSide = 1.5
if Froude <= 1, LppBehind = 3 ; if Froude > 1 and Froude < 1.5, LppBehind = 4 ; otherwise,
LppBehind = 5.
— Seakeeping:
LppBefore = 1
LppBelow = 1.5
LppAbove = 1
LppSide = 1.5
if Froude <= 1, LppBehind = 3; if Froude > 1 and Froude < 1.5, LppBehind = 4, otherwise,
LppBehind = 5.
— Decay:
LppBefore = 3

HEXPRESS™ 2-57
User Interface Menu Bar

LppBelow = 1.5
LppAbove = 1
LppSide = 3
LppBehind = 3
— User-defined: user can prescribe his own numbers. Default are the ones from Resistance.

FIGURE 2.3.7-3 Domain Constructor and Mesh Setup window

• Configuration: defines if the case should be symmetric or not. If the geometry file is already
split in two, ’Symmetric’ should be selected. In case the geometry file is the entire body and the
goal is to simulate half of it, select ’Symmetric’. In case the geometry file is the entire body and
the goal is to simulate the entire body, select ’Non-symmetric’.
• Body orientation: defines the orientation of the reference frame related to the location of the
center o f gravity of the body.
• Reference: defines the reference length (automatically or not) and speed.

2-58 HEXPRESS™
Menu Bar User Interface

• Mesh density: defines the type and number of refinements for each patch depending on its name.
Here is the table of refinement criteria.

If one can define names in the CAD software, the script will be able to recognize them and
define mesh settings accordingly. In the script, a ’Coarse’ mesh correspond to the 1st level,
’Medium’ to 2nd level and ’Fine’ to 3rd level. Hence if the selected mesh density is ’Medium’,
the 2nd number of refinement level will be selected. The same idea applies for the diffusion.
Example 1: if the geometry contains a patch named "Deck", a Target cell size criterion will be
applied with a maximum number of refinement of 4 and target sizes of (0,0,0). The diffusion
will be set to global (2 by default).
Example 2: if the geometry contains a patch named "Rudder", if the user selected a ’Fine’
mesh, the curvature and the Target cell size criteria will be applied with a maximum number of
refinement of 10 and target sizes of (0,0,0). The diffusion will be set to 1.
If the face name is not in this table, the script will assign a target cell size criteria with a value
of 6 for the maximum number of refinements, using a global diffusion.
• Merge patches with the same name: the feature will parse the list of faces and try to merge the
ones with the same name. Names should be defined carefully in the CAD software to avoid that
too many faces are merged.
• Merge tangential faces: when using it, a feature angle is requested to merge all patches which
are tangential according to this given angle. A low angle will merge more faces whereas an
angle close to 180degrees will merge few faces.
• Viscous layers: for a model scale, we assume that Y+ should be between 20 and 50, and for full
scale between 50 and 300. Hence, according to the mesh density:
— Model scale:
if the mesh density is 'Coarse': Y+ = 50.
if the mesh density is 'Medium': Y+ = 30.
if the mesh density is 'Fine': Y+ = 20.
— Full scale:
if the mesh density is 'Coarse': Y+ = 300.
if the mesh density is 'Medium': Y+ = 150.
if the mesh density is 'Fine: Y+ = 50.

HEXPRESS™ 2-59
User Interface Menu Bar

Viscous layers are then defined and computed for solid faces only and if the face is not called
“DECK” or “Deck” since there is usually no need to insert viscous layers on the deck of a ship
(viscous effects from the air part are negligible).
The script assumes an isotropic mesh is used on the solid walls. Hence, the height of the first
Euler cell on the solid walls can be computed by the script according to the number of refine-
ment: size_euler_cell = Initial cell size / 2**N, with N the Number of refinement on the face.
The script will then computes the number of viscous layers needed to completely fill the Euler
cell and ensure that inflation technique will be activated, based on a stretching ratio of 1.2.
The given kinematic viscosity by the user is used to compute the first layer thickness as an
information, printed in the shell.
• Try to Set buffer type to Type II will impose buffer insertion of Type II for the edges on the Mir-
ror plane for the settings of the snapping step. However, HEXPRESS™ will try to respect this
input but it is not guaranteed that it will be the case after snapping. If not, a warning is raised in
the .rep file or in the report file.
After specification of the inputs, domain is constructed, boundary conditions are also defined
automatically, different internal surfaces are created to allow different zone of refinements and
all mesh settings are setup. The user is invited to check the whole mesh wizard before generat-
ing the mesh.

The domain creation will not work in case the symmetry plane is not perfectly aligned
on the Y plane.
Domain creation is not yet implemented for 2d case.
The geometry should be aligned with X-axis initially. Rotation can be done with CAD
manipulation before if necessary. Z-axis should be the gravity axis.
The geometry should not have a bounding box already included since the script will
create it automatically.
Y+ is based on the supposition that wall function will be used during the computation.
The number of viscous layers is computed based on a theoretical formula and does not
take into account the influence from patches nearby. It is advised to let the inflation
method active or to check the number of viscous layers to insert after the optimization
step.

b) Domhydro
This plugin allows the "domhydro" tool to be launched inside HEXPRESS™ interface. "Domhy-
dro" serves as a tool which can solve the hydrostatic problem of a body using the domain and
boundary conditions files from HEXPRESS™.

b.1)Assumptions
— Horizontal positions of center of gravity and the center of buoyancy are equal. The vertical
position of the center of gravity is approximated considering that the mass is equally distrib-
uted on the shell below the free surface (equal distribution of the mass on the wetted sur-
face). The same distribution of mass is used to approximate the different inertia.

For instance, this should be taken into account especially for superstructures where the
mass in the air part can be important.

2-60 HEXPRESS™
Menu Bar User Interface

— This tool provides parameters based on geometric considerations. Hence, it is advised to


compare the results with real values if they are known (given by the naval architect for
instance).
— In 3D, the body is assumed to be aligned along the X-axis. If it is not the case (for instance
the body has an initial yaw angle), one should specify it in the Cardan angles.
— In 2D, the roll motion of a boat section is defined by the rotation around z0, i.e. the "yaw
Rz0" rotation.
— When using an additional external effort, only the final Z-axis resultant and the moment
along X and Y-axis are taken into account the equilibrium position (the others components
cannot be counterbalanced by hydrostatic forces).
— The body should not be in a bucket shape (the body is not close by a flat deck and it is
"empty" inside), otherwise if its ground is below the free surface location, water will be con-
sidered inside.

FIGURE 2.3.7-2 Illustration of a problematic case where water is considered inside the body

b.2) Modes Description


Two modes are implemented in this tool: Hydrostatic to Parameters (h2p) or Parameters to Hydro-
static (p2h). Each one has its own objective described below:
• h2p: in this mode, the body is assumed to be at the hydrostatic position. As a result, the tool
provides extra information on the body’s characteristics. They are listed below:
— Total wetted surface
— Projected wetted surface
— Water plane area
— Total volume
— Immersed volume
— Volume in the air
— Mass
— Center of buoyancy
— Estimated center of gravity (wetted body surface)
— Estimated center of gravity (entire body surface)
— Estimated Inertia tensor (wetted body surface)
— Estimated Inertia tensor (entire body surface)

HEXPRESS™ 2-61
User Interface Menu Bar

• p2h: in this mode, the parameters of the body are known (mass, position of the center of grav-
ity), and the tool computes iteratively the hydrostatic and the equilibrium positions.
The equilibrium position corresponds to the hydrostatic position with all the degrees
of freedom free. Indeed, one can decide to freeze one or several degrees of freedom to
compute the hydrostatic position.
In p2h mode, the tool computes the following information, including the rotation and the
translation to apply on the domain if necessary, using the ’Move Part’ feature in Domain
Manipulation for instance:
— Rotation axis
— Rotation angle
— Point of rotation (gravity center)
— Vertical translation
— New position of the gravity center
— Cardan angles (Yaw Rz0, Pitch Ry1, Roll Rx2 in final position (deg.))
— Total wetted surface (final position)
— Projected wetted surface (final position)
— Water plane area (final position)
— Center of buoyancy (final position)
— Cardan angles (Yaw Rz0, Pitch Ry1, Roll Rx2 in equilibrium position (deg.))
— Total wetted surface (equilibrium position)
— Projected wetted surface (equilibrium position)
— Water plane area (equilibrium position)
— Total volume (equilibrium position)
— Immersed volume (equilibrium configuration)
— Volume in the air (equilibrium configuration)
— Estimated Inertia tensor (wetted body surface)
— Estimated Inertia tensor (entire body surface)

In both modes, the output is written in a file called


’domainfilename_domhydro_mode_b#.out’, stored in the folder of the domain file (cau-
tion with writing permissions!). The template is always the same and "domhydro" writes
NA in case the parameters were not computed by the selected mode.

The formula used to calculate total wetted surface isS W


2 2 2
= S Xf + S Yf + S Zf where as
the formula for projected wetted surface (without considering surface along X) is
2 2
S W = S Yf + S Zf .

b.3)How to use the tool


"Domhydro" is based on the domain and boundary conditions files. Hence, once the domain is cre-
ated, cleaned and saved, "domhydro" can be launched. Manual hints should be given to the tool: it
should know how many bodies are present and their respective location. For this purpose, the
boundary conditions names should be adapted:
• go to the boundary conditions menu,
• add the suffix "_b#" behind each solid surface name of each body (where "#" represents the
body’s index),

2-62 HEXPRESS™
Menu Bar User Interface

• save the HEXPRESS™ project again (under another name if one does not want to lose the pre-
vious names),
• launch "domhydro".

b.4) How to launch the tool


Clicking on the plugin opens the wizard (See Figure 2.3.7-4) for the tool and default values are
defined. The complete list of inputs is given below.

FIGURE 2.3.7-4 Domhydro Wizard

b.4.1) General Inputs


Inputs:
Clean Project: closes the current open project.
Load Domain File: opens a new domain file.
Fluids/Flow Properties:
Water density, default = 998.4 Kg/m3
Air density, default = 1.2 Kg/m3
Z-gravity component , default = -9.81 m/s2
Body Definition:
One should select if the loaded domain is the entire boat or half boat.
Body index: corresponds to the "#" from all the "_b#" added in the boundary condition menu.
Cardan Angles (see FINE™/Marine user manual for more information about Cardan angles):
Initial Roll angle (deg), Pitch angle (deg) and Yaw angle (deg)
Mode selection:
"hydrostatic position to parameters" or "parameters to hydrostatic position"

HEXPRESS™ 2-63
User Interface Menu Bar

b.4.2) Inputs for Hydrostatic Position to Parameters


Initial free surface location (Z), default = 0.0m
Z-coordinate of the center of gravity (’domhydro’ can also compute it automatically).

b.4.3) Inputs for Parameters to Hydrostatic Position

2-64 HEXPRESS™
Menu Bar User Interface

Additional modification of orientation: (for instance, one can add extra rotations in order to calcu-
late the hydrostatic positions for several roll angles, starting from the same domain file)
Extra Roll angle (deg), Pitch angle (deg) and Yaw angle (deg)
Motion to freeze: it is possible to freeze the roll or pitch during the calculation of the hydrostatic
position.
Characteristics of the body:
Mass of the body, default: 0.0Kg
Center of gravity: Xcog,Ycog,Zcog
External force: It is possible to add an external force (resultant and moment) to compute the hydro-
static position, taking into consideration a wind effect on a sail for instance. This force can be a fol-
lower effort (default) or a non-follower one. With the non-follower, the direction of the force does
not change when the body moves: this is the case an extra mass is attached onto a body. To summa-
rize:
• follower efforts: the force direction does change according to the body motion
• non-follower efforts: the direction of the force remains fixed (like gravity)
Fx,Fy,Fz, default = (0.0,0.0,0.0) N
Mx,My,Mz, default = (0.0,0.0,0.0) N.m
Xapp,Yapp,Zapp coordinates of the application point, default = (0.0,0.0,0.0) m
Expert parameters:
Tolerance : collapsed points tolerance, default = 1e-06 m
Maximum number of iterations, default = 1000

b.5)Examples
b.5.1) Inertia Matrix is unknown
A classic situation is when the geometry is received in its hydrostatic position and all the boat’s
characteristics are known except the inertia matrix. The inertia matrix is mandatory when solving
the motion thanks to the Newton’s laws. In this case, one can use "domhydro" in h2p mode to calcu-
late the inertia matrix.
b.5.2) Sailing boat
Let’s consider the following situation:
• several roll angles of a sailing boat should be simulated (let’s say 2, 5 and 7 deg.),
• the mass and the initial gravity center location are known,

if it is not the case, "domhydro" should be first run in h2p mode.
• the geometry is in its primary configuration.
This procedure should be followed:
1. Launch "domhydro" in p2h mode entering the basic inputs and in particular:
— Cardan angles of the configuration (deg.): 0 0 0,

In case the boat is not in its primary configuration, values different from 0 should be
entered for the initial Cardan angles.

HEXPRESS™ 2-65
User Interface Menu Bar

— additional modification of the orientation (deg.): D_Rz0 D_Ry1 D_Rx2, with D_Rz0=0
D_Ry1=0 D_Rx2=2, which corresponds to the new orientation of the boat.
2. "domhydro" returns the new hydrostatic position of the boat and the domain transformation to
apply in HEXPRESS to put the boat in its new position, including the new Cardan angles.
3. Go back to HEXPRESS and use the ’Move Part’ feature to move the body (or the CAD soft-
ware)
4. Start meshing with the new domain (equilibrium configuration).
5. In the menu Motion parameters of the FINE/Marine interface, the Cardan angles should be
set to their new values.
6. Repeat these actions for the roll angles: 5 and 7 degrees.
b.5.3) Roll decay test
Let’s consider the following situation:
• the idea is to simulate a roll decay test starting from an initial angle of rotation (let’s say 5
deg.),
• the mass and the initial gravity center location are known,

if it is not the case, "domhydro" should be first run in h2p mode.
• the geometry is in its primary configuration.
This procedure should be followed:
• Run ’domhydro’ in p2h mode entering the following information:
— Cardan angles of the configuration (deg.): 0 0 0

In case the boat is not in its primary configuration, the corresponding values should be
entered for the initial Cardan angles.
— additional modification of the orientation (deg.): 0 0 0 corresponding the primary configura-
tion
• "domhydro" returns the new position of the boat to get the hydrostatic position.
• Go back to HEXPRESS and use the ’Move Part’ feature to prepare the domain in hydro-
static position.
• Run ’domhydro’ in p2h mode with the new domain, entering the following information:
— Cardan angles of the configuration (deg.): 0 0 0
— additional modification of the orientation (deg.): D_Rz0 D_Ry1 D_Rx2, with D_Rz0=0,
D_Ry1=0, D_Rx2=5 corresponding the future initial orientation of the boat.
• Keep the roll angle fixed.
• "domhydro" returns the new hydrostatic position of the boat.
• Go back to HEXPRESS.
• Start meshing with the previous domain (it is not necessary to use the ’Move Part’ now).
• In the menu Motion parameters of the FINE/Marine interface, the Cardan angles should be
set to 0 0 0 but in the Initial Conditions tab, the initial rotation angles should be changed to
deltaRx2=5, deltaRy1=0, deltaRz0=0 and initial vertical position of the gravity center to its
new location, found from the last run of "domhydro".
b.5.4) Follower and non-follower forces
Here is an example of a computation of a hydrostatic position. The case is a cube with the following
characteristics:

2-66 HEXPRESS™
Menu Bar User Interface

• center of gravity coordinates: (0,-1,-3), mass: 2000 kg, dimensions: 2x2x2m, centered on point
(0,0,0).
• gravity: -10 m/s2, water density: 1000 kg/m3, air density: 0 kg/m3
— follower force with intensity (0,14142.136,-14142.136) N is applied on the application point
with coordinates (0.,3.,1). The result is illustrated below:

FIGURE 2.3.7-6 Follower force

— non-follower force with intensity (0,14142.136,-14142.136) N is applied on the application


point with coordinates (0.,3.,1). The result is illustrated below:

FIGURE 2.3.7-5 Non-follower force

Definition of the body indexes are required. For user who does not want to modify the
names of the patches, they can create a project backup before running ’domhydro’.

c) Mesh quality check


This plugin checks the mesh quality for the current loaded mesh and displays a theoretical color
code in function of the results, as well as the reasons for such a color code.

HEXPRESS™ 2-67
User Interface Menu Bar

FIGURE 2.3.7-6 Mesh quality check message

Meaning of the color code:


• the color code turns Red if one of this criteria is true:
if the number of invalid cell (negative, concave or twisted) is different from 0
if the minimum orthogonality is < 5 degrees
if average orthogonality < 65 degrees
if maximum aspect ratio is > 5000
if maximum expansion ratio is > 20
• otherwise, the color is Yellow if one of this criteria is true:
if min orthogonality < 15 degrees
if average orthogonality < 75 degrees
if maximum aspect ratio is > 2000
if maximum expansion ratio is > 5
• otherwise, it stays Green.
It should be noticed that we usually advise a minimum orthogonality bigger than 5
degrees to ensure that the mesh displacement with a weighting deformation will work for
a reasonable motion amplitude. In case the minimum orthogonality is very close from 0,
we strongly advise to rework on the mesh or change the geometry locally whatever the
computation or the mesh displacement will be (more advises are given in the FAQ of the
FINE™/Marine documentation package).
A complete summary of the mesh quality is printed in the shell as long as HEX-
PRESS™ or FINE™/Marine has been started with the ’-print’ argument (always done by
default on Windows platforms).

2-68 HEXPRESS™
Toolbar User Interface

d) Set type II on mirror faces


There is no dialog box for this script. It actually applies a type II for the buffer insertion on the
edges from the mirror faces. This script should be launched after the domain creation and before the
mesh generation.
Based on the angle between the faces of the solid and the mirror plane, HEXPRESS™ will assign
different buffer insertion types to all the edges of the domains. But we have observed that type II is
sometimes the most adequate buffer type for edges on mirror plane. Hence the user might want to
modify the buffer insertion by himself. This script does it automatically.

It should be noted that if the angle is too important, type I is the only possible choice
and HEXPRESS™ will force type I anyway.

e) Z constant internal surface


The plugin allows to create an internal surface at Z-constant coordinate. The internal surface covers
the whole domain in the two other directions whatever the domain can be. In case of 2D project,
constant internal surface along Y direction is considered.

FIGURE 2.3.7-7 Z-constant internal surface creation window

Pressing the Apply button launches the internal surface creation and pressing Close closes the win-
dow. In case the coordinate is outside of the domain, an error will be raised.

2-4 Toolbar
The toolbar contains three icons providing direct access input/output functions. These actions are
also accessible through the menu bar.

TABLE 4. Direct input/output functions access

Icon Description
Close the current project and opens the welcome dialog box which proposes a list of
options. See the Project/New menu item description (section 2-3.1.1 on page 2-4).

Save the current project. See the Project/Save menu item description (section 2-3.1.3
on page 2-5).

Open an existing project created by HEXPRESS, HEXPRESS/Hybrid, IGG™


or AutoGrid5™. See the Project/Open... menu item description (section 2-3.1.2 on
page 2-4).

HEXPRESS™ 2-69
User Interface Quick Access Pad

In addition, it contains four other icons to directly access specific tools:

TABLE 5. Direct specific tools access

Icon Description
Starts the distance tool which computes the distance between two points selected
on the screen. See the Internal Surface/Distance menu item description (section
2-3.6.3 on page 2-55)
Starts the mesh quality analysis tool.
See the Grid/Mesh Quality... menu item description (section 2-3.3.4 on page 2-
42)
Opens the Grid/Boundary Conditions menu (30)

Active block Selects a block (for a multi-block project only)


Sets the grid generation mode (section 6-3 on page 6-4)

Displays the reporting.

2-5 Quick Access Pad


The Quick Access Pad is located in the left part of the GUI. It contains icons providing a direct
access to commonly used functions of HEXPRESS. Some of them are also accessible through the
menu bar (see section 2-3 on page 2-3 for a complete description of these functionalities).
The panel is divided into five subpanels, each of them can be toggled by left-clicking on the appro-
priate heading:
- CAD Manipulation subpanel
- Internal Surface subpanel
- Domain Manipulation subpanel
- Mesh Wizard subpanel
- View subpanel

2-5.1 CAD Manipulation


The CAD Manipulation subpanel (Figure 2.5.1-1) commands allow the creation, modification and
visualization of CAD Parasolid™ format entities (bodies). It consists of two pages (Create/Edit
and Visualization/Selection) containing CAD operations, visualization and selection. The icons
perform specific operations related to the subpanel and page.
Please refer to section 4-2.2 on page 4-5 for more details.

2-70 HEXPRESS™
Quick Access Pad User Interface

FIGURE 2.5.1-1 CAD Manipulation subpanel

2-5.2 Internal Surface


The Internal Surface subpanel (Figure 2.5.2-1) commands allow the creation of points, curves and
surfaces. These are basic but very useful geometries functions allowing to include additional geo-
metrical entities within the initial geometry to mesh.
Please refer to section 2-3.2 on page 2-19 for the modifications of those entities.

FIGURE 2.5.2-1 Internal Surface subpanel

2-5.2.1 Point page

a) Cartesian Point
This command is used to create Cartesian points, that is a point defined by its three Cartesian coor-
dinates x, y and z. The following prompt appears:
Enter Point Coordinates (x y z) ? (q)
>> 0 1 0
Enter the desired coordinates and press <Enter>. The corresponding Cartesian point will be dis-
played in a filled-in circle in the graphics area.
To quit this command, enter <q> and press <Enter>.

HEXPRESS™ 2-71
User Interface Quick Access Pad

b) Curve-Plane Inters
This command is used to create Cartesian points at the intersection between a plane and curves that
must be selected before using this command. The Cartesian points will be displayed in filled-in cir-
cles. The following prompts allowing the selection of the plane will appear:
Enter plane origin
>> 0 0 0
Enter plane normal
>> 0 0 1
To quit this command before the end, enter <q> in the keyboard input area and press <Enter>.

2-5.2.2 Curve page

a) Polyline
This command is used to create a polyline by entering a set of control points. Between two points,
the curve is represented as a line segment.
• Using the mouse, the user must simply move the cursor to the desired position and press the left
mouse button to add a control point to the curve.
• Using the keyboard, the user must enter the 3 coordinates separated by a blank, while the cursor
is in the graphics area. The keyboard inputs are automatically echoed to the string input area.
Pressing <Enter> adds a control point to the curve.
• The creation of the curve is terminated by pressing the right mouse button. Notice that the last
curve segment, attached to the mouse movement is not part of the curve.
• When entering the points with the mouse, the depth of the point is automatically fixed by HEX-
PRESS. The current depth can be seen by reading the mouse coordinates in the corresponding
area.
• During the specification of the points with the mouse, it is possible to attract the cursor to exist-
ing points, curves or surfaces. This feature is very interesting since it allows to connect curves
together and to create T junctions. By default this attraction is enabled. To toggle the attraction
to points, press <a> in the graphics area. Similarly, to toggle the attraction to curves or surfaces,
press <c> or <s> respectively. When the cursor is attracted to an entity, a filled-in circle is dis-
played. The attraction works on:
— point attraction: Cartesian points and curves end points if they are visible,
— curve attraction: visible curves,
— surface attraction: visible surfaces,
— vertices and fixed points. This attraction always work and cannot be deactivated.
The point, curve or surface attraction feature is activated or deactivated by pressing respectively
<a>, <c> or <s> repeatedly, while the cursor is in the graphics area.

b) CSpline
This command is used to draw a parametric cubic spline through a set of control points entered with
the mouse and/or with the keyboard.
• Using the mouse, the user must simply move the cursor to the desired position and press the left
mouse button to add a control point to the curve.
• Using the keyboard, the user must enter the 3 coordinates separated by a blank, while the cursor
is in the graphics area. The keyboard inputs are automatically echoed in the string input area.
Pressing <Enter> adds a control point to the curve.

2-72 HEXPRESS™
Quick Access Pad User Interface

• The creation of the curve is terminated by pressing the right mouse button. Notice that the last
curve segment, attached to the mouse movement is not part of the curve and is removed from
the screen.
• When entering the points with the mouse, the depth of the point is automatically fixed by HEX-
PRESS. The current depth can be seen by reading the mouse coordinates in the corresponding
area.
• During the specification of the points with the mouse, it is possible to attract the cursor to exist-
ing points, curves or surfaces. This feature is very interesting since it allows to connect curves
together and to create T junctions. By default this attraction is enabled. To toggle the attraction
to points, press <a> in the graphics area. Similarly, to toggle the attraction to curves or surfaces,
press <c> or <s> respectively. When the cursor is attracted to an entity, a filled-in circle is dis-
played. The attraction works on:
— point attraction: Cartesian points and curves end points if they are visible.
— curve attraction: visible curves.
— surface attraction: visible surfaces.
— vertices and fixed points. This attraction always work and cannot be deactivated.

The point, curve or surface attraction feature is activated or deactivated by pressing


respectively <a>, <c> or <s> repeatedly, while the cursor is in the graphics area.

c) Arc
It opens the following submenu for the selection of various circular arc creation modes:

Arc->Normal-Center-Point-Point. This menu option is used to create circles or circular arcs


through two points and perpendicular to an anchored vector. It allows also the creation of an arc
perpendicular to an anchored vector, running through one point and of a given angle. The following
inputs are requested:
• an anchored vector, defined by a direction and an anchor point,
• the start and end points (or an angle in place of the end point).
All these data (except for the angle) can be entered either through the keyboard input area or with
the mouse.
The centre of the circle is calculated so that the circular arc runs exactly through the two points. The
anchor of the vector can be used to define it. However, in case it is not on the perpendicular to the
chord bound by the two points, the centre is set on this perpendicular, the nearest to the vector. See
the figure below.

HEXPRESS™ 2-73
User Interface Quick Access Pad

first point anchored


vector

Centre closest distance


second point

anchor point

Plane defined by the two points


and perpendicular to the vector

FIGURE 2.5.2-2 : Circular arc

To draw a complete circle, the start point must be equal to the end point. The following prompts are
given for the anchor vector and the two points (data entered with the keyboard):
Enter normal to the arc
>> 0 1 0
Enter normal anchor point (q)
>> 0 0 0
Enter start point
>> 0 1 1
Enter end point
>> 1 1 0

The normal to the arc can be chosen as the screen normal by simply left-clicking in the
graphics area.
For the specification of the normal anchor point, start and end points, it is possible to attract the cur-
sor to existing points, curves or surfaces. This feature is very interesting since it allows to connect
curves together and to create T junctions. By default this attraction is enabled. To toggle the attrac-
tion to points, press <a> in the graphics area. Similarly, to toggle the attraction to curves or sur-
faces, press <c> or <s> respectively. When the cursor is attracted to an entity, a filled-in circle is
displayed. The attraction works on:
— point attraction: Cartesian points and curves end points if they are visible,
— curve attraction: visible curves,
— surface attraction: visible surfaces,
— vertices and fixed points. This attraction always work and cannot be deactivated.

The point, curve or surface attraction feature is activated or deactivated by pressing

2-74 HEXPRESS™
Quick Access Pad User Interface

respectively <a>, <c> or <s> repeatedly, while the cursor is in the graphics area.

An angle can be specified in place of the end point by pressing <p> when the start point is entered.
The following prompt will appear:
Enter angle
>> 45
Enter the desired angle and press <Enter>.
To quit this tool without creating an arc, press <q> or the right mouse button.
Example:
To draw a circular arc from (1,1,0) to (0,1,1) with centre (0,1,0), enter the following:
plane normal (0,1,0)
anchor point (0,1,0)
start point (0,1,1)
end point (1,1,0)

Notice that entering (0,0,0) for the anchor point would give the same result. Indeed, (0,0,0) is
located on the same arc normal than (0,1,0).

Arc->Normal-Point-Point-Radius. This menu option is used to create circles or circular arcs


through two points, with a given radius and perpendicular to a normal. The following inputs are
requested from the user:
• Circle/arc normal,
• Start and end point,
• Circle/arc radius,
• Arc position.
All these data (except the arc position) can be entered either through the keyboard input area or with
the mouse. The normal to the arc can be chosen as the screen normal by simply left-clicking in the
graphics area.
For the specification of the arc start and end points, it is possible to attract the cursor to existing
points, curves or surfaces. This feature is very interesting since it allows to connect curves together
and to create T junctions. By default this attraction is enabled. To toggle the attraction to points,
press <a> in the graphics area. Similarly, to toggle the attraction to curves or surfaces, press <c> or
<s> respectively. When the cursor is attracted to an entity, a filled-in circle is displayed. The attrac-
tion works on:
— point attraction: Cartesian points and curves end points if they are visible,
— curve attraction: visible curves,
— surface attraction: visible surfaces,
— vertices and fixed points. This attraction always work and cannot be deactivated.

The point, curve or surface attraction feature is activated or deactivated by pressing


respectively <a>, <c> or <s> repeatedly, while the cursor is in the graphics area.
Once the start point is entered, it is displayed in a filled-in circle and a semicircle is drawn through
this start point and the cursor (Figure 2.5.2-3). Moreover, a line representing the radius and a cross

HEXPRESS™ 2-75
User Interface Quick Access Pad

representing the center are displayed; the corresponding values of the radius and center are shown
in the information area. When the end point is entered, it is also displayed in a filled-in circle.

FIGURE 2.5.2-3 Arc representation before its creation

FIGURE 2.5.2-4 Six arcs drawn through two points with a given radius

If the radius is entered through the keyboard input area, it is possible that the value entered is too
small (if value is lower than half distance between start and end point), in which case a warning
message appears. When the radius is entered, the sense of the circular arc can be chosen by pressing
<o> repeatedly. In fact, there are six possibilities to draw an arc between two points and with a
given radius, which includes two possibilities of complete circle, as shown in Figure 2.5.2-4.
Once the correct sense is chosen, simply click on the left mouse button to complete the arc creation.
To quit this tool without creating an arc, press <q> or the right mouse button.

Arc->Point-Point-Point. This menu option is used to create circular arcs through three points. The
following inputs are requested from the user:
• Start point,
• End point,
• Middle point.
All these data can be entered either through the keyboard input area or with the mouse.
During the specification of the points with the mouse, it is possible to attract the cursor to existing
points, curves or surfaces. By default this attraction is enabled. To toggle the attraction to points,
press <a> in the graphics area. Similarly, to toggle the attraction to curves or surfaces, press <c> or
<s> respectively. When the cursor is attracted to an entity, a filled-in circle is displayed. The attrac-
tion works on:
• visible points and curves end points,
• visible curves,
• visible surfaces,
• vertices and fixed points. This attraction always work and cannot be deactivated.

2-76 HEXPRESS™
Quick Access Pad User Interface

The point, curve or surface attraction feature is activated or deactivated by pressing


respectively <a>, <c> or <s> repeatedly, while the cursor is in the graphics area.
The start and end points must be specified first and are displayed in a filled-in circle. When both
points are specified, a circular arc is drawn between the start point, end point and the current cursor
position, representing the mid point (Figure 2.5.2-5). Moreover, a line representing the radius and a
cross representing the center are displayed; the corresponding values of the radius and center are
shown in the information area.
It is possible to get a complete circle by pressing the <o> key. Pressing <o> a second time comes
back to the circular arc mode.

FIGURE 2.5.2-5 Circular arc representation before its creation

Entering the mid point will complete the circular arc (or circle) creation.
To exit the tool without creating an arc, press <q> or the right mouse button.

2-5.2.3 Surface page

a) Lofted
This command is used to create a NURBS surface interpolating a set of selected curves. The orien-
tation and the order of the selected curves are taken into account to define the surface.

FIGURE 2.5.2-6 Curves order and orientation when creating a Lofted surface

An automatic creation of internal surface at Z-constant has been implemented and
available thanks to the Marine module in the Plugins menu. See 57 for more details.

b) Coons
This command allows to create a NURBS surface from four selected curves, using a bilinear inter-
polation. The four curves should define a closed region and should have the following orientation:

HEXPRESS™ 2-77
User Interface Quick Access Pad

4 2

FIGURE 2.5.2-7 Curves order and orientation when creating a Coons surface

The four curves must also be selected as indicated in the figure (curve 1 first,...).

c) Import
This button offers the possibility to import an STL surface as an internal surface into HEX-
PRESS™.
This command also allows to import ".dat" geometry files already exported within HEXPRESS™
with the following command.

For multidomain case, the internal surface will be part of the active domain when
importing the file.

d) Export
This command allows to export ".dat" geometry files that can be imported within HEXPRESS™
with the previous command.

2-5.3 Domain Manipulation

Manual Edge Split/Merge Auto Edge Merge

Manual Face Split/Merge


Auto Face Merge
Move Part Replace Domain

Undo Settings

Delete Block
Domain validity check

FIGURE 2.5.3-1 Domain manipulation subpanel

The Domain Manipulation subpanel (Figure 2.5.3-1) allows to transform edges, faces, parts or an
entire domain composing the current domains of the mesh.

2-78 HEXPRESS™
Quick Access Pad User Interface

• Both edges and faces composing the domain can be manually and/or automatically split and
merged.
• A settings icon allows to define the shortest edge length after split and the feature angle. The
feature angle is the minimum angle between two edges or between the two normals of faces to
merge.
• A "domain validity check" icon allows to control the domain before meshing.
• An "undo" icon allows to undo the last performed operation.
Please refer to Chapter 5 for more illustrated details.

2-5.4 Mesh Wizard


The Mesh Wizard subpanel (Figure 2.5.4-1) commands allow the step by step creation of an
unstructured hexahedral mesh starting from a domain. Please refer to Chapter 6 for a complete
description.

FIGURE 2.5.4-1 Mesh Wizard subpanel

HEXPRESS™ 2-79
User Interface Quick Access Pad

2-5.5 View
The View subpanel (Figure 2.5.5-1) controls viewing and rendering operations on the geometry and
the grid.This subpanel is divided into three frames.

FIGURE 2.5.5-1 View subpanel

2-5.5.1 Domains
This frame gives the possibility to select in one click the domains to show in the graphics area.

2-5.5.2 Display Options


The first row allows to set the selection mode (called "Scope").

• The button ( ) refers to the face mode viewing. All the viewing modification are applied on
the currently selected face. The face may be selected interactively by left-clicking on the face
into the graphics area or by right-clicking on the face icon ( ). This last operation opens a
dialog box listing all the faces available, called the Face Viewer. The Face Viewer can also be
opened by pressing the dedicated icon .

2-80 HEXPRESS™
Quick Access Pad User Interface

FIGURE 2.5.5-2 Face Viewer

This menu gives an overview of all the visualization options patch by patch or by groups of patches.
A face can be selected by left-clicking in the face browser or interactively in the graphics area. This
face is then automatically visualized in the graphics area. It is possible to select several faces at
once in the following ways:
1. While holding the <Ctrl> key down, select the desired faces in the browser.
2. While holding the <Shift> key down, select two faces defining a range of faces.
3. While pressing the left mouse button, drag the mouse and release the left button to select a range
of faces.
4. Pressing <Ctrl>+ <a> keys down will select all patches.
5. Interactively in the graphics area depending of the selection options (shortcut <o>):
• <Ctrl> + left-click or left-click on successive faces,
• Draw a rectangle in the graphics area to select all surfaces which are completely or partly
inside the rectangle. For this purpose, hold <Ctrl> key and drag the mouse with the left-
click.

HEXPRESS™ 2-81
User Interface Quick Access Pad

6. Clicking on Select button and move mouse and left-click in the popup menu to select the type of
face selection.

• Select All Blanked allows to select all blanked faces in the graphics area.
• Select Face By Area allows to select all the faces with an area in the range specified by the
user.

• Select Face By Name allows to select all the faces whose name match the input name. A
dialog box is provided to input the name. The name can be a regular expression (i.e. if the
input is "channel*" all the faces whose name begins with channel will be selected)
• Select Geometrically Similar Faces allows to select all the faces with an area and a perim-
eter (under a tolerance of 0.03) identical to the selected face in the list.
• Select Tangent Faces allows to select all the faces tangent to each other (neighbouring
faces presenting an angle above the specified angle), starting from the list of selected faces.

The shortcut <t> can be used to select the option directly.


The different filters allow the display of specific faces in the browser while hiding the other faces:
— The Name filter displays faces by name. Enter or choose an expression and all faces whose
name contains this expression will be listed.
— The Type filter lists all faces of a given type (e.g. SOL, INL, OUT, MIR, EXT, etc).
— The Block filter lists all faces of a given block (interesting for multi-domain project).
ID and Color are indications about the ID of the patch and the current color assigned to the group or
the patches. Pressing the color area facing a group or a patch will open the Rendering editor (see
87).

Groups, type and names are defined in the Boundary Conditions menu (see 30).
By right-clicking on a face or a group of faces in the menu or in the graphics area, a popup menu
allows to:
— completely hide faces and make them unselectable, by using the Blank/Unblank functional-
ity (right-click in the menu or in the graphics area) or by double clicking on the check box
on the left of the surface name. The check box actually shows the state of the surface:
unblank (ticked) or blank (unticked) (Blank/Unblank),

2-82 HEXPRESS™
Quick Access Pad User Interface

— zoom to all selected faces (Zoom in),


— invert selection (Invert Selection),
— undo successive selections of faces (Undo Selection).

The shortcut <h> in the graphics area will display hints. There are information about mouse button
bindings and shortcuts.

• The button ( ) refers to the block mode viewing. All the viewing modification are applied on
the currently selected block (domain). The block may be selected interactively by left-clicking
on the block into the graphics area.
• The button ( ) applies viewing modifications on all the blocks.

The second buttons row allows to modify the way of displaying surfaces in the graphics area:
displays the topological vertices and edges numbers as text in the graphical area

displays the topological vertices as markers

displays the topological edges of the geometry.

displays the triangulation from the geometry surfaces or the mesh faces.

displays the faces as opaque surfaces (shaded).

• The button ( ) refers to face rendering. This menu is divided in three tabs : one for control-
ling the face rendering (Material), one for controlling the mesh appearance (Mesh) and one for
the Background colors. The settings in first two tabs work according to the active scope: Face,
Block or Grid. When the Face mode is active the settings are applied on the selected faces in the
Face Viewer dialog box.

HEXPRESS™ 2-83
User Interface Quick Access Pad

FIGURE 2.5.5-3 Rendering Editor

A Save as Default button is dedicated to save the current settings as preferences. This includes the
material and mesh properties as well as the background colors.

The preferences are saved in the "~/.numeca/hexpress.preferences" file.


The Reset button cancels all performed rendering operations since the Rendering editor dialog box
is open.

a) Material
The surface material properties are defined by four parameters:
• Diffuse: refers to the fundamental color of the surface.

• Specular: affects the light reflections on the surface. The shape, the strength and the color of
the highlight depends of the material. For instance, a material like cotton tissue will not
have any specular highlight, in comparison to a reflective surface like a mirror that will
have a very bright specular highlight.
—Color: is the color of the specular highlight.

2-84 HEXPRESS™
Quick Access Pad User Interface

—Amount: is the strength of the highlight. It is a value ranging from 0 to 1. A value of 0


means that the surface has no specular highlight; a value of 1 means that the surface
presents a strong specular highlight.

—Gloss: defines the extent of the highlight. It is a value ranging from 1 to 4. A value of 1
means that the specular highlight is widespread. It will be the case for rough material. A
value of 4 means that the highlight is very narrow. It will be the case for very smooth
surfaces, like glass.

• Opacity: controls the transmission of light through the surface. An opacity of 1.0 means a
completely opaque surface. An opacity of 0 means a completely transparent surface.

HEXPRESS™ 2-85
User Interface Quick Access Pad

Transparency availability depends only on the driver/machine/graphic card combina-


tion. If not available the value is discarded. Regarding transparency and diffuse color,
some graphics hardware only take the intensity of the color into account.
• Reflection: is the property of a surface to reflect the surrounding environment. Reflection is
the property of a surface to reflect the surrounding environment. A “spherical environment
mapping” technique is applied on the selected surface(s) when the option use reflection
mapping is set active:
—An image, also called “map”, is provided for each surface. This map represents a given
material.
—The color of each surface point is found by using the local normal at the surface point to
address the map.
—Amount: changes the reflectivity property of the surface.
A reflectivity amount of 0 means that the surface has no reflectivity: the final color is
the diffuse color of the surface. A reflectivity amount of 1 means that the surface is
purely reflective: the final color is equal to the reflection color. All value in-between
result in a mix of reflectivity and surface color.

b) Mesh
This tab, used for controlling the mesh lines appearance, allows to control:
• the color of the mesh
• the line pattern
• the thickness of the mesh lines

2-86 HEXPRESS™
Quick Access Pad User Interface

• whether lighting should be applied on the mesh lines or not


Each operation in this tab takes immediately effect, as for the Material tab, according to the active
Scope (Face, Block or Grid).

c) Background
The third tab allows to define the background color. of the graphics area.
The edition button Ed. allows the user to specify his own background color independently of the
proposed colors. The look of the menu varies according the operating system.

FIGURE 2.5.5-4 Color selection

During the initial and adaptation steps, the user can only control the color and mesh
attributes for the whole mesh and not face by face. This is explained by the fact that dur-
ing these steps, the cartesian mesh is not attached to any face.
No lighting is applied on the mesh solid surface representation during the initial and
adaptation steps.
Lighting of edges does not apply when the color is black.

2-5.5.3 Camera Position

Clicking on the icon ( ) opens the Camera Position dialogue box as shown in Figure 2.5.5-5

FIGURE 2.5.5-5 Camera Position

HEXPRESS™ 2-87
User Interface Quick Access Pad

• Save button: Saves the current camera position. A new entry, Camera # will be added in the list
each time the Save button is hit.
• Delete button: Deletes the selected camera position.
• Close button: Closes the dialogue box.

2-5.6 Control Area


The control area (Figure 2.1.0-2) is composed of six major regions:
• Message area
• Keyboard input area
• Mouse coordinates
• Information area
• Grid parameters area
• Viewing buttons

2-5.6.1 Message area


This area has several functions:
— Display of warning messages in red advising the user.
— Display of request messages asking the user for input from "keyboard input area" or graph-
ics area.
— Display of general information messages (current functionality options, etc).
Viewing or selection actions for the mouse are indicated with the "<>" symbol. "<1>"
corresponds to the left-click, "<2>" corresponds to the middle-click and "<3>" corre-
sponds to the right-click.

2-5.6.2 Keyboard input area


Some options in HEXPRESS require numerical input from the user.
The "keyboard input area" is provided to allow such input. When an option requires numerical
input, a message is displayed in the message area. Without leaving the graphics area, the user can
then type the required data. The keystrokes are automatically echoed in the keyboard input area and
the user can modify any input. Input is acknowledged after pressing <Enter>.
Entering scalar values: a scalar value is specified by a floating number followed by <Enter>.
Valid values are e.g. 5, 1.32323, -0.1234, 1.4E-5.
Entering vectors: a vector is specified by typing its three components separated by a blank and fol-
lowed by <Enter>. Valid values are e.g. 1.32323 -0.1234 1.4E-5.

2-5.6.3 Mouse coordinates


This area displays the mouse cursor coordinates in the graphics area. If the cursor is no longer in the
window, it indicates its last position in the window.

2-5.6.4 Information area


This area gives general information (about faces, curves, etc). For example, when selecting a curve
its name is displayed.

2-88 HEXPRESS™
Quick Access Pad User Interface

2-5.6.5 Grid parameters area


This area shows useful information about the unstructured mesh (Figure 2.5.6-1):
• Number of cells (number of parent and child cells -Figure 2.5.6-2).
• Number of leaf cells (number of cells in finest grid level -Figure 2.5.6-2).
• Number of vertices.

FIGURE 2.5.6-1 Grid parameters area

FIGURE 2.5.6-2 Number of cells - Number of leaf cells

2-5.6.6 Viewing buttons


The viewing buttons are used to perform manipulations on the active view, such as scrolling, zoom-
ing and rotating. Each function uses the left <1>, middle <2> and right <3> buttons of the mouse
in different ways. The sub-sections below describe the function associated with each mouse button
for each viewing option.

For systems using a mouse with only two buttons, the middle mouse button can be
emulated for viewing options by holding the <Ctrl> key while left-clicking.
During viewing operations, HEXPRESS automatically removes all ‘heavy’ graph-
ics representations from the active view, such as solid model or color shading. This is
done to maintain a reasonable speed during rotation, translation or zoom operations. The
complete picture is restored after a viewing operation is finished.

a) X, Y, and Z projection buttons


These buttons show a view of the graphics objects on an X, Y or Z projection plane.
• Left-click to project the view on an X, Y or Z constant plane. If the same button is pressed more
than once, the horizontal axis orientation changes at each press.

b) Coordinate axis
The coordinate axis button acts as a toggle to display different types of coordinate axis on the active
view, using the following mouse buttons:
• Left-click: turn on/off the display of symbolic coordinate axis at the lower right corner of the
view.

HEXPRESS™ 2-89
User Interface Quick Access Pad

• Middle-click: turn on/off the display of scaled coordinate axis for the active view. The axis
surrounds all objects in the view and may not be visible when the view is zoomed.

c) Scrolling
This button is used to translate the contents of the active view within the plane of graphics window
in the direction specified by the user. The following functions can be performed with the following
mouse buttons:
• Left-click: press and drag the left mouse button to indicate the translation direction. The transla-
tion is proportional to the mouse displacement. Release the button when finished.
The translation magnitude is automatically calculated by measuring the distance between the
initial clicked point and the current position.
• Middle-click: press and drag the middle mouse button to indicate the translation direction. The
translation is continuous in the indicated direction. Release the button when finished.
The translation speed is automatically calculated by measuring the distance between the initial
clicked point and the current cursor position.

d) 3D viewing button
This button enables viewing operations directly in the graphics area. Available operations are 3D
rotation, scrolling and zooming.
After having selected the option, move the mouse to the Graphics area then:
• Press and drag the left mouse button to perform a 3D rotation
• Press and drag the middle mouse button to perform a translation
• Press and drag the middle mouse button, while holding the <Shift> key, to perform a zoom
• Roll the middle mouse button to perform a zoom where the mouse is pointing.
• To select the centre of rotation, hold the <Shift> key and press the left mouse button only on a
vertex. The centre of rotation is always located in the centre of the screen. When changing, the
model is moved according to the new rotation center.
This 3D viewing tool is also accessible using the <F1> key.
e) Rotate about x, y or z axis
The rotation buttons are used to rotate graphical objects on the active view around the X, Y or Z
axis. Rotations are always performed around the centre of the active view and can be performed
with the following mouse buttons:
• Left-click: press and drag the left mouse button to the left or to the right. A clockwise or coun-
ter clockwise rotation will be performed, proportional to the mouse displacement. Release the
button when finished.
• Middle-click: press and drag the middle mouse button to the left or to the right. A continuous
clockwise or counter clockwise rotation will be performed. Release the button when finished.

f) Zoom in/out
This button is used for zooming operations on the active view. Zooming is always performed
around the view centre. The functions can be performed with the following mouse buttons:
• Left-click: press and drag the left mouse button to the left or to the right. A zoom in - zoom out
will be performed, proportional to the mouse displacement. Release the button when finished.

2-90 HEXPRESS™
Quick Access Pad User Interface

• Middle-click: press and drag the middle mouse button to the left or to the right. A continuous
zoom in - zoom out will be performed. Release the button when finished.

g) Region zoom
This button allows the user to specify a rectangular area in the active view that will be fitted to the
Graphics area. After having selected the button,
• Move the mouse to the active view,
• Press and drag the left mouse button to select the rectangular area in the active view,
• Release the button to perform the zoom operation.
These operations can be repeated several times to perform multiple zooms.
• Press <q> or the right mouse button to quit the option.
This tool is also accessed using the <F2> key.
h) Fit button
The fit button is used to fit the content of the active view to the Graphics area without changing the
camera orientation.

i) Original button
The original button is used to fit the content of the active view and reset the default viewpoint.

j) Cutting Plane
This option displays a movable plane that cuts the geometry and the mesh. The surface mesh is dis-
played. The plane is symbolically represented by four boundaries and its normal, and is by default
semi-transparent. Upon hitting the button, the Cutting Plane pop-up as shown in Figure 2.5.6-3
appears. The icon remains yellow as long as the tool is active.

FIGURE 2.5.6-3 Cutting plane dialogue

The Cutting Plane dialogue allows the users to specify the origin and direction of the plane. The
Recenter button recomputes the origin of the cutting tool to be at the centre of the screen. At the
same time, the size of the cutting tool outline is recomputed to fit the view. This option is especially
useful after performing zoom on a specific region.

Mouse bindings:
• Left-click + drag: Rotates the plane;
• Middle-click + drag: Translates the plane.

HEXPRESS™ 2-91
User Interface Quick Access Pad

Key bindings:
• <x>, <y> or <z> : Aligns the plane normal along the X, Y or Z axis;
• <n> : Reverts the plane normal;
• <h> : Toggles the hints display;
• <o> : Opens the Cutting plane options dialogue:

FIGURE 2.5.6-4 Cutting plane options dialogue

Hide cut-away: hides the geometry on the other side of the plane.
Activate transparency: deactivates to make the cutting plane fully transparent

It is advised to deactivate plane transparency when using X11 driver to increase the
execution speed.
Show mesh: deactivates to hide the mesh and view geometry only.
Intersecting cutting plane only: activates to display only cells intersecting the cutting plane. The
cells are displayed through each side of the cutting plane.
Shading: activates to display cells in solid mode. Deactivate for wireframe mode.
Shrink factor: from 0 to 1, the shrink factor reduces the cell size in the X, Y and Z direction.

Shrink factor = 0.2 Shrink factor = 0.7

FIGURE 2.5.6-5 Shrink factor from 0.2 to 0.7

2-92 HEXPRESS™
Quick Access Pad User Interface

k) Cylindrical cutting tool


This option allows the users to position a cylinder and perform a cut through the mesh. The cells cut
by the cylinder are displayed in the graphics area. Upon hitting the button, the Cutting Cylinder dia-
logue shown in Figure 2.5.6-6 appears and allows the users to specify the origin, normal and radius
of the cylinder. The cut applies on all blocks. By default, the cylinder appears semi-transparent.

This cutting tool performs cut on the mesh only.

FIGURE 2.5.6-6 Cutting cylinder dialogue

Mouse bindings:
• Left-click + drag : Changes the radius of the cylinder;
• Middle-click + drag : Changes the origin of the cylinder;
• Middle-click + <Ctrl> + drag : Contraints the movement of cylinder’s origin along X, Y or Z
axis. This direction is determined by the initial direction of the mouse after clicking. The closest
direction to the X, Y or Z axis will be retained and it remains until the end of the drag operation.

Key bindings:
• <h> : Toggles the hints display;
• <x>, <y> and <z> : Aligns the cylinder axis along X, Y or Z;
• <o> : Opens the Cutting options dialog box as shown in Figure 2.5.6-7;

FIGURE 2.5.6-7 Cutting cylinder options

Opaque cylinder during changes: Shows opaque cylinder during movement.


Show inside cells: activates to display the boundary cells that are inside the cylinder on top of the
cells intersecting the cylinder.
Shrink factor: specifies a shrink factor for cells display. More details in Figure 2.5.6-5.

HEXPRESS™ 2-93
User Interface Quick Access Pad

l) Box cutting tool


This option allows the users to position a box and perform a cut through the mesh. The cells cut by
the box are displayed in the graphics area. Upon hitting the button, the Cutting box dialogue shown
in Figure 2.5.6-8 appears and allows the users to specify the origin and size of the box. The cut
applies on all blocks. By default, the box appears semi-transparent.

This option performs cut on the mesh only.

FIGURE 2.5.6-8 Cutting box dialogue

Mouse bindings:
• Left-click + drag : Changes the size of the box;
• Middle-click + drag : Changes the origin of the box;
• Middle-click + <Ctrl> + drag : Contraints the movement of box’s origin along X, Y or Z axis.
This direction is determined by the initial direction of the mouse after clicking. The closest
direction to the X, Y or Z axis will be retained and it remains until the end of the drag operation.

Key bindings:
• <h> : Toggles the hint display;
• <o> : Opens the Cutting options dialog box as shown in Figure 2.5.6-7.

m) Spherical cutting tool


This option works the same way as the box cutting tool. It has the same mouse and key bindings as
box cutting tool as well. Upon hitting the button, the Cutting sphere dialogue shown in
Figure 2.5.6-9 appears and allows the users to specify the origin and radius of the sphere. The cut
applies on all blocks.

FIGURE 2.5.6-9 Cutting sphere dialogue

This option performs cut on the mesh only.

2-94 HEXPRESS™
GUI interaction User Interface

2-5.7 Graphics Area & Views


The graphics area (Figure 2.1.0-2) is the region of the screen dedicated to the display of all graphi-
cal objects created by the system. These graphical objects are displayed in a window called "view"
in the HEXPRESS terminology.

2-6 GUI interaction


2-6.1 Keyboard shortcuts
HEXPRESS provides shortcuts for the most commonly used options, which allow the user to
activate options without accessing the menus. A shortcut consists of a single key press and is indi-
cated at the right of each menu item when available. To use a shortcut:
• Move the mouse to the graphics area
• Press the key corresponding to the shortcut. The menu option is activated automatically.
A list of the available shortcuts is given in the following table.

TABLE 6. Keyboard short-cuts


Short cuts
Function
Alt-p Toggles the display of the Quick Access Pad.
Escape Stops the current tool.
Used to translate to the right the active view.
Used to translate to the left the active view.
Used to translate to the top the active view.

Used to translate to the bottom the active view.

F1 Used to perform a 3D viewing. See section d) "3D viewing button" on page


2-90.
F2 Used to perform a zoom in/out. See section f) "Zoom in/out" on page 2-90.
F3 Used to fit the content of the view. See section h) "Fit button" on page 2-91.
F4 Used to fit the content of the view and reset the camera orientation.
See section i) "Original button" on page 2-91.
F5 Used to activate the cutting plane. See section j) "Cutting Plane" on page 2-
85

HEXPRESS™ 2-95
User Interface GUI interaction

2-96 HEXPRESS™
CHAPTER 3: Meshing
Fundamentals

3-1 Overview
HEXPRESS™ has been developed to ensure a quick management of the grid generation process for
external and internal configurations. The software is able to generate an unstructured hexahedra
mesh in any "water-tight" computational domain (".dom").
The software provides a highly interactive user interface allowing a easy setup of the mesh genera-
tion for complex geometries. Based on a wizard approach, the mesh is generated step by step
through a minimum user inputs. The mesh wizard involves five different steps. Each step must be
successfully accomplished before proceeding to the next:
• Initial mesh
HEXPRESS creates an initial mesh surrounding the computational domain.
• Adapt to geometry
HEXPRESS adapts the initial mesh such that the cell sizes satisfy geometry dependent
criteria and removes afterwards cells intersecting the geometry or located outside the com-
putational domain.
• Snap to geometry
HEXPRESS projects the adapted mesh onto the geometry and recovers lower dimen-
sional features such as topological edges (curves) and topological vertices (corners). Since
the technology in HEXPRESS is based on a top-down approach, the adapted mesh does
not conform to the geometry. A simple projection on the surface would not preserve ridges
or sharp corners, that is why a unique technology has been developed inside of HEX-
PRESS to perform this capturing while ensuring the highest quality mesh. Additional
cells are also introduced during this stage to obtain a smoothly hexahedra mesh.
• Optimize
Though the snapping step already ensures a high quality mesh, some distorted cells may
exist. A powerful mesh optimization tool is implemented in HEXPRESS that allows the
conversion of concave cells in convex ones.
• Viscous layers
Finally, HEXPRESS can insert layers of high aspect ratio cells tangentially to the wall in
order to correctly resolve boundary layers.

HEXPRESS ™ 3-1
Meshing Fundamentals Mesh Domain Definition

3-2 Mesh Domain Definition


The starting point of any simulation is the definition of an appropriate computational domain (more
details in Chapter 4), which, in most cases, can be interpreted as the complement of the solid parts
present in the model. HEXPRESS expects a "water-tight" computational domain. The computa-
tional domain consists of a topology and a geometry part:
• The topology describes the skeleton of the model. Basically, it allows the definition of a
closed volume and provides information on the connection of the model surfaces (topologi-
cal faces) with common curves (topological edges). Similarly, it connects curves together
by common corners (topological vertices).
• The geometry part defines the actual geometry of the model. Each model surface is
described by a triangulation, each curve by a list of points connected by segments and the
corners are defined by a single point.

FIGURE 3.2.0-1 Internal application (left) and external application (right) domain

HEXPRESS accepts three different CAD formats as input for the topology and geometry descrip-
tion of the computational domain:
• Parasolid & CATIA models. can be imported and its different bodies can be accessed.
Recall here that the computational domain must be described as a single closed volume.
• STL (Stereo Lithography Triangulation) model representation can be imported together
with additional information about the geometry attributes of the triangles, required to cor-
rectly reconstruct the topology of the model.
• Computational domain file ".dom" is the HEXPRESS native model format. It is a dis-
cretized representation of the computational domain containing all topology information.
The computational domain is of course ready for HEXPRESS grid generation.

3-2 HEXPRESS™
Mesh Domain Definition Meshing Fundamentals

Parasolid™ STL STARCD


CATIA

Import Parasolid™ Convert


Import STL
or CATIA V5 Re-orient

Create bounding box

Unify, delete
subtract, intersect

Export Faceting Export STL +PROP


STL

Spec. length.
tolerances, ...
Import STL

Create Group
Merge
Reverse

Reverse
tolerance
Create Domain

DOM

FIGURE 3.2.0-2 HEXPRESS CAD handling

HEXPRESS™ 3-3
Meshing Fundamentals Mesh Generation Steps

3-3 Mesh Generation Steps


The mesh generation within HEXPRESS™ is divided in five main steps:

FIGURE 3.3.0-1 Mesh generation steps

3-3.1 Initial Mesh


HEXPRESS starts its mesh generation process from an initial mesh which encompasses the
whole computational domain. An initial mesh is automatically proposed which corresponds to an
isotropic subdivision of the computational domain bounding box. Furthermore, an existing unstruc-
tured mesh can be loaded as initial mesh.

3-3.2 Adapt to geometry


This mesh generation step is probably the most important in terms of user interaction in HEX-
PRESS. Indeed, the parameters selection in this action directly dictates the computed mesh
obtained with HEXPRESS.
This adaptation step consists of two major actions: the refinement and the trimming.

3-3.2.1 Refinement
In this action, cells are successively subdivided such that specific geometrical criteria are satisfied.

3-4 HEXPRESS™
Mesh Generation Steps Meshing Fundamentals

FIGURE 3.3.2-1 Refinement of surface intersecting cells

Three classes of criteria are available:


• Curve criteria
Cells which intersect curves are considered as candidates for refinement. Three criteria are
implemented and are respectively based on:
— a proximity testing between curves
— a curve curvature measurement
— a specification of cell target sizes on the curves
• Surface criteria
Cells which intersect surfaces are considered as candidates for refinement. Three criteria
are implemented and are respectively based on:
— a proximity testing between surfaces
— a surface curvature measurement
— a specification of cell target sizes on the surfaces
• Volume criterion (Box)
For this criterion, cells which are intersecting or located inside a three-dimensional volume
are flagged for refinement if their cell size is larger than some user prescribed target size.
In order to limit the number of cells created during refinement, HEXPRESS subdivides cells ani-
sotropically as often as possible. A cell can thus be subdivided in 2, 4 or 8 cells (Figure 3.3.2-2)

Subdivisions in 2 Subdivisions in 4 Isotropic subdivision

FIGURE 3.3.2-2 Refinement modes of a hexahedron

3-3.2.2 Trimming
The trimming step removes all the cells intersecting or located outside of the geometry. HEX-
PRESS automatically finds the cells located inside the computational domain. At the end of the
process, a staircase mesh is obtained including all the interior cells (see Figure 3.3.2-3).

HEXPRESS™ 3-5
Meshing Fundamentals Mesh Generation Steps

FIGURE 3.3.2-3 Trimming of surface intersecting cells

HEXPRESS can avoid trimming on planar surfaces: Cartesian mesh is preserved in


planar surfaces after execution of snapping and optimization steps, thus leading to
improve mesh quality (see section 6-6.6 for more details).

3-3.3 Snap to geometry


The aim of this fully automated mesh step is to project the staircase mesh obtained after the mesh
adaptation action on the surface to obtain a good quality body conforming mesh. In addition to a
simple projection on the geometry, this action involves sophisticated algorithms to recover lower
dimensional geometric features such as corners and curves in the mesh. These algorithms guarantee
that, when the mesh is projected onto the surface geometry, a mesh vertex is attached to each corner
of the geometry and that a path of mesh edges is attached to the curve.
In addition, the snapping of the mesh onto the geometry may create highly distorted elements. Lay-
ers of additional cells (buffer insertion) are introduced into the mesh to create a body conforming
mesh.
Finally, the mesh is smoothed by moving points on the surface and in the volume in order to obtain
a mesh with a good but not guaranteed quality.

3-3.4 Optimization
The mesh obtained after the snapping action may involve poor quality cells usually located close to
corners and curves. Some of these cells are concave or may even present a negative volume. A cell
is defined as concave (the cell looks like a "boomerang") if the Jacobian of the transformation to a
unit cube has at least one zero value for a point located inside of the cell.
HEXPRESS provides specific algorithms to convert concave cells to convex ones by slightly dis-
placing their vertices. A novel approach is also implemented to improve the orthogonality of con-
vex cells. In most instances, convex cells are important to ensure the stability and the robustness of
a flow solver. Furthermore mesh adaptation applied to concave cells may also create negative chil-
dren cells.
Negative cells should be prohibited. Usually, HEXPRESS is able to deliver a mesh without any
negative cell. However, the presence of negative cells is usually a sign of an inadequate choice of
cell sizes in a geometrical complex region. Further mesh refinements will usually solve the prob-
lem.

3-6 HEXPRESS™
Mesh Quality Meshing Fundamentals

3-3.5 Viscous layers


HEXPRESS proposes a very specific approach for the insertion of layers of large aspect ratio
cells to accurately resolve boundary layers. The technique is based on successive subdivisions of
the cells connected to the walls, this contrasts with other techniques which insert layers by extru-
sion. This refinement technique has the advantage of robustness and speed. Besides, the inflation
algorithm improves the mesh quality in viscous layers.

3-4 Mesh Quality


After the grid generation, the menu Grid/Mesh Quality... computes and displays per block the
characteristics of the mesh in terms of negative or concave cells and of minimum-maximum of the
cells volume, the aspect ratio and the cells skewness. More details in section 2-3.3.4 on page 2-42.

3-5 Multi-Domain
The introduction of multi-domain option largely enhance HEXPRESS™ capabilities, with the pos-
sibility to import and manage several domains and meshes in the same project. Furthermore it
allows to merge meshes exported from HEXPRESS™/Hybrid, IGG™ and AutoGrid5™ (structured
NUMECA mesh generators) with HEXPRESS™ domains as illustrated in Figure 3.5.0-1.

5TM

FIGURE 3.5.0-1 Multi-domain

When dealing with a multi-domain project, several "water-tight" computational domains (".dom")
have to be loaded within HEXPRESS™ through the menu /Project/Import.../Domain. When the
domains are imported, their selection is performed by left-clicking on it in the graphic area or by the
Active block entry in the tool bar.

HEXPRESS™ 3-7
Meshing Fundamentals Batch Mode

Domain manipulations (section 2-5.3 on page 2-78) if necessary have to be performed


before mesh generation.
When generating the mesh following the wizard (section 3-3 on page 3-4), all settings and viewing
operations are applied separately to each domain after selecting it in Active block in the Toolbar or
by left-clicking on it.

When HEXPRESS™ meshes are generated based on each imported domain, addi-
tional existing structured or unstructured meshes can be added into the project through
the menu Project/Import.../Project.
Finally before saving the whole project, connections between generated and/or imported meshes
have to be specified through the menu Grid/Non Matching Connections.... This menu allows to
specify a user-defined connection between meshes. Two types of connection can be defined: full
non matching connection and rotor/stator connection. The last type, in practice, allows to connect
two domains presenting different periodicity and/or different rotation speed, while the first type
allows to connect two domains presenting the same periodicity and rotation speed (more details in
section 2-3.3.3 on page 2-35).

3-6 Batch Mode


This section provides all available information to launch installed NUMECA software from a shell
without using HEXPRESS™ interface.

How to launch on UNIX.


1. Create a domain "user_prefix.dom" and topology "user_prefix.igg" files using HEXPRESS™
interface.
2. Start HEXPRESS™ to create a mesh from those files by typing:
hexpress -batch -project /mesh-full-path/mesh.igg -niversion 31_# -print
The command line to start the grid generator HEXPRESS™ contains its name, the full path name
of the mesh (and of the domain located in the same directory and with the same user prefix) and the
HEXPRESS™ release that will be used. The "-batch" option avoids the display of the HEX-
PRESS™ graphical user interface.

This command should be used with HEXPRESS™ standalone version only. For
FINE™/Open and FINE™/Marine packages, please change "31_#" to "open31_#" or
"marine31_#" respectively.

How to launch under Windows.


1. Create a domain "user_prefix.dom" and topology "user_prefix.igg" files using HEXPRESS™
interface.

3-8 HEXPRESS™
Batch Mode Meshing Fundamentals

2. Start HEXPRESS™ to create a mesh from those files by typing:


d:\NUMECA_SOFTWARE\Hexpress31_#\bin\hexpress.exe -batch -project /mesh-full-path/
mesh.igg -print (on Windows 32bits)
d:\NUMECA_SOFTWARE\Hexpress31_#\bin64\hexpressx86_64.exe -batch -project /mesh-full-
path/mesh.igg -print (on Windows 64bits)
The command line to start the grid generator HEXPRESS™ contains its full path name, the full
path name of the mesh (and of the domain located in the same directory and with the same user pre-
fix) and the HEXPRESS™ release that will be used. The "-batch" option avoids the display of the
HEXPRESS™ graphical user interface.

In order to use HEXPRESS™ included in FINE™/Marine or FINE™/Open package,


"Hexpress31_#" should be replaced by "FineMarine31_#" or "FineOpen31_#".

Batch mode treats also multi-domains meshes and computations of full non matching
connections.

HEXPRESS™ 3-9
Meshing Fundamentals Batch Mode

3-10 HEXPRESS™
CHAPTER 4: Geometry Definition

4-1 Overview
This chapter is presenting the different CAD operations necessary to convert respectively a CAD
model into a computational domain to mesh within HEXPRESS. The resulting computational
domain is stored in a file with extension ".dom" (see section A-4 on page A-2 for a description).
Different CAD operations allow to create the solid model which will be converted into a computa-
tional domain: unification of bodies, bounding box creation, bodies substraction and bodies inter-
section. After conversion to a discretized computational domain, further tools are available to edit
the computational domain and to merge surfaces.
Figure 4.1.0-1 presents a flow chart of the successive CAD manipulations needed to create a valid
computational domain for HEXPRESSstarting from Parasolid™ or CATIA models, STL trian-
gulations and StarCD surface meshes:
1. A bounding box can be added to Parasolid™ or CATIA bodies to define the computational
domain of the required region surrounding bodies, e.g. for external flow simulation.
2. Parasolid™ and CATIA bodies can be added, subtracted or intersected.
3. The solid model of the computational domain is then exported, in a discretized format, by
triangulating the surface of its closed volume.
4. The triangulation of the computational domain, annotated with geometry attributes, can be
exported into a ".stl" and a ".prop" file for further editing.
5. Triangulations can be directly imported using a ".stl" format file together with associated
property file ".prop", which gives a geometry attribute to each triangle of the triangulation.
This additional information allows the automatic creation of topological information by
HEXPRESS.
6. An additional tool allows to import StarCD surface meshes and convert them into a trian-
gulation format: ".stl" and ".prop" files.

HEXPRESS ™ 4-1
Geometry Definition Overview

7. Merging of topological surfaces can be performed on the triangulation model to simplify


the meshing process. Merging of surfaces decreases the number of topological entities in
the domain, especially the number of curves which must be captured by the mesh generator
(see section 6-7 on page 6-33 for a discussion of the corner and curve mesh capturing func-
tionalities).

Parasolid™ STL STARCD


CATIA

Import Parasolid™ Convert


Import STL
or CATIA V5 Re-orient

Create bounding box

Unify, delete
subtract, intersect

Export Faceting Export STL +PROP


STL

Spec. length.
tolerances,...
Import STL

Create Group
Merge
Reverse

Reverse
tolerance
Create Domain

DOM

FIGURE 4.1.0-1 HEXPRESS CAD handling

4-2 HEXPRESS™
Overview Geometry Definition

HEXPRESS is equipped with a Parasolid CAD engine. Therefore, any CAD model native to
this engine is transparently loaded by the mesh generator. Other native models must be translated to
the Parasolid format using external software before being processed (except for CATIA v5 for-
mat). A CAD model exhibits complex features which are unnecessary for the flow simulation. It is
therefore useful to remove unneeded geometry details from the model before starting the mesh gen-
eration. In HEXPRESS, this removal is not applied to the model directly but the complexity of
the computational domain is simplified by merging surfaces. The common edges between the
merged surfaces are then removed and are not captured in the mesh (see section 6-7 on page 6-33
for a discussion of the corner and curve mesh capturing functionalities). This merging is performed
at the topology level, hence no NURBS (Non Uniform Rational Bi-Spline) or surface representa-
tion is reconstructed. Geometry simplification in HEXPRESS is therefore accomplished with
minimum overhead. Figure 4.1.0-2 presents the computational domain of a draft tube before (top)
and after (bottom) simplification by surface merging.

FIGURE 4.1.0-2 Triangulated Parasolid CAD model before (top) and after (bottom)
surface merging

The user is referred to section A-4 on page A-2 for a description of the format of the file (suffix
".dom") storing the definition of HEXPRESScomputational domain.

HEXPRESS™ 4-3
Geometry Definition CAD Model

4-2 CAD Model


HEXPRESS accepts three different CAD formats as input for the topology and geometry descrip-
tion of the computational domain (Figure 4.1.0-1):
• Parasolid & CATIA model. can be imported and its different bodies can be accessed.
Recall here that the computational domain must be described as a single closed volume
(see section 4-2.1 on page 4-4).
• Colored STL (Stereo Lithography Triangulation) model representation can be
imported together with additional information about the geometry attributes of the trian-
gles, required to correctly reconstruct the topology of the model (see section 4-3 on page 4-
21).
• Computational domain file ".dom" is the HEXPRESS native model format. It is a dis-
cretized representation of the computational domain containing all topology information.
The computational domain is the geometry used for HEXPRESS grid generation and can
still be improved with the domain operations allowing the merging/splitting of its edges and
faces.

4-2.1 Import Solid Models


4-2.1.1 Import PARASOLID™ models
Parasolid™ models (files with extension ’.x_t’, ’.X_T’, ’.xmt_txt’ or ’.XMT_TXT’) are imported
by clicking on the SOLID button ( ) in the Welcome to HEXPRESS dialog box (see section 2-2
on page 2-2)
Several Parasolid™ files can be imported in the same HEXPRESS session using Project/
Import.../Parasolid. After importing, all bodies are displayed in wireframe mode.

HEXPRESS expects solid bodies. HEXPRESS is not able to perform any editing
operation on sheet bodies. In fact, sheet bodies are made by surfaces but not considered
as 3D solid and closed bodies.

HEXPRESS uses the Parasolid™ v24.0.193 library, thus all Parasolid™ models up
to version 24 can be imported.
To obtain a complete list of supported models version numbers, the user is referred to the
"para_schema" subdirectory in the HEXPRESS installation directory. This subdirectory contains
all Parasolid™ schemes compatible with HEXPRESS.
HEXPRESS provides several basic editing capabilities (unify, subtract, intersect, delete) in its
solid modelling session to create an unique solid body representing the computational domain.

4-2.1.2 Import CATIA V5 models


CATIA V5 models can be imported in HEXPRESS™ with the extension ’*.CATPart’ by clicking
on the SOLID button ( ) corresponding to CATIA V5 import in the Welcome to HEXPRESS dia-
log box (see section 2-2 on page 2-2). Versions up to R21 are supported.

4-4 HEXPRESS™
CAD Model Geometry Definition

4-2.2 Editing
When a solid model is successfully imported, the next step is to build a solid body describing the
computational domain. One of the imported bodies may represent the body, in which case the edit-
ing steps can be bypassed. Alternatively, the computational domain can be obtained by performing
Boolean operations on the solid bodies in the Parasolid™ database.
A box creation capability is also available in order to create a bounding box in the case where the
computational domain is the complement of a specific body, e.g. for external flow around a body.
The editing operations are accessed through the Quick Access Pad/CAD Manipulation/Create/
Edit options (Figure 4.2.2-1) which allow the user to create and modify bodies.

FIGURE 4.2.2-1 Create/Edit panel

4-2.2.1 Create Box


This button creates a parallelepiped box by defining two opposing points. These points can be spec-
ified through input in a dialog box or by clicking in the graphic area.

a) Dialog box
This dialog box allows the user to specify the coordinates of two opposing points used to define a
box (Figure 4.2.2-2).

FIGURE 4.2.2-2 Create box function

This action requires the following steps:


1. Specify the coordinates (x,y,z) of the first point.
2. Press the Apply button, which allows the second point definition and disables the first one.
3. Specify the coordinates (x,y,z) of the second point.
4. Press the Apply button, which allows the Accept button.

HEXPRESS™ 4-5
Geometry Definition CAD Model

5. Press Accept to generate the box and quit the box creation tool.

Because of Parasolid limitations, the coordinates of a box are limited by the range:
First corner X: -500, Y: -500, Z: -500 and Opposite corner X: 500, Y: 500, Z: 500

b) Interactive creation
The two opposing points of the box may be interactively specified by clicking in the graphics area.
1. A default box appears in the graphics area. Move the cursor to the desired location and left-
click on the first point.
2. While moving the cursor around, the drawing of the box is updated according to the cursor
position. Move the cursor to the desired location and left-click to place the second (oppo-
site) point.
3. Left-click to accept the box and quit the box creation tool.

The box creation tool can be aborted at any time, either by pressing the Cancel button
in the dialog box, or by right-clicking in the graphic area.

An accepted box cannot be modified later. It must be deleted and a new box created
but before clicking on Accept, the position of the box can be adapted by left-clicking on
box corner (when highlighted in yellow) and moving the cursor to the desired location or
by typing the coordinates (x,y,z) into the creation box dialog box. Nevertheless, it is
much easier to use the X,Y,Z plane views for box fitting.

4-2.2.2 Create Cylinder


The objective is to create cylinders entities through user inputs in a dialog box or by clicking in the
graphic area.

a) Dialog box
This dialog box allows the user to specify the origin of the cylinder, its direction, its height and its
radius (see Figure 4.2.2-3).

FIGURE 4.2.2-3 Create cylinder

This action requires the following steps:


1. Specify the coordinates (x,y,z) of the origin point.

4-6 HEXPRESS™
CAD Model Geometry Definition

2. Press the Apply button, which allows the direction definition and disables the first one.
3. Specify the direction (X,Y,Z) of the direction.
4. Press the Apply button, which allows the height definition.
5. Press Enter on the keyboard and specify the radius.
6. Press Enter and click on Accept to generate the cylinder and quit the cylinder creation tool.
Because of Parasolid limitations, the coordinates of a box are limited by the range:
First corner X: -500, Y: -500, Z: -500 and Opposite corner X: 500, Y: 500, Z: 500

b) Interactive creation
The cylinder may be interactively created by clicking in the graphics area.
1. A default dialog box appears in the graphics area. Move the cursor to the desired location
and left-click to confirm the position of the origin.
2. While moving the cursor around, the drawing of the cylinder is updated according to the
cursor position. Move the cursor to the desired location and left-click to confirm the direc-
tion and the height of the cylinder.
3. Move the cursor to adapt the radius and left-click to confirm.
4. Left-click to accept the cylinder and quit the creation tool.

The cylinder creation tool can be aborted at any time, either by pressing the Cancel
button in the dialog box, or by right-clicking in the graphic area.

An accepted cylinder cannot be modified later. It must be deleted and a new cylinder
created, but before clicking on Accept, the radius can be adapted by directly specifying
its value in the dialog box. Nevertheless, it can be easier to use the X,Y,Z plane views
for cylinder fitting.

4-2.2.3 Create Cone


The objective is to create cones entities through user inputs in a dialog box or by clicking in the
graphic area.

a) Dialog box
This dialog box allows the user to specify the summit of the cone, its direction, its height and the
radius at the basis (see Figure 4.2.2-4).

FIGURE 4.2.2-4 Create cone

HEXPRESS™ 4-7
Geometry Definition CAD Model

This action requires the following steps:


1. Specify the summit coordinates (x,y,z).
2. Press the Apply button, which allows the direction definition and disables the first one.
3. Specify the direction (X,Y,Z) of the direction.
4. Press the Apply button, which allows the height definition.
5. Press Enter on the keyboard and specify the basis radius.
6. Press Enter and click on Accept to generate the cone and quit the creation tool.
Because of Parasolid limitations, the coordinates of a box are limited by the range:
First corner X: -500, Y: -500, Z: -500 and Opposite corner X: 500, Y: 500, Z: 500

b) Interactive creation
The cone may be interactively created by clicking in the graphics area.
1. A default dialog box appears in the graphics area. Move the cursor to the desired location
and left-click to confirm the summit position.
2. While moving the cursor around, the drawing of the cone is updated according to the cursor
position. Move the cursor to the desired location and left-click to confirm the direction and
the height of the cone.
3. Move the cursor to adapt the basis radius and left-click to confirm.
4. Left-click to accept the cone and quit the creation tool.

The cone creation tool can be aborted at any time, either by pressing the Cancel button
in the dialog box, or by right-clicking in the graphic area.

An accepted cone cannot be modified later. It must be deleted and a new cone created,
but before clicking on Accept, the basis radius can be adapted by directly specifying its
value in the dialog box. Nevertheless, it can be easier to use the X,Y,Z plane views
for cone fitting.

4-2.2.4 Create Plane


The objective is to create planes entities through user inputs in a dialog box or by clicking in the
graphic area. Planes can typically be used in Boolean operations, to split a body into two parts. The
condition is that the plane completely intersects the body.

a) Dialog box
This dialog box allows the user to specify the origin of the plane, its normal direction, its size (see
Figure 4.2.2-5).

4-8 HEXPRESS™
CAD Model Geometry Definition

FIGURE 4.2.2-5 Create plane

This action requires the following steps:


1. Specify the coordinates (x,y,z) of the origin point.
2. Press the Apply button, which allows the normal definition and disables the first one.
3. Press the Apply button, which allows the plane size definition.
4. Press Enter on the keyboard and click on Accept to generate the plane and quit the plane
creation tool.
Because of Parasolid limitations, the coordinates of a box are limited by the range:
First corner X: -500, Y: -500, Z: -500 and Opposite corner X: 500, Y: 500, Z: 500

b) Interactive creation
The plane may be interactively created by clicking in the graphics area.
1. A default dialog box appears in the graphics area. Move the cursor to the desired location
and left-click to confirm the origin position.
2. While moving the cursor around, the drawing of the plane is updated according to the cur-
sor position. Move the cursor to the desired location and left-click to confirm the normal of
the plane.
3. Specify the plane size in the dialog box and press Enter.
4. Click on Accept to create the plane.

The plane creation tool can be aborted at any time, either by pressing the Cancel but-
ton in the dialog box, or by right-clicking in the graphic area.

An accepted plane cannot be modified later. It must be deleted and a new plane cre-
ated, but before clicking on Accept, the origin and the normal values can be modified in
the graphics area. The radius can also be adapted by directly specifying its value in the
dialog box. Nevertheless, it can be easier to use the X,Y,Z plane views for
plane fitting.

HEXPRESS™ 4-9
Geometry Definition CAD Model

4-2.2.5 Create Sphere


The objective is to create spherical entities through user inputs in a dialog box or by clicking in the
graphic area.

a) Dialog box
This dialog box allows the users to specify the origin and radius of the sphere. See Figure 4.2.2-6.

FIGURE 4.2.2-6 Create sphere

This action requires the following steps:


1. Specify the coordinates (x,y,z) of the origin point.
2. Press the Apply button, which allows the input for radius definition.
3. Press Enter on the keyboard and click on Accept to create the sphere and quit the sphere
creation tool.

The minimum radius is limited to 1e-8.


b) Interactive creation
The sphere may be interactively created by clicking in the graphics area.
1. A default dialog box appears in the graphics area. Move the cursor to the desired location
and left-click to confirm the origin position.
2. While moving the cursor around, the drawing of the sphere is updated with different radius
according to the cursor position. Move the cursor to the desired location and left-click to
confirm the radius of the sphere.
3. Click on Accept to create the sphere and quit the creation tool.

The sphere creation tool can be aborted at any time, either by pressing the Cancel but-
ton in the dialog box, or by right-clicking in the graphic area.

An accepted sphere cannot be modified later. It must be deleted and a new sphere shall
be created, but before clicking on Accept, the sphere radius can be adapted by directly
specifying its value in the dialog box.

4-10 HEXPRESS™
CAD Model Geometry Definition

4-2.2.6 Subtract

a) Overview
A Boolean subtract operation may be performed between a target body and a list of tool bodies. The
target body and tool bodies are selected either in a dialog box or by picking in the graphic area.

b) Body picking description


The body under the cursor is highlighted. It is possible to cycle through several bodies by middle-
clicking. The highlighted body can be selected/unselected by left-clicking.

c) How to substract bodies?


The user may subtract bodies as follows (Figure 4.2.2-7):
1. Select the target body.
2. Press the Accept button in the body selection box.

FIGURE 4.2.2-7 Target and Tool bodies selection dialog boxes

3. Select the tool body (or bodies) (bodies to be subtracted from the target body).
4. Press the Perform button.
If the Boolean subtract operation between the target body and the tool bodies is successfully per-
formed, the target body is modified and the tool bodies are deleted.

Only one target body may be selected, but several tool bodies can be selected.
All bodies except the target can be selected simultaneously by pressing ’a’ in the
graphic area.

The Boolean subtract operation tool can be aborted at any time, either by pressing
Cancel button or by right-clicking in the graphic area.

Orientation of the Parasolid™ bodies is very important (Figure 4.2.2-9).


4-2.2.7 Unite

a) Overview
A Boolean unite operation can be performed between a target body and a list of tool bodies. The
target body and tool bodies can be selected either in a dialog box or by picking in the graphic area.

HEXPRESS™ 4-11
Geometry Definition CAD Model

b) Body picking description


The body under the cursor is highlighted. It is possible to cycle through several bodies by middle-
clicking. The highlighted body can be selected/unselected by left-clicking.

c) How to unite bodies?


The user may unite bodies as follows (Figure 4.2.2-8):
1. Select the target body.
2. Press Accept button in the body selection box.

FIGURE 4.2.2-8 Target and Tool bodies selection dialog boxes

3. Select the tool body (or bodies).


4. Press the Perform button.
If the Boolean unite operation between the target body and the tool bodies is successfully per-
formed, the target body is modified and the tool bodies are deleted.

Only one target body can be selected, but several tool bodies can be selected.
Orientation of the Parasolid™ bodies is very important (Figure 4.2.2-9)

3 Parasolid™ bodies Select 1st body Select 2nd body Bodies not well united
to unite yellow pipe blue box because
1st body is not well oriented

FIGURE 4.2.2-9 Parasolid™ bodies orientation

All bodies except the target can be selected at the same time by pressing ’a’ in the
graphic area.

The Boolean unite operation tool can be aborted at any time, either by pressing Cancel

4-12 HEXPRESS™
CAD Model Geometry Definition

button or by right-clicking in the graphic area.

The Unite operation gives good results in term of bodies but not of surfaces. In fact,
surfaces remain disconnected after this operation. For example, the unite operation on
three solid bodies results in a general body, which could be (depending on the case)
unsuitable for further operations with HEXPRESS™.

4-2.2.8 Intersect

a) Overview
A Boolean intersection operation can be performed between a target body and a list of tool bodies.
The target body and tool bodies can be selected either in a dialog box or by picking in the graphic
area.

b) Body picking description


The body under the cursor is highlighted. It is possible to cycle through several bodies by middle-
clicking. The highlighted body can be selected/unselected by left-clicking.

c) How to intersect bodies?


The following steps are performed to complete the intersect operation (Figure 4.2.2-10):
1. Select the target body.
2. Press the Accept button in the body selection box.

FIGURE 4.2.2-10 Target and Tool body selection dialog boxes

3. Select the tool body (or bodies).


4. Press the Perform button.
If the Boolean intersect operation between the target body and the tool bodies is successfully per-
formed, the target body is modified and the tool bodies are deleted.

Only one target body can be selected, but several tool bodies can be selected.
All body except the target can be selected simultaneously by pressing ’a’ in the
graphic area.

The Boolean intersect operation tool can be aborted at any time, either by pressing
Cancel button or by right-clicking in the graphic area.

Orientation of the Parasolid™ bodies is very important (Figure 4.2.2-9).

HEXPRESS™ 4-13
Geometry Definition CAD Model

4-2.2.9 Delete

a) Overview
This function allows the user to delete one or several bodies. These bodies may be selected either in
a dialog box or by picking in the graphic area.

b) Body picking description


The body under the cursor is highlighted. It is possible to cycle through several bodies by middle-
clicking. The highlighted body can be selected/unselected by left-clicking.

c) How to delete bodies?


A deletion operation is performed as follows (Figure 4.2.2-11):
1. Select the bodies.
2. Press the Delete button in the body selection box.

FIGURE 4.2.2-11 Body selection dialog box

Several bodies can be selected.


All bodies can be selected simultaneously by pressing ’a’ in the graphic area.
The deletion operation tool can be aborted at any time, either by pressing Cancel but-
ton in the dialog box, either by right-clicking in the graphic area.

4-2.2.10 Transform
The Transform button allows to scale, rotate or translate the selected Parasolid entities.

FIGURE 4.2.2-12 Body transformation menu

4-14 HEXPRESS™
CAD Model Geometry Definition

The operations (translation, rotation, scaling) are applied to the active bodies selected from the Vis-
ualization/Selection page after clicking on the Apply button:
• For the rotation, the origin, axis and angle in degree have to specified,
• For the translation, the translation direction has to be specified. The specified vector includes
the magnitude of the translation,
• For the scaling, the scaling factor along the X, Y and Z directions should be specified. The scal-
ing factors have to be strictly positive.

When different scaling factors along the X, Y and Z directions are imposed, depend-
ing of the complexity of the geometry, the scaling may not succeed.

4-2.2.11 Undo
The Undo button allows to undo CAD manipulations up to 10 successive operations. The undo
functionality is available for CAD manipulations except the Create Domain and Save functionali-
ties.

The option is not compatible with the management of internal surfaces.


4-2.2.12 Create Domain
The Create Domain step converts a solid representation of the computational domain into a discre-
tized one. Pressing Create Domain opens the Create domain dialog box (Figure 4.2.2-13).
The discretization of the model is a conformal triangulation of the surface boundary delimiting the
computational domain, it is produced using the faceting capabilities of Parasolid™. Triangles are
grouped according to their original topology faces in the solid model. There is a one-to-one map-
ping between the discretization triangle groups and the solid model topology faces. If no further
operation is performed on the triangulation itself, the curves in the HEXPRESS ".dom" file are
those found in the solid model.
The discretization resolution can be modified by changing the faceting parameters and pressing the
Apply button in the pop-up window
Pressing the Cancel button in the Create domain dialog box deletes the current discrete representa-
tion and any work performed on the model is lost.

HEXPRESS™ 4-15
Geometry Definition CAD Model

The validation of the discretization and the creation of the domain object (".dom" file) is accom-
plished by pressing the Create button.

FIGURE 4.2.2-13 Create domain dialog box

It is very important to notice that a poor triangulation will certainly lead to a bad mesh. On the con-
trary, a good triangulation will allow to capture the geometry correctly.

FIGURE 4.2.2-14 Differences between a poor triangulation (left) and a good one (right)

a) Faceting
The faceting step allows the user to adapt the default resolution discretization if necessary.
The following parameters control the creation of the triangulation of the selected body.

4-16 HEXPRESS™
CAD Model Geometry Definition

• Minimum length: the minimum edge length of the triangulation facets. A default value is
automatically computed by the system.
• Maximum length: the maximum edge length of the triangulation facets. A default value is
automatically computed by the system.
• Curve chordal tolerance: the maximum distance between a curve and the corresponding tri-
angulation edges. A default value is automatically computed by the system.
• Surface plane tolerance: the distance tolerance in model units between a surface and its tri-
angulation, i.e. the maximum distance between a facet and its corresponding surface. A
default value is automatically computed by the system.
• Curve resolution: the maximum angle in degrees between a curve and the triangulation
edges, i.e. the maximum of the sum of the angles between the edge and the curve tangents
measured at the extremities of the edge. Values may range from 1.0 to 30. A default value is
automatically computed by the system.
• Surface resolution: the angular tolerance in degrees between a surface and its triangulation.
Values may range from 1.0 to 30. degrees. A default value is automatically computed by the
system.
Pressing the Apply button updates the faceting of the model taking into account the new parameters.
The Default buttons, associated to each of these parameters, reset their values to the default ones.
Best Practice:
The Minimum length should be smaller that the minimum geometrical entity to capture. Usually,
curve and surface resolutions should be equal to 5 for a correct triangulation up to 2 for a precise
triangulation. Curve chordal and surface plane tolerances can be divided by 100 most of times but
should be tuned according to the case.
Each geometry to export gives different default faceting settings. Users are invited to make a first
try only with a visual but satisfying triangulation keeping in mind that the mesh quality depends on
the triangulation.

b) Discretized CAD manipulation


When the desired level of resolution is obtained for the discrete representation, several editing oper-
ations can be applied in order to remove topological details. Recall that a set of connected triangle
edges, separating two triangle groups, results in a curve in the ".dom" file.
These editing operations are the same as the ones applied on imported ".stl" and associated ".prop"
files, please refer to section 4-3.3.3 on page 4-25 for further details.

c) Export parameters
Several parameters can be modified:
• Reverse triangulation orientation: always check that the orientation of the triangulation is
consistent (see section 4-3.3.3 on page 4-25 on how to select facets and to check their orien-
tation), i.e. all triangle normals point either inside the domain or outside the domain. Since
the standard orientation convention is to have normals pointing inwards, the "Reverse trian-
gulation orientation" item should be checked in the latter case.
• Merge tolerance: refers to the minimum distance between vertices. Vertices closer than this
reference length will be considered duplicate and merged. No limitation check is performed
on the merge tolerance. Choosing a tolerance that is too large may prevent HEXPRESS
from successfully creating the ".dom" computational domain.

HEXPRESS™ 4-17
Geometry Definition CAD Model

Pressing the Create button opens a file chooser window that enables the user to set the name of the
new domain. Once it is done, the domain is created and imported (Figure 4.2.2-15):

FIGURE 4.2.2-15 Domain import.

If No is pressed, the Create domain dialog box remains opened. If Yes is pressed, all bodies are
deleted, the new domain is imported and is ready for meshing.
When loading CAD Parasolid™ or CATIA v5 entities, the name of the surfaces will be transferred
in the created domain. For each domain face, a name will be assigned in two different ways:
• If the CAD file contains surface names, there are transferred to the domain faces during domain
construction,
• Faces of boxes created via CAD Manipulation will have a name of type
“bodyname_face_facenumber”, e.g. B1_face_1 for instance.

Triangulation settings are saved during the creation of the domain and written in the
domain file (".dom"). They are written in the line following the line with the orientation
face flag. For instance, for a single block case, it is the 6th line of the ".dom" file. Please
check Appendix A-4 for a description of the domain format and triangulation parame-
ters.

4-2.2.13 Save
The Save button creates a Parasolid™ file to save a backup file after performing CAD manipulation
operations or to modify this Parasolid™ file in an external CAD software. Clicking on Save button
opens a file chooser to enter the name of the Parasolid™ file and will save all entities selected in the
Visualization/Selection menu.

4-18 HEXPRESS™
CAD Model Geometry Definition

4-2.3 Visualization/Selection
This page contains a browser to select, show, and hide bodies.

FIGURE 4.2.3-1 Visualization/Selection menu

When loading a CAD Parasolid™ or CATIA v5 geometry, bodies or sheets names appear in the
Visualization/Selection page. To manipulate them, select one or several bodies or sheets and per-
form the actions present in the Create/Edit page or the actions coming from the right-click menu.

4-2.3.1 Selection
A body can be selected at any time by left-clicking on its name, it is then highlighted in the graphics
area. Multiple selections are made by <Ctrl>-left-clicking. If a body is already selected, <Ctrl>-
left-click unselects it. It is also possible to select bodies by left-clicking on them in the graphic area:
• The select tool must be started by pressing the Select button.
• The body under the cursor is highlighted. If several bodies lie under the cursor, they can be
cycled by middle-clicking. The highlighted body can be selected/unselected by left-click-
ing.
• Right-clicking exits the selection tool.

4-2.3.2 Pop-up Menu


Selected bodies can be either shown or hidden. This is accomplished by right-clicking in the
browser, which opens the following menu (Figure 4.2.3-2):

FIGURE 4.2.3-2 Visualization/Selection pop-up menu

Following options are available:

HEXPRESS™ 4-19
Geometry Definition CAD Model

• Hide: selected bodies are hidden.


• Show as wireframe: edges of selected bodies are displayed
• Show as solid: faces of selected bodies are displayed.
• Show as triangulation: current triangulation is displayed
• Zoom to: zoom is applied on selected bodies
• Check: selected bodies geometry is verified

FIGURE 4.2.3-3 Check pop-up: geometry ok (right) - not ok (left)

• Sew: edges of selected bodies are merged with a tolerance specified by the user.

FIGURE 4.2.3-4 Sew bodies dialog box

It is also possible to hide all the bodies by pressing Hide All button, and to display all bodies by
pressing Show All button. The Select button allows a mouse picking selection of the bodies
(Figure 4.2.3-5).

FIGURE 4.2.3-5 Visualization/Selection subpanel

4-20 HEXPRESS™
STL Model Geometry Definition

4-3 STL Model


4-3.1 Introduction
4-3.1.1 What is STL?
The acronym STL stands for Stereo Triangulation Lithography. This file format has traditionally
been associated with Stereo Lithography prototyping machines, but is used by HEXPRESS to
describe the "water-tight" surface boundary of the computational domain represented by a triangu-
lation. The reader is referred to section A-1 on page A-1 for a description of the STL file format.

4-3.1.2 STL representation of the computational domain


The triangulation in the STL file is assumed to respect a specific orientation convention. The nor-
mal of all the triangles points into or points out of the computational domain. The triangulation is
also assumed to be conformal, i.e. all adjacent facets must share two vertices.
HEXPRESS is now able to read colored STL which also contains the groups definition. For back-
ward compatibility reasons, HEXPRESS can also read with old STL representation format, an
additional property file (suffix ".prop"), giving information on the STL file triangles. The first line
of the property file gives the number of topology faces in the computational domain. HEXPRESS
scans the following lines of the property file in synchronization with reading the facets in the STL
(".stl") file in order to get triangles and the topology face to which they belong. In this manner,
HEXPRESS groups all triangles by topology face identifier.
The topology description is then built by HEXPRESS based on the STL and property file
description. HEXPRESScreates topological edges as a list of triangle edges whose neighbours
have a different topological face support. Topological faces are created by grouping all triangles
having the same topological face support.
HEXPRESS provides tools to visualize and modify the STL and associated property representa-
tion.

4-3.2 Import
Colored STL files can be imported by clicking on the STL button ( ) of the Welcome to HEX-
PRESS dialog box (see Figure 2.2.0-1 on page 2-3) or using Project/Import.../STL triangulation
menu. The additional property file with extension ’.prop’ if existing is also automatically imported.

4-3.3 STL Manipulation


There are two types of STL files, which can be imported in HEXPRESS™. The first one is the
colored STL file in which groups are already created and the second one (non-colored) corresponds
to a STL format where groups are not present.

4-3.3.1 STL Group Tool


If the imported STL file has only one group (means that it does not have color), a pop-up dialog box
appears, shown on Figure 4.3.3-1.

HEXPRESS™ 4-21
Geometry Definition STL Model

FIGURE 4.3.3-1 STL group tool

This dialog box needs the inputs STL Merge Tolerance and Feature Angle Tolerance so as to cre-
ate the groups. The default values are shown in the dialog box. The actions associated to the buttons
Preview and Apply are the following:
• Preview: when clicking on this button, it will generate the preview of the STL file in the
graphics area. It will show the groups with colors created by using above input parameters.
• Apply: this button apply the settings and creates the groups. All created groups created will
be added to the data structure.

4-3.3.2 STL Manipulation Menu


The STL Manipulation menu can be divided in two parts: the manipulation and the viewing/selec-
tion modes.

FIGURE 4.3.3-2 STL Manipulation menu

a) Viewing/Selection
Select: this button in the Edit page provides the user various selection modes. When user clicks on
this button, an interactive tool for selecting the groups with the mouse is enabled, together with a
selection mode dialog box shown in figure 6 below. It has various group selection options described
below:
• Single Selection: groups can be selected by left-clicking on the mouse. If user clicks on a
selected group again, then that group will become as non-selected group. The selection is
cumulative, which means that when clicking on several different groups (without the need
of pressing shift), the groups are added to the current selection. The shortcut <a> can be
used in the graphics area to select or unselect all groups at once.

4-22 HEXPRESS™
STL Model Geometry Definition

Front Group can be used to select groups which are in front of the others (the ones
which are visible when shaded representation is active). The groups which are in the
back will not be selected.
Front and Back Groups: both front and back groups will be selected, if this option
is selected.

FIGURE 4.3.3-3 Single Selection mode

• Rectangular Selection: groups can be selected by drawing rectangle around the groups to
be selected.
Inside Only option selects the groups which are inside the drawn rectangle.
Inside + Intersecting option selects the groups which are inside as well as intersect-
ing the rectangle.

FIGURE 4.3.3-4 Rectangular Selection mode

• Polygonal Selection: in this mode, a polygon is drawn around the groups to select.
Inside Only option selects the groups which are inside the drawn polygon.
Inside + Intersecting option selects the groups which are inside as well as intersect-
ing the polygon.

HEXPRESS™ 4-23
Geometry Definition STL Model

FIGURE 4.3.3-5 Polygonal Selection mode

View/Select page is a tree view (see Figure 4.3.3-2) in which all the group names present in the
STL file will be shown:
— Press the left-mouse button to select the group under the mouse.
— Press <Shift> + left-mouse button to add a group to the current selection.
— Press <Ctrl> left mouse button to add a group to the current selection.
— Press the right-mouse button to pop up the floating menu shown on
— Selecting the “Root” of all the groups will select all the groups in the tree

FIGURE 4.3.3-6 Floating menu - Display Options

Upon selection in this menu, the related operation will be performed on all selected groups:
— Hide: this will hide the selected groups.
— Show as wireframe: the selected groups will be displayed in a wireframe mode (boundaries
of the groups).
— Show as solid: the groups will be visible in solid view mode.
— Show as triangulation: in this mode, the facets of the groups will be visible.
— Rename: this will change the name of the groups. In case only one group was selected, the
user will enter the name directly on top of the current name. When more than one group are
selected, a dialog box will be popped-up so as to enter the common root name for all the
selected groups. Each group will then be renamed <new_name>_1, <new_name>new_n.
— SortGroup-Ascending or SortGroup-Descending: click on this menu to sort the selected
groups in the ascending or descending order.

4-24 HEXPRESS™
STL Model Geometry Definition

b) Manipulation
This is used to perform different operations on STL file such as merging or splitting groups. It is
also possible to undo the last operation. The functions of various buttons used in this menu are
explained below.
Merge: this button will be used to merge the selected groups of the STL file. To select or unselect
groups, left-click on the mouse. To quit the merge operation, right-click on the mouse.
Split: this button will be used to split the selected group in two groups. The required steps to per-
form the split operation are:
• Select the group to be split,
• Click on the Split button,
• Select two split points on the boundary of the group. The points should be on the edges of
the facets which are the boundary edges of the group. After selecting two valid split points
HEXPRESS™ will automatically generate the path.
• Right-click to quit the split operation.
Undo: this button will undo the last operation on the STL file.
Create Domain: this button creates the domain based on the present surfaces.

If the original STL file contains surface names, there are transferred to the domain
faces during domain construction.

4-3.3.3 STL/Edit
HEXPRESS™ provides simple operations to edit the imported STL file in the menu bar.

a) Mirror geometry
STL/Edit/Mirror geometry mirrors the whole STL representation relative to a specified mirror
plane.
The following prompt controls the definition of the mirror plane:
PLANE: point =
>> 0. 0. 0.
PLANE: normal =
>> 1. 0. 0.
To quit this command before the end, enter <q> in the keyboard input area and press <Enter>.

b) Translate geometry
STL/Edit/Translate geometry translates the whole STL representation by the specified translation
vector.
The following prompt controls the definition of the translation vector:
Translation vector =
>> 1. 0. 0.
To quit this command before the end, enter <q> in the keyboard input area and press <Enter>.

HEXPRESS™ 4-25
Geometry Definition STL Model

c) Rotate geometry
STL/Edit/Rotate geometry rotates the whole STL representation by the specified angle around an
axis defined by a point and a direction vector.
The following prompt controls the definition of the mirror plane:
Rotation axis vector (q)
>> 0. 0. 1.
Rotation axis origin (q)
>> 0. 0. 0.
Rotation angle (q)
>> 10.
The angle is expressed in degrees.
To quit this command before the end, enter <q> in the keyboard input area and press <Enter>.

d) Clear all
STL/Edit/Clear all clears all groups and cell lists. The graphical representation is removed from
the view and deleted.

e) Information
STL/Edit/Information outputs information regarding the triangulation attributes to the console
shell. A typical output appears as follows:

STLDiscretisation Information
------------------------------
---> nb. triangles : 14330
---> nb. vertices : 42990
---> nb. groups : 13
---> groups

Flag nb. triangles


---- -------------

0 12059
1 936
2 37
3 10
4 38
5 39
6 42
7 982
8 46
9 10
10 44
11 45
12 42
unselected 0

Total cells: 14330


---> xMin = 2.999999932945e-02, -5.999999865890e-02, 2.199999988079e-01
---> xMax = 1.299999952316e-01, 5.999999865890e-02, 3.199999928474e-01
---> xMid = 7.999999728054e-02, 0.000000000000e+00, 2.699999958277e-01
Signed Volume: 6.454585192160e+01

These information can be useful to check the discretization of each face. The total amount of cells is
also computed to get an idea about how many triangles the complete domain will contain. Besides,
information about the minimum and the maximum coordinates are computed as well as the mean
coordinates and the volume of the geometry.
The user is also asked for a reference length. All triangle edges shorter than this reference length are
considered as degenerated and then collapsed.
Absolute Tolerance for size information =
>> 1e-6

4-26 HEXPRESS™
STL Model Geometry Definition

To quit this command before the end and have no further information displayed in the console shell,
enter <q> in the keyboard input area and press <Enter>.

Additional information about potential degenerated triangles is displayed in the console shell.

Cell has min. length = 2.097351920513e-08


.........max. length = 4.128045738260e-03, flag = 1
--> count = 1828
--> node 0: 5.514487624168e-02 -2.437819911216e-12 2.495113313198e-01
--> node 1: 5.927037075162e-02 -1.448141693366e-11 2.493663281202e-01
--> node 2: 5.927037447691e-02 2.062554571580e-08 2.493663281202e-01
Cell has min. length = 2.986047331594e-08
.........max. length = 8.229180342422e-05, flag = 0
--> count = 4888
--> node 0: 9.326978772879e-02 -2.007243782282e-02 2.569002211094e-01
--> node 1: 9.335155040026e-02 -2.006312087178e-02 2.569002509117e-01
--> node 2: 9.335155040026e-02 -2.006312273443e-02 2.569002211094e-01
Cell has min. length = 2.097351920513e-08
.........max. length = 2.295982731667e-03, flag = 0
--> count = 7741
--> node 0: 5.917158722878e-02 -3.586173697840e-04 2.516319751740e-01
--> node 1: 5.927037447691e-02 2.062554571580e-08 2.493663281202e-01
--> node 2: 5.927037075162e-02 -1.448141693366e-11 2.493663281202e-01
Cell has min. length = 2.986047331594e-08
.........max. length = 5.724828521196e-05, flag = 0
--> count = 12855
--> node 0: 9.340154379606e-02 -2.003522962332e-02 2.569002509117e-01
--> node 1: 9.335155040026e-02 -2.006312273443e-02 2.569002211094e-01
--> node 2: 9.335155040026e-02 -2.006312087178e-02 2.569002509117e-01
STLDiscretisation: SIZE INFO
---> min. length = 2.097351920513e-08
---> max. length = 8.660253859303e-02
---> nb. degen. cells [reference dist. = 5.000000000000e-08] : 4

4-3.3.4 STL/Export...

a) Ascii stl format


STL/Export.../Ascii stl format is used to export an STL representation to an ASCII ".stl" file
and an associated property file with extension ".prop". The following prompt appears to define
whether all the groups should be exported or only those currently visible.

Export all [1] or visible cells only [0]?


>> 1

To quit this command before the end, enter <q> in the keyboard input area and press <Enter>.

b) Binary stl format


STL/Export.../Binary stl format is used to export an STL representation to a binary ".stl" file
and an associated property file with extension ".prop". The following prompt appears to define
whether all the groups should be exported or only those currently visible.

Export all [1] or visible cells only [0]?


>> 1

To quit this command before the end, enter <q> in the keyboard input area and press <Enter>.

When performing the action, the export operation is applied to the active domain only
and is resulting in an ASCII or binary STL file completed with a property file including
surface definitions for ASCII STL file.

HEXPRESS™ 4-27
Geometry Definition StarCD Surface Mesh

In the resulting binary file, only "COLOR" is present.


VisCAM/SolidView STL is not supported.

4-4 StarCD Surface Mesh


The import of StarCD surface mesh files are described in section 2-3.6.1 on page 2-54. The conver-
sion produces an ".stl" and associated ".prop" file. Starting with version 1.2, the orientation of the
triangles is checked automatically to ensure the same orientation of all the triangles (pointing all
outward or all inward).

4-5 Internal Surface Geometry


The Internal Surface subpanel (Figure 4.5.0-1) commands allow the creation of points, curves and
surfaces. These are basic but very useful geometries functions allowing to include additional sur-
faces within the initial geometry to mesh.

FIGURE 4.5.0-1 Geometry subpanel

The additional surfaces are not modifying the limits of the domain but can be used during the adap-
tation step in order to refine the mesh in the neighbourhood of these new geometrical entities.
Please refer to section 2-5.2 for more details.

4-28 HEXPRESS™
CHAPTER 5: Domain Manipulation

5-1 Overview
This chapter is presenting the different domain operations necessary to clean or adapt a computa-
tional domain before generating the mesh within HEXPRESS™. The resulting computational
domain is stored in a file with extension ".dom" (see section A-4 on page A-2 for a description).
When a first computational domain has been created, domain operations allow to improve its defi-
nition by splitting/merging its edges and faces. Finally, tools allow to check the validity of the
domain.

5-2 Domain Definition


The starting point of any simulation is the definition of an appropriate computational domain,
which, in most cases, can be interpreted as the complement of the solid parts present in the model.
HEXPRESS expects a "water-tight" computational domain. The computational domain consists
of a topology and a geometry part as presented in Figure 5.2.0-1.
• The topology describes the skeleton of the model. Basically, it allows the definition of a
closed volume and provides information on the connection of the model surfaces (topologi-
cal faces) with common curves (topological edges). Similarly, it connects curves together
by common corners (topological vertices).
• The geometry part defines the actual geometry of the model. Each model surface is
described by a triangulation, each curve by a list of points connected by segments and the
corners are defined by a single point.

HEXPRESS ™ 5-1
Domain Manipulation Domain Manipulation

FIGURE 5.2.0-1 HEXPRESS computational domain definition.

5-3 Domain Manipulation


As described in section 2-5.3 on page 2-78, the Domain Manipulation subpanel (Figure 5.3.0-1)
allows to transform edges and faces composing the domain of the mesh, as well as the domain
itself.
• Both edges and faces composing the domain can be manually and/or automatically split and
merged.
• A settings icon allows to define the shortest edge length after split and the feature angle. The
feature angle is the minimum angle between two edges or between the two normals of faces to
merge.
• A "domain validity check" icon allows to control the domain before meshing.
• An "undo" icon allows to undo the last performed operation.

5-2 HEXPRESS™
Domain Manipulation Domain Manipulation

Manual Edge Split/Merge Auto Edge Merge

Manual Face Split/Merge


Auto Face Merge
Move Part Replace Domain

Undo Settings

Delete Block
Domain validity check

FIGURE 5.3.0-1 Domain manipulation subpanel

Split Edges: allows to split manually selected edge one by one using mouse picking. To select the
edge, just pick it in the graphics area at the position where it should split.

FIGURE 5.3.0-2 Manual edge split

Merge Edges: allows to merge manually selected edge one by one using mouse picking. To select
the vertex, just pick it in the graphics area at the position where the edges should be merged (loca-
tion of the vertex).

FIGURE 5.3.0-3 Manual edge merge

HEXPRESS™ 5-3
Domain Manipulation Domain Manipulation

Merge Edges Automatically: allows to merge automatically edge based on a feature angle.
When clicking on the icon, the following dialog box appears.

FIGURE 5.3.0-4 Automatic edge merge dialog box - settings

Define angle to be used for feature detection allows to define an angle over which the merging is
performed. The default feature angle is 140 degrees.
Display options allows to define the way the merging will be displayed:
• Activate ’Zoom in to display the set of edges being merged’ to center the graphics area on the
merged edges.
• Activate ’Do not modify display’ to keep defaults graphics area zoom.
When clicking on OK to start the merging, the edges could then be merged one by one (Merge) or
fully automated (Merge All).

FIGURE 5.3.0-5 Automatic edge merge dialog box - merging

Split Faces: allows to split manually selected face one by one using mouse picking. Faces can be
manually split by a new edge (two points) or a plane (three points).

Toggle <m> allows to select the way to split the face (by an edge or a plane).

The two points have to be specified to create this edge in the graphics area on the face to be split.
Selected face is displayed in green.

5-4 HEXPRESS™
Domain Manipulation Domain Manipulation

FIGURE 5.3.0-6 Manual face split

In cases HEXPRESS™ cannot find an optimal split path just with two points, a third point (to
define a plane) in addition to the usual two points can be specified on the face boundary for identi-
fying good split path.

Merge Faces: allows to merge manually faces based on a common existing edge. The edge has to
be specified to create the new merged face. To select the edge, just pick it in the graphics area. The
faces that are going to be merged together are displayed in green.

FIGURE 5.3.0-7 Manual face merge

After this operation, two faces are unified in one but vertices are not automatically
merged. Users can decide to keep or merge the corresponding edges.

HEXPRESS™ 5-5
Domain Manipulation Domain Manipulation

Merge Faces Automatically: allows to merge automatically face based on a feature angle.
When clicking on the icon, the following dialog box appears.

FIGURE 5.3.0-8 Automatic face merge dialog box - settings

Define angle to be used for feature detection allows to define an angle over which the merging is
performed. The default feature angle is 140 degrees.
Display options allows to define the way the merging will be displayed:
• Activate ’Zoom in to display the set of faces being merged’ to center the graphics area on the
merged faces.
• Activate ’Do not modify display’ to keep defaults graphics area zoom.
Boundary conditions type allows to adapt the merging process when different boundary condition
type detected:
• Activate ’Merge faces and assign UND type to the resulting face’ to reset the boundary con-
dition for the resulting faces.
• Activate ’Do not merge faces’ to avoid merging of faces having different boundary conditions.

When clicking on OK to start the merging, the faces could then be merged one by one (Merge) or
fully automated (Merge All).

FIGURE 5.3.0-9 Automatic face merge dialog box - merging

After this operation, two faces are unified in one but vertices are not automatically
merged. Users can decide to keep or merge the corresponding edges.

5-6 HEXPRESS™
Domain Manipulation Domain Manipulation

Merge Face Selection: allows to merge a set of selected faces in the graphics area or in the Merge
Faces dialog box. With this option, the user simply selects the faces he wants to merge and then
performs the merging by pressing the Merge button. Click on icon to undo the performed
merging operations.

FIGURE 5.3.0-10 Merge face dialog box

A face can be selected by left-clicking in the face browser or interactively in the graphics area. This
face is then automatically visualized in the graphics area. It is possible to select several faces at
once in the following ways:
1. While holding the <Ctrl> key down, select the desired faces in the browser.
2. While holding the <Shift> key down, select two faces delimitating a range of faces.
3. While pressing the left mouse button, drag the mouse and release the left button to select a range
of faces.
4. Pressing <Ctrl> + <a> keys down will select all patches.
5. Interactively in the graphics area depending of the selection options (shortcut <o>):
• <Ctrl> + left-click or left-click on successive faces,
• Draw a rectangle in the graphics area to select all surfaces which are completely or partly
inside the rectangle. For this purpose, hold <Ctrl> key and drag the mouse with the left-
click.

HEXPRESS™ 5-7
Domain Manipulation Domain Manipulation

6. Clicking on Select button and move mouse and left-click in the popup menu to select the type of
face selection.

• Select All Blanked allows to select all blanked faces in the graphics area.
• Select Face By Area allows to select all the faces with an area in the range specified by the
user.

• Select Face By Name allows to select all the faces whose name match the input name. A
dialog box is provided to input the name. The name can be a regular expression (i.e. if the
input is "channel*" all the faces whose name begins with channel will be selected)
• Select Geometrically Similar Faces allows to select all the faces with an area and a perim-
eter (under a tolerance of 0.03) identical to the selected face in the list.
• Select Tangent Faces allows to select all the faces tangent to each other (neighbouring
faces presenting an angle above the specified angle), starting from the list of selected faces.

The shortcut <t> can be used to select the option directly.


By right-clicking on a face or a group of faces in the menu or in the graphics area, a popup menu
allows to:
• blank all selected faces (Blank/Unblank),
• set name to all selected faces (Set Name),
• zoom to all selected faces (Zoom in),
• invert selection (Invert Selection),
• undo successive selections of faces (Undo Selection).

The shortcut <h> in the graphics area will display hints. There are information about mouse button
bindings and shortcuts.

Move Part: allows to translate and/or rotate and/or scale one or more parts of a domain consisting in
several disjoined parts (a part can also be a body onto a mirror patch). For instance, the option

5-8 HEXPRESS™
Domain Manipulation Domain Manipulation

allows to rotate a rudder of a boat, rotate a body around its pitch angle or to move the loads of an
aircraft.

The operations (translation, rotation, scaling) are applied to the parts selected in the left list of the
Move Parts dialog box after clicking on the Apply button:
• for the rotation, the origin, axis and angle in degree have to specified,
• for the translation, the translation direction has to be specified. The specified vector includes the
magnitude of the translation.
• for the scaling, the scaling factor along X,Y,Z directions has to be specified.

This option is available only if disjoined parts exist in the domain.


This option does not have checks to detect if the moving part stays inside the domain
or whether it does not intersect other parts.

When performing a scaling on a domain including a mirror face, it does not move dur-
ing the scaling by translating the domain to the origin before the scaling and then trans-
lating back to its original place after the scaling.

An Undo button is directly available in the window to come back to the previous posi-
tion.
Delete: allows to delete a domain when dealing with a multi-domains project. The option is avail-
able only for a multi-domain project without generated mesh and will delete existing FNMB con-
nections related to the domain.

The "undo" operation does not restore FNMB connections. They have to be recom-
puted.
Replace Domain: allows to replace a domain in an existing project. The main objective to use an
existing HEXPRESS project on similar geometries (domain). The replacement works as follows:
1. Open the original mesh project.

HEXPRESS™ 5-9
Domain Manipulation Domain Manipulation

2. Click on the Replace Domain icon (mesh should not be generated but mesh settings can be
present).

FIGURE 5.3.0-11 Domain replacement inputs

3. Select the new domain file.


4. Specify the comparisons options: Maximum allowed relative error (%) and Number of com-
parison iterations. Indeed, an iterative process will try to match different geometrical entities
by increasing the relative error of the geometrical comparisons.
5. Press Ok button to confirm.
6. Two scenarii can then happen:
• All entities are matched: in this case, HEXPRESS will just give the message that the
domain replacement was successful.
• Some entities did not match to each other (for instance, it is the case when a patch has been
splitted in two). In such scenario, the original and the replacement domains are represented
on the graphics area (the first one in red, the last one in blue) with a small shift between
them.

FIGURE 5.3.0-12 Domain replacement status

5-10 HEXPRESS™
Domain Manipulation Domain Manipulation

The menu is divided in two tabs: edges and faces matching. They are dedicated to manual match-
ing. The left column lists the faces/edges of the original domain whereas the right column gives the
list of the faces/edges of the replacement domain. Their number can be different (for instance, when
patches have been merged or split), in that case select one or several patches from the replacement
domain to match with one patch of the original domain (the contrary is not possible since we cannot
apply two different mesh settings to the same patch). For this purpose, the Match and Unmatch but-
tons are present below the lists.
When the Hide matched elements option is ticked, the geometrical entities which have been
already matched (automatically or manually) are hidden. Otherwise, matched entities are shown in
italic.

FIGURE 5.3.0-13 Hide matched elements button

The Zoom in to selected entity option will allow to perform an automatic zoom each time a new
element is selected.
Once all entities are matched, or once the user decides that enough entities are matched, pressing
the Ok button will finish the procedure. Otherwise, the Cancel button comes back to the original
domain.

The Undo button can cancel the latest operation.


The automatic replacement fails when the body has been moved (after a translation or
a rotation for instance). The manual matching will be the last option in that case.

Domain replacement stops if the number of blocks are not the same.
Undo: allows to undo the last domain manipulation action.

There is no redo button.


Check Domain: allows to have an overview of the geometry validity of the domain before meshing.

HEXPRESS™ 5-11
Domain Manipulation Domain Manipulation

FIGURE 5.3.0-14 Domain check validity: invalid domain (left) - valid domain (right)

Settings: allows to adapt the values for the feature angle and the shortest edge length after splitting.
By default the values are respectively 140 degrees and 0.0001 (based on imported geometry unit).
For instance, the surfaces with an angle of less than 140 degrees between them will not be available
for merging during the manual face merge action. To be able to merge more surfaces, reduce this
number. When defined, the automatic merging will:
• merge edges and faces presenting an angle over the feature angle.
• merge edges presenting a length under the shortest edge length.

FIGURE 5.3.0-15 Domain manipulation settings

5-12 HEXPRESS™
CHAPTER 6: Mesh Wizard

6-1 Overview
The mesh wizard helps to build an unstructured hexahedral mesh into a valid HEXPRESScom-
putational domain see section on page 4-3). Recall that a computational domain is represented by
a set of topological faces (surfaces) connected together by topological edges (curves). A topological
edge separates two topological faces and may be connected by topological vertices (corners). Each
topological face is represented by a triangulation which linearly approximates the input CAD
geometry. Similarly, topological edges are defined by a list of points. When a topological edge is a
loop, it is denoted cyclic.
The mesh wizard involves five different steps (see Figure 6.1.0-1). Each step must be successfully
accomplished before proceeding to the next:
• Initial mesh"
HEXPRESS creates an initial mesh surrounding the computational domain (see section
6-5 on page 6-7 for more information).
• Adapt to geometry
HEXPRESS adapts the initial mesh such that the cell sizes satisfy geometry dependent
criteria and removes afterwards cells intersecting the geometry or located outside the com-
putational domain (see section 6-6 on page 6-10 for more information).
• Snap to geometry
HEXPRESS projects the adapted mesh onto the geometry and recovers lower dimen-
sional features such as topological edges (curves) and topological vertices (corners). Since
the technology in HEXPRESS is based on a top-down approach, the adapted mesh does
not conform to the geometry. A simple projection on the surface would not preserve ridges
or sharp corners, that is why a unique technology has been developed inside of HEX-
PRESS to perform this capturing while ensuring the highest quality mesh. Additional
cells (buffer insertion) are also introduced during this stage to obtain a smoothly conform-
ing hexahedra mesh (see section 6-7 on page 6-33 for more information).
• Optimize
Though the snapping step already ensures a high quality mesh, some distorted cells (con-
cave or negative) may exist. A powerful mesh optimization tool is implemented in HEX-

HEXPRESS™ 6-1
Mesh Wizard Mesh Wizard Actions

PRESS that allows the conversion of concave cells in convex ones (see section 6-8 on
page 6-41 for more information).
• Viscous layers
Finally, HEXPRESS allows to insert layers of high aspect ratio cells tangentially to the
wall in order to correctly resolve boundary layers (see section 6-9 on page 6-44 for more
information).

FIGURE 6.1.0-1 Mesh Wizard

6-2 Mesh Wizard Actions


6-2.1 Check Action
The mesh wizard pad (see Figure 6.1.0-1) involves five boxes corresponding to the successive
mesh generation actions of HEXPRESS. An action can be checked or unchecked by left-clicking
on its corresponding box (Figure 6.2.1-1).

FIGURE 6.2.1-1 Checking/Unchecking an action

After an action is checked, the pop-up window containing all the corresponding parameters can be
accessed by left clicking on the button beside the check box. The user can then modify the proposed
default values. The "Initial mesh", "Snap to geometry" and "Optimize" parameters should generally
be left at their default values. The parameters related to the "Adapt to geometry" action should be
modified by the user to select suitable mesh adaptation criteria (see section 6-6 on page 6-10 for
more details). Furthermore, the insertion of viscous layers ("Viscous layers" action) is also depend-
ent on user choices (see section 6-9 on page 6-44 for more details).

6-2 HEXPRESS™
Mesh Wizard Actions Mesh Wizard

6-2.2 Execute Action


A checked action is executed during the next run of the mesh generation process. At the bottom of
the panel, the Start button (see Figure 6.2.2-1) launches the mesh generation process for all the
checked actions. The Step button steps through the first checked item and executes its correspond-
ing mesh generation action until it is completed. The Stop button allows to suspend the executed
action.

FIGURE 6.2.2-1 Start - Step buttons

After completion of the mesh generation process, consisting of executing all checked actions, the
color of the action boxes turns either green or red. A green box means that the mesh generation
action is completed successfully while a red color indicates that a problem occurred (the user is
referred to the different sections of this chapter describing in more details the various mesh genera-
tion actions for a description of potential problems). A red color button indicates a blocking prob-
lem. Depending on the circumstances, it may indicate a mesh quality problem, a difficulty during
the step or may simply indicate some potential problems in the existing domain file.
A mesh generation action can be deactivated, returning to the previous action, by left-clicking on its
corresponding box. If a mesh was generated by the previous action, it will be loaded and a valid
previous state of the mesh will be recovered.

When an action is performed, the obtained mesh is saved in a temporary file. This
means that after performing three successive actions, three intermediate meshes are
saved (i.e. suffix "_init.hex", "_adapt.hex", "_snap.hex",etc) and these are finally saved
in a subdirectory "/cache/" when saving the mesh (menu Project/Save or Project/Save
as...).
Example: Figure 6.2.2-2 presents a mesh wizard status in which the "Initial mesh", "Adapt to geom-
etry" and "Snap to geometry" steps were completed successfully.
By left clicking on the "Snap to geometry" action, this last action is deactivated and the mesh status
after completion of the "Adapt to geometry" action is recovered.

FIGURE 6.2.2-2 Mesh wizard with three actions completed

HEXPRESS™ 6-3
Mesh Wizard 2D/3D Mesh Generation

6-2.3 Common Action Buttons


When the action is checked for execution, the window for the selected action can be accessed by
direct-clicking on the button itself. All the respective windows are containing the same buttons at
the bottom as shown in Figure 6.2.3-1:

FIGURE 6.2.3-1 Common action buttons

• Ok. Exits the panel and saves the modifications on the parameters. This button is not avail-
able when action has been performed;
• Go. Saves the parameters and launches the mesh generation process for the concerned
action, if this last action is checked for execution. The panel is closed upon completion of
the task. This button is not available when action has been performed;
• Cancel. Exits the panel without saving any modification on the parameters.

6-3 2D/3D Mesh Generation


The HEXPRESS user interface toolbar (see section 2-4 on page 2-69) contains a specific entry
for choosing between the 2D and 3D mesh generation modes (Figure 6.3.0-1).

FIGURE 6.3.0-1 Grid generation mode selection

6-3.1 Geometry Constraints for 2D projects


The three dimensional mesh generation mode is the default selection. A two dimensional domain is
still three-dimensional, however it is then bounded in the Z-direction by two mirror planes (MIR),
parallel to the 2D mesh generation plane separated by an arbitrary distance. In this case, HEX-
PRESS will only generate one cell in the Z-direction.

Exactly two mirror (MIR) planes should be present (it cannot be more or less) per
block (domain).

To make a 3D computation consistent with a 2D computation, the FINE/Marine


flow solver scales the mesh thickness in the Z-direction to unity automatically. Conse-
quently, output forces and moments are always per unit length whatever the thickness of
the original mesh is. This is not the case in the FINE/Open flow solver. Hence the
thickness in Z-direction will affect the output forces and moments (as an advice, it is
preferable to use a thickness of 1).

6-4 HEXPRESS™
2D/3D Mesh Generation Mesh Wizard

FIGURE 6.3.1-1 2D domain: MIR faces (grey) - EXT faces (red)

The two dimensional grid generation mode must be selected before executing any
action on the mesh wizard. All specific mesh action parameters related to the Z-axis are
disabled in this mode. Therefore, changing mesh generation mode during the mesh gen-
eration will lead to an error message: the user is invited to delete completely the mesh to
change the mesh generation mode.

FIGURE 6.3.1-2 Error message when changing of generation mode

6-3.2 Geometry Constraints for axi-symmetric project


A two dimensional domain is still three-dimensional. HEXPRESS includes the possibility to gen-
erate an axi-symmetric mesh from a two dimensional domain. To perform such a generation, all the
steps below are necessary:
• Generate a 2D mesh (see section 6-3.1 on page 6-4 for the constraints on 2D mesh generation).
• In the Grid/Mesh transformation menu, apply an angle of 90 degrees to rotate the mesh
around the X or Y-axis so as to get 1 cell in the Y or X-direction respectively.
• (optional) HEXPRESS does not support prisms cells. Hence in case the project is centered on
the Z-axis, apply a translation so as to have a gap with the Z axis.

HEXPRESS™ 6-5
Mesh Wizard 2D/3D Mesh Generation

• In the Grid/Mesh transformation menu, set the angle and the number of cells in theta direc-
tion. Click on <Apply> to generate the axi-transformation (see section 2-3.3.5 on page 2-48).
• To create a rotation periodicity, first go to the Grid/Periodicity menu, and define a rotation
periodicity with an angle around Z axis (see section 2-3.3.5 on page 2-48). This angle should
correspond to the number of times the axi-symmetric should be repeated to get a 360 degrees
mesh.
• Then change MIR faces to SOL in the Grid/Boundary Conditions menu and go to the Grid/
Non Matching Connections menu to manually add a FNMB connection with periodicity for
rotating patches (see section 2-3.3.3 on page 2-35).

Axisymmetric transformation is applied on a generated 2D mesh rotated so as to be in


the Oxz plane with rotation axis along z.
A singular line is not allowed. To avoid singular line, the 2D mesh can be slightly
move from the origin but this may affect the mass flow if for instance the velocity is
imposed at the inlet and the mesh is too far from origin.
When imposing to small angle, that may introduce stiffness in the flow solver. While
imposing a too high angle may introduce error. Usually an angle of 5 degrees seems to be
a good compromise.

FIGURE 6.3.2-1 FNMB for Axi-symmetric mesh

Rotation axis has to be Z.

6-6 HEXPRESS™
Imposing Boundary Conditions Mesh Wizard

Automatic search does not work for axi-symmetric mesh.


FNMB connections displayed on 2D domain.

6-4 Imposing Boundary Conditions


Boundary conditions menu allows to define the type of boundary condition imposed on a patch or
a group of patches. The type of boundary condition for a patch can influence the mesh generation
process. For instance, a box from the Box adaptation will refine only Solid surfaces (SOL). The
other menu influenced by this choice is the Viscous layers menu: it will only list patches flagged as
Solid (SOL). In any case, they are mandatory for the flow solvers and should be correctly defined.
Please read carefully section 2-3.3.2 on page 2-30 to know more about how to work on this menu.

FIGURE 6.4.0-1 Boundary conditions window

6-5 Initial Mesh


6-5.1 Overview
HEXPRESS starts its mesh generation process from an initial mesh which encompasses the
whole computational domain. An initial mesh is automatically proposed (Figure 6.5.1-1) which
corresponds to an isotropic subdivision of the computational domain bounding box. The box can be

HEXPRESS™ 6-7
Mesh Wizard Initial Mesh

rectangular or cylindrical. The section Subdivide the domain bounding box is dedicated to rectan-
gular boxes and the section Create cylindrical mesh to initial cylindrical boxes. Furthermore, the
user is able to import his own unstructured mesh.

FIGURE 6.5.1-1 Initial mesh parameters

6-5.2 Domain Bounding Box Subdivision


6-5.2.1 Description
The bounding box of the computational domain is the parallelepiped which encloses the computa-
tional domain. It is automatically computed by HEXPRESS. To create an initial mesh, HEX-
PRESS computes the number of subdivisions in the X, Y and Z directions to generate isotropic
cells while limiting the total number of cells under the default number (1000).

6-5.2.2 Specify maximum total number of cells


The maximum number of cells of the initial mesh is controlled by parameter Nb of cells. The user
can modify the default value by entering different value. The number of subdivisions computed by
HEXPRESS will be such that the number of cells of the initial mesh matches as closely as possi-
ble the specified value.

6-5.2.3 Auto button


Clicking the Auto button computes a division which leads to a mesh with isotropic cells. In fact, the
specified maximum number of cells is considered the upper bound of the total number of cells in
the initial mesh.

6-5.2.4 Specify divisions of the bounding box


The automatic subdivisions choice made by HEXPRESS™ can be overridden by the user by enter-
ing a different value respectively in the subdivision along X, Y and Z axis. The corresponding total
number of cells is then displayed in the Nb of cells entry.

6-8 HEXPRESS™
Initial Mesh Mesh Wizard

6-5.3 Cylindrical Mesh


6-5.3.1 Description
The objective of the cylindrical mesh is to provide facilities to produce an unstructured cylindrical
mesh which can be a better initial mesh for domains which are aligned with cylindrical coordinates
system.

6-5.3.2 Sector Parameters


The sector parameters give the possibility to specify the revolution axis, the origin of the axis, the
minimum and maximum radius and the angle of revolution.

The revolution axis must be X, Y or Z axis.


The minimum radius must be bigger than 0 and smaller than the maximum radius.
6-5.3.3 Number of Divisions
It is possible to change the number of cells for the radial, tangential and axial directions. The Total
Number of Cells indicates the total number of cells for the initial mesh.

FIGURE 6.5.3-1 Initial cylindrical mesh

The refinement parameters menu is then modified according to the choice of an initial cylindrical
mesh: the target cell sizes X, Y and Z are replaced by R, Theta and Z in the adaptation criteria.

HEXPRESS™ 6-9
Mesh Wizard Adapt To Geometry

FIGURE 6.5.3-2 Refinement parameters menu for an initial cylindrical mesh

6-5.4 Import Mesh File


The user can import ( ) an external mesh as an initial mesh for the mesh generation process. Any
hexahedral mesh (i.e. suffix ".hex") converted to the HEXPRESS format is valid. A file name can
be directly specified or a file selection box is activated.

The mesh refinement algorithm used in HEXPRESS (see section 6-6 on page 6-10)
assumes that all cells of the initial mesh are oriented in the same way with respect to the
X, Y and Z axis. This is true for the initial mesh obtained by subdivision of the computa-
tional domain bounding box. However, this is not necessarily the case for a HEX-
PRESS mesh obtained after snapping to the geometry. Indeed, the additional cells
introduced during buffer insertion (see section 6-7 on page 6-33) may be randomly ori-
ented. In this situation, anisotropic refinement may lead to unexpected refinement pat-
terns and isotropic refinement should be enforced.

A converted structured project from IGG™ or AutoGrid5™ can be used as initial
mesh. Before converting, the IGG™ or AutoGrid5™ mesh should not contain undefined
patches (UND) otherwise the concerned patches will be considered as internal surface
and may lead to problem during adaptation step. All "UND" have to be changed in
another type (for example CON if at the connection between blocks) before loading into
HEXPRESS™.

6-6 Adapt To Geometry


6-6.1 Overview
This mesh generation action is probably the most important in terms of user interaction in HEX-
PRESS. Indeed, the parameters selection in this action directly dictates the computed mesh
obtained within HEXPRESS.
In this action, cells are successively subdivided such that specific geometrical criteria are satisfied.
Two classes of criteria are available:
• Curve criteria
Cells which intersect curves are considered as candidates for refinement. Three criteria are
implemented and are respectively based on:
— a proximity testing between curves
— a curve curvature measurement

6-10 HEXPRESS™
Adapt To Geometry Mesh Wizard

— a specification of cell target sizes on the curves


• Surface criteria
Cells which intersect surfaces and geometrical surfaces created with the Geometry menu
(more details in section 2-3.2 and section 2-5.2) are considered as candidates for refinement
(Figure 6.6.1-1). Three criteria are implemented and are respectively based on:
— a proximity testing between surfaces
— a surface curvature measurement
— a specification of cell target sizes on the surfaces
• Volume criterion (Box)
For this criterion, cells which are intersecting or located inside a three-dimensional volume
are flagged for refinement if their cell size is larger than some user prescribed target size.

FIGURE 6.6.1-1 Cells flagged for refinement by surface intersection

Proximity measurement saved in ".dist" file (distance adaptation criterion) is also


applied between solid surfaces and non solid surfaces, e.g. between a solid surface (SOL)
and any other surface type (MIR, EXT,...).
In order to limit the number of cells created during refinement, HEXPRESS subdivides cells ani-
sotropically as often as possible. A cell can thus be subdivided in 2, 4 or 8 cells (see Figure 6.6.1-2)

Subdivisions in 2 Subdivisions in 4 Isotropic subdivision

FIGURE 6.6.1-2 Refinement modes of a hexahedron

For the criteria involving the user specification of target sizes (along the X, Y and Z axis) such as
the volume criterion and surface target size criterion, the mechanism used for anisotropic refine-
ment depends on the orientation of the cell with respect to the Cartesian axes. In case of the default
initial mesh, the cells are simply oriented along the axes (X, Y and Z axis). Thus, cell sizes are inde-
pendently compared to the target sizes and the cell refinement is triggered accordingly along each
axis.

HEXPRESS™ 6-11
Mesh Wizard Adapt To Geometry

For surface refinement criteria, such as the distance and the curvature criteria, HEXPRESS com-
putes target sizes in a reference framework attached to the surface with base vectors formed by the
two surface tangents and normal. These target sizes are mapped onto the cell reference axis and
compared to the actual cell size in order to determine the type of refinement to apply to the cell. In
practice, cells which are oriented sufficiently parallel to surfaces may be subdivided anisotropically.
A cell, oriented at 45 degrees between the surface tangent and the cell principal axis, will never be
refined anisotropically.
The anisotropic refinement can be controlled by a parameter available in the list of expert parame-
ters of the surface adaptation criteria (see Figure 6.6.4-8 on page 6-26).
The Refinement and trimming parameters dialog box contains refinement and trimming parameters
as shown in Figure 6.6.1-3.

FIGURE 6.6.1-3 Mesh refinement and trimming parameters dialog box

6-6.1.1 Refinement
This action consists of successive refinements of the initial mesh in order to satisfy the adaptation
criteria (Figure 6.6.1-4).

FIGURE 6.6.1-4 Refinement of surface intersecting cells

6-12 HEXPRESS™
Adapt To Geometry Mesh Wizard

The refinement parameters (available when clicking on Parameters... button - Figure 6.6.1-3) are
organized into a notebook, divided into 4 panels qualified as global, curve adaptation, surface
adaptation and box adaptation parameters (see Figure 6.6.2-1).

6-6.1.2 Trimming
The trimming step removes all the cells intersecting or located outside of the geometry. HEX-
PRESS automatically finds the cell located inside the computational domain. At the end of the
process, a staircase mesh is obtained including all the interior cells (see Figure 6.6.1-5).

FIGURE 6.6.1-5 Trimming of surface intersecting cells

HEXPRESS can avoid trimming on planar surfaces: Cartesian mesh is preserved in


planar surfaces after execution of snapping and optimization steps, thus leading to
improve mesh quality (see section 6-6.6 for more details).

6-6.2 Global Parameters

FIGURE 6.6.2-1 Global refinement and trimming parameters

HEXPRESS™ 6-13
Mesh Wizard Adapt To Geometry

6-6.2.1 Maximum number of refinements


The adaptation process successively bisects the cells flagged for refinement in one or several differ-
ent directions. The sizes of the initial mesh cells are therefore divided by a factor 2N after N succes-
sive refinements. This may result in an exponential growth of the total number of cells in the mesh,
even though the refinement may be confined to some areas of the computational domain. This may
occur when the user poorly defines the target size of the cells on surfaces, which e.g. may have be
chosen too small, or the distance criterion may lead to an excessive number of cells in gaps. To
bound the number of cells, the user should set the maximum number of refinements to a reasonable
limit.

6-6.2.2 Advanced parameters


Several global expert parameters are available when clicking on Advanced >>> button (see
Figure 6.6.2-1) to finely tune the mesh adaptation process. Since HEXPRESS is optimized for
these defaults, any modification may therefore alter the success of the meshing process.

a) Enable refinement
By default this parameter is activated and it gives access to Curve, Surface and Box refinement
tabs. If not, the relevant tabs will be grayed out.

b) Enable trimming
By default this parameter is activated and it allows users to access the trimming parameters in Trim-
ming tab.

c) Refinement diffusion
When a cell is flagged for refinement, it is advisable to also tag its neighbours for refinement in
order to ensure a sufficiently smooth transition between fine and coarse cell regions. This process is
called "refinement diffusion". The integer value of the refinement diffusion parameter corresponds
to the number of layers of neighbours cells on which the diffusion of the refinement tag is applied.
For example, a value of 2 means that the neighbours of a cell are flagged for refinement together
with the neighbours of the neighbours. In addition, the type of diffusion applied in HEXPRESS
creates square shaped refinement regions for the sake of grid smoothness. Figure 6.6.2-2 shows the
diffusion of refinement to neighboring cells of surface intersecting cells. The default value is set to
2.

6-14 HEXPRESS™
Adapt To Geometry Mesh Wizard

( )

FIGURE 6.6.2-2 Diffusion of refinement from surface intersecting cells

d) Number of cells in gaps


The distance criterion (see section a) on page 6-23 for more details) is based on the computation of
the distance between closest neighboring surfaces. For each triangle defining the geometrical sur-
face, the distance to the closest triangles of a different surface is computed (saved in ".dist" file).
The distance is calculated by tracing a ray in the normal direction to the triangle, at its centroid. The
intersections of the ray with the other surfaces are computed giving the distance to the closest sur-
face. A target size for the cells intersecting a triangle is computed by dividing the closest distance
by the number of cells requested in gaps, given by this expert parameter.
The default value is set to 7, which means that 5 cells usually remain in the mesh after trimming
(Figure 6.6.2-3).

FIGURE 6.6.2-3 Number of cells in gaps

HEXPRESS™ 6-15
Mesh Wizard Adapt To Geometry

e) Minimum cell size


This parameter controls the minimum cell size in the mesh. It also acts as a control on the total
number of cells in the mesh. The default value is set to 0, meaning the parameter is not active by
default.

f) Maximum cell size


This parameters controls the maximum cell size in the mesh. During the refinement process, all
cells whose size is larger than the maximum allowable size are refined. The default value is a very
large number, meaning the parameter is not active by default

g) Prevent refinement of exterior cells


This function improves the refinement of Cartesian and unstructured meshes by preventing exterior
cells from further refinement, and thus, reducing the number of cells created during mesh adapta-
tion especially when the geometries are close to each other as shown in Figure 6.6.2-4. In other
terms, the algorithm will detect the external cells at each refinement step, avoid further refinement
of external cells whenever possible and so optimize the performance of the adaptation step.

FIGURE 6.6.2-4 Meshes with Prevent refinement of exterior cells deactivated (left) and
activated (right)

The final number of cells should not vary with and without this functionality. Only the
number of cells during the adaptation step changes.

This feature can decrease the RAM memory during the adaptation step. The gain is
more important for big cases. A speed up has also been observed for big cases.

h) Impose isotropic refinement near domain corners


This parameter imposes isotropic refinement near domain corners. Generally, it gives better mesh
quality. By default it is activated.

For cases with initial anisotropic meshes, imposing isotropic refinement near domain
corners usually gives better results if trimming is activated.

6-16 HEXPRESS™
Adapt To Geometry Mesh Wizard

i) Apply trimming by distance


When this parameter is disabled, HEXPRESS keeps all the cells that are very close to concave
dihedral angles in to the domain instead of removing them during trimming step. Thus, it gives
more robust snapping and better mesh quality near concave dihedral angles. In some cases, with the
given refinement level, HEXPRESScannot eliminate twisted cells by applying trimming by dis-
tance. However, by disabling this paramater the mesh is well captured. See Figure 6.6.2-5.

By default, this parameter is deactivated.


In the past, this parameter is enabled by default but not interfaced. Therefore, when
opening any old project, it will be activated by default.

FIGURE 6.6.2-5 Meshes with Apply trimming by distance enabled (left) and disabled (right)

6-6.3 Curve Refinement


In addition to the surface and volume refinement (see next two sections), the adaptation step allows
mesh refinement along domain edges to give users the ability to achieve a higher level of refine-
ment and capture edges more accurately, without the need to refine on the entire surface.
The Curve refinement tab gives access to the list of domain edges and to the edge refinement con-
trol parameters. The page is similar to the Surface refinement one.

The curve selection and the parameters controlling the edge refinement are the same
as for the surfaces. Refer to section 6-6.4 for more details.

HEXPRESS™ 6-17
Mesh Wizard Adapt To Geometry

FIGURE 6.6.3-1 Curve refinement

Best Practice:
This feature can be used in addition to Surface refinement to capture more accurately leading and
trailing edges of a wing or a blade, for instance. In this context, the refinement onto the surfaces can
be decreased and the number of refinements of the corresponding curves should be increased. As a
result, the number of cells will be less important for the same accuracy.

The number of refinement prescribed into the Curve refinement are disconnected
from the number of refinements of the surfaces from the Surface refinement menu. For
instance, for a surface with 4 curves, a number of refinements of 5 for curves and 3 for
the surface, will create 2 extra refinements on the curves.

6-6.4 Surface Refinement


The Surface refinement tab controls the mesh refinement process on a surface-by-surface basis.
These drivers involve three different adaptation criteria which can be activated or deactivated by
the user for each geometry surface with the following specific parameters:
• Distance criterion
• Curvature criterion
• Target cell sizes criterion

6-18 HEXPRESS™
Adapt To Geometry Mesh Wizard

FIGURE 6.6.4-1 Surface refinement

Usually, only solid surfaces ("SOL") are used for refinement but all surface types are
present in the list for particular cases (as internal flows for instance).
During each adaptation iteration, HEXPRESS detects all the cells which intersect the surfaces or
the geometrical surfaces created with the Geometry menu (more details in section 2-3.2 and sec-
tion 2-5.2). The criteria specified for a specific surface are then applied. This actually results in
comparing the cell size to the target either computed automatically by the system (for distance and
curvature criteria) or specified by the user (for target cell sizes criterion).

6-6.4.1 Surface Selection

a) Using surfaces list


A geometry surface can be selected by left-clicking on it. Furthermore, multiple selection is availa-
ble by combining <Ctrl> or <Shift> with left-click. <Ctrl>+ <a> combination selects or unselects
all surfaces. It is also possible to drag the mouse over the surfaces to select them.
The selected surfaces are highlighted in blue in the list and displayed in pink in graphics area.

HEXPRESS™ 6-19
Mesh Wizard Adapt To Geometry

b) By picking
Geometry surfaces can also be selected interactively by left-clicking on the surface in the graphics
area (<Ctrl> - left-click or left-click allow multiple selection by picking depending of the option
selected (<o>)).

The selected surfaces are displayed in pink whereas a potential surface for selection is in green
(mouse in on the surface but did not select it). <Ctrl> + <a> combination selects or unselects all
surfaces.

c) Rectangle Selection
An other possible selection is to draw a rectangle in the graphics area to select all surfaces which
are completely or partially inside the rectangle (depending of selected option <o>). For this pur-
pose, hold <Ctrl> key and drag the mouse with the left-click.

d) Select Identical
By right-clicking on a face or a group of faces, the action Select Identical will select all the faces
with the same settings from the list.

e) Using Select button


The Select button (also when right-clicking on a face in the graphics area), different selection types
are proposed to select faces:

• Select All Blanked allows to select all blanked faces in the graphics area.

6-20 HEXPRESS™
Adapt To Geometry Mesh Wizard

• Select Face By Area allows to select all the faces with an area in the range specified by the user.

• Select Face By Name allows to select all the faces whose name match the input name. A dialog
box is provided to input the name. The name can be a regular expression (i.e. if the input is
"channel*" all the faces whose name begins with channel will be selected)
• Select Geometrically Similar Faces allows to select all the faces with an area and a perimeter
(under a tolerance of 0.03) identical to the selected face in the list.
• Select Tangent Faces allows to select all the faces tangent to each other (neighbouring faces
presenting an angle above the specified angle), starting from the list of selected faces.

The shortcut <t> can be used to select the option directly.


f) Zoom In
By right-clicking on a face or a group of faces in the menu or in the graphics area, the action Zoom
in will zoom to all the selected faces.

g) Blank/Unblank
It is possible to completely hide faces (or groups of faces) and make them unselectable, by using the
Blank/Unblank functionality (right-click in the menu or in the graphics area) or by double clicking
on the check box on the left of the surface name. The check box actually shows the state of the sur-
face: unblank (ticked) or blank (unticked).

h) Invert Selection
It is possible to invert the current selection by using the Invert Selection functionality (right-click
in the menu or in the graphics area, or shortcut <i>).

i) Undo Selection
It is possible to undo the successive selections by using the Undo Selection functionality (right-
click in the menu or in the graphics area, or shortcut <u>).

j) Different settings highlight


In case two or more selected surfaces (or groups) have different settings, the settings which do not
match between the surfaces are highlighted in yellow in the interface.
This is only a visual information. It is not mandatory to modify them.

HEXPRESS™ 6-21
Mesh Wizard Adapt To Geometry

FIGURE 6.6.4-2 Different settings highlight

Pressing <Enter> in the highlighted input frame or pressing again the criteria will
apply the same setting for all surfaces.

6-6.4.2 Surface Grouping


If at least two surfaces are selected, the Group (or Ungroup) function is available (in the left panel,
below the surface list) or directly in the surfaces list or in the graphical area, by right-clicking.
Besides, the Group as BC function has been implemented to get the same surface groups from the
Boundary conditions menu (see section 2-3.3.2).

6-6.4.3 Active
A geometry surface can be activated or deactivated by left-clicking on the Active check button. An
inactive surface does not interfere in the mesh refinement process, i.e. the adaptation criteria which
were previously defined for this particular surface will no longer be applied to its intersecting cells
(it will appear in grey in the adaptation window).

FIGURE 6.6.4-3 Active check button

6-6.4.4 Refinement
The maximum number of refinement per surface can be specified by entering a value in the Refine-
ment sub-panel.

FIGURE 6.6.4-4 Maximum number of refinements for a selected surface

6-22 HEXPRESS™
Adapt To Geometry Mesh Wizard

The default value is an arbitrary large number such that the parameter is essentially inactive. In this
case, the global maximum number of refinements controls the adaptation process (see section 6-6.2
on page 6-13).
The maximum number of refinements per surface ultimately controls the refinement of cells inter-
secting that surface (if it is presenting a value lower than the global maximum number of refine-
ments). This parameter supersedes any other selected adaptation criteria. Fine tuning of this
parameter is useful when it may be difficult to determine the appropriate cell target size, or if the
distance and curvature criteria yield a prohibitive number of cells.

6-6.4.5 Adaptation Criteria

FIGURE 6.6.4-5 Surface adaptation criteria

a) Distance criterion

Description
The aim of the distance criterion is to allow enough refinements of the cells in order to fill any gaps
between very close surfaces with a sufficient amount of cells. HEXPRESS automatically pre-
computes the distances between nearby surfaces which are flagged as solid ("SOL") and/or any sur-
face type ("MIR", "EXT",...) and/or geometrical surfaces created with the Geometry menu. This
distance is computed and saved in a file with suffix ".dist" for each triangle defining the surface.

The distances between surfaces is re-computed when a modification of boundary con-


ditions occurs or if new geometrical surfaces are added in the computational domain.
The distance criterion works as follows: suppose we have a cell C in the initial mesh, and let SizeC
be the size of the cell C (let us consider only isotropic refinement for the sake of simplicity). Sup-
pose C is intersected by a surface S, and S uses the distance criterion. The intersection data for cell
C contains the list of triangles of S that intersect C and the minimal normal distance Dmin from
those triangles to other surfaces of the domain. Let Ngap be the value of number of cells in gap from
the General tab. The value Dmin/Ngap is compared with SizeC, and the cell is marked for refine-
ment as many times as it needed in order to make the size of children cells smaller than Dmin/Ngap.
The number of refinements based of the distance criterion can not be greater than the Max number
of refinements of the given patch.

Distance criterion works only for cells intersected by appropriate surfaces. If a cell lies
between two surfaces with active distance criterion and it is not intersected by them it
might be refined due to diffusion, but it will not be refined because of the distance crite-
rion. That means that the distance criterion does not guarantee Ngap of cells between sur-
faces.

HEXPRESS™ 6-23
Mesh Wizard Adapt To Geometry

A ray is traced from the centroid of the triangle parallel to the normal, its intersection with the other
surfaces is computed to give the distance to the closest surface. This distance is divided by the
required number of cells in gaps to provide a target cell size in the direction normal to the surface.
Cells which intersect the surface are given the computed target size. In fact, the target size is pro-
jected on the principal axis of the cell and compared to the actual cell size. If the cell is essentially
oriented parallel to the geometry, it is likely that it will be refined anisotropically tangentially to the
wall. The expert parameter Anisotropic extent (discussed on page 6-27) may be used to control the
trigger of anisotropic refinement depending on the cell orientation with respect to the surface.

Distance criterion works only for cells intersected by appropriated surfaces. If a cell
lies between two surfaces with active distance criterion and it is not intersected by them
it might be refined due to diffusion, but it will not be refined because of the distance cri-
terion. That means that the distance criterion does not guarantee the number of cells in
gap between surfaces.

How to apply?
The distance criterion is activated by left-clicking on the Distance check button (Figure 6.6.4-5).

b) Curvature criterion

Description
The aim of this adaptation criterion is to automatically compute a target cell size suitable for resolv-
ing curved surfaces. Smaller cells are expected where the geometry has high curvature. The number
of triangles intersected by a cell are used to measure the local curvature of the surface (Figure 6.6.4-
6). The following deviations are computed, after projecting the normals in the principal directions1
of the cell:

i
 j = max  n j  – min  n k j  , j = 1 ,2 ,3 

i
where n j corresponds to the jth component of the ith normal triangle.

The  j is a measure of the local curvature. The vector   1  2  3  is a point P in a 3D space


defined by the local principal axes of the cell. If the distance from P to the origin is larger than a
threshold value,  , than the cell should be refined. However, the direction of the refinement is cho-
sen on a component by component basis. Refinement in direction j is triggered if the following
condition is fulfilled:  j   , where  is the Anisotropic extent expert parameter discussed on
page 6-27.

1. We define the principal directions of a cell by the three vectors joining the centroids of the three pairs of
opposite faces.

6-24 HEXPRESS™
Adapt To Geometry Mesh Wizard

FIGURE 6.6.4-6 Cell intersecting triangles of a surface (Arrows are triangle normals)

How to apply?
The curvature criterion is enabled by left-clicking on the Curvature check button (Figure 6.6.4-5).

c) Target cell sizes criterion

Description
In addition to the previously discussed automatic adaptation criteria, the user can enforce his own
requirements by specifying his own target cell sizes for each geometrical surface. The size of a cell
intersecting a geometrical surface are compared to the prescribed user target and the cell is refined
until its actual size is lower than the target.

How to apply?
The target cell size criterion is enabled by left-clicking on the Target cell sizes check button
(Figure 6.6.4-5) and by specifying values for the cell size (Figure 6.6.4-7) in the X, Y and Z Carte-
sian axes (if 3D mesh):

FIGURE 6.6.4-7 Target cell sizes

Best practice: how to select the number of refinements?


Let’s call D the size of initial cell in the direction of interest, di the minimum cell size desired (to
capture the smallest geometrical elements in i-direction). The number of refinements in i-direction
ln  D  d i  D ni
ni can be estimated using n i = ----------------------- since ---- = 2 .
ln  2  di

Example (2D):
D = 1.0 (chord length = 1.0, 1 cell only)
dx = 1/50 = 0.02 (50 cells desired)
→ Resulting nx = 5.64
D = 1.0 (chord length = 1.0, 1 cell only)
dy = 0.1/15 = 0.0067 (15 cells desired)
→ Resulting ny = 7.23

HEXPRESS™ 6-25
Mesh Wizard Adapt To Geometry

Number of refinements N = max(nx, ny) = 7.23 ~ 8

d) Combining refinement criteria


The different refinement criteria can be combined together. The actual size of a cell intersecting a
surface is always compared to the target cell size computed either automatically (distance, curva-
ture) or specified by the user (prescribed target size).

6-6.4.6 Advanced parameters


Advanced parameters are accessed by left-clicking on the Advanced >>> button (Figure 6.6.4-8).

FIGURE 6.6.4-8 Surface refinement - Advanced parameters

a) Aspect ratio

Description
In expert mode it is possible to modify the maximum allowable aspect ratio (Figure 6.6.4-8) for a
cell intersecting a surface. The maximum aspect ratio is computed as follows:
-  - -----
- ------  - 
AR = max  ------ ------ ------ ------
      

where    correspond to the cell size in the respective principal direction of the cell. The
default value for this parameter is set to 2. It is not recommended to increase this default value
above the current value, indeed larger values may alter the robustness of the geometry capturing
algorithms and lead to poor quality meshes.

Influence on refinement
When a cell is triggered for refinement along some of its principal directions, the aspect ratio of the
resulting subdivided cells is pre-computed. If the aspect ratio exceeds the maximum allowable
value then the cell is triggered for refinement in the other directions in order to limit the aspect ratio
of the new cells. Notice that this aspect ratio constraint only applies to cells intersecting surfaces.
Cells which are refined by diffusion of the refinement tags are not subject to this constraint. There-
fore, after the trimming phase, the remaining cells may exhibit aspect ratio exceeding the prescribed
value.

b) Curvature ref factor (R/C)


This section gives details about the curvature based refinement. This utility is used to refine cells in
regions exhibiting local curvature. User can set the curvature refinement factor for particular sur-
faces of the domain so as to control the size of the cells.

6-26 HEXPRESS™
Adapt To Geometry Mesh Wizard

This criteria is used by HEXPRESS only when Curvature is used as adaptation cri-
teria.

Backward compatibility is not ensured with the previous expert parameter present in
v2.8 and before since the nature of the parameters completely changed. The user is
invited to define advanced adaptation criteria again.
It is a positive factor which controls the size of the cell in curvature based refinement for particular
refinement level. It can be calculated as:

F = RC

where,
R = Radius of curvature,
C = Size of the cell,
F = Curvature refinement factor.

In the curvature based refinement, the cell will be marked for refinement only if the cell size C is
greater than the value (R / F), noted as CF.
The value of CF will only depend upon the value of curvature refinement factor F, since the radius
of curvature will be constant.

Influence on refinement
If the value of F is increased then the value of CF will be less important: the cell size after refine-
ment will be decreased and hence the number of cells will be increased.

c) Anisotropic extent
This expert parameter controls the sensitivity of the anisotropic mesh refinement procedure. It con-
trols how well a cell must be oriented with respect to a surface in order to be triggered for aniso-
tropic refinement. For an application of the distance criterion, if a cell is perfectly oriented
tangential to a surface, the refinement will be triggered only tangentially to the wall, or normally to
the wall if the surface is highly curved.
This parameter is an angle specified in degrees and varying between 45 and 90 degrees. For values
close to 90 degrees, anisotropic refinement will occur only for cells which are well oriented with
respect to surfaces, on the contrary, for values close to 45 degrees, anisotropic refinement predomi-
nates over isotropic refinement. The default value of this parameter is 85 degrees.

Influence on refinement
The anisotropic extent parameter influences the refinement triggered by the distance criterion. The
distance criterion essentially computes a target cell size in the direction normal to the surface and
seeks to apply it to the intersecting cells. Therefore, for the well oriented cells with respect to the
surface, i.e. essentially tangential to the surface, refinement will be triggered to decrease the cell
size in the direction normal to the wall by subdividing the cell tangentially to the wall. The value of
the anisotropic extent parameter controls the maximum deviation that allows anisotropic refine-
ment.
As described in section b) on page 6-24, the curvature criterion measures the maximum deviation
between the normal components of surface triangles intersecting by a cell in order to compute an
estimate of the surface curvature. Three deviation values are computed for the three Cartesian axis.
If one deviation is large compared to the others, the curvature of the surface measured in this partic-

HEXPRESS™ 6-27
Mesh Wizard Adapt To Geometry

ular direction is much larger than in the other directions, which leads to a refinement of the cell in
this direction. The anisotropic extent parameter acts as a threshold value that controls refinement in
a particular direction.

d) Refinement diffusion
When a cell is flagged for refinement, it is advisable to also tag its neighbours for refinement in
order to ensure a sufficiently smooth transition between fine and coarse cell regions. This process is
called ‘‘refinement diffusion’’ and can be applied globally or locally.
By default the refinement diffusion is applied globally by specifying an integer value of the Refine-
ment diffusion parameter under the Global parameters thumbnail. In addition for each curve, sur-
face or volume box on which refinement parameters are applied, a local refinement diffusion
integer value can be imposed instead of the Global one.
The local refinement diffusion allows to impose a higher value of refinement diffusion on internal
surface as for the internal surface for Marine applications (for free surface capturing).

6-6.5 Box Refinement


The box refinement is based on the specification of a volume box or a cylindrical sector contained
within the computational domain.

FIGURE 6.6.5-1 Box refinement

For each iteration of the adaptation process, the cells inside or intersecting a volume box are tagged.
The size of the tagged cells is compared to user specified target cell size and refined if necessary.

6-28 HEXPRESS™
Adapt To Geometry Mesh Wizard

6-6.5.1 Volume Box


A volume box is a region of the computational domain defined by two points: the box lower left
corner and the box upper right corner or the box center and the box upper right corner.
A box is created by left-clicking on the New box button (see Figure 6.6.5-1) and by specifying its
lower left corner coordinates (Xmin, Ymin, Zmin) and upper right corner coordinates (Xmax,
Ymax, Zmax) or the box center (Xcenter, Ycenter, Zcenter) and the box upper right corner (Xmax,
Ymax, Zmax).

Toggle <c> allows to select the way to create the box.


A box can be modified or deleted by left-clicking and right-clicking on it in the list and select
respectively Edit Box or Delete Box (also left-clicking on the Delete button (see Figure 6.6.5-1)).

6-6.5.2 Cylindrical Sector


A cylindrical sector is a region of the computational domain defined by an origin, an axis, a radius,
an angle and a height.

A sector is created by left-clicking on the New sector button (see Figure 6.6.5-1) and by specifying
the origin and axis of the cylinder, the mimimum/maximum radius, start/end angles and height of
the sector.
A sector can be modified or deleted by left-clicking and right-clicking on it in the list and select
respectively Edit Sector or Delete Sector (also left-clicking on the Delete button (see Figure 6.6.5-
1)).

6-6.5.3 Active
A box or sector can be activated or deactivated by the user by left-clicking on the Active check but-
ton (see Figure 6.6.5-1). A deactivated box and sector do not influence the computational domain
refinement.

HEXPRESS™ 6-29
Mesh Wizard Adapt To Geometry

6-6.5.4 Parameters
The maximum number of refinement per box/sector can be specified by entering a value in the
Parameters sub-panel.
The default value is an arbitrary large number such that the parameter is essentially inactive. In this
case, the global maximum number of refinements controls the adaptation process (see section 6-6.2
on page 6-13).
The maximum number of refinements per box/sector ultimately controls the refinement of cells
intersecting the solid surfaces and included in the box/sector (if it is presenting a value lower than
the global maximum number of refinements). This parameter supersedes any other selected adapta-
tion criteria. Fine tuning of this parameter is useful when it may be difficult to determine the appro-
priate cell target size.

6-6.5.5 Target Cell Sizes


The target sizes of the cells intersecting or inside a box/sector can be specified by the following
entries:

FIGURE 6.6.5-2 Box adaptation target cell sizes

The target sizes (Figure 6.6.5-2) correspond to the cell size measured along the Cartesian X, Y and
Z axes.
Every cell within (if button Volumic activated) or intersecting the box/sector is tagged for potential
refinement. The size of these cells is compared with respect to target size and if it is larger than the
target, the cell is flagged for refinement in the corresponding direction. The refinement is aniso-
tropic.

6-6.5.6 Volumic refinement


The Volumic check button (see Figure 6.6.5-1) allows further control of the cells flagged for refine-
ment, i.e. the cells which are within or intersecting the box/sector. When this button is unchecked,
the refinement will only occur for cells which also intersect solid surfaces ("SOL"). If the button is
checked, the refinement applies to all cells included in the box/sector and in the computational
domain, i.e. all tagged cells can be potentially refined. In this case, the number of refined cells is
potentially much larger than in the case of an unchecked button.

For FINE™/Marine users, this parameter is checked by default when defining boxes
and sectors for refinement.

6-6.5.7 Refinement Diffusion


When a cell is flagged for refinement, it is advisable to also tag its neighbours for refinement in
order to ensure a sufficiently smooth transition between fine and coarse cell regions. This process is
called ‘‘refinement diffusion’’ and can be applied globally or locally.
By default the refinement diffusion is applied globally by specifying an integer value of the Refine-
ment diffusion parameter under the Global/Advanced tab. In addition for each box or sector on

6-30 HEXPRESS™
Adapt To Geometry Mesh Wizard

which refinement parameters are applied, a local refinement diffusion integer value can be imposed
instead of the Global value.
The local refinement diffusion allows to impose a higher value of refinement diffusion on selected
box or sector.

6-6.5.8 Interaction Volume-Surface Criteria


The volume and surface based criteria are essentially independent of each other. If the Volumic
check button (Figure 6.6.5-1) is inactive for a volume box or cylindrical sector, cells inside the vol-
ume box (or cylindrical sector) and intersecting a solid surface are candidates for refinement. How-
ever, the parameters specified for surface criteria, such as maximum number of refinements, do not
affect the box/sector refinement.

6-6.6 Trimming Parameters


The trimming step removes all the cells intersecting or located outside of the geometry. HEX-
PRESS automatically finds the cell located inside the computational domain.
HEXPRESS™ can avoid trimming on planar patches: Cartesian mesh is preserved after execution
of the adaptation step, thus leading to improve mesh quality.
• Used for trimming: If this option is selected, the patches of the domain for which this flag is set
will be used in the trimming operation.
• Not used for trimming: If this option is selected, the patches of the domain for which this flag
is set will not be used in the trimming operation.
When the user selects a flag from the combo box then the trimming behavior for the selected
patches is appropriately updated.

For MIRROR patches loaded from previous versions of HEXPRESS, the flag will
be automatically set to Not used for trimming in the patch list.

HEXPRESS™ 6-31
Mesh Wizard Adapt To Geometry

FIGURE 6.6.6-1 Trimming of surface intersecting cells

Only planar patches aligned with Cartesian axis are present in this menu.
The patch selector dialog box contains a list of the selectable patches. This list contains three col-
umns:
• Patch name: names of the selectable patches of the domain.
• Boundary conditions type: boundary conditions set for each domain patch.
• Trimming flag: trimming flag set to each domain patch.
The selection of faces can be performed in two ways.
— Selection of faces in list view:
In this mode, faces can be selected by simply clicking on the rows in the list view. If the user
selects a selected face, then this face will be unselected (toggle operation).
Multiple faces can also be selected by pressing the <Ctrl> key or the <Shift> key on the key-
board. All faces in the list can be selected by pressing the <Ctrl> + <a> keys. The selected faces
will be highlighted in the graphics window.
— Selection of faces in the graphics window:
This selection mode can be used for selecting faces of the domain in the graphics window with
the help of a mouse left-click. To select the face, simply click on the face highlighted in green
color that needs to be selected. The selected face will be highlighted in pink color. This selection
process can be cumulative, meaning that if the user selects the first face and then wants to select
another face with left-click or <Ctrl> + left-click (depending of the selected option <o>), that
face will be selected along with the previously selected face. All selected faces will be high-
lighted in pink color.
Faces which are selected in this selection mode will also be highlighted in the list view so as to
maintain the synchronization of the selection process in both selection modes.
It is possible to completely hide faces and make them unselectable, by using the Enable/Disa-
ble functionality (right-click in the menu or in the graphics area) or by double clicking on the
check box on the left of the surface name. The check box actually shows the state of the surface:
enabled (ticked) or disabled (unticked).

6-32 HEXPRESS™
Snap to geometry Mesh Wizard

6-6.7 Best Practice


6-6.7.1 Using distance surface criterion
The distance criterion measures the proximity between nearby surfaces and computes a specific tar-
get size such that a pre-defined number of cells remain in the volume after trimming. The distance
computation however only applies to different surfaces. HEXPRESS does not compute the dis-
tance between a surface and itself. Thus in case of geometries such as pipes defined by a single
cylindrical surface, the distance criterion is meaningless and does not influence mesh generation.
• ACTION: Impose target size OR Curvature on the surface.

6-6.7.2 No cell in domain after trimming


After the "Adapt to geometry" action is completed, the mesh could not contain any cell. This means
that HEXPRESS cannot find any valid cell inside the domain. In this case, HEXPRESS cannot
discriminate between the cells which are located inside of the computational domain and those
which are located outside or intersecting the geometry surfaces.
• ACTION: Perform additional refinements.

6-7 Snap to geometry


6-7.1 Overview
The aim of this fully automated mesh action is to project the staircase mesh obtained after the mesh
adaptation action on the surface to obtain a good quality body conforming mesh. In addition to a
simple projection on the geometry, this action involves sophisticated algorithms to recover lower
dimensional geometric features such as corners and curves in the mesh. These algorithms guarantee
that, when the mesh is projected onto the surface geometry, a mesh vertex is attached to each corner
of the geometry and that a path of mesh edges is attached to the curve.
In addition, the snapping of the mesh onto the geometry may create highly distorted elements. Lay-
ers of additional cells (buffer insertion) are introduced into the mesh to create a body conforming
mesh.
Finally, the mesh is smoothed by moving points on the surface and in the volume in order to obtain
a mesh with a good but not guaranteed quality.
Occasionally, the corner or curve capturing algorithms may fail to capture all the corners or/and
curves of the computational domain. When such a problem occurs, the mesh snapping action
resumes and exits with a specific error code which is reported in the report file (".rep") and the
action box in the mesh wizard turns red indicating that a major failure occurred. A failure to capture
a corner is usually an indication that a problem is present in the geometry, e.g. the surface triangula-
tion is not oriented properly (see section c) on page 4-17). A failure in the curve capturing can gen-
erally be solved by additional cell refinements in the vicinity of the curve, the parameters of the
adaptation action should be modified and this action resumed.

HEXPRESS™ 6-33
Mesh Wizard Snap to geometry

6-7.2 Advanced flags


By left clicking on the Advanced >>> button in the snapping parameters window, it gives access to
some expert parameters when Enable snapping action is checked.
The different options of the mesh snapping action (Figure 6.7.2-1) can be activated or deactivated
through check buttons. However, all steps should stay activated to obtain a good quality mesh.

FIGURE 6.7.2-1 Snapping parameters

6-7.2.1 Snap on surfaces


This algorithm projects the boundary of the volume mesh, which we call the surface mesh, onto the
geometry. It does not modify the coordinates of the mesh vertices but computes for each vertex of
the surface mesh a host geometry surface for projection.

6-7.2.2 Capture corners


The corner capturing algorithm determines a mesh vertex for attachment to each corner of the
geometry. This action is a precursor to the capturing of any curve in the geometry. The selection of
the capturing vertices is optimized to provide the highest quality mesh at the end of the mesh gener-
ation. In practice, several candidate vertices are tested for capturing a particular geometry corner. A
functional, based on geometry criteria, is optimized to select the appropriate one.

6-7.2.3 Capture curves


The curve capturing algorithm attempts to select a set of mesh connected vertices by mesh edges,
which defines a path in the mesh starting at a vertex connected to the origin corner of the curve and
ending at the end corner of the curve. This path is optimized similarly to the corner capturing algo-
rithm to yield the highest quality mesh at the end of the mesh generation.
Occasionally, problems with the curve capturing algorithm occur. This is usually related to a locally
too coarse mesh close to the corners, or the fact that several curves are very close to each other.
Usually, refining locally (adapt to geometry) resolves the problem.

6-34 HEXPRESS™
Snap to geometry Mesh Wizard

6-7.2.4 Projection on surfaces


This action is projecting the boundary vertices of the volume mesh onto the geometry. Vertices
attached to corners and curves are projected on these geometry entities while the other vertices are
projected on the surfaces. A painting algorithm is employed to determine the projection surface for
each vertex.
If a failure occurs in the capturing algorithms for the curve or the corners, the algorithm may lead to
an unusual projection pattern.

6-7.2.5 Buffer insertion


Once the mesh is correctly projected onto the geometry, with all corners and curves properly cap-
tured by mesh vertices, the buffer insertion algorithm is applied to recover a mesh with high quality
body conforming cells. Notice that the buffer insertion is bypassed when a problem occurs in the
capturing algorithms.

FIGURE 6.7.2-2 Mesh without buffer insertion (left) - with buffer insertion (right)

The projected mesh often contains highly distorted cells. Some facets of the surface mesh, with ver-
tices connected to the same curve, may look like triangles. These are actually degenerate quadrilat-
erals with three vertices projected onto a curve. The same pattern may also appear inside of the
volume. To overcome this situation and recover a high quality mesh, one or two layers of additional
cells are extruded from the surface mesh towards the inside of the computational domain
(Figure 6.7.2-2).
The buffer insertion algorithm introduces topologically additional cells, i.e. initially the cells
present a zero thickness, they are then inflated by application of smoothing.

6-7.2.6 Mesh smoothing


The mesh smoothing algorithm inflates the cells introduced by the buffer insertion algorithm. In
addition, it also slightly smooths irregularities which may have been produced by the projection
algorithm.
Nevertheless, it does not guarantee to provide high grid quality or even convex cells. It is not
uncommon that the mesh after smoothing contains a small number of negative or concave cells.
These cells are highly distorted and require the application of more sophisticated algorithms to be
transformed into convex elements presenting a good quality.

HEXPRESS™ 6-35
Mesh Wizard Snap to geometry

Number of iterations. The smoothing algorithm consists of successive displacements of the verti-
ces to the centroid of the cavity defined by the surrounding cells. This procedure is very common in
mesh generation and is similar to the solution of a Laplace equation whose unknowns are the coor-
dinates of the vertices. The default value of the number of successive passes is set to 25. Generally,
it should not be modified by the user.

6-7.3 Partial Curve Snapping


Snapping operation can be unsuccessful because of curves capturing failure. In some cases, it may
be useful to ignore such curves for further operations.

FIGURE 6.7.3-1 Curve Snapping menu

Snapping option for every curve can be chosen between the three following possibilities:
• Must be captured (default option): means that if the curve is not captured, then mesh gen-
eration process stops,
• Must be skipped: means that the curve must not be captured,
• Can be skipped: means that if the curve cannot be well captured in 3D cases, instead of
skipping the whole curve HEXPRESS™ will try to capture some segments from the curve
and skip the other ones. For 2D cases, if the curve cannot be well captured, it will be
skipped.
The <Ctrl> key can be used in combination with the left mouse button to select several curves. The
<Shift> key can be used in combination with the left mouse button to select a list of curves in the
chooser. In addition, by right-clicking on a curve in the list, the action Select Identical will select
all the curves with the same settings from the list and the action Zoom in will zoom to all the
selected curve.
Interactively in the graphics area the curves can be selected depending of the selection options
(shortcut <o>):
• <Ctrl> + left-click or left-click,

6-36 HEXPRESS™
Snap to geometry Mesh Wizard

• Draw a rectangle in the graphics area to select all curves which are completely or partly
inside the rectangle. For this purpose, hold <Ctrl> key and drag the mouse with the left-
click.
The shortcuts <u>, <i> and <h> allow to respectively undo successive selections of curves, invert
current selection of curves and display hints in the graphics area. There are information about
mouse button bindings and shortcuts

6-7.4 Buffer Insertion


This section gives the details of buffer insertion settings utility for domain curves. This utility is
used to set different types of buffer insertion to domain curves, such as type I and type II.

FIGURE 6.7.4-1 Buffer Insertion type

Depending upon the buffer insertion type settings to domain curves, the buffer insertion in snapping
process of the mesh generation will be affected.

FIGURE 6.7.4-2 Buffer Insertion menu

HEXPRESS™ 6-37
Mesh Wizard Snap to geometry

There is a limitation of the method: if more than 3 curves are connected to a domain vertex, and one
of the curves is of type I, then all other curves connected to the vertex will be of type I too. Hence it
is not always possible to get the pattern of type II, even for convex edges and type I for concave
edges. In this case, HEXPRESS will automatically set the buffer of this problematic edge to the
default type and a message will be written in report file. Once the snapping is performed, the buffer
insertion menu displays the type effectively used during the snapping.
This menu shows the list view which contains all the edges present in the domain. The edges can be
selected from the list view in two ways:
— Selection by list view:
This mode provides the selection by mouse left-clicking on the name of the curve. The toggle
operation can also be used. The <Ctrl> key can be used in combination with the left mouse but-
ton to select several curves. The <Shift> key can be used in combination with the left mouse
button to select a list of curves in the chooser. Multiple selection by mouse dragging is also pro-
posed.
By right-clicking on a curve, the action Select Identical will select all the curves with the same
settings from the list.
By right-clicking on a curve in the menu, the action Zoom in will zoom to all the selected curve.
— Selection in graphics window:
In this mode of selection, the edge can be selected by clicking on the edge in the graphics area.
If user left clicks on a selected edge, the edge will be deselected. Similarly, <Ctrl> + left-click
on the edge will select the multiple edges. The selected edge in the graphics area will be high-
lighted in the list view, so as to maintain the synchronization in between selection through list
view and through graphics window. The selected edge will be highlighted in the yellow color.

6-7.5 Best Practice


How to handle snapping failures in HEXPRESS? This check list will provide the necessary
actions to be performed by the user to find the reason of the possible snapping failures and how to
handle them.

a) Which entity has not been snapped correctly?


The different reports inform about the type of entities that failed to be captured including the IDs.
They also provide the names of entities which are connected to it. This report can be found at sev-
eral locations:
1) Icon at the top right of the interface (see section 2-4).
2) In the shell (only if HEXPRESS has been launched with “-print” argument).
Example: Topological edge 72 FAILED capturing.
shared by face ID=12 (Mir)
shared by face ID=37 (Bulb_B2)

Snapping problems can appear on vertices, edges, faces or can be due to holes in the
mesh.

b) How to locate them?


— Blue marks: a blue mark is displayed on the entities which are not snapped correctly just
after snapping failure. They are shown in the graphics area as well as in the adaptation and
snapping menus.

6-38 HEXPRESS™
Snap to geometry Mesh Wizard

FIGURE 6.7.5-1 Buffer Insertion menu

Curve marked as can be skipped in the Curve Snapping menu are highlighted in
blue as well.
The blue curves are removed from display under one of the following circumstances:
•The user unticks the Initial Mesh step (this also deletes the mesh).
•After the adapt step has been completed.
•After the optimization step has been completed.
•If snapping step has been completed successfully and no curves failed to be captured.

— Face viewer: the Face viewer dialog box contains information about patch names and IDs
(see section 2-5.5.2).

c) How to handle these issues?


1) Connectivity problem
Use the Check Domain button in Domain manipulation menu (described in section 5-3) to see if
vertices connected to more than 3 edges are present. The table below presents the current topology
constraints on the domain definition. HEXPRESS cannot capture a cyclic curve defined by a sin-
gle corner, i.e. a curve which starts and ends at the same vertex. Such a curve should be split in two
pieces by modifying the geometry or by removing this corner. This can be done through the
Domain manipulation menu (see Chapter 5). The introduction of relaxed cells can also solve this
issue: the geometry will be slightly modified but it will help HEXPRESS to overcome this situa-
tion (see section 6-8.2.1 on page 6-43).
HEXPRESSalso has difficulties in properly capturing a corner with a degree equal or higher than
4. The degree of a corner is equal to the number of connected edges. Internal nodes of the mesh
have a degree at most equal to 6. The trimming algorithm leaves some nodes exposed for surface

HEXPRESS™ 6-39
Mesh Wizard Snap to geometry

capturing. The highest degree of such nodes is therefore 6, but in general vertices with degree larger
than 4 are rare and may not be present close to a corner as candidates for capturing, which may
jeopardize the capture of high degree corners.
TABLE 7. Topology constraints

If this kind of vertices are present:


- Try to merge problematic edges/vertices in Domain manipulation menu. And if not possible:
- Split the edge in the problematic zone and set the problematic part to must be ignored in the
expert parameters of the Curve Snapping menu (section 6-7.3).
Cyclic curves are not well captured by HEXPRESS. In this case, split the cyclic curve at the
kinks in order to create corners which will be captured by HEXPRESSor improve the triangula-
tion in the CAD software.
2) Faces not captured
- Add refinements in adaptation menu. To do so, check visually after adaptation step if all faces
have enough cells around them to be captured. At least 5 cells in all direction should be present. If
there is no cell at all between close surfaces, add distance criteria to the corresponding surfaces.
- Check triangulation settings: check visually that all faces are well discretized by showing the tri-
angulation on each surface. Otherwise, go back to CAD manipulation or to the CAD software to
improve them.
3) Sharp edges
- Add curve refinements in adaptation menu.
- Split the edge in the problematic zone and set the problematic part to must be ignored in the
expert parameters of the snapping step.
4) Holes detected
It sometimes happens that if the mesh refinement is not sufficient then the mesh contains holes.
That can happens, for example, in narrow gaps or in the vicinity of acute dihedral angles. In such
situations HEXPRESSwill report the presence of holes in the mesh and for each hole it identifies

6-40 HEXPRESS™
Optimization Mesh Wizard

two relevant domain faces. The holes detected will be shown in blue wire form in the graphics area.
Information for the holes will also be reported in the status line and report. The best way to check a
particular hole is to highlight two relevant domain faces in different colors and use zoom in and
rotation as shown in the example shown in Figure 6.7.5-2.

FIGURE 6.7.5-2 Holes visualization after snapping step

If there is a hole in the mesh attributed to a pair of domain faces and a domain edge
common to the same pair of faces is not captured then the mesh faces near this non-cap-
tured edge will be mistakenly identified as faces forming a hole.

Holes in the mesh attributed to a single domain face (i.e. a domain face close to itself)
can not be visualized because such holes are not detected.

6-8 Optimization
6-8.1 Overview
The mesh obtained after the snapping action may involve poor quality cells usually located close to
corners and curves. Some of these cells are concave or may even present a negative volume. A cell
is defined as concave (the cell looks like a "boomerang") if the Jacobian of the transformation to a
unit cube has at least one zero value for a point located inside of the cell. In practice, the concave
property is tested by checking the negativeness of the volume of the tetrahedral subdividing the cell
(see Figure 6.8.1-1). This kind of subdivision is, of course, not unique and should therefore be cho-
sen carefully.

HEXPRESS™ 6-41
Mesh Wizard Optimization

FIGURE 6.8.1-1 The cell on the left is concave because tetrahedron abcd has a negative
volume. The cell on the right is on the contrary convex.

The number of poor quality cells can be checked using the mesh quality analysis tool (see section 2-
3.3.4 on page 2-42).
HEXPRESS provides specific algorithms to convert concave cells to convex ones by slightly dis-
placing their vertices. A novel approach is also implemented to improve the orthogonality of con-
vex cells.

The jacobian transformation matrix transforms a skewed parallelepiped to a unite


cube. It is defined by the following relation:

In most instances, convex cells are important to ensure the stability and the robustness of a flow
solver. Mesh adaptation applied to concave cells may also create negative children cells.
Negative cells should be prohibited. Usually, HEXPRESS is able to deliver a mesh without any
negative cell. However, the presence of negative cells is usually a sign of an inadequate choice of
cell sizes in a geometrical complex region. Further mesh refinements (adapt to geometry) will usu-
ally solve the problem.
The removal of all the concave cells of the mesh and their transformation to convex hexahedral are
usually accomplished. However, for some intricate geometries, the number of remaining concave
cells may be of the order of 1 to 5 per million cells. This depends on the adequacy of cell sizes with
respect to geometry length scales.

6-8.2 Advanced
The Advanced parameters of the "optimization" step are accessed by left-clicking on the Advanced
>>> button.

6-42 HEXPRESS™
Optimization Mesh Wizard

FIGURE 6.8.2-1 Optimization options panel

6-8.2.1 Relaxing Geometry


The aim of the present option is to facilitate the elimination of a small amount of invalid cells dur-
ing optimization which can not be removed otherwise. This can be achieved by allowing the opti-
mizer to move the surface mesh vertices away from the domain boundary, which is not respected
anymore, meaning that the surface mesh is not strictly followed. In that case, the optimizer has
more freedom and consequently is often able to convert the rest of invalid cells to valid ones.

FIGURE 6.8.2-2 Relaxed geometry

The number and the visualization of the relaxed cells can be done through the mesh
quality menu (see section j) "Relaxed Cells" on page 2-46) after the optimization step.

HEXPRESS™ 6-43
Mesh Wizard Viscous Layers

6-8.2.2 Other Parameters


The optimization proceeds iteratively until all concave cells are transformed to convex ones or until
a maximum number of iterations is reached. However, several parameters can be changed to define
how hard the optimization will be to improve the mesh quality.
In order to increase the number of optimization iterations and remove few remaining negative and/
or concave cells in some circumstances, the Max nb of external optimization loops value can be
thus increase.
The second parameter is the maximum number of invalid cells during an external optimization
loop. During one optimization loop, HEXPRESSstops if the number of invalid cells is higher
than this parameter and the optimization step is failed.
Essentially, optimizer makes its job in two steps. First, it eliminates invalid cells. Second, it
improves the quality of the mesh as follows: it computes the quality of all cells using the cell
orthogonality and the cell's face flatness as the quality criteria. Then optimizer picks 3% of cells
with worst quality and applies 7 optimization iterations to them. Max nb of final optimization
iterations and Percentage of vertices to optimize represent the two aforesaid parameters. Increas-
ing these two values allows to improve mesh quality in exchange of longer optimization time. The
default values 3 and 7 is a good compromise between quality and performance.
Extra optimization iterations can be applied for the cells with orthogonality smaller than some spec-
ified value. Max nb of orthogonality optimization iterations and Minimal orthogonality
threshold control the execution of these extra optimization iterations. For instance, if Max nb of
orthogonality optimization iterations is 5 and Minimal orthogonality threshold is 15, then the
optimizer will execute 5 additional optimizing iterations over all the cells with orthogonality less
than 15 degrees.

The CPU time can be significantly increased with increasing optimization iterations.
It is not guaranteed that extra optimization iterations always give better mesh quality.
Limitation: possible improvements of mesh quality can be lost after insertion of vis-
cous layers.

6-9 Viscous Layers


6-9.1 Overview
HEXPRESS proposes a very specific approach for the insertion of layers of large aspect ratio
cells to accurately resolve boundary layers. The technique is based on successive subdivisions of
the cells connected to the walls, this contrasts with other techniques which insert layers by extru-
sion. This refinement technique has the advantage of robustness and speed.
Any number of high aspect ratio cells can be introduced by anisotropic refinement tangential to the
surfaces.
The settings of the "viscous layers" action are accessed by right-clicking on the corresponding box
(when action checked) in Mesh Wizard and left-clicking on Edit.

6-44 HEXPRESS™
Viscous Layers Mesh Wizard

6-9.2 Global Menu

FIGURE 6.9.2-1 Global menu for a fixed first layer thickness method

6-9.2.1 Global parameters


Two parameters can be set globally to all surfaces at the same time. Once the values are correct,
pressing the Apply to Active Surfaces button will apply these settings to the active surfaces only in
the Surface tab.

a) Fixed first layer thickness


The first parameter to be specified is the thickness of the first layer.
A tool allows to "best estimate" the first cell size (First layer thickness) that should be inserted at
the solid wall and the recommended number of layers (Number of layers) to reach an optimal
inflation. When clicking on the Compute button, a new dialog box allows to compute the first cell
size on the wall. The required inputs are:
• y+
• Reference length
• Kinematic viscosity of the fluid (the heaviest fluid in case of multi-fluid simulation) and the
reference velocity or the Reynolds number.
The value of the first cell size is then appearing at the bottom as an indication and can be imposed
as First layer thickness when clicking on Apply button.

HEXPRESS™ 6-45
Mesh Wizard Viscous Layers

b) Fixed stretching ratio


The Stretching ratio  , defines the thickness ratio of the layers in the direction normal to the wall:
hi + 1
 = ----------
hi

The evolution of the size of the layers normal to the wall is therefore controlled by a power law:
i
h i =  h 0 ,i = 0 n – 1

6-9.2.2 Control parameters


This menu gives the choice between two different methods of viscous layers insertion. Their dis-
tinction is based on a first layer thickness which can vary of not.

a) Fixed first layer thickness method


The main constraints attached to the quality of viscous layers insertion are as follows:
• fix a user-defined cell size at the wall,
• limit the stretching ratio between neighboring cells in the direction normal to the solid sur-
faces,
• insert a “representative” number of layers to mimic the boundary layer.
These constraints can however be contradictory in some circumstances, depending upon the thick-
ness of the buffer layer, since it cannot be controlled during the mesh generation process.
As a result, the user must be cautious in the selection of the three inputs defined here above, so as to
guarantee that:
• all viscous layers can be included in the buffer layer,
• the stretching ratio between the cells at the frontier of the buffer layer is acceptable.
In case not all viscous layers can be included in the buffer layer, the size of the first cell at the wall
is not longer preserved and an identical cell size is selected for all viscous layers. The cell size is
then defined as the thickness of the buffer layer locally, divided by the number of layers selected by
the user.
Such a behavior can possibly lead to some degradation in the quality of the mesh inside and across
the buffer layer, and can drive to some convergence difficulties and/or inaccuracies in that area (see
Figure 5.9.2-3).

6-46 HEXPRESS™
Viscous Layers Mesh Wizard

FIGURE 6.9.2-2 Degradation of mesh quality after insertion of viscous layers

This constraint is overcome with the inflation and insertion method of the viscous layers. In that
case, the inflation algorithm can be activated and the cells over a number of layers close to the solid
boundaries are progressively deformed so as to adapt to the user constraints. As a result, not only
the thickness of the buffer layer is modified, but deformation can also progress inside the inviscid
core so as to maintain a satisfactory stretching factor

FIGURE 6.9.2-3 Viscous layers inflation and insertion process

This inflation process ensures that the first cell size, stretching factor and number of layers selected
by the user to fill in the viscous layers can be satisfied. However, the user is allowed to relax this
constraint and define a range in the desired number of layers (instead of a fixed value). The number
of layers is then said “floating”, and be freely selected by HEXPRESS within a prescribed range
selected by the user.
Relaxing such a constraint can be largely beneficial since the inflation is strongly related to 3D
Laplacian smoothing algorithms, which makes this process iterative and CPU consuming with
respect to basic viscous layer insertion (without inflation).

HEXPRESS™ 6-47
Mesh Wizard Viscous Layers

b) Variable first layer thickness method

FIGURE 6.9.2-4 Global menu for a variable first layer thickness method

This method, once activated in the global tab, allow the variation of the first layer thickness. It
requires three user-inputs for each: a geometric expansion factor, a number of layers and an aspect
ratio of the viscous layer that is adjacent to the surface-mesh.
Such a method would allow a smoother and better insertion of the viscous layers, for any refine-
ment level. Currently, in case a surface contains several refinement levels, the inflation will be
working for the bigger cells, and then the viscous layers will be crushed into the first layer of the
Euler mesh for lower refinements. Such effect would not occur anymore as the first layer thickness
will be depending upon the local refinement level.
See section 6-9.3.4 for the details about the required inputs for each surface or groups of surfaces.
The inflation is always active for this method. Please read previous section for more information
about the inflation method.

In the advanced sub menu (Advanced >>> button), the Inflation factor has been
introduced to control the inflation speed performed at each iteration. Hence, if this factor
is high, the inflation runs fast but can break down. On the contrary, if the factor is
smaller, the inflation is slower but more robust. The default is the optimum value.

6-48 HEXPRESS™
Viscous Layers Mesh Wizard

6-9.3 Surface Settings

FIGURE 6.9.3-1 Viscous layer insertion parameters for the fixed first layer thickness method

The viscous layer parameters are available when clicking on Active button (Figure 6.9.3-1).

6-9.3.1 Surface Selection


The viscous layer insertion widget allows selection of all the solid surfaces present in the model.
Notice that high aspect ratio layers can only be inserted on geometric surfaces with boundary condi-
tion of type "SOL".

The shortcut <h> in the graphics area will display hints. There are information about
mouse button bindings and shortcuts.

a) Using surfaces list


A geometry surface can be selected by left-clicking on it. Furthermore, multiple selection is availa-
ble by combining <Ctrl> or <Shift> with left-click. <Ctrl> + <a> combination selects or unse-
lects all surfaces. It is also possible to drag the mouse over the surfaces to select them.
The selected surfaces are highlighted in blue in the list and displayed in pink in graphics area.

b) By picking
Geometry surfaces can also be selected interactively by left-clicking on the surface in the graphics
area (<Ctrl> + left-click or left-click allow multiple selection by picking depending of selected
option (<o>)). The selected surfaces are displayed in pink whereas a potential surface for selection
is in green (mouse in on the surface but did not select it). <Ctrl> + <a> combination selects or
unselects all surfaces.

HEXPRESS™ 6-49
Mesh Wizard Viscous Layers

c) Rectangle Selection
An other possible selection is to draw a rectangle in the graphics area to select all surfaces which
are completely or partially inside the rectangle depending of the option (<o>). For this purpose,
hold <Ctrl> key and drag the mouse with the left-click.

d) Enable/Disable
It is possible to completely hide faces (or groups of faces) and make them unselectable, by using the
Enable/Disable functionality (right-click in the menu or in the graphics area) or with shortcut <b>
or by double clicking on the check box on the left of the surface name. The check box actually
shows the state of the surface: enabled (ticked) or disabled (unticked).

e) Select Identical
By right-clicking on a face or a group of faces, the action Select Identical will select all the faces
with the same settings from the list.

f) Zoom In
By right-clicking on a face or a group of faces in the menu or in the graphics area, the action Zoom
in will zoom to all the selected faces.

g) Invert Selection
It is possible to invert the current selection by using the Invert Selection functionality (right-click
in the menu or in the graphics area, or shortcut <i>).

h) Undo Selection
It is possible to undo the successive selections by using the Undo Selection functionality (right-
click in the menu or in the graphics area, or shortcut <u>).

i) Different settings highlight


In case two or more selected surfaces (or groups) have different settings, the settings which do not
match between the surfaces are highlighted in yellow in the interface.

This is only a visual information. It is not mandatory to modify them.

6-50 HEXPRESS™
Viscous Layers Mesh Wizard

FIGURE 6.9.3-2 Different settings highlight

Pressing <Enter> in the highlighted input frame will apply the same value for all sur-
faces.

6-9.3.2 Surface Grouping


If at least two surfaces are selected, the Group (or Ungroup) function is available (in the left panel,
below the surface list) or directly in the graphical area and the surfaces list, by right-clicking.
Besides, the Group as Adapt function has been implemented to define the same surface grouping as
the one from the Surface adaptation menu.

6-9.3.3 Active
A selected surface can be activated or deactivated for viscous layer insertion by left-clicking on the
Active check button (Figure 6.9.3-1).

6-9.3.4 Parameters

a) For fixed first layer thickness method


Three parameters have to be set by the user to correctly insert viscous layers: First layer thickness,
Stretching ratio and Number of layers. For the description of the first two, please read section 6-
9.2.1.
Concerning the Number of layers, the user must specify the number of viscous layers to be intro-
duced in the first cell close to the solid surface.
When clicking on the Apply button, the "appropriate number of layers" based on the First layer
thickness and Stretching ratio can be imposed as Number of layers. This "appropriate number of
layers" is a proposal based on empirical laws. It could be not respected during the inflation method.

The "appropriate number of layers" can be computed only when an optimized mesh is
available (otherwise, the symbol "NA" is mentioned instead of a number).

When the imposed three parameters are generating viscous layers that are going
locally out of the first cell size close to the solid wall, this last cell will be uniformly split
respecting only the number of viscous layers imposed by the user (Figure 6.9.3-3).

HEXPRESS™ 6-51
Mesh Wizard Viscous Layers

FIGURE 6.9.3-3 Viscous Layer Insertion

b) For variable first layer thickness method

FIGURE 6.9.3-4 Surface settings for fixed first layer thickness method

Viscous layers are inserted thanks to three input parameters:


• the Aspect ratio of the surface-mesh layer that is adjacent to the surface-mesh,
• a factor of Geometric expansion in cell height,
• the Number of layers.
Layer insertion by aspect ratio is computed one layer at a time using a simple marching scheme.
Similarly, each layer is computed one node at a time. The surface-mesh is the mesh onto the solid
patches. Figure 6.9.3-5 shows the calculation of the first layer thickness D0 thanks to the formula:

L0
D 0 = ---------
-
AR 0

6-52 HEXPRESS™
Viscous Layers Mesh Wizard

with AR0 the aspect ratio of the surface-mesh layer and L0 the average of the edges size connected
to the node where the insertion of the first layer is performed. L0 is computed with the formula:
N

 a0i
L 0 = i----------------
=0 -
N

with N being the number of edges connected to the node.

FIGURE 6.9.3-5 Representation of the insertion of the first layer

Then the next layer will be computed by the same method, except that the aspect ratio ARi evolves
thanks to the formula:

AR i + 1 =  AR i   f

with i being the layer number and f the geometric expansion.


As illustrated here below on a 2D simple case, the resulting thickness of the layer containing all vis-
cous layers will be approximately equal to "1.5 times a" with a being the size of the connected edge
on one node of the surface-mesh.

FIGURE 6.9.3-6 2D representation of the variable first layer thickness concept

6-9.4 Troubleshooting
The activation of the inflation method in the Graphical User Interface does not necessarily mean
that the inflation algorithm will be executed. Inflation is only necessary and active in cases where
the combination of the first cell size, stretching factor and number of layers do not match with the

HEXPRESS™ 6-53
Mesh Wizard Viscous Layers

thickness of the buffer layer. Therefore, in case the constraints fixed on these 3 parameters can be
fulfilled without the need to inflate the buffer layer, the inflation algorithm will not be executed,
whether inflation is or not active in the graphical user interface.
Effective execution of the inflation algorithm can however be controlled looking into the shell at
the average ratio real-to-target cell size. This parameter defines the average ratio between the cur-
rent size of the buffer layer and some target value that HEXPRESS will try to reach iteratively
during the inflation process. In any case, inflation will be effective only if the ratio is smaller than 1.
In other cases, the buffer layer thickness is large enough to insert the viscous layers and insertion
will proceed directly without inflation. This process is usually very quick with comparison to infla-
tion.

FIGURE 6.9.4-1 Information in the shell when inflation will be effectively executed

FIGURE 6.9.4-2 Information in the shell when inflation will not be executed

An other situation can happen: inflation is activated and performed because the “Aver-
age ratio real-to-target size” is smaller than 0.9 has mentioned in Figure 6.9.4-2, but the

6-54 HEXPRESS™
Viscous Layers Mesh Wizard

resulting mesh after optimization of the mesh with viscous layers is not of acceptable
quality because there are concave, twisted or negative cells remaining. Therefore the
inflation is cancelled and the normal viscous layers are inserted.
After the inflation, some mesh surface vertices might not be snapped to the geometry anymore. In
this context, mesh surface vertices mean the grid points on the geometry boundary. This limitation
is illustrated in Figure 6.9.4-3.

FIGURE 6.9.4-3 Vertices that are not snapped after inflation

When HEXPRESS detects these unsnapped vertices, a warning as shown in Figure 6.9.4-4 will
appear in the shell and in the report file to inform the user. The geometry edges with unsnapped ver-
tices will be listed as well. To avoid this problem, users can add additional refinements in the area
where a deviation from the geometry is found.

FIGURE 6.9.4-4 Report file

HEXPRESS™ 6-55
Mesh Wizard Viscous Layers

6-56 HEXPRESS™
CHAPTER 7: Python Scripts and
Plugins

7-1 Overview
Actions executed by the user through the HEXPRESS™ interface are recorded in a python-like
script giving added flexibility for automation of geometry creation and mesh generation. The
Project/Script... menu allows to edit and save the script while it can be executed using the Project/
Script.../Execute menu or the Execute Python script in the Welcome to HEXPRESS dialog box.
To launch a python script with HEXPRESS™ in batch, the command is:
hexpress -niversion 31_# -batch -script PATH_TO_SCRIPT/script.py -print

In order to use HEXPRESS™ included in FINE™/Marine or FINE™/Open package,


"_#" should be replaced by "marine31_#" or "open31_#".
The script should contain the command 31open_project() to specify the project to
work on.
Path on Windows should be prescribed with "/" instead of usual "\".
Project/Script.../Edit... opens a dialog box displaying all the commands performed by the user
since the beginning of its session. The user can easily edit this script (add, remove and modify com-
mands). The dialog box contains two pull-down menus. File menu allows to open a script in a sepa-
rate dialog box and to save the script in a file. Run menu allows to run the script shown in the
window under the current session ("Rerun on top").

HEXPRESS ™ 7-1
Python Scripts and Plugins Project Commands

FIGURE 7.1.0-1 Script Recording

Project/Script.../Save All... is used to save the dynamic recording of all commands performed by
the user since the beginning of its session.
Project/Script.../Execute... is used to run a python script file containing HEXPRESS™ com-
mands. A file chooser is opened to select a file with a ".py" extension. Upon selection of a valid file,
the script is executed in the current session and the result is visualized in the graphical window.
Depending on the content of the script, operations will be added to the current project or a new
project will be automatically opened before operations are performed (the previous project is
closed). If the script being run contains a syntactical error it will be aborted and a message will
appear in the shell.
Project/Script.../Re-execute Last can be used to rerun the last script that was run using the
Project/Script.../Execute... command. This option is most useful when writing own scripts manu-
ally to rapidly test it on the fly.
The supported commands for writing python scripts are described below, all other commands, even
if recorded, are not officially supported.
All actions running in HEXPRESS™ GUI cannot be all recorded as python scripts.
When replaying a python script that has been recorded automatically, it may be that the graphics
representations are not identical as in the initial session.

7-2 Project Commands


All the commands described below act on the active domain and associated block mesh. The user
can change the active domain by using the set_active_domain function, described below.
• open_project(filename,1) opens an existing HEXPRESS™ (.igg) project. "1" means that the
".hex" file will also be loaded, "0" will open the project without. If no number is precised, "1" is
chosen.
example: HXP.open_project("my_hexpress_project.igg",1)
• import_project(filename) imports an existing HEXPRESS™ (.igg) project.
example: HXP.import_project("my_hexpress_project.igg")
• save_project(filename) saves the current project. filename is full path name of the project file.
It must have the extension ".igg". After a first save operation, the filename argument can be
omitted, In that case the project file is overwritten.

7-2 HEXPRESS™
Viewing Commands Python Scripts and Plugins

example 1: HXP.save_project("/tmp/my_hexpress_project.igg")
example 2: HXP.save_project() # overwrites my_hexpress_project.igg
• close_project() closes the current project and initializes a new one.
• set_mesh_generation_mode(mode) sets the mesh generation mode to 2D or 3D. Default is 3D.
This function should only be called when the project must be 2D. It must be called directly after
the domain importation.
mode can have the values "2D" or "3D".
• export_fluent(filename) saves the mesh in Fluent format under the specified file name. Note
that the extension is ignored and ".msh" extension is used instead.
• export_cgns(filename) saves the mesh in CGNS format under the specified file name.
• export_nastran(filename, precision) saves the mesh in NASTRAN format under the specified
file name and precision format (1 for single, 2 for double).
• get_numeca_dir_() returns the path of the installation.

7-3 Viewing Commands


7-3.1 Camera position
• save_camera_position(position,target,up,width,height) saves the position of the camera in
the project, defined by its position, target, up vector, width and height.
position and target are of type Point.
up is of type Vector.
width and height are floats.
• set_camera_position(position,target,up,width,height) sets the position of the camera in the
project, defined by its position, target, up vector, width and height.
position and target are of type Point.
up is of type Vector.
width and height are floats.

7-4 Geometry Commands


7-4.1 Global Functions
• get_common_edges(refFace, otherFaces) returns the list of edges common to refFace and the
list of faces otherFaces. The returned list contain objects of type DomainEdge.
• compute_first_layer_thickness(yRef, Lref, Vref, kinVisc) computes the first layer thickness
with respect to the input parameters.
• compute_number_of_layers(face,first_layer_thickness,stretchingRatio) computes the
number of required layers for the input face (type DomainFace), according to the first layer
thickness and the stretching ratio.

HEXPRESS™ 7-3
Python Scripts and Plugins Geometry Commands

• geometry_rotate(origin,direction,angle,list_entities) rotates a list of curves and/or surfaces


around a given axis. origin and direction specify the rotation axis. angle is the angle of rotation
in degrees. list_entities is the list of curves and/or surfaces (specified with their name or as an
object).
• geometry_translate(direction,list_entities) translates a list of curves and/or surfaces along a
given direction. direction is the translation direction, in direction and magnitude. list_entities is
the list of curves and/or surfaces (specified with their name or as an object).
• geometry_mirror(origin,direction,list_entities) mirrors a list of curves and/or surfaces with
respect to a given plane. origin and direction specify the mirror plane. list_entities is the list of
curves and/or surfaces (specified with their name or as an object).
• geometry_scale(scale_vector,list_entities) scales a list of curves and/or surfaces around a
given axis. scale_vector specifies the scale factors along x, y and z in the form of an object of
class Vector. These values should be different from zero. list_entities is the list of curves and/or
surfaces (specified with their name or as an object).
• delete_curves(curve_list) deletes a set of curves.
• delete_surfaces() deletes the surface.

7-4.2 CAD Commands


• import_parasolid(filename) imports a Parasolid file.
example: HXP.import_parasolid("my_parasolid_file.xmt_txt")
• export_parasolid(filename) exports all Parasolid entities in the current session into filename.
Filename must have the extension ".xmt_txt".
• import_catia_file(filename) imports a CATPart file.
• get_all_bodies() returns the list of all bodies currently imported in HEXPRESS™. Each ele-
ment in the list is of class Body.
example: for body in get_all_bodies():
filename = "domain" + body.get_name()
create_domain(filename, body, ... other parameters ...)
• check() returns whether the body is clean or not (boolean value: 1 or 0)
• create_domain(filename,bodies,min_facet_size,max_facet_size,curve_chord_tol,
curve_chord_angle, surf_plane_tol,surf_plane_angle) triangulates the list of bodies and
saves it in a domain format in filename.
filename is the output file name. It must have ".dom" extension.
bodies is the list of the bodies to triangulate. Each item in the list must of class Body (see Body
class below) or simply the name of the body.
min_facet_size, max_facet_size, curve_chord_tol, surf_plane_tol, curve_chord_angle,
surf_plane_angle correspond to the parameters appearing in the Export dialog box of the CAD
Manipulation panel.
• create_cube(name, p1, p2) creates a box named name by specifying two opposite points p1,
p2. p1 and p2 are of type Point.
example: HXP.create_cube("B1", Point(0, 0, 0), Point(1, 1, 1))
• create_cylinder(name, center, axis, height, radius) creates a cylinder named name by specify-
ing its center, axis, height and radius.
center and axis are of type Point.
height and radius are floats.
example: HXP.create_cylinder("B2", Point(0, 0, 0), Point(0, 0, 1), 1., 0.2)
• create_cone(name, apex, axis, height, radius) creates a cone named name by specifying its
apex, axis, height and radius.

7-4 HEXPRESS™
Geometry Commands Python Scripts and Plugins

apex and axis are of type Point.


height and radius are floats.
example: HXP.create_cone("B3", Point(0, 0, 0), Point(0, 0, 1), 1., 0.2)
• create_plane(name, origin, normal, vector, size) creates a plane by specifying its name, ori-
gin, normal vector, a vector perpenticular to the normal vector and size. The parameter vector
defines a direction such that two edges of the square will be parallel to this direction and the
other two edges will be normal to it.
origin, normal and vector are of type Point.
size defines the squared extend of the plane around the origin.
example: HXP.create_plane("B4", Point(0, 0, 0), Point(0, 0, 1), 5.)
• create_sphere(name, origin, radius) creates a sphere with prescribed origin and radius.
origin is of type Point.
example: HXP.create_sphere("B5", Point(0, 0, 0), 0.5)
• delete_bodies(body_list) deletes the list of bodies body_list
body_list is a list of body names.
• substract_bodies(ref_body, tool_bodies) subtracts the list of bodies tool_bodies from
ref_body.
ref_body is the name of the reference body.
tool_bodies is a list of body names substracted from ref_body.
example: HXP.substract_bodies("B4", ["B1", "B3"])
• unite_bodies(ref_body, tool_bodies) unites the list of bodies tool_bodies with ref_body.
ref_body is the name of the reference body.
tool_bodies is a list of body names united with ref_body.
example: HXP.unite_bodies("B4", ["B1", "B3"])
• intersect_bodies(ref_body, tool_bodies) finds the intersection(s) between a reference body
ref_body and a list of bodies tool_bodies.
ref_body is the name of the reference body.
tool_bodies is a list of body names intersecting with ref_body.
example: HXP.intersect_bodies("B4", ["B1", "B3"])
• rotate_bodies(bodies, origin, axis, angle) rotates the list of bodies around an axis.
bodies is the list of body names that must be rotated.
origin is the origin of the rotation axis. It must be of type Point.
axis the the direction of the rotation axis.It must be of type Point.
angle is the rotation amount, in degrees.
example: HXP.rotate_bodies(["B1", "B3"] , Point(0, 0, 0) , Point(0, 0, 1) , 90.)
• translate_bodies(bodies, direction) translates the list of bodies in the imposed direction.
bodies is the list of body names that must be translated.
direction is the direction of translation. It also contains the magnitude of the translation. It must
be of type Point.
example: HXP.translate_bodies(["B1", "B3"] , Point(0, 0, 10))
• scale_bodies(bodies, scale_factors) scales the list of bodies along the X, Y and Z directions.
bodies is the list of body names that must be scaled.
scale_factors is a vector containing the scale factors along X, Y and Z. It must be of type Point.
example: HXP.scale_bodies(["B1", "B3"] , Point(2, 2, 2))
• sew_bodies(tolerance, bodies) sews the list of bodies using the given tolerance.
bodies is the list of body names that must be sewed.
tolerance is the tolerance used during sewing

HEXPRESS™ 7-5
Python Scripts and Plugins Geometry Commands

7-4.3 STL Commands


• import_stl(filename) imports an STL file in the current session.
filename must be an STL input file.
• stl_create_domain(filename) creates a domain from the set of stl groups present in the session.
filename is the output file name where the domain is saved.
• stl_group_by_feature(tolerance, featureAngle) creates stl groups based on the input feature
angle.
tolerance is the tolerance used for merging STL points.
featureAngle is the angle used for creating groups.
• export_domain_to_stl(filename, ascii_flag) saves the domain triangulation to a ASCII or
binary STL file filename.
filename is the output file name. It must have .stl extension.
ascii_flag 1 for export to a ASCII STL, 0 for export to a binary STL.

7-4.4 Domain Commands


• import_domain(filename) imports the domain file in the current session.
filename must be a domain input file.
• get_domain_file_name() returns the name of the domain file. If the project is new and a
domain is imported, the return value is the name of the imported domain file. If an existing
project is loaded, the returned name is the name of the domain associated with the project.
• translate_parts(id, vector) translates the list of parts (id) of the domain by a vector.
• rotate_parts(id, origin, vector, angle) rotates the list of parts (id) of the domain along an axis
(origin and vector) by an angle in degree.
• scale_parts(id, scaling) scales the list of parts (id) of the domain by the specified scaling factor
(scaling is a Vector type).
• replace_domain(filename,

7-4.5 CartesianPoint class


• CartesianPoint(p) creates a Cartesian point at the coordinates p (x,y,z).
• curve_plane_intersection(point,vector,curve_list) creates a Cartesian point at each intersec-
tion between all curves of the list and the plane specified by a point and its normal. Returns the
list of points.

7-4.6 Curve Construction


• new_polyline()
• new_polyline(p1,..,pi)
• new_polyline(name,p1,...pi)
Constructs a polyline. The first function defines an empty polyline. The other functions allow to
specify points of the polyline. These points are objects of class Point. name is a unique name
assigned to the curve. This argument is optional but it is however strongly recommended to specify
a name. It must be surrounded by quotes.
Example: p3 = new_polyline("poly1",Point(1,0,0),Point(1,1,0),Point(1,1,1))
• new_cspline()

7-6 HEXPRESS™
Geometry Commands Python Scripts and Plugins

• new_cspline (p1,..,pi)
• new_cspline (name,p1,...pi)
Constructs a cspline. See polyline for details about arguments.
• create_arc_ppp(startpoint,endpoint,midpoint,name) creates an arc through three points
(startpoint,endpoint,midpoint). name specifies the name assigned to the arc. The name may not
already be used by another curve in the repository.
• create_arc_cnpp(orig,normal,startpoint,endpoint,name) creates an arc through two points
(startpoint,endpoint) and perpendicular to an anchored vector. origin specifies the anchor point.
normal specifies the anchor vector direction. name specifies the name assigned to the arc. The
name may not already be used by another curve in the repository.
• create_arc_nppr(normal,startpoint,endpoint,radius,sense,name) creates an arc through two
points (startpoing,endpoint) with a given radius and perpendicular to a normal. normal speci-
fies the normal vector. radius specifies the arc radius. sense specifies the arc position. name
specifies the name assigned to the arc. The name may not already be used by another curve in
the repository.

7-4.6.1 Member functions


• select() / unselect() selects and deselects the curve.
• set_name(name) assigns a new name to the curve. The name must be unique and not already
used by another curve in the repository. If this condition is not met, an exception is raised. •
• get_name() returns the name of the curve.
• show()/hide() shows and hides the curve.
• reverse() reverses curve orientation. To reverse also the curve parametrization the argument is
set to 1. In that way, the vertex position is changed when reversing the curve.
• add_point(p) adds a control point on the curve. The type of <p> can be one of the Point classes
• insert_point(i,p) inserts a control point on the curve at ith location.
• remove_point(i) removes the ith control point on the curve.
• move_point(i,p) moves the ith control point on the curve at <p> location.
• set_discretization(n) sets the curve discretization to n. n is the number of points to discretize
the curve.
• set_curve_discretization(n,curve_list) sets the curve discretization to n. n is the number of
points to discretize the curve.

7-4.7 Internal Surface Commands


• lofted_surface(curve_list, surface_name) creates an internal surface as lofted surface, from a
list of curves. The internal surface is added to the active domain.
• import_internal_surface(filename) imports an external file a creates an internal surface out of
it (it can be .stl or .dat).

7-4.7.1 Member functions


• set_name(name) assigns a new name to the surface. The name must be unique and not already
used by another surface in the repository. If this condition is not met, an exception is raised.
• get_name() returns the name of the surface.
• select()/unselect() selects and deselects the surface.

HEXPRESS™ 7-7
Python Scripts and Plugins Geometry Commands

• show()/hide() shows and hides the surface.

7-4.8 Body Class


The Body class is used to access and manipulate Parasolid bodies imported or created in HEX-
PRESS™. A body object can be created by providing its Parasolid identifier. A typical way to
access the bodies is by calling the get_all_bodies() function.
• Body(id) : Body constructor. id is the Parasolid identifier.

7-4.8.1 Member functions


• get_name() returns the name of the body.
• get_xyz_box() returns the box containing the body. The return value is of type Box.
• get_type() returns the type the body. The type is a string that can take the following values:
"body", "sheet" , "wire".
• get_faces() returns the faces (BodyFace class) of the body.
• num_faces() returns the number of faces in the body.

7-4.9 BodyFace Class


The BodyFace class is used to access and manipulate Parasolid faces imported or created in HEX-
PRESS™.
• BodyFace(id) : constructs a BodyFace object from the Parasolid id. The id must correspond to a
valid id in Parasolid database.

7-4.9.1 Member functions


• get_name() returns the name of the body face.
• get_xyz_box() returns the box containing the body face. The return value is of type Box.
• get_edges() returns the edges (BodyEdge class) of the face.

7-4.10 BodyEdge Class


The BodyEdge class is used to access and manipulate Parasolid edges imported or created in HEX-
PRESS™.

7-4.10.1 Member functions


• get_name() returns the name of the body edge.
• get_xyz_box() returns the box containing the body edge. The return value is of type Box.

7-4.11 Domain Class


The Domain class is used to access and control the mesh generation process of domains in HEX-
PRESS™. A typical way to access the domains is by calling the get_all_domains() function.
• Domain(pointer) : Domain constructor

7-8 HEXPRESS™
Geometry Commands Python Scripts and Plugins

7-4.11.1 Member functions


• get_name() returns the name of the domain.
• get_xyz_box() returns the box containing the domain. The return value is of type Box.
• get_rtz_box(axis, origin) returns the cylindrical box containing the domain. Should only be
used for projects of cylindrical nature with its axis along X, Y or Z.
• num_faces() returns the number of faces in the domain.
• get_faces(pattern_matching_string) returns the list of faces of the domain. The return value is
a list of objects of type DomainFace. pattern_matching_string is an optional string argument
that allows returning the list of faces based on name pattern matching. Pattern matching uses
python regular expression syntax. See python module "re" for more information on regular
expressions. If no value is given to pattern_matching_string, all faces of the domain are
returned. Note: pattern matching is NOT based on unix pattern matching.
Examples:
domain.get_faces( "HULL" ) # Return all faces containing HULL in their name
domain.get_faces( "^HULL" ) # Return all faces whose name starts with HULL
• get_selected_faces() returns the list of selected faces. The returned value is a list of Domain-
Face objects. Cannot be used in batch mode.
• clear_face_selection() clears the list of selected faces. Cannot be used in batch mode.
• add_faces_to_selection(facelist) adds the input facelist to the list of selected faces.Cannot be
used in batch mode.
facelist is a list of DomainFace objects.
• create_BC_group(name, bc_type) creates an empty boundary condition group with name
name and BC type bc_type.
name is a string.
bc_type is a string that can have the following values: INL, OUT, SOL, MIR, UND, EXT
• delete_BC_group(bc_group_name) deletes the given BC group.
bc_group_name is the name of the group (string).
• add_patch_to_BC_group(bc_group_name, faceID) adds a face to the specified BC group.
bc_group_name is the name of the group (string).
faceID is the unique identifier of the face (integer). The command face._id can be used as well
to have the id of the face.
Example :
if (face.get_type() == "MIR"):
domain.add_patch_to_BC_group("MIR_GROUP",face._id)
If the face is a mirror patch, it will be added to the BC group called "MIR_GROUP". The faceID is
identified by face._id.
• set_BC_group_name(bc_group_name, new_name) changes the name of the boundary condi-
tion group given by bc_group_name to new_name.
• set_BC_group_type(bc_group_name, bc_type) changes the type of the boundary condition
group given by bc_group_name to bc_type.
bc_group_name is the name of the group (string).
bc_type is a string that can have the following values: INL, OUT, SOL, MIR, UND, EXT
• get_number_of_cells() returns the number of cell in the mesh associated with the domain.
• get_mesh_bad_cells_count() returns the number of negative, concave and twisted cells in the
mesh attached to the domain.

HEXPRESS™ 7-9
Python Scripts and Plugins Geometry Commands

Example:
neg,concave,twisted = get_active_domain().get_mesh_bad_cells_count()
print "Number of Negative Cells = ", neg
• get_mesh_orthogonality() returns the min, max and average orthogonality, as well as its stand-
ard deviation
• get_mesh_aspect_ratio() returns the min, max and average aspect ratio, as well as its standard
deviation
• get_mesh_expansion_ratio() returns the min, max and, average expansion ratio, as well as its
standard deviation
• get_mesh_skewness_range() returns the skewness between 0-5 , 5-15 , 15-25 degrees
• get_mesh_max_skewness() returns the maximum skewness in the mesh.
• split_face(face, x1,y1,z1,x2,y2,z2,smallEdgeLength) splits a face in two with two points and
returns the newly created faces.
(x1,y1,z1) and (x2,y2,z2) are the coordinates of the points on the two edges where splitting must
take place.
face can be either the id of the face or an object of type DomainFace. The return value are two
faces of type DomainFace.
smallEdgeLength is the shortest edge length after splitting.
• split_face(face, x1, y1, z1, x2, y2, z2, smallEdgeLength, x3, y3, z3) splits a face in two with
three points (i.e. to use a plane) and returns the newly created faces.
face can be either the id of the face or an object of type DomainFace. The return value are two
faces of type DomainFace.
(x1, y1, z1) and (x2, y2, z2) are the coordinates of points on the two edges where splitting must
take place.
(x3, y3, z3) is a point anywhere on the face.
smallEdgeLength is the shortest edge length after splitting.
• merge_faces(face1, face2) merges two faces of the Domain and return the newly created face.
face1 and face2 can be either the ids of the face or objects of type DomainFace. The return
value is of type DomainFace.
• merge_face_list(facelist) merges the list of faces passed as input. The faces must belong to the
same domain and must be contiguous.
facelist is a list of DomainFace objects or a list of faces identifiers.
• merge_all_edges(featureAngle) merges all possible pairs of edges of the domain whose angle
at the common vertex is larger than the featureAngle.
• create_adaptation_group(name,faceList) creates a new adaptation group for the domain.
name is the name of the group. faceList is the list of faces to put in the group. The list can con-
tain either the id of the faces (integer) or objects of type DomainFace. The function returns an
object of type SurfaceAdaptationGroup
• get_adaptation_group(name) returns the surface adaptation group identified by name. The
function returns an object of type SurfaceAdaptationGroup.
• num_adaptation_groups() returns the number of surface adaptation groups.
• create_VL_group(name,faceList) creates a new viscous layer group for the domain. name is
the name of the group. faceList is the list of faces to be in the group. The list can contain either
the id of the faces (integer) or objects of type DomainFace. The function returns an object of
type VLGroup.
• get_VL_group(name) returns the viscous layers group identified by name. The function
returns an object of type VLGroup.
• num_VL_groups() returns the number of viscous layer groups.

7-10 HEXPRESS™
Mesh Generation Commands Python Scripts and Plugins

• create_edge_adaptation_group(name,edgeList) creates a new edge (curve) adaptation group


for the domain. name is the name of the group. edgeList is the list of edges to put in the group.
The list can contain either the id of the edges (integer) or objects of type DomainEdge. The
function returns an object of type EdgeAdaptationGroup
• get_edge_adaptation_group(name) returns the edge adaptation group identified by name. The
function returns an object of type EdgeAdaptationGroup.
• num_edge_adaptation_groups() returns the number of edge adaptation groups.
• operator == (inputDomain) returns if this domain is the same as the inputDomain.

7-5 Mesh Generation Commands


7-5.1 Global Functions
• set_active_domain(domain) sets the active domain.
domain can be either the name of the domain (string) or an object of type Domain.
• get_active_domain() returns the active domain. The return value is an object of type Domain.
• get_all_domains() returns the list of all domains in the project. The return value is a list of
Domain objects (see class description for a definition of the Domain class).
example: domains = get_all_domains()
for domain in domains:
print domain.get_name()
• domain_face(faceID) returns the face of the active domain corresponding to its faceID. The
returned value is an object of type DomainFace.
• domain_edge(edgeID) returns the edge of the active domain corresponding to its edgeID. The
returned value is an object of type DomainEdge.
• split_edge(edgeId, x, y, z, smallEdgeLength) splits an edge in two.
edgeId is the edge identifier.
x, y, z are the coordinates of the split location.
smallEdgeLength is a small value. The vertex on the edge will be used to split the edge when
the distance between the split location and the vertex is less than smallEdgeLength.
• merge_edges(vertexId) merges two edges together.
vertexId is the identifier of the vertex shared by the two edges.
• split_face(faceId, x1, y1, z1, x2, y2, z2, smallEdgeLength) splits a face in two.
• merge_faces(face1Id, face2Id) merges two faces together.
face1Id and face2Id are the two faces identifiers.
• init_cartesian_mesh(nx, ny, nz) specifies the number of cells along the X, Y and Z directions
for the generation of an initial Cartesian mesh. This function does NOT generate the initial
mesh, its simply initializes its values.
• init_cylindrical_mesh(nr, nt, nz, rotation_axis, origin, rmin, rmax, teta_min, teta_max)
initializes a cylindrical mesh with the prescribed values. This function does NOT generate the
initial mesh, it simply initializes its values.
nr, nt, nz are the number of desired points along the R, TETA and Z directions.
rotation_axis specifies the axis of rotation. It can have the values "X", "Y" or "Z" (string).
origin is the origin of rotation axis. It must be of type Point.
rmin and rmax specify the limits of the mesh along the radius

HEXPRESS™ 7-11
Python Scripts and Plugins Mesh Generation Commands

teta_min and teta_max specify the limits of the mesh along the azimuthal direction, in degrees.
example: HXP.init_cylindrical_mesh(10, 20, 10, "Z", Point(0,0,0), 5 , 10 , 0 , 180)
• init_mesh_from_file(filename) initializes the mesh from an existing HEXPRESS™ mesh.
filename is the name of the existing mesh, in .hex format.
• generate_initial_mesh() generates the initial mesh, based on previously defined parameters.
example: HXP.init_cartesian_mesh(10, 5, 5)
HXP.generate_initial_mesh ()
• set_global_number_of_refinements(num_refinement) specifies the global number of refine-
ments during the mesh adaptation step.
num_refinement must be an integer.
• get_global_number_of_refinements() returns the global number of refinements for the active
block.
• enable_refinement(bool) enables or disables refinement step according to the input parameter
bool.
bool should be True or False.
• enable_trimming(bool) enables or disables trimming step.
bool should be True or False.
• set_advanced_global_parameters(diffusion, min_size, max_size, global_max_aspect_ratio,
num_cell_in_gaps) sets expert global generation parameters.
diffusion is the value of refinement diffusion.
min_size is the smallest cell size.
max_size is the largest cell size.
global_max_aspect_ratio is the value for global maximum aspect ratio.
num_cell_in_gaps is the number of cells to insert in gaps.
• set_prevent_exterior_cells_refinement(bool) prevents refinement on exterior cells.
bool should be 1 or 0.
• set_isotropic_refinement_in_corners(bool) enables isotropic refinement in the corner.
bool should be 1 or 0.
• set_trimming_by_distance(bool) enables trimming by distance.
bool should be 1 or 0.
• create_refinement_sector(axis, origin_x, origin_y, origin_z, radius_min, radius_max,
start_angle, end_angle, height) creates refinement sector with user-defined parameters.
• create_refinement_cube(x1, y1, z1, x2, y2, z2) creates refinement with two opposite points.
• refinement_box(box_number).set_position(x_min, y_min, z_min, x_max, y_max, z_max)
defines a new position for the refinement box specified.
• refinement_box(box_number).set_adaptation_flags(bool1, bool2) enables refinement for the
refinement box/sector specified according to input value bool1.
bool1 should be 0 or 1.
bool2 should be 0 or 1 (0 = surface only & 1 = volumic)
• refinement_box(box_number).set_refinement_level(n_max) specifies the maximum number
of refinements for the refinement box/sector specified.
n_max must be an integer.
• refinement_box(box_number).set_target_size(nx, ny, nz) specifies the target sizes along X,
Y and Z axis for the refinement box/sector specified.
example: HXP.refinement_box(2).set_target_size(0.01, 0.01, 0.1)
• refinement_box(box_number).set_max_aspect_ratio(ratio) specifies the maximum aspect
ratio for the refinement cells.

7-12 HEXPRESS™
Mesh Generation Commands Python Scripts and Plugins

• refinement_box(box_number).set_diffusion_depth(diffusion) specifies the refinement diffu-


sion for the refinement box/sector specified.
diffusion must be an integer.
• refinement_box(box_number).disable() disables the refinement box/sector specified.
• delete_all_refinement_boxes() deletes all refinement boxes/sectors defined.
• adapt_mesh() performs the adaptation step according to user-defined parameters.
• snap_mesh() performs the snapping step.
• enable_optimization(bool) enables or disables optimization step according to the input param-
eter bool.
bool should be True or False.
• set_optimization_params(relaxInvalidFlag, nbExtIterMax, invalidCellsMax,nbFinalOpti-
mIter, finalOptimPercent, maxNumOrthoIter,minOrtho) sets the expert optimization
parameters.
relaxInvalidFlag relaxes or not the geometry to eliminate invalid cells (boolean).
nbExtIterMax is the maximum number of external optimization loops.
invalidCellsMax is the maximum number of invalid cells.
nbFinalOptimIter is the maximum number of final optimization iterations.
finalOptimPercent is the percentage of vertices to optimize during final optimization.
maxNumOrthoIter is the maximum number of orthogonality optimization iterations.
minOrtho is the minimal orthogonality threshold
• regularize_mesh() optimizes the mesh.
• enable_viscous_layers(bool) enables or disables viscous layer insertion according to the input
parameter bool.
bool can take the value True or False.
• set_viscous_layers_global_params(inflateFlag, fixedNbLayer, minNbLayer, maxN-
bLayer, inflateFactor, fixedFirstLayerThickness) sets the global parameters for viscous layer
insertion control.
InflateFlag to inflate or not viscous layers (0: no inflation, 1: inflation).
fixedNbLayer is fixed (0) or floating (1) number of layers.
minNbLayer is the minimum number of layers.
maxNbLayer is the maximum number of layers.
inflateFactor is the inflation factor.
fixedFirstLayerThickness is constant (1) or variable (0) first layer thickness.
• insert_viscous_layers() inserts the viscous layers for each enabled face.
• search_all_fnmbs(search_rs) searches all non matching connections in the project.
search_rs is a boolean that specifies whether to search for rotor/stator connections.
• compute_fnmb(fnmb) computes the given non matching connection.
fnmb is either the name of the connection or an object of type FNMB (returned for example for
get_all_fnmbs)
example: search_all_fnmbs(0)
for fnmb in HXP.get_all_fnmbs():
compute_fnmb(fnmb)
• enable_rs_correction() aligns the mesh at R/S interface.
• import_cgns(filename) imports a CGNS file.
• export_cgns(filename) exports current selected mesh as a CGNS file.

HEXPRESS™ 7-13
Python Scripts and Plugins Mesh Generation Commands

7-5.2 DomainFace Class


• DomainFace(id): constructor. id is the persistent identifier of the face (saved in the .dom file)

7-5.2.1 Member functions


• get_name() returns the name of the face.
• set_name(name) changes the name of the face to name.
• _id returns the id of the face.
• set_type(bc_type) changes the boundary condition of the face to bc_type.
bc_type is a string that can have the following values: INL, OUT, SOL, MIR, UND, EXT.
example: HXP.domain("my_domain").get_faces(7).set_type("INL")
• get_type() returns the boundary condition of the face.
• get_area() returns the area of the face (sum of face triangles area)
• is_adaptation_enabled() returns whether the adaptation step is enabled for the face.
• enable_adaptation(bool) enables or disables adaptation for the face.
• set_number_of_refinements(num_ref) specifies the number of refinements for the face.
num_ref is an integer.
• get_number_of_refinements() returns the number of refinements for the face.
• set_adaptation_criterias(distance, curvature, target_size) specifies which adaptation criteria
to use.
distance, curvature, target_size are boolean values determining whether the distance, curvature
or target size criteria are used for the face.
• get_adaptation_criterias() returns which adaptation criteria is active.
• set_target_sizes(nx, ny, nz) sets the target sizes along X, Y and Z axis. When using this func-
tion, the target size adaptation criteria is automatically enabled.
nx, ny, nz are real positive values. If 0 is specified, the face is refined the number of times spec-
ified by the global number of refinements.
• get_target_sizes() returns the target sizes along X, Y and Z axis.
• set_diffusion_depth(num_depth) specifies the number of refinement diffusion for the face.
num_depth is an integer.
• get_diffusion_depth() returns the diffusion depth for the face.
• set_max_aspect_ratio(ratio) sets the maximum aspect ratio for the face.
• get_max_aspect_ratio() returns the maximum aspect ratio for the face.
• set_advanced_adaptation_criterias(curvatureFactor, anisoExtent) sets advanced adaptation
criteria for the face.
curvatureFactor is the curvature reference factor.
anisoExtent is the anisotropic extent.
• get_advanced_adaptation_criterias() returns advanced adaptation criteria for the face.
• enable_trimming(bool) enables or disables trimming step on the face.
bool should be True or False.
example: HXP.domain_face(0).enable_trimming(True)
• enable_viscous_layers(bool) enables or disables viscous layer insertion on the face.
bool should be True or False.
• set_viscous_layer_params(nbLayer, stretch, thickness, aspectratio, expansion) sets the vis-
cous layers parameters for the face.

7-14 HEXPRESS™
Mesh Generation Commands Python Scripts and Plugins

nbLayer is the number of inserted layers.


stretch is the stretching ratio between layers when constant first layer thickness is active.
thickness is the first layer thickness when constant first layer thickness is active.
aspectratio is the aspect ratio of the surface-mesh layer (by default set to 5) when variable first
layer thickness is active.
expansion is the geometric expansion in cell height (by default set to 1.2) when variable first
layer thickness is active.
• get_viscous_layer_params() returns the viscous layers parameters for the face.
• get_xyz_box() returns the box containing the face. The return value is of type Box.
• num_edges() returns the number of edges in the face
• contains_edge(edge) returns whether the face contains the edge. edge must be of type
DomainEdge.
• get_edges() returns the list of edges of the face. The return value is a list of objects of type
DomainEdge.
• get_common_edges(face) returns the list of edges that is also shared with face (of type
DomainFace). The return value is a list of objects of type DomainEdge.
• num_loops() returns the number of loops in the face
• get_loops() returns the list of loops in the face. The return value is a list of list of DomainEdge.
• get_neighbor_faces() returns the faces neighboring ths face. The return value is a list of
DomainFace.
• operator == (inputFace) returns if this face is the same as the inputFace.

7-5.3 DomainEdge Class


• DomainEdge(id): constructor. id is the persistent identifier of the edge (saved in the .dom file)

7-5.3.1 Member functions


• is_adaptation_enabled() returns whether the adaptation step is enabled for the edge.
• enable_adaptation(bool) enables or disables adaptation for the edge.
• set_number_of_refinements(num_ref) specifies the number of refinements for the edge.
num_ref is an integer.
• get_number_of_refinements() returns the number of refinements for the edge.
• set_adaptation_criterias(distance, curvature, target_size) specifies which adaptation criteria
to use.
distance, curvature, target_size are boolean values determining whether the distance, curvature
or target size criteria are used for the edge.
• get_adaptation_criterias() returns the adaptation criterias.
• set_target_sizes(nx, ny, nz) sets the target sizes along X, Y and Z axis. When using this func-
tion, the target size adaptation criteria is automatically enabled.
nx, ny, nz are real positive values. If 0 is specified, the edge is refined the number of times spec-
ified by the global number of refinements.
• get_target_sizes() returns the target sizes along X, Y and Z axis.
• set_diffusion_depth(num_depth) specifies the number of refinement diffusion for the edge.
num_depth is an integer.
• get_diffusion_depth() returns the diffusion depth for the edge.

HEXPRESS™ 7-15
Python Scripts and Plugins Mesh Generation Commands

• set_advanced_adaptation_criterias(maxAspectRatio, curvatureFactor) sets advanced


adaptation criteria for the edge.
maxAspectRatio is the maximum aspect ratio.
curvatureFactor is the curvature reference factor.
• get_advanced_adaptation_criterias() returns the advanced adaptation criteria in a list: max
aspect ratio and curvature factor.
• set_max_aspect_ratio(ratio) sets the max aspect ratio ratio for the edge.
• get_max_aspect_ratio() returns the maximum aspect ratio for the edge.
• set_buffer_insertion_type(type) sets the inserted buffer type.
type is set to 0 for type I and 1 for type II.
• set_snap_mode(mode) specifies whether the edge must be captured.
mode is set to 0 for "must be captured", 1 for "must be skipped" or 2 for "can be skipped"
• get_length() returns the length of the edge.
• get_xyz_box() returns the box containing the edge. The return value is of type Box.
• get_faces() returns the two faces sharing the edge.
• get_other_face(face1) an edge is always shared by two faces. This functions returns the face
that is not face1, given as input. The return value is of type DomainFace.
• get_vertices() returns the two vertices of the edge. The return values are of type DomainVer-
tex.
Example:
v0,v1 = edge.get_vertices()
print "Vertex id 0 ", v0._id
• get_min_angle_between_faces() returns the minimum angle (in degree) between the two adja-
cent faces of the edge. Typical values:
Angle between two flat surfaces: 180
Angle between two faces of a cube: 90
Angle for an accute edge: a few degrees
• operator == (inputEdge) returns if this edge is the same as the inputEdge.
Example:
e1 = face.get_edges()[0]
e2 = face.get_edges()[0]
if e1 == e2:
print "Same edges"

7-5.4 SurfaceAdaptationGroup class


• SurfaceAdaptationGroup(domain,groupName) returns an existing adaptation group for the
specified domain (type Domain), based on its name groupName. An exception is raised is the
group does not already exist.
• get_patches() returns the list of patches (DomainFace) defined in the adaptation group.

All the commands below have the same definition as the member functions from the
DomainFace class. Please read section 7-5.2 for more information about the functions.

• enable_adaptation(value) applies the function to each patch in the group.

7-16 HEXPRESS™
Mesh Generation Commands Python Scripts and Plugins

• set_adaptation_criterias(dist,curvature,target) applies the function to each patch in the


group.
• get_adaptation_criterias() returns the adaptation criterias for the group.
• set_advanced_adaptation_criterias(curvatureFactor,aniso_extent) applies the function to
each patch in the group.
• get_advanced_adaptation_criterias() returns the advanced adaptation criterias for the group.
• set_diffusion_depth(depth) applies the function to each patch in the group.
• get_diffusion_depth() returns the diffusion depth for the group.
• set_number_of_refinements(n) applies the function to each patch in the group.
• get_number_of_refinements() returns the number of refinements for the group.
• set_max_aspect_ratio(maxAspectRatio) applies the function to each patch in the group.
• get_max_aspect_ratio() returns the max aspect ratio parameter for the group.
• set_target_sizes(x,y,z) applies the function to each patch in the group.
• get_target_sizes() returns the target sizes for the group.

7-5.5 EdgeAdaptationGroup class


• EdgeAdaptationGroup(domain,groupName) returns an existing edge (curve) adaptation
group for the specified domain (type Domain), based on its name groupName. An exception is
raised is the group does not already exist.
• get_edges() returns the list of edges (DomainEdge) defined in the adaptation group.

All the commands below have the same definition as the member functions from the
DomainEdge class. Please read section 7-5.3 for more information about the functions.

• enable_adaptation(value) applies the function to each edge in the group.


• set_adaptation_criterias(dist,curvature,target) applies the function to each edge in the
group.
• get_adaptation_criterias() returns the adaptation criterias for the group.
• set_advanced_adaptation_criterias(curvatureFactor,aniso_extent) applies the function to
each edge in the group.
• get_advanced_adaptation_criterias() returns the advanced adaptation criterias for the group.
• set_diffusion_depth(depth) applies the function to each edge in the group.
• get_diffusion_depth() returns the diffusion depth for the group.
• set_number_of_refinements(n) applies the function to each edge in the group.
• get_number_of_refinements() returns the number of refinements for the group.
• set_max_aspect_ratio(maxAspectRatio) applies the function to each edge in the group.
• get_max_aspect_ratio() returns the max aspect ratio parameter for the group.
• set_target_sizes(x,y,z) applies the function to each edge in the group.
• get_target_sizes() returns the target sizes for the group.

HEXPRESS™ 7-17
Python Scripts and Plugins Dialogue box creation

7-5.6 VLGroup class


• VLGroup(domain,groupName) returns an existing viscous layer group for the specified
domain (type Domain), based on its name groupName. An exception is raised is the group does
not already exist.
• get_patches() returns the list of patches (DomainFace) defined in the viscous layer group.
• enable_viscous_layers(value) applies the function to each patch in the group.
• set_viscous_layer_params(nbLayer,stretch,thickness) applies the function to each patch in
the group. See DomainFace class for more information about the function.
• get_viscous_layer_params() returns the viscous layers parameters for the group.

7-5.7 FNMB class


• FNMB(name) constructs a new FNMB object, identified by its name. The FNMB must already
exist in the project. FNMB may also be found automatically by using the search_all_fnmbs
function.
• set_name(name) sets the name of the FNMB.
• get_name() returns the name of the FNMB.
• set_type(type) sets the type of the FNMB.
type is "Rotor/stator" or "Full non matching".
• get_type() returns the type of the FNMB.
• set_parameters(max_proj_dist, min_proj_dist, nb_smooth, periodic, per_index,
nb_repetitions, reverse, vertex_tol) sets the parameters controlling the computation of the
FNMB.
max_proj_dist is the maximum projection distance.
min_proj_dist is the minimum projection distance.
nb_smooth is the number of smoothing iterations.
periodic is a boolean to activate or not the periodic option.
per_index is the periodicity index (only used in case of periodic FNMB: periodic set to 1).
nb_repetitions is the number of repetitions (only used in case of periodic FNMB: periodic set to
1).
reverse is a boolean to activate or not the reverse option.
vertex_tol is the vertex tolerance (only used for rotor/stator connections).
• get_parameters() returns the parameters controlling the computation of the FNMB.

7-6 Dialogue box creation


The wording and options used throughout this section are directly taken from Tcl/Tk. The reader is
supposed to know basics of Tcl/Tk concepts. The following widgets can currently be constructed
from a python scripts:
• Entry
• Button
• CheckButton
• List

7-18 HEXPRESS™
Dialogue box creation Python Scripts and Plugins

• ComboBox
• Label
The following container widgets (widgets that can contain other widgets) can be created:
• Frame
• LabelFrame
• NoteBook
• PanedWindow
• DialogueBox
Each widget comes with an associated class with a (reduced) number of functions to modify or
access the value of the widgets.

These functions and classes aims at mimicking some functionalities of the Tcl/Tk
toolkit. It is not meant to provide extensive functionalities for creating advanced dia-
logue boxes. Only a reduced subset of features is provided. Any feature not described in
the above commands is not available.

7-6.1 Classes
7-6.1.1 Variable class
These objects are mostly used with RadioButton widgets to set and query the state of the buttons.
• Variable(value) constructs a variable with the specified initial value.
• setValue(value) sets the value of the variable.
• getValue() returns the value of the variable, as a string.

7-6.1.2 Command class


Commands are typically assigned to buttons, entries, lists, etc... and are used to execute an action
when the user presses a button, types enter in the field,... Two constructors are provided:
• Command(function) constructs a command which takes a function as argument
• Command(object, member_function) constructs a command which takes an object and a
member function of its class. The member function must have no argument in its signature.
Example:
class MyClass:
def __init__(self):
... python code ...
def myfunc(self):
... python code ...
a = MyClass()
c = Command( a, MyClass.myfunc ) # creates the Command

HEXPRESS™ 7-19
Python Scripts and Plugins Dialogue box creation

7-6.1.3 DialogueBox class


• DialogueBox(title) constructs a new dialogue box. title is an optional argument to specify a title
in the banner of the dialogue box.
• show() displays the dialogue box.
• close() closes and destroys the dialogue box.
• showUnderMouse() shows the dialogue box at the current mouse location.

7-6.1.4 Frame class


• Frame(parent) constructs a frame aimed at containing other widgets. parent is the parent of the
frame and must be of type: DialogueBox, Frame, LabelFrame, NoteBook or PanedWindow.

7-6.1.5 LabelFrame class


• LabelFrame(parent,label) constructs a label frame in parent aimed at containing other widg-
ets. label is the text appearing at the top of the label frame.

7-6.1.6 PanedWindow class


A PanedWindow is a window that is divided into two vertically, with a separator that can be moved
by the user to resize the left or right area.
• PanedWindow(parent) constructs a paned windows in parent.
• getLeftFrame() returns the left frame of the window. The returned object is of type Frame.
• getRightFrame() returns the left frame of the window. The returned object is of type Frame.

7-6.1.7 NoteBook class


NoteBooks allow to organise a dialogue box in pages that can themselves contain widgets.
• NoteBook(parent) constructs a NoteBook in parent.
• addPage(label) adds a new page to the notebook with name label. Two pages may not have the
same label. The returned value is a frame (class Frame) that can be filled with other widgets.

7-6.1.8 Label class


• Label(parent, text) constructs a simple label displaying text.

7-6.1.9 Button class


• Button(parent, text, command) constructs a button in parent with text appearing in the button.
parent must be a container widget (see above)
command is an optional argument that can be either a function that requires no argument or an
object of type Command. Upon pressing the button, the command will be called automati-
cally.

7-6.1.10 CheckButton class


CheckButton are buttons that can have two state: 0 (disabled) or 1 (enabled).
• CheckButton(parent,text,initValue,command) constructs a check button in parent.
parent must be a container widget.

7-20 HEXPRESS™
Dialogue box creation Python Scripts and Plugins

text is the text at the right of the button.


initValue is the initial value of the button and can have the value 0 or 1
command is an optional argument that can be either a function that requires no argument or an
object of type Command. Upon pressing the button, the command will be called automatically.

7-6.1.11 RadioButton class


• RadioButton(parent,text,variable,value,command) creates a radio button in parent.
parent must be a container widget.
text is the text at the right of the button.
variable is an object of type Variable. it is common that two or more radio buttons share the
same variable so that when one radiobutton is selected, the other one gets unselected, according
the value of the radiobutton.
value is the value to which variable will be set when pressing the button
command is an optional argument that can be either a function that requires no argument or an
object of type Command. Upon pressing the button, the command will be called automatically.
Example:
dialogue = DialogueBox()
dialogue.var = Variable(1) # create a variable with initial value 1
dialogue.radio1 = dialogue.radiobutton("Value 1", dialogue.var, 0 )
dialogue.radio2 = dialogue.radiobutton("Value 2", dialogue.var, 1 )
dialogue.radio1.pack()
dialogue.radio2.pack()

7-6.1.12 Entry class


• Entry(parent,label,command,value,width,unit,labelwidth,focus) constructs a new entry
widget in parent allowing the user to enter values (string, float(s), int(s),...).
parent must be a container widget.
label is a text appearing in front of the entry. This input is optional.
command is a function or object of class Command called when pressing the Enter key. This
input is optional.
value is the value of the entry (string, float, integer,...).
width specifies the default width of the entry. This input is optional.
unit is a string that will appear next to the entry to indicate the entry units. This input is
optional. Note that if the text for the units uses [], it must be backslashed "\[m\]".
labelwidth is the width of the entry label. This input is optional.
focus forces the focus on the entry.
• enable(state) changes the state of the entry (enabled or disabled). state is a boolean value.
• getStringValue() returns the value in the entry as a string.
• getFloatValue() returns the float value in the entry. An exception is raised (ValueError) if the
input is not a float.

HEXPRESS™ 7-21
Python Scripts and Plugins Dialogue box creation

7-6.1.13 List class


• List(parent,items) constructs a list in parent that displays a list of items.
parent must be a container widget.
items is a tuple containing the names of the item that will appear in the list.
• appendItem(itemName) adds an item to the list and returns its id. itemName is the text appear-
ing in the list.
• removeItem(itemId) removes the item from the list. itemId is the id identifying the item.
• getSelection() returns a tuple containing the ids of the selected items.
• getItemFromId(id) returns the name of the item from its id in the list.

7-6.1.14 ComboBox class


• ComboBox(parent,label,items,command) constructs a combo box in parent that allows to
select one item between a list of items.
parent must be a container widget.
label is a text appearing in front of the combo box.
items is a tuple containing the names of the item that will appear in the combo list.
command is a function or object of class Command called when pressing the selecting a item
in the list. This input is optional.
• setValue(value) specifies the value of the selected item.
• getValue() returns the value of the selected item

7-6.2 Additional commands for all widgets


All widget classes can have the following commands:
• pack( side="left",fill = "x", expand = "no" , anchor = "", padx = 1, pady = 1) member
function which displays the widget in its parent according to the input parameters.
side specifies which side of the parent the widget will be packed against. Possible values are
"top", "bottom", "left", "right".
fill specifies how the widget should stretch with regards to the available space in its parent.
Possible values are: "", "x" , "y" or "both". For example "x" specifies that the widget must
stretch horizontally to fill the entire width of the parent.
expand specifies whether the widget should resize when its parent resizes itself.
anchor specifies where to position each widget in its parent. Possible values are: n, e, w or s.
Default is center.
padx specifies how much horizontal external padding to leave on each side of the widget.
pady specifies how much horizontal external padding to leave on each side of the widget.
• unpack() hides the widget from the screen.

7-6.3 Additional commands for container widgets


All the Container widgets have additionally the following functions:

7-22 HEXPRESS™
Dialogue box creation Python Scripts and Plugins

button(text,command) creates and returns a Button widget, passing all the arguments to the
object.
checkbutton(text,initValue,command) creates and returns a CheckButton widget, passing all the
arguments to the object.
radiobutton(text,variable,value,command) creates and returns a RadioButton widget, passing all
the arguments to the object. See RadioButton class.
entry(label,command,width) creates and returns an Entry widget, passing all the arguments to the
object.
list(items) creates and returns a List widget, passing all the arguments to the object.
label(text) creates and returns a Label widget. See Label class.
combobox(label,items,command) creates and returns a ComboBox widget, passing all the argu-
ments to the object. See ComboBox class.
labelframe(text) creates and returns a LabelFrame widget, passing all the arguments to the object.
See LabelFrame class.

7-6.4 Example: Z-constant internal surface


The "Marine" module comes with various plugins including one to automatically create an internal
surface at a Z-constant coordinate (see section 2-3.7.3). One can open the corresponding python
script in "NUMECA_INSTALLATION/_python/_hexpress_plugins/Marine/" to see how the script
is build. Here is a description of the example (comments are added and marked by a symbol "#").
Import required librairies: "Tk" for dialogue boxes, "string" is dedicated to Python management and
"HXP" to enable HEXPRESS™ macro commands (defined in sections 7-2 to 7-5 of this chapter).
from Tk import *
import string
import HXP
The dialogue box is defined in a dedicated class. This class will contain 2 separate functions
"__init__" and "apply". The first one defines the dialogue box design whereas the second one gives
what the Apply button will do in HEXPRESS™.
class ZConstantDialogue(DialogueBox):
def __init__(self):
DialogueBox.__init__(self, "Internal surface" ) #definition of the dialogue box title
self.show() #the dialogue box appears immediately

content = self.labelframe(label="Z constant surface") #definition of a frame with the


title "Z constant surface"

buttonsFrame = self.frame() #definition of a frame for buttons


content.pack(side="top",fill="x",padx=10,pady=10)
buttonsFrame.pack(side="top",anchor = "se" , expand = "yes" )

HEXPRESS™ 7-23
Python Scripts and Plugins Dialogue box creation

self.entry = content.entry(label="Z = " , width = 20 , command = Command(self,ZCon-


stantDialogue.apply) ) #definition of an entry with the title "Z=". The entry has a width
of 20
self.entry.pack( side = "left" , fill = "x" , expand = "yes", padx = 10 ) #the action
"pack" will show the entry in the dialogue box

apply = buttonsFrame.button(text="Apply",command = Command(self,ZConstantDi-


alogue.apply ) ) #location and definition of the button "Apply"
close = buttonsFrame.button(text="Close",command = Command(self,Dialogue-
Box.close) ) #location and definition of the button "Close"

close.pack(side="right") #the action "pack" will show the button and put it on the
right of the dialogue box
apply.pack(side="right")

def apply(self):

Z = self.entry.getFloatValue() #"getFloatValue" gets the value entered for the entry


"Z" as a float

try:
domain = HXP.get_active_domain() #defines "domain" which contains a list of
the active domain
except Exception, value:
Warning(value.args[0])
return #goes out of the function "apply"

b = domain.get_xyz_box() #returns the box containing the domain and stores the infor-
mation in the variable "b"

if Z < b.zmin or Z > b.zmax:


Warning("The entered value lies outside the limits of the bounding box")
return #goes out of the function "apply"

c1 = new_polyline("c1") # creates first polyline called "c1"


c1.insert_point( 1, Point(b.xmin,b.ymin,Z) ) # inserts point
c1.insert_point( 2, Point(b.xmin,b.ymax,Z) )
c2 = new_cspline("c2") # creates second polyline called "c2"
c2.insert_point( 1, Point(b.xmax,b.ymin,Z) )
c2.insert_point( 2, Point(b.xmax,b.ymax,Z) )

7-24 HEXPRESS™
Dialogue box creation Python Scripts and Plugins

lofted_surface([c1,c2],"ISurface_Z=" + str(Z)) #creates a lofted surface based on the


points previously inserted

z = ZConstantDialogue() #instantiates the dialogue box "ZconstantDialogue"

HEXPRESS™ 7-25
Python Scripts and Plugins Dialogue box creation

7-26 HEXPRESS™
APPENDIX A: File Format

A-1 What is STL?


The STL letters stand for Stereo Triangulation Lithography. This file format has traditionally been
associated with Stereo Lithography prototyping machines, but is used by HEXPRESS to describe
the "water-tight" surface boundary of the meshing domain.

A-2 ’.stl’ file format specification


The format is specified as both in Ascii (printable character) format as well as in binary format.

A-2.1 Ascii file format


The first line is a description line. This line must start with the word "solid" in lower case, which
may be followed by information such as the file name, author, date,...
As an example consider the following part of a STL file:

solid
:
:
facet normal 0.0 0.0 1.0
outer loop
vertex 1.0 1.0 0.0
vertex -1.0 1.0 0.0
vertex 0.0 -1.0 0.0
endloop
endfacet
:
:
endsolid

HEXPRESS™ A-1
File Format ’.prop’ file format specification

The last line should be the keyword "endsolid". The lines between the above contain descriptions of
3 vertex facets including their normal. Note that the ordering of the vertices is very important since
it gives the orientation of the facet and should comply with the right hand rule.
The facet normals may remain unspecified and set by default to 0. 0. 0. and will generally be gener-
ated by the parsing software/system. The main restriction placed upon the facets in STL files is that
all adjacent facets have to share two common vertices.

A-2.2 Binary file format


Binary STL files consist of a 80 bytes header line that can be interpreted as a comment string. The
following 4 bytes interpreted as a long integer give the total number of facets. This last integer is
followed by a normal and 3 vertices for each facet where each coordinate is represented by a 4 bytes
floating point number (12 bytes in total). There is a 2 bytes spacer between each facet. The result is
that each facet is represented by 50 bytes, 12 for the normal, 36 for the 3 vertices, and 2 for the
spacer.
In the binary STL format the color information is added as in the Materialise Magics software.
More details are available on wikipedia (http://en.wikipedia.org/wiki/STL_%28file_format%29).

A-3 ’.prop’ file format specification


The ".prop" property file associated to a ".stl" must respect the following constraints:

• It should be read simultaneously with the ".stl" file. The nth triangle in the ".stl" file is associ-
ated with the nth attribute in the ".prop" file. The number of attributes stored in the ".prop" file
is equal to the number of triangles in the ".stl" file.
• An attribute is an integer value which corresponds to the ID of a topology face. For n topolog-
ical faces, the attributes range from 0 to n-1.
• Each group of triangles must be related.
The file format is the following:

ng
attribute0
:
:
attributen-1

where ng is the number of topology faces


n is the number of triangles in the ‘‘.stl’’ file to which the ‘‘.prop’’ file is
associated.

A-4 ’.dom’ file format specification


The domain file with suffix ".dom" stores the computational domain meshable by HEXPRESS
The computational domain is a triangulated representation of the CAD model.

A-2 HEXPRESS™
’.dom’ file format specification File Format

HEXPRESS expects a "water-tight" computational domain. The computational domain consists


of a topology and a geometry part as presented in Figure A.4.0-1 on page A-3.
• The topology describes the skeleton of the model. Basically, it allows the definition of a
closed volume and provides information on the connection of the model surfaces (topologi-
cal faces) with common curves (topological edges). Similarly, it connects curves together
by common corners (topological vertices).
• The geometry part defines the actual geometry of the model. Each model surface is
described by a triangulation; each curve by a list of points connected by segments and the
corners are defined by a single point.

FIGURE A.4.0-1 HEXPRESS computational domain definition.

File header
Domain file is an ASCII file. It starts from a 3 line header as follows
• The first line contain the file description in the form:
Multidomain - Created by HEXPRESS version on date ,
where version is the HEXPRESS version and date is the file creation date in format MM/DD/
YYYY.
• Second line contains the domain file format version has the form
Version version
where version is the .dom format version written as a fixed point number. Example: Version 2.3
• Third line has the form

HEXPRESS™ A-3
File Format ’.dom’ file format specification

NUMBER_OF_BLOCKS N ,
where N is the number of blocks.
The file header is followed by N sections, each section defines a domain for one block.

Single block domain section


• The first line of the block's domain description defines the name of the block
• The next line contains the orientation check flag. If it is 1, the domain will be checked for cor-
rect orientation of triangulation during loading. The flag is set to 0 when the project is saved.
• The next line contains 8 triangulation parameters which were used for creating the domain
from the corresponding Parasolid model. These parameters are
— the minimum edge length of the triangulation facets (float)
— the maximum edge length of the triangulation facets (float)
— Curve chordal tolerance (float)
— Surface plane tolerance (float)
— Curve resolution (float)
— Surface resolution (float)
— Triangulation orientation flag (0 or 1)
— Merge tolerance (float)
• The next line contains the number of seed points
• The subsequent lines list for each seed point, its ID (starting from 0) and x,y,z coordinates
seed_point_1 x y z
seed_point_2 x y z
...
• The next line gives the number of topological vertices (corners)
• The subsequent lines list for each topological vertex, its ID and x,y,z coordinates
topo_vertex_1 x y z
topo_vertex_2 x y z
...
• The next line gives the number of curves
• Each curve is defined by a list of points and a list of segments connected to these points
curve_id_1 (starting from 0)
number_of_points
point_1 x y z
point_2 x y z
point_3 x y z
...
number_of_segments
segment_1 point_id_O point_id_D

A-4 HEXPRESS™
’.dom’ file format specification File Format

segment_2 point_id_O point_id_D


segment_3 point_id_O point_id_D
...
curve_id_2
...
• Curve descriptions are followed by the number of surfaces
• Each surface is defined by a set of points and a list of triangles connected to these points
surface_id_1 (starting from 0)
number_of_points 1 (1 is not used but must be present)
point_1 x y z
point_2 x y z
point_3 x y z
...
number_of_triangles
triangle_1 3 point_id_0 point_id_1 point_id_2
triangle_2 3 point_id_0 point_id_1 point_id_2
triangle_3 3 point_id_0 point_id_1 point_id_2
...
surface_id_2
...
• The next part of the file specifies the topology of the model. The number of topological edges
is specified on the next line, it corresponds to the number of curves
• For each topological edge, the IDs of the topological vertices used as extremities are given.
For a cyclic topological edge, these IDs are (-1, -1). The type of the curve is specified, 1 for a
convex edge, 2 for a concave edge. In addition, the curve ID defining the topological edge is
given, it usually equals to the topological edge ID
topo_edge_ID_1 O_topo_vtx_ID D_topo_vtx_ID type curve_ID
topo_edge_ID_2 O_topo_vtx_ID D_topo_vtx_ID type curve_ID
topo_edge_ID_3 O_topo_vtx_ID D_topo_vtx_ID type curve_ID
...

HEXPRESS™ A-5
File Format ’.dom’ file format specification

FIGURE A.4.0-2 Convex, concave and flat topological edges

• The next line gives the number of topological faces


• For each topological face, we give its name and the number of topological edges defining the
face. These edges form successive loops (internal loops define holes in the face). For each top-
ological edge, the orientation is given +1 or -1 depending whether the loop complies with the
right-hand rule or not respectively. The ID of the surface defining the topological face is also
given.
topo_face_ID_1 'face_name_1' number_topo_edges topo_edge_1 orient_1 topo_edge_2
orient_2 ... surface_ID
topo_face_ID_2 'face_name_2' number_topo_edges topo_edge_1 orient_1 topo_edge_2
orient_2 ... surface_ID
...

A-6 HEXPRESS™
Index

INDEX
Numerics chunksize 2-17
2D 6-4 clear cache 2-16
3D viewing 2-90 concave cells 2-43, 2-44, 2-45, 6-42
control points
A adding new 2-21
action 6-2 deleting 2-21
active 6-22 hide 2-27
adaptation 1-3, 3-4 modifying 2-22
box 6-28 convention 1-5
curve 6-17 convert
surface 6-18 domain --> STL 2-54
anisotropic extent 6-27 StarCD --> STL 2-54
ANSYS 2-7 coordinate axis 2-89
aspect ratio 2-44, 6-26 corner capture 6-34
auto button 6-8 correction manual 2-46
axis 2-89 create
axi-symmetric 2-49, 6-5 box 4-5
curve 2-71
B domain (Parasolid) 4-15
background 2-87 surface 2-71
batch mode 3-8 curvature 6-24
boundary conditions 2-30, 6-7 ref factor 6-26
type 2-33, 2-34 curve
bounding box 4-1, 4-5, 6-8 adaptation 6-17
box adaptation 6-28 capture 6-34
buffer insertion 6-35, 6-37 create 2-71
delete 2-28
C display curve 2-26
CAD hide 2-27
manipulation 1-1, 2-70 modify
model 4-4 add control point 2-21
cancel 6-4 discretization 2-22
capture divide 2-23
corner 6-34 modify control point 2-22
curve 6-34 remove control point 2-21
Cartesian point 2-24, 2-27, 2-28, 2-71 reverse orientation 2-23
CATIA orientation 2-23, 2-27
import 1-2, 2-7 select 2-24
V5 4-3 show curve orientation 2-27
CEDRE 2-15 snapping 6-36
short names 2-16 cut-away 2-92
cell view 2-52 cutting plane 2-91, 2-93
CGNS 2-8, 2-13 cylindrical
check 4-20 sector 6-29

HEXPRESS™ i
Index

INDEX
D viewer 2-80
delete 4-14 faceting 4-16
curve 2-28 features 1-1
surface 2-28 file management 1-4
text 2-53 filter 2-33
diffusion 6-14 fit view 2-91
depth 6-28 fixed first layer thickness 6-46
discretization 2-22, 2-23, 4-17 Fluent export 2-10
display format A-1
curve 2-26 full non matching 2-35, 3-8
point 2-25
surface 2-26 G
distance 6-15, 6-23 gap 6-15
domain geometry 3-2, 5-1
convert STL 2-54 getting start 1-1
definition 3-2, 5-1 go 6-4
import 2-7 graphics area 1-6, 2-95
manipulation 2-78, 5-2 grid
validity 2-79, 5-2, 5-11 boundary conditions 2-30
domhydro 2-60 level 2-51
driver 1-6 mirror 2-30
non matching 2-35
E parameters area 2-89
edge periodicity 2-28
merge 2-79, 5-2, 5-3 quality 2-42
split 2-79, 5-2, 5-3 repetition 2-30, 2-54
edit rotation 2-48
mirror 2-21 transformation 2-48
rotate 2-20 translation 2-29, 2-48
scale 2-20
translate 2-20 H
export 1-2, 2-8, 4-27 hand symbol 1-5
Fluent 2-10 hexahedral 1-1
Samcef-Bacon 2-12, 2-13 HEXPRESS/Hybrid 2-8
StarCD 2-8 hide
curve 2-27
F curve control points 2-27
face surface 2-27
displacement 2-52 hints 2-33
merge 2-79, 5-2, 5-5
merge list 5-7 I
select 2-32, 2-82, 5-8, 6-20 import 2-7, 4-21
split 2-79, 5-2, 5-4 CATIA 1-2, 2-7

ii HEXPRESS™
Index

INDEX
mesh file 6-10 geometry 4-25
Parasolid 2-7 modify curve 2-21
STL 1-2, 2-7 mouse coordinates area 2-88
information 4-26 MSW driver 1-6
area 2-88 multi-domain 3-7
initial mesh 1-3, 3-4, 6-7 multigrid Level 2-51
insert text 2-53
installation 1-5 N
interface 2-1 NASTRAN 2-14
internal surface 2-19, 2-69 negative cells 2-43
intersect 4-13 new project 2-4
invert 2-33, 2-83, 5-8, 6-21 NURBS 4-3

J O
Jacobian 6-42 open
existing project 2-4
K new project 2-4
keyboard input area 2-88 OpenFOAM 2-15
OPENGL driver 1-6
L optimization 1-4, 3-6, 6-41
layer 6-51 orientation 4-12
license 1-7 of curve 2-23, 2-27
light bulb 1-5 original view 2-91
orthogonality 2-44
M overview 2-1
manual correction 2-46
material 2-84 P
menu bar 2-3 pair of scissors 1-5
merge 2-79, 4-3, 5-2 Parasolid 1-1
edge 5-3 import 2-7
face 5-5 patch
face list 5-7 filter 2-33
mesh visualization 2-31
adapt 1-3 periodicity 2-28
files 1-4 perspective 2-53
generation 3-4 picking 4-11, 6-20, 6-49
initial 1-3 plugins 2-56
optimize 1-4 marine 2-57
snap 1-4 PNG 2-17
viscous layers 1-4 point
wizard 6-2 display 2-25
meshing fundamentals 3-1 preferences 2-17
message area 2-88 print as PNG 2-17
mirror 2-21, 2-30, 2-69 project 2-10

HEXPRESS™ iii
Index

INDEX
management 1-4 sew 4-20
menu 2-3, 2-4 shading 2-92
new 2-4 shortcuts 2-95
preferences 2-17 shrink factor 2-52, 2-92
print 2-17 smoothing 6-35
quit 2-3, 2-19 snap surface 6-34
save 2-5 snapping 1-4, 3-6, 6-33
save as 2-6 solid 4-20
projection 6-35 split 2-79, 5-2
distance 2-38 edge 5-3
python 7-1 face 5-4
StarCD 4-28
Q convert STL 2-54
quality 2-42, 2-67 StarCD export 2-8
quick access pad 2-70 start 1-1, 6-3
quit 2-3, 2-19 interface 1-6
step 6-3
R STL
refinement 3-4, 6-12 import 2-7
rendering 2-87 model 4-21
repetition 2-30, 2-54 stop 6-3
reverse triangulation 2-39 stretching ratio 6-46
rotate 2-20 structured 1-2, 2-5
geometry 4-26 substract 4-11
rotation 2-48 surface
rotor/stator 3-8 adaptation 6-18
connection 2-40 create 2-71
delete 2-28
S display surface 2-26
Samcef-Bacon export 2-12, 2-13 hide 2-27
save modify
project 2-5 discretization 2-23
project as 2-6 select 2-24
scale 2-20 show lofting curves 2-27
script 2-16, 7-1
scrolling 2-90 T
sector 6-29 target cell size 6-25, 6-30
select text
curve 2-24 delete 2-53
face 2-32, 2-82, 5-8, 6-20 insert 2-53
surface 2-24 tolerance 2-41, 4-17
selection 4-19 toolbar 2-69
settings 2-79, 5-2, 5-12 topology 3-2, 5-1

iv HEXPRESS™
Index

INDEX
transform Parasolid 4-14
transformation 2-48 Y
translate 2-20 Y-projection 2-89
geometry 4-25 Y-rotation 2-90
translation 2-29, 2-48
transparency 2-92 Z
triangulation 1-2, 4-2, 4-17, 4-20 zoom area 2-91
reverse 2-39 zoom in/out 2-90
trimming 3-5, 6-13, 6-31 Z-projection 2-89
twisted cells 6-42 Z-rotation 2-90

U
undo 2-33, 2-79, 2-83, 5-2, 5-8, 5-11, 6-21
Parasolid 4-15
unite 4-11
unstructured 1-2

V
validity check 5-11
variable first layer thickness 6-48
vertex tolerance 2-41
view
cell 2-52
curve orientation 2-23, 2-27
original 2-91
perspective 2-53
repetition 2-54
subpanel 2-80
viewing buttons 2-89
viscous layers 1-4, 3-7, 6-44
visualization 4-19
volume 2-44
volumic 6-30

W
welcome 2-2
wireframe 4-20

X
X11 driver 1-6
X-projection 2-89
X-rotation 2-90

HEXPRESS™ v

Das könnte Ihnen auch gefallen