www.mooseframework.org
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ADPressure< compute_stage > Class Template Reference

ADPressure applies a pressure on a given boundary in the direction defined by component. More...

#include <ADPressure.h>

Inheritance diagram for ADPressure< compute_stage >:
[legend]

Public Member Functions

 ADPressure (const InputParameters &parameters)
 

Static Public Member Functions

static InputParameters validParams ()
 

Protected Member Functions

ADReal computeQpResidual () override
 

Protected Attributes

const int _component
 displacement component to apply the kernel to More...
 
const Real _alpha
 _alpha Parameter for HHT time integration scheme More...
 
 usingIntegratedBCMembers
 
const Real _constant
 Pressure value constant factor, function factor, and postprocessor factor. More...
 
const Function *const _function
 
const PostprocessorValue *const _postprocessor
 

Detailed Description

template<ComputeStage compute_stage>
class ADPressure< compute_stage >

ADPressure applies a pressure on a given boundary in the direction defined by component.

Definition at line 17 of file ADPressure.h.

Constructor & Destructor Documentation

◆ ADPressure()

template<ComputeStage compute_stage>
ADPressure< compute_stage >::ADPressure ( const InputParameters &  parameters)

Definition at line 36 of file ADPressure.C.

37  : ADIntegratedBC<compute_stage>(parameters),
38  _component(getParam<unsigned int>("component")),
39  _constant(getParam<Real>("constant")),
40  _function(isParamValid("function") ? &this->getFunction("function") : nullptr),
41  _postprocessor(isParamValid("postprocessor") ? &this->getPostprocessorValue("postprocessor")
42  : nullptr),
43  _alpha(getParam<Real>("alpha"))
44 {
45 }

Member Function Documentation

◆ computeQpResidual()

template<ComputeStage compute_stage>
ADReal ADPressure< compute_stage >::computeQpResidual ( )
overrideprotected

Definition at line 49 of file ADPressure.C.

50 {
51  ADReal factor = _constant;
52 
53  if (_function)
54  factor *= _function->value(_t + _alpha * _dt, _q_point[_qp]);
55 
56  if (_postprocessor)
57  factor *= *_postprocessor;
58 
59  return factor * (_normals[_qp](_component) * _test[_i][_qp]);
60 }

◆ validParams()

template<ComputeStage compute_stage>
InputParameters ADPressure< compute_stage >::validParams ( )
static

Definition at line 20 of file ADPressure.C.

21 {
22  InputParameters params = ADIntegratedBC<compute_stage>::validParams();
23  params.addClassDescription("Applies a pressure on a given boundary in a given direction");
24  params.addRequiredRangeCheckedParam<unsigned int>(
25  "component", "component <= 2", "The component for the pressure");
26  params.addParam<Real>("constant", 1.0, "The magnitude to use in computing the pressure");
27  params.addParam<FunctionName>("function", "The function that describes the pressure");
28  params.addParam<PostprocessorName>("postprocessor",
29  "Postprocessor that will supply the pressure value");
30  params.addParam<Real>("alpha", 0.0, "alpha parameter required for HHT time integration scheme");
31  params.set<bool>("use_displaced_mesh") = true;
32  return params;
33 }

Member Data Documentation

◆ _alpha

template<ComputeStage compute_stage>
const Real ADPressure< compute_stage >::_alpha
protected

_alpha Parameter for HHT time integration scheme

Definition at line 45 of file ADPressure.h.

◆ _component

template<ComputeStage compute_stage>
const int ADPressure< compute_stage >::_component
protected

displacement component to apply the kernel to

Definition at line 36 of file ADPressure.h.

◆ _constant

template<ComputeStage compute_stage>
const Real ADPressure< compute_stage >::_constant
protected

Pressure value constant factor, function factor, and postprocessor factor.

Definition at line 39 of file ADPressure.h.

◆ _function

template<ComputeStage compute_stage>
const Function* const ADPressure< compute_stage >::_function
protected

Definition at line 40 of file ADPressure.h.

◆ _postprocessor

template<ComputeStage compute_stage>
const PostprocessorValue* const ADPressure< compute_stage >::_postprocessor
protected

Definition at line 41 of file ADPressure.h.

◆ usingIntegratedBCMembers

template<ComputeStage compute_stage>
ADPressure< compute_stage >::usingIntegratedBCMembers
protected

Definition at line 47 of file ADPressure.h.


The documentation for this class was generated from the following files:
ADPressure::_function
const Function *const _function
Definition: ADPressure.h:40
ADPressure::_constant
const Real _constant
Pressure value constant factor, function factor, and postprocessor factor.
Definition: ADPressure.h:39
ADPressure::_alpha
const Real _alpha
_alpha Parameter for HHT time integration scheme
Definition: ADPressure.h:45
validParams
InputParameters validParams()
ADPressure::_postprocessor
const PostprocessorValue *const _postprocessor
Definition: ADPressure.h:41
ADPressure::_component
const int _component
displacement component to apply the kernel to
Definition: ADPressure.h:36