https://mooseframework.inl.gov
Loading...
Searching...
No Matches
src
postprocessors
NumResidualEvaluations.C
Go to the documentation of this file.
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
NumResidualEvaluations::validParams
()
20
{
21
InputParameters
params =
GeneralPostprocessor::validParams
();
22
params.
addClassDescription
(
"Returns the total number of residual evaluations performed."
);
23
return
params;
24
}
25
26
NumResidualEvaluations::NumResidualEvaluations
(
const
InputParameters
& parameters)
27
:
GeneralPostprocessor
(parameters)
28
{
29
}
30
31
Real
32
NumResidualEvaluations::getValue
()
const
33
{
34
return
_fe_problem
.
getNonlinearSystemBase
(
_sys
.
number
()).
nResidualEvaluations
();
35
}
FEProblem.h
NonlinearSystem.h
registerMooseObject
registerMooseObject("MooseApp", NumResidualEvaluations)
NumResidualEvaluations.h
SubProblem.h
FEProblemBase::getNonlinearSystemBase
NonlinearSystemBase & getNonlinearSystemBase(const unsigned int sys_num)
Definition
FEProblemBase.h:3764
GeneralPostprocessor
This class is here to combine the Postprocessor interface and the base class Postprocessor object alo...
Definition
GeneralPostprocessor.h:22
GeneralPostprocessor::validParams
static InputParameters validParams()
Definition
GeneralPostprocessor.C:13
InputParameters
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system.
Definition
InputParameters.h:68
InputParameters::addClassDescription
void addClassDescription(const std::string &doc_string)
This method adds a description of the class that will be displayed in the input file syntax dump.
Definition
InputParameters.C:81
NonlinearSystemBase::nResidualEvaluations
unsigned int nResidualEvaluations() const
Return the total number of residual evaluations done so far in this calculation.
Definition
NonlinearSystemBase.h:575
NumResidualEvaluations
Just returns the total number of Residual Evaluations performed.
Definition
NumResidualEvaluations.h:18
NumResidualEvaluations::NumResidualEvaluations
NumResidualEvaluations(const InputParameters ¶meters)
Definition
NumResidualEvaluations.C:26
NumResidualEvaluations::validParams
static InputParameters validParams()
Definition
NumResidualEvaluations.C:19
NumResidualEvaluations::getValue
virtual Real getValue() const override
This will get called to actually grab the final value the postprocessor has calculated.
Definition
NumResidualEvaluations.C:32
SystemBase::number
unsigned int number() const
Gets the number of this system.
Definition
SystemBase.C:1156
UserObjectBase::_fe_problem
FEProblemBase & _fe_problem
Reference to the FEProblemBase for this user object.
Definition
UserObjectBase.h:180
UserObjectBase::_sys
SystemBase & _sys
Reference to the system object for this user object.
Definition
UserObjectBase.h:184
Generated on Fri Aug 21 2026 13:33:59 for https://mooseframework.inl.gov by
1.9.8