LCOV - code coverage report
Current view: top level - src/kernels - SimpleSplitCHWRes.C (source / functions) Hit Total Coverage
Test: idaholab/moose phase_field: #31405 (292dce) with base fef103 Lines: 12 13 92.3 %
Date: 2025-09-04 07:55:36 Functions: 4 4 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 "SimpleSplitCHWRes.h"
      11             : 
      12             : registerMooseObject("PhaseFieldApp", SimpleSplitCHWRes);
      13             : 
      14             : InputParameters
      15          23 : SimpleSplitCHWRes::validParams()
      16             : {
      17          23 :   InputParameters params = Kernel::validParams();
      18          23 :   params.addClassDescription("Gradient energy for split Cahn-Hilliard equation with constant "
      19             :                              "Mobility for a coupled order parameter variable.");
      20          46 :   params.addParam<MaterialPropertyName>(
      21             :       "mob_name", "M", "The mobility used with the kernel, should be a constant value");
      22          23 :   return params;
      23           0 : }
      24             : 
      25          12 : SimpleSplitCHWRes::SimpleSplitCHWRes(const InputParameters & parameters)
      26          24 :   : Kernel(parameters), _M(getMaterialProperty<Real>("mob_name"))
      27             : {
      28          12 : }
      29             : 
      30             : Real
      31      518400 : SimpleSplitCHWRes::computeQpResidual()
      32             : {
      33      518400 :   return _M[_qp] * _grad_u[_qp] * _grad_test[_i][_qp];
      34             : }
      35             : 
      36             : Real
      37     1540800 : SimpleSplitCHWRes::computeQpJacobian()
      38             : {
      39     1540800 :   return _M[_qp] * _grad_phi[_j][_qp] * _grad_test[_i][_qp];
      40             : }

Generated by: LCOV version 1.14