18 #include "libmesh/transient_system.h" 19 #include "libmesh/enum_norm_type.h" 32 params.
addParam<NonlinearSystemName>(
33 "nl_sys",
"nl0",
"The nonlinear system that we should output information for.");
40 _nl(_problem_ptr->getNonlinearSystemBase(
41 _problem_ptr->nlSysNum(getParam<NonlinearSystemName>(
"nl_sys")))),
50 std::ostringstream oss;
53 unsigned int max_name_size = 0;
54 for (
unsigned int var_num = 0; var_num <
_sys.n_vars(); var_num++)
56 unsigned int var_name_size =
_sys.variable_name(var_num).size();
57 if (var_name_size > max_name_size)
58 max_name_size = var_name_size;
62 oss <<
" |residual|_2 of individual variables:\n";
63 for (
unsigned int var_num = 0; var_num <
_sys.n_vars(); var_num++)
66 oss << std::setw(27 - max_name_size) <<
" " 67 << std::setw(max_name_size + 2)
68 << std::left <<
_sys.variable_name(var_num) +
":" << var_res_id <<
"\n";
A MultiMooseEnum object to hold "execute_on" flags.
NonlinearSystemBase & _nl
Reference to MOOSE's nonlinear system.
System & _sys
Reference to libMesh system.
A class for producing various debug related outputs.
static InputParameters validParams()
static InputParameters validParams()
virtual void output() override
Perform the debugging output.
const ExecFlagType EXEC_NONLINEAR
virtual NumericVector< Number > & RHS()=0
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
Adds the ability to output on every nonlinear and/or linear residual.
registerMooseObject("MooseApp", VariableResidualNormsDebugOutput)
VariableResidualNormsDebugOutput(const InputParameters ¶meters)
Class constructor.