LCOV - code coverage report
Current view: top level - src/kernels - ADOneDEnergyWallHeating.C (source / functions) Hit Total Coverage
Test: idaholab/moose thermal_hydraulics: #32971 (54bef8) with base c6cf66 Lines: 16 17 94.1 %
Date: 2026-05-29 20:41:18 Functions: 3 3 100.0 %
Legend: Lines: hit not hit

          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 "ADOneDEnergyWallHeating.h"
      11             : 
      12             : registerMooseObject("ThermalHydraulicsApp", ADOneDEnergyWallHeating);
      13             : 
      14             : InputParameters
      15         511 : ADOneDEnergyWallHeating::validParams()
      16             : {
      17         511 :   InputParameters params = ADKernel::validParams();
      18        1022 :   params.addRequiredCoupledVar("P_hf", "heat flux perimeter");
      19        1022 :   params.addCoupledVar("T_wall", "Wall temperature as a variable");
      20        1022 :   params.addRequiredParam<MaterialPropertyName>("Hw",
      21             :                                                 "Convective heat transfer coefficient, W/m^2-K");
      22        1022 :   params.addRequiredParam<MaterialPropertyName>("T", "Temperature material property");
      23         511 :   params.addClassDescription(
      24             :       "Computes a convective heat flux term for the energy equation for 1-phase flow");
      25             : 
      26         511 :   return params;
      27           0 : }
      28             : 
      29         270 : ADOneDEnergyWallHeating::ADOneDEnergyWallHeating(const InputParameters & parameters)
      30             :   : ADKernel(parameters),
      31         270 :     _temperature(getADMaterialProperty<Real>("T")),
      32         540 :     _Hw(getADMaterialProperty<Real>("Hw")),
      33         270 :     _T_wall(adCoupledValue("T_wall")),
      34         540 :     _P_hf(adCoupledValue("P_hf"))
      35             : {
      36         270 : }
      37             : 
      38             : ADReal
      39       94255 : ADOneDEnergyWallHeating::computeQpResidual()
      40             : {
      41      188510 :   return _Hw[_qp] * _P_hf[_qp] * (_temperature[_qp] - _T_wall[_qp]) * _test[_i][_qp];
      42             : }

Generated by: LCOV version 1.14