https://mooseframework.inl.gov
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Attributes | List of all members
KokkosIntegralVariablePostprocessor< Base > Class Template Reference

#include <KokkosIntegralVariablePostprocessor.h>

Inheritance diagram for KokkosIntegralVariablePostprocessor< Base >:
[legend]

Public Member Functions

 KokkosIntegralVariablePostprocessor (const InputParameters &parameters)
 
KOKKOS_FUNCTION Real computeQpIntegral (const unsigned int qp, Datum &datum) const
 
MooseVariableBasemooseVariableBase () const
 Get the variable that this object is using.
 
MooseVariableField< Real > & mooseVariableField ()
 Return the MooseVariableField object that this interface acts on.
 
MooseVariableFE< Real > * mooseVariable () const
 Return the MooseVariableFE object that this interface acts on.
 
MooseVariableFV< Real > * mooseVariableFV () const
 Return the MooseVariableFV object that this interface acts on.
 
MooseLinearVariableFV< Real > * mooseLinearVariableFV () const
 Return the MooseLinearVariableFV object that this interface acts on.
 

Static Public Member Functions

static InputParameters validParams ()
 

Protected Member Functions

virtual const OutputTools< Real >::VariableValuevalue ()
 The value of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableValuevalueOld ()
 The old value of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableValuevalueOlder ()
 The older value of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableValuedot ()
 The time derivative of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableValuedotDot ()
 The second time derivative of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableValuedotOld ()
 The old time derivative of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableValuedotDotOld ()
 The old second time derivative of the variable this object is operating on.
 
virtual const VariableValuedotDu ()
 The derivative of the time derivative of the variable this object is operating on with respect to this variable's coefficients.
 
virtual const VariableValuedotDotDu ()
 The derivative of the second time derivative of the variable this object is operating on with respect to this variable's coefficients.
 
virtual const OutputTools< Real >::VariableGradientgradient ()
 The gradient of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableGradientgradientOld ()
 The old gradient of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableGradientgradientOlder ()
 The older gradient of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableSecondsecond ()
 The second derivative of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableSecondsecondOld ()
 The old second derivative of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableSecondsecondOlder ()
 The older second derivative of the variable this object is operating on.
 
virtual const OutputTools< Real >::VariableTestSecondsecondTest ()
 The second derivative of the test function.
 
virtual const OutputTools< Real >::VariableTestSecondsecondTestFace ()
 The second derivative of the test function on the current face.
 
virtual const OutputTools< Real >::VariablePhiSecondsecondPhi ()
 The second derivative of the trial function.
 
virtual const OutputTools< Real >::VariablePhiSecondsecondPhiFace ()
 The second derivative of the trial function on the current face.
 

Protected Attributes

Moose::Kokkos::VariableValue _u
 Holds the solution at current quadrature points.
 
Moose::Kokkos::VariableGradient _grad_u
 Holds the solution gradient at the current quadrature points.
 
const bool _use_abs_value
 Option to use absolute variable value.
 
bool _nodal
 Whether or not this object is acting only at nodes.
 
MooseVariableBase_var
 The variable this object is acting on.
 
MooseVariableFE< Real > * _variable
 
MooseVariableFV< Real > * _fv_variable
 
MooseLinearVariableFV< Real > * _linear_fv_variable
 
MooseVariableField< Real > * _field_variable
 
Assembly_mvi_assembly
 

Private Attributes

const MooseObject_moose_object
 

Detailed Description

template<typename Base>
class KokkosIntegralVariablePostprocessor< Base >

Definition at line 16 of file KokkosIntegralVariablePostprocessor.h.

Constructor & Destructor Documentation

◆ KokkosIntegralVariablePostprocessor()

template<typename Base >
KokkosIntegralVariablePostprocessor< Base >::KokkosIntegralVariablePostprocessor ( const InputParameters parameters)

Member Function Documentation

◆ computeQpIntegral()

template<typename Base >
KOKKOS_FUNCTION Real KokkosIntegralVariablePostprocessor< Base >::computeQpIntegral ( const unsigned int  qp,
Datum datum 
) const
inline

Definition at line 36 of file KokkosIntegralVariablePostprocessor.h.

38{
40 return Kokkos::abs(_u(datum, qp));
41 else
42 return _u(datum, qp);
43}
Moose::Kokkos::VariableValue _u
Holds the solution at current quadrature points.
const bool _use_abs_value
Option to use absolute variable value.

◆ dot()

const OutputTools< Real >::VariableValue & MooseVariableInterface< Real >::dot ( )
protectedvirtualinherited

The time derivative of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 103 of file MooseVariableInterface.C.

149{
150 if (_nodal)
151 return _variable->dofValuesDot();
152 else
153 return _variable->uDot();
154}
const DofValues & dofValuesDot() const override
const FieldVariableValue & uDot() const
element dots
MooseVariableFE< Real > * _variable
bool _nodal
Whether or not this object is acting only at nodes.

◆ dotDot()

const OutputTools< Real >::VariableValue & MooseVariableInterface< Real >::dotDot ( )
protectedvirtualinherited

The second time derivative of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 110 of file MooseVariableInterface.C.

159{
160 if (_nodal)
161 return _variable->dofValuesDotDot();
162 else
163 return _variable->uDotDot();
164}
const FieldVariableValue & uDotDot() const
const DofValues & dofValuesDotDot() const override

◆ dotDotDu()

const VariableValue & MooseVariableInterface< Real >::dotDotDu ( )
protectedvirtualinherited

The derivative of the second time derivative of the variable this object is operating on with respect to this variable's coefficients.

This is useful for creating Jacobian entries for residual statements that use _u_dotdot

Returns
The reference to be stored off and used later.

Definition at line 144 of file MooseVariableInterface.C.

239{
240 if (_nodal)
242 else
243 return _variable->duDotDotDu();
244}
const VariableValue & duDotDotDu() const
const MooseArray< libMesh::Number > & dofValuesDuDotDotDu() const override

◆ dotDotOld()

const OutputTools< Real >::VariableValue & MooseVariableInterface< Real >::dotDotOld ( )
protectedvirtualinherited

The old second time derivative of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 124 of file MooseVariableInterface.C.

179{
180 if (_nodal)
182 else
183 return _variable->uDotDotOld();
184}
const DofValues & dofValuesDotDotOld() const override
const FieldVariableValue & uDotDotOld() const

◆ dotDu()

const VariableValue & MooseVariableInterface< Real >::dotDu ( )
protectedvirtualinherited

The derivative of the time derivative of the variable this object is operating on with respect to this variable's coefficients.

This is useful for creating Jacobian entries for residual statements that use _u_dot

Returns
The reference to be stored off and used later.

Definition at line 134 of file MooseVariableInterface.C.

229{
230 if (_nodal)
231 return _variable->dofValuesDuDotDu();
232 else
233 return _variable->duDotDu();
234}
const MooseArray< libMesh::Number > & dofValuesDuDotDu() const override
const VariableValue & duDotDu() const

◆ dotOld()

const OutputTools< Real >::VariableValue & MooseVariableInterface< Real >::dotOld ( )
protectedvirtualinherited

The old time derivative of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 117 of file MooseVariableInterface.C.

169{
170 if (_nodal)
171 return _variable->dofValuesDotOld();
172 else
173 return _variable->uDotOld();
174}
const FieldVariableValue & uDotOld() const
const DofValues & dofValuesDotOld() const override

◆ gradient()

const OutputTools< Real >::VariableGradient & MooseVariableInterface< Real >::gradient ( )
protectedvirtualinherited

The gradient of the variable this object is operating on.

This is computed by default and should already be available as _grad_u

Returns
The reference to be stored off and used later.

Definition at line 153 of file MooseVariableInterface.C.

249{
250 if (_nodal)
251 mooseError("gradients are not defined at nodes");
252
253 return _variable->gradSln();
254}
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application.
Definition MooseError.h:311
const FieldVariableGradient & gradSln() const override
element gradients

◆ gradientOld()

const OutputTools< Real >::VariableGradient & MooseVariableInterface< Real >::gradientOld ( )
protectedvirtualinherited

The old gradient of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 160 of file MooseVariableInterface.C.

259{
260 if (_nodal)
261 mooseError("gradients are not defined at nodes");
262
263 return _variable->gradSlnOld();
264}
const FieldVariableGradient & gradSlnOld() const override

◆ gradientOlder()

const OutputTools< Real >::VariableGradient & MooseVariableInterface< Real >::gradientOlder ( )
protectedvirtualinherited

The older gradient of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 167 of file MooseVariableInterface.C.

269{
270 if (_nodal)
271 mooseError("gradients are not defined at nodes");
272
273 return _variable->gradSlnOlder();
274}
const FieldVariableGradient & gradSlnOlder() const

◆ mooseLinearVariableFV()

MooseLinearVariableFV< Real > * MooseVariableInterface< Real >::mooseLinearVariableFV ( ) const
inherited

Return the MooseLinearVariableFV object that this interface acts on.

Definition at line 70 of file MooseVariableInterface.C.

69{
72 "The variable defined in ", _moose_object.name(), " is not a MooseLinearVariableFV!");
74}
const std::string & name() const
Get the name of the class.
Definition MooseBase.h:103
MooseLinearVariableFV< Real > * _linear_fv_variable

◆ mooseVariable()

MooseVariableFE< Real > * MooseVariableInterface< Real >::mooseVariable ( ) const
inherited

Return the MooseVariableFE object that this interface acts on.

Definition at line 60 of file MooseVariableInterface.C.

79{
80 if (!_variable)
82 "_variable is null in ", _moose_object.name(), ". Are you using a finite volume variable?");
83 return _variable;
84}

◆ mooseVariableBase()

MooseVariableBase * MooseVariableInterface< Real >::mooseVariableBase ( ) const
inlineinherited

Get the variable that this object is using.

Returns
The variable this object is using.

Definition at line 50 of file MooseVariableInterface.h.

50{ return _var; };
MooseVariableBase * _var
The variable this object is acting on.

◆ mooseVariableField()

MooseVariableField< Real > & MooseVariableInterface< Real >::mooseVariableField ( )
inherited

Return the MooseVariableField object that this interface acts on.

Definition at line 55 of file MooseVariableInterface.C.

355{
356 return *_field_variable;
357}
MooseVariableField< Real > * _field_variable

◆ mooseVariableFV()

MooseVariableFV< Real > * MooseVariableInterface< Real >::mooseVariableFV ( ) const
inherited

Return the MooseVariableFV object that this interface acts on.

Definition at line 65 of file MooseVariableInterface.C.

58{
59 if (!_fv_variable)
60 mooseError("_fv_variable is null in ",
62 ". Did you forget to set fv = true in the Variables block?");
63 return _fv_variable;
64}
MooseVariableFV< Real > * _fv_variable

◆ second()

const OutputTools< Real >::VariableSecond & MooseVariableInterface< Real >::second ( )
protectedvirtualinherited

The second derivative of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 174 of file MooseVariableInterface.C.

279{
280 if (_nodal)
281 mooseError("second derivatives are not defined at nodes");
282
283 return _variable->secondSln();
284}
const FieldVariableSecond & secondSln() const
element seconds

◆ secondOld()

const OutputTools< Real >::VariableSecond & MooseVariableInterface< Real >::secondOld ( )
protectedvirtualinherited

The old second derivative of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 181 of file MooseVariableInterface.C.

289{
290 if (_nodal)
291 mooseError("second derivatives are not defined at nodes");
292
293 return _variable->secondSlnOld();
294}
const FieldVariableSecond & secondSlnOld() const

◆ secondOlder()

const OutputTools< Real >::VariableSecond & MooseVariableInterface< Real >::secondOlder ( )
protectedvirtualinherited

The older second derivative of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 188 of file MooseVariableInterface.C.

299{
300 if (_nodal)
301 mooseError("second derivatives are not defined at nodes");
302
303 return _variable->secondSlnOlder();
304}
const FieldVariableSecond & secondSlnOlder() const

◆ secondPhi()

const OutputTools< Real >::VariablePhiSecond & MooseVariableInterface< Real >::secondPhi ( )
protectedvirtualinherited

The second derivative of the trial function.

Returns
The reference to be stored off and used later.

Definition at line 211 of file MooseVariableInterface.C.

329{
330 if (_nodal)
331 mooseError("second derivatives are not defined at nodes");
332
334 mooseError("second order shape function derivatives not available for linear FV variables");
335
337}
const VariablePhiSecond & secondPhi() const
Definition Assembly.h:1329

◆ secondPhiFace()

const OutputTools< Real >::VariablePhiSecond & MooseVariableInterface< Real >::secondPhiFace ( )
protectedvirtualinherited

The second derivative of the trial function on the current face.

This should be called in e.g. IntegratedBC when you need second derivatives of the trial function function on the boundary.

Returns
The reference to be stored off and used later.

Definition at line 220 of file MooseVariableInterface.C.

342{
343 if (_nodal)
344 mooseError("second derivatives are not defined at nodes");
345
347 mooseError("second order shape function derivatives not available for linear FV variables");
348
350}
const VariablePhiSecond & secondPhiFace(const MooseVariableField< Real > &) const
Definition Assembly.h:1342

◆ secondTest()

const OutputTools< Real >::VariableTestSecond & MooseVariableInterface< Real >::secondTest ( )
protectedvirtualinherited

The second derivative of the test function.

Returns
The reference to be stored off and used later.

Definition at line 195 of file MooseVariableInterface.C.

309{
310 if (_nodal)
311 mooseError("second derivatives are not defined at nodes");
312
313 return _variable->secondPhi();
314}
const FieldVariablePhiSecond & secondPhi() const override final
Return the rank-2 tensor of second derivatives of the variable's elemental shape functions.

◆ secondTestFace()

const OutputTools< Real >::VariableTestSecond & MooseVariableInterface< Real >::secondTestFace ( )
protectedvirtualinherited

The second derivative of the test function on the current face.

This should be called in e.g. IntegratedBC when you need second derivatives of the test function function on the boundary.

Returns
The reference to be stored off and used later.

Definition at line 204 of file MooseVariableInterface.C.

319{
320 if (_nodal)
321 mooseError("second derivatives are not defined at nodes");
322
323 return _variable->secondPhiFace();
324}
const FieldVariablePhiSecond & secondPhiFace() const override final
Return the rank-2 tensor of second derivatives of the variable's shape functions on an element face.

◆ validParams()

template<typename Base >
static InputParameters KokkosIntegralVariablePostprocessor< Base >::validParams ( )
static

◆ value()

const OutputTools< Real >::VariableValue & MooseVariableInterface< Real >::value ( )
protectedvirtualinherited

The value of the variable this object is operating on.

This is computed by default and should already be available as _u

Returns
The reference to be stored off and used later.

Definition at line 82 of file MooseVariableInterface.C.

89{
90 if (_nodal)
91 return _variable->dofValues();
92 else
93 return _variable->sln();
94}
const DofValues & dofValues() const override
dof values getters
const FieldVariableValue & sln() const override
element solutions

◆ valueOld()

const OutputTools< Real >::VariableValue & MooseVariableInterface< Real >::valueOld ( )
protectedvirtualinherited

The old value of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 89 of file MooseVariableInterface.C.

109{
110 if (_nodal)
111 return _variable->dofValuesOld();
112 else
113 return _variable->slnOld();
114}
const FieldVariableValue & slnOld() const override
const DofValues & dofValuesOld() const override

◆ valueOlder()

const OutputTools< Real >::VariableValue & MooseVariableInterface< Real >::valueOlder ( )
protectedvirtualinherited

The older value of the variable this object is operating on.

Returns
The reference to be stored off and used later.

Definition at line 96 of file MooseVariableInterface.C.

129{
130 if (_nodal)
131 return _variable->dofValuesOlder();
132 else
133 return _variable->slnOlder();
134}
const FieldVariableValue & slnOlder() const override
const DofValues & dofValuesOlder() const override

Member Data Documentation

◆ _field_variable

MooseVariableField<Real >* MooseVariableInterface< Real >::_field_variable
protectedinherited

Definition at line 230 of file MooseVariableInterface.h.

◆ _fv_variable

MooseVariableFV<Real >* MooseVariableInterface< Real >::_fv_variable
protectedinherited

Definition at line 228 of file MooseVariableInterface.h.

◆ _grad_u

template<typename Base >
Moose::Kokkos::VariableGradient KokkosIntegralVariablePostprocessor< Base >::_grad_u
protected

Holds the solution gradient at the current quadrature points.

Definition at line 29 of file KokkosIntegralVariablePostprocessor.h.

◆ _linear_fv_variable

MooseLinearVariableFV<Real >* MooseVariableInterface< Real >::_linear_fv_variable
protectedinherited

Definition at line 229 of file MooseVariableInterface.h.

◆ _moose_object

const MooseObject& MooseVariableInterface< Real >::_moose_object
privateinherited

Definition at line 236 of file MooseVariableInterface.h.

◆ _mvi_assembly

Assembly* MooseVariableInterface< Real >::_mvi_assembly
protectedinherited

Definition at line 233 of file MooseVariableInterface.h.

◆ _nodal

bool MooseVariableInterface< Real >::_nodal
protectedinherited

Whether or not this object is acting only at nodes.

Definition at line 223 of file MooseVariableInterface.h.

◆ _u

template<typename Base >
Moose::Kokkos::VariableValue KokkosIntegralVariablePostprocessor< Base >::_u
protected

Holds the solution at current quadrature points.

Definition at line 27 of file KokkosIntegralVariablePostprocessor.h.

Referenced by KokkosElementL2Norm::computeQpIntegral().

◆ _use_abs_value

template<typename Base >
const bool KokkosIntegralVariablePostprocessor< Base >::_use_abs_value
protected

Option to use absolute variable value.

Definition at line 31 of file KokkosIntegralVariablePostprocessor.h.

◆ _var

MooseVariableBase* MooseVariableInterface< Real >::_var
protectedinherited

The variable this object is acting on.

Definition at line 226 of file MooseVariableInterface.h.

◆ _variable

MooseVariableFE<Real >* MooseVariableInterface< Real >::_variable
protectedinherited

Definition at line 227 of file MooseVariableInterface.h.


The documentation for this class was generated from the following file: