https://mooseframework.inl.gov
Loading...
Searching...
No Matches
LinearFVFunctorRadiativeBC.C
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
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 "MathUtils.h"
12
14
17{
20 "Boundary condition for radiative heat flux in a linear finite volume system. "
21 "The nonlinear radiative flux q = sigma * emissivity * (T^4 - Tinfinity^4) is "
22 "linearized via first-order Taylor expansion around the extrapolated boundary face "
23 "temperature from the previous iteration, yielding a Robin-type condition with "
24 "second-order spatial accuracy. The lagged coefficients are updated on every linear system "
25 "assembly. Fixed point iterations can be used to converge the nonlinear problem every time "
26 "step.");
27 params.addRequiredParam<MooseFunctorName>(
28 "emissivity",
29 "Functor describing the surface emissivity for the radiative boundary condition");
30 params.addRequiredParam<MooseFunctorName>(
31 "Tinfinity", "Functor for the far-field temperature of the body in radiative heat transfer");
32 params.addParam<Real>(
33 "stefan_boltzmann_constant", 5.670374419e-8, "The Stefan-Boltzmann constant");
34 params.addRequiredParam<MooseFunctorName>(
35 "diffusion_coeff",
36 "Functor for the thermal conductivity. Must match the diffusion_coeff used in "
37 "LinearFVDiffusion, as it serves as the alpha coefficient in the Robin formulation.");
38 return params;
39}
40
43 _emissivity(getFunctor<Real>("emissivity")),
44 _tinf(getFunctor<Real>("Tinfinity")),
45 _sigma(getParam<Real>("stefan_boltzmann_constant")),
46 _diffusion_coeff(getFunctor<Real>("diffusion_coeff"))
47{
49}
50
51Real
53{
54 const auto & elem_info = (_current_face_type == FaceInfo::VarFaceNeighbors::ELEM)
57 return _var.getElemValue(*elem_info, state) +
58 _var.gradSln(*elem_info, state) * computeCellToFaceVector();
59}
60
61Real
66
67Real
69{
70 const Real T_b_old = extrapolateFaceTemperature(state);
71 return 4.0 * _sigma * _emissivity(face, state) * Utility::pow<3>(T_b_old);
72}
73
74Real
76{
77 const Real T_b_old = extrapolateFaceTemperature(state);
78 return _sigma * _emissivity(face, state) *
79 (3.0 * Utility::pow<4>(T_b_old) + Utility::pow<4>(_tinf(face, state)));
80}
registerMooseObject("HeatTransferApp", LinearFVFunctorRadiativeBC)
const ElemInfo * elemInfo() const
const ElemInfo * neighborInfo() const
void addRequiredParam(const std::string &name, const std::string &doc_string)
void addParam(const std::string &name, const std::initializer_list< typename T::value_type > &value, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
FaceInfo::VarFaceNeighbors _current_face_type
RealVectorValue computeCellToFaceVector() const
MooseLinearVariableFV< Real > & _var
Boundary condition for radiative heat flux in a linear finite volume system.
virtual Real getGamma(Moose::FaceArg face, Moose::StateArg state) const override
LinearFVFunctorRadiativeBC(const InputParameters &parameters)
virtual Real getAlpha(Moose::FaceArg face, Moose::StateArg state) const override
const Real _sigma
Stefan-Boltzmann constant (sigma)
const Moose::Functor< Real > & _tinf
Far-field temperature functor (T_infinity)
Real extrapolateFaceTemperature(Moose::StateArg state) const
Extrapolates the boundary face temperature from the previous iteration.
const Moose::Functor< Real > & _emissivity
Emissivity functor (epsilon)
virtual Real getBeta(Moose::FaceArg face, Moose::StateArg state) const override
static InputParameters validParams()
const Moose::Functor< Real > & _diffusion_coeff
Thermal conductivity functor; must match the diffusion_coeff in LinearFVDiffusion.
Real getElemValue(const ElemInfo &elem_info, const StateArg &state) const
VectorValue< Real > gradSln(const ElemInfo &elem_info, const StateArg &state) const