.. vale off :class:`Variable` ================= .. py:class:: ansys.mechanical.stubs.v241.Ansys.ACT.Mechanical.Fields.Variable Bases: :py:obj:`object` Represents an object that is either an input or an output for a P:Ansys.ACT.Mechanical.Fields.Variable.Field. Depending on whether it is an input or output and on the way it is defined, this object holds a series of discrete values or an expression that may involve other variables. .. !! processed by numpydoc !! .. py:currentmodule:: Variable Overview -------- .. tab-set:: .. tab-item:: Methods .. list-table:: :header-rows: 0 :widths: auto * - :py:attr:`~GetDiscreteValue` - Changes a value at a given position in the tabular definition of the variable. * - :py:attr:`~SetDiscreteValue` - Changes a value at a given position in the tabular definition of the variable. .. tab-item:: Properties .. list-table:: :header-rows: 0 :widths: auto * - :py:attr:`~Field` - Gets the owner field. * - :py:attr:`~IsInput` - Gets a value indicating whether this variable is an input for its container field. Otherwise, it is an output variable. * - :py:attr:`~IsOutput` - Gets a value indicating whether this variable is an output for its container field. Otherwise, it is an input variable. * - :py:attr:`~Index` - Gets the index of this variable in its container field. * - :py:attr:`~Name` - Gets the variable's name. * - :py:attr:`~Range` - Gets the domain of validity for variable's value. * - :py:attr:`~DefinitionType` - Gets a value that indicates how this variable is defined. * - :py:attr:`~DiscreteValueCount` - Gets the number of discrete values of this variable. * - :py:attr:`~DiscreteValues` - Gets or sets the discrete values of this variable or * - :py:attr:`~MinMaxDiscreteValues` - Returns a Tuple containing the min and max values from the list of discrete values. * - :py:attr:`~Formula` - Gets or sets the expression that is used to defined this variable, or * - :py:attr:`~Unit` - Gets the symbol of the unit used to express this variable's values. * - :py:attr:`~QuantityName` - Gets the name of the quantity represented by this variable. Property detail --------------- .. py:property:: Field :no-index: :type: Optional[Ansys.ACT.Mechanical.Fields.Field] Gets the owner field. .. !! processed by numpydoc !! .. py:property:: IsInput :no-index: :type: Optional[System.Boolean] Gets a value indicating whether this variable is an input for its container field. Otherwise, it is an output variable. .. !! processed by numpydoc !! .. py:property:: IsOutput :no-index: :type: Optional[System.Boolean] Gets a value indicating whether this variable is an output for its container field. Otherwise, it is an input variable. .. !! processed by numpydoc !! .. py:property:: Index :no-index: :type: Optional[System.Int32] Gets the index of this variable in its container field. .. !! processed by numpydoc !! .. py:property:: Name :no-index: :type: Optional[System.String] Gets the variable's name. .. !! processed by numpydoc !! .. py:property:: Range :no-index: :type: Optional[Ansys.ACT.Mechanical.Fields.Range] Gets the domain of validity for variable's value. .. !! processed by numpydoc !! .. py:property:: DefinitionType :no-index: :type: Optional[Ansys.ACT.Mechanical.Fields.VariableDefinitionType] Gets a value that indicates how this variable is defined. .. !! processed by numpydoc !! .. py:property:: DiscreteValueCount :no-index: :type: Optional[System.Int32] Gets the number of discrete values of this variable. .. !! processed by numpydoc !! .. py:property:: DiscreteValues :no-index: :type: Optional[System.Collections.Generic.IList[Ansys.Core.Units.Quantity]] Gets or sets the discrete values of this variable or .. !! processed by numpydoc !! .. py:property:: MinMaxDiscreteValues :no-index: :type: Optional[System.Tuple[Ansys.Core.Units.Quantity,Ansys.Core.Units.Quantity]] Returns a Tuple containing the min and max values from the list of discrete values. .. !! processed by numpydoc !! .. py:property:: Formula :no-index: :type: Optional[System.String] Gets or sets the expression that is used to defined this variable, or .. !! processed by numpydoc !! .. py:property:: Unit :no-index: :type: Optional[System.String] Gets the symbol of the unit used to express this variable's values. .. !! processed by numpydoc !! .. py:property:: QuantityName :no-index: :type: Optional[System.String] Gets the name of the quantity represented by this variable. .. !! processed by numpydoc !! Method detail ------------- .. py:method:: GetDiscreteValue(index: System.Int32) -> Ansys.Core.Units.Quantity :no-index: Changes a value at a given position in the tabular definition of the variable. .. !! processed by numpydoc !! .. py:method:: SetDiscreteValue(index: System.Int32, value: Ansys.Core.Units.Quantity) -> System.Void :no-index: Changes a value at a given position in the tabular definition of the variable. .. !! processed by numpydoc !! .. vale on