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 "FVPorosityTimeDerivative.h" 11 : #include "NS.h" 12 : 13 : registerMooseObject("NavierStokesApp", FVPorosityTimeDerivative); 14 : 15 : InputParameters 16 78 : FVPorosityTimeDerivative::validParams() 17 : { 18 78 : InputParameters params = FVTimeKernel::validParams(); 19 78 : params.addClassDescription("A time derivative multiplied by a porosity material property"); 20 78 : params.addParam<MaterialPropertyName>(NS::porosity, NS::porosity, "The porosity"); 21 78 : return params; 22 0 : } 23 : 24 42 : FVPorosityTimeDerivative::FVPorosityTimeDerivative(const InputParameters & parameters) 25 42 : : FVTimeKernel(parameters), _eps(getMaterialProperty<Real>(NS::porosity)) 26 : { 27 42 : } 28 : 29 : ADReal 30 32000 : FVPorosityTimeDerivative::computeQpResidual() 31 : { 32 32000 : return _eps[_qp] * FVTimeKernel::computeQpResidual(); 33 : }