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 "HeatRateConductionRZ.h" 11 : 12 : registerMooseObject("ThermalHydraulicsApp", HeatRateConductionRZ); 13 : 14 : InputParameters 15 60 : HeatRateConductionRZ::validParams() 16 : { 17 60 : InputParameters params = SideIntegralPostprocessor::validParams(); 18 60 : params += RZSymmetry::validParams(); 19 : 20 120 : params.addRequiredCoupledVar("temperature", "Temperature"); 21 120 : params.addRequiredParam<MaterialPropertyName>("thermal_conductivity", 22 : "Thermal conductivity material property"); 23 120 : params.addRequiredParam<bool>("inward", 24 : "Set to true to get the conduction rate into the domain and to " 25 : "false to the get the conduction rate out of the domain"); 26 : 27 60 : params.addClassDescription("Integrates a conduction heat flux over an RZ boundary."); 28 : 29 60 : return params; 30 0 : } 31 : 32 22 : HeatRateConductionRZ::HeatRateConductionRZ(const InputParameters & parameters) 33 : : SideIntegralPostprocessor(parameters), 34 : RZSymmetry(this, parameters), 35 : 36 22 : _grad_T(coupledGradient("temperature")), 37 44 : _k(getADMaterialProperty<Real>("thermal_conductivity")), 38 66 : _direction_factor(getParam<bool>("inward") ? -1.0 : 1.0) 39 : { 40 22 : } 41 : 42 : Real 43 900 : HeatRateConductionRZ::computeQpIntegral() 44 : { 45 900 : const Real circumference = computeCircumference(_q_point[_qp]); 46 900 : return -_direction_factor * MetaPhysicL::raw_value(_k[_qp]) * _grad_T[_qp] * _normals[_qp] * 47 900 : circumference; 48 : }