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 "ConvectiveHeatFlux1PhaseAux.h" 11 : 12 : registerMooseObject("ThermalHydraulicsApp", ConvectiveHeatFlux1PhaseAux); 13 : 14 : InputParameters 15 39 : ConvectiveHeatFlux1PhaseAux::validParams() 16 : { 17 39 : InputParameters params = AuxKernel::validParams(); 18 39 : params.addClassDescription("Computes convective heat flux for 1-phase flow."); 19 78 : params.addRequiredCoupledVar("T_wall", "Wall temperature"); 20 78 : params.addRequiredParam<MaterialPropertyName>("T", "Material property name of fluid temperature"); 21 78 : params.addRequiredParam<MaterialPropertyName>( 22 : "Hw", "Material property name of wall heat transfer coefficient"); 23 78 : params.addParam<Real>("scaling_factor", 1., "Scaling factor"); 24 39 : return params; 25 0 : } 26 : 27 21 : ConvectiveHeatFlux1PhaseAux::ConvectiveHeatFlux1PhaseAux(const InputParameters & parameters) 28 : : AuxKernel(parameters), 29 21 : _T_wall(coupledValue("T_wall")), 30 21 : _T(getMaterialProperty<Real>("T")), 31 21 : _Hw(getMaterialProperty<Real>("Hw")), 32 63 : _scaling_factor(getParam<Real>("scaling_factor")) 33 : { 34 21 : } 35 : 36 : Real 37 32 : ConvectiveHeatFlux1PhaseAux::computeValue() 38 : { 39 32 : return _Hw[_qp] * (_T_wall[_qp] - _T[_qp]) * _scaling_factor; 40 : }