gambit tutorial guide

485
0. USING THIS TUTORIAL GUIDE 0.1 What's in This Guide This guide contains step-by-step examples that teach you how to use GAMBIT to create and mesh various geometries. Each example illustrates at least one new concept with respect to GAMBIT geometry creation and mesh generation. Tutorial 1 includes explicit instructions for all steps in the geometry creation, mesh generation, and examination of a completed mesh. Its purpose is to introduce the beginning user to several basic features and operations that are available in GAMBIT. The remaining tutorials are designed for the user who has read or worked through Tutorial 1 or who is already familiar with GAMBIT. Consequently, they are not as explicit in their instructions as is Tutorial 1. Tutorial 5 illustrates how to import geometry into GAMBIT from an existing file. The file that contains the geometry to be imported is located in the directory where GAMBIT is installed. (This file is included on your installation tape or CD.) 0.2 How to Use This Guide If you are new to GAMBIT, you should first work through Tutorial 1 in order to familiarize yourself with the GAMBIT graphical user interface (GUI) and with basic geometry creation and meshing procedures. You may then want to try a tutorial that demonstrates features that you are going to use in your application. For example, if you are planning to start from an existing geometry that requires some cleanup, you should look at Tutorial 5. Each tutorial demonstrates different GAMBIT features, so it is recommended that you do each tutorial in order to get the full benefit from this Tutorial Guide. Note that Step 1 in Tutorials 2 through 6 requires you to select the solver to be used for the CFD calculation. In many cases, you could select a different solver than the one used in the tutorial. The solver selection is included in the tutorials to demonstrate the process of selecting a solver. It also illustrates that the choice of solver dictates the options available in various forms (for example, the boundary types available in the Specify Boundary Types form).

Upload: manjhunathcr8231

Post on 26-Dec-2015

205 views

Category:

Documents


5 download

DESCRIPTION

Gambit Tutorial Guide

TRANSCRIPT

Page 1: Gambit Tutorial Guide

0. USING THIS TUTORIAL GUIDE

0.1 What's in This Guide

This guide contains step-by-step examples that teach you how to use GAMBIT to create and mesh various geometries. Each example illustrates at least one new concept with respect to GAMBIT geometry creation and mesh generation.

Tutorial 1 includes explicit instructions for all steps in the geometry creation, mesh generation, and examination of a completed mesh. Its purpose is to introduce the beginning user to several basic features and operations that are available in GAMBIT. The remaining tutorials are designed for the user who has read or worked through Tutorial 1 or who is already familiar with GAMBIT. Consequently, they are not as explicit in their instructions as is Tutorial 1.

Tutorial 5 illustrates how to import geometry into GAMBIT from an existing file. The file that contains the geometry to be imported is located in the directory where GAMBIT is installed. (This file is included on your installation tape or CD.)

0.2 How to Use This Guide

If you are new to GAMBIT, you should first work through Tutorial 1 in order to familiarize yourself with the GAMBIT graphical user interface (GUI) and with basic geometry creation and meshing procedures. You may then want to try a tutorial that demonstrates features that you are going to use in your application. For example, if you are planning to start from an existing geometry that requires some cleanup, you should look at Tutorial 5. Each tutorial demonstrates different GAMBIT features, so it is recommended that you do each tutorial in order to get the full benefit from this Tutorial Guide.

Note that Step 1 in Tutorials 2 through 6 requires you to select the solver to be used for the CFD calculation. In many cases, you could select a different solver than the one used in the tutorial. The solver selection is included in the tutorials to demonstrate the process of selecting a solver. It also illustrates that the choice of solver dictates the options available in various forms (for example, the boundary types available in the Specify Boundary Types form).

Page 2: Gambit Tutorial Guide

0.3 Font Conventions

The following font conventions are used throughout this manual to represent user input data, the titles of forms and command buttons, options, and the names of modeling objects.

Font Description Example(s)

Courier Command line arguments, file names, and other user input from the keyboard

volume create sphere GAMBIT.ini

Arial Narrow, Bold Titles of buttons, selectors, fields, and forms as they appear in the graphical user interface

Model Volume Vertex

Arial Narrow Titles of options and commands

Interval size Lower topology

Arial Narrow, Italic Names of GAMBIT topological entities and coordinate systems

edge.1 vertex.3

0.4 Using the Mouse

The GAMBIT GUI is designed for use with a three-button mouse. The function associated with each mouse button varies according to whether the mouse is operating on menus and forms, or in the graphics window. Some graphics-window mouse operations involve keyboard keys in conjunction with the mouse.

0.4.1 Menus and Forms

Mouse operations for GAMBIT menus and forms require only the left and right mouse buttons and do not involve any keyboard key operations. Most of the mouse operations performed on GAMBIT GUI menus and forms require only the left mouse button. The right mouse button is used to open menus related to command buttons on the toolpads. On some forms that include a text window, the right mouse button opens a hidden menu of options such as that described in "Using a Pick List Form" in Section 3.2.8 of the GAMBIT User's Guide.

0.4.2 Graphics Window

Page 3: Gambit Tutorial Guide

There are three general types of GAMBIT GUI graphics-window mouse operations:

• Display • Task • Vertex creation

Display operations allow you to directly manipulate the appearance of the model in any of the enabled graphics-window quadrants. Task operations allow you to specify topological entities and to execute geometry and meshing operations. The vertex creation operation allows you to create vertices on any displayed coordinate-system grid. (For further information on these operations, see Section 3.3.2 of the GAMBIT User's Guide.)

Display Operations

GAMBIT graphics-window display operations employ all three mouse buttons as well as the Ctrl keyboard key.

Keyboard Key/ Mouse

Button Mouse Motion Description

Left-click Left-drag the cursor in any direction.

Rotates the model

Middle-click Middle-drag the cursor in any direction.

Translates the model

Right-click Right-drag the cursor vertically.

Zooms the model in or out

Right-click Right-drag the cursor horizontally.

Rotates the view of the model about the center of the graphics window

Ctrl-left-click Left-drag the cursor diagonally.

Enlarges the model, retaining the model proportions. When you release the mouse button, GAMBIT enlarges the display

Double-middle-click Displays the model as shown immediately before the current view

Task Operations

Page 4: Gambit Tutorial Guide

GAMBIT graphics window task operations employ all three mouse buttons in conjunction with the Shift key to allow you to pick entities and to execute actions related to GAMBIT forms. There are two types of task operations:

• Picking entities • Executing actions

Picking Entities

Many GAMBIT modeling and meshing operations require you to specify one or more entities to which the operation applies. There are two ways to specify an entity for a GAMBIT operation:

• Input the entity name in the appropriate list box on the specification form or select it from the appropriate pick list.

• Use the mouse to "pick" the entity from the model as displayed in the graphics window.

When you use the mouse to pick an entity from the model that is displayed in the graphics window, GAMBIT inserts the entity name in the currently-active pick list as if you had specified its name on the currently-open specification form.

There are two different types of GAMBIT entity-picking operations, each of which involves the Shift key. Throughout the Tutorial Guide, you will see expressions such as Shift-left-click; this indicates that you should press and hold the Shift key while clicking the left mouse button. The two entity picking operations are as follows:

Operation Description

Shift-left-click Highlights the entity in the graphics window and includes it in the currently active pick list.

Shift-middle-click

Toggles between adjoining multiple entities of a given type.

To select a group of objects, Shift-left-drag a box around the objects. The box does not have to completely enclose the objects; it only needs to be enclosing parts of them.

Executing Actions

When you Shift-right-click the mouse in the graphics window, GAMBIT accepts the selection of an entity and moves the focus to the next pick list in the form. If the current pick list is the last one in the form, Shift-right-click executes the operation associated with the currently open form. In this case, the Shift-right-click operation is equivalent to the act of clicking Apply on the bottom of the form.

Page 5: Gambit Tutorial Guide

0.5 GUI Components

GAMBIT allows you to construct and mesh models by means of its graphical user interface (GUI), which is designed to be mouse-driven. The GAMBIT GUI (Figure 0-1) consists of eight components, each of which serves a separate purpose with respect to the creating and meshing of a model. The following sections briefly describe the GUI components.

Figure 0-1: The GAMBIT GUI

0.5.1 Graphics Window

The graphics window is the region of the GUI in which the model is displayed. It is located in the upper left portion of the GUI and occupies most of the screen in the default layout. Chapter 3 of the GAMBIT User's Guide presents a more detailed description of the graphics window.

0.5.2 Main Menu Bar

The main menu bar is located at the top of the GUI, directly above the graphics window. It contains four menu items. Each of the items is associated with its own menu of

Page 6: Gambit Tutorial Guide

commands that allow you to perform various GAMBIT operations. To open the menu associated with any item, left-click the item name (for example, File).

Chapter 4 of the GAMBIT User's Guide presents detailed descriptions of the menu items, as well as the commands available on each associated menu.

0.5.3 Operation Toolpad

The Operation toolpad is located in the upper right portion of the GUI. It consists of a field of command buttons, each of which performs a specific function associated with the process of creating and meshing a model.

Within the Operation toolpad, command buttons are grouped according to their hierarchy and purpose in the overall scheme of creating and meshing the model. The topmost group constitutes the main pad. All other command button groups constitute subpads.

Subpads

When you click a main-pad command button, GAMBIT opens an associated subpad. For example, if you click the GEOMETRY command button on the main pad, GAMBIT opens the Geometry subpad.

Each subpad contains command buttons that perform operations related to the overall purpose of the subpad. For example, the Geometry subpad contains command buttons that allow you to perform operations related to the creation and refinement of model geometry.

Some of the command buttons located on subpads open related subpads of their own. For example, when you click the VOLUME command button on the Geometry subpad, GAMBIT opens the Geometry/Volume subpad.

Each command button on the Geometry/Volume subpad is associated with a specification form that allows you to specify parameters related to the function indicated on the button.

Toolpad Command Buttons

Toolpad command buttons allow you to execute program commands related to building, meshing, or viewing the model and working with the GUI. Some toolpad command buttons cause a direct action to occur; others open specification forms.

All toolpad command buttons contain symbols representing their functions. Buttons that perform more than one function (multifunction command buttons) contain small, downward-pointing arrowheads in their lower left corners.

For complete descriptions of the GAMBIT GUI toolpad and command buttons, see Chapter 3 of the GAMBIT User's Guide.

Page 7: Gambit Tutorial Guide

Tutorial Convention--Toolpad Command Buttons

GAMBIT geometry and meshing procedures operate by means of specification forms. Each specification form is associated with a unique combination of GAMBIT toolpad command buttons.

This tutorial guide employs the following convention to indicate the command button combination associated with any specification form:

L1 -> L2 -> L3

where L1 represents the main-pad command button, and L2 and L3 represent the second- and third-level subpad command buttons, respectively. For example, the command button combination associated with the Create Real Brick form is as follows:

GEOMETRY -> VOLUME -> CREATE VOLUME

Note that the toolpad choices are indicated in two ways:

• The name of the command button that appears in the Description window of the GAMBIT GUI

• A picture of the command button

When you see this kind of flow chart in a tutorial, you should left-click the command buttons in the order shown so that they appear depressed. A command button has a black border on its top and left-hand side when it is depressed. The GEOMETRY command

button at the top of the Operation toolpad in Figure 0-1 is an example of a depressed button. The black border is on the bottom and right-hand side when the button

is not depressed; see the MESH command button in Figure 0-1. Note that if a button is already depressed, you need not click that button again. In fact, clicking a selected button will deselect it.

Toolpad choices that require pressing the right mouse button are indicated by an R to the right of the corresponding command button icon, followed by the icon to select from the

list of available functions. For example, R indicates that you should

right-click the CREATE VOLUME command button , then choose the CREATE REAL

CYLINDER option from the resulting list. CREATE REAL CYLINDER is the

Page 8: Gambit Tutorial Guide

text that is written in the Description window when you hold the mouse cursor over the

menu item.

0.5.4 Form Field

When you click any subpad command button (except UNDO), GAMBIT opens an associated specification form. Specification forms, such as that shown in Figure 0-2, allow you to specify parameters related to modeling and meshing operations, the assignment of boundary attributes, and the creation and manipulation of GAMBIT coordinate systems and grids.

Figure 0-2: Example GAMBIT specification form

When you open a specification form, it appears in the form field. The form field is located at the right side of the GUI, immediately below the Operation toolpad.

Text boxes allow you to input alphanumeric data. They are located on forms and appear as white, indented rectangles (for example, the Width text box in Figure 0-2). The title of any text box appears immediately to its left. To enter data by means of a text box, left-click in the box to enable it for user input, and then input the data from the keyboard.

0.5.5 Global Control Toolpad

The Global Control toolpad is located at the lower right corner of the GUI. Its purpose is to allow you to control the layout and operation of the graphics window as well as the appearance of the model as displayed in any particular quadrant. Section 3.4 of the GAMBIT User's Guide describes the function and use of each button on the Global Control toolpad.

0.5.6 Description Window

Page 9: Gambit Tutorial Guide

The Description window is located at the bottom of the GUI, immediately to the left of the Global Control toolpad. The purpose of the Description window is to display messages describing the various GUI components, including sashes, fields, windows, and command buttons.

Messages displayed in the Description window describe the component of the GUI corresponding to the current location of the mouse pointer. As you move the mouse pointer across the screen, GAMBIT updates the Description window message to reflect the change in the location of the pointer.

0.5.7 Transcript Window and Command Text Box

The Transcript window is located in the lower left portion of the GUI. The Command text box is located immediately below the Transcript window.

The purpose of the Transcript window is to display a log of commands executed and messages displayed by GAMBIT during the current modeling session. The Command text box allows you to perform GAMBIT modeling and meshing operations by means of direct keyboard input, rather than by means of mouse operations on the GUI. See the GAMBIT Command Reference Guide for more details.

© Fluent, Inc. 10/26/99

Page 10: Gambit Tutorial Guide

1. CREATING AND MESHING BASIC GEOMETRY

This tutorial illustrates geometry creation and mesh generation for a simple geometry using GAMBIT.

In this tutorial you will learn how to:

• Start GAMBIT • Use the Operation toolpad • Create a brick and an elliptical cylinder • Unite two volumes • Manipulate the display of your model • Mesh a volume • Examine the quality of the mesh • Save the session and exit GAMBIT

1.1 Prerequisites

This tutorial assumes you have no prior experience of working with GAMBIT. You should, however, read Chapter 0, "Using This Tutorial Guide," to familiarize yourself with the GAMBIT interface and with conventions used in the tutorial instructions.

1.2 Problem Description

The model consists of an intersecting brick and elliptical cylinder. The basic geometry is shown schematically in Figure 1-1.

Page 11: Gambit Tutorial Guide

Figure 1-1: Problem specification

1.3 Strategy

This first tutorial illustrates some of the basic operations for generating a mesh using GAMBIT. In particular, it demonstrates:

• How to build the geometry easily using the "top-down" solid modeling approach • How to create a hexahedral mesh automatically

The "top-down" approach means that you will construct the geometry by creating volumes (bricks, cylinders, etc.) and then manipulating them through Boolean operations (unite, subtract, etc.). In this way, you can quickly build complicated shapes without first creating the underlying vertices, edges, and faces.

Once you have built a valid geometry model, you can directly and (in many cases) automatically create the mesh. In this example, the Cooper meshing algorithm is used to automatically create an unstructured, hexahedral mesh. More complicated geometries may require some manual decomposition before you can create the mesh; this is demonstrated in subsequent tutorials.

The steps you will follow in this tutorial are listed below:

• Create two volumes (a brick and an elliptical cylinder). • Unite the two volumes. • Automatically generate the mesh.

Page 12: Gambit Tutorial Guide

• Examine the quality of the resulting mesh.

To keep this introductory tutorial short and simple, certain steps that you would normally follow have been omitted:

• Adjusting the distribution of nodes on individual edges of the geometry • Setting continuum types (for example, identifying which mesh zones are fluid and

which are solid) and boundary types

These details, as well as others, are covered in subsequent tutorials.

1.4 Procedure

Type

gambit -id basgeom

to start GAMBIT.

This opens the GAMBIT graphical user interface (GUI). (See Figure 1-2.) GAMBIT

uses the name you specify (in this example, basgeom) as a prefix to all files it creates: for

example, basgeom.jou.

Page 13: Gambit Tutorial Guide

Figure 1-2: The GAMBIT graphical user interface (GUI)

Step 1: Create a Brick

1. Create a brick by doing the following:

a) In the Operation toolpad (located in the top right corner of the GAMBIT GUI), select

the GEOMETRY command button by clicking on it with the left mouse button. If the Geometry subpad does not appear when you select the GEOMETRY command button, click it again.

The name of a command button is displayed in the Description window at the bottom of the GAMBIT GUI when you hold the mouse cursor over the command button. The GEOMETRY command button will appear depressed when it is selected. Selecting the GEOMETRY command button opens the Geometry subpad. Note that when you first start GAMBIT, the GEOMETRY command button is selected by default.

b) Use the left mouse button to select the VOLUME command button in the Geometry subpad.

Page 14: Gambit Tutorial Guide

Again, this command button will be depressed when selected. Selecting this command

button opens the Geometry/Volume subpad.

c) Use the left mouse button to select the CREATE VOLUME command button in the Geometry/Volume subpad.

This opens the Create Real Brick form.

The above description of selecting command buttons can be shortened to the following:

GEOMETRY -> VOLUME -> CREATE VOLUME

The selection of the command buttons will be represented using this method for the remainder of this tutorial, and in all subsequent tutorials.

d) Left-click in the text entry box to the right of Width in the Create Real Brick form, and

enter a value of 10 for the Width of the brick.

e) Use the Tab key on the keyboard to move to the Depth text entry box, and enter 6 for the Depth of the brick.

The text entry box for Height can be left blank; GAMBIT will set this value to be the same value as the Width by default.

f) Select Centered from the option menu to the right of Direction.

i) Hold down the left mouse button on the option button to the right of Direction until the option menu appears.

Page 15: Gambit Tutorial Guide

ii) Select Centered from the list.

g) Click Apply.

A message appears in the Transcript window at the bottom left of the GAMBIT GUI to

indicate that a volume, called volume.1, was created. The volume will be visible in the graphics window, as shown in Figure 1-3.

If you make a mistake at any point in the geometry creation process, you can use the

UNDO command button to undo multiple levels of geometry creation. At this point,

you have only performed one operation, so you can only undo one operation.

Figure 1-3: Rectangular brick volume (side view)

Step 2: Create an Elliptical Cylinder

1. Create an elliptical cylinder.

a) Hold down the right mouse button while the cursor is on the CREATE VOLUME command button.

b) Select the CREATE REAL CYLINDER option from the resulting menu.

! CREATE REAL CYLINDER is the text that is written in the Description window when you

hold the mouse cursor over the menu item.

This opens the Create Real Cylinder form.

Page 16: Gambit Tutorial Guide

The above method of selecting command buttons can be shortened to the following:

GEOMETRY -> VOLUME -> CREATE VOLUME R

where R indicates a toolpad choice using the right mouse button.

c) Enter a Height of 10.

d) Enter a value of 3 for Radius 1.

e) Enter a value of 6 for Radius 2.

f) Retain the default Axis Location of Positive Z.

g) Click Apply.

The brick and elliptical cylinder are shown in Figure 1-4.

Page 17: Gambit Tutorial Guide

Figure 1-4: Brick and elliptical cylinder

Step 3: Unite the Two Volumes

1. Unite the brick and elliptical cylinder into one volume.

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

This opens the Unite Real Volumes form.

Notice that the top Volumes list box is yellow in the Unite Real Volumes form at this point. The yellow color indicates that this field is active, and any volume selected will be

entered into this box on the form.

a) Hold down the Shift key on the keyboard and select the brick by clicking on one of its edges in the graphics window using the left mouse button.

! The Shift key must always be held down when selecting entities in the graphics window using the left mouse button. This operation will be referred to as Shift-left-click in all further steps.

Page 18: Gambit Tutorial Guide

The brick will appear red in the graphics window and its name (volume.1) will appear in the Volumes list box in the Unite Real Volumes form.

b) Shift-left-click the elliptical cylinder in the graphics window.

c) Click Apply to accept the selection and unite the elliptical cylinder and brick.

! Alternatively, you could continue to hold down the Shift key and click the right mouse button in the graphics window to accept the selection of the volumes. This method allows

you to rapidly accept selections and apply operations with minimal movement of the

mouse.

! The Shift key must always be held down when clicking the right-mouse button to accept the selection of entities in the graphics window. This operation is referred to as Shift-

right-click.

The volume is shown in Figure 1-5. You can rotate the display (as shown in Figure 1-5)

by holding down the left mouse button in the graphics window and moving the mouse to

the left. More information on manipulating the graphics display is given in the next step.

Figure 1-5: Brick and elliptical cylinder united into one volume

Step 4: Manipulate the Display

1. Zoom out from the current view by holding down the right mouse button in the graphics window and pushing the mouse away from you.

2. Rotate the view around the screen center by holding down the right mouse button and moving the mouse from side to side.

Page 19: Gambit Tutorial Guide

3. Rotate the view in free-form mode by holding down the left mouse button and moving the mouse.

4. Translate the display by holding down the middle mouse button and moving the mouse.

5. Divide the graphics window into four quadrants by clicking the SELECT PRESET

CONFIGURATION command button in the Global Control toolpad.

GAMBIT divides the graphics window into four quadrants and applies a different orientation to the model in each of the four quadrants. Each view of the graphics window

can be manipulated independently. All changes to the model appear in all portions of the

graphics window, unless you disable one or more quadrants.

Figure 1-6: GAMBIT GUI-four graphics-window quadrants

6. Restore a single display of the model.

a) Use the left mouse button to select the graphics-window "sash anchor"-the small gray box in the center of the graphics window.

Page 20: Gambit Tutorial Guide

b) Use the mouse to drag the sash anchor to the bottom right corner of the graphics window.

7. Restore the front view of the model by left-clicking the ORIENT MODEL command button in the Global Control toolpad.

8. Scale the model to fit the graphics window by clicking the FIT TO WINDOW command button in the Global Control toolpad.

Step 5: Mesh the Volume

1. Create a mesh for the volume.

MESH -> VOLUME -> MESH VOLUMES

This opens the Mesh Volumes form.

a) Shift-left-click the volume in the graphics window.

GAMBIT will automatically choose the Cooper Scheme Type as the meshing tool to be

used, and will use an Interval size of 1 (the default) under Spacing. See the GAMBIT Modeling Guide, Chapter 3 for details about the Cooper meshing tool.

b) Click Apply at the bottom of the Mesh Volumes form.

Page 21: Gambit Tutorial Guide

This accepts the volume you selected as the one to be meshed. It also accepts the source

faces (the faces whose surface meshes are to be swept through the volume to form volume

elements) that GAMBIT has chosen for the Cooper meshing scheme and starts the meshing. A status bar appears at the top of the GAMBIT GUI to indicate how much of the meshing is complete.

The volume will be meshed as shown in Figure 1-7.

Figure 1-7: Meshed volume

Step 6: Examine the Mesh

It is important that you check the quality of the resulting mesh, because properties such

as skewness can greatly affect the accuracy and robustness of the CFD solution.

GAMBIT provides several quality measures (sometimes called "metrics") with which you can assess the quality of your mesh. In the case of skewness measures such as EquiAngle Deviation and EquiVolume Deviation, for example, smaller values are more desirable. It is also important to verify that all of the elements in your mesh have positive area/volume.

You should consult the documentation for the target CFD solver for additional mesh

quality guidelines.

1. Select the EXAMINE MESH command button at the bottom right of the Global Control toolpad.

This opens the Examine Mesh form.

Page 22: Gambit Tutorial Guide

a) Select Range under Display Type at the top of the Examine Mesh form.

A histogram appears at the bottom of the form. The histogram consists of a bar chart

representing the statistical distribution of mesh elements with respect to the specified

Quality Type. Each vertical bar on the histogram corresponds to a unique set of upper and lower quality limits.

The 3D Element type selected by default at the top of the form is a brick .

b) Select EquiAngle Skew from the Quality Type option menu.

Page 23: Gambit Tutorial Guide

c) Click on one of the green vertical bars in the histogram to view elements within a certain quality range.

Each element has a value of skewness between 0 and 1, where 0 represents an ideal

element. The histogram is divided into 10 bars; each bar represents a 0.1 increment in

the skewness value. For a good mesh, the bars on the left of the histogram will be large

and those on the right will be small.

Figure 1-8 shows the view in the graphics window if you click on the fifth bar from the left on the histogram (representing cells with a skewness value between 0.4 and 0.5).

Figure 1-8: Elements of the mesh within a specified quality range

d) Move the Upper and Lower slider boxes beneath the histogram to redefine the quality range to be displayed.

Step 7: Save the Session and Exit GAMBIT

1. Save the GAMBIT session and exit GAMBIT.

File-> Exit

GAMBIT will ask you whether you wish to save the current session before you exit.

Page 24: Gambit Tutorial Guide

Click Yes to save the current session and exit GAMBIT.

1.5 Summary

This tutorial provided a quick introduction to GAMBIT by demonstrating how to create a simple 3-D geometry using the "top-down" modeling approach. The Cooper scheme was used to automatically generate an unstructured, hexahedral mesh. For more information on the Cooper scheme, consult the GAMBIT Modeling Guide.

© Fluent, Inc. 10/27/99

Page 25: Gambit Tutorial Guide

2. MODELING A MIXING ELBOW (2-D)

In this tutorial, you will use GAMBIT to create the geometry for a mixing elbow and then generate a mesh. The mixing elbow configuration is encountered in piping systems in power plants and process industries. It is often important to predict the flow field and temperature field in the neighborhood of the mixing region in order to properly design the location of inlet pipes.

In this tutorial you will learn how to:

• Create vertices using a grid system • Create arcs by selecting the center of curvature and the endpoints of the arc • Create straight edges between vertices • Split an arc using a vertex point • Create faces from edges • Specify the distribution of nodes on an edge • Create structured meshes on faces • Set boundary types • Prepare the mesh to be read into FLUENT 4 • Export a mesh

2.1 Prerequisites

This tutorial assumes that you have worked through Tutorial 1 and you are consequently familiar with the GAMBIT interface.

2.2 Problem Description

The problem to be considered is shown schematically in Figure 2-1. A cold fluid enters through the large pipe and a warmer fluid enters through the small pipe. The two fluids mix in the elbow.

Page 26: Gambit Tutorial Guide

Figure 2-1: Problem specification

2.3 Strategy

In this tutorial, you will build a 2-D mesh using a "bottom-up" approach (in contrast to the "top-down" approach used in Tutorial 1). The "bottom-up" approach means that you will first create some vertices, connect the vertices to create edges, and connect the edges to make faces (in 3-D, you would stitch the faces together to create volumes). While this process by its very nature requires more steps, the result is, just as in Tutorial 1, a valid geometry that can be used to generate the mesh.

The mesh created in this tutorial is intended for use in FLUENT 4, so it must be a single block, structured mesh. However, this mesh can also be used in any of the other Fluent solvers. This type of mesh is sometimes called a mapped mesh, because each grid point has a unique I, J, K index. In order to meet this criterion, certain additional steps must be performed in GAMBIT and are illustrated in this tutorial. After creating the straight edges and arcs that comprise the geometry, you will create two faces: one for the main flow passage (the elbow) and one for the smaller inlet duct. The mesh is generated for the larger face using the Map scheme; this requires that the number of grid nodes be equal on opposite edges of the face. You will force GAMBIT to use the Map scheme to mesh the smaller face as well.

Several other features are also demonstrated in this tutorial:

• Using a background grid and "snap-to-grid" to quickly create a set of vertices. • Using "pick lists" as an alternative to mouse clicks for picking entities. • Specifying a non-uniform distribution of nodes on an edge.

Page 27: Gambit Tutorial Guide

• Setting boundary types. • Exporting a mesh for a particular Fluent solver (FLUENT 4 in this case).

2.4 Procedure

Start GAMBIT.

Step 1: Select a Solver

1. Choose the solver you will use to run your CFD calculation by selecting the following from the main menu bar:

Solver ->FLUENT 4

This selects the FLUENT 4 solver as the one to be used for the CFD calculation. The choice of a solver dictates the options available in various forms (for example, the

boundary types available in the Specify Boundary Types form). The solver currently selected is indicated at the top of the GAMBIT GUI.

Step 2: Create the Initial Vertices

1. Create vertices to define the outline of the large pipe of the mixing elbow.

TOOLS -> COORDINATE SYSTEM -> DISPLAY GRID

This opens the Display Grid form.

Page 28: Gambit Tutorial Guide

a) Check that Visibility is selected.

This ensures that the background grid will be visible when it is created.

b) Select X (the default) to the right of Axis.

c) Enter a Minimum value of -32, a Maximum value of 32, and an Increment of 16.

d) Click the Update list button.

This creates a background grid with four cells in the x direction and enters the x

coordinates in the XY_plane X Values list.

e) Select Y to the right of Axis.

f) Enter a Minimum value of -32, a Maximum value of 32, and an Increment of 16.

g) Click the Update list button.

Page 29: Gambit Tutorial Guide

This creates a background grid with four cells in the y direction and enters the y

coordinates in the XY_plane Y Values list.

h) Check that Snap is selected under Options.

The vertices you create later in this step will be "snapped" to points on the grid where the

grid lines intersect.

i) Select Lines (the default) to the right of Grid.

The grid will be displayed using lines rather than points.

j) Click Apply.

GAMBIT will draw a 4x4 grid in the graphics window as shown in Figure 2-2. You will

need to click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the whole grid. You may need to move the Display Grid form in order to access the Global Control toolpad.

Figure 2-2: 44 grid to be used for creating vertices

k) Ctrl-right-click the nine grid points shown in Figure 2-3.

"Ctrl-right-click" indicates that you should hold down the Ctrl key on the keyboard and click on the point at which the vertex is to be created using the right mouse button.

You can use the UNDO command button if you create any of the vertices

incorrectly.

Page 30: Gambit Tutorial Guide

Figure 2-3: Create vertices at grid points

l) Deselect the Visibility check box in the Display Grid form and click Apply.

The grid will be removed from the graphics window and you will be able to clearly see

the nine vertices created, as shown in Figure 2-4.

Figure 2-4: Vertices for the main pipe

Step 3: Create Arcs for the Bend of the Mixing Elbow

1. Create an arc by selecting the following command buttons in order:

Page 31: Gambit Tutorial Guide

GEOMETRY -> EDGE -> CREATE EDGE R

This opens the Create Real Circular Arc form.

a) Retain the default Method.

Notice that the Center list box is yellow in the Create Real Circular Arc form at this point. The yellow color indicates that this is the active field in the form, and any vertex selected

will be entered into this box on the form.

b) Shift-left-click the vertex in the center of the graphics window (vertex E in Figure 2-5).

The selected vertex will appear red in the graphics window and its name will appear in

the Center list box under Vertices in the form.

Page 32: Gambit Tutorial Guide

Figure 2-5: Vertices used to create arcs

c) Left-click in the list box to the right of End-Points to accept the selection of vertex E and make the End-Points list box active.

! Alternatively, you could continue to hold down the Shift key and click the right mouse button in the graphics window to accept the selection of the vertex and move the focus to

the End-Points list box.

Note that the End-Points list box is now yellow-that is, this is now the active list box, and any vertex selected will be entered in this box.

d) Shift-left-click the vertex to the right of the center vertex in the graphics window (vertex F in Figure 2-5).

The vertex will turn red.

e) Select the vertex directly below the one in the center of the graphics window (vertex D in Figure 2-5).

f) Click Apply to accept the selected vertices and create the arc.

2. Repeat the above steps to create a second arc. The center of the arc is the vertex in the center of the graphics window (vertex E in Figure 2-5). The endpoints of the arc are the vertices to the right and below the center vertex that have not yet been selected (vertices G and B, respectively, in Figure 2-5). The arcs are shown in Figure 2-6.

Page 33: Gambit Tutorial Guide

Figure 2-6: Vertices and arcs

Step 4: Create Straight Edges

1. Create straight edges for the large pipe.

GEOMETRY -> EDGE -> CREATE EDGE R

This opens the Create Straight Edge form.

a) Shift-left-click the left endpoint of the smaller arc (vertex D in Figure 2-7).

Page 34: Gambit Tutorial Guide

Figure 2-7: Vertices used to create straight edges

b) Shift-left-click the vertices marked C, A, and B in Figure 2-7, in order.

c) Click Apply to accept the selection of the vertices.

Three straight edges are drawn between the vertices.

d) Shift-left-click the vertices marked F, H, I, and G in Figure 2-7, in order.

e) Click Apply to accept the selection of the vertices.

The graphics window with the arcs and straight edges is shown in Figure 2-8.

Page 35: Gambit Tutorial Guide

Figure 2-8: Arcs and edges

Step 5: Create the Small Pipe for the Mixing Elbow

In this step, you will create vertices on the outer radius of the bend of the mixing elbow

and split the large arc into three smaller arcs. Next, you will create vertices for the inlet

of the small pipe. Finally, you will create the straight edges for the small pipe.

1. Create vertices on the outer radius of the bend, and split the large arc into three sections.

GEOMETRY -> EDGE -> SPLIT/MERGE EDGES

This opens the Split Edge form.

Page 36: Gambit Tutorial Guide

a) Select the large arc as the edge to split by using the Edge pick list.

Note that you could select the edge in the graphics window; a pick list provides an

alternate way of picking an element.

i. Left-click the black arrow to the right of the Edge list box in the Split Edge form.

This opens the Edge List form. There are two types of pick-list forms: Single and Multiple. In a Single pick-list form, only one entity can be selected at a time. In a Multiple pick-list form, you can select multiple entities.

Page 37: Gambit Tutorial Guide

ii. Select edge.2 under Available in the Edge List form.

! Note that the Available names may be different in your geometry, depending on the order in which you created the edges.

iii. Click the > button to pick edge.2.

edge.2 will be moved from the Available list to the Picked list. The large arc is the edge that should be selected and shown in red in the graphics window.

iv. Close the Edge List form.

This method of selecting an entity can be used as an alternative to Shift-left-click in the graphics window. See the GAMBIT User's Guide for more information on pick lists.

b) Select Real connected (the default) under Type in the Split Edge form.

You should select this option because the edge you selected is real geometry, not virtual

geometry, and because you want the two edges created by the split to share the vertex

created when GAMBIT does the split. See the GAMBIT Modeling Guide for more

information on real and virtual geometry.

c) Select Point (the default) to the right of Split With.

You will split the edge by creating a point on the edge and then using this point to split

the edge.

d) Select Cylindrical from the Type option menu.

You can now use cylindrical coordinates to specify where GAMBIT should split the edge.

e) Input a value of -39.93 degrees next to t under Local.

This is the angle between the horizontal direction and the position of the right-hand side

of the opening of the small pipe on the bend of the mixing elbow, as shown in Figure 2-1.

f) Click Apply.

The large arc is split into two smaller arcs and a vertex is created.

g) Use the Edge List form (or Shift-left-click in the graphics window) to select the larger of the two arcs just created (edge.9).

h) Input a value of -50.07 degrees next to t under Local.

Page 38: Gambit Tutorial Guide

This is the angle between the horizontal direction and the position of the left-hand side of

the opening of the small pipe on the bend of the mixing elbow (-90 + 39.93), as shown in

Figure 2-1.

i) Click Apply.

The arc is split into two parts and a second vertex is created on the bend of the mixing

elbow, as shown in Figure 2-9.

Figure 2-9: Vertices created on outer radius of mixing elbow bend

2. Create points at the small inlet.

GEOMETRY -> VERTEX -> MOVE/COPY VERTICES

This opens the Move / Copy Vertices form.

Page 39: Gambit Tutorial Guide

a) Select the second vertex created on the bend of the mixing elbow.

b) Select Copy under Vertices in the Move / Copy Vertices form.

c) Select Translate (the default) under Operation.

d) Enter the translation vector (0, -12, 0) under Global to create the new vertex at a position 12 units below the vertex you selected.

The inlet is 12 units below the second point created on the outer radius of the bend.

Note that GAMBIT automatically fills in the values under Local as you enter values under Global.

e) Click Apply.

f) Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to scale the model to fit into the graphics window.

g) Select the vertex just created in the graphics window.

h) Enter the translation vector (4, 0, 0) under Global in the Move / Copy Vertices form to create the new vertex at a position 4 units to the right of the vertex you selected.

Page 40: Gambit Tutorial Guide

i) Click Apply.

The vertices are shown in Figure 2-10.

Figure 2-10: Vertices to define the small pipe

3. Create straight edges for the small pipe.

GEOMETRY -> EDGE -> CREATE EDGE

This opens the Create Straight Edge form.

a) Create straight edges for the small pipe by selecting the vertices marked K, L, M, and J in Figure 2-11, in order, and accepting the selection.

Page 41: Gambit Tutorial Guide

Figure 2-11: Vertices to be used to create small pipe

The small pipe is shown (with the large pipe) in Figure 2-12.

Figure 2-12: Completed small pipe

Step 6: Create Faces from Edges

1. Create a face for the large pipe.

GEOMETRY -> FACE -> FORM FACE

This opens the Create Face From Wireframe form.

Page 42: Gambit Tutorial Guide

a) Shift-left-click each edge of the large pipe, in turn, to form a continuous loop.

! The large pipe is created from the 10 edges shown in Figure 2-13. If you select an incorrect edge, click Reset in the Create Face From Wireframe form to deselect all edges, and then reselect the correct edges.

Figure 2-13: Edges used to create face for large pipe

Note that the edges must form a continuous loop, but they can be selected in any order.

An alternative method to select several edges is to Shift-left-drag a box around the edges. The box does not have to completely enclose the edges; it only needs to enclose a portion

of an edge to select it. The edges will be selected when you release the mouse button.

b) Click Apply to accept the selected edges and create a face.

The edges of the face will turn blue.

Page 43: Gambit Tutorial Guide

2. Create a face for the small pipe by selecting the four edges shown in Figure 2-14 and then accepting the selected edges.

Figure 2-14: Edges used to create face for small pipe

Step 7: Specify the Node Distribution

The next step is to define the grid density on the edges of the geometry. You will

accomplish this graphically by selecting an edge, assigning the number of nodes, and

specifying the distribution of nodes along the edge.

1. Specify the node density on the inlet and outlet of the large pipe.

MESH -> EDGE -> MESH EDGES

This opens the Mesh Edges form.

Page 44: Gambit Tutorial Guide

a) Shift-left-click the edge marked EA in Figure 2-15.

Figure 2-15: Edges to be meshed

The edge will change color and an arrow and several circles will appear on the edge.

Page 45: Gambit Tutorial Guide

b) Shift-left-click the edge marked EB in Figure 2-15.

c) Check that Apply is selected to the right of Grading in the Mesh Edges form and that Successive Ratio is selected in the Type option menu.

The Successive Ratio option sets the ratio of distances between consecutive points on the edge equal to the specified Ratio.

d) Enter 1.25 in the text entry box to the right of Ratio.

Alternatively, you can slide the Ratio slider box (the small, gray rectangle with a vertical

line in its center that is located on the slider bar) until 1.25 is displayed in the Ratio text box.

e) Select the Double sided check box under Grading.

If you specify a Double sided grading on an edge, the element intervals are graded in two directions from a starting point on the edge. GAMBIT determines the starting point such that the intervals on either side of the point are approximately the same length.

Note that Ratio changes to Ratio 1 and Ratio 2 when you select the Double sided check box. In addition, the value you entered for Ratio is automatically entered into both the Ratio 1 and the Ratio 2 text entry boxes.

f) Select Interval count from the option menu under Spacing and enter a value of 10 in the text entry box. Check that Apply is selected to the right of Spacing.

GAMBIT will create 10 intervals on the edge.

g) Click the Apply button at the bottom of the form.

Figure 2-16 shows the mesh on the inlet and outlet edges of the large pipe.

Page 46: Gambit Tutorial Guide

Figure 2-16: Edge meshing on inlet and outlet of large pipe

2. Mesh the four straight edges of the large pipe.

a) Select the edges marked EC, ED, EE, and EF in Figure 2-16.

b) Check that Apply is selected to the right of Grading in the Mesh Edges form and click the Default button to the right of Grading.

GAMBIT will deselect the Double-sided check box and set the Ratio to 1.

c) Check that Apply is selected to the right of Spacing and select Interval count from the option menu.

d) Enter a value of 15 in the text entry box below Spacing and click the Apply button at the bottom of the form.

Figure 2-17 shows the mesh on the straight edges of the large pipe.

Page 47: Gambit Tutorial Guide

Figure 2-17: Mesh on the straight edges of the large pipe

3. Mesh the edge connecting the two pipes.

a) Select the edge marked EG in Figure 2-17.

b) Check that Apply is selected to the right of Grading in the Mesh Edges form and enter a

value of 1 for the Ratio.

c) Check that Apply is selected to the right of Spacing, select Interval count from the option

menu, and enter a value of 6 in the text entry box below Spacing.

d) Click the Apply button at the bottom of the form.

4. Mesh the two edges on the outer radius of the bend of the mixing elbow.

a) Select the edge marked EH in Figure 2-17. The arrow should point towards the small pipe. Shift-middle-click the edge to reverse the direction of the arrow if necessary.

! The arrow is small and you may have to zoom into the edge to see it. It is located near the center of the edge.

b) Select the edge marked EI in Figure 2-17. The arrow should point towards the small pipe. Shift-middle-click the edge to reverse the direction of the arrow if necessary.

c) Check that Apply is selected to the right of Grading in the Mesh Edges form and enter a

value of 0.9 for the Ratio.

Page 48: Gambit Tutorial Guide

d) Check that Apply is selected to the right of Spacing, select Interval count from the option

menu, and enter a value of 12 in the text entry box below Spacing.

e) Click the Apply button at the bottom of the form.

The mesh on the two edges on the outer radius of the bend is shown in Figure 2-18.

Figure 2-18: Mesh on outer bend of pipe

5. Set the grading for the inner bend of the mixing elbow.

Page 49: Gambit Tutorial Guide

a) Select the edge marked EJ in Figure 2-18.

b) Check that Apply is selected to the right of Grading in the Mesh Edges form and enter a

value of 0.85 for the Ratio.

c) Select the Double sided check box.

d) Deselect the Apply check box to the right of Spacing.

You will not set a spacing on this edge, instead you will let GAMBIT calculate the spacing for you when it meshes the face. You will mesh the face using a mapped mesh, so

the number of nodes on the inner bend of the mixing elbow must equal the number of

nodes on the outer bend, and GAMBIT will determine the correct number of nodes for you automatically.

e) Deselect the Mesh check box under Options and click the Apply button at the bottom of the form.

You deselected the Mesh check box because at this point you do not want to mesh the edge; you only want to apply the Grading to the edge. GAMBIT will mesh the edge using the specified Grading when it meshes the large pipe of the mixing elbow in the next step.

Figure 2-19 shows the edge meshing for the mixing elbow geometry.

Page 50: Gambit Tutorial Guide

Figure 2-19: Edge meshing for the mixing elbow

Step 8: Create Structured Meshes on Faces

1. Create a structured mesh for the large pipe.

MESH -> FACE -> MESH FACES

This opens the Mesh Faces form.

a) Shift-left-click the large pipe in the graphics window.

Page 51: Gambit Tutorial Guide

Note that four of the vertices on this face are marked with an "E" in the graphics window; they are End vertices. Therefore, GAMBIT will select the Map Type of Scheme in the Mesh Faces form. See the GAMBIT Modeling Guide for more information on Map meshing.

b) Click the Apply button at the bottom of the form.

GAMBIT will ignore the Interval size of 1 under Spacing, because the mapped meshing scheme is being used and the existing edge meshing fully determines the mesh on all

edges.

Notice that GAMBIT calculates the number of nodes on the inner bend of the mixing elbow and displays these nodes before creating the mesh on the face. The face will be

meshed as shown in Figure 2-20.

Figure 2-20: Structured mesh on the large pipe of the mixing elbow

2. Mesh the small pipe of the mixing elbow.

a) Select the small pipe in the graphics window.

You will force GAMBIT to use the Map scheme to mesh the smaller face.

b) In the Mesh Faces form, select Quad from the Elements option menu under Scheme and Map from the option menu to the right of Type.

This is an example of "enforced mapping", where GAMBIT automatically modifies the face vertex type on the face to satisfy the chosen meshing scheme. See the GAMBIT Modeling Guide for more information on face vertex types.

Page 52: Gambit Tutorial Guide

c) Retain the default Interval size of 1 under Spacing and click the Apply button at the bottom of the form.

The structured mesh for the entire elbow is shown in Figure 2-21.

Figure 2-21: Structured mesh for the mixing elbow

Step 9: Set Boundary Types

1. Remove the mesh from the display before you set the boundary types.

This makes it easier to see the edges and faces of the geometry. The mesh is not deleted,

just removed from the graphics window.

a) Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad.

b) Select Off from the option menu to the right of Mesh near the bottom of the form.

c) Click Apply and close the form.

2. Set boundary types for the mixing elbow.

ZONES -> SPECIFY BOUNDARY TYPES

This opens the Specify Boundary Types form.

Page 53: Gambit Tutorial Guide

Note that FLUENT 4 is shown as the chosen solver at the top of the form. The Specify Boundary Types form displays different Types depending on the solver selected.

a) Define two inflow boundaries.

i. Enter the name inflow1 in the Name text entry box.

If you do not specify a name, GAMBIT will give the boundary a default name based on what you select in the Type and Entity lists.

ii. Select INFLOW in the Type option menu.

iii. Change the Entity to Edges by selecting Edges in the option menu below Entity.

iv. Shift-left-click the main inflow for the mixing elbow in the graphics window (marked EA in Figure 2-22) and click Apply to accept the selection.

Page 54: Gambit Tutorial Guide

Figure 2-22: Boundary types for edges of mixing elbow

This edge will be set as an inflow boundary.

v. Enter inflow2 in the Name text entry box.

vi. Check that INFLOW is still selected in the Type option menu and select the edge marked EK in Figure 2-22 (the inlet for the small pipe). Click Apply to accept the selection of the edge.

b) Define an outflow boundary.

1. Enter outflow in the Name text entry box. 2. Change the Type to OUTFLOW by selecting OUTFLOW in the option menu below

Type. 3. Select the main outflow for the mixing elbow (the edge marked EB in Figure 2-

22) and click Apply to accept the selection.

The inflow and outflow boundaries for the mixing elbow are shown in Figure 2-23.

Page 55: Gambit Tutorial Guide

Figure 2-23: Inflow and outflow boundaries for the mixing elbow

Note that you could also specify the remaining outer edges of the mixing elbow as wall

boundaries. This is not necessary, however, because when GAMBIT saves a mesh, any edges (in 2-D) on which you have not specified a boundary type will be written out as

wall boundaries by default. In addition, when GAMBIT writes a mesh, any faces (in 2-D) on which you have not specified a continuum type will be written as FLUID by default. This means that you do not need to specify a continuum type in the Specify Continuum Types form for this tutorial.

Step 10: Export the Mesh and Save the Session

1. Export a mesh file for the mixing elbow.

File -> Export -> Mesh…

This opens the Export Mesh File form. Note that the File Type is Structured FLUENT 4 Grid.

a) Enter the File Name for the file to be exported (2-DELBOW.GRD).

b) Click Accept.

The file will be written to your working directory.

Page 56: Gambit Tutorial Guide

2. Save the GAMBIT session and exit GAMBIT.

File -> Exit

GAMBIT will ask you whether you wish to save the current session before you exit.

Click Yes to save the current session and exit GAMBIT.

2.5 Summary

This tutorial shows you how to generate a 2-D mesh using the "bottom-up" approach. Since the mesh is to be used in FLUENT 4, it was generated in a single block, structured fashion. Several other features that are commonly used for 2-D mesh generation were also demonstrated, including entering vertices using a background grid, creating straight edges and arcs, and specifying node distributions on individual edges. As compared to Tutorial 1, which omitted some details, all steps required to create a mesh ready to read into the solver were covered, including how to set boundary types, choose a specific Fluent solver, and finally write out the mesh file.

© Fluent, Inc. 10/27/99

Page 57: Gambit Tutorial Guide

3. MODELING A THREE-PIPE INTERSECTION (3-D)

This tutorial employs "primitives"-that is, predefined GAMBIT modeling components and procedures. There are two types of GAMBIT primitives:

• Geometry • Mesh

Geometry primitives are volumes possessing standard shapes-such as bricks, cylinders, and spheres. Mesh primitives are standard mesh configurations.

In this tutorial, you will use geometry primitives to create a three-pipe intersection. You will decompose this geometry into four parts and add boundary layers. Finally, you will mesh the three-pipe intersection and will employ a mesh primitive to mesh one part of the decomposed geometry.

In this tutorial you will learn how to:

• Create volumes by defining their dimensions • Split a volume • Use GAMBIT journal files • Add boundary layers to your geometry • Prepare the mesh to be read into POLYFLOW

3.1 Prerequisites

This tutorial assumes you have worked through Tutorial 1 and you are consequently familiar with the GAMBIT interface.

3.2 Problem Description

The problem to be considered is shown schematically in Figure 3-1. The geometry consists of three intersecting pipes, each with a diameter of 6 units and a length of 4 units. The three pipes are orthogonal to each other. The geometry can be represented as three intersecting cylinders and a sphere octant at the corner of the intersection.

Page 58: Gambit Tutorial Guide

Figure 3-1: Problem specification

3.3 Strategy

In this tutorial, you will quickly create the basic geometry for a three-pipe intersection. The basic geometry can be automatically meshed with tetrahedra, but your goal in this tutorial is to create a conformal, hexahedral mesh for POLYFLOW, which requires some decomposition of the geometry before meshing. Thus, the tutorial shows some of the typical procedures for decomposing a complicated geometry into "meshable" volumes.

The first decomposition involves using a brick to split off a portion of the three-pipe intersection. The resulting volume is described as a sphere "octant" (one-eighth of a sphere) residing in the corner of the intersection, as shown in Figure 3-2. This volume, which is very similar in shape to a tetrahedron, will therefore be meshed using GAMBIT's Tet Primitive scheme. Note that this creates a hexahedral mesh in a tetrahedral topology; it does not create tetrahedral cells.

Page 59: Gambit Tutorial Guide

Figure 3-2: Decomposition of the three-pipe intersection geometry

The remaining geometry is then split into three parts, one for each pipe, as shown in Figure 3-1. To do this, you will create an edge and three faces that are used to split the volume into the required three parts. These volumes are meshed using GAMBIT's Cooper scheme (described in detail in the GAMBIT Modeling Guide). This tutorial illustrates three different ways to specify the source faces required by the Cooper scheme.

Two other helpful topics are covered in this tutorial: the use of journal files and the meshing of boundary layers. The journal file contains a record of all your command inputs to GAMBIT. This file can be edited and your inputs can be converted into variable parameters that allow subsequent geometries (with changes in key dimensions, for example) to be quickly created and meshed. The boundary layer meshing tools in GAMBIT allow you to control how the mesh is refined near walls and other boundaries.

3.4 Procedure

Start GAMBIT.

Step 1: Select a Solver

1. Choose the solver you will use to run your CFD calculation by selecting the following from the main menu bar:

Solver -> POLYFLOW

Page 60: Gambit Tutorial Guide

The choice of a solver dictates the options available in various forms (for example, the

boundary types available in the Specify Boundary Types form). The solver currently selected is indicated at the top of the GAMBIT GUI.

Step 2: Create the Geometry

1. Create the three pipes for the intersection.

GEOMETRY -> VOLUME -> CREATE VOLUME R

This opens the Create Real Cylinder form.

a) Create the first pipe.

i. Enter a Height of 10 in the Create Real Cylinder form.

ii. Enter 3 for Radius 1.

The text entry box for Radius 2 can be left blank; GAMBIT will set this value by default to be the same value as Radius 1.

iii. Select Positive Z (the default) in the list to the right of Axis Location.

iv. Click Apply.

b) Create the second pipe. Use the same Height and Radius 1 as above, and select Positive X in the list to the right of Axis Location.

c) Create the third pipe. Use the same Height and Radius 1 as above, and select Positive Y in the list to the right of Axis Location.

Page 61: Gambit Tutorial Guide

2. Click the FIT TO WINDOW command button , at the top left of the Global Control toolpad, to view all three cylinders.

You can rotate the view by holding down the left mouse button and moving the mouse.

The cylinders are shown in Figure 3-3.

Figure 3-3: Three cylinders for the three-pipe intersection

3. Create a sphere to complete the basic geometry.

GEOMETRY -> VOLUME -> CREATE VOLUME R

This opens the Create Real Sphere form.

a) Enter 3 for the Radius.

Page 62: Gambit Tutorial Guide

b) Click Apply.

4. Unite the four volumes into one volume.

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

This opens the Unite Real Volumes form.

a) Shift-left-click all of the volumes in the graphics window, and click Apply.

The volumes will be united into one volume. The completed geometry is shown in Figure

3-4.

Figure 3-4: The completed geometry

Step 3: Decompose the Geometry

It is possible to automatically mesh this full geometry using the TGrid scheme. However, it is not possible to automatically mesh this geometry with conformal hexahedra. In order

to generate a conformal hexahedral mesh, you must now decompose the geometry into

portions, each fulfilling the criteria of available hexahedral meshing schemes. In this

example, you will create a brick that will be used to split the three-pipe volume, forming

Page 63: Gambit Tutorial Guide

a sphere octant (one-eighth of a sphere) where the three pipes intersect. You will then

create an edge, and use it to form three faces inside the geometry. These faces will be

used to split the three-pipe intersection volume into three pipe sections.

1. Create a brick.

GEOMETRY -> VOLUME -> CREATE VOLUME R

This opens the Create Real Brick form.

a) Enter a value of 5 for the Width of the brick.

GAMBIT will set the Depth and the Height of the brick to be the same as the Width if no values are entered in these fields in the form.

b) Select -X -Y -Z in the list next to Direction.

c) Click Apply.

The view in the graphics window is shown in Figure 3-5.

Page 64: Gambit Tutorial Guide

Figure 3-5: Three-pipe geometry and brick

2. Split the volume and create a sphere octant volume where the three pipes intersect.

If you split one volume with another volume, the following volumes will result:

• Volumes corresponding to the common region(s) from intersection. • Volumes corresponding to the region(s) defined by subtracting the second volume

from the first.

In other words, splitting a volume results in a combination of the intersection and

subtraction Boolean operations. The order of selecting the volumes is important. For

example, Figure 3-6 shows the difference between splitting volume A using volume B,

and vice versa.

Page 65: Gambit Tutorial Guide

Figure 3-6: Splitting volumes

GEOMETRY -> VOLUME -> SPLIT/MERGE VOLUMES

This opens the Split Volume form.

a) Select the three-pipe volume in the graphics window.

Page 66: Gambit Tutorial Guide

b) Left-click in the list box to the right of Split With Volume to accept the selection of the three-pipe volume and make the Split With Volume list box active.

c) Select the brick and click Apply to accept the selection.

GAMBIT will split the three-pipe volume using the brick, leaving two volumes: the three pipes (volume.2) and the sphere octant (volume.3).

3. Create a straight edge inside the three-pipe volume.

GEOMETRY -> EDGE -> CREATE EDGE

This opens the Create Straight Edge form.

a) Shift-left-click the vertex at the origin (Gx, Gy, Gz).

b) Select the vertex that is shared by all three cylinders (x = y = z).

c) Click Apply to accept the selected vertices and create an edge between them.

The edge is shown in Figure 3-7 and will appear yellow in the graphics window.

Page 67: Gambit Tutorial Guide

Figure 3-7: Straight edge created inside the volume

4. Create faces inside the three-pipe volume.

GEOMETRY -> FACE -> FORM FACE

This opens the Create Face From Wireframe form.

a) Create a face inside the geometry using the edge created in the previous step.

i. Select the edge created in the previous step.

ii. Select a curved edge on one of the cylindrical surfaces that is connected to the edge just selected.

iii. Select the edge that closes the loop.

Page 68: Gambit Tutorial Guide

The three edges to be selected are shown in Figure 3-8.

Figure 3-8: Three edges used to create a face

iv. Click Apply to accept the selection and create a face.

The edge created in the previous step will turn blue.

b) Create a second face by selecting the blue edge, a different curved edge connected to the blue edge, and the edge that closes the loop.

c) Create a third face by selecting the blue edge, the third curved edge connected to the blue edge, and the edge that closes the loop.

The three faces are shown in Figure 3-9. It may be useful to remove the volumes from the

display; it is then easier to see the faces you created. The volumes are not deleted, just

removed from the graphics window. To remove the volumes from the display, click the

SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the

Global Control toolpad. Select the check box to the left of Volumes. Select the check box to the left of Visible, select Off from the option menu to the right of Visible near the bottom of the form, and click Apply. Turn the visibility of the volumes back on after you have examined the faces.

Page 69: Gambit Tutorial Guide

Figure 3-9: Three faces created inside the pipe intersection

5. Split the three-pipe volume using the faces created in the previous step.

GEOMETRY -> VOLUME -> SPLIT/MERGE VOLUMES

This opens the Split Volume form.

a) Select the three-pipe volume in the graphics window.

b) Select Face in the list below Split With.

c) Pick one of the internal faces created in the steps above.

Shift-middle-click on a face if you need to deselect it and select the face next to it.

Page 70: Gambit Tutorial Guide

d) Click Apply to split the volume.

GAMBIT will use all three faces (which are connected to each other) to split the three-pipe volume into three smaller volumes (which represent the three pipes of the

intersection). All three volumes are connected with common geometry. The decomposed

geometry is shown in Figure 3-10 and is now ready to be meshed.

Figure 3-10: Decomposed geometry

Step 4: Journal Files

! Note that this step is not an essential part of the tutorial and is designed to provide information on using journal files in GAMBIT.

Every time a GUI operation is performed in GAMBIT, the corresponding commands are automatically written to a journal file. This journal file, therefore, provides a backup

copy of all the commands for the current session.

Journal files can be used to recreate a geometry or mesh that was created in a previous

session. You can view, run, and edit journal files in GAMBIT. See the GAMBIT User's Guide for more information on journal files.

1. View the journal file for the current GAMBIT session.

File -> Run -> Journal…

This opens the Run Journal form.

Page 71: Gambit Tutorial Guide

a) Select the Edit / Run Mode option at the top of the form.

b) Click the Current Journal button.

The File Name for the current journal file will appear in the form.

c) Click Accept.

This opens the Edit/Run Journal form. You can see the journal file for the current session, showing every step completed.

2. Edit the current journal file.

a) Left-click at the end of the first line and press the Enter key.

Page 72: Gambit Tutorial Guide

GAMBIT will open a new line where you can type a command.

b) Type reset in the new line.

! If you run the journal file without executing the reset command, GAMBIT creates new geometry on top of the existing geometry.

3. Save the journal file with a new name.

a) In the File Name text entry box at the bottom of the form, delete the text

"GAMBIT.#####/jou".

##### is the process identifier for the current GAMBIT session. In the above form,

##### is 20668.

b) Rename the journal file by typing 3pipe.geo in the File Name text entry box.

c) Click the Save button at the bottom of the form.

The file will be saved to your working directory. By saving the journal file to another

name, you ensure that it will not be overwritten or appended.

4. Replay the steps you have taken in the current session.

a) Hold down the right mouse button in the TEXT EDIT FIELD (this name will be displayed in the Description window when the mouse cursor is over this field) of the Edit/Run Journal form until a menu appears. Choose the Select All option in the menu.

A black box in the LINE EXECUTION COLUMN of the Edit/Run Journal form indicates that a line is selected. Note that all lines are now marked with a black box. You can

select/deselect individual lines by clicking the left mouse button on the arrow on the left

side of the required line.

b) Repeatedly click the Step button at the bottom of the Edit/Run Journal form until a cylinder appears in the graphics window.

Note that GAMBIT's current position in the journal file is marked by an asterisk in the LINE EXECUTION COLUMN of the Edit/Run Journal form. The Step button allows you to step through a journal file one line at a time. Each time the Step button is clicked, GAMBIT will execute the next highlighted line; it will skip any lines that are not highlighted.

GAMBIT has used the information in the journal file to recreate the first cylinder you created in Step 2.

c) Click the Step button again.

Page 73: Gambit Tutorial Guide

A second cylinder appears in the graphics window.

d) Click the Auto button in the Edit/Run Journal form.

The Auto button allows you to automatically rerun a journal file. If the Auto button is used, GAMBIT will automatically execute all lines that are highlighted, and skip any lines that are not highlighted. GAMBIT just used your journal file to redo the geometry creation and decomposition for the three-pipe intersection. Each line of the journal file

was displayed in the Transcript window as it was executed.

e) Close the Edit/Run Journal form.

Step 5: Turn Off Automatic Smoothing of the Mesh

It is necessary to turn off smoothing of the mesh in this example to prevent the boundary

layers from being smoothed out during the volume meshing.

Edit -> Defaults…

This opens the Edit Defaults form.

Page 74: Gambit Tutorial Guide

1. Select the MESH tab at the top of the form.

This displays the types of meshing for which you can set defaults.

2. Select the FACE radio button.

GAMBIT displays the Variables for which defaults are set in a list in the Edit Defaults form.

Page 75: Gambit Tutorial Guide

3. Select AUTO_SMOOTH in the Variable list.

AUTO_SMOOTH will appear in the text entry box at the bottom of the list and its default

value will appear in the Value text entry box.

4. Enter a value of 0 in the Value text entry box.

5. Click the Modify button to the left of AUTO_SMOOTH.

The Value of the variable AUTO_SMOOTH will be updated in the list.

6. Close the Edit Defaults form.

Step 6: Apply Boundary Layers at Walls

Boundary layers are layers of elements growing out from a boundary into the domain.

They are used to locally refine the mesh in the direction normal to a face or an edge. A

single boundary layer can be attached to several face/edge pairs or volume/face pairs.

The direction of the boundary layer is indicated during picking with an arrow that points

towards the middle of the active face or volume.

1. Create boundary layers on the edges where the sphere octant intersects the pipes.

MESH -> BOUNDARY LAYER -> CREATE BOUNDARY LAYER

This opens the Create Boundary Layer form.

Page 76: Gambit Tutorial Guide

a) Enter 0.1 next to First row under Definition.

This defines the height of the first row of elements normal to the edge.

b) Enter 1.4 next to Growth factor.

This sets the ratio of distances between consecutive rows of elements.

c) Move the slider box below Rows until the number of rows = 4.

This defines the total number of element rows. Notice that GAMBIT updates the Depth automatically. The depth is the total height of the boundary layer.

d) Retain the default Transition pattern (1:1).

e) Select one of the three curved edges where the sphere octant intersects the pipes (Figure 3-11).

Page 77: Gambit Tutorial Guide

The boundary layer will be displayed on the edge.

f) Check that the arrow indicating the direction of the boundary layer is pointing towards the origin (Gx, Gy, Gz). If it is not, Shift-middle-click the edge until the arrow is pointing in the correct direction.

g) Select a second curved edge where the sphere octant intersects the pipes and ensure that the arrow on the edge is pointing towards the origin.

h) Repeat for the third curved edge.

The boundary layers will be displayed on the edges as shown in Figure 3-11.

i) Click Apply in the Create Boundary Layer form to apply the boundary layers to the edges.

Figure 3-11: Boundary layer on three edges of the sphere octant

2. Repeat the above steps to create the same boundary layer on the three curved edges where the three pipes intersect, as shown in Figure 3-12. Again, the arrows on the edges must point towards the origin.

Page 78: Gambit Tutorial Guide

Figure 3-12: Boundary layers on the three edges where the pipes intersect

Step 7: Mesh the Sphere Octant Volume

1. Mesh the sphere octant.

MESH -> VOLUME -> MESH VOLUMES

This opens the Mesh Volumes form.

a) Select the sphere octant in the graphics window.

GAMBIT automatically selects Hex Elements and the Tet Primitive Type under Scheme in the Mesh Volumes form, because the volume represents a logical tetrahedron. (NOTE:

Page 79: Gambit Tutorial Guide

The Tet Primitive scheme divides a logical tetrahedron into four logical-hexahedral blocks and creates hexahedral mesh elements in each block. The Tet Primitive scheme does not create tetrahedral mesh elements. (See the GAMBIT Modeling Guide.))

b) Accept the default Interval size under Spacing in the Mesh Volumes form and click the Apply button at the bottom of the form.

The mesh for the sphere octant is shown in Figure 3-13 Note the boundary layers you

applied on three faces of the sphere octant.

Figure 3-13: Mesh on sphere octant

2. Remove the mesh from the display before you mesh the three pipes.

This makes it easier to see the edges and faces of the geometry. The mesh is not deleted,

just removed from the graphics window.

a) Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad.

b) Select Off from the option menu to the right of Mesh near the bottom of the form.

c) Click Apply and close the form.

The boundary layers will still be visible in the graphics window.

Step 8: Mesh the Pipe Volumes

You will now mesh the three pipes. These volumes will be meshed using GAMBIT's Cooper scheme (described in detail in the GAMBIT Modeling Guide). This tutorial

Page 80: Gambit Tutorial Guide

illustrates three different ways to specify the source faces (the faces whose surface

meshes are to be swept through the volume to form volume elements) required by the

Cooper scheme. In the first example, you will modify the face vertex types for the side face of one pipe. This is the safest way to ensure correct meshing. In the second example, you

will enforce the Submap scheme on the side face of the pipe. In the third example, you will enforce the Cooper meshing scheme for the volume and hand-pick all the source faces.

1. Mesh one of the pipes by changing the vertex type on the wall face to Side and then using the Cooper meshing scheme to mesh the volume.

By changing the vertex type to Side on the wall face of the pipe, you will enable GAMBIT to use the Submap scheme on this face. The criteria for the Cooper meshing scheme will then be fulfilled for the pipe, and the pipe can be meshed using the Cooper scheme.

a) Change the vertex type on the wall face to Side.

MESH -> FACE -> SET FACE VERTEX TYPES

This opens the Set Face Vertex Type form.

i. Select Side (the default) under Type.

ii. Select the wall face of the pipe (shown in Figure 3-14) in the graphics window. Note the vertex on the wall face marked with an "E" for End (where the three pipes intersect).

Page 81: Gambit Tutorial Guide

Figure 3-14: Wall face of the first pipe volume showing the End vertex

iii. Left-click in the Vertices list box.

iv. Select the vertex that was marked with an "E" in the graphics window (where the three pipes intersect, as shown in Figure 3-14).

v. Click Apply in the Set Face Vertex Type form.

The vertex will be changed to Type "S" for Side. You will only see the vertex label if you reselect the face. A message will appear in the Transcript window stating that the vertex was set to type Side.

b) Mesh the pipe volume using the Cooper meshing scheme.

MESH -> VOLUME -> MESH VOLUMES

This opens the Mesh Volumes form.

Page 82: Gambit Tutorial Guide

i. Select the first pipe volume in the graphics window.

Note that Hex Elements and the Cooper Type are automatically selected under Scheme in the Mesh Volumes form because you changed the vertex type on the wall face to Side.

GAMBIT automatically selects the source faces because you changed the vertex type on the wall face to Side.

ii. Retain the default Interval size of 1 and click the Apply button at the bottom of the form.

The pipe will be meshed as shown in Figure 3-15.

Page 83: Gambit Tutorial Guide

Figure 3-15: Pipe meshed by changing the vertex type on the wall face to Side and using the Cooper meshing scheme

! It may be useful to remove the mesh from the display at this point; it is then easier to see the faces of the geometry for the other two pipes. The mesh is not deleted, just removed

from the graphics window. To remove the mesh from the display, click the SPECIFY

MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad. Select Off from the option menu to the right of Mesh near the bottom of the form and click Apply.

2. Mesh the second pipe using the Submap scheme on the wall face of the pipe and using the Cooper meshing scheme to mesh the volume.

By enforcing the Submap scheme on the wall face of the pipe, GAMBIT will automatically modify the vertex types on this face to honor the Submap scheme. The criteria for the Cooper meshing scheme will then be fulfilled for the pipe, and the pipe can be meshed using the Cooper scheme.

a) Set the meshing scheme for the wall face to Submap.

MESH -> FACE -> MESH FACES

This opens the Mesh Faces form.

i. Select the wall face of the second pipe (shown in Figure 3-16) in the graphics window.

Page 84: Gambit Tutorial Guide

Figure 3-16: Wall face of the second pipe volume

ii. Select Quad in the Elements option menu under Scheme, and select Submap under Type.

See the GAMBIT Modeling Guide for more information on the Submap scheme.

iii. Retain the default Interval size of 1.

iv. Deselect the Mesh check box under Options.

You deselected the Mesh check box because at this point you do not want to mesh the face; you only want to apply the meshing Scheme to the face. GAMBIT will mesh the face using the specified Scheme when it meshes the pipe volume.

v. Click the Apply button at the bottom of the form.

b) Mesh the pipe volume using the Cooper meshing scheme.

MESH -> VOLUME -> MESH VOLUMES

This opens the Mesh Volumes form.

Page 85: Gambit Tutorial Guide

i. Select the pipe volume in the graphics window.

Note that Hex Elements and the Cooper Type are automatically selected under Scheme in the Mesh Volumes form because you enforced the Submap scheme on the side face of the pipe.

GAMBIT automatically selects the source faces because you enforced the Submap scheme on the side face of the pipe.

ii. Retain the default Interval size of 1 under Spacing and click the Apply button at the bottom of the form.

The pipe will be meshed as shown in Figure 3-17.

Page 86: Gambit Tutorial Guide

Figure 3-17: Pipe meshed using the Submap scheme for the wall face of the pipe and the

project scheme for the volume

! It may be useful to remove the mesh from the display at this point; it is then easier to see the faces of the geometry for the last pipe.

3. Mesh one of the pipes by hand-picking the source faces and then using the Cooper meshing tool.

a) Select the third pipe in the graphics window.

Note that GAMBIT selects Undetermined next to Elements under Scheme in the form. The criteria for the Cooper scheme are not fulfilled for the pipe. This is because GAMBIT

Page 87: Gambit Tutorial Guide

cannot mesh the side face of the volume using the Map or Submap meshing schemes. However, you can force GAMBIT to use the Cooper scheme on this volume by selecting the Cooper scheme and then manually picking the source faces (the faces whose surface meshes are to be swept through the volume to form volume elements). When you click

Apply, GAMBIT will automatically enforce the Submap scheme on the side face and modify the vertex types to honor the scheme selected. See the GAMBIT Modeling Guide

for more information on using the Cooper meshing scheme.

b) Select Hex in the Elements option menu under Scheme, and select Cooper under Type.

c) Left-click in the Sources list box in the form, and then pick the source faces for the mesh by selecting all the faces of the pipe except the pipe wall. The faces are marked A through D in Figure 3-18.

! Shift-middle-click on a face to deselect it and select the face next to it. You can also click Reset in the Mesh Volumes form to deselect all faces and volumes, and reset all parameters entered in the form.

The four faces to be selected are at opposite ends of the pipe, as shown in Figure 3-18.

You can select the faces in the graphics window, or you can use the Sources pick list.

Figure 3-18: Source faces used to mesh one of the pipe volumes

using the Cooper meshing scheme

d) Retain the default Interval size of 1 under Spacing and click the Apply button at the bottom of the form.

4. Display all the face meshes for the three-pipe intersection.

You will only display the face meshes at this point because displaying the volume meshes

would create a cluttered view in the graphics window.

Page 88: Gambit Tutorial Guide

a) Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad.

b) Select the check box to the left of Faces.

c) Select On from the option menu to the right of Mesh near the bottom of the form.

d) Click Apply and close the form.

The face meshes on the three-pipe intersection are shown in Figure 3-19.

Figure 3-19: Face meshes for the three-pipe intersection

Step 9: Examine the Quality of the Mesh

1. Select the EXAMINE MESH command button at the bottom right of the Global Control toolpad.

This opens the Examine Mesh form.

Page 89: Gambit Tutorial Guide

a) Select the Sphere option under Display Type.

This creates a section through the grid that is spherical in shape. For the three-pipe

geometry, a spherical section displays more useful information than a planar section.

The 3D Element type selected by default at the top of the form is a brick .

b) Select EquiAngle Skew from the Quality Type option menu.

c) Select the + option under Cut Orientation near the bottom of the form.

Page 90: Gambit Tutorial Guide

The "+" option indicates that only elements on the positive side of the cut are displayed. For a sphere, this means that only elements on the inside of the sphere will be visible.

The "0" option displays elements on the cut, and the "-" option displays elements on the negative side of the cut (the outside of the sphere in this case).

d) Click the SELECT PRESET CONFIGURATION command button in the Global Control toolpad.

This divides the graphics window into four quadrants and displays a different view of the

spherical section of the grid in each quadrant.

e) Hold down the left mouse button on the X slider box in the Examine Mesh form and move it until the spherical cut is centered in the x direction in the graphics window.

f) Move the Y and Z slider boxes to center the spherical cut in the y and z directions in the graphics window. The graphics window display is shown in Figure 3-20.

Figure 3-20: Spherical cut centered in the x, y, and z directions

Page 91: Gambit Tutorial Guide

g) Move the R slider box in the Examine Mesh form to view the mesh on different spherical cuts in the graphics window.

h) Hold down the left mouse button on the GRAPHICS-WINDOW SASH anchor, the small gray box in the center of the four quadrants of the graphics window, and drag it diagonally across the graphics window to the bottom right corner.

This restores a single window.

i) Close the Examine Mesh form.

The spherical cut of the mesh will be removed and the face meshes will be restored.

Step 10: Set Boundary Types

1. Remove the mesh and boundary layers from the display before you set the boundary types.

This makes it easier to see the edges and faces of the geometry. The mesh and boundary

layers are not deleted, just removed from the graphics window.

a) Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad.

b) Select Off from the option menu to the right of Mesh near the bottom of the form.

c) Click Apply.

d) Select the check box to the left of B. Layers and select Off from the option menu to the right of Visible near the bottom of the form.

e) Click Apply and close the form.

2. Set boundary types for the three-pipe intersection.

ZONES -> SPECIFY BOUNDARY TYPES

This opens the Specify Boundary Types form.

Page 92: Gambit Tutorial Guide

a) Define the flow inlet.

i. Enter the name inflow in the Name text entry box.

ii. Select ELEMENT_SIDE in the Type option menu.

The specific boundary types will be defined inside the POLYFLOW solver.

iii. Check that Faces is selected as the Entity.

iv. Shift-left-click the end of one of the pipes (the face marked A in Figure 3-21) and click Apply to accept the selection.

Page 93: Gambit Tutorial Guide

Figure 3-21: Boundary types for faces of the three-pipe intersection

b) Define the two flow outlets.

i. Enter the name outflow1 in the Name text entry box.

ii. Check that ELEMENT_SIDE is still selected in the Type option menu and Shift-left-click the end of one of the other pipes in the graphics window (the face marked B in Figure 3-21).

iii. Click Apply to accept the selection of the face.

iv. Set the Type for the end of the third pipe (the face marked C in Figure 3-21) to be

ELEMENT_SIDE, using the Name outflow2.

c) Define wall boundary types for the walls of the three-pipe intersection.

i. Enter the name wall in the Name text entry box.

ii. Check that ELEMENT_SIDE is still selected in the Type option menu and pick all the wall faces (the outer walls of the three pipes and the outer face of the sphere octant) in the graphics window.

! You will select four faces in total.

iii. Click Apply to accept the selection of the faces.

The boundaries for the three-pipe intersection are shown in Figure 3-22.

Page 94: Gambit Tutorial Guide

Figure 3-22: Boundary types for the three-pipe intersection

Note that when GAMBIT writes a mesh, any volumes (in 3-D) on which you have not specified a continuum type will be written as FLUID by default. This means that you do not need to specify a continuum type in the Specify Continuum Types form for this tutorial.

Step 11: Export the Mesh and Save the Session

1. Export a mesh file for the three-pipe intersection.

File -> Export -> Mesh …

This opens the Export Mesh File form.

a) Enter the File Name for the file to be exported (intersection.neu).

b) Click Accept.

The file will be written to your working directory.

2. Save the GAMBIT session and exit GAMBIT.

Page 95: Gambit Tutorial Guide

File -> Exit

GAMBIT will ask you whether you wish to save the current session before you exit.

Click Yes to save the current session and exit GAMBIT.

3.5 Summary

In this tutorial, you created geometry consisting of three intersecting pipes. Before creating the mesh, you decomposed the three-pipe geometry into four volumes: the three individual pipes and the wedge-shaped corner of the intersection (the sphere "octant"). These constituent volumes were readily meshed using GAMBIT's Cooper and Tet Primitive meshing schemes.

© Fluent, Inc. 10/27/99

Page 96: Gambit Tutorial Guide

4. MODELING A COMBUSTION CHAMBER (3-D)

In this tutorial, you will create the geometry for a burner using a top-down geometry construction method in GAMBIT (creating a volume using solids). You will then mesh the burner geometry with an unstructured hexahedral mesh.

In this tutorial you will learn how to:

• Move a volume • Subtract one volume from another • Shade a volume • Intersect two volumes • Blend the edges of a volume • Create a volume using the sweep face option • Prepare the mesh to be read into FLUENT/UNS

4.1 Prerequisites

This tutorial assumes that you have worked through Tutorial 1 and you are consequently familiar with the GAMBIT interface.

4.2 Problem Description

The problem to be considered is shown schematically in Figure 4-1. The geometry consists of a simplified fuel injection nozzle that feeds into a combustion chamber. You will only model one quarter of the burner geometry in this tutorial, because of the symmetry of the geometry. The nozzle consists of two concentric pipes with radii of 4 units and 10 units respectively. The edges of the combustion chamber are blended on the wall next to the nozzle.

Page 97: Gambit Tutorial Guide

Figure 4-1: Problem specification

4.3 Strategy

In this tutorial, you will create a combustion chamber geometry using the "top-down" construction method. You will create volumes (in this case, bricks and cylinders) and use Boolean operations to unite, intersect, and subtract these volumes to obtain the basic geometry. Finally, using the "blend" command, you will round off some edges to complete the geometry creation.

For this model, it is not possible to simply pick the geometry and mesh the entire domain with hexahedral elements, because the Cooper tool (which you will be using in this tutorial) requires two groups of faces, one group topologically parallel to a sweep path, and the other group topologically perpendicular. However, the rounded (blended) edges fit in neither group. See the GAMBIT Modeling Guide for a more detailed description of the Cooper tool. You need to decompose the geometry into portions that can be meshed using the Cooper tool. There are several ways to decompose geometry in GAMBIT. In this example, you will use a method whereby portions of the volume around the blend are split off from the main volume. A detailed description of the decomposition strategy for the combustion chamber is given below.

Note that there are several faces in the geometry for which the default meshing scheme is the Pave scheme; most of these faces are perpendicular to the z direction. There are also geometrical protrusions in the z direction, so this should be chosen as the main direction for the Cooper meshing scheme. To make this possible, the paved faces in the x and y directions (the two symmetry planes in the geometry shown in Figure 4-2) must be changed to use the Submap or Map meshing scheme.

Page 98: Gambit Tutorial Guide

Figure 4-2: The two symmetry planes in the combustion chamber geometry

By default, GAMBIT selects the Pave meshing scheme for these two faces because each has a rounded edge where the blend occurs. If you split off the rounded corners of both faces and connect them through a volume, you can use the Submap meshing scheme on the remaining faces, and hence the Cooper meshing scheme for the volume.

Instead of creating two faces, one on each symmetry plane, you will create a face at the junction of the two blended edges (face A in Figure 4-3). This face will then be swept in two directions onto the symmetry planes (creating faces B and C in Figure 4-3), to split the volume into three parts. The three volumes can then be meshed individually using the Cooper tool.

Page 99: Gambit Tutorial Guide

Figure 4-3: Faces created at the blended edges and on the symmetry planes

This tutorial also demonstrates a few ways of controlling the mesh density and the meshing schemes used on individual faces. You will mesh the small quarter-circle face that forms the second inlet with a Tri Primitive scheme and a finer mesh size. Similarly, you will mesh the annular face of the primary inlet with a fine mapped mesh. To meet the requirements of the Cooper tool, you will also need to create a mapped mesh on the face between these two faces. Finally, you will use the automatic Cooper tool to mesh the remaining faces and the volume.

4.4 Procedure

Start GAMBIT.

Step 1: Select a Solver

1. Choose the solver you will use to run your CFD calculation by selecting the following from the main menu bar:

Solver -> FLUENT/UNS

The choice of a solver dictates the options available in various forms (for example, the

boundary types available in the Specify Boundary Types form). The solver currently selected is indicated at the top of the GAMBIT GUI.

Step 2: Set the Default Interval Size for Meshing

Edit -> Defaults…

In this tutorial, you will change the default interval size used for meshing. The mesh

spacing is, by default, based on the interval size parameter, which you will modify in the

Edit Defaults form. The value you enter should be the estimated average size of a mesh element in the model. This value will appear as the default Interval size on all meshing forms. You will be able to change it on the meshing forms, if required.

Page 100: Gambit Tutorial Guide

1. Select the MESH tab at the top of the form.

2. Select the INTERVAL radio button near the top of the form.

3. Select SIZE in the Variable list.

SIZE will appear in the space at the bottom of the list and its default value will appear in

the Value text entry box.

Page 101: Gambit Tutorial Guide

4. Enter a value of 2 in the Value text entry box.

5. Click the Modify button to the left of SIZE.

The Value of the variable SIZE will be updated in the list.

6. Close the Edit Defaults form.

Step 3: Create Two Cylinders

1. Create a cylinder to form the opening of the burner.

GEOMETRY -> VOLUME -> CREATE VOLUME R

This opens the Create Real Cylinder form.

a) Enter a value of 12 for the Height of the cylinder.

b) Enter a value of 4 for Radius 1 of the cylinder.

The text entry box for Radius 2 can be left blank; GAMBIT will set this by default to be the same value as Radius 1.

c) Select Positive Z (the default) as the Axis Location.

d) Click Apply.

1. Repeat the steps above to create a cylinder of Height = 20 and Radius 1 = 10 along the Positive Z axis.

Page 102: Gambit Tutorial Guide

2. Click the FIT TO WINDOW command button , at the top left of the Global Control toolpad, to see the cylinders created.

The two cylinders are shown in Figure 4-4. Hold down the left mouse button and move

the mouse to rotate the view in the graphics window. You can zoom out from the current

view by holding down the right mouse button and pushing the mouse away from you.

Figure 4-4: Two cylinders

4. Move the first cylinder you created so that it is at the front of the large cylinder.

GEOMETRY -> VOLUME -> MOVE/COPY/ALIGN VOLUMES

This opens the Move / Copy Volumes form.

Page 103: Gambit Tutorial Guide

a) Shift-left-click the small cylinder in the graphics window.

volume.1 will be entered next to Volumes in the Move / Copy Volumes form.

b) Select Move (the default) under Volumes in the Move / Copy Volumes form.

c) Select Translate (the default) under Operation.

d) Enter a Global translation vector of (0, 0, 8) to move the cylinder 8 units in the z direction.

Note that GAMBIT automatically fills in the values under Local as you enter values under Global.

e) Click Apply.

The two cylinders are shown in Figure 4-5. Notice that the small cylinder has been

moved from the back of the large cylinder to the front.

Page 104: Gambit Tutorial Guide

Figure 4-5: Two cylinders after moving the small cylinder

Step 4: Subtract the Small Cylinder From the Large Cylinder

1. Create one volume from the two cylinders by subtracting one cylinder from the other.

The order of selecting the volumes is important. For example, Figure 4-6 shows the

difference between subtracting volume B from volume A, and vice versa.

Figure 4-6: Subtracting volumes

Page 105: Gambit Tutorial Guide

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

R

This opens the Subtract Real Volumes form.

a) Shift-left-click the large cylinder in the graphics window.

b) Left-click in the list box to the right of Subtract Volume to accept the selection of volume.2 and make the Subtract Volume list box active.

! Alternatively, you could continue to hold down the Shift key and click the right mouse button in the graphics window to accept the selection of the large cylinder and move the

focus to the Subtract Volume list box.

c) Select the small cylinder and accept the selection.

Selecting the cylinders in this order ensures that the small cylinder is subtracted from the

large cylinder and not vice versa.

Step 5: Shade and Rotate the Display

1. Click the RENDER MODEL command button , in the middle of the bottom row of the Global Control toolpad, to create a shaded view of the volume.

2. Hold down the left mouse button and drag the mouse to rotate the graphics display and see the cylindrical hole created in the large cylinder (see Figure 4-7).

Page 106: Gambit Tutorial Guide

Figure 4-7: Shaded geometry showing hole in large cylinder

3. To return to the unshaded view, right-click on the RENDER MODEL command button

in the Global Control toolpad and select from the resulting list.

Step 6: Remove Three Quarters of the Cylindrical Volume

In this step, you will create a brick that will be intersected with the cylindrical volume.

Three quarters of the cylindrical volume will be removed, leaving the volume for the

entrance of the burner.

1. Create a brick that will be intersected with the cylindrical volume already created.

GEOMETRY -> VOLUME -> CREATE VOLUME R

This opens the Create Real Brick form.

Page 107: Gambit Tutorial Guide

a) Enter a value of 21 for the Width of the brick.

The text entry boxes for Depth and Height can be left blank; GAMBIT will set these values by default to be the same value as the Width, to create a cube.

b) Use a Direction of +X +Y +Z (the default).

c) Click Apply.

Figure 4-8 shows the cylindrical volume and the brick.

Figure 4-8: Cylindrical volume and brick

2. Intersect the brick and the cylindrical volume.

Page 108: Gambit Tutorial Guide

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

R

This opens the Intersect Real Volumes form.

a) Shift-left-click the brick in the graphics window.

b) Select the cylindrical volume in the graphics window.

c) Click Apply to accept the selection of the volumes.

The order in which you select the two volumes is not important when you are intersecting

them. The cylindrical volume will be trimmed so that only the part inside the brick

remains, as shown in Figure 4-9.

Figure 4-9: One quarter of the cylindrical volume remains

Step 7: Create the Chamber of the Burner

1. Create a brick for the chamber.

Page 109: Gambit Tutorial Guide

GEOMETRY -> VOLUME -> CREATE VOLUME

This opens the Create Real Brick form.

a) Enter a value of 20 for the Width of the brick, 30 for the Depth, and 40 for the Height.

b) Change the Direction to +X +Y -Z by selecting this option in the option menu to the right of Direction.

c) Click Apply.

2. Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the brick created.

3. Unite the brick and cylindrical volume into a single volume.

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

R

This opens the Unite Real Volumes form.

Page 110: Gambit Tutorial Guide

a) Shift-left-click the cylindrical volume in the graphics window.

b) Select the brick and click Apply to accept the selection.

The order in which you select the two volumes is not important when you are uniting

them. The brick and the cylindrical volume will be united as shown in Figure 4-10.

Figure 4-10: Brick and cylindrical volume are united

Step 8: Blend the Edges of the Chamber

1. Blend (round off) two edges of the chamber geometry to give it a more rounded shape.

GEOMETRY -> VOLUME -> BLEND VOLUMES

This opens the Blend Volumes form.

Page 111: Gambit Tutorial Guide

a) Click the Edge button under Define Blend Types.

This opens the Edge Blend Type form.

i. Shift-left-click the two edges to be blended, as shown in Figure 4-11.

Page 112: Gambit Tutorial Guide

Figure 4-11: Edges to be blended

ii. Select Constant radius round (the default) under Options in the Edge Blend Type form.

iii. Enter 5 for the Radius.

iv. Click Apply in the Edge Blend Type form and Close the form.

b) Shift-left-click the volume in the graphics window.

c) Click Apply in the Blend Volumes form.

The burner geometry with the blended edges is shown in Figure 4-12.

Page 113: Gambit Tutorial Guide

Figure 4-12: Burner with blended edges

Step 9: Geometry Decomposition

For this model, it is not possible to simply pick the geometry and mesh it with a

hexahedral mesh. The Cooper meshing scheme requires that all "source" faces are topologically parallel, and that all other faces can be meshed using the Map or Submap meshing scheme. However, the curved faces resulting from the blend operation do not

satisfy the Cooper criteria. Therefore, you will need to decompose the geometry into portions that are each suitable for the Cooper tool. There are several ways to decompose geometry in GAMBIT. In this example, you will use a method whereby portions of the volume around the blend are split off from the main volume. To do this, you will create a

vertex near the junction of the two blended edges. You will then use this vertex to create

straight edges, and use these edges to create a face. This face will then be swept in two

directions to create two volumes. These two volumes will be used to split the burner

volume into three parts. It will then be possible to mesh each of these parts individually

using the Cooper tool.

1. Create a vertex inside the volume.

GEOMETRY -> VERTEX -> MOVE/COPY/ALIGN VERTICES

This opens the Move / Copy Vertices form.

Page 114: Gambit Tutorial Guide

a) Select the vertex marked A in Figure 4-13.

To zoom in to an area of the graphics window, hold down the Ctrl key and use the left mouse button to draw a box around the area you want to view.

Figure 4-13: Vertex to copy

b) Select Copy under Vertices in the Move / Copy Vertices form.

c) Select Translate (the default) under Operation.

d) Enter the translation vector (0, 0, -5) under Global.

e) Click Apply.

The vertex will be visible in the graphics window as a white cross near where the two

blended edges meet. See vertex B in Figure 4-14.

2. Create two straight edges using the new vertex.

GEOMETRY -> EDGE -> CREATE EDGE

This opens the Create Straight Edge form.

Page 115: Gambit Tutorial Guide

a) Shift-left-click the vertex marked A in Figure 4-14.

Figure 4-14: Vertices to be selected to create edges

b) Shift-left-click the vertices marked B and C in Figure 4-14, in order.

c) Click Apply to accept the selected vertices and create two edges.

The edges are shown in Figure 4-15.

Page 116: Gambit Tutorial Guide

Figure 4-15: Two new straight edges

3. Create a face using the two new edges.

GEOMETRY -> FACE -> FORM FACE

This opens the Create Face From Wireframe form.

a) Shift-left-click the edge marked D in Figure 4-16.

Page 117: Gambit Tutorial Guide

Figure 4-16: Edges used to create the face

b) Shift-left-click the edges marked E and F in Figure 4-16.

c) Click Apply to accept the selected edges and create a face.

4. Create a volume by selecting the new face and sweeping it along the direction defined by an edge.

GEOMETRY -> VOLUME -> FORM VOLUME R

This opens the Sweep Real Faces form.

Page 118: Gambit Tutorial Guide

a) Select the new face in the graphics window.

Shift-middle-click on a face to deselect it and select the face next to it.

b) Left-click in the list box to the right of Edge to make the Edge list box active.

c) Select the edge marked G in Figure 4-17.

! A red arrow will appear on the edge, indicating the direction in which the face will be swept. This arrow should be pointing away from the face you selected. If it is not, click

the Reverse button in the Sweep Real Faces form to reverse the direction of the arrow and the sweep.

Page 119: Gambit Tutorial Guide

Figure 4-17: Edge to be used for sweep face

d) Click Apply to sweep the face.

The volume created by the sweep is shown in Figure 4-18.

Figure 4-18: Face swept parallel to an edge to form a volume

Note that the volume created by the Sweep Real Faces operation extends outside the boundaries of the burner box.

5. Sweep the same face in a different direction.

a) Select the face marked H in Figure 4-19.

b) Left-click in the list box to the right of Edge to make the Edge list box active.

Page 120: Gambit Tutorial Guide

Figure 4-19: Face and edge to be used for sweep face

c) Select the edge marked J in Figure 4-19.

d) Click Reverse to reverse the direction of the edge.

! Again, the arrow on this edge should be pointing away from the selected face.

e) Click Apply.

The volume created by the sweep is shown in Figure 4-20.

Figure 4-20: Face swept parallel to an edge to form a second volume

Page 121: Gambit Tutorial Guide

6. Split the large burner volume using the two smaller volumes.

If you split one volume with another volume, the following volumes will result:

• Volumes corresponding to the common region(s) from intersection. • Volumes corresponding to the region(s) defined by subtracting the second volume

from the first.

In other words, splitting a volume results in a combination of the intersection and

subtraction Boolean operations. The order of selecting the volumes is important. For

example, Figure 4-21 shows the difference between splitting volume A using volume B,

and vice versa.

Figure 4-21: Splitting volumes

GEOMETRY -> VOLUME -> SPLIT/MERGE VOLUMES

This opens the Split Volume form.

Page 122: Gambit Tutorial Guide

a) Select the large burner geometry in the graphics window.

b) Select Volume as the Split With tool.

c) Left-click in the list box to the right of Split With Volume to make the Split With Volume list box active.

d) Select the first volume created using the sweep face method.

e) Click Apply.

GAMBIT will use both of the two smaller volumes (which are connected to each other) to split the large burner volume into three smaller volumes. All three volumes are

connected with common geometry.

7. Delete the extraneous volume.

The Split Volume operation creates two extraneous volumes that lie outside the boundaries of the burner box. During the Split Volume operation, GAMBIT deletes the extraneous volume generated by the bidirectional split of volume.4 but retains the extraneous volume generated by the bidirectional split of volume.5 (which is labeled, volume.6). As a result, it is necessary to manually delete this volume (volume.6).

GEOMETRY -> VOLUME -> DELETE VOLUMES

This opens the Delete Volumes form.

Page 123: Gambit Tutorial Guide

a) Select the extraneous volume (volume.6).

b) Click Apply.

The complete decomposed burner geometry (see Figure 4-22) is now ready to be meshed.

Figure 4-22: Decomposed burner geometry

Step 10: Generate an Unstructured Hexahedral Mesh

In the meshing section of this tutorial you will use:

• Cooper tool • Face meshing schemes • Variable global mesh densities

It is possible to use the Cooper tool to automatically mesh the entire model with a uniform mesh size, but this tutorial will instead demonstrate a few ways of controlling the mesh

density and the meshing schemes used. Typically, the Cooper tool will use the Pave meshing scheme on all source faces, if certain criteria are not met. See the GAMBIT Modeling Guide for more information on GAMBIT's meshing tools.

Page 124: Gambit Tutorial Guide

The two small volumes will be meshed first using the Cooper meshing scheme. For the remaining volume, you will mesh some faces first. In this case, you will mesh the small

quarter-circle face with a Tri Primitive scheme and a finer mesh size. Similarly, you will mesh the annular face of the inlet with a fine mapped mesh. However, to ensure that the

face in-between the quarter-circle and the annular faces has a mapped (or submapped)

mesh, which is required for the Cooper tool, you will mesh this face before meshing the annular face. Finally, you will use the automatic Cooper tool to mesh the remaining faces and volume.

1. Generate a mesh for one of the small volumes.

MESH -> VOLUME -> MESH VOLUMES

This opens the Mesh Volumes form.

a) Select the volume at the top front of the burner geometry.

The volume to be selected is shown in Figure 4-23.

Page 125: Gambit Tutorial Guide

Figure 4-23: Faces to select for Cooper meshing on the volume

at the top of the burner geometry

In this case the criteria for the Cooper scheme are not fulfilled. This is because GAMBIT will not automatically mesh the back face of the volume using the Map or Submap meshing scheme, because the angle at one of the face corners is not close enough to 90

for it to be automatically classified with the End vertex type, which is a requirement for automatic Map meshing on a four-sided face. However, you can force GAMBIT to use the Cooper scheme on this volume by selecting it and then manually picking the source faces (the faces whose surface meshes are to be swept through the volume to form volume

elements). When you click Apply, GAMBIT will automatically enforce the Submap scheme on all side faces not already set to use the Map or Submap schemes, and will modify the vertex types to honor the scheme selected. See the GAMBIT Modeling Guide

for more information on using the meshing schemes.

b) Select Hex from the Elements option menu under Scheme in the Mesh Volumes form and select Cooper from the Type option menu.

c) Left-click in the Source list box (which will turn yellow), and then select the faces marked K and L in Figure 4-23 as the Source faces.

The faces are at opposite ends of the volume.

! If you select the wrong face, and the face you want is the one next to the face selected, Shift-middle-click on the face to deselect it and select the face next to it. You can also click Reset in the Mesh Volumes form to reset everything you set in the form.

d) Retain the default Interval size of 2 under Spacing in the Mesh Volumes form.

Page 126: Gambit Tutorial Guide

Note that this is the interval size for meshing that you set as the default in Step 2 of this

tutorial.

e) Click the Apply button at the bottom of the form.

Notice that all faces are meshed before GAMBIT meshes the volume. The mesh is shown in Figure 4-24.

Figure 4-24: Mesh generated for the first small volume in the burner geometry

2. Generate a mesh for the other small volume in the burner geometry.

a) Select the volume at the side of the burner geometry.

The volume to be selected is shown in Figure 4-25.

Page 127: Gambit Tutorial Guide

Figure 4-25: Faces to select for cooper meshing on the volume at the side of the burner geometry

b) Select Hex from the Elements option menu under Scheme in the Mesh Volumes form and select Cooper from the Type option menu.

c) Left-click in the Source list box (which will turn yellow), and select the faces marked M and N in Figure 4-25 as the Source faces.

The faces are at opposite ends of the volume.

! If you select the wrong face, and the face you want is the one next to the face selected, Shift-middle-click on the face to deselect it and select the face next to it. You can also click Reset in the Mesh Volumes form to deselect all faces, and then select the correct faces.

d) Retain the default Interval size of 2 under Spacing in the Mesh Volumes form and click the Apply button at the bottom of the form.

The mesh is shown in Figure 4-26.

Figure 4-26: Mesh generated for the second small volume in the burner geometry

Next, you will mesh the small face where the burner entrance and the burner chamber

meet, and the face at the entrance to the burner. In GAMBIT, you can "pre-mesh" any source faces on a volume by selecting a meshing scheme and size, to improve the quality

of the final mesh.

3. Mesh the small face where the burner entrance and the burner chamber meet.

Page 128: Gambit Tutorial Guide

MESH -> FACE -> MESH FACES

This opens the Mesh Faces form.

a) Select the face marked P in Figure 4-27.

Notice that GAMBIT automatically selects the Tri Primitive Scheme in the Mesh Faces form. See the GAMBIT Modeling Guide for more information on the Tri Primitive scheme.

Page 129: Gambit Tutorial Guide

Figure 4-27: Faces to be meshed in the burner geometry

b) Enter 0.5 for the Interval size under Spacing and click the Apply button at the bottom of the form.

The face will be meshed as shown in Figure 4-28.

Figure 4-28: Mesh on small face

4. Mesh the curved face along the entrance to the burner.

a) Select the face marked Q in Figure 4-27.

GAMBIT will automatically select the Map Scheme in the Mesh Faces form. See the GAMBIT Modeling Guide for more information on the Map meshing scheme.

b) Retain the default Interval size of 2 under Spacing and click the Apply button at the bottom of the form.

The face will be meshed as shown in Figure 4-29.

Page 130: Gambit Tutorial Guide

Figure 4-29: Mesh on curved face along the entrance to the burner

5. Mesh the face at the entrance to the burner.

a) Select the face marked R in Figure 4-27.

GAMBIT will automatically select the Map Scheme in the Mesh Faces form.

b) Enter 1 for the Interval size under Spacing and click the Apply button at the bottom of the form.

The face will be meshed as shown in Figure 4-30.

Figure 4-30: Mesh on face at entrance of burner

6. Create a mesh for the rest of the volume of the burner.

Page 131: Gambit Tutorial Guide

MESH -> VOLUME -> MESH VOLUMES

a) Select the remaining burner geometry in the graphics window.

GAMBIT will automatically choose the Cooper Scheme as the meshing tool to be used,

and will use an Interval size of 2 (the default) under Spacing. It will also select the source faces it requires to generate the Cooper mesh. These faces are marked S through X in Figure 4-31.

Figure 4-31: Source faces to be used for cooper mesh

b) Click Apply at the bottom of the Mesh Volumes form.

This accepts the volume you selected as the one to be meshed and the source faces

GAMBIT has chosen for the Cooper meshing scheme, and starts the meshing. The complete mesh is shown in Figure 4-32.

Notice that hidden line removal has been turned on in Figure 4-32 to make the mesh

easier to see. To turn on hidden line removal, hold down the right mouse button on the

RENDER MODEL command button in the Global Control toolpad and select

from the resulting list. To view the mesh without hidden line removal,

reselect the option.

Page 132: Gambit Tutorial Guide

Figure 4-32: Volume mesh for the burner geometry

7. You can view a shaded display of the mesh using the RENDER MODEL command button in the Global Control toolpad

a) Hold down the right mouse button on the RENDER MODEL command button and

select from the resulting list.

b) Rotate and translate the volume to view the mesh.

c) When you are finished, return to the wireframe view of the model, by selecting the

following command buttons in the Global Control toolpad: R .

Step 11: Examine the Quality of the Mesh

1. Select the EXAMINE MESH command button at the bottom right of the Global Control toolpad.

This opens the Examine Mesh form.

Page 133: Gambit Tutorial Guide

The 3D Element type selected by default at the top of the form is a brick .

a) Select the Plane option under Display Type.

b) Select EquiAngle Skew from the Quality Type option menu.

c) Hold down the left mouse button on the X slider box and move it to view slices of the mesh with different x values.

An example is shown in Figure 4-33. The mesh is drawn as a wireframe (by default) as

you drag the slider box, and it is colored by EquiAngle Skew quality when you release the slider box. As you sweep a plane through the x values, you will see the way in which the

Page 134: Gambit Tutorial Guide

Cooper tool has automatically decomposed the volume internally to mesh it with hexahedral elements.

Figure 4-33: Slice of the mesh in the x direction

d) Use the Y and Z sliders to view slices in the y and z directions.

e) Select Range under Display Type, and then click with the left mouse button on the histogram bars that appear at the bottom of the Examine Mesh form to highlight elements in a particular quality range.

Figure 4-34 shows the view in the graphics window if you click on the fifth bar from the left on the histogram (representing cells with a skewness value between 0.4 and 0.5). These low values for the maximum skewness indicate that the mesh is acceptable.

The histogram consists of a bar chart representing the statistical distribution of mesh

elements with respect to the specified Quality Type. Each vertical bar on the histogram corresponds to a unique set of upper and lower quality limits.

Page 135: Gambit Tutorial Guide

Figure 4-34: Elements within a specified quality range

f) Close the Examine Mesh form by clicking the Close button at the bottom of the form.

Step 12: Set Boundary Types

1. Remove the mesh from the display before you set the boundary types.

This makes it easier to see the edges and faces of the geometry. The mesh is not deleted,

just removed from the graphics window.

a) Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad.

b) Select Off from the option menu to the right of Mesh near the bottom of the form.

c) Click Apply and close the form.

2. Set boundary types for the burner.

ZONES -> SPECIFY BOUNDARY TYPES

This opens the Specify Boundary Types form.

Page 136: Gambit Tutorial Guide

a) Define two velocity inlets.

i. Select VELOCITY_INLET in the Type option menu.

ii. Check that Faces is selected as the Entity.

iii. Shift-left-click the face marked A in Figure 4-35 and click Apply to accept the selection.

GAMBIT will give the boundary a default name based on what you select in the Type and Entity lists (velocity_inlet.1 in this example). You can also specify a name for a boundary by entering a name in the Name text entry box.

Page 137: Gambit Tutorial Guide

Figure 4-35: Boundary types for the burner (side view)

This face will be set as a velocity inlet.

iv. Check that VELOCITY_INLET is still selected in the Type option menu, select the face marked B in Figure 4-35, and click Apply.

b) Define a pressure outlet.

i. Change the Type to PRESSURE_OUTLET by selecting it in the option menu below Type.

ii. Select the face marked C in Figure 4-35 and click Apply to accept the selection.

c) Define symmetry boundary types for the two faces normal to the x axis.

i. Enter the name symmetryx in the Name text entry box.

ii. Change the Type to SYMMETRY.

iii. Select the two faces on the left side of the geometry as you look at it from the front (the faces marked D and E in Figure 4-36). Accept the selection of the faces.

Page 138: Gambit Tutorial Guide

Figure 4-36: Boundary types for the burner

d) Define symmetry boundary types for the two faces normal to the y axis.

i. Enter the name symmetryy in the Name text entry box.

ii. Check that SYMMETRY is still selected in the Type option menu and select the two faces on the bottom of the geometry (the faces marked F and G in Figure 4-36). Accept the selection of the faces.

The velocity inlet, pressure outlet, and symmetry boundaries for the 3-D combustion

chamber are shown in Figure 4-37.

Page 139: Gambit Tutorial Guide

Figure 4-37: Boundary types for the combustion chamber

Note that you could also specify the remaining outer faces of the model as WALL boundaries. This is not necessary, however, because when GAMBIT saves a mesh, any external faces (in 3-D) for which you have not specified a boundary type will be written

out as WALL boundaries by default.

In addition, when GAMBIT writes a mesh, any volumes (in 3-D) for which you have not specified a continuum type will be written as FLUID by default. This means that you do not need to specify a continuum type in the Specify Continuum Types form for this tutorial.

Step 13: Export the Mesh and Save the Session

1. Export a mesh file.

File -> Export Mesh…

This opens the Export Mesh File form. Notice that the File Type at the top of the form is UNS / RAMPANT / FLUENT 5.

a) Enter the File Name for the file to be exported (burner.msh).

Page 140: Gambit Tutorial Guide

b) Click Accept.

The file will be written to your working directory.

2. Save the GAMBIT session and exit GAMBIT.

File -> Exit

GAMBIT will ask you whether you wish to save the current session before you exit.

Click Yes to save the current session and exit GAMBIT.

4.5 Summary

In this tutorial, you created the geometry and hexahedral mesh for a 3-D combustion chamber using a top-down construction approach. The use of Boolean operations for uniting, subtracting, and intersecting volumes was demonstrated. The blend volumes command was used to create a rounded shape on the edges of the combustion chamber. Next, the geometry was decomposed into smaller volumes for which the Cooper meshing scheme could be used. Several different ways of meshing the source faces needed by the Cooper scheme were shown.

© Fluent, Inc. 05/30/00

Page 141: Gambit Tutorial Guide

5. IMPORTING AND CLEANING UP SEDAN GEOMETRY

In this tutorial you will import an IGES file containing the geometry for a sedan automobile, clean up the geometry, and mesh it with triangles and tetrahedra.

In this tutorial you will learn how to:

• Import an IGES file • Specify the way in which the geometry will be colored • Connect edges, using a manual and an automatic method • Merge faces • Create a triangular surface mesh • Mesh a volume with a tetrahedral mesh • Prepare the mesh to be read into FLUENT 5

5.1 Prerequisites

This tutorial assumes you have worked through Tutorial 1 and, therefore, that you are familiar with the GAMBIT GUI.

5.2 Problem Description

The problem to be considered is shown schematically in Figure 5-1; it is the external body of a luxury sedan. You will generate a mesh on the outside of the car body; therefore, you will create a brick around the sedan to represent the flow domain.

Figure 5-1: Outline of sedan

Page 142: Gambit Tutorial Guide

5.3 Strategy

In this tutorial, you will create a fully unstructured tetrahedral mesh around a car-body geometry imported as an IGES file. This tutorial illustrates the steps you would typically follow to prepare an imported CAD geometry for meshing. The imported geometry is "dirty"-that is, there are gaps between some of the surfaces that make it unsuitable for creating a CFD mesh. You will first clean up the geometry using the tools available in GAMBIT.

Most of the gaps can be fixed automatically either during mesh import or subsequently by means of the "connect edge" command. The original CAD geometry is not modified during the fixing process; the modifications required to eliminate the gaps are made using "virtual" geometry, which lies on top of the "real" geometry. Some edges in the original geometry are very short and will be eliminated using the "vertex connect" command. Other edges are not automatically connected, because they are farther apart than the specified tolerance. You will connect such edges manually.

The imported geometry includes a number of small surfaces, the edges of which may unnecessarily constrain the mesh generation process. Using the "merge faces" command, GAMBIT allows you to easily combine these surfaces prior to meshing. You can then have GAMBIT automatically create a triangular mesh on the car body.

Since the imported geometry consists only of the car body, you need to create a suitable domain around the car in order to conduct a CFD analysis (this is loosely equivalent to placing the car in a wind tunnel). The remainder of the tutorial shows how to add a real box around the car body, use virtual geometry to create some missing faces, and finally stitch all faces together into a single volume. This volume can then be meshed (without any decomposition) using a tetrahedral meshing scheme.

5.4 Procedure

1. Copy the file

path/Fluent.Inc/gambit1.0/tut/sedan.igs

from the GAMBIT installation area in the directory path to your working directory (for

example, /home/user/tutorial/).

2. Start GAMBIT.

Step 1: Select a Solver

Page 143: Gambit Tutorial Guide

1. You will use the default solver (FLUENT 5).

The choice of a solver dictates the options available in various forms (for example, the

boundary types available in the Specify Boundary Types form). The solver currently selected is indicated at the top of the GAMBIT GUI.

Step 2: Import the IGES File for the Sedan Body

File -> Import -> IGES …

This opens the Import IGES File form.

1. Select the No stand-alone vertices and No stand-alone edges check boxes under Options.

Page 144: Gambit Tutorial Guide

This option instructs GAMBIT not to read in any vertices that do not belong to faces, edges, or volumes. This option should be used when you want only the surfaces. The

vertices can be deleted after the geometry has been read into GAMBIT, but this option eliminates the extra step.

2. Click on the Browse... button.

This opens the Select File form.

a) Select sedan.igs in the Files list.

b) Click Accept in the Select File form.

3. Change to connectivity-based coloring of the geometry in the graphics window by

clicking on the SPECIFY COLOR MODE command button in the Global Control toolpad.

The SPECIFY COLOR MODE command button will change to . When GAMBIT is in this connectivity color mode, it displays colors based on connectivity between entities.

Page 145: Gambit Tutorial Guide

The color of all edges in the graphics window will change to orange. This indicates that

the faces are not connected to each other; there are gaps between the faces.

4. Set the connect tolerance to 10% of the shortest edge by selecting the Virtual Cleanup toggle and specifying the % Shortest Edge at 10.

This invokes an automated sequence of connect operations that attempt to clean up the

imported geometry after it is read into GAMBIT.

5. Click Accept in the Import IGES File form.

The IGES file for the sedan body will be read into GAMBIT, and is shown in Figure 5-2. Notice that the geometry first appears with orange edges. As the repair operations

progress, the edges turn light blue .

Figure 5-2: Imported sedan body

Step 3: Eliminate Very Short Edges

The imported IGES geometry is "dirty"-that is, there are a few short edges and gaps

between the faces that need to be repaired. In this step, you will eliminate the short

edges.

1. Find the shortest edge.

GEOMETRY -> EDGE -> CONNECT/DISCONNECT EDGES ->

Page 146: Gambit Tutorial Guide

This opens the Connect Edges form.

a) Select All from the option menu to the right of Edges.

b) Select the Real and Virtual (Tolerance) option.

c) Press the Highlight shortest edge button.

GAMBIT will highlight (in white) the shortest edge-along with its label-in the graphics window.

d) Zoom in near the highlighted edge by pressing the Ctrl key while using the mouse to drag a box around the edge.

Figure 5-3 shows the general area on the sedan that contains the shortest edge. Figure 5-4 shows a zoomed view of the edge.

Page 147: Gambit Tutorial Guide

Figure 5-3: Sedan-showing general area of shortest edge location

Figure 5-4: Sedan-showing zoomed area near shortest edge

2. Remove the shortest edge.

GEOMETRY -> VERTEX -> CONNECT/DISCONNECT VERTICES ->

Page 148: Gambit Tutorial Guide

This opens the Connect Vertices form.

a) Select the Virtual (Forced) option.

b) Pick the two vertices on the shortest edge.

c) Click Apply.

When GAMBIT attempts to connect these two vertices, an error message is generated stating that connecting these two vertices will cause the connecting edge to be deleted. In

some cases, this is an undesired effect; therefore, the geometry is protected from such

operations by means of a default setting.

d) Select Defaults from the Edit menu on the main menu bar, and change the value of the GEOMETRY/VERTEX/CONNECT_REMOVE_SHORT_EDGE variable to 1.

e) Repeat steps (a), (b), and (c).

This time, GAMBIT connects the vertices without generating an error message.

f) Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the full sedan in the graphics window.

g) Select the Virtual (Tolerance) option to activate the Highlight shortest edge button on the Connect Vertices form.

h) Click the Highlight shortest edge button and repeat steps (a), (b), and (c) to eliminate the next shortest edge (see Figure 5-5).

Page 149: Gambit Tutorial Guide

i) Repeat steps (f) and (g) to verify that the shortest edge is now acceptable.

Figure 5-5: Sedan-showing zoomed area near next shortest edge

Step 4: Automatically Connect All Remaining "Duplicate" Edges

The imported IGES geometry is still "dirty"-that is, there are a few gaps remaining

between the faces that make it unsuitable for creating a mesh. In this step, you will "clean

up" the geometry using GAMBIT's tools.

1. Connect all edges in the geometry that are less than a specified tolerance apart using an automatic method.

GEOMETRY -> EDGE -> CONNECT/DISCONNECT EDGES ->

This opens the Connect Edges form.

Page 150: Gambit Tutorial Guide

a) Select All from the option menu to the right of Edges.

b) Select the Real and Virtual (Tolerance) option.

You want GAMBIT to connect all real and virtual edges that are within a tolerance distance of each other.

c) Enter a value of 10 for the Shortest Edge % and press Enter.

The Tolerance value in the Connect Edges form will be updated.

d) Select the T-Junctions option.

This option ensures that edges that do not match up correctly will be connected.

GAMBIT will perform edge splits and then reconnect the geometry; an example is shown in Figure 5-6.

Page 151: Gambit Tutorial Guide

Figure 5-6: Connecting edges

e) Click Apply.

A few more edges turn blue in the graphics window as they are connected.

! The edges on the symmetry plane will remain orange because they do not have any other edges with which they can be connected.

When GAMBIT has finished connecting the edges, three of the edges will still be orange (apart from those on the symmetry plane). You could increase the Shortest Edge % and connect the edges again, but instead you will learn how to manually force the

connections.

You will use the manual approach in this case because there are only a few more edges

to connect. The manual approach is useful when the gaps between the edges are of the

order of the shortest edge in size, or larger, because the Shortest Edge % connection would require a size so large that other faces would become collapsed.

2. Connect edges using a manual method.

a) Tilt the geometry forward slightly by holding down the left mouse button in the graphics window and then moving the mouse pointer downward. Then turn the geometry to view the front bumper by holding down the left mouse button in the graphics window and moving the mouse pointer to the right.

This will enable you to distinguish the pairs of orange unconnected edges from the edges

on the symmetry plane, which are also orange.

Page 152: Gambit Tutorial Guide

b) Zoom in near the front of the car by holding down the Ctrl key on the keyboard while dragging a box around the front of the car with the left mouse button. Figure 5-7 shows the area on the sedan where you will find the unconnected edges, and Figure 5-8 shows a zoomed view of the front of the sedan. You should clearly see three pairs of orange edges at the front of the sedan.

You will not be able to see that there are two edges to the pair, but the fact that the edges

are orange indicates that there are two unconnected edges there.

Figure 5-7: Area to zoom into on the sedan

Page 153: Gambit Tutorial Guide

Figure 5-8: Zoomed view of the front of the sedan

c) Select Pick from the option menu to the right of Edges in the Connect Edges form.

d) Select the Virtual (Forced) option.

You will force GAMBIT to manually connect the edges that you select, using GAMBIT's virtual geometry.

e) Select one pair of orange edges by holding down the Shift key and dragging a small box across the edges with the left mouse button.

! The box does not have to completely enclose the edges; it only needs to enclose a

portion of an edge to select it. The edges will be selected when you release the mouse

button.

It will appear as if only one edge is selected in the graphics window, unless you zoom in

very close to the pair of edges.

f) Click Apply to accept the selection and connect the edges.

g) Repeat steps (e) and (f) to connect the other two pairs of edges.

3. Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the full sedan in the graphics window.

Step 5: Merge Faces

In many cases, the IGES model contains more detail than you need for meshing. The

imported geometry for the sedan includes a number of small faces, the edges of which

may constrain the mesh generation process unnecessarily. In GAMBIT, you can merge faces together prior to meshing.

1. Merge some of the faces on the sedan hood.

GEOMETRY -> FACE -> SPLIT/MERGE/COLLAPSE FACES ->

R

This opens the Merge Faces (Virtual) form.

Page 154: Gambit Tutorial Guide

a) Select Virtual (Forced) under Type.

b) Zoom in to the hood of the sedan by holding down the Ctrl key on the keyboard while dragging a box around the hood of the car with the left mouse button.

c) Select the three faces on the top of the hood as shown in Figure 5-9, either by selecting one at a time, or by selecting all three faces within a box.

d) Click Apply to accept the selected faces and merge them into one face, as shown in Figure 5-10.

Figure 5-9: Three faces on hood of sedan

Page 155: Gambit Tutorial Guide

Figure 5-10: Three faces merged on hood of sedan

2. Merge four faces on the trunk of the car (just behind the rear window) using the above method. The faces to be merged are shown in Figure 5-11, and the merged faces are shown in Figure 5-12.

Figure 5-11: Four faces on trunk of sedan

Page 156: Gambit Tutorial Guide

Figure 5-12: Four faces merged on trunk of sedan

3. Merge three faces near the rear end of the trunk of the car using the above method. The faces to be merged are shown in Figure 5-13, and the merged faces are shown in Figure 5-14.

Figure 5-13: Three faces near rear end of trunk

Page 157: Gambit Tutorial Guide

Figure 5-14: Three faces merged near rear end of trunk

4. Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the full sedan in the graphics window.

The top portion of the trunk should now consist of two large faces, as shown in Figure 5-

15.

Figure 5-15: Merged faces on sedan

Step 6: Mesh Faces on Car Body

1. Create a surface mesh on the faces of the car body.

Page 158: Gambit Tutorial Guide

MESH -> FACE -> MESH FACES ->

a) Select all the faces on the car body by holding down the Shift key and using the left mouse button to drag a box around the whole geometry in the graphics window.

! It may take a while for GAMBIT to select all the faces. GAMBIT is analyzing each face to determine suitable meshing schemes. You should wait until all the edges turn red

before going on to the next step.

b) Select Tri from the hidden Elements menu under Scheme, and select Pave from the Type option menu.

See the GAMBIT Modeling Guide for more information on meshing schemes.

c) Enter an Interval size of 0.03 under Spacing and click the Apply button at the bottom of the form.

GAMBIT will mesh the car body surfaces. A portion of the mesh is shown in Figure 5-16.

Page 159: Gambit Tutorial Guide

Figure 5-16: Surface mesh on rear of car body

2. Remove the mesh from the display.

! This will make it easier to see what to do in the next steps. The mesh is not deleted, just removed from the graphics window.

a) Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad.

This opens the Specify Display Attributes form.

Page 160: Gambit Tutorial Guide

b) Select Off from the option menu to the right of Mesh near the bottom of the form.

GAMBIT will select the Mesh check box.

c) Click Apply and close the form.

The mesh will be removed from the graphics window.

Step 7: Create a Brick Around the Car Body

1. Create a brick.

GEOMETRY -> VOLUME -> CREATE VOLUME ->

This opens the Create Real Brick form.

Page 161: Gambit Tutorial Guide

a) Enter a value of 10 for the Width of the brick.

b) Enter 5 for the Depth and 5 for the Height.

c) Select Centered from the option menu to the right of Direction.

d) Click Apply.

2. Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the full sedan and the brick just created in the graphics window.

3. Move the brick to the desired location relative to the sedan.

GEOMETRY -> VOLUME -> MOVE/COPY/ALIGN VOLUMES ->

This opens the Move / Copy Volumes form.

Page 162: Gambit Tutorial Guide

a) Shift-left-click the brick in the graphics window.

b) Select Move (the default) under Volumes in the Move / Copy Volumes form.

c) Select Translate (the default) under Operation.

d) Enter (0, 2.5, 2.5) under Global to move the brick 2.5 units in the y direction and 2.5 units in the z direction.

Note that GAMBIT automatically fills in the values under Local as you enter values under Global.

e) Click Apply.

4. Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the full sedan and the brick in the graphics window.

The brick and sedan are shown in Figure 5-17.

Page 163: Gambit Tutorial Guide

Figure 5-17: Brick and sedan

Step 8: Remove Unwanted Geometry

You cannot simply subtract the car from the brick to produce the flow domain around the

car, because you used "virtual geometry" to clean up the car body and GAMBIT cannot perform Boolean operations on virtual geometry. Instead, you must "stitch together" a

virtual volume from the virtual faces of the car and the real faces of the brick. To do this

you will delete the volume of the brick, leaving the lower geometry (the faces) behind. In

the next steps, you will create virtual edges and faces.

1. Delete the volume of the brick, leaving the faces behind.

GEOMETRY -> VOLUME -> DELETE VOLUMES

This opens the Delete Volumes form.

a) Shift-left-click the brick in the graphics window.

b) Deselect the Lower Geometry option in the Delete Volumes form and click Apply.

The brick volume will be deleted, but all its components (faces, edges, and vertices) will

remain in the geometry, because you deselected the Lower Geometry option.

Page 164: Gambit Tutorial Guide

Step 9: Create Straight Edges on the Symmetry Plane

In this step, you will create two straight edges that will be used in the next step to create

faces on the symmetry plane.

1. Split the bottom edge of the symmetry plane into three sections.

GEOMETRY -> EDGE -> SPLIT/MERGE EDGES

This opens the Split Edge form.

a) Select the Real connected option (the default) next to Type.

b) Select Split With Point (the default).

You will split the edge by creating a point on the edge and then using this point to split

the edge.

c) Use the Ctrl key and the left mouse button to zoom in to the sedan and the line at the bottom of the symmetry plane, similar to the view shown in Figure 5-18.

d) Select the blue line at the bottom of the symmetry plane in the graphics window.

e) Enter a U Value of 0.64 in the Split Edge form and click Apply.

Page 165: Gambit Tutorial Guide

The vertex needs to be close to the front of the sedan. A U Value of 0.64 will place the vertex in the correct position, but it is the position relative to the sedan that is important,

not the exact U Value.

The edge is split into two parts and a vertex is created near the front bumper of the

sedan, as shown in Figure 5-18.

f) Select the longer edge of the two edges just created in the graphics window.

g) Enter a U Value of 0.57 in the Split Edge form and click Apply.

Again, the position of the vertex relative to the sedan is more important than the exact U Value.

The edge will be split and a second vertex created near the rear bumper of the sedan, as

shown in Figure 5-18.

Figure 5-18: Bottom edge of symmetry plane is split into three edges

2. Create straight edges between the two points just created and two points on the sedan.

GEOMETRY -> EDGE -> CREATE EDGE

This opens the Create Straight Edge form.

Page 166: Gambit Tutorial Guide

a) Select the Virtual option to the right of Type.

You must use Virtual because the vertex to be used on the car body is a virtual vertex.

b) Zoom in to the front of the sedan, so that you can see the front bumper and the first vertex created on the line at the bottom of the symmetry plane, as shown in Figure 5-19.

c) Shift-left-click the first vertex created on the bottom line of the symmetry plane.

d) Shift-left-click the vertex on the sedan that is also on the symmetry plane, as shown in Figure 5-19.

! Make sure that you select the vertex that is on the symmetry plane as well as the sedan.

The vertex will be on an orange line if it is on both the symmetry plane and the sedan

geometry.

e) Click Apply to accept the selected vertices and create a line, as shown in Figure 5-19.

Figure 5-19: Line from bottom of symmetry plane to front of sedan

Page 167: Gambit Tutorial Guide

3. Create a straight line from the second vertex created on the bottom line of the symmetry plane to the rear bumper of the sedan, as shown in Figure 5-20.

! Again, make sure you select the vertex that is on both the sedan geometry and the symmetry plane.

Figure 5-20: Line from bottom of symmetry plane to rear of sedan

Step 10: Create Faces on the Symmetry Plane

In this step, you will create two new faces on the symmetry plane by stitching edges

together. You will use the existing symmetry plane on the brick as a host. The two faces

you create in this step will be used to create a volume in the next step.

1. Create a new face on the symmetry plane by stitching edges together.

GEOMETRY -> FACE -> FORM FACE

This opens the Create Face From Wireframe form.

Page 168: Gambit Tutorial Guide

a) Select the Virtual option next to Type.

You must use Virtual because the edges to be selected on the car body are virtual edges.

b) Shift-left-click the edges underneath the sedan, the two small diagonal edges on the symmetry plane, and the middle edge at the bottom of the symmetry plane.

! The area under the sedan where the edges to be selected are located is shown in Figure 5-21, and the edges to be selected are shown in Figure 5-22.

Figure 5-21: Area under sedan where edges to be selected are located

! You should select seven edges in total. Pay particular attention to any very small edges. If you select an incorrect edge, Shift-middle-click on the edge to deselect it and select the edge next to it.

Page 169: Gambit Tutorial Guide

Figure 5-22: Edges used to create face at bottom of sedan

c) Select the Host check box in the Create Face From Wireframe form.

d) Select Face from the Host option menu.

e) Shift-left-click the back face of the brick (the symmetry plane) in the graphics window, as shown in Figure 5-23.

If you select the wrong face, Shift-middle-click on the face to deselect it and select the face next to it.

f) Enter 0.001 in the Tolerance text entry box.

The tolerance value (0.001) must be less than or equal to the tolerance used for the

connect operation (0.00163959). (See page 12.)

g) Click Apply to accept the selection and create the face.

Page 170: Gambit Tutorial Guide

Figure 5-23: Symmetry plane of the brick

2. Create a second face on the symmetry plane.

a) Check that the Virtual option is selected next to Type.

b) Left-click in the Edges list box in the Create Face From Wireframe form.

c) Select all the edges shown in Figure 5-24.

! You should select 26 edges in total.

d) Left-click in the list box to the right of Host in the form.

e) Shift-left-click the back face of the brick (the symmetry plane) in the graphics window, as shown in Figure 5-23.

f) Click Apply to accept the selection and create the face.

Page 171: Gambit Tutorial Guide

Figure 5-24: Edges used to create face at top of sedan

3. Verify the creation of the faces.

GEOMETRY -> FACE -> SUMMARIZE/QUERY FACES/TOTAL ENTITIES

This opens the Summarize Faces form.

a) Left-click the black arrow to the right of the Faces list box.

This opens the Face List form. There are two types of pick-list forms: Single and Multiple. In a Single pick-list form, only one entity can be selected at a time. In a Multiple pick-list form, you can select multiple entities.

Page 172: Gambit Tutorial Guide

i. Select the two faces at the bottom of the Available list in the Face List form.

! Note that the names of entities in the Available list may be different in your geometry. In the above form, the last two faces in the Available list are v_face.151 and v_face.152, but you might see faces with different numbers.

ii. Click the > button to pick the two faces.

The two faces will be moved from the Available list to the Picked list, and they will be highlighted in the graphics window.

iii. Check that the two faces highlighted in the graphics window are the correct faces that you should have created in the previous steps.

Figure 5-22 and Figure 5-24 show the faces that you should have created.

iv. Close the Face List form.

b) Click Reset in the Summarize Faces form to deselect the two faces in the graphics window.

Step 11: Create a Volume

1. Use the faces to create a volume.

GEOMETRY -> VOLUME -> FORM VOLUME

This opens the Stitch Faces form.

Page 173: Gambit Tutorial Guide

a) Select the Virtual option next to Type.

b) Select the symmetry plane in the graphics window (as shown in Figure 5-23) and remember the label name (e.g., face.149).

c) Left-click the black arrow to the right of the Faces list box.

This opens the Face List form.

i. Click on the All > button to move all the faces from the Available list to the Picked list.

ii. Select the name of the symmetry plane in the Picked list.

The symmetry plane face will be highlighted in the graphics window.

iii. Click the < button to move the symmetry plane face back into the Available list.

iv. Close the Face List form.

d) Click Apply in the Stitch Faces form to accept the selection of the faces and create the volume.

Page 174: Gambit Tutorial Guide

Step 12: Mesh the Edges

When you created the mesh on the faces of the sedan, you used a fine mesh. For the

volume, you will create a more coarse mesh, so you will need to instruct GAMBIT to gradually change the mesh density between the coarse and fine meshes. To do this, you

will specify the distribution of nodes along some edges in the geometry.

1. Define the grid density on three edges of the geometry underneath the sedan.

MESH -> EDGE -> MESH EDGES

This opens the Mesh Edges form.

a) Select the edges marked A, B, and C in Figure 5-25 (the two small edges you created underneath the sedan and the middle section of the edge underneath the sedan that you split into three sections).

The edges will change color and an arrow and several circles will appear on each edge.

Page 175: Gambit Tutorial Guide

Figure 5-25: Edges underneath the sedan to be selected for edge meshing

b) Check that Apply is selected to the right of Grading in the Mesh Edges form and that Successive Ratio is selected from the Type option menu.

The Successive Ratio option sets the ratio of distances between consecutive points on the edge equal to the Ratio specified in the Mesh Edges form.

c) Retain the default Ratio of 1.

d) Check that Apply is selected to the right of Spacing. Select Interval size from the option menu under Spacing and enter a value of 0.03 in the text entry box.

e) Click the Apply button at the bottom of the form.

Figure 5-26 shows the mesh on two of the edges underneath the sedan.

Page 176: Gambit Tutorial Guide

Figure 5-26: Edge meshing near the front of the sedan

2. Define the grid density on the two outer sections of the edge underneath the sedan that you split into three sections.

a) Select the edges marked D and E in Figure 5-27 (two of the edges you created by splitting the edge underneath the sedan into three sections).

b) Make sure that the arrows on the two edges point away from the sedan. Shift-middle-click on an edge to change the direction of the arrow, if necessary.

Figure 5-27: Edges to be selected for edge meshing

Page 177: Gambit Tutorial Guide

c) Check that Apply is selected to the right of Grading in the Mesh Edges form and select First Length from the Type option menu.

The First Length option sets the length of the first interval on the edge. The other points on the edge are calculated using the geometric ratio factor required to fit the specified

number of points in the remaining portion of the edge.

d) Enter a value of 0.03 next to Length.

e) Check that Apply is selected to the right of Spacing. Select Interval count from the option menu under Spacing and enter a value of 15 in the text entry box.

f) Click the Apply button at the bottom of the form.

The meshed edges are shown in Figure 5-28.

Figure 5-28: Edge meshing for the sedan geometry

Step 13: Mesh the Volume

1. Mesh the volume with a coarser mesh than the mesh on the car faces.

MESH -> VOLUME -> MESH VOLUMES

This opens the Mesh Volumes form.

Page 178: Gambit Tutorial Guide

a) Select the volume in the graphics window.

b) Select Tet/Hybrid from the Elements option menu under Scheme in the Mesh Volumes form, and select TGrid from the Type option menu.

See the GAMBIT Modeling Guide for more information on meshing schemes.

c) Retain the default Interval size of 1 under Spacing and click the Apply button at the bottom of the form.

A portion of the volume mesh (looking at the sedan from the symmetry plane side) is

shown in Figure 5-29, along with the surface mesh for the sedan, which you previously

turned off. To redisplay the surface mesh, click the SPECIFY MODEL DISPLAY

ATTRIBUTES command button at the bottom of the Global Control toolpad. Select On from the option menu to the right of Mesh near the bottom of the form and click Apply.

To achieve the model view shown in Figure 5-29, below, you must turn on hidden-line

removal mode and make the symmetry plane invisible.

i) To turn on hidden-line removal, right-click the RENDER MODEL command button

in the Global Control toolpad and select from the resulting list.

ii) To make the symmetry plane invisible, click the SPECIFY MODEL DISPLAY

ATTRIBUTES command button to open the Specify Display Attributes form, select

Page 179: Gambit Tutorial Guide

Off from the option menu to the right of Visible option, click the Faces pick-list button to open the Face List (Multiple) pick-list form, select the symmetry face (face.149) from the pick-list form, close the form, and click Apply on the Specify Display Attributes form.

Figure 5-29: A portion of the volume mesh

Step 14: Examine the Volume Mesh

1. Select the EXAMINE MESH command button at the bottom right of the Global Control toolpad.

This opens the Examine Mesh form.

Page 180: Gambit Tutorial Guide

a) Select Range under Display Type at the top of the form.

The 3D Element type selected by default at the top of the form is a brick . You will

not see any mesh elements in the graphics window when you first open the Examine Mesh form, because there are no hexahedral elements in the mesh.

b) Left-click on the tetrahedron icon next to 3D Element near the top of the form.

The mesh elements will now be visible in the graphics window.

c) Select EquiVolume Skew from the Quality Type option menu.

Page 181: Gambit Tutorial Guide

This is the default skewness measure for tetrahedra in TGrid.

d) Click with the left mouse button on the histogram bars that appear at the bottom of the Examine Mesh form to highlight elements in a particular quality range.

Figure 5-30 shows the view in the graphics window if you click on the fourth bar from the right on the histogram (representing cells with a skewness value between 0.6 and 0.7). These low values for the maximum skewness indicate that the mesh is acceptable.

The histogram consists of a bar chart representing the statistical distribution of mesh

elements with respect to the specified Quality Type. Each vertical bar on the histogram corresponds to a unique set of upper and lower quality limits.

Figure 5-30: Elements within a specified quality range

e) Close the Examine Mesh form by clicking the Close button at the bottom of the form.

Step 15: Set Boundary Types

1. Remove the mesh from the display before you set the boundary types.

This makes it easier to see the edges and faces of the geometry. The mesh is not deleted,

just removed from the graphics window.

a) Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the Global Control toolpad.

b) Select Off from the option menu to the right of Mesh near the bottom of the form.

c) Click Apply and close the form.

Page 182: Gambit Tutorial Guide

2. Set boundary types for the sedan.

ZONES -> SPECIFY BOUNDARY TYPES ->

This opens the Specify Boundary Types form.

a) Define the pressure inlet boundary.

i. Select PRESSURE_INLET in the Type option menu.

ii. Check that Faces is selected as the Entity.

iii. Shift-left-click the face on the brick in front of the car in the graphics window (marked A in Figure 5-31) and click Apply to accept the selection.

This face will be set as a pressure inlet.

Page 183: Gambit Tutorial Guide

GAMBIT will give the boundary a default name based on what you select in the Type and Entity lists (pressure_inlet.1 in this example). You can also specify a name for a boundary by entering a name in the Name text entry box.

Figure 5-31: Pressure inlet (A) and pressure outlet (B) for the sedan geometry

b) Define the pressure outlet boundary.

i. Change the Type to PRESSURE_OUTLET by selecting it from the option menu below Type.

ii. Select the face on the brick behind the car in the graphics window (marked B in Figure 5-31) and click Apply to accept the selection.

c) Define symmetry boundary types for the two faces on the symmetry plane of the brick.

i. Enter symmetry1 in the Name text entry box.

ii. Select SYMMETRY from the Type option menu.

iii. Select the two faces you created on the symmetry plane of the brick (the faces marked C and D in Figure 5-32) and click Apply to accept the selection.

GAMBIT will merge the two faces into a single symmetry zone.

Page 184: Gambit Tutorial Guide

Figure 5-32: Two faces created on the symmetry plane of the brick

d) Define symmetry boundary types for the top face of the brick and the side face opposite the symmetry plane.

i. Enter symmetry2 in the Name text entry box.

ii. Check that SYMMETRY is selected in the Type option menu.

iii. Select the faces on the brick that are above and to the side of the sedan (the faces marked E and F in Figure 5-33) and accept the selection.

Page 185: Gambit Tutorial Guide

Figure 5-33: Two symmetry boundaries for the sedan geometry

The pressure inlet, pressure outlet, and symmetry boundaries for the sedan geometry are

shown in Figure 5-34.

Figure 5-34: Boundary types for the sedan geometry

Note that you could also specify the remaining outer edges of the sedan geometry as wall

boundaries. This is not necessary, however, because when GAMBIT saves a mesh, any faces (in 3D) on which you have not specified a boundary type will be written out as wall

boundaries by default.

Page 186: Gambit Tutorial Guide

In addition, when GAMBIT writes a mesh, any volumes (in 3D) on which you have not specified a continuum type will be written as fluid by default. This means that you do not

need to specify a continuum type in the Specify Continuum Types form for this tutorial.

Step 16: Export the Mesh and Save the Session

1. Export a mesh file for the sedan.

File Export Mesh…

This opens the Export Mesh File form.

a) Enter the File Name for the file to be exported (sedan.msh).

b) Click Accept in the Export Mesh File form.

The file will be written to your working directory.

2. Save the GAMBIT session and exit GAMBIT.

File -> Exit

GAMBIT will ask you whether you wish to save the current session before you exit.

Click Yes to save the current session and exit GAMBIT.

5.5 Summary

Page 187: Gambit Tutorial Guide

This tutorial illustrated how to import geometry from an external CAD package as an IGES file, and mesh it. Several geometry "cleanup" operations were demonstrated. Additional geometry was created to construct a box around the car-body geometry, and an unstructured tetrahedral volume mesh was generated.

© Fluent, Inc. 10/27/99

Page 188: Gambit Tutorial Guide

6. MODELING FLOW IN A TANK

In this tutorial you will utilize the techniques illustrated in the previous tutorials to create a complex pipe junction that represents a real-world example of flow in a process tank.

In this tutorial you will learn how to:

• Create cylinders and bricks by defining their dimensions • Translate and rotate volumes • Perform Boolean operations on volumes (unite and subtract) • Split a volume using another volume • Align two volumes using a vertex pair • Specify the distribution of nodes on an edge • Add boundary layers to your geometry • Generate an unstructured hexahedral mesh • Examine the quality of the mesh • Prepare the mesh to be read into FIDAP

6.1 Prerequisites

This tutorial assumes that you have worked through Tutorials 1, 2, 3, and 4.

6.2 Problem Description

The problem to be considered is shown schematically in Figure 6-1. Due to symmetry, only half of the actual model is shown.

The geometry consists of a large cylindrical tank with an inlet/outlet annular section. This section is connected to the tank at half the length of the tank and at an offset from the center of the tank. In the annular section, the inner pipe is the inlet pipe. There is a small T-junction on the upper end of outer pipe. This is the outlet.

The overall goal is to create a high quality hexahedral mesh including boundary layers and edge meshing to sufficiently capture gradient in solution variables, such as velocity and temperature. The solver selected for this tutorial is FIDAP

Page 189: Gambit Tutorial Guide

Figure 6-1: Problem specification

6.3 Strategy

In this tutorial we will combine several of the previously shown tools and strategies and apply them on a real industrial problem. The first thing to find out is if the boundary condition and the physics will allow us to model only half of the geometry. This is a very important step since it immediately reduces the effort of preprocessing and running time. After confirming the symmetry condition, we start building the geometry using primitives and Boolean operations. Although we normally recommend to create the model in the following order;

1. Geometry creation 2. Decomposition 3. Mesh generation

We will illustrate, in this journal, that the order of geometry creation and decomposition is not strict. Mesh generation, though, should in all cases be left to last.

Page 190: Gambit Tutorial Guide

The overall geometry creation is fairly straightforward and based on cylinder primitives, Boolean unites, and subtracts. The model can not be meshed as is, using hexahedral meshing, since several faces in this model are non-trivial and their normals are facing all three major directions. Essentially there are two pipe-pipe intersections, which needs to be decomposed

The first section is the pipe/annulus intersection at the outlet. In this situation, the recommended strategy is to use a block to split of the outlet pipe. The split has to be made with an angle, such that the unstructured mesh from the pipe will be "projected" to the wall of the inner pipe. (See the following figure.)

The second section is the main intersection of the inlet/outlet pipes with the tank. Again, we are using a block to split of the bigger tank section into a center section. We are tilting the cutting block to optimize mesh quality. This will allow the mesh on all non-trivial source faces to be "projected" into the bottom of the tank as illustrated in the picture below

Page 191: Gambit Tutorial Guide

Edge meshing and boundary layers are applied at several areas to ensure appropriate grading in key areas of the model. The boundary layers are particularly important in areas where the face is being paved-that is, on most source faces, while edge meshing is used where the mesh is being mapped. In some cases edge meshing and boundary layer are combined for full control over the mesh density

Several techniques are used in the face meshing part like; enforce Submap without meshing and multiple source face meshing, where side faces between source faces are also meshed

Finally, the Cooper tool is used to mesh all volumes in this model.

6.4 Procedure

Start GAMBIT using the session identifier "Tank".

Step 1: Select a Solver

1. You will change the solver to FIDAP

The choice of a solver dictates the options available in various forms (for example, the

boundary types available in the Specify Boundary Types form). The solver currently selected is indicated at the top of the GAMBIT GUI.

Page 192: Gambit Tutorial Guide

Step 2: Set the Default Interval Size for Meshing

Edit -> Defaults…

In this tutorial, you will change the default interval size used for meshing. The mesh

spacing is by default based on the interval size function, which you will modify in the Edit Defaults form. The value you enter should be the estimated average size of an element in the model. This value will appear as the default Interval size on all meshing forms. You will be able to change it on the meshing forms if required.

1. Select the MESH tab at the top of the form. immediate

2. Select the INTERVAL radio button near the top of the form.

3. Select SIZE in the Variable list.

SIZE will appear in the space at the bottom of the list and its default value will appear in

the Value text entry box.

4. Enter a value of 2 in the Value text entry box.

5. Click the Modify button to the left of SIZE.

The Value of the variable SIZE will be updated in the list.

6. Close the Edit Defaults form.

Page 193: Gambit Tutorial Guide

Step 3: Create Cylinders

1. Create the first pipe for the pipe junction.

GEOMETRY -> VOLUME -> CREATE VOLUME R

Page 194: Gambit Tutorial Guide

This opens the Create Real Cylinder form.

a) Enter a Height of 60.

b) Enter 40 for Radius 1.

The text entry box for Radius 2 can be left blank; GAMBIT will set this value by default to be the same value as Radius 1.

c) Select Positive Z (the default) in the list to the right of Axis Location.

d) Click Apply.

e) Click the FIT TO WINDOW command button at the top left of the Global Control toolpad to see the cylinder created.

You can rotate the view by holding down the left mouse button and moving the mouse. The cylinder is shown in Figure 6-2.

Page 195: Gambit Tutorial Guide

Figure 6-2: First cylinder for the pipe junction

2. Create a second cylinder, with a Height of 64, a Radius 1 of 13, in the Centered Y direction.

The two cylinders are shown in Figure 6-3.

Figure 6-3: Second cylinder for the pipe junction

Page 196: Gambit Tutorial Guide

3. Create a third cylinder, with a Height of 64, a Radius 1 of 6, in the Centered Y direction.

4. Create a fourth cylinder, with a Height of 64, a Radius 1 of 4, in the Centered Y direction.

The four cylinders created so far are shown in Figure 6-4.

5. Create a fifth cylinder, with a Height of 16, a Radius 1 of 6, in the Centered X direction.

The five cylinders are shown in Figure 6-5.

Figure 6-4: Four cylinders for the pipe junction

Page 197: Gambit Tutorial Guide

Figure 6-5: Five cylinders for the pipe junction

Step 4: Complete the Geometry Creation

1. Move three of the cylinders to create the geometry of the complex pipe junction.

GEOMETRY -> VOLUME -> MOVE/COPY/ALIGN VOLUMES

This opens the Move / Copy Volumes form.

Page 198: Gambit Tutorial Guide

a) Select the second, third, and fourth cylinders created, by either selecting them in the graphics window or using the Volume query list.

b) Select Move (the default) under Volume in the Move / Copy Volumes form.

c) Select Translate (the default) under Operation.

d) Enter a Global translation vector of (-17, 52, 0) and click Apply.

Note that GAMBIT automatically fills in the values under Local as you enter values under Global.

The three cylinders will be moved as shown in Figure 6-6.

Page 199: Gambit Tutorial Guide

Figure 6-6: Three cylinders moved into position for the complex pipe junction geometry

2. Move the fifth cylinder using a Global translation vector of (-32, 74, 0).

3. Subtract volume.3 from volume.2.

The order of selecting the volumes is important. For example, Figure 6-7 shows the

difference between subtracting volume B from volume A, and vice versa.

Figure 6-7: Subtracting volumes

Page 200: Gambit Tutorial Guide

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

R

This opens the Subtract Real Volumes form.

a) Select volume.2 in the graphics window and Accept the selection of the volume.

b) Select volume.3 and accept the selection of the volume.

The completed geometry is shown in Figure 6-8.

Figure 6-8: Completed geometry

Page 201: Gambit Tutorial Guide

Step 5: Decompose the Geometry

In this tutorial we are decomposing the big tank before we are uniting it with all the

pipes. If we reversed the order, the pipes would have been split right through them, which

is undesirable. We also rotating the brick to make the cut of the tank be more symmetric.

This will also increase the edge-angle of one of the faces, which ultimately leads to better

mesh quality

1. Create a brick to split the large cylinder.

GEOMETRY -> VOLUME -> CREATE VOLUME R

This opens the Create Real Brick form.

a) Enter a value of 42 for the Width of the brick.

b) Enter a Depth of 82 and a Height of 160.

c) Select Centered from the option menu to the right of Direction and click Apply.

The brick and the pipe junction are shown in Figure 6-9.

Page 202: Gambit Tutorial Guide

Figure 6-9: Brick and complex pipe junction

2. Rotate the brick relative to the geometry.

GEOMETRY -> VOLUME -> MOVE/COPY/ALIGN VOLUMES

This opens the Move / Copy Volumes form.

Page 203: Gambit Tutorial Guide

a) Select the brick in the graphics window.

b) Select Move (the default) under Volume at the top of the Move / Copy Volumes form.

c) Select Rotate under Operation.

d) Enter an Angle of 30 for the angle of rotation.

You will use the default Active Coord. Sys. Vector. The brick will be rotated around the z axis.

e) Click Apply.

The brick will be rotated as shown in Figure 6-10.

Page 204: Gambit Tutorial Guide

Figure 6-10: Rotated brick

3. Split the largest cylinder using the brick.

If you split one volume with another volume, the following volumes will result:

• Volumes corresponding to the common region(s) from intersection. • Volumes corresponding to the region(s) defined by subtracting the second volume

from the first.

In other words, splitting a volume results in a combination of the intersection and

subtraction Boolean operations. The order of selecting the volumes is important. For

example, Figure 6-11 shows the difference between splitting volume A using volume B,

and vice versa.

Page 205: Gambit Tutorial Guide

Figure 6-11: Splitting volumes

GEOMETRY -> VOLUME -> SPLIT/MERGE VOLUMES

This opens the Split Volume form.

a) Select the first cylinder you created in the graphics window (the largest cylinder) and accept the selection of the cylinder.

b) Select the brick in the graphics window.

c) Click Apply.

Page 206: Gambit Tutorial Guide

The cylinder will be split as shown in Figure 6-12.

Figure 6-12: Splitting the large cylinder

Step 6: Unite Some Parts of the Geometry

1. Unite two of the volumes into one volume.

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

R

This opens the Unite Real Volumes form.

Page 207: Gambit Tutorial Guide

Figure 6-13: Volumes to be united

a) Select the cylinder that you created by subtracting one cylinder from another in Step 3 (the volume marked A in Figure 6-13).

b) Select the middle section of the largest pipe which was created by splitting the pipe with the brick (the volume marked B in Figure 6-13).

c) Click Apply.

The two volumes will be united as shown in Figure 6-14. The order in which you select

the two volumes is not important when you are uniting them.

Page 208: Gambit Tutorial Guide

Figure 6-14: Two volumes united into one

2. Unite two more volumes.

a) Select the middle cylinder of the three concentric cylinders (the volume marked C in Figure 6-13).

b) Select the volume you created in the previous step.

c) Click Apply.

The united volumes are shown in Figure 6-15.

Page 209: Gambit Tutorial Guide

Figure 6-15: United volumes

Step 7: Subtract the Remaining Parts of the Symmetry Plane

1. Create a brick, which will be used to remove some parts of the geometry to create a symmetry plane in the geometry.

GEOMETRY -> VOLUME -> CREATE VOLUME

This opens the Create Real Brick form.

a) Enter a Width of 50, a Depth of 100, and a Height of 20.

Page 210: Gambit Tutorial Guide

b) Select -X +Y -Z from the Direction option menu.

c) Click Apply to create the brick.

The brick and the pipe junction are shown in Figure 6-16.

Figure 6-16: Brick and pipe junction

2. Subtract the brick from the complex pipe volume.

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

R

This opens the Subtract Real Volumes form.

Page 211: Gambit Tutorial Guide

a) Select the volume that contains most of the pipe sections in the geometry (the volume marked A in Figure 6-17). Accept the selection of the volume.

Figure 6-17: Volume to use in subtraction

b) Select the brick in the graphics window.

c) In the Subtract Real Volumes form, select the Retain check box below Subtract Volume.

This option instructs GAMBIT to subtract the brick from the pipe geometry, but retain the brick to be used again in the next step.

d) Click Apply.

Page 212: Gambit Tutorial Guide

The brick will be subtracted from the pipe geometry as shown in Figure 6-18. Notice that

the brick is still displayed in this figure, this is because the Retain check box is selected in the Subtract Real Volumes form.

Figure 6-18: Brick subtracted from the pipe geometry

3. Subtract the brick from the small pipe.

a) Select the smallest cylinder in the graphics window, and accept the selection.

b) Select the brick in the graphics window.

c) In the Subtract Real Volumes form, deselect the Retain check box.

d) Click Apply.

Figure 6-19 shows the geometry after the subtraction.

Page 213: Gambit Tutorial Guide

Figure 6-19: Brick subtracted from the small pipe to create a symmetry plane

Step 8: Split off Annulus Pipe to Make the Volumes Meshable

1. Create a brick to split off part of the geometry.

Again the decomposition of the cylinder is done before the full geometry has been

created. In this example, we are using Align instead Move/Copy to position the tool to the

appropriate position before the splitting

GEOMETRY -> VOLUME -> CREATE VOLUME

This opens the Create Real Brick form.

Page 214: Gambit Tutorial Guide

a) Enter a value of 20 for the Width of the brick. Leave the Depth and Height text entry boxes blank.

GAMBIT will set the Depth and Height by default to be the same value as the Width, to create a cube.

b) Select -X +Y +Z from the option menu to the right of Direction and click Apply.

2. Rotate the brick relative to the geometry.

GEOMETRY -> VOLUME -> MOVE/COPY/ALIGN VOLUMES

This opens the Move / Copy Volumes form.

Page 215: Gambit Tutorial Guide

a) Select the brick in the graphics window.

b) Select Move (the default) under Volume at the top of the Move / Copy b) Volumes form.

c) Select Rotate under Operation.

d) Enter an Angle of 30 for the angle of rotation.

You will now redefine the Active Coord. Sys. Vector so that GAMBIT rotates the brick about the y axis.

e) Click the Define button to the right of Axis.

This opens the Vector Definition form.

Page 216: Gambit Tutorial Guide

1. i. Select Positive Y under Coordinate System Axis and click Apply.

f) Click Apply in the Move / Copy Volumes form.

3. Create a vertex on the brick.

You will create a vertex on the brick and use it to align the brick correctly relative to the

geometry. This is an alternative method to moving the splitting tool (the brick) to the

right position in the geometry using coordinates.

GEOMETRY -> EDGE -> SPLIT/MERGE EDGE

This opens the Split Edge form.

Page 217: Gambit Tutorial Guide

a) Select the edge on the brick marked A in Figure 6-20.

Figure 6-20: Edge to be split on the brick

b) Enter a U Value of 0.3 in the Split Edge form and click Apply.

Page 218: Gambit Tutorial Guide

4. Align the brick with the part of the geometry to be split.

GEOMETRY -> VOLUME -> MOVE/COPY/ALIGN VOLUMES

R

This opens the Align Volumes form.

a) Select the brick in the graphics window and accept the selection.

The Translation Vertex Pair list box in the Align Volumes form will be highlighted. You will now select the vertex on the object you want to move and then the vertex with which you

want to align the object.

b) Select the vertex you just created on the brick.

c) Select the vertex marked A in Figure 6-21. The vertex is on the end of the long thin pipes near the smallest cylinder.

Page 219: Gambit Tutorial Guide

Figure 6-21: Vertex to be selected to align the brick

d) Click Apply in the form.

The brick will be aligned with the pipe volume as shown in Figure 6-22.

Figure 6-22: Brick aligned with pipe geometry

5. Use the brick to split the volume that contains most of the pipe sections.

GEOMETRY -> VOLUME -> SPLIT/MERGE VOLUMES

This opens the Split Volume form.

Page 220: Gambit Tutorial Guide

a) Select the volume that contains most of the pipe sections in the geometry (the volume marked A in Figure 6-23) and accept the selection.

Figure 6-23: Volumes to be used in the split

b) Select the brick (marked B in Figure 6-23) in the graphics window.

Select Real connected (the default) under Type in the Split Volume form

c) Click Apply.

The geometry will be split as shown in Figure 6-24.

Page 221: Gambit Tutorial Guide

Figure 6-24: Decomposed geometry

Step 9: Unite the Side Pipe

This is the final unite operation to complete the construction of the geometry

1. Unite two more volumes.

GEOMETRY -> VOLUME -> BOOLEAN OPERATIONS

R

This opens the Unite Real Volumes form.

Page 222: Gambit Tutorial Guide

Figure 6-25: Volume to be united

a) Select the volume you created in the previous step (marked A in Figure 6-25).

b) Select the smallest cylinder (the volume marked B in Figure 6-25).

c) Click Apply.

The united volumes are shown in Figure 6-26.

Page 223: Gambit Tutorial Guide

Figure 6-26: United volumes

Step 10: Mesh the Edges

The next step is to define the grid density on some edges of the geometry. You will

accomplish this graphically by selecting an edge, assigning the number of nodes, and

specifying the distribution of nodes along the edge.

1. Define the grid density on four edges of the geometry.

MESH -> EDGE -> MESH EDGES

This opens the Mesh Edges form.

Page 224: Gambit Tutorial Guide

a) Select the edges marked A, B, C, and D in Figure 6-27.

The edges will change color and an arrow and several circles will appear on each edge.

The arrow is small and you may have to zoom into the edge to see it. It is located near the

center of the edge.

Page 225: Gambit Tutorial Guide

Figure 6-27: Edges to be selected for edge meshing

b) Ensure that Apply is selected to the right of Grading in the Mesh Edges form and select Last First Ratio from the Type option menu.

The Last First Ratio is defined as the size ratio between the first element (or grid distance) on the edge, and the last, based on the direction (sense) of the edge. For double sided

grading, the last first ratio is the ratio between the central element and the element at the

end of the edge

c) Enter a value of 3.6 for Ratio 1.

d) Select the Double sided check box

If you specify a Double sided grading on an edge, the element intervals are graded in two directions from a starting point on the edge. GAMBIT determines the starting point such that the intervals on either side of the point are approximately the same length. Ratio 2 is automatically given the value of Ratio 1

e) Ensure that the Apply check box is selected to the right of Spacing. Select Interval size

from the option menu under Spacing and enter a value of 2.5 in the text entry box.

f) Click Apply in the Mesh Edges form.

2. Define the grid density on two edges of the geometry.

a) Select the edges marked E and F in Figure 6-27.

Page 226: Gambit Tutorial Guide

b) Ensure that Apply is selected to the right of Grading in the Mesh Edges form and select Successive Ratio from the Type option menu.

The Successive Ratio option sets the ratio of distances between consecutive points on the edge equal to the Ratio specified in the Mesh Edges form.

c) Retain the default Ratio of 1.

d) Ensure that the Apply check box is selected to the right of Spacing. Enter 5 next to Interval size.

e) Click the Apply button at the bottom of the Mesh Edges form.

The edge meshing for the six edges is shown in Figure 6-28.

Figure 6-28: Edge meshing on the complex pipe junction geometry

Step 11: Apply Boundary Layers

Boundary layers are layers of elements growing out from a boundary into the domain.

They are used to locally refine the mesh in the direction normal to a face or an edge.

Boundary layers are used in this example to improve mesh density close to walls on faces

that will be paved

1. Create boundary layers on one edge.

Page 227: Gambit Tutorial Guide

MESH -> BOUNDARY LAYER -> CREATE BOUNDARY LAYER

This opens the Create Boundary Layer form.

a) Enter 7 next to First row under Definition.

This defines the height of the first row of elements normal to the edge.

b) Enter 0.88 next to Growth factor.

This sets the ratio of distances between consecutive rows of elements.

c) Move the slider box below Rows until the number of rows = 8.

This defines the total number of element rows. Notice that GAMBIT updates the Depth automatically. The depth is the total height of the boundary layer.

Page 228: Gambit Tutorial Guide

d) Retain the default Transition pattern (1:1).

e) Select the edge shown in Figure 6-29 with the boundary layer on it. The boundary layer should appear in the direction shown in Figure 6-29. If it does not, Shift-middle-click the edge to change the direction of the boundary layer.

Figure 6-29: Edge on which to apply the boundary layer, showing the direction in which

the boundary layer should point

f) Click Apply in the Create Boundary Layer form to apply the boundary layer to the edge.

2. Create boundary layers on the three edges shown in Figure 6-30.

a) Enter 0.5 next to First row under Definition.

b) Enter 1.5 next to Growth factor.

c) Move the slider box below Rows until the number of rows = 2.

d) Retain the default Transition pattern (1:1).

e) Select the three edges shown in Figure 6-30 with boundary layers on them. The boundary layers should appear in the directions shown in Figure 6-30. If they do not, Shift-middle-click an edge to change the direction of the boundary layer.

Page 229: Gambit Tutorial Guide

Figure 6-30: Edges on which to apply the boundary layers, showing the directions in

which the boundary layers should point

f) Click Apply in the Create Boundary Layer form to apply the boundary layers to the edges.

2. Create boundary layers on the three edges shown in Figure 6-31.

a) Enter 1 next to First row under Definition.

b) Enter 1.5 next to Growth factor.

c) Move the slider box below Rows until the number of rows = 2.

d) Retain the default Transition pattern (1:1).

e) Select the three edges shown in Figure 6-31 with boundary layers on them. The boundary layers should appear in the directions shown in Figure 6-31. If they do not, Shift-middle-click an edge to change the direction of the boundary layer.

Page 230: Gambit Tutorial Guide

Figure 6-31: Edges on which to apply the boundary layers, showing the directions in

which the boundary layers should point

f) Click Apply in the Create Boundary Layer form to apply the boundary layers to the edges.

Step 12: Turn Off Automatic Smoothing of the Mesh

It is necessary to turn off smoothing of the mesh in this example, because smoothing

would "wash out" the boundary layers on the ends of the pipes.

Edit -> Defaults…

This opens the Edit Defaults form.

Page 231: Gambit Tutorial Guide

1. Select the MESH tab at the top of the form.

This displays the types of meshing for which you can set defaults.

2. Select the FACE radio button.

GAMBIT displays the Variables for which defaults are set in a list in the Edit Defaults form.

Page 232: Gambit Tutorial Guide

3. Select AUTO_SMOOTH in the Variable list.

AUTO_SMOOTH will appear in the text entry box at the bottom of the list and its default

value will appear in the Value text entry box.

4. Enter a value of 0 in the Value text entry box.

5. Click the Modify button to the left of AUTO_SMOOTH.

The Value of the variable AUTO_SMOOTH will be updated in the list.

6. Close the Edit Defaults form.

Step 13: Mesh One of the Volumes

1. Mesh the volume marked C in Figure 6-32.

MESH -> VOLUME -> MESH VOLUMES

This opens the Mesh Volumes form.

a) Select the volume marked C in Figure 6-32 in the graphics window.

GAMBIT will automatically select the Cooper Scheme in the Mesh Volumes form. See the GAMBIT Modeling Guide for more information on the Cooper meshing scheme.

Page 233: Gambit Tutorial Guide

Figure 6-32: Volume to be meshed

b) Retain the default Interval size of 2 under Spacing in the Mesh Volumes form and click the Apply button at the bottom of the form.

This accepts the volume you selected as the one to be meshed. It also accepts the source

faces (the faces whose surface mesh is to be swept through the volume to form volume

elements) GAMBIT has chosen for the Cooper meshing scheme and starts the meshing. If you need to modify or confirm the source faces, either pick faces from the graphics

window or modify the selection of source faces by means of the Sources face text box. The mesh for the volume is shown in Figure 6-33.

Page 234: Gambit Tutorial Guide

Figure 6-33: Mesh for volume C

It may be useful to remove the mesh from the display before you mesh the faces in the

next exercise; it is then easier to see the faces of the geometry. The mesh is not deleted,

just removed from the graphics window. To remove the mesh from the display, click the

SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom of the

Global Control toolpad. Select Off from the option menu to the right of Mesh near the bottom of the form and click Apply.

Step 14: Mesh Some Faces

These faces are meshed to ensure a good mesh density around the pipes and mapped

meshes on some of the source faces. Some side faces also need to be meshed to assure

mesh matching between different source faces

1. Mesh the face marked A in Figure 6-34.

MESH -> FACE -> MESH FACES

This opens the Mesh Faces form.

Page 235: Gambit Tutorial Guide

a) Select the face marked A in Figure 6-34 in the graphics window. The face to select is the curved face.

GAMBIT will automatically select the Submap Scheme in the Mesh Faces form. See the GAMBIT Modeling Guide for more information on the Submap meshing scheme.

b) Change the Interval size to 3 under Spacing and Click the Apply button

Page 236: Gambit Tutorial Guide

Figure 6-34: Faces to be meshed

The face will be meshed as shown in Figure 6-34.

Figure 6-35: Mesh on face A

Page 237: Gambit Tutorial Guide

1. Mesh the face marked B in Figure 6-34

a) Select the face marked B in Figure 6-34 in the graphics window.

GAMBIT will automatically select the Map Scheme in the Mesh Faces form. See the GAMBIT Modeling Guide for more information on the Map meshing scheme.

b) Enter 1 as the Interval size under Spacing in the Mesh Faces form and click the Apply button at the bottom of the form.

The face will be meshed as shown in Figure 6-35.

Figure 6-36: Mesh on face A and B

2. Mesh the face marked C in Figure 6-34

a) Select the face marked C in Figure 6-34 in the graphics window.

GAMBIT will automatically select a Scheme in the Mesh Faces form. If GAMBIT does not automatically select a Map Scheme, change the Scheme option to Map in order to impose face vertex types that allow a mapped meshing scheme.

b) Retain the default Interval size of 2.5 under Spacing in the Mesh Faces form and click the Apply button at the bottom of the form.

The face will be meshed as shown in Figure 6-37.

Page 238: Gambit Tutorial Guide

Figure 6-37: Mesh on face A-C

3. Mesh the face marked D in Figure 6-34.

a) Select the face marked D in Figure 6-34 in the graphics window.

GAMBIT will automatically select the Map Scheme in the Mesh Faces form.

b) Enter 1 as the Interval size under Spacing in the Mesh Faces form and click the Apply button at the bottom of the form.

The face will be meshed as shown in Figure 6-38.

Page 239: Gambit Tutorial Guide

Figure 6-38: Mesh on face A-D

Step 15: Modify Mesh Settings on Some Faces

"Modifying mesh settings" is the same as "applying without meshing". This step

illustrates two different applications to this technique

First, you will modify the scheme setting on two faces from Pave to Submap. This is one way of making the main volume ready for Cooper meshing

Secondly, you will modify the default size of one of the source faces. In this case, you

allow the Cooper meshing scheme to make sure the mesh is matching with other source faces.

1. Set the meshing scheme to be Submap for the faces marked F and G in Figure 6-39.

Page 240: Gambit Tutorial Guide

a) Select the faces marked F and G in Figure 6-39 in the graphics window.

b) Select Submap from the Scheme option menu.

Figure 6-39: Faces to be modified

c) Retain the default Interval size of 2 under Spacing in the Mesh Faces form.

d) Deselect the Mesh check box under Options.

Page 241: Gambit Tutorial Guide

You deselected the Mesh check box because at this point you do not want to mesh the faces; you only want to apply the Scheme to the faces. GAMBIT will mesh the faces using the Scheme you specified when it creates a volume mesh.

e) Click the Apply button at the bottom of the form.

2. Set the meshing size on the face marked H in Figure 6-40.

a) Select the face marked H in Figure 6-40 in the graphics window (the face at the end of the pipe).

GAMBIT will automatically select the Pave Scheme in the Mesh Faces form. See the GAMBIT Modeling Guide for more information on the Pave meshing scheme.

Figure 6-40: Face to be modified

b) Enter 1 as the Interval size under Spacing in the Mesh Faces form.

c) Check that Mesh is not selected under Options and click the Apply button at the bottom of the form.

Step 16: Mesh the Volumes

1. Mesh the volumes marked J and K in Figure 6-41.

MESH -> VOLUME -> MESH VOLUMES

Page 242: Gambit Tutorial Guide

This opens the Mesh Volumes form.

a) Select the volumes marked J and K in Figure 6-41 in the graphics window.

GAMBIT will automatically select the Cooper Scheme in the Mesh Volumes form. See the GAMBIT Modeling Guide for more information on the Cooper meshing scheme.

b) Enter 4 as the Interval size under Spacing in the Mesh Volumes form and click the Apply button at the bottom of the form.

The volumes will be meshed as shown in Figure 6-42.

Page 243: Gambit Tutorial Guide

Figure 6-41: Volumes to be meshed

Figure 6-42: Mesh on volumes J and K

2. Mesh the volume marked L in Figure 6-41.

a) Select the volume marked L in Figure 6-41 in the graphics window.

GAMBIT will automatically select the Cooper Scheme in the Mesh Volumes form.

Page 244: Gambit Tutorial Guide

b) Check that the Remove lower mesh and Remove old mesh check boxes are not selected at the bottom of the form.

c) Click the Apply button again.

The final volume mesh is shown in Figure 6-43.

Figure 6-43: Final volume mesh

Notice that hidden line removal has been turned on in Figure 6-43 to make the mesh

easier to see. To turn on hidden line removal, hold down the right mouse button on the

RENDER MODEL command button in the Global Control toolpad and select

from the resulting list. To view the mesh without hidden line removal,

select the option.

3. You can view the mesh by shading it using the RENDER MODEL command button in the Global Control toolpad

a) Hold down the right mouse button on the RENDER MODEL command button and

select from the resulting list.

b) Rotate and translate the volume to view the mesh.

Page 245: Gambit Tutorial Guide

c) When you are finished, return to the wireframe view of the model, by selecting the

following command buttons in the Global Control toolpad: R .

Step 17: Examine the Volume Mesh

1. Select the EXAMINE MESH command button at the bottom right of the Global Control toolpad.

This opens the Examine Mesh form.

Page 246: Gambit Tutorial Guide

b) Examine the mesh with cut planes and with the EquiAngle Skew.

Step 18: Set Zone Types and Export the Mesh

1. Set boundary types for the complex pipe junction.

ZONES ->SPECIFY BOUNDARY TYPES

This opens the Specify Boundary Types form.

Page 247: Gambit Tutorial Guide

! It may be useful to remove the mesh from the display before you set the boundary types; it is then easier to see the faces of the geometry. The mesh is not deleted, just removed

from the graphics window. To remove the mesh from the display,

Click the SPECIFY MODEL DISPLAY ATTRIBUTES command button at the bottom

of the Global Control toolpad. Select Off from the option menu to the right of Mesh near the bottom of the form and click Apply.

a) Define an inlet.

i. Enter the name inlet in the Name text entry box.

ii. Select PLOT in the Type option menu.

iii. Check that Face is selected as the Entity.

iv. Shift-left-click the face marked A in Figure 6-44 and accept the selection.

Page 248: Gambit Tutorial Guide

Figure 6-44: Faces to set as inlet, outlet, and wall boundaries

b) Define an outlet.

i. Enter the name outlet in the Name text entry box.

ii. Check that PLOT is still selected in the Type option menu.

iii. Select the face marked B in Figure 6-44 and accept the selection.

c) Define symmetry boundary types for faces on the x-y plane.

i. Enter the name symmetry in the Name text entry box.

ii. Select PLOT in the Type option menu.

iii. Select all the faces on the symmetry plane (marked E, F, G, and H in Figure 6-45). Accept the selection of the faces.

Page 249: Gambit Tutorial Guide

Figure 6-45: Faces on the symmetry plane

Note that you could also specify the remaining external faces of the tank geometry as

WALL boundaries. This is not necessary, however, because when GAMBIT saves a mesh, any external faces (in 3-D) for which you have not specified a boundary type will be

written out as WALL boundaries by default.

In addition, when GAMBIT writes a mesh, any volumes (in 3-D) for which you have not specified a continuum type will be written as FLUID by default. This means that you do not need to specify a continuum type in the Specify Continuum Types form for this tutorial.

2. Export a mesh file.

a) Open the Export Mesh File form

File -> Export -> Mesh…

This opens the Export Mesh File form.

Page 250: Gambit Tutorial Guide

i. Enter the File Name for the file to be exported (Tank.FDNEUT).

ii. Click Accept.

The grid file will be written to your working directory.

3. Save the GAMBIT session and exit GAMBIT

a) Select Exit from the File menu.

File -> Exit.

b) Click Yes to save the current session and exit GAMBIT.

6.5 Summary

In this tutorial multiple primitive creations and Boolean operations was used to create the full geometry. Decomposition was embedded in the creation. Edge meshing, boundary layers and face meshing were used to control the mesh density, and type of mesh, in different areas of the model . The Cooper meshing scheme was used for all volumes.

© Fluent, Inc. 10/27/99

Page 251: Gambit Tutorial Guide

GAMBIT USER'S GUIDE Table of Contents

Chapter Title

1 INTRODUCTION

2 STARTING GAMBIT

3 THE GAMBIT GRAPHICAL USER INTERFACE (GUI)

4 GAMBIT MENU COMMANDS

Appendix A IF BLOCKS AND DO LOOPS

Appendix B CONSTANTS, FUNCTIONS, AND EXPRESSIONS

1. INTRODUCTION

1.1 GAMBIT Documentation Suite

1.2 Format and Font Conventions

1.2.1 Format Conventions

• Graphic Format Layout Format

Page 252: Gambit Tutorial Guide

1.2.2 Fonts

1.3 User's Guide-Outline

2. STARTING GAMBIT

2.1 Startup Command

2.1.1 Overview

2.1.2 Startup Command Options

2.2 GAMBIT File Organization

2.2.1 Session Files

2.2.2 Directory Structure

2.2.3 File Management

3. THE GAMBIT GRAPHICAL USER INTERFACE (GUI)

3.1 GUI Components

3.1.1 Graphics Window

3.1.2 Main Menu Bar

3.1.3 Operation Toolpad

3.1.4 Form Field

3.1.5 Global Control Toolpad

3.1.6 Description Window

3.1.7 Transcript Window and Command Text Box

3.1.8 GUI Sashes

3.1.9 GUI Sash Anchor

3.2 GUI Control Elements

Page 253: Gambit Tutorial Guide

3.2.1 Command Buttons

3.2.2 Option Buttons

3.2.3 Radio Buttons

3.2.4 Check Boxes

3.2.5 Text Boxes

3.2.6 List Boxes

3.2.7 Text Windows

3.2.8 Pick-List Forms

3.2.9 Query-List Forms

3.2.10 Slider Bars

3.3 Using the Mouse

3.3.1 Menus and Forms

3.3.2 Graphics Window

• Display Operations Task Operations Creating Vertices

3.4 Using the Global Control Toolpad

3.4.1 Quadrant Command Buttons

3.4.2 Control Command Buttons

• Fit to Window Select Pivot Select Preset Configuration Modify Lights Annotate Specify Label Type Undo Redo Orient Model Specify Display Attributes

Page 254: Gambit Tutorial Guide

Render Model Specify Color Mode Examine Mesh

4. GAMBIT MENU COMMANDS

4.1 File Commands

4.1.1 New

4.1.2 Open

4.1.3 Save

4.1.4 Save As

4.1.5 Print Graphics

4.1.6 Run Journal

4.1.7 Clean Journal

4.1.8 View File

4.1.9 Import

4.1.10 Export

4.1.11 Exit

4.2 Edit Commands

4.2.1 Title

4.2.2 File

4.2.3 Parameters

4.2.4 Defaults

4.3 Solver Menu

4.4 Help Menu

4.4.1 Quick

Page 255: Gambit Tutorial Guide

4.4.2 Table of Contents

4.4.3 About

APPENDIX A: IF BLOCKS AND DO LOOPS

A.1 Overview

A.2 IF Blocks

A.2.1 General Syntax

A.2.2 Example

A.2.3 Nested IF Blocks

A.3 DO Loops

A.3.1 General Syntax

A.3.2 DO-Loop Operations

A.3.3 Example

A.3.4 BREAK and NEXT Commands

A.3.5 Nested DO Loops

APPENDIX B: CONSTANTS, FUNCTIONS, AND EXPRESSIONS

B.1 Constants

B.2 Functions

B.2.1 Numeric Functions

B.2.2 String Functions

• (=) -- String Assignment (+) -- String Concatenation (CSTRCMP) -- Case-Insensitive String Compare (CSTRNCMP) -- Case-Insensitive Substring Compare (DIRNAME) -- Directory Path/ Directory Path

Page 256: Gambit Tutorial Guide

(DIRPLUSFILE) -- Directory Path and File Name (DIRPLUSSUBDIR) -- Directory and Subdirectory Path (DS) -- Convert UNIX File Name to DOS File Name (FILENAME) -- File Name/ Directory Path (FILEPREFIX) -- Prefix of a File Name (FILESUFFIX) -- Suffix of a File Name (GETCWD) -- Current Working Directory (GETENV) -- Environment Variable (GETIDENT) -- Current GAMBIT Database Identifier (GETSCR) -- Current Scratch Directory (NTOS) -- Numeric-to-String Representation Conversion (STON) -- String-to-Numeric Representation Conversion (STRCMP) -- Case-Sensitive String Compare (STRFMT) -- String Formatting (STRLEN) -- Number of Characters in a String (STRNCMP) -- Case-Sensitive Substring Compare (STRRSTR) -- Offset of Last Substring Within a String (STRSTR) -- Offset of First Substring Within a String (STRTOLC) -- Convert a String to Lower Case (STRTOUC) -- Convert a String to Upper Case (SUBSTR) -- Substring Extraction (US) -- Convert DOS File Name to UNIX File Name

B.3 Expressions

B.3.1 Arithmetic Expressions

B.3.2 Logical Expressions

© Fluent, Inc. 04/24/00

Page 257: Gambit Tutorial Guide

1. INTRODUCTION

GAMBIT is a software package designed to help analysts and designers build and mesh models for computational fluid dynamics (CFD) and other scientific applications. GAMBIT receives user input by means of its graphical user interface (GUI). The GAMBIT GUI makes the basic steps of building, meshing, and assigning zone types to a model simple and intuitive, yet it is versatile enough to accommodate a wide range of modeling applications.

The following sections of this chapter outline the contents of the GAMBIT documentation suite and describe the format and font conventions that are used throughout the GAMBIT documentation.

1.1 GAMBIT Documentation Suite

The GAMBIT documentation suite consists of the following guides.

Title Description

User's Guide Instructions on how to start and run GAMBIT, including a detailed description of the GAMBIT graphical user interface (GUI)

Modeling Guide Basic GAMBIT modeling geometry types. Detailed descriptions of GAMBIT geometry, mesh, zones, and tools commands and operations

Tutorial Guide Tutorial examples that illustrate the use and basic operation of GAMBIT

Command Reference Guide

A compendium of GAMBIT keyboard commands and options

1.2 Format and Font Conventions

1.2.1 Format Conventions

Page 258: Gambit Tutorial Guide

The GAMBIT documentation suite employs two standard format types.

• Graphic format • Layout format

The graphic format defines the types of symbols that are used to represent control elements and command buttons on the GAMBIT graphical user interface (GUI). The layout format defines the structure of the documentation with respect to the description of GAMBIT specification forms.

Graphic Format

The GAMBIT GUI employs two types of components for user interaction.

• Control elements • Toolpad command buttons

Control elements allow you to perform operations such as executing actions and operations, choosing from among a given set of options, and inputting alphanumeric data. Toolpad command buttons allow you to perform operations such as opening specification forms and controlling GUI display characteristics-for example, the overall layout of the graphics window or the orientation of the model.

The following sections describe the appearance and use of the components listed above as well as the graphic format that is used throughout the GAMBIT documentation to represent each type of component.

Control Elements

The GAMBIT GUI control elements are as follows.

Control

Element Example Graphic

Format Description

Command button

Command Executes the command

indicated on the button title

Option button

Option 1 Option 2 ...

Selects from a hidden menu of mutually exclusive options

Text box

Value Accepts alphanumeric data from the keyboard

Page 259: Gambit Tutorial Guide

Form heading

Heading: Indicates the general function of button and selector groups

Radio button

Option Selects from a displayed menu of mutually exclusive options

Check box

Option Toggles on or off a program option

Pick-list box

List Selects items from a pick list form

Scroll lists

List Displays scrollable lists

Slider bar

Parameter -- Specifies parameter values across a continuous range

Toolpad Command Buttons

GAMBIT toolpad command buttons appear on toolpads located on the upper and lower right portions of the GUI. Each toolpad command button contains a graphical symbol that represents the function of the button. For example, the Examine Mesh command button appears as follows:

.

In this guide, all toolpad command buttons are represented as push buttons containing the graphical symbol appropriate to the button.

Layout Format

Throughout this guide, descriptions of specification forms follow a layout format convention wherein paragraphs describing subgroups of control elements are indented

Page 260: Gambit Tutorial Guide

relative to their respective headings or groups. For example, the description of the Import ACIS File form (see Section 4.1.9) appears as shown below.

Using the Import ACIS File Form

To open the Import ACIS File form (see below), select Import ACIS File from the File menu on the main menu bar.

The Import ACIS File form contains the following options.

Format: -------------------------

ASCII specifies an ASCII format.

Binary specifies a binary format.

File Name: specifies the name of the file containing the geometry to be imported.

Browse... opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Note that, in the example form description presented above, the ASCII and Binary radio buttons are indented to indicate that they are subcomponents of the Format heading.

1.2.2 Fonts

The following font conventions are used throughout this guide to represent user input data, the titles of forms and command buttons, and the names of modeling objects such as model entities and coordinate systems.

Page 261: Gambit Tutorial Guide

Font Description Example(s)

Courier User keyboard input such as command line arguments and file names

gambit value

Century Schoolbook,

Italic Command line options filename

vertex

Arial Narrow, helvetica, sans-serif, Bold

Titles of forms, headings, and form fields Model Volume Vertex

Arial Narrow, helvetica, sans-serif

Titles of options and commands Interval size Lower topology

Arial Narrow, helvetica, sans-serif, Italic

Names of GAMBIT topological entities, coordinate systems, and boundary layers

edge.1 vertex.1 c_sys.1 b_layer.1

1.3 User's Guide--Outline

The following table summarizes the content of this guide.

Chapter Title Description

1 Introduction Descriptions of the format and layout conventions employed throughout the GAMBIT documentation suite

2 Starting GAMBIT GAMBIT startup procedure, command line arguments, GAMBIT file structure and session terminology

3 The GAMBIT Graphical User Interface

Descriptions and instructions concerning the structure and use of the GUI graphics window, Operation toolpad and subpads, and Global Control toolpad

4 GAMBIT Menu Commands Descriptions and instructions concerning the use of commands and operations that are available by means of the GAMBIT GUI main menu bar

Page 262: Gambit Tutorial Guide

Appendix A IF Blocks and DO Loops Descriptions of the syntax for IF blocks and DO loops that may be employed in GAMBIT journal files

Appendix B Constants, Functions, and Expressions

Definitions of the constants, functions, and logical expressions that are available for use in defining GAMBIT parameters and in journal files

© Fluent, Inc. 05/05/00

Page 263: Gambit Tutorial Guide

2. STARTING GAMBIT

The purpose of this chapter is to describe the general form of the GAMBIT startup command, including available command options, and to describe the organizational structure of the files that are associated with GAMBIT sessions.

2.1 Startup Command

2.1.1 Overview

To start GAMBIT, you must enter the following command:

gambit [ option1 option2 ...]

where the option arguments represent any of the startup options described in Section 2.1.2, below.

2.1.2 Startup Command Options

The startup command options that are available in GAMBIT are as follows.

Option (Parameters) Description

-def filename Specifies the name (filename) of an initialization file that contains the GAMBIT program default values.

-dev driver Specifies a graphics driver name.

-doc Launches the local web browser and opens the table of contents for GAMBIT online documentation.

-geom width x height +x

+y

Specifies the window size (in pixels).

-help Displays the available startup options.

Page 264: Gambit Tutorial Guide

-id id Specifies an alphanumeric identifier for the GAMBIT

session. (NOTE: If you omit the -id option, GAMBIT

assigns the session the default identifier, default_id.) For a description of the session identifier and its use, see Section 2.2 and Chapter 4 of this guide.

-in filename Specifies the name (filename) of a journal file that is to be run in the batch mode. For a description of the purpose and use of GAMBIT journal files, see Chapter 4 of this guide.

-new | -old Mutually exclusive options that specify whether or not GAMBIT is to open a new or existing session.

• -new specifies that GAMBIT is to open a new session

• -old specifies that GAMBIT is to open an existing session

-res filename Starts GAMBIT in the batch mode. (NOTE: This option is used to restore the journal file from the database file

named filename.dbs.)

Some of the startup command options listed above require the specification of numeric or string parameters such as window dimensions or file names, respectively. The rules that govern GAMBIT startup command syntax require that you do not enclose string parameters in quotation or double-quotation marks. For example, the correct syntax for

starting an existing GAMBIT session named "model1" is as follows:

gambit -id model1 -old .

You can also include a path name in string parameters that refer to file names or

identifiers. For example, if the files associated with the session "model1" in the previous

example are located in a directory named "project1," the correct syntax for the command is as follows:

gambit -id project/model1 -old .

2.2 GAMBIT File Organization

2.2.1 Session Files

Page 265: Gambit Tutorial Guide

When you start GAMBIT, either in the batch mode or in the real-time mode employing the GUI, GAMBIT creates a modeling "session." A GAMBIT modeling session consists of all operations performed in relation to a GAMBIT model. Such operations include but are not limited to the following:

• Import of geometry and mesh information • Creation of geometry • Creation and refinement of a mesh • Assignment of zone types • Creation and modification of coordinate systems and grids • Changing the appearance and orientation of the model as displayed in the graphics

window

GAMBIT keeps track of session operations, as well as the ongoing status of the model, by means of three data files. The names, titles, formats, and contents of the session data files are as follows.

Name Title Format Contents

jou Journal Text A sequential list of geometry, mesh, zone, and tools commands executed during the session

trn Transcript Text A log of messages displayed in the GAMBIT Transcript window during the session

dbs Database Binary A binary database containing geometry, mesh, display, defaults, and journal information associated with the model

In addition to the three data files listed above, GAMBIT creates a "lock" file, named

"id.lok", where id represents the session identifier. The purpose of the lock file is to lock out the process number for the current GAMBIT session so that the data files cannot be accessed and/or modified by any concurrent GAMBIT session.

2.2.2 Directory Structure

GAMBIT employs four types of directories to organize session data files and other files related to GAMBIT operation. The following table describes the type, location, and contents of each of the four directories.

Directory

Type Location Contents

Page 266: Gambit Tutorial Guide

Home User specified Files that are global to all GAMBIT sessions, such as initialization files

Source User specified Permanent files containing information related to a specific category, such as a project. Contents may include project-specific initialization files, journal files, database files, transcript files, macros, and environment variables.

Scratch User specified Copies of files from the source directory, temporary files, the working subdirectory, and

the id.lok file.

Working Subdirectory of the scratch directory (see below)

Temporary session data files--jou, trn, and

dbs.

Home, Source, and Scratch Directories

By default, the location of the source and scratch directories is identical to that from which GAMBIT is launched. You can change the default locations of the home, source, and scratch directories by means of the GAMBIT Edit Defaults form. For a description of the Edit Defaults form and its use, see Chapter 4 of this guide.

Working Directory

The working directory is a subdirectory of the scratch directory. Its name consists of the

identifier "GAMBIT" appended with a process number. For example, if you start GAMBIT

such that the scratch directory is named "users1" and the process number is "12345",

GAMBIT locates the session files--that is, jou, dbs, trn, and lok--in a directory named

users1/GAMBIT.12345 .

2.2.3 File Management

The following sections describe the manner in which GAMBIT manages files when you perform the following operations.

• Open an existing GAMBIT session • Save a current GAMBIT session

Opening an Existing GAMBIT Session

Page 267: Gambit Tutorial Guide

When you open an existing GAMBIT session, GAMBIT copies the existing session data files in the source directory to their corresponding files in the working directory. For example, if the session information is as follows,

• Session identifier--burner71

• Source directory--mymodel

• Process number--1234

GAMBIT copies files in the following manner.

Existing Data File Name Copied File Name

/mymodel/burner71.jou /users1/GAMBIT.1234/jou

/mymodel/burner71.dbs /users1/GAMBIT.1234/dbs

/mymodel/burner71.trn /users1/GAMBIT.1234/trn

Thereafter, if you modify the model during the current GAMBIT session, GAMBIT

modifies the jou, dbs, and trn files but does not alter the original data files from which they were copied until you perform a save operation.

Saving a Current Session

When you save a GAMBIT session, GAMBIT copies the three active data files from the working directory either to the source directory or to another user-specified directory. The three copied files share a common root name-that is, the session identifier. The extension of each copied file corresponds to the name of the data file from which it is copied.

For example, if the save operation information is as follows,

• Session identifier--model1

• Target directory--mymodel

• Process number--6789

GAMBIT copies the active session data in the following manner.

Session File Location/Name Copy File Location/Name

scratchname/GAMBIT.6789/jou mymodel/model1.jou

scratchname/GAMBIT.6789/dbs mymodel/model1.dbs

Page 268: Gambit Tutorial Guide

scratchname/GAMBIT.6789/trn mymodel/model1.trn

© Fluent, Inc. 11/08/99

Page 269: Gambit Tutorial Guide

3. THE GAMBIT GRAPHICAL USER INTERFACE (GUI)

GAMBIT allows you to construct and mesh models by means of its graphical user interface (GUI). The GAMBIT GUI (Figure 3-1) is mouse-driven and user-friendly.

Figure 3-1: GAMBIT graphical user interface (GUI)

The following sections of this chapter describe the appearance and use of the basic GUI components and control elements as well as instructions for using the mouse and the Global Control toolpad.

Page 270: Gambit Tutorial Guide

3.1 GUI Components

The GAMBIT GUI consists of eight components, each of which serves a separate purpose with respect to the creating and meshing of a model. The GUI components are as follows:

• Graphics window • Main menu bar • Operation toolpad • Form field • Global Control toolpad • Description window • Transcript window • Command text box

The following sections describe the features of the components listed above as well as other features of the GUI.

3.1.1 Graphics Window

The graphics window (Figure 3-2) is the region of the GUI in which the model is displayed. It is located in the upper left portion of the GUI and occupies most of the screen in the default layout configuration.

Page 271: Gambit Tutorial Guide

Figure 3-2: Graphics window

The graphics window includes the following subcomponents:

• Quadrants • Sashes • Sash anchor

The following sections describe each of the subcomponents listed above.

Graphics-Window Quadrants

The graphics window consists of four separate quadrants, any one, two, or four of which can be displayed simultaneously. You can customize each quadrant to create a distinct representation of the current model-both with respect to the viewing angle and with respect to the model attributes within the quadrant. It is possible, for example, to display

a wireframe view of a portion of the model in the −x direction in one quadrant while displaying a shaded isometric view of another portion of the model in a separate quadrant. The default graphics-window configuration displays only the upper left

quadrant with a wireframe view of the model oriented in the −z direction.

Each quadrant possesses a set of orientation axes in its lower left corner. The axes indicate the current global orientation of the model as viewed in that quadrant.

Page 272: Gambit Tutorial Guide

Graphics-Window Sashes

The quadrants of the graphics window are separated from each other by means of two graphics-window sashes-one horizontal, the other vertical. The horizontal sash separates the upper and lower quadrants of the graphics window. The vertical sash separates the left and right quadrants.

The graphics-window sashes appear on the GUI as thin, gray lines. In the default configuration, the horizontal and vertical sashes are located at the bottom and right sides, respectively, of the graphics window.

To resize the vertical dimensions of the quadrants, left-click the horizontal graphics-window sash and drag it to a new location within the graphics window. When you release the mouse button, GAMBIT automatically resizes the quadrants according to the final position of the sash. To resize the horizontal dimensions of the quadrants, left-click and drag the vertical graphics-window sash to a new location.

Graphics-Window Sash Anchor

The graphics-window sashes are linked to each other by means of the sash anchor, which appears as a small, gray box located at their point of intersection. The graphics-window sash anchor allows you to resize all four quadrants by means of a single mouse operation. In the default configuration, it is located at the lower right corner of the graphics window.

To resize the quadrants using the sash anchor, left-click the sash anchor and drag it to a new location within the graphics window. When you release the mouse button, GAMBIT automatically resizes the quadrants according to the final position of the sash anchor.

Resizing Quadrants Using Preset Configurations

The graphics-window sashes and sash anchor also allows you to resize the quadrants according to 11 preset configurations. When you select a preset configuration, GAMBIT resizes the quadrants so that the selected quadrants fill the entire graphics window. The preset configurations represent various combinations of the upper and lower, left and right quadrants and also include two user-defined configurations.

To select a preset configuration, right-click the graphics-window sashes or sash anchor to open a menu of preset-configurations, then left-click the desired configuration.

Redefining the User-Defined Preset Configurations

Page 273: Gambit Tutorial Guide

Two of the preset graphics-window configurations are user-definable. The default configuration for both options displays only the upper left quadrant.

To redefine either user-defined configuration, perform the following steps.

Step Location Action Comments

1 Graphics window

Create the graphics-window layout to be used as the user-defined configuration.

You can use either the graphics-window sash anchor or the preset configurations to create the desired layout.

2 Graphics-window sash or sash anchor

Right-click the sash or sash anchor.

Opens the preset-configuration menu

3 Preset-configuration menu

Left-click the arrow at the lower right corner of the menu.

Opens the Set/Clear submenu

4 Set/Clear submenu

Click Set. Opens the user-definition submenu

5 User-definition submenu

Left-click the symbol representing the configuration to be defined (1 or 2).

Defines the specified configuration to represent the layout currently displayed in the graphics window

To reset either user-defined configuration to its default setting, perform the following steps.

Step Location Action Comments

1 Graphics-window sash or sash anchor

Right-click the sash or sash anchor.

Opens the preset-configuration menu

2 Preset-configuration menu

Left-click the arrow at the lower right corner of the menu.

Opens the Set/Clear submenu

3 Set/Clear Click Clear. Opens the user-definition

Page 274: Gambit Tutorial Guide

submenu submenu

4 User-definition submenu

Left-click the symbol representing the configuration to be reset (1 or 2).

Resets the specified configuration to its default settings.

3.1.2 Main Menu Bar

The main menu bar is located at the top of the GUI, directly above the graphics window (see Figure 3-1). It contains the following menu items:

• File • Edit • Solver • Help

Each of the items is associated with its own menu of commands that allow you to perform various GAMBIT operations. To open the menu associated with any item, left-click the item name (for example, File).

The menu commands accessible from the main menu bar allow you to perform the following operations.

Menu Item Operation(s)

File Create, open, and save GAMBIT sessions; print graphics; edit and/or run journal files; clean up journal files; import and export model data; exit the program

Edit Edit session titles; launch a text editor; edit model parameters and program defaults

Solver Specify a computational solver

Help Launch the local web browser and open the GAMBIT online help document

Chapter 4 of this guide presents detailed descriptions of the menu items listed above as well as the menu commands available on each associated menu.

Page 275: Gambit Tutorial Guide

3.1.3 Operation Toolpad

The Operation toolpad (Figure 3-3) is located in the upper right portion of the GUI. It consists of a field of command buttons, each of which performs a specific function associated with the process of creating and meshing a model.

Figure 3-3: Operation toolpad

Within the Operation toolpad, command buttons are grouped according to their hierarchy and purpose in the overall scheme of creating and meshing the model. The topmost group constitutes the main pad. All other command button groups constitute subpads.

Main Pad

The topmost group of command buttons on the Operation toolpad constitutes the main pad (see Figure 3-4).

Figure 3-4: Operation toolpad-main pad

The main pad includes the following command buttons.

Symbol Command Button Purpose(s)

Page 276: Gambit Tutorial Guide

Geometry Create and refine model geometry

Mesh Create and refine the mesh

Zones Specify boundary and continuum zone types

Tools Specify coordinate systems and grids and perform specialized GAMBIT operations

Subpads

When you click a main-pad command button, GAMBIT opens an associated subpad. For example, if you click the Geometry command button on the main pad, GAMBIT opens the Geometry subpad (Figure 3-5).

Figure 3-5: Geometry subpad

Each subpad contains command buttons that perform operations related to the overall purpose of the subpad. For example, the Geometry subpad contains the following command buttons:

• Vertex • Edge • Face • Volume • Group

Each of the subpad command buttons listed above allows you to perform operations related to the creation and refinement of model geometry.

Some of the command buttons located on subpads open related subpads of their own. For example, when you click the Volume command button on the Geometry subpad, GAMBIT opens the Geometry/Volume subpad (Figure 3-6).

Page 277: Gambit Tutorial Guide

Figure 3-6: Geometry/Volume subpad

The Geometry/Volume subpad allows you to perform operations related to creating and working with volume entities. It contains the following command buttons:

• Form Volume • Create Volume • Boolean Operations • Blend Volume • Modify Volume Color/Label • Move/Copy/Align Volumes • Split/Merge Volumes • Heal Real Volume • Summarize/Check/Query Volumes / Total Entities • Delete Volumes

Each command button on the Geometry/Volume subpad is associated with a specification form that allows you to specify parameters related to the function indicated on the button.

3.1.4 Form Field

When you click any subpad command button, GAMBIT opens an associated specification form. Specification forms, such as that shown in Figure 3-7, allow you to specify parameters related to modeling and meshing operations, the assignment of boundary attributes, and the creation and manipulation of GAMBIT coordinate systems and grids. Specification forms can be used, for example, to define the radius of a sphere, designate edges of the model to be aligned, or select a particular meshing option from a list of available procedures.

Page 278: Gambit Tutorial Guide

Figure 3-7: Example GAMBIT specification form

When you open a specification form, it appears in the form field. The form field is located at the right side of the GUI, immediately below the Operation toolpad. After a specification form has been opened, you can move it to any other location on the GUI. To move the form, left-click its title bar and drag it to its new location.

3.1.5 Global Control Toolpad

The Global Control toolpad (Figure 3-8) is located at the lower right corner of the GUI. Its purpose is to allow you to control the layout and operation of the graphics window, specifythe appearance of the model as displayed in any particular quadrant, and undo GAMBIT operations.

Figure 3-8: Global Control toolpad

The Global Control toolpad contains 15 active command buttons. The upper set of five command buttons allows you to enable and disable individual graphics window quadrants. The lower set of command buttons allows you to control the appearance of the

Page 279: Gambit Tutorial Guide

graphics window and/or the model as viewed in any individual quadrant and to undo GAMBIT operations.

Section 3.4 of this guide describes the function and use of each button on the Global Control toolpad.

3.1.6 Description Window

The Description window (Figure 3-9) is located at the bottom of the GUI, immediately to the left of the Global Control toolpad. The purpose of the Description window is to display messages describing the various GUI components, including sashes, fields, windows, and command buttons.

Figure 3-9: Description window

Messages displayed in the Description window describe the component of the GUI coinciding with the current location of the mouse pointer. As you move the mouse pointer across the screen, GAMBIT updates the Description window message to reflect the change in the location of the pointer.

3.1.7 Transcript Window and Command Text Box

The Transcript window is located in the lower left portion of the GUI. The Command text box is located immediately below the Transcript window (see Figure 3-10).

Figure 3-10: Transcript window and Command text box

Page 280: Gambit Tutorial Guide

The purpose of the Transcript window is to display a log of commands executed and messages displayed by GAMBIT during the current modeling session. The Command text box allows you to perform GAMBIT modeling and meshing operations by means of direct keyboard input, rather than by means of mouse operations on the GUI. (NOTE: The Command: descriptor also provides access to a hidden menu that allows you to copy Transcript window commands to the Command text box and to insert pause commands in the current journal file (see below).)

Resizing the Transcript Window

GAMBIT allows you to change the proportions of the Transcript window by means of a resize command button located in the upper right corner of the window. The resize command button contains an upward-pointing arrow on its face.

When you click the resize command button, GAMBIT expands the Transcript window vertically to occupy the entire height of the GUI-including the area ordinarily occupied by the graphics window. To restore the Transcript window to its default size, click the resize button (downward-pointing arrow) again.

NOTE: You can also resize the Transcript window horizontally by dragging the sash located at the right side of the window.

Using the Command Text Box

The Command text box region of the GUI consists of two components:

• Text box • Command: descriptor (located at the left side of the text box)

The text box allows you to execute GAMBIT commands directly without using the GUI forms and command buttons. The Command: descriptor provides access to a hidden menu that allows you to copy commands from the Transcript window to the text box and to insert pause commands in the current journal file.

Executing Commands

To execute a GAMBIT command using the Command text box, perform the following steps:

1. Left- or middle-click in the text box to enable it for user input. 2. Input the command text from the keyboard. 3. Press Enter.

Pasting Commands from the Transcript Window

Page 281: Gambit Tutorial Guide

The Command: descriptor provides access to a hidden menu that allows you to copy any individual command that currently exists in the Transcript window to the Command text box. (NOTE: To access the hidden menu, right-click the Command: descriptor.) This feature provides a convenient means to repeat GAMBIT command-line commands.

To copy a command from the Transcript window to the Command text box:

1. Click on (highlight) the command in the Transcript window. 2. Right-click the Command: descriptor to open the hidden Command menu. 3. Select Paste Highlighted Command from the hidden Command menu.

Inserting Pause Commands to the Current Journal File

To insert a pause command in the current journal file:

1. Right-click the Command: descriptor to open the hidden Command menu. 2. Select Insert Pause in Journal from the hidden Command menu.

3.1.8 GUI Sashes

You can reapportion the overall layout of the GAMBIT GUI by means of the GUI sashes. The GUI sashes are similar in function to graphics-window sashes but reconfigure the entire GUI rather than just the graphics window.

There are two GAMBIT GUI sashes; each is represented as a thin, gray line-one vertical, the other horizontal. The vertical sash runs from the top edge to the bottom edge of the GUI and separates the Operation toolpad, form field, and Global Control toolpad (on the right) from the graphics window and Description window (on the left). The horizontal sash runs from the vertical GUI sash (on the right) to the left edge of the GUI and separates the graphics window (above the sash) from the Transcript window and Description window (below the sash).

To resize portions of the GUI by means of either the horizontal or vertical GUI sash, left-click the sash and drag it to its new location. When you release the mouse button, GAMBIT reapportions the GUI according to the new location of the sash.

3.1.9 GUI Sash Anchor

Page 282: Gambit Tutorial Guide

The GUI sash anchor is located at the intersection of the horizontal and vertical GUI sashes and is represented as a small, gray box. Its purpose is to allow you to reapportion the entire GUI layout by means of a single mouse operation.

Resizing the GUI Using the GUI Sash or Sash Anchor

To resize the GUI using the GUI sash anchor, left- or middle-click the sash anchor and drag it to a new location. When you release the mouse button, GAMBIT automatically resizes each part of the GUI according to the final position of the sash anchor.

Resizing the GUI Using Preset Configurations

You can also resize the parts of the GUI according to four preset GUI configurations. When you select a preset configuration, GAMBIT resizes the GUI components so that the selected configuration fills the entire GUI window. The preset configurations are as follows.

Configuration Description

1 (Default)

Graphics window, Operation toolpad, form field, Global Control toolpad, Description window, and Transcript window

2 Graphics window, Description window, and Transcript window

3 Graphics window, Operation toolpad, form field, and Global Control toolpad

4 Graphics window only

To select a preset GUI configuration, right-click the GUI sashes or sash anchor to open the preset-configuration menu, then left-click the desired configuration.

© Fluent, Inc. 11/08/99

Page 283: Gambit Tutorial Guide

3.2 GUI Control Elements

GAMBIT allows you to control program operation by means of GUI control elements. The following table depicts the GAMBIT GUI control elements.

Control Element Example

Command button

Option button

Radio button

Check box

Text box

List box

Text window

Page 284: Gambit Tutorial Guide

Pick-list form

Query-list form

Slider bar

The following sections describe the purpose and operation of each of the control elements shown above.

3.2.1 Command Buttons

Command buttons allow you to execute program actions. There are two types of command buttons: toolpad and form. The following table shows examples of each type of command button.

Type Example

Toolpad

Page 285: Gambit Tutorial Guide

Form

Toolpad command buttons are located on the Operation toolpad and Global Control toolpad; form command buttons are located on GAMBIT forms (for example, specification forms). To execute the action associated with any command button, left-click the button.

Toolpad Command Buttons

Toolpad command buttons allow you to execute program commands that are related to building, meshing, assigning zone types, or viewing the model and working with the GUI. Some toolpad command buttons cause a direct action to occur; others open specification forms.

Each toolpad command button contains a symbol representing the function of the button. Any button that performs more than one function (multifunction command buttons) contains a small, downward-pointing arrowhead in the lower left corner of the button. For example, the Stitch Faces command button shown above also performs the following functions:

• Sweep Real Face • Revolve Real Faces • Form Real Volume From Wireframe

To execute the command represented by the symbol currently displayed on a multifunction command button, left-click the button. To change the function of a command button, right-click it to open a list of available functions, and left-click the desired function to select it from the list.

Form Command Buttons

Form command buttons allow you to execute actions related to GAMBIT forms. Each button contains only a title (for example, Apply, Reset, or Close). To execute the action indicated by the title of a form command button, left-click the button.

3.2.2 Option Buttons

Option buttons allow you to select from a hidden menu of related, mutually exclusive options. They appear only on specification forms and are distinguished by a small, raised

Page 286: Gambit Tutorial Guide

rectangle on the button face. The title displayed on the face of an option button represents the option currently selected from its hidden menu.

To open the hidden menu of options associated with any option button, left-click or right-click the button. To select an option from the menu, left-click its title in the menu list.

3.2.3 Radio Buttons

Radio buttons allow you to select from among a displayed group of related, mutually exclusive options. They appear as small, round or diamond-shaped buttons located on forms, and they always exist in groups of two or more. The title of each option in a group is shown immediately to the right of its associated radio button.

To select a particular option from a displayed group of mutually exclusive options, left-click its radio button. The selected option is identified by a small, colored dot or diamond in the center of the button.

3.2.4 Check Boxes

Check boxes allow you to specify non-mutually exclusive options for program operations. They are located on forms and can appear alone or in groups of two or more. The title of each option is shown immediately to the right of its check box.

To select a particular check-box option, left-click its check box. When you select a check-box option, the check box turns color and, on some systems, a check mark appears in the box to indicate that the option has been selected.

3.2.5 Text Boxes

Text boxes allow you to input alphanumeric data. They are located on forms and appear as indented rectangles. The title of any text box appears immediately to its left.

The following bullet points summarize the use of GAMBIT text boxes.

• To enter data by means of a text box, left-click in the box to enable it for user input, then input the data from the keyboard.

• To scroll text that overflows the text box, left-click the text and left-drag the mouse past the right or left edge of the box.

Page 287: Gambit Tutorial Guide

• To delete one or more characters in the box, left-click and drag the mouse pointer to highlight the character(s), then press Delete or Backspace, or enter data to replace the character(s) being deleted.

• To highlight all of the text in a text box, double-click the text box.

3.2.6 List Boxes

List boxes allow you to select from lists of items-for example, a list of face entities-that currently exist in the model. Each list box takes the form of a text box with a pick-list button located immediately to the right of the box. The pick-list button is a small, rectangular button with an upward-pointing arrowhead on its face.

When you click the pick-list button, GAMBIT opens the pick-list form associated with the list-box item type. For example, if you click the pick-list button associated with a list box titled Vertices, GAMBIT opens a Vertex List pick-list form. For a general description of pick-list forms and their use, see Section 3.2.8, below.

3.2.7 Text Windows

Text windows appear on forms that contain lines of text-such as parameter lists or text files. When the size of the displayed text exceeds the size of the text window, GAMBIT displays scroll bars on the right side and/or bottom of the text window. To display text that exists beyond the current limits of the text window, either resize the form to resize the window, left-drag the horizontal or vertical scroll bar, or left-click the appropriate scroll arrow located at the end of a scroll bar.

3.2.8 Pick-List Forms

Pick-list forms allow you to select one or more items, such as topological entities, from a list of available items. For example, if you click the Vertices pick-list button on the Create Straight Edge form (see the GAMBIT Modeling Guide, Section 2.3.1), GAMBIT opens a Vertex List pick-list form, such as that shown in Figure 3-11. The Vertex List pick-list form allows you to specify two existing vertices that constitute the endpoints of the edge.

Page 288: Gambit Tutorial Guide

Figure 3-11: Example Vertex List pick-list form

NOTE: You can also specify the vertices by using the mouse to pick them from the graphics window (see "Picking Entities," in Section 3.3.2) or by inputting their labels in the Vertices text box on the Create Straight Edge form.

The following sections describe the basic components of pick-list forms.

Form Components

Each pick-list form includes the following components:

• Title bar • Available scroll list • Picked scroll list • Transfer command buttons

Title Bar

The title bar displays a title that describes the function of the form. The title includes the following subcomponents:

• Item type • Number of items

The item type describes the type of item listed on the form-for example, Vertex List or Face List. The number-of-items subcomponent describes the number of items that are to be picked by means of the form. It always appears on the right side of the title bar and is bracketed by parentheses. There are three number-of-items designations, each of which indicates how many items can be picked from those listed in the Available scroll list on the form.

Page 289: Gambit Tutorial Guide

• Single—indicates that you must pick only one item. • Double—indicates that you must pick two of the items. • Multiple—indicates that you can pick one or more items.

Available Scroll List

The Available scroll list displays all currently existing items of the type associated with the form. (NOTE: If you right-click the Available scroll list, GAMBIT opens a hidden menu of options that allow you to sort, toggle the select state of, or deselect all items in the Available list (see below).)

Picked Scroll List

The Picked scroll list displays all currently picked items of the type associated with the form. (NOTE: If you right-click the Picked scroll list, GAMBIT opens a hidden menu containing a single option that allows you to deselect all items in the Picked list (see below).)

Transfer Command Buttons

The transfer command buttons allow you to transfer individual items to or from the Picked scroll list (see below).

Using a Pick List Form

Pick-list forms, such as that shown in Figure 3-11, above, include the following options and specifications.

Available displays all currently existing object types that are associated with the title of the form.

NOTE: The Available scroll list includes a hidden menu of options that allow you to sort, toggle, and unselect items in the list. To open the hidden menu, right-click anywhere in the Available scroll list.

The hidden-menu options are as follows:

• Sort—sorts list items in alphabetical order. • Toggle all—highlights those items that are not currently highlighted,

and vice versa. • Unselect all—unselects all items in the list.

Picked displays all currently picked object types that are associated with the title of the form.

Page 290: Gambit Tutorial Guide

NOTE: The Picked scroll list includes a hidden menu of options that allow you to toggle and unselect items in the list. To open the hidden menu, right-click anywhere in the Picked scroll list.

The hidden-menu options are as follows:

• Toggle all - highlights those items that are not currently highlighted, and vice versa.

• Unselect all - unselects all items in the list.

--> adds to the Picked scroll list only those items that are currently highlighted in the Available scroll list.. To add one or more items to the Picked scroll list, highlight the item(s) in the Available scroll list and click this command button.

NOTE: If you double-click an item in the Available scroll list, GAMBIT adds the item to the Picked scroll list.

<-- removes from the Picked scroll list only those items that are currently highlighted in the Picked scroll list. To remove one or more items from the Picked scroll list, highlight the item(s) in the Picked scroll list and click this command button.

All > adds to the Picked scroll list all objects that are currently displayed in the Available scroll list.

< All removes all items from the Picked scroll list.

Close closes the pick-list form.

NOTE: GAMBIT allows you to add items to pick lists by means of mouse operations in the graphics window. For a description of the mouse operations that are related to picking items, see "Picking Entities," in Section 3.3.2, below.

3.2.9 Query-List Forms

Query-list forms display a comprehensive list of entities-such as faces or edges-that currently exist in the model. They always appear as individual forms, titled "Query" and displaying the entity type that is associated with the form. Each query-list form includes a scroll list of entity names as well as Reset and Close command buttons.

Page 291: Gambit Tutorial Guide

To select a single entity from a query list, left-click (highlight) the name of the entity in the scroll list. To unselect a highlighted entity, left-click its highlighted name. To unselect all highlighted entities, click Reset.

Figure 3-12: Example Query Vertices query-list form

Using Query-List Forms

To open a query-list form such as that shown in Figure 3-12, above, click the Query toolpad command button on one of the Geometry subpads. For a description of the use of Query forms, see "Query Vertices" in Section 2.2 of the GAMBIT Modeling Guide.

All query-list forms include the following specifications.

Label Names

contains the names of all entities associated with the form that currently exist in the model. Entities highlighted in the Label Names scroll list are also highlighted in the graphics window.

Filter specifies a filter text string.

The Filter specification allows you to identify and highlight subsets of entities. To highlight a subset of entities, input a string value common to all entities in the subset. For example, if you specify the filter string,

"vertex.2" in the Filter text box on the Query Vertices form, GAMBIT highlights vertex.2; vertex.20, vertex.21, . . ., vertex.29; vertex.200, vertex.201, . . ., vertex.299, and so on.

Label specifies that labels corresponding to highlighted entities names are

Page 292: Gambit Tutorial Guide

displayed in the graphics window.

Reset unselects all entities in the query list.

Close closes the query-list form.

3.2.10 Slider Bars

Slider bars allow you to adjust settings in a continuous manner across a specified range of values. They are located on display-related specification forms and on boundary-layer specification forms, and they appear as horizontal bars containing a small, gray rectangle with a vertical line in its center (the slider box).

You can adjust a slider bar setting in the following ways:

• Click the slider box and drag it to its new location (continuous movement) • Click in the area on either side of the slider (incremental movement)

© Fluent, Inc. 11/08/99

Page 293: Gambit Tutorial Guide

3.3 Using the Mouse

The GAMBIT GUI is designed for use with a three-button mouse. The function associated with each mouse button varies according to whether the mouse is operating on menus and forms or in the graphics window. Some graphics-window mouse operations involve keyboard keys in conjunction with the mouse.

3.3.1 Menus and Forms

Mouse operations for GAMBIT menus and forms require only the left and right mouse buttons and do not involve any keyboard key operations.

Left Mouse Button

Most of the mouse operations performed on GAMBIT GUI menus and forms require only the left mouse button. The left mouse button allows you to perform the following form-related operations:

• Open the menu associated with an item on the main menu bar • Select a menu command • Execute the operation indicated on a command button • Select an option from a list of mutually exclusive radio buttons • Open the hidden menu for an option button • Select an option from an option-button menu • Open or close a pick-list form • Enable a text box for entering data • Highlight an item in a list • Relocate (drag) a form on the GUI

Right Mouse Button

The right mouse button allows you to perform the following form-related functions:

• Open a menu of options available by means of a multifunction toolpad command button

• Open a hidden menu of options such as that described in "Using a Pick List Form" in Section 3.2.8, above.

3.3.2 Graphics Window

Page 294: Gambit Tutorial Guide

There are three general types of GAMBIT GUI graphics-window mouse operations:

• Display • Task • Vertex creation

Display operations allow you to directly manipulate the appearance of the model in any of the graphics-window quadrants. Task operations allow you to specify topological entities and to execute geometry and meshing operations. The vertex creation operation allows you to create vertices on any displayed coordinate system grid.

Display Operations

GAMBIT GUI graphics-window display operations employ all three mouse buttons as well as the Shift and Ctrl keyboard keys. The types of display operations are as follows:

• Rotate • Translate • Revolve • Zoom and pan-zoom • Enlarge • Show previous view • Journal view

NOTE (1): The following descriptions of display-window operations are based on the default functionality of the GAMBIT mouse buttons. For example, in the GAMBIT default configuration, GAMBIT rotates the model when you left-drag the mouse across the graphics window (see "Rotating the Model (Left-drag)," below.) Similarly, if you Shift-left-click an entity in the graphics window, GAMBIT adds the entity to the appropriate open pick list (see "Picking Entities," below).

GAMBIT allows you to exchange the functionality of the mouse buttons with respect to the Shift key operations. For example, you can exchange the functions of the left mouse button such that you need only to left-click an entity to add it to a pick list but must Shift-left-drag the mouse to rotate the model.

To exchange the functionality of the mouse buttons with respect to Shift key operations, perform the following steps:

1. Hold down the right mouse button 2. Click the left mouse button once

When you do so, GAMBIT changes the appearance of the cursor to indicate that the functionality of the mouse buttons has been exchanged.

Page 295: Gambit Tutorial Guide

To restore the default functionality of the mouse buttons, repeat the procedure described above. When you do so, GAMBIT restores the default cursor shape to indicate that the mouse functionality has been restored to its default state.

NOTE (2): GAMBIT graphics window mouse operations apply only to "enabled" graphics-window quadrants. For a description of the enabling and disabling of graphics-windows quadrants, see Section 3.4.1, below.

Rotating the Model (Left-drag)

To rotate the model in any quadrant, left-click anywhere in the quadrant and left-drag the cursor either horizontally or vertically in the quadrant. GAMBIT rotates the model around an axis in the plane of the screen and perpendicular to the direction of mouse movement.

Translate the Model (Middle-drag)

To translate the model across the screen in any quadrant, middle-click anywhere in the quadrant and middle-drag the cursor either horizontally or vertically in the quadrant.

Revolve/Zoom the Model (Right-drag)

The right mouse button performs two different types of display operations in the graphics window, each of which corresponds to a different direction of mouse movement:

• Revolve (horizontal movement) • Zoom (vertical movement)

When you right-click anywhere in a quadrant and right-drag the mouse horizontally, GAMBIT revolves the model around a central axis normal to the plane of the screen. When you right-drag the mouse vertically, GAMBIT zooms in or out on the model.

Enlarging the Model

GAMBIT allows you to enlarge any portion of the model display by means of the control (Ctrl) keyboard key and either the left or middle mouse buttons. The Ctrl-left and Ctrl-middle mouse button functions differ with respect to whether GAMBIT retains or ignores the proportions of the model when the model display is enlarged.

Retaining Model Proportions (Ctrl-left-drag)

When you enlarge the model display by means of the Ctrl-left mouse button, GAMBIT enlarges a region of the modeling space the size of which is directly proportional to the quadrant in which the model display is enlarged. Consequently, the enlarged display retains the correct proportions with respect to model dimensions.

Page 296: Gambit Tutorial Guide

When you Ctrl-left-drag the mouse in a quadrant of the graphics window, GAMBIT displays two rectangles that bound the region to be enlarged. The rectangles differ from each other as follows.

• The outer (dashed) rectangle represents the total region that is included when the display is enlarged. Its dimensions are directly proportional to those of the quadrant in which it exists.

• The inner (solid) rectangle shows the region over which the mouse has been dragged.

When you release the mouse button, GAMBIT enlarges the display.

Ignoring Model Proportions (Ctrl-middle-drag)

When you enlarge the model display by means of the Ctrl-middle mouse button, GAMBIT ignores the proportions of the graphics-window quadrant in which it enlarges the display. Consequently, the dimensions of the model in the enlarged display do not necessarily reflect the actual dimensions of the model.

When you Ctrl-middle-drag the mouse in a quadrant of the graphics window, GAMBIT displays a single solid rectangle that represents the region to be enlarged. When you release the mouse button, GAMBIT enlarges the model display such that the horizontal and vertical dimensions of the rectangle fill the entire width and height, respectively, of the quadrant in which the model display is enlarged. If the dimensions of the rectangle are not directly proportional to those of the quadrant, the enlarged model appears to be stretched in either the horizontal or vertical directions.

Show Previous View (Double-middle-click)

When you double-click the graphics window using the middle mouse button, GAMBIT displays the model as shown immediately previous to the current view. For example, if you display a model in an isometric view, then rotate the model to view one side, you can return to the isometric view by double-middle-clicking the mouse anywhere in the graphics window.

Journal View (Double-right-click)

When you double-click the graphics window using the right mouse button, GAMBIT writes the command associated with the currently displayed view of the model to the active journal file.

Task Operations

GAMBIT graphics window task operations employ all three mouse buttons in conjunction with the Shift key to allow you to specify entities and to execute actions related to GAMBIT forms. There are two types of task operations:

Page 297: Gambit Tutorial Guide

• Picking entities • Executing actions

Picking Entities

Many GAMBIT modeling and meshing operations require you to specify one or more entities to which the operation applies. There are two ways to specify an entity for a GAMBIT operation:

• Input the entity name in the appropriate list box on the specification form or select by means of the appropriate pick-list form.

• Use the mouse to "pick" the entity from the model as displayed in the graphics window

When you use the mouse to pick an entity from the model as displayed in the graphics window, GAMBIT includes the entity name in the currently active pick list as if you had specified its name on the currently open specification form.

There are two different types of GAMBIT entity picking operations, each of which involves the Shift key. The two entity picking operations are as follows.

Operation Description

Shift-left-click Highlights the entity in the graphics window and includes the entity in the currently active pick list

Shift-middle-click

Performs the following functions:

• Removes currently highlighted items from the pick list • Picks any unpicked entities in a manner identical to that of the

Shift-left-click operation

As an example of the Shift-middle-click operation, consider the procedure required to pick one of the three faces shown in Figure 3-13 for a face-related geometry operation. All three faces share a common edge, labeled edge.1.

Page 298: Gambit Tutorial Guide

Figure 3-13: Three faces with adjoining edge

If you Shift-middle-click on edge.1, GAMBIT highlights face.1 and adds its label to the current pick list. If you Shift-middle-click a second time on edge.1, GAMBIT removes face.1 from the pick list and replaces it with face.2. If you Shift-middle-click a third time on edge.1, GAMBIT removes face.2 from the face pick list and replaces it with face.3. Finally, if you Shift-middle-click a fourth time on edge.1, GAMBIT removes face.3 from the pick list and replaces it with face.1.

NOTE: To pick any face or volume in a given model, you must pick an edge that is associated with the face or volume. The type of entity picked depends on the currently active list box. For example, if you open the Mesh Faces form and activate the Faces list box, then pick an edge that constitutes a boundary of a face, GAMBIT adds the face to the list of specified faces. Similarly, if you open the Delete Volumes form and activate the Volumes list box, then pick an edge that constitutes part of a volume, GAMBIT adds the volume to the list of specified volumes.

Executing Actions

When you Shift-right-click the mouse in the graphics window, GAMBIT executes the operation associated with the currently open form or skips to next available list box or text box on the form. If all of the form specifications are complete, the Shift-right-click operation is equivalent to the act of clicking Apply on the bottom of the form. For example, if you open the Create Real Sphere form, input a positive value in the Radius text box and Shift-right-click in the graphics window, GAMBIT creates a sphere with the specified radius.

Creating Vertices

Page 299: Gambit Tutorial Guide

GAMBIT allows you to create vertices by means of the Ctrl-right mouse button. The Ctrl-right-click method of creating vertices applies in any graphics window quadrant that contains an active "grid." For a description of the procedures and specifications required to display a grid, see Section 5.1.2 of the GAMBIT Modeling Guide.

To create a vertex by means of the mouse, Ctrl-right-click the point at which the vertex is to be created. The geometric location of the vertex depends on whether you do or do not select the Snap option when you activate the grid display.

• If you select the Snap option, GAMBIT locates the vertex at the grid point that is nearest to the point of intersection between the plane and the screen normal vector described above.

• If you do not select the Snap option, GAMBIT locates the vertex at the point of intersection between the grid plane and a vector that is perpendicular to the screen and passes through the point at which you click the quadrant.

© Fluent, Inc. 11/08/99

Page 300: Gambit Tutorial Guide

3.4 Using the Global Control Toolpad

The Global Control toolpad (Figure 3-8 and below) allows you to control the layout and operation of the graphics window as well as the appearance of the model as displayed in any individual quadrant. In addition, the Global Control toolpad includes an Undo/Redo button that undoes the most recently executed GAMBIT operation or re-executes the most recently undone operation.

The Global Control toolpad contains two types of command buttons:

• Quadrant • Control

Global Control toolpad

The quadrant command buttons allow you to specify whether or not any or all of the quadrants are enabled or disabled with respect to changes in their appearance. The control command buttons allow you to perform the following operations:

• Change the overall layout of the graphics window • Alter the appearance of the model in any individual quadrant • Undo or redo GAMBIT operations

The following sections describe the operation and use of both types of command buttons.

3.4.1 Quadrant Command Buttons

Page 301: Gambit Tutorial Guide

Quadrant command buttons allow you to enable and disable any or all of the graphics-window quadrants with respect to changes in the model appearance. From left to right on the Global Control toolpad, the quadrant command buttons correspond to the following quadrants:

• Upper left • Upper right • Lower left • Lower right • All four quadrants (enable only)

Each quadrant command button toggles its corresponding quadrant between the enabled and disabled states. Enabled quadrants are displayed in red on their corresponding command buttons. Disabled quadrants are displayed in gray.

To enable a disabled quadrant or disable an enabled quadrant, click the corresponding quadrant command button. To enable all quadrants, click All.

3.4.2 Control Command Buttons

Control command buttons allow you to specify the appearance of the graphics window itself and of the model as viewed in any individual quadrant. In addition, the Undo/Redo control command button undoes the most recently executed GAMBIT operation or re-executes the most recently undone operation. The Global Control toolpad contains the following control command buttons.

Symbol Command Description

Fit to Window Scales the graphics display to fit within the boundaries of the enabled quadrants

Select Pivot Specifies the location of the pivot point for model movement by means of the mouse

Select Preset Configuration

Arranges the graphics window to reflect one of six preset configurations

Page 302: Gambit Tutorial Guide

Modify Lights

Annotate

Specify Label Type

Specifies the direction and magnitude of light on the model Allows you to add arrows, lines, and text to the graphics display

Specifies the types of labels displayed by means of the Specify Display Attributes form

Undo

Redo

Undoes the most recently executed GAMBIT operation Redoes the most recently undone GAMBIT operation

Orient Model Applies a preset model orientation to all active quadrants, orients the model with respect to a specified face or vector, and stores commands related to the current orientation in a journal file

Specify Display Attributes

Allows you to specify the characteristics of the graphics display

Render Model Specifies whether the model is displayed in a wireframe, shaded, or hidden perspective

Specify Color Mode Specifies whether model colors are based on entity types or on connectivity

Examine Mesh Allows you to interactively view an existing mesh.

The following sections describe the function and use of the command buttons listed above.

Page 303: Gambit Tutorial Guide

Fit to Window

The Fit to Window command button scales the graphics display to fit in each of the enabled quadrants.

Select Pivot

The Select Pivot command button allows you to change the pivot point around which the model turns when you rotate and/or revolve it using the left and right mouse buttons (see "Rotating the Model (Left-drag)" and "Revolve/Zoom the Model (Right-drag)," above).

GAMBIT allows you to specify either of two points about which to pivot the model.

Symbol Pivot Point

Center of viewing volume (default)

User-specified point

To define a user-specified pivot point, click the Select Pivot command button to display the user-specified point symbol, then left-click at the selection point in the graphics window to identify the new pivot point location. GAMBIT locates the pivot point according to the following hierarchy of rules:

1. If the selection point intersects one or more coordinate systems, GAMBIT locates the pivot point at the coordinate system closest to the viewer.

2. If the selection point intersects one or more vertices, GAMBIT locates the pivot at the vertex closest to the viewer.

3. If the selection point intersects one or more edges, GAMBIT locates the pivot in reference to the selection point and the nearest edge. GAMBIT uses either the

Page 304: Gambit Tutorial Guide

point of intersection as the anchor point or the tangent to the edge at that point as an axis of rotation.

4. If the selection point intersects one or more faces, GAMBIT locates the pivot at the point of intersection with the closest face.

5. If the selection point does not intersect any model components, GAMBIT sets the center of the viewing volume as the pivot point.

To restore the pivot point to its default (quadrant centroid) location, click Select Pivot command button to display the quadrant centroid symbol.

Select Preset Configuration

The Select Preset Configuration command button allows you to modify the overall configuration of the graphics window and the orientation of the model as displayed in the enabled quadrants.

To open the menu of preset configuration options, right-click the Select Preset Configuration button. The preset configuration options include the following configurations and orientations.

Option Description

Displays all four quadrants and applies the following orientations to the currently enabled quadrants.

Displays all four quadrants and applies an isometric view in each currently enabled quadrant.

Expands the upper left quadrant to fill the graphics window.

Page 305: Gambit Tutorial Guide

Expands the upper right quadrant to fill the graphics window.

Expands the lower left quadrant to fill the graphics window.

Expands the lower right quadrant to fill the graphics window.

Modify Lights

When you click the Modify Lights command button, GAMBIT opens the Modify Lights form. The Modify Lights form allows you to customize the appearance of model shading.

Using the Modify Lights Form

The Modify Lights form (see below) allows you to specify the direction and brightness of eight different light sources used to determine model shading. Each light source is represented on the Modify Lights form by one of eight colors: white, cyan, magenta, blue, yellow, green, red, and black.

Page 306: Gambit Tutorial Guide

The Modify Lights form consists of the following components:

• Status buttons • Orientation globe

Status Buttons

The Modify Lights form contains eight sets of status buttons corresponding to each of the eight light sources. Each set of status buttons includes the following buttons:

• Light command button • Ambient and Distant radio buttons

Each Light command button toggles the state of its associated light source between the active (On) and inactive (Off) states. The Ambient and Distant radio buttons constitute mutually exclusive selectors that allow you to specify whether a specific light source is located close to (Ambient) or distant from (Distant) the model.

Orientation Globe

The Modify Lights orientation globe consists of a wireframe sphere upon which are located eight colored circles-each of which is displayed as either solid or hollow. Each circle represents one of the eight light sources. Solid circles represent light sources that are currently specified as On; hollow circles represent light sources that are currently specified as Off.

Page 307: Gambit Tutorial Guide

To reposition any of the eight light sources relative to the model (center of globe) left-click its corresponding circle on the orientation globe and left-drag the circle to the new location. To drag the light source to the side of the globe farthest from the viewer, drag it to the edge of the globe, then back toward the middle. The light source is located on the far side of the globe when it is located on the dashed portion of a circumferential line.

NOTE: If you reposition lights that are Ambient or Off, GAMBIT does not change model shading.

Annotate

When you click the Annotate command button, GAMBIT opens the Annotate form. The Annotate form allows you to add annotation objects such as arrows, lines, or text to any individual graphics window quadrant and to modify or delete such objects.

GAMBIT allows you to perform the following operations with respect to annotation objects.

Operation Description

Add Creates a new object in the graphics window

Modify Modifies an existing object

Delete Deletes an existing object

Delete all Deletes all existing objects

Adding an Annotation Object

GAMBIT allows you to add the following types of annotation objects:

• Arrow--a straight line or series of connected line segments with a single arrowhead at one end

• Line --a straight line or series of connected line segments without an arrowhead at either end

• Text --alphanumeric text that can be placed anywhere in the graphics window • Title --alphanumeric text that constitutes a title for the model

Page 308: Gambit Tutorial Guide

When you Add an annotation object to a graphics window quadrant, GAMBIT creates the object and fixes its position and orientation at an anchor point relative to the quadrant itself. Annotation objects do not move when you translate, rotate, or zoom in or out on the model. To specify the anchor point, left-click the graphics window at the anchor point.

If you resize a quadrant that contains annotation objects, GAMBIT maintains the positions of the object anchor points relative to the original proportions of the quadrant. However, GAMBIT does not alter Text or Title characters when you resize a quadrant, therefore, the characters retain their original size.

Arrow Object

To add an Arrow annotation object, perform the following steps:

Step Description

1 Select the Add radio button on the Annotate form.

2 Select the Object:Arrow option.

3 Specify the object Color and Width.

4 Shift-left-click the graphics window at the point at which the tail of the arrow is to be located, and release the mouse button.

5 Shift-left-click again in the graphics window, and Shift-left-drag the mouse pointer to the point at which the head of the arrow is to be located.

6 Click Apply on the Annotate form (or Shift-right-click in the graphics window).

NOTE: To create an arrow consisting of more than one line segment, repeat Step 5 for each endpoint of each intermediate segment. When you Shift-right-click to Apply the arrow annotation object, GAMBIT creates an arrow defined by the series of line segments and possessing a single arrowhead located at the last point selection point.

Line Object

To add a Line annotation object, follow the general directions outlined above with respect to adding an Arrow object but select the Object:Line in lieu of the Object:Arrow option in Step 2. The Line and Arrow annotation objects differ only in that the Line object does not include an arrowhead.

Text Object

Page 309: Gambit Tutorial Guide

To add a Text annotation object, perform the following steps:

Step Description

1 Select the Add radio button on the Annotate form.

2 Select the Object:Text option.

3 Specify the object Color and Size, and input the alphanumeric Text associated with the object.

4 Shift-left-click in the graphics window, and drag the text to its final location.

5 Click Apply on the Annotate form (or Shift-right-click in the graphics window).

Title Object

To add a Title annotation object, perform the following steps:

Step Description

1 Select the Add radio button on the Annotate form.

2 Select the Object:Title option.

3 Specify the object Color and Size, and input the alphanumeric Text associated with the object.

4 Click Apply on the Annotate form (or Shift-right-click in the graphics window).

Modifying an Annotation Object

To modify an annotation object, perform the following steps:

Step Description

1 Select the Modify radio button on the Annotate form.

2 Pick the object to be modified. (NOTE: To unpick a picked object, Shift-middle-click on the object.)

3 Specify the modifications by means of the Object and Properties fields on the

Page 310: Gambit Tutorial Guide

Annotate form. (NOTE: To change the position of an object within its quadrant, Shift-left-drag or Shift-middle-drag the object to its new location.)

4 Click Apply on the Annotate form (or Shift-right-click in the graphics window).

Deleting an Annotation Object

To delete an annotation object, perform the following steps:

Step Description

1 Select the Delete radio button on the Annotate form.

2 Shift-left-click the object to be deleted.

3 Click Apply on the Annotate form (or Shift-right-click in the graphics window).

Deleting All Existing Annotation Objects

To delete all existing annotation objects, perform the following steps:

Step Description

1 Select the Delete all radio button on the Annotate form.

2 Click Apply on the Annotate form (or Shift-right-click in the graphics window).

Using the Annotate Form

The Annotate form (see below) allows you to add, modify, or delete annotations to the graphics display. To open the Annotate form, click the Annotate command button on the Global Control toolpad.

Page 311: Gambit Tutorial Guide

The Annotate form includes the following options and specifications.

Operation: -------------------------

Add specifies the addition of an annotation object.

Modify specifies the modification of an existing annotation object.

Delete specifies the deletion of an existing annotation object.

Delete all deletes all existing annotation objects.

Object: (active for Add and Modify options only)

Arrow Line Text Title

specifies the type of annotation to be added or modified.

Properties: -------------------------

Color: specifies the color of the annotation.

When you click the Color bar (located immediately to the right of the Color: heading), GAMBIT opens the Set Color form, which allows you to specify the annotation color. For instructions concerning the use of the Set Color form, see "Using the Set Color Form," below.

Width: (Arrow and Line options only) specifies the thickness of the Arrow or Line annotation object.

Page 312: Gambit Tutorial Guide

Text: (Text and Title annotations only) specifies the wording of the annotation.

Using the Set Color Form

The Set Color form allows you to specify the color of an annotation object. To open the Set Color form (see below), click the Color bar on the Annotate form.

The Set Color form includes the following specifications.

Color name specifies the color by name.

Colors: allows you to select a color from a list of available colors.

To select a color, left-click the color in the scroll list. GAMBIT displays the currently selected color on a color band located immediately above the Colors scroll list.

NOTE: You must click Apply to apply the color specification and close the form.

Specify Label Type

Page 313: Gambit Tutorial Guide

When you click the Specify Label Type command button, GAMBIT opens the Specify Label Type form. The Specify Label Type form allows you to specify the kinds of labels that are displayed when you display labels by means of the Specify Display Attributes form (see "Specify Display Attributes," below).

GAMBIT allows you to specify the display of any or all of the following types of labels.

Label Type Description Example

Regular Entity face.3

Interval Edge mesh intervals int = 15

Boundary Type Boundary-type zone specifications

btype = WALL

Scheme Meshing scheme scheme = pave

Boundary Layer Boundary layers b_layer = b_layer.5

Continuum Type Continuum-type zone specifications

ctype = FLUID

To display a label, you must specify the label type, by means of the Specify Label Type form, and activate labels for the entity (or entities) of interest, by means of the Specify Display Attributes form. For example, to display the numbers of mesh intervals for all edges in the model, you must select the Interval options on the Specify Label Type form, then activate labels for all edges by means of the Specify Display Attributes form.

NOTE (1): If the Label option on the Specify Display Attributes form is On, changes made on the Specify Label Type form affect the model display as soon as they are specified.

NOTE (2): The Specify Label Type form specifications do not affect coordinate system labels.

Using the Specify Label Type Form

The Specify Label Type form (see below) allows you to specify the types of labels that are displayed by means of the Specify Display Attributes form. To open the Specify Label Type form, click the Label Type command button on the Global Control toolpad.

Page 314: Gambit Tutorial Guide

The Specify Label Type form consists of a field of five check boxes that allow you to specify the display of the following label types (see above):

• Regular • Interval • Boundary Type • Scheme • Boundary Layer • Continuum Type

Undo

The Undo command undoes GAMBIT operations in reverse order relative to their sequence of execution.

Overview

When you click the Undo command button, GAMBIT reverses the most recently executed operation. For example, if you create a vertex and click Undo, GAMBIT deletes the vertex.

Multiple Undo Operations

As you create and/or mesh a model, GAMBIT maintains and updates an "undo" list-that is, a first-in/last-out sequential list of Geometry, Mesh, Zones, Tools and Global Control commands performed during the modeling session. When you execute the Undo command, GAMBIT reverses the most recently executed operation and removes it from the undo list. If you execute the Undo command a second time, GAMBIT reverses and removes from the undo list the operation that you performed immediately prior to the most recently executed operation-and so on. For example, if you create and mesh a

Page 315: Gambit Tutorial Guide

cylindrical volume, then click Undo, GAMBIT removes the mesh from the volume. If you click Undo a second time, GAMBIT deletes the volume.

By default, GAMBIT maintains 10 undo levels--that is, the undo list contains the 10 most recently executed operations. To increase or decrease the number of operations retained

in the undo list, modify the GAMBIT UNDO default variable by means of the Edit Defaults form (see Section 4.2.4).

NOTE: Increasing the number of undo levels necessarily increases the amount of disk space required by the GAMBIT program.

Redo

The Redo command reverses the most recently executed GAMBIT Undo operation.

Overview

When you click the Redo command button, GAMBIT reverses the most recently executed Undo operation. For example, if you create a vertex and click Undo, GAMBIT deletes the vertex. If you then click Redo, GAMBIT restores the vertex to the model.

Multiple Redo Operations

GAMBIT allows you to Redo multiple-operation sequences that are undone by means of the Undo operation. For example, if you create and mesh a cylindrical volume, then click Undo, GAMBIT removes the mesh from the volume. If you click Undo a second time, GAMBIT deletes the volume. If you then click Redo, GAMBIT restores the volume, and if you click Redo a second time, GAMBIT restores the mesh.

By default, GAMBIT allows you to undo the 10 most recently executed operations and to Redo the 10 most recently executed Undo operations. To increase or decrease the number

of operations that can be undone and/or redone, modify the GAMBIT UNDO default variable by means of the Edit Defaults form (see Section 4.2.4).

NOTE: Increasing the number of undo levels necessarily increases the amount of disk space required by the GAMBIT program.

Orient Model

Page 316: Gambit Tutorial Guide

The Orient Model command button allows you to apply a preset model orientation to all currently enabled quadrants, to orient the model with respect to a specified face or vector, and to store commands related to the current orientation in a journal file.

To open the menu of Orient Model options, right-click the Orient Model command button. The Orient Model menu includes the following options.

Option Description

Displays the model as viewed in the −x direction.

Displays the model as viewed in the +x direction.

Displays the model as viewed in the −y direction.

Displays the model as viewed in the +y direction.

Displays the model as viewed in the −z direction.

Displays the model as viewed in the +z direction.

Displays an isometric view of the model.

Reverses the orientation of the model as currently displayed in each quadrant.

Page 317: Gambit Tutorial Guide

View Face/Vector option--orients the model in a direction either normal to an existing face or defined by a vector (see "Using the View Face/Vector Form," below).

Displays the model according to its previous orientation and configuration. (NOTE: This operation is identical to the double-middle-click in the graphics window (see "Show Previous View (Double-middle-click)," above).

Saves the commands corresponding to the current model orientation and configuration to the session journal text file. (NOTE: This operation is identical to the double-right-click in the graphics window (see "Journal View (Double-right-click)," above).

Using the View Face/Vector Form

The View Face/Vector option allows you to view the model from a direction normal to any one of the model faces or in relation to a specified vector. When you select the View Face/Vector on the Orient Model menu, GAMBIT opens the View Face/Vector form (see below). The View Face/Vector form allows you to specify the face toward which or vector along which the model is to be viewed.

The View Face/Vector form includes the following options:

(quadrant command buttons) enable or disable any or all quadrants with respect to changes in model appearance.

Orientation:

Normal to Face Along Vector

allows you to specify one of two options for orienting the model.

• Normal to Face orients the model normal to a selected face • Along Vector orients the model in the direction of a

Page 318: Gambit Tutorial Guide

specified vector

The following sections describe each of the options.

Normal to Face Option

The Normal to Face option allows you to orient the model in the direction normal to a specified face. For instructions in specifying the face that defines the view direction, see "List Boxes," above. (NOTE: When you specify the Normal to Face option, GAMBIT scales the model to fit in the enabled quadrants when it reorients the model.)

Along Vector Option

The Along Vector option allows you to view the model in the direction of a specified vector. GAMBIT orients the model so that the specified vector is normal to the plane of the screen.

When you select the Along Vector option, GAMBIT displays a Define command button immediately below the Along Vector button. To specify the vector in the direction of which the model is to be viewed, click the Define command button to open the Vector Definition form. (See "Using the Vector Definition Form," below.)

Using the Vector Definition Form

When you select the Along Vector option on the View Face/Vector form and click the Define command button, GAMBIT opens the Vector Definition form (see below). The Vector Definition form allows you to specify the vector along which the model is to be viewed. (NOTE: The Vector Definition form is also used to define vectors, such as axes of revolution, for GAMBIT geometry operations (see Chapter 2 of the GAMBIT Modeling Guide).)

Page 319: Gambit Tutorial Guide

The Vector Definition form includes the following specifications.

Active Coordinate System Vector

displays the coordinates of the Start and End points for the current vector definition.

Method: contains four radio buttons that allow you to select the method used in specifying the vector. The available methods are as follows:

• Coord. Sys. Axis -- specifies a vector defined by one of the coordinate axes

• Edge -- specifies a vector defined by the endpoints of an existing edge

• 2 Vertices -- specifies a vector defined by two existing vertices • 2 Points -- specifies a vector defined by two points

The options and specifications available in the lower part of the Vector Definition form vary according to the Method option selected. The following sections describe specifications associated with each of the four options listed above.

Page 320: Gambit Tutorial Guide

Specifying a Vector Parallel to Coordinate System Axes

Coord. Sys. Axis specifies viewing the model along a vector defined by one of the coordinate axes. When you select the Coord. Sys. Axis option, the lower portion of the Vector Definition form appears as shown above. It includes the following specifications.

Coordinate Sys. specifies the coordinate system of reference for the vector along which the model is to be viewed.

Immediately below the Coordinate Sys. list box is a group of radio buttons that allow you to specify the orientation of the model and perspective of the viewer relative to the coordinate axes. The six orientation options are as follows:

• Positive X, Negative X • Positive Y, Negative Y • Positive Z, Negative Z

For example, if you specify c_sys.1 in the Coordinate Sys. list box and select the Positive Y orientation option, GAMBIT displays the model as viewed in the positive direction along the y axis of c_sys.1.

Specifying a Vector Parallel to a Model Edge

Edge specifies viewing the model along a vector defined by the Start and End endpoints of an existing edge. When you select the Edge option, the lower portion of the Vector Definition form appears as shown below. It includes the following specifications.

Vector Definition form -- Edge option specifications

Edge specifies the edge parallel to which the model is to be viewed.

Reverse reverses the model orientation relative to the edge sense. (NOTE: You can

Page 321: Gambit Tutorial Guide

also reverse the view by middle-clicking on the edge.)

Specifying a Vector Parallel to a Line Passing Through Two Vertices

Vertices specifies viewing the model along a vector defined by two existing vertices. When you select the 2 Vertices option, the lower portion of the Vector Definition form appears as shown below. It includes the following specifications.

Vector Definition form -- 2 Vertices option specifications

Vertices: contains two text boxes that allow you to specify the Start and End vertices that define the vector along which the model is to be viewed. To reverse the orientation of the model, switch the Start and End vertex specifications.

Specifying a Vector Between Two Points

2 Points specifies viewing the model along a vector defined by two points. When you select the 2 Points option, the lower portion of the Vector Definition form appears as shown below. It includes the following specifications.

Page 322: Gambit Tutorial Guide

Vector Definition form -- 2 Points option specifications

Coordinate Values:

contains two radio buttons that allow you to select the point associated with the values currently displayed in the lower part of the form. The options are as follows:

• Point 1 -- specifies the start point • Point 2 -- specifies the end point

To reverse the model orientation, switch the specifications for the two points.

Coordinate Sys

specifies the coordinate system of reference for the points that define the vector along which the model is to be viewed.

Type -----------------------

Cartesian Cylindrical Spherical

specifies the type of coordinate system to be used in the current point specification.

Global | Local allows you to define the coordinates of the point with respect to either the global or local coordinate system. The nature of the text boxes that appear under each heading depends on the type of coordinate system selected by means of the Type option (see above). To define the coordinates of the point currently specified, input its coordinate values in either the Global or the Local text boxes. When you input a values in either set of text boxes, computes and displays the corresponding values for the other set.

Page 323: Gambit Tutorial Guide

Specify Display Attributes

When you click the Specify Display Attributes command button, GAMBIT opens the Specify Display Attributes form (see below). The Specify Display Attributes form allows you to customize the appearance of the model in any currently enabled quadrant.

Using the Specify Display Attributes Form

The Specify Display Attributes form allows you to customize the appearance of the model in any or all of the graphics windows quadrants. It includes the following options.

(quadrant command buttons) enable or disable any or all quadrants with respect to changes in model appearance.

The middle section of the Specify Display Attributes form allows you to select individual model entities or entire entity types for display specification. The available entity-type options include groups (Groups), volumes (Volumes), faces (Faces), edges (Edges), vertices (Vertices), boundary layers (B. Layers), and coordinate systems (C. Sys).

Page 324: Gambit Tutorial Guide

Specifying Display Attributes--Groups Example

The options available for each entity type are identical to those for model groups—which are as follows.

Groups applies the specified display attributes to any or all groups in the model.

All Pick

allows you to select the model groups to which the specified display attributes apply.

• All specifies all groups in the model • Pick specifies groups selected by means of the Group list box (see

below). (NOTE: If you pick a group in the graphics window or click in the Group list box, GAMBIT automatically selects the Pick option.)

Groups allows you to select specific groups to which to apply the display attributes.

Visible specifies the visibility of the selected groups.

On Off

renders the selected groups visible (On) or invisible (Off).

Label specifies the visibility of labels for the selected groups.

On Off

renders labels for the selected groups visible (On) or invisible (Off). To select the types of labels to be displayed, use the Specify Label Type command on the Global Control toolpad.

Silhouette specifies the visibility of silhouettes for the selected groups.

On Off

renders silhouettes for the selected groups visible (On) or invisible (Off). Silhouettes display outlines of surfaces that do not possess edges-for example, the curved surfaces of cylinders and spheres.

Mesh specifies the visibility of the mesh.

On Off

renders the mesh visible (On) or invisible (Off).

Render specifies the general appearance of the selected visible groups.

Wire allows you to specify the appearance of the selected visible groups:

Page 325: Gambit Tutorial Guide

Shade Hidden • Wire wireframe model view displays a wireframe view of the

selected groups. • Shade shaded model view displays a three-dimensional shaded

view of the selected groups. • Hidden renders invisible all hidden lines. Hidden lines are those

concealed behind other entities in the current model orientation.

Render Model

The Render Model command allows you to render the model as either shaded, wireframe, or hidden. The symbol displayed on the Render Model command button indicates its current function. To change the function of the button, right-click it to open the menu of available functions, then select the desired function from the menu. When you select a function from the menu, GAMBIT automatically renders the model according to the selected function.

Specify Color Mode

The Specify Color Mode command button allows you to toggle between two modes of defining color for the lines, curves, and points as displayed in the active graphics-window quadrants. The two color modes are as follows:

• Topology -- specifies that the colors displayed for vertices, edges, faces, and volumes correspond to the hierarchy of model entities.

• Connectivity -- specifies that model colors are based on connectivity between entities.

Topology Mode

In the topology color mode, GAMBIT displays entity colors according to the GAMBIT geometry color conventions. The default topology color conventions are as follows.

Page 326: Gambit Tutorial Guide

Entity Color

Vertex white

Edge yellow

Face cyan

Volume green

You can change the default topology color conventions by means of the Edit Defaults form (see "Using the Edit Defaults Form" in Section 4.2.4).

The colors listed in the table above correspond to only those entities that do not constitute parts of higher-topology entities. For example, if an edge exists on its own, it is displayed as yellow, but if it constitutes part of a face, it is displayed as cyan.

Connectivity Mode

In the connectivity color mode, GAMBIT displays colors based on the connectivity between entities. The default connectivity color conventions are as follows.

Number of Connections Color

0 white

1 orange

2 deepskyblue

3 or more cyan

For example, in the connectivity color mode, lone vertices are white but any vertex that constitutes an endpoint for two separate edges is colored orange. Similarly, lone edges are white, but an edge that an edge that is shared by three separate faces is colored deepskyblue.

If two coincident entities differ in the degree of their connectivity to other entities in the model, GAMBIT displays the color corresponding to the least-connected entity. For example, if a lone vertex is coincident with the corner vertex of a four-sided face, GAMBIT displays a white vertex at the location of coincidence.

NOTE (1): GAMBIT determines connectivity coloration for any entity on the basis of the number of sides of the entity that are connected to higher entities. If you create a face that

Page 327: Gambit Tutorial Guide

includes a dangling edge, GAMBIT assigns the dangling edge a connectivity color of deepskyblue, because the face itself exists on two separate sides of the edge.

NOTE (2): You can change the default connectivity color conventions by means of the Edit Defaults form (see "Using the Edit Defaults Form" in Section 4.2.4).

Examine Mesh

When you click the Examine Mesh command button, GAMBIT opens the Examine Mesh form (see below). The Examine Mesh form allows you to display an existing mesh and to customize the characteristics of the mesh display.

Page 328: Gambit Tutorial Guide

To display a mesh by means of the Examine Mesh form, you must specify two major sets of parameters:

• Display Type • Display Mode

The Display Type parameters determine which mesh elements are visible when the mesh is displayed. The Display Mode parameters determine the visual appearance of elements that are displayed.

Specifying the Display Type

There are three general Display Type specifications on the Examine Mesh form:

Page 329: Gambit Tutorial Guide

• Domain • Element type • Quality type

The domain specification allows you to define which region of the mesh is displayed. The element-type specification determines which element shapes are included in the group of displayed elements. The quality-type specification determines the quality criterion that is used to color displayed elements and/or to define which elements are displayed.

The following sections describe each of the specifications listed above.

Specifying the Domain

The domain specification consists of the following options:

• Plane • Sphere • Range

The Plane and Sphere options allow you to display mesh elements located relative to a planar or spherical cut through the mesh. The Range option allows you to display only those mesh elements the quality of which falls within specified limits with respect to a designated quality criterion.

The following sections describe the each of the options listed above and illustrate their relative effects on the mesh display for the elliptical cylinder shown in Figure 3-14. (NOTE: In this example, the cross section of the cylinder is elongated with respect to the x axis, and the cylinder is aligned with the z axis.)

Page 330: Gambit Tutorial Guide

Figure 3-14: Meshed elliptical cylinder

Plane Option

When you select the Plane option, GAMBIT displays a plane cut through the mesh. To customize the plane cut, you must specify two parameters:

• Cut Type • Cut Orientation

The Cut Type specification determines whether GAMBIT displays a zero-thickness plane cut through the mesh or an array of mesh elements defined by their position with respect to the cutting plane. The Cut Orientation specification allows you to align the cutting plane with one of the three planes of the active coordinate system and to specify the position of the cutting plane.

Specifying the Cut Type

To specify the Cut Type, you must select one of the following options:

• Display cut • Display elements

Display cut Option

When you select the Display cut option, GAMBIT displays a zero-thickness plane cut through the mesh-such as that shown in Figure 3-15. The plane cut shown in Figure 3-15

Page 331: Gambit Tutorial Guide

is located in the center of the elliptical cylinder and is aligned with the y-z coordinate plane.

Figure 3-15: Plane cut -- Cut Type: Display cut option, y-z plane

You can align the cutting plane with any of the three Cartesian coordinate planes by means of the Cut Orientation slider bars (see "Specifying the Cut Orientation," below).

Display elements Option

When you select the Display elements option, GAMBIT displays a region of the mesh defined with respect to the cutting plane. You can specify which region of the mesh is displayed by means of Display elements suboptions. The Display elements suboptions are as follows:

Suboption Description

- Displays elements that exist below the cutting plane

0 Displays elements that are intersected by the cutting plane

+ Displays elements that exist above the cutting plane

A set of radio buttons corresponding to the Display elements suboptions is located above the Cut Orientation slider bars in the lower section of the Examine Mesh form. To select a Display elements suboption, click its corresponding radio button.

Page 332: Gambit Tutorial Guide

Figure 3-16 and Figure 3-17 show the effect of the 0 and - suboptions, respectively, on the mesh display for the elliptical cylinder shown in Figure 3-14. In both figures, the cutting plane is centered in the cylinder and aligned with the y-z plane.

Figure 3-16: Plane cut -- Cut Type: Display elements, y-z plane, Suboption (0)

Figure 3-17: Plane cut -- Cut Type: Display elements, y-z plane, Suboption (-)

NOTE: When you select the Display elements option, GAMBIT displays only those elements that meet both the domain and element type specifications currently specified in

Page 333: Gambit Tutorial Guide

the Display Type field on the Examine Mesh form. For example, if you select the Plane option and specify the display of pyramidal elements only, GAMBIT displays only those mesh elements that are pyramidal in shape and are intersected by the specified cutting plane. (See "Specifying the Element Type," below.)

Specifying the Cut Orientation

To specify the Cut Orientation, you must specify the alignment and position of the cutting plane. The alignment and position specifications determine the following characteristics of the cutting plane:

• Alignment relative to the planes of the active coordinate system • Location in the model domain

The alignment and position of the cutting plane are specified by means of the Cut Orientation slider bars located in the lower section of the Examine Mesh form (see above). There are three Cut Orientation slider bars, labeled X, Y, and Z.

GAMBIT allows you to align the cutting plane such that it is parallel to any one of the three coordinate planes of the active coordinate system. To orient the cutting plane, click the slider box corresponding to the axis that is normal to the desired coordinate plane. For example, to orient the reference plane such that it is parallel to the x-y coordinate plane (Figure 3-18), click the slider box labeled Z.

Figure 3-18: Plane cut -- Cut Type: Display elements, x-y plane

To reposition the cutting plane in the model domain, left-drag the slider box to the left or right. When you left-drag the slider box, GAMBIT automatically updates the graphics

Page 334: Gambit Tutorial Guide

window mesh display to reflect the current position of the box. To change the position of the cutting plane in increments, left-click the slider bar on either side of the slider box.

NOTE: If you activate a coordinate system other than the currently active system, GAMBIT automatically updates the orientation of the cutting plane with reference to the newly active system.

Sphere Option

When you select the Sphere option, GAMBIT displays a spherical cut through the mesh. To customize the spherical cut, you must specify two parameters:

• Cut Type • Cut Orientation

The Cut Type specification determines whether GAMBIT displays a zero-thickness spherical shell or an array of mesh elements defined by their position with respect to the shell. The Cut Orientation specification allows you to position the center of the sphere and to specify the radius of the sphere.

Specifying the Cut Type

To specify the Cut Type, you must select one of the following options:

• Display cut • Display elements

The spherical-cut Display cut and Display elements options produce effects similar to those of the corresponding plane-cut options but differ as outlined below.

Display cut Option

When you select the spherical-cut Display cut option, GAMBIT displays a zero-thickness spherical shell such as that shown in Figure 3-19.

Page 335: Gambit Tutorial Guide

Figure 3-19: Sphere cut -- Cut Type: Display cut option

The lines shown on the surface of the spherical cut represent lines of intersection between the sphere and either the mesh-element faces or the geometrical boundaries of the model components. You can position the sphere within the model domain and specify its radius by means of the Cut Orientation slider bars (see "Specifying the Cut Orientation," below).

Display elements Option

When you select the Display elements option, GAMBIT displays a region of the mesh defined relative to the cutting sphere. You can specify which region of the mesh is displayed by means of Display elements suboptions. The Display elements suboptions are as follows:

Suboption Description

- Displays elements that exist entirely outside the cutting sphere

0 Displays elements that are intersected by the cutting sphere

+ Displays elements that exist entirely inside the cutting sphere

A set of radio buttons corresponding to the Display elements suboptions is located above the Cut Orientation slider bars in the lower section of the Examine Mesh form. To select a Display elements suboption, click its corresponding radio button.

Figure 3-20, Figure 3-21, Figure 3-22 and show the effect of the -, 0, and + suboptions, respectively, on the mesh display for the elliptical cylinder shown in Figure 3-14. In each

Page 336: Gambit Tutorial Guide

figure, the cutting sphere is located in the center of the cylinder, and its radius is that shown in Figure 3-19, above.

Figure 3-20: Sphere cut -- Cut Type: Display elements, Suboption (-)

Figure 3-21: Sphere cut -- Cut Type: Display elements, Suboption (0)

Page 337: Gambit Tutorial Guide

Figure 3-22: Sphere cut -- Cut Type: Display elements, Suboption (+)

NOTE: When you select the Display elements option, GAMBIT displays only those elements that meet both the domain and element type specifications currently specified in the Display Type field on the Examine Mesh form. For example, if you select the Sphere option and specify the display of pyramidal elements only, GAMBIT displays only those mesh elements that are pyramidal in shape and are intersected by the specified cutting sphere. (See "Specifying the Element Type," below.)

Specifying the Cut Orientation

To specify the Cut Orientation, you must specify the position and radius of the cutting sphere. The position and radius of the cutting sphere are specified by means of the Cut Orientation slider bars located in the lower section of the Examine Mesh form (see above).

When you specify a Sphere cut, GAMBIT displays four Cut Orientation slider bars, labeled X, Y, Z, and R. The X, Y, and Z slider bars allow you to specify the position of the center of the sphere relative to the axes of the active coordinate system. The R slider bar allows you to specify the radius of the sphere.

Range Option

When you select the Range option, GAMBIT displays only those mesh elements the quality of which falls within a specified range with respect to a specified Quality Type criterion (see Figure 3-23).

Page 338: Gambit Tutorial Guide

Figure 3-23: Elliptical cylinder mesh -- Range option

To display mesh elements by means of the Range option, you must specify the following parameters:

• Quality criterion • Range

To specify the quality criterion, you must use the Quality Type option button located at the bottom of the Display Type field (see "Specifying the Quality Type," below). To define the range, you must specify its lower and upper limits by means of the range components located in the lower section of the Examine Mesh form (see below).

When you select the Range option, GAMBIT displays two types of range components on the Examine Mesh form:

• Histogram

Page 339: Gambit Tutorial Guide

• Lower and Upper limit slider bars

Histogram

The range histogram consists of a bar chart representing the statistical distribution of mesh elements with respect to the specified quality criterion. Each vertical bar on the histogram corresponds to a unique set of lower and upper quality limits. To display those elements the quality of which falls within the limits represented by any vertical bar on the histogram, left-click the corresponding bar.

Lower and Upper Limit Slider Bars

The Lower and Upper limit slider bars allow you to specify the lower and upper limits of the quality range that determines which elements are displayed in the graphics window. To specify the Lower or Upper limit of the range, left-drag the appropriate slider box to the desired location. To change the Lower or Upper limit of the range incrementally, left-click the appropriate slider bar on either side of the corresponding slider box.

NOTE: If the Lower value is greater than the Upper value, GAMBIT simultaneously displays those elements with quality values less than the Upper value and greater than the Lower value.

Specifying the Element Type

When you select the Display elements option, GAMBIT displays two-dimensional (face) and/or three-dimensional (volume) elements in the graphics window. GAMBIT allows you to customize the mesh display so that only specified types of elements are displayed. To specify the element type, you must specify two parameters:

• Class • Shape

The class specification determines whether GAMBIT displays face elements or volume elements. The shape specification determines which element shapes are included in the set of displayed elements.

Class

For the purposes of displaying the mesh, there are two classes of elements:

• 2D Element • 3D Element

Each class is associated with its own set of available element shapes (see below). To specify a class, left-click the class option button in the Display Type field and select either the 2D Element or 3D Element option.

Page 340: Gambit Tutorial Guide

Shape

When you select an element class, GAMBIT displays a set of option selector buttons that represent the element shapes available for the specified class. The option selector buttons are located at the right side of the class option button.

The following table shows the element shapes corresponding to each element class.

Element Class Shape Selector Button

2D Element Quadrilateral

Triangle

3D Element Hexahedron

Tetrahedron

Prism

Wedge

When you display mesh elements by means of the Examine Mesh form, GAMBIT displays only those elements the shapes of which match the current element-type specifications. For example, if you specify a plane cut according to the following parameters:

Parameter Specification

Class 3D Element

Shape Hexahedron, Wedge

GAMBIT displays only those volume elements that meet both of the following criteria:

• Intersected by the specified plane • In the shape of either a brick or a wedge

Similarly, if you specify a plane cut according to the following parameters:

Parameter Specification

Page 341: Gambit Tutorial Guide

Category 2D Element

Shape Quad

GAMBIT displays only those face elements that are intersected by the specified plane and possess a quadrilateral shape (see Figure 3-24).

Figure 3-24: Plane cut, y -- z plane-2D Element, Quad

Specifying the Quality Type

The quality-type specification defines the criterion that determines the following mesh display characteristics:

• Which elements are displayed by means of the domain Range option (see "Range Option," above)

• The coloration of elements for faceted mesh displays (see "Faceted Option," below.)

The following sections describe the quality types available in GAMBIT and the correspondence between quality types and the mesh element types described in the previous section.

Quality Type Definitions

GAMBIT provides the following mesh quality-type specifications:

Page 342: Gambit Tutorial Guide

• Area • Aspect Ratio • Diagonal Ratio • Edge Ratio • EquiAngle Skew • EquiSize Skew • MidAngle Skew • Stretch • Taper • Volume • Warpage

The following sections summarize the definitions and characteristics of each of the specifications listed above.

Area

The Area specification applies only to 2-D elements and represents mesh quality on the basis of element area.

Aspect Ratio

The Aspect Ratio applies to triangular, tetrahedral, quadrilateral, and hexahedral elements and is defined differently for each element type. The definitions are as follows.

Triangular and Tetrahedral Elements

For triangular and tetrahedral elements, the Aspect Ratio ( ) is defined as:

where f is a scaling factor, and r and R represent the radii of the circles (for triangular elements) or spheres (for tetrahedral elements) that inscribe and circumscribe,

respectively, the mesh element. For triangular elements, ; for tetrahedral

elements, .

By definition,

where describes an equilateral element.

Quadrilateral and Hexahedral Elements

Page 343: Gambit Tutorial Guide

For quadrilateral and hexahedral elements, is defined as:

where is the average length of the edges in a coordinate direction (i) local to the element (see Figure 3-25) and n is the total number of coordinate directions associated

with the element. For quadrilateral elements, ; for hexahedral elements, .

Figure 3-25: Aspect Ratio ( ) -- quadrilateral element

Again, by definition,

.

where describes an equilateral element.

Diagonal Ratio

The Diagonal Ratio ( ) applies only to quadrilateral and hexahedral elements and is defined as follows:

Page 344: Gambit Tutorial Guide

where the are the lengths of the element diagonals. For quadrilateral elements, ;

for hexahedral elements, .

By definition,

.

The higher the value of , the less regularly shaped is its associated element. For

square quadrilateral elements and cubic hexahedral elements, .

Edge Ratio

The Edge Ratio ( ) is defined as follows:

where represents the length of the element edge i, and n is the total number of edges associated with the element.

By definition,

.

The higher the value of , the less regularly shaped is its associated element. For

equilateral element shapes, .

EquiAngle Skew

The EquiAngle Skew ( ) is a normalized measure of skewness that is defined as follows:

where and are the maximum and minimum angles (in degrees) between the

edges of the element, and is the characteristic angle corresponding to an equilateral

cell of similar form. For triangular and tetrahedral elements, . For quadrilateral

and hexahedral elements, .

Page 345: Gambit Tutorial Guide

By definition,

where describes an equilateral element, and describes a completely degenerate (poorly shaped) element.

NOTE: For pyramidal mesh elements, is equal to its maximum value for any of the five faces of the mesh element. In an ideal pyramidal mesh element, all four triangular faces are equilateral and the base of the pyramid is a square.

Table 3-1 outlines the overall relationship between and element quality.

Table 3-1: vs. Mesh Quality

Quality

Equilateral (Perfect)

Excellent

Good

Fair

Poor

Very poor (sliver)

Degenerate

In general, high-quality meshes contain elements that possess average values of 0.1 (2-D) and 0.4 (3-D).

EquiSize Skew

The EquiSize Skew ( ) is a measure of skewness that is defined as follows:

Page 346: Gambit Tutorial Guide

where S is the area (2-D) or volume (3-D) of the mesh element, and is the maximum area (2-D) or volume (3-D) of an equilateral cell the circumscribing radius of which is identical to that of the mesh element.

By definition,

where describes an equilateral element, and describes a completely degenerate (poorly shaped) element.

The relationship between and mesh quality shown in Table 3-1, above, applies to

values of , as well. In general, high-quality meshes contain elements that possess

average values of 0.1 (2-D) and 0.4 (3-D).

(NOTE: The EquiSize Skew quality metric applies only to triangular and tetrahedral elements. If you select the EquiSize Skew metric for a mesh that contains elements other than triangles and tetrahedra, GAMBIT evaluates the non-triangular and non-tetrahedral elements using the EquiAngle Skew metric.)

MidAngle Skew

The MidAngle Skew ( ) applies only to quadrilateral and hexahedral elements and is

defined by the cosine of the minimum angle ( ) formed between the bisectors of the element edges (quadrilateral) or faces (hexahedral) (see Figure 3-26).

Figure 3-26: MidAngle Skew ( ) definition -- quadrilateral element

For quadrilateral elements,

Page 347: Gambit Tutorial Guide

.

For hexahedral elements,

where , , and are the three angles computed from the face-bisecting lines of the element.

By definition,

where describes an equilateral element, and describes a completely degenerate (poorly shaped) element.

Stretch

The Stretch quality metric ( ) applies only to quadrilateral and hexahedral elements and is defined as follows:

where is the length of diagonal i, is the length of the element edge j, and n and m are the total numbers of diagonals and edges, respectively. For quadrilateral elements, n = 2 and m = 4; for hexahedral elements, n = 4 and m = 12.

By definition,

where describes an equilateral element, and describes a completely degenerate (poorly shaped) element.

Taper

The Taper quality metric ( ) applies only to quadrilateral and hexahedral mesh elements and is defined as follows.

For any quadrilateral (or hexahedral) mesh element, it is possible to construct a parallelogram (or parallelepiped) such that the distance between any given corner of the

Page 348: Gambit Tutorial Guide

parallelogram (or parallelepiped) and its nearest element corner node is a constant value. As a result, any vector, T, constructed from an element corner node to the nearest corner of the parallelogram (or parallelepiped) possesses a magnitude identical to that of all other such vectors (see Figure 3-27).

Figure 3-27: Taper quality metric definition -- quadrilateral element

Each vector, T, can be resolved into components, , that are parallel to the bisectors of the mesh element. For quadrilateral elements, there are two such components for each

vector; for hexahedral elements, there are three. The Taper quality metric ( ) is defined as the normalized maximum of all such components for the element.

By definition,

where describes an equilateral element, and describes a completely degenerate (poorly shaped) element.

Volume

The Volume specification applies only to 3-D elements and represents mesh quality in terms of mesh element volumes.

Page 349: Gambit Tutorial Guide

Warpage

The Warpage ( ) applies only to quadrilateral elements and is defined as follows:

where Z is the deviation from a best-fit plane that contains the element, and a and b are the lengths of the line segments that bisect the edges of the element.

By definition,

where describes an equilateral element, and describes a completely degenerate (poorly shaped) element.

Element Types vs. Quality Types

Each element type is associated with a unique set of available quality types. Table 3-2 summarizes the correspondence between mesh element types and the quality types described above. (Shaded boxes in the table represent quality types that are available for each corresponding element type.)

Table 3-2: Mesh element type vs. quality type

2-D Element 3-D Element

Quality Type

Area X X

Aspect Ratio X X X X X X

Diagonal Ratio X X

Edge Ratio X X X X X X

EquiAngle Skew X X X X X X

EquiSize Skew X X

MidAngle Skew X X

Page 350: Gambit Tutorial Guide

Stretch X X

Taper X X

Volume X X X X

Warpage X

To specify a quality type, click the Quality Type option button and select the quality type from the option menu.

NOTE: The Quality Type option menu includes only those quality types that are common to all currently selected element types. For example, if you specify the element type to include only 2D Element rectangles, the Quality Type option menu includes six items: Area, Aspect Ratio, Skew, Stretch, Taper, and Warpage. If, on the other hand, you specify the element type to include both 2D Element shapes (rectangles and triangles), the Quality Type option menu includes only the option Skew.

Specifying the Display Mode

Display Mode specifications determine the appearance of the mesh display. To specify the display mode, you must specify the following parameters:

• Enabled quadrants • Appearance

The quadrant specification determines which graphics window quadrants are affected by the current specifications on the Examine Mesh form. The appearance specification determines the manner in which the mesh elements are displayed in each enabled quadrant.

Specifying the Enabled Quadrants

The quadrant specification field consists of a set of five command buttons that are identical to the quadrant command buttons used to enable and disable general graphics operations in each of the quadrants. For a description of the use of quadrant command buttons, see Section 3.4.1, above.

Specifying the Appearance

GAMBIT provides the following options with respect to the appearance of the displayed mesh:

• Wire • Faceted

Page 351: Gambit Tutorial Guide

The Wire option specifies that GAMBIT displays a wireframe view of the mesh. The Faceted option specifies that GAMBIT renders the mesh display in either a colored, shaded, or hidden view. Neither option is exclusive of the other.

Wire Option

When you select the Wire option, GAMBIT displays all lines corresponding to the edges of all displayed mesh elements.

Faceted Option

When you select the Faceted option, GAMBIT renders all displayed mesh elements to illustrate their shape, location, and/or quality characteristics. There are three Faceted rendering suboptions, each of which is mutually exclusive of the others:

• Quality • Shade • Hidden

Quality Suboption

When you select the Quality suboption, GAMBIT renders the faces of all displayed mesh elements as follows:

• Color to represent the quality of the element with respect to the currently specified quality criterion as displayed on the scale at the bottom of the Examine Mesh form (see "Specifying the Quality Type," above)

• Shade to reflect the position of the face with respect to the light source

If you rotate the model by means of the mouse, the colors of the element faces change to reflect changes in the position of each element face with respect to the light source. (For a description of the procedures and specifications required to modify the position and brightness of the light source, see "Modify Lights," above.)

Shade Suboption

When you select the Shade suboption, GAMBIT renders the faces of all displayed mesh elements in shades of gray to reflect the position of each face with respect to the light source.

Hidden Suboption

When you select the Hidden suboption, GAMBIT displays a wireframe view of the mesh but hides all lines that are concealed behind displayed mesh element faces.

Using the Examine Mesh Form

Page 352: Gambit Tutorial Guide

The Examine Mesh form allows you to specify the type of mesh elements displayed and the display mode for those elements. It includes the following specifications.

Display Type: -------------------------

Plane displays a plane cut through the mesh. The cut can represent either a zero-thickness plane or mesh elements defined in relation to those intersected by the plane (see "Plane Option," above).

Sphere displays a spherical cut through the mesh. The cut can represent either a zero-thickness spherical shell or mesh elements defined in relation to those intersected by the shell (see "Sphere Option," above).

Range displays all mesh volume elements possessing quality values within a specified range for one of several available mesh quality criteria (see "Range Option," above).

3D Element 2D Element

specifies the class of elements to be displayed. Element classes include face elements (2D Element) and volume elements (3D Element).

specifies 2D Element shapes.

Specifies 3D Element shapes.

Quality Type: -------------------------

Area Aspect Ratio Diagonal Ratio Edge Ratio EquiAngle Skew EquiSize Skew MidAngle Skew Stretch Taper Volume Warpage

allows you to specify the quality criterion that determines which elements are displayed by means of the Range option and the coloration of elements for faceted mesh displays. (See "Specifying the Quality Type," above.)

Display Mode: -------------------------

(quadrant command buttons) enable or disable any or all quadrants with respect to changes in mesh display. Changes made

Page 353: Gambit Tutorial Guide

by means of the Examine Mesh form are applied only to enabled quadrants.

Wire specifies a wireframe view of the displayed mesh elements.

Faceted specifies a faceted rendering of all displayed mesh element faces.

Faceting Type: ----------------------

Quality colors each mesh element face to represent its quality and shades each mesh element face to reflect its current position with respect to the light source. (NOTE: Element colors change slightly when you reorient the model.)

Shade shades the mesh elements to create a three-dimensional rendering of the mesh.

Hidden displays a wireframe view of the model but hides all lines that are concealed behind other elements in the current mesh specification and orientation.

Cut Type: -------------------------

Display Cut displays a zero-thickness planar or spherical cut through the mesh.

Display Elements displays elements defined in relation to the plane or spherical shell.

Cut Orientation: contains slider bars that allow you to specify the orientation of a plane cut or the radius and location of the center of a spherical cut. The Cut Orientation field also includes radio buttons that allow you to specify the region of elements to be displayed by means of the Display elements option.

Plane Cut Slider Bars

The plane-cut slider bars (see below) allow you to change the position of the cut plane in the x (X), y (Y), and z (Z) directions.

Page 354: Gambit Tutorial Guide

To change the location of the cut plane, left-click one of the slider boxes and drag it to a new location on its slider bar. GAMBIT repositions the plane according to the final position of the slider box.

The plane-cut sliders also allow you to change the orientation of the cut plane with respect to the coordinate planes. The X, Y, and Z sliders orient the cut plane perpendicular to the x, y or z coordinate planes, respectively, of the active coordinate system. To change the orientation of the cut plane, left-click the appropriate slider.

Spherical Cut Slider Bars

The spherical-cut slider bars allow you to change the location of the center of the cutting sphere in the x (X), y (Y), and z (Z) directions and to specify the radius (R) of the sphere.

To change the location of the sphere center, left-click one of the X, Y, or Z slider boxes and drag it to a new location on the slider bar. To change the sphere radius, left-click the R slider box and drag it to its new location.

Display elements Suboption Radio Buttons

When you select the Display Elements option (see above), GAMBIT displays three radio buttons above the Cut Orientation slider bars. The radio buttons allow you to specify the region of mesh elements to be displayed.

Page 355: Gambit Tutorial Guide

The options specified by means of the radio buttons are as follows.

For both the plane-cut and spherical-cut options, the 0 option specifies that only those elements intersected by the specified plane or spherical shell are displayed.

For plane cuts, the - and + options display all elements located in the negative and positive coordinate directions, respectively, relative to the elements intersected by the plane.

For spherical cuts, the - and + options specify the display of elements inside and outside, respectively, those elements intersected by the spherical shell.

© Fluent, Inc. 11/08/99

Page 356: Gambit Tutorial Guide

4. GAMBIT MENU COMMANDS

The GAMBIT main menu bar includes the following menu commands.

Menu

Item Purposes

File • Create, open and save sessions • Print graphics • Edit and/or run journal files • Clean up journal files • View transcript files • Import and export geometry and mesh data • Exit the program

Edit • Edit session titles • Edit text files • Create and edit parameters • Edit program defaults

Solver • Specify a solver

Help • Access online help documents

The following sections of this chapter describe the functions and uses of commands available for each of main menu items listed above.

NOTE: Most of the specification forms described in the following sections include Accept and Close command buttons. Unless otherwise noted, the functions of the two buttons are as follows:

• Accept--executes the operation associated with the form. • Close--closes the form without executing the associated operation.

Page 357: Gambit Tutorial Guide

4.1 File Commands

The GAMBIT File command menu includes the following commands.

Command Description

New Creates a new session

Open Opens a previously saved session

Save Saves the current session

Save As Saves the current session under a new name

Print Graphics Prints currently displayed graphics

Run Journal Displays and allows you to edit and/or execute the commands in any journal file

Clean Journal Removes extraneous commands, messages, and signals from a GAMBIT journal file

View File Displays the current transcript file

Import Imports geometry and mesh data

Export Exports geometry and mesh data

Exit Stops program execution

4.1.1 New

When you select New from the File command menu, GAMBIT opens the Create New Session form. The Create New Session form allows you to create and name a new GAMBIT session.

To create a new session, you must specify the following items:

• Session identifier • Save option

Page 358: Gambit Tutorial Guide

In addition to the two mandatory specifications listed above, GAMBIT also allows you to specify a title for the session.

The session identifier constitutes the root name for GAMBIT data files associated with the new session. (For a description of GAMBIT data file contents and organization, see Chapter 2 of this guide.) The save option determines whether or not GAMBIT saves existing session data before creating a new session. The session title constitutes a general descriptor for the session.

Specifying the Session Identifier

The session identifier can consist of any combination of alphanumeric characters and/or symbols that constitutes a valid file name in the operating system under which GAMBIT

is running. The GAMBIT default session identifier is "model1."

Specifying the Save Option

When you create a new session, GAMBIT deletes any data associated with the current session. To save the current session data when you create a new session, select the Save current session option on the Create New Session form.

Specifying the Session Title

The session title constitutes a general descriptor for the session. It may consist of any combination of alphanumeric characters and/or symbols up to 80 characters in length.

Using the Create New Session Form

The Create New Session form (see below) allows you to create and name a new GAMBIT session. To open the Create New Session form, select New from the File menu on the main menu bar.

The Create New Session form includes the following specifications.

Page 359: Gambit Tutorial Guide

ID: specifies the identifier for the new session.

Title: specifies a session title up to 80 characters in length.

Save current session

specifies that any current session data is saved when the new session is created. GAMBIT uses the current session identifier as the root file name for the files containing the current session data.

4.1.2 Open

When you select Open from the File command menu, GAMBIT opens the Open Existing Session form. The Open Existing Session form allows you to open a previously saved session.

To open an existing session, you must specify the following information:

• Session identifier • Save option

The session identifier constitutes the root name of the data files for the session to be opened. (For a description of GAMBIT data file contents and organization, see Chapter 2 of this guide.) The save option determines whether or not GAMBIT saves current session data before opening a new session.

Specifying the Session Identifier

To open an existing session, you must specify the identifier of the session to be opened. The session identifier constitutes the root name of all files associated with the session.

You can specify the session identifier in one of two ways:

• ID text box • Browse command button

The ID text box allows you to directly specify the identifier of the session to be opened. The Browse command button allows you to browse file directories and to select the session to be opened from a list of existing files.

Using the ID Text Box

When you specify an identifier in the ID text box and click Accept, GAMBIT searches the

current directory for a database (dbs) file the root name of which matches the specified identifier. If the database file corresponding to the session to be opened exists in a

Page 360: Gambit Tutorial Guide

directory other than the current directory, you must also include the directory specification in the input text.

If you include a file extension when you specify the identifier, GAMBIT searches for a file matching the exact name specified in the ID text box. If you do not include a file extension when you specify the identifier, GAMBIT searches for a file with a root name

matching the session identifier and a database file extension (dbs). For example, if you

specify the identifier "example" in the ID text box, GAMBIT searches for a database file

named example.dbs.

Using the Browse Command Button

When you click the Browse command button, GAMBIT opens the Select File form. The Select File form allows you to browse file directories in search of existing files. (For instructions concerning the use of the Select File form, see "Using the Select File Form," below.)

To specify the identifier of an existing GAMBIT session by means of the Select File

form, you must search for and select a database (dbs) file the root name of which constitutes the identifier of the session to be opened. For example, to specify an existing

session with the identifier, "wing005," you must search for and select a file named

wing005.dbs.

Specifying the Save Option

When you open an existing session, GAMBIT deletes any data associated with the current session. To save the current session data when you open an existing session, select the Save current session option on the Open Existing Session form.

Using the Open Existing Session Form

The Open Existing Session form (see below) allows you to open a previously saved session. To open the Open Existing Session form, select Open from the File menu on the main menu bar.

The Open Existing Session form includes the following specifications.

ID: specifies the identifier of the session to be opened.

Page 361: Gambit Tutorial Guide

Browse… opens the Select File form (see "Using the Select File Form," below), which allows you to browse directories and file lists and to select a file name from the lists.

Save current session

specifies that any current session data is saved when the existing session is opened. GAMBIT uses the current session identifier as the root file name for the files containing the current session data.

Using the Select File Form

The Select File form (see below) allows you to browse directories and to select a file from a list of currently available files. To open the Select File form, click the Browse command button on any file-related GAMBIT form.

The Select File form includes the following specifications.

Filter Changing the Filter Directory Specification

There are three ways to change the filter directory specification.

• Input the new directory name in the Filter text box and press Enter or click the Filter command button.

Page 362: Gambit Tutorial Guide

• Double-click a directory name in the Directories list. • Highlight a directory name in the Directories list and click the

Filter command button at the bottom of the form.

Changing the Filter File Specification

To change the filter file specification, input the new specification in the Filter text box and either press Enter or click the Filter command button at the bottom of the Select File form.

Directories lists all directories and subdirectories associated with the directory specified in the Filter text box. The topmost directory listed in the Directories list represents the current filter directory.

Files lists all files that match the current filter specifications.

Selection specifies the file to be selected by means of the Select File form. To change the selected file, either input the new file name in the Selection text box or highlight the name of the file in the Files list.

Accept accepts the current file selection and closes the Select File form. You can also select a file and close the form by double-clicking the file name in the Files list.

Filter changes the filter directory specification to the currently highlighted directory in the Directories list or updates the directories or files list to reflect changes made to the Filter specification..

Cancel closes the Select File form without accepting a file for selection.

4.1.3 Save

When you select Save from the File command menu, GAMBIT saves the current session data to three data files the root name of which constitutes the current session identifier. (For a description of GAMBIT data file contents and organization, see Chapter 2 of this guide.)

The saved data includes the following items:

• Model geometry • Boundary-type specifications • Continuum-type specifications • Mesh specifications

Page 363: Gambit Tutorial Guide

• Layout and characteristics of the GUI and graphics window at the time the data is saved.

4.1.4 Save As

When you select Save As from the File command menu, GAMBIT opens the Save Session As form. The Save Session As form allows you to save the current model data using a specified identifier.

To save session data by means of the Save Session As form, you must specify an identifier that serves as the root name for the session database files. (For a description of the session identifier specifications, see "Specifying the Session Identifier," in Section 4.1.1, above.) If you specify an identifier that corresponds to an existing session, GAMBIT prompts you to acknowledge that the existing session data is to be overwritten by the current data.

Using the Save Session As Form

The Save Session As form (see below) allows you to save the current model data using a specified session identifier. To open the Save Session As form, select Save As from the File command menu on the main menu bar.

The Save Session As form includes the following specifications.

ID: specifies the identifier under which the current data is to be saved.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

4.1.5 Print Graphics

When you select Print Graphics from the File command menu, GAMBIT opens the Print Graphics form. The Print Graphics form allows you to print the model as currently displayed in the graphics window. You can print the graphics either to a printer or to a file.

Page 364: Gambit Tutorial Guide

Printing Graphics to a Printer

To print graphics to a printer, you must specify the following information:

• Printer Name -- identifier corresponding to the printer • Printer Options -- command codes required by the printer • Printer Command -- command string required to print graphics files

When GAMBIT opens the Print Graphics form, it displays the current default settings for the Printer Name, Printer Options, and Printer Command string specifications. The default settings are specific to the hardware configuration, operating system, and/or networking capabilities of the computer system upon which GAMBIT resides. To change the default settings for any of the items listed above, open the Edit Defaults form and modify the printer settings on the GLOBAL default definition subform. (See Section 4.2.4, below.)

Printing Graphics to a File

To print graphics to a file, you must specify the following information:

• File Format -- graphics format • File Name -- name of the file to which the graphics are printed

Specifying a File Format

GAMBIT allows you to specify any one of the following formatsfor the graphics output file:

• SGI RGB -- Silicon Graphics • PS -- PostScript • EPS -- Encapsulated PostScript • GIF -- CompuServe Graphics Interchange Format bitmap • TIFF -- TIFF bitmap • BMP -- Windows bitmap • TARGA -- Targa bitmap • PICT -- Macintosh PICT

Specifying a File Name

There are two ways to specify the file name for the graphics file.

• Input the name in the File Name text box • Click the Browse command button and select an existing file name by means of

the Select File form

The graphics file name can consist of any combination of alphanumeric characters and/or symbols that constitutes a valid file name in the operating system under which GAMBIT

Page 365: Gambit Tutorial Guide

is running. For a description of how to use the Select File form, see "Using the Select File Form," in Section 4.1.2, above.

Using the Print Graphics Form

The Print Graphics form (see below) allows you to print graphics either to a printer or to a file. To open the Print Graphics form, select Print Graphics from the File command menu on the main menu bar.

The Print Graphics form includes the following options.

Destination: -------------------------

Printer specifies printing graphics to a printer.

File specifies printing graphics to a file.

Printing Graphics to a Printer

When you select the Printer option on the Print Graphics form, the middle section of the form appears as shown above. It includes the following specifications.

Printer Name: specifies the name of the printer to which the graphics are printed.

Printer Options: specifies system-specific options for the printer.

Printer Command:

specifies the system commands required to print the graphics to the

printer. (NOTE: The parameters %p, %o, and %f represent the printer name and options and the name of the file to be printed, respectively.)

Printing Graphics to a File

Page 366: Gambit Tutorial Guide

When you select the File option on the Print Graphics form, the middle section of the form appears as shown below.

The Print Graphics form File options are as follows.

File Format: -------------------------

SGI RGB PS EPS GIF TIFF BMP TARGA PICT

specifies the format for the graphics file (see above).

File Name: specifies the name of the file to which the graphics output is saved.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

4.1.6 Run Journal

When you select Run Journal from the File command menu, GAMBIT opens the Run Journal form. The Run Journal form allows you to execute the commands contained in a journal file.

Overview

Journal files are text files that contain GAMBIT program commands. During any GAMBIT session, GAMBIT maintains a temporary journal file that contains all commands executed during the session. When you save a session, GAMBIT copies the

Page 367: Gambit Tutorial Guide

temporary journal file to a permanent file. The root name of the permanent journal file is

the session identifier, and its extension is "jou." For example, if you save a session with

the identifier "model2," GAMBIT copies the journal file to a file named "model2.jou."

NOTE: GAMBIT allows you to include comment lines, as well as commands, in journal files. Any line in a journal file that begins with a forward slash (/) is interpreted as a comment line rather than as a command line.

The Run Journal form allows you to run journal files-including the current (temporary) journal file, journal files saved from previous sessions, and journal files that have been created external to the GAMBIT program by means of a text editor. When you run a journal file, GAMBIT executes the file commands as if they were entered by means of the Command line.

NOTE (1): GAMBIT allows you to use IF blocks and DO loops in journal files. For a description of the syntax associated with GAMBIT IF blocks and DO loops, see Appendix A of this guide.

NOTE (2): You can pause the execution of a journal file at any moment during the Run Journal operation. While the file is paused, GAMBIT allows you to execute commands from the Command line or to open and run other journal files by means of the Run Journal form. GAMBIT maintains a stack of open journal files and executes them on a last-in/first-out basis.

Journal File Run Modes

You can run a journal file in either of two modes:

• Run • Edit/Run

Run Mode

When you run a journal file in the Run mode, GAMBIT automatically executes all of the journal file commands in sequence, beginning at the top of the file.

Edit/Run Mode

When you run a journal file in the Edit/Run mode, GAMBIT opens the Edit/Run Journal form. The Edit/Run Journal form allows you to edit and run the entire journal file or specified portions of it. For a description of the procedures and specifications required to use the Edit/Run Journal form, see "Using the Edit/Run Journal Form," below.

Using the Run Journal Form

Page 368: Gambit Tutorial Guide

The Run Journal form (see below) allows you to run an existing journal file. To open the Run Journal form, select Run Journal from the File menu on the main menu bar.

The Run Journal form includes the following specifications.

Mode: -------------------------

Run specifies running the journal file in the automatic mode. In the Run mode, GAMBIT executes all of the commands in the journal file as if they are input in sequence by means of the Command text box.

During the execution of the journal file, a Pause command button appears at the right side of the Command text box. To pause the execution of the journal file commands, click the Pause button. When you do so, GAMBIT pauses the execution of the journal file following the execution of the current command. At the same time, GAMBIT changes the button title from Pause to Resume. To resume execution of the journal file commands, click Resume. (NOTE: If GAMBIT

encounters a "read pause" command during the running of a journal file, GAMBIT pauses execution of journal file commands as if the Pause button had been clicked.)

Edit/Run specifies running the journal file in the semiautomatic mode. When you select the Edit/Run option, GAMBIT opens the Edit/Run Journal form (see "Using the Edit/Run Journal Form," below.)

File Name: specifies the name of the journal file.

Current Journal specifies the name of the current, temporary journal file.

Close existing journal

allows you to close all open journal files that are currently paused. (NOTE: If you do not select the Close existing journal option, GAMBIT places the specified journal file in the stack of open journal files (see above).)

Browse… opens the Select File form, which allows you to browse existing

Page 369: Gambit Tutorial Guide

directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Using the Edit/Run Journal Form

The Edit/Run Journal form (see below) allows you to edit and/or execute any or all of the commands in a journal file. It consists of a text editor and an input field consisting of a text box and several command buttons.

To open the Edit/Run Journal form, select Run Journal from the File menu on the main menu bar, then select the Edit/Run option on the Run Journal form, specify a journal file name, and click Accept.

Using the Text Editor

Page 370: Gambit Tutorial Guide

When you load a file into the Edit/Run Journal form, the file appears in the text editor window. The text editor window allows you to modify, add, and/or delete lines of text. The following table summarizes the operations you can perform using the Edit/Run Journal form text editor.

Operation Instruction(s)

Select text Left-click the beginning of the text block and left-drag the mouse to the end of the text. To select multiple lines of text, left-drag the mouse across all lines to be highlighted.

Modify text Select the text to be modified, and input the new text from the keyboard.

Insert text Locate the cursor at the text insertion point, and input text from the keyboard.

Delete text Select the text to be deleted, and press Delete or Backspace.

Insert a line Locate the cursor at the end of the line prior to the insertion point, and press Enter.

Delete a line

Select all text on the line to be deleted and press Delete or Backspace, then locate the cursor on the empty line, and press Backspace.

In addition to the operations described above, the Edit/Run Journal form text editor allows you to search for and replace blocks of text (see "Using the Hidden Menu," below.)

Working with Command Lines and Marker Fields

Each line of text in a journal file constitutes all or part of a GAMBIT command. When you select the Run mode option on the Run Journal form, GAMBIT automatically executes each command in sequence, beginning at the topmost line of the file. By contrast, the Edit/Run Journal form allows you to select and execute individual command lines or groups of command lines.

The Edit/Run Journal form text editor includes a marker field (identified by a right-

pointing arrowhead, ">") located immediately to the left of each line of text. The marker field identifies which lines of text are to be executed when you click either the Auto or Step command button at the bottom of the form. Only those lines corresponding to selected (highlighted) marker fields are executed.

To select a line of text for execution, left-click its marker field. GAMBIT highlights the marker fields for all selected lines of text. To unselect a selected (highlighted) line of text, left-click its marker field again.

Page 371: Gambit Tutorial Guide

To select a group of text lines for execution, left-drag the mouse across the marker fields associated with the group. GAMBIT highlights all of the selected marker fields. To unselect the group, left-drag the mouse across the highlighted marker fields.

When you execute journal file commands by means of the Auto or Step command buttons at the bottom of the Edit/Run Journal form, GAMBIT executes all lines of text corresponding to selected marker fields, beginning at the topmost selected line. (NOTE: If you do not specify a starting point, GAMBIT executes the journal file commands beginning at the topmost line in the journal file.) To specify a different starting point for command execution, Shift-left-click the marker field corresponding to the desired starting

point. GAMBIT identifies the specified starting point line by displaying a "+" sign in its

marker field (that is, "+>".) To unselect the currently-specified starting point, Shift-left-click its marker field or Shift-left-click a different marker field to designate it as the new starting point.

Using the Hidden Menu

In addition to the selection options outlined above, GAMBIT allows you to perform global selection and unselection operations by means of a hidden menu. To open the hidden menu, right-click anywhere in the text editor window.

The hidden menu includes the following options:

Option Description

Select All Selects all lines in the journal file

Unselect All Unselects all selected lines in the journal file

Toggle All Selects all unselected lines; unselects all selected lines

Reset Pointer Resets the journal file starting point to the topmost selected line

Replace Opens the Global Search and Replace form

The first four options perform functions related to specifying the sequence in which journal file commands are executed. The Replace option allows you to search for and replace blocks of text by means of the Global Search and Replace form. For instructions concerning the operation of the Global Search and Replace form, see "Using the Global Search and Replace Form," below.

Using the Input Field

The input field located at the bottom of the Edit/Run Journal form includes the following commands and specifications.

Page 372: Gambit Tutorial Guide

File Name: specifies the name of the file to be loaded or saved by means of the Load and Save command buttons (see below).

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Auto begins sequential execution of all selected command lines, starting at the topmost selected line or the specified starting point line. During execution,

GAMBIT displays the word, "Now" in the marker field of the command line currently being executed.

Step executes the next selected command line, starting at the topmost selected line or at the specified starting-point line.

Load loads the file specified in the File Name text box into the Edit/Run Journal form text editor.

Save saves the file as currently displayed in the text editor to the file name specified in the File Name text box.

Close closes the Edit/Run Journal form.

Using the Global Search and Replace Form

The Global Search and Replace form (see below) allows you to search for and replace blocks of text in the currently-displayed journal file. To open the Global Search and Replace form, select Replace from the Edit Journal File form hidden menu (see above).

The Global Search and Replace form includes the following specifications.

Find What: specifies the text search string.

Page 373: Gambit Tutorial Guide

Replace With:

specifies the replacement text string.

Options: -------------------------

Match Case restricts the search to only those blocks of text matching the text search string with respect to both character-type and case.

Pattern Match

allows pattern matchingsearching for textpattern matchingyou to use the

wildcard character, "*", to search for all instances of a word containing a specified combination of letters or symbols. For example, if you specify

"fr*" in the Find What text box and select the Pattern Match option,

GAMBIT searches the text file for all words beginning with "fr." If you do not select the Pattern Match option, GAMBIT interprets the Find What

text string literally and searches for all words containing "fr*."

Replace searches for all occurrences of the text search string in the currently-displayed text file and replaces them with the text replacement string.

4.1.7 Clean Journal

When you select Clean Journal from the File command menu, GAMBIT opens the Clean Journal form. The Clean Journal form allows you to remove extraneous commands and messages from a journal file

NOTE: For a description of GAMBIT journal files and their use, see Section 4.1.6, above.

The Clean Journal operation removes the following types of commands and messages from the file in a single operation:

• Commands associated with undo operations • Error messages • Signals

• save commands (optional)

The following sections describe the manner in which the Clean Journal operation removes the types of commands and messages listed above.

Commands Associated with Undo Operations

When you clean up a journal file by means of the Clean Journal operation, GAMBIT removes from the journal file all commands associated with undo operations. GAMBIT undo operations can involve two types of commands:

Page 374: Gambit Tutorial Guide

• Undo commands • Undo-group commands

An undo command undoes the most recently executed GAMBIT operation. Undo-group commands allow you to specify a sequence of one or more GAMBIT commands that can

be undone by means of a single undo command.

The following subsections describe these two types of commands with respect to their handling by the Clean Journal operation.

Undo Commands

A GAMBIT undo command undoes the most recently executed operation. When you

clean up a journal file that includes undo commands, GAMBIT removes the undo commands themselves as well as the commands that are undone by their execution. For example, if the specified journal file contains the following sequence of commands:

volume create brick width 5.3 volume create sphere radius 4 undo

the Clean Journal operation removes the second and third command lines so that the resulting journal file contains only the following command:

volume create brick width 5.3

Undo-Group Commands

GAMBIT undo-group commands allow you to specify a sequence of commands that can

be undone by the execution of a single undo command. The undo-group commands include the following two commands:

• undo begingroup • undo endgroup

To specify a sequence of commands that can be undone by a single undo command, you

must precede the sequence with the undo begingroup command and follow the

sequence with the undo endgroup command. For example, if you execute the following the sequence of commands:

undo begingroup volume create frustum height 10 radius 5 volume create brick width 3 undo endgroup undo

GAMBIT creates a cylinder and a brick, then undoes both operations.

Page 375: Gambit Tutorial Guide

NOTE: The undo begingroup and undo endgroup commands can be explicitly executed only from the GAMBIT Command line. Some GUI operations (for example, the Copy

operation) result in the automatic creation of undo begingroup and undo endgroup commands in the active journal file, but the commands themselves are not directly available by means of the GUI.

To explicitly specify a sequence of GUI operations as part of an undo group:

1. Enter undo begingroup on the Command line. 2. Execute the sequence of operations to be included in the undo group-either by

means of Command line commands or by means of the GUI.

3. Enter undo endgroup from the Command line.

If a journal file contains a sequence of commands that is preceded by an undo

begingroup command and followed by both an undo endgroup command and an undo command, the Clean Journal operation removes the entire command sequence, including

the undo command and the undo-group commands that bracket the sequence. For example, if a journal file contains the following sequence of five commands:

undo begingroup volume create brick width 5.3 volume create sphere radius 4 undo endgroup undo

the Clean Journal operation removes all five commands from the file.

Error Messages

If you attempt to perform a procedure that violates GAMBIT operation or syntax rules, GAMBIT displays an error message in the Transcript window and records the error event in the active journal file. In the journal file, all such event records begin with the character sequence "/ERR". When you clean up a journal file by means of the Clean Journal operation, GAMBIT removes from the journal file all lines that begin with the characters "/ERR".

Signals

Signals are system-generated reports of exceptional system-level events such as program errors (for example, division by zero) or user requests to terminate the current process. In the journal file, all such reports are recorded as a single line in the file beginning with the character sequence "/SIG". When you clean up a journal file by means of the Clean Journal operation, GAMBIT removes from the journal file all lines that begin with the characters "/SIG".

Save Commands

Page 376: Gambit Tutorial Guide

The Clean Journal form includes a Clean Journal option that removes all save commands

from the journal file. For a description of the GAMBIT save command, see Section 5.2 of the GAMBIT Command Reference Guide.

Using the Clean Journal Form

The Clean Journal form (see below) allows you to clean up an existing journal file. To open the Clean Journal form, select Clean Journal from the File menu on the main menu bar.

The Clean Journal form includes the following specifications.

File to Process:

specifies the name of the journal file to be processed in the cleaning operation.

Current Journal

specifies the name of the current, temporary journal file as the file to be processed in the cleaning operation..

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

New File Name:

specifies the name of the cleaned file.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Remove save commands

removes save commands from the cleaned journal file.

Page 377: Gambit Tutorial Guide

4.1.8 View File

When you select View File from the File command menu, GAMBIT opens the View File form. The View File form allows you to view any text file and to copy information from the text file to the GAMBIT Command line or to any open window.

When you first open the View File form, GAMBIT automatically loads the current

transcript (trn) file. The transcript file contains information identical to that displayed in the Transcript window.

To copy information from a text file displayed in the View File form to the Command line or an open window, you must perform the following operations:

• Highlight the text to be copied • Locate the cursor at the text insertion point • Click the middle mouse button

Using the View File Form

The View File form (see below) allows you to view and, optionally, highlight information in any text file. To open the View File form, select View File from the File menu on the main menu bar.

The View File form includes the following specifications.

File Name specifies the name of the file to be loaded into the View File form.

Browse… opens the Select File form, which allows you to browse existing directories

Page 378: Gambit Tutorial Guide

and file lists and to select a file name from the lists. (See "Using the Select File Form," in Section 4.1.2.)

Load loads the text file specified in the File Name text box into the View File form.

4.1.9 Import

The Import command allows you to import geometry and mesh information created external to GAMBIT by means of Import File forms. Import File form layouts differ according to import file type.

When you select Import from the File command menu, GAMBIT opens a submenu of allowable import file types. The submenu includes the following file types:

• ACIS • Parasolid • IGES • STEP • ICEM Input • Vertex Data • CAD • Mesh

ACIS, Parasolid, IGES, STEP, and CAD files describe model geometry. ACIS and Parasolid files are associated with the ACIS and Parasolid geometric modelers, respectively. IGES and STEP are industry standard specifications. (NOTE: GAMBIT does not support all IGES entities -- for example, solids.) CAD files contain faceted representations of geometry generated by CAD programs.

ICEM Input and Vertex Data information consists of points that can be used to describe geometric surfaces. Mesh files include information concerning numbers and coordinates of mesh nodes, element connectivity, and groupings of the exterior sides of the mesh elements that define geometric boundaries to which boundary types, such as INFLOW or WALL, can be attached (see "Importing Mesh Files," below).

The following sections describe the procedures required to import files of the types listed above.

Importing ACIS Files

To import an ACIS file, you must specify the following information:

• Format

Page 379: Gambit Tutorial Guide

• File Name

The format specifies the form of the ACIS file data (ASCII or binary). The file name specifies the name of the ACIS file from which geometry information is to be imported.

Using the Import ACIS File Form

The Import ACIS File form (see below) allows you to import geometry from ACIS files. To open the Import ACIS File form, select Import from the File menu on the main menu bar, and select ACIS from the Import submenu.

The Import ACIS File form includes the following specifications.

Format: -------------------------

ASCII specifies an ASCII format.

Binary specifies a binary format.

File Name: specifies the name of the ACIS file.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Importing Parasolid Files

To import a Parasolid file, you must specify the following information:

• File Name • Import Options

Specifying the File Name

Page 380: Gambit Tutorial Guide

The file name specifies the Parasolid file that contains the information to be imported. GAMBIT allows you to input the file name directly in the File Name text box or to select the file from directories and file lists by means of the Browse command button.

Specifying the Import Options

The Import Options allow you to customize the procedure by which the Parasolid file data are translated to become GAMBIT geometry. The Import Options are as follows:

• Model Scale Factor • Stand-alone Geometry

Specifying the Model Scale Factor

The Model Scale Factor specification allows you to apply a constant scale factor to all dimensions in the imported geometry. Its default value is equal to unity (1.0).

Specifying the Stand-alone Geometry Options

The Stand-alone Geometry options allow you to specify whether or not to retain or delete imported vertices, edges, and/or faces that are not connected to higher topology entities. There are three Stand-alone Geometry options:

• No stand-alone vertices • No stand-alone edges • No stand-alone faces

NOTE: The No stand-alone faces option is available because GAMBIT is capable of importing Parasolid volumes. In practice, however, the option is rarely used.

If you select the No stand-alone option for any geometry type, GAMBIT deletes all imported entities of that type that are not connected to higher topological entities. For example, if you select the No stand-alone vertices option, GAMBIT deletes all vertices that are not connected to edges.

If you do not select the No stand-alone option for a geometry type, GAMBIT includes stand-alone entities of that type in the imported geometry.

Using the Import Parasolid File Form

The Import Parasolid File form (see below) allows you to import geometry from Parasolid files. To open the Import Parasolid File form, select Import from the File menu on the main menu bar, and select Parasolid from the Import submenu.

Page 381: Gambit Tutorial Guide

The Import Parasolid File form includes the following specifications.

File Name: specifies the name of the IGES file containing the geometry to be imported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Import Options: ----------------------------------------------------------------------

Model Scale Factor specifies a scaling factor for imported model geometry.

Stand-alone Geometry

specifies whether or not to retain or delete imported topological entities that are not connected to higher entities.

No stand-alone vertices

(not yet supported in GAMBIT 1.3) deletes vertices that are not connected to any edges.

No stand-alone edges deletes edges that are not connected to any faces.

No stand-alone faces deletes faces that are not connected to any volumes.

Importing IGES Files

To import an IGES file, you must specify the following information:

• File Name

Page 382: Gambit Tutorial Guide

• Import Options • Virtual Cleanup specifications (optional)

Specifying the File Name

The file name specifies the name of the IGES file from which geometry is to be imported. GAMBIT allows you to input the file name directly in the File Name text box or to select the file from directories and file lists by means of the Browse command button.

When you specify the name of an existing IGES file in the File Name text box, GAMBIT displays file summary information in the middle section of the Import IGES File form. The summary information represents information available in the global section of the IGES file and includes the following items:

Item Description

Product ID Name of the software used to create the IGES file

System ID Name of the system upon which the IGES file is created

Model Space Scale Ratio of model space to real space

Date Date of IGES file creation/modification

Time Time of IGES file creation/modification

Distance Tolerance Shortest distance in model space that the IGES file generating system considered coincident

Maximum Coordinate The maximum coordinate in the IGES file

Units Units of distance used in the file.

Specifying the Import Options

The Import Options allow you to customize the procedure by which the IGES file data is translated to become GAMBIT geometry. The Import Options are as follows:

• Translator • Model Scale Factor • Stand-alone Geometry • Import Source

Specifying the Translator

Page 383: Gambit Tutorial Guide

The Translator options allow you to specify which translator to use when importing IGES files into GAMBIT. The Translator options are as follows:

• Native • Spatial

The Native option specifies the use of an IGES translator specifically designed for use with GAMBIT. The Native translator is capable of producing virtual geometry in the course of the data import process.

The Spatial option specifies the use of a generic translator developed by Spatial Technology, Inc.. The Spatial translator produces only real geometry.

Specifying the Model Scale Factor

The Model Scale Factor specification allows you to apply a constant scale factor to all dimensions in the imported geometry. Its default value is equal to the reciprocal of the Model Space Scale (see above).

NOTE: GAMBIT geometry operations may fail if the model dimensions are too large or too small relative to the GAMBIT global tolerance value. The GAMBIT global tolerance

value is 10−6. To insure that GAMBIT geometry operations correctly handle imported IGES geometry, specify a Model Space Scale factor that enlarges or reduces the imported

geometry such that its coordinate values are in the range of 10−5 to 104.

Often, the system that generates the IGES file incorrectly reports the maximum coordinate value. It is important, therefore, to read and verify geometry values before applying the Model Space Scale factor.

Specifying the Stand-alone Geometry

The Stand-alone Geometry options allow you to specify whether or not to retain or delete imported vertices, edges, and/or faces that are not connected to higher topology entities. There are three Stand-alone Geometry options:

• No stand-alone vertices • No stand-alone edges • No stand-alone faces

NOTE: The No stand-alone faces option is available because GAMBIT is capable of importing IGES volumes. In practice, however, the option is rarely used.

If you select the No stand-alone option for any geometry type, GAMBIT deletes all imported entities of that type that are not connected to higher topological entities. For example, if you select the No stand-alone vertices option, GAMBIT deletes all vertices that are not connected to edges.

Page 384: Gambit Tutorial Guide

If you do not select the No stand-alone option for a geometry type, GAMBIT includes stand-alone entities of that type in the imported geometry.

Specifying the Import Source

The Import Source options allow you to specify the program used to generate the IGES file that contains the data to be imported. The Import Source options are as follows:

• Generic • AutoCAD • SolidWorks

Specifying the Virtual Cleanup Specifications

When you select the Virtual Cleanup option, GAMBIT automatically cleans up geometry as it is imported. Such cleanup operations include connecting disconnected vertices and edges and merging very-short edges with longer adjacent edges in order to facilitate meshing.

NOTE: You can use the Virtual Cleanup option on the Import IGES File form to automatically cleanup geometry that has already been imported into GAMBIT. To do so:

1. Open the Import IGES File form. 2. Select the Virtual Cleanup option and input appropriate values for the Connect

Tolerance and Merge Tolerance specifications (see below). 3. Ensure that the File Name text field is blank. 4. Click Apply.

The Virtual Cleanup option includes two main specifications:

• Connect Tolerance • Merge Tolerance

The Connect Tolerance specifies the maximum allowable distance between geometric entities to be connected (see Section 2.3.2 of the GAMBIT Modeling Guide). You can specify the tolerance either in terms of absolute distance (Value) or as a percentage of the length of the shortest edge in the model (Shortest Edge %).

The Merge Tolerance specifies the maximum length of any edge to be considered as a candidate for merging in the cleanup process (see Section 2.3.5 of the GAMBIT Modeling guide).

Using the Import IGES File Form

Page 385: Gambit Tutorial Guide

The Import IGES File form (see below) allows you to import geometry from IGES files. To open the Import IGES File form, select Import from the File menu on the main menu bar, and select IGES from the Import submenu.

The Import IGES File form includes the following specifications.

File Name: specifies the name of the IGES file containing the geometry to be imported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Summary: contains a summary of IGES global file information (see above).

Page 386: Gambit Tutorial Guide

Import Options: ------------------------

Translator specifies the translator used in the import process.

Native specifies an IGES translator specifically designed for use with GAMBIT

Spatial specifies an IGES translator designed by Spatial Technology, Inc.

Model Scale Factor specifies a scaling factor for imported model geometry.

Stand-alone Geometry

specifies whether or not to retain or delete imported topological entities that are not connected to higher entities.

No stand-alone vertices

deletes vertices that are not connected to any edges.

No stand-alone edges deletes edges that are not connected to any faces.

No stand-alone faces deletes faces that are not connected to any volumes.

Import Source: --------------------------------------------

Generic AutoCAD SolidWorks

specifies the program used to create the IGES file.

Virtual Cleanup specifies the automation of GAMBIT cleanup operations for the imported geometry.

Connect Tolerance specifies the maximum allowable distance between geometric entities to be connected. The distance must be input as either a real value (Value) or a percentage of the length of the shortest edge in the model (Shortest Edge %).

Merge Tolerance specifies the maximum length of any edge considered a candidate for merging in the cleanup process.

Importing STEP Files

To import a STEP file, you must specify the following information:

• File Name • Stand-alone Geometry options

Page 387: Gambit Tutorial Guide

Specifying the File Name

The File Name specifies the STEP file that contains the information to be imported. GAMBIT allows you to input the file name directly in the File Name text box or to select the file from directories and file lists by means of the Browse command button.

Specifying the Stand-alone Geometry Options

The Stand-alone Geometry options allow you to specify whether or not to retain or delete imported vertices, edges, and/or faces that are not connected to higher topology entities. There are three Stand-alone Geometry options:

• No stand-alone vertices (not yet supported in GAMBIT 1.3) • No stand-alone edges • No stand-alone faces

If you select the No stand-alone option for any geometry type, GAMBIT deletes all imported entities of that type that are not connected to higher topological entities. For example, if you select the No stand-alone vertices option, GAMBIT deletes all vertices that are not connected to edges.

If you do not select the No stand-alone option for a geometry type, GAMBIT includes stand-alone entities of that type in the imported geometry.

Using the Import STEP File Form

The Import STEP File form (see below) allows you to import geometry from STEP files. To open the Import STEP File form, select Import from the File menu on the main menu bar, and select STEP from the Import submenu.

The Import STEP File form includes the following specifications.

File Name: specifies the name of the IGES file containing the geometry to be imported.

Page 388: Gambit Tutorial Guide

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Stand-alone Geometry

specifies whether or not to retain or delete imported topological entities that are not connected to higher entities.

No stand-alone vertices

(not yet supported in GAMBIT 1.3) deletes vertices that are not connected to any edges.

No stand-alone edges deletes edges that are not connected to any faces.

No stand-alone faces deletes faces that are not connected to any volumes.

Importing ICEM Input Files

ICEM data consists of sets of coordinates that define points in space. When you import an ICEM input file into GAMBIT, you can either convert the spatial points directly to vertices or allow GAMBIT to create a set of edges or a face described by the positions of the points. To import an ICEM input file, you must specify the following information:

• File Name • Import Options

Specifying the File Name

The File Name specifies the ICEM input file that contains the information to be imported. GAMBIT allows you to input the file name directly in the File Name text box or to select the file from directories and file lists by means of the Browse command button.

Specifying the Import Options

The Import Options options allow you to specify the type of geometry created ruing the import operation and the allowable distance between the created geometry and the original data points. There are two Import Options:

• Tolerance • Geometry to Create

Specifying the Tolerance

The Tolerance value specifies the maximum allowable distance between the created GAMBIT geometry and the original ICEM input data points used to describe the geometry.

Page 389: Gambit Tutorial Guide

Specifying the Geometry to Create

The Geometry to Create optiosn allow you to specify whether GAMBIT creates vertices, edges, or a face from the imported data. If you specify the creation of a face, you must also specify the manner in which the original data is interpreted in the face creation procedure.

The Geometry to Create options are as follows:

• Vertices -- converts all poitns in the ICEM input file to vertices • Edges -- converts each row of points in the ICEM file into an edge • Face -- converts the ICEM input file points into a face.

As noted above, if you select the Face option, you must specify the method by which the ICEM point data is converted to a GAMBIT face. GAMBIT provides four face-creation options:

• Net surface -- creates a network of edges from the rows and columns of the ICEM data and fits the face to the network

• Vertex rows -- shapes the created face by fitting a surface to the imported points • Skin surface (rows) -- creates an edge from each row in the ICEM data file and fits

the face to the network of created edges • Skin surface (columns) -- creates an edge from each column of the ICEM data file

and fits the face to the network of created edges

Using the Import ICEM Input File Form

The Import ICEM Input File form (see below) allows you to import geometry from ICEM input files. To open the Import ICEM Input File form, select Import from the File menu on the main menu bar, and select ICEM Input from the Import submenu.

Page 390: Gambit Tutorial Guide

The Import ICEM Input File form includes the following specifications.

File Name: specifies the name of the file containing the data to be imported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Import Options: ----------------------------------------------------------------------

Tolerance specifies the maximum distance between the created GAMBIT geometry and the original data point locations.

Geometry to Create: ----------------------------------------------------------------------

Vertices creates vertices from the ICEM data.

Edges creates edges from the ICEM data.

Faces creates a face from the ICEM data.

Net surface creates a network of edges from the row and column data and fits a face to the network.

Page 391: Gambit Tutorial Guide

Vertex rows shapes the face by fitting a surface to the data points.

Skin surface (rows) creates an edge from each row in the data file and fits the face to the network of created edges.

Skin surface (columns)

creates an edge from each column in the data file and fits the face to the network of created edges.

Importing Vertex Data Files

Vertex data files contain sets of coordinates that represent vertices. To import a vertex data file, you must specify the File Name of the file to be imported.

Using the Import Vertex Data File Form

The Import Vertex Data File form (see below) allows you to import geometry from vertex data files. To open the Import Vertex Data File form, select Import from the File menu on the main menu bar, and select Vertex Data from the Import submenu.

The Import Vertex Data File form includes the following specifications.

File Name: specifies the name of the file containing the data to be imported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Importing CAD Files

To import a CAD file, you must specify the following information:

• CAD System • File Name

The CAD System specifies the name of the CAD program used to generate the file. GAMBIT supports the importation of geometry from any of three CAD programs: Pro/ENGINEER, OPTEGRA Visualizer, and I-DEAS.

Page 392: Gambit Tutorial Guide

NOTE: When you specify the Pro/ENGINEER option on the Import CAD form (see below), GAMBIT runs Pro/ENGINEER in the background to create a STEP file, then reads the STEP file to produce the GAMBIT geometry. Consequently, you must have a valid Pro/ENGINEER license in order to use the Pro/ENGINEER option.

The File Name specifies the name of the file that contains the information to be imported.

Using the Import CAD Form

The Import CAD form (see below) allows you to import faceted geometry contained in CAD files. To open the Import CAD form, select Import from the File menu on the main menu bar, and select CAD from the Import submenu.

The Import CAD form includes the following specifications.

CAD System:

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

Pro/ENGINEER OPTEGRA VISUALIZER I-DEAS FTL

specifies the CAD program used to generate the geometry to be imported. GAMBIT supports the importation of faceted geometry from any of the following CAD programs:

• Pro/ENGINEER • OPTEGRA VISUALIZER • I-DEAS

File Name: specifies the name of the file that contains the geometry to be imported.

NOTE: The I-DEAS FTL option specifies the importation of I-DEAS faceted geometry; not I-DEAS mesh information. To import I-DEAS mesh information, use the File/Import/Mesh option (see "Importing Mesh Files," below).

Browse… opens the Select File form (see "Using the Select File Form" in Section 4.1.2).

Page 393: Gambit Tutorial Guide

Importing Mesh Files

To import a mesh file, you must specify the following information:

• Type • Dimension • Feature Angle (3-D geometry only) • Merge Tolerance • Scale • File Name

The Type and Dimension specifications define the format of the mesh data to be imported. The Feature Angle defines the angle criterion that determines where to create topological edges for an imported three-dimensional mesh. The Merge Tolerance (which is not available for all types of imported meshes) determines which pairs (or sets) of imported nodes are merged in the importation process. The Scale specification scales the dimensions of the model relative to its original size. The File Name constitutes the name of the file to be imported.

Specifying the Type

GAMBIT allows you to import mesh information in the following formats.

• FIDAP • GAMBIT • I-DEAS UNV • ANSYS • NASTRAN • PATRAN • PLOT3D FORMATTED • FLUENT4 • FLUENT5 • TGRID • STL • HYPERMESH

NOTE: STL files constitute collections of unconnected triangular facets that describe the exterior of model geometry. When you import an STL file, GAMBIT automatically translates the STL-file facet information into topological entities, faces, and volumes. For a description of the format of the mesh information associated with each of the other options listed above, consult the appropriate user documentation.

Specifying the Dimension

If you specify the I-DEAS UNV, ANSYS, NASTRAN, or PATRAN Type options, you must also specify the imported mesh Dimension. The Dimension options are as follows.

Page 394: Gambit Tutorial Guide

• 2 D -- planar surface mesh • 3 D -- volume mesh • Surface -- surface mesh in 3-D space

Specifying the Feature Angle

When you import a mesh file, GAMBIT automatically creates geometry based on the mesh information in the file. If you import a two-dimensional mesh, GAMBIT creates model edges at the outer boundaries of the mesh. If you import a three-dimensional mesh, GAMBIT creates faces at the outer boundaries of the mesh and creates edges, as necessary, based, in part, on the angle between adjacent mesh element faces.

The Feature Angle specification on the Import Mesh form constitutes the criterion that GAMBIT employs to determine which mesh edges to convert to topological edges.

Specifically, the Feature Angle represents a minimum value of the parameter in the expression

where is the angle (in degrees) between adjacent mesh element faces along a common mesh element edge (see Figure 4-1).

Figure 4-1: Mesh element faces, Feature Angle specification

If is greater than the Feature Angle, GAMBIT creates a topological edge at the mesh

edge that is common to the two mesh element faces. If is less than the Feature Angle, GAMBIT does not include the common mesh element edge as part of a geometric edge based on the angle criterion. (NOTE: Other geometry edges and faces are created based on element connectivity and element group information that is contained in the mesh file.)

Page 395: Gambit Tutorial Guide

NOTE (1): If you specify a Feature Angle value of zero, GAMBIT creates faces and volumes based only on boundary and continuum zones information that exists in the imported mesh file.

NOTE (2): You can create and modify geometry based on an imported mesh by means of the Modify Meshed Geometry form (see "Using the Modify Meshed Geometry Form" in the GAMBIT Modeling Guide, Sections 3.3.7 and 3.4.5)

Specifying the Merge Tolerance

The Merge Tolerance value specifies the maximum distance between merge-able nodes in the imported mesh. For example, if two nodes are separated by a distance of 5.0(10-7) and the Merge Tolerance is set at 10-6, then the nodes are merged to become a single node in the imported mesh.

Specifying the Scale Factor

The Scale enlarges or reduces the imported mesh by a factor x , where x is the specified Scale value on the Import Mesh form.

Using the Import Mesh Form

The Import Mesh form (see below) allows you to import mesh information from mesh files. To open the Import Mesh form, select Import from the File menu on the main menu bar, and select Mesh from the Import submenu.

The Import Mesh form includes the following specifications.

Page 396: Gambit Tutorial Guide

Type: -------------------------

FIDAP GAMBIT I-DEAS UNV ANSYS NASTRAN PATRAN PLOT3D FORMATTED FLUENT4 FLUENT5 TGRID STL HYPERMESH

specifies the output format for the mesh information.

Dimension: -------------------------

2 D 3 D Surface

specifies the dimension for I-DEAS UNV, ANSYS, NASTRAN and PATRAN files.

Feature Angle specifies the minimum value of that GAMBIT employs to determine which mesh edges are converted to model edges.

Merge Tolerance specifies the maximum distance between nodes that are to be merged in the mesh import process.

Scale specifies the factor by which the mesh is enlarged or reduced in the mesh import process.

File Name: specifies the name of the file containing the mesh and boundary attribute information to be imported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

4.1.10 Export

When you select Export from the File menu, GAMBIT opens a submenu of file export options. The submenu includes the following options:

• ACIS

Page 397: Gambit Tutorial Guide

• Parasolid • IGES • STEP • Mesh

The ACIS, Parasolid, IGES, and STEP options export model geometry in the format of the ACIS or Parasolid modelers or IGES or STEP standards, respectively. The Mesh option exports mesh information in a format appropriate to the currently selected solver.

Exporting ACIS Files

To export geometry information in an ACIS format, you must specify the following parameters.

Parameter Description

Format Specifies the form in which the data is stored in the ACIS file (ASCII or Binary)

Version Specifies the ACIS version with which the exported geometry is compatible

Method Determines whether or not GAMBIT includes sequence numbers when it exports an ASCII version of the ACIS file

(NOTE: For a description of the form and purpose of ACIS-file sequence numbers, refer to ACIS documentation.)

File Name Specifies the name of the export file

Using the Export ACIS File Form

The Export ACIS File form (see below) allows you to export model geometry information in ACIS format. To open the Export ACIS File form, select Export from the File menu on the main menu bar, and select ACIS from the Export submenu.

Page 398: Gambit Tutorial Guide

The Export ACIS File form includes the following specifications.

Format: -------------------------

ASCII specifies that the ACIS file is written in an ASCII format.

Binary specifies that the ACIS file is written in a binary format.

Version: contains an option button that allows you to specify the ACIS code version with which the exported geometry is compatible.

Method: (ASCII format only)

Sequencing specifies that sequence numbers are included in the exported ACIS file.

No Sequencing specifies that sequence numbers are not included in the exported ACIS file.

File Name: specifies the name of the file to which the ACIS geometry information is exported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Exporting Parasolid Files

To export geometry information in a Parasolid format, you must specify the following parameters.

Parameter Description

Page 399: Gambit Tutorial Guide

Format Specifies the form in which the data is stored in the Parasolid file (Text or Binary)

Version Specifies the Parasolid version with which the exported geometry is compatible

File Name Specifies the name of the export file

Using the Export Parasolid File Form

The Export Parasolid File form (see below) allows you to export model geometry information in Parasolid format. To open the Export Parasolid File form, select Export from the File menu on the main menu bar, and select Parasolid from the Export submenu.

The Export Parasolid File form includes the following specifications.

Format: -------------------------

Text specifies that the Parasolid file is written in a text format.

Binary specifies that the Parasolid file is written in a binary format.

Version: contains an option button that allows you to specify the Parasolid code version with which the exported geometry is compatible.

File Name: specifies the name of the file to which the geometry information is exported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Page 400: Gambit Tutorial Guide

Exporting IGES Files

To export geometry information in an IGES format, you must specify the File Name and the status of the Write MSBO solids option. If you select the Write MSBO solids option, GAMBIT creates manifold solid B-rep objects (MSBOs) when exporting the IGES data.

Using the Export IGES File Form

The Export IGES File form (see below) allows you to export model geometry information in IGES format. To open the Export IGES File form, select Export from the File menu on the main menu bar, and select IGES from the Export submenu.

The Export IGES File form includes the following specifications.

File Name: specifies the name of the file to which the geometry information is exported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Write MSBO solids

creates manifold solid B-rep objects when exporting the IGES data.

Exporting STEP Files

To export geometry information in a STEP format, you must specify the File Name for the file to which the data is to be exported.

Using the Export STEP File Form

The Export STEP File form (see below) allows you to export model geometry information in STEP format. To open the Export STEP File form, select Export from the File menu on the main menu bar, and select STEP from the Export submenu.

Page 401: Gambit Tutorial Guide

The Export STEP File form includes the following specifications.

File Name: specifies the name of the file to which the geometry information is exported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Exporting Mesh Files

When you select Export from the File menu and select Mesh from the Export submenu, GAMBIT opens the Export Mesh Files form. The Export Mesh Files form allows you to export GAMBIT mesh, boundary-type, and continuum-type information in a format appropriate to the currently selected solver.

The following table lists the available GAMBIT mesh export file formats, their associated file extensions, and the solvers to which they correspond.

Format Extension Solver(s)

FIDAP Neutral FDNEUT FIDAP

UNS / RAMPANT/ FLUENT 5 msh FLUENT/UNS RAMPANT FLUENT 5

Structured FLUENT 4 Grid GRD FLUENT 4

NEKTON msh NEKTON

ANSYS cdb ANSYS

Generic Neutral neu POLYFLOW Generic

Each format differs from the others with respect to two characteristics:

Page 402: Gambit Tutorial Guide

• Organization of its mesh information • Types of allowable boundary attributes

Both characteristics are directly related to those of the currently active solver; therefore, to change the format of the exported file, you must first change the solver specification. For a description of the solver specifications available in GAMBIT, see Section 4.3.

Using the Export Mesh File Form

The Export Mesh File form (see below) allows you to export mesh information. To open the Export Mesh File form, select Export from the File menu on the main menu bar, and select Mesh from the Export submenu.

The Export Mesh File form includes the following specifications.

File Type: displays the export file format. To change the export file type, you must change the solver specification (see Section 4.3).

File Name: specifies the name of the file to which the mesh and boundary attribute information is exported.

Browse… opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

4.1.11 Exit

The Exit command allows you to stop program execution. To exit the GAMBIT program, select Exit from the File menu on the main menu bar. If you have changed the model since the time it was last saved, GAMBIT prompts you to save the model before exiting the program (see below).

Page 403: Gambit Tutorial Guide

© Fluent, Inc. 05/01/00

Page 404: Gambit Tutorial Guide

4.2 Edit Commands

The GAMBIT Edit command menu includes the following commands.

Command Description

Title Edits the current session title

File Launches a local text editor

Parameters Creates and specifies GAMBIT parameters

Defaults Edits GAMBIT program default values

Undo Undoes the most recently executed GAMBIT operation (NOTE: This command is also available on the Global Control toolpad (see "Undo" in Section 3.4.2 of this guide).)

Redo Re-executes the most recently undone GAMBIT operation (NOTE: This command is also available on the Global Control toolpad (see "Redo" in Section 3.4.2 of this guide).)

4.2.1 Title

When you select Title from the Edit command menu, GAMBIT opens the Edit Session Title form. The Edit Session Title form allows you to edit the current session title. The title for any GAMBIT session can consist of any combination of up to 80 alphanumeric characters.

Using the Edit Session Title Form

The Edit Session Title form (see below) allows you to edit the current session title. To open the Edit Session Title form, select Title from the Edit menu on the main menu bar.

Page 405: Gambit Tutorial Guide

The Edit Session Title form includes the following specifications.

Title: specifies the title of the current session.

4.2.2 File

When you select File from the Edit command menu, GAMBIT opens the Edit File form. The Edit File form allows you to edit any text file by means of a text editor external to GAMBIT.

To edit a text file by means of the Edit File form, you must specify the following parameters.

Parameter Description

File Name Name of the text file to be edited

Editor Name Name of the editor to be used in editing the text file

Editor Options Editor command options

Editor Command Form of command to launch the editor

The Editor Name, Editor Options, and Editor Command specifications vary according to the editor used to edit the text file and the operating system under which GAMBIT and the editor run. To modify the default values for the editor options, select Defaults from the Edit menu on the main menu bar (see Section 4.2.4).

Using the Edit File Form

The Edit File form (see below) allows you to edit text files using an editor external to GAMBIT. To open the Edit File form, select File from the Edit menu on the main menu bar.

Page 406: Gambit Tutorial Guide

The Edit File form includes the following specifications.

File Name specifies the name of the text file to be edited.

Browse... opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2).

Editor Name specifies the editor to be used to edit the specified file.

Editor Options specifies options for the editor.

Editor Command:

specifies the system commands required to launch the editor. (NOTE:

The parameters %e, %o, and %f represent the editor name and options and the name of the file to be edited, respectively.)

4.2.3 Parameters

Using Parameters

GAMBIT parameters constitute numeric or string constants that you can use in any modeling or meshing operation in lieu of actual numeric or string input. For example, if you define a numeric scalar parameter with a value of 6.257, you can input that parameter in the Radius text box on the Create Real Sphere form to create sphere of radius 6.257.

NOTE (1): You can use parameters in any GAMBIT operation that is executed from the Command line or from within a journal file, however you cannot use parameters to execute GAMBIT operations by means of GAMBIT GUI specification forms.

NOTE (2): To display a list of currently defined parameters, execute the following Command-line command:

Page 407: Gambit Tutorial Guide

parameter list .

When you execute the parameter list command, GAMBIT displays all currently defined parameters and their associated values in the Transcript window.

There are two methods of defining or updating any GAMBIT parameter:

• Edit Parameters form specifications • Parameter commands

The following sections describe the procedures and specifications associated with each of the methods listed above.

Edit Parameters Form Specifications

When you select the Parameters option on the Edit menu, GAMBIT opens the Edit Parameters form. The Edit Parameters form contains a list box and an input field. The list box displays all currently defined parameters. The input field contains text boxes, option buttons, and command buttons that allow you to define new parameters or to update existing parameters.

To define a new parameter, input the parameter specifications and click the Add command button. To update an existing parameter, highlight its name in the parameter list at the top of the form, then change the parameter specifications by means of the input options and click the Update command button.

Specifying Parameters

To define or update any GAMBIT parameter, you must specify the following information:

• Name • Type • Form • Value(s)

Name

The parameter Name constitutes the character string by which the parameter is referenced in GAMBIT operations. You can specify any combination of alphanumeric characters and symbols (excluding spaces) as the parameter name as long as the combination represents a valid name for the operating system under which GAMBIT is running.

To reference a parameter in any GAMBIT operation, you must precede the parameter

name with a dollar-sign symbol-that is, "$". For example, if you define a numeric scalar

Page 408: Gambit Tutorial Guide

parameter named "R1" and use the parameter to specify the radius of a sphere, the Command line (or journal) command must adhere to the following syntax:

volume create sphere radius $R1 .

GAMBIT provides a number of predefined constants and functions that can be used in conjunction with or in the definition of parameters. Appendix B of this guide describes all such constants and functions available in GAMBIT.

NOTE: All arithmetic expressions that involve the definition or use of parameters must be enclosed in parentheses. For example, to create a sphere the radius of which is twice

the value of the parameter $R1, you must execute the following command:

volume create sphere radius ($R1*2)

Type

The parameter Type determines the general characteristic of the parameter value. There are three types of GAMBIT parameters:

• Numeric • String • Untyped

Numeric parameters represent numerical values. String parameters represent strings of alphanumeric characters and/or symbols. Untyped parameters may constitute either numbers or characters.

Form

The parameter Form defines whether the parameter constitutes an individual value or as a set of values. There are two forms of GAMBIT parameters:

• Scalar • Array

Scalar parameters represent individual values. Array parameters represent sets of values.

Value

Parameter Value specifications differ according to parameter Form. Scalar parameters each represent a single value. Array parameters are associated with sets of values any one of which can be referenced by a GAMBIT operation. The following sections describe the procedures required to specify the values of scalar and array parameters.

Page 409: Gambit Tutorial Guide

NOTE: GAMBIT provides a number of predefined constants and functions that can be used in the definition of parameters. Appendix B of this guide describes all such constants and functions available in GAMBIT.

Specifying a Scalar Parameter Value

To define the value of a scalar parameter, specify its numeric or string value in the Value text box on the Edit Parameters form.

Specifying Array Parameter Values

To define the values associated with an array parameter, you must specify two types of information:

• Indices • Values

Indices define the dimensions of the array associated with the parameter. The values specifications constitute the individual values associated with each element of the array.

Specifying Array Parameter Indices

When you define an array parameter, you must specify the dimensions of the array. To specify the dimensions of an array, you must specify its indices. Each individual index specification consists of the following two components:

• Starting point • Range

The starting point determines the first number used in the numbering of the array dimension. The range determines the total number of elements associated with the

dimension. For example, if you specify a one-dimensional array parameter named "x" such that it possesses a starting point of 0 and a range of 3, GAMBIT defines the

parameter x as a 1 3 array with array elements x(0), x(1), and x(2).

There are two ways of defining the starting points and ranges for any parameter:

• Input the array dimensions in the Index Declaration text box • Declare the dimensions by means of the Define Array Indices form

Index Declaration Text Box

When you specify starting points and ranges by means of the Index Declaration text box, you must conform to the following input convention:

[ : , : ,...]

Page 410: Gambit Tutorial Guide

where and represent the starting point and range, respectively, for the first array

index, and and represent the starting point and range for the second array index. For

example, if you specify the dimensions of a parameter named "$radius" as follows:

[0:2,3:3]

GAMBIT defines $radius such that it contains the following elements:

$radius[0,3] $radius[0,4] $radius[0,5] $radius[1,3] $radius[1,4] $radius[1,5]

Define Array Indices Form

For a description of the procedures required to specify array dimensions by means of the Define Array Indices form, see "Using the Define Array Indices Form," below.

Specifying Array Parameter Values

To specify a set of values for an array parameter, you must perform the following operations:

1. Define the parameter. 2. Highlight (left-click) its name in the parameter list box. 3. Click the Values command button

When you click the Values command button, GAMBIT opens the Define Array Values form. For a description of the procedures required to specify array parameter values by means of the Define Array Values form, see "Using the Define Array Values Form," below.

NOTE: The Values command button appears in the input field of the Edit Parameters form when you highlight an array parameter in the list box.

Using the Edit Parameters Form

The Edit Parameters form allows you to define and update GAMBIT parameters. To open the Edit Parameters form (see below), select Parameters from the Edit menu on the main menu bar.

Page 411: Gambit Tutorial Guide

The Edit Parameters form consists of two components:

• List box • Input field

List Box

The list box displays information that describes all currently defined parameters. It contains the following information for each parameter:

• Name • Type • Form

• Value (scalar parameters only)

• Index Declaration (array parameters only)

Input Field

The input field on the Edit Parameters form includes the following specifications.

Name: specifies the parameter name.

Type: -------------------------

Numeric String Untyped

specifies the parameter type.

Page 412: Gambit Tutorial Guide

Form: -------------------------

Scalar Array

specifies the parameter form.

Specifying Scalar Parameters

Value specifies the parameter value.

Specifying Array Parameters

When you select the Form:Array option, the input field on the Edit Parameters form appears as shown below.

The input field includes the following fields and options.

Index Declaration

specifies the array dimensions.

Indices opens the Define Array Indices form.

Values opens the Define Array Values form.

General Operations

Add defines a new parameter according to the current specifications and displays the parameter in the parameter list box.

Update modifies the currently highlighted parameter according to the current specifications.

Delete deletes the currently highlighted parameter.

Close closes the Edit Parameters form.

Print prints the list of current parameter definitions.

Page 413: Gambit Tutorial Guide

Using the Define Array Indices Form

The Define Array Indices form allows you to specify the starting point and range of an array parameter. To open the Define Array Indices form (see below), click the Indices command button on the Edit Parameters form.

The Define Array Indices form consists of two columns of text boxes labeled Start and Range. The values in the Start and Range columns for any row define the starting point and range for the corresponding dimension (Dim #).

The Define Array Indices form includes the following specifications:

Array Parameter:

displays the name of the array parameter for which the displayed Start and Range value are defined.

Dim # (column) specifies dimension numbers.

Page 414: Gambit Tutorial Guide

Start specifies array dimension starting points (see above).

Range specifies array dimension ranges (see above).

Reset resets the Define Array Indices form fields to their previous values.

Using the Define Array Values Form

The Define Array Values form allows you to specify the values corresponding to the elements of an array parameter. To open the Define Array Values form (see below), highlight an array parameter in the parameter list on the Edit Parameters form and click the Values command button.

Page 415: Gambit Tutorial Guide

The Define Array Values form consists of two columns labeled Index and Value and an input field in the lower section of the form. To specify or modify the value for any element, highlight the corresponding entry in the Value list, then input its value in the Value text box and press Enter.

The Define Array Values form includes the following specifications:

Array Name:

displays the name of the array parameter for which the displayed values are defined.

Index (column) displays the dimension numbers corresponding to each array element.

Value (column) displays the currently defined array element values.

Modify item:

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

Index: displays the index number of the currently highlighted array element.

Value specifies the value for the currently highlighted array element.

Accept defines the array values as currently displayed.

Parameter Commands

To define or update a parameter by means of the Command-line command or from with a journal file, you must execute a command of the following general form:

$p = x

where p and x represent the name and value, respectively, of the parameter. For example,

to define a parameter named "length" as a numerical parameter with a value of 5.33, you must execute the following command:

$length = 5.33

Similarly, to define a string parameter named "comp_name" with the value of "pipe07", you must execute the following command: $comp_name = "pipe"

Assigning the Parameter Type

GAMBIT automatically assigns a parameter type that corresponds to the value of x. For

instance, in the examples described above, GAMBIT defines $length and $comp_name as numeric and string parameters, respectively.

Page 416: Gambit Tutorial Guide

Defining Array Parameters

To define an array parameter by means of a Command-line parameter command or from within a journal file, you must first declare the array. The array-declaration command is of the following form:

declare $p[{n}:m]

where,

• p is the name of the parameter

• n is the starting index (default = 1) of the dimension • m is the range of the dimension

(NOTE: The square brackets ([]) are part of the required syntax; the other brackets indicate that the variable n is optional.)

For example, if you execute the following command:

declare $pipelength[4]

GAMBIT creates a one-dimensional array named "pipelength" that contains the following four elements:

• $pipelength[1] • $pipelength[2] • $pipelength[3]

• $pipelength[4] .

Similarly, if you execute the following command:

declare $duct[0:2]

GAMBIT creates a one-dimensional array named "duct" that contains two elements:

• $duct[0]

• $duct[1] .

Finally, if you execute the following command:

declare $radius[0:2,3:3]

GAMBIT defines an array named "$radius" such that it contains the following elements: $radius[0,3] $radius[0,4] $radius[0,5] $radius[1,3] $radius[1,4] $radius[1,5]

4.2.4 Defaults

Page 417: Gambit Tutorial Guide

When you select Defaults from the Edit command menu, GAMBIT opens the Edit Defaults form. The Edit Defaults form allows you to modify GAMBIT program defaults-such as entity colors, mesh schemes and parameters, and working directories. The form also allows you to load, customize, and save default settings.

Using the Edit Defaults Form

The Edit Defaults form (see below) allows you to modify default values for GAMBIT program variables and to load and save initialization files. To open the Edit Defaults form, select Defaults from the Edit menu on the main menu bar.

Page 418: Gambit Tutorial Guide

The Edit Defaults form consists of the following types of components:

• Default definition subforms • File command buttons

Default definition subforms allow you to view and modify default settings for specific categories of GAMBIT program variables. The file command buttons and text boxes on

Page 419: Gambit Tutorial Guide

the Edit Defaults form allow you to load, save, and/or print initialization (.ini) files that contain program variable default settings.

The following sections describe the specifications and procedures associated with each of the two component types listed above.

Default Definition Subforms

The following summarizes each of the default definition subforms that are included in the Edit Defaults form.

Subform Title Description

COORDINATES • Coordinate-system type • Ruler and grid parameters

DEBUG • Programming debug flags

FILE_IO • Boundary and continuum type labels • FIDAP and UNS defaults • IGES import options

GEOMETRY • Entity colors • Face-merging criteria

GLOBAL • File and directory locations • Memory allocation • Maximum Undo levels • Solver

GRAPHICS • Graphics display colors and options • Mouse button mode

LABEL • Automatic labels for real, virtual, and faceted entities

MESH • Mesh colors, schemes, and parameters • Mesh element types

Page 420: Gambit Tutorial Guide

SASH • GUI and graphics window sash locations

CAD • Pro/ENGINEEER startup command

To display a specific default definition subform, click the corresponding tab on the Edit Defaults form. For example, to display the COORDINATES default definition subform shown above, click the COORDINATES tab on the Edit Defaults form.

Each default definition subform contains the following components:

• Field of radio buttons • Scroll list • Edit command buttons and text boxes

The following sections describe each of the components listed above.

Radio Buttons

Each default definition subform contains a field of one or more radio buttons. Each radio button is associated with a specific subset of GAMBIT program variables. For example, the COORDINATES default definition subform contains the following radio buttons:

• GENERAL • ARROW • RULER • GRID

To access the defaults that are associated with any of the radio buttons listed on a default definition subform, click the radio button.

NOTE: If the number of radio buttons corresponding to any default definition subform exceeds the maximum number displayable on the form, GAMBIT displays horizontal and vertical scroll bars in the upper portion of the form. To view the hidden radio buttons, either resize the form or use the scroll bars to display the portion of the radio button field that contains the hidden buttons.

Scroll List

When you click any of the radio buttons, GAMBIT displays a scroll list that contains the corresponding subset of program variables. For example, if you click the GENERAL radio button on the COORDINATES default definition subform, GAMBIT displays the following variables in the scroll list:

Page 421: Gambit Tutorial Guide

• TYPE • GRID_MODE

The default definition form scroll list contains the following three columns:

• Variable • Value • Description

The Variable column includes the names of all variables in the current subset. The

Value column contains the current setting for each variable listed. The Description column contains a description of each variable and/or default value and a list of available options.

Edit Command Buttons and Text Boxes

When you highlight (left-click) any program variable displayed in the scroll list, GAMBIT displays its name and current value in the text boxes located at the bottom of the default definition subform. To modify the value of the currently highlighted program variable, input the new value in the Value text box and click Modify. To reset the program variable to its default value, click Reset.

File Commands

The bottom section of the Edit Defaults form contains file command buttons and text boxes that allow you to load, save, and print GAMBIT initialization files. The file command section includes the following options.

Load loads the initialization file that is currently specified in adjacent text box.

Load specifies the name of the initialization file to be loaded.

NOTE: During the program startup procedure GAMBIT, automatically loads the initialization file

$HOME/GAMBIT.ini

if it exists.

Browse ... opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Save saves current program variable values to the initialization file specifiedsaving program defaults in the adjacent text box.

Page 422: Gambit Tutorial Guide

Save specifies the name of the initialization file to be saved.

NOTE: If the file name specified in the Save text box corresponds to the name of an existing file, GAMBIT prompts you to confirm that you want to overwrite the existing file. If you do not want to overwrite the existing file, specify a new name in the Save text box.

Browse... opens the Select File form, which allows you to browse existing directories and file lists and to select a file name from the lists. (See "Using the Select File Form" in Section 4.1.2.)

Close closes the Edit Defaults session and saves current values.

Print prints the current program variable default values to the default printer.

© Fluent, Inc. 05/30/00

4.4 Help Menu

The Help command allows you to access online documentation by means of the local web browser and to display information on the current version of the program. When you click Help on the menu bar, GAMBIT opens the Help command menu. The Help command menu includes the following options:

• Quick • Table of Contents • About

The Quick option accesses context-sensitive online help. The Table of Contents option allows you to browse the entire suite of GAMBIT documentation by means of a hyperlinked table of contents. The About option displays information regarding the currently running version of GAMBIT.

4.4.1 Quick

Page 423: Gambit Tutorial Guide

When you select Quick from the Help menu, GAMBIT changes the appearance of the cursor to represent a hand with a pointing finger. To access the online documentation associated with any component currently displayed on the GUI, left-click on the component. When you do so, GAMBIT launches the local web browser and opens and displays documentation associated with the component.

For example, to view documentation related to a currently open specification form, such as the Create Real Brick form, perform the following operations.

Step Location Action Comments

1 Main menu bar Click Help Opens the Help command menu

2 Help command menu

Click Quick Selects the context-sensitive help option

3 Specification form

Click anywhere on the Create Real Brick form

Launches the local browser (or accesses any currently open browser) and opens the file containing documentation pertaining to the form

4.4.2 Table of Contents

When you select Table of Contents from the Help menu, GAMBIT launches the local web browser and opens a file that constitutes a hyperlinked table of contents for the entire GAMBIT documentation suite. To locate a subject of interest in the GAMBIT online help document, use the hyperlinked table of contents to navigate through GAMBIT online documentation.

4.4.1 About

When you select the About option from the Help menu, GAMBIT opens a form that displays information related to the currently running version of the program (see below).

Page 424: Gambit Tutorial Guide

© Fluent, Inc. 11/08/99

APPENDIX A--IF BLOCKS AND DO LOOPS

A.1 Overview

GAMBIT allows you to use IF blocks and DO loops as part of a set of journal-file commands. IF blocks and DO loops allow you to customize journal files in order to facilitate the creation and/or meshing of GAMBIT models. For example, you can use DO loops to construct, locate, and orient multiple copies of a single entity type.

The following sections of this appendix describe the general syntax and use of GAMBIT IF blocks and DO loops.

A.2 IF Blocks

A.2.1 General Syntax

The general syntax of a GAMBIT IF block is as follows:

IF COND (E)

Commands [ ELSE

Commands ] ENDIF

where E represents a logical expression and the square brackets ([]) indicate that the ELSE statement and its associated Commands are optional. (For a description of valid logical expressions, see Appendix B, Section B.3.2.)

When GAMBIT encounters an IF block, it evaluates the expression, E, and executes selected blocks of subsequent commands depending on whether the expression is true or

Page 425: Gambit Tutorial Guide

false. The following table describes the action that results from the evaluation of a GAMBIT IF block expression (E).

E Action

True • GAMBIT executes the block of commands that exists between the IF and ELSE commands.

• If the IF block does not contain an ELSE command, GAMBIT executes the entire block of commands between the IF and ENDIF commands.

False • GAMBIT skips to the next ELSE command at the same nesting level. • If the IF block does not contain an ELSE command, GAMBIT skips to

the command that follows the ENDIF command.

NOTE (1): GAMBIT IF, ELSE, and ENDIF statements are not case-sensitive. For example, the following block of commands constitutes a valid GAMBIT IF block:

if cond ($q .eq. 5) volume create sphere radius ($q*3) endif

NOTE (2): If you use a GAMBIT parameter as part of the logical expression, E, you must define the parameter prior to encountering the IF block. You can define the parameter either by means of the GAMBIT Edit Parameters form or by means of a journal file or Command line command (see Section 4.2.3).

A.2.2 Example

As an example of the use of GAMBIT IF blocks, consider the following block of commands:

IF COND ($a .GT. 5) volume create sphere radius ($a/2) ELSE volume create brick width 1 height 1 depth 1 ENDIF

GAMBIT interprets the IF block as follows:

• If the parameter "a" is greater than 5, create a sphere of radius 2.5.

• If the parameter "a" is less than or equal to 5, create a unit cube.

Page 426: Gambit Tutorial Guide

A.2.3 Nested IF Blocks

GAMBIT IF blocks can contain any number of nested IF blocks. For example, the following structure constitutes a valid general use of nested IF blocks:

IF COND ( )

IF COND ( ) Commands

ELSE

IF COND ( ) Commands

ELSE Commands

ENDIF ENDIF ELSE

IF COND ( ) Commands

ENDIF ENDIF

where the represent separate, valid logical expressions.

A.3 DO Loops

A.3.1 General Syntax

The general syntax of any GAMBIT DO loop is as follows:

DO PARA "$p" [ INIT i ] COND (E) [ INCR n ]

commands ENDDO

where the brackets ([]) indicate that the keywords INIT and INCR and their associated parameters are optional.

The DO-loop parameters shown above are defined as follows.

Parameter Definition

$p Loop control variable.

Page 427: Gambit Tutorial Guide

NOTE: The loop control variable must constitute an existing parameter-that is, a parameter that has been previously defined. For a description of the definition and use of GAMBIT parameters (see Section 4.2.3).

i An arithmetic expression that provides the initial value for $p when loop

execution begins. (Default = 1.)

E A logical expression used to terminate loop execution. The loop terminates when the expression E evaluates as false.NOTE: For a description of valid logical expressions, see Appendix B, Section B.3.2.

n An arithmetic expression that defines the amount by which $p is

incremented after each execution of the DO loop. (Default = 1.)

NOTE: The value of n is evaluated only once-at the initialization of the DO loop.

NOTE (1): GAMBIT DO-loop statements are not case-sensitive. For example, the following block of commands constitutes a valid DO loop

do para "$x" init 3 cond ($x .le. 5) volume create brick width $x height ($x*2.5) enddo

NOTE (2): Do not attempt to define or update parameters from within a DO loop.

A.3.2 DO-Loop Operations

When GAMBIT encounters a DO loop, it executes the following sequence of operations.

Step Operation

1 Evaluate i and n.

2 Initialize $p to the value of i.

3 Evaluate E:

• If E evaluates as false, skip to the command that follows the ENDDO command.

• If E does not evaluate as false, execute the commands that exist between

Page 428: Gambit Tutorial Guide

the DO command and the ENDDO command.

4 Increment $p by n.

5 Go to Step 3.

A.3.3 Example

As an example of a GAMBIT DO loop, consider the following block of commands:

$Tmp = 2 $Z = 6 do para "$Z" init 6 cond ($Z .le. 24) incr ($Tmp*3) volume create sphere radius $Z enddo

If you execute the command block shown above, GAMBIT creates four spheres with radii 6, 12, 18, and 24.

A.3.4 BREAK and NEXT Commands

GAMBIT allows you to control DO loop operation by means of two additional commands:

• BREAK • NEXT

The BREAK and NEXT commands operate as follows:

• If GAMBIT encounters a BREAK command, it skips immediately to the command

that follows the ENDDO command.

• If GAMBIT encounters a NEXT command, it skips any commands that exist

between the NEXT command and the ENDDO command but continues execution of

the DO loop.

A.3.5 Nested DO Loops

GAMBIT allows you to nest DO loops within other DO loops. The only restriction that GAMBIT imposes on the nesting of DO loops is that each nested loop must be completely contained within the outer loop.

Page 429: Gambit Tutorial Guide

© Fluent, Inc. 11/08/99

APPENDIX B -- CONSTANTS, FUNCTIONS, AND EXPRESSIONS

B.1 Constants

GAMBIT provides the following predefined constants for use in any value expression.

Constant Value Description

PI 3.141592653590

TWOPI 6.283185307180

DEG2RAD 0.0174532925199 Degree-to-radian conversion factor

RAD2DEG 57.29577951308 Radian-to-degree conversion factor

B.2 Functions

There are two types of intrinsic functions in GAMBIT:

• Numeric • String

Numeric functions are mathematical functions that operate only on numerical values. (NOTE: All numeric function evaluations return a single value.) String functions allow you to manipulate alphanumeric strings.

Page 430: Gambit Tutorial Guide

B.2.1 Numeric Functions

GAMBIT provides the following numeric functions..

Function Description

ABS (x) Absolute value of x,

ACOS (x) Angle whose cosine is x

ASIN (x) Angle whose sin is x

ATAN (x) Angle whose tan is x

COS (x) Cosine of x

COSH (x) Hyperbolic cosine of x

DIGSUM (x) Sum of digits of integer portion of x-for example, DIGSUM(123) = 6

EXP (x) Exponential of x,

INT (x) Integer truncation of x

LOG (x) Natural logarithm of x,

LASTID (entity)

Highest identifier number used for the specified entity type (see NOTE 3, below)

LOG10 (x) Base-10 logarithm of x,

MAX ( ) Maximum of x or y

MIN ( ) Minimum of or

MOD ( ) Modulo or remainder:

POW ( ) x raised to the power y,

SIGN (x) −1.0 if x is negative, else 1.0

Page 431: Gambit Tutorial Guide

SIN (x) Sine of x

SINH (x) Hyperbolic sine of x

SQRT (x) Square root of x

TAN (x) Tangent of x

TANH (x) Hyperbolic tangent of x

NOTE (1): The arguments x and y in the functions listed above represent any valid value expression-that is, a number, constant, function, arithmetic expression, or parameter.

NOTE (2): All trigonometric functions require and return values expressed in degrees.

NOTE (3): The LASTID(entity) function returns a numeric value that constitutes the highest number currently assigned for a specified entity type. For example, if five volumes have been created in a given model, the command

$x = LASTID(vo_id)

returns a value of 5 for the parameter x.

You can specify the entity type either by means of a string (such as vo_id in the example shown above) or by means of a number. The available entity type designations (strings and numbers) are as follows.

Entity Type String Number

Vertex ve_id 1

Edge ed_id 2

Face fa_id 3

Volume vo_id 4

Group gr_id 5

Coordinate System

cs_id 6

Boundary Layer

bl_id 7

B.2.2 String Functions

Page 432: Gambit Tutorial Guide

The string functions available in GAMBIT are as follows.

Function Definition

= String assignment

+ String concatenation

CSTRCMP Case-insensitive lexicographic string compare

CSTRNCMP Case-insensitive lexicographic substring compare

DIRNAME Directory path portion of a file name containing a directory path

DIRPLUSFILE Combine a directory path and file name

DIRPLUSSUBDIR Combine a directory path and subdirectory path

DS Convert a UNIX file name which contains a directory path to a DOS file name

FILENAME File name portion of a file name containing a directory path

FILEPREFIX Prefix of a file name

FILESUFFIX Suffix of a file name

GETCWD Current working directory

GETENV Get value of environment variable

GETIDENT Current GAMBIT database Identifier

GETSCR Current scratch directory

NTOS Numeric to string representation conversion

STON String to numeric representation conversion

STRCMP Case-sensitive lexicographic string compare

STRFMT String formatting

STRLEN Number of characters in a string

Page 433: Gambit Tutorial Guide

STRNCMP Case-sensitive lexicographic substring compare

STRRSTR Offset of the last occurrence of a substring within a string

STRSTR Offset of the first occurrence of a substring within a string

STRTOLC Convert a string to lower case

STRTOUC Convert a string to upper case

SUBSTR Substring extraction

US Convert a DOS file name which contains a directory path to a UNIX file name

The follow subsections describe and show examples of each of the functions listed above.

(=) -- String Assignment

String assignment allows the user to assign a string value to a parameter in GAMBIT. Assigned strings may be literal strings enclosed in double quotation marks or other string parameters.

Examples

$X = "STRING"

$Y = $X

(+) -- String Concatenation

String concatenation allows the user to concatenate string values in parameters in GAMBIT. Literal strings and string parameters can be concatenated in any combination.

Examples

$X = "ABC" + "DEF"

$X = $Y + "DEF"

Page 434: Gambit Tutorial Guide

(CSTRCMP) -- Case-Insensitive String Compare

CSTRCMP performs a character-by-character comparison of "STRING1" and "STRING2" and ignores the case of each character until a difference is found or the end of "STRING1" is reached. CSTRCMP returns a numeric value that indicates whether "STRING1" is greater than, equal to or less than "STRING2". The value indicates the logical relationship between STRING1 and STRING2 as follows.

Value Relationship

> 0 "STRING1" is greater than "STRING2"

< 0 "STRING1" is less than "STRING2"

= 0 "STRING1" equals "STRING2"

Format

CSTRCMP ( "STRING1" , "STRING2" )

Example

The following function call returns the numeric value 0 in parameter X-indicating that "STRING1" and "STRING2" are equal:

$X = CSTRCMP ( "ABCDEFGHI" , "abcdefghi" )

(CSTRNCMP) -- Case-Insensitive Substring Compare

CSTRNCMP performs a character-by-character comparison of "STRING1" and "STRING2" and ignores the case of each character until a difference is found or LENGTH characters have been compared. CSTRNCMP returns a numeric value indicating whether LENGTH characters in "STRING1" are greater than, equal to or less than LENGTH characters in "STRING2". The value indicates the logical relationship between STRING1 and STRING2 as follows.

Value Relationship

> 0 LENGTH characters in "STRING1" are greater than LENGTH characters in "STRING2"

< 0 LENGTH character in "STRING1" are less than LENGTH characters in

Page 435: Gambit Tutorial Guide

"STRING2"

= 0 LENGTH characters in "STRING1" equals LENGTH characters in "STRING2"

Format

CSTRNCMP ( "STRING1" , "STRING2" , LENGTH )

Example

The following function call returns the numeric value 0 in parameter X, indicating that the first 4 characters in "STRING1" are equal to the first 4 characters in "STRING2":

$X = CSTRNCMP ( "ABCDEFGH" , "abcdwxyz" , 4 )

(DIRNAME) -- Directory Path/ Directory Path

DIRNAME returns the directory path portion of a file name which contains a directory path by searching for a "/" or "\" in "FILENAME" and returning the portion of "FILENAME" from the beginning of "FILENAME" up to but not including the last "/" or "\" found. If no "/" or "\" is found in "FILENAME", FILENAME returns an empty string.

Format

DIRNAME ( "FILENAME" )

Example

The following function call returns the string value "/users/prob1" in parameter X:

$X = DIRNAME ( "/users/prob1/prob1.dbs" )

(DIRPLUSFILE) -- Directory Path and File Name

DIRPLUSFILE returns a string consisting of the "DIRECTORYNAME" and "FILENAME" combined with the appropriate "/" or "\" characters where necessary.

Format

DIRPLUSFILE ( "DIRECTORYNAME" , "FILENAME" )

Example

Page 436: Gambit Tutorial Guide

The following function call returns the string value "/users/prob1/ prob1.dbs" in parameter X:

$X = DIRPLUSFILE ( "/users/prob1" , "prob1.dbs" )

(DIRPLUSSUBDIR) -- Directory and Subdirectory Path

DIRPLUSSUBDIR returns the directory path name consisting of the "DIRECTORYNAME" and "SUBDIRECTORYNAME" combined with the appropriate "/" or "\" characters placed where necessary.

Format

DIRPLUSSUBDIR ("DIRECTORYNAME", "SUBDIRECTORYNAME")

Example

The following function call returns the string value "/users/prob1" in parameter X:

$X = DIRPLUSSUBDIR ( "/users" , "prob1" )

(DS) -- Convert UNIX File Name to DOS File Name

DS converts a UNIX file name which contains a directory path to a DOS filename by replacing "/" characters with the "\" characters.

Format

DS ( "FILENAME" )

Example

The following function call returns the string value "\users\prob1\ prob1.dbs" in parameter X:

$X = DS ( "/users/prob1/prob1.dbs" )

(FILENAME) -- File Name/ Directory Path

FILENAME returns only the file name portion of a file name containing a directory path. FILENAME searches for the last occurrence of "/" or "\" in "FILENAME" and returns the portion of "FILENAME" to the right of the last "/" or "\" found. If no "/" or "\" is found in "FILENAME", FILENAME returns an empty string.

Page 437: Gambit Tutorial Guide

Format

FILENAME ( "FILENAME" )

Example

The following function call returns the string value "prob1.dbs" in parameter X:

$X = FILENAME ( "/users/prob1/prob1.dbs" )

(FILEPREFIX) -- Prefix of a File Name

FILEPREFIX returns the prefix of a file name by searching for a "." in "FILENAME"

and returning the portion of "FILENAME" to the left of the "." including the path if a

path is specified. If no "." is found in "FILENAME", FILEPREFIX returns an empty string.

Format

FILEPREFIX ( "FILENAME" )

Example

The following function call returns the string value "prob1" in parameter X:

$X = FILEPREFIX ( "prob1.dbs" )

(FILESUFFIX) -- Suffix of a File Name

FILESUFFIX returns the suffix of a file name by searching for a "." in "FILENAME"

and returning the portion of "FILENAME" to the right of the ".". If no "." is found in "FILENAME", FILEPREFIX returns an empty string.

Format

FILESUFFIX ( "FILENAME" )

Example

The following function call returns the string value "dbs" in parameter X:

$X = FILESUFFIX ( "prob1.dbs" )

(GETCWD) -- Current Working Directory

Page 438: Gambit Tutorial Guide

GETCWD returns the current GAMBIT working directory.

Format

GETCWD ( )

Example

The following function call returns the string value "/users/prob1" in parameter X

assuming that the current problem is being run in "/users/ prob1":

$X = GETCWD ( )

(GETENV) -- Environment Variable

GETENV returns the value of the environment variable ENVVAR.

Format

GETENV ( "ENVVAR" )

Example

Assuming the environment variable GAMBITROOT is set to "/usr/local/ GAMBIT", the

following function call returns the string value "/usr/ local/GAMBIT" in parameter X:

$X = GETENV ( "GAMBITROOT")

(GETIDENT) -- Current GAMBIT Database Identifier

GETIDENT returns the current GAMBIT problem identifier.

Format

GETIDENT ( )

Example

The following function call returns the string value "prob1" in parameter X assuming the

current problem identifier is "prob1":

$X = GETIDENT ( )

Page 439: Gambit Tutorial Guide

(GETSCR) -- Current Scratch Directory

GETSCR returns the current GAMBIT scratch directory.

Format

GETSCR ( )

Example

For example, the following function call returns the string value "/users/ prob1" in

parameter X assuming that the current scratch directory is "/users/prob1":

$X = GETSCR ( )

(NTOS) -- Numeric-to-String Representation Conversion

NTOS converts NUMBER to its string representation and returns the corresponding string value. Scientific notation for the numeric representation is supported and is expanded in the string representation.

Format

NTOS ( NUMBER )

Example

The following function call returns the string value "12300" in parameter X:

$X = NTOS ( 123E+2 )

(STON) -- String-to-Numeric Representation Conversion

STON converts "STRING" to its numeric representation and returns the corresponding numeric value. STON ignores leading blanks and only converts the numeric characters up to the first non-numeric character encountered starting from the left of "STRING".

Format

STON ( "STRING" )

Example

The following function call returns the numeric value 123 in the scalar parameter X:

Page 440: Gambit Tutorial Guide

$X = STON ( "123" )

(STRCMP) -- Case-Sensitive String Compare

STRCMP performs a character-by-character comparison of "STRING1" and "STRING2" taking into account the case of each character until a difference is found or the end of "STRING1" is reached. STRCMP returns a numeric value indicating whether "STRING1" is greater than, equal to or less than "STRING2". The value indicates the logical relationship between STRING1 and STRING2 as follows.

Value Relationship

> 0 "STRING1" is greater than "STRING2"

< 0 "STRING1" is less than "STRING2"

= 0 "STRING1" equals "STRING2"

Format

STRCMP("STRING1", "STRING2")

Example

The following function call returns the numeric value 0 in parameter X indicating that "STRING1" and "STRING2" are equal:

$X = STRCMP ( "ABCDEFGHI", "ABCDEFGHI" )

(STRFMT) -- String Formatting

STRFMT formats each ARGUMENT according to the contents of "FORMAT SPECIFIER" and returns the results as a string value. "FORMAT SPECIFIER" may include any combination of literals and C style format specifiers. There must be a separate format specifier for each ARGUMENT in the argument list and each format specifier must be the correct type or a syntax error will occur.

Specifier Description

%c Single character

Page 441: Gambit Tutorial Guide

%d Integer

%i Integer

%e Floating point (scientific notation)

%f Decimal floating point

%g Use the shorter of %e or %f

%o Octal

%s String of characters

%u Unsigned decimal

%x Hexadecimal

%% Print % sign

Format

STRFMT ("FORMAT SPECIFIER" [, ARGUMENT1 [, ARGUMENT2 [, ARGUMENTn]]])

Example

The following function call returns the string value "The value of Y: 10" in parameter X:

$Y = 10 $X = STRFMT ( "The value of Y: %d" , $Y )

(STRLEN) -- Number of Characters in a String

STRLEN returns the number of characters in "STRING" (including blanks).

Format

STRLEN ( "STRING" )

Example

The following function call returns the numeric value 6 in parameter X:

$X = STRLEN ( "STRING" )

Page 442: Gambit Tutorial Guide

(STRNCMP) -- Case-Sensitive Substring Compare

STRNCMP performs a character-by-character comparison of "STRING1" and "STRING2" taking into account the case of each character until a difference is found or LENGTH characters have been compared. STRNCMP returns a numeric value indicating whether LENGTH characters in "STRING1" are greater than, equal to or less than LENGTH characters in "STRING2". The value indicates the logical relationship between STRING1 and STRING2 as follows.

Value Relationship

> 0 LENGTH characters in "STRING1" are greater than LENGTH characters in "STRING2"

< 0 LENGTH character in "STRING1" are less than LENGTH characters in "STRING2"

= 0 LENGTH characters in "STRING1" equals LENGTH characters in "STRING2"

Format

STRNCMP ( "STRING1" , "STRING2" , LENGTH )

Example

The following function call returns the numeric value 0 in parameter X indicating that the first 4 characters in "STRING1" are equal to the first 4 characters in "STRING2":

$X = STRNCMP ( "ABCDEFGH" , "ABCDWXYZ" , 4 )

(STRRSTR) -- Offset of Last Substring Within a String

STRRSTR returns the starting character position in "STRING" where the last occurrence of "SUBSTRING" is found or 0 if "SUBSTRING" is not found in "STRING".

Value Relationship

> 0 Starting character position in "STRING" where the last occurrence of "SUBSTRING" was found

= 0 "SUBSTRING" was not found in "STRING"

Page 443: Gambit Tutorial Guide

Format

STRRSTR ( "STRING" , "SUBSTRING" )

Example

The following function call returns the numeric value 10 in parameter X:

$X = STRRSTR ( "ABCDEFABCDEF", "DE" )

(STRSTR) -- Offset of First Substring Within a String

STRSTR returns the starting character position in "STRING" where the first occurrence of "SUBSTRING" is found or 0 if "SUBSTRING" is not found in "STRING".

Value Relationship

> 0 Starting character position in "STRING" where the first occurrence of "SUBSTRING" was found

= 0 "SUBSTRING" was not found in "STRING"

Format

STRSTR ( "STRING" , "SUBSTRING" )

Example

The following function call returns the numeric value 4 in parameter X:

$X = STRSTR ( "ABCDEFABCDEF" , "DE" )

(STRTOLC) -- Convert a String to Lower Case

STRTOLC converts the alphabetic characters "STRING" to lower case.

Format

STRTOLC ( "STRING" )

Example

The following function call returns the string value "abcdef" in parameter X:

Page 444: Gambit Tutorial Guide

$X = STRTOLC ( "ABCDEF" )

(STRTOUC) -- Convert a String to Upper Case

STRTOUC converts the alphabetic characters "STRING" to upper case.

Format

STRTOUC ( "STRING" )

Example

The following function call returns the string value "ABCDEF" in parameter X:

$X = STRTOUC ( "abcdef" )

(SUBSTR) -- Substring Extraction

SUBSTR extracts a substring from "STRING" starting from POSITION for LENGTH characters and returns the substring value.

Format

SUBSTR("STRING", POSITION, LENGTH)

Example

The following function call returns the string value "DEF" in parameter X:

$X = SUBSTR ( "ABCDEFGHI" , 4 , 3 )

(US) -- Convert DOS File Name to UNIX File Name

US converts a DOS file name that contains a directory path to a UNIX filename by replacing "\" characters with the "/" characters.

Format

US ( "FILENAME" )

Example

Page 445: Gambit Tutorial Guide

The following function call returns the string value "/users/prob1/ prob1.dbs" in parameter X:

$X = US ( "\users\prob1\prob1.dbs" )

B.3 Expressions

GAMBIT allows you to use two types of expressions in parameter definitions and journal files:

• Arithmetic expressions • Logical expressions

Arithmetic expressions evaluate to a numeric value and can be used wherever a numeric value is expected-for example, a keyword value, a data record entry, or a DO loop control variable. Logical expressions evaluate to true or false and are used in IF blocks and DO loops. (For descriptions of the use of IF blocks and DO loops in GAMBIT, see Appendix A.)

B.3.1 Arithmetic Expressions

GAMBIT arithmetic expressions are of the form:

where s is a sign (+ or −) and and are arithmetic expressions that are related to each other by means the arithmetic operator, AOP.

The following table lists valid arithmetic operators.

Symbol Operator

+ Addition

− Subtraction

∗ Multiplication

/ Division

^ Exponentiation

Page 446: Gambit Tutorial Guide

Operators may not be placed immediately adjacent to each other. Parentheses may be used to determine a hierarchy of operations or for clarity. When parentheses are not used

the order of operations is ^, *, /, + and -.

The expressions and may consist of a numerical values, constants, functions,

parameters, or other arithmetic expressions of the form . There is no limit to the level of nesting of arithmetic expressions. Examples of valid arithmetic expressions are as follows:

−5.0*SIN($a)

2*(PI+(TAN($x+5)/($y−5)))

3^3.5 + −4*$rad*RAD2DEG

SQRT(2+MAX($a,$b))

B.3.2 Logical Expressions

Logical expressions consist of two types of operations:

• Relational • Logical

Relational operations consist of comparisons made between arithmetic expressions. Logical operations consist of comparisons made between logical expressions.

Relational Operations

The general syntax for GAMBIT relational operations is as follows:

where and are arithmetic expressions, and ROP is a relational operator that defines the comparison between the expressions. The following table lists the valid relational operators available in GAMBIT.

ROP Description

.GT. Greater than ( )

.GE. Greater than or equal to ( )

Page 447: Gambit Tutorial Guide

.LT. Less than ( )

.LE. Less than or equal to ( )

.EQ. Equal to (=)

.NE. Not equal to ( )

Logical Operations

The general syntax for GAMBIT logical operations is as follows:

where and are arithmetic expressions, and LOP is a logical operator that defines the comparison between the expressions.

GAMBIT allows you to use any of the following logical operators:

• .AND. • .OR. • .NOT.

© Fluent, Inc. 11/08/99

Page 448: Gambit Tutorial Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-A

About command 3 ACIS files 3 Activate Coordinate System 1 adjusting meshes 1 Align forms 1

aligning edges 1 entities 1 faces 1 groups 1 vertices 1 volumes 1

Annotate form 3

annotation objects adding 3 arrow 3 deleting 3 line 3 modifying 3 text 3

arcs circular 1 conic 1 elliptical 1 1a fillet 1 Area quality metric 3 arithmetic expressions 3 arrow annotation objects 3 Aspect Ratio quality metric 3

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

Page 449: Gambit Tutorial Guide

4.4 Help Menu

The Help command allows you to access online documentation by means of the local web browser and to display information on the current version of the program. When you click Help on the menu bar, GAMBIT opens the Help command menu. The Help command menu includes the following options:

• Quick • Table of Contents • About

The Quick option accesses context-sensitive online help. The Table of Contents option allows you to browse the entire suite of GAMBIT documentation by means of a hyperlinked table of contents. The About option displays information regarding the currently running version of GAMBIT.

4.4.1 Quick

When you select Quick from the Help menu, GAMBIT changes the appearance of the cursor to represent a hand with a pointing finger. To access the online documentation associated with any component currently displayed on the GUI, left-click on the component. When you do so, GAMBIT launches the local web browser and opens and displays documentation associated with the component.

For example, to view documentation related to a currently open specification form, such as the Create Real Brick form, perform the following operations.

Step Location Action Comments

1 Main menu bar Click Help Opens the Help command menu

2 Help command menu

Click Quick Selects the context-sensitive help option

3 Specification form

Click anywhere on the Create Real Brick form

Launches the local browser (or accesses any currently open browser) and opens the file containing documentation pertaining to the form

Page 450: Gambit Tutorial Guide

4.4.2 Table of Contents

When you select Table of Contents from the Help menu, GAMBIT launches the local web browser and opens a file that constitutes a hyperlinked table of contents for the entire GAMBIT documentation suite. To locate a subject of interest in the GAMBIT online help document, use the hyperlinked table of contents to navigate through GAMBIT online documentation.

4.4.1 About

When you select the About option from the Help menu, GAMBIT opens a form that displays information related to the currently running version of the program (see below).

© Fluent, Inc. 11/08/99

Page 451: Gambit Tutorial Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-B

background 1 blend types 1 Blend Volumes 1 Boolean operations 1 face 1 unite 2 volume 1 boundary layers 1 creating 1 definition 1 deleting 1 internal continuity 1 modifying 1 parameters 1 summarizing 1 transition patterns 1 transition rows 1 boundary types 1 entity sets 1 labels 1 specifying 1 brick 1 brick and elliptical cylinder 2 Browse command button 3

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

Page 452: Gambit Tutorial Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-C

CAD files 3 chamfering edges 1 check boxes 3 Check Edges 1 Check Face Meshes 1 Check Faces 1 Check Group Meshes 1 Check Groups 1 Check Vertices 1 Check Volume Meshes 1 Check Volumes 1

checking edges 1 face meshes 1 faces 1 groups 1 vertices 1 volume meshes 1 1a volumes 1 circles (full) 1 circular arcs 1 circular faces 1

Clean Journal command 3 form 3 cleaning up geometry 1 Collapse Face (Virtual) 1 collapse operations 1 color mode 3 command buttons 1 3 form 3 toolpad 3 3a Command text box 3 hidden menu 3 pasting commands to 3 concatenation 3 conic arcs 1

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

Page 453: Gambit Tutorial Guide

Connect Edges 1 Connect Faces 1 connect operations 1 Connect Vertices 1

connecting edges 1 1a faces 1 vertices 1 1a connection types 1 1a 1b connectivity color mode 3 constants 3 construct operations 1 context-sensitive help 3 continuum types 1 entity sets 1 specifying 1 control elements 1 3

conventions font 2 toolpad command button 2 toolpad command buttons 2 conversion list 1 Convert Edges 1 Convert Faces 1 Convert Vertices 1 converting edges 1 converting faces 1 converting vertices 1 Cooper meshing scheme 1 coordinate systems 1 activating 1 creating 1 deleting 1 global 1 1a local 1 location and orientation 1 modifying 1 overview 1 parameters 1 reference 1 summarizing 1 type 1

copying edges 1 entities 1 faces 1

Page 454: Gambit Tutorial Guide

groups 1 meshes 1 vertices 1 volumes 1 Corner vertex types 1 Create Boundary Layer 1 Create Coordinate System 1 Create Face From Wireframe 1 Create Group 1 Create Group 1 Create New Session form 3 Create Real Brick 1 Create Real Circular Arc 1 Create Real Circular Face 1 Create Real Circular Face From Vertices 1 Create Real Conic Arc 1 Create Real Cylinder 1 Create Real Edge From Vertices 1 Create Real Elliptical Arc 1 Create Real Elliptical Face 1 Create Real Elliptical Face From Vertices 1 Create Real Face From Vertex Rows 1 Create Real Fillet Arc 1 Create Real Frustum 1 Create Real Full Circle 1 Create Real Net Surface Face 1 Create Real Parallelogram Face 1 Create Real Polygon Face 1 Create Real Prism 1 Create Real Pyramid 1 Create Real Rectangular Face 1 Create Real Skin Surface Face 1 Create Real Sphere 1 Create Real Torus 1 Create Real Vertex 1 Create Straight Edge 1 Create Vertex On Edge 1 Create Vertex On Face 1 Create Vertices At Edge Intersections 1 Create Virtual Vertex On Volume 1 creating a session 3

creating boundary layers 1 bricks 2 coordinate systems 1 cylinders 2

Page 455: Gambit Tutorial Guide

edges 1 circular arc 1 conic arc 1 elliptical arc 1 fillet arc 1 full circle 1 NURBS 1 projecting 1 revolve vertices 1 straight 1 faces 1 circular 1 elliptical 1 net-surface 1 parallelogram 1 polygonal 1 rectangular 1 revolve edges 1 skin-surface 1 sweep edges 1 vertex rows 1 wireframe 1 geometry 1 grids 1 groups 1 vertices 1 by mouse 1 volumes 1 brick 1 cylinder 1 frustum 1 prism 1 pyramid 1 sphere 1 torus 1 CSTRCMP string function 3 CSTRNCMP string function 3 cylinder 1

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

Page 456: Gambit Tutorial Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-D

database (dbs) files 3 decomposing geometry 1 defaults 3 3a Defaults command 3

defaults definition subforms 3 editing 3 files 3 Define Array Values form 3 Define ArrayIndices form 3 defining a vector 1 Delete Boundary Layer 1 Delete Coordinate Systems 1 Delete Edges 1 Delete Faces 1 Delete Groups 1 Delete Vertices 1 Delete Volumes 1

deleting boundary layers 1 coordinate systems 1 edge meshes 1 face meshes 1 group meshes 1 volume meshes 1 volumes 1 Description window 2 3 Diagonal Ratio quality metric 3 directory structure 3 DIRNAME string function 3 DIRPLUSFILE string function 3 DIRPLUSSUBDIR string function 3 Disconnect About Real Edge 1 Disconnect About Real Face 1 Disconnect About Real Vertex 1

disconnecting edges 1

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

Page 457: Gambit Tutorial Guide

faces 1 vertices 1 Display Grid 1 Display Ruler 1 Display Type 2 Display Type options 3 displaying rulers 1 DO loops 3 double-sided grading 1 draft method 1 1a DS string function 3

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-E

Edge Blend Type form 1 Edge Ratio quality metric 3

edges aligning 1 checking 1 circular arc 1 conic arc 1 connecting 1 converting 1 copying 1 creating 1 deleting 1 deleting mesh 1 disconnecting 1 element types 1 elliptical arc 1

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

Page 458: Gambit Tutorial Guide

fillet arc 1 full circle 1 hard-linking 1 linking meshes 1 merging 1 meshing 1

modifying color 1 label 1 moving 1 NURBS 1 projecting 1 querying 1 revolving vertices 1 soft-linking 1 splitting 1 1a straight 1 summarizing 1 summarizing meshes 1 unlinking meshes 1 Edit commands 3 Defaults 3 File 3 Parameters 3 Title 3 Edit Defaults form 3 Edit Edge Lower Topology form 1 Edit Face Lower Topology form 1 Edit File form 3 Edit Group Lower Topology form 1 Edit Parameters form 3 Edit Session Title form 3 Edit Volume Lower Topology form 1 Edit/Run Journal form 3 hidden menu 3 input field 3 text editor 3 editing a journal file 3 editing a session title 3 editing a text file 3

element types edges 1 face 1 volumes 1 elliptical arcs 1 1a End vertex types 1

Page 459: Gambit Tutorial Guide

entities aligning 1 copying 1 labels 1 moving 1 orphan 1 parasite 1 picking 1 2 reflecting 1 rotating 1 scaling 1 specifying 1 totaling 1 translating 1 virtual 1 entity sets 1 EquiAngle Skew 2 EquiAngle Skew quality metric 3 EquiSize Skew quality metric 3 error messages 3 Examine Mesh form 3 Cut Orientation options 3 Cut Type options 3 Display cut 3 Display elements 3 Display Mode options 3 Faceted options 3 Wire option 3

Display Type options Plane 3 Range 3 Sphere 3 Quality Type options 3 examining the mesh 2 colors and shading 3 element quality range 3 element types 3 histogram 3 quality types 3 slider bars 3 faceted view 3 plane cut 3 spherical cut 3 wireframe view 3 Exit command 3 exiting GAMBIT 2

Page 460: Gambit Tutorial Guide

Export ACIS File form 3 Export command 3 Export Mesh File form 3 exporting mesh files 3

expressions arithmetic 3 logical 3

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-F

faces aligning 1 checking 1 circular 1 collapsing 1 connecting 1 converting 1 copying 1 creating 1 deleting 1 deleting meshes 1 disconnecting 1 elliptical 1 forming 1 healing 1 intersecting 1 linking meshes 1 merging 1 mesh checking 1 mesh element type 1 meshing 1

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

Page 461: Gambit Tutorial Guide

modifying color 1 label 1 moving 1 moving mesh nodes 1 net-surface 1 parallelogram 1 polygonal 1 querying 1 rectangular 1 revolving edges 1 skin-surface 1 smoothing meshes 1 splitting 1 1a subtracting 1 summarizing 1 summarizing mesh 1 sweeping edges 1 uniting 1 vertex rows 1 vertex types 1 wireframe 1 feature angle 3 File command(Edit menu) 3 File commands 3 Clean Journal 3 Exit 3 Export 3 Import 3 New 3 Open 3 Print Graphics 3 Run Journal 3 Save 3 Save As 3 View File 3 file formats 3

file organization directory structure 3 session files 3 FILENAME string function 3 FILEPREFIX string function 3 FILESUFFIX string function 3

files ACIS 3 CAD 3

Page 462: Gambit Tutorial Guide

database (dbs) 3 defaults 3 editing 3 exporting 3 IGES 3 importing 3 initialization 3 journal (jou) 3 lock (lok) 3 mesh 3 selecting 3 STL 3 transcript (trn) 3 viewing 3 fillet arcs 1 radius 1 trimming edges 1 Filter specification 1 FIT TO WINDOW command 2 font conventions 1 2 3 foreground 1 form field 3 Form Real Volume From Wireframe 1 format conventions 1

forming faces 1 volumes 1 revolve faces 1 stitch faces 1 sweep faces 1 wireframe 1

forms Save Session As 3 Activate Coordinate System 1 Align 1 Annotate 3 Blend Volumes 1 Check Edges 1 Check Face Meshes 1 Check Faces 1 Check Group Meshes 1 Check Groups 1 Check Vertices 1 Check Volume Meshes 1 Check Volumes 1 Clean Journal 3

Page 463: Gambit Tutorial Guide

Collapse Face (Virtual) 1 Connect Edges 1 Connect Faces 1 Connect Vertices 1 Convert Edges 1 Convert Faces 1 Convert Vertices 1 Create Boundary Layer 1 Create Coordinate System 1 Create Face From Wireframe 1 Create Group 1 1a Create New Session 3 Create Real Brick 1 2 Create Real Circular Arc 1 Create Real Circular Face 1 Create Real Circular Face From Vertices 1 Create Real Conic Arc 1 Create Real Cylinder 1 2 Create Real Edge From Vertices 1 Create Real Elliptical Arc 1 Create Real Elliptical Face 1 Create Real Elliptical Face From Vertices 1 Create Real Face From Vertex Rows 1 Create Real Fillet Arc 1 Create Real Frustum 1 Create Real Full Circle 1 Create Real Net Surface Face 1 Create Real Parallelogram Face 1 Create Real Polygon Face 1 Create Real Prism 1 Create Real Pyramid 1 Create Real Rectangular Face 1 Create Real Skin Surface Face 1 Create Real Sphere 1 Create Real Torus 1 Create Real Vertex 1 Create Straight Edge 1 Create Vertex On Edge 1 Create Vertex On Face 1 Create Vertices At Edge Intersections 1 Create Virtual Vertex On Volume 1 Define Array Indices 3 Define Array Values 3 Delete Boundary Layer 1 Delete Coordinate Systems 1 Delete Edge Meshes 1

Page 464: Gambit Tutorial Guide

Delete Edges 1 Delete Face Meshes 1 Delete Faces 1 Delete Group Meshes 1 Delete Groups 1 Delete Vertices 1 Delete Volume Meshes 1 Delete Volumes 1 Disconnect About Real Edge 1 Disconnect About Real Face 1 Disconnect About Real Vertex 1 Display Grid 1 Display Ruler 1 Edge Blend Type 1 Edge List 1 Edit Defaults 3 Edit Edge Lower Topology 1 Edit Face Lower Topology 1 Edit File 3 Edit Group Lower Topology 1 Edit Parameters 3 Edit Session Title 3 Edit Volume Lower Topology 1 Edit/Run Journal 3 Examine Mesh 2 Exit 2 Export ACIS File 3 Export Mesh File 3 Form Real Volume From Wireframe 1 Global Search and Replace 3 Heal Real Faces 1 Heal Real Volume 1 Import ACIS File 3 Import CAD 3 Import IGES File 3 Import Mesh 3 Intersect Real Faces 1 Intersect Real Volumes 1 Link Edge Meshes 1 Link Face Meshes 1 Link Volume Meshes 1 Merge Edges (Virtual) 1 Merge Faces (Virtual) 1 Merge Volumes 1 Mesh Edges 1 Mesh Faces 1

Page 465: Gambit Tutorial Guide

Mesh Groups 1 Mesh Volumes 1 2 Modify Boundary Layer 1 Modify Boundary Layer Label 1 Modify Coordinate System 1 Modify Edge Color 1 Modify Edge Label 1 Modify Face Color 1 Modify Face Label 1 Modify Group 1 1a Modify Group Color 1 Modify Group Label 1 Modify Lights 3 Modify Meshed Geometry 1 1a Modify Vertex Color 1 Modify Vertex Label 1 Modify Volume Color 1 Modify Volume Label 1 Move Face Nodes 1 Move/Copy 1 pick-list 3 Print Graphics 3 Project Edge On Face 1 Query Edges 1 Query Faces 1 Query Groups 1 Query Vertices 1 Query Volumes 1 query-list 3 Revolve Edges 1 Revolve Real Faces 1 Revolve Vertices 1 Run Journal 3 Select File 3 Set Color 1 3 Set Edge Element Type 1 Set Face Element Type 1 Set Face Vertex Type 1 Set Volume Element Type 1 Slide Virtual Vertex 1 Smooth Face Mesh 1 Smooth Volume Mesh 1 specification 3 3a Specify Boundary Types 1 Specify Continuum Types 1 Specify Label Type 3

Page 466: Gambit Tutorial Guide

Split Edge 1 Split Face 1 Split Meshed Edge 1 Split Meshed Face 1 Split Volume 1 Stitch Faces 1 Subtract Real Faces 1 Subtract Real Volumes 1 Summarize Boundary Layers 1 Summarize Coordinate Systems 1 Summarize Edge Mesh 1 Summarize Edges 1 Summarize Face Mesh 1 Summarize Faces 1 Summarize Group Meshes 1 Summarize Groups 1 Summarize Vertices 1 Summarize Volume Meshes 1 Summarize Volumes 1 Sweep Edges 1 Sweep Real Faces 1 Total Entities 1 Unite Real Faces 1 Unite Real Volumes 1 2 Unlink Edge Meshes 1 Unlink Face Meshes 1 Unlink Volume Meshes 1 Vector Definition 1 3 Vertex Blend Type 1 View Face/Vector 3 View File 3 frustum 1

functions numeric 3 string 3

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

Page 467: Gambit Tutorial Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-G

Geometry commands 1 Edge 1 Face 1 Group 1 Vertex 1 Volume 1 Geometry subpad 2 Geometry/Volume subpad 2

geometry completeness 1 consistency 1 creating 1 decomposing 1 exporting 3 general operations 1 importing 3 projecting 1 simplifying 1 virtual 1 applications 1 fundamentals 1 operations 1 GETCWD string function 3 GETENV string function 3 GETIDENT string function 3 GETSCR string function 3 Global Control toolpad 3 3a quadrant command buttons 3 Global Search and Replace form 3

grading center of 1 double-sided 1 schemes 1 graphic format 3

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

Page 468: Gambit Tutorial Guide

graphic format conventions 1 graphical user interface (GUI) 2 3 graphics file formats 3 graphics window 3 annotating 3

mouse operations display 3 journal view 3 previous view 3 revolve 3 rotate 3 translate 3 zoom 3 task 3 executing actions 3 picking entities 3 quadrants 3

grids defining 1 displaying 1 overview 1 parameters 1 snap option 1 type 1 visibility 1

groups aligning 1 checking 1 checking mesh 1 copying 1 creating 1 1a deleting 1 deleting meshes 1 meshing 1 modifying 1 1a color 1 label 1 moving 1 querying 1 summarizing 1 summarizing meshes 1 guest entities 1 GUI 3 GUI components 2 GUI control elements 3 3a check boxes 3

Page 469: Gambit Tutorial Guide

command buttons 3 list boxes 3 option buttons 3 pick-list forms 3 query-list forms 3 radio buttons 3 slider bars 3 text boxes 3 text windows 3

GUI command buttons 3 components 3 form field 3 preset configurations 3 sashes 3

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-H

hard links 1 1a Heal Real Faces 1 Heal Real Volume 1

healing faces 1 Help menu 3 About 3 Quick 3 Table of Contents 3 home directory 3 host entities 1

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

Page 470: Gambit Tutorial Guide

© Fluent, Inc. 11/23/99

A B C D E F G H I J L M N O P Q R S T U V W Z

Index-I identifier 3 IF blocks 3 IGES files 3 Import ACIS File form 3 Import CAD form 3 Import command 3 Import IGES File form 3 Import Mesh form 3 importing files 3

importing ACIS files 3 CAD files 3 IGES files 3 mesh files 3 initialization files 3 internal continuity 1 interpolant entities 1 interpolating 1 Intersect Real Faces 1 Intersect Real Volumes 1

intersecting faces 1 volumes 1 interval length ratio 1

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

A B C D E F G H I J L M N O P Q R S T U V W Z

© Fluent, Inc. 11/23/99

Page 471: Gambit Tutorial Guide

Index-J journal (jou) files 3 cleaning 3 command lines 3 editing 3 inserting pauses 3 marker fields 3 running 3 journaling the view 3

Index-L

labels 1 layout format 1 3 line annotation objects 3 Link Edge Meshes 1 Link Face Meshes 1 Link Volume Meshes 1 linking endpoint vertices 1

linking meshes edges 1 faces 1 volumes 1 list boxes 3 loading program defaults 3 lock (lok) files 3 logical expressions 3

main menu bar 3 main pad 3 manipulating the display 2 Map meshing scheme 1 menu commands 3 Merge Edges (Virtual) 1 Merge Faces (Virtual) 1 merge operations 1 merge types 1 1a Merge Volumes 1

merging

Page 472: Gambit Tutorial Guide

edges 1 1a faces 1 1a volumes 1 mesh element type 3 mesh files 3 exporting 3 importing 3

Mesh operations Boundary Layer commands 1 Edge commands 1 Face Mesh commands 1 Group commands 1 Volume commands 1 mesh orientation 1 mesh quality metrics 2 Area 3 Aspect Ratio 3 Diagonal Ratio 3 Edge Ratio 3 EquiAngle Skew 3 EquiSize Skew 3 MidAngle Skew 3 Stretch 3 Taper 3 Volume 3 Warpage 3 Mesh subpad 1 meshed geometry 1 meshing 1

meshing schemes edges 1

faces Quad-Map 1 Quad-Pave 1 Quad/Tri-Map 1 Quad/Tri-Pave 1 Submap 1 Tri Primitive 1 Tri-Pave 1 Wedge Primitive 1

volumes Cooper 1 Map 1 Stairstep 1 Submap 1 Tet Primitive 1

Page 473: Gambit Tutorial Guide

TGrid 1

meshing cube with cutout corner 1 edges 1 faces 1 groups 1 virtual edges 1 volumes 1 2

mesh examining 2 MidAngle Skew quality metric 3 model scale factor 3 Modify Boundary Layer 1 Modify Boundary Layer Label 1 Modify Coordinate System 1 Modify Edge Color 1 Modify Edge Label 1 Modify Face Color 1 Modify Face Label 1 Modify Group 1 Modify Group 1 Modify Group Color 1 Modify Group Label 1

Modify Lights form 3 Modify Meshed Geometry 1 Modify Vertex Color 1 Modify Vertex Label 1 Modify Volume Color 1 Modify Volume Label 1

modifying annotation objects 3 boundary layers 1 label 1 coordinate systems 1

edges color 1 label 1

faces color 1 label 1 groups 1 color 1 label 1 meshed geometry 1 1a

vertices

Page 474: Gambit Tutorial Guide

color 1 label 1

volumes color 1 label 1

mouse operations graphics window 2 3 executing actions 2 3 journaling the view 3 picking entities 2 3 revolving the model 3 rotating the model 3 showing previous view 3 translating the model 3 zooming the model 3 menus and forms 2 3 Move/Copy forms 1

moving edges 1 entities 1 lower topology 1 face mesh nodes 1 faces 1 groups 1 vertices 1 volumes 1

Index-N

net-surface face 1 New command 3 node spacing 1 Notrielement vertex types 1 NTOS string function 3 numeric functions 3 NURBS curves 1

Index-O

Open command 3

Open Existing Session formforms Open Existing Session 3 opening a session 3 3a

Page 475: Gambit Tutorial Guide

Operation toolpad 3 option buttons 3 ORIENT MODEL command 2 orphan entities 1 edges 1 faces

Index-P

parallelogram face 1 parameters 3 Parameters command 3

parameters array 3 forms of 3 Index Declaration 3 naming 3 scalar 3 specifying values 3 types of 3 parasite entities 1 edges 1 vertices 1 pasting commands to Command text box 3 pause commands 3 periodic boundary conditions 1 perpendicular sweep 1 1a pick-list forms 3 picking entities 1 2 3 3a polygonal faces 1

position parameter u 1 v 1 previous model view 3

Print Graphics command 3 form 3 prism 1 Project Edge On Face 1 projecting edges 1 pyramid 1

Page 476: Gambit Tutorial Guide

Index-Q

Quad-Map meshing scheme 1 Quad-Pave meshing scheme 1 Quad/Tri-Map meshing scheme 1 Quad/Tri-Pave meshing scheme 1 quadrant command buttons 3 quadrants 3 preset configurations 3 resizing 3 Quality Type 2 Quality Type options 3 Area 3 Aspect Ratio 3 Diagonal Ratio 3 Edge Ratio 3 EquiAngle Skew 3 EquiSize Skew 3 MidAngle Skew 3 Stretch 3 Taper 3 Volume 3 Warpage 3 Query Edges 1 Query Faces 1 Query Groups 1 Query Vertices 1 Query Volumes 1 query-list forms 3

querying edges 1 faces 1 groups 1 vertices 1 volumes 1 Quick (help) command 3

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

Index-R

radio buttons 3 Redo command" 3 reflecting an entity 1

removing bumps 1

1 Modeling Guide 2 Tutorial Guide 3 User's Guide

Page 477: Gambit Tutorial Guide

spurs 1 replacing text 3

retaining edges 1 faces 1 1a group members 1 split tool 1 Reversal vertex types 1 reverse grading 1 revolution angle and axis 1 Revolve Edges 1 Revolve Real Faces 1 Revolve Vertices 1 revolving the model 3

revolving edges 1 faces 1 vertices 1 rigid sweep 1 1a rotating an entity 1 rotating the model 3 rotation angle and axis 1 1a

rulers displaying 1 intervals 1 range 1

Run Journal command 3 form 3

Index-S

sashes GUI 3 Save As command 3 Save command 3 Save Session As form 3 saving a session 3 3a saving the session 2 scale factor 3 scaling an entity 1 scratch directory 3 searching for text 3

Page 478: Gambit Tutorial Guide

Select File form 3 SELECT PRESET CONFIGURATION command 2 selecting a file 3 session identifier 3 session title 3 3a

session files 3 opening 3 saving 3 Set Color form 1 3 setting face vertex types 1 setting volume element types 1 shape parameter 1 Side vertex types 1 signals 3 simplifying geometry 1 skin-surface face 1 Slide Virtual Vertex 1 Slide Virtual Vertex 1 slider bars 3

smoothing face meshes 1 volume meshes 1 snap option 1 soft-links 1 Solver menu 3 solvers 1 effect on boundary types 1 source directory 3 spacing 1 specification forms 3 3a Specify Boundary Types 1 Specify Continuum Types 1

Specify Label Type form 3 sphere 1 spherical cut 3 Split Edge 1 Split Face 1 Split Meshed Face 1 split operations 1 split path mesh nodes 1 split point 1 1a split tool 1 1a 1b 1c split types 1 Split Volume 1

Page 479: Gambit Tutorial Guide

splitting edges 1 1a 1b faces 1 1a 1b volumes 1 spurs 1 Stairstep meshing scheme 1 starting GAMBIT 2 3 startup command options 3 Stitch Faces 1 STL files 3 STON string function 3 STRCMP string function 3 Stretch quality metric 3 STRFMT string function 3 string assignment 3 string concatenation 3 string functions 3 CSTRCMP 3 CSTRNCMP 3 DIRNAME 3 DIRPLUSFILE 3 DIRPLUSSUBDIR 3 DS 3 FILENAME 3 FILEPREFIX 3 FILESUFFIX 3 GETCWD 3 GETENV 3 GETIDENT 3 GETSCR 3 NTOS 3 STON 3 STRCMP 3 STRFMT 3 STRLEN 3 STRNCMP 3 STRRSTR 3 STRSTR 3 STRTOLC 3 STRTOUC 3 SUBSTR 3 US 3 STRLEN string function 3 STRNCMP string function 3 STRRSTR string function 3 STRSTR string function 3

Page 480: Gambit Tutorial Guide

STRTOLC string function 3 STRTOUC string function 3 Submap meshing scheme 1 1a subpads 3 subset entities 1 SUBSTR string function 3 Subtract Real Faces 1 Subtract Real Volumes 1

subtracting faces 1 volumes 1 Summarize Boundary Layers 1 Summarize Coordinate Systems 1 Summarize Edges 1 Summarize Face Mesh 1 Summarize Faces 1 Summarize Group Meshes 1 Summarize Groups 1 Summarize Vertices 1 Summarize Volume Mesh 1 Summarize Volumes 1

summarizing boundary layers 1 coordinate systems 1 edge meshes 1 edges 1 face meshes 1 faces 1 group meshes 1 groups 1 vertices 1 volume meshes 1 volumes 1 superset entities 1 Sweep Edges 1 Sweep Real Faces 1 sweep types 1 1a

sweeping edges 1 faces 1

Index-T

T-connect operations 1 1a

Page 481: Gambit Tutorial Guide

Table of Contents command 3 Taper quality metric 3 Tet Primitive meshing scheme 1 text annotation objects 3 text boxes 3 text editor 3 text files 3 viewing 3 text windows 3 TGrid meshing scheme 1 title 3 Title command 3 tolerance criteria 1 1a toolpad command buttons 1 Tools commands 1 Coordinate Systems 1 Activate Coordinate System 1 Create Coordinate System 1 Delete Coordinate Systems 1 Display Grid 1 Display Ruler 1 Modify Coordinate System 1 Summarize Coordinate Systems 1 top-down modeling approach 2 topological validity 1 edges 1 faces 1 groups 1 vertices 1 volumes 1 topology color mode 3 torus 1 Total Entities 1 Transcript window 3 transcript (trn) files 3 transition patterns 1 transition rows 1 translating an entity 1 translating the model 3 Tri Primitive meshing scheme 1 Tri-Pave meshing scheme 1 Trielement vertex types 1 twist method 1 1a

Index-U

Page 482: Gambit Tutorial Guide

Undo command 2 Undo command" 3 undo-group commands 3 Unite Real Faces 1 Unite Real Volumes 1 uniting volumes 2

uniting faces 1 volumes 1 Unlink Mesh Edges 1 US string function 3

Index-V

validity criteria 1 Vector Definition form 1 3 Vertex Blend Type form 1 vertex types 1

vertices aligning 1 checking 1 connecting 1 converting 1 copying 1 creating 1 creating at intersections 1

creating by mouse 1 deleting 1 disconnecting 1 link reference 1 linking 1

modifying color 1 label 1 moving 1 querying 1 sliding 1 summarizing 1

View Face/Vector command 3 form 3

Page 483: Gambit Tutorial Guide

View File command 3 form 3 viewing text files 3 virtual geometry 1 virtual operations 1 merge 1

virtual entities categories 1 classes 1 guest 1 host 1 interpolant 1 orphan 1 parasite 1 subset 1 superset 1

geometry applications 1 fundamentals 1 operations 1 high-level 1 low-level 1

operations geometry clean-up 1 adjusting meshes 1 collapse 1 connect 1 construct 1 merge 1 restrictions 1 simplifying geometry 1 split 1 restrictions 1 T-connect 1 Volume quality metric 3

volumes aligning 1 brick 1 checking 1 checking mesh 1 copying 1 creating 1 cylinder 1 deleting 1

Page 484: Gambit Tutorial Guide

deleting meshes 1 forming 1 revolve faces 1 stitch faces 1 sweep faces 1 wireframe 1 frustum 1 healing 1 intersecting 1 linking meshes 1 merging 1 mesh element types 1

modifying color 1 label 1 moving 1 prism 1 pyramid 1 querying 1 smoothing meshes 1 sphere 1 splitting 1 subtracting 1 summarizing 1 summarizing meshes 1 torus 1 uniting 1

Index-W

Warpage quality metric 3 Wedge Primitive meshing scheme 1 wireframe 1 1a working directory 3

Index-Z

zone types 1

Zones commands Specify Boundary Types 1 Specify Continuum Types 1 zooming the model 3

Page 485: Gambit Tutorial Guide