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 "CoefTimeDerivative.h" 11 : 12 : registerMooseObject("MooseApp", CoefTimeDerivative); 13 : 14 : InputParameters 15 14999 : CoefTimeDerivative::validParams() 16 : { 17 14999 : InputParameters params = TimeDerivative::validParams(); 18 14999 : params.addParam<Real>("Coefficient", 1, "The coefficient for the time derivative kernel"); 19 14999 : return params; 20 0 : } 21 : 22 382 : CoefTimeDerivative::CoefTimeDerivative(const InputParameters & parameters) 23 382 : : TimeDerivative(parameters), _coef(getParam<Real>("Coefficient")) 24 : { 25 382 : } 26 : 27 : Real 28 190559360 : CoefTimeDerivative::computeQpResidual() 29 : { 30 190559360 : return _coef * TimeDerivative::computeQpResidual(); 31 : } 32 : 33 : Real 34 112501760 : CoefTimeDerivative::computeQpJacobian() 35 : { 36 112501760 : return _coef * TimeDerivative::computeQpJacobian(); 37 : }