Creating Inputs
An input is a parameter that shows up in the Settings window of the feature instance in the Model Builder. An input always represent data storage in a COMSOL Multiphysics model (MPH file) built with the Model Builder. You can choose to hide an input from the Settings window, and then the input only represents a data storage.
The value of a variable, on the other hand, can be read when solving or from result features in the Model Builder. This is not possible with user inputs. If you want to access a value of an input, you must first declare a variable and define its value equal to the value of the input. It is possible to add a variable definition to an input node, which represents a variable declaration and a variable definition. The declaration takes the information from the input, and the definition gives the declared variable the value of the input.
Standard Inputs
There are these types of standard inputs:
User Input. This is a general user input that supports all settings and sizes. It is a bit more complex to set up due to the number of supported settings.
Selectable Input. A user input that a user only can set to a predefined set of allowed values. It does not support units or array types. The typical GUI component is a combo box (or dropdown menu).
Boolean Input. A user input that only allows two values, 0 and 1 (represents false and true). It does not support units or array types. The typical GUI component is a checkbox.
Special Versions of Inputs
There are also special versions of inputs, which add predefined declarations of one or several user inputs with a special relation, for example. These special user inputs are summarized below:
Material Property. Defines two user inputs: one for selecting the source of the material data and the other for specifying a user-defined value.
Material List. Defines a user input that contains a material selection.
Feature Input. Defines two user inputs: one for selecting the source of the feature input data and the other for specifying a user-defined value.
Selection Input. Defines an extra selection of geometrical entities for the feature to select entities on different domains when coupling them to the feature, for example
GUI Options Settings
A user input also needs information about its appearance in the user interface. It is possible to control how it appears, when it appears, and where it appears in the Settings window of a feature or property. You control these settings from the GUI Options section of each user input node and through a special activation condition node; see Activation Condition.