Professional Documents
Culture Documents
Introduction to Scripting
in HFSS
June 2003
D a te
S o f t w ar e
Ve r s io n
June 2003
9.0
Getting Help
Ansoft Technical Support
To contact Ansoft technical support staff in your geographical area,
please log on to the Ansoft corporate website, http://www.ansoft.com,
click the Contact button, and then click Support. Your Ansoft sales engineer may also be contacted in order to obtain this information.
E-mail can work well for technical support. All Ansoft software files are
ASCII text and can be sent conveniently by e-mail. When reporting difficulties, it is extremely helpful to include very specific information about
what steps were taken or what stages the simulation reached. This
allows more rapid and effective debugging.
Context-Sensitive Help
To access online help from the HFSS user interface, do one of the following:
To open a help topic about an HFSS menu command, press Shift+F1,
and then click the command or toolbar icon.
To open a help topic about an HFSS dialog box, open the dialog box,
and then press F1.
iii
iv
Table of Contents
1. Introduction to VBScript
A Sample HFSS Script . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2
VBScript Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-4
Declaring Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-4
Array Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-4
1-5
1-5
1-6
1-6
Contents-1
2-2
2-6
2-6
2-6
2-6
2-7
2-7
2-7
2-7
2-8
2-8
2-10
Contents-2
CreateCylinder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-6
CreateEllipse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-6
CreateHelix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-7
CreatePoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-8
CreatePolyline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-8
CreateRectangle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-9
CreateRegularPolyhedron . . . . . . . . . . . . . . . . . . . . . . . 10-10
CreateRegularPolygon . . . . . . . . . . . . . . . . . . . . . . . . . . 10-10
CreateSphere . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-11
CreateSpiral . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-12
CreateTorus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-12
EditPolyline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-13
SweepAlongPath . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-14
SweepAlongVector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-14
SweepAroundAxis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-15
CreateObjectFromFaces . . . . . . . . . . . . . . . . . . . . . . . . 10-23
CreateRelativeCS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-24
DeleteLastOperation . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-24
DetachFaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-25
EditEntityList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-25
EditFaceCS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-26
EditRelativeCS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-26
Export . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-26
GenerateHistory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-27
Import . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-27
Intersect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-28
MoveFaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-28
Section . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-29
SeparateBody . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-29
SetModelUnits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-30
SetWCS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-30
Split . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-31
Subtract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-31
UncoverFaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-32
Unite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-33
Contents-6
EditMaster . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-22
EditPerfectE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-22
EditPerfectH . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-22
EditLumpedPort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-22
EditLumpedRLC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-22
EditMagneticBias . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-23
EditRadiation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-23
EditSlave . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-23
EditSymmetry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-23
EditVoltage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-23
EditWavePort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-23
Contents-8
Contents-9
EnterPoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-6
EnterQty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-6
EnterScalar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-7
EnterScalarFunc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-7
EnterSurf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-7
EnterVector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-8
EnterVectorFunc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-8
EnterVol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-9
ExportOnGrid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-9
ExportToFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-10
WriteRegister . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-10
Contents-12
Introduction to VBScript
HFSS uses the Microsoft Visual Basic Scripting Edition (VBScript) scripting
language to record macros. VBScript is based on the Microsoft Visual Basic
programming language.
Using scripts is a fast, effective way to accomplish tasks you want to repeat.
When you execute a script, the commands in the script are performed.
You can write a script using any text editor or you can record a script from
within the HFSS interface. After recording the script from within HFSS, you
can then modify it if necessary using a text editor.
Although HFSS records scripts in VBScript format, it can also execute scripts
in JavaScriptTM format. If you are running a script from a command prompt,
the script can be written in any language that provides the Microsoft COM
methods. The HFSS scripting documentation refers to VBScript format only.
This chapter provides an overview of key VBScript components. For more
details about VBScript, please see the Recommended VBScript References
section at the end of this chapter.
In a Sub or Function procedure call, you can group the input parameters inside
parentheses or without parentheses. Here the four strings are the input parameters of
the Sub procedure InsertDesign of the object oProject.
Set oDesign = oProject.SetActiveDesign("HFSSModel1")
Set oEditor = oDesign.SetActiveEditor("3D Modeler")
oEditor.CreateBox Array("NAME:BoxParameters", "XPosition:=", _
"0mm", "YPosition:=", "0mm", "ZPosition:=", "0mm", _
"XSize:=", "1.6mm", "YSize:=", "1.2mm", "ZSize:=", _
"0.8mm"), Array("NAME:Attributes", "Name:=", "Box1", "Flags:=", _
"", "Color:=", "(132 132 193)", "Transparency:=", _
0.400000005960464, "PartCoordinateSystem:=",
For additional HFSS script examples, see Chapter 20, Example Scripts.
VBScript Variables
A VBScript variable is a placeholder representing information that may change during the time
your script is running. Use a variable name in a script to view or modify its value.
Declaring Variables
To declare variables explicitly in a script, use the Dim, Public, or Private statements. For
example:
Dim box_xsize
After declaring a variable, you can assign information to it. For example:
box_xsize = 3mm
Array Variables
Create an array variable when you want to assign more than one related value to a single variable. An array variable contains a series of values. For example:
Dim Primitives(2)
All arrays in VBScript are zero-based, so the array above actually contains 3 elements. You assign
data to each of the arrays elements using an index into the array. Data can be assigned to the
elements of an array as follows:
Primitives(0) = Box1
Primitives(1) = Cone1
Primitives(2) = Cylinder1
Similarly, the data can be retrieved from any element using an index into a particular array element. For example:
one_prim = Primitives(1)
You can also use the Array function to assign an array of elements to a variable. For example:
Dim Primitives
Primitives = Array (Box1, cone1, Cylinder1)
Note
When using the Array function, do not use parentheses on the variable when it is
declared. For example, use Dim myarray, not Dim myarray().
VBScript Operators
VBScript provides operators, which are grouped into these categories: arithmetic operators,
comparison operators, and logical operators.
Please see the online VBScript Users Guide for more details.
Operator Precedence
When several operations occur in an expression, each part is evaluated and resolved in a predetermined order, called operator precedence. You can use parentheses to override the order of
precedence and force some parts of an expression to be evaluated before others. Operations
within parentheses are always performed before those outside the parentheses. Within parentheses, however, standard operator precedence is maintained.
When expressions contain operators from more than one category, arithmetic operators are
evaluated first, comparison operators are evaluated next, and logical operators are evaulated
last. Comparison operators all have equal precedence, that is, they are evaluated in the left-toright order in which they appear. Arithmetic and logical operators are evaluated in the following
order of precedence.
Arithmetic Operators
Following is a list of VBScripts arithmetic operators.
Symbol
Description
Exponentiation
Unary negation
Multiplication
Division
Integer division
Mod
Modulus arithmetic
Addition
Subtraction
&
String concatenation
Comparison Operators
Following is a list of VBScripts comparison operators.
Symbol
=
Description
Equality
<>
Inequality
<
Less than
>
Greater than
<=
>=
Is
Object equivalence
Logical Operators
Following is a list of VBScripts logical operators:
Symbol
Description
Not
Logical negation
And
Logical conjunction
Or
Logical disjunction
Xor
Logical exclusion
Eqv
Logical equivalence
Imp
Logical implication
Using If...Then...Else
Following is an example that demonstrates the If...Then...Else conditional statement:
If obj = "Box1" Then
<statements to execute>
ElseIf obj = "Cylinder1" Then
<statements to execute>
Else
<statements to execute>
End If
Syntax: CStr(variablename).
Converts variablename to a string. For example, it can be used to
convert the number 2.5 to the string 2.5.
CBool
Syntax: CBool(variablename).
Converts variablename to a boolean. If variablename is 0 or 0,
CBool returns False. Otherwise it returns True.
CDbl
Syntax: CDbl(variablename).
Converts variablename to a double precision number. For example,
it can be used to convert the string 2.5 to the number 2.5.
CInt
Syntax: CInt(variablename).
Converts variablename to an integer.
This chapter provides an overview of HFSS scripting using VBScript. Information is included on the following topics:
HFSS script variables.
Recording, running, pausing, resuming, and stopping a script.
Modifying a script for easier playback.
HFSS scripting conventions, including script command syntax used in this
guide, named arguments, and setting numerical values.
Executing a script from within a script.
Modifying properties.
oHfssApp
The oHfssApp object provides a handle for VBScript to access the AnsoftHfss product.
One example of accessing this object is:
Set oHfssApp = CreateObject(AnsoftHfss.HfssScriptInterface)
oDesktop
The oDesktop object is used to perform desktop-level operations, including project management.
One example of accessing this object is:
Set oDesktop = oHfssApp.GetAppDesktop()
See Chapter 3, Desktop Object Script Commands, for details about script commands recognized
by the oDesktop object.
oProject
The oProject object corresponds to one project open in the product. It is used to manipulate
the project and its data. Its data includes variables, material definitions and one or more
designs. One example of accessing this object is:
Set oProject = oDesktop.GetActiveProject()
See the following chapters for details about the script commands recognized by the oProject
object:
oDesign
The oDesign object corresponds to an instance of a design in the project. This object is used to
manipulate the design and its data. Its data includes variables, modules, and editors.
One example of accessing this object is:
Set oDesign = oProject.GetActiveDesign()
See the following chapters for details about the script commands recognized by the oDesign
object:
oEditor
The oEditor object corresponds to an editor, such as the 3D Modeler. This object is used to add
and modify data in the editor.
One example of accessing this object is:
Set oEditor = oDesign.SetActiveEditor(3D Modeler)
The AnsoftHfss product scripting supports the following editors:
Editor
Name in Script
3D Modeler Editor
3D Modeler
Reporter Editor
See Chapter 10, 3D Modeler Editor Script Commands, for details about the script commands recognized by the oEditor object and Chapter 11, Reporter Editor Script Commands for details
about Reporter editor commands.
oModule
The oModule object corresponds to a module in the design. Modules are used to handle a set of
related functionality.
One example of accessing this object is:
Set oModule = oDesign.GetModule(BoundarySetup)
Name in Script
BoundarySetup
MeshSetup
AnalysisSetup
Optimetrics
Solutions
FieldsReporter
RadField
Chapter
Recording a Script
Once you start to record a script, your subsequent actions are added to the script. Each interface command has one or more associated script commands that are recorded to the script. The
script is recorded to a text file in .vbs (VBScript) file format.
Running a Script
1 On the Tools menu, click Run Script.
2
3
Stopping a Script
A quoted string.
<bool>
<double>
<int>
An integer. Example: 1
<value>
Command:
Lists the interface command that corresponds to the script command. Menu
commands are separated by carats. For example,
HFSS>Excitations>Assign>Wave Port.
Syntax:
Return Value:
Parameters:
Example:
Named Arguments
Many HFSS script commands use named arguments. The names can appear in three ways:
1. Named data, name precedes data.
For example: ...,"SolveInside:=", true, ...
2. Named Array, name precedes array.
For example: ...,"Attributes:=", Array(...),...
3. Named Array, name inside array.
For example: ..., Array("NAME:Attributes",...),...
In the first and second examples, the name is formatted as <Name>:=. This signals HFSS that
this is a name for the next argument in the script command. In the third example, the name is
formatted as NAME:<name> and is the first element of the Array.
The names are used both to identify what the data means to you and to inform HFSS which data
is being given. The names must be included or the script will not play back correctly. However, if
you are writing a script, you do not need to pass in every piece of data that the command can
2-8 HFSS and VBScript
take. For example, if you are modifying a boundary, the script will be recorded to include every
piece of data needed for the boundary, whether or not it was modified. If you are writing a
script by hand, you can just add the data that changed and omit anything that you do not want
to change. HFSS will use the names to determine which data you provided.
For example, when editing an impedance boundary, HFSS records the edit impedance boundary
command as follows:
oModule.EditImpedance "Imped1", Array("NAME:Imped1", _
"Resistance:=", "100", "Reactance:=", "50", _
"InfGroundPlane:=", false)
If you only want to change the resistance, then you can leave out the other data arguments
when you are manually writing a script:
oModule.EditImpedance "Imped1", Array("NAME:Imped1", _
"Resistance:=", "100")
<ScriptName>
If the full path to the script is not specified, HFSS searches for the specified script in the following locations, in this order:
Editing Properties
Any data that is shown in the dockable Properties dialog box or in the modal Properties pop-up
window is called a property. For example, project and local variables are properties. The XSize
of a box in the Geometry editor is also a property. See Chapter 6, Property Script Commands,
for an explanation of how to manipulate properties in a script.
CloseProject
Use:
Closes a specified project. Changes to the project will not be saved. Save
the project using the Project command Save or SaveAs before closing to
save changes.
Command:
File>Close
Syntax:
CloseProject <ProjectName>
Return Value:
None
Parameters:
<ProjectName>
Type: <string>
Example:
oDesktop.CloseProject Project1
GetActiveProject
Use:
Command:
None
Syntax:
GetActiveProject
Return Value:
Parameters:
None
Example:
GetProjectList
Use:
Command:
None
Syntax:
GetProjectList
Return Value:
Parameters:
None
Example:
list_of_projects = oDesktop.GetProjectList()
NewProject
Use:
Creates a new project. The new project becomes the active project.
Command:
File>New
Syntax:
NewProject
Return Value:
Parameters:
None
Example:
OpenMultipleProjects
Use:
Command:
File>Multiple Open
Syntax:
Return Value:
None
Parameters:
<Directory>
Type: <string>
<FileType>
Type: <string>
Example:
OpenProject
Use:
Command:
File>Open
Syntax:
OpenProject <FileName>
Return Value:
Parameters:
Example:
oDesktop.OpenProject D:/Projects/Project1.hfss
PauseScript
Use:
Pauses the scripts execution and displays a message in a pop-up dialog box
to the user. The script execution will not resume until the user clicks
Tools>Resume Script.
Command:
Tools>Pause Script
Syntax:
PauseScript <Message>
Return Value:
None
Parameters:
<Message>
Type: <string>
Example:
Print
Use:
Command:
File>Print
Syntax:
Return Value:
None
Parameters:
None
Example:
oDesktop.Print
QuitApplication
Use:
Command:
File>Exit
Syntax:
QuitApplication
Return Value:
None
Parameters:
None
Example:
oDesktop.QuitApplication
RestoreWindow
Use:
Command:
None
Syntax:
RestoreWindow
Return Value:
None
Parameters:
None
Example:
oDesktop.RestoreWindow
RunProgram
Use:
Command:
None
Syntax:
Return Value:
None
Parameters:
<ProgName>
Type: <string>
Name of the program to run.
<ProgPath>
Type: <string>
Location of the program. Pass in an empty string to use the system path.
<WorkPath>
Type: <string>
Working directory in which program will start.
<ArgArray>
Type: Array of strings
Arguments to pass to the program. If no arguments, pass in None.
Example:
oDesktop.RunProgram "winword.exe", _
"C:\Program Files\Microsoft Office\Office10",_
"", None
RunScript
Use:
Launches another script from within the script currently being executed.
Command:
Tools>Run Script
Syntax:
RunScript <ScriptPath>
Return Value:
None
Parameters:
<ScriptPath>
Type: <string>
Name or full path of the script to execute. If the full path to the script
is not specified, HFSS searches for the specified script in the following
locations, in this order:
Example:
oDesktop.RunScript "C:/Project/test1.vbs"
SetActiveProject
Use:
Command:
None
Syntax:
SetActiveProject <ProjectName>
Return Value:
Parameters:
<ProjectName>
Type: <string>
Example:
Sleep
Use:
Command:
none
Syntax:
Sleep <TimeInMilliseconds>
Return Value:
None
Parameters:
<TimeInMilliseconds>
Example:
oDesktop.Sleep 1000
Type: <int>
Project commands should be executed by the oProject object. One example of accessing this object is:
Set oProject = oDesktop.GetActiveProject()
Close
Use:
Command:
None
Syntax:
Close
Return Value:
None
Parameters:
None
Example:
oProject.Close
CopyDesign
Use:
Copies a design.
Command:
Edit>Copy
Syntax:
CopyDesign <DesignName>
Return Value:
None
Example:
oProject.CopyDesign HFSSModel1
CutDesign
Use:
Cuts a design from the active project. The design is stored in memory and
can be pasted in any HFSS project.
Command:
Edit>Cut
Syntax:
CutDesign <DesignName>
Return Value:
None
Example:
oProject.CutDesign HFSSModel1
DeleteDesign
Use:
Command:
Edit>Delete
Syntax:
DeleteDesign <DesignName>
Return Value:
None
Example:
oProject.DeleteDesign HfssModel2
GetActiveDesign
Use:
Command:
None
Syntax:
GetActiveDesign
Return Value:
Parameters:
None
Example:
GetDesign
Use:
Command:
None
Syntax:
GetDesign <DesignName>
Return Value:
Parameters:
<DesignName>
Type: <string>
Name of the design to return.
Example:
GetName
Use:
Command:
None
Syntax:
GetName
Return Value:
Parameters:
None
Example:
name = oProject.GetName ()
GetPath
Use:
Command:
None
Syntax:
GetPath
Return Value:
The path to the project, which does not include the project name.
Parameters:
None
Example:
path = oProject.GetPath ()
GetTopDesignList
Use:
Command:
None
Syntax:
GetTopDesignList
Return Value:
Parameters:
None
Example:
name_list = oProject.GetTopDesignList ()
InsertDesign
Use:
Inserts a new design in the project. In HFSS scripts, the last argument will
always be empty.
Command:
Syntax:
Return Value:
None
Parameters:
<DesignName>
Type: <string>
Name of the new design.
<SolutionType>
Type: <string>
Solution type of the new design. Can be DrivenModal,
DrivenTerminal, or Eigenmode.
Example:
Paste
Use:
Command:
Edit>Paste
Syntax:
Paste
Return Value:
None
Parameters:
None
Example:
oProject.Paste
Redo
Use:
Command:
Edit>Redo
Syntax:
Redo
Return Value:
None
Parameters:
None
Example:
oProject.Redo
Save
Use:
Command:
File>Save
Syntax:
Save
Return Value:
None
Parameters:
None
Example:
oProject.Save
SaveAs
Use:
Command:
File>Save As
Syntax:
Return Value:
None
Parameters:
<FileName>
Type: <string>
New name for the file.
<OverWrite>
Type: <bool>
Set to true if an existing project by that name should be overwritten.
Example:
SetActiveDesign
Use:
Command:
None
Syntax:
SetActiveDesign <DesignName>
Return Value:
Parameters:
<DesignName>
Type: <string>
Name of the design to set as the active design.
Example:
SimulateAll
Use:
Command:
None
Syntax:
None
Return Value:
Parameters:
None
Example:
oProject.SimulateAll
Undo
Use:
Command:
Edit>Undo
Syntax:
Undo
Return Value:
None
Parameters:
None
Example:
oProject.Undo
AddMaterial
Use:
Command:
Syntax:
AddMaterial Array(NAME:<MaterialName>,
<MatProperty>, <MatProperty>, ...)
Return Value:
None
Parameters:
uTesla
Example:
oProject.AddMaterial Array("NAME:Material2",_
"dielectric_loss_tangent:=", "44",
Array("NAME:saturation_mag",_
"property_type:=", "AnisoProperty",_
"unit:=", "Gauss",_
"component1:=", "11", _
"component2:=", "22", _
"component3:=", "33"), _
"delta_H:=", "44Oe")
EditMaterial
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<OriginalName>
Type: <string>
Name of the material before editing.
<NewName>
Type: <string>
New name for the material.
ExportMaterial
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<ExportData>
Array("NAME:<LibraryName>",
<MaterialName>, <MaterialName>, ...)
Example:
oProject.ExportMaterial Array("NAME:mo0907b",_
"Material1", Material2", "Material3),_
UserLib"
Material Script Commands 5-3
RemoveMaterial
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<MaterialName>
Type: <string>
Name of the material to be removed.
<IsProjectMaterial>
Type: <bool>
If true, HFSS assumes the material is a project material. In this case,
the last two parameters will be ignored.
<LibraryName>
Type: <string>
The name of the user or personal library where the material resides.
<LibraryLocation>
Type: <string>
Should be UserLib or PersonalLib.
Example:
Example:
"UserLib"
"Project"
Property
Refers to a single item that can be modified in the dockable Properties
dialog box or in the modal Properties pop-up window.
<PropServer>
Refers to the item whose properties are being modified. This is usually a
compound name giving all the information needed by the editor, design,
or project to locate the item being edited.
<PropTab>
Corresponds to one tab in the Property dialog box the tab under which
properties are being edited.
<PropName>
Name of a single property .
<PropTab>
ProjectVariableTab
AnsoftHfss Design
Local Variables:
<PropServer>
LocalVariables
<PropTab>
LocalVariableTab
AnsoftHfss Modules
<PropServer>
Format is: <ModuleName>:<ItemName>, where <ItemName> is the
boundary name, solution setup name, etc., depending on which module
is being edited.
Example: <PropServer> for the boundary PerfE1 is
BoundarySetup:PerfE1
<PropTab>
Boundary module: HfssTab
Mesh Operations module: MeshSetupTab
Analysis module: HfssTab
Optimetrics module: OptimetricsTab
Solutions module: Does not support properties.
Field Overlays module: FieldsPostProcessorTab
Radiation module: RadFieldSetupTab
AnsoftHfss 3D Model Editor
Object in the module:
<PropServer>
Name of the object. For example: Box1.
<PropTab>
6-2 Property Script Commands
Geometry3DAttributeTab
Operation on an object:
<PropServer>
Format is <ObjName>:<OpperationName>:<int>
Concatenation of object name, operation name, and the index of the
operation.
For example: "Box2:CreateBox:2" refers to the second
CreateBox command in Box2s history.
<PropTab>
Geometry3DCmdTab
ChangeProperty
Use:
Command:
None
Syntax:
Return Value:
None
Parameters:
<PropTabArray>
Array(Name:<PropTab>,
<PropServersArray>,
<NewPropsArray>,
<ChangedPropsArray>,
<DeletedPropsArray>)
<PropServersArray>
Array(Name:PropServers, <PropServer>,
<PropServer>, ...)
<NewPropsArray>
Array(Name:NewProps, <PropDataArray>,
<PropDataArray>,...)
<ChangedPropsArray>
Array(Name:ChangedProps,<PropDataArray>,
<PropDataArray>, ...)
<DeletedPropsArray>
Array(Name:DeletedProps, <PropName>,
<PropName>, ...)
<PropDataArray>
Array("NAME:<PropName>",
PropType:=, <PropType>,
NewName:=, <string>,
Description:=, <string>,
NewRowPosition:=, <int>,
ReadOnly:=, <bool>,
Hidden:=, <bool>,
<PropTypeSpecificArgs>)
<PropType>
Type: string
Identifies the type of property when a new property is added. In HFSS,
only separator properties and variable properties can be added.
"SeparatorProp"
VariableProp"
TextProp
"NumberProp"
"ValueProp"
CheckboxProp"
MenuProp
PointProp"
VPointProp"
"V3DPointProp"
"ButtonProp"
NewName
Specify the new name of a property if the propertys name is being
edited. In HFSS, the name can only be changed for separators and variables.
Description
Specify a description of the property. In HFSS, the description can only
be changed for separators and variables.
NewRowPosition
Used to reorder rows in the Property dialog box. In HFSS, this only
applies to the Project>Project Variables panel and the Hfss>Design
Property Script Commands 6-5
Properties panel. Specify the new zero-based row index of the variable
or separator.
ReadOnly
Used to mark a property as read only so it can not be modified. In
HFSS, this flag can only be set for variables and separators.
Hidden
Used to hide a property so it can not be viewed outside of the Property
dialog box. In HFSS, this flag can only be set for variables and separators.
<PropTypeSpecificArgs>
SeparatorProp: no arguments
TextProp: Value:=, <string>
NumberProp: Value:=, <double>
ValueProp: Value:=, <value>
CheckboxProp: Value:=, <bool>
MenuProp: Value:=, <string>
PointPropX:=", <double>, "Y:=", <double>
VPointProp: "X:=", <value>, "Y:=", <value>
V3DPointProp: "X:=",<value>, "Y:=",<value>,
"Z:=",<value>
Material Button: Material:=, <string>
Color Button: "R:=",<int>,"G:=",<int>,"B:=",<int>
Transparency Button:Value:=, <double>
<PropTypeSpecificArgs> for VariableProps
Syntax:
Value:=, <value>, <OptimizationFlagsArray>,
<TuningFlagsArray>, <SensitivityFlagsArray>,
<StatisticsFlagsArray>
Parameters:
<OptimizationFlagsArray>
Array("NAME:Optimization",
6-6 Property Script Commands
"Included:=", <bool>,
"Min:=", <value>,
"Max:=", <value>)
<Tuning flagsArray>
Array("NAME:Tuning",
"Included:=", <bool>,
"Step:=", <value>,
"Min:=", <value>,
"Max:=", <value>)
<SensitivityFlagsArray>
Array("NAME:Sensitivity",
"Included:=", <bool>,
"Min:=", <value>,
"Max:=", <value>,
"IDisp:=", <value> )
<StatisticsFlagsArray>
Array(NAME:Statistical,
Included:=, <bool>,
Dist:=, <Distribution>,
StdD:=, <value>,
Min:=, <value>,
Max:=, <value>,
Tol:=, <string>)
<Distribution>
Type: string
Value should be Gaussian or Uniform
StdD
Standard deviation.
Min
Property Script Commands 6-7
Example:
Example:
GetProperties
Use:
Command:
None
Syntax:
Return Value:
Variant array of strings the names of the properties belonging to the prop
server.
Example:
Dim all_props
all_props = oDesign.GetProperties(HfssTab,_
"BoundarySetup:WavePort1")
GetPropertyValue
Use:
Gets the value of a single property. This can be executed by the oProject,
oDesign, or oEditor variables.
Command:
None
Syntax:
Return Value:
Example:
value_string = _
oEditor.GetPropertyValue(Geometry3DCmdTab,_
Box1:CreateBox:1, XSize)
GetVariables
Use:
Syntax:
GetVariables()
Return Value:
Example:
Dim var_array
Example:
project_var_array = oProject.GetVariables()
Example:
local_var_array = oDesign.GetVariables()
GetVariableValue
Use:
Gets the value of a single variable. To get the value of Project variables,
execute this command using oProject. To get the value of local variables,
use oDesign.
Command:
None
Syntax:
GetVariableValue( <VarName> )
Return Value:
Parameters:
<VarName>
Type: string
Name of the variable to access.
Example:
project_var_value_string =
oProject.GetVariableValue(var_name)
Example:
local_var_value_string =
oDesign.GetVariableValue(var_name)
SetPropertyValue
Use:
Sets the value of one property. This is not supported for properties of the
following types: ButtonProp, PointProp, V3DPointProp, and
VPointProp. Only the ChangeProperty command can be used to modify
these properties. This can be executed by the oProject, oDesign, or
oEditor variables.
Command:
None
Syntax:
Return Value:
None
Parameters:
<PropValue>
Type: String
Contains the value to set the property. The formatting is different
depending on what type of property is being edited. Use
GetPropertyValue for the desired property to see the expected
format.
Example:
oEditor.SetPropertyValue _
Geometry3DCmdTab,Box1:CreateBox:1,_
XSize, 3mm
SetVariableValue
Use:
Sets the value of a variable. To set the value of a Project variable, execute
this command using oProject. To set the value of a local variable, use
oDesign.
Syntax:
Return Value:
None
Parameters:
<VarValue>
Type: <value>
New value for the variable.
Example:
Example:
var_value = 2Ohm
oDesign.SetVariableValue Var2, var_value
Dim all_props
Dim prop
all_props = oEditor.GetProperties(Geometry3DCmdTab,_
Box1:CreateBox:1)
For Each prop In all_props
val = oEditor.GetPropertyValue(Geometry3DCmdTab,_
Box1:CreateBox:1, prop)
new_val = InputBox("New Value of " + prop + ":",_
"Current Value of '" + prop + "' is " + val, val)
If new_val <> val Then
oEditor.SetPropertyValue Geometry3DCmdTab,_
Box1:CreateBox:1, prop, new_val
val = _
oEditor.SetPropertyValue(Geometry3DCmdTab,_
Box1:CreateBox:1, prop)
MsgBox("Now the value of '" + prop + "' is " + val)
End If
Next
AddDataset
Use:
Adds a dataset.
Command:
Project>Datasets>Add
Syntax:
AddDataset <DatasetDataArray>
Return Value:
None
Parameters:
<DatasetDataArray>
Array("NAME:<DatasetName>,
Array(NAME:Coordinates, <CoordinateArray>,
<CoordinateArray>, ...)
<DatasetName>
Type: <string>
Name of the dataset.
<CoordinateArray>
Array("NAME:Coordinate",
"X:=", <double>, "Y:=", <double>)
Example:
oProject.AddDataset Array("NAME:ds1",_
Array("NAME:Coordinates",_
Array("NAME:Coordinate", "X:=", 1, "Y:=", 2,_
Array("NAME:Coordinate", "X:=", 3, "Y:=", 4),_
Array("NAME:Coordinate", "X:=", 5, "Y:=", 7),_
Array("NAME:Coordinate", "X:=", 6, "Y:=", 20)))
DeleteDataset
Use:
Command:
Project>Datasets>Remove
Syntax:
DeleteDataset <DatasetName>
Return Value:
None
EditDataset
Use:
Modifies a dataset. When a dataset is modified, its name as well as its data
can be changed.
Command:
Project>Datasets>Edit
Syntax:
Return Value:
None
Parameters:
<OriginalName>
Type: <string>
Name of the dataset before editing.
Example:
AbortSolveAsynch
Use:
Command:
none
Syntax:
AbortSolveAsynch <SetupName>
Return Value:
None
Example:
oDesign.AbortSolveAsynch Setup1
ApplyMeshOps
Use:
If there are any mesh operations that were defined and not yet performed
in the current variation for the specified solution setups, they will be
applied to the current mesh. If necessary, an initial mesh will be computed
first. No further analysis will be performed.
Command:
Syntax:
ApplyMeshOps <SetupNameArray>
Return Value:
<SetupNameArray>
Type: <int>
-1: completed with error
0: completed successfully
Example:
GetModule
Use:
Command:
none
Syntax:
GetModule <ModuleName>
Return Value:
Module object.
Example:
GetName
Use:
Command:
none
Syntax:
GetName
Return Value:
Example:
name_string = oDesign.GetName
Type: <string>
GetSolveAsynchStatus
Use:
Command:
none
Syntax:
GetSolveAsynchStatus <SetupName>
Return Value:
Type: <int>
-1: completed with error
1: still running
0: completed with no error
Example:
Redo
Use:
Command:
Edit>Redo
Syntax:
Redo
Return Value:
None
Example:
oDesign.Redo
RenameDesignInstance
Use:
Command:
Right click a design instance in the project tree, and then click Rename on
the shortcut menu.
Syntax:
Return Value:
None
Example:
SARSetup
Use:
Command:
HFSS>Fields>SAR Setting
Syntax:
Return Value:
None
Parameters:
<TissueMass>
Type: <double>
Double between 1 and 10 in grams.
<MaterialDensity>
Type: <double>
Positive double in gram/cm3.
Example:
oDesign.SARSetup 1, 1
SetActiveEditor
Use:
Command:
None
Syntax:
SetActiveEditor(<EditorName>)
Return Value:
Editor object
Example:
SetSolutionType
Use:
Command:
HFSS>Solution Type
Syntax:
SetSolutionType <SolutionType>
Return Value:
None
Parameters:
<SolutionType>
Type: <string>
Possible values are: DrivenModal, DrivenTerminal,or
Eigenmode
Example:
oDesign.SetSolutionType "DrivenTerminal"
Solve
Use:
Command:
HFSS>Analyze
Syntax:
Solve <SetupNameArray>
Return Value:
Type: <int>
-1: command execution error
1: simulation error
0: normal completion
Parameters:
Example:
SolveAsynch
Use:
Command:
none
Syntax:
SolveAsynch <SetupName>
Return Value:
Type: <int>
-1: command execution error
1: simulation error
0: normal completion
Example:
Undo
Use:
Command:
Edit>Undo
Syntax:
Undo
Return Value:
None
Example:
oDesign.Undo
AddOutputVariable
Use:
Adds a new output variable to the output variable list. Output variables are
associated with a name and an expression. The name of an output variable
is not permitted to collide with design variables, Sim values, or other output
variable names. It cannot have spaces or any arithmetic or other operators.
The definitions can not be cyclic. For example, A = 2*B, B=3*A is not
allowed.
Syntax:
Return Value:
None
Parameters:
<VarName>
Type: <string>
Name of the output variable.
<Expression>
Type: <value>
Value to assign to the variable.
DeleteOutputVariable
Use:
Syntax:
DeleteOutputVariable <VarName>
Return Value:
None
EditOutputVariable
Use:
Syntax:
Return Value:
None
Parameters:
<OrigVarName>
Type: <string>
Original name of the variable.
<NewVarName>
Type: <string>
New name of the variable if any, or else pass an empty string.
<NewExpression>
Type: <value>
New value to assign to the variable.
GetOutputVariableValue
Use:
Gets the double value of an output variable. Only those expressions that
return a double value are supported. The expression is evaluated only for a
single point.
Syntax:
Return Value:
Parameters:
<SolutionName>
Type: <string>
Name of the solution as listed in the Traces dialog box.
For example: Setup1 : Last Adaptive
<IntrinsicVariation>
Type: <string>
A set of intrinsic variables, value pairs to use when evaluating the output expression.
Example: "Freq='20GHz' Theta='20deg' Phi='30deg'
Output Variable Script Commands 9-3
<SimValueContext>
Type: <string>
Context for which the output variable expression is being evaluated.
This can be an empty string if there is no context (for example, for Sparameters).
Example: "Infinite Sphere1" or Line1 or
Example:
Dim Val
Val=oDesign.GetOutputVariableValue "OutVarTest",_
"Setup1 : Sweep1",_
"Freq='20GHz' Theta='20deg' Phi='30deg'",_
"Infinite Sphere1"
10
NonModel
Wireframe
Color
Format is a string containing an R,G,B triple formatted as (R G B).
Example: Color:=,
(255
255
255)
Transparency
Specify a number between 0 and 1.
PartCoordinateSystem
Orientation of the primitive. The name of one of the defined coordinate
systems should be specified.
<SelectionsArray>
Array("NAME:Selections",
"Selections:=", <string>)
Selections
Comma-separated list of parts on which to perform the operation.
Example: Selections:=, Rect1, Rect2
Command:
Draw>Bondwire
Syntax:
Return Value:
None
Parameters:
<ParametersArray>
Array("NAME:BondwireParameters",
"WireType:=", <string>,
"WireDiameter:=", <value>,
"NumSides:=", <value>,
"XPadPos:=", <value>,
"YPadPos:=", <value>,
"ZPadPos:=", <value>,
"XDir:=", <value>,
"YDir:=", <value>,
"ZDir:=", <value>,
"Distance:=", <value>,
"h1:=", <value>,
"h2:=", <value>,
"alpha:=", <value>,
"beta:=", <value>,
"WhichAxis:=", <string>)
WireType
Should be one of: JEDEC_4Points, JEDEC_5Points
Example: WireType:=, JEDEC_4Points
WhichAxis
Axis normal to the plane where the wire is drawn. Possible values are:
X, Y, Z
Example: WhichAxis:=, Z means the bond wire will be drawn
on the XY plane.
CreateBox
Use:
Command:
Draw>Box
Syntax:
Return Value:
None
Parameters:
<BoxParametersArray>
Array(NAME:BoxParameters,
XPosition:=, <value>,
YPosition:=, <value>,
ZPosition:=, <value>,
XSize:=,<value>,
YSize:=,<value>,
ZSize:=,<value>)
CreateCircle
Use:
Command:
Draw>Circle
Syntax:
Return Value:
None
Parameters:
<CircleParametersArray>
Array("NAME:CircleParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"Radius:=", <value>,
"WhichAxis:=", <string>)
WhichAxis
Axis of normal vector to the circle. Possible values are: X, Y, Z
Example: WhichAxis:=, Z means the circle will be drawn in the
XY plane.
CreateCone
Use:
Command:
Draw>Cone
Syntax:
Return Value:
None
Parameters:
<ConeParametersArray>
Array("NAME:ConeParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"WhichAxis:=", <string>,
"Height:=", <value>,
"BottomRadius:=", <value>,
"TopRadius:=", <value>)
WhichAxis
Axis of the cone. Possible values are: X, Y, Z
Example: WhichAxis:=, Z
CreateCutplane
Use:
Command:
Draw>Plane
Syntax:
CreateCutplane <CutplaneParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<CutplaneParametersArray>
Array(NAME:PlaneParameters,
"PlaneBaseX:=", <value>,
"PlaneBaseY:=", <value>,
"PlaneBaseZ:=", <value>,
"PlaneNormalX:=", <value>,
"PlaneNormalY:=", <value>),
"PlaneNormalZ:=", <value>)
CreateCylinder
Use:
Command:
Draw>Cylinder
Syntax:
CreateCylinder <CylinderParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<CylinderParametersArray>
Array(NAME:CylinderParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"Radius:=", <value>,
"Height:=", <value>,
"WhichAxis:=", <string>)
WhichAxis
Axis of the cylinder. Possible values are: X, Y, Z
Example: WhichAxis:=, Z
CreateEllipse
Use:
Command:
Draw>Ellipse
Syntax:
Return Value:
None
Parameters:
<EllipseParametersArray>
Array("NAME:EllipseParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"MajRadius:=", <value>,
"Ratio:=", <value>,
"WhichAxis:=", <string>)
WhichAxis
Axis of normal vector to the ellipse. Possible values are: X, Y,
Z
Example: WhichAxis:=, Z means the ellipse will be drawn in
the XY plane.
CreateHelix
Use:
Command:
Draw>Helix
Syntax:
Return Value:
None
Parameters:
<SelectionsArray>
Array("NAME:Selections",
"Selections:=", <string>)
Selections
Comma-separated list of parts to sweep.
Example: Selections:=, Rect1, Rect2
<HelixParametersArray>
Array("NAME:HelixParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"XStartDir:=", <value>,
"YStartDir:=", <value>,
"ZStartDir:=", <value>,
"Thread:=", <value>,
"NumThread:=", <value>,
"RightHand:=", <bool>)
CreatePoint
Use:
Command:
Draw>Point
Syntax:
Return Value:
None
Parameters:
<PointParametersArray>
Array(NAME:PointParameters,
"PointX:=", <value>,
"PointY:=", <value>,
"PointZ:=", <value>)
CreatePolyline
Use:
Command:
Draw>Polyline
Syntax:
CreatePolyline <PolylineParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<PolylineParametersArray>
Array("NAME:PolylineParameters",
IsPolylineCovered:=", <bool>,
"IsPolylineClosed:=", <bool>,
<PolylinePointsArray>,
<PolylineSegmentsArray>)
<PolylinePointsArray>
Array("NAME:PolylinePoints", <OnePointArray>,
<OnePointArray>, ...)
<OnePointArray>
Array("NAME:PLPoint",
"X:=", <value>,
"Y:=", <value>,
Z:=", <value>))
<PolylineSegmentsArray>
Array("NAME:PolylineSegments",
<OneSegmentArray>, <OneSegmentArray>, ...)
<OneSegmentArray>
Array("NAME:PLSegment",
"SegmentType:=", <string>,
"StartIndex:=", <value>,
"NoOfPoints:=", <value>)
SegmentType
Can be Line, Arc, Spline, or AngularArc
CreateRectangle
Use:
Command:
Draw>Rectangle
Syntax:
CreateRectangle <RectangleParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<RectangleParametersArray>
Array("NAME:RectangleParameters",
"XStart:=", <value>,
"YStart:=", <value>,
"ZStart:=", <value>,
"Width:=", <value>,
"Height:=", <value>,
"WhichAxis:=", <string>)
WhichAxis
Axis of normal vector to the rectangle. Possible values are: X, Y,
Z
Example: WhichAxis:=, Z means the rectangle will be drawn in
the XY plane.
CreateRegularPolyhedron
Use:
Command:
Draw>Regular Polyhedron
Syntax:
CreateRegularPolyhedron <PolyhedronParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<PolyhedronParametersArray>
Array(NAME:PolyhedronParameters,
XCenter:=, <value>,
YCenter:=, <value>,
ZCenter:=, <value>,
XStart:=,
<value>,
YStart:=,
<value>,
ZStart:=,
<value>,
Height:=,
<value>,
NumSides:=, <value>,
WhichAxis:=, <string>)
NumSides:
Specify a number greater than 2.
WhichAxis
Axis of the polyhedron. Possible values are: X, Y, Z
Example: WhichAxis:=, Z
CreateRegularPolygon
Use:
Command:
Draw>RegularPolygon
Syntax:
CreateRegularPolygon <PolygonParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<PolygonParametersArray>
Array("NAME:RegularPolygonParameters",
"XCenter:=",<value>,
"YCenter:=",<value>,
"ZCenter:=",<value>,
"XStart:=", <value>,
"YStart:=", <value>,
"ZStart:=", <value>,
"NumSides:=", "12",
"WhichAxis:=", <string>)
NumSides
Specify a number greater than 2.
WhichAxis
Axis of normal vector to the polygon. Possible values are: X, Y,
Z
Example: WhichAxis:=, Z means the polygon will be drawn in
the XY plane.
CreateSphere
Use:
Command:
Draw>Sphere
Syntax:
Return Value:
None
Parameters:
<SphereParametersArray>
Array("NAME:SphereParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"Radius:=", <value>)
CreateSpiral
Use:
Command:
Draw>Spiral
Syntax:
Return Value:
None
Parameters:
<SelectionsArray>
Array("NAME:Selections",
"Selections:=", <string>)
Selections
Comma separated list of parts to sweep.
Example: Selections:=, Rect1, Rect2
<SpiralParametersArray>
Array("NAME:SpiralParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"XStartDir:=", <value>,
"YStartDir:=", <value>,
"ZStartDir:=", <value>,
"NumThread:=", <value>,
"RightHand:=", <bool>,
"RadiusIncrement:=", <value>)
CreateTorus
Use:
Command:
Draw>Torus
Syntax:
Return Value:
None
Parameters:
<TorusParametersArray>
Array("NAME:TorusParameters",
"XCenter:=", <value>,
"YCenter:=", <value>,
"ZCenter:=", <value>,
"MajorRadius:=", <value>,
"MinorRadius:=", <value>,
"WhichAxis:=", <string>)
WhichAxis
Axis of the torus. Possible values are: X, Y, Z
Example: WhichAxis:=, Z
EditPolyline
Use:
Command:
Modifies a polyline primitive. Specify the name of the polyline to modify and
the new set of data for the polyline.
Draw>Line Segment>Insert Segment Before>Straight
Draw>Line Segment>Insert Segment Before>Spline
Draw>Line Segment>Insert Segment Before>3 Point Arc
Draw>Line Segment>Insert Segment Before>Center Point Arc
Draw>Line Segment>Insert Segment After>Straight
Draw>Line Segment>Insert Segment After>Spline
Draw>Line Segment>Insert Segment After>3 Point Arc
Draw>Line Segment>Insert Segment After>Center Point Arc
Edit>Delete Start Point
Edit>Delete End Point.
Syntax:
EditPolyline <SelectionsArray>,
<PolylineParametersArray>,
Return Value:
None
Parameters:
<SelectionsArray>
Array("NAME:Selections",
"Selections:=", string)
Selections
Name of the polyline to modify. The name should be formatted as
<PolylineName>:CreatePolyline:1.
Example: Selections:=, Polyline1:CreatePolyline:1
SweepAlongPath
Use:
Command:
Draw>Sweep>Along Path
Syntax:
SweepAlongPath <SelectionsArray>,
<PathSweepParametersArray>
Return Value:
None
Parameters:
<PathSweepParametersArray>
Array("NAME:PathSweepParameters",
"DraftAngle:=", <value>,
"DraftType:=", <string>,
"TwistAngle:=", <value>)
DraftType
Possible values are Extended, Round, Natural
Example:
oEditor.SweepAlongPath _
Array("NAME:Selections", "Selections:=",
"Polygon1,Polyline1"),_
Array("NAME:PathSweepParameters", _
"DraftAngle:=", "0deg",_
"DraftType:=", "Round",_
"TwistAngle:=", "30deg")
SweepAlongVector
Use:
Command:
Draw>Sweep>Along Vector
Syntax:
SweepAlongVector <SelectionsArray>,
Return Value:
None
Parameters:
<VecSweepParametersArray>
<VecSweepParametersArray>
Array("NAME:VectorSweepParameters",
"DraftAngle:=", <value>,
"DraftType:=", <string>,
"SweepVectorX:=", <value>, _
"SweepVectorY:=", <value>,
10-14 3D Modeler Editor Script Commands
"SweepVectorZ:=", <value)
DraftType
Possible values are Extended, Round, Natural
SweepAroundAxis
Use:
Command:
Draw>Sweep>Around Axis
Syntax:
SweepAroundAxis <SelectionsArray>,
<AxisSweepParametersArray>
Return Value:
None
Parameters:
<AxisSweepParametersArray>
Array("NAME:AxisSweepParameters",
"DraftAngle:=",
<value>,
"DraftType:=", <string>,
"SweepAxis:=", <string>,
"SweepAngle:=", <value>)
DraftType
Possible values are Extended, Round, Natural
SweepAxis
Possible values are X, Y, Z
Command:
Edit>Copy
Syntax:
Copy <SelectionsArray>
Return Value:
None
DuplicateAlongLine
Use:
Command:
Edit>Duplicate>Along Line
Syntax:
DuplicateAlongLine <SelectionsArray>,
<DupLineParametersArray>
Return Value:
None
Parameters:
<DupLineParametersArray>
Array("NAME:DuplicateToAlongLineParameters",
"XComponent:=", <value>,
"YComponent:=", <value>,
"ZComponent:=", <value>,
"NumClones:=", <value>)
NumClones
Specify a number greater than 1.
DuplicateAroundAxis
Use:
Command:
Edit>Duplicate>Around Axis
Syntax:
DuplicateAroundAxis <SelectionsArray>,
<DupAxisParametersArray>
Return Value:
None
Parameters:
<DupAxisParametersArray>
Array("NAME:DuplicateAroundAxisParameters",
"WhichAxis:=", <string>,
"AngleStr:=", <value>,
"NumClones:=",<value>)
WhichAxis
Axis to duplicate around. Possible values are: X, Y, Z
Example: WhichAxis:=, Z
NumClones:
Specify a number greater than 1.
DuplicateMirror
Use:
Command:
Edit>Duplicate>Mirror
Syntax:
DuplicateMirror <SelectionsArray>,
<DupMirrorParametersArray>
Return Value:
None
Parameters:
<DupMirrorParametersArray>
Array("NAME:DuplicateToMirrorParameters",
"DuplicateMirrorBaseX:=", <value>,
"DuplicateMirrorBaseY:=", <value>,
"DuplicateMirrorBaseZ:=", <value>,
"DuplicateMirrorNormalX:=", <value>,
"DuplicateMirrorNormalY:=", <value>,
"DuplicateMirrorNormalZ:=", <value>)
Mirror
Use:
Command:
Edit>Arrange>Mirror
Syntax:
Return Value:
None
Parameters:
<MirrorParametersArray>
Array("NAME:MirrorParameters",
"MirrorBaseX:=", <value>,
"MirrorBaseY:=", <value>,
"MirrorBaseZ:=", <value>,
"MirrorNormalX:=", <value>,
"MirrorNormalY:=", <value>,
"MirrorNormalZ:=", <value>)
3D Modeler Editor Script Commands 10-17
Move
Use:
Command:
Edit>Arrange>Move
Syntax:
Return Value:
None
Parameters:
<MoveParametersArray>
Array("NAME:TranslateParameters",
"TranslateVectorX:=", <value>,
"TranslateVectorY:=", <value>,
"TranslateVectorZ:=", <value>)
OffsetFaces
Use:
Command:
Edit>Arrange>Offset
Syntax:
Return Value:
None
Parameters:
<OffsetParametersArray>
Array("NAME:OffsetParameters",
"OffsetDistance:=", <value>)
Paste
Use:
Command:
Edit>Paste
Syntax:
Paste
Return Value:
None
Rotate
Use:
Command:
Edit>Arrange>Rotate
Syntax:
Return Value:
None
Parameters:
<RotateParametersArray>
Array("NAME:RotateParameters",
"RotateAxis:=", <string>
"RotateAngle:=", <value>)
RotateAxis
Possible values are: X, Y, Z
Scale
Use:
Command:
Edit>Scale
Syntax:
Return Value:
None
Parameters:
<ScaleParametersArray>
Array("NAME:ScaleParameters",
"ScaleX:=", <value>,
"ScaleY:=", <value>,
"ScaleZ:=", <value>)
Command:
3D Modeler>Assign Material
Syntax:
Return Value:
None
Example:
oEditor.AssignMaterial _
Array("NAME:Selections", "Selections:=", "Polygon1"),
Array("NAME:Attributes", _
"MaterialName:=", "tungsten",_
"SolveInside:=", false)
Connect
Use:
Command:
3D Modeler>Surface>Connect
Syntax:
Connect <SelectionsArray>
Return Value:
None
CoverLines
Use:
Command:
3D Modeler>Surface>Cover Lines
Syntax:
CoverLines <SelectionsArray>
Return Value:
None
CoverSurfaces
Use:
Command:
3D Modeler>Surface>Cover Faces
Syntax:
CoverSurfaces <SelectionsArray>
Return Value:
None
CreateEntityList
Use:
Creates a list of entities. The list can contain objects or faces, but not
both. Only the Name attribute from <AttributesArray> is supported.
Command:
3D Modeler>List>Create>Object List
3D Modeler>List>Create>Face List
Syntax:
CreateEntityList <EntityListParametersArray>,
Return Value:
None
Parameters:
<EntityListParametersArray>
<AttributesArray>
Array(NAME:GeometryEntityListParameters,
"EntityType:=", <string>,
"EntityList:=", <array>
EntityType
Possible values are Object, Face
EntityList
Array of integers the IDs of the objects or faces to put in the list.
CreateFaceCS
Use:
Command:
3D Modeler>Coordinate System>Create>Face CS
Syntax:
Return Value:
None
Parameters:
<FaceCSParametersArray>
Array("NAME:FaceCSParameters",
"FaceID:=", <int>,
"PartID:=", <int>,
Array("NAME:OriginPosn",
"IsAttachedToEntity:=", <bool>,
"EntityID:=", <value>,
"PositionType:=", <string>,
"UParam:=", <value>,
"VParam:=", <value>,
"XPosition:=", <value>,
3D Modeler Editor Script Commands 10-21
"YPosition:=", <value>,
"ZPosition:=", <value>)
Array("NAME:AxisPosn",
"IsAttachedToEntity:=", <bool>
"EntityID:=",
<value>
"PositionType:=", <string>,
"UParam:=", <value>,
"VParam:=", <value>,
"XPosition:=", <value>,
"YPosition:=", <value>,
"ZPosition:=", <value>)
"WhichAxis:=", <string>)
FaceID
ID of the face on which to create the coordinate system.
PartID
ID of the object on which the face ID lies.
IsAttachedToEntity
Specifies whether the point is anchored (to a vertex, edge, or face).
If IsAttachedToEntity is true, provide the UParam and VParam
parameters. Otherwise, provide the XPosition, YPosition, and
ZPosition parameters.
EntityID
ID of the vertex, edge, or face to which the point is anchored.
PositionType
Place where the point is anchored.
Possible values are: "FaceCenter", "EdgeCenter", "OnVertex",
"OnEdge", "OnFace"
UParam, VParam
Numbers between 0 and 1 representing the relative position of the point
on the edge or face.
10-22 3D Modeler Editor Script Commands
CreateObjectFromFaces
Use:
Command:
Syntax:
CreateObjectFromFaces <SelectionsArray>,
<ObjFromFaceParametersArray>
Return Value:
None
Parameters:
<ObjFromFaceParametersArray>
Array("NAME:Parameters",
<FacesOfOneObjToDetach>, <FacesOfOneObjToDetach>,
...)
<FacesOfOneObjToDetach>
Array("Name:BodyFromFaceToParameters",
"FacesToDetach:=", <array>)
FacesToDetach
Array of integers the IDs of the faces to use to create objects.
Example:
oEditor.CreateObjectFromFaces _
Array("NAME:Selections", "Selections:=", "Box1"),_
Array("NAME:Parameters", _
Array("NAME:BodyFromFaceToParameters", _
"FacesToDetach:=", Array(185)))
CreateRelativeCS
Use:
Command:
Syntax:
CreateRelativeCS <RelativeCSParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<RelativeCSParametersArray>
Array("NAME:RelativeCSParameters",
"OriginX:=", <value>,
"OriginY:=", <value>,
"OriginZ:=", <value>,
"XAxisXvec:=", <value>,
"XAxisYvec:=", <value>,
"XAxisZvec:=", <value>,
"YAxisXvec:=", <value>,
"YAxisYvec:=", <value>,
"YAxisZvec:=", <value>)
DeleteLastOperation
Use:
Command:
Syntax:
DeleteLastOperation <SelectionsArray>
Return Value:
None
DetachFaces
Use:
Command:
3D Modeler>Surface>Detach Faces
Syntax:
DetachFaces <SelectionsArray>,
<DetachFacesParametersArray>
Return Value:
None
Parameters:
<DetachFacesParametersArray>
Array("NAME:Parameters",
<FacesOfOneObjToDetach>,
<FacesOfOneObjToDetach>, ...)
<FacesOfOneObjToDetach>
Array("Name:DetachFacesToParameters",
"FacesToDetach:=", <array>)
FacesToDetach
An array of integers the face IDs of the faces to detach.
Example:
oEditor.DetachFaces _
Array("NAME:Selections", "Selections:=",_
"Box5,Box4"),_
Array("NAME:Parameters", _
Array("NAME:DetachFacesToParameters", _
"FacesToDetach:=", Array(123, 122)),
Array("NAME:DetachFacesToParameters", _
"FacesToDetach:=", Array(94)))
EditEntityList
Use:
Command:
3D Modeler>List>Reassign
Syntax:
EditEntityList <SelectionsArray>,
Return Value:
None
<EntityListParametersArray>
EditFaceCS
Use:
Command:
3D Modeler->Coordinate System->Edit
Syntax:
Return Value:
None
EditRelativeCS
Use:
Command:
3D Modeler>Coordinate System>Edit
Syntax:
EditRelativeCS <RelativeCSParametersArray>,
<AttributesArray>
Return Value:
None
Parameters:
<ParametersArray>
Array("NAME:RelativeCSParameters",
"OriginX:=", <value>,
"OriginY:=", <value>,
"OriginZ:=", <value>,
"XAxisXvec:=", <value>,
"XAxisYvec:=", <value>,
"XAxisZvec:=", <value>,
"YAxisXvec:=", <value>,
"YAxisYvec:=", <value>,
"YAxisZvec:=", <value>)
Export
Use:
Command:
3D Modeler>Export
Syntax:
Export <ExportParametersArray>
Return Value:
None
Parameters:
<ExportParametersArray>
Array("NAME:ExportParameters",
"File Name:=", <string>,
"Major Version:=", <int>,
GenerateHistory
Use:
Command:
3D Modeler>Generate History
Syntax:
GenerateHistory <SelectionsArray>
Return Value:
None
Import
Use:
Command:
3D Modeler>Import
Syntax:
Import <ImportParametersArray>
Return Value:
None
Parameters:
<ImportParametersArray>
Array("NAME:NativeBodyParameters",
"AutoHeal:=", <bool>,
"Options:=",
<string>,
"SourceFile:=", <string>)
Intersect
Use:
Command:
3D Modeler>Boolean>Instersect
Syntax:
Return Value:
None
Parameters:
<IntersectParametersArray>
Array("NAME:IntersectParameters",
"KeepOriginals:=",
<bool>)
MoveFaces
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<MoveFacesParametersArray>
Array("NAME:Parameters",
<FacesOfOneObjToMove>, <FacesOfOneObjToMove>, ...)
<FacesOfOneObjToMove>
Array("Name:MoveFacesParameters",
"MoveAlongNormalFlag:=",
<bool>,
"OffsetDistance:=", <value>,
"MoveVectorX:=", <value>,
"MoveVectorY:=", <value>,
"MoveVectorZ:=", <value>,
"FacesToMove:=", <array>)
MoveAlongNormalFlag
Specifies whether to move along the face normal or along a vector.
If false, provide the MoveVectorX, MoveVectorY, and MoveVectorZ
parameters.
FacesToMove
Array of integers the IDs of the faces to move
10-28 3D Modeler Editor Script Commands
Example:
oEditor.MoveFaces _
Array("NAME:Selections", "Selections:=", _
"Box2,Box1"), _
Array("NAME:Parameters", _
Array("NAME:MoveFacesParameters", _
"MoveAlongNormalFlag:=", true, _
"OffsetDistance:=", "1mm", _
"FacesToMove:=", Array(218)),
Array("NAME:MoveFacesParameters", _
"MoveAlongNormalFlag:=", false,_
"OffsetDistance:=", "1mm", _
"MoveVectorX:=", "1mm", _
"MoveVectorY:=", "0mm", _
"MoveVectorZ:=", "0mm", _
"FacesToMove:=", Array(185)))
Section
Use:
Command:
3D Modeler>Surface>Section
Syntax:
Return Value:
None
Parameters:
<SectionParametersArray>
Array("NAME:SectionToParameters",
"SectionPlane:=", <string>)
Section Plane
Possible values are XY, YZ, ZX
SeparateBody
Use:
Command:
3D Modeler>Boolean>Separate Bodies
Syntax:
SeparateBody <SelectionsArray>
Return Value:
None
SetModelUnits
Use:
Command:
3D Modeler>Units
Syntax:
SetModelUnits <ModelUnitsParametersArray>
Return Value:
None
Parameters:
<ModelUnitsParametersArray>
Array("NAME:Units Parameter",
"Units:=", <string>,
"Rescale:=", <bool>)
Units
Possible values are: cm, ft, in, meter, mil, mm,
nm, uin, um
SetWCS
Use:
Command:
Syntax:
SetWCS <WCSParametersArray>
Return Value:
None
Parameters:
<WCSParametersArray>
Array("NAME:SetWCS Parameter",
"Working Coordinate System:=", <string>)
Working Coordinate System
Name of the coordinate system to set as the WCS.
Split
Use:
Command:
3D Modeler->Boolean->Split
Syntax:
Return Value:
None
Parameters:
<SplitParametersArray>
Array("NAME:SplitToParameters",
"SplitPlane:=", <string>,
"WhichSide:=", <string>)
SplitPlane
Possible values are XY, YZ, ZX
WhichSide
Side to keep. Possible values are Both, PositiveOnly, NegativeOnly
Subtract
Use:
Command:
3D Modeler->Boolean->Subtract
Syntax:
Subtract <SubtractSelectionsArray>,
<SubtractParametersArray>
Return Value:
None
Parameters:
<SubtractSelectionsArray>
Array(NAME:Selections,
Blank Parts:=, <string>,
Tool Parts:=, <string>)
Blank Parts
Comma-separated list of parts to use as the blank in the subtract operation.
Example: Blank Parts:=, Box1, Box2
Tool Parts
Comma-separated list of parts to use as the tool in the subtract operation.
3D Modeler Editor Script Commands 10-31
<bool>)
oEditor.Subtract _
Array("NAME:Selections", _
"Blank Parts:=", "Polygon1",_
"Tool Parts:=",
"Box1"),_
Array("NAME:SubtractParameters", _
"KeepOriginals:=", false)
UncoverFaces
Use:
Command:
3D Modeler>Surface>Uncover Faces
Syntax:
Return Value:
None
Parameters:
<UncoverParametersArray>
Array("NAME:Parameters",
<FacesOfOneObjToUncover>,
<FacesOfOneObjToUncover>,...)
<FacesOfOneObjToUncover>
Array("Name:UncoverFacesParameters",
"FacesToUncover:=", <array>)
FacesToUncover
An array of integers the face IDs of the faces to uncover.
Example:
oEditor.UncoverFaces _
Array("NAME:Selections", "Selections:=", _
"Box3,Box2"),_
Array("NAME:Parameters", _
Array("NAME:UncoverFacesParameters", _
"FacesToUncover:=", Array(69)),
Array("NAME:UncoverFacesParameters", _
"FacesToUncover:=", Array(36)))
Unite
Use:
Command:
3D Modeler>Boolean>Unite
Syntax:
Return Value:
None
Parameters:
<UniteParametersArray>
Array("NAME:UniteParameters",
"KeepOriginals:=", <bool>)
Command:
None
Syntax:
Delete <SelectionsArray>
Return Value:
None
GetFaceByPosition
Use:
Command:
None
Syntax:
GetFaceByPosition <FaceByPositionParametersArray>
Return Value:
Parameters:
<FaceByPositionParametersArray>
Array("NAME:Parameters",
"BodyName:=", <string>,
"XPosition:=", <value>,
"YPosition:=", <value>,
"ZPosition:=", <value>)
BodyName
Name of the body on which the point lies.
Example:
Dim oFaceID
Set oFaceID = oEditor.GetFaceByPosition_
Array(NAME:Parameters,_
BodyName:=, Box1,_
XPosition:=, 0mm,_
YPosition:=, 0mm,_
ZPosition:=, 0mm)
PageSetup
Use:
Command:
File>Page Setup
Syntax:
PageSetup <PageSetupParametersArray>
Return Value:
None
Parameters:
<PageSetupParametersArray>
Array("NAME:PageSetupData",
"margins:=",
Array("left:=", <value>,
"right:=", <value>,
"top:=", <value>,
"bottom:=", <value>))
RenamePart
Use:
Renames an object.
Command:
None
Syntax:
RenamePart <RenameParametersArray>
Return Value:
None
Parameters:
<RenameParametersArray>
Array("NAME:Rename Data",
"Old Name:=", <string>,
"New Name:=", <string>)
11
Reporter commands should be executed by the oDesign object. One example of accessing this object is:
Set oDesign = Project.SetActiveDesign("HFSSModel1")
oDesign.CommandName <args>
Note: HFSS version 9 does not fully support Reporter scripting. Operations
performed in the Reporter will not be automatically recorded; however the
script commands in this chapter can be used to create and modify reports
from a script.
CreateReport
Use:
Creates a new report and adds it to the Results branch in the project tree.
Command:
None
Syntax:
CreateReport <ReportDataArray>
Return Value:
None
Parameters:
<ReportDataArray>
Array(NAME:<ReportName>,
ReportType:=, <string>,
DisplayType:=, <string>,
<TraceArray>)
ReportType
Possible values are:
Modal S Parameters - Only for Driven Modal solution-type problems with ports.
Terminal S Parameters - Only for Driven Terminal solution-type
problems with ports.
Eigenmode Parameters - Only for Eigenmode solution-type problems.
Fields
Far Fields - Only for problems with radiation or PML boundaries.
Near Fields - Only for problems with radiation or PML boundaries.
DisplayType
If ReportType is Modal S Parameters, Terminal S Parameters, or Eigenmode Parameters, then set to one of the following:
Rectangular Plot, Polar Plot, Radiation Pattern,
Smith Chart, Data Table, 3D Rectangular Plot, or
3D Polar Plot.
If ReportType is Fields, then set to one of the following:
Rectangular Plot, Polar Plot, Radiation Pattern,
Data Table, or 3D Rectangular Plot.
If ReportType is Far Fields or Near Fields, then set to one
of the following:
oDesign.CreateReport Array("NAME:Rept2DRectTime",_
"ReportType:=","Modal S Parameters",_
"DisplayType:=","Rectangular Plot", _
Array("NAME:Traces", _
Array("NAME:Trace1", _
SolutionName:=","Setup2 : Sweep1",_
Context:=",_
"Domain:=Time,IsImpulse:=true,RiseTime:=0",
"Time:=", Array("All"), _
"XComponent:=", "Time", _
Reporter Editor Script Commands 11-3
"YComponent:=",_
"db(S(WavePort1:1,WavePort2:1))",_
"YAxis:=", 1)))
Example:
oDesign.CreateReport Array("NAME:Rept2DRectFreq",_
"ReportType:=","Modal S Parameters",_
"DisplayType:=","Rectangular Plot", _
Array("NAME:Traces", _
Array("NAME:Trace2", _
"SolutionName:=","Setup1 : Sweep1",_
"Context:=","",_
"Freq:=", Array("All"), _
"XComponent:=", "freq",_
"YComponent:=",_
"db(S(WavePort1:1,WavePort2:1))",_
"YAxis:=", 0)))
Example:
oDesign.CreateReport Array("NAME:Rept2DRectOuVar2Trac",_
"ReportType:=","Modal S Parameters",_
"DisplayType:=","Rectangular Plot", _
Array("NAME:Traces", _
Array("NAME:Trace1", _
"SolutionName:=","Setup1 : Sweep1",_
"Context:=","", _
"Freq:=", _
Array("12GHz","13GHz","14GHz","15GHz"), _
"XComponent:=", "freq",_
"YComponent:=", "outputvarS11",_
"YAxis:=", 1), _
Array("NAME:Trace2", _
"SolutionName:=","Setup1 : Sweep1",_
"Context:=","", _
"Freq:=", Array("All"), _
"XComponent:=", "freq", _
"YComponent:=",_
"mag(S(WavePort1:1,WavePort2:1))",_
"YAxis:=", 0)))
Example:
oDesign.CreateReport Array("NAME:Rept3DPolarNearFields",_
"ReportType:=","Near Fields",_
"DisplayType:=","3D Polar Plot", _
Array("NAME:Traces", _
Array("NAME:Tracea", _
"SolutionName:=","Setup1 : LastAdaptive",_
"Context:=","Sphere1",_
"phi:=", Array("0deg","360deg","10deg"),_
theta:=", Array("0deg","180deg","10deg"),_
"freq:=", Array("12GHz"),_
"XComponent:=", "phi",_
"YComponent:=", "theta",_
"ZComponent:=", "NearETotal")))
Example:
oDesign.CreateReport Array("NAME:Rept3DPolarFarFields",_
"ReportType:=","Far Fields",_
"DisplayType:=","3D Polar Plot", _
Array("NAME:Traces", _
Array("NAME:Trace1", _
"SolutionName:=","Setup1 : LastAdaptive",_
"Context:=","Infinite Sphere1", _
"phi:=", Array("0deg","360deg","10deg"), _
"theta:=", Array("0deg","180deg","10deg"),_
"freq:=", Array("All"),_
"XComponent:=", "phi", _
YComponent:=", "theta",_
"ZComponent:=", "rETotal")))
Example:
oDesign.CreateReport Array("NAME:ReptFieldsRadiation",_
"ReportType:=","Fields",_
"DisplayType:=","Radiation Pattern", _
Array("NAME:Traces", _
Array("NAME:Trace1", _
"SolutionName:=","Setup1 : LastAdaptive",_
"Context:=","Polyline1",_
"NormalizedDistance:=",
Array("0","1","0.01"),_
Reporter Editor Script Commands 11-5
"Freq:=",Array("12GHz"),_
"Phase:=", Array("0deg","0deg","0deg"),_
"XComponent:=","NormalizedDistance", _
"YComponent:=","Mag_E")))
Example:
oDesign.CreateReport Array("NAME:Rept3DRectPlot2Traces",_
"ReportType:=","Modal S Parameters",_
"DisplayType:=","3D Rectangular Plot", _
Array("NAME:Traces", _
Array("NAME:Trace1",_
"SolutionName:=","Setup1 : Sweep1",_
"Context:=","",_
"freq:=", Array("All"), _
"$height:=", Array("All"),_
"XComponent:=", "freq",_
"YComponent:=", "$height",_
"ZComponent:=",
"db(S(WavePort1:1,WavePort1:1))",_
"YAxis:=", 0),
Array("NAME:Trace2", _
"SolutionName:=","Setup1 : Sweep1",_
"Context:=","",_
"freq:=", Array("All"), _
"$height:=", Array("All"),_
"XComponent:=", "freq",_
"YComponent:=", "$height",_
"ZComponent:=",
"mag(S(WavePort1:1,WavePort2:1))",_
"YAxis:=", 1)))
Example:
oDesign.CreateReport Array("NAME:ReptDataTable",_
"ReportType:=","Modal S Parameters",_
"DisplayType:=","Data Table", _
Array("NAME:Traces", _
Array("NAME:Trace1",_
"SolutionName:=","Setup1 : Sweep1",_
"Context:=","",_
"Freq:=", Array("All"), _
"XComponent:=", "freq",_
"YComponent:=",_
"db(S(WavePort1:1,WavePort2:1))",_
"YAxis:=", 0)))
Example:
oDesign.CreateReport Array("NAME:ReptSmithTime",_
"ReportType:=","Modal S Parameters",_
"DisplayType:=","Smith Chart", _
Array("NAME:Traces", _
Array("NAME:Trace1", _
"SolutionName:=","Setup2 : Sweep1", _
"Context:=",_
"Domain:=Time,IsImpulse:=true,RiseTime:=0", _
"Time:=", Array("All"), _
"XComponent:=","Time",_
"YComponent:=", "S(WavePort1:1,WavePort2:1)")))
Example:
oDesign.CreateReport Array("NAME:ReptSmithFreq",_
"ReportType:=","Modal S Parameters",_
"DisplayType:=","Smith Chart", _
Array("NAME:Traces", _
Array("NAME:Trace1", _
"SolutionName:=","Setup1 : Sweep1",_
"Context:=","",_
"Freq:=", Array("All"), _
"XComponent:=","freq",_
"YComponent:=",_
"S(WavePort1:1,WavePort2:1)")))
Example:
oDesign.CreateReport Array("NAME:ReptPolarSParam",_
ReportType:=","Modal S Parameters",_
"DisplayType:=","Polar Plot", _
Array("NAME:Traces", _
Array("NAME:Trace2", _
"SolutionName:=","Setup1 : Sweep2",_
"Context:=","",_
"Freq:=", Array("All"), _
Reporter Editor Script Commands 11-7
"YComponent:=", _
S(WavePort1:1,WavePort1:1))))
RemoveReport
Use:
Command:
Right-click the report to delete in the project tree, and then click Delete on
the shortcut menu.
Syntax:
RemoveReport <ReportName>
Return Value:
None
12
Command:
Syntax:
ChangeImpedanceMult <MultVal>
Return Value:
None
Parameters:
<MultVal>
Type: <value>
New value for the impedance multiplier.
Example:
oModule.ChangeImpedanceMult 0.5
DeleteAllBoundaries
Use:
Command:
HFSS>Boundaries>Delete All
Syntax:
DeleteAllBoundaries
Return Value:
None
Example:
oModule.DeleteAllBoundaries
DeleteAllExcitations
Use:
Command:
HFSS>Excitations>Delete All
Syntax:
DeleteAllExcitations
Return Value:
None
Example:
oModule.DeleteAllExcitations
DeleteBoundaries
Use:
Command:
Delete command in the List dialog box. Click HFSS>List to open the List
dialog box.
Syntax:
DeleteBoundaries <NameArray>
Return Value:
None
Parameters:
<NameArray>
Type: Array of strings
An array of boundary names.
Example:
ReassignBoundary
Use:
Command:
HFSS>Boundaries>Reassign or HFSS>Excitations>Reassign
Syntax:
ReassignBoundary Array(Name:<BoundName>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
Return Value:
None
Example:
oModule.ReassignBoundary Array("NAME:PerfE1",_
Objects:=", Array(Box2, Box3),_
Faces:=, Array(12, 11))
RenameBoundary
Use:
Command:
Right-click a boundary in the project tree, and then click Rename on the
shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OldName>
Type: <string>
<NewName>
Type: <string>
Example:
oModule.RenameBoundary PerfE1
PerfE
ReprioritizeBoundaries
Use:
Specifies the order in which the boundaries and excitations are recognized
by the solver. The first boundary in the list has the highest priority. Note:
this command is only valid if all defined boundaries and excitations appear
in the list. All ports must be listed before any other boundary type.
Command:
HFSS>Boundaries>Reprioritize
Syntax:
ReprioritizeBoundaries <NewOrderArray>
Return Value:
None
Parameters:
<NewOrderArray>
Example:
oModule.ReprioritizeBoundaries Array(NAME:NewOrder,
AssignCurent
Use:
Command:
HFSS>Excitations>Assign>Current
Syntax:
AssignCurrent <CurrentArray>
Return Value:
None
Parameters:
<CurrentArray>
Array(NAME:<BoundName>,
Objects:=, <AssignmentObjects>,
"Current:=", <value>,
<DirectionArray>,
Faces:=, <AssignmentFaces>)
<DirectionArray>
Array(NAME:Direction,
Start:=, <LineEndPoint>,
End:=, <LineEndPoint>)
Example:
oModule.AssignCurrent Array("NAME:Current1",_
"Current:=", "1000mA",_
Array("NAME:Direction",_
"Start:=", Array(-0.4, 0.4, -1.6),_
"End:=", Array(-0.4, 0.4, 0)), _
"Faces:=", Array(12))
AssignFiniteCond
Use:
Command:
HFSS>Boundaries>Assign>Finite Conductivity
Syntax:
AssignFiniteCond <FiniteCondArray>
Return Value:
None
Parameters:
<FiniteCondArray>
Array(NAME:<BoundName>,
UseMaterial:=,<bool>,
Material:=, <string>,
Conductivity:=, <value>,
Permeability:=, <value>,
InfGroundPlane:=, <bool>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
UseMaterial
If True, provide Material parameter.
If False, provide Conductivity and Permeability parameters.
Example:
oModule.AssignFiniteCond Array(NAME:FiniteCond1,_
UseMaterial:=, false,_
Conductivity:=, 58000000,_
Permeability:=, 1,_
InfGroundPlane:=, false,_
Faces:=, Array(12))
Example:
oModule.AssignFiniteCond Array(NAME:FiniteCond1,_
UseMaterial:=, true, _
Material:=, copper,_
InfGroundPlane:=, false,_
Faces:=, Array(12))
AssignImpedance
Use:
Command:
HFSS>Boundaries>Assign>Impedance
Syntax:
AssignImpedance <ImpedanceArray>
Return Value:
None
Parameters:
<ImpedanceArray>
Array(NAME:<BoundName>,
Resistance:=, <value>,
Reactance:=, <value>,
InfGroundPlane:=, <bool>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
Example:
oModule.AssignImpedance Array(NAME:Imped1,_
Resistance:=, 50,_
Reactance:=, 50,_
InfGroundPlane:=, false,_
Faces:=, Array(12))
AssignIncidentWave
Use:
Command:
HFSS>Excitations>Assign>IncidentWave
Syntax:
AssignIncidentWave <IncidentWaveArray>
Return Value:
None
Parameters:
<IncidentWaveArray>
Array(NAME:<BoundName>,
"IsCartesian:=",<bool>
"EoX:=", <value>,
"EoY:=", <value>,
"EoZ:=", <value>,
"kX:=", <value>,
"kY:=", <value>,
"kZ:=", <value>
"PhiStart:=",<value>,
"PhiStop:=", <value>,
"PhiPoints:=", <int>,
Boundary and Excitation Module Script Commands 12-7
"ThetaStart:=", <value>,
"ThetaStop:=", <value>,
"ThetaPoints:=", <int>,
"EoPhi:=", <value>,
"EoTheta:=", <value>)
IsCartesian
If true, provide the EoX, EoY, EoZ, kX, kY, kZ parameters.
If false, provide the PhiStart, PhiStop, PhiPoints, ThetaStart,
ThetStop, ThetaPoints, EoPhi, EoTheta parameters.
Example:
oModule.AssignIncidentWave Array("NAME:IncWave1",_
"IsCartesian:=", true,_
"EoX:=", "1", "EoY:=", "0", "EoZ:=", "0",_
"kX:=", "0", "kY:=", "0", "kZ:=", "1")
Example:
oModule.AssignIncidentWave Array("NAME:IncWave2",_
"IsCartesian:=", false,_
"PhiStart:=","0deg",_
"PhiStop:=", "90deg",_
"PhiPoints:=", 2,_
"ThetaStart:=", "0deg",_
"ThetaStop:=", "180deg",_
"ThetaPoints:=", 3, _
"EoPhi:=", "1", "EoTheta:=", "0")
AssignLayeredImp
Use:
Command:
HFSS>Boundaries>Assign>Layered Impedance
Syntax:
AssignLayeredImp <LayeredImpArray>
Return Value:
None
Parameters:
<LayeredImpArray>
Array(NAME:<BoundName>,
"Frequency:=", <value>,
"Roughness:=", <value>,
"IsInternal:=", <bool>,
<LayersArray>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
<LayersArray>
Array("NAME:Layers",
<OneLayerArray>, <OneLayerArray>, ...)
<OneLayerArray>
Array("NAME:<LayerName>",
LayerType:=, <LayerType>,
"Thickness:=",<value>,
"Material:=", <string>)
<LayerName>
Type: <string>
Specifies the layer number, such as Layer1 or Layer2
<LayerType>
Type: <string>
Should be specified for the last layer only.
Possible values: Infinite, PerfectE, or PerfectH
Thickness
Thickness of the layer. Should be specified for all layers except the last
layer.
Material
Material assigned on the layer. For the last layer, do not specify a material if the LayerType is PerfectE or PerfectH.
Example:
oModule.AssignLayeredImp Array("NAME:Layered1",_
"Frequency:=", "10GHz",_
"Roughness:=", "0um",_
"IsInternal:=", false,_
Array("NAME:Layers",_
Array("NAME:Layer1",_
"Thickness:=","1um",_
Boundary and Excitation Module Script Commands 12-9
"Material:=", "tin"),_
Array("NAME:Layer2",_
"LayerType:=", "Infinite",_
"Material:=", "copper")),_
"Faces:=", Array(12))
AssignLumpedPort
Use:
Command:
HFSS>Excitations>Assign>Lumped Port
Syntax:
AssignLumpedPort <LumpedPortArray>
Return Value:
None
Parameters:
<LumpedPortArray>
Array(NAME:<BoundName>,
Resistance:=, <value>,
Reactance:=, <value>,
<ModesArray>,
<TerminalsArray>,
Faces:=, <AssignmentFaces>)
Example:
oModule.AssignLumpedPort Array("NAME:LumpPort1",_
Array("NAME:Modes",_
"Resistance:=", "50Ohm",_
"Reactance:=","0Ohm",_
Array("NAME:Mode1",_
"ModeNum:=",1,_
"UseIntLine:=", true,_
Array("NAME:IntLine",_
"Start:=", Array(-0.4, 0.4, -1.6),_
"End:=", Array(-0.4, 0.4, 0)),_
"CharImp:=", "Zpv")),_
"Faces:=", Array(11))
Example:
oModule.AssignLumpedPort Array("NAME:LumpPort1",_
Array("NAME:Terminals",_
"Resistance:=", "50Ohm",_
"Reactance:=", "0Ohm",_
Array("NAME:T1", "TermNum:=",1,_
Array("NAME:TermLine",_
"Start:=", Array("0mm", "-2.2mm", "-2mm"),_
"End:=", Array("0mm", "-2.2mm", "0mm")))),
"Faces:=", Array(12))
AssignLumpedRLC
Use:
Command:
HFSS>Boundaries>Assign>Lumped RLC
Syntax:
AssignLumpedRLC <LumpedRLCArray>
Return Value:
None
Parameters:
<LumpedRLCArray>
Array(NAME:<BoundName>,
"UseResist:=",<bool>,
Resistance:=", <value>,
"UseInduct:=", <bool>,
"Inductance:=", <value>,
"UseCap:=", <bool>,
"Capacitance:=", <value>,
<CurrentLineArray>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
<CurrentLineArray>
Array("NAME:CurrentLine", _
"Start:=", <LineEndPoint>,
"End:=", <LineEndPoint>)
Example:
oModule.AssignLumpedRLC Array("NAME:LumpRLC1",_
"UseResist:=", true,_
Resistance:=", "10Ohm",_
"UseInduct:=", true,_
"Inductance:=", "10nH",_
"UseCap:=", true,_
"Capacitance:=","10pF",_
Array("NAME:CurrentLine", _
"Start:=", Array(-0.4, -1.2, -1.6),_
"End:=", Array(-0.4, -1.2, 0)),
Boundary and Excitation Module Script Commands 12-11
"Faces:=", Array(12))
AssignMagneticBias
Use:
Command:
HFSS>Excitations>Assign>Magnetic Bias
Syntax:
AssignMagneticBias <MagneticBiasArray>
Return Value:
None
Parameters:
<MagneticBiasArray>
Array(NAME:<BoundName>,
"IsUniformBias:=", <bool>,
"Bias:=", <value>,
"XAngle:=", <value>,
"YAngle:=", <value>,
"ZAngle:=", <value>,
"Project:=",<string>,
Objects:=, <AssignmentObjects>)
IsUniformBias
If true, supply the Bias, XAngle, YAngle, and ZAngle parameters.
If false, supply the Project parameter.
Example:
oModule.AssignMagneticBias Array("NAME:MagBias1",_
"IsUniformBias:=", true,_
"Bias:=", "1",_
"XAngle:=", "10deg",_
"YAngle:=", "10deg",_
"ZAngle:=", "10deg",_
"Objects:=", Array("Box2"))
Example:
oModule.AssignMagneticBias Array("NAME:MagBias2",_
"IsUniformBias:=", false,_
"Project:=","D:/Maxwell/testing/m3dfs.pjt",_
"Objects:=", Array("Box2"))
AssignMaster
Use:
Command:
HFSS>Boundaries>Assign>Master
Syntax:
AssignMaster <MasterArray>
Return Value:
None
Parameters:
<MasterArray>
Array(NAME:<BoundName>,
<CoordSysArray>,
"ReverseV:=", <bool>,
Faces:=, <AssignmentFaces>)
<CoordSysArray>
Array("NAME:CoordSysVector",
"Origin:=", <CoordSysPoint>,
"UPos:=", <LineEndPoint>)
Example:
oModule.AssignMaster Array("NAME:Master1",_
Array("NAME:CoordSysVector",_
"Origin:=", Array(-1.4, -1.4, -0.8),_
"UPos:=", Array(-1.4, -1.4, 0)),_
"ReverseV:=", false,_
"Faces:=", Array(12))
AssignPerfectE
Use:
Command:
HFSS>Boundaries>Assign>Perfect E
Syntax:
AssignPerfectE <PerfectEArray>
Return Value:
None
Parameters:
<PerfectEArray>
Array(NAME:<BoundName>,
InfGroundPlane:=, <bool>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
Example:
oModule.AssignPerfectE Array(NAME:PerfE1,_
InfGroundPlane:=", false,_
Faces:=, Array(12))
Boundary and Excitation Module Script Commands 12-13
AssignPerfectH
Use:
Command:
HFSS>Boundaries>Assign>PerfectH
Syntax:
AssignPerfectH <PerfectHArray>
Return Value:
None
Parameters:
<PerfectHArray>
Array(Name:<BoundName>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
Example:
oModule.AssignPerfectH Array("NAME:PerfH1,_
"Faces:=, Array(12))
AssignRadiation
Use:
Command:
HFSS>Boundaries>Assign>Radiation
Syntax:
AssignRadiation <RadiationArray>
Return Value:
None
Parameters:
<RadiationArray>
Array(NAME:<BoundName>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
Example:
oModule.AssignRadiation Array("NAME:Rad1",_
"Faces:=", Array(12))
AssignSlave
Use:
Command:
HFSS>Boundaries>Assign>Slave
Syntax:
AssignSlave <SlaveArray>
Return Value:
None
Parameters:
<SlaveArray>
Array(NAME:<BoundName>,
<CoordSysArray>,
ReverseV:=, <bool>,
Master:=, <string>,
UseScanAngles:=, <bool>,
Phi:=, <value>,
Theta:=, <value>,
"Phase:=", <value>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
<UseScanAngles>
If UseScanAngles is True, then Phi and Theta should be specified.
If it is False, then Phase should be specified.
Example:
oModule.AssignSlave Array(NAME:Slave1,_
Array(NAME:CoordSysVector, _
Origin:=, Array(-1, 0, 0.2),_
UPos:=, Array(-1, 0, 0)),_
ReverseV:=, false,_
Master:=, Master1,_
UseScanAngles:=, true,_
Phi:=, 10deg,_
Theta:=, 0deg,_
Faces:=, Array(12))
Example:
oModule.AssignSlave Array("NAME:Slave2",_
Array("NAME:CoordSysVector",_
"Origin:=", Array(-1, 0, 0.2),_
"UPos:=", Array(-2, 0, 0.2)),_
"ReverseV:=", false,_
"Master:=", "Master1",_
"UseScanAngles:=",false,_
"Phase:=", "10deg",_
"Faces:=", Array(11))
AssignSymmetry
Use:
Command:
HFSS>Boundaries>Assign>Symmetry
Syntax:
AssignSymmetry <SymmetryArray>
Return Value:
None
Parameters:
<SymmetryArray>
Array(NAME:<BoundName>,
Boundary and Excitation Module Script Commands 12-15
"IsPerfectE:=", <bool>
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
Example:
oModule.AssignSymmetry Array("NAME:Sym1",_
"IsPerfectE:=", true,_
"Faces:=", Array(12))
AssignVoltage
Use:
Command:
HFSS>Excitations>Assign>Voltage
Syntax:
AssignVoltage <VoltageArray>
Return Value:
None
Parameters:
<VoltageArray>
Array(NAME:<BoundName>,
"Voltage:=", <value>,
<DirectionArray>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>)
<DirectionArray>
Array("NAME:Direction",_
"Start:=",<LineEndPoint>,
"End:=", <LineEndPoint>)
Example:
oModule.AssignVoltage Array("NAME:Voltage1",_
"Voltage:=", "1000mV",_
Array("NAME:Direction",_
"Start:=", Array(-0.4, -1.2, 0),_
"End:=", Array(-1.4, -1.2, 0)),_
"Faces:=", Array(7))
AssignWavePort
Use:
Command:
HFSS>Excitations>Assign>Wave Port
Syntax:
AssignWavePort <WavePortArray>
Return Value:
None
Parameters:
<WavePortArray>
Array(NAME:<BoundName>,
"NumModes:=", <int>,
"PolarizeEField:=",<bool>,
"DoDeembed:=", <bool>,
"DeembedDist:=", <value>,
"DoRenorm:=", <bool>,
"RenormValue:=",<value>,
<ModesArray>,
<TerminalsArray>,
<DifferentialPairsArray>,
Faces:=, <AssignmentFaces>)
NumModes
Number of modes for modal problems.
Number of terminals for terminal problems.
<ModesArray>
Specify for modal problems.
Array("NAME:Modes",
<OneModeArray>, <OneModeArray>, ...)
<OneModeArray>
Array("NAME:<ModeName>",
"ModeNum:=", <int>,
"UseIntLine:=", <bool>,
<IntLineArray>)
<ModeName>
Type: <string>
Boundary and Excitation Module Script Commands 12-17
<OneDiffPairArray>
Array("NAME:Pair1",_
"PosTerm:=", <string>,
"NegTerm:=", <string>,
"CommonName:=", <string>,
"CommonRefZ:=", <value>,
"DiffName:=", <string>,
"DiffRefZ:=", <value>)
PosTerm
Name of the terminal to use as the positive terminal.
NegTerm
Name of the terminal to use as the negative terminal.
CommonName
Name for the common mode.
CommonRefZ
Reference impedance for the common mode.
DiffName
Name for the differential mode.
DiffRefZ
Reference impedance for the differential mode.
Example:
Modal problem:
oModule.AssignWavePort Array("NAME:WavePort1",_
NumModes:=", 2,_
"PolarizeEField:=",false,_
"DoDeembed:=", true,_
"DeembedDist:=", "10mil",_
"DoRenorm:=", true,_
"RenormValue:=","50Ohm",
Array("NAME:Modes",_
Boundary and Excitation Module Script Commands 12-19
Array("NAME:Mode1",_
"ModeNum:=", 1,_
"UseIntLine:=", true,_
Array("NAME:IntLine",_
"Start:=", Array(-0.4, -1.2, 0),_
"End:=", Array(-1.4, 0.4, 0)),_
"CharImp:=", "Zpi"), _
Array("NAME:Mode2",_
"ModeNum:=", 2,_
"UseIntLine:=", false)),_
"Faces:=", Array(7))
Example:
Terminal problem:
oModule.AssignWavePort Array("NAME:WavePort1",_
"NumModes:=", 2,_
"PolarizeEField:=", false,_
"DoDeembed:=", false,
"RenormImp:=", "50Ohm",_
Array("NAME:Terminals",_
Array("NAME:T1", _
"TermNum:=", 1, Array("NAME:TermLine",_
"Start:=", Array("-0.2mm", "-1.6mm", "-1.8mm"),_
"End:=", Array("-0.2mm", "-1.6mm", "0mm"))),_
Array("NAME:T2",_
"TermNum:=", 2, Array("NAME:TermLine",_
"Start:=", Array("-0.2mm", "-1.4mm",_
"-1.8mm"),_
"End:=", Array("-0.2mm", "-1.4mm", "0mm")))),_
Array("NAME:DiffPairs",_
Array("NAME:Pair1",_
"PosTerm:=", "T1",_
"NegTerm:=", "T2",_
"CommonName:=", "Comm1",_
"CommonRefZ:=", "10Ohm",_
"DiffName:=", "Diff1",_
"DiffRefZ:=", "30Ohm")),_
"Faces:=", Array(11))
EditCurrent
Use:
Command:
Syntax:
Return Value:
None
EditFiniteCond
Use:
Command:
Syntax:
Return Value:
None
EditImpedance
Use:
Command:
Syntax:
Return Value:
None
EditIncidentWave
Use:
Command:
Syntax:
Return Value:
None
EditLayeredImpedance
Use:
Command:
Syntax:
Return Value:
None
EditMaster
Use:
Command:
Syntax:
Return Value:
None
EditPerfectE
Use:
Command:
Syntax:
Return Value:
None
EditPerfectH
Use:
Command:
Syntax:
Return Value:
None
EditLumpedPort
Use:
Command:
Syntax:
Return Value:
None
EditLumpedRLC
Use:
Command:
Syntax:
Return Value:
None
EditMagneticBias
Use:
Command:
Syntax:
Return Value:
None
EditRadiation
Use:
Command:
Syntax:
Return Value:
None
EditSlave
Use:
Command:
Syntax:
Return Value:
None
EditSymmetry
Use:
Command:
Syntax:
Return Value:
None
EditVoltage
Use:
Command:
Syntax:
Return Value:
None
EditWavePort
Use:
Command:
Syntax:
Return Value:
None
Boundary and Excitation Module Script Commands 12-23
CreatePML
Use:
Command to create a new PML group from the script. This is equivalent to
creating a new PML group in the user interface.
Command:
None
Syntax:
Return Value:
None
Parameters:
PMLObj
Name of the object to use as the PML cover.
BaseObj
Name of the base object touching the PML cover object.
Orientation
String representing the orientation of the PML.
Possible values are: XAxis, YAxis, and ZAxis
UseFreq
If true, provide the MinFreq parameter.
If false, provide the MinBeta parameter.
Example:
Example:
ModifyPMLGroup
Use:
Command:
None
Syntax:
ModifyPMLGroup Array(NAME:<GroupName>,
"RadDist:=", <value>,
"UseFreq:=", <bool>,
MinFreq:=, <value>,
MinBeta:=, <double>)
Return Value:
None
Parameters:
<GroupName>
Name of the PML group to modify.
UseFreq
If true, provide the MinFreq argument.
If false, provide the MinBeta argument.
Example:
oModule.ModifyPMLGroup Array("NAME:PMLGroup1",
"RadDist:=", "1.166666667mm",
"UseFreq:=", false, "MinBeta:=", 2)
PMLGroupCreated
Use:
Command added by HFSS after a PML has been created. It is not responsible
for creating the PML objects and materials. It just contains the information
needed by the PML Setup wizard for future modification of the PML. This
script command is not intended to be modified by you. Removing this
command from the script will prevent future modification of the PML
through the user interface after the script is played back.
Command:
Syntax:
PMLGroupCreated <args>
Return Value:
None
PMLGroupModified
Use:
Command:
Syntax:
PMLGroupModified <args>
Return Value:
None
RecalculatePMLMaterials
Use:
Command:
None
Syntax:
RecalculatePMLMaterials
Return Value:
None
Example:
oModule.RecalculatePMLMaterials
13
Mesh setup and operations commands should be executed by the MeshSetup module.
Set oModule = oDesign.GetModule("MeshSetup")
oModule.CommandName <args>
Conventions Used in this Chapter
<OpName>
Type: <string>
Name of a mesh operation.
<AssignmentObjects>
Type: Array of strings
An array of object names.
<AssignmentFaces>
Type: Array of integers.
An array of face IDs. The ID of a face can be determined through the
user interface using the 3D Modeler>Measure>Area command. The
face ID is given in the Measure Information dialog box.
Command:
Delete command in the List dialog box. Click HFSS>List to access the List
dialog box.
Syntax:
DeleteOp <NameArray>
Return Value:
None
Parameters:
<NameArray>
Type: Array of strings.
An array of mesh operation names.
Example:
RenameOp
Use:
Command:
Right-click the mesh operation in the project tree, and then click Rename
on the shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OldName>
Type: <string>
Old name for the mesh operation.
<NewName>
Type: <string>
New name for the mesh operation.
Example:
Command:
Syntax:
AssignLengthOp <LengthOpParams>
Return Value:
None
Parameters:
<LengthOpParams>
Array("NAME:<OpName>",
"RefineInside:=", <bool>,
Objects:=, <AssignmentObjects>,
Faces:=, <AssignmentFaces>,
"RestrictElem:=", <bool>
"NumMaxElem:=", <integer>
"RestrictLength:=", <bool>
"MaxLength:=", <value>)
RefineInside
If true, Objects should be specified. Implies apply restrictions to tetrahedra inside the object.
If false, Faces and/or Objects can be specified. Implies apply restrictions to triangles on the surface of the face or object.
RestrictElem
If true, NumMaxElem should be specified.
RestrictLength
If true, MaxLength should be specified.
Example:
"RestrictLength:=",
true, _
"MaxLength:=", "1mm")
AssignSkinDepthOp
Use:
Command:
Syntax:
AssignSkinDepthOp <SkinDepthOpParams>
Return Value:
None
Parameters:
<SkinDepthOpParams>
Array("NAME:<OpName>",
"Faces:=", <AssignmentFaces>,
"RestrictElem:=", <bool>,
"NumMaxElem:=", <int>,
"SkinDepth:=", <value>,
"SurfTriMaxLength:=", <value>,
"NumLayers:=", <int>)
RestrictElem
If true, NumMaxElem should be specified.
Example:
oModule.AssignSkinDepthOp Array("NAME:SkinDepth1", _
"Faces:=", Array(7), _
"RestrictElem:=", true, _
"NumMaxElem:=", 1000, _
"SkinDepth:=", "1mm", _
"SurfTriMaxLength:=", "1mm", _
"NumLayers:=", 2)
AssignTrueSurfOp
Use:
Command:
Syntax:
AssignTrueSurfOp <TrueSurfOpParams>
Return Value:
None
Parameters:
<TrueSurfOpParams>
Array("NAME:<OpName>",
"Faces:=", <AssignmentFaces>,
"SurfDevChoice:=",
<RadioOption>,
"SurfDev:=", <value>,
"NormalDevChoice:=", <RadioOption>,
"NormalDev:=", <value>,
"AspectRatioChoice:=", <RadioOption>,
"AspectRatio:=", <double>)
<RadioOption>
Type: <int>
0: Ignore
1: Use defaults
2: Specify the value
Example:
oModule.AssignTrueSurfOp Array("NAME:TrueSurf1",
"Faces:=", Array(9), _
"SurfDevChoice:=",
2, _
"SurfDev:=", "0.04123105626mm", _
"NormalDevChoice:=", 2, _
"NormalDev:=", "15deg", _
"AspectRatioChoice:=", 1)
EditLengthOp
Use:
Command:
Syntax:
Return Value:
None
Example:
EditSkinDepthOp
Use:
Command:
Syntax:
Return Value:
None
Example:
oModule.EditSkinDepthOp "SkinDepth1",
Array("NAME:SkinD",_
"RestrictElem:=", false, _
"SkinDepth:=", "2mm", _
"SurfTriMaxLength:=", "1mm", _
"NumLayers:=", 2)
EditTrueSurfOp
Use:
Command:
Syntax:
Return Value:
None
Example:
oModule.EditTrueSurfOp "TrueSurf2",
Array("NAME:trusurf", _
"SurfDevChoice:=", 2, _
"SurfDev:=","0.03mm", _
"NormalDevChoice:=", 1, _
"AspectRatioChoice:=", 2, _
"AspectRatio:=", 10)
14
DeleteDrivenSweep
Use:
Command:
Right-click a frequency sweep in the project tree, and then click Rename on
the shortcut menu.
Syntax:
Return Value:
None
DeleteSetups
Use:
Command:
Right-click a solution setup in the project tree, and then click Delete on the
shortcut menu, or delete selected solution setups in the List dialog box.
Syntax:
DeleteSetups <SetupArray>
Return Value:
None
Parameters:
<SetupArray>
Array(<name1>, <name2>, ...)
Example:
EditDrivenSweep
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<SetupName>
Type: <string>
Name of the solution setup containing the sweep to be edited.
<SweepName>
Type: <string>
Name of the sweep to be edited.
<Attributes Array>
Array(NAME:<SweepName>,
Type:=, <SweepType>,
SetupType:=, <SetupType>,
<FrequencyInformation>,
<DCExtrapInfo>)
See the InsertDrivenSweep command for details.
EditSetup
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<SetupName>
Type: <string>
Name of the solution setup being edited.
<AttributesArray>
Array(NAME:<NewSetupName>, <NamedParameters>)
See the InsertSetup command for details and examples.
InsertDrivenSweep
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<SetupName>
Type: <string>
Name of the solution setup into which the sweep will be inserted.
<Attributes Array>
Array(NAME:<SweepName>,
Type:=, <SweepType>,
SetupType:=, <SetupType>,
<FrequencyInformation>,
<DCExtrapInfo>)
<SweepType>
Can be Discrete, Fast, or Interpolating.
Analysis Module Script Commands 14-3
<SetupType>
Can be LinearSetup, LinearCount, or SinglePoints.
<FrequencyInformation>
This will vary based on the sweep and solution type. See the examples
below.
<DCExtrapInfo>
Information about whether and how to perform DC extrapolation. This
parameter is not used for Discrete sweeps. See the examples below.
Example:
Example:
A Fast sweep, specified using the starting and stopping frequencies and the
step size:
oModule.InsertDrivenSweep "Setup1", _
Array("NAME:Sweep2", "Type:=", "Fast", _
"SetupType:=", "LinearStep", _
"StartFreq:=", "1GHz", "StopFreq:=", "10GHz", _
"StepSize:=", "0.1GHz", "SaveFields:=", true, _
"ExtrapToDC:=", false)
Example:
InsertSetup
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<SetupType>
Type: <string>
HfssDriven or HfssEigen. Must match the HFSS solution type.
<AttributesArray>
Array(NAME:<SetupName>, <Named Parameters>)
<Named Parameters>
The named parameters will vary according to the solution type. See the
examples below.
Example:
true, _
"Target:=", 0.3333)
Example:
"MaximumPasses:=", 3, _
"MinimumPasses:=",
1, _
"MinimumConvergedPasses:=", 1, _
"PercentRefinement:=", 20, _
"ReducedSolutionBasis:=", false, _
"DoLambdaRefine:=", true, _
"DoMaterialLambda:=", true, _
"Target:=", 0.3333, _
"PortAccuracy:=", 2, _
"SetPortMinMaxTri:=", false)
Example:
1, _
"MaxDeltaFreq:=", 10, _
"ConvergeOnRealFreq:=", false, _
"MaximumPasses:=", 3, _
"MinimumPasses:=", 1, _
"MinimumConvergedPasses:=", 1, _
"PercentRefinement:=", 20, _
"ReducedSolutionBasis:=", false, _
"DoLambdaRefine:=", true, _
"DoMaterialLambda:=", true, _
"Target:=", 0.25)
Example:
RenameDrivenSweep
Use:
Command:
Right-click a frequency sweep in the project tree, and then click Rename on
the shortcut menu.
Syntax:
Return Value:
None
Example:
RenameSetup
Use:
Command:
Right-click a solution setup in the project tree, and then click Rename on
the shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OldName>
Type: <string>
Name of the solution setup being renamed.
<NewName>
Type: <string>
New name for the solution setup.
RevertAllToInitial
Use:
Marks the current mesh for all solution setups as invalid. This will force the
next simulation to begin with the initial mesh.
Command:
Syntax:
RevertAllToInitial
Return Value:
None
RevertSetupToInitial
Use:
Marks the current mesh for a solution setup as invalid. This will force the
next simulation to begin with the initial mesh.
Command:
Right-click a setup in the project tree, and then click Revert to Initial Mesh
on the shortcut menu.
Syntax:
RevertSetupToInitial <SetupName>
Return Value:
None
SolveSetup
Use:
Command:
Right-click a solution setup in the project tree, and then click Analyze on
the shortcut menu.
Syntax:
SolveSetup <SetupName>
Return Value:
None
15
<MinV>
Type: <VarValue>
The minimum value of a variable.
<MaxV>
Type: <VarValue>
The maximum value of a variable.
<IncludeVar>
Type: <bool>
Specifies whether the variable is included in the analysis.
<StartingPoint>
Array(NAME:StartingPoint,
<VarName>:=",
<Constraint>
Array(NAME:LCS,
lc:=, Array(<VarName>:=,
<Coeff>, <VarName>:=, <Coeff>,
<Cond>, rhs:=, <Rhs>), ...
rel:=,
Command:
Right-click the setup in the project tree, and then click Delete on the
shortcut menu.
Syntax:
DeleteSetups <NameArray>
Return Value:
None
Parameters:
<NameArray>
Type: Array of strings.
An array of setup names.
Example:
oModule.DeleteSetups Array(OptimizationSetup1)
RenameSetup
Use:
Command:
Right-click the setup in the project tree, and then click Rename on the
shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OldName>
Type: <string>
<NewName>
Type: <string>
Example:
SolveSetup
Use:
Command:
Right-click the setup in the project tree, and then click Analyze on the
shortcut menu.
Syntax:
SolveSetup <SetupName>
Return Value:
None
Parameters:
oModule.SolveSetup OptimizationSetup1
Command:
Right-click the setup in the project tree, and then click Properties on the
shortcut menu.
Syntax:
Return Value:
None
InsertSetup
Use:
Command:
Right-click the Optimetrics folder in the project tree, and then click Add>
Parametric on the shortcut menu.
Syntax:
Return Value:
None
Parameters:
<Parametric Params>
Array("NAME:<SetupName>", SaveFields:=,
<SaveField>, <StartingPoint>, Sim. Setups:=,
<SimSetups>,
<SweepDefs>, <SweepOps>,
Array(NAME:Goals, Array(NAME:Goal,
<OptiGoalSpec>), ... Array(NAME:Goal,
<OptiGoalSpec>))
<SetupName>
Type: <string>
Name of the parametric setup.
<SimSetups>
Type: Array of strings.
An array of HFSS solution setup names.
<SweepDefs>
Array(NAME:Sweeps,
Array(NAME:SweepDefinition, Variable:=,
oModule.InsertSetup "OptiParametric",
Array("NAME:ParametricSetup1", _
"SaveFields:=", true,
Array("NAME:StartingPoint"), _
"Sim. Setups:=", Array("Setup1"),_
Array("NAME:Sweeps", _
Array("NAME:SweepDefinition", _
"Variable:=", "$width", _
"Data:=", "LIN 12mm 17mm 2.5mm", _
"OffsetF1:=", false, _
Optimetrics Module Script Commands 15-7
"Synchronize:=",
0),
Array("NAME:SweepDefinition", _
"Variable:=", "$length", _
"Data:=",
"OffsetF1:=", false, _
"Synchronize:=", 0)),
Array("NAME:Sweep Operations"), _
Array("NAME:Goals", _
Array("NAME:Goal", _
"Solution:=",
"Setup1 : LastAdaptive", _
"Calculation:=", "returnloss", _
"Context:=", "",_
Array("NAME:Ranges", _
"Range:=", Array("Var:=", "Freq", "Type:=", "s", _
"Start:=", "8GHz", "Stop:=", "8GHz"))), _
Array("NAME:Goal", _
"Solution:=",
"Setup1 : LastAdaptive",_
"Calculation:=", "reflect", _
"Context:=", "", _
Array("NAME:Ranges", _
"Range:=", Array("Var:=", "Freq", "Type:=", "s", _
"Start:=", "8GHz", "Stop:=", "8GHz")))))
Command:
Right-click the setup in the project tree, and then click Properties on the
shortcut menu.
Syntax:
Return Value:
None
InsertSetup
Use:
Command:
Right-click the Optimetrics folder in the project tree, and then click
Add>Optimization on the shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OptimizationParams>
Array("NAME:<SetupName>", SaveFields:=,
<SaveField>,
<StartingPoint>, Optimizer:=,
<Optimizer>,
MaxIterations:=, <MaxIter>, PriorPSetup:=,
<PriorSetup>, PreSolvePSetup:=, <Preceed>,
<OptimizationVars>, <Constraint>,
Array(NAME:Goals, Array(NAME:Goal,
<OptiGoalSpec>, <OptimizationGoalSpec>), ...
Array(NAME:Goal, <OptiGoalSpec>,
<OptimizationGoalSpec>)),
Acceptable_Cost:=, <AcceptableCost>, Noise:=,
<Noise>, UpdateDesignWhenDone:=, <UpdateDesign
<OptimizationVars>
Array(NAME:Variables, VarName:=, Array(i:=,
<IncludeVar>, Min:=, <MinV>, Max:=, <MaxV>,
MinStep:=, <MinStepV>, MaxStep:=, <MaxStepV>),
. VarName:=, Array(i:=, <IncludeVar>,
Min:=, <MinV>, Max:=, <MaxV>,
Optimetrics Module Script Commands 15-9
Type: <string>
Either Independent or Dependent
<GoalValueFormat>
Type:<string>
Either Real/Imag or Mag/Ang.
<GoalValue>
Type: <string>
Value in string. Value can be a real number, complex number, or
expression.
Example:
oModule.InsertSetup "OptiOptimization",_
Array("NAME:OptimizationSetup1", _
"SaveFields:=",
false, _
"Quasi Newton", _
"MaxIterations:=", 100, _
"PriorPSetup:=", "ParametricSetup1", _
"PreSolvePSetup:=",
true, _
Array("NAME:Variables", _
"$length:=", Array("i:=", true, "Min:=", "6mm", _
"Max:=", "18mm", _
"MinStep:=", "0.001mm", "MaxStep:=", _
"1.2mm"), _
"$width:=", Array("i:=",
true, "Min:=", _
"Setup1 : LastAdaptive", _
"Calculation:=", "reflect", _
"Context:=", "", _
Optimetrics Module Script Commands 15-11
Array("NAME:Ranges", _
"Range:=", Array("Var:=",
"Freq", _
"Type:=", "s", _
"Start:=", "8GHz", "Stop:=", "8GHz")), _
"Condition:=",
"<=", _
Array("NAME:GoalValue", _
"GoalValueType:=", "Independent", _
"Format:=",
"Real/Imag", _
0.0002, _
"Noise:=", 0.0001, _
"UpdateDesign:=", true, _
"UpdateIteration:=", 5, _
"KeepReportAxis:=",
true, _
"UpdateDesignWhenDone:=", true)
Command:
Right-click the setup in the project tree, and then click Properties on the
shortcut menu.
Syntax:
Return Value:
None
InsertSetup
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<SensitivityParams>
Array("NAME:<SetupName>", SaveFields:=,
<SaveField>,
<StartingPoint>, MaxIterations:=,
<SensitivityVars>,
<Constraint>,
Array(NAME:Goals, Array(NAME:Goal,
<OptiGoalSpec>), ..., Array(NAME:Goal,
<OptiGoalSpec>)), Master Goal:=. <MasterGoalID>,
MasterError:=, <MasterError>)
<SensitivityVars>
Array(NAME:Variables,
VarName:=, Array(i:=, <IncludeVar>,
Min:=, <MinV>, Max:=, <MaxV>,
IDisp:=, <InitialDisp>),...
VarName:=, Array(i:=, <IncludeVar>,
Min:=, <MinV>, Max:=, <MaxV>,
IDisp:=, <InitialDisp>))
<InitialDisp>
Type : <VarValue>
The initial displacement of the variable.
<MasterGoalID>
Type: <int>
Index of the master goal. Index starts from zero.
<MasterError>
Type: <double>
Error associated with the master goal.
Example:
oModule.InsertSetup "OptiSensitivity", _
Array("NAME:SensitivitySetup1",_
"SaveFields:=", true,_
Array("NAME:StartingPoint"), _
"MaxIterations:=", 20,_
PriorPSetup:=", "",_
"PreSolvePSetup:=",
true, _
Array("NAME:Variables"), _
Array("NAME:LCS"),_
Array("NAME:Goals",_
Array("NAME:Goal", _
"Solution:=", "Setup1 : LastAdaptive",_
"Calculation:=", "returnloss",_
"Context:=", "",_
Array("NAME:Ranges",_
"Range:=", Array("Var:=", "Freq", "_
Type:=", "s",_
"Start:=", "8GHz", "Stop:=", "8GHz"))),_
Array("NAME:Goal",_
"Solution:=", "Setup1 : LastAdaptive",_
"Calculation:=", "reflect",_
"Context:=", "",_
Array("NAME:Ranges",_
"Range:=", Array("Var:=","Freq",_
15-14 Optimetrics Module Script Commands
"Type:=", "s",_
"Start:=", "8GHz", "Stop:=", "8GHz")))),_
"Master Goal:=",
1,_
"MasterError:=", 0.001)
Command:
Right-click the setup in the project tree, and click Properties on the
shortcut menu.
Syntax:
Return Value:
None
InsertSetup
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<StatisticalParams>
Array("NAME:<SetupName>", SaveFields:=,
<SaveField>,
<StartingPoint>, MaxIterations:=,
<StatisticalVars>,
Array(NAME:Goals, Array(NAME:Goal,
<OptiGoalSpec>), , Array(NAME:Goal,
<OptiGoalSpec>))),
<StatisticalVars>
Array(NAME:Variables,
VarName:=, Array(i:=, <IncludeVar>, Dist:=,
<DistType>, Tol:=, <Tolerance>,
StdD:=, <StdD>, Min:=, <MinCutoff>, Max:=,
<MaxCutoff>, ...
Optimetrics Module Script Commands 15-15
oModule.InsertSetup "OptiStatistical", _
Array("NAME:StatisticalSetup1", _
"SaveFields:=",
true, _
Array("NAME:StartingPoint"),_
"MaxIterations:=", 50,_
"PriorPSetup:=", "", _
Array("NAME:Variables"), _
Array("NAME:Goals", _
Array("NAME:Goal", _
"Solution:=", "Setup1 : LastAdaptive", _
"Calculation:=", "returnloss", _
15-16 Optimetrics Module Script Commands
"Context:=", "", _
Array("NAME:Ranges", _
"Range:=", Array("Var:=", "Freq", _
"Type:=", "s",_
"Start:=", "8GHz", "Stop:=", "8GHz"))),_
Array("NAME:Goal",_
"Solution:=", "Setup1 : LastAdaptive",_
"Calculation:=", "reflect",_
"Context:=", "", _
Array("NAME:Ranges",_
"Range:=", Array("Var:=", "Freq", "Type:=", _
"s", "Start:=", "8GHz", "Stop:=", "8GHz"))))
16
DeleteImportData
Use:
Command:
HFSS>Results>Import Solutions
Syntax:
DeleteImportData <ImportSpecArray>
Return Value:
None
Parameters:
<ImportSpecArray>
Array(<ImportSpec>, ...)
<ImportSpec>
Type: <string>
Format of string is importname:solnnameORtablename.
Example:
oModule.DeleteImportData _
Array(Import1:Adaptive_1, Import2:DataTable)
EditSources
Use:
Indicates which source excitations should be used for fields post processing.
Command:
HFSS>Fields>Edit Sources
Syntax:
Return Value:
None
Parameters:
<FieldType>
Type: <string>
Possible values are:
NoIncidentWave, ScatteredFields, TotalFields, or
IncidentFields.
<SourceArray>
Array(NAME:SourceNames, <Source1Name>,
<Source2Name>, ...)
A source name is typically the name of the associated excitation.
<MultiplicityArray>
Array(NAME:Modes, <port1NumModes>, <port2NumModes>,
...)
or
Array(NAME:Terminals, <port1NumTerminals>, ...)
A non-port source should indicate multiplicity of 1.
<MagnitudeArray>
Array(NAME:Magnitudes, <Source1Mag>, <Source2Mag>,
...)
This gives the Mag of the complex excitation for each source.
<PhaseArray>
Array(NAME:Phases, <Source1Phase>, <Source2Phase>,
...)
This gives the Phase in degrees of the complex excitation for each
source.
<TerminatedArray>
Array(NAME:Terminated, <IsSource1Terminated>, ...)
This array is empty if it is not a Driven Terminal solution-type problem.
If it is Driven Terminal, then each source must have an entry, but
entries for non port sources are ignored.
<ImpedanceArray>
Array(NAME:Impedances, <Source1ComplexImped>, ...)
This array is empty if it is not a Driven Terminal solution-type problem.
If it is Driven Terminal, there must be an entry for each terminated
source. Complex format is a string representation as re + im j.
Example:
oModule.EditSources "NoIncidentWave", _
Array("NAME:SourceNames", "WavePort1", _
"WavePort2"), Array("NAME:Terminals", 2, 2), _
Array("NAME:Magnitudes", 1, 0), _
Array("NAME:Phases",
0, 0),_
Example:
oModule.EditSources "NoIncidentWave", _
Array("NAME:SourceNames", "EigenMode"), _
Array("NAME:Modes",
2), Array("NAME:Magnitudes", _
oModule.EditSources "TotalFields", _
Array("NAME:SourceNames", "WavePort1", _
"LumpPort1", "IncWave1", "Voltage1", "Current1"),_
Array("NAME:Modes", 1, 1, 6, 1, 1), _
Array("NAME:Magnitudes",
DeleteSolutionVariation
Use:
Deletes matrix solution data for specific solutions and design variations.
Command:
HFSS>Results>Clean Up Solutions
Syntax:
DeleteSolutionVariation
Return Value:
None
Parameters:
<DataSpecifierArray>
Array(<DataSpecifierArray>, ...)
Example:
oModule.DeleteSolutionVariation Array( _
Array(width=2in, Setup1, Adaptive_1) _
Array(width=2in, Setup1, Sweep1) )
DeleteVariation
Use:
Deletes matrix, field, and/or mesh solution data for specific variations,
across all solutions.
Command:
HFSS>Results>Browse Solutions
Syntax:
Return Value:
None
Parameters:
<VariationArray>
Array(<DesignVariationKey>, <DesignVariationKey>,...)
<FullVariations>
Type: <bool>
Specifies whether to delete meshes, fields, matrix data, profile, and
convergence data.
<MeshAndFieldsOnly>
Type: <bool>
Specifies whether to delete only meshes and fields.
<FieldsOnly>
Type: <bool>
Specifies whether to delete fields only.
Example:
oModule.DeleteVariation _
Array(width=2in, width=2.5in), _
TRUE, FALSE, FALSE
ExportForSpice
Use:
Exports matrix solution data to a file in a format suitable for Spice analysis.
Available only for Driven Terminal solution types with ports. Output in an
appropriate format will be generated for each of the non-empty file names
provided.
Command:
None
Syntax:
ExportForSpice <DesignVariationKey>,
<SolnSelectionArray>, <SpiceType>, <BandWidth>,
<FWSFile>, <LumpedElementFile>, <PoleZeroSpiceFile>,
<PoleZeroMatlabFile>, <PartialFractionFile>
Return Value:
None
Parameters:
<SpiceType>
Type: <int>
Possible values are:
0: PSpice
2: Maxwell Spice
<BandWidth>
Type: <int>
Possible values are:
0: Low (narrow) band width
<FWSFile>
Type: <string>
<LumpedElementFile>
Type: <string>
<PoleZeroSpiceFile>
Type: <string>
<PoleZeroMatlabFile>
Type: <string>
<PartialFractionFile>
Type: <string>
Example:
oModule.ExportForSpice width=2in, _
Array(Setup1:Sweep1), 2, 0, _
c:\mydir\Sweep1.fws, , , ,
ExportForHSpice
Use:
Command:
None
Syntax:
ExportForHSpice <DesignVariationKey>,
<SolnSelectionArray>, <SpiceType>, <BandWidth>,
<FWSFile>, <LumpedElementFile>, <PoleZeroSpiceFile>,
<PoleZeroMatlabFile>, <PartialFractionFile>,
<FittingError>, <MinimumOrder>, <MaximumOrder>
Return Value:
None
Parameters:
<SpiceType>
Type: <int>
Possible value is:
1: HSpice
<BandWidth>
Type: <int>
Possible value is:
0: Low (narrow) band width
<FWSFile>
Type: <string>
<LumpedElementFile>
Type: <string>
<PoleZeroSpiceFile>
Type: <string>
<PoleZeroMatlabFile>
Type: <string>
<PartialFractionFile>
Type: <string>
<FittingError>
Type: <double>
The accuracy to use in fitting the pole zero model, expressed as a fraction.
<MinimumOrder>
Type: <int>
Minimum number of poles in rational function expansion.
<MaximumOrder>
Type: <int>
Maximum number of poles in rational function expansion.
Example:
oModule.ExportForHSpice width=2in, _
Array(Setup1:Sweep1), 1, 0, _
c:\mydir\Sweep1.fws, , , , , _
.005, 20, 200
ExportNetworkData
Use:
Exports matrix solution data to a file. Available only for Driven solution
types with ports.
Command:
None
Syntax:
ExportNetworkData <DesignVariationKey>,
<SolnSelectionArray>, <FileFormat>, <OutFile>,
<FreqsArray>, <DoRenorm>, <RenormImped>
Return Value:
None
Parameters:
<SolnSelectionArray>
Array(<SolnSelector>, <SolnSelector>, ...)
If more than one array entry, this indicates a combined Interpolating
sweep.
<SolnSelector>
Type: <string>
Gives solution setup name and solution name, separated by a colon.
<FileFormat>
Type: <int>
Possible values are:
1 : HFSS 8.x format (.szg)
2 : Tab delimited spreadsheet format (.tab)
3 : Touchstone (.sNp)
4 : CitiFile (.cit)
7 : Matlab (.m)
8 : Terminal Z0 spreadsheet
<OutFile>
Type: <string>
Full path to the file to write out.
<FreqsArray>
Type: Array of doubles.
The frequencies to export. To export all frequencies, use
Array(all).
<DoRenorm>
Type: <bool>
Specifies whether to renormalize the data before export.
<RenormImped>
Type: <double>
Real impedance value in ohms, for renormalization. Required in syntax,
but ignored if DoRenorm is false.
Example:
Example:
ExportNMFData
Use:
Command:
None
Syntax:
Return Value:
None
Example:
oModule.ExportNMFData Array(Setup1:Sweep1), _
c:\mydir\out.nmf, Array(all), , FALSE, 0
ImportSolution
Use:
Command:
HFSS>Results>Import Solutions
Syntax:
Return Value:
None
Parameters:
<FileName>
Type: <string>
Location of the source data. The type of the data file will be determined strictly by its file extension. Supported types are Touchstone
(.sNp or .yNp or .zNp or .tou), HFSS 8.x format (.szg), and Ansoft
Designer (.flp).
<ImportName>
Type: <string>
Identifying name to use for the import, analogous to solution setup
name.
<SolnArray>
Type: Array of strings
The names of the solutions selected for import from the file. The only
import format supporting multiple solutions in one file is HFSS8.x format.
Example:
oModule.ImportSolution c:\mydir\in.s2p, _
MeasuredData, Array(Sweep1)
ImportTable
Use:
Imports a data table for use in plotting reports. The table can have multiple
independent real-valued columns of data, and multiple dependent real- or
complex-valued columns of data. The data supported imports are either tab
delimited format (.tab) or comma delimited format (.csv). The first row
may contain column names. Complex data columns are inferred from the
column data format. In tab delimited format, (double, double)
denotes a complex number. In comma delimited format, (double,
double) denotes a complex number.
Command:
HFSS>Results>Import Solutions
Syntax:
Return Value:
None
Parameters:
<FileName>
Type: <string>
Location of the source data.
<ImportName>
Type: <string>
Identifying name to use for the import, analogous to solution setup
name.
<TableName>
Type: <string>
Identifying name for the table, analogous to solution name.
<ComplexIsRealImag>
Type: <bool>
Whether to use real/imag to interpret data for any complex column.
If false, then use mag/phase(degrees).
<IsMatrixData>
Type: <bool>
Controls whether the table data can be used in matrix data reports or in
field data reports.
<ColNames>
Array(ColName1, ...)
Non-empty array used only if you want to override the column names
obtained from the table data file, in which case all column names are
required.
<ColIndependentFlags>
Array(<bool>, ...)
Indicates which columns are independent. If this is the empty array, the
default is that only the first column is independent. If this is the nonempty array, a flag must be present for every column.
Example:
oModule.ImportTable c:\mydir\mytable.tab, _
ImportData, Measurements, TRUE, TRUE, _
Array(), Array(TRUE, TRUE, FALSE, FALSE, FALSE)
17
CreateFieldPlot
Use:
Command:
HFSS>Fields>Plot Fields>Mag_E
Syntax:
CreateFieldPlot
Return Value:
None
Parameters:
<PlotParameterArray>
<PlotParameterArray>
Array(NAME:<PlotName>,
SolutionName:=, <string>,
"QuantityName:=", <string>,
"PlotFolder:=", <string>,
"UserSpecifyName:=",
<int>,
"UserSpecifyFolder:=", <int>,
"IntrinsicVar:=", <string>,
"PlotGeomInfo:=", <PlotGeomArray>,
"FilterBoxes:=", <FilterBoxArray>,
<PlotOnPointsSettings>,
<PlotOnLineSettings>,
<PlotOnSurfaceSettings>,
<PlotOnVolumeSettings>)
SolutionName
Name of the solution setup and solution formatted as:
<SolveSetupName> : <WhichSolution>,
where <WhichSolution> can be Adaptive_<n>,
LastAdaptive, or PortOnly.
For example: "Setup1 : Adaptive_2"
HFSS requires a space on either side of the : character. If it is
missing, the plot will not be created.
QuantityName
Type of plot to create. Possible values are:
Mesh plots: Mesh
Field plots: Mag_E, Mag_H, Mag_Jvol, Mag_Jsurf,
ComplexMag_E, ComplexMag_H, ComplexMag_Jvol,
ComplexMag_Jsurf, Vector_E, Vector_H,
17-2 Field Overlays Module Script Commands
<GeomTypeData>
<GeomType>, <ListType>, <NumIDs>, <ID>, <ID>, ...)
<GeomType>
Type: <string>
Possible values are Volume, Surface, Line, Point.
<ListType>
Type: <string>
Possible values are ObjList, or FacesList.
These are used for the GeomType of Line or Point.
<NumIDs>
Type: <int>
Number of IDs or object names that will follow.
<ID>
Type: <int> or <string>
ID of a face or name of an object, line, or point on which to plot.
<FilterBoxArray>
Array of names of objects to use to restrict the plot range.
Array(<NumFilters>, <ObjName>, <ObjName>, ...)
Example: Array(1, Box1)
Example: Array(0)
no filtering
<PlotOnPointSettings>
Array("NAME:PlotOnPointSettings",
"PlotMarker:=", <bool>,
"PlotArrow:=", <bool>)
<PlotOnLineSettings>
Array("NAME:PlotOnLineSettings",
Array("NAME:LineSettingsID",
"Width:=", <int>,
17-4 Field Overlays Module Script Commands
"Style:=", <string>),
"IsoValType:=", <string>,
"ArrowUniform:=", <bool>,
"NumofArrow:=",
<int>)
Style
Possible values are Cylinder, Solid, Dashdash,
Dotdot, Dotdash
IsoValType
Possible values are Tone, Fringe, Gourard
<PlotOnSurfaceSettings>
Array("NAME:PlotOnSurfaceSettings",
"Filled:=", <bool>,
"IsoValType:=", <string>,
"SmoothShade:=", <bool>,
"AddGrid:=", <bool>,
"MapTransparency:=", <bool>,
"Transparency:=", <doubl.e>,
"ArrowUniform:=", <bool>
"ArrowSpacing:=",
<double>
"PointSize:=", <int>,
"ArrowUniform:=", <bool>,
"ArrowSpacing:=, <double>)
Example:
oModule.CreateFieldPlot Array("NAME:Mag_E1", _
"SolutionName:=",
"Setup1 : LastAdaptive", _
"QuantityName:=", "Mag_E", _
"PlotFolder:=", "E Field1", _
"UserSpecifyName:=",
0, _
"UserSpecifyFolder:=", 0, _
"IntrinsicVar:=", "Freq='1GHz' Phase='0deg'",_
"PlotGeomInfo:=", Array( 1, "Surface",_
"FacesList", 1, "7"),_
"FilterBoxes:=", Array(0),
Array("NAME:PlotOnSurfaceSettings", _
"Filled:=", false, _
"IsoValType:=", "Fringe", _
"SmoothShade:=", true, _
"AddGrid:=", false, _
"MapTransparency:=", true, _
"Transparency:=", 0, _
"ArrowUniform:=", true, _
"ArrowSpacing:=",
0.100000001490116, _
DeleteFieldPlot
Use:
Command:
HFSS>Fields>Delete Plot
Syntax:
DeleteFieldPlot <NameArray>
Return Value:
None
Parameters:
<NameArray>
Example:
ModifyFieldPlot
Use:
Command:
HFSS>Fields>Modify Plot
Syntax:
Return Value:
None
Example:
oModule.ModifyFieldPlot "Vector_E1",_
Array("NAME:Vector_E2", _
"SolutionName:=",
"Setup1 : LastAdaptive", _
"QuantityName:=", "Vector_E", _
"PlotFolder:=", "E Field1",
"UserSpecifyName:=", 0, _
"UserSpecifyFolder:=", 0, _
"IntrinsicVar:=","Freq='1GHz' Phase='30deg'", _
"PlotGeomInfo:=", Array(1,_
"Surface","FacesList", 1, "7"), _
"FilterBoxes:=", Array(0), _
Array("NAME:PlotOnSurfaceSettings", _
"Filled:=",
false, _
"IsoValType:=", "Fringe", _
"SmoothShade:=", true, _
"AddGrid:=", false, _
"MapTransparency:=",
true, _
"Transparency:=", 0, _
"ArrowUniform:=", true, _
"ArrowSpacing:=",
0.100000001490116, _
RenameFieldPlot
Use:
Renames a plot.
Command:
Right-click the plot you want to rename in the project tree, and then click
Rename on the shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OldName>
Type: <string>
Original name of the plot.
<NewName>
Type: <string>
New name of the plot.
Example:
RenamePlotFolder
Use:
Command:
Right-click a plot folder in the project tree, and then click Rename on the
shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OldName>
Type: <string>
Original name of the folder.
<NewName>
Type: <string>
New name of the folder.
Example:
SetFieldPlotSettings
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<PlotName>
Type: <string>
Name of the plot to modify.
<PlotItemAttributes>
Array(NAME:FieldsPlotItemSettings,
<PlotOnPointsSettings>,
<PlotOnLineSettings>,
<PlotOnSurfaceSettings>,
<PlotOnVolumeSettings>)
See description of CreateFieldPlot command for details.
Example:
oModule.SetFieldPlotSettings "Mag_E2", _
Array("NAME:FieldsPlotItemSettings", _
Array("NAME:PlotOnLineSettings", _
Array("NAME:LineSettingsID", _
"Width:=", 4,
"Style:=", "Cylinder"), _
"IsoValType:=", "Tone", _
"ArrowUniform:=", true, _
"NumofArrow:=",
100), _
Array("NAME:PlotOnSurfaceSettings", _
"Filled:=", false, _
"IsoValType:=", "Tone", _
"SmoothShade:=",
true, _
"AddGrid:=", false, _
"MapTransparency:=", true, _
"Transparency:=", 0, _
"ArrowUniform:=",
true, _
"ArrowSpacing:=", 0.100000001490116, _
"GridColor:=", Array(255, 255, 255)))
Field Overlays Module Script Commands 17-9
SetPlotFolderSettings
Use:
Command:
Syntax:
SetPlotFolderSettings <PlotFolderName>
<PlotFolderAttributes>
Return Value:
None
Parameters:
<PlotFolderName>
Type: <string>
Name of the folder with the attributes to modify.
<PlotFolderAttributes>
Array(NAME:FieldsPlotSettings,
Real time mode:=, <bool>,
<ColorMapSettings>,
<Scale3DSettings>,
<Marker3DSettings>,
<Arrow3DSettings>)
<ColorMapSettings>
Array("NAME:ColorMapSettings",
"ColorMapType:=", <string>,
"SpectrumType:=", <string>,
"UniformColor:=", Array(<int>, <int>, <int>),
"RampColor:=", Array(<int>, <int>, <int>)
ColorMapType
Possible values are Uniform, Ramp, Spectrum
SpectrumType
Possible values are Rainbow, Temperature, Magenta,
Gray
UniformColor, RampColor
Array containing the R, G, B components of the color. Components
should be in the range 0 to 255.
<Scale3DSettings>
Array("NAME:Scale3DSettings",
"m_nLevels:=",
<int>,
"m_autoScale:=", <bool>,
"minvalue:=", <double>,
"maxvalue:=",
<double>,
"log:=", <bool>,
"IntrinsicMin:=", <double>,
"IntrinsicMax:=",
<double>)
<Marker3DSettings>
Array("NAME:Marker3DSettings",
MarkerType:=", <int>,
"MarkerMapSize:=",
<bool>,
"MarkerMapColor:=", <bool>,
"MarkerSize:=", <double>)
MarkerType
9: Sphere
10: Box
11: Tetrahedron
12: Octahedron
default: Sphere
<Arrow3DSettings>
Array("NAME:Arrow3DSettings",
"ArrowType:=",
<int>,
"ArrowMapSize:=", <bool>,
"ArrowMapColor:=", <bool>,
"ShowArrowTail:=", <bool>,
"ArrowSize:=",
<double>)
ArrowType
0: Line
Field Overlays Module Script Commands 17-11
1: Cylinder
2: Umbrella
default: Line
Example:
true,
Array("NAME:ColorMapSettings", _
"ColorMapType:=", "Spectrum", _
"SpectrumType:=", "Rainbow", _
"UniformColor:=", Array(127, 255, 255), _
"RampColor:=", Array(255,
127, 127)), _
Array("NAME:Scale3DSettings", _
"m_nLevels:=",
27, _
"m_autoScale:=", true, _
"minvalue:=", 9.34379863739014, _
"maxvalue:=",
13683.755859375, _
"log:=", false, _
"IntrinsicMin:=", 9.34379863739014, _
"IntrinsicMax:=",
13683.755859375), _
Array("NAME:Marker3DSettings", _
MarkerType:=", 0, _
"MarkerMapSize:=",
true, _
"MarkerMapColor:=", false, _
"MarkerSize:=", 0.25), _
Array("NAME:Arrow3DSettings", _
"ArrowType:=",
1, _
"ArrowMapSize:=", true, _
"ArrowMapColor:=", true, _
"ShowArrowTail:=", true, _
"ArrowSize:=",
0.25))
18
Fields Calculator commands should be executed by the Field Overlays module, which is called FieldsReporter in HFSS scripts.
Set oModule = oDesign.GetModule("FieldsReporter")
oModule.CommandName <args>
The command associated with each of the following scripting commands will
be a button pressed in the Fields Calculator.
AddNamedExpr
Use:
Creates a named expression using the expression at the top of the stack.
Command:
Click Add.
Syntax:
AddNamedExpr <Name>
Return Value:
None
Parameters:
<Name>
Type: <string>
Name for the new named expression.
Example:
oModule.AddNamedExpr Mag_JxE
CalcOp
Use:
Command:
Syntax:
CalcOp <OperationString>
Return Value:
None
Parameters:
<OperationString>
Type: String
The text on the corresponding calculator button.
Examples: Mag, +
CalcStack
Use:
Command:
Syntax:
CalcStack <OperationString>
Return Value:
None
Parameters:
<Operation String>
Type: <string>
The text on the corresponding calculator button.
Example:
oModule.CalcStack push
ChangeGeomSettings
Use:
Command:
Geom Settings
Syntax:
ChangeGeomSettings <int>
Return Value:
None
Parameters:
ClcEval
Use:
Evaluates the expression at the top of the stack using the provided solution
name and variable values.
Command:
Click Eval.
Syntax:
Return Value:
None
Parameters:
<SolutionName>
Type: <string>
<VariablesArray>
Array of variable name, value pairs.
Example:
ClcMaterial
Use:
Command:
Click Matl.
Syntax:
Return Value:
None
Parameters:
<Material String>
Type: <string>
The material property to apply.
<OperationString>
Type: <string>
Possible values are mult, or div.
Example:
ClearAllNamedExpr
Use:
Command:
Click ClearAll.
Syntax:
ClearAllNamedExpr
Return Value:
None
Parameters:
None
CopyNamedExprToStack
Use:
Command:
Syntax:
CopyNamedExprToStack <Name>
Return Value:
None
Parameters:
<Name>
Type: <string>
The name of the expression to be copied to the top of the stack.
Example:
oModule.CopyNamedExprToStack Mag_JxE
DeleteNamedExpr
Use:
Command:
Syntax:
DeleteNamedExpr <Name>
Return Value:
None
Parameters:
<Name>
Type: <string>
The name of the named expression to be deleted.
Example:
oModule.DeleteNamedExpr Mag_JxE
EnterComplex
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<Real>
Type: <double>
Real component of the scalar.
<Imaginary>
Type: <double>
Imaginary component of the scalar.
Example:
oModule.EnterComplex 1 + 2 j
EnterComplexVector
Use:
Command:
Syntax:
Return Value:
None
Parameters:
Example:
EnterLine
Use:
Command:
Syntax:
EnterLine <LineName>
Return Value:
None
Parameters:
<LineName>
Type: <string>
Name of a line defined in the 3D Modeler editor.
Example:
oModule.EnterLine Line1
EnterPoint
Use:
Command:
Syntax:
EnterPoint <PointName>
Return Value:
None
Parameters:
<PointName>
Type: <string>
Name of a point defined in the 3D Modeler editor.
Example:
oModule.EnterPoint Point1
EnterQty
Use:
Command:
Syntax:
EnterQty <FieldQuantityString>
Return Value:
None
Parameters:
Example:
oModule.EnterQty E
EnterScalar
Use:
Command:
Click Number and then click Scalar. Complex option not selected.
Syntax:
EnterScalar <Scalar>
Return Value:
None
Parameters:
<Scalar>
Type: <double>
The real number to enter onto the stack.
EnterScalarFunc
Use:
Command:
Syntax:
EnterScalarFunc <VarName>
Return Value:
None
Parameters:
<VarName>
Type: <string>
Name of a variable to enter as a scalar function onto the stack.
Example:
oModule.EnterScalarFunc Phase
EnterSurf
Use:
Command:
Syntax:
EnterSurf <SurfaceName>
Return Value:
None
Parameters:
<SurfaceName>
Type: <string>
Name of a surface defined in the 3D Modeler editor.
Example:
oModule.EnterSurf Rectangle1
EnterVector
Use:
Command:
Click Number, and then click Vector. Complex option not selected.
Syntax:
Return Value:
None
Parameters:
<X>
Type: <double>
X component of the vector.
<Y>
Type: <double>
Y component of the vector.
<Z>
Type: <double>
Z component of the vector.
Example:
EnterVectorFunc
Use:
Command:
Syntax:
Return Value:
None
Parameters:
Example:
oModuleEnterVectorFunc Array(X, Y, Z)
EnterVol
Use:
Command:
Syntax:
EnterVol <VolumeName>
Return Value:
None
Parameters:
<VolumeName>
Type: <string>
Name of a volume defined in the 3D Modeler editor.
Example:
oModule.EnterVol Box1
ExportOnGrid
Use:
Evaluates the top stack element at a set of points specified by a grid and
exports the data to a file.
Command:
Syntax:
Return Value:
None
Parameters:
<OutputFile>
Type: <string>
Name of the output file.
<MinArray>, <MaxArray>, <SpacingsArray>
Type: Array<double, double, double>
Min, Max, and Spacing for the X, Y, and Z components of the grid.
Example:
oModule.ExportOnGrid
"C:\Hfss9OutputFiles\GridExport.reg",_
Array("1", "1", "1"),_
Array("4", "4", "4"),_
Array("2", "2", "2")
ExportToFile
Use:
Command:
Syntax:
Return Value:
None
Parameters:
<OutputFile>
Type: <string>
Name of the output file.
<PtsFile>
Type: <string>
Name of the file containing the points at which to evaluate the top
stack element. The file should contain tab- or space-separated x,y,z
values of data points.
WriteRegister
Use:
Evalutates the top stack element for all tetrahedrons and writes the data to
a file.
Command:
Click Write.
Syntax:
ClcWrite <OutputFile>
Return Value:
None
Parameters:
<OutputFile>
Type: <string>
Name of the output file.
19
Command:
Delete command in the List dialog box. Click HFSS>List to access the List
dialog box.
Syntax:
DeleteFarFieldSetup <NameArray>
Return Value:
None
Parameters:
<NameArray>
Type: Array of strings.
An array of radiation setup names.
Example:
DeleteNearFieldSetup
Use:
Command:
Delete command in the List dialog box. Click HFSS>List to access the List
dialog box.
Syntax:
DeleteNearFieldSetup <NameArray>
Return Value:
None
Parameters:
<NameArray>
Type: Array of strings.
An array of radiation setup names.
Example:
RenameSetup
Use:
Command:
Right-click a radiation setup in the project tree, and then click Rename on
the shortcut menu.
Syntax:
Return Value:
None
Parameters:
<OldName>
Type: <string>
<NewName>
Type: <string>
Example:
Command:
Syntax:
EditFarFieldSphereSetup <InfSphereParams>
Return Value:
None
Example:
oModule.EditFarFieldSphereSetup Array("NAME:InfSphere",_
"UseCustomRadiationSurface:=", true, _
"CustomRadiationSurface:=, "FaceList1, _
"ThetaStart:=", "0deg", _
"ThetaStop:=", "180deg", _
"ThetaStep:=", "10deg", _
"PhiStart:=", "15deg", _
"PhiStop:=", "36deg", _
"PhiStep:=", "10deg", _
"UseLocalCS:=", false)
EditNearFieldLineSetup
Use:
Command:
Double-click the radiation setup in the project tree to modify its settings.
Syntax:
EditNearFieldLineSetup <LineParams>
Return Value:
None
Example:
oModule.EditNearFieldLineSetup Array("NAME:MyLine", _
"UseCustomRadiationSurface:=", false, _
"Line:=", "Polyline2", _
"NumPts:=", "100")
EditNearFieldSphereSetup
Use:
Command:
Syntax:
EditNearFieldSphereSetup <SphereParams>
Return Value:
None
Example:
oModule.EditNearFieldSphereSetup Array("NAME:MySphere", _
"UseCustomRadiationSurface:=", true, _
"CustomRadiationSurface:=, "FaceList1, _
"Radius:=", "35mm", _
"ThetaStart:=", "0deg", "ThetaStop:=", "180deg", _
"ThetaStep:=", "10deg", "PhiStart:=", "15deg", _
"PhiStop:=", "36deg", "PhiStep:=", "10deg", _
"UseLocalCS:=", false)
Example:
Partial values can be specified, in which case default values will be used to
populate the rest of the fields:
oModule.EditNearFieldSphereSetup "NAME:MyInfSphere", _
Array("NAME:MySphere", _
"UseCustomRadiationSurface:=", true, _
"CustomRadiationSurface:=, "FaceList1, _
"Radius:=", "45mm")
This will cause default values to be used for the rest of the fields such as
ThetaStop, ThetaStart, ThetaStep, PhiStep, PhiStart, and
PhiStop;however, the value for the key CustomRadiationSurface has
to be specified if custom radiation surfaces are used.
InsertFarFieldSphereSetup
Use:
Command:
Syntax:
InsertFarFieldSphereSetup <InfSphereParams>
Return Value:
None
Parameters:
<InfSphereParams>
Array(NAME:<SetupName>,
"UseCustomRadiationSurface:=", <bool>,
"CustomRadiationSurface:=, <FaceListName>,
"ThetaStart:=", <value>,
"ThetaStop:=", <value>,
"ThetaStep:=", <value>,
"PhiStart:=", <value>,
"PhiStop:=", <value>,
"PhiStep:=", <value>,
"UseLocalCS:=", <bool>,
"CoordSystem:=", <CSName>)
UseCustomRadiationSurface
If true, provide CustomRadiationSurface parameter.
If false, radiation boundary/PML boundaries will be used as radiation
surfaces.
UseLocalCS
If true, provide CoordSystem parameter.
If false, global coordinate system will be used.
Example:
oModule.InsertFarFieldSphereSetup
Array("NAME:InfiniteSphere1",_
"UseCustomRadiationSurface:=", false, _
"ThetaStart:=", "0deg",_
"ThetaStop:=", "180deg",_
"ThetaStep:=", "10deg",_
"PhiStart:=", "0deg",_
"PhiStop:=", "36deg",_
"PhiStep:=", "10deg",_
"UseLocalCS:=", true,_
"CoordSystem:=", "RelativeCS1")
InsertNearFieldLineSetup
Use:
Inserts a near-field line setup. Requires the presence of lines in the model.
Command:
Syntax:
InsertNearFieldLineSetup <LineParams>
Return Value:
None
Parameters:
<LineParams>
Array(NAME:<SetupName>,
"UseCustomRadiationSurface:=", <bool>,
"CustomRadiationSurface:=, <FaceListName>,
"Line:=", <PolyLineName>,
"NumPts:=", <int>)
<PolyLineName>
Type: String.
Name of the polyline as determined by name in the history tree.
UseCustomRadiationSurface
If true, provide CustomRadiationSurface parameter.
If false, radiation boundary/PML boundaries will be used as radiation
surfaces.
Example:
oModule.InsertNearFieldLineSetup Array("NAME:MyLine", _
"UseCustomRadiationSurface:=", false, _
"Line:=", "Polyline1", _
"NumPts:=", "100")
InsertNearFieldSphereSetup
Use:
Command:
Syntax:
InsertNearFieldSphereSetup <SphereParams>
Return Value:
None
Parameters:
<SphereParams>
Array(NAME:<SetupName>,
"UseCustomRadiationSurface:=", <bool>,
"CustomRadiationSurface:=, <FaceListName>,
"Radius:=", <value>,
"ThetaStart:=", <value>,
"ThetaStop:=", <value>,
"ThetaStep:=", <value>,
"PhiStart:=", <value>,
"PhiStop:=", <value>,
"PhiStep:=", <value>,
"UseLocalCS:=", <bool>,
"CoordSystem:=", <CSName>)
UseCustomRadiationSurface
If true, provide CustomRadiationSurface parameter.
If false, radiation boundary/PML boundaries will be used as radiation
surfaces.
UseLocalCS
If true, provide CoordSystem parameter.
If false, global coordinate system will be used.
Example:
oModule.InsertNearFieldSphereSetup _
Array("NAME:MySphere", _
"UseCustomRadiationSurface:=", true, _
"CustomRadiationSurface:=, "FaceList1, _
"ThetaStart:=", "0deg", "ThetaStop:=", "180deg", _
"ThetaStep:=", "10deg", "PhiStart:=", "0deg", _
"PhiStop:=", "360deg", "PhiStep:=", "10deg", _
"UseLocalCS:=", true, _
"CoordSystem:=", "FaceCS1")
Modifies the antenna array setup. There are 3 choices in the setup. The
default is set to No Array Setup. There are two (other) kinds of arrays that
the user can set: Regular Array Setup and Custom Array Setup.
Command:
Syntax:
EditAntennaArraySetup <AntennaArrayParams>
Return Value:
None
Parameters:
<AntennaArrayParams>
Array("NAME:ArraySetupInfo",
"UseOption:=", <ArrayOption>,
<RegularArrayParams>,
<CustomArrayParams>)
<ArrayOption>
Type: <string>
Can be one of three strings: NoArray, or RegularArray,
CustomArray.
If RegularArray is specified, then <RegularArrayParams> must
be specified. If CustomArray is specified, <CustomArrayParams>
must be specified. You can also supply both the custom and regular
array specifications and switch between them by setting this flag to the
option you want to use.
<RegularArrayParams>
Array("NAME:RegularArray",
"NumUCells:=", <value>,
"NumVCells:=", <value>,
"CellUDist:=", <value>,
"CellVDist:=", <value>,
"UDirnX:=", <value>,
"UDirnY:=", <value>,
Radiation Module Script Commands 19-9
"UDirnZ:=", <value>,
"VDirnX:=", <value>,
"VDirnY:=", <value>,
"VDirnZ:=", <value>,
"FirstCellPosX:=", <value>,
"FirstCellPosY:=", <value>,
"FirstCellPosZ:=", <value>,
"UseScanAngle:=", <bool>,
"ScanAnglePhi:=", <value>,
"ScanAngleTheta:=", <value>,
"UDirnPhaseShift:=", <value>,
"VDirnPhaseShift:=", <value>)
UseScanAngle
If true, the values of the ScanAnglePhi and ScanAngleTheta
parameters will be used and need to be specified.
If false, the values of the UDirnPhaseShift and VDirnPhaseShift
parameters will be used and must be specified.
<CustomArrayParams>
Array("NAME:CustomArray",
"NumCells:=", <int>,
<CellsParamsArray
<CellsParamsArray>
Array("NAME:Cell",
<CellParams>, <CellParams>, ...)
<CellParams>
Array(Name:<CellName>,
"XCoord:=", <double>,
"YCoord:=", <double>,
"ZCoord:=", <double>,
"Amplitude:=", <double>,
"Phase:=", <double>)
19-10 Radiation Module Script Commands
Example:
Example:
Command:
Syntax:
ExportRadiationParametersToFile <ExportToFileParams>
Return Value:
None
Parameters:
<ExportToFileParams>
Array("ExportFileName:=", <FilePath>
"SetupName:=", <SetupName>
"IntrinsicVariationKey:=", <string>,
"DesignVariationKey:=", <string>,
"SolutionName:=", <string>)
<FilePath>
Type: String.
Specifies the file to export to, for example: "C:\projects\exportantparams.txt".
IntrinsicVariationKey
Specifies the frequency at which to extract the parameters. Example:
"Freq='10GHz'"
DesignVariationKey
Specifies the design variations at which to extract the parameters.
Example: "width=5mm"
Example:
oModule.ExportRadiationParametersToFile _
Array("ExportFileName:=", _
C:\projects\exportantparams.txt",_
"SetupName:=", "Infinite Sphere1", _
"IntrinsicVariationKey:=", "Freq='10GHz'", _
"DesignVariationKey:=", "",
"SolutionName:=", "LastAdaptive")
Radiation Module Script Commands 19-13
20
Example Scripts
= CreateObject("AnsoftHfss.HfssScriptInterface")
Case "mm"
Case "um"
Case "in"
Case "mil"
Case Else
MsgBox("Invalid Units - defaults to m")
Units = ""
End Select
'
' Obtain the other user-defined parameters.
'
Turns = InputBox("Select the number of turns (must be integer):", _
"Variable Helix", 2,50,50)
PointsPerTurn = InputBox("Select the points per turn:", _
"Variable Helix",16,50,50)
R(0) = InputBox("Select the initial Radius: ", _
"Variable Helix",10,50,50)
R(1) = InputBox("Select the final Radius: ", _
"Variable Helix",10,50,50)
P(0) = InputBox("Select the initial Pitch: ", _
"Variable Helix", 4,50,50)
P(1) = InputBox("Select the final Pitch: ", _
"Variable Helix", 4,50,50)
NumPoints = Turns*PointsPerTurn
'
' Initialize the points and segments arrays.
'
Redim points(NumPoints+1)
Redim segments(NumPoints)
points(0) = "NAME:PolylinePoints"
segments(0) = "NAME:PolylineSegments"
'
' Build the Point and Segment Arrays needed in the HFSS polyline call.
'
For n = 1 To (NumPoints+1)
Example Scripts 20-3
Angle = (n-1)*2*Pi/PointsPerTurn
Radius = R(0) + ((n-1)/NumPoints)*(R(1)-R(0))
Pitch = P(0) + ((n-1)/NumPoints)*(P(1)-P(0))
Rise = (n-1)*Pitch/PointsPerTurn
XValue = cstr(Radius*cos(Angle)) & Units
YValue = cstr(Radius*sin(Angle)) & Units
ZValue = cstr(Rise) & Units
points(n) = Array("NAME:PLPoint", "X:=", XValue, "Y:=", _
YValue, "Z:=", ZValue)
'
' Create the line segments between each of the pairs of points.
'
If n<=NumPoints Then
segments(n) = Array("NAME:PLSegment", "SegmentType:=", _
"Line", "StartIndex:=", (n-1), "NoOfPoints:=", 2)
End If
Next
'
' Create the polyline.
'
oEditor.CreatePolyline _
Array("NAME:PolylineParameters", "IsPolylineCovered:=", true, _
"IsPolylineClosed:=", false, points, segments), _
Array("NAME:Attributes", "Name:=", "Line_Helix","Flags:=", _
"", "Color:=", "(132 132 193)", "Transparency:=",0.4, _
"PartCoordinateSystem:=", "Global", "MaterialName:=", _
"vacuum", "SolveInside:=", true)
'
' Create the helix cross-section.
'
oEditor.CreateCircle _
Array("NAME:CircleParameters", "IsCovered:=", true, "XCenter:=",_
cstr(R(0))&Units, "YCenter:=", 0, "ZCenter:=", 0, "Radius:=", _
"1"&Units, "WhichAxis:=", "Y"), _
20-4 Example Scripts
= CreateObject("AnsoftHfss.HfssScriptInterface")
oProject.GetActiveDesign()
Dim oFS,ofile,x,y,z,path,range
Dim arr2,del_f,freq,cfreq,val,temp,stn,stw,i,line
'
' Input the desired file name.
'
path = inputbox("Input the file name" &chr(13) & _
"Note: If you do not specify a path the file will " & _
"be placed in the script directory", _
"File","C:\hfss_export.txt",50,50)
'
' If the user clicks Cancel, the path will be blank, in which case the script should just exit.
If path <>"" then
'
' Create the file, open it for data entry, and output the column labels.
'
Set oFS = CreateObject("Scripting.FileSystemObject")
20-6 Example Scripts
= oDesign.GetOutputVariableValue _
= oDesign.GetOutputVariableValue _
Index
Numbers
3D Modeler editor commands
AssignMaterial 10-20
Connect 10-20
Copy 10-16
CoverLines 10-20
CoverSurfaces 10-20
CreateBondwire 10-3
CreateBox 10-4
CreateCircle 10-4
CreateCone 10-5
CreateCutplane 10-5
CreateCylinder 10-6
CreateEllipse 10-6
CreateEntityList 10-21
CreateFaceCS 10-21
CreateHelix 10-7
CreateObjectFromFaces 1023
CreatePoint 10-8
CreatePolyline 10-8
CreateRectangle 10-9
CreateRegularPolygon 10-10
CreateRegularPolyhedron
10-10
CreateRelativeCS 10-24
CreateSphere 10-11
CreateSpiral 10-12
CreateTorus 10-12
Delete 10-34
DeleteLastOperation 10-24
DetachFaces 10-25
DuplicateAlongLine 10-16
DuplicateAroundAxi 10-16
DuplicateMirror 10-17
EditEntityList 10-25
EditFaceCS 10-26
EditPolyline 10-13
EditRelativeCS 10-26
Export 10-26
GenerateHistory 10-27
GetFaceByPosition 10-34
Import 10-27
Intersect 10-28
Mirror 10-17
Move 10-18
MoveFaces 10-28
OffsetFaces 10-18
PageSetup 10-35
Paste 10-18
RenamePart 10-35
Rotate 10-19
Scale 10-19
Section 10-29
Index-1
SeparateBody 10-29
SetModelUnits 10-30
SetWCS 10-30
Split 10-31
Subtract 10-31
SweepAlongPath 10-14
SweepAlongVector 10-14
SweepAroundAxis 10-15
UncoverFaces 10-32
Unite 10-33
A
AbortSolveAsynch 8-2
AddDataset 7-2
AddMaterial 5-2
AddNamedExpr 18-2
AddOutputVariable 9-2
Analysis module commands
DeleteDrivenSweep 14-2
DeleteSetups 14-2
EditDrivenSweep 14-2
EditSetup 14-3
InsertDrivenSweep 14-3
InsertSetup 14-5
RenameDrivenSweep 14-7
RenameSetup 14-8
RevertAllToInitial 14-8
RevertSetupToInitial 14-8
SolveSetup 14-8
ApplyMeshOps 8-2
arithmetic operators 1-5
array variables 1-4
AssignCurrent 12-5
AssignFiniteCond 12-6
AssignImpedance 12-7
AssignIncidentWave 12-7
AssignLayeredImp 12-8
AssignLengthOp 13-3
AssignLumpedPort 12-10
AssignLumpedRLC 12-11
AssignMagneticBias 12-12
Index-2
AssignMaster 12-13
AssignMaterial 10-20
AssignPerfectE 12-13
AssignPerfectH 12-14
AssignRadiation 12-14
AssignSkinDepthOp 13-4
AssignSlave 12-14
AssignSymmetry 12-15
AssignTrueSurfOp 13-4
AssignVoltage 12-16
AssignWavePort 12-17
B
Boundary/Excitation module commands
AssignCurrent 12-5
AssignFiniteCond 12-6
AssignImpedance 12-7
AssignIncidentWave 12-7
AssignLayeredImp 12-8
AssignLumpedPort 12-10
AssignLumpedRLC 12-11
AssignMagneticBias 12-12
AssignMaster 12-13
AssignPerfectE 12-13
AssignPerfectH 12-14
AssignRadiation 12-14
AssignSlave 12-14
AssignSymmetry 12-15
AssignVoltage 12-16
AssignWavePort 12-17
ChangeImpedanceMult 12-2
CreatePML 12-24
DeleteAllBoundaries 12-2
DeleteAllExcitations 12-2
DeleteBoundaries 12-3
EditCurrent 12-21
EditFiniteCond 12-21
EditImpedance 12-21
EditIncidentWave 12-21
EditLayeredImpedance 12-21
EditLumpedPort 12-22
EditLumpedRLC 12-22
EditMagneticBias 12-23
EditMaster 12-22
EditPerfectE 12-22
EditPerfectH 12-22
EditRadiation 12-23
EditSlave 12-23
EditSymmetry 12-23
EditVoltage 12-23
EditWavePort 12-23
ModifyPMLGroup 12-26
PMLGroupCreated 12-26
PMLGroupModified 12-27
ReassignBoundaries 12-3
RecalculatePMLMaterials 12-27
RenameBoundary 12-3
ReprioritizeBoundary 12-4
C
CalcOp 18-2
CalcStack 18-2
ChangeGeomSettings 18-3
ChangeImpedanceMult 12-2
ChangeProperty 6-4
ClcEval 18-3
ClcMaterial 18-3
ClearAllNamedExpr 18-4
Close 4-2
CloseProject 3-2
comment lines 1-2
comparison operators 1-6
conditional statements
If...Then... Else 1-7
Select Case 1-7
types of 1-7
Connect 10-20
context-sensitive help iii
conventions
command syntax 2-7
data types 2-7
script command 2-8
converting data types 1-9
Copy 10-16
CopyDesign 4-2
CopyNamedExprToStack 18-4
CoverLines 10-20
CoverSurfaces 10-20
coyright notice ii
CreateBondwire 10-3
CreateBox 10-4
CreateCircle 10-4
CreateCone 10-5
CreateCutplane 10-5
CreateCylinder 10-6
CreateEllipse 10-6
CreateEntityList 10-21
CreateFaceCS 10-21
CreateFieldPlot 17-2
CreateHelix 10-7
CreateObjectFromFaces 10-23
CreatePML 12-24
CreatePoint 10-8
CreatePolyline 10-8
CreateRectangle 10-9
CreateRegularPolygon 10-10
CreateRegularPolyhedron 10-10
CreateRelativeCS 10-24
CreateReport 11-2
CreateSphere 10-11
CreateSpiral 10-12
CreateTorus 10-12
CutDesign 4-2
D
dataset commands
AddDataset 7-2
DeleteDataset 7-2
EditDataset 7-3
Delete 10-34
DeleteAllBoundaries 12-2
DeleteAllExcitations 12-2
DeleteBoundaries 12-3
DeleteDataset 7-2
DeleteDesign 4-2
Index-3
DeleteDrivenSweep 14-2
DeleteFarFieldSetup 19-2
DeleteFieldPlot 17-6
DeleteImportData 16-2
DeleteLastOperation 10-24
DeleteNamedExpr 18-4
DeleteNearFieldSetup 19-2
DeleteOp 13-2
DeleteOutputVariable 9-2
DeleteSetups
Analysis module command 14-2
Optimetrics module command 15-5
DeleteSolutionVariation 16-4
DeleteVariation 16-5
Design object commands
AbortSolveAsynch 8-2
AddOutputVariable 9-2
ApplyMeshOps 8-2
CreateReport 11-2
DeleteOutputVariable 9-2
EditOutputVariable 9-3
GetModule 8-2
GetName 8-3
GetOutputVariableValue 9-3
GetSolveAsynchStatus 8-3
Redo 8-3
RemoveReport 11-8
RenameDesignInstance 8-4
SARSetup 8-4
SetActiveEditor 8-4
SetSolutionType 8-5
Solve 8-5, 8-6
SolveAsynch 8-6
Desktop object commands
CloseProject 3-2
GetActiveProject 3-2
GetProjectList 3-2
NewProject 3-2
OpenMultipleProjects 3-3
OpenProject 3-3
PauseScript 3-3
Print 3-4
QuitApplication 3-4
Index-4
RestoreWindow 3-4
RunProgram 3-5
RunScript 3-6
SetActiveProject 3-6
Sleep 3-7
DetachFaces 10-25
DuplicateAlongLine 10-16
DuplicateAroundAxis 10-16
DuplicateMirror 10-17
E
EditAntennaArraySetup 19-9
EditCurrent 12-21
EditDataset 7-3
EditDrivenSweep 14-2
EditEntityList 10-25
EditFaceCS 10-26
EditFarFieldSphereSetup 19-4
EditFiniteCond 12-21
EditImpedance 12-21
EditIncidentWave 12-21
EditLayeredImpedance 12-21
EditLengthOp 13-5
EditLumpedPort 12-22
EditLumpedRLC 12-22
EditMagneticBias 12-23
EditMaster 12-22
EditMaterial 5-3
EditNearFieldLineSetup 19-4
EditNearFieldSphereSetup 19-5
EditOutputVariable 9-3
EditPerfectE 12-22
EditPerfectH 12-22
EditPolyline 10-13
EditRadiation 12-23
EditRelativeCS 10-26
EditSetup
Analysis module command 14-3
optimization command 15-9
parametric command 15-6
sensitivity command 15-13
F
Field Overlays module commands
AddNamedExpr 18-2
CalcOp 18-2
CalcStack 18-2
ChangeGeomSettings 18-3
ClcEval 18-3
ClcMaterial 18-3
ClearAllNamedExpr 18-4
CopyNamedExprToStack 18-4
CreateFieldPlot 17-2
DeleteFieldPlot 17-6
DeleteNamedExpr 18-4
EnterComplex 18-5
EnterComplexVector 18-5
EnterLine 18-6
EnterPoint 18-6
EnterQty 18-6
EnterScalar 18-7
EnterScalarFunc 18-7
EnterSurf 18-7
EnterVector 18-8
EnterVectorFunc 18-8
EnteVol 18-9
ExportOnGrid 18-9
ExportToFile 18-10
ModifyFieldPlot 17-7
RenameFieldPlot 17-8
RenamePlotFolder 17-8
SetFieldPlotSettings 17-9
SetPlotFolderSettings 17-10
WriteRegister 18-10
Fields Calculator commands
AddNamedExpr 18-2, 18-4
CalcOp 18-2
CalcStack 18-2
ChangeGeomSettings 18-3
ClcEval 18-3
ClcMaterial 18-3
CopyNamedExprToStack 18-4
DeleteNamedExpr 18-4
EnterComplex 18-5
EnterComplexVector 18-5
EnterLine 18-6
EnterPoint 18-6
EnterQty 18-6
EnterScalar 18-7
EnterScalarFunc 18-7
EnterSurf 18-7
EnterVector 18-8
EnterVectorFunc 18-8
EnterVol 18-9
ExportOnGrid 18-9
ExportToFile 18-10
WriteRegister 18-10
For...Next loop 1-8
Index-5
G
GenerateHistory 10-27
GetActiveDesign 4-3
GetActiveProject 3-2
GetDesign 4-3
GetFaceByPosition 10-34
GetModule 8-2
GetName 4-3, 8-3
GetOutputVariableValue 9-3
GetPath 4-3
GetProjectList 3-2
GetProperties 6-9
GetPropertyValue 6-9
GetSolveAsynchStatus 8-3
GetTopDesignList 4-4
GetVariables 6-9
GetVariableValue 6-10
H
help
Ansoft technical support iii
context-sensitive iii
on dialog boxes iii
on menu commands iii
hierarchy of variables in HFSS 2-2
I
If...Then... Else statement 1-7
Import 10-27
ImportSolution 16-11
ImportTable 16-12
InputBox function 1-9
InsertDesign 4-4
InsertDrivenSweep 14-3
InsertFarFieldSphereSetup 19-6
InsertNearFieldLineSetup 19-7
InsertNearFieldSphereSetup 19-8
InsertSetup
Analysis module command 14-5
Index-6
J
JavaScript, script format 1-1
K
keywords, VBScript 1-2
L
logical operators 1-6
M
material commands
AddMaterial 5-2
EditMaterial 5-3
ExportMaterial 5-3
RemoveMaterial 5-4
Mesh Operations module commands
AssignLengthOp 13-3
AssignSkinDepthOp 13-4
AssignTrueSurfOp 13-4
DeleteOp 13-2
EditLengthOp 13-5
EditSkinOp 13-6
EditTrueSurfOp 13-6
RenameOp 13-2
Microsoft
VBScript users guide 1-10
Visual Basic 1-1
Mirror 10-17
ModifyFieldPlot 17-7
modifying a script 2-7
ModifyPMLGroup 12-26
modules in HFSS scripting 2-4
Move 10-18
MoveFaces 10-28
MsgBox function 1-9
N
NewProject 3-2
O
oDesign object 2-3
oDesktop object 2-3
oEditor object 2-4
OffsetFaces 10-18
oHfssApp object 2-3
oModule object 2-4
OpenMultipleProjects 3-3
OpenProject 3-3
operators
arithmetic 1-5
categories in VBScript 1-5
comparison 1-6
logical 1-6
precedence of 1-5
oProject object 2-3
Optimetrics module commands
DeleteSetups 15-5
RenameSetup 15-5
SolveSetup 15-5
optimization commands
EditSetup 15-9
InsertSetup 15-9
output variable commands
AddOutputVariable 9-2
DeleteOutputVariable 9-2
EditOutputVariable 9-3
GetOutputVariableValue 9-3
P
PageSetup 10-35
parametric commands
EditSetup 15-6
InsertSetup 15-6
Paste 4-4, 10-18
PauseScript 3-3
pausing a script 2-6
PMLGroupCreated 12-26
PMLGroupModified 12-27
Print 3-4
Project object commands
AddDataset 7-2
AddMaterial 5-2
ChangeProperty 6-4
Close 4-2
CopyDesign 4-2
CutDesign 4-2
DeleteDataset 7-2
DeleteDesign 4-2
EditDataset 7-3
EditMaterial 5-3
ExportMaterial 5-3
GetActiveDesign 4-3
GetDesign 4-3
GetName 4-3
GetPath 4-3
GetProperties 6-9
GetPropertyValue 6-9
GetTopDesignList 4-4
GetVariables 6-9
GetVariableValue 6-10
InsertDesign 4-4
Paste 4-4
Redo 4-5
RemoveMaterial 5-4
Save 4-5
SaveAs 4-5
SetActiveDesign 4-6
SetPropertyValue 6-10
SetVariableValue 6-11
SimulateAll 4-6
Undo 4-6
property commands
ChangeProperty 6-4
GetProperties 6-9
Index-7
GetPropertyValue 6-9
GetVariables 6-9
GetVariableValue 6-10
SetPropertyValue 6-10
SetVariableValue 6-11
Q
QuitApplication 3-4
R
Radiation module commands
DeleteFarFieldSetup 19-2
DeleteNearFieldSetup 19-2
EditAntennaArraySetup 19-9
EditFarFieldSphereSetup 19-4
EditNearFieldSphereSetup 19-5
EditNearLineSetup 19-4
ExportRadiationParametersToFile
19-13
InsertFarFieldSphereSetup 19-6
InsertNearFieldLineSetup 19-7
InsertNearFieldSphereSetup 19-8
RenameSetup 19-3
ReassignBoundaries 12-3
RecalculatePMLMaterials 12-27
recording a script 2-6
Redo
design-level command 8-3
project-level command 4-5
references, for VBScript 1-10
RemoveMaterial 5-4
RemoveReport 11-8
RenameBoundary 12-3
RenameDesignInstance 8-4
RenameDrivenSweep 14-7
RenameFieldPlot 17-8
RenameOp 13-2
RenamePart 10-35
RenamePlotFolder 17-8
RenameSetup
Index-8
S
sample scripts
data export 20-6
simple HFSS 1-2
variable helix 20-2
SARSetup 8-4
Save 4-5
SaveAs 4-5
Scale 10-19
scripts
in JavaScript format 1-1
modifying for easier playback 2-7
pausing 2-6
recording 2-6
resuming 2-6
running 2-6
running from command prompt 1-1
stop recording 2-6
stopping execution of 2-7
Section 10-29
Select Case statement 1-7
sensitivity commands
EditSetup 15-13
InsertSetup 15-13
SeparateBody 10-29
SetActiveDesign 4-6
SetActiveEditor 8-4
SetActiveProject 3-6
SetFieldPlotSettings 17-9
SetModelUnits 10-30
SetPlotFolderSettings 17-10
SetPropertyValue 6-10
SetSolutionType 8-5
SetVariableValue 6-11
SetWCS 10-30
SimulateAll 4-6
Sleep 3-7
Solutions module commands
DeleteImportData 16-2
DeleteSolutionVariation 16-4
DeleteVariation 16-5
EditSources 16-2
ExportForHSpice 16-7
ExportForSpice 16-6
ExportNetworkData 16-9
ExportNMF 16-10
ImportSolution 16-11
ImportTable 16-12
Solve 8-5
SolveAsynch 8-6
SolveSetup
Analysis module command 14-8
Optimetrics module command 15-5
Split 10-31
statistical commands
EditSetup 15-15
InsertSetup 15-15
stopping a script 2-7
stopping script recording 2-6
Sub procedures 1-2
Subtract 10-31
SweepAlongPath 10-14
SweepAlongVector 10-14
SweepAroundAxis 10-15
U
UncoverFaces 10-32
underscore ( _ ) character 1-3
Undo
design-level command 8-6
project-level command 4-6
Unite 10-33
V
variables
array 1-4
assigning information 1-4
declaring 1-4
hierarchy in HFSS 2-2
used as objects 1-2
used in HFSS scripts 2-2
.vbs file format 2-6
VBScript
Microsoft users guide 1-10
operators 1-5
overview 1-1
references 1-10
Sub procedures 1-2
.vbs file format 2-6
W
WriteRegister 18-10
T
trademark notice ii
Index-9
Index-10