https://mooseframework.inl.gov
Loading...
Searching...
No Matches
KokkosRadiativeHeatFluxBCBase.h
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
10#pragma once
11
13
19{
20public:
23
24 template <typename Derived>
25 KOKKOS_FUNCTION Real precomputeQpResidual(const unsigned int qp, AssemblyDatum & datum) const;
26 template <typename Derived>
27 KOKKOS_FUNCTION Real precomputeQpJacobian(const unsigned int j,
28 const unsigned int qp,
29 AssemblyDatum & datum) const;
30
31protected:
34
36 const Real _tinf;
37};
38
39template <typename Derived>
40KOKKOS_FUNCTION Real
42 AssemblyDatum & datum) const
43{
44 auto bc = static_cast<const Derived *>(this);
45
46 Real T = _u(datum, qp);
47 Real T4 = T * T * T * T;
48 Real T4inf = _tinf * _tinf * _tinf * _tinf;
49 return _sigma_stefan_boltzmann * bc->coefficient() * (T4 - T4inf);
50}
51
52template <typename Derived>
53KOKKOS_FUNCTION Real
55 const unsigned int qp,
56 AssemblyDatum & datum) const
57{
58 auto bc = static_cast<const Derived *>(this);
59
60 Real T = _u(datum, qp);
61 Real T3 = T * T * T;
62 return 4 * _sigma_stefan_boltzmann * bc->coefficient() * T3 * _phi(datum, j, qp);
63}
const double T
Boundary condition for radiative heat flux where temperature and the temperature of a body in radiati...
KOKKOS_FUNCTION Real precomputeQpJacobian(const unsigned int j, const unsigned int qp, AssemblyDatum &datum) const
KOKKOS_FUNCTION Real precomputeQpResidual(const unsigned int qp, AssemblyDatum &datum) const
static InputParameters validParams()
const Real _sigma_stefan_boltzmann
Stefan-Boltzmann constant.
KokkosRadiativeHeatFluxBCBase(const InputParameters &parameters)
const Real _tinf
The temperature of the body irhs.
const InputParameters & parameters() const
const VariablePhiValue _phi