LCOV - code coverage report
Current view: top level - src/postprocessors - NumResidualEvaluations.C (source / functions) Hit Total Coverage
Test: idaholab/moose framework: 419b9d Lines: 9 10 90.0 %
Date: 2025-08-08 20:01:16 Functions: 3 3 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             : // MOOSE includes
      11             : #include "NumResidualEvaluations.h"
      12             : #include "FEProblem.h"
      13             : #include "SubProblem.h"
      14             : #include "NonlinearSystem.h"
      15             : 
      16             : registerMooseObject("MooseApp", NumResidualEvaluations);
      17             : 
      18             : InputParameters
      19       14319 : NumResidualEvaluations::validParams()
      20             : {
      21       14319 :   InputParameters params = GeneralPostprocessor::validParams();
      22       14319 :   params.addClassDescription("Returns the total number of residual evaluations performed.");
      23       14319 :   return params;
      24           0 : }
      25             : 
      26          27 : NumResidualEvaluations::NumResidualEvaluations(const InputParameters & parameters)
      27          27 :   : GeneralPostprocessor(parameters)
      28             : {
      29          27 : }
      30             : 
      31             : Real
      32         316 : NumResidualEvaluations::getValue() const
      33             : {
      34         316 :   return _fe_problem.getNonlinearSystemBase(_sys.number()).nResidualEvaluations();
      35             : }

Generated by: LCOV version 1.14