LCOV - code coverage report
Current view: top level - src/kokkos/postprocessors - KokkosIntegralVariablePostprocessor.K (source / functions) Hit Total Coverage
Test: idaholab/moose framework: #32971 (54bef8) with base c6cf66 Lines: 14 15 93.3 %
Date: 2026-05-29 20:35:17 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 "KokkosIntegralVariablePostprocessor.h"
      11             : 
      12             : template <typename Base>
      13             : InputParameters
      14       11344 : KokkosIntegralVariablePostprocessor<Base>::validParams()
      15             : {
      16       11344 :   InputParameters params = Base::validParams();
      17       45376 :   params.addRequiredCoupledVar("variable", "The name of the variable that this object operates on");
      18       22688 :   params.addClassDescription("Computes a volume integral of the specified variable");
      19       23066 :   params.addParam<bool>(
      20       21932 :       "use_absolute_value", false, "Whether to use absolute value of the variable or not");
      21       11344 :   return params;
      22           0 : }
      23             : 
      24             : template <typename Base>
      25         427 : KokkosIntegralVariablePostprocessor<Base>::KokkosIntegralVariablePostprocessor(
      26        1472 :     const InputParameters & parameters)
      27             :   : Base(parameters),
      28             :     MooseVariableInterface<Real>(this,
      29             :                                  false,
      30             :                                  "variable",
      31             :                                  Moose::VarKindType::VAR_ANY,
      32             :                                  Moose::VarFieldType::VAR_FIELD_STANDARD),
      33         243 :     _u(Base::kokkosCoupledValue("variable")),
      34         486 :     _grad_u(Base::kokkosCoupledGradient("variable")),
      35        1215 :     _use_abs_value(Base::template getParam<bool>("use_absolute_value"))
      36             : {
      37         427 :   Base::addMooseVariableDependency(&mooseVariableField());
      38         427 : }
      39             : 
      40             : template class KokkosIntegralVariablePostprocessor<KokkosElementIntegralPostprocessor>;
      41             : template class KokkosIntegralVariablePostprocessor<KokkosSideIntegralPostprocessor>;

Generated by: LCOV version 1.14