www.mooseframework.org
Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | Friends | List of all members
Console Class Reference

An output object for writing to the console (screen) More...

#include <Console.h>

Inheritance diagram for Console:
[legend]

Public Member Functions

 Console (const InputParameters &parameters)
 Class constructor. More...
 
virtual ~Console ()
 Destructor. More...
 
virtual void initialSetup () override
 Initial setup function Prints the system information, this is done here so that the system information is printed prior to any PETSc solve information. More...
 
virtual void timestepSetup () override
 Gets called at the beginning of the timestep before this object is asked to do its job. More...
 
virtual void output (const ExecFlagType &type) override
 Customizes the order of output for the various components as well as adds additional output such as timestep information and nonlinear/linear residual information. More...
 
virtual std::string filename () override
 Creates the output file name Appends the user-supplied 'file_base' input parameter with a '.txt' extension. More...
 
void meshChanged () override
 Performs console related printing when the mesh is changed. More...
 
MultiMooseEnumsystemInfoFlags ()
 Return system information flags. More...
 
void clear ()
 
virtual bool hasOutput ()
 Returns true if any of the other has methods return true. More...
 
bool hasOutput (const ExecFlagType &type)
 Tests that any output exist for the given output type. More...
 
bool hasNodalVariableOutput ()
 Returns true if there exists nodal nonlinear variables for output. More...
 
const std::set< std::string > & getNodalVariableOutput ()
 The list of nodal nonlinear variables names that are set for output. More...
 
bool hasElementalVariableOutput ()
 Returns true if there exists elemental nonlinear variables for output. More...
 
const std::set< std::string > & getElementalVariableOutput ()
 The list of elemental nonlinear variables names that are set for output. More...
 
bool hasScalarOutput ()
 Returns true if there exists scalar variables for output. More...
 
const std::set< std::string > & getScalarOutput ()
 The list of scalar variables names that are set for output. More...
 
bool hasPostprocessorOutput ()
 Returns true if there exists postprocessors for output. More...
 
const std::set< std::string > & getPostprocessorOutput ()
 The list of postprocessor names that are set for output. More...
 
bool hasVectorPostprocessorOutput ()
 Returns true if there exists VectorPostprocessors for output. More...
 
const std::set< std::string > & getVectorPostprocessorOutput ()
 The list of VectorPostprocessor names that are set for output. More...
 
const OutputOnWarehouseadvancedExecuteOn () const
 Get the current advanced 'execute_on' selections for display. More...
 
void setFileNumber (unsigned int num)
 Sets the file number manually. More...
 
unsigned int getFileNumber ()
 Return the current file number for this outputter. More...
 
virtual Real time () override
 Get the output time. More...
 
virtual Real timeOld ()
 Get the old output time. More...
 
virtual Real dt ()
 Get the current time step size. More...
 
virtual Real dtOld ()
 Get old time step size. More...
 
virtual int timeStep ()
 Get the current time step. More...
 
const unsigned int & interval () const
 Get the output interval. More...
 
const MultiMooseEnumexecuteOn () const
 Get the current 'execute_on' selections for display. More...
 
bool isAdvanced ()
 Returns true if this object is an AdvancedOutput object. More...
 
void allowOutput (bool state)
 Method for controlling the allow output state. More...
 
virtual void outputStep (const ExecFlagType &type)
 A single call to this function should output all the necessary data for a single timestep. More...
 
const std::string & type () const
 Get the type of this object. More...
 
const std::string & name () const
 Get the name of the object. More...
 
const InputParametersparameters () const
 Get the parameters of the object. More...
 
template<typename T >
const T & getParam (const std::string &name) const
 Retrieve a parameter for the object. More...
 
template<typename T >
getCheckedPointerParam (const std::string &name, const std::string &error_string="") const
 Verifies that the requested parameter exists and is not NULL and returns it to the caller. More...
 
bool isParamValid (const std::string &name) const
 Test if the supplied parameter is valid. More...
 
MooseAppgetMooseApp () const
 Get the MooseApp this object is associated with. More...
 
virtual bool enabled () const
 Return the enabled status of the object. More...
 
template<typename... Args>
void paramError (const std::string &param, Args... args)
 Emits an error prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message. More...
 
template<typename... Args>
void paramWarning (const std::string &param, Args... args)
 Emits a warning prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message. More...
 
template<typename... Args>
void paramInfo (const std::string &param, Args... args)
 Emits an informational message prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message. More...
 
template<typename... Args>
void mooseError (Args &&... args) const
 
template<typename... Args>
void mooseWarning (Args &&... args) const
 
template<typename... Args>
void mooseDeprecated (Args &&... args) const
 
template<typename... Args>
void mooseInfo (Args &&... args) const
 
virtual void jacobianSetup ()
 Gets called just before the Jacobian is computed and before this object is asked to do its job. More...
 
virtual void residualSetup ()
 Gets called just before the residual is computed and before this object is asked to do its job. More...
 
virtual void subdomainSetup ()
 Gets called when the subdomain changes (i.e. More...
 
const ExecFlagEnumgetExecuteOnEnum () const
 Return the execute on MultiMooseEnum for this object. More...
 
virtual const std::vector< ExecFlagType > & execFlags () const
 (DEPRECATED) Get the execution flag for the object TODO: ExecFlagType More...
 
ExecFlagType execBitFlags () const
 (DEPRECATED) Build and return the execution flags as a bitfield TODO: ExecFlagType More...
 

Static Public Member Functions

static void petscSetupOutput ()
 Output string for setting up PETSC output. More...
 
static std::string outputNorm (const Real &old_norm, const Real &norm)
 A helper function for outputting norms in color. More...
 
static InputParameters enableOutputTypes (const std::string &names=std::string())
 A method for enabling individual output type control. More...
 
static std::string getOutputFileBase (const MooseApp &app, std::string suffix="_out")
 Returns the default output file base. More...
 
static ExecFlagEnum getDefaultExecFlagEnum ()
 Return an ExecFlagEnum object with the available execution flags for Output objects. More...
 
static void addDeprecatedInputParameters (InputParameters &params)
 A static helper for injecting deprecated parameters. More...
 
static ExecFlagEnum getExecuteOptions ()
 (DEPRECATED) Returns the available options for the 'execute_on' input parameters TODO: ExecFlagType More...
 

Public Attributes

const ConsoleStream _console
 An instance of helper class to write streams to the Console objects. More...
 

Protected Member Functions

void init ()
 Adds the printing of system information to the init() method. More...
 
virtual void outputInput () override
 Print the input file at the beginning of the simulation. More...
 
virtual void outputScalarVariables () override
 Prints the aux scalar variables table to the screen. More...
 
virtual void outputPostprocessors () override
 Prints the postprocessor table to the screen. More...
 
virtual void outputVectorPostprocessors () override
 Not implemented. More...
 
virtual void outputSystemInformation () override
 Print system information. More...
 
void writeTimestepInformation ()
 Prints the time step information for the screen output. More...
 
void write (std::string message, bool indent=true)
 Write message to screen and/or file. More...
 
void writeStreamToFile (bool append=true)
 Write the file stream to the file. More...
 
void writeVariableNorms ()
 Print the L2-norms for each variable. More...
 
virtual bool shouldOutput (const ExecFlagType &type)
 Handles logic for determining if a step should be output. More...
 
virtual void outputNodalVariables ()
 Performs output of nodal nonlinear variables The child class must define this method to output the nonlinear variables as desired. More...
 
virtual void outputElementalVariables ()
 Performs output of elemental nonlinear variables The child class must define this method to output the nonlinear variables as desired. More...
 
bool checkFilename ()
 Checks the filename for output Checks the output against the 'output_if_base_contians' list. More...
 
virtual bool onInterval ()
 Returns true if the output interval is satisfied. More...
 
template<typename T >
T & declareRestartableData (std::string data_name)
 Declare a piece of data as "restartable". More...
 
template<typename T >
T & declareRestartableData (std::string data_name, const T &init_value)
 Declare a piece of data as "restartable" and initialize it. More...
 
template<typename T >
T & declareRestartableDataWithContext (std::string data_name, void *context)
 Declare a piece of data as "restartable". More...
 
template<typename T >
T & declareRestartableDataWithContext (std::string data_name, const T &init_value, void *context)
 Declare a piece of data as "restartable" and initialize it. More...
 
template<typename T >
T & declareRecoverableData (std::string data_name)
 Declare a piece of data as "recoverable". More...
 
template<typename T >
T & declareRecoverableData (std::string data_name, const T &init_value)
 Declare a piece of data as "restartable" and initialize it. More...
 
template<typename T >
T & declareRestartableDataWithObjectName (std::string data_name, std::string object_name)
 Declare a piece of data as "restartable". More...
 
template<typename T >
T & declareRestartableDataWithObjectNameWithContext (std::string data_name, std::string object_name, void *context)
 Declare a piece of data as "restartable". More...
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level)
 Call to register a named section for timing. More...
 

Protected Attributes

unsigned int _max_rows
 The max number of table rows. More...
 
MooseEnum _fit_mode
 The FormattedTable fit mode. More...
 
bool _scientific_time
 Toggle for outputting time in time and dt in scientific notation. More...
 
bool _write_file
 Flag for controlling outputting console information to a file. More...
 
bool _write_screen
 Flag for controlling outputting console information to screen. More...
 
bool _verbose
 Flag for writing detailed time step information. More...
 
std::stringstream _file_output_stream
 Stream for storing information to be written to a file. More...
 
bool _perf_log
 State for all performance logging. More...
 
unsigned int _perf_log_interval
 The interval at which the performance log is printed. More...
 
bool _solve_log
 State for solve performance log. More...
 
bool _libmesh_log
 Control the display libMesh performance log. More...
 
bool _perf_header
 State for the performance log header information. More...
 
bool _all_variable_norms
 Flag for writing all variable norms. More...
 
bool _outlier_variable_norms
 Flag for writing outlier variable norms. More...
 
std::vector< Real > _outlier_multiplier
 Multipliers for coloring variable residual norms (default [2, 0.8]) More...
 
unsigned int _precision
 Number of significant digits. More...
 
bool _tables_restartable
 Flag for allowing all table data to become restartable. More...
 
FormattedTable_postprocessor_table
 Table containing postprocessor data. More...
 
std::map< std::string, FormattedTable_vector_postprocessor_tables
 Formatted tables for outputting vector postprocessor data. One per VectorPostprocessor. More...
 
std::map< std::string, FormattedTable > & _vector_postprocessor_time_tables
 Table for vector postprocessor time data. More...
 
FormattedTable_scalar_table
 Table containing scalar aux variables. More...
 
FormattedTable_all_data_table
 Table containing postprocessor values and scalar aux variables. More...
 
const Real _new_row_tol
 Tolerance used when deciding whether or not to add a new row to the table. More...
 
const bool _time_data
 Enable/disable VecptorPostprocessor time data file. More...
 
const bool _time_column
 Enable/disable output of time column for Postprocessors. More...
 
bool _elemental_as_nodal
 Flags to control nodal output. More...
 
bool _scalar_as_nodal
 
std::string _file_base
 The base filename from the input paramaters. More...
 
unsigned int & _file_num
 A file number counter, initialized to 0 (this must be controlled by the child class, see Exodus) More...
 
unsigned int _padding
 Number of digits to pad the extensions. More...
 
std::vector< std::string > _output_if_base_contains
 Storage for 'output_if_base_contains'. More...
 
Real _norm
 Current norm returned from PETSc. More...
 
PetscInt _nonlinear_iter
 Current non-linear iteration returned from PETSc. More...
 
PetscInt _linear_iter
 Current linear iteration returned from PETSc. More...
 
FEProblemBase_problem_ptr
 Pointer the the FEProblemBase object for output object (use this) More...
 
bool _transient
 Transient flag (true = transient) More...
 
bool _use_displaced
 Flag for using displaced mesh. More...
 
EquationSystems * _es_ptr
 Reference the the libMesh::EquationSystems object that contains the data. More...
 
MooseMesh_mesh_ptr
 A convenience pointer to the current mesh (reference or displaced depending on "use_displaced") More...
 
bool _sequence
 Flag for forcing call to outputSetup() with every call to output() (restartable) More...
 
ExecFlagEnum _execute_on
 The common Execution types; this is used as the default execution type for everything except system information and input. More...
 
Real & _time
 The current time for output purposes. More...
 
Real & _time_old
 The old time. More...
 
int & _t_step
 The current time step. More...
 
Real & _dt
 Time step delta. More...
 
Real & _dt_old
 Old time step delta. More...
 
unsigned int _num
 The number of outputs written. More...
 
const unsigned int _interval
 The output time step interval. More...
 
std::set< Real > _sync_times
 Sync times for this outputter. More...
 
Real _start_time
 Start outputting time. More...
 
Real _end_time
 End outputting time. More...
 
int _start_step
 Start outputting at this time step. More...
 
int _end_step
 End outputting at this time step. More...
 
Real _t_tol
 Time checking tolerance. More...
 
bool _sync_only
 Flag for only executing at sync times. More...
 
bool _initialized
 True if init() has been called. More...
 
bool _allow_output
 Flag for disabling output. More...
 
bool _is_advanced
 Flag for advanced output testing. More...
 
OutputOnWarehouse _advanced_execute_on
 Storage for the individual component execute flags. More...
 
PerfID _output_step_timer
 Timers. More...
 
const InputParameters_pars
 Parameters of this object, references the InputParameters stored in the InputParametersWarehouse. More...
 
MooseApp_app
 The MooseApp this object is associated with. More...
 
const std::string & _type
 The type of this object (the Class name) More...
 
const std::string & _name
 The name of this object, reference to value stored in InputParameters. More...
 
const bool & _enabled
 Reference to the "enable" InputParaemters, used by Controls for toggling on/off MooseObjects. More...
 
FEProblemBase_mci_feproblem
 Reference to FEProblemBase instance. More...
 
const ExecFlagEnum_execute_enum
 Execute settings for this oejct. More...
 
const std::vector< ExecFlagType_exec_flags
 (DEPRECATED) execution flag (when is the object executed/evaluated) TODO: ExecFlagType More...
 
const ExecFlagType_current_execute_flag
 Reference to FEProblemBase. More...
 
const InputParameters_pg_params
 Params. More...
 
PerfGraph_perf_graph
 The performance graph to add to. More...
 
std::string _prefix
 A prefix to use for all sections. More...
 

Private Member Functions

void mooseConsole (const std::string &message)
 Add a message to the output streams. More...
 

Private Attributes

const std::ostringstream & _console_buffer
 Reference to cached messages from calls to _console. More...
 
Real _old_linear_norm
 Storage for the old linear residual (needed for color output and only when used when printing to the screen) More...
 
Real _old_nonlinear_norm
 Storage for the old non linear residual (needed for color output and only when used when printing to the screen) More...
 
bool _print_mesh_changed_info
 Flag for printing mesh information when the mesh changes. More...
 
MultiMooseEnum _system_info_flags
 Flags for controlling the what simulations information is shown. More...
 
bool _allow_changing_sysinfo_flag
 A boolean for protecting _system_info_flags from being changed undesirably. More...
 

Friends

class OutputWarehouse
 

Detailed Description

An output object for writing to the console (screen)

Definition at line 25 of file Console.h.

Constructor & Destructor Documentation

◆ Console()

Console::Console ( const InputParameters parameters)

Class constructor.

Definition at line 159 of file Console.C.

161  _max_rows(getParam<unsigned int>("max_rows")),
162  _fit_mode(getParam<MooseEnum>("fit_mode")),
163  _scientific_time(getParam<bool>("scientific_time")),
164  _write_file(getParam<bool>("output_file")),
165  _write_screen(getParam<bool>("output_screen")),
166  _verbose(getParam<bool>("verbose")),
167  _perf_log(getParam<bool>("perf_log")),
168  _perf_log_interval(getParam<unsigned int>("perf_log_interval")),
169  _solve_log(isParamValid("solve_log") ? getParam<bool>("solve_log") : _perf_log),
170  _libmesh_log(getParam<bool>("libmesh_log")),
171  _perf_header(isParamValid("perf_header") ? getParam<bool>("perf_header") : _perf_log),
172  _all_variable_norms(getParam<bool>("all_variable_norms")),
173  _outlier_variable_norms(getParam<bool>("outlier_variable_norms")),
174  _outlier_multiplier(getParam<std::vector<Real>>("outlier_multiplier")),
175  _precision(isParamValid("time_precision") ? getParam<unsigned int>("time_precision") : 0),
177  _old_linear_norm(std::numeric_limits<Real>::max()),
178  _old_nonlinear_norm(std::numeric_limits<Real>::max()),
179  _print_mesh_changed_info(getParam<bool>("print_mesh_changed_info")),
180  _system_info_flags(getParam<MultiMooseEnum>("system_info")),
182 {
183  // Apply the special common console flags (print_...)
185  const auto & actions = awh.getActionListByName("common_output");
186  mooseAssert(actions.size() == 1, "Should be only one common_output Action");
187  Action * common_action = *actions.begin();
188 
189  // Honor the 'print_linear_residuals' option, only if 'execute_on' has not been set by the user
190  if (!parameters.isParamSetByUser("execute_on"))
191  {
192  if (common_action->getParam<bool>("print_linear_residuals"))
193  _execute_on.push_back("linear");
194  else
195  _execute_on.erase("linear");
196  }
197 
198  if (!_pars.isParamSetByUser("perf_log") && common_action->getParam<bool>("print_perf_log"))
199  {
200  _perf_log = true;
201  _solve_log = true;
202  }
203 
204  // Append the common 'execute_on' to the setting for this object
205  // This is unique to the Console object, all other objects inherit from the common options
206  const ExecFlagEnum & common_execute_on = common_action->getParam<ExecFlagEnum>("execute_on");
207  for (auto & mme : common_execute_on)
208  _execute_on.push_back(mme);
209 
210  // If --show-outputs is used, enable it
211  if (_app.getParam<bool>("show_outputs"))
212  _system_info_flags.push_back("output");
213 }
bool _libmesh_log
Control the display libMesh performance log.
Definition: Console.h:186
A MultiMooseEnum object to hold "execute_on" flags.
Definition: ExecFlagEnum.h:25
ExecFlagEnum _execute_on
The common Execution types; this is used as the default execution type for everything except system i...
Definition: Output.h:186
unsigned int _precision
Number of significant digits.
Definition: Console.h:201
MooseEnum _fit_mode
The FormattedTable fit mode.
Definition: Console.h:159
bool _all_variable_norms
Flag for writing all variable norms.
Definition: Console.h:192
bool _verbose
Flag for writing detailed time step information.
Definition: Console.h:171
bool _write_screen
Flag for controlling outputting console information to screen.
Definition: Console.h:168
const std::ostringstream & _console_buffer
Reference to cached messages from calls to _console.
Definition: Console.h:217
Storage for action instances.
const std::list< Action * > & getActionListByName(const std::string &task) const
Retrieve a constant list of Action pointers associated with the passed in task.
bool _allow_changing_sysinfo_flag
A boolean for protecting _system_info_flags from being changed undesirably.
Definition: Console.h:235
Base class for actions.
Definition: Action.h:36
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
Definition: MooseObject.h:188
bool _outlier_variable_norms
Flag for writing outlier variable norms.
Definition: Console.h:195
bool _perf_header
State for the performance log header information.
Definition: Console.h:189
MultiMooseEnum _system_info_flags
Flags for controlling the what simulations information is shown.
Definition: Console.h:229
TableOutput(const InputParameters &parameters)
Class constructor.
Definition: TableOutput.C:60
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseObject.h:62
bool _solve_log
State for solve performance log.
Definition: Console.h:183
unsigned int _perf_log_interval
The interval at which the performance log is printed.
Definition: Console.h:180
ActionWarehouse & actionWarehouse()
Definition: MooseApp.h:140
std::ostringstream & consoleBuffer()
The buffered messages stream for Console objects.
void erase(const std::string &names)
Un-assign a value.
unsigned int _max_rows
The max number of table rows.
Definition: Console.h:156
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171
Real _old_nonlinear_norm
Storage for the old non linear residual (needed for color output and only when used when printing to ...
Definition: Console.h:223
bool _write_file
Flag for controlling outputting console information to a file.
Definition: Console.h:165
bool _perf_log
State for all performance logging.
Definition: Console.h:177
bool isParamSetByUser(const std::string &name) const
Method returns true if the parameter was by the user.
std::vector< Real > _outlier_multiplier
Multipliers for coloring variable residual norms (default [2, 0.8])
Definition: Console.h:198
const T & getParam(const std::string &name)
Retrieve a parameter for the object.
Definition: MooseApp.h:916
void push_back(const std::string &names)
Insert operators Operator to insert (push_back) values into the enum.
Real _old_linear_norm
Storage for the old linear residual (needed for color output and only when used when printing to the ...
Definition: Console.h:220
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174
bool _scientific_time
Toggle for outputting time in time and dt in scientific notation.
Definition: Console.h:162
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
Definition: MooseObject.h:86
bool _print_mesh_changed_info
Flag for printing mesh information when the mesh changes.
Definition: Console.h:226
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:1049

◆ ~Console()

Console::~Console ( )
virtual

Destructor.

Definition at line 215 of file Console.C.

216 {
217  // Write the libMesh log
218  if (_libmesh_log)
219  write(libMesh::perflog.get_perf_info(), false);
220 
221  // Write the file output stream
223 
224  // Disable logging so that the destructor in libMesh doesn't print
225  Moose::perf_log.disable_logging();
226  libMesh::perflog.disable_logging();
227 }
bool _libmesh_log
Control the display libMesh performance log.
Definition: Console.h:186
void write(std::string message, bool indent=true)
Write message to screen and/or file.
Definition: Console.C:625
PerfLog perf_log
Perflog to be used by applications.
void writeStreamToFile(bool append=true)
Write the file stream to the file.
Definition: Console.C:357

Member Function Documentation

◆ addDeprecatedInputParameters()

static void Output::addDeprecatedInputParameters ( InputParameters params)
staticinherited

A static helper for injecting deprecated parameters.

◆ advancedExecuteOn()

const OutputOnWarehouse & AdvancedOutput::advancedExecuteOn ( ) const
virtualinherited

Get the current advanced 'execute_on' selections for display.

Reimplemented from Output.

Definition at line 763 of file AdvancedOutput.C.

764 {
765  return _advanced_execute_on;
766 }
OutputOnWarehouse _advanced_execute_on
Storage for the individual component execute flags.
Definition: Output.h:243

◆ allowOutput()

void Output::allowOutput ( bool  state)
inlineinherited

Method for controlling the allow output state.

Parameters
stateThe state to set the allow flag to

Definition at line 122 of file Output.h.

122 { _allow_output = state; }
bool _allow_output
Flag for disabling output.
Definition: Output.h:234

◆ checkFilename()

bool FileOutput::checkFilename ( )
protectedinherited

Checks the filename for output Checks the output against the 'output_if_base_contians' list.

Returns
Returns true if the filename is valid for output

Definition at line 147 of file FileOutput.C.

Referenced by FileOutput::shouldOutput(), and AdvancedOutput::shouldOutput().

148 {
149  // Return true if 'output_if_base_contains' is not utilized
150  if (_output_if_base_contains.empty())
151  return true;
152 
153  // Assumed output is false
154  bool output = false;
155 
156  // Loop through each string in the list
157  for (const auto & search_string : _output_if_base_contains)
158  {
159  // Search for the string in the file base, if found set the output to true and break the loop
160  if (_file_base.find(search_string) != std::string::npos)
161  {
162  output = true;
163  break;
164  }
165  }
166 
167  // Return the value
168  return output;
169 }
virtual void output(const ExecFlagType &type)=0
Overload this function with the desired output activities.
std::string _file_base
The base filename from the input paramaters.
Definition: FileOutput.h:82
std::vector< std::string > _output_if_base_contains
Storage for &#39;output_if_base_contains&#39;.
Definition: FileOutput.h:91

◆ clear()

void TableOutput::clear ( )
inherited

Definition at line 221 of file TableOutput.C.

Referenced by OutputWarehouse::reset().

222 {
224  for (auto & pair : _vector_postprocessor_tables)
225  pair.second.clear();
226  for (auto & pair : _vector_postprocessor_time_tables)
227  pair.second.clear();
230 }
FormattedTable & _postprocessor_table
Table containing postprocessor data.
Definition: TableOutput.h:67
FormattedTable & _scalar_table
Table containing scalar aux variables.
Definition: TableOutput.h:76
FormattedTable & _all_data_table
Table containing postprocessor values and scalar aux variables.
Definition: TableOutput.h:79
std::map< std::string, FormattedTable > _vector_postprocessor_tables
Formatted tables for outputting vector postprocessor data. One per VectorPostprocessor.
Definition: TableOutput.h:70
std::map< std::string, FormattedTable > & _vector_postprocessor_time_tables
Table for vector postprocessor time data.
Definition: TableOutput.h:73

◆ declareRecoverableData() [1/2]

template<typename T >
T & Restartable::declareRecoverableData ( std::string  data_name)
protectedinherited

Declare a piece of data as "recoverable".

This means that in the event of a recovery this piece of data will be restored back to its previous value.

Note - this data will NOT be restored on Restart!

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)

Definition at line 269 of file Restartable.h.

270 {
271  std::string full_name = _restartable_system_name + "/" + _restartable_name + "/" + data_name;
272 
273  registerRecoverableDataOnApp(full_name);
274 
275  return declareRestartableDataWithContext<T>(data_name, nullptr);
276 }
std::string _restartable_system_name
The system name this object is in.
Definition: Restartable.h:194
std::string _restartable_name
The name of the object.
Definition: Restartable.h:191
void registerRecoverableDataOnApp(std::string name)
Helper function for actually registering the restartable data.
Definition: Restartable.C:54

◆ declareRecoverableData() [2/2]

template<typename T >
T & Restartable::declareRecoverableData ( std::string  data_name,
const T &  init_value 
)
protectedinherited

Declare a piece of data as "restartable" and initialize it.

This means that in the event of a restart this piece of data will be restored back to its previous value.

Note - this data will NOT be restored on Restart!

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)
init_valueThe initial value of the data

Definition at line 280 of file Restartable.h.

281 {
282  std::string full_name = _restartable_system_name + "/" + _restartable_name + "/" + data_name;
283 
284  registerRecoverableDataOnApp(full_name);
285 
286  return declareRestartableDataWithContext<T>(data_name, init_value, nullptr);
287 }
std::string _restartable_system_name
The system name this object is in.
Definition: Restartable.h:194
std::string _restartable_name
The name of the object.
Definition: Restartable.h:191
void registerRecoverableDataOnApp(std::string name)
Helper function for actually registering the restartable data.
Definition: Restartable.C:54

◆ declareRestartableData() [1/2]

template<typename T >
T & Restartable::declareRestartableData ( std::string  data_name)
protectedinherited

Declare a piece of data as "restartable".

This means that in the event of a restart this piece of data will be restored back to its previous value.

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)

Definition at line 202 of file Restartable.h.

203 {
204  return declareRestartableDataWithContext<T>(data_name, nullptr);
205 }

◆ declareRestartableData() [2/2]

template<typename T >
T & Restartable::declareRestartableData ( std::string  data_name,
const T &  init_value 
)
protectedinherited

Declare a piece of data as "restartable" and initialize it.

This means that in the event of a restart this piece of data will be restored back to its previous value.

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)
init_valueThe initial value of the data

Definition at line 209 of file Restartable.h.

210 {
211  return declareRestartableDataWithContext<T>(data_name, init_value, nullptr);
212 }

◆ declareRestartableDataWithContext() [1/2]

template<typename T >
T & Restartable::declareRestartableDataWithContext ( std::string  data_name,
void *  context 
)
protectedinherited

Declare a piece of data as "restartable".

This means that in the event of a restart this piece of data will be restored back to its previous value.

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)
contextContext pointer that will be passed to the load and store functions

Definition at line 216 of file Restartable.h.

217 {
218  std::string full_name = _restartable_system_name + "/" + _restartable_name + "/" + data_name;
219  auto data_ptr = libmesh_make_unique<RestartableData<T>>(full_name, context);
220  T & restartable_data_ref = data_ptr->get();
221 
222  registerRestartableDataOnApp(full_name, std::move(data_ptr), _restartable_tid);
223 
224  return restartable_data_ref;
225 }
std::string _restartable_system_name
The system name this object is in.
Definition: Restartable.h:194
std::string _restartable_name
The name of the object.
Definition: Restartable.h:191
THREAD_ID _restartable_tid
The thread ID for this object.
Definition: Restartable.h:197
void registerRestartableDataOnApp(std::string name, std::unique_ptr< RestartableDataValue > data, THREAD_ID tid)
Helper function for actually registering the restartable data.
Definition: Restartable.C:46

◆ declareRestartableDataWithContext() [2/2]

template<typename T >
T & Restartable::declareRestartableDataWithContext ( std::string  data_name,
const T &  init_value,
void *  context 
)
protectedinherited

Declare a piece of data as "restartable" and initialize it.

This means that in the event of a restart this piece of data will be restored back to its previous value.

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)
init_valueThe initial value of the data
contextContext pointer that will be passed to the load and store functions

Definition at line 229 of file Restartable.h.

232 {
233  std::string full_name = _restartable_system_name + "/" + _restartable_name + "/" + data_name;
234  auto data_ptr = libmesh_make_unique<RestartableData<T>>(full_name, context);
235  data_ptr->set() = init_value;
236 
237  T & restartable_data_ref = data_ptr->get();
238  registerRestartableDataOnApp(full_name, std::move(data_ptr), _restartable_tid);
239 
240  return restartable_data_ref;
241 }
std::string _restartable_system_name
The system name this object is in.
Definition: Restartable.h:194
std::string _restartable_name
The name of the object.
Definition: Restartable.h:191
THREAD_ID _restartable_tid
The thread ID for this object.
Definition: Restartable.h:197
void registerRestartableDataOnApp(std::string name, std::unique_ptr< RestartableDataValue > data, THREAD_ID tid)
Helper function for actually registering the restartable data.
Definition: Restartable.C:46

◆ declareRestartableDataWithObjectName()

template<typename T >
T & Restartable::declareRestartableDataWithObjectName ( std::string  data_name,
std::string  object_name 
)
protectedinherited

Declare a piece of data as "restartable".

This means that in the event of a restart this piece of data will be restored back to its previous value.

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)
object_nameA supplied name for the object that is declaring this data.

Definition at line 245 of file Restartable.h.

246 {
247  return declareRestartableDataWithObjectNameWithContext<T>(data_name, object_name, nullptr);
248 }

◆ declareRestartableDataWithObjectNameWithContext()

template<typename T >
T & Restartable::declareRestartableDataWithObjectNameWithContext ( std::string  data_name,
std::string  object_name,
void *  context 
)
protectedinherited

Declare a piece of data as "restartable".

This means that in the event of a restart this piece of data will be restored back to its previous value.

NOTE: This returns a reference! Make sure you store it in a reference!

Parameters
data_nameThe name of the data (usually just use the same name as the member variable)
object_nameA supplied name for the object that is declaring this data.
contextContext pointer that will be passed to the load and store functions

Definition at line 252 of file Restartable.h.

255 {
256  std::string old_name = _restartable_name;
257 
258  _restartable_name = object_name;
259 
260  T & value = declareRestartableDataWithContext<T>(data_name, context);
261 
262  _restartable_name = old_name;
263 
264  return value;
265 }
std::string _restartable_name
The name of the object.
Definition: Restartable.h:191

◆ dt()

Real Output::dt ( )
virtualinherited

Get the current time step size.

Definition at line 241 of file Output.C.

Referenced by writeTimestepInformation().

242 {
243  if (_transient)
244  return _dt;
245  else
246  return 1;
247 }
bool _transient
Transient flag (true = transient)
Definition: Output.h:171
Real & _dt
Time step delta.
Definition: Output.h:198

◆ dtOld()

Real Output::dtOld ( )
virtualinherited

Get old time step size.

Definition at line 250 of file Output.C.

251 {
252  if (_transient)
253  return _dt_old;
254  else
255  return 1;
256 }
Real & _dt_old
Old time step delta.
Definition: Output.h:201
bool _transient
Transient flag (true = transient)
Definition: Output.h:171

◆ enabled()

virtual bool MooseObject::enabled ( ) const
inlinevirtualinherited

Return the enabled status of the object.

Reimplemented in EigenKernel.

Definition at line 96 of file MooseObject.h.

Referenced by EigenKernel::enabled().

96 { return _enabled; }
const bool & _enabled
Reference to the "enable" InputParaemters, used by Controls for toggling on/off MooseObjects.
Definition: MooseObject.h:183

◆ enableOutputTypes()

InputParameters AdvancedOutput::enableOutputTypes ( const std::string &  names = std::string())
staticinherited

A method for enabling individual output type control.

Parameters
names(optional) Space separated of output type names that are supported by this Output object, if this is omitted all outputs types will be supported. The list of available output types is given below.

Output objects vary widely in what type of outputs they support (e.g., elemental variables, or postprocessor data). This method provides the user a means for controlling the types of outputs that are supported for the object being created. This is a static method that MUST be used to append parameters inside the objects validParams function.

List of Output Types and Method Names The output system is designed around overloading virtual method calls to output the various output types, the following list gives the name of the output type and the associated virtual method that should be overloaded to perform the output in the object being created.

Type virtual Method Name


nodal outputNodalVariables() elemental outputElementalVariables() scalar outputScalarVariables() postprocessor outputPostprocessors() vector_postprocessor outputVectorPostprocessors() input outputInput() system_information outputSystemInformation()

See also
CSV Exodus

Definition at line 101 of file AdvancedOutput.C.

Referenced by validParams< Console >(), validParams< Exodus >(), validParams< Nemesis >(), and validParams< TableOutput >().

102 {
103  // The parameters object that will be returned
105 
106  // Get the MultiEnum of output types
107  MultiMooseEnum output_types = getOutputTypes();
108 
109  // Update the enum of output types to append
110  if (names.empty())
111  output_types = output_types.getRawNames();
112  else
113  output_types = names;
114 
115  // Add the parameters and return them
116  addValidParams(params, output_types);
117  return params;
118 }
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
std::string getRawNames() const
Method for returning the raw name strings for this instance.
InputParameters emptyInputParameters()
static void addValidParams(InputParameters &params, const MultiMooseEnum &types)
Method for defining the available parameters based on the types of outputs.
static MultiMooseEnum getOutputTypes()
Get the supported types of output (e.g., postprocessors, etc.)
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...

◆ execBitFlags()

ExecFlagType SetupInterface::execBitFlags ( ) const
inherited

(DEPRECATED) Build and return the execution flags as a bitfield TODO: ExecFlagType

Definition at line 85 of file SetupInterface.C.

86 {
87  // TODO: ExecFlagType
88  mooseDeprecated("The execBitFlags method is being removed because MOOSE was updated to use a "
89  "ExecFlagEnum for execute flags. This method maintains the behavior of the "
90  "original method but the use of this method should be removed from your "
91  "application. The ExecFlagEnum should be inspected directly via the "
92  "getExecuteOnEnum() method.");
93 
94  unsigned int exec_bit_field = EXEC_NONE;
95  for (const auto & flag : _exec_flags)
96  exec_bit_field |= flag.id();
97  return ExecFlagType("deprecated", exec_bit_field);
98 }
MooseEnumItem ExecFlagType
Definition: Moose.h:85
const ExecFlagType EXEC_NONE
void mooseDeprecated(Args &&... args)
Emit a deprecated code/feature message with the given stringified, concatenated args.
Definition: MooseError.h:237
const int & id() const
Return the numeric, name, or raw name.
Definition: MooseEnumItem.h:37
const std::vector< ExecFlagType > _exec_flags
(DEPRECATED) execution flag (when is the object executed/evaluated) TODO: ExecFlagType ...

◆ execFlags()

const std::vector< ExecFlagType > & SetupInterface::execFlags ( ) const
virtualinherited

(DEPRECATED) Get the execution flag for the object TODO: ExecFlagType

Reimplemented in MultiAppTransfer.

Definition at line 73 of file SetupInterface.C.

74 {
75  // TODO: ExecFlagType
76  mooseDeprecated("The execFlags() method is being removed because MOOSE has been updated to use a "
77  "ExecFlagEnum for execute flags. The current flags should be retrieved from "
78  "the \"exeucte_on\" parameters of your object or by using the \"_execute_enum\" "
79  "reference to the parameter or the getExecuteOnEnum() method.");
80 
81  return _exec_flags;
82 }
void mooseDeprecated(Args &&... args)
Emit a deprecated code/feature message with the given stringified, concatenated args.
Definition: MooseError.h:237
const std::vector< ExecFlagType > _exec_flags
(DEPRECATED) execution flag (when is the object executed/evaluated) TODO: ExecFlagType ...

◆ executeOn()

const MultiMooseEnum & Output::executeOn ( ) const
inherited

Get the current 'execute_on' selections for display.

Definition at line 265 of file Output.C.

266 {
267  return _execute_on;
268 }
ExecFlagEnum _execute_on
The common Execution types; this is used as the default execution type for everything except system i...
Definition: Output.h:186

◆ filename()

std::string Console::filename ( )
overridevirtual

Creates the output file name Appends the user-supplied 'file_base' input parameter with a '.txt' extension.

Returns
A string containing the output filename

Reimplemented from FileOutput.

Definition at line 281 of file Console.C.

Referenced by writeStreamToFile().

282 {
283  return _file_base + ".txt";
284 }
std::string _file_base
The base filename from the input paramaters.
Definition: FileOutput.h:82

◆ getCheckedPointerParam()

template<typename T >
T MooseObject::getCheckedPointerParam ( const std::string &  name,
const std::string &  error_string = "" 
) const
inlineinherited

Verifies that the requested parameter exists and is not NULL and returns it to the caller.

The template parameter must be a pointer or an error will be thrown.

Definition at line 77 of file MooseObject.h.

78  {
79  return parameters().getCheckedPointerParam<T>(name, error_string);
80  }
T getCheckedPointerParam(const std::string &name, const std::string &error_string="") const
Verifies that the requested parameter exists and is not NULL and returns it to the caller...
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseObject.h:62
const std::string & name() const
Get the name of the object.
Definition: MooseObject.h:56

◆ getDefaultExecFlagEnum()

ExecFlagEnum Output::getDefaultExecFlagEnum ( )
staticinherited

Return an ExecFlagEnum object with the available execution flags for Output objects.

Definition at line 77 of file Output.C.

Referenced by validParams< CommonOutputAction >(), and validParams< Output >().

78 {
80  exec_enum.addAvailableFlags(EXEC_FAILED);
81  return exec_enum;
82 }
const ExecFlagType EXEC_FAILED
A MultiMooseEnum object to hold "execute_on" flags.
Definition: ExecFlagEnum.h:25
void addAvailableFlags(const ExecFlagType &flag, Args... flags)
Add additional execute_on flags to the list of possible flags.
Definition: ExecFlagEnum.h:85
ExecFlagEnum getDefaultExecFlagEnum()
Return the default ExecFlagEnum for MOOSE.
Definition: MooseUtils.C:715

◆ getElementalVariableOutput()

const std::set< std::string > & AdvancedOutput::getElementalVariableOutput ( )
inherited

The list of elemental nonlinear variables names that are set for output.

Returns
A vector of strings containing the names of the nonlinear variables for output
See also
hasElementalVariableOutput

Definition at line 721 of file AdvancedOutput.C.

Referenced by Nemesis::output(), and Exodus::outputElementalVariables().

722 {
723  return _execute_data["elemental"].output;
724 }
OutputDataWarehouse _execute_data
Storage structures for the various output types.

◆ getExecuteOnEnum()

const ExecFlagEnum & SetupInterface::getExecuteOnEnum ( ) const
inherited

Return the execute on MultiMooseEnum for this object.

Definition at line 67 of file SetupInterface.C.

Referenced by ExecuteMooseObjectWarehouse< Transfer >::addObjectMask(), EigenExecutionerBase::init(), AttribExecOns::initFrom(), and MultiAppTransfer::MultiAppTransfer().

68 {
69  return _execute_enum;
70 }
const ExecFlagEnum & _execute_enum
Execute settings for this oejct.

◆ getExecuteOptions()

ExecFlagEnum SetupInterface::getExecuteOptions ( )
staticinherited

(DEPRECATED) Returns the available options for the 'execute_on' input parameters TODO: ExecFlagType

Returns
A MooseEnum with the available 'execute_on' options, the default is 'residual'

Definition at line 101 of file SetupInterface.C.

102 {
103  // TODO: ExecFlagType
104  ::mooseDeprecated("The 'getExecuteOptions' was replaced by the ExecFlagEnum class because MOOSE "
105  "was updated to use this for the execute flags and the new function provides "
106  "additional arguments for modification of the enum.");
108 }
ExecFlagEnum getDefaultExecFlagEnum()
Return the default ExecFlagEnum for MOOSE.
Definition: MooseUtils.C:715
void mooseDeprecated(Args &&... args)
Emit a deprecated code/feature message with the given stringified, concatenated args.
Definition: MooseError.h:237

◆ getFileNumber()

unsigned int FileOutput::getFileNumber ( )
inherited

Return the current file number for this outputter.

This method was implemented for the MultiApp system, particularly when reseting an application and a new output file is desired after the reset.

Definition at line 184 of file FileOutput.C.

Referenced by OutputWarehouse::getFileNumbers().

185 {
186  return _file_num;
187 }
unsigned int & _file_num
A file number counter, initialized to 0 (this must be controlled by the child class, see Exodus)
Definition: FileOutput.h:85

◆ getMooseApp()

MooseApp& MooseObject::getMooseApp ( ) const
inlineinherited

Get the MooseApp this object is associated with.

Definition at line 91 of file MooseObject.h.

Referenced by RestartableDataIO::createBackup(), RestartableDataIO::deserializeRestartableData(), ConsoleUtils::outputMeshInformation(), Resurrector::restartRestartableData(), and RestartableDataIO::restoreBackup().

91 { return _app; }
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174

◆ getNodalVariableOutput()

const std::set< std::string > & AdvancedOutput::getNodalVariableOutput ( )
inherited

The list of nodal nonlinear variables names that are set for output.

Returns
A vector of strings containing the names of the nodal nonlinear variables for output

Note: The list returned by this will contain the names of both elemental and nodal variable names if 'elemental_as_nodal = true' in the input file. The libMesh output system (EquationSystems::build_solution_vector) performs the correct action within the solution vector by setting the nodal values as the average of the values for each of the element that the node shares.

See also
hasNodalVariableOutput

Definition at line 709 of file AdvancedOutput.C.

Referenced by Nemesis::output(), and Exodus::outputNodalVariables().

710 {
711  return _execute_data["nodal"].output;
712 }
OutputDataWarehouse _execute_data
Storage structures for the various output types.

◆ getOutputFileBase()

std::string FileOutput::getOutputFileBase ( const MooseApp app,
std::string  suffix = "_out" 
)
staticinherited

Returns the default output file base.

Returns
The name of the input file with '_out' append to the end

This method is static to allow for outside objects to call it, namely CommonOutputAction::setRecoverFileBase().

See also
CommonOutputAction::setRecoverFileBase()

Definition at line 111 of file FileOutput.C.

Referenced by FileOutput::FileOutput(), and MooseApp::getCheckpointDirectories().

112 {
113  // If the App has an outputfile, then use it (MultiApp scenario)
114  if (!app.getOutputFileBase().empty())
115  return app.getOutputFileBase();
116 
117  // If the output base is not set it must be determined from the input file
118  /* This will only return a non-empty string if the setInputFileName() was called, which is
119  * generally not the case. One exception is when CoupledExecutioner is used */
120  std::string input_filename = app.getInputFileName();
121  if (input_filename.empty())
122  input_filename = app.getFileName();
123 
124  // Assert that the filename is not empty
125  mooseAssert(!input_filename.empty(), "Input Filename is NULL");
126 
127  // Determine location of "." in extension, assert if it is not found
128  size_t pos = input_filename.find_last_of('.');
129  mooseAssert(pos != std::string::npos, "Unable to determine suffix of input file name");
130 
131  // Append the "_out" to the name and return it
132  size_t start = 0;
133  if (input_filename.find_last_of('/') != std::string::npos)
134  start = input_filename.find_last_of('/') + 1;
135  return input_filename.substr(start, pos - start) + suffix;
136 }
std::string getFileName(bool stripLeadingPath=true) const
Return the filename that was parsed.
Definition: MooseApp.C:1043
std::string getOutputFileBase() const
Override the selection of the output file base name.
Definition: MooseApp.C:784
std::string getInputFileName() const
Returns the input file name that was set with setInputFileName.
Definition: MooseApp.h:154

◆ getParam()

template<typename T >
const T & MooseObject::getParam ( const std::string &  name) const
inherited

Retrieve a parameter for the object.

Parameters
nameThe name of the parameter
Returns
The value of the parameter

Definition at line 188 of file MooseObject.h.

Referenced by FEProblemBase::addMaterialHelper(), ConstraintWarehouse::addObject(), BicubicSplineFunction::BicubicSplineFunction(), Piecewise::buildFromXandY(), MultiApp::createApp(), DerivativeParsedMaterial::DerivativeParsedMaterial(), EigenKernel::EigenKernel(), FEProblemBase::FEProblemBase(), FieldSplitPreconditioner::FieldSplitPreconditioner(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), SideSetsBetweenSubdomainsGenerator::generate(), ExtraNodesetGenerator::generate(), MeshExtruderGenerator::generate(), SideSetsAroundSubdomainGenerator::generate(), GenericConstantRankTwoTensor::GenericConstantRankTwoTensor(), TimeSequenceStepper::init(), AttribThread::initFrom(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), initialSetup(), AdvancedOutput::initialSetup(), SideSetsBetweenSubdomains::modify(), AddExtraNodeset::modify(), MeshExtruder::modify(), SideSetsAroundSubdomain::modify(), ParsedAddSideset::ParsedAddSideset(), ParsedAux::ParsedAux(), ParsedGenerateSideset::ParsedGenerateSideset(), ParsedMaterial::ParsedMaterial(), ParsedODEKernel::ParsedODEKernel(), ParsedSubdomainMeshGenerator::ParsedSubdomainMeshGenerator(), ParsedSubdomainMeshModifier::ParsedSubdomainMeshModifier(), PhysicsBasedPreconditioner::PhysicsBasedPreconditioner(), SingleMatrixPreconditioner::SingleMatrixPreconditioner(), TimePeriod::TimePeriod(), and VectorOfPostprocessors::VectorOfPostprocessors().

189 {
190  return InputParameters::getParamHelper(name, _pars, static_cast<T *>(0));
191 }
static const T & getParamHelper(const std::string &name, const InputParameters &pars, const T *the_type)
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171
const std::string & name() const
Get the name of the object.
Definition: MooseObject.h:56

◆ getPostprocessorOutput()

const std::set< std::string > & AdvancedOutput::getPostprocessorOutput ( )
inherited

The list of postprocessor names that are set for output.

Returns
A vector of strings containing the names of the postprocessor variables for output
See also
hasPostprocessorOutput

Definition at line 745 of file AdvancedOutput.C.

Referenced by TableOutput::outputPostprocessors(), Nemesis::outputPostprocessors(), and Exodus::outputPostprocessors().

746 {
747  return _execute_data["postprocessors"].output;
748 }
OutputDataWarehouse _execute_data
Storage structures for the various output types.

◆ getScalarOutput()

const std::set< std::string > & AdvancedOutput::getScalarOutput ( )
inherited

The list of scalar variables names that are set for output.

Returns
A vector of strings containing the names of the scalar variables for output
See also
hasScalarVariableOutput

Definition at line 733 of file AdvancedOutput.C.

Referenced by TableOutput::outputScalarVariables(), Nemesis::outputScalarVariables(), and Exodus::outputScalarVariables().

734 {
735  return _execute_data["scalars"].output;
736 }
OutputDataWarehouse _execute_data
Storage structures for the various output types.

◆ getVectorPostprocessorOutput()

const std::set< std::string > & AdvancedOutput::getVectorPostprocessorOutput ( )
inherited

The list of VectorPostprocessor names that are set for output.

Returns
A vector of strings containing the names of the VectorPostprocessor variables for output
See also
hasVectorPostprocessorOutput

Definition at line 757 of file AdvancedOutput.C.

Referenced by CSV::initialSetup(), and TableOutput::outputVectorPostprocessors().

758 {
759  return _execute_data["vector_postprocessors"].output;
760 }
OutputDataWarehouse _execute_data
Storage structures for the various output types.

◆ hasElementalVariableOutput()

bool AdvancedOutput::hasElementalVariableOutput ( )
inherited

Returns true if there exists elemental nonlinear variables for output.

Returns
True if nonlinear variable output exists
See also
getElementalVariableOutput

Definition at line 715 of file AdvancedOutput.C.

Referenced by Exodus::initialSetup().

716 {
717  return hasOutputHelper("elemental");
718 }
bool hasOutputHelper(const std::string &name)
Helper method for checking if output types exists.

◆ hasNodalVariableOutput()

bool AdvancedOutput::hasNodalVariableOutput ( )
inherited

Returns true if there exists nodal nonlinear variables for output.

Returns
True if nonlinear variable output exists
See also
getNodalVariableOutput

Definition at line 703 of file AdvancedOutput.C.

Referenced by Exodus::initialSetup(), and Exodus::outputElementalVariables().

704 {
705  return hasOutputHelper("nodal");
706 }
bool hasOutputHelper(const std::string &name)
Helper method for checking if output types exists.

◆ hasOutput() [1/2]

bool AdvancedOutput::hasOutput ( )
virtualinherited

Returns true if any of the other has methods return true.

Definition at line 350 of file AdvancedOutput.C.

Referenced by Exodus::initialSetup(), and AdvancedOutput::shouldOutput().

351 {
352  // Test that variables exist for output AND that output execution flags are valid
353  for (const auto & it : _execute_data)
354  if (!(it.second).output.empty() && _advanced_execute_on.contains(it.first) &&
355  _advanced_execute_on[it.first].isValid())
356  return true;
357 
358  // Test execution flags for non-variable output
359  if (_advanced_execute_on.contains("system_information") &&
360  _advanced_execute_on["system_information"].isValid())
361  return true;
362  if (_advanced_execute_on.contains("input") && _advanced_execute_on["input"].isValid())
363  return true;
364 
365  return false;
366 }
OutputOnWarehouse _advanced_execute_on
Storage for the individual component execute flags.
Definition: Output.h:243
OutputDataWarehouse _execute_data
Storage structures for the various output types.
bool contains(const std::string &name)
A method for testing of a key exists.

◆ hasOutput() [2/2]

bool AdvancedOutput::hasOutput ( const ExecFlagType type)
inherited

Tests that any output exist for the given output type.

See also
Exodus

Definition at line 338 of file AdvancedOutput.C.

339 {
340  // If any of the component outputs are true, then there is some output to perform
341  for (const auto & it : _advanced_execute_on)
342  if (wantOutput(it.first, type))
343  return true;
344 
345  // There is nothing to output
346  return false;
347 }
OutputOnWarehouse _advanced_execute_on
Storage for the individual component execute flags.
Definition: Output.h:243
const std::string & type() const
Get the type of this object.
Definition: MooseObject.h:50
bool wantOutput(const std::string &name, const ExecFlagType &type)
Handles logic for determining if a step should be output.

◆ hasPostprocessorOutput()

bool AdvancedOutput::hasPostprocessorOutput ( )
inherited

Returns true if there exists postprocessors for output.

Returns
True if postprocessor output exists
See also
getPostprocessorOutput

Definition at line 739 of file AdvancedOutput.C.

Referenced by Exodus::initialSetup().

740 {
741  return hasOutputHelper("postprocessors");
742 }
bool hasOutputHelper(const std::string &name)
Helper method for checking if output types exists.

◆ hasScalarOutput()

bool AdvancedOutput::hasScalarOutput ( )
inherited

Returns true if there exists scalar variables for output.

Returns
True if scalar variable output exists
See also
getScalarVariableOutput

Definition at line 727 of file AdvancedOutput.C.

Referenced by Exodus::initialSetup().

728 {
729  return hasOutputHelper("scalars");
730 }
bool hasOutputHelper(const std::string &name)
Helper method for checking if output types exists.

◆ hasVectorPostprocessorOutput()

bool AdvancedOutput::hasVectorPostprocessorOutput ( )
inherited

Returns true if there exists VectorPostprocessors for output.

Returns
True if VectorPostprocessor output exists
See also
getVectorPostprocessorOutput

Definition at line 751 of file AdvancedOutput.C.

752 {
753  return hasOutputHelper("vector_postprocessors");
754 }
bool hasOutputHelper(const std::string &name)
Helper method for checking if output types exists.

◆ init()

void Console::init ( )
protected

Adds the printing of system information to the init() method.

◆ initialSetup()

void Console::initialSetup ( )
overridevirtual

Initial setup function Prints the system information, this is done here so that the system information is printed prior to any PETSc solve information.

Reimplemented from AdvancedOutput.

Definition at line 230 of file Console.C.

231 {
232  // Only allow the main app to change the perf_log settings.
233  if (_app.name() == "main")
234  {
235  // Disable libMesh log
236  if (!_libmesh_log)
237  libMesh::perflog.disable_logging();
238  }
239 
240  // system info flag can be changed only before console initial setup
242 
243  // If execute_on = 'initial' perform the output
244  if (wantOutput("system_information", EXEC_INITIAL))
246 
247  // Call the base class method
249 
250  // If file output is desired, wipe out the existing file if not recovering
251  if (!_app.isRecovering())
252  writeStreamToFile(false);
253 
254  // Enable verbose output if Executioner has it enabled
255  if (_app.getExecutioner()->isParamValid("verbose") &&
256  _app.getExecutioner()->getParam<bool>("verbose"))
257  _verbose = true;
258 
259  // Display a message to indicate the application is running (useful for MultiApps)
261  write(std::string("\nRunning App: ") + _app.name() + "\n");
262 
263  // If the user adds "final" to the execute on, append this to the postprocessors, scalars, etc.,
264  // but only
265  // if the parameter (e.g., postprocessor_execute_on) has not been modified by the user.
266  if (_execute_on.contains("final"))
267  {
268  if (!_pars.isParamSetByUser("postprocessor_execute_on"))
269  _advanced_execute_on["postprocessors"].push_back("final");
270  if (!_pars.isParamSetByUser("scalars_execute_on"))
271  _advanced_execute_on["scalars"].push_back("final");
272  if (!_pars.isParamSetByUser("vector_postprocessor_execute_on"))
273  _advanced_execute_on["vector_postprocessors"].push_back("final");
274  }
275 
278 }
bool _libmesh_log
Control the display libMesh performance log.
Definition: Console.h:186
const std::string & name() const
Get the name of the object.
Definition: MooseApp.h:73
Executioner * getExecutioner() const
Retrieve the Executioner for this App.
Definition: MooseApp.h:249
ExecFlagEnum _execute_on
The common Execution types; this is used as the default execution type for everything except system i...
Definition: Output.h:186
OutputOnWarehouse _advanced_execute_on
Storage for the individual component execute flags.
Definition: Output.h:243
virtual void outputSystemInformation() override
Print system information.
Definition: Console.C:571
bool _verbose
Flag for writing detailed time step information.
Definition: Console.h:171
unsigned int multiAppLevel() const
The MultiApp Level.
Definition: MooseApp.h:511
bool _allow_changing_sysinfo_flag
A boolean for protecting _system_info_flags from being changed undesirably.
Definition: Console.h:235
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
Definition: MooseObject.h:188
bool contains(const std::string &value) const
Contains methods for seeing if a value is in the MultiMooseEnum.
void write(std::string message, bool indent=true)
Write message to screen and/or file.
Definition: Console.C:625
FEProblemBase * _problem_ptr
Pointer the the FEProblemBase object for output object (use this)
Definition: Output.h:168
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171
bool wantOutput(const std::string &name, const ExecFlagType &type)
Handles logic for determining if a step should be output.
void writeStreamToFile(bool append=true)
Write the file stream to the file.
Definition: Console.C:357
bool isParamSetByUser(const std::string &name) const
Method returns true if the parameter was by the user.
virtual void initialSetup()
Initialization method.
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174
void writeTimestepInformation()
Prints the time step information for the screen output.
Definition: Console.C:384
bool hasMultiApps() const
Returns whether or not the current simulation has any multiapps.
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
Definition: MooseObject.h:86
bool isRecovering() const
Whether or not this is a "recover" calculation.
Definition: MooseApp.C:853
const ExecFlagType EXEC_INITIAL

◆ interval()

const unsigned int& Output::interval ( ) const
inherited

Get the output interval.

◆ isAdvanced()

bool Output::isAdvanced ( )
inherited

Returns true if this object is an AdvancedOutput object.

Definition at line 271 of file Output.C.

272 {
273  return _is_advanced;
274 }
bool _is_advanced
Flag for advanced output testing.
Definition: Output.h:237

◆ isParamValid()

bool MooseObject::isParamValid ( const std::string &  name) const
inlineinherited

Test if the supplied parameter is valid.

Parameters
nameThe name of the parameter to test

Definition at line 86 of file MooseObject.h.

Referenced by AdvancedOutput::AdvancedOutput(), BicubicSplineFunction::BicubicSplineFunction(), Piecewise::buildFromFile(), Piecewise::buildFromXandY(), DistributedGeneratedMesh::buildMesh(), GeneratedMesh::buildMesh(), CartesianMeshGenerator::CartesianMeshGenerator(), LibmeshPartitioner::clone(), OversampleOutput::cloneMesh(), CSVReader::CSVReader(), MultiAppNearestNodeTransfer::execute(), Exodus::Exodus(), FEProblemBase::FEProblemBase(), FileOutput::FileOutput(), MultiApp::fillPositions(), FunctionDT::FunctionDT(), RenameBoundaryGenerator::generate(), BreakBoundaryOnSubdomainGenerator::generate(), ElementSubdomainIDGenerator::generate(), ExtraNodesetGenerator::generate(), LowerDBlockFromSidesetGenerator::generate(), MeshSideSetGenerator::generate(), RenameBlockGenerator::generate(), GeneratedMeshGenerator::generate(), ParsedSubdomainMeshGenerator::generate(), MeshExtruderGenerator::generate(), SubdomainBoundingBoxGenerator::generate(), MultiAppNearestNodeTransfer::getLocalEntities(), MeshGenerator::getMesh(), MultiAppNearestNodeTransfer::getNearestNode(), EigenExecutionerBase::init(), IterationAdaptiveDT::init(), MooseMesh::init(), AdvancedOutput::initExecutionTypes(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), SolutionAux::initialSetup(), MooseParsedVectorFunction::initialSetup(), initialSetup(), Receiver::initialSetup(), SolutionFunction::initialSetup(), MooseParsedGradFunction::initialSetup(), MooseParsedFunction::initialSetup(), AdvancedOutput::initialSetup(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), IterationAdaptiveDT::IterationAdaptiveDT(), LeastSquaresFit::LeastSquaresFit(), LibmeshPartitioner::LibmeshPartitioner(), BreakBoundaryOnSubdomain::modify(), MeshExtruder::modify(), MeshSideSet::modify(), LowerDBlockFromSideset::modify(), AssignElementSubdomainID::modify(), ParsedSubdomainMeshModifier::modify(), RenameBlock::modify(), SubdomainBoundingBox::modify(), MooseMesh::MooseMesh(), EigenExecutionerBase::normalizeSolution(), Output::Output(), PetscOutput::PetscOutput(), Piecewise::Piecewise(), SolutionUserObject::readExodusII(), RenameBlock::RenameBlock(), RenameBlockGenerator::RenameBlockGenerator(), RenameBoundaryGenerator::RenameBoundaryGenerator(), SolutionUserObject::SolutionUserObject(), and TimePeriod::TimePeriod().

86 { return _pars.isParamValid(name); }
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171
const std::string & name() const
Get the name of the object.
Definition: MooseObject.h:56
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.

◆ jacobianSetup()

void SetupInterface::jacobianSetup ( )
virtualinherited

Gets called just before the Jacobian is computed and before this object is asked to do its job.

Reimplemented in EqualValueEmbeddedConstraint.

Definition at line 52 of file SetupInterface.C.

53 {
54 }

◆ meshChanged()

void Console::meshChanged ( )
overridevirtual

Performs console related printing when the mesh is changed.

Reimplemented from MeshChangedInterface.

Definition at line 608 of file Console.C.

609 {
611  {
612  _console << ConsoleUtils::outputMeshInformation(*_problem_ptr, /*verbose = */ false);
613 
615  if (!output.empty())
616  _console << "Nonlinear System:\n" << output;
617 
619  if (!output.empty())
620  _console << "Auxiliary System:\n" << output;
621  }
622 }
std::string outputNonlinearSystemInformation(FEProblemBase &problem)
Output the Nonlinear system information.
Definition: ConsoleUtils.C:114
std::string outputAuxiliarySystemInformation(FEProblemBase &problem)
Output the Auxiliary system information.
Definition: ConsoleUtils.C:108
virtual void output(const ExecFlagType &type) override
Customizes the order of output for the various components as well as adds additional output such as t...
Definition: Console.C:293
std::string outputMeshInformation(FEProblemBase &problem, bool verbose=true)
Output the mesh information.
Definition: ConsoleUtils.C:54
FEProblemBase * _problem_ptr
Pointer the the FEProblemBase object for output object (use this)
Definition: Output.h:168
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
bool _print_mesh_changed_info
Flag for printing mesh information when the mesh changes.
Definition: Console.h:226

◆ mooseConsole()

void Console::mooseConsole ( const std::string &  message)
private

Add a message to the output streams.

Parameters
messageThe message to add to the output streams

Any call to this method will write the supplied message to the screen and/or file, following the same restrictions as outputStep.

Calls to this method should be made via OutputWarehouse::mooseConsole so that the output stream buffer is cleaned up correctly. Thus, it is a private method.

Definition at line 645 of file Console.C.

646 {
647  // Write the messages
648  write(message);
649 
650  // Flush the stream to the screen
651  Moose::out << std::flush;
652 }
void write(std::string message, bool indent=true)
Write message to screen and/or file.
Definition: Console.C:625

◆ mooseDeprecated()

template<typename... Args>
void MooseObject::mooseDeprecated ( Args &&...  args) const
inlineinherited

◆ mooseError()

template<typename... Args>
void MooseObject::mooseError ( Args &&...  args) const
inlineinherited

Definition at line 144 of file MooseObject.h.

Referenced by PetscExternalPartitioner::_do_partition(), GridPartitioner::_do_partition(), FEProblemBase::addConstraint(), FEProblemBase::addInitialCondition(), FEProblem::addLineSearch(), FEProblemBase::addLineSearch(), FEProblemBase::addOutput(), DiracKernel::addPointWithValidId(), FEProblemBase::addPostprocessor(), MooseMesh::addQuadratureNode(), FEProblemBase::addVectorPostprocessor(), Output::advancedExecuteOn(), AnnularMesh::AnnularMesh(), AnnularMeshGenerator::AnnularMeshGenerator(), MultiApp::appPostprocessorValue(), MultiApp::appProblem(), MultiApp::appProblemBase(), MultiApp::appUserObjectBase(), DerivativeParsedMaterialHelper::assembleDerivatives(), Function::average(), Axisymmetric2D3DSolutionFunction::Axisymmetric2D3DSolutionFunction(), BicubicSplineFunction::BicubicSplineFunction(), BoundingValueElementDamper::BoundingValueElementDamper(), BoundingValueNodalDamper::BoundingValueNodalDamper(), BoundsAux::BoundsAux(), BreakMeshByBlockGenerator::BreakMeshByBlockGenerator(), BreakMeshByBlockGeneratorBase::BreakMeshByBlockGeneratorBase(), MooseMesh::buildCoarseningMap(), Piecewise::buildFromFile(), Piecewise::buildFromXandY(), Piecewise::buildFromXY(), TiledMesh::buildMesh(), FileMesh::buildMesh(), SpiralAnnularMesh::buildMesh(), DistributedGeneratedMesh::buildMesh(), GeneratedMesh::buildMesh(), ImageMeshGenerator::buildMesh3D(), ImageMesh::buildMesh3D(), MooseMesh::buildMeshBaseObject(), MooseMesh::buildRefinementMap(), MooseMesh::buildSideList(), CartesianMeshGenerator::CartesianMeshGenerator(), ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), EigenExecutionerBase::chebyshev(), SubProblem::checkBlockMatProps(), SubProblem::checkBoundaryMatProps(), FEProblemBase::checkCoordinateSystems(), FEProblemBase::checkDependMaterialsHelper(), FEProblemBase::checkDisplacementOrders(), Material::checkExecutionStage(), BreakMeshByBlockBase::checkInputParameter(), Steady::checkIntegrity(), EigenExecutionerBase::checkIntegrity(), ActuallyExplicitEuler::checkLinearConvergence(), FEProblemBase::checkProblemIntegrity(), Material::checkStatefulSanity(), FEProblemBase::checkUserObjects(), LibmeshPartitioner::clone(), MooseMesh::clone(), ComparisonPostprocessor::comparisonIsTrue(), CompositeFunction::CompositeFunction(), ElementLpNormAux::compute(), ElementH1ErrorFunctionAux::compute(), NodalPatchRecovery::compute(), KernelBase::computeADOffDiagJacobian(), InterfaceKernel::computeElemNeighJacobian(), TimeSequenceStepperBase::computeFailedDT(), IterationAdaptiveDT::computeFailedDT(), TimeStepper::computeFailedDT(), HistogramVectorPostprocessor::computeHistogram(), EqualValueEmbeddedConstraint::computeQpJacobian(), EqualValueEmbeddedConstraint::computeQpOffDiagJacobian(), KernelValue::computeQpResidual(), FEProblemBase::computeResidualInternal(), FEProblemBase::computeResidualTag(), FEProblemBase::computeResidualType(), StatisticsVectorPostprocessor::computeStatValue(), Material::computeSubdomainProperties(), ExplicitEuler::computeTimeDerivatives(), ImplicitEuler::computeTimeDerivatives(), BDF2::computeTimeDerivatives(), NewmarkBeta::computeTimeDerivatives(), CrankNicolson::computeTimeDerivatives(), ActuallyExplicitEuler::computeTimeDerivatives(), LStableDirk2::computeTimeDerivatives(), LStableDirk3::computeTimeDerivatives(), ImplicitMidpoint::computeTimeDerivatives(), ExplicitTVDRK2::computeTimeDerivatives(), AStableDirk4::computeTimeDerivatives(), LStableDirk4::computeTimeDerivatives(), ExplicitRK2::computeTimeDerivatives(), PenetrationAux::computeValue(), ConcentricCircleMesh::ConcentricCircleMesh(), ConcentricCircleMeshGenerator::ConcentricCircleMeshGenerator(), TimeStepper::constrainStep(), AuxKernel::coupledDot(), AuxKernel::coupledDotDu(), CoupledForce::CoupledForce(), DebugResidualAux::DebugResidualAux(), BicubicSplineFunction::derivative(), DerivativeSumMaterial::DerivativeSumMaterial(), DGKernelBase::DGKernelBase(), FEProblemBase::duplicateVariableCheck(), EigenProblem::EigenProblem(), Eigenvalues::Eigenvalues(), ElementalVariableValue::ElementalVariableValue(), ElementQualityAux::ElementQualityAux(), MooseMesh::errorIfDistributedMesh(), SolutionUserObject::evalMeshFunction(), SolutionUserObject::evalMeshFunctionGradient(), SolutionUserObject::evalMultiValuedMeshFunction(), SolutionUserObject::evalMultiValuedMeshFunctionGradient(), MultiAppPostprocessorTransfer::execute(), DiscreteElementUserObject::execute(), MultiAppPostprocessorInterpolationTransfer::execute(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), ElementQualityChecker::execute(), NodalValueSampler::execute(), PointValue::execute(), MultiAppPostprocessorToAuxScalarTransfer::execute(), MultiAppScalarToAuxScalarTransfer::execute(), MultiAppVariableValueSampleTransfer::execute(), MultiAppInterpolationTransfer::execute(), MultiAppUserObjectTransfer::execute(), FindValueOnLine::execute(), MultiAppNearestNodeTransfer::execute(), TimeExtremeValue::execute(), VectorPostprocessorComparison::execute(), LeastSquaresFit::execute(), LeastSquaresFitHistory::execute(), FEProblemBase::executeControls(), MultiAppVectorPostprocessorTransfer::executeFromMultiapp(), MultiAppVectorPostprocessorTransfer::executeToMultiapp(), Exodus::Exodus(), FileOutput::FileOutput(), CentroidMultiApp::fillPositions(), MultiApp::fillPositions(), VerifyNodalUniqueID::finalize(), VerifyElementUniqueID::finalize(), DiscreteElementUserObject::finalize(), ElementQualityChecker::finalize(), MemoryUsage::finalize(), PointSamplerBase::finalize(), Transfer::find_sys(), BreakMeshByBlockBase::findFreeBoundaryId(), BreakMeshByBlockGeneratorBase::findFreeBoundaryId(), FunctionDT::FunctionDT(), FunctionMaterialBase::FunctionMaterialBase(), ParsedMaterialHelper::functionParse(), FunctionScalarAux::FunctionScalarAux(), FunctionScalarIC::FunctionScalarIC(), GapValueAux::GapValueAux(), ElementSubdomainIDGenerator::generate(), ExtraNodesetGenerator::generate(), RenameBlockGenerator::generate(), RenameBoundaryGenerator::generate(), GeneratedMeshGenerator::generate(), MeshExtruderGenerator::generate(), SideSetsFromBoundingBoxGenerator::generate(), StackGenerator::generate(), SpiralAnnularMeshGenerator::generate(), PatternedMeshGenerator::generate(), BoundingBoxNodeSetGenerator::generate(), GeneratedMesh::GeneratedMesh(), GeneratedMeshGenerator::GeneratedMeshGenerator(), RandomICBase::generateRandom(), GenericConstantMaterial::GenericConstantMaterial(), GenericFunctionMaterial::GenericFunctionMaterial(), MooseMesh::getBoundaryID(), MultiApp::getBoundingBox(), MooseMesh::getCoarseningMap(), Control::getControllableParameterByName(), FEProblemBase::getCoordSystem(), PiecewiseConstant::getDirection(), FEProblemBase::getDistribution(), ElementGenerator::getElemType(), MultiApp::getExecutioner(), FEProblemBase::getFunction(), SolutionUserObject::getLocalVarIndex(), AuxKernel::getMaterialProperty(), AuxKernel::getMaterialPropertyOld(), AuxKernel::getMaterialPropertyOlder(), SubProblem::getMatrixTagID(), AnnularMesh::getMaxInDimension(), DistributedGeneratedMesh::getMaxInDimension(), GeneratedMesh::getMaxInDimension(), FEProblemBase::getMaxQps(), FEProblemBase::getMaxShapeFunctions(), AnnularMesh::getMinInDimension(), DistributedGeneratedMesh::getMinInDimension(), GeneratedMesh::getMinInDimension(), MooseMesh::getMortarInterface(), MooseMesh::getMortarInterfaceByName(), MooseMesh::getNodeBlockIds(), MooseMesh::getNodeList(), FEProblemBase::getNonlinearSystem(), MooseMesh::getPairedBoundaryMapping(), ImageMeshGenerator::GetPixelInfo(), ImageMesh::GetPixelInfo(), MaterialStdVectorAux::getRealValue(), MooseMesh::getRefinementMap(), FEProblemBase::getSampler(), DisplacedProblem::getScalarVariable(), FEProblemBase::getScalarVariable(), DisplacedProblem::getStandardVariable(), FEProblemBase::getStandardVariable(), MooseMesh::getSubdomainBoundaryIds(), MooseMesh::getSubdomainID(), DisplacedProblem::getSystem(), FEProblemBase::getSystem(), FEProblemBase::getUserObject(), FEProblemBase::getUserObjectBase(), PerformanceData::getValue(), Residual::getValue(), PerfGraphData::getValue(), LineValueSampler::getValue(), FindValueOnLine::getValueAtPoint(), SubProblem::getVariableHelper(), SubProblem::getVectorTagID(), DisplacedProblem::getVectorVariable(), FEProblemBase::getVectorVariable(), MultiApp::globalAppToLocal(), MooseParsedVectorFunction::gradient(), AdvancedOutput::hasOutputHelper(), CrankNicolson::init(), CSVTimeSequenceStepper::init(), IterationAdaptiveDT::init(), EigenExecutionerBase::init(), Transient::init(), MooseMesh::init(), FEProblemBase::init(), NumPicardIterations::initialize(), FullSolveMultiApp::initialSetup(), PiecewiseBase::initialSetup(), SolutionAux::initialSetup(), Axisymmetric2D3DSolutionFunction::initialSetup(), SolutionFunction::initialSetup(), Exodus::initialSetup(), SolutionUserObject::initialSetup(), FEProblemBase::initialSetup(), AdvancedOutput::initOutputList(), AdvancedOutput::initShowHideLists(), Material::initStatefulProperties(), Function::integral(), InterfaceKernel::InterfaceKernel(), InterfaceTimeKernel::InterfaceTimeKernel(), EigenExecutionerBase::inversePowerIteration(), InversePowerMethod::InversePowerMethod(), IterationAdaptiveDT::IterationAdaptiveDT(), LayeredSideIntegral::LayeredSideIntegral(), LeastSquaresFit::LeastSquaresFit(), LibmeshPartitioner::LibmeshPartitioner(), LinearCombinationFunction::LinearCombinationFunction(), LinearCombinationPostprocessor::LinearCombinationPostprocessor(), LinearNodalConstraint::LinearNodalConstraint(), LineMaterialSamplerBase< Real >::LineMaterialSamplerBase(), LineSearch::lineSearch(), LineValueSampler::LineValueSampler(), MaterialRealTensorValueAux::MaterialRealTensorValueAux(), MaterialRealVectorValueAux::MaterialRealVectorValueAux(), MaterialStdVectorRealGradientAux::MaterialStdVectorRealGradientAux(), MaterialVectorPostprocessor::MaterialVectorPostprocessor(), Distribution::median(), SubProblem::meshChanged(), MeshExtruder::MeshExtruder(), MeshExtruderGenerator::MeshExtruderGenerator(), MeshSideSetGenerator::MeshSideSetGenerator(), SideSetsFromNormals::modify(), SideSetsFromPoints::modify(), MeshExtruder::modify(), BreakMeshByBlockBase::modify(), AddExtraNodeset::modify(), AssignElementSubdomainID::modify(), SmoothMesh::modify(), AddAllSideSetsByNormals::modify(), ElementDeleterBase::modify(), ParsedSubdomainMeshModifier::modify(), RenameBlock::modify(), ImageSubdomain::modify(), OrientedSubdomainBoundingBox::modify(), BoundingBoxNodeSet::modify(), AddSideSetsFromBoundingBox::modify(), SubdomainBoundingBox::modify(), MooseMesh::MooseMesh(), MultiAppMeshFunctionTransfer::MultiAppMeshFunctionTransfer(), MultiAppPostprocessorTransfer::MultiAppPostprocessorTransfer(), NearestNodeDistanceAux::NearestNodeDistanceAux(), NearestNodeValueAux::NearestNodeValueAux(), RenameBlockGenerator::newBlockID(), RenameBlock::newBlockID(), RenameBlockGenerator::newBlockName(), RenameBlock::newBlockName(), NewmarkBeta::NewmarkBeta(), NodalConstraint::NodalConstraint(), NodalScalarKernel::NodalScalarKernel(), NodalVariableValue::NodalVariableValue(), NumDOFs::NumDOFs(), NumNonlinearIterations::NumNonlinearIterations(), NumVars::NumVars(), ElementSideNeighborLayers::operator()(), ElementPointNeighbors::operator()(), RelationshipManager::operator==(), XDA::output(), SolutionHistory::output(), Exodus::output(), AdvancedOutput::outputElementalVariables(), AdvancedOutput::outputInput(), AdvancedOutput::outputNodalVariables(), AdvancedOutput::outputPostprocessors(), AdvancedOutput::outputScalarVariables(), AdvancedOutput::outputSystemInformation(), outputVectorPostprocessors(), AdvancedOutput::outputVectorPostprocessors(), MooseObject::paramError(), PiecewiseBilinear::parse(), ParsedAddSideset::ParsedAddSideset(), ParsedAux::ParsedAux(), ParsedGenerateSideset::ParsedGenerateSideset(), ParsedODEKernel::ParsedODEKernel(), ParsedSubdomainMeshGenerator::ParsedSubdomainMeshGenerator(), ParsedSubdomainMeshModifier::ParsedSubdomainMeshModifier(), PetscExternalPartitioner::PetscExternalPartitioner(), PhysicsBasedPreconditioner::PhysicsBasedPreconditioner(), Piecewise::Piecewise(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), PiecewiseMulticonstant::PiecewiseMulticonstant(), PiecewiseMultiInterpolation::PiecewiseMultiInterpolation(), SolutionUserObject::pointValueGradientWrapper(), SolutionUserObject::pointValueWrapper(), LStableDirk2::postResidual(), LStableDirk3::postResidual(), ImplicitMidpoint::postResidual(), ExplicitTVDRK2::postResidual(), AStableDirk4::postResidual(), LStableDirk4::postResidual(), ExplicitRK2::postResidual(), Predictor::Predictor(), Transient::preExecute(), SolutionUserObject::readExodusII(), SolutionUserObject::readXda(), EqualValueEmbeddedConstraint::reinitConstraint(), RelativeSolutionDifferenceNorm::RelativeSolutionDifferenceNorm(), RenameBlock::RenameBlock(), RenameBlockGenerator::RenameBlockGenerator(), RenameBoundaryGenerator::RenameBoundaryGenerator(), RinglebMesh::RinglebMesh(), RinglebMeshGenerator::RinglebMeshGenerator(), ScalarComponentIC::ScalarComponentIC(), BicubicSplineFunction::secondDerivative(), FEProblemBase::setCoordSystem(), PiecewiseBase::setData(), EigenProblem::setEigenproblemType(), Sampler::setNumberOfRequiedRandomSeeds(), Exodus::setOutputDimensionInExodusWriter(), Split::setup(), TransientMultiApp::setupApp(), TimeSequenceStepperBase::setupSequence(), Transient::setupTimeIntegrator(), SideSetsFromBoundingBoxGenerator::SideSetsFromBoundingBoxGenerator(), SideSetsFromNormals::SideSetsFromNormals(), SideSetsFromNormalsGenerator::SideSetsFromNormalsGenerator(), SideSetsFromPoints::SideSetsFromPoints(), SideSetsFromPointsGenerator::SideSetsFromPointsGenerator(), SolutionTimeAdaptiveDT::SolutionTimeAdaptiveDT(), SolutionUserObject::SolutionUserObject(), PicardSolve::solve(), ActuallyExplicitEuler::solve(), FullSolveMultiApp::solveStep(), UserObject::spatialValue(), SphericalAverage::SphericalAverage(), SpiralAnnularMesh::SpiralAnnularMesh(), SpiralAnnularMeshGenerator::SpiralAnnularMeshGenerator(), StitchedMesh::StitchedMesh(), NodalUserObject::subdomainSetup(), GeneralUserObject::subdomainSetup(), Constraint::subdomainSetup(), systemInfoFlags(), Terminator::Terminator(), TestSetupPostprocessorDataActionFunction::TestSetupPostprocessorDataActionFunction(), ThreadedGeneralUserObject::ThreadedGeneralUserObject(), ThreadedGeneralUserObject::threadJoin(), DiscreteElementUserObject::threadJoin(), GeneralUserObject::threadJoin(), TiledMeshGenerator::TiledMeshGenerator(), Function::timeDerivative(), TimeExtremeValue::TimeExtremeValue(), TimePeriod::TimePeriod(), VectorPostprocessorVisualizationAux::timestepSetup(), MultiAppCopyTransfer::transfer(), MultiAppMeshFunctionTransfer::transferVariable(), FEProblemBase::uDotDotOldRequested(), FEProblemBase::uDotOldRequested(), EqualValueBoundaryConstraint::updateConstrainedNodes(), SolutionUserObject::updateExodusBracketingTimeIndices(), Axisymmetric2D3DSolutionFunction::value(), ValueRangeMarker::ValueRangeMarker(), ValueThresholdMarker::ValueThresholdMarker(), MultiAppTransfer::variableIntegrityCheck(), VariableTimeIntegrationAux::VariableTimeIntegrationAux(), VectorNodalBC::VectorNodalBC(), VectorOfPostprocessors::VectorOfPostprocessors(), VectorPostprocessorFunction::VectorPostprocessorFunction(), MooseParsedGradFunction::vectorValue(), MooseParsedFunction::vectorValue(), VolumeHistogram::VolumeHistogram(), VTKOutput::VTKOutput(), DOFMapOutput::writeStreamToFile(), and writeStreamToFile().

144  {
145  std::ostringstream oss;
146  moose::internal::mooseStreamAll(oss, std::forward<Args>(args)...);
147  std::string msg = oss.str();
148  callMooseErrorRaw(msg, &_app);
149  }
void mooseStreamAll(std::ostringstream &ss)
All of the following are not meant to be called directly - they are called by the normal macros (moos...
Definition: MooseError.C:87
void callMooseErrorRaw(std::string &msg, MooseApp *app)
Definition: MooseObject.C:57
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174

◆ mooseInfo()

template<typename... Args>
void MooseObject::mooseInfo ( Args &&...  args) const
inlineinherited

◆ mooseWarning()

template<typename... Args>
void MooseObject::mooseWarning ( Args &&...  args) const
inlineinherited

◆ name()

const std::string& MooseObject::name ( ) const
inlineinherited

Get the name of the object.

Returns
The name of the object

Definition at line 56 of file MooseObject.h.

Referenced by GridPartitioner::_do_partition(), FEProblemBase::addADJacobianMaterial(), FEProblemBase::addADResidualMaterial(), Executioner::addAttributeReporter(), DumpObjectsProblem::addAuxKernel(), FEProblemBase::addAuxKernel(), DumpObjectsProblem::addAuxScalarKernel(), FEProblemBase::addAuxScalarKernel(), DumpObjectsProblem::addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), DumpObjectsProblem::addConstraint(), FEProblemBase::addConstraint(), FEProblemBase::addDamper(), DumpObjectsProblem::addDGKernel(), FEProblemBase::addDGKernel(), DumpObjectsProblem::addDiracKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addDistribution(), DumpObjectsProblem::addFunction(), FEProblemBase::addFunction(), FEProblemBase::addIndicator(), DumpObjectsProblem::addInitialCondition(), FEProblemBase::addInitialCondition(), DumpObjectsProblem::addInterfaceKernel(), FEProblemBase::addInterfaceKernel(), DumpObjectsProblem::addKernel(), FEProblemBase::addKernel(), FEProblemBase::addMarker(), DumpObjectsProblem::addMaterial(), FEProblemBase::addMaterial(), FEProblemBase::addMaterialHelper(), MooseMesh::addMortarInterface(), FEProblemBase::addMultiApp(), DumpObjectsProblem::addNodalKernel(), FEProblemBase::addNodalKernel(), FEProblemBase::addPostprocessor(), FEProblemBase::addPredictor(), FEProblemBase::addSampler(), DumpObjectsProblem::addScalarKernel(), FEProblemBase::addScalarKernel(), FEProblemBase::addTimeIntegrator(), FEProblemBase::addTransfer(), FEProblemBase::addUserObject(), FEProblemBase::addVectorPostprocessor(), Output::advancedExecuteOn(), MultiApp::appPostprocessorValue(), MultiApp::appProblem(), MultiApp::appProblemBase(), MultiApp::appUserObjectBase(), DerivativeParsedMaterialHelper::assembleDerivatives(), AStableDirk4::AStableDirk4(), Function::average(), MultiApp::backup(), BreakMeshByBlockGenerator::BreakMeshByBlockGenerator(), ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), FEProblemBase::checkDependMaterialsHelper(), Damper::checkMinDamping(), Material::checkStatefulSanity(), CompositeFunction::CompositeFunction(), Material::computeSubdomainProperties(), VectorPostprocessorVisualizationAux::computeValue(), AuxKernel::coupledCallback(), AuxKernel::coupledDot(), AuxKernel::coupledDotDu(), MultiApp::createApp(), FEProblemBase::declareVectorPostprocessorVector(), DOFMapOutput::demangle(), DerivativeSumMaterial::DerivativeSumMaterial(), DGKernelBase::DGKernelBase(), DumpObjectsProblem::dumpObjectHelper(), ElementValueSampler::ElementValueSampler(), MooseMesh::errorIfDistributedMesh(), AB2PredictorCorrector::estimateTimeError(), SolutionUserObject::evalMeshFunction(), SolutionUserObject::evalMeshFunctionGradient(), SolutionUserObject::evalMultiValuedMeshFunction(), SolutionUserObject::evalMultiValuedMeshFunctionGradient(), MultiAppPostprocessorTransfer::execute(), MultiAppPostprocessorInterpolationTransfer::execute(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), StatisticsVectorPostprocessor::execute(), PointValue::execute(), MultiAppPostprocessorToAuxScalarTransfer::execute(), MultiAppScalarToAuxScalarTransfer::execute(), MultiAppVariableValueSampleTransfer::execute(), MultiAppMeshFunctionTransfer::execute(), MultiAppUserObjectTransfer::execute(), MultiAppInterpolationTransfer::execute(), MultiAppProjectionTransfer::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppVectorPostprocessorTransfer::execute(), HistogramVectorPostprocessor::execute(), MultiAppCopyTransfer::execute(), Exodus::Exodus(), FileOutput::FileOutput(), MultiApp::fillPositions(), PointSamplerBase::finalize(), DerivativeParsedMaterialHelper::findMatPropDerivative(), FunctionDT::FunctionDT(), GeneralUserObject::GeneralUserObject(), LowerDBlockFromSidesetGenerator::generate(), StitchedMeshGenerator::generate(), Material::getADMaterialProperty(), MultiApp::getBoundingBox(), MooseObject::getCheckedPointerParam(), Control::getControllableParameterByName(), Control::getControllableValue(), Control::getControllableValueByName(), DistributionInterface::getDistribution(), FEProblemBase::getDistribution(), DistributionInterface::getDistributionByName(), MultiApp::getExecutioner(), OutputWarehouse::getFileNumbers(), FEProblemBase::getFunction(), SolutionUserObject::getLocalVarIndex(), Marker::getMarkerValue(), FEProblemBase::getMaterial(), NodalPatchRecovery::getMaterialProperty(), AuxKernel::getMaterialProperty(), Material::getMaterialProperty(), SubProblem::getMaterialPropertyBlockNames(), SubProblem::getMaterialPropertyBoundaryNames(), NodalPatchRecovery::getMaterialPropertyOld(), AuxKernel::getMaterialPropertyOld(), Material::getMaterialPropertyOld(), NodalPatchRecovery::getMaterialPropertyOlder(), AuxKernel::getMaterialPropertyOlder(), Material::getMaterialPropertyOlder(), MeshGenerator::getMesh(), MooseMesh::getMortarInterfaceByName(), OutputWarehouse::getOutput(), MooseObject::getParam(), GeneralUserObject::getPostprocessorValue(), AuxKernel::getPostprocessorValue(), FEProblemBase::getPostprocessorValue(), GeneralUserObject::getPostprocessorValueByName(), AuxKernel::getPostprocessorValueByName(), FEProblemBase::getPostprocessorValueOld(), FEProblemBase::getPostprocessorValueOlder(), FEProblemBase::getSampler(), AuxKernel::getScatterVectorPostprocessorValue(), FEProblemBase::getScatterVectorPostprocessorValue(), AuxKernel::getScatterVectorPostprocessorValueByName(), FEProblemBase::getScatterVectorPostprocessorValueOld(), Transient::getTimeStepperName(), AuxKernel::getUserObject(), InitialConditionBase::getUserObject(), FEProblemBase::getUserObject(), InitialConditionBase::getUserObjectBase(), AuxKernel::getUserObjectBase(), FEProblemBase::getUserObjectBase(), AuxKernel::getUserObjectByName(), InitialConditionBase::getUserObjectByName(), GeneralUserObject::getVectorPostprocessorValue(), AuxKernel::getVectorPostprocessorValue(), FEProblemBase::getVectorPostprocessorValue(), GeneralUserObject::getVectorPostprocessorValueByName(), AuxKernel::getVectorPostprocessorValueByName(), FEProblemBase::getVectorPostprocessorValueOld(), FEProblemBase::hasFunction(), AdvancedOutput::hasOutputHelper(), FEProblemBase::hasPostprocessor(), FEProblemBase::hasUserObject(), FEProblemBase::hasVectorPostprocessor(), FEProblemBase::init(), AdvancedOutput::initExecutionTypes(), AttribName::initFrom(), CSVReader::initialize(), StatisticsVectorPostprocessor::initialize(), HistogramVectorPostprocessor::initialize(), MultiAppProjectionTransfer::initialSetup(), DerivativeFunctionMaterialBase::initialSetup(), SolutionUserObject::initialSetup(), AdvancedOutput::initOutputList(), FEProblemBase::initPostprocessorData(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), Material::initStatefulProperties(), FEProblemBase::initVectorPostprocessorData(), Function::integral(), InterfaceKernel::InterfaceKernel(), Registry::isADObj(), MooseObject::isParamValid(), Registry::isRegisteredObj(), LinearCombinationFunction::LinearCombinationFunction(), Marker::Marker(), MatDiffusionBase< Real >::MatDiffusionBase(), MaterialDerivativeTestKernelBase< Real >::MaterialDerivativeTestKernelBase(), MaterialVectorPostprocessor::MaterialVectorPostprocessor(), Distribution::median(), MemoryUsageReporter::MemoryUsageReporter(), MeshSideSetGenerator::MeshSideSetGenerator(), ElementDeleterBase::modify(), MooseVariableInterface< Real >::MooseVariableInterface(), NearestPointBase< LayeredAverage >::NearestPointBase(), NodalValueSampler::NodalValueSampler(), NodalVariableValue::NodalVariableValue(), Registry::objData(), DOFMapOutput::output(), Output::Output(), AdvancedOutput::outputElementalVariables(), AdvancedOutput::outputInput(), AdvancedOutput::outputNodalVariables(), ConsoleUtils::outputOutputInformation(), Nemesis::outputPostprocessors(), Exodus::outputPostprocessors(), AdvancedOutput::outputPostprocessors(), AdvancedOutput::outputScalarVariables(), AdvancedOutput::outputSystemInformation(), AdvancedOutput::outputVectorPostprocessors(), ParsedAddSideset::ParsedAddSideset(), ParsedAux::ParsedAux(), ParsedGenerateSideset::ParsedGenerateSideset(), ParsedODEKernel::ParsedODEKernel(), ParsedSubdomainMeshGenerator::ParsedSubdomainMeshGenerator(), ParsedSubdomainMeshModifier::ParsedSubdomainMeshModifier(), PointSamplerBase::PointSamplerBase(), Registry::registerObjectsTo(), FEProblemBase::registerRandomInterface(), Material::resetQpProperties(), MultiApp::restore(), Sampler::Sampler(), ScalarComponentIC::ScalarComponentIC(), MooseMesh::setBoundaryName(), Control::setControllableValue(), Control::setControllableValueByName(), OutputWarehouse::setFileNumbers(), MooseMesh::setSubdomainName(), Split::setup(), TransientMultiApp::setupApp(), SideSetsFromNormalsGenerator::SideSetsFromNormalsGenerator(), SideSetsFromPointsGenerator::SideSetsFromPointsGenerator(), SideValueSampler::SideValueSampler(), TransientMultiApp::solveStep(), UserObject::spatialValue(), SphericalAverage::SphericalAverage(), StitchedMesh::StitchedMesh(), SubProblem::storeBoundaryDelayedCheckMatProp(), SubProblem::storeBoundaryMatPropName(), SubProblem::storeBoundaryZeroMatProp(), SubProblem::storeSubdomainDelayedCheckMatProp(), SubProblem::storeSubdomainMatPropName(), SubProblem::storeSubdomainZeroMatProp(), TaggingInterface::TaggingInterface(), ThreadedGeneralUserObject::ThreadedGeneralUserObject(), Function::timeDerivative(), VectorPostprocessorVisualizationAux::timestepSetup(), TransientMultiApp::TransientMultiApp(), MultiAppTransfer::variableIntegrityCheck(), and AdvancedOutput::wantOutput().

56 { return _name; }
const std::string & _name
The name of this object, reference to value stored in InputParameters.
Definition: MooseObject.h:180

◆ onInterval()

bool Output::onInterval ( )
protectedvirtualinherited

Returns true if the output interval is satisfied.

Definition at line 199 of file Output.C.

Referenced by output(), OversampleOutput::outputStep(), and Output::outputStep().

200 {
201  // The output flag to return
202  bool output = false;
203 
204  // Return true if the current step on the current output interval and within the output time range
205  // and within the output step range
206  if (_time >= _start_time && _time <= _end_time && _t_step >= _start_step &&
207  _t_step <= _end_step && (_t_step % _interval) == 0)
208  output = true;
209 
210  // Return false if 'sync_only' is set to true
211  if (_sync_only)
212  output = false;
213 
214  // If sync times are not skipped, return true if the current time is a sync_time
215  if (_sync_times.find(_time) != _sync_times.end())
216  output = true;
217 
218  // Return the output status
219  return output;
220 }
virtual void output(const ExecFlagType &type)=0
Overload this function with the desired output activities.
Real _start_time
Start outputting time.
Definition: Output.h:213
int & _t_step
The current time step.
Definition: Output.h:195
int _start_step
Start outputting at this time step.
Definition: Output.h:219
const unsigned int _interval
The output time step interval.
Definition: Output.h:207
int _end_step
End outputting at this time step.
Definition: Output.h:222
bool _sync_only
Flag for only executing at sync times.
Definition: Output.h:228
std::set< Real > _sync_times
Sync times for this outputter.
Definition: Output.h:210
Real & _time
The current time for output purposes.
Definition: Output.h:189

◆ output()

void Console::output ( const ExecFlagType type)
overridevirtual

Customizes the order of output for the various components as well as adds additional output such as timestep information and nonlinear/linear residual information.

This method explicitly re-implements portions of AdvancedOutput::output, which is generally not recommended. This is done here to get the output ordering desired. If additional output types (e.g., elemental or nodal) are required in the future this calls will need to be explicitly added as well.

Reimplemented from AdvancedOutput.

Definition at line 293 of file Console.C.

Referenced by meshChanged(), outputSystemInformation(), and writeStreamToFile().

294 {
295  // Return if the current output is not on the desired interval
296  if (type != EXEC_FINAL && !onInterval())
297  return;
298 
299  // Output the system information first; this forces this to be the first item to write by default
300  // However, 'output_system_information_on' still operates correctly, so it may be changed by the
301  // user
302  if (wantOutput("system_information", type) && !(type == EXEC_INITIAL && _initialized))
304 
305  // Write the input
306  if (wantOutput("input", type))
307  outputInput();
308 
309  // Write the timestep information ("Time Step 0 ..."), this is controlled with "execute_on"
312 
313  // Print Non-linear Residual (control with "execute_on")
315  {
316  if (_nonlinear_iter == 0)
317  _old_nonlinear_norm = std::numeric_limits<Real>::max();
318 
319  _console << std::setw(2) << _nonlinear_iter
320  << " Nonlinear |R| = " << outputNorm(_old_nonlinear_norm, _norm) << '\n';
321 
323  }
324 
325  // Print Linear Residual (control with "execute_on")
327  {
328  if (_linear_iter == 0)
329  _old_linear_norm = std::numeric_limits<Real>::max();
330 
331  _console << std::setw(7) << _linear_iter
332  << " Linear |R| = " << outputNorm(_old_linear_norm, _norm) << '\n';
333 
335  }
336 
337  // Write variable norms
338  else if (type == EXEC_TIMESTEP_END)
339  {
341  write(Moose::perf_log.get_perf_info(), false);
343  }
344 
345  // Write Postprocessors and Scalars
346  if (wantOutput("postprocessors", type))
348 
349  if (wantOutput("scalars", type))
351 
352  // Write the file
354 }
ExecFlagEnum _execute_on
The common Execution types; this is used as the default execution type for everything except system i...
Definition: Output.h:186
virtual bool onInterval()
Returns true if the output interval is satisfied.
Definition: Output.C:199
void writeVariableNorms()
Print the L2-norms for each variable.
Definition: Console.C:425
virtual void outputSystemInformation() override
Print system information.
Definition: Console.C:571
int & _t_step
The current time step.
Definition: Output.h:195
const ExecFlagType EXEC_TIMESTEP_END
const std::string & type() const
Get the type of this object.
Definition: MooseObject.h:50
bool contains(const std::string &value) const
Contains methods for seeing if a value is in the MultiMooseEnum.
bool _initialized
True if init() has been called.
Definition: Output.h:231
PetscInt _linear_iter
Current linear iteration returned from PETSc.
Definition: PetscOutput.h:52
virtual void outputPostprocessors() override
Prints the postprocessor table to the screen.
Definition: Console.C:538
void write(std::string message, bool indent=true)
Write message to screen and/or file.
Definition: Console.C:625
unsigned int _perf_log_interval
The interval at which the performance log is printed.
Definition: Console.h:180
PerfLog perf_log
Perflog to be used by applications.
virtual void outputInput() override
Print the input file at the beginning of the simulation.
Definition: Console.C:525
virtual void outputScalarVariables() override
Prints the aux scalar variables table to the screen.
Definition: Console.C:553
const ExecFlagType EXEC_LINEAR
Real _norm
Current norm returned from PETSc.
Definition: PetscOutput.h:46
Real _old_nonlinear_norm
Storage for the old non linear residual (needed for color output and only when used when printing to ...
Definition: Console.h:223
bool wantOutput(const std::string &name, const ExecFlagType &type)
Handles logic for determining if a step should be output.
void writeStreamToFile(bool append=true)
Write the file stream to the file.
Definition: Console.C:357
const ExecFlagType EXEC_NONLINEAR
Real _old_linear_norm
Storage for the old linear residual (needed for color output and only when used when printing to the ...
Definition: Console.h:220
void writeTimestepInformation()
Prints the time step information for the screen output.
Definition: Console.C:384
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
const ExecFlagType EXEC_FINAL
static std::string outputNorm(const Real &old_norm, const Real &norm)
A helper function for outputting norms in color.
Definition: Console.C:507
PetscInt _nonlinear_iter
Current non-linear iteration returned from PETSc.
Definition: PetscOutput.h:49
const ExecFlagType EXEC_INITIAL

◆ outputElementalVariables()

void AdvancedOutput::outputElementalVariables ( )
protectedvirtualinherited

Performs output of elemental nonlinear variables The child class must define this method to output the nonlinear variables as desired.

See also
Exodus::outputElementalVariables

Reimplemented in Exodus.

Definition at line 192 of file AdvancedOutput.C.

Referenced by AdvancedOutput::output().

193 {
194  mooseError(
195  "Individual output of elemental variables is not support for this output object named '",
196  name(),
197  "'");
198 }
void mooseError(Args &&... args) const
Definition: MooseObject.h:144
const std::string & name() const
Get the name of the object.
Definition: MooseObject.h:56

◆ outputInput()

void Console::outputInput ( )
overrideprotectedvirtual

Print the input file at the beginning of the simulation.

Reimplemented from AdvancedOutput.

Definition at line 525 of file Console.C.

Referenced by output().

526 {
527  if (!_write_screen && !_write_file)
528  return;
529 
530  std::ostringstream oss;
531  oss << "--- " << _app.getInputFileName()
532  << " ------------------------------------------------------";
534  _console << oss.str() << '\n';
535 }
bool _write_screen
Flag for controlling outputting console information to screen.
Definition: Console.h:168
void printInputFile(std::ostream &out)
This method uses the Actions in the warehouse to reproduce the input file.
std::string getInputFileName() const
Returns the input file name that was set with setInputFileName.
Definition: MooseApp.h:154
ActionWarehouse & actionWarehouse()
Definition: MooseApp.h:140
bool _write_file
Flag for controlling outputting console information to a file.
Definition: Console.h:165
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.

◆ outputNodalVariables()

void AdvancedOutput::outputNodalVariables ( )
protectedvirtualinherited

Performs output of nodal nonlinear variables The child class must define this method to output the nonlinear variables as desired.

See also
Exodus::outputNodalVariables

Reimplemented in Exodus.

Definition at line 184 of file AdvancedOutput.C.

Referenced by AdvancedOutput::output().

185 {
186  mooseError("Individual output of nodal variables is not support for the output object named '",
187  name(),
188  "'");
189 }
void mooseError(Args &&... args) const
Definition: MooseObject.h:144
const std::string & name() const
Get the name of the object.
Definition: MooseObject.h:56

◆ outputNorm()

std::string Console::outputNorm ( const Real &  old_norm,
const Real &  norm 
)
static

A helper function for outputting norms in color.

Parameters
old_normThe old residual norm to compare against
normThe current residual norm

Definition at line 507 of file Console.C.

Referenced by output(), PicardSolve::solve(), and PicardSolve::solveStep().

508 {
509  std::string color = COLOR_GREEN;
510 
511  // Red if the residual went up... or if the norm is nan
512  if (norm != norm || norm > old_norm)
513  color = COLOR_RED;
514  // Yellow if change is less than 5%
515  else if ((old_norm - norm) / old_norm <= 0.05)
516  color = COLOR_YELLOW;
517 
518  std::stringstream oss;
519  oss << std::scientific << color << norm << COLOR_DEFAULT;
520 
521  return oss.str();
522 }

◆ outputPostprocessors()

void Console::outputPostprocessors ( )
overrideprotectedvirtual

Prints the postprocessor table to the screen.

Reimplemented from TableOutput.

Definition at line 538 of file Console.C.

Referenced by output().

539 {
541 
543  {
544  std::stringstream oss;
545  oss << "\nPostprocessor Values:\n";
548  _console << oss.str() << '\n';
549  }
550 }
MooseEnum _fit_mode
The FormattedTable fit mode.
Definition: Console.h:159
FormattedTable & _postprocessor_table
Table containing postprocessor data.
Definition: TableOutput.h:67
bool empty() const
Returns a boolean value based on whether the FormattedTable contains data or not. ...
unsigned int _max_rows
The max number of table rows.
Definition: Console.h:156
virtual void outputPostprocessors() override
Populates the tables with postprocessor values.
Definition: TableOutput.C:86
void printTable(std::ostream &out, unsigned int last_n_entries=0)
Methods for dumping the table to the stream - either by filename or by stream handle.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
void sortColumns()
Sorts columns alphabetically.

◆ outputScalarVariables()

void Console::outputScalarVariables ( )
overrideprotectedvirtual

Prints the aux scalar variables table to the screen.

Reimplemented from TableOutput.

Definition at line 553 of file Console.C.

Referenced by output().

554 {
556 
557  if (!_scalar_table.empty())
558  {
559  std::stringstream oss;
560  oss << "\nScalar Variable Values:\n";
561  if (processor_id() == 0)
562  {
565  }
566  _console << oss.str() << '\n';
567  }
568 }
MooseEnum _fit_mode
The FormattedTable fit mode.
Definition: Console.h:159
bool empty() const
Returns a boolean value based on whether the FormattedTable contains data or not. ...
FormattedTable & _scalar_table
Table containing scalar aux variables.
Definition: TableOutput.h:76
unsigned int _max_rows
The max number of table rows.
Definition: Console.h:156
void printTable(std::ostream &out, unsigned int last_n_entries=0)
Methods for dumping the table to the stream - either by filename or by stream handle.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
void sortColumns()
Sorts columns alphabetically.
virtual void outputScalarVariables() override
Populates the tables with scalar aux variables.
Definition: TableOutput.C:147

◆ outputStep()

void Output::outputStep ( const ExecFlagType type)
virtualinherited

A single call to this function should output all the necessary data for a single timestep.

Parameters
typeThe type execution flag (see Moose.h)
See also
outputNodalVariables outputElementalVariables outputScalarVariables outputPostprocessors

Reimplemented in OversampleOutput.

Definition at line 165 of file Output.C.

Referenced by PetscOutput::petscLinearOutput(), and PetscOutput::petscNonlinearOutput().

166 {
167  // Output is not allowed
168  if (!_allow_output && type != EXEC_FORCED)
169  return;
170 
171  // If recovering disable output of initial condition, it was already output
172  if (type == EXEC_INITIAL && _app.isRecovering())
173  return;
174 
175  // Return if the current output is not on the desired interval
176  if (type != EXEC_FINAL && !onInterval())
177  return;
178 
179  // Call the output method
180  if (shouldOutput(type))
181  {
182  TIME_SECTION(_output_step_timer);
183  output(type);
184  }
185 }
const ExecFlagType EXEC_FORCED
virtual bool onInterval()
Returns true if the output interval is satisfied.
Definition: Output.C:199
virtual void output(const ExecFlagType &type)=0
Overload this function with the desired output activities.
virtual bool shouldOutput(const ExecFlagType &type)
Handles logic for determining if a step should be output.
Definition: Output.C:188
const std::string & type() const
Get the type of this object.
Definition: MooseObject.h:50
bool _allow_output
Flag for disabling output.
Definition: Output.h:234
PerfID _output_step_timer
Timers.
Definition: Output.h:246
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174
bool isRecovering() const
Whether or not this is a "recover" calculation.
Definition: MooseApp.C:853
const ExecFlagType EXEC_FINAL
const ExecFlagType EXEC_INITIAL

◆ outputSystemInformation()

void Console::outputSystemInformation ( )
overrideprotectedvirtual

Print system information.

Reimplemented from AdvancedOutput.

Definition at line 571 of file Console.C.

Referenced by initialSetup(), and output().

572 {
573  if (_system_info_flags.contains("framework"))
575 
576  if (_system_info_flags.contains("mesh"))
578 
579  if (_system_info_flags.contains("nonlinear"))
580  {
582  if (!output.empty())
583  _console << "Nonlinear System:\n" << output;
584  }
585 
586  if (_system_info_flags.contains("aux"))
587  {
589  if (!output.empty())
590  _console << "Auxiliary System:\n" << output;
591  }
592 
593  if (_system_info_flags.contains("relationship"))
594  {
596  if (!output.empty())
597  _console << "Relationship Managers:\n" << output;
598  }
599 
600  if (_system_info_flags.contains("execution"))
602 
603  if (_system_info_flags.contains("output"))
605 }
std::string outputNonlinearSystemInformation(FEProblemBase &problem)
Output the Nonlinear system information.
Definition: ConsoleUtils.C:114
std::string outputExecutionInformation(const MooseApp &app, FEProblemBase &problem)
Output execution information.
Definition: ConsoleUtils.C:242
std::string outputAuxiliarySystemInformation(FEProblemBase &problem)
Output the Auxiliary system information.
Definition: ConsoleUtils.C:108
std::string outputOutputInformation(MooseApp &app)
Output the output information.
Definition: ConsoleUtils.C:270
virtual void output(const ExecFlagType &type) override
Customizes the order of output for the various components as well as adds additional output such as t...
Definition: Console.C:293
std::string outputMeshInformation(FEProblemBase &problem, bool verbose=true)
Output the mesh information.
Definition: ConsoleUtils.C:54
bool contains(const std::string &value) const
Contains methods for seeing if a value is in the MultiMooseEnum.
MultiMooseEnum _system_info_flags
Flags for controlling the what simulations information is shown.
Definition: Console.h:229
FEProblemBase * _problem_ptr
Pointer the the FEProblemBase object for output object (use this)
Definition: Output.h:168
std::string outputFrameworkInformation(const MooseApp &app)
Outputs framework information.
Definition: ConsoleUtils.C:35
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string outputRelationshipManagerInformation(const MooseApp &app)
Output action RelationshipManager information.
Definition: ConsoleUtils.C:222

◆ outputVectorPostprocessors()

virtual void Console::outputVectorPostprocessors ( )
inlineoverrideprotectedvirtual

Not implemented.

Reimplemented from TableOutput.

Definition at line 118 of file Console.h.

119  {
120  mooseError("Can't currently output VectorPostprocessors to the screen");
121  };
void mooseError(Args &&... args) const
Definition: MooseObject.h:144

◆ paramError()

template<typename... Args>
void MooseObject::paramError ( const std::string &  param,
Args...  args 
)
inlineinherited

Emits an error prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message.

If this object's parameters were not created directly by the Parser, then this function falls back to the normal behavior of mooseError - only printing a message using the given args.

Definition at line 105 of file MooseObject.h.

Referenced by ADIntegratedBCTempl< T, compute_stage >::ADIntegratedBCTempl(), ADKernelTempl< T, compute_stage >::ADKernelTempl(), DGKernelBase::DGKernelBase(), ElementValueSampler::ElementValueSampler(), StackGenerator::generate(), StitchedMeshGenerator::generate(), MultiApp::init(), IntegratedBC::IntegratedBC(), Kernel::Kernel(), NodalBC::NodalBC(), NodalEqualValueConstraint::NodalEqualValueConstraint(), NodalKernel::NodalKernel(), NodalValueSampler::NodalValueSampler(), RandomIC::RandomIC(), MultiAppCopyTransfer::transfer(), and TransientMultiApp::TransientMultiApp().

105  {
106  auto prefix = param + ": ";
107  if (!_pars.inputLocation(param).empty())
108  prefix = _pars.inputLocation(param) + ": (" + _pars.paramFullpath(param) + "):\n";
109  mooseError(prefix, args...);
110  }
void mooseError(Args &&... args) const
Definition: MooseObject.h:144
const std::string & inputLocation(const std::string &param) const
Get/set a string representing the location in the input text the parameter originated from (i...
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171
const std::string & paramFullpath(const std::string &param) const
Get/set a string representing the full HIT parameter path from the input file (e.g.

◆ parameters()

const InputParameters& MooseObject::parameters ( ) const
inlineinherited

Get the parameters of the object.

Returns
The parameters of the object

Definition at line 62 of file MooseObject.h.

Referenced by FEProblemBase::addADJacobianMaterial(), FEProblemBase::addADResidualMaterial(), DumpObjectsProblem::addAuxKernel(), FEProblemBase::addAuxKernel(), DumpObjectsProblem::addAuxScalarKernel(), FEProblemBase::addAuxScalarKernel(), DumpObjectsProblem::addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), DumpObjectsProblem::addConstraint(), FEProblemBase::addConstraint(), FEProblemBase::addDamper(), DumpObjectsProblem::addDGKernel(), FEProblemBase::addDGKernel(), DumpObjectsProblem::addDiracKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addDistribution(), DumpObjectsProblem::addFunction(), FEProblemBase::addFunction(), FEProblemBase::addIndicator(), DumpObjectsProblem::addInitialCondition(), FEProblemBase::addInitialCondition(), DumpObjectsProblem::addInterfaceKernel(), FEProblemBase::addInterfaceKernel(), DumpObjectsProblem::addKernel(), FEProblemBase::addKernel(), FEProblem::addLineSearch(), FEProblemBase::addMarker(), DumpObjectsProblem::addMaterial(), FEProblemBase::addMaterial(), FEProblemBase::addMaterialHelper(), FEProblemBase::addMultiApp(), DumpObjectsProblem::addNodalKernel(), FEProblemBase::addNodalKernel(), FEProblemBase::addOutput(), FEProblemBase::addPostprocessor(), FEProblemBase::addPredictor(), FEProblemBase::addSampler(), DumpObjectsProblem::addScalarKernel(), FEProblemBase::addScalarKernel(), FEProblemBase::addTimeIntegrator(), FEProblemBase::addTransfer(), FEProblemBase::addUserObject(), FEProblemBase::addVectorPostprocessor(), AdvancedOutput::AdvancedOutput(), assemble_l2(), Moose::assemble_matrix(), AuxKernel::AuxKernel(), AuxScalarKernel::AuxScalarKernel(), BoundsAux::BoundsAux(), LibmeshPartitioner::clone(), OversampleOutput::cloneMesh(), Moose::compute_bounds(), Moose::compute_jacobian(), Moose::compute_nearnullspace(), Moose::compute_nullspace(), Moose::compute_postcheck(), Moose::compute_transpose_nullspace(), Console(), DumpObjectsProblem::deduceNecessaryParameters(), DumpObjectsProblem::dumpObjectHelper(), EigenProblem::EigenProblem(), Eigenvalue::Eigenvalue(), Executioner::Executioner(), Exodus::Exodus(), FEProblem::FEProblem(), GapValueAux::GapValueAux(), MooseObject::getCheckedPointerParam(), MooseMesh::init(), BlockRestrictable::initializeBlockRestrictable(), FEProblemBase::initNullSpaceVectors(), InterfaceKernel::InterfaceKernel(), isValid(), LayeredSideIntegral::LayeredSideIntegral(), MooseVariableInterface< Real >::MooseVariableInterface(), NearestPointBase< LayeredAverage >::NearestPointBase(), NodeFaceConstraint::NodeFaceConstraint(), PenetrationAux::PenetrationAux(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), MultiAppProjectionTransfer::projectSolution(), RandomIC::RandomIC(), InputParameterWarehouse::removeInputParameters(), FEProblem::setInputParametersFEProblem(), FEProblemBase::setInputParametersFEProblem(), DumpObjectsProblem::stringifyParameters(), and Transient::Transient().

62 { return _pars; }
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171

◆ paramInfo()

template<typename... Args>
void MooseObject::paramInfo ( const std::string &  param,
Args...  args 
)
inlineinherited

Emits an informational message prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message.

If this object's parameters were not created directly by the Parser, then this function falls back to the normal behavior of mooseInfo - only printing a message using the given args.

Definition at line 135 of file MooseObject.h.

Referenced by TransientMultiApp::TransientMultiApp().

136  {
137  auto prefix = param + ": ";
138  if (!_pars.inputLocation(param).empty())
139  prefix = _pars.inputLocation(param) + ": (" + _pars.paramFullpath(param) + "):\n";
140  mooseInfo(prefix, args...);
141  }
const std::string & inputLocation(const std::string &param) const
Get/set a string representing the location in the input text the parameter originated from (i...
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171
void mooseInfo(Args &&... args) const
Definition: MooseObject.h:164
const std::string & paramFullpath(const std::string &param) const
Get/set a string representing the full HIT parameter path from the input file (e.g.

◆ paramWarning()

template<typename... Args>
void MooseObject::paramWarning ( const std::string &  param,
Args...  args 
)
inlineinherited

Emits a warning prefixed with the file and line number of the given param (from the input file) along with the full parameter path+name followed by the given args as the message.

If this object's parameters were not created directly by the Parser, then this function falls back to the normal behavior of mooseWarning - only printing a message using the given args.

Definition at line 119 of file MooseObject.h.

120  {
121  auto prefix = param + ": ";
122  if (!_pars.inputLocation(param).empty())
123  prefix = _pars.inputLocation(param) + ": (" + _pars.paramFullpath(param) + "):\n";
124  mooseWarning(prefix, args...);
125  }
void mooseWarning(Args &&... args) const
Definition: MooseObject.h:152
const std::string & inputLocation(const std::string &param) const
Get/set a string representing the location in the input text the parameter originated from (i...
const InputParameters & _pars
Parameters of this object, references the InputParameters stored in the InputParametersWarehouse.
Definition: MooseObject.h:171
const std::string & paramFullpath(const std::string &param) const
Get/set a string representing the full HIT parameter path from the input file (e.g.

◆ petscSetupOutput()

void Console::petscSetupOutput ( )
static

Output string for setting up PETSC output.

Definition at line 655 of file Console.C.

Referenced by Moose::PetscSupport::petscSetupOutput().

656 {
657  char c[] = {
658  32, 47, 94, 92, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
659  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
660  32, 32, 32, 32, 32, 32, 32, 47, 94, 92, 13, 10, 124, 32, 32, 32, 92, 95, 47,
661  94, 92, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
662  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 94, 92, 95, 47,
663  32, 32, 32, 124, 13, 10, 124, 32, 32, 32, 32, 32, 32, 32, 32, 92, 95, 47, 94,
664  92, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
665  32, 32, 32, 47, 94, 92, 95, 47, 32, 32, 32, 32, 32, 32, 32, 32, 124, 13, 10,
666  32, 92, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 92, 95, 47, 94, 92,
667  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 94, 92, 95, 47, 32, 32, 32,
668  32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 13, 10, 32, 32, 92, 95, 95, 32, 32,
669  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 92, 95, 95, 95, 45, 45, 45,
670  95, 95, 95, 47, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 95,
671  95, 47, 13, 10, 32, 32, 32, 32, 32, 45, 45, 45, 95, 95, 95, 32, 32, 32, 32,
672  32, 32, 32, 32, 32, 47, 32, 32, 32, 32, 32, 32, 32, 92, 32, 32, 32, 32, 32,
673  32, 32, 32, 32, 95, 95, 95, 45, 45, 45, 13, 10, 32, 32, 32, 32, 32, 32, 32,
674  32, 32, 32, 32, 45, 45, 45, 95, 95, 95, 32, 32, 124, 32, 32, 32, 32, 32, 32,
675  32, 32, 32, 124, 32, 32, 95, 95, 95, 45, 45, 45, 13, 10, 32, 32, 32, 32, 32,
676  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 45, 45, 124, 32, 32, 95, 32,
677  32, 32, 95, 32, 32, 124, 45, 45, 13, 10, 32, 32, 32, 32, 32, 32, 32, 32, 32,
678  32, 32, 32, 32, 32, 32, 32, 32, 32, 124, 32, 32, 124, 111, 124, 32, 124, 111, 124,
679  32, 32, 124, 13, 10, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
680  32, 32, 32, 47, 32, 32, 32, 32, 45, 32, 32, 32, 45, 32, 32, 32, 32, 92, 13,
681  10, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 124, 32,
682  32, 32, 32, 32, 32, 95, 95, 95, 32, 32, 32, 32, 32, 32, 124, 13, 10, 32, 32,
683  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 32, 32, 32,
684  45, 45, 32, 32, 32, 45, 45, 32, 32, 32, 32, 32, 92, 13, 10, 32, 32, 32, 32,
685  32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 32, 32, 32, 32, 32, 32, 32,
686  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 92, 13, 10, 32, 32, 32, 32,
687  32, 32, 32, 32, 32, 32, 32, 32, 124, 32, 32, 32, 32, 32, 32, 32, 47, 92, 32,
688  32, 32, 32, 32, 47, 92, 32, 32, 32, 32, 32, 32, 32, 124, 13, 10, 32, 32, 32,
689  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 92, 32, 32, 92, 32, 32, 32, 32, 32,
690  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 47, 13, 10, 32, 32, 32,
691  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 92, 32, 32, 92, 95, 95, 95, 95,
692  95, 95, 95, 95, 95, 95, 95, 95, 32, 47, 32, 32, 47, 92, 13, 10, 32, 32, 32,
693  32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 92, 32, 32, 32, 32, 32, 32,
694  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 92, 13, 10, 32, 32,
695  32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 32, 32, 92, 32, 32, 32, 32,
696  32, 39, 95, 95, 95, 39, 32, 32, 32, 32, 32, 47, 32, 32, 32, 32, 92, 13, 10,
697  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 92, 32, 32, 32, 32, 32, 92, 32,
698  45, 45, 95, 95, 45, 45, 45, 95, 95, 45, 45, 32, 47, 32, 32, 32, 32, 32, 47,
699  92, 13, 10, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 92, 47, 32, 32,
700  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
701  92, 47, 32, 32, 92, 13, 10, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 32,
702  47, 32, 32, 32, 32, 32, 32, 32, 77, 46, 79, 46, 79, 46, 83, 46, 69, 32, 32,
703  32, 32, 32, 32, 32, 92, 32, 32, 32, 92, 13, 10, 32, 32, 32, 32, 32, 32, 32,
704  47, 32, 32, 32, 124, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
705  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 124, 32, 32, 32, 92, 13, 10, 32,
706  32, 32, 32, 32, 32, 124, 32, 32, 32, 32, 124, 45, 45, 45, 45, 45, 45, 45, 45,
707  45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, 124, 32,
708  32, 32, 32, 124, 13, 10, 32, 32, 32, 32, 32, 32, 32, 92, 32, 32, 32, 32, 92,
709  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
710  32, 32, 32, 32, 47, 32, 32, 32, 32, 47, 13, 10, 32, 32, 32, 32, 32, 32, 32,
711  32, 32, 92, 92, 32, 92, 95, 92, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
712  32, 32, 32, 32, 32, 32, 32, 32, 47, 95, 47, 32, 47, 47, 13, 10, 32, 32, 32,
713  32, 32, 32, 32, 32, 32, 32, 32, 45, 45, 32, 32, 92, 32, 32, 32, 32, 32, 32,
714  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 47, 32, 32, 45, 45, 13, 10, 32,
715  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 124, 32, 32, 45,
716  45, 45, 95, 95, 95, 95, 95, 45, 45, 45, 32, 32, 124, 13, 10, 32, 32, 32, 32,
717  32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 124, 32, 32, 32, 32, 32, 124,
718  32, 32, 32, 124, 32, 32, 32, 32, 32, 124, 13, 10, 32, 32, 32, 32, 32, 32, 32,
719  32, 32, 32, 32, 32, 32, 32, 32, 32, 124, 32, 32, 32, 32, 32, 124, 32, 32, 32,
720  124, 32, 32, 32, 32, 32, 124, 13, 10, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
721  32, 32, 32, 32, 32, 47, 32, 86, 32, 32, 32, 32, 32, 92, 32, 47, 32, 32, 32,
722  32, 86, 32, 32, 92, 13, 10, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32,
723  32, 32, 32, 124, 95, 124, 95, 95, 95, 95, 95, 124, 32, 124, 95, 95, 95, 95, 124,
724  95, 95, 124};
725  Moose::out << std::string(c) << std::endl << std::endl;
726 }

◆ registerTimedSection()

PerfID PerfGraphInterface::registerTimedSection ( const std::string &  section_name,
const unsigned int  level 
)
protectedinherited

Call to register a named section for timing.

Parameters
section_nameThe name of the code section to be timed
levelThe importance of the timer - lower is more important (0 will always come out)
Returns
The ID of the section - use when starting timing

Definition at line 50 of file PerfGraphInterface.C.

51 {
52  if (_prefix != "")
53  return _perf_graph.registerSection(_prefix + "::" + section_name, level);
54  else
55  return _perf_graph.registerSection(section_name, level);
56 }
PerfGraph & _perf_graph
The performance graph to add to.
std::string _prefix
A prefix to use for all sections.
PerfID registerSection(const std::string &section_name, unsigned int level)
Registers a named section of code.
Definition: PerfGraph.C:42

◆ residualSetup()

void SetupInterface::residualSetup ( )
virtualinherited

Gets called just before the residual is computed and before this object is asked to do its job.

Definition at line 57 of file SetupInterface.C.

58 {
59 }

◆ setFileNumber()

void FileOutput::setFileNumber ( unsigned int  num)
inherited

Sets the file number manually.

This method was implemented for the MultiApp system, particularly when reseting an application and a new output file is desired after the reset.

Definition at line 178 of file FileOutput.C.

Referenced by OutputWarehouse::setFileNumbers().

179 {
180  _file_num = num;
181 }
unsigned int & _file_num
A file number counter, initialized to 0 (this must be controlled by the child class, see Exodus)
Definition: FileOutput.h:85

◆ shouldOutput()

bool AdvancedOutput::shouldOutput ( const ExecFlagType type)
protectedvirtualinherited

Handles logic for determining if a step should be output.

Returns
True if a call if output should be preformed

Reimplemented from FileOutput.

Definition at line 240 of file AdvancedOutput.C.

Referenced by Nemesis::output(), and OversampleOutput::outputStep().

241 {
242  if (!checkFilename())
243  return false;
244 
245  if (hasOutput(type))
246  return true;
247  else
248  return Output::shouldOutput(type);
249 }
virtual bool hasOutput()
Returns true if any of the other has methods return true.
virtual bool shouldOutput(const ExecFlagType &type)
Handles logic for determining if a step should be output.
Definition: Output.C:188
const std::string & type() const
Get the type of this object.
Definition: MooseObject.h:50
bool checkFilename()
Checks the filename for output Checks the output against the &#39;output_if_base_contians&#39; list...
Definition: FileOutput.C:147

◆ subdomainSetup()

void SetupInterface::subdomainSetup ( )
virtualinherited

Gets called when the subdomain changes (i.e.

in a Jacobian or residual loop) and before this object is asked to do its job

Reimplemented in Material, Constraint, GeneralUserObject, NodalUserObject, and ThreadedGeneralUserObject.

Definition at line 62 of file SetupInterface.C.

63 {
64 }

◆ systemInfoFlags()

MultiMooseEnum& Console::systemInfoFlags ( )
inline

Return system information flags.

Definition at line 86 of file Console.h.

87  {
89  mooseError(
90  "accessing console system information flags is not allowed after console initial setup");
91  return _system_info_flags;
92  }
void mooseError(Args &&... args) const
Definition: MooseObject.h:144
bool _allow_changing_sysinfo_flag
A boolean for protecting _system_info_flags from being changed undesirably.
Definition: Console.h:235
MultiMooseEnum _system_info_flags
Flags for controlling the what simulations information is shown.
Definition: Console.h:229

◆ time()

Real PetscOutput::time ( )
overridevirtualinherited

Get the output time.

This outputter enables the ability to perform output on the nonlinear and linear iterations performed by PETSc. To separate theses outputs within the output a pseudo time is defined, this function provides this time and it should be used in place of _time from Outputter.

Reimplemented from Output.

Definition at line 253 of file PetscOutput.C.

Referenced by FileOutput::FileOutput(), Tecplot::output(), Nemesis::output(), Exodus::outputEmptyTimestep(), Exodus::outputNodalVariables(), TableOutput::outputPostprocessors(), TableOutput::outputScalarVariables(), and writeTimestepInformation().

254 {
256  return _nonlinear_time;
257  else if (_on_linear_residual)
258  return _linear_time;
259  else
260  return Output::time();
261 }
bool _on_linear_residual
True if current output calls is on the linear residual (used by time())
Definition: PetscOutput.h:89
Real _linear_time
Psuedo linear time.
Definition: PetscOutput.h:83
bool _on_nonlinear_residual
True if current output call is on the non-linear residual (used by time())
Definition: PetscOutput.h:92
Real _nonlinear_time
The psuedo non-linear time.
Definition: PetscOutput.h:77
virtual Real time()
Get the output time.
Definition: Output.C:223

◆ timeOld()

Real Output::timeOld ( )
virtualinherited

Get the old output time.

Returns
The old output time, which may be different than the simulation time
See also
time()

Definition at line 232 of file Output.C.

Referenced by writeTimestepInformation().

233 {
234  if (_transient)
235  return _time_old;
236  else
237  return _t_step - 1;
238 }
Real & _time_old
The old time.
Definition: Output.h:192
int & _t_step
The current time step.
Definition: Output.h:195
bool _transient
Transient flag (true = transient)
Definition: Output.h:171

◆ timeStep()

int Output::timeStep ( )
virtualinherited

Get the current time step.

Definition at line 259 of file Output.C.

Referenced by Checkpoint::filename(), CSV::getVectorPostprocessorFileName(), and writeTimestepInformation().

260 {
261  return _t_step;
262 }
int & _t_step
The current time step.
Definition: Output.h:195

◆ timestepSetup()

void Console::timestepSetup ( )
overridevirtual

Gets called at the beginning of the timestep before this object is asked to do its job.

Reimplemented from SetupInterface.

Definition at line 287 of file Console.C.

288 {
290 }
void writeTimestepInformation()
Prints the time step information for the screen output.
Definition: Console.C:384

◆ type()

const std::string& MooseObject::type ( ) const
inlineinherited

Get the type of this object.

Returns
the name of the type of this object

Definition at line 50 of file MooseObject.h.

Referenced by DumpObjectsProblem::addAuxKernel(), DumpObjectsProblem::addAuxScalarKernel(), FEProblemBase::addAuxScalarVariable(), DumpObjectsProblem::addAuxVariable(), DisplacedProblem::addAuxVariable(), FEProblemBase::addAuxVariable(), DumpObjectsProblem::addBoundaryCondition(), DumpObjectsProblem::addConstraint(), DumpObjectsProblem::addDGKernel(), DumpObjectsProblem::addDiracKernel(), FEProblemBase::addDistribution(), DumpObjectsProblem::addFunction(), FEProblemBase::addFunction(), DumpObjectsProblem::addInitialCondition(), DumpObjectsProblem::addInterfaceKernel(), DumpObjectsProblem::addKernel(), DumpObjectsProblem::addMaterial(), DumpObjectsProblem::addNodalKernel(), FEProblemBase::addPredictor(), FEProblemBase::addSampler(), DumpObjectsProblem::addScalarKernel(), FEProblemBase::addScalarVariable(), PhysicsBasedPreconditioner::addSystem(), FEProblemBase::addTimeIntegrator(), DumpObjectsProblem::addVariable(), DisplacedProblem::addVariable(), FEProblemBase::addVariable(), FEProblemBase::advanceMultiApps(), FEProblemBase::backupMultiApps(), MooseMesh::buildRefinementAndCoarseningMaps(), FEProblemBase::computeAuxiliaryKernels(), DGKernel::computeElemNeighJacobian(), ElemElemConstraint::computeElemNeighJacobian(), InterfaceKernel::computeElemNeighJacobian(), DGKernel::computeElemNeighResidual(), ElemElemConstraint::computeElemNeighResidual(), InterfaceKernel::computeElemNeighResidual(), FEProblemBase::computeMultiAppsDT(), DGKernel::computeOffDiagElemNeighJacobian(), InterfaceKernel::computeOffDiagElemNeighJacobian(), DGConvection::computeQpJacobian(), CoupledTiedValueConstraint::computeQpJacobian(), TiedValueConstraint::computeQpJacobian(), DGDiffusion::computeQpJacobian(), LinearNodalConstraint::computeQpJacobian(), EqualValueBoundaryConstraint::computeQpJacobian(), EqualValueEmbeddedConstraint::computeQpJacobian(), CoupledTiedValueConstraint::computeQpOffDiagJacobian(), EqualValueEmbeddedConstraint::computeQpOffDiagJacobian(), DGConvection::computeQpResidual(), CoupledTiedValueConstraint::computeQpResidual(), TiedValueConstraint::computeQpResidual(), LinearNodalConstraint::computeQpResidual(), DGDiffusion::computeQpResidual(), EqualValueBoundaryConstraint::computeQpResidual(), EqualValueEmbeddedConstraint::computeQpResidual(), FEProblemBase::computeUserObjects(), DisplacedProblem::createQRules(), FEProblemBase::createQRules(), DumpObjectsProblem::deduceNecessaryParameters(), DumpObjectsProblem::dumpObjectHelper(), FEProblemBase::duplicateVariableCheck(), FEProblemBase::execMultiApps(), FEProblemBase::execMultiAppTransfers(), FEProblemBase::execTransfers(), FEProblemBase::finishMultiAppStep(), ElementSubdomainIDGenerator::generate(), ElementGenerator::getElemType(), FEProblemBase::getMaterial(), FEProblemBase::getMaterialData(), FEProblemBase::getTransfers(), FEProblemBase::hasMultiApps(), AdvancedOutput::hasOutput(), FEProblemBase::incrementMultiAppTStep(), AdvancedOutput::initAvailableLists(), SolutionUserObject::initialSetup(), AdvancedOutput::initShowHideLists(), AssignElementSubdomainID::modify(), ControlOutput::output(), Gnuplot::output(), CSV::output(), Exodus::output(), output(), Nemesis::output(), AdvancedOutput::output(), OversampleOutput::outputStep(), Output::outputStep(), FEProblemBase::outputStep(), FEProblemBase::restoreMultiApps(), FEProblemBase::setCoupling(), PerfGraphOutput::shouldOutput(), FileOutput::shouldOutput(), Output::shouldOutput(), AdvancedOutput::shouldOutput(), DisplacedProblem::updateGeomSearch(), FEProblemBase::updateGeomSearch(), and AdvancedOutput::wantOutput().

50 { return _type; }
const std::string & _type
The type of this object (the Class name)
Definition: MooseObject.h:177

◆ write()

void Console::write ( std::string  message,
bool  indent = true 
)
protected

Write message to screen and/or file.

Parameters
messageThe desired message
indentTrue if multiapp indenting is desired

Definition at line 625 of file Console.C.

Referenced by initialSetup(), mooseConsole(), output(), and ~Console().

626 {
627  // Do nothing if the message is empty, writing empty strings messes with multiapp indenting
628  if (message.empty())
629  return;
630 
631  // Write the message to file
632  if (_write_file)
633  _file_output_stream << message;
634 
635  // Apply MultiApp indenting
636  if (indent && _app.multiAppLevel() > 0)
637  MooseUtils::indentMessage(_app.name(), message);
638 
639  // Write message to the screen
640  if (_write_screen)
641  Moose::out << message;
642 }
std::string indent(unsigned int spaces)
Create empty string for indenting.
Definition: ConsoleUtils.C:29
const std::string & name() const
Get the name of the object.
Definition: MooseApp.h:73
void indentMessage(const std::string &prefix, std::string &message, const char *color=COLOR_CYAN)
Indents the supplied message given the prefix and color.
Definition: MooseUtils.C:479
unsigned int multiAppLevel() const
The MultiApp Level.
Definition: MooseApp.h:511
bool _write_screen
Flag for controlling outputting console information to screen.
Definition: Console.h:168
std::stringstream _file_output_stream
Stream for storing information to be written to a file.
Definition: Console.h:174
bool _write_file
Flag for controlling outputting console information to a file.
Definition: Console.h:165
MooseApp & _app
The MooseApp this object is associated with.
Definition: MooseObject.h:174

◆ writeStreamToFile()

void Console::writeStreamToFile ( bool  append = true)
protected

Write the file stream to the file.

Parameters
appendToggle for appending the file

This helper function writes the _file_output_stream to the file and clears the stream, by default the file is appended. This does nothing if 'output_file' is false.

Definition at line 357 of file Console.C.

Referenced by initialSetup(), output(), and ~Console().

358 {
359  if (!_write_file)
360  return;
361 
362  // Create the stream
363  std::ofstream output;
364 
365  // Open the file
366  if (append)
367  output.open(filename().c_str(), std::ios::app | std::ios::out);
368  else
369  output.open(filename().c_str(), std::ios::trunc);
370 
371  if (output.fail())
372  mooseError("Unable to open file ", filename());
373 
374  std::string s = _file_output_stream.str();
375  // Write contents of file output stream and close the file
377  output.close();
378 
379  // Clear the file output stream
380  _file_output_stream.str("");
381 }
void mooseError(Args &&... args) const
Definition: MooseObject.h:144
virtual void output(const ExecFlagType &type) override
Customizes the order of output for the various components as well as adds additional output such as t...
Definition: Console.C:293
virtual std::string filename() override
Creates the output file name Appends the user-supplied &#39;file_base&#39; input parameter with a &#39;...
Definition: Console.C:281
std::stringstream _file_output_stream
Stream for storing information to be written to a file.
Definition: Console.h:174
std::string & removeColor(std::string &msg)
remove ANSI escape sequences for teminal color from msg
Definition: MooseUtils.C:471
bool _write_file
Flag for controlling outputting console information to a file.
Definition: Console.h:165

◆ writeTimestepInformation()

void Console::writeTimestepInformation ( )
protected

Prints the time step information for the screen output.

Definition at line 384 of file Console.C.

Referenced by initialSetup(), output(), and timestepSetup().

385 {
386  // Stream to build the time step information
387  std::stringstream oss;
388 
389  // Write timestep data for transient executioners
390  if (_transient)
391  {
392  // Write time step and time information
393  oss << "\nTime Step " << timeStep();
394 
395  // Set precision
396  if (_precision > 0)
397  oss << std::setw(_precision) << std::setprecision(_precision) << std::setfill('0')
398  << std::showpoint;
399 
400  // Show scientific notation
401  if (_scientific_time)
402  oss << std::scientific;
403 
404  // Print the time
405  oss << ", time = " << time() << '\n';
406 
407  // Show old time information, if desired
408  if (_verbose)
409  oss << std::right << std::setw(21) << std::setfill(' ') << "old time = " << std::left
410  << timeOld() << '\n';
411 
412  // Show the time delta information
413  oss << std::right << std::setw(21) << std::setfill(' ') << "dt = " << std::left << dt() << '\n';
414 
415  // Show the old time delta information, if desired
416  if (_verbose)
417  oss << std::right << std::setw(21) << std::setfill(' ') << "old dt = " << _dt_old << '\n';
418  }
419 
420  // Output to the screen
421  _console << oss.str() << std::flush;
422 }
unsigned int _precision
Number of significant digits.
Definition: Console.h:201
virtual Real dt()
Get the current time step size.
Definition: Output.C:241
Real & _dt_old
Old time step delta.
Definition: Output.h:201
virtual Real time() override
Get the output time.
Definition: PetscOutput.C:253
bool _verbose
Flag for writing detailed time step information.
Definition: Console.h:171
bool _transient
Transient flag (true = transient)
Definition: Output.h:171
virtual Real timeOld()
Get the old output time.
Definition: Output.C:232
bool _scientific_time
Toggle for outputting time in time and dt in scientific notation.
Definition: Console.h:162
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
virtual int timeStep()
Get the current time step.
Definition: Output.C:259

◆ writeVariableNorms()

void Console::writeVariableNorms ( )
protected

Print the L2-norms for each variable.

Definition at line 425 of file Console.C.

Referenced by output().

426 {
427  // If all_variable_norms is true, then so should outlier printing
430 
431  // if we are not priting anything, let's not waste time computing the norms below and just exit
432  // this call
433  if ((_all_variable_norms == false) && (_outlier_variable_norms == false))
434  return;
435 
436  // if it is an eigenvalue prolblem, we do not know to define RHS,
437  // and then we do not know how to compute variable norms
438  if (dynamic_cast<EigenProblem *>(_problem_ptr) != nullptr)
439  return;
440 
441  // Flag set when header prints
442  bool header = false;
443 
444  // String stream for variable norm information
445  std::ostringstream oss;
446 
447  // Get a references to the NonlinearSystem and libMesh system
449  System & sys = nl.system();
450 
451  // Storage for norm outputs
452  std::map<std::string, Real> other;
453  std::map<std::string, Real> outlier;
454 
455  // Average norm
456  unsigned int n_vars = sys.n_vars();
457  Real avg_norm = (nl.nonlinearNorm() * nl.nonlinearNorm()) / n_vars;
458 
459  // Compute the norms for each of the variables
460  for (unsigned int i = 0; i < n_vars; i++)
461  {
462  // Compute the norm and extract the variable name
463  Real var_norm = sys.calculate_norm(nl.RHS(), i, DISCRETE_L2);
464  var_norm *= var_norm; // use the norm squared
465  std::string var_name = sys.variable_name(i);
466 
467  // Outlier if the variable norm is greater than twice (default) of the average norm
468  if (_outlier_variable_norms && (var_norm > _outlier_multiplier[1] * avg_norm))
469  {
470  // Print the header
471  if (!header)
472  {
473  oss << "\nOutlier Variable Residual Norms:\n";
474  header = true;
475  }
476 
477  // Set the color, RED if the variable norm is 0.8 (default) of the total norm
478  std::string color = COLOR_YELLOW;
479  if (_outlier_variable_norms && (var_norm > _outlier_multiplier[0] * avg_norm * n_vars))
480  color = COLOR_RED;
481 
482  // Display the residual
483  oss << " " << var_name << ": " << std::scientific << color << std::sqrt(var_norm)
484  << COLOR_DEFAULT << '\n';
485  }
486 
487  // GREEN
488  else if (_all_variable_norms)
489  {
490  // Print the header if it doesn't already exist
491  if (!header)
492  {
493  oss << "\nVariable Residual Norms:\n";
494  header = true;
495  }
496  oss << " " << var_name << ": " << std::scientific << COLOR_GREEN << std::sqrt(var_norm)
497  << COLOR_DEFAULT << '\n';
498  }
499  }
500 
501  // Update the output streams
502  _console << oss.str();
503 }
NonlinearSystemBase & getNonlinearSystemBase()
bool _all_variable_norms
Flag for writing all variable norms.
Definition: Console.h:192
bool _outlier_variable_norms
Flag for writing outlier variable norms.
Definition: Console.h:195
NonlinearSystemBase * nl
Nonlinear system to be solved.
FEProblemBase * _problem_ptr
Pointer the the FEProblemBase object for output object (use this)
Definition: Output.h:168
virtual NumericVector< Number > & RHS()=0
std::vector< Real > _outlier_multiplier
Multipliers for coloring variable residual norms (default [2, 0.8])
Definition: Console.h:198
virtual System & system() override
Get the reference to the libMesh system.
Real nonlinearNorm() const
Return the last nonlinear norm.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.

Friends And Related Function Documentation

◆ OutputWarehouse

friend class OutputWarehouse
friend

Definition at line 231 of file Console.h.

Member Data Documentation

◆ _advanced_execute_on

OutputOnWarehouse Output::_advanced_execute_on
protectedinherited

◆ _all_data_table

FormattedTable& TableOutput::_all_data_table
protectedinherited

Table containing postprocessor values and scalar aux variables.

Definition at line 79 of file TableOutput.h.

Referenced by TableOutput::clear(), CSV::initialSetup(), Gnuplot::output(), CSV::output(), TableOutput::outputPostprocessors(), TableOutput::outputScalarVariables(), and TableOutput::TableOutput().

◆ _all_variable_norms

bool Console::_all_variable_norms
protected

Flag for writing all variable norms.

Definition at line 192 of file Console.h.

Referenced by writeVariableNorms().

◆ _allow_changing_sysinfo_flag

bool Console::_allow_changing_sysinfo_flag
private

A boolean for protecting _system_info_flags from being changed undesirably.

Definition at line 235 of file Console.h.

Referenced by initialSetup(), and systemInfoFlags().

◆ _allow_output

bool Output::_allow_output
protectedinherited

Flag for disabling output.

Definition at line 234 of file Output.h.

Referenced by Output::allowOutput(), OversampleOutput::outputStep(), and Output::outputStep().

◆ _app

MooseApp& MooseObject::_app
protectedinherited

The MooseApp this object is associated with.

Definition at line 174 of file MooseObject.h.

Referenced by GridPartitioner::_do_partition(), AB2PredictorCorrector::AB2PredictorCorrector(), Executioner::addAttributeReporter(), FEProblemBase::addMaterialHelper(), FEProblemBase::addMultiApp(), FEProblemBase::addOutput(), FEProblemBase::allowOutput(), AStableDirk4::AStableDirk4(), AlgebraicRelationshipManager::attachAlgebraicFunctorHelper(), RelationshipManager::attachRelationshipManagers(), ElementSideNeighborLayers::attachRelationshipManagersInternal(), ElementPointNeighbors::attachRelationshipManagersInternal(), FileMesh::buildMesh(), MeshGeneratorMesh::buildMesh(), MooseMesh::buildMeshBaseObject(), FEProblemBase::checkNonlinearConvergence(), OversampleOutput::cloneMesh(), FEProblemBase::computeJacobianTags(), FEProblemBase::computeResidualTags(), Console(), TimeStepper::constrainStep(), MultiApp::createApp(), DumpObjectsProblem::dumpObjectHelper(), DumpObjectsProblem::dumpVariableHelper(), EigenExecutionerBase::EigenExecutionerBase(), EigenKernel::EigenKernel(), NonlinearEigen::execute(), InversePowerMethod::execute(), Transient::execute(), Steady::execute(), FileOutput::FileOutput(), FEProblemBase::forceOutput(), MeshGenerator::getMesh(), MeshGenerator::getMeshByName(), MooseObject::getMooseApp(), InversePowerMethod::init(), NonlinearEigen::init(), Transient::init(), Steady::init(), MooseMesh::init(), NumPicardIterations::initialize(), TimePeriod::initialSetup(), initialSetup(), MultiApp::initialSetup(), FEProblemBase::initialSetup(), AdvancedOutput::initOutputList(), FEProblemBase::initPetscOutput(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), InversePowerMethod::InversePowerMethod(), MooseObject::mooseError(), NonlinearEigen::NonlinearEigen(), EigenExecutionerBase::normalizeSolution(), PerfGraphOutput::output(), Tecplot::output(), Exodus::output(), Nemesis::output(), ControlOutput::outputActiveObjects(), ControlOutput::outputChangedControls(), ControlOutput::outputControls(), Exodus::outputEmptyTimestep(), outputInput(), Exodus::outputInput(), Exodus::outputNodalVariables(), OversampleOutput::outputStep(), Output::outputStep(), FEProblemBase::outputStep(), outputSystemInformation(), MultiApp::parentOutputPositionChanged(), PerformanceData::PerformanceData(), PetscOutput::petscLinearOutput(), PetscOutput::petscNonlinearOutput(), Transient::preExecute(), FEProblemBase::projectSolution(), FEProblemBase::setRestartFile(), TransientMultiApp::setupApp(), TimeSequenceStepperBase::setupSequence(), Transient::setupTimeIntegrator(), TransientMultiApp::solveStep(), FEProblemBase::subdomainSetup(), FEProblemBase::theWarehouse(), TimeExtremeValue::TimeExtremeValue(), TimePeriod::TimePeriod(), FEProblemBase::timestepSetup(), Transient::Transient(), and write().

◆ _console

const ConsoleStream ConsoleStreamInterface::_console
inherited

An instance of helper class to write streams to the Console objects.

Definition at line 32 of file ConsoleStreamInterface.h.

Referenced by IterationAdaptiveDT::acceptStep(), SetupRecoverFileBaseAction::act(), Adaptivity::adaptMesh(), FEProblemBase::adaptMesh(), SimplePredictor::apply(), MultiApp::backup(), FEProblemBase::backupMultiApps(), FEProblemBase::checkProblemIntegrity(), IterationAdaptiveDT::computeAdaptiveDT(), Transient::computeConstrainedDT(), NonlinearSystemBase::computeDamping(), IterationAdaptiveDT::computeDT(), IterationAdaptiveDT::computeFailedDT(), IterationAdaptiveDT::computeInterpolationDT(), FEProblemBase::computeResidualTags(), IterationAdaptiveDT::constrainStep(), TimeStepper::constrainStep(), MultiApp::createApp(), FEProblemBase::execMultiApps(), FEProblemBase::execMultiAppTransfers(), MultiAppPostprocessorTransfer::execute(), MultiAppPostprocessorInterpolationTransfer::execute(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), MultiAppPostprocessorToAuxScalarTransfer::execute(), MultiAppScalarToAuxScalarTransfer::execute(), MultiAppVariableValueSampleTransfer::execute(), MultiAppInterpolationTransfer::execute(), MultiAppMeshFunctionTransfer::execute(), MultiAppUserObjectTransfer::execute(), MultiAppProjectionTransfer::execute(), MultiAppVectorPostprocessorTransfer::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppCopyTransfer::execute(), Steady::execute(), MultiAppDTKUserObjectTransfer::execute(), ActionWarehouse::executeActionsWithAction(), ActionWarehouse::executeAllActions(), FEProblemBase::FEProblemBase(), ElementQualityChecker::finalize(), FEProblemBase::finishMultiAppStep(), MultiApp::globalAppToLocal(), InversePowerMethod::init(), NonlinearEigen::init(), Steady::init(), FEProblemBase::initialAdaptMesh(), FEProblemBase::initialSetup(), EigenExecutionerBase::inversePowerIteration(), Transient::keepGoing(), IterationAdaptiveDT::limitDTByFunction(), IterationAdaptiveDT::limitDTToPostprocessorValue(), EigenExecutionerBase::makeBXConsistent(), meshChanged(), MooseObject::mooseDeprecated(), MooseObject::mooseInfo(), MooseObject::mooseWarning(), PerfGraphOutput::output(), DOFMapOutput::output(), VariableResidualNormsDebugOutput::output(), output(), ControlOutput::outputActiveObjects(), ControlOutput::outputChangedControls(), ControlOutput::outputControls(), outputInput(), outputPostprocessors(), outputScalarVariables(), outputSystemInformation(), FEProblemBase::possiblyRebuildGeomSearchPatches(), EigenExecutionerBase::postExecute(), AB2PredictorCorrector::postSolve(), ActionWarehouse::printActionDependencySets(), EigenExecutionerBase::printEigenvalue(), MaterialPropertyDebugOutput::printMaterialMap(), SolutionTimeAdaptiveDT::rejectStep(), DT2::rejectStep(), MultiApp::restore(), FEProblemBase::restoreMultiApps(), SimplePredictor::shouldApply(), NonlinearSystem::solve(), PicardSolve::solve(), LStableDirk2::solve(), LStableDirk3::solve(), ImplicitMidpoint::solve(), ExplicitTVDRK2::solve(), AStableDirk4::solve(), LStableDirk4::solve(), ExplicitRK2::solve(), TransientMultiApp::solveStep(), PicardSolve::solveStep(), DT2::step(), AB2PredictorCorrector::step(), NonlinearEigen::takeStep(), writeTimestepInformation(), writeVariableNorms(), and FEProblemBase::~FEProblemBase().

◆ _console_buffer

const std::ostringstream& Console::_console_buffer
private

Reference to cached messages from calls to _console.

Definition at line 217 of file Console.h.

◆ _current_execute_flag

const ExecFlagType& SetupInterface::_current_execute_flag
protectedinherited

Reference to FEProblemBase.

Definition at line 98 of file SetupInterface.h.

◆ _dt

Real& Output::_dt
protectedinherited

Time step delta.

Definition at line 198 of file Output.h.

Referenced by Output::dt(), and PetscOutput::solveSetup().

◆ _dt_old

Real& Output::_dt_old
protectedinherited

Old time step delta.

Definition at line 201 of file Output.h.

Referenced by Output::dtOld(), and writeTimestepInformation().

◆ _elemental_as_nodal

bool AdvancedOutput::_elemental_as_nodal
protectedinherited

Flags to control nodal output.

Definition at line 260 of file AdvancedOutput.h.

Referenced by AdvancedOutput::AdvancedOutput(), Exodus::Exodus(), and AdvancedOutput::initialSetup().

◆ _enabled

const bool& MooseObject::_enabled
protectedinherited

Reference to the "enable" InputParaemters, used by Controls for toggling on/off MooseObjects.

Definition at line 183 of file MooseObject.h.

Referenced by MooseObject::enabled().

◆ _end_step

int Output::_end_step
protectedinherited

End outputting at this time step.

Definition at line 222 of file Output.h.

Referenced by Output::onInterval().

◆ _end_time

Real Output::_end_time
protectedinherited

End outputting time.

Definition at line 216 of file Output.h.

◆ _es_ptr

EquationSystems* Output::_es_ptr
protectedinherited

◆ _exec_flags

const std::vector<ExecFlagType> SetupInterface::_exec_flags
protectedinherited

(DEPRECATED) execution flag (when is the object executed/evaluated) TODO: ExecFlagType

Definition at line 95 of file SetupInterface.h.

Referenced by SetupInterface::execBitFlags(), MultiAppTransfer::execFlags(), and SetupInterface::execFlags().

◆ _execute_enum

const ExecFlagEnum& SetupInterface::_execute_enum
protectedinherited

Execute settings for this oejct.

Definition at line 92 of file SetupInterface.h.

Referenced by ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), and SetupInterface::getExecuteOnEnum().

◆ _execute_on

ExecFlagEnum Output::_execute_on
protectedinherited

The common Execution types; this is used as the default execution type for everything except system information and input.

Definition at line 186 of file Output.h.

Referenced by AdvancedOutput::AdvancedOutput(), Console(), Output::executeOn(), AdvancedOutput::initExecutionTypes(), initialSetup(), output(), Output::Output(), PetscOutput::PetscOutput(), PerfGraphOutput::shouldOutput(), Output::shouldOutput(), and PetscOutput::solveSetup().

◆ _file_base

std::string FileOutput::_file_base
protectedinherited

◆ _file_num

unsigned int& FileOutput::_file_num
protectedinherited

◆ _file_output_stream

std::stringstream Console::_file_output_stream
protected

Stream for storing information to be written to a file.

Definition at line 174 of file Console.h.

Referenced by write(), and writeStreamToFile().

◆ _fit_mode

MooseEnum Console::_fit_mode
protected

The FormattedTable fit mode.

Definition at line 159 of file Console.h.

Referenced by outputPostprocessors(), and outputScalarVariables().

◆ _initialized

bool Output::_initialized
protectedinherited

True if init() has been called.

Definition at line 231 of file Output.h.

Referenced by AdvancedOutput::hasOutputHelper(), Output::initialSetup(), AdvancedOutput::initialSetup(), and output().

◆ _interval

const unsigned int Output::_interval
protectedinherited

The output time step interval.

Definition at line 207 of file Output.h.

Referenced by Output::onInterval().

◆ _is_advanced

bool Output::_is_advanced
protectedinherited

Flag for advanced output testing.

Definition at line 237 of file Output.h.

Referenced by AdvancedOutput::AdvancedOutput(), and Output::isAdvanced().

◆ _libmesh_log

bool Console::_libmesh_log
protected

Control the display libMesh performance log.

Definition at line 186 of file Console.h.

Referenced by initialSetup(), and ~Console().

◆ _linear_iter

PetscInt PetscOutput::_linear_iter
protectedinherited

Current linear iteration returned from PETSc.

Definition at line 52 of file PetscOutput.h.

Referenced by output(), and PetscOutput::petscLinearOutput().

◆ _max_rows

unsigned int Console::_max_rows
protected

The max number of table rows.

Definition at line 156 of file Console.h.

Referenced by outputPostprocessors(), and outputScalarVariables().

◆ _mci_feproblem

FEProblemBase& MeshChangedInterface::_mci_feproblem
protectedinherited

Reference to FEProblemBase instance.

Definition at line 42 of file MeshChangedInterface.h.

Referenced by MeshChangedInterface::MeshChangedInterface().

◆ _mesh_ptr

MooseMesh* Output::_mesh_ptr
protectedinherited

A convenience pointer to the current mesh (reference or displaced depending on "use_displaced")

Definition at line 180 of file Output.h.

Referenced by OversampleOutput::cloneMesh(), OversampleOutput::initOversample(), XDA::output(), Tecplot::output(), Output::Output(), Exodus::outputSetup(), and OversampleOutput::updateOversample().

◆ _name

const std::string& MooseObject::_name
protectedinherited

◆ _new_row_tol

const Real TableOutput::_new_row_tol
protectedinherited

Tolerance used when deciding whether or not to add a new row to the table.

Definition at line 82 of file TableOutput.h.

Referenced by TableOutput::outputPostprocessors().

◆ _nonlinear_iter

PetscInt PetscOutput::_nonlinear_iter
protectedinherited

Current non-linear iteration returned from PETSc.

Definition at line 49 of file PetscOutput.h.

Referenced by output(), and PetscOutput::petscNonlinearOutput().

◆ _norm

Real PetscOutput::_norm
protectedinherited

Current norm returned from PETSc.

Definition at line 46 of file PetscOutput.h.

Referenced by output(), PetscOutput::petscLinearOutput(), and PetscOutput::petscNonlinearOutput().

◆ _num

unsigned int Output::_num
protectedinherited

The number of outputs written.

Definition at line 204 of file Output.h.

◆ _old_linear_norm

Real Console::_old_linear_norm
private

Storage for the old linear residual (needed for color output and only when used when printing to the screen)

Definition at line 220 of file Console.h.

Referenced by output().

◆ _old_nonlinear_norm

Real Console::_old_nonlinear_norm
private

Storage for the old non linear residual (needed for color output and only when used when printing to the screen)

Definition at line 223 of file Console.h.

Referenced by output().

◆ _outlier_multiplier

std::vector<Real> Console::_outlier_multiplier
protected

Multipliers for coloring variable residual norms (default [2, 0.8])

Definition at line 198 of file Console.h.

Referenced by writeVariableNorms().

◆ _outlier_variable_norms

bool Console::_outlier_variable_norms
protected

Flag for writing outlier variable norms.

Definition at line 195 of file Console.h.

Referenced by writeVariableNorms().

◆ _output_if_base_contains

std::vector<std::string> FileOutput::_output_if_base_contains
protectedinherited

Storage for 'output_if_base_contains'.

Definition at line 91 of file FileOutput.h.

Referenced by FileOutput::checkFilename().

◆ _output_step_timer

PerfID Output::_output_step_timer
protectedinherited

Timers.

Definition at line 246 of file Output.h.

Referenced by OversampleOutput::outputStep(), and Output::outputStep().

◆ _padding

unsigned int FileOutput::_padding
protectedinherited

◆ _pars

const InputParameters& MooseObject::_pars
protectedinherited

◆ _perf_graph

PerfGraph& PerfGraphInterface::_perf_graph
protectedinherited

The performance graph to add to.

Definition at line 66 of file PerfGraphInterface.h.

Referenced by PerfGraphData::getValue(), and PerfGraphInterface::registerTimedSection().

◆ _perf_header

bool Console::_perf_header
protected

State for the performance log header information.

Definition at line 189 of file Console.h.

◆ _perf_log

bool Console::_perf_log
protected

State for all performance logging.

Definition at line 177 of file Console.h.

Referenced by Console().

◆ _perf_log_interval

unsigned int Console::_perf_log_interval
protected

The interval at which the performance log is printed.

Definition at line 180 of file Console.h.

Referenced by output().

◆ _pg_params

const InputParameters* PerfGraphInterface::_pg_params
protectedinherited

Params.

Definition at line 63 of file PerfGraphInterface.h.

◆ _postprocessor_table

FormattedTable& TableOutput::_postprocessor_table
protectedinherited

Table containing postprocessor data.

Definition at line 67 of file TableOutput.h.

Referenced by TableOutput::clear(), TableOutput::outputPostprocessors(), outputPostprocessors(), and TableOutput::TableOutput().

◆ _precision

unsigned int Console::_precision
protected

Number of significant digits.

Definition at line 201 of file Console.h.

Referenced by writeTimestepInformation().

◆ _prefix

std::string PerfGraphInterface::_prefix
protectedinherited

A prefix to use for all sections.

Definition at line 69 of file PerfGraphInterface.h.

Referenced by PerfGraphInterface::registerTimedSection().

◆ _print_mesh_changed_info

bool Console::_print_mesh_changed_info
private

Flag for printing mesh information when the mesh changes.

Definition at line 226 of file Console.h.

Referenced by meshChanged().

◆ _problem_ptr

FEProblemBase* Output::_problem_ptr
protectedinherited

◆ _scalar_as_nodal

bool AdvancedOutput::_scalar_as_nodal
protectedinherited

◆ _scalar_table

FormattedTable& TableOutput::_scalar_table
protectedinherited

Table containing scalar aux variables.

Definition at line 76 of file TableOutput.h.

Referenced by TableOutput::clear(), TableOutput::outputScalarVariables(), and outputScalarVariables().

◆ _scientific_time

bool Console::_scientific_time
protected

Toggle for outputting time in time and dt in scientific notation.

Definition at line 162 of file Console.h.

Referenced by writeTimestepInformation().

◆ _sequence

bool Output::_sequence
protectedinherited

Flag for forcing call to outputSetup() with every call to output() (restartable)

Definition at line 183 of file Output.h.

◆ _solve_log

bool Console::_solve_log
protected

State for solve performance log.

Definition at line 183 of file Console.h.

Referenced by Console().

◆ _start_step

int Output::_start_step
protectedinherited

Start outputting at this time step.

Definition at line 219 of file Output.h.

Referenced by Output::onInterval().

◆ _start_time

Real Output::_start_time
protectedinherited

Start outputting time.

Definition at line 213 of file Output.h.

Referenced by Output::onInterval().

◆ _sync_only

bool Output::_sync_only
protectedinherited

Flag for only executing at sync times.

Definition at line 228 of file Output.h.

Referenced by Output::onInterval().

◆ _sync_times

std::set<Real> Output::_sync_times
protectedinherited

Sync times for this outputter.

Definition at line 210 of file Output.h.

Referenced by Output::onInterval().

◆ _system_info_flags

MultiMooseEnum Console::_system_info_flags
private

Flags for controlling the what simulations information is shown.

Definition at line 229 of file Console.h.

Referenced by Console(), outputSystemInformation(), and systemInfoFlags().

◆ _t_step

int& Output::_t_step
protectedinherited

◆ _t_tol

Real Output::_t_tol
protectedinherited

Time checking tolerance.

Definition at line 225 of file Output.h.

Referenced by PetscOutput::solveSetup().

◆ _tables_restartable

bool TableOutput::_tables_restartable
protectedinherited

Flag for allowing all table data to become restartable.

Definition at line 64 of file TableOutput.h.

◆ _time

Real& Output::_time
protectedinherited

◆ _time_column

const bool TableOutput::_time_column
protectedinherited

Enable/disable output of time column for Postprocessors.

Definition at line 88 of file TableOutput.h.

Referenced by TableOutput::TableOutput().

◆ _time_data

const bool TableOutput::_time_data
protectedinherited

Enable/disable VecptorPostprocessor time data file.

Definition at line 85 of file TableOutput.h.

Referenced by CSV::output(), and TableOutput::outputVectorPostprocessors().

◆ _time_old

Real& Output::_time_old
protectedinherited

The old time.

Definition at line 192 of file Output.h.

Referenced by PetscOutput::solveSetup(), and Output::timeOld().

◆ _transient

bool Output::_transient
protectedinherited

Transient flag (true = transient)

Definition at line 171 of file Output.h.

Referenced by Output::dt(), Output::dtOld(), Output::time(), Output::timeOld(), and writeTimestepInformation().

◆ _type

const std::string& MooseObject::_type
protectedinherited

The type of this object (the Class name)

Definition at line 177 of file MooseObject.h.

Referenced by FEProblemBase::init(), and MooseObject::type().

◆ _use_displaced

bool Output::_use_displaced
protectedinherited

Flag for using displaced mesh.

Definition at line 174 of file Output.h.

Referenced by Output::Output().

◆ _vector_postprocessor_tables

std::map<std::string, FormattedTable> TableOutput::_vector_postprocessor_tables
protectedinherited

Formatted tables for outputting vector postprocessor data. One per VectorPostprocessor.

Definition at line 70 of file TableOutput.h.

Referenced by TableOutput::clear(), CSV::output(), and TableOutput::outputVectorPostprocessors().

◆ _vector_postprocessor_time_tables

std::map<std::string, FormattedTable>& TableOutput::_vector_postprocessor_time_tables
protectedinherited

Table for vector postprocessor time data.

Definition at line 73 of file TableOutput.h.

Referenced by TableOutput::clear(), CSV::output(), and TableOutput::outputVectorPostprocessors().

◆ _verbose

bool Console::_verbose
protected

Flag for writing detailed time step information.

Definition at line 171 of file Console.h.

Referenced by initialSetup(), and writeTimestepInformation().

◆ _write_file

bool Console::_write_file
protected

Flag for controlling outputting console information to a file.

Definition at line 165 of file Console.h.

Referenced by outputInput(), write(), and writeStreamToFile().

◆ _write_screen

bool Console::_write_screen
protected

Flag for controlling outputting console information to screen.

Definition at line 168 of file Console.h.

Referenced by outputInput(), and write().


The documentation for this class was generated from the following files: