Parametric Analysis > Using Design Variables

www.kxcad.net Home > CAE Index > MSC Software Index > Adams MD R2 Index


Your Ad Here

Using Design Variables
Design variables let you invent your own independent parameters and tie modeling objects to them. For example, if you have three cylinders in your model that you want to keep the same length, you can create a design variable called cylinder_length and control all three cylinder lengths with the design variable.
Design variables also let you organize the critical parameters in your design into a concise list of values that you can easily review and modify. In addition, you can use parametric analyses to automatically execute a series of simulations that vary your design variables.
Design variables are Adams/View variable objects. Variable objects are general-purpose places to store data or expressions. A design variable is a variable you use specifically to parameterize your model. This chapter and the parameterization tools use the term design variable. Some tools, such as the Command Navigator and the Table Editor, apply to all variables, however. In those contexts, you see just the term variable. It it applies to all variables, including design variables.
Also see Updating Variables.
Creating Design Variables
You create design variables using the Create Design Variable dialog box or the Create Design Variable command that appears in the shortcut menu of any text box that accepts a design variable.
The Create Design Variable dialog box lets you select the type of design variable you want and assign a value to the variable. It does not place the variable in your model where it is to be used, however.
The Create Design Variable command on the shortcut menu lets you create a design variable and places the variable in your model where it will be used, all in one operation. It uses default values for your variable. You must modify the variable to change its type or name.
You should choose whichever method is most convenient:
Creating Design Variables using a Dialog Box
Creating Design Variables using a Dialog Box
The following procedure explains how to create a design variable using a dialog box. You can create a design variable of the following types: real, integer, string, and object. For real and integer variables, you can also specify information about how to vary the value during a parametric analysis. These options are described in Controlling Variable Values.
To create a design variable using the Create Design Variable dialog box:
1.
From the Build menu, point to Design Variable, and then select New.
The Create Design Variable dialog box appears.
2.
In the Name text box, enter the name of the design variable. Adams/View creates a default name for you. Select the type of design variable to create.
3.
4.
5.
Adams/View creates the design variable.
Now that you've created a design variable, you'll need to reference it in your model. You can enter the design variable directly, using the Reference Design Variable command, or you can type it into a text box. You can also use the Function Builder to create a more complex expression using the design variable. When you reference your design variable, Adams/View places parentheses () around the variable because you are creating a simple expression that references the value of the design variable.
To reference a design variable in your model:
1.
2.
Right-click the text box representing the value to be parameterized, point to Parameterize, and then select Reference Design Variable.
Adams/View displays the Database Navigator.
3.
Adams/View inserts an expression such as (.my_model.my_design_var) into the text box.
4.
Adams/View creates or modifies the object using your design variable for the value you selected.
Creating a Design Variable using the Shortcut Menu
You can use the Create Design Variable command on the shortcut menu to create a design variable and place the appropriate expression in a text box all in one operation. Adams/View uses the value currently in the text box as the standard value.
To create a design variable using the Create Design Variable option:
1.
2.
3.
Right-click the text box, point to Parameterize, and then select Create Design Variable.
Adams/View creates a new design variable with a default name and the value that was in the text box and inserts an expression such as (.my_model.DV_1) into the text box.
4.
Adams/View creates or modifies the object using your design variable for the value you selected.
Modifying Design Variables
You can modify a design variable, such as change its standard value. You can use the Modify Design Variable dialog box or the Table Editor.
To modify a design variable using the Modify Design Variable dialog box:
1.
From the Build menu, select Design Variable, and then point to Modify.
The Database Navigator appears.
2.
Adams/View displays the Modify Design Variable dialog box and loads the current properties for the design variable you selected.
3.
4.
If you changed the value of the design variable, Adams/View immediately updates any objects that refer to the design variable.
To modify a design variable using the Table Editor:
1.
From the Tools menu, select Table Editor.
The Table Editor appears.
2.
3.
4.
If you changed the value of a design variable, Adams/View immediately updates any objects that refer to the design variable.
 
Note:  
By default, the Table Editor displays only variables of the type real in your model. You can display other types of variables, such as string, object, or integer, and control the columns that are displayed using the Filters button, which displays the Variables Table Editor Filters dialog box. Learn about Setting Types of Objects Displayed in the Table Editor.
Using Design Variables with Points
As explained in Using Points, points are an easy way to parameterize the geometry of your model. To vary a point in a parametric analysis, however, you must create design variables for one or more coordinates of the point.
To parameterize a point coordinate:
1.
Modify the point.
Adams/View displays the Table Editor showing the points in your model.
2.
Adams/View displays the cell value in the Input text box.
3.
Right-click the Input text box, point to Parameterize, point to Create Design Variable, and then select Real.
Adams/View creates a new design variable with a default name and the value that was in the text box and inserts an expression, such as (.my_model.DV_1), into the text box.
4.
Adams/View modifies the point to use the design variable as the coordinate value.
Your Ad Here