LCOV - code coverage report
Current view: top level - src/kernels - TotalEnergyConvectiveFlux.C (source / functions) Hit Total Coverage
Test: idaholab/moose navier_stokes: 9fc4b0 Lines: 0 22 0.0 %
Date: 2025-08-14 10:14:56 Functions: 0 4 0.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 "TotalEnergyConvectiveFlux.h"
      11             : 
      12             : registerMooseObject("NavierStokesApp", TotalEnergyConvectiveFlux);
      13             : 
      14             : InputParameters
      15           0 : TotalEnergyConvectiveFlux::validParams()
      16             : {
      17           0 :   InputParameters params = Kernel::validParams();
      18             : 
      19           0 :   params.addRequiredCoupledVar("rho", "density");
      20           0 :   params.addRequiredCoupledVar("rho_u", "rho*u");
      21           0 :   params.addCoupledVar("rho_v", "rho*v");
      22           0 :   params.addCoupledVar("rho_w", "rho*w");
      23           0 :   params.addRequiredCoupledVar("enthalpy", "Enthalpy");
      24           0 :   params.addClassDescription(
      25             :       "Implements the advection term for the Navier Stokes energy equation.");
      26             : 
      27           0 :   return params;
      28           0 : }
      29             : 
      30           0 : TotalEnergyConvectiveFlux::TotalEnergyConvectiveFlux(const InputParameters & parameters)
      31             :   : Kernel(parameters),
      32           0 :     _rho(coupledValue("rho")),
      33           0 :     _rho_u(coupledValue("rho_u")),
      34           0 :     _rho_v(isCoupled("rho_v") ? coupledValue("rho_v") : _zero),
      35           0 :     _rho_w(isCoupled("rho_w") ? coupledValue("rho_w") : _zero),
      36           0 :     _enthalpy(coupledValue("enthalpy"))
      37             : {
      38           0 : }
      39             : 
      40             : Real
      41           0 : TotalEnergyConvectiveFlux::computeQpResidual()
      42             : {
      43           0 :   RealVectorValue rho_u_vec(_rho_u[_qp], _rho_v[_qp], _rho_w[_qp]);
      44           0 :   return -_enthalpy[_qp] * (rho_u_vec * _grad_test[_i][_qp]);
      45             : }
      46             : 
      47             : Real
      48           0 : TotalEnergyConvectiveFlux::computeQpJacobian()
      49             : {
      50           0 :   return 0.;
      51             : }

Generated by: LCOV version 1.14