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

Enforce gradient continuity between two different variables across a subdomain boundary. More...

#include <InterfaceDiffusionFluxMatch.h>

Inheritance diagram for InterfaceDiffusionFluxMatch:
[legend]

Public Member Functions

 InterfaceDiffusionFluxMatch (const InputParameters &parameters)
 

Protected Member Functions

virtual Real computeQpResidual (Moose::DGResidualType type) override
 
virtual Real computeQpJacobian (Moose::DGJacobianType type) override
 

Protected Attributes

const Real _D
 diffusion coefficient More...
 
const Real _D_neighbor
 neighbor diffusion coefficient More...
 

Detailed Description

Enforce gradient continuity between two different variables across a subdomain boundary.

Definition at line 21 of file InterfaceDiffusionFluxMatch.h.

Constructor & Destructor Documentation

InterfaceDiffusionFluxMatch::InterfaceDiffusionFluxMatch ( const InputParameters &  parameters)

Definition at line 19 of file InterfaceDiffusionFluxMatch.C.

20  : InterfaceDiffusionBase(parameters)
21 {
22 }
InterfaceDiffusionBase(const InputParameters &parameters)

Member Function Documentation

Real InterfaceDiffusionFluxMatch::computeQpJacobian ( Moose::DGJacobianType  type)
overrideprotectedvirtual

Definition at line 44 of file InterfaceDiffusionFluxMatch.C.

45 {
46  switch (type)
47  {
48  case Moose::ElementElement:
49  return _D * _grad_phi[_j][_qp] * _normals[_qp] * _test[_i][_qp];
50 
51  case Moose::NeighborNeighbor:
52  return -_D_neighbor * _grad_phi_neighbor[_j][_qp] * _normals[_qp] * _test_neighbor[_i][_qp];
53 
54  case Moose::ElementNeighbor:
55  return -_D_neighbor * _grad_phi_neighbor[_j][_qp] * _normals[_qp] * _test[_i][_qp];
56 
57  case Moose::NeighborElement:
58  return _D * _grad_phi[_j][_qp] * _normals[_qp] * _test_neighbor[_i][_qp];
59  }
60  mooseError("Internal error.");
61 }
const Real _D_neighbor
neighbor diffusion coefficient
const Real _D
diffusion coefficient
Real InterfaceDiffusionFluxMatch::computeQpResidual ( Moose::DGResidualType  type)
overrideprotectedvirtual

Definition at line 25 of file InterfaceDiffusionFluxMatch.C.

26 {
27  // equal gradients means difference is zero
28  Real res =
29  _D * _grad_u[_qp] * _normals[_qp] - _D_neighbor * _grad_neighbor_value[_qp] * _normals[_qp];
30 
31  switch (type)
32  {
33  case Moose::Element:
34  return res * _test[_i][_qp];
35 
36  case Moose::Neighbor:
37  return res * _test_neighbor[_i][_qp];
38  }
39 
40  mooseError("Internal error.");
41 }
const Real _D_neighbor
neighbor diffusion coefficient
const Real _D
diffusion coefficient

Member Data Documentation

const Real InterfaceDiffusionBase::_D
protectedinherited
const Real InterfaceDiffusionBase::_D_neighbor
protectedinherited

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