24 std::string var_param_name,
27 : _nodal(nodal), _moose_object(*moose_object)
36 parameters.
varName(var_param_name, moose_object->
name()),
38 expected_var_field_type);
58 ". Did you forget to set fv = true in the Variables block?");
68 "_variable is null in ", _moose_object.name(),
". Are you using a finite volume variable?");
77 return _variable->dofValues();
79 return _variable->sln();
87 mooseError(
"Dofs are scalars while vector variables have vector values. Mismatch");
97 return _variable->dofValuesOld();
99 return _variable->slnOld();
107 mooseError(
"Dofs are scalars while vector variables have vector values. Mismatch");
112 template <
typename T>
117 return _variable->dofValuesOlder();
119 return _variable->slnOlder();
127 mooseError(
"Dofs are scalars while vector variables have vector values. Mismatch");
132 template <
typename T>
137 return _variable->dofValuesDot();
139 return _variable->uDot();
142 template <
typename T>
147 return _variable->dofValuesDotDot();
149 return _variable->uDotDot();
152 template <
typename T>
157 return _variable->dofValuesDotOld();
159 return _variable->uDotOld();
162 template <
typename T>
167 return _variable->dofValuesDotDotOld();
169 return _variable->uDotDotOld();
177 mooseError(
"Dofs are scalars while vector variables have vector values. Mismatch");
187 mooseError(
"Dofs are scalars while vector variables have vector values. Mismatch");
197 mooseError(
"Dofs are scalars while vector variables have vector values. Mismatch");
207 mooseError(
"Dofs are scalars while vector variables have vector values. Mismatch");
212 template <
typename T>
217 return _variable->dofValuesDuDotDu();
219 return _variable->duDotDu();
222 template <
typename T>
227 return _variable->dofValuesDuDotDotDu();
229 return _variable->duDotDotDu();
232 template <
typename T>
237 mooseError(
"gradients are not defined at nodes");
239 return _variable->gradSln();
242 template <
typename T>
247 mooseError(
"gradients are not defined at nodes");
249 return _variable->gradSlnOld();
252 template <
typename T>
257 mooseError(
"gradients are not defined at nodes");
259 return _variable->gradSlnOlder();
262 template <
typename T>
267 mooseError(
"second derivatives are not defined at nodes");
269 return _variable->secondSln();
272 template <
typename T>
277 mooseError(
"second derivatives are not defined at nodes");
279 return _variable->secondSlnOld();
282 template <
typename T>
287 mooseError(
"second derivatives are not defined at nodes");
289 return _variable->secondSlnOlder();
292 template <
typename T>
297 mooseError(
"second derivatives are not defined at nodes");
299 return _variable->secondPhi();
302 template <
typename T>
307 mooseError(
"second derivatives are not defined at nodes");
309 return _variable->secondPhiFace();
312 template <
typename T>
317 mooseError(
"second derivatives are not defined at nodes");
319 return _mvi_assembly->secondPhi(*_variable);
322 template <
typename T>
327 mooseError(
"second derivatives are not defined at nodes");
329 return _mvi_assembly->secondPhiFace(*_variable);
332 template <
typename T>
341 mooseError(
"Either _variable or _fv_variable must be non-null in MooseVariableInterface");
343 return *_fv_variable;
virtual const OutputTools< T >::VariableValue & valueOld()
The old value of the variable this object is operating on.
virtual const OutputTools< T >::VariablePhiSecond & secondPhiFace()
The second derivative of the trial function on the current face.
MooseVariableFV< T > * mooseVariableFV() const
virtual const OutputTools< T >::VariableGradient & gradientOld()
The old gradient of the variable this object is operating on.
MooseVariableBase * _var
The variable this object is acting on.
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application...
OutputTools< RealVectorValue >::VariableValue VectorVariableValue
virtual const OutputTools< T >::VariableValue & dotDot()
The second time derivative of the variable this object is operating on.
virtual const OutputTools< T >::VariableValue & dotDotOld()
The old second time derivative of the variable this object is operating on.
const FieldVariableValue & uDotOld() const
bool _nodal
Whether or not this object is acting only at nodes.
MooseVariableFV< T > * _fv_variable
virtual const std::string & name() const
Get the name of the class.
const FieldVariableValue & uDot() const
element dots
virtual const VariableValue & dotDotDu()
The derivative of the second time derivative of the variable this object is operating on with respect...
MooseVariableFE< T > * mooseVariable() const
virtual const OutputTools< T >::VariableValue & valueOlder()
The older value of the variable this object is operating on.
virtual const OutputTools< T >::VariableGradient & gradientOlder()
The older gradient of the variable this object is operating on.
Every object that can be built by the factory should be derived from this class.
const FieldVariableValue & uDotDot() const
const FieldVariableValue & sln() const override
element solutions
VarKindType
Framework-wide stuff.
const FieldVariableValue & uDotDotOld() const
virtual const OutputTools< T >::VariableTestSecond & secondTest()
The second derivative of the test function.
virtual const OutputTools< T >::VariableValue & value()
The value of the variable this object is operating on.
virtual const OutputTools< T >::VariableValue & dotOld()
The old time derivative of the variable this object is operating on.
unsigned int number() const
Gets the number of this system.
MooseVariableFE< T > * _variable
virtual const MooseVariableFieldBase & getVariable(const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY) const =0
Returns the variable reference for requested variable which must be of the expected_var_type (Nonline...
virtual const OutputTools< T >::VariableTestSecond & secondTestFace()
The second derivative of the test function on the current face.
OutputTools< Real >::VariableValue VariableValue
virtual const VariableValue & dotDu()
The derivative of the time derivative of the variable this object is operating on with respect to thi...
const FieldVariableValue & slnOlder() const override
virtual const OutputTools< T >::VariableValue & dot()
The time derivative of the variable this object is operating on.
Generic class for solving transient nonlinear problems.
Moose::VarKindType kind() const
Kind of the variable (Nonlinear, Auxiliary, ...)
virtual const OutputTools< T >::VariableGradient & gradient()
The gradient of the variable this object is operating on.
MooseVariableField< T > & mooseVariableField()
Return the MooseVariableField<T> object that this interface acts on.
const MooseObject & _moose_object
virtual const OutputTools< T >::VariableSecond & secondOld()
The old second derivative of the variable this object is operating on.
const InputParameters & parameters() const
Get the parameters of the object.
virtual const OutputTools< T >::VariableSecond & second()
The second derivative of the variable this object is operating on.
virtual const OutputTools< T >::VariablePhiSecond & secondPhi()
The second derivative of the trial function.
const FieldVariableValue & slnOld() const override
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int nl_sys_num)=0
SystemBase & sys()
Get the system this variable is part of.
virtual ~MooseVariableInterface()
virtual const OutputTools< T >::VariableSecond & secondOlder()
The older second derivative of the variable this object is operating on.
MooseVariableInterface(const MooseObject *moose_object, bool nodal, std::string var_param_name="variable", Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY)
Constructing the object.