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

Couples to some other value and modulates it by the mesh height in a direction. More...

#include <CoupledDirectionalMeshHeightInterpolation.h>

Inheritance diagram for CoupledDirectionalMeshHeightInterpolation:
[legend]

Public Member Functions

 CoupledDirectionalMeshHeightInterpolation (const InputParameters &parameters)
 Factory constructor, takes parameters so that all derived classes can be built using the same constructor. More...
 
virtual ~CoupledDirectionalMeshHeightInterpolation ()
 

Protected Member Functions

virtual Real computeValue ()
 

Protected Attributes

const VariableValue & _coupled_val
 The value of a coupled variable to modulate. More...
 
unsigned int _direction
 The direction to interpolate in. More...
 
Real _direction_min
 
Real _direction_max
 

Detailed Description

Couples to some other value and modulates it by the mesh height in a direction.

What this means is that a constant field will become a linear field that is zero at the end of the domain that is most negative in the given direction and is that given constant value at the extremum of the mesh in the given direction.

This can be useful for specifying linear mesh "stretches". If you are wanting to stretch a mesh by "5"... put 5 into the field that this couples to and this AuxKernel can create a linear "displacement" field that will give that stretch.

Definition at line 30 of file CoupledDirectionalMeshHeightInterpolation.h.

Constructor & Destructor Documentation

CoupledDirectionalMeshHeightInterpolation::CoupledDirectionalMeshHeightInterpolation ( const InputParameters &  parameters)

Factory constructor, takes parameters so that all derived classes can be built using the same constructor.

Definition at line 27 of file CoupledDirectionalMeshHeightInterpolation.C.

29  : AuxKernel(parameters),
30  _coupled_val(coupledValue("coupled_var")),
31  _direction(getParam<MooseEnum>("direction"))
32 {
33  BoundingBox bounding_box = MeshTools::create_bounding_box(_subproblem.mesh());
34 
35  _direction_min = bounding_box.min()(_direction);
36  _direction_max = bounding_box.max()(_direction);
37 }
const VariableValue & _coupled_val
The value of a coupled variable to modulate.
unsigned int _direction
The direction to interpolate in.
virtual CoupledDirectionalMeshHeightInterpolation::~CoupledDirectionalMeshHeightInterpolation ( )
inlinevirtual

Definition at line 39 of file CoupledDirectionalMeshHeightInterpolation.h.

39 {}

Member Function Documentation

Real CoupledDirectionalMeshHeightInterpolation::computeValue ( )
protectedvirtual

Definition at line 40 of file CoupledDirectionalMeshHeightInterpolation.C.

Referenced by ~CoupledDirectionalMeshHeightInterpolation().

41 {
42  const Node & current_pos = *_current_node;
43 
44  Real percentage_along_direction =
46 
47  return percentage_along_direction * _coupled_val[_qp];
48 }
const VariableValue & _coupled_val
The value of a coupled variable to modulate.
unsigned int _direction
The direction to interpolate in.

Member Data Documentation

const VariableValue& CoupledDirectionalMeshHeightInterpolation::_coupled_val
protected

The value of a coupled variable to modulate.

Definition at line 45 of file CoupledDirectionalMeshHeightInterpolation.h.

Referenced by computeValue().

unsigned int CoupledDirectionalMeshHeightInterpolation::_direction
protected

The direction to interpolate in.

Definition at line 48 of file CoupledDirectionalMeshHeightInterpolation.h.

Referenced by computeValue(), and CoupledDirectionalMeshHeightInterpolation().

Real CoupledDirectionalMeshHeightInterpolation::_direction_max
protected
Real CoupledDirectionalMeshHeightInterpolation::_direction_min
protected

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