Params Window

Window ‣ Parameters (F11)

Schema project can store a number of parameters which are independent from element so they called “global parameters”. Their values can be assigned directly or can depend on other parameters and be expressed via formula (see below).

Global parameters can be used for providing values for element parameters and this gives an ability to make interconnected and driven elements in the schema - when you change a value of some global parameter and this instantly affects several elements at once.

_images/params_window.png

Create New Parameter

Parameter ‣ Create… (Ctrl+Ins)

When creating a new parameter, one should specify its Name and Dimension, these two are mandatory and can not be changed later. While Unit only takes a default value, actual unit of measurement can be changed later when specifying parameter magnitude.

_images/params_window_create.png

Annotate Parameter

Parameter ‣ Annotate… (Ctrl+Return)

Annotation is just a short human readable description of parameter.

_images/params_window_annotate.png

Set Parameter Value

Parameter ‣ Set… (Return)

Parameter value can be assigned directly via dialog. You can override unit of measurement specified during the parameter construction.

_images/params_window_set.png

Set Parameter Formula

Parameter ‣ Set… (Return) ‣ Add formula

Parameter value can be derived from values of other parameters. You can provide a formula for value calculation. In the “Set value” dialog click the right bars menu and select the Add formula item. Later, use the same menu and the command Remove formula if you don’t need formula any longer and want to provide parameter value directly.

_images/params_window_formula_1.png

A dialog appears where you can type an expression that will be calculated to obtain the parameter value. Formulas are written in Lua syntax (see Lua Script Primer). While you type, the formula is instantly checked for correctness and a red marker shows if something is wrong with it.

_images/params_window_formula_2.png

The formula can depend on values of other parameters, it will be automatically recomputed and a new parameter value obtained when one of dependencies changes. Dependencies must be stated explicitly in the “Params” page of the dialog. Click the Plus button and select a parameter to dependent on. Several dependencies can be added one by one.

_images/params_window_formula_3.png

When dependencies are registered, you can use them by name in the formula code to derive the parameter value from. Here in the picture L0 and F0 are names of other parameters added as dependencies:

_images/params_window_formula_4.png

When parameter is driven by formula, it is marked by the “gear” icon in the table and the list of dependencies is shown in the “Name” column. E.g. L1 = f(L0, F0) means that a value for parameter L1 is somehow calculated from values of parameters L0 and F0 which are also here in the table.

_images/params_window_formula_5.png

Adjust Parameter

Parameter ‣ Adjust

Global parameter can be used in the Adjustment tool like any other element parameter. Just select the Adjust command from the parameters table context menu or use the Adjust command in the window menu. But if the parameter is driven by formula it can not be really adjusted because you can’t provide a value to the driven parameter directly (see that value of L1 is marked in italic font in the picture below). Instead you have to adjust its dependencies and the Adjuster tool will reflect how the driven value is changed.

_images/params_window_adjust.png

Delete Parameter

Parameter ‣ Delete (Ctrl+Del)

The system checks if a parameter under deletion is a dependency for another global parameter or if there is an element parameter linked to it and prevents deletion of such parameter. All dependencies and links should be refused manually.