www.mooseframework.org
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Pressure Class Reference

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

#include <Pressure.h>

Inheritance diagram for Pressure:
[legend]

Public Member Functions

 Pressure (const InputParameters &parameters)
 

Protected Member Functions

virtual Real computeQpResidual ()
 

Protected Attributes

const int _component
 
const Real _factor
 
Function *const _function
 
const PostprocessorValue *const _postprocessor
 
const Real _alpha
 _alpha Parameter for HHT time integration scheme More...
 

Detailed Description

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

Definition at line 24 of file Pressure.h.

Constructor & Destructor Documentation

◆ Pressure()

Pressure::Pressure ( const InputParameters &  parameters)

Definition at line 32 of file Pressure.C.

33  : IntegratedBC(parameters),
34  _component(getParam<unsigned int>("component")),
35  _factor(getParam<Real>("factor")),
36  _function(isParamValid("function") ? &getFunction("function") : NULL),
37  _postprocessor(isParamValid("postprocessor") ? &getPostprocessorValue("postprocessor") : NULL),
38  _alpha(getParam<Real>("alpha"))
39 {
40  if (_component > 2)
41  mooseError("Invalid component given for ", name(), ": ", _component, ".\n");
42 }
const Real _factor
Definition: Pressure.h:34
const std::string name
Definition: Setup.h:22
const int _component
Definition: Pressure.h:32
const Real _alpha
_alpha Parameter for HHT time integration scheme
Definition: Pressure.h:41
Function *const _function
Definition: Pressure.h:36
const PostprocessorValue *const _postprocessor
Definition: Pressure.h:38

Member Function Documentation

◆ computeQpResidual()

Real Pressure::computeQpResidual ( )
protectedvirtual

Definition at line 45 of file Pressure.C.

46 {
47  Real factor = _factor;
48 
49  if (_function)
50  factor *= _function->value(_t + _alpha * _dt, _q_point[_qp]);
51 
52  if (_postprocessor)
53  factor *= *_postprocessor;
54 
55  return factor * (_normals[_qp](_component) * _test[_i][_qp]);
56 }
const Real _factor
Definition: Pressure.h:34
const int _component
Definition: Pressure.h:32
const Real _alpha
_alpha Parameter for HHT time integration scheme
Definition: Pressure.h:41
Function *const _function
Definition: Pressure.h:36
const PostprocessorValue *const _postprocessor
Definition: Pressure.h:38

Member Data Documentation

◆ _alpha

const Real Pressure::_alpha
protected

_alpha Parameter for HHT time integration scheme

Definition at line 41 of file Pressure.h.

Referenced by computeQpResidual().

◆ _component

const int Pressure::_component
protected

Definition at line 32 of file Pressure.h.

Referenced by computeQpResidual(), and Pressure().

◆ _factor

const Real Pressure::_factor
protected

Definition at line 34 of file Pressure.h.

Referenced by computeQpResidual().

◆ _function

Function* const Pressure::_function
protected

Definition at line 36 of file Pressure.h.

Referenced by computeQpResidual().

◆ _postprocessor

const PostprocessorValue* const Pressure::_postprocessor
protected

Definition at line 38 of file Pressure.h.

Referenced by computeQpResidual().


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