- functionThe function to use for controlling the specified parameter.
C++ Type:FunctionName
Unit:(no unit assumed)
Controllable:No
Description:The function to use for controlling the specified parameter.
- parameterThe input parameter(s) to control. Specify a single parameter name and all parameters in all objects matching the name will be updated
C++ Type:std::string
Unit:(no unit assumed)
Controllable:No
Description:The input parameter(s) to control. Specify a single parameter name and all parameters in all objects matching the name will be updated
RealFunctionControl
The RealFunctionControl
object is designed to control a "Real" parameter with a function rather than use the value specified in the input file. This object is mainly a demonstration of how to create a Control object and modify a parameter.
Example
Consider a simulation that solves the diffusion equation, where the Laplacian term has a coefficient, but the coefficient is defined as a constant input parameter ("coef"). For some reason, it is desired to control this coefficient and replace the constant value with a function that varies with space and time; this function is defined in the Functions block.
The RealFunctionControl
object is designed for this purpose as shown in Listing 1.
[Controls]
[./func_control]
type = RealFunctionControl
parameter = '*/*/coef'
function = 'func_coef'
execute_on = 'initial timestep_begin'
[../]
[]
(moose/test/tests/controls/real_function_control/real_function_control.i)Notice that the "parameter" input parameter is expecting a parameter name which can be defined in various forms.
For a discussion on the naming of objects and parameters see Object and Parameter Names section.
Input Parameters
- depends_onThe Controls that this control relies upon (i.e. must execute before this one)
C++ Type:std::vector<std::string>
Unit:(no unit assumed)
Controllable:No
Description:The Controls that this control relies upon (i.e. must execute before this one)
- execute_onINITIAL TIMESTEP_ENDThe list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html.
Default:INITIAL TIMESTEP_END
C++ Type:ExecFlagEnum
Unit:(no unit assumed)
Controllable:No
Description:The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html.
Optional Parameters
- control_tagsAdds user-defined labels for accessing object parameters via control logic.
C++ Type:std::vector<std::string>
Unit:(no unit assumed)
Controllable:No
Description:Adds user-defined labels for accessing object parameters via control logic.
- enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Unit:(no unit assumed)
Controllable:No
Description:Set the enabled status of the MooseObject.
- implicitTrueDetermines whether this object is calculated using an implicit or explicit form
Default:True
C++ Type:bool
Unit:(no unit assumed)
Controllable:No
Description:Determines whether this object is calculated using an implicit or explicit form