You are on page 1of 11

INTRODUCTION

Executing GAMBIT Commands

1. INTRODUCTION
GAMBIT is designed for use with a mouse, but most of its operations can also be executed by means of commands entered from the keyboard or from a journal file. The purpose of this manual is to summarize the purpose, format, and use of such commands.

1.1 Executing GAMBIT Commands


GAMBIT commands can be executed from either of two sources:

Keyboard

Journal files

To execute a GAMBIT command from the keyboard, you must input the command on the
Command line and press Enter. (The Command line is located immediately below the
Transcript window on the GAMBIT GUI.) GAMBIT automatically checks the syntax of
any keyboard command and returns an error message in the Transcript window if the
syntax is incorrect or if the command constitutes an illegal operation. In some cases, such
error messages include a list of allowable keywords and/or input variables.
Journal files are text files each line of which constitutes a comment or GAMBIT command. The syntax of GAMBIT journal-file commands is identical to that of commands
entered by means of the keyboard. For a complete description of GAMBIT journal files
and their use, see Section 4.1.6 of the GAMBIT Users Guide.

Fluent Inc., Jul-04

1-1

Command Description Format

INTRODUCTION

1.2 Command Description Format


In this manual, each GAMBIT keyboard command is summarized in its own section. Each
command summary consists of the following components.
Component

Description

Purpose

Describes the general purpose and function of the command

General Form

Describes the command syntax, including keyword hierarchy


and variable type

Example

Shows an example of the command, including one or more


keywords

Keywords

Lists and describes all keywords relevant to the command

1.2.1 Interpreting Command Syntax


GAMBIT commands consist of the following components:

Operator

Keywords

Variables

Operators are string expressions that represent GAMBIT operations. Keywords are string
expressions that represent either control words or options associated with GAMBIT
operations. Variables are numerical or string values that represent parameters associated
with operations and/or keywords.
In this manual, operators, keywords, and variables are represented by the Courier font
and variables are italicized. For example, a command description of the form:
vertex reflect vertex1 [ vertex2 ... ]
vector real1 real2 real3
[ origin real1 real2 real3
vertex vertex ]
[ connected ]

contains the following components.

1-2

Fluent Inc., Jul-04

INTRODUCTION

Command Description Format

Component

Expression

Operator

vertex reflect

Keywords

vector
origin
vertex
connected

Variables

vertex
vertex1
vertex2
real1
real2
real3

Specifying an Operator
Each operator represents a specific GAMBIT operation. For example, the vertex
summarize operator represents the operation that causes GAMBIT to display vertex
summary information in the Transcript window. When you execute any keyboard command, GAMBIT records the operator and all associated keywords and variable values in a
journal file.
Specifying Keywords
Keyword syntax consists of the following components:

Type

Hierarchy

Keyword type determines whether a given keyword is optional or mandatory. Keyword


hierarchy determines which keywords represent suboptions of other keywords.
Keyword Type
There are two types of command keywords:

Optional

Mandatory

Fluent Inc., Jul-04

1-3

Command Description Format

INTRODUCTION

Optional Keywords
Optional keywords are string expressions that are allowed but not required by GAMBIT
commands. For example, in the command description
edge connect [ edge1 edge2 [ edge3 ...]]
[ virtual
[ tolerance real ]]

the keyword virtual is an optional keyword that allows the user to specify that the edge
resulting from the edge connect operation constitutes a virtual edge. Likewise, the
keyword tolerance is an optional keyword that allows the user to specify that the
connection operation is performed only if the specified edges are located within a specified distance relative to each other.
In this manual, optional keywords are always enclosed in square brackets ([]). For
example, a command description of the form
face delete face
[ lowertopology ]
[ onlymesh ]

indicates that the lowertopology and onlymesh options are both allowed but not
required by the face delete command.
If a command includes a set of mutually exclusive optional keywords, the [] brackets
enclose the entire set. For example, a command description of the form
vertex delete vertex
[ onlymesh
onlyblend ]

indicates that the onlymesh and onlyblend keywords represent mutually exclusive
options; therefore, either option is allowed, but neither is required, by the vertex
delete command.
Mandatory Keywords
Mandatory keywords are string expressions that are required by the commands with
which they are associated. For example, in the command description:
edge create [ edge ] fillet edge1 edge2
parameters real1 real2
radius real
[ trim
notrim ]

1-4

Fluent Inc., Jul-04

INTRODUCTION

Command Description Format

the keywords parameters and radius are mandatory keywords, because they are
required in order to execute the command. The keywords trim and notrim, on the other
hand, are optional keywords and are not required by the command.
Sets of mutually exclusive, mandatory keywords are always enclosed in braces ({}). For
example, a command description of the form
edge create [ edge ] circle
{ threepoints vertex1 vertex2 vertex3
center2points vertex1 vertex2 vertex3 }

indicates that you must specify either the threepoints keyword or the
center2points keyword in order to execute the edge create circle command.
Keyword Hierarchy
Keyword hierarchy determines which keywords represent suboptions of other keywords.
In this manual, keyword hierarchy is represented by means of indentation. For example, a
command description of the form
vertex connect vertex1 vertex2
[ virtual
[ tolerance real ]]

indicates that the keyword virtual is allowed but not required by the vertex
connect command and that the keyword tolerance represents a suboption of the
virtual option.
Specifying Variables
Most commands and keywords are associated with variables. Variables represent numerical values or string expressions that define parameters that are allowed or required by
commands or keyword options. For example, in a command description of the form
vertex create [ vertex ] hardpoint face face
coordinates real1 [ real2 [ real3 ]]

the variables vertex and face represent string expressions (entity labels), and the variables real1, real2, and real3 represent real, non-integer numbers (spatial coordinates).
Optional Variables
Optional variables represent values that are allowed but not required by their associated
commands or keywords. In this manual, optional variables are always enclosed in square
brackets ([]). In the example shown above, for instance, the variables vertex, real2,
and real3 are optional, but the variables face and real1 are required.

Fluent Inc., Jul-04

1-5

Command Description Format

INTRODUCTION

Nested Brackets
Some commands and keywords allow or require more than one variable specification. In
this manual, nested square brackets ([[]]) indicate the hierarchy of multiple variables
associated with a single command or keyword. For example, in the vertex create
command description shown above, you can specify real1 without specifying real2
and real3, but you cannot specify real2 without also specifying real1. Likewise, you
cannot specify real3 without also specifying real1 and real2.
Ellipses
In this manual, some specifications of optional variables include ellipses (...). Ellipses
indicate that you can specify more than one variable for the associated command or keyword. For example, a command description of the form
vertex modify vertex1 [ vertex2 ... ]

indicates that, to execute the vertex modify command, you must specify at least one
vertex label (vertex1) but you may also specify any number of additional vertex labels
(vertex2, vertex3, etc.).
Variable Types
There are three types of variables associated with GAMBIT commands:

String

Integer

Real

The command descriptions in this manual include allowable ranges for each variable.
When you specify a string variable, you must enclose the string expression in double
quotation marksfor example,
vertex modify "vertex.7"

When you specify an integer variable, you must not include a decimal point. (NOTE: If
you input a non-integer in field that requires an integer variable, GAMBIT truncates the
input value.)
When you specify a real variable, you can (but are not required to) include a decimal
point.
The following table summarizes the variables used in this manual.

1-6

Fluent Inc., Jul-04

INTRODUCTION

Command Description Format

Variable

Description

Type

Example

vertex

Vertex label

String

"vertex.1"

edge

Edge label

String

"edge.3"

face

Face label

String

"face.16"

volume

Volume label

String

"volume.7"

group

Group label

String

"group.2"

system

Coordinate system label

String

"c_sys.1"

blayer

Boundary layer

String

"blayer.5"

axis

Axis name

String

"x"

real

Real number

Non-integer

6.7

integer

Real number

Integer

11

option

Option number

Integer

color

Color name*

String

"red"

node

Node number

Integer

1034

* Color names are listed in the following table.

Fluent Inc., Jul-04

1-7

Command Description Format

INTRODUCTION

Some GAMBIT commands require the specification of a color variable. For example,
the following command changes the color of a vertex named vertex.2 to purple:
vertex modify "vertex.2" color "purple"

The following table lists the names of all colors available in GAMBIT.
adobered

goldenrod

maroon

purple

aquamarine

green

mediumaquamarine

red

beige

greenyellow

mediumblue

rosybrown

black

grey

mediumpurple

royalblue

blue

hotpink

mediumseagreen

saddlebrown

blueviolet

khaki

mediumslateblue

salmon

brown

lawngreen

mediumspringgreen

sandybrown

burlywood

lightblue

mediumturquoise

seagreen

cadetblue

lightcoral

mediumvioletred

sienna

chocolate

lightcyan

olivedrab

skyblue

coral

lightgoldenrodyellow

orange

slateblue

cyan

lightgoldenrodyellow

orangered

springgreen

darkgreen

lightgreen

orchid

steelblue

darkkhaki

lightpink

palegoldenrod

tan

darksalmon

lightsalmon

palegreen

thistle

darkslateblue

lightseagreen

paleturquoise

tomato

darkturquoise

lightskyblue

palevioletred

turquoise

deeppink

lightslateblue

peru

violet

deepskyblue

lightsteelblue

pink

white

dodgerblue

lightyellow

plum

yellow

firebrick

limegreen

powderblue

yellowgreen

gold

magenta

1-8

Fluent Inc., Jul-04

INTRODUCTION

Command Description Format

Multiple Variables
Some of the command descriptions presented in this manual include multiple variables
that is, two or more variables that correspond to a given command or keyword. When a
command or keyword includes more than one variable of a given type, each variable is
distinguished from the others by a trailing number attached to the variable type specification. For example, in the command description
edge create [ edge ] circle
{ threepoints vertex1 vertex2 vertex3
center2points vertex1 vertex2 vertex3 }

the edge variable does not include a trailing number, because GAMBIT allows you to
specify only one edge label for the edge create circle command. The vertex
variable type specifications, on the other hand, are represented as vertex1, vertex2,
and vertex3 to indicate that you must specify three individual vertices in order to
execute either the threepoints or center2points option.
1.2.2 Example Command Description
As an example of the interpretation principles outlined above, consider the following
command description.
coordinate create [ system ]
[ cartesian
cylindrical
spherical ]
{ rotation
[ oldsystem system ]
[ offset real1 [ real2 [ real3 ]]
[ axis1 axis1 angle1 real1
[ axis2 axis2 angle2 real2
[ axis3 axis3 angle3 real3 ]]]
vertices vertex1 vertex2 vertex3 }

The following outline illustrates the correct interpretation of the command description
shown above in terms of what is required and/or allowed by the command.

Fluent Inc., Jul-04

1-9

Command Description Format

INTRODUCTION

Summary

You can specify a system label (system).

You can specify only one of the following three keywords:


cartesian
cylindrical
spherical

There are no variables or suboptions associated with any of these three keywords.

You must specify one of the following two keywords:


rotation
vertices

If you specify the rotation keyword, you can specify any of the following three
keyword/variable combinations:
oldsystem system
offset real1
axis1 axis1 angle1 real1

If you specify offset real1, you can also include one or two other real
variables in the commandthat is, you can specify the keyword/variable combination in one of the following three forms:
offset real1
offset real1 real2
offset real1 real2 real3

If you specify axis1 axis1 angle1 real1, you can also specify the following keyword/variable combination
axis2 axis2 angle2 real2

If you specify axis2 axis2 angle2 real2, you can also specify the following keyword/variable combination
axis3 axis3 angle3 real3

If you specify the vertices keyword, you must specify three vertex labels
(vertex1, vertex2, and vertex3)
Example
The following example represents a valid GAMBIT coordinate create command.
coordinate create "c_sys.5" rotation offset 5.5 3.7

1-10

Fluent Inc., Jul-04

INTRODUCTION

Command Reference GuideOutline

1.3 Command Reference GuideOutline


The following table summarizes the contents of this guide.
Chapter

Contents

INTRODUCTION

GEOMETRY COMMANDS

MESH COMMANDS

ZONE COMMANDS

TOOLS COMMANDS

MISCELLANEOUS COMMANDS

POSTPROCESSING COMMANDS

Fluent Inc., Jul-04

1-11

You might also like