Adding a Local Variable at the Design Level

A design variable is associated with a Twin Builder design. You can assign a design variable to a parameter value in the Twin Builder design in which it was created.

  1. Select Twin Builder > Design Properties.
  1. Under the Local Variables tab, click Add. The Add Property dialog box appears.
  1. In the Name text box, type the name of the variable.
    Note:
  2. In the Unit Type text box, use the drop-down list to select from the list of available unit types. None is the default.

When you select a unit type, the choices in the Units drop-down list adapt to that unit type. For example, selecting Length as the unit type causes the Unit menu to show a range of metric and English units for length. Similarly, if you select the Resistance unit type, the Units drop-down list displays a range of standard Ohm units.

  1. In the Value text box, type the quantity that the variable represents. Optionally, include the units of measurement.
    Note:

    If you include the variable’s units in its definition (in the Value text box), do not include the variable’s units when you enter the variable name for a parameter value.

  2. The quantity can be a numerical value, a mathematical expression, or a mathematical function. The quantity entered will be the current (or default value) for the variable. If the mathematical expression includes a reference to an existing variable, this variable is treated as a dependent variable. The units for a dependent variable will change to those of the independent variable on which the value depends. Additionally, dependent variables, though useful in many situations, cannot be the direct subject of optimization, sensitivity analysis, tuning, or statistical analysis.

    Note:

    Complex numbers are not allowed for variables to be used in an Optimetrics sweep, or for optimization, statistical, sensitivity, or tuning setups.

  1. Click OK to return to the Properties dialog box.

The new variable and its value appear in the table. If the value is an expression, the evaluated value displays. Updating the expression also changes the evaluated value display.

  1. Optionally, type a description of the variable in the Description text box.
  2. The new variable can now be assigned to a parameter value in the design in which it was created.

    Note:

    Local Variables are not usable in the design’s subcircuits and are not in the design’s public interface (that is, they are not visible on the component representing the design when it is used as a subdesign).

Related Topics 

Adding an Array of Values for a Local Variable

Design Variables vs. Equation Variables