www.mooseframework.org
RadiativeHeatFluxBCBase.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
11 #include "Function.h"
12 #include "MathUtils.h"
13 
15 
16 InputParameters
18 {
19  InputParameters params = IntegratedBC::validParams();
20  params.addParam<Real>("stefan_boltzmann_constant", 5.670367e-8, "The Stefan-Boltzmann constant.");
21  params.addParam<FunctionName>(
22  "Tinfinity", "0", "Temperature of the body in radiative heat transfer.");
23  params.addParam<Real>("boundary_emissivity", 1, "Emissivity of the boundary.");
24  params.addClassDescription("Boundary condition for radiative heat flux where temperature and the"
25  "temperature of a body in radiative heat transfer are specified.");
26  return params;
27 }
28 
29 RadiativeHeatFluxBCBase::RadiativeHeatFluxBCBase(const InputParameters & parameters)
30  : IntegratedBC(parameters),
31  _sigma_stefan_boltzmann(getParam<Real>("stefan_boltzmann_constant")),
32  _tinf(getFunction("Tinfinity")),
33  _eps_boundary(getParam<Real>("boundary_emissivity"))
34 {
35 }
36 
37 Real
39 {
40  Real T4 = MathUtils::pow(_u[_qp], 4);
41  Real T4inf = MathUtils::pow(_tinf.value(_t, _q_point[_qp]), 4);
42  return _test[_i][_qp] * _sigma_stefan_boltzmann * coefficient() * (T4 - T4inf);
43 }
44 
45 Real
47 {
48  Real T3 = MathUtils::pow(_u[_qp], 3);
49  return 4 * _sigma_stefan_boltzmann * _test[_i][_qp] * coefficient() * T3 * _phi[_j][_qp];
50 }
RadiativeHeatFluxBCBase::RadiativeHeatFluxBCBase
RadiativeHeatFluxBCBase(const InputParameters &parameters)
Definition: RadiativeHeatFluxBCBase.C:29
pow
ExpressionBuilder::EBTerm pow(const ExpressionBuilder::EBTerm &left, T exponent)
Definition: ExpressionBuilder.h:673
RadiativeHeatFluxBCBase::_tinf
const Function & _tinf
Function describing the temperature of the body irhs.
Definition: RadiativeHeatFluxBCBase.h:47
RadiativeHeatFluxBCBase
Boundary condition for radiative heat flux where temperature and the temperature of a body in radiati...
Definition: RadiativeHeatFluxBCBase.h:23
RadiativeHeatFluxBCBase::_sigma_stefan_boltzmann
const Real _sigma_stefan_boltzmann
Stefan-Boltzmann constant.
Definition: RadiativeHeatFluxBCBase.h:44
RadiativeHeatFluxBCBase::computeQpResidual
virtual Real computeQpResidual()
Definition: RadiativeHeatFluxBCBase.C:38
RadiativeHeatFluxBCBase::coefficient
virtual Real coefficient() const =0
qdot = sigma * coeff * (T^4 - Tinf^4 ) sigma: _sigma_stefan_boltzmann coeff: coefficient() coefficien...
validParams
InputParameters validParams()
RadiativeHeatFluxBCBase::validParams
static InputParameters validParams()
Definition: RadiativeHeatFluxBCBase.C:17
defineLegacyParams
defineLegacyParams(RadiativeHeatFluxBCBase)
RadiativeHeatFluxBCBase.h
RadiativeHeatFluxBCBase::computeQpJacobian
virtual Real computeQpJacobian()
Definition: RadiativeHeatFluxBCBase.C:46