Line data Source code
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 : 10 : #include "FunctorGapFluxModelConduction.h" 11 : #include "libmesh/utility.h" 12 : 13 : registerMooseObject("HeatTransferApp", FunctorGapFluxModelConduction); 14 : 15 : InputParameters 16 82 : FunctorGapFluxModelConduction::validParams() 17 : { 18 82 : InputParameters params = GapFluxModelConductionBase::validParams(); 19 82 : params.addClassDescription( 20 : "Gap flux model for varying gap conductance using a functor for temperature."); 21 164 : params.addRequiredParam<MooseFunctorName>("temperature", "The name of the temperature functor"); 22 164 : params.addParam<MooseFunctorName>("gap_conductivity_multiplier", 23 164 : 1, 24 : "Thermal conductivity multiplier. Multiplied by the constant " 25 : "gap_conductivity to form the final conductivity"); 26 82 : return params; 27 0 : } 28 : 29 44 : FunctorGapFluxModelConduction::FunctorGapFluxModelConduction(const InputParameters & parameters) 30 : : GapFluxModelConductionBase(parameters), 31 44 : _T(getFunctor<ADReal>("temperature")), 32 132 : _gap_conductivity_multiplier(getFunctor<ADReal>("gap_conductivity_multiplier")) 33 : { 34 44 : } 35 : 36 : ADReal 37 1782 : FunctorGapFluxModelConduction::computeFlux() const 38 : { 39 1782 : const auto state = determineState(); 40 1782 : return computeConductionFlux(_T(_secondary_point, state), 41 1782 : _T(_primary_point, state), 42 3564 : 0.5 * (_gap_conductivity_multiplier(_secondary_point, state) + 43 3564 : _gap_conductivity_multiplier(_primary_point, state))); 44 : }