https://mooseframework.inl.gov
Classes | Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Protected Attributes | List of all members
MFEMProblem Class Referenceabstract

#include <MFEMProblem.h>

Inheritance diagram for MFEMProblem:
[legend]

Classes

struct  MFEMSolverDefinition
 

Public Types

enum  NumericType { NumericType::REAL, NumericType::COMPLEX }
 Enumerates the supported numeric representations for MFEM variables and operators. More...
 
enum  Direction : unsigned char { Direction::TO_EXTERNAL_APP, Direction::FROM_EXTERNAL_APP }
 
enum  CoverageCheckMode {
  CoverageCheckMode::FALSE, CoverageCheckMode::TRUE, CoverageCheckMode::OFF, CoverageCheckMode::ON,
  CoverageCheckMode::SKIP_LIST, CoverageCheckMode::ONLY_LIST
}
 
using DataFileParameterType = DataFileName
 The parameter type this interface expects for a data file name. More...
 

Public Member Functions

 MFEMProblem (const InputParameters &params)
 Construct an MFEM problem from the supplied parameters. More...
 
virtual ~MFEMProblem ()
 Destroy the MFEM problem. More...
 
virtual void initialSetup () override
 
virtual void execute (const ExecFlagType &exec_type) override
 Convenience function for performing execution of MOOSE systems. More...
 
virtual void externalSolve () override
 New interface for solving an External problem. More...
 
virtual void syncSolutions (Direction) override
 Method to transfer data to/from the external application to the associated transfer mesh. More...
 
virtual MFEMMeshmesh () override
 Overwritten mesh() method from base MooseMesh to retrieve the correct mesh type, in this case MFEMMesh. More...
 
virtual const MFEMMeshmesh () const override
 
virtual std::vector< VariableName > getAuxVariableNames ()
 Returns all the variable names from the auxiliary system base. More...
 
void addBoundaryCondition (const std::string &bc_name, const std::string &name, InputParameters &parameters) override
 
void addMaterial (const std::string &material_name, const std::string &name, InputParameters &parameters) override
 
void addFunctorMaterial (const std::string &material_name, const std::string &name, InputParameters &parameters) override
 
void addFESpace (const std::string &type, const std::string &name, InputParameters &parameters)
 Add an MFEM FESpace to the problem. More...
 
void addFESpaceHierarchy (const std::string &type, const std::string &name, InputParameters &parameters)
 Add an MFEMFESpaceHierarchy to the problem. More...
 
void setMesh ()
 Set the mesh used by MFEM. More...
 
void addSubMesh (const std::string &type, const std::string &name, InputParameters &parameters)
 Add an MFEM SubMesh to the problem. More...
 
void addQuadratureFunction (const std::string &type, const std::string &name, InputParameters &parameters)
 Add an MFEM QuadratureFunction-backed coefficient to the problem. More...
 
void addTransfer (const std::string &transfer_name, const std::string &name, InputParameters &parameters) override
 Add transfers between MultiApps and/or MFEM SubMeshes. More...
 
virtual void addVariable (const std::string &var_type, const std::string &var_name, InputParameters &parameters) override
 Override of ExternalProblem::addVariable. More...
 
void addGridFunction (const std::string &var_type, const std::string &var_name, InputParameters &parameters)
 Adds one MFEM GridFunction to be used in the MFEM solve. More...
 
void addAuxVariable (const std::string &var_type, const std::string &var_name, InputParameters &parameters) override
 Override of ExternalProblem::addAuxVariable. More...
 
void addElementalFieldVariable (const std::string &, const std::string &, InputParameters &) override
 Override of FEProblemBase::addElementalFieldVariable to be a no-op because we do not use the Marker/Indicator objects designed to work with libMesh infrastructure. More...
 
void addKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters) override
 Override of ExternalProblem::addKernel. More...
 
void addRealComponentToKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 Adds a real component kernel to the parent MFEMComplexKernel. More...
 
void addImagComponentToKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 Adds an imaginary component kernel to the parent MFEMComplexKernel. More...
 
void addRealComponentToBC (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 Adds a real component BC to the parent MFEMComplexIntegratedBC. More...
 
void addImagComponentToBC (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 Adds an imaginary component BC to the parent MFEMComplexIntegratedBC. More...
 
void addAuxKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters) override
 Override of ExternalProblem::addAuxKernel. More...
 
void addFunction (const std::string &type, const std::string &name, InputParameters &parameters) override
 Override of ExternalProblem::addFunction. More...
 
void addInitialCondition (const std::string &ic_name, const std::string &name, InputParameters &parameters) override
 Add an MFEM initial condition to the problem. More...
 
void addPostprocessor (const std::string &type, const std::string &name, InputParameters &parameters) override
 Override of ExternalProblem::addPostprocessor. More...
 
void addVectorPostprocessor (const std::string &type, const std::string &name, InputParameters &parameters) override
 Add a vector postprocessor and register its vectors with the MFEM execution system. More...
 
void addIndicator (const std::string &type, const std::string &name, InputParameters &parameters) override
 Override of FEProblemBase::addIndicator. More...
 
void addMarker (const std::string &type, const std::string &name, InputParameters &parameters) override
 Override of FEProblemBase::addMarker. More...
 
virtual void addMFEMSolver (const std::string &user_object_name, const std::string &name, InputParameters &parameters)
 Method called in AddMFEMSolverAction which records a solver for later dependency-ordered construction. More...
 
virtual void resolveMFEMSolvers ()
 Construct recorded MFEM solvers in dependency order and select the problem driver solver(s). More...
 
void executeMFEMObjects (const ExecFlagType &exec_type)
 Execute MFEM executed objects scheduled on the supplied execute flag. More...
 
InputParameters addMFEMFESpaceFromMOOSEVariable (InputParameters &moosevar_params)
 Method used to get an mfem FEC depending on the variable family specified in the input file. More...
 
Moose::MFEM::CoefficientManagergetCoefficients ()
 Method to get the PropertyManager object for storing material properties and converting them to MFEM coefficients. More...
 
MFEMProblemDatagetProblemData ()
 Method to get the current MFEMProblemData object storing the current data specifying the FE problem. More...
 
const MFEMProblemDatagetProblemData () const
 Return the current MFEM problem data in a const context. More...
 
MPI_Comm getComm ()
 Return the MPI communicator associated with this FE problem's mesh. More...
 
const mfem::ParMesh & getMFEMVariableMesh (std::string var_name)
 Return the ParMesh associated with a particular variable. More...
 
void displaceMesh ()
 Displace the mesh, if mesh displacement is enabled. More...
 
void rebalanceMesh (mfem::ParMesh &pmesh)
 Rebalance the (necessarily nonconforming) mesh. More...
 
std::optional< std::reference_wrapper< mfem::ParGridFunction const > > getMeshDisplacementGridFunction ()
 Returns optional reference to the displacement GridFunction to apply to nodes. More...
 
Moose::FEBackend feBackend () const override
 
std::string solverTypeString (unsigned int solver_sys_num) override
 Return solver type as a human readable string. More...
 
void updateFESpaces ()
 Calls Update() on all FE spaces. More...
 
void updateGridFunctions ()
 Calls Update() on all gridfunctions. More...
 
bool hRefine ()
 If AMR is enabled, request (and perform if needed) h-refinement. More...
 
bool pRefine ()
 If AMR is enabled, request (and perform if needed) p-refinement. More...
 
std::shared_ptr< mfem::ParGridFunction > getGridFunction (const std::string &name)
 
std::shared_ptr< mfem::ParComplexGridFunction > getComplexGridFunction (const std::string &name)
 
NumericType getNumericType () const
 Retrieve the numeric type of the problem. More...
 
template<typename T >
T & getMFEMObject (const std::string &system, const std::string &name, const THREAD_ID tid=0) const
 Retrieve an MFEM object from the warehouse by system and name. More...
 
bool hasMFEMObject (const std::string &system, const std::string &name) const
 Determine whether an MFEM object with the supplied system and name exists. More...
 
virtual void solve (unsigned int nl_sys_num=0) override final
 Solve is implemented to providing syncing to/from the "transfer" mesh. More...
 
virtual void addExternalVariables ()
 Method called to add AuxVariables to the simulation. More...
 
bool initialized () const
 
virtual libMesh::EquationSystemses () override
 
const MooseMeshmesh (bool use_displaced) const override
 
MooseMeshmesh (bool use_displaced)
 
void setCoordSystem (const std::vector< SubdomainName > &blocks, const MultiMooseEnum &coord_sys)
 
void setAxisymmetricCoordAxis (const MooseEnum &rz_coord_axis)
 
void setCoupling (Moose::CouplingType type)
 Set the coupling between variables TODO: allow user-defined coupling. More...
 
Moose::CouplingType coupling () const
 
void setCouplingMatrix (std::unique_ptr< libMesh::CouplingMatrix > cm, const unsigned int nl_sys_num)
 Set custom coupling matrix. More...
 
void setCouplingMatrix (libMesh::CouplingMatrix *cm, const unsigned int nl_sys_num)
 
const libMesh::CouplingMatrixcouplingMatrix (const unsigned int nl_sys_num) const override
 The coupling matrix defining what blocks exist in the preconditioning matrix. More...
 
void setNonlocalCouplingMatrix ()
 Set custom coupling matrix for variables requiring nonlocal contribution. More...
 
bool areCoupled (const unsigned int ivar, const unsigned int jvar, const unsigned int nl_sys_num) const
 
bool hasUOAuxStateCheck () const
 Whether or not MOOSE will perform a user object/auxiliary kernel state check. More...
 
bool checkingUOAuxState () const
 Return a flag to indicate whether we are executing user objects and auxliary kernels for state check Note: This function can return true only when hasUOAuxStateCheck() returns true, i.e. More...
 
virtual bool checkResidualForNans () const override
 Whether to check residual for NaN/Inf values. More...
 
void setCheckResidualForNans (bool check_residual_for_nans)
 Setter for residual NaN/Inf checking. More...
 
void trustUserCouplingMatrix ()
 Whether to trust the user coupling matrix even if we want to do things like be paranoid and create a full coupling matrix. More...
 
std::vector< std::pair< MooseVariableFieldBase *, MooseVariableFieldBase * > > & couplingEntries (const THREAD_ID tid, const unsigned int nl_sys_num)
 
std::vector< std::pair< MooseVariableFieldBase *, MooseVariableFieldBase * > > & nonlocalCouplingEntries (const THREAD_ID tid, const unsigned int nl_sys_num)
 
virtual bool hasVariable (const std::string &var_name) const override
 Whether or not this problem has the variable. More...
 
bool hasSolverVariable (const std::string &var_name) const
 
virtual const MooseVariableFieldBasegetVariable (const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY) const override
 Returns the variable reference for requested variable which must be of the expected_var_type (Nonlinear vs. More...
 
virtual const MooseVariableFieldBasegetVariable (const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY) const=0
 Returns the variable reference for requested variable which must be of the expected_var_type (Nonlinear vs. More...
 
virtual MooseVariableFieldBasegetVariable (const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY)
 
virtual MooseVariableFieldBasegetVariable (const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY)
 
MooseVariableFieldBasegetActualFieldVariable (const THREAD_ID tid, const std::string &var_name) override
 Returns the variable reference for requested MooseVariableField which may be in any system. More...
 
virtual MooseVariablegetStandardVariable (const THREAD_ID tid, const std::string &var_name) override
 Returns the variable reference for requested MooseVariable which may be in any system. More...
 
virtual VectorMooseVariablegetVectorVariable (const THREAD_ID tid, const std::string &var_name) override
 Returns the variable reference for requested VectorMooseVariable which may be in any system. More...
 
virtual ArrayMooseVariablegetArrayVariable (const THREAD_ID tid, const std::string &var_name) override
 Returns the variable reference for requested ArrayMooseVariable which may be in any system. More...
 
virtual bool hasScalarVariable (const std::string &var_name) const override
 Returns a Boolean indicating whether any system contains a variable with the name provided. More...
 
virtual MooseVariableScalargetScalarVariable (const THREAD_ID tid, const std::string &var_name) override
 Returns the scalar variable reference from whichever system contains it. More...
 
virtual libMesh::SystemgetSystem (const std::string &var_name) override
 Returns the equation system containing the variable provided. More...
 
const RestartableEquationSystemsgetRestartableEquationSystems () const
 Get the RestartableEquationSystems object. More...
 
virtual void setActiveElementalMooseVariables (const std::set< MooseVariableFEBase *> &moose_vars, const THREAD_ID tid) override
 Set the MOOSE variables to be reinited on each element. More...
 
virtual void clearActiveElementalMooseVariables (const THREAD_ID tid) override
 Clear the active elemental MooseVariableFEBase. More...
 
virtual void clearActiveFEVariableCoupleableMatrixTags (const THREAD_ID tid) override
 
virtual void clearActiveFEVariableCoupleableVectorTags (const THREAD_ID tid) override
 
virtual void setActiveFEVariableCoupleableVectorTags (std::set< TagID > &vtags, const THREAD_ID tid) override
 
virtual void setActiveFEVariableCoupleableMatrixTags (std::set< TagID > &mtags, const THREAD_ID tid) override
 
virtual void clearActiveScalarVariableCoupleableMatrixTags (const THREAD_ID tid) override
 
virtual void clearActiveScalarVariableCoupleableVectorTags (const THREAD_ID tid) override
 
virtual void setActiveScalarVariableCoupleableVectorTags (std::set< TagID > &vtags, const THREAD_ID tid) override
 
virtual void setActiveScalarVariableCoupleableMatrixTags (std::set< TagID > &mtags, const THREAD_ID tid) override
 
virtual void createQRules (libMesh::QuadratureType type, libMesh::Order order, libMesh::Order volume_order=libMesh::INVALID_ORDER, libMesh::Order face_order=libMesh::INVALID_ORDER, SubdomainID block=Moose::ANY_BLOCK_ID, bool allow_negative_qweights=true)
 
void bumpVolumeQRuleOrder (libMesh::Order order, SubdomainID block)
 Increases the element/volume quadrature order for the specified mesh block if and only if the current volume quadrature order is lower. More...
 
void bumpAllQRuleOrder (libMesh::Order order, SubdomainID block)
 
unsigned int getMaxQps () const
 
libMesh::Order getMaxScalarOrder () const
 
void checkNonlocalCoupling ()
 
void checkUserObjectJacobianRequirement (THREAD_ID tid)
 
void setVariableAllDoFMap (const std::vector< const MooseVariableFEBase *> &moose_vars)
 
const std::vector< const MooseVariableFEBase * > & getUserObjectJacobianVariables (const THREAD_ID tid) const
 
virtual Assemblyassembly (const THREAD_ID tid, const unsigned int sys_num) override
 
virtual const Assemblyassembly (const THREAD_ID tid, const unsigned int sys_num) const override
 
Moose::Kokkos::AssemblykokkosAssembly ()
 
const Moose::Kokkos::AssemblykokkosAssembly () const
 
virtual std::vector< VariableName > getVariableNames ()
 Returns a list of all the variables in the problem (both from the NL and Aux systems. More...
 
void checkDuplicatePostprocessorVariableNames ()
 
void timestepSetup () override
 
void customSetup (const ExecFlagType &exec_type) override
 
void residualSetup () override
 
void jacobianSetup () override
 
virtual void prepare (const Elem *elem, const THREAD_ID tid) override
 
virtual void prepare (const Elem *elem, unsigned int ivar, unsigned int jvar, const std::vector< dof_id_type > &dof_indices, const THREAD_ID tid) override
 
virtual void prepareFace (const Elem *elem, const THREAD_ID tid) override
 
virtual void setCurrentSubdomainID (const Elem *elem, const THREAD_ID tid) override
 
virtual void setNeighborSubdomainID (const Elem *elem, unsigned int side, const THREAD_ID tid) override
 
virtual void setNeighborSubdomainID (const Elem *elem, const THREAD_ID tid)
 
virtual void prepareAssembly (const THREAD_ID tid) override
 
virtual void prepareAssemblyNeighbor (const THREAD_ID tid)
 Begin a fresh neighbor accumulation phase by sizing and zeroing the neighbor blocks. More...
 
virtual void addGhostedElem (dof_id_type elem_id) override
 Will make sure that all dofs connected to elem_id are ghosted to this processor. More...
 
virtual void addGhostedBoundary (BoundaryID boundary_id) override
 Will make sure that all necessary elements from boundary_id are ghosted to this processor. More...
 
virtual void ghostGhostedBoundaries () override
 Causes the boundaries added using addGhostedBoundary to actually be ghosted. More...
 
virtual void sizeZeroes (unsigned int size, const THREAD_ID tid)
 
virtual bool reinitDirac (const Elem *elem, const THREAD_ID tid) override
 Returns true if the Problem has Dirac kernels it needs to compute on elem. More...
 
virtual void reinitElem (const Elem *elem, const THREAD_ID tid) override
 
virtual void reinitElemPhys (const Elem *elem, const std::vector< Point > &phys_points_in_elem, const THREAD_ID tid) override
 
void reinitElemFace (const Elem *elem, unsigned int side, BoundaryID, const THREAD_ID tid)
 
virtual void reinitElemFace (const Elem *elem, unsigned int side, const THREAD_ID tid) override
 
virtual void reinitLowerDElem (const Elem *lower_d_elem, const THREAD_ID tid, const std::vector< Point > *const pts=nullptr, const std::vector< Real > *const weights=nullptr) override
 
virtual void reinitNode (const Node *node, const THREAD_ID tid) override
 
virtual void reinitNodeFace (const Node *node, BoundaryID bnd_id, const THREAD_ID tid) override
 
virtual void reinitNodes (const std::vector< dof_id_type > &nodes, const THREAD_ID tid) override
 
virtual void reinitNodesNeighbor (const std::vector< dof_id_type > &nodes, const THREAD_ID tid) override
 
virtual void reinitNeighbor (const Elem *elem, unsigned int side, const THREAD_ID tid) override
 
virtual void reinitNeighborPhys (const Elem *neighbor, unsigned int neighbor_side, const std::vector< Point > &physical_points, const THREAD_ID tid) override
 
virtual void reinitNeighborPhys (const Elem *neighbor, const std::vector< Point > &physical_points, const THREAD_ID tid) override
 
virtual void reinitElemNeighborAndLowerD (const Elem *elem, unsigned int side, const THREAD_ID tid) override
 
virtual void reinitScalars (const THREAD_ID tid, bool reinit_for_derivative_reordering=false) override
 fills the VariableValue arrays for scalar variables from the solution vector More...
 
virtual void reinitOffDiagScalars (const THREAD_ID tid) override
 
virtual void getDiracElements (std::set< const Elem *> &elems) override
 Fills "elems" with the elements that should be looped over for Dirac Kernels. More...
 
virtual void clearDiracInfo () override
 Gets called before Dirac Kernels are asked to add the points they are supposed to be evaluated in. More...
 
virtual void subdomainSetup (SubdomainID subdomain, const THREAD_ID tid)
 
virtual void neighborSubdomainSetup (SubdomainID subdomain, const THREAD_ID tid)
 
virtual void newAssemblyArray (std::vector< std::shared_ptr< SolverSystem >> &solver_systems)
 
virtual void initNullSpaceVectors (const InputParameters &parameters, std::vector< std::shared_ptr< NonlinearSystemBase >> &nl)
 
virtual void init () override
 
void initKokkos ()
 Construct Kokkos assembly and systems and allocate Kokkos material property storages. More...
 
virtual void solveLinearSystem (const unsigned int linear_sys_num, const Moose::PetscSupport::PetscOptions *po=nullptr)
 Build and solve a linear system. More...
 
virtual void setException (const std::string &message)
 Set an exception, which is stored at this point by toggling a member variable in this class, and which must be followed up with by a call to checkExceptionAndStopSolve(). More...
 
virtual bool hasException ()
 Whether or not an exception has occurred. More...
 
virtual void checkExceptionAndStopSolve (bool print_message=true)
 Check to see if an exception has occurred on any processor and, if possible, force the solve to fail, which will result in the time step being cut. More...
 
virtual bool solverSystemConverged (const unsigned int solver_sys_num) override
 
virtual unsigned int nNonlinearIterations (const unsigned int nl_sys_num) const override
 
virtual unsigned int nLinearIterations (const unsigned int nl_sys_num) const override
 
virtual Real finalNonlinearResidual (const unsigned int nl_sys_num) const override
 
virtual bool computingPreSMOResidual (const unsigned int nl_sys_num) const override
 Returns true if the problem is in the process of computing it's initial residual. More...
 
virtual bool startedInitialSetup ()
 Returns true if we are in or beyond the initialSetup stage. More...
 
virtual void onTimestepBegin () override
 
virtual void onTimestepEnd () override
 
virtual Realtime () const
 
virtual RealtimeOld () const
 
virtual inttimeStep () const
 
virtual Realdt () const
 
virtual RealdtOld () const
 
Real getTimeFromStateArg (const Moose::StateArg &state) const
 Returns the time associated with the requested state. More...
 
virtual void transient (bool trans)
 
virtual bool isTransient () const override
 
virtual void addTimeIntegrator (const std::string &type, const std::string &name, InputParameters &parameters)
 
virtual void addPredictor (const std::string &type, const std::string &name, InputParameters &parameters)
 
virtual void copySolutionsBackwards ()
 
void skipNextForwardSolutionCopyToOld ()
 Prevents the copy of the solution vector to the old solution vector in each system. More...
 
virtual void advanceState ()
 Advance all of the state holding vectors / datastructures so that we can move to the next timestep. More...
 
virtual void restoreSolutions ()
 
virtual void saveOldSolutions ()
 Allocate vectors and save old solutions into them. More...
 
virtual void restoreOldSolutions ()
 Restore old solutions from the backup vectors and deallocate them. More...
 
void needSolutionState (unsigned int oldest_needed, Moose::SolutionIterationType iteration_type)
 Declare that we need up to old (1) or older (2) solution states for a given type of iteration. More...
 
bool hasSolutionState (unsigned int state, Moose::SolutionIterationType iteration_type) const
 Whether we need up to old (1) or older (2) solution states for a given type of iteration. More...
 
virtual void outputStep (ExecFlagType type)
 Output the current step. More...
 
virtual void postExecute ()
 Method called at the end of the simulation. More...
 
void forceOutput ()
 Indicates that the next call to outputStep should be forced. More...
 
virtual void initPetscOutputAndSomeSolverSettings ()
 Reinitialize PETSc output for proper linear/nonlinear iteration display. More...
 
Moose::PetscSupport::PetscOptionsgetPetscOptions ()
 Retrieve a writable reference the PETSc options (used by PetscSupport) More...
 
void logAdd (const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
 Output information about the object just added to the problem. More...
 
virtual bool hasFunction (const std::string &name, const THREAD_ID tid=0)
 
virtual FunctiongetFunction (const std::string &name, const THREAD_ID tid=0)
 
virtual void addKokkosFunction (const std::string &type, const std::string &name, InputParameters &parameters)
 Add a Kokkos function to the problem. More...
 
virtual bool hasKokkosFunction (const std::string &name) const
 Get whether a Kokkos function exists. More...
 
virtual Moose::Kokkos::Function getKokkosFunction (const std::string &name)
 Get a Kokkos function in an abstract type. More...
 
template<typename T >
T & getKokkosFunction (const std::string &name)
 Get a Kokkos function in a concrete type. More...
 
virtual void addMeshDivision (const std::string &type, const std::string &name, InputParameters &params)
 Add a MeshDivision. More...
 
MeshDivisiongetMeshDivision (const std::string &name, const THREAD_ID tid=0) const
 Get a MeshDivision. More...
 
virtual void addConvergence (const std::string &type, const std::string &name, InputParameters &parameters)
 Adds a Convergence object. More...
 
virtual ConvergencegetConvergence (const std::string &name, const THREAD_ID tid=0) const
 Gets a Convergence object. More...
 
virtual const std::vector< std::shared_ptr< Convergence > > & getConvergenceObjects (const THREAD_ID tid=0) const
 Gets the Convergence objects. More...
 
virtual bool hasConvergence (const std::string &name, const THREAD_ID tid=0) const
 Returns true if the problem has a Convergence object of the given name. More...
 
bool needToAddDefaultNonlinearConvergence () const
 Returns true if the problem needs to add the default nonlinear convergence. More...
 
bool needToAddDefaultMultiAppFixedPointConvergence () const
 Returns true if the problem needs to add the default fixed point convergence. More...
 
bool needToAddDefaultSteadyStateConvergence () const
 Returns true if the problem needs to add the default steady-state detection convergence. More...
 
void setNeedToAddDefaultNonlinearConvergence ()
 Sets _need_to_add_default_nonlinear_convergence to true. More...
 
void setNeedToAddDefaultMultiAppFixedPointConvergence ()
 Sets _need_to_add_default_multiapp_fixed_point_convergence to true. More...
 
void setNeedToAddDefaultSteadyStateConvergence ()
 Sets _need_to_add_default_steady_state_convergence to true. More...
 
bool hasSetMultiAppFixedPointConvergenceName () const
 Returns true if the problem has set the fixed point convergence name. More...
 
bool hasSetSteadyStateConvergenceName () const
 Returns true if the problem has set the steady-state detection convergence name. More...
 
virtual void addDefaultNonlinearConvergence (const InputParameters &params)
 Adds the default nonlinear Convergence associated with the problem. More...
 
virtual bool onlyAllowDefaultNonlinearConvergence () const
 Returns true if an error will result if the user supplies 'nonlinear_convergence'. More...
 
void addDefaultMultiAppFixedPointConvergence (const InputParameters &params)
 Adds the default fixed point Convergence associated with the problem. More...
 
void addDefaultSteadyStateConvergence (const InputParameters &params)
 Adds the default steady-state detection Convergence. More...
 
virtual void addLineSearch (const InputParameters &)
 add a MOOSE line search More...
 
virtual void lineSearch ()
 execute MOOSE line search More...
 
LineSearchgetLineSearch () override
 getter for the MOOSE line search More...
 
virtual void addDistribution (const std::string &type, const std::string &name, InputParameters &parameters)
 The following functions will enable MOOSE to have the capability to import distributions. More...
 
virtual bool hasDistribution (const std::string &name) const
 
virtual DistributiongetDistribution (const std::string &name)
 
virtual void addSampler (const std::string &type, const std::string &name, InputParameters &parameters)
 The following functions will enable MOOSE to have the capability to import Samplers. More...
 
virtual SamplergetSampler (const std::string &name, const THREAD_ID tid=0)
 
NonlinearSystemBasegetNonlinearSystemBase (const unsigned int sys_num)
 
const NonlinearSystemBasegetNonlinearSystemBase (const unsigned int sys_num) const
 
void setCurrentNonlinearSystem (const unsigned int nl_sys_num)
 
NonlinearSystemBasecurrentNonlinearSystem ()
 
const NonlinearSystemBasecurrentNonlinearSystem () const
 
virtual const SystemBasesystemBaseNonlinear (const unsigned int sys_num) const override
 Return the nonlinear system object as a base class reference given the system number. More...
 
virtual SystemBasesystemBaseNonlinear (const unsigned int sys_num) override
 
virtual const SystemBasesystemBaseSolver (const unsigned int sys_num) const override
 Return the solver system object as a base class reference given the system number. More...
 
virtual SystemBasesystemBaseSolver (const unsigned int sys_num) override
 
virtual const SystemBasesystemBaseAuxiliary () const override
 Return the auxiliary system object as a base class reference. More...
 
virtual SystemBasesystemBaseAuxiliary () override
 
virtual NonlinearSystemgetNonlinearSystem (const unsigned int sys_num)
 
virtual const SystemBasegetSystemBase (const unsigned int sys_num) const
 Get constant reference to a system in this problem. More...
 
virtual SystemBasegetSystemBase (const unsigned int sys_num)
 Get non-constant reference to a system in this problem. More...
 
SystemBasegetSystemBase (const std::string &sys_name)
 Get non-constant reference to a system in this problem. More...
 
LinearSystemgetLinearSystem (unsigned int sys_num)
 Get non-constant reference to a linear system. More...
 
const LinearSystemgetLinearSystem (unsigned int sys_num) const
 Get a constant reference to a linear system. More...
 
SolverSystemgetSolverSystem (unsigned int sys_num)
 Get non-constant reference to a solver system. More...
 
const SolverSystemgetSolverSystem (unsigned int sys_num) const
 Get a constant reference to a solver system. More...
 
void setCurrentLinearSystem (unsigned int sys_num)
 Set the current linear system pointer. More...
 
LinearSystemcurrentLinearSystem ()
 Get a non-constant reference to the current linear system. More...
 
const LinearSystemcurrentLinearSystem () const
 Get a constant reference to the current linear system. More...
 
virtual const SystemBasesystemBaseLinear (unsigned int sys_num) const override
 Get a constant base class reference to a linear system. More...
 
virtual SystemBasesystemBaseLinear (unsigned int sys_num) override
 Get a non-constant base class reference to a linear system. More...
 
virtual void addHDGKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addNodalKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addScalarKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosNodalKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosBoundaryCondition (const std::string &bc_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosLinearFVKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosLinearFVBC (const std::string &bc_name, const std::string &name, InputParameters &parameters)
 
virtual void addConstraint (const std::string &c_name, const std::string &name, InputParameters &parameters)
 
virtual void setInputParametersFEProblem (InputParameters &parameters)
 
virtual void addAuxVariable (const std::string &var_name, const libMesh::FEType &type, const std::set< SubdomainID > *const active_subdomains=NULL)
 
virtual void addAuxArrayVariable (const std::string &var_name, const libMesh::FEType &type, unsigned int components, const std::set< SubdomainID > *const active_subdomains=NULL)
 
virtual void addAuxScalarVariable (const std::string &var_name, libMesh::Order order, Real scale_factor=1., const std::set< SubdomainID > *const active_subdomains=NULL)
 
virtual void addAuxScalarKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosAuxKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
AuxiliarySystemgetAuxiliarySystem ()
 
virtual void addDiracKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addDGKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addFVKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addLinearFVKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addFVBC (const std::string &fv_bc_name, const std::string &name, InputParameters &parameters)
 
virtual void addLinearFVBC (const std::string &fv_bc_name, const std::string &name, InputParameters &parameters)
 
virtual void addFVInterfaceKernel (const std::string &fv_ik_name, const std::string &name, InputParameters &parameters)
 
virtual void addInterfaceKernel (const std::string &kernel_name, const std::string &name, InputParameters &parameters)
 
virtual void addFVInitialCondition (const std::string &ic_name, const std::string &name, InputParameters &parameters)
 Add an initial condition for a finite volume variables. More...
 
void projectSolution ()
 
unsigned short getCurrentICState ()
 Retrieves the current initial condition state. More...
 
void projectInitialConditionOnCustomRange (libMesh::ConstElemRange &elem_range, ConstBndNodeRange &bnd_node_range, const std::optional< std::set< VariableName >> &target_vars=std::nullopt)
 Project initial conditions for custom elem_range and bnd_node_range This is needed when elements/boundary nodes are added to a specific subdomain at an intermediate step. More...
 
void projectFunctionOnCustomRange (ConstElemRange &elem_range, Number(*func)(const Point &, const libMesh::Parameters &, const std::string &, const std::string &), Gradient(*func_grad)(const Point &, const libMesh::Parameters &, const std::string &, const std::string &), const libMesh::Parameters &params, const std::vector< VariableName > &target_vars)
 Project a function onto a range of elements for a given variable. More...
 
virtual void addMaterialHelper (std::vector< MaterialWarehouse *> warehouse, const std::string &material_name, const std::string &name, InputParameters &parameters)
 
virtual void addInterfaceMaterial (const std::string &material_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosMaterial (const std::string &material_name, const std::string &name, InputParameters &parameters)
 
void prepareMaterials (const std::unordered_set< unsigned int > &consumer_needed_mat_props, const SubdomainID blk_id, const THREAD_ID tid)
 Add the MooseVariables and the material properties that the current materials depend on to the dependency list. More...
 
void reinitMaterials (SubdomainID blk_id, const THREAD_ID tid, bool swap_stateful=true)
 
void reinitMaterialsFace (SubdomainID blk_id, const THREAD_ID tid, bool swap_stateful=true, const std::deque< MaterialBase *> *reinit_mats=nullptr)
 reinit materials on element faces More...
 
void reinitMaterialsFaceOnBoundary (const BoundaryID boundary_id, const SubdomainID blk_id, const THREAD_ID tid, const bool swap_stateful=true, const std::deque< MaterialBase *> *const reinit_mats=nullptr)
 reinit materials on element faces on a boundary (internal or external) This specific routine helps us not reinit when don't need to More...
 
void reinitMaterialsNeighborOnBoundary (const BoundaryID boundary_id, const SubdomainID blk_id, const THREAD_ID tid, const bool swap_stateful=true, const std::deque< MaterialBase *> *const reinit_mats=nullptr)
 reinit materials on neighbor element (usually faces) on a boundary (internal or external) This specific routine helps us not reinit when don't need to More...
 
void reinitMaterialsNeighbor (SubdomainID blk_id, const THREAD_ID tid, bool swap_stateful=true, const std::deque< MaterialBase *> *reinit_mats=nullptr)
 reinit materials on the neighboring element face More...
 
void reinitMaterialsBoundary (BoundaryID boundary_id, const THREAD_ID tid, bool swap_stateful=true, const std::deque< MaterialBase *> *reinit_mats=nullptr)
 reinit materials on a boundary More...
 
void reinitMaterialsInterface (BoundaryID boundary_id, const THREAD_ID tid, bool swap_stateful=true)
 
void prepareKokkosMaterials (const std::unordered_set< unsigned int > &consumer_needed_mat_props)
 
void reinitKokkosMaterials ()
 
virtual void swapBackMaterials (const THREAD_ID tid)
 
virtual void swapBackMaterialsFace (const THREAD_ID tid)
 
virtual void swapBackMaterialsNeighbor (const THREAD_ID tid)
 
void setActiveMaterialProperties (const std::unordered_set< unsigned int > &mat_prop_ids, const THREAD_ID tid)
 Record and set the material properties required by the current computing thread. More...
 
bool hasActiveMaterialProperties (const THREAD_ID tid) const
 Method to check whether or not a list of active material roperties has been set. More...
 
void clearActiveMaterialProperties (const THREAD_ID tid)
 Clear the active material properties. More...
 
template<typename T >
std::vector< std::shared_ptr< T > > addObject (const std::string &type, const std::string &name, InputParameters &parameters, const bool threaded=true, const std::string &var_param_name="variable")
 Method for creating and adding an object to the warehouse. More...
 
virtual void addReporter (const std::string &type, const std::string &name, InputParameters &parameters)
 Add a Reporter object to the simulation. More...
 
virtual void addKokkosPostprocessor (const std::string &pp_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosVectorPostprocessor (const std::string &pp_name, const std::string &name, InputParameters &parameters)
 
virtual void addKokkosReporter (const std::string &type, const std::string &name, InputParameters &parameters)
 
const ReporterDatagetReporterData () const
 Provides const access the ReporterData object. More...
 
ReporterDatagetReporterData (ReporterData::WriteKey)
 Provides non-const access the ReporterData object that is used to store reporter values. More...
 
virtual std::vector< std::shared_ptr< UserObject > > addUserObject (const std::string &user_object_name, const std::string &name, InputParameters &parameters)
 
template<class T >
T & getUserObject (const std::string &name, unsigned int tid=0) const
 Get the user object by its name. More...
 
const UserObjectgetUserObjectBase (const std::string &name, const THREAD_ID tid=0) const
 Get the user object by its name. More...
 
bool hasUserObject (const std::string &name) const
 Check if there if a user object of given name. More...
 
virtual void addKokkosUserObject (const std::string &user_object_name, const std::string &name, InputParameters &parameters)
 
template<class T >
const T & getKokkosUserObject (const std::string &name) const
 Get the Kokkos user object by its name. More...
 
bool hasKokkosUserObject (const std::string &name) const
 Check if there if a Kokkos user object of given name. More...
 
void checkUserObjectNameCollision (const std::string &name, const std::string &type) const
 Check for name collision between different user objects. More...
 
const PositionsgetPositionsObject (const std::string &name) const
 Get the Positions object by its name. More...
 
virtual void addFVInterpolationMethod (const std::string &method_type, const std::string &name, InputParameters &parameters)
 Add an FV interpolation method. More...
 
const FVInterpolationMethodgetFVInterpolationMethod (const InterpolationMethodName &name, const THREAD_ID tid=0) const
 Retrieve an FV interpolation method. More...
 
const FVFaceInterpolationMethodgetFVFaceInterpolationMethod (const InterpolationMethodName &name, const THREAD_ID tid=0) const
 Retrieve a scalar face interpolation method. More...
 
const FVAdvectedInterpolationMethodgetFVAdvectedInterpolationMethod (const InterpolationMethodName &name, const THREAD_ID tid=0) const
 Retrieve an advected interpolation method. More...
 
bool hasFVInterpolationMethod (const InterpolationMethodName &name) const
 Check if an FV interpolation method with a given name exists. More...
 
bool hasPostprocessorValueByName (const PostprocessorName &name) const
 Whether or not a Postprocessor value exists by a given name. More...
 
const PostprocessorgetPostprocessorObjectByName (const PostprocessorName &object_name, const THREAD_ID tid=0) const
 Return the Postprocessor object registered under the supplied object name. More...
 
const PostprocessorValuegetPostprocessorValueByName (const PostprocessorName &name, std::size_t t_index=0) const
 Get a read-only reference to the value associated with a Postprocessor that exists. More...
 
void setPostprocessorValueByName (const PostprocessorName &name, const PostprocessorValue &value, std::size_t t_index=0)
 Set the value of a PostprocessorValue. More...
 
bool hasPostprocessor (const std::string &name) const
 Deprecated. More...
 
const VectorPostprocessorValuegetVectorPostprocessorValueByName (const std::string &object_name, const std::string &vector_name, std::size_t t_index=0) const
 Get a read-only reference to the vector value associated with the VectorPostprocessor. More...
 
void setVectorPostprocessorValueByName (const std::string &object_name, const std::string &vector_name, const VectorPostprocessorValue &value, std::size_t t_index=0)
 Set the value of a VectorPostprocessor vector. More...
 
const VectorPostprocessorgetVectorPostprocessorObjectByName (const std::string &object_name, const THREAD_ID tid=0) const
 Return the VPP object given the name. More...
 
virtual void addDamper (const std::string &damper_name, const std::string &name, InputParameters &parameters)
 
void setupDampers ()
 
bool hasDampers ()
 Whether or not this system has dampers. More...
 
virtual void addMultiApp (const std::string &multi_app_name, const std::string &name, InputParameters &parameters)
 Add a MultiApp to the problem. More...
 
std::shared_ptr< MultiAppgetMultiApp (const std::string &multi_app_name) const
 Get a MultiApp object by name. More...
 
std::vector< std::shared_ptr< Transfer > > getTransfers (ExecFlagType type, Transfer::DIRECTION direction) const
 Get Transfers by ExecFlagType and direction. More...
 
std::vector< std::shared_ptr< Transfer > > getTransfers (Transfer::DIRECTION direction) const
 
const ExecuteMooseObjectWarehouse< Transfer > & getMultiAppTransferWarehouse (Transfer::DIRECTION direction) const
 Return the complete warehouse for MultiAppTransfer object for the given direction. More...
 
void execMultiAppTransfers (ExecFlagType type, Transfer::DIRECTION direction)
 Execute MultiAppTransfers associated with execution flag and direction. More...
 
bool execMultiApps (ExecFlagType type, bool auto_advance=true)
 Execute the MultiApps associated with the ExecFlagType. More...
 
void finalizeMultiApps ()
 
void incrementMultiAppTStep (ExecFlagType type)
 Advance the MultiApps t_step (incrementStepOrReject) associated with the ExecFlagType. More...
 
void advanceMultiApps (ExecFlagType type)
 Deprecated method; use finishMultiAppStep and/or incrementMultiAppTStep depending on your purpose. More...
 
void finishMultiAppStep (ExecFlagType type, bool recurse_through_multiapp_levels=false)
 Finish the MultiApp time step (endStep, postStep) associated with the ExecFlagType. More...
 
void backupMultiApps (ExecFlagType type)
 Backup the MultiApps associated with the ExecFlagType. More...
 
void restoreMultiApps (ExecFlagType type, bool force=false)
 Restore the MultiApps associated with the ExecFlagType. More...
 
Real computeMultiAppsDT (ExecFlagType type)
 Find the smallest timestep over all MultiApps. More...
 
void execTransfers (ExecFlagType type)
 Execute the Transfers associated with the ExecFlagType. More...
 
Real computeResidualL2Norm (NonlinearSystemBase &sys)
 Computes the residual of a nonlinear system using whatever is sitting in the current solution vector then returns the L2 norm. More...
 
Real computeResidualL2Norm (LinearSystem &sys)
 Computes the residual of a linear system using whatever is sitting in the current solution vector then returns the L2 norm. More...
 
virtual Real computeResidualL2Norm ()
 Computes the residual using whatever is sitting in the current solution vector then returns the L2 norm. More...
 
virtual void computeResidualSys (libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual)
 This function is called by Libmesh to form a residual. More...
 
void computeResidual (libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual)
 This function is called by Libmesh to form a residual. More...
 
virtual void computeResidual (const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual, const unsigned int nl_sys_num)
 Form a residual with default tags (nontime, time, residual). More...
 
void computeResidualAndJacobian (const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual, libMesh::SparseMatrix< libMesh::Number > &jacobian)
 Form a residual and Jacobian with default tags. More...
 
virtual void computeResidualTag (const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual, TagID tag)
 Form a residual vector for a given tag. More...
 
virtual void computeResidualType (const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual, TagID tag)
 Form a residual vector for a given tag and "residual" tag. More...
 
virtual void computeResidualInternal (const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual, const std::set< TagID > &tags)
 Form a residual vector for a set of tags. More...
 
virtual void computeResidualTags (const std::set< TagID > &tags)
 Form multiple residual vectors and each is associated with one tag. More...
 
virtual void computeJacobianSys (libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian)
 Form a Jacobian matrix. More...
 
virtual void computeJacobian (const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian, const unsigned int nl_sys_num)
 Form a Jacobian matrix with the default tag (system). More...
 
virtual void computeJacobianTag (const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian, TagID tag)
 Form a Jacobian matrix for a given tag. More...
 
virtual void computeJacobianInternal (const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian, const std::set< TagID > &tags)
 Form a Jacobian matrix for multiple tags. More...
 
virtual void computeJacobianTags (const std::set< TagID > &tags)
 Form multiple matrices, and each is associated with a tag. More...
 
virtual void computeJacobianBlocks (std::vector< JacobianBlock *> &blocks, const unsigned int nl_sys_num)
 Computes several Jacobian blocks simultaneously, summing their contributions into smaller preconditioning matrices. More...
 
virtual void computeJacobianBlock (libMesh::SparseMatrix< libMesh::Number > &jacobian, libMesh::System &precond_system, unsigned int ivar, unsigned int jvar)
 Really not a good idea to use this. More...
 
virtual void computeLinearSystemSys (libMesh::LinearImplicitSystem &sys, libMesh::SparseMatrix< libMesh::Number > &system_matrix, NumericVector< libMesh::Number > &rhs, const bool compute_gradients=true)
 Assemble both the right hand side and the system matrix of a given linear system. More...
 
void computeLinearSystemTags (const NumericVector< libMesh::Number > &soln, const std::set< TagID > &vector_tags, const std::set< TagID > &matrix_tags, const bool compute_gradients=true)
 Assemble the current linear system given a set of vector and matrix tags. More...
 
virtual Real computeDamping (const NumericVector< libMesh::Number > &soln, const NumericVector< libMesh::Number > &update)
 
virtual bool shouldUpdateSolution ()
 Check to see whether the problem should update the solution. More...
 
virtual bool updateSolution (NumericVector< libMesh::Number > &vec_solution, NumericVector< libMesh::Number > &ghosted_solution)
 Update the solution. More...
 
virtual void predictorCleanup (NumericVector< libMesh::Number > &ghosted_solution)
 Perform cleanup tasks after application of predictor to solution vector. More...
 
virtual void computeBounds (libMesh::NonlinearImplicitSystem &sys, NumericVector< libMesh::Number > &lower, NumericVector< libMesh::Number > &upper)
 
virtual void computeNearNullSpace (libMesh::NonlinearImplicitSystem &sys, std::vector< NumericVector< libMesh::Number > *> &sp)
 
virtual void computeNullSpace (libMesh::NonlinearImplicitSystem &sys, std::vector< NumericVector< libMesh::Number > *> &sp)
 
virtual void computeTransposeNullSpace (libMesh::NonlinearImplicitSystem &sys, std::vector< NumericVector< libMesh::Number > *> &sp)
 
virtual void computePostCheck (libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &old_soln, NumericVector< libMesh::Number > &search_direction, NumericVector< libMesh::Number > &new_soln, bool &changed_search_direction, bool &changed_new_soln)
 
virtual void computeIndicatorsAndMarkers ()
 
virtual void computeIndicators ()
 
virtual void computeMarkers ()
 
virtual void addResidual (const THREAD_ID tid) override
 
virtual void addResidualNeighbor (const THREAD_ID tid) override
 
virtual void addResidualLower (const THREAD_ID tid) override
 
virtual void addResidualScalar (const THREAD_ID tid=0)
 
virtual void cacheResidual (const THREAD_ID tid) override
 
virtual void cacheResidualNeighbor (const THREAD_ID tid) override
 
virtual void addCachedResidual (const THREAD_ID tid) override
 
virtual void addCachedResidualDirectly (NumericVector< libMesh::Number > &residual, const THREAD_ID tid)
 Allows for all the residual contributions that are currently cached to be added directly into the vector passed in. More...
 
virtual void setResidual (NumericVector< libMesh::Number > &residual, const THREAD_ID tid) override
 
virtual void setResidual (libMesh::NumericVector< libMesh::Number > &residual, const THREAD_ID tid)=0
 
virtual void setResidualNeighbor (NumericVector< libMesh::Number > &residual, const THREAD_ID tid) override
 
virtual void setResidualNeighbor (libMesh::NumericVector< libMesh::Number > &residual, const THREAD_ID tid)=0
 
virtual void addJacobian (const THREAD_ID tid) override
 
virtual void addJacobianNeighbor (const THREAD_ID tid) override
 
virtual void addJacobianNeighbor (libMesh::SparseMatrix< libMesh::Number > &jacobian, unsigned int ivar, unsigned int jvar, const DofMap &dof_map, std::vector< dof_id_type > &dof_indices, std::vector< dof_id_type > &neighbor_dof_indices, const std::set< TagID > &tags, const THREAD_ID tid) override
 
virtual void addJacobianNeighbor (libMesh::SparseMatrix< libMesh::Number > &jacobian, unsigned int ivar, unsigned int jvar, const libMesh::DofMap &dof_map, std::vector< dof_id_type > &dof_indices, std::vector< dof_id_type > &neighbor_dof_indices, const std::set< TagID > &tags, const THREAD_ID tid)=0
 
virtual void addJacobianNeighborLowerD (const THREAD_ID tid) override
 
virtual void addJacobianLowerD (const THREAD_ID tid) override
 
virtual void addJacobianBlockTags (libMesh::SparseMatrix< libMesh::Number > &jacobian, unsigned int ivar, unsigned int jvar, const DofMap &dof_map, std::vector< dof_id_type > &dof_indices, const std::set< TagID > &tags, const THREAD_ID tid)
 
virtual void addJacobianScalar (const THREAD_ID tid=0)
 
virtual void addJacobianOffDiagScalar (unsigned int ivar, const THREAD_ID tid=0)
 
virtual void cacheJacobian (const THREAD_ID tid) override
 
virtual void cacheJacobianNeighbor (const THREAD_ID tid) override
 
virtual void addCachedJacobian (const THREAD_ID tid) override
 
virtual void prepareShapes (unsigned int var, const THREAD_ID tid) override
 
virtual void prepareFaceShapes (unsigned int var, const THREAD_ID tid) override
 
virtual void prepareNeighborShapes (unsigned int var, const THREAD_ID tid) override
 
virtual void addDisplacedProblem (std::shared_ptr< DisplacedProblem > displaced_problem)
 
virtual std::shared_ptr< const DisplacedProblemgetDisplacedProblem () const
 
virtual std::shared_ptr< DisplacedProblemgetDisplacedProblem ()
 
virtual void updateGeomSearch (GeometricSearchData::GeometricSearchType type=GeometricSearchData::ALL) override
 Update this object's geometric search data as well as the displaced problem's if it exists. More...
 
virtual void updateMortarMesh ()
 
void createMortarInterface (const std::pair< BoundaryID, BoundaryID > &primary_secondary_boundary_pair, const std::pair< SubdomainID, SubdomainID > &primary_secondary_subdomain_pair, bool on_displaced, bool periodic, const bool debug, const bool correct_edge_dropping, const Real minimum_projection_angle, const Mortar3DSubpatchPlane mortar_3d_subpatch_plane, const MooseEnum &triangulation, const bool triangulate_triangles, const Mortar3DQuadraturePointMapping mortar_3d_qp_mapping=Mortar3DQuadraturePointMapping::NORMAL_PROJECTION)
 
const std::unordered_map< std::pair< BoundaryID, BoundaryID >, MortarInterfaceConfig > & getMortarInterfaces (bool on_displaced) const
 
virtual void possiblyRebuildGeomSearchPatches ()
 
virtual GeometricSearchDatageomSearchData () override
 
void setRestartFile (const std::string &file_name)
 Communicate to the Resurector the name of the restart filer. More...
 
const MaterialPropertyRegistrygetMaterialPropertyRegistry () const
 
const InitialConditionWarehousegetInitialConditionWarehouse () const
 Return InitialCondition storage. More...
 
const FVInitialConditionWarehousegetFVInitialConditionWarehouse () const
 Return FVInitialCondition storage. More...
 
SolverParamssolverParams (unsigned int solver_sys_num=0)
 Get the solver parameters. More...
 
const SolverParamssolverParams (unsigned int solver_sys_num=0) const
 const version More...
 
Adaptivityadaptivity ()
 
virtual void initialAdaptMesh ()
 
virtual bool adaptMesh ()
 
unsigned int getNumCyclesCompleted ()
 
bool hasInitialAdaptivity () const
 Return a Boolean indicating whether initial AMR is turned on. More...
 
bool hasInitialAdaptivity () const
 Return a Boolean indicating whether initial AMR is turned on. More...
 
void initXFEM (std::shared_ptr< XFEMInterface > xfem)
 Create XFEM controller object. More...
 
std::shared_ptr< XFEMInterfacegetXFEM ()
 Get a pointer to the XFEM controller object. More...
 
bool haveXFEM ()
 Find out whether the current analysis is using XFEM. More...
 
virtual bool updateMeshXFEM ()
 Update the mesh due to changing XFEM cuts. More...
 
virtual void meshChanged (bool intermediate_change, bool contract_mesh, bool clean_refinement_flags)
 Update data after a mesh change. More...
 
void notifyWhenMeshChanges (MeshChangedInterface *mci)
 Register an object that derives from MeshChangedInterface to be notified when the mesh changes. More...
 
void notifyWhenMeshDisplaces (MeshDisplacedInterface *mdi)
 Register an object that derives from MeshDisplacedInterface to be notified when the displaced mesh gets updated. More...
 
void initElementStatefulProps (const libMesh::ConstElemRange &elem_range, const bool threaded)
 Initialize stateful properties for elements in a specific elem_range This is needed when elements/boundary nodes are added to a specific subdomain at an intermediate step. More...
 
void initKokkosStatefulProps ()
 
virtual void checkProblemIntegrity ()
 Method called to perform a series of sanity checks before a simulation is run. More...
 
void registerRandomInterface (RandomInterface &random_interface, const std::string &name)
 
void setConstJacobian (bool state)
 Set flag that Jacobian is constant (for optimization purposes) More...
 
void setKernelCoverageCheck (CoverageCheckMode mode)
 Set flag to indicate whether kernel coverage checks should be performed. More...
 
void setKernelCoverageCheck (bool flag)
 Set flag to indicate whether kernel coverage checks should be performed. More...
 
void setMaterialCoverageCheck (CoverageCheckMode mode)
 Set flag to indicate whether material coverage checks should be performed. More...
 
void setMaterialCoverageCheck (bool flag)
 Set flag to indicate whether material coverage checks should be performed. More...
 
void setParallelBarrierMessaging (bool flag)
 Toggle parallel barrier messaging (defaults to on). More...
 
void setVerboseProblem (bool verbose)
 Make the problem be verbose. More...
 
bool verboseMultiApps () const
 Whether or not to use verbose printing for MultiApps. More...
 
void parentOutputPositionChanged ()
 Calls parentOutputPositionChanged() on all sub apps. More...
 
unsigned int subspaceDim (const std::string &prefix) const
 Dimension of the subspace spanned by vectors with a given prefix. More...
 
const MooseObjectWarehouse< Function > & getFunctionWarehouse ()
 
const MaterialWarehousegetMaterialWarehouse () const
 
const MaterialWarehousegetRegularMaterialsWarehouse () const
 
const MaterialWarehousegetDiscreteMaterialWarehouse () const
 
const MaterialWarehousegetInterfaceMaterialsWarehouse () const
 
const MaterialWarehousegetKokkosMaterialsWarehouse () const
 
std::shared_ptr< MaterialBasegetMaterial (std::string name, Moose::MaterialDataType type, const THREAD_ID tid=0, bool no_warn=false)
 Return a pointer to a MaterialBase object. More...
 
MaterialDatagetMaterialData (Moose::MaterialDataType type, const THREAD_ID tid=0, const MooseObject *object=nullptr) const
 
MaterialDatagetKokkosMaterialData (Moose::MaterialDataType type, const MooseObject *object=nullptr) const
 
const std::set< const MooseObject * > & getMaterialPropertyStorageConsumers (Moose::MaterialDataType type) const
 
const std::set< const MooseObject * > & getKokkosMaterialPropertyStorageConsumers (Moose::MaterialDataType type) const
 
bool restoreOriginalNonzeroPattern () const
 
bool errorOnJacobianNonzeroReallocation () const
 Will return True if the user wants to get an error when a nonzero is reallocated in the Jacobian by PETSc. More...
 
void setErrorOnJacobianNonzeroReallocation (bool state)
 
bool preserveMatrixSparsityPattern () const
 Will return True if the executioner in use requires preserving the sparsity pattern of the matrices being formed during the solve. More...
 
void setPreserveMatrixSparsityPattern (bool preserve)
 Set whether the sparsity pattern of the matrices being formed during the solve (usually the Jacobian) should be preserved. More...
 
bool ignoreZerosInJacobian () const
 Will return true if zeros in the Jacobian are to be dropped from the sparsity pattern. More...
 
void setIgnoreZerosInJacobian (bool state)
 Set whether the zeros in the Jacobian should be dropped from the sparsity pattern. More...
 
bool acceptInvalidSolution () const
 Whether or not to accept the solution based on its invalidity. More...
 
bool allowInvalidSolution () const
 Whether to accept / allow an invalid solution. More...
 
bool showInvalidSolutionConsole () const
 Whether or not to print out the invalid solutions summary table in console. More...
 
bool immediatelyPrintInvalidSolution () const
 Whether or not the solution invalid warnings are printed out immediately. More...
 
bool hasTimeIntegrator () const
 Returns whether or not this Problem has a TimeIntegrator. More...
 
virtual void executeAllObjects (const ExecFlagType &exec_type)
 
virtual ExecutorgetExecutor (const std::string &name)
 
virtual void computeUserObjects (const ExecFlagType &type, const Moose::AuxGroup &group)
 Call compute methods on UserObjects. More...
 
virtual void computeUserObjectByName (const ExecFlagType &type, const Moose::AuxGroup &group, const std::string &name)
 Compute an user object with the given name. More...
 
void needsPreviousNewtonIteration (bool state)
 Set a flag that indicated that user required values for the previous Newton iterate. More...
 
bool needsPreviousNewtonIteration () const
 Check to see whether we need to compute the variable values of the previous Newton iterate. More...
 
void needsPreviousMultiAppFixedPointIterationSolution (bool needed, const unsigned int solver_sys_num)
 Set a flag that indicated that user required values for the previous multiapp fixed point iterate for the solver systems (not auxiliary) More...
 
bool needsPreviousMultiAppFixedPointIterationSolution (const unsigned int solver_sys_num) const
 Check to see whether we need to compute the variable values of the previous multiapp fixed point iteration for the solver systems (not auxiliary) More...
 
void needsPreviousMultiAppFixedPointIterationAuxiliary (bool state)
 Set a flag that indicated that user required values for the previous multiapp fixed point iterate for the auxiliary system. More...
 
bool needsPreviousMultiAppFixedPointIterationAuxiliary () const
 Check to see whether we need to compute the variable values of the previous multiapp fixed point iteration for the auxiliary system. More...
 
ExecuteMooseObjectWarehouse< Control > & getControlWarehouse ()
 Reference to the control logic warehouse. More...
 
void executeControls (const ExecFlagType &exec_type)
 Performs setup and execute calls for Control objects. More...
 
void executeSamplers (const ExecFlagType &exec_type)
 Performs setup and execute calls for Sampler objects. More...
 
virtual void updateActiveObjects ()
 Update the active objects in the warehouses. More...
 
void reportMooseObjectDependency (MooseObject *a, MooseObject *b)
 Register a MOOSE object dependency so we can either order operations properly or report when we cannot. More...
 
ExecuteMooseObjectWarehouse< MultiApp > & getMultiAppWarehouse ()
 
bool hasJacobian () const
 Returns _has_jacobian. More...
 
bool constJacobian () const
 Returns _const_jacobian (whether a MOOSE object has specified that the Jacobian is the same as the previous time it was computed) More...
 
void addOutput (const std::string &, const std::string &, InputParameters &)
 Adds an Output object. More...
 
TheWarehousetheWarehouse () const
 
void setSNESMFReuseBase (bool reuse, bool set_by_user)
 If or not to reuse the base vector for matrix-free calculation. More...
 
bool useSNESMFReuseBase ()
 Return a flag that indicates if we are reusing the vector base. More...
 
void skipExceptionCheck (bool skip_exception_check)
 Set a flag that indicates if we want to skip exception and stop solve. More...
 
bool isSNESMFReuseBaseSetbyUser ()
 Return a flag to indicate if _snesmf_reuse_base is set by users. More...
 
bool & petscOptionsInserted ()
 If PETSc options are already inserted. More...
 
PetscOptions & petscOptionsDatabase ()
 
virtual void setUDotRequested (const bool u_dot_requested)
 Set boolean flag to true to store solution time derivative. More...
 
virtual void setUDotDotRequested (const bool u_dotdot_requested)
 Set boolean flag to true to store solution second time derivative. More...
 
virtual void setUDotOldRequested (const bool u_dot_old_requested)
 Set boolean flag to true to store old solution time derivative. More...
 
virtual void setUDotDotOldRequested (const bool u_dotdot_old_requested)
 Set boolean flag to true to store old solution second time derivative. More...
 
virtual bool uDotRequested ()
 Get boolean flag to check whether solution time derivative needs to be stored. More...
 
virtual bool uDotDotRequested ()
 Get boolean flag to check whether solution second time derivative needs to be stored. More...
 
virtual bool uDotOldRequested ()
 Get boolean flag to check whether old solution time derivative needs to be stored. More...
 
virtual bool uDotDotOldRequested ()
 Get boolean flag to check whether old solution second time derivative needs to be stored. More...
 
void haveADObjects (bool have_ad_objects) override
 Method for setting whether we have any ad objects. More...
 
virtual void haveADObjects (bool have_ad_objects)
 Method for setting whether we have any ad objects. More...
 
bool haveADObjects () const
 Method for reading wehther we have any ad objects. More...
 
bool haveADObjects () const
 Method for reading wehther we have any ad objects. More...
 
bool shouldSolve () const
 
const MortarInterfaceWarehousemortarData () const
 Returns the mortar data object. More...
 
MortarInterfaceWarehousemortarData ()
 
virtual bool hasNeighborCoupling () const
 Whether the simulation has neighbor coupling. More...
 
virtual bool hasMortarCoupling () const
 Whether the simulation has mortar coupling. More...
 
void computingNonlinearResid (bool computing_nonlinear_residual) final
 Set whether or not the problem is in the process of computing the nonlinear residual. More...
 
bool computingNonlinearResid () const
 Returns true if the problem is in the process of computing the nonlinear residual. More...
 
virtual void computingNonlinearResid (const bool computing_nonlinear_residual)
 Set whether or not the problem is in the process of computing the nonlinear residual. More...
 
bool computingNonlinearResid () const
 Returns true if the problem is in the process of computing the nonlinear residual. More...
 
void setCurrentlyComputingResidual (bool currently_computing_residual) final
 Set whether or not the problem is in the process of computing the residual. More...
 
void numGridSteps (unsigned int num_grid_steps)
 Set the number of steps in a grid sequences. More...
 
void uniformRefine ()
 uniformly refine the problem mesh(es). More...
 
void automaticScaling (bool automatic_scaling) override
 Automatic scaling setter. More...
 
virtual void automaticScaling (bool automatic_scaling)
 Automatic scaling setter. More...
 
bool automaticScaling () const
 Automatic scaling getter. More...
 
bool automaticScaling () const
 Automatic scaling getter. More...
 
virtual void reinitElemFaceRef (const Elem *elem, unsigned int side, Real tolerance, const std::vector< Point > *const pts, const std::vector< Real > *const weights=nullptr, const THREAD_ID tid=0) override
 reinitialize FE objects on a given element on a given side at a given set of reference points and then compute variable data. More...
 
virtual void reinitNeighborFaceRef (const Elem *neighbor_elem, unsigned int neighbor_side, Real tolerance, const std::vector< Point > *const pts, const std::vector< Real > *const weights=nullptr, const THREAD_ID tid=0) override
 reinitialize FE objects on a given neighbor element on a given side at a given set of reference points and then compute variable data. More...
 
bool fvBCsIntegrityCheck () const
 
void fvBCsIntegrityCheck (bool fv_bcs_integrity_check)
 
void getFVMatsAndDependencies (SubdomainID block_id, std::vector< std::shared_ptr< MaterialBase >> &face_materials, std::vector< std::shared_ptr< MaterialBase >> &neighbor_materials, std::set< MooseVariableFieldBase *> &variables, const THREAD_ID tid)
 Get the materials and variables potentially needed for FV. More...
 
void resizeMaterialData (Moose::MaterialDataType data_type, unsigned int nqp, const THREAD_ID tid)
 Resize material data. More...
 
bool haveDisplaced () const override final
 Whether we have a displaced problem in our simulation. More...
 
bool hasLinearConvergenceObjects () const
 Whether we have linear convergence objects. More...
 
void setNonlinearConvergenceNames (const std::vector< ConvergenceName > &convergence_names)
 Sets the nonlinear convergence object name(s) if there is one. More...
 
void setLinearConvergenceNames (const std::vector< ConvergenceName > &convergence_names)
 Sets the linear convergence object name(s) if there is one. More...
 
void setMultiAppFixedPointConvergenceName (const ConvergenceName &convergence_name)
 Sets the MultiApp fixed point convergence object name if there is one. More...
 
void setSteadyStateConvergenceName (const ConvergenceName &convergence_name)
 Sets the steady-state detection convergence object name if there is one. More...
 
const std::vector< ConvergenceName > & getNonlinearConvergenceNames () const
 Gets the nonlinear system convergence object name(s). More...
 
const std::vector< ConvergenceName > & getLinearConvergenceNames () const
 Gets the linear convergence object name(s). More...
 
const ConvergenceName & getMultiAppFixedPointConvergenceName () const
 Gets the MultiApp fixed point convergence object name. More...
 
const ConvergenceName & getSteadyStateConvergenceName () const
 Gets the steady-state detection convergence object name. More...
 
void computingScalingJacobian (bool computing_scaling_jacobian)
 Setter for whether we're computing the scaling jacobian. More...
 
bool computingScalingJacobian () const override final
 Getter for whether we're computing the scaling jacobian. More...
 
void computingScalingResidual (bool computing_scaling_residual)
 Setter for whether we're computing the scaling residual. More...
 
bool computingScalingResidual () const override final
 
MooseAppCoordTransformcoordTransform ()
 
virtual std::size_t numNonlinearSystems () const override
 
virtual std::size_t numLinearSystems () const override
 
virtual std::size_t numSolverSystems () const override
 
bool isSolverSystemNonlinear (const unsigned int sys_num)
 Check if the solver system is nonlinear. More...
 
virtual unsigned int currentNlSysNum () const override
 
virtual unsigned int currentLinearSysNum () const override
 
virtual unsigned int nlSysNum (const NonlinearSystemName &nl_sys_name) const override
 
unsigned int linearSysNum (const LinearSystemName &linear_sys_name) const override
 
unsigned int solverSysNum (const SolverSystemName &solver_sys_name) const override
 
unsigned int systemNumForVariable (const VariableName &variable_name) const
 
bool getFailNextNonlinearConvergenceCheck () const
 Whether it will skip further residual evaluations and fail the next nonlinear convergence check(s) More...
 
bool getFailNextSystemConvergenceCheck () const
 Whether it will fail the next system convergence check(s), triggering failed step behavior. More...
 
void setFailNextNonlinearConvergenceCheck ()
 Skip further residual evaluations and fail the next nonlinear convergence check(s) More...
 
void setFailNextSystemConvergenceCheck ()
 Tell the problem that the system(s) cannot be considered converged next time convergence is checked. More...
 
void resetFailNextNonlinearConvergenceCheck ()
 Tell the problem that the nonlinear convergence check(s) may proceed as normal. More...
 
void resetFailNextSystemConvergenceCheck ()
 Tell the problem that the system convergence check(s) may proceed as normal. More...
 
void setExecutionPrinting (const ExecFlagEnum &print_exec)
 
bool shouldPrintExecution (const THREAD_ID tid) const
 Check whether the problem should output execution orders at this time. More...
 
void reinitMortarUserObjects (BoundaryID primary_boundary_id, BoundaryID secondary_boundary_id, bool displaced)
 Call reinit on mortar user objects with matching primary boundary ID, secondary boundary ID, and displacement characteristics. More...
 
virtual const std::vector< VectorTag > & currentResidualVectorTags () const override
 Return the residual vector tags we are currently computing. More...
 
void setCurrentResidualVectorTags (const std::set< TagID > &vector_tags)
 Set the current residual vector tag data structure based on the passed in tag IDs. More...
 
void clearCurrentResidualVectorTags ()
 Clear the current residual vector tag data structure. More...
 
void clearCurrentJacobianMatrixTags ()
 Clear the current Jacobian matrix tag data structure ... More...
 
virtual void needFV () override
 marks this problem as including/needing finite volume functionality. More...
 
virtual bool haveFV () const override
 returns true if this problem includes/needs finite volume functionality. More...
 
virtual bool hasNonlocalCoupling () const override
 Whether the simulation has active nonlocal coupling which should be accounted for in the Jacobian. More...
 
bool identifyVariableGroupsInNL () const
 Whether to identify variable groups in nonlinear systems. More...
 
virtual void setCurrentLowerDElem (const Elem *const lower_d_elem, const THREAD_ID tid) override
 Set the current lower dimensional element. More...
 
virtual void setCurrentBoundaryID (BoundaryID bid, const THREAD_ID tid) override
 sets the current boundary ID in assembly More...
 
const std::vector< NonlinearSystemName > & getNonlinearSystemNames () const
 
const std::vector< LinearSystemName > & getLinearSystemNames () const
 
const std::vector< SolverSystemName > & getSolverSystemNames () const
 
virtual const libMesh::CouplingMatrixnonlocalCouplingMatrix (const unsigned i) const override
 
virtual bool checkNonlocalCouplingRequirement () const override
 
void createTagMatrices (CreateTaggedMatrixKey)
 
bool useHashTableMatrixAssembly () const
 
bool hasKokkosObjects () const
 
bool hasKokkosResidualObjects () const
 
void addKokkosMeshInitializationHook (std::function< void()> function)
 Add a function hook that needs to be called after Kokkos mesh initialization. More...
 
const bool & currentlyComputingResidual () const
 Returns true if the problem is in the process of computing the residual. More...
 
const bool & currentlyComputingResidual () const
 Returns true if the problem is in the process of computing the residual. More...
 
virtual bool nlConverged (const unsigned int nl_sys_num)
 
virtual bool converged (const unsigned int sys_num)
 Eventually we want to convert this virtual over to taking a solver system number argument. More...
 
bool defaultGhosting ()
 Whether or not the user has requested default ghosting ot be on. More...
 
virtual TagID addVectorTag (const TagName &tag_name, const Moose::VectorTagType type=Moose::VECTOR_TAG_RESIDUAL)
 Create a Tag. More...
 
void addNotZeroedVectorTag (const TagID tag)
 Adds a vector tag to the list of vectors that will not be zeroed when other tagged vectors are. More...
 
bool vectorTagNotZeroed (const TagID tag) const
 Checks if a vector tag is in the list of vectors that will not be zeroed when other tagged vectors are. More...
 
virtual const VectorTaggetVectorTag (const TagID tag_id) const
 Get a VectorTag from a TagID. More...
 
std::vector< VectorTaggetVectorTags (const std::set< TagID > &tag_ids) const
 
virtual const std::vector< VectorTag > & getVectorTags (const Moose::VectorTagType type=Moose::VECTOR_TAG_ANY) const
 Return all vector tags, where a tag is represented by a map from name to ID. More...
 
virtual TagID getVectorTagID (const TagName &tag_name) const
 Get a TagID from a TagName. More...
 
virtual TagName vectorTagName (const TagID tag) const
 Retrieve the name associated with a TagID. More...
 
virtual bool vectorTagExists (const TagID tag_id) const
 Check to see if a particular Tag exists. More...
 
virtual bool vectorTagExists (const TagName &tag_name) const
 Check to see if a particular Tag exists by using Tag name. More...
 
virtual unsigned int numVectorTags (const Moose::VectorTagType type=Moose::VECTOR_TAG_ANY) const
 The total number of tags, which can be limited to the tag type. More...
 
virtual Moose::VectorTagType vectorTagType (const TagID tag_id) const
 
virtual TagID addMatrixTag (TagName tag_name)
 Create a Tag. More...
 
virtual TagID getMatrixTagID (const TagName &tag_name) const
 Get a TagID from a TagName. More...
 
virtual TagName matrixTagName (TagID tag)
 Retrieve the name associated with a TagID. More...
 
virtual bool matrixTagExists (const TagName &tag_name) const
 Check to see if a particular Tag exists. More...
 
virtual bool matrixTagExists (TagID tag_id) const
 Check to see if a particular Tag exists. More...
 
virtual unsigned int numMatrixTags () const
 The total number of tags. More...
 
virtual std::map< TagName, TagID > & getMatrixTags ()
 Return all matrix tags in the system, where a tag is represented by a map from name to ID. More...
 
virtual bool hasLinearVariable (const std::string &var_name) const
 Whether or not this problem has this linear variable. More...
 
virtual bool hasAuxiliaryVariable (const std::string &var_name) const
 Whether or not this problem has this auxiliary variable. More...
 
virtual const std::set< MooseVariableFieldBase * > & getActiveElementalMooseVariables (const THREAD_ID tid) const
 Get the MOOSE variables to be reinited on each element. More...
 
virtual bool hasActiveElementalMooseVariables (const THREAD_ID tid) const
 Whether or not a list of active elemental moose variables has been set. More...
 
Moose::CoordinateSystemType getCoordSystem (SubdomainID sid) const
 
unsigned int getAxisymmetricRadialCoord () const
 Returns the desired radial direction for RZ coordinate transformation. More...
 
virtual DiracKernelInfodiracKernelInfo ()
 
void reinitNeighborLowerDElem (const Elem *elem, const THREAD_ID tid=0)
 reinitialize a neighboring lower dimensional element More...
 
void reinitMortarElem (const Elem *elem, const THREAD_ID tid=0)
 Reinit a mortar element to obtain a valid JxW. More...
 
void reinitGeomSearch ()
 reinitialize this object's geometric search data, e.g. More...
 
virtual void storeSubdomainMatPropName (SubdomainID block_id, const std::string &name)
 Adds the given material property to a storage map based on block ids. More...
 
virtual void storeBoundaryMatPropName (BoundaryID boundary_id, const std::string &name)
 Adds the given material property to a storage map based on boundary ids. More...
 
virtual void storeSubdomainZeroMatProp (SubdomainID block_id, const MaterialPropertyName &name)
 Adds to a map based on block ids of material properties for which a zero value can be returned. More...
 
virtual void storeBoundaryZeroMatProp (BoundaryID boundary_id, const MaterialPropertyName &name)
 Adds to a map based on boundary ids of material properties for which a zero value can be returned. More...
 
virtual void storeSubdomainDelayedCheckMatProp (const std::string &requestor, SubdomainID block_id, const std::string &name)
 Adds to a map based on block ids of material properties to validate. More...
 
virtual void storeBoundaryDelayedCheckMatProp (const std::string &requestor, BoundaryID boundary_id, const std::string &name)
 Adds to a map based on boundary ids of material properties to validate. More...
 
virtual void checkBlockMatProps ()
 Checks block material properties integrity. More...
 
virtual void checkBoundaryMatProps ()
 Checks boundary material properties integrity. More...
 
virtual void markMatPropRequested (const std::string &)
 Helper method for adding a material property name to the _material_property_requested set. More...
 
virtual bool isMatPropRequested (const std::string &prop_name) const
 Find out if a material property has been requested by any object. More...
 
void addConsumedPropertyName (const MooseObjectName &obj_name, const std::string &prop_name)
 Helper for tracking the object that is consuming a property for MaterialPropertyDebugOutput. More...
 
const std::map< MooseObjectName, std::set< std::string > > & getConsumedPropertyMap () const
 Return the map that tracks the object with consumed material properties. More...
 
virtual std::set< SubdomainIDgetMaterialPropertyBlocks (const std::string &prop_name)
 Get a vector containing the block ids the material property is defined on. More...
 
virtual std::vector< SubdomainName > getMaterialPropertyBlockNames (const std::string &prop_name)
 Get a vector of block id equivalences that the material property is defined on. More...
 
virtual bool hasBlockMaterialProperty (SubdomainID block_id, const std::string &prop_name)
 Check if a material property is defined on a block. More...
 
virtual std::set< BoundaryIDgetMaterialPropertyBoundaryIDs (const std::string &prop_name)
 Get a vector containing the block ids the material property is defined on. More...
 
virtual std::vector< BoundaryName > getMaterialPropertyBoundaryNames (const std::string &prop_name)
 Get a vector of block id equivalences that the material property is defined on. More...
 
virtual bool hasBoundaryMaterialProperty (BoundaryID boundary_id, const std::string &prop_name)
 Check if a material property is defined on a block. More...
 
virtual std::set< dof_id_type > & ghostedElems ()
 Return the list of elements that should have their DoFs ghosted to this processor. More...
 
const bool & currentlyComputingJacobian () const
 Returns true if the problem is in the process of computing the Jacobian. More...
 
void setCurrentlyComputingJacobian (const bool currently_computing_jacobian)
 Set whether or not the problem is in the process of computing the Jacobian. More...
 
const bool & currentlyComputingResidualAndJacobian () const
 Returns true if the problem is in the process of computing the residual and the Jacobian. More...
 
void setCurrentlyComputingResidualAndJacobian (bool currently_computing_residual_and_jacobian)
 Set whether or not the problem is in the process of computing the Jacobian. More...
 
virtual bool safeAccessTaggedMatrices () const
 Is it safe to access the tagged matrices. More...
 
virtual bool safeAccessTaggedVectors () const
 Is it safe to access the tagged vectors. More...
 
const std::set< TagID > & getActiveScalarVariableCoupleableVectorTags (const THREAD_ID tid) const
 
const std::set< TagID > & getActiveScalarVariableCoupleableMatrixTags (const THREAD_ID tid) const
 
const std::set< TagID > & getActiveFEVariableCoupleableVectorTags (const THREAD_ID tid) const
 
const std::set< TagID > & getActiveFEVariableCoupleableMatrixTags (const THREAD_ID tid) const
 
void addAlgebraicGhostingFunctor (libMesh::GhostingFunctor &algebraic_gf, bool to_mesh=true)
 Add an algebraic ghosting functor to this problem's DofMaps. More...
 
void addCouplingGhostingFunctor (libMesh::GhostingFunctor &coupling_gf, bool to_mesh=true)
 Add a coupling functor to this problem's DofMaps. More...
 
void removeAlgebraicGhostingFunctor (libMesh::GhostingFunctor &algebraic_gf)
 Remove an algebraic ghosting functor from this problem's DofMaps. More...
 
void removeCouplingGhostingFunctor (libMesh::GhostingFunctor &coupling_gf)
 Remove a coupling ghosting functor from this problem's DofMaps. More...
 
void hasScalingVector (const unsigned int nl_sys_num)
 Tells this problem that the assembly associated with the given nonlinear system number involves a scaling vector. More...
 
void clearAllDofIndices ()
 Clear dof indices from variables in nl and aux systems. More...
 
template<typename T >
const Moose::Functor< T > & getFunctor (const std::string &name, const THREAD_ID tid, const std::string &requestor_name, bool requestor_is_ad)
 
bool hasFunctor (const std::string &name, const THREAD_ID tid) const
 checks whether we have a functor corresponding to name on the thread id tid More...
 
template<typename T >
bool hasFunctorWithType (const std::string &name, const THREAD_ID tid) const
 checks whether we have a functor of type T corresponding to name on the thread id tid More...
 
template<typename T >
void addFunctor (const std::string &name, const Moose::FunctorBase< T > &functor, const THREAD_ID tid)
 add a functor to the problem functor container More...
 
template<typename T , typename PolymorphicLambda >
const Moose::FunctorBase< T > & addPiecewiseByBlockLambdaFunctor (const std::string &name, PolymorphicLambda my_lammy, const std::set< ExecFlagType > &clearance_schedule, const MooseMesh &mesh, const std::set< SubdomainID > &block_ids, const THREAD_ID tid)
 Add a functor that has block-wise lambda definitions, e.g. More...
 
void setFunctorOutput (bool set_output)
 Setter for debug functor output. More...
 
void setChainControlDataOutput (bool set_output)
 Setter for debug chain control data output. More...
 
template<typename T >
void registerUnfilledFunctorRequest (T *functor_interface, const std::string &functor_name, const THREAD_ID tid)
 Register an unfulfilled functor request. More...
 
void reinitFVFace (const THREAD_ID tid, const FaceInfo &fi)
 reinitialize the finite volume assembly data for the provided face and thread More...
 
void preparePRefinement ()
 Prepare DofMap and Assembly classes with our p-refinement information. More...
 
bool doingPRefinement () const
 
bool havePRefinement () const
 Query whether p-refinement has been requested at any point during the simulation. More...
 
void markFamilyPRefinement (const InputParameters &params)
 Mark a variable family for either disabling or enabling p-refinement with valid parameters of a variable. More...
 
template<typename T >
MooseVariableFEBasegetVariableHelper (const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type, Moose::VarFieldType expected_var_field_type, const std::vector< T > &systems, const SystemBase &aux) const
 
void _setCLIOption ()
 For Internal Use. More...
 
virtual void terminateSolve ()
 Allow objects to request clean termination of the solve. More...
 
virtual bool isSolveTerminationRequested () const
 Check of termination has been requested. More...
 
const ConsoleStreamconsole () const
 Return console handle. More...
 
virtual bool enabled () const
 Return the enabled status of the object. More...
 
std::shared_ptr< MooseObjectgetSharedPtr ()
 Get another shared pointer to this object that has the same ownership group. More...
 
std::shared_ptr< const MooseObjectgetSharedPtr () const
 
bool isKokkosObject () const
 Get whether this object is a Kokkos functor The parameter MooseBase::kokkos_object_param is set by the Kokkos base classes. More...
 
MooseAppgetMooseApp () const
 Get the MooseApp this class is associated with. More...
 
const std::string & type () const
 Get the type of this class. More...
 
const std::string & name () const
 Get the name of the class. More...
 
std::string typeAndName () const
 Get the class's combined type and name; useful in error handling. More...
 
MooseObjectParameterName uniqueParameterName (const std::string &parameter_name) const
 
MooseObjectName uniqueName () const
 
const InputParametersparameters () const
 Get the parameters of the object. More...
 
const hit::Node * getHitNode () const
 
bool hasBase () const
 
const std::string & getBase () const
 
template<typename T >
const T & getParam (const std::string &name) const
 Retrieve a parameter for the object. More...
 
template<typename T1 , typename T2 >
std::vector< std::pair< T1, T2 > > getParam (const std::string &param1, const std::string &param2) const
 Retrieve two parameters and provide pair of parameters for the object. More...
 
template<typename T >
const T * queryParam (const std::string &name) const
 Query a parameter for the object. More...
 
template<typename T >
const T & getRenamedParam (const std::string &old_name, const std::string &new_name) const
 Retrieve a renamed 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...
 
bool isParamSetByUser (const std::string &name) const
 Test if the supplied parameter is set by a user, as opposed to not set or set to default. More...
 
void connectControllableParams (const std::string &parameter, const std::string &object_type, const std::string &object_name, const std::string &object_parameter) const
 Connect controllable parameter of this action with the controllable parameters of the objects added by this action. More...
 
template<typename... Args>
void paramError (const std::string &param, Args... args) const
 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) const
 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 paramWarning (const std::string &param, Args... args) const
 
template<typename... Args>
void paramInfo (const std::string &param, Args... args) const
 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...
 
std::string messagePrefix (const bool hit_prefix=true) const
 
std::string errorPrefix (const std::string &) const
 Deprecated message prefix; the error type is no longer used. More...
 
template<typename... Args>
void mooseError (Args &&... args) const
 Emits an error prefixed with object name and type and optionally a file path to the top-level block parameter if available. More...
 
template<typename... Args>
void mooseDocumentedError (const std::string &repo_name, const unsigned int issue_num, Args &&... args) const
 
template<typename... Args>
void mooseErrorNonPrefixed (Args &&... args) const
 Emits an error without the prefixing included in mooseError(). More...
 
template<typename... Args>
void mooseWarning (Args &&... args) const
 Emits a warning prefixed with object name and type. More...
 
template<typename... Args>
void mooseWarning (Args &&... args) const
 
template<typename... Args>
void mooseWarningNonPrefixed (Args &&... args) const
 Emits a warning without the prefixing included in mooseWarning(). More...
 
template<typename... Args>
void mooseWarningNonPrefixed (Args &&... args) const
 
template<typename... Args>
void mooseDeprecated (Args &&... args) const
 Emits a deprecation warning prefixed with the object name and type, and a stack trace. More...
 
template<typename... Args>
void mooseDeprecated (Args &&... args) const
 
template<typename... Args>
void mooseDeprecatedNoTrace (Args &&... args) const
 Emits a deprecation warning prefixed with the object name and type, and no stack trace. More...
 
template<typename... Args>
void mooseInfo (Args &&... args) const
 
void callMooseError (std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
 External method for calling moose error with added object context. More...
 
const Parallel::Communicatorcomm () const
 
processor_id_type n_processors () const
 
processor_id_type processor_id () const
 
std::string getDataFileName (const std::string &param) const
 Deprecated method. More...
 
std::string getDataFileNameByName (const std::string &relative_path) const
 Deprecated method. More...
 
std::string getDataFilePath (const std::string &relative_path) const
 Returns the path of a data file for a given relative file path. More...
 
PerfGraphperfGraph ()
 Get the PerfGraph. More...
 
const libMesh::ConstElemRangegetEvaluableElementRange ()
 In general, {evaluable elements} >= {local elements} U {algebraic ghosting elements}. More...
 
const libMesh::ConstElemRangegetNonlinearEvaluableElementRange ()
 
const libMesh::ConstElemRangegetCurrentAlgebraicElementRange ()
 These are the element and nodes that contribute to the jacobian and residual for this local processor. More...
 
const libMesh::ConstNodeRangegetCurrentAlgebraicNodeRange ()
 
const ConstBndNodeRangegetCurrentAlgebraicBndNodeRange ()
 
void setCurrentAlgebraicElementRange (libMesh::ConstElemRange *range)
 These functions allow setting custom ranges for the algebraic elements, nodes, and boundary nodes that contribute to the jacobian and residual for this local processor. More...
 
void setCurrentAlgebraicNodeRange (libMesh::ConstNodeRange *range)
 
void setCurrentAlgebraicBndNodeRange (ConstBndNodeRange *range)
 
void allowOutput (bool state)
 Ability to enable/disable all output calls. More...
 
template<typename T >
void allowOutput (bool state)
 
Moose::Kokkos::Array< Moose::Kokkos::System > & getKokkosSystems ()
 Get the Kokkos System array (always populated when any Kokkos object exists) More...
 
const Moose::Kokkos::Array< Moose::Kokkos::System > & getKokkosSystems () const
 
Moose::Kokkos::Array< Moose::Kokkos::FESystem > & getKokkosFESystems ()
 Get the Kokkos FESystem array (populated only when FE Kokkos objects exist) More...
 
const Moose::Kokkos::Array< Moose::Kokkos::FESystem > & getKokkosFESystems () const
 
Moose::Kokkos::SystemgetKokkosSystem (const unsigned int sys_num)
 Get the Kokkos System of a specified number. More...
 
const Moose::Kokkos::SystemgetKokkosSystem (const unsigned int sys_num) const
 
Moose::Kokkos::FESystemgetKokkosFESystem (const unsigned int sys_num)
 Get the Kokkos FESystem of a specified number. More...
 
const Moose::Kokkos::FESystemgetKokkosFESystem (const unsigned int sys_num) const
 
bool hasMultiApps () const
 Returns whether or not the current simulation has any multiapps. More...
 
bool hasMultiApps (ExecFlagType type) const
 
bool hasMultiApp (const std::string &name) const
 
const AutomaticMortarGenerationgetMortarInterface (const std::pair< BoundaryID, BoundaryID > &primary_secondary_boundary_pair, const std::pair< SubdomainID, SubdomainID > &primary_secondary_subdomain_pair, bool on_displaced) const
 Return the undisplaced or displaced mortar generation object associated with the provided boundaries and subdomains. More...
 
AutomaticMortarGenerationgetMortarInterface (const std::pair< BoundaryID, BoundaryID > &primary_secondary_boundary_pair, const std::pair< SubdomainID, SubdomainID > &primary_secondary_subdomain_pair, bool on_displaced)
 
const MaterialPropertyStoragegetMaterialPropertyStorage ()
 Return a reference to the material property storage. More...
 
const MaterialPropertyStoragegetBndMaterialPropertyStorage ()
 
const MaterialPropertyStoragegetNeighborMaterialPropertyStorage ()
 
Moose::Kokkos::MaterialPropertyStoragegetKokkosMaterialPropertyStorage ()
 
Moose::Kokkos::MaterialPropertyStoragegetKokkosBndMaterialPropertyStorage ()
 
Moose::Kokkos::MaterialPropertyStoragegetKokkosNeighborMaterialPropertyStorage ()
 
const MooseObjectWarehouse< Indicator > & getIndicatorWarehouse ()
 Return indicator/marker storage. More...
 
const MooseObjectWarehouse< InternalSideIndicatorBase > & getInternalSideIndicatorWarehouse ()
 
const MooseObjectWarehouse< Marker > & getMarkerWarehouse ()
 
bool needBoundaryMaterialOnSide (BoundaryID bnd_id, const THREAD_ID tid)
 These methods are used to determine whether stateful material properties need to be stored on internal sides. More...
 
bool needInterfaceMaterialOnSide (BoundaryID bnd_id, const THREAD_ID tid)
 
bool needInternalNeighborSideMaterial (SubdomainID subdomain_id, const THREAD_ID tid)
 
const ExecFlagTypegetCurrentExecuteOnFlag () const
 Return/set the current execution flag. More...
 
void setCurrentExecuteOnFlag (const ExecFlagType &)
 

Static Public Member Functions

static InputParameters validParams ()
 Return the input parameters used to construct an MFEM problem. More...
 
static void selectVectorTagsFromSystem (const SystemBase &system, const std::vector< VectorTag > &input_vector_tags, std::set< TagID > &selected_tags)
 Select the vector tags which belong to a specific system. More...
 
static void selectMatrixTagsFromSystem (const SystemBase &system, const std::map< TagName, TagID > &input_matrix_tags, std::set< TagID > &selected_tags)
 Select the matrix tags which belong to a specific system. More...
 
static void callMooseError (MooseApp *const app, const InputParameters &params, std::string msg, const bool with_prefix, const hit::Node *node, const bool show_trace=true)
 External method for calling moose error with added object context. More...
 
template<typename T >
static void objectSetupHelper (const std::vector< T *> &objects, const ExecFlagType &exec_flag)
 Helpers for calling the necessary setup/execute functions for the supplied objects. More...
 
template<typename T >
static void objectExecuteHelper (const std::vector< T *> &objects)
 

Public Attributes

std::map< std::string, std::vector< dof_id_type > > _var_dof_map
 
 usingCombinedWarningSolutionWarnings
 
const ConsoleStream _console
 An instance of helper class to write streams to the Console objects. More...
 
std::vector< Real_real_zero
 Convenience zeros. More...
 
std::vector< VariableValue_scalar_zero
 
std::vector< VariableValue_zero
 
std::vector< VariablePhiValue_phi_zero
 
std::vector< MooseArray< ADReal > > _ad_zero
 
std::vector< VariableGradient_grad_zero
 
std::vector< MooseArray< ADRealVectorValue > > _ad_grad_zero
 
std::vector< VariablePhiGradient_grad_phi_zero
 
std::vector< VariableSecond_second_zero
 
std::vector< MooseArray< ADRealTensorValue > > _ad_second_zero
 
std::vector< VariablePhiSecond_second_phi_zero
 
std::vector< Point > _point_zero
 
std::vector< VectorVariableValue_vector_zero
 
std::vector< VectorVariableCurl_vector_curl_zero
 

Static Public Attributes

static const std::string type_param = "_type"
 The name of the parameter that contains the object type. More...
 
static const std::string name_param = "_object_name"
 The name of the parameter that contains the object name. More...
 
static const std::string unique_name_param = "_unique_name"
 The name of the parameter that contains the unique object name. More...
 
static const std::string app_param = "_moose_app"
 The name of the parameter that contains the MooseApp. More...
 
static const std::string moose_base_param = "_moose_base"
 The name of the parameter that contains the moose system base. More...
 
static const std::string kokkos_object_param = "_kokkos_object"
 The name of the parameter that indicates an object is a Kokkos functor. More...
 

Protected Member Functions

void validateVariableNumericType (const std::string &var_type, const std::string &var_name) const
 Verify that a primary variable's numeric type matches the problem's equation system. More...
 
virtual void meshChanged ()
 Deprecated. More...
 
void createTagVectors ()
 Create extra tagged vectors and matrices. More...
 
void createTagSolutions ()
 Create extra tagged solution vectors. More...
 
virtual void meshDisplaced ()
 Update data after a mesh displaced. More...
 
void computeSystems (const ExecFlagType &type)
 Do generic system computations. More...
 
bool duplicateVariableCheck (const std::string &var_name, const libMesh::FEType &type, bool is_aux, const std::set< SubdomainID > *const active_subdomains)
 Helper to check for duplicate variable names across systems or within a single system. More...
 
void computeUserObjectsInternal (const ExecFlagType &type, TheWarehouse::Query &query)
 
void computeKokkosUserObjectsInternal (const ExecFlagType &type, TheWarehouse::Query &query)
 
void checkDisplacementOrders ()
 Verify that SECOND order mesh uses SECOND order displacements. More...
 
void checkUserObjects ()
 
void checkDependMaterialsHelper (const std::map< SubdomainID, std::vector< std::shared_ptr< MaterialBase >>> &materials_map)
 Helper method for checking Material object dependency. More...
 
void checkCoordinateSystems ()
 Verify that there are no element type/coordinate type conflicts. More...
 
void reinitBecauseOfGhostingOrNewGeomObjects (bool mortar_changed=false)
 Call when it is possible that the needs for ghosted elements has changed. More...
 
void addObjectParamsHelper (InputParameters &params, const std::string &object_name, const std::string &var_param_name="variable")
 Helper for setting the "_subproblem" and "_sys" parameters in addObject() and in addUserObject(). More...
 
template<typename T >
MooseVariableFieldBasegetVariableHelper (const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type, Moose::VarFieldType expected_var_field_type, const std::vector< T > &nls, const SystemBase &aux) const
 Helper function called by getVariable that handles the logic for checking whether Variables of the requested type are available. More...
 
bool verifyVectorTags () const
 Verify the integrity of _vector_tags and _typed_vector_tags. More...
 
template<bool warning>
void flagInvalidSolutionInternal (const InvalidSolutionID invalid_solution_id) const
 Set solution invalid mark for the given solution ID. More...
 
InvalidSolutionID registerInvalidSolutionInternal (const std::string &message, const bool warning) const
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level) const
 Call to register a named section for timing. More...
 
PerfID registerTimedSection (const std::string &section_name, const unsigned int level, const std::string &live_message, const bool print_dots=true) const
 Call to register a named section for timing. More...
 
std::string timedSectionName (const std::string &section_name) const
 
template<typename T , typename... Args>
T & declareRestartableData (const std::string &data_name, Args &&... args)
 Declare a piece of data as "restartable" and initialize it. More...
 
template<typename T , typename... Args>
ManagedValue< T > declareManagedRestartableDataWithContext (const std::string &data_name, void *context, Args &&... args)
 Declares a piece of "managed" restartable data and initialize it. More...
 
template<typename T , typename... Args>
const T & getRestartableData (const std::string &data_name) const
 Declare a piece of data as "restartable" and initialize it Similar to declareRestartableData but returns a const reference to the object. More...
 
template<typename T , typename... Args>
T & declareRestartableDataWithContext (const std::string &data_name, void *context, Args &&... args)
 Declare a piece of data as "restartable" and initialize it. More...
 
template<typename T , typename... Args>
T & declareRecoverableData (const std::string &data_name, Args &&... args)
 Declare a piece of data as "recoverable" and initialize it. More...
 
template<typename T , typename... Args>
T & declareRestartableDataWithObjectName (const std::string &data_name, const std::string &object_name, Args &&... args)
 Declare a piece of data as "restartable". More...
 
template<typename T , typename... Args>
T & declareRestartableDataWithObjectNameWithContext (const std::string &data_name, const std::string &object_name, void *context, Args &&... args)
 Declare a piece of data as "restartable". More...
 
std::string restartableName (const std::string &data_name) const
 Gets the name of a piece of restartable data given a data name, adding the system name and object name prefix. More...
 

Protected Attributes

MFEMProblemData _problem_data
 Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers. More...
 
NumericType _num_type
 The numeric representation currently active for this problem. More...
 
std::map< std::string, MFEMSolverDefinition_mfem_solver_definitions
 Solver definitions recorded by AddMFEMSolverAction before the dependency resolver constructs them. More...
 
Moose::MFEM::SolutionState_solution_state_data
 Restartable MFEM solution state associated with this problem. More...
 
MooseMesh_mesh
 
bool _initialized
 
std::optional< std::vector< ConvergenceName > > _nonlinear_convergence_names
 Nonlinear system(s) convergence name(s) More...
 
std::optional< std::vector< ConvergenceName > > _linear_convergence_names
 Linear system(s) convergence name(s) (if any) More...
 
std::optional< ConvergenceName > _multiapp_fixed_point_convergence_name
 MultiApp fixed point convergence name. More...
 
std::optional< ConvergenceName > _steady_state_convergence_name
 Steady-state detection convergence name. More...
 
std::set< TagID_fe_vector_tags
 
std::set< TagID_fe_matrix_tags
 
std::set< TagID_linear_vector_tags
 Temporary storage for filtered vector tags for linear systems. More...
 
std::set< TagID_linear_matrix_tags
 Temporary storage for filtered matrix tags for linear systems. More...
 
const bool & _solve
 Whether or not to actually solve the nonlinear system. More...
 
bool _transient
 
Real_time
 
Real_time_old
 
int_t_step
 
Real_dt
 
Real_dt_old
 
bool _need_to_add_default_nonlinear_convergence
 Flag that the problem needs to add the default nonlinear convergence. More...
 
bool _need_to_add_default_multiapp_fixed_point_convergence
 Flag that the problem needs to add the default fixed point convergence. More...
 
bool _need_to_add_default_steady_state_convergence
 Flag that the problem needs to add the default steady convergence. More...
 
const std::vector< LinearSystemName > _linear_sys_names
 The linear system names. More...
 
const std::size_t _num_linear_sys
 The number of linear systems. More...
 
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
 The vector of linear systems. More...
 
std::map< LinearSystemName, unsigned int_linear_sys_name_to_num
 Map from linear system name to number. More...
 
LinearSystem_current_linear_sys
 The current linear system that we are solving. More...
 
const bool _using_default_nl
 Boolean to check if we have the default nonlinear system. More...
 
const std::vector< NonlinearSystemName > _nl_sys_names
 The nonlinear system names. More...
 
const std::size_t _num_nl_sys
 The number of nonlinear systems. More...
 
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
 The nonlinear systems. More...
 
std::map< NonlinearSystemName, unsigned int_nl_sys_name_to_num
 Map from nonlinear system name to number. More...
 
NonlinearSystemBase_current_nl_sys
 The current nonlinear system that we are solving. More...
 
SolverSystem_current_solver_sys
 The current solver system. More...
 
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
 Combined container to base pointer of every solver system. More...
 
std::map< SolverVariableName, unsigned int_solver_var_to_sys_num
 Map connecting variable names with their respective solver systems. More...
 
std::map< SolverSystemName, unsigned int_solver_sys_name_to_num
 Map connecting solver system names with their respective systems. More...
 
std::vector< SolverSystemName > _solver_sys_names
 The union of nonlinear and linear system names. More...
 
std::shared_ptr< AuxiliarySystem_aux
 The auxiliary system. More...
 
Moose::CouplingType _coupling
 Type of variable coupling. More...
 
std::vector< std::unique_ptr< libMesh::CouplingMatrix > > _cm
 Coupling matrix for variables. More...
 
Moose::Kokkos::Array< Moose::Kokkos::System_kokkos_systems
 System array - sparsely populated (only slots for systems needing a Kokkos::System) More...
 
Moose::Kokkos::Array< Moose::Kokkos::FESystem_kokkos_fe_systems
 FESystem array - sparsely populated (only slots for systems needing a Kokkos::FESystem) More...
 
std::map< std::string, unsigned int_subspace_dim
 Dimension of the subspace spanned by the vectors with a given prefix. More...
 
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
 The Assembly objects. More...
 
Moose::Kokkos::Assembly _kokkos_assembly
 
MooseObjectWarehouse< MeshDivision_mesh_divisions
 Warehouse to store mesh divisions NOTE: this could probably be moved to the MooseMesh instead of the Problem Time (and people's uses) will tell where this fits best. More...
 
MooseObjectWarehouse< Function_functions
 functions More...
 
MooseObjectWarehouse< Moose::FunctionBase_kokkos_functions
 
MooseObjectWarehouse< Convergence_convergences
 convergence warehouse More...
 
MooseObjectWarehouse< KernelBase_nonlocal_kernels
 nonlocal kernels More...
 
MooseObjectWarehouse< IntegratedBCBase_nonlocal_integrated_bcs
 nonlocal integrated_bcs More...
 
MaterialPropertyRegistry _material_prop_registry
 
MaterialPropertyStorage_material_props
 
MaterialPropertyStorage_bnd_material_props
 
MaterialPropertyStorage_neighbor_material_props
 
Moose::Kokkos::MaterialPropertyStorage_kokkos_material_props
 
Moose::Kokkos::MaterialPropertyStorage_kokkos_bnd_material_props
 
Moose::Kokkos::MaterialPropertyStorage_kokkos_neighbor_material_props
 
MooseObjectWarehouse< Marker_markers
 
ReporterData _reporter_data
 
ExecuteMooseObjectWarehouse< MultiApp_multi_apps
 MultiApp Warehouse. More...
 
ExecuteMooseObjectWarehouse< TransientMultiApp_transient_multi_apps
 Storage for TransientMultiApps (only needed for calling 'computeDT') More...
 
ExecuteMooseObjectWarehouse< Transfer_transfers
 Normal Transfers. More...
 
ExecuteMooseObjectWarehouse< Transfer_to_multi_app_transfers
 Transfers executed just before MultiApps to transfer data to them. More...
 
ExecuteMooseObjectWarehouse< Transfer_from_multi_app_transfers
 Transfers executed just after MultiApps to transfer data from them. More...
 
ExecuteMooseObjectWarehouse< Transfer_between_multi_app_transfers
 Transfers executed just before MultiApps to transfer data between them. More...
 
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
 A map of objects that consume random numbers. More...
 
std::vector< std::unordered_map< SubdomainID, bool > > _block_mat_side_cache
 Cache for calculating materials on side. More...
 
std::vector< std::unordered_map< BoundaryID, bool > > _bnd_mat_side_cache
 Cache for calculating materials on side. More...
 
std::vector< std::unordered_map< BoundaryID, bool > > _interface_mat_side_cache
 Cache for calculating materials on interface. More...
 
std::vector< MeshChangedInterface * > _notify_when_mesh_changes
 Objects to be notified when the mesh changes. More...
 
std::vector< MeshDisplacedInterface * > _notify_when_mesh_displaces
 Objects to be notified when the mesh displaces. More...
 
Adaptivity _adaptivity
 
unsigned int _cycles_completed
 
std::shared_ptr< XFEMInterface_xfem
 Pointer to XFEM controller. More...
 
MooseMesh_displaced_mesh
 
std::shared_ptr< DisplacedProblem_displaced_problem
 
GeometricSearchData _geometric_search_data
 
std::unique_ptr< MortarInterfaceWarehouse_mortar_data
 
bool _reinit_displaced_elem
 Whether to call DisplacedProblem::reinitElem when this->reinitElem is called. More...
 
bool _reinit_displaced_face
 Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called. More...
 
bool _reinit_displaced_neighbor
 Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called. More...
 
bool _input_file_saved
 whether input file has been written More...
 
bool _has_dampers
 Whether or not this system has any Dampers associated with it. More...
 
bool _has_constraints
 Whether or not this system has any Constraints. More...
 
bool _snesmf_reuse_base
 If or not to resuse the base vector for matrix-free calculation. More...
 
bool _skip_exception_check
 If or not skip 'exception and stop solve'. More...
 
bool _snesmf_reuse_base_set_by_user
 If or not _snesmf_reuse_base is set by user. More...
 
bool _has_initialized_stateful
 Whether nor not stateful materials have been initialized. More...
 
bool _const_jacobian
 true if the Jacobian is constant More...
 
bool _has_jacobian
 Indicates if the Jacobian was computed. More...
 
bool _needs_old_newton_iter
 Indicates that we need to compute variable values for previous Newton iteration. More...
 
bool _previous_nl_solution_required
 Indicates we need to save the previous NL iteration variable values. More...
 
std::vector< bool > _previous_multiapp_fp_nl_solution_required
 Indicates we need to save the previous multiapp fixed-point iteration solver variable values. More...
 
bool _previous_multiapp_fp_aux_solution_required
 Indicates we need to save the previous multiapp fixed-point iteration auxiliary variable values. More...
 
bool _has_nonlocal_coupling
 Indicates if nonlocal coupling is required/exists. More...
 
bool _calculate_jacobian_in_uo
 
std::vector< std::vector< const MooseVariableFEBase * > > _uo_jacobian_moose_vars
 
std::vector< unsigned char > _has_active_material_properties
 Whether there are active material properties on each thread. More...
 
std::vector< SolverParams_solver_params
 
CoverageCheckMode _kernel_coverage_check
 Determines whether and which subdomains are to be checked to ensure that they have an active kernel. More...
 
std::vector< SubdomainName > _kernel_coverage_blocks
 
const bool _boundary_restricted_node_integrity_check
 whether to perform checking of boundary restricted nodal object variable dependencies, e.g. More...
 
const bool _boundary_restricted_elem_integrity_check
 whether to perform checking of boundary restricted elemental object variable dependencies, e.g. More...
 
CoverageCheckMode _material_coverage_check
 Determines whether and which subdomains are to be checked to ensure that they have an active material. More...
 
std::vector< SubdomainName > _material_coverage_blocks
 
bool _fv_bcs_integrity_check
 Whether to check overlapping Dirichlet and Flux BCs and/or multiple DirichletBCs per sideset. More...
 
const bool _material_dependency_check
 Determines whether a check to verify material dependencies on every subdomain. More...
 
const bool _uo_aux_state_check
 Whether or not checking the state of uo/aux evaluation. More...
 
bool _check_residual_for_nans
 Whether to check the residual for NaN or Inf values. More...
 
unsigned int _max_qps
 Maximum number of quadrature points used in the problem. More...
 
libMesh::Order _max_scalar_order
 Maximum scalar variable order. More...
 
bool _has_time_integrator
 Indicates whether or not this executioner has a time integrator (during setup) More...
 
bool _has_exception
 Whether or not an exception has occurred. More...
 
bool _parallel_barrier_messaging
 Whether or not information about how many transfers have completed is printed. More...
 
MooseEnum _verbose_setup
 Whether or not to be verbose during setup. More...
 
bool _verbose_multiapps
 Whether or not to be verbose with multiapps. More...
 
bool _verbose_restore
 Whether or not to be verbose on solution restoration post a failed time step. More...
 
std::string _exception_message
 The error message to go with an exception. More...
 
ExecFlagType _current_execute_on_flag
 Current execute_on flag. More...
 
ExecuteMooseObjectWarehouse< Control_control_warehouse
 The control logic warehouse. More...
 
Moose::PetscSupport::PetscOptions _petsc_options
 PETSc option storage. More...
 
PetscOptions _petsc_option_data_base
 
bool _is_petsc_options_inserted
 If or not PETSc options have been added to database. More...
 
std::shared_ptr< LineSearch_line_search
 
std::unique_ptr< libMesh::ConstElemRange_evaluable_local_elem_range
 
std::unique_ptr< libMesh::ConstElemRange_nl_evaluable_local_elem_range
 
std::unique_ptr< libMesh::ConstElemRange_aux_evaluable_local_elem_range
 
std::unique_ptr< libMesh::ConstElemRange_current_algebraic_elem_range
 
std::unique_ptr< libMesh::ConstNodeRange_current_algebraic_node_range
 
std::unique_ptr< ConstBndNodeRange_current_algebraic_bnd_node_range
 
bool _using_ad_mat_props
 Automatic differentiaion (AD) flag which indicates whether any consumer has requested an AD material property or whether any suppier has declared an AD material property. More...
 
unsigned short _current_ic_state
 
const bool _use_hash_table_matrix_assembly
 Whether to assemble matrices using hash tables instead of preallocating matrix memory. More...
 
std::map< TagName, TagID_matrix_tag_name_to_tag_id
 The currently declared tags. More...
 
std::map< TagID, TagName > _matrix_tag_id_to_tag_name
 Reverse map. More...
 
Factory_factory
 The Factory for building objects. More...
 
DiracKernelInfo _dirac_kernel_info
 
std::map< SubdomainID, std::set< std::string > > _map_block_material_props
 Map of material properties (block_id -> list of properties) More...
 
std::map< BoundaryID, std::set< std::string > > _map_boundary_material_props
 Map for boundary material properties (boundary_id -> list of properties) More...
 
std::map< SubdomainID, std::set< MaterialPropertyName > > _zero_block_material_props
 Set of properties returned as zero properties. More...
 
std::map< BoundaryID, std::set< MaterialPropertyName > > _zero_boundary_material_props
 
std::set< std::string > _material_property_requested
 set containing all material property names that have been requested by getMaterialProperty* More...
 
std::vector< std::set< MooseVariableFieldBase * > > _active_elemental_moose_variables
 This is the set of MooseVariableFieldBase that will actually get reinited by a call to reinit(elem) More...
 
std::vector< unsigned int_has_active_elemental_moose_variables
 Whether or not there is currently a list of active elemental moose variables. More...
 
std::vector< std::set< TagID > > _active_fe_var_coupleable_matrix_tags
 
std::vector< std::set< TagID > > _active_fe_var_coupleable_vector_tags
 
std::vector< std::set< TagID > > _active_sc_var_coupleable_matrix_tags
 
std::vector< std::set< TagID > > _active_sc_var_coupleable_vector_tags
 
bool _default_ghosting
 Whether or not to use default libMesh coupling. More...
 
std::set< dof_id_type_ghosted_elems
 Elements that should have Dofs ghosted to the local processor. More...
 
bool _currently_computing_jacobian
 Flag to determine whether the problem is currently computing Jacobian. More...
 
bool _currently_computing_residual_and_jacobian
 Flag to determine whether the problem is currently computing the residual and Jacobian. More...
 
bool _computing_nonlinear_residual
 Whether the non-linear residual is being evaluated. More...
 
bool _currently_computing_residual
 Whether the residual is being evaluated. More...
 
bool _safe_access_tagged_matrices
 Is it safe to retrieve data from tagged matrices. More...
 
bool _safe_access_tagged_vectors
 Is it safe to retrieve data from tagged vectors. More...
 
bool _have_ad_objects
 AD flag indicating whether any AD objects have been added. More...
 
std::unordered_set< TagID_not_zeroed_tagged_vectors
 the list of vector tags that will not be zeroed when all other tags are More...
 
bool _cli_option_found
 True if the CLI option is found. More...
 
bool _color_output
 True if we're going to attempt to write color output. More...
 
bool _termination_requested
 True if termination of the solve has been requested. More...
 
const bool & _enabled
 Reference to the "enable" InputParameters, used by Controls for toggling on/off MooseObjects. More...
 
MooseApp_app
 The MOOSE application this is associated with. More...
 
ActionFactory_action_factory
 Builds Actions. More...
 
const std::string & _type
 The type of this class. More...
 
const std::string & _name
 The name of this class. More...
 
const InputParameters_pars
 The object's parameters. More...
 
const Parallel::Communicator_communicator
 
MooseApp_pg_moose_app
 The MooseApp that owns the PerfGraph. More...
 
const std::string _prefix
 A prefix to use for all sections. More...
 
MooseApp_restartable_app
 Reference to the application. More...
 
const std::string _restartable_system_name
 The system name this object is in. More...
 
const THREAD_ID _restartable_tid
 The thread ID for this object. More...
 
const bool _restartable_read_only
 Flag for toggling read only status (see ReporterData) More...
 
InitialConditionWarehouse _ics
 
FVInitialConditionWarehouse _fv_ics
 
ScalarInitialConditionWarehouse _scalar_ics
 
MaterialWarehouse _materials
 
MaterialWarehouse _interface_materials
 
MaterialWarehouse _discrete_materials
 
MaterialWarehouse _all_materials
 
MaterialWarehouse _kokkos_materials
 
MooseObjectWarehouse< Indicator_indicators
 
MooseObjectWarehouse< InternalSideIndicatorBase_internal_side_indicators
 
std::map< SubdomainID, std::multimap< std::string, std::string > > _map_block_material_props_check
 Data structures of the requested material properties. More...
 
std::map< BoundaryID, std::multimap< std::string, std::string > > _map_boundary_material_props_check
 

Detailed Description

Definition at line 28 of file MFEMProblem.h.

Member Typedef Documentation

◆ DataFileParameterType

using DataFileInterface::DataFileParameterType = DataFileName
inherited

The parameter type this interface expects for a data file name.

Definition at line 27 of file DataFileInterface.h.

Member Enumeration Documentation

◆ CoverageCheckMode

enum FEProblemBase::CoverageCheckMode
stronginherited
Enumerator
FALSE 
TRUE 
OFF 
ON 
SKIP_LIST 
ONLY_LIST 

Definition at line 170 of file FEProblemBase.h.

171  {
172  FALSE,
173  TRUE,
174  OFF,
175  ON,
176  SKIP_LIST,
177  ONLY_LIST,
178  };

◆ Direction

enum ExternalProblem::Direction : unsigned char
stronginherited
Enumerator
TO_EXTERNAL_APP 
FROM_EXTERNAL_APP 

Definition at line 21 of file ExternalProblem.h.

21  : unsigned char
22  {
23  TO_EXTERNAL_APP,
24  FROM_EXTERNAL_APP
25  };

◆ NumericType

Enumerates the supported numeric representations for MFEM variables and operators.

Enumerator
REAL 
COMPLEX 

Definition at line 356 of file MFEMProblem.h.

357  {
358  REAL,
359  COMPLEX
360  };
std::complex< Real > COMPLEX

Constructor & Destructor Documentation

◆ MFEMProblem()

MFEMProblem::MFEMProblem ( const InputParameters params)

Construct an MFEM problem from the supplied parameters.

Definition at line 71 of file MFEMProblem.C.

72  : ExternalProblem(params),
73  _num_type{static_cast<int>(getParam<MooseEnum>("numeric_type"))},
74  _solution_state_data(declareRestartableDataWithContext<Moose::MFEM::SolutionState>(
75  "mfem_solution_state", &_problem_data))
76 {
77  // Initialise Hypre for all MFEM problems.
78  mfem::Hypre::Init();
79  // Disable multithreading for all MFEM problems (including any libMesh or MFEM subapps).
81 #ifdef LIBMESH_HAVE_OPENMP
82  omp_set_num_threads(1);
83 #endif
84  setMesh();
85 }
Moose::MFEM::SolutionState & _solution_state_data
Restartable MFEM solution state associated with this problem.
Definition: MFEMProblem.h:413
NumericType _num_type
The numeric representation currently active for this problem.
Definition: MFEMProblem.h:402
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
void setMesh()
Set the mesh used by MFEM.
Definition: MFEMProblem.C:119
ExternalProblem(const InputParameters &parameters)

◆ ~MFEMProblem()

virtual MFEMProblem::~MFEMProblem ( )
inlinevirtual

Destroy the MFEM problem.

Definition at line 44 of file MFEMProblem.h.

44 {}

Member Function Documentation

◆ _setCLIOption()

void Problem::_setCLIOption ( )
inlineinherited

For Internal Use.

Definition at line 32 of file Problem.h.

32 { _cli_option_found = true; }
bool _cli_option_found
True if the CLI option is found.
Definition: Problem.h:52

◆ acceptInvalidSolution()

bool FEProblemBase::acceptInvalidSolution ( ) const
inherited

Whether or not to accept the solution based on its invalidity.

If this returns false, it means that an invalid solution was encountered (an error) that was not allowed.

Definition at line 4085 of file FEProblemBase.C.

Referenced by SolverSystem::checkInvalidSolution(), and NonlinearSystem::converged().

4086 {
4087  return allowInvalidSolution() || // invalid solutions are always allowed
4088  !_app.solutionInvalidity().hasInvalidSolutionError(); // if not allowed, check for errors
4089 }
bool hasInvalidSolutionError() const
Whether or not an invalid solution was encountered that was an error.
SolutionInvalidity & solutionInvalidity()
Get the SolutionInvalidity for this app.
Definition: MooseApp.h:185
bool allowInvalidSolution() const
Whether to accept / allow an invalid solution.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375

◆ adaptivity()

Adaptivity& FEProblemBase::adaptivity ( )
inlineinherited

◆ adaptMesh()

bool FEProblemBase::adaptMesh ( )
virtualinherited
Returns
Whether or not the mesh was changed

Reimplemented in DumpObjectsProblem.

Definition at line 8564 of file FEProblemBase.C.

Referenced by SteadyBase::execute(), Eigenvalue::execute(), and TransientBase::incrementStepOrReject().

8565 {
8566  // reset cycle counter
8567  _cycles_completed = 0;
8568 
8570  return false;
8571 
8572  TIME_SECTION("adaptMesh", 3, "Adapting Mesh");
8573 
8574  unsigned int cycles_per_step = _adaptivity.getCyclesPerStep();
8575 
8576  bool mesh_changed = false;
8577 
8578  for (unsigned int i = 0; i < cycles_per_step; ++i)
8579  {
8580  if (!_mesh.interiorLowerDBlocks().empty() || !_mesh.boundaryLowerDBlocks().empty())
8581  mooseError("HFEM does not support mesh adaptivity currently.");
8582 
8583  // Markers were already computed once by Executioner
8584  if (_adaptivity.getRecomputeMarkersFlag() && i > 0)
8585  computeMarkers();
8586 
8587  bool mesh_changed_this_step;
8588  mesh_changed_this_step = _adaptivity.adaptMesh();
8589 
8590  if (mesh_changed_this_step)
8591  {
8592  mesh_changed = true;
8593 
8594  meshChanged(
8595  /*intermediate_change=*/true, /*contract_mesh=*/true, /*clean_refinement_flags=*/true);
8597  }
8598  else
8599  {
8600  // If the mesh didn't change, we still need to update the displaced mesh
8601  // to undo the undisplacement performed in Adaptivity::adaptMesh
8602  if (_displaced_problem)
8603  _displaced_problem->updateMesh();
8604 
8605  _console << "Mesh unchanged, skipping remaining steps..." << std::endl;
8606  break;
8607  }
8608 
8609  // Show adaptivity progress
8610  _console << std::flush;
8611  }
8612 
8613  // We're done with all intermediate changes; now get systems ready
8614  // for real if necessary.
8615  if (mesh_changed)
8616  es().reinit_systems();
8617 
8618  // Execute multi-apps that need to run after adaptivity, but before the next timestep.
8620 
8621  return mesh_changed;
8622 }
bool adaptMesh(std::string marker_name=std::string())
Adapts the mesh based on the error estimator used.
Definition: Adaptivity.C:145
virtual void meshChanged()
Deprecated.
const std::set< SubdomainID > & interiorLowerDBlocks() const
Definition: MooseMesh.h:1552
unsigned int _cycles_completed
unsigned int getCyclesPerStep() const
Pull out the number of cycles_per_step previously set through the AdaptivityAction.
Definition: Adaptivity.h:126
virtual void computeMarkers()
virtual void reinit_systems()
bool getRecomputeMarkersFlag() const
Pull out the _recompute_markers_during_cycles flag previously set through the AdaptivityAction.
Definition: Adaptivity.h:139
virtual libMesh::EquationSystems & es() override
MooseMesh & _mesh
Adaptivity _adaptivity
const std::set< SubdomainID > & boundaryLowerDBlocks() const
Definition: MooseMesh.h:1556
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
bool isAdaptivityDue()
Query if an adaptivity step should be performed at the current time / time step.
Definition: Adaptivity.C:420
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
bool execMultiApps(ExecFlagType type, bool auto_advance=true)
Execute the MultiApps associated with the ExecFlagType.
const ExecFlagType EXEC_POST_ADAPTIVITY
Definition: Moose.C:60

◆ addAlgebraicGhostingFunctor()

void SubProblem::addAlgebraicGhostingFunctor ( libMesh::GhostingFunctor algebraic_gf,
bool  to_mesh = true 
)
inherited

Add an algebraic ghosting functor to this problem's DofMaps.

Definition at line 1024 of file SubProblem.C.

1025 {
1026  EquationSystems & eq = es();
1027  const auto n_sys = eq.n_systems();
1028  if (!n_sys)
1029  return;
1030 
1031  eq.get_system(0).get_dof_map().add_algebraic_ghosting_functor(algebraic_gf, to_mesh);
1032  cloneAlgebraicGhostingFunctor(algebraic_gf, to_mesh);
1033 }
unsigned int n_systems() const
void cloneAlgebraicGhostingFunctor(libMesh::GhostingFunctor &algebraic_gf, bool to_mesh=true)
Creates (n_sys - 1) clones of the provided algebraic ghosting functor (corresponding to the nonlinear...
Definition: SubProblem.C:1002
const T_sys & get_system(std::string_view name) const
virtual libMesh::EquationSystems & es()=0

◆ addAuxArrayVariable()

void FEProblemBase::addAuxArrayVariable ( const std::string &  var_name,
const libMesh::FEType type,
unsigned int  components,
const std::set< SubdomainID > *const  active_subdomains = NULL 
)
virtualinherited

Definition at line 3410 of file FEProblemBase.C.

3414 {
3415  parallel_object_only();
3416 
3417  mooseDeprecated("Please use the addAuxVariable(var_type, var_name, params) API instead");
3418 
3419  if (duplicateVariableCheck(var_name, type, /* is_aux = */ true, active_subdomains))
3420  return;
3421 
3422  InputParameters params = _factory.getValidParams("ArrayMooseVariable");
3423  params.set<FEProblemBase *>("_fe_problem_base") = this;
3425  params.set<MooseEnum>("order") = type.order.get_order();
3426  params.set<MooseEnum>("family") = Moose::stringify(type.family);
3427  params.set<unsigned int>("components") = components;
3428 
3429  if (active_subdomains)
3430  for (const SubdomainID & id : *active_subdomains)
3431  params.set<std::vector<SubdomainName>>("block").push_back(Moose::stringify(id));
3432 
3433  logAdd("Variable", var_name, "ArrayMooseVariable", params);
3434  _aux->addVariable("ArrayMooseVariable", var_name, params);
3435  if (_displaced_problem)
3436  _displaced_problem->addAuxVariable("ArrayMooseVariable", var_name, params);
3437 
3438  markFamilyPRefinement(params);
3439  if (_displaced_problem)
3440  _displaced_problem->markFamilyPRefinement(params);
3441 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
VarKindType
Framework-wide stuff.
Definition: MooseTypes.h:763
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void markFamilyPRefinement(const InputParameters &params)
Mark a variable family for either disabling or enabling p-refinement with valid parameters of a varia...
Definition: SubProblem.C:1372
void mooseDeprecated(Args &&... args) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:54
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
bool duplicateVariableCheck(const std::string &var_name, const libMesh::FEType &type, bool is_aux, const std::set< SubdomainID > *const active_subdomains)
Helper to check for duplicate variable names across systems or within a single system.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addAuxKernel()

void MFEMProblem::addAuxKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Override of ExternalProblem::addAuxKernel.

Creates the MOOSE-side MFEM auxkernel wrapper.

Reimplemented from FEProblemBase.

Definition at line 442 of file MFEMProblem.C.

445 {
446  addObject<MFEMExecutedObject>(kernel_name, name, parameters);
447 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addAuxScalarKernel()

void FEProblemBase::addAuxScalarKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3490 of file FEProblemBase.C.

3493 {
3494  parallel_object_only();
3495 
3496  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3497  {
3498  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
3499  parameters.set<SystemBase *>("_sys") = &_displaced_problem->auxSys();
3500  }
3501  else
3502  {
3503  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
3504  {
3505  // We allow AuxScalarKernels to request that they use_displaced_mesh,
3506  // but then be overridden when no displacements variables are
3507  // provided in the Mesh block. If that happened, update the value
3508  // of use_displaced_mesh appropriately for this AuxScalarKernel.
3509  if (parameters.have_parameter<bool>("use_displaced_mesh"))
3510  parameters.set<bool>("use_displaced_mesh") = false;
3511  }
3512 
3513  parameters.set<SubProblem *>("_subproblem") = this;
3514  parameters.set<SystemBase *>("_sys") = _aux.get();
3515  }
3516 
3517  logAdd("AuxScalarKernel", name, kernel_name, parameters);
3518  _aux->addScalarKernel(kernel_name, name, parameters);
3519 }
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addAuxScalarVariable()

void FEProblemBase::addAuxScalarVariable ( const std::string &  var_name,
libMesh::Order  order,
Real  scale_factor = 1.,
const std::set< SubdomainID > *const  active_subdomains = NULL 
)
virtualinherited

Definition at line 3444 of file FEProblemBase.C.

3448 {
3449  parallel_object_only();
3450 
3451  mooseDeprecated("Please use the addAuxVariable(var_type, var_name, params) API instead");
3452 
3453  if (order > _max_scalar_order)
3454  _max_scalar_order = order;
3455 
3456  FEType type(order, SCALAR);
3457  if (duplicateVariableCheck(var_name, type, /* is_aux = */ true, active_subdomains))
3458  return;
3459 
3460  InputParameters params = _factory.getValidParams("MooseVariableScalar");
3461  params.set<FEProblemBase *>("_fe_problem_base") = this;
3463 
3464  params.set<MooseEnum>("order") = type.order.get_order();
3465  params.set<MooseEnum>("family") = "SCALAR";
3466  params.set<std::vector<Real>>("scaling") = std::vector<Real>{1};
3467  if (active_subdomains)
3468  for (const SubdomainID & id : *active_subdomains)
3469  params.set<std::vector<SubdomainName>>("block").push_back(Moose::stringify(id));
3470 
3471  logAdd("ScalarVariable", var_name, "MooseVariableScalar", params);
3472  _aux->addVariable("MooseVariableScalar", var_name, params);
3473  if (_displaced_problem)
3474  _displaced_problem->addAuxVariable("MooseVariableScalar", var_name, params);
3475 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
VarKindType
Framework-wide stuff.
Definition: MooseTypes.h:763
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseDeprecated(Args &&... args) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:54
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
bool duplicateVariableCheck(const std::string &var_name, const libMesh::FEType &type, bool is_aux, const std::set< SubdomainID > *const active_subdomains)
Helper to check for duplicate variable names across systems or within a single system.
std::shared_ptr< DisplacedProblem > _displaced_problem
libMesh::Order _max_scalar_order
Maximum scalar variable order.

◆ addAuxVariable() [1/2]

void MFEMProblem::addAuxVariable ( const std::string &  var_type,
const std::string &  var_name,
InputParameters parameters 
)
overridevirtual

Override of ExternalProblem::addAuxVariable.

Sets a MFEM grid function to be used in the MFEM solve.

Reimplemented from FEProblemBase.

Definition at line 432 of file MFEMProblem.C.

435 {
436  // We handle MFEM AuxVariables just like MFEM Variables, except
437  // we do not add additional GridFunctions for time derivatives.
438  addGridFunction(var_type, var_name, parameters);
439 }
void addGridFunction(const std::string &var_type, const std::string &var_name, InputParameters &parameters)
Adds one MFEM GridFunction to be used in the MFEM solve.
Definition: MFEMProblem.C:392
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131

◆ addAuxVariable() [2/2]

void FEProblemBase::addAuxVariable ( const std::string &  var_name,
const libMesh::FEType type,
const std::set< SubdomainID > *const  active_subdomains = NULL 
)
virtualinherited

Definition at line 3368 of file FEProblemBase.C.

3371 {
3372  parallel_object_only();
3373 
3374  mooseDeprecated("Please use the addAuxVariable(var_type, var_name, params) API instead");
3375 
3376  if (duplicateVariableCheck(var_name, type, /* is_aux = */ true, active_subdomains))
3377  return;
3378 
3379  std::string var_type;
3380  if (type == FEType(0, MONOMIAL))
3381  var_type = "MooseVariableConstMonomial";
3382  else if (type.family == SCALAR)
3383  var_type = "MooseVariableScalar";
3384  else if (FEInterface::field_type(type) == TYPE_VECTOR)
3385  var_type = "VectorMooseVariable";
3386  else
3387  var_type = "MooseVariable";
3388 
3389  InputParameters params = _factory.getValidParams(var_type);
3390  params.set<FEProblemBase *>("_fe_problem_base") = this;
3392  params.set<MooseEnum>("order") = type.order.get_order();
3393  params.set<MooseEnum>("family") = Moose::stringify(type.family);
3394 
3395  if (active_subdomains)
3396  for (const SubdomainID & id : *active_subdomains)
3397  params.set<std::vector<SubdomainName>>("block").push_back(Moose::stringify(id));
3398 
3399  logAdd("AuxVariable", var_name, var_type, params);
3400  _aux->addVariable(var_type, var_name, params);
3401  if (_displaced_problem)
3402  _displaced_problem->addAuxVariable("MooseVariable", var_name, params);
3403 
3404  markFamilyPRefinement(params);
3405  if (_displaced_problem)
3406  _displaced_problem->markFamilyPRefinement(params);
3407 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
VarKindType
Framework-wide stuff.
Definition: MooseTypes.h:763
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void markFamilyPRefinement(const InputParameters &params)
Mark a variable family for either disabling or enabling p-refinement with valid parameters of a varia...
Definition: SubProblem.C:1372
void mooseDeprecated(Args &&... args) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:54
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
bool duplicateVariableCheck(const std::string &var_name, const libMesh::FEType &type, bool is_aux, const std::set< SubdomainID > *const active_subdomains)
Helper to check for duplicate variable names across systems or within a single system.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addBoundaryCondition()

void MFEMProblem::addBoundaryCondition ( const std::string &  bc_name,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Reimplemented from FEProblemBase.

Definition at line 244 of file MFEMProblem.C.

247 {
248  auto bc = addObject<MFEMBoundaryCondition>(bc_name, name, parameters).front();
249  const auto & mfem_bc = *bc;
250 
251  if (dynamic_cast<const MFEMIntegratedBC *>(&mfem_bc))
252  {
253  auto integrated_bc = std::dynamic_pointer_cast<MFEMIntegratedBC>(bc);
254  auto eqsys =
256  if (eqsys)
257  eqsys->AddIntegratedBC(std::move(integrated_bc));
258  else
259  mooseError("Cannot add integrated BC with name '" + name +
260  "' because there is no corresponding equation system.");
261  }
262  else if (dynamic_cast<const MFEMComplexIntegratedBC *>(&mfem_bc))
263  {
264  auto integrated_bc = std::dynamic_pointer_cast<MFEMComplexIntegratedBC>(bc);
265  auto eqsys =
267  if (eqsys)
268  eqsys->AddComplexIntegratedBC(std::move(integrated_bc));
269  else
270  mooseError("Cannot add complex integrated BC with name '" + name +
271  "' because there is no corresponding equation system.");
272  }
273  else if (dynamic_cast<const MFEMComplexEssentialBC *>(&mfem_bc))
274  {
275  auto essential_bc = std::dynamic_pointer_cast<MFEMComplexEssentialBC>(bc);
276  auto eqsys =
278  if (eqsys)
279  eqsys->AddComplexEssentialBCs(std::move(essential_bc));
280  else
281  mooseError("Cannot add boundary condition with name '" + name +
282  "' because there is no corresponding equation system.");
283  }
284  else if (dynamic_cast<const MFEMEssentialBC *>(&mfem_bc))
285  {
286  auto essential_bc = std::dynamic_pointer_cast<MFEMEssentialBC>(bc);
287  auto eqsys =
289  if (eqsys)
290  eqsys->AddEssentialBC(std::move(essential_bc));
291  else
292  mooseError("Cannot add boundary condition with name '" + name +
293  "' because there is no corresponding equation system.");
294  }
295  else
296  {
297  mooseError("Unsupported bc of type '", bc_name, "' and name '", name, "' detected.");
298  }
299 }
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
Owns the weak-form mathematics of a MOOSE MFEM problem.
virtual void AddEssentialBC(std::shared_ptr< MFEMEssentialBC > bc)
Add BC associated with essentially constrained DoFs on boundaries.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
void AddComplexEssentialBCs(std::shared_ptr< MFEMComplexEssentialBC > bc)
Add complex essential BCs.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< Moose::MFEM::EquationSystem > eqn_system
void AddComplexIntegratedBC(std::shared_ptr< MFEMComplexIntegratedBC > bc)
Add complex integrated BCs.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
virtual void AddIntegratedBC(std::shared_ptr< MFEMIntegratedBC > kernel)

◆ addCachedJacobian()

void FEProblemBase::addCachedJacobian ( const THREAD_ID  tid)
overridevirtualinherited

◆ addCachedResidual()

void FEProblemBase::addCachedResidual ( const THREAD_ID  tid)
overridevirtualinherited

◆ addCachedResidualDirectly()

void FEProblemBase::addCachedResidualDirectly ( NumericVector< libMesh::Number > &  residual,
const THREAD_ID  tid 
)
virtualinherited

Allows for all the residual contributions that are currently cached to be added directly into the vector passed in.

Parameters
residualThe vector to add the cached contributions to.
tidThe thread id.

Definition at line 2015 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintResiduals(), and NonlinearSystemBase::enforceNodalConstraintsResidual().

2016 {
2018  _assembly[tid][_current_nl_sys->number()]->addCachedResidualDirectly(
2020 
2022  _assembly[tid][_current_nl_sys->number()]->addCachedResidualDirectly(
2024 
2025  std::vector<VectorTag> extra_residual_vector_tags;
2026  extra_residual_vector_tags.reserve(currentResidualVectorTags().size());
2027  const auto time_tag = _current_nl_sys->timeVectorTag();
2028  const auto non_time_tag = _current_nl_sys->nonTimeVectorTag();
2029  for (const auto & vector_tag : currentResidualVectorTags())
2030  if (vector_tag._id != time_tag && vector_tag._id != non_time_tag)
2031  extra_residual_vector_tags.push_back(vector_tag);
2032 
2033  // Flush extra vector tag caches (e.g. from extra_vector_tags on NodalConstraints)
2034  // to their respective system vectors after the standard TIME/NONTIME caches above.
2035  // Without this, NodalConstraint contributions to extra vector tags are silently
2036  // discarded by the blanket clearCachedResiduals.
2037  _assembly[tid][_current_nl_sys->number()]->addCachedResiduals(Assembly::GlobalDataKey{},
2038  extra_residual_vector_tags);
2039 
2040  // We do this because by adding the cached residual directly, we cannot ensure that all of the
2041  // cached residuals are emptied after only the two add calls above
2042  _assembly[tid][_current_nl_sys->number()]->clearCachedResiduals(Assembly::GlobalDataKey{});
2043 
2044  if (_displaced_problem)
2045  _displaced_problem->addCachedResidualDirectly(residual, tid);
2046 }
bool hasVector(const std::string &tag_name) const
Check if the named vector exists in the system.
Definition: SystemBase.C:925
TagID nonTimeVectorTag() const override
virtual const std::vector< VectorTag > & currentResidualVectorTags() const override
Return the residual vector tags we are currently computing.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
TagID timeVectorTag() const override
Ideally, we should not need this API.
std::shared_ptr< DisplacedProblem > _displaced_problem
virtual const VectorTag & getVectorTag(const TagID tag_id) const
Get a VectorTag from a TagID.
Definition: SubProblem.C:162
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addConstraint()

void FEProblemBase::addConstraint ( const std::string &  c_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3274 of file FEProblemBase.C.

3277 {
3278  parallel_object_only();
3279 
3280  _has_constraints = true;
3281 
3282  auto determine_var_param_name = [&parameters, this]()
3283  {
3284  if (parameters.isParamValid("variable"))
3285  return "variable";
3286  else
3287  {
3288  // must be a mortar constraint
3289  const bool has_secondary_var = parameters.isParamValid("secondary_variable");
3290  const bool has_primary_var = parameters.isParamValid("primary_variable");
3291  if (!has_secondary_var && !has_primary_var)
3292  mooseError(
3293  "Either a 'secondary_variable' or 'primary_variable' parameter must be supplied for '",
3295  "'");
3296  return has_secondary_var ? "secondary_variable" : "primary_variable";
3297  }
3298  };
3299 
3300  const auto nl_sys_num =
3301  determineSolverSystem(parameters.varName(determine_var_param_name(), name), true).second;
3302  if (!isSolverSystemNonlinear(nl_sys_num))
3303  mooseError("You are trying to add a Constraint to a linear variable/system, which is not "
3304  "supported at the moment!");
3305 
3306  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3307  {
3308  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
3309  parameters.set<SystemBase *>("_sys") = &_displaced_problem->solverSys(nl_sys_num);
3310  _reinit_displaced_face = true;
3311  }
3312  else
3313  {
3314  // It might _want_ to use a displaced mesh... but we're not so set it to false
3315  if (parameters.have_parameter<bool>("use_displaced_mesh"))
3316  parameters.set<bool>("use_displaced_mesh") = false;
3317 
3318  parameters.set<SubProblem *>("_subproblem") = this;
3319  parameters.set<SystemBase *>("_sys") = _nl[nl_sys_num].get();
3320  }
3321 
3322  logAdd("Constraint", name, c_name, parameters);
3323  _nl[nl_sys_num]->addConstraint(c_name, name, parameters);
3324 }
const std::string & getObjectName() const
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
bool _has_constraints
Whether or not this system has any Constraints.
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.

◆ addConsumedPropertyName()

void SubProblem::addConsumedPropertyName ( const MooseObjectName obj_name,
const std::string &  prop_name 
)
inherited

Helper for tracking the object that is consuming a property for MaterialPropertyDebugOutput.

Definition at line 737 of file SubProblem.C.

Referenced by MaterialPropertyInterface::addConsumedPropertyName().

738 {
739  _consumed_material_properties[obj_name].insert(prop_name);
740 }
std::map< MooseObjectName, std::set< std::string > > _consumed_material_properties
Definition: SubProblem.h:1203

◆ addConvergence()

void FEProblemBase::addConvergence ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Adds a Convergence object.

Definition at line 2661 of file FEProblemBase.C.

Referenced by FEProblemBase::addDefaultMultiAppFixedPointConvergence(), ReferenceResidualProblem::addDefaultNonlinearConvergence(), FEProblemBase::addDefaultNonlinearConvergence(), and FEProblemBase::addDefaultSteadyStateConvergence().

2664 {
2665  parallel_object_only();
2666 
2667  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); tid++)
2668  {
2669  std::shared_ptr<Convergence> conv = _factory.create<Convergence>(type, name, parameters, tid);
2670  _convergences.addObject(conv, tid);
2671  }
2672 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
unsigned int n_threads()
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MooseObjectWarehouse< Convergence > _convergences
convergence warehouse
virtual std::unique_ptr< Base > create()=0
Base class for convergence criteria.
Definition: Convergence.h:21
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
virtual void addObject(std::shared_ptr< T > object, THREAD_ID tid=0, bool recurse=true) override
Adds an object to the storage structure.
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ addCouplingGhostingFunctor()

void SubProblem::addCouplingGhostingFunctor ( libMesh::GhostingFunctor coupling_gf,
bool  to_mesh = true 
)
inherited

Add a coupling functor to this problem's DofMaps.

Definition at line 1057 of file SubProblem.C.

1058 {
1059  const auto num_nl_sys = numNonlinearSystems();
1060  if (!num_nl_sys)
1061  return;
1062 
1063  systemBaseNonlinear(0).system().get_dof_map().add_coupling_functor(coupling_gf, to_mesh);
1064  cloneCouplingGhostingFunctor(coupling_gf, to_mesh);
1065 }
void cloneCouplingGhostingFunctor(libMesh::GhostingFunctor &coupling_gf, bool to_mesh=true)
Creates (n_sys - 1) clones of the provided coupling ghosting functor (corresponding to the nonlinear ...
Definition: SubProblem.C:1036
virtual const SystemBase & systemBaseNonlinear(const unsigned int sys_num) const =0
Return the nonlinear system object as a base class reference given the system number.
virtual libMesh::System & system()=0
Get the reference to the libMesh system.
void add_coupling_functor(GhostingFunctor &coupling_functor, bool to_mesh=true)
virtual std::size_t numNonlinearSystems() const =0
const DofMap & get_dof_map() const

◆ addDamper()

void FEProblemBase::addDamper ( const std::string &  damper_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 5689 of file FEProblemBase.C.

5692 {
5693  parallel_object_only();
5694 
5695  const auto nl_sys_num =
5696  parameters.isParamValid("variable")
5697  ? determineSolverSystem(parameters.varName("variable", name), true).second
5698  : (unsigned int)0;
5699 
5700  if (!isSolverSystemNonlinear(nl_sys_num))
5701  mooseError("You are trying to add a DGKernel to a linear variable/system, which is not "
5702  "supported at the moment!");
5703 
5704  parameters.set<SubProblem *>("_subproblem") = this;
5705  parameters.set<SystemBase *>("_sys") = _nl[nl_sys_num].get();
5706 
5707  _has_dampers = true;
5708  logAdd("Damper", name, damper_name, parameters);
5709  _nl[nl_sys_num]->addDamper(damper_name, name, parameters);
5710 }
bool _has_dampers
Whether or not this system has any Dampers associated with it.
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.

◆ addDefaultMultiAppFixedPointConvergence()

void FEProblemBase::addDefaultMultiAppFixedPointConvergence ( const InputParameters params)
inherited

Adds the default fixed point Convergence associated with the problem.

This is called if the user does not supply 'multiapp_fixed_point_convergence'.

Parameters
[in]paramsParameters to apply to Convergence parameters

Definition at line 2687 of file FEProblemBase.C.

2688 {
2689  const std::string class_name = "DefaultMultiAppFixedPointConvergence";
2690  InputParameters params = _factory.getValidParams(class_name);
2691  params.applyParameters(params_to_apply);
2692  params.applyParameters(parameters());
2693  params.set<bool>("added_as_default") = true;
2695 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void applyParameters(const InputParameters &common, const std::vector< std::string > &exclude={}, const bool allow_private=false)
Method for applying common parameters.
virtual void addConvergence(const std::string &type, const std::string &name, InputParameters &parameters)
Adds a Convergence object.
const ConvergenceName & getMultiAppFixedPointConvergenceName() const
Gets the MultiApp fixed point convergence object name.

◆ addDefaultNonlinearConvergence()

void FEProblemBase::addDefaultNonlinearConvergence ( const InputParameters params)
virtualinherited

Adds the default nonlinear Convergence associated with the problem.

This is called if the user does not supply 'nonlinear_convergence'.

Parameters
[in]paramsParameters to apply to Convergence parameters

Reimplemented in ReferenceResidualProblem.

Definition at line 2675 of file FEProblemBase.C.

2676 {
2677  const std::string class_name = "DefaultNonlinearConvergence";
2678  InputParameters params = _factory.getValidParams(class_name);
2679  params.applyParameters(params_to_apply);
2680  params.applyParameters(parameters());
2681  params.set<bool>("added_as_default") = true;
2682  for (const auto & conv_name : getNonlinearConvergenceNames())
2683  addConvergence(class_name, conv_name, params);
2684 }
const std::vector< ConvergenceName > & getNonlinearConvergenceNames() const
Gets the nonlinear system convergence object name(s).
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void applyParameters(const InputParameters &common, const std::vector< std::string > &exclude={}, const bool allow_private=false)
Method for applying common parameters.
virtual void addConvergence(const std::string &type, const std::string &name, InputParameters &parameters)
Adds a Convergence object.

◆ addDefaultSteadyStateConvergence()

void FEProblemBase::addDefaultSteadyStateConvergence ( const InputParameters params)
inherited

Adds the default steady-state detection Convergence.

This is called if the user does not supply 'steady_state_convergence'.

Parameters
[in]paramsParameters to apply to Convergence parameters

Definition at line 2698 of file FEProblemBase.C.

2699 {
2700  const std::string class_name = "DefaultSteadyStateConvergence";
2701  InputParameters params = _factory.getValidParams(class_name);
2702  params.applyParameters(params_to_apply);
2703  params.applyParameters(parameters());
2704  params.set<bool>("added_as_default") = true;
2705  addConvergence(class_name, getSteadyStateConvergenceName(), params);
2706 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void applyParameters(const InputParameters &common, const std::vector< std::string > &exclude={}, const bool allow_private=false)
Method for applying common parameters.
const ConvergenceName & getSteadyStateConvergenceName() const
Gets the steady-state detection convergence object name.
virtual void addConvergence(const std::string &type, const std::string &name, InputParameters &parameters)
Adds a Convergence object.

◆ addDGKernel()

void FEProblemBase::addDGKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3562 of file FEProblemBase.C.

3565 {
3566  parallel_object_only();
3567 
3568  const auto nl_sys_num = determineSolverSystem(parameters.varName("variable", name), true).second;
3569  if (!isSolverSystemNonlinear(nl_sys_num))
3570  mooseError("You are trying to add a DGKernel to a linear variable/system, which is not "
3571  "supported at the moment!");
3572 
3573  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3574  {
3575  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
3576  parameters.set<SystemBase *>("_sys") = &_displaced_problem->solverSys(nl_sys_num);
3578  }
3579  else
3580  {
3581  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
3582  {
3583  // We allow DGKernels to request that they use_displaced_mesh,
3584  // but then be overridden when no displacements variables are
3585  // provided in the Mesh block. If that happened, update the value
3586  // of use_displaced_mesh appropriately for this DGKernel.
3587  if (parameters.have_parameter<bool>("use_displaced_mesh"))
3588  parameters.set<bool>("use_displaced_mesh") = false;
3589  }
3590 
3591  parameters.set<SubProblem *>("_subproblem") = this;
3592  parameters.set<SystemBase *>("_sys") = _nl[nl_sys_num].get();
3593  }
3594 
3595  logAdd("DGKernel", name, dg_kernel_name, parameters);
3596  _nl[nl_sys_num]->addDGKernel(dg_kernel_name, name, parameters);
3597 
3599 }
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
bool _has_internal_edge_residual_objects
Whether the problem has dgkernels or interface kernels.

◆ addDiracKernel()

void FEProblemBase::addDiracKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3522 of file FEProblemBase.C.

3525 {
3526  parallel_object_only();
3527 
3528  const auto nl_sys_num = determineSolverSystem(parameters.varName("variable", name), true).second;
3529  if (!isSolverSystemNonlinear(nl_sys_num))
3530  mooseError("You are trying to add a DiracKernel to a linear variable/system, which is not "
3531  "supported at the moment!");
3532 
3533  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3534  {
3535  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
3536  parameters.set<SystemBase *>("_sys") = &_displaced_problem->solverSys(nl_sys_num);
3537  _reinit_displaced_elem = true;
3538  }
3539  else
3540  {
3541  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
3542  {
3543  // We allow DiracKernels to request that they use_displaced_mesh,
3544  // but then be overridden when no displacements variables are
3545  // provided in the Mesh block. If that happened, update the value
3546  // of use_displaced_mesh appropriately for this DiracKernel.
3547  if (parameters.have_parameter<bool>("use_displaced_mesh"))
3548  parameters.set<bool>("use_displaced_mesh") = false;
3549  }
3550 
3551  parameters.set<SubProblem *>("_subproblem") = this;
3552  parameters.set<SystemBase *>("_sys") = _nl[nl_sys_num].get();
3553  }
3554 
3555  logAdd("DiracKernel", name, kernel_name, parameters);
3556  _nl[nl_sys_num]->addDiracKernel(kernel_name, name, parameters);
3557 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addDisplacedProblem()

void FEProblemBase::addDisplacedProblem ( std::shared_ptr< DisplacedProblem displaced_problem)
virtualinherited

Definition at line 8372 of file FEProblemBase.C.

8373 {
8374  parallel_object_only();
8375 
8378 }
std::shared_ptr< DisplacedProblem > displaced_problem
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseMesh * _displaced_mesh

◆ addDistribution()

void FEProblemBase::addDistribution ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

The following functions will enable MOOSE to have the capability to import distributions.

Definition at line 2834 of file FEProblemBase.C.

2837 {
2838  parameters.set<std::string>("type") = type;
2839  addObject<Distribution>(type, name, parameters, /* threaded = */ false);
2840 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93

◆ addElementalFieldVariable()

void MFEMProblem::addElementalFieldVariable ( const std::string &  ,
const std::string &  ,
InputParameters  
)
inlineoverridevirtual

Override of FEProblemBase::addElementalFieldVariable to be a no-op because we do not use the Marker/Indicator objects designed to work with libMesh infrastructure.

Reimplemented from FEProblemBase.

Definition at line 141 of file MFEMProblem.h.

142  {
143  }

◆ addExternalVariables()

virtual void ExternalProblem::addExternalVariables ( )
inlinevirtualinherited

Method called to add AuxVariables to the simulation.

These variables would be the fields that should either be saved out with the MOOSE-formatted solutions or available for transfer to variables in Multiapp simulations.

Definition at line 48 of file ExternalProblem.h.

Referenced by AddExternalAuxVariableAction::act().

48 {}

◆ addFESpace()

void MFEMProblem::addFESpace ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)

Add an MFEM FESpace to the problem.

Definition at line 317 of file MFEMProblem.C.

Referenced by addMFEMFESpaceFromMOOSEVariable().

320 {
321  if (getProblemData().fespace_hierarchies.Has(name))
322  mooseError("Cannot add FESpace '",
323  name,
324  "': an MFEMFESpaceHierarchy with the same name already exists. "
325  "FESpaces and FESpaceHierarchies share the fespaces namespace.");
326 
327  auto & mfem_fespace = *addObject<MFEMFESpace>(type, name, parameters).front();
328 
329  // Register fespace and associated fe collection.
330  getProblemData().fecs.Register(name, mfem_fespace.getFEC());
331  getProblemData().fespaces.Register(name, mfem_fespace.getFESpace());
332 }
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
Moose::MFEM::FESpaces fespaces
Moose::MFEM::FECollections fecs
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
void Register(const std::string &field_name, FieldArgs &&... args)
Construct new field with name field_name and register.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ addFESpaceHierarchy()

void MFEMProblem::addFESpaceHierarchy ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)

Add an MFEMFESpaceHierarchy to the problem.

Definition at line 335 of file MFEMProblem.C.

338 {
339  if (getProblemData().fespaces.Has(name))
340  mooseError("Cannot add MFEMFESpaceHierarchy '",
341  name,
342  "': a FESpace with the same name already exists. "
343  "FESpaces and FESpaceHierarchies share the fespaces namespace.");
344 
345  auto hierarchy_obj = addObject<MFEMFESpaceHierarchy>(type, name, parameters).front();
346  auto hierarchy_shared = hierarchy_obj->getHierarchyShared();
347  // Register the hierarchy for co-ownership by solvers.
348  getProblemData().fespace_hierarchies.Register(name, hierarchy_shared);
349  // Register the finest-level FESpace in fespaces under the hierarchy name so that
350  // variables can say `fespace = <hierarchy_name>` without a separate FESpace definition.
351  // The aliasing shared_ptr keeps the hierarchy alive as long as this entry lives.
352  auto finest = std::shared_ptr<mfem::ParFiniteElementSpace>(
353  hierarchy_shared, &hierarchy_obj->getHierarchy().GetFinestFESpace());
355 }
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
Moose::MFEM::FESpaces fespaces
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
Moose::MFEM::FESpaceHierarchies fespace_hierarchies
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
void Register(const std::string &field_name, FieldArgs &&... args)
Construct new field with name field_name and register.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ addFunction()

void MFEMProblem::addFunction ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Override of ExternalProblem::addFunction.

Creates a corresponding MFEM Coefficient or VectorCoefficient object for the added MOOSE function.

Reimplemented from FEProblemBase.

Definition at line 587 of file MFEMProblem.C.

590 {
592  auto & func = getFunction(name);
593  // FIXME: Do we want to have optimised versions for when functions
594  // are only of space or only of time.
595  if (std::find(SCALAR_FUNCS.begin(), SCALAR_FUNCS.end(), type) != SCALAR_FUNCS.end())
596  {
597  getCoefficients().declareScalar<mfem::FunctionCoefficient>(
598  name,
599  [&func](const mfem::Vector & p, mfem::real_t t) -> mfem::real_t
600  { return func.value(t, Moose::MFEM::libMeshPointFromMFEMVector(p)); });
601  }
602  else if (std::find(VECTOR_FUNCS.begin(), VECTOR_FUNCS.end(), type) != VECTOR_FUNCS.end())
603  {
605  getCoefficients().declareVector<mfem::VectorFunctionCoefficient>(
606  name,
607  dim,
608  [&func, dim](const mfem::Vector & p, mfem::real_t t, mfem::Vector & u)
609  {
610  libMesh::RealVectorValue vector_value =
611  func.vectorValue(t, Moose::MFEM::libMeshPointFromMFEMVector(p));
612  for (int i = 0; i < dim; i++)
613  {
614  u[i] = vector_value(i);
615  }
616  });
617  }
618  else if ("MFEMParsedFunction" != type)
619  {
620  mooseWarning("Could not identify whether function ",
621  type,
622  " is scalar or vector; no MFEM coefficient object created.");
623  }
624 }
KOKKOS_INLINE_FUNCTION const T * find(const T &target, const T *const begin, const T *const end)
Find a value in an array.
Definition: KokkosUtils.h:40
libMesh::Point libMeshPointFromMFEMVector(const mfem::Vector &vec)
Convert an MFEM position vector to a libMesh::Point.
const std::vector< std::string > SCALAR_FUNCS
Definition: MFEMProblem.C:547
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
static constexpr std::size_t dim
This is the dimension of all vector and tensor datastructures used in MOOSE.
Definition: Moose.h:165
int vectorFunctionDim(const std::string &type, const InputParameters &parameters)
Definition: MFEMProblem.C:535
virtual Function & getFunction(const std::string &name, const THREAD_ID tid=0)
void mooseWarning(Args &&... args) const
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
mfem::Coefficient & declareScalar(const std::string &name, const std::string &existing_or_literal)
Declare an alias to an existing scalar coefficient or, if it does not exist, try interpreting the nam...
mfem::VectorCoefficient & declareVector(const std::string &name, const std::string &existing_or_literal)
Declare an alias to an existing vector coefficientor or, if it does not exist, try interpreting the n...
virtual void addFunction(const std::string &type, const std::string &name, InputParameters &parameters)
Moose::MFEM::CoefficientManager & getCoefficients()
Method to get the PropertyManager object for storing material properties and converting them to MFEM ...
Definition: MFEMProblem.h:265
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
const std::vector< std::string > VECTOR_FUNCS
Definition: MFEMProblem.C:584

◆ addFunctor()

template<typename T >
void SubProblem::addFunctor ( const std::string &  name,
const Moose::FunctorBase< T > &  functor,
const THREAD_ID  tid 
)
inherited

add a functor to the problem functor container

Definition at line 1393 of file SubProblem.h.

Referenced by FEProblemBase::addFunction(), SubProblem::addPiecewiseByBlockLambdaFunctor(), FEProblemBase::addUserObject(), and SystemBase::addVariable().

1396 {
1397  constexpr bool added_functor_is_ad =
1398  !std::is_same<T, typename MetaPhysicL::RawType<T>::value_type>::value;
1399 
1400  mooseAssert(tid < _functors.size(), "Too large a thread ID");
1401 
1402  auto & functor_to_request_info = _functor_to_request_info[tid];
1403  auto & functors = _functors[tid];
1404  auto it = functors.find("wraps_" + name);
1405  if (it != functors.end())
1406  {
1407  // We have this functor already. If it's a null functor, we want to replace it with the valid
1408  // functor we have now. If it's not then we'll add a new entry into the multimap and then we'll
1409  // error later if a user requests a functor because their request is ambiguous. This is the
1410  // reason that the functors container is a multimap: for nice error messages
1411  auto * const existing_wrapper_base =
1412  added_functor_is_ad ? std::get<2>(it->second).get() : std::get<1>(it->second).get();
1413  auto * const existing_wrapper = dynamic_cast<Moose::Functor<T> *>(existing_wrapper_base);
1414  if (existing_wrapper && existing_wrapper->template wrapsType<Moose::NullFunctor<T>>())
1415  {
1416  // Sanity check
1417  auto [request_info_it, request_info_end_it] = functor_to_request_info.equal_range(name);
1418  if (request_info_it == request_info_end_it)
1419  mooseError("We are wrapping a NullFunctor but we don't have any unfilled functor request "
1420  "info. This doesn't make sense.");
1421 
1422  // Check for valid requests
1423  while (request_info_it != request_info_end_it)
1424  {
1425  auto & [requested_functor_is_ad, requestor_is_ad] = request_info_it->second;
1426  if (!requested_functor_is_ad && requestor_is_ad && added_functor_is_ad)
1427  mooseError("We are requesting a non-AD functor '" + name +
1428  "' from an AD object, but the true functor is AD. This means we could be "
1429  "dropping important derivatives. We will not allow this");
1430  // We're going to eventually check whether we've fulfilled all functor requests and our
1431  // check will be that the multimap is empty. This request is fulfilled, so erase it from the
1432  // map now
1433  request_info_it = functor_to_request_info.erase(request_info_it);
1434  }
1435 
1436  // Ok we didn't have the functor before, so we will add it now
1437  std::get<0>(it->second) =
1439  existing_wrapper->assign(functor);
1440  // Finally we create the non-AD or AD complement of the just added functor
1441  if constexpr (added_functor_is_ad)
1442  {
1443  typedef typename MetaPhysicL::RawType<T>::value_type NonADType;
1444  auto * const existing_non_ad_wrapper_base = std::get<1>(it->second).get();
1445  auto * const existing_non_ad_wrapper =
1446  dynamic_cast<Moose::Functor<NonADType> *>(existing_non_ad_wrapper_base);
1447  mooseAssert(existing_non_ad_wrapper->template wrapsType<Moose::NullFunctor<NonADType>>(),
1448  "Both members of pair should have been wrapping a NullFunctor");
1449  existing_non_ad_wrapper->assign(
1450  std::make_unique<Moose::RawValueFunctor<NonADType>>(functor));
1451  }
1452  else
1453  {
1454  typedef typename Moose::ADType<T>::type ADType;
1455  auto * const existing_ad_wrapper_base = std::get<2>(it->second).get();
1456  auto * const existing_ad_wrapper =
1457  dynamic_cast<Moose::Functor<ADType> *>(existing_ad_wrapper_base);
1458  mooseAssert(existing_ad_wrapper->template wrapsType<Moose::NullFunctor<ADType>>(),
1459  "Both members of pair should have been wrapping a NullFunctor");
1460  existing_ad_wrapper->assign(std::make_unique<Moose::ADWrapperFunctor<ADType>>(functor));
1461  }
1462  return;
1463  }
1464  else if (!existing_wrapper)
1465  {
1466  // Functor was emplaced but the cast failed. This could be a double definition with
1467  // different types, or it could be a request with one type then a definition with another
1468  // type. Either way it is going to error later, but it is cleaner to catch it now
1469  mooseError("Functor '",
1470  name,
1471  "' is being added with return type '",
1472  MooseUtils::prettyCppType<T>(),
1473  "' but it has already been defined or requested with return type '",
1474  existing_wrapper_base->returnType(),
1475  "'.");
1476  }
1477  }
1478 
1479  // We are a new functor, create the opposite ADType one and store it with other functors
1480  if constexpr (added_functor_is_ad)
1481  {
1482  typedef typename MetaPhysicL::RawType<T>::value_type NonADType;
1483  auto new_non_ad_wrapper = std::make_unique<Moose::Functor<NonADType>>(
1484  std::make_unique<Moose::RawValueFunctor<NonADType>>(functor));
1485  auto new_ad_wrapper = std::make_unique<Moose::Functor<T>>(functor);
1486  _functors[tid].emplace("wraps_" + name,
1487  std::make_tuple(SubProblem::TrueFunctorIs::AD,
1488  std::move(new_non_ad_wrapper),
1489  std::move(new_ad_wrapper)));
1490  }
1491  else
1492  {
1493  typedef typename Moose::ADType<T>::type ADType;
1494  auto new_non_ad_wrapper = std::make_unique<Moose::Functor<T>>((functor));
1495  auto new_ad_wrapper = std::make_unique<Moose::Functor<ADType>>(
1496  std::make_unique<Moose::ADWrapperFunctor<ADType>>(functor));
1497  _functors[tid].emplace("wraps_" + name,
1498  std::make_tuple(SubProblem::TrueFunctorIs::NONAD,
1499  std::move(new_non_ad_wrapper),
1500  std::move(new_ad_wrapper)));
1501  }
1502 }
This is a wrapper that forwards calls to the implementation, which can be switched out at any time wi...
Wraps non-AD functors such that they can be used in objects that have requested the functor as AD...
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::vector< std::multimap< std::string, std::pair< bool, bool > > > _functor_to_request_info
A multimap (for each thread) from unfilled functor requests to whether the requests were for AD funct...
Definition: SubProblem.h:1176
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::vector< std::multimap< std::string, std::tuple< TrueFunctorIs, std::unique_ptr< Moose::FunctorEnvelopeBase >, std::unique_ptr< Moose::FunctorEnvelopeBase > > > > _functors
A container holding pointers to all the functors in our problem.
Definition: SubProblem.h:1159
A functor that serves as a placeholder during the simulation setup phase if a functor consumer reques...
const Elem & get(const ElemType type_in)

◆ addFunctorMaterial()

void MFEMProblem::addFunctorMaterial ( const std::string &  material_name,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Reimplemented from FEProblemBase.

Definition at line 309 of file MFEMProblem.C.

312 {
313  addObject<MFEMFunctorMaterial>(material_name, name, parameters);
314 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addFVBC()

void FEProblemBase::addFVBC ( const std::string &  fv_bc_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3616 of file FEProblemBase.C.

Referenced by DiffusionFV::addFVBCs().

3619 {
3620  addObject<FVBoundaryCondition>(fv_bc_name, name, parameters);
3621 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addFVInitialCondition()

void FEProblemBase::addFVInitialCondition ( const std::string &  ic_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Add an initial condition for a finite volume variables.

Parameters
ic_nameThe name of the boundary condition object
nameThe user-defined name from the input file
parametersThe input parameters for construction

Definition at line 3785 of file FEProblemBase.C.

3788 {
3789  parallel_object_only();
3790 
3791  // before we start to mess with the initial condition, we need to check parameters for errors.
3793  const std::string & var_name = parameters.get<VariableName>("variable");
3794 
3795  // Forbid initial conditions on a restarted problem, as they would override the restart
3796  checkICRestartError(ic_name, name, var_name);
3797 
3798  parameters.set<SubProblem *>("_subproblem") = this;
3799 
3800  // field IC
3801  if (hasVariable(var_name))
3802  {
3803  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); ++tid)
3804  {
3805  auto & var = getVariable(
3807  parameters.set<SystemBase *>("_sys") = &var.sys();
3808  std::shared_ptr<FVInitialConditionBase> ic;
3809  if (var.isFV())
3810  ic = _factory.create<FVInitialCondition>(ic_name, name, parameters, tid);
3811  else
3812  mooseError(
3813  "Your variable for an FVInitialCondition needs to be an a finite volume variable!");
3814  _fv_ics.addObject(ic, tid);
3815  }
3816  }
3817  else
3818  mooseError("Variable '",
3819  var_name,
3820  "' requested in finite volume initial condition '",
3821  name,
3822  "' does not exist.");
3823 }
virtual bool hasVariable(const std::string &var_name) const override
Whether or not this problem has the variable.
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
unsigned int n_threads()
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
Base class for a system (of equations)
Definition: SystemBase.h:85
virtual const MooseVariableFieldBase & getVariable(const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY) const override
Returns the variable reference for requested variable which must be of the expected_var_type (Nonline...
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
virtual std::unique_ptr< Base > create()=0
void checkParams(const std::string &parsing_syntax)
This function checks parameters stored in the object to make sure they are in the correct state as th...
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
void checkICRestartError(const std::string &ic_name, const std::string &name, const VariableName &var_name)
Checks if the variable of the initial condition is getting restarted and errors for specific cases...
void addObject(std::shared_ptr< FVInitialConditionBase > object, THREAD_ID tid, bool recurse=true)
Add object to the warehouse.
FVInitialConditionWarehouse _fv_ics
This is a template class that implements the workhorse compute and computeNodal methods.
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ addFVInterfaceKernel()

void FEProblemBase::addFVInterfaceKernel ( const std::string &  fv_ik_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

We assume that variable1 and variable2 can live on different systems, in this case the user needs to create two interface kernels with flipped variables and parameters

Definition at line 3624 of file FEProblemBase.C.

3627 {
3630  addObject<FVInterfaceKernel>(
3631  fv_ik_name, name, parameters, /*threaded=*/true, /*variable_param_name=*/"variable1");
3632 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addFVInterpolationMethod()

void FEProblemBase::addFVInterpolationMethod ( const std::string &  method_type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Add an FV interpolation method.

Parameters
method_typeThe type of the method.
nameThe name of the method.
parametersThe input parameters of the method.

Definition at line 4719 of file FEProblemBase.C.

4722 {
4723  parallel_object_only();
4724 
4726 
4727  for (const auto tid : make_range(libMesh::n_threads()))
4728  {
4729  auto method = _factory.create<FVInterpolationMethod>(method_type, name, parameters, tid);
4730  logAdd("FVInterpolationMethod", name, method_type, parameters);
4731  theWarehouse().add(method);
4732  }
4733 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
unsigned int n_threads()
void add(std::shared_ptr< MooseObject > obj)
add adds a new object to the warehouse and stores attributes/metadata about it for running queries/fi...
Definition: TheWarehouse.C:116
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Registered base class for linear FV interpolation objects.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
virtual std::unique_ptr< Base > create()=0
TheWarehouse & theWarehouse() const
IntRange< T > make_range(T beg, T end)
void addObjectParamsHelper(InputParameters &params, const std::string &object_name, const std::string &var_param_name="variable")
Helper for setting the "_subproblem" and "_sys" parameters in addObject() and in addUserObject().

◆ addFVKernel()

void FEProblemBase::addFVKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3602 of file FEProblemBase.C.

Referenced by DiffusionFV::addFVKernels().

3605 {
3606  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3607  // FVElementalKernels are computed in the historically finite element threaded loops. They rely
3608  // on Assembly data like _current_elem. When we call reinit on the FEProblemBase we will only
3609  // reinit the DisplacedProblem and its associated Assembly objects if we mark this boolean as
3610  // true
3611  _reinit_displaced_elem = true;
3612  addObject<FVKernel>(fv_kernel_name, name, parameters);
3613 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addGhostedBoundary()

void FEProblemBase::addGhostedBoundary ( BoundaryID  boundary_id)
overridevirtualinherited

Will make sure that all necessary elements from boundary_id are ghosted to this processor.

Implements SubProblem.

Definition at line 2232 of file FEProblemBase.C.

Referenced by DisplacedProblem::addGhostedBoundary().

2233 {
2234  _mesh.addGhostedBoundary(boundary_id);
2235  if (_displaced_problem)
2236  _displaced_mesh->addGhostedBoundary(boundary_id);
2237 }
MooseMesh & _mesh
std::shared_ptr< DisplacedProblem > _displaced_problem
void addGhostedBoundary(BoundaryID boundary_id)
This will add the boundary ids to be ghosted to this processor.
Definition: MooseMesh.C:3329
MooseMesh * _displaced_mesh

◆ addGhostedElem()

void FEProblemBase::addGhostedElem ( dof_id_type  elem_id)
overridevirtualinherited

Will make sure that all dofs connected to elem_id are ghosted to this processor.

Implements SubProblem.

Definition at line 2225 of file FEProblemBase.C.

Referenced by DisplacedProblem::addGhostedElem(), and NodalPatchRecovery::NodalPatchRecovery().

2226 {
2227  if (_mesh.elemPtr(elem_id)->processor_id() != processor_id())
2228  _ghosted_elems.insert(elem_id);
2229 }
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
std::set< dof_id_type > _ghosted_elems
Elements that should have Dofs ghosted to the local processor.
Definition: SubProblem.h:1108
MooseMesh & _mesh
processor_id_type processor_id() const
processor_id_type processor_id() const

◆ addGridFunction()

void MFEMProblem::addGridFunction ( const std::string &  var_type,
const std::string &  var_name,
InputParameters parameters 
)

Adds one MFEM GridFunction to be used in the MFEM solve.

Definition at line 392 of file MFEMProblem.C.

Referenced by addAuxVariable(), MFEMEigenproblem::addVariable(), and addVariable().

395 {
396 
397  if (var_type == "MFEMVariable" || var_type == "MFEMComplexVariable")
398  {
399  // Add MFEM variable directly.
400  if (var_type == "MFEMComplexVariable")
401  addObject<MFEMComplexVariable>(var_type, var_name, parameters);
402  else
403  addObject<MFEMVariable>(var_type, var_name, parameters);
404  }
405  else
406  {
407  // Add MOOSE variable.
408  ExternalProblem::addVariable(var_type, var_name, parameters);
409 
410  // Add MFEM variable indirectly ("gridfunction").
412  addObject<MFEMVariable>("MFEMVariable", var_name, mfem_variable_params);
413  }
414 
415  // Register gridfunction.
416  if (var_type == "MFEMComplexVariable")
417  {
418  MFEMComplexVariable & mfem_variable =
419  getMFEMObject<MFEMComplexVariable>("MooseVariableBase", var_name);
421  mfem_variable.declareCoefficients();
422  }
423  else // must be real, but may have been set up indirectly from a MOOSE variable
424  {
425  MFEMVariable & mfem_variable = getMFEMObject<MFEMVariable>("MooseVariableBase", var_name);
426  getProblemData().gridfunctions.Register(var_name, mfem_variable.getGridFunction());
427  mfem_variable.declareCoefficients();
428  }
429 }
Constructs and stores an mfem::ParComplexGridFunction object.
std::shared_ptr< mfem::ParComplexGridFunction > getComplexGridFunction() const
Returns a shared pointer to the constructed gridfunction.
Moose::MFEM::ComplexGridFunctions cmplx_gridfunctions
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
InputParameters addMFEMFESpaceFromMOOSEVariable(InputParameters &moosevar_params)
Method used to get an mfem FEC depending on the variable family specified in the input file...
Definition: MFEMProblem.C:658
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
Constructs and stores an mfem::ParGridFunction object.
Definition: MFEMVariable.h:19
std::shared_ptr< mfem::ParGridFunction > getGridFunction() const
Returns a shared pointer to the constructed gridfunction.
Definition: MFEMVariable.h:27
virtual void addVariable(const std::string &var_type, const std::string &var_name, InputParameters &params)
Canonical method for adding a non-linear variable.
void Register(const std::string &field_name, FieldArgs &&... args)
Construct new field with name field_name and register.
void declareCoefficients()
Declare default coefficients associated with this gridfunction.
Definition: MFEMVariable.C:88
Moose::MFEM::GridFunctions gridfunctions

◆ addHDGKernel()

void FEProblemBase::addHDGKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3170 of file FEProblemBase.C.

3173 {
3174  parallel_object_only();
3175  const auto nl_sys_num = determineSolverSystem(parameters.varName("variable", name), true).second;
3176  if (!isSolverSystemNonlinear(nl_sys_num))
3177  mooseError("You are trying to add a HDGKernel to a linear variable/system, which is not "
3178  "supported at the moment!");
3180  kernel_name, name, parameters, nl_sys_num, "HDGKernel", _reinit_displaced_elem);
3181 
3182  _nl[nl_sys_num]->addHDGKernel(kernel_name, name, parameters);
3183 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
void setResidualObjectParamsAndLog(const std::string &ro_name, const std::string &name, InputParameters &parameters, const unsigned int nl_sys_num, const std::string &base_name, bool &reinit_displaced)
Set the subproblem and system parameters for residual objects and log their addition.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ addImagComponentToBC()

void MFEMProblem::addImagComponentToBC ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)

Adds an imaginary component BC to the parent MFEMComplexIntegratedBC.

Definition at line 520 of file MFEMProblem.C.

523 {
525  getMFEMObject<MFEMComplexIntegratedBC>("BoundaryCondition", name).getSharedPtr());
526  parameters.set<VariableName>("variable") = parent_ptr->getParam<VariableName>("variable");
527  parameters.set<std::vector<BoundaryName>>("boundary") =
528  parent_ptr->getParam<std::vector<BoundaryName>>("boundary");
530  addObject<MFEMBoundaryCondition>(kernel_name, name + "_imag", parameters).front());
531  parent_ptr->setImagBC(bc_ptr);
532 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
std::shared_ptr< MooseObject > getSharedPtr()
Get another shared pointer to this object that has the same ownership group.
Definition: MooseObject.C:70
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addImagComponentToKernel()

void MFEMProblem::addImagComponentToKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)

Adds an imaginary component kernel to the parent MFEMComplexKernel.

Definition at line 493 of file MFEMProblem.C.

496 {
497  auto parent_ptr = std::dynamic_pointer_cast<MFEMComplexKernel>(
498  getMFEMObject<MFEMComplexKernel>("Kernel", name).getSharedPtr());
499  parameters.set<VariableName>("variable") = parent_ptr->getParam<VariableName>("variable");
500  auto kernel_ptr = addObject<MFEMKernel>(kernel_name, name + "_imag", parameters).front();
501  parent_ptr->setImagKernel(kernel_ptr);
502 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
std::shared_ptr< MooseObject > getSharedPtr()
Get another shared pointer to this object that has the same ownership group.
Definition: MooseObject.C:70
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addIndicator()

void MFEMProblem::addIndicator ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Override of FEProblemBase::addIndicator.

Creates the MFEMIndicator used when setting up adaptive mesh refinement later.

Reimplemented from FEProblemBase.

Definition at line 129 of file MFEMProblem.C.

132 {
133  auto estimator = addObject<MFEMIndicator>(indicator_type, name, parameters).front();
134 
135  // construct the estimator itself
136  estimator->createEstimator();
137 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addInitialCondition()

void MFEMProblem::addInitialCondition ( const std::string &  ic_name,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Add an MFEM initial condition to the problem.

Reimplemented from FEProblemBase.

Definition at line 821 of file MFEMProblem.C.

824 {
825  addObject<MFEMExecutedObject>(ic_name, name, parameters);
826 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addInterfaceKernel()

void FEProblemBase::addInterfaceKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3653 of file FEProblemBase.C.

3656 {
3657  parallel_object_only();
3658 
3659  const auto nl_sys_num = determineSolverSystem(parameters.varName("variable", name), true).second;
3660  if (!isSolverSystemNonlinear(nl_sys_num))
3661  mooseError("You are trying to add a InterfaceKernel to a linear variable/system, which is not "
3662  "supported at the moment!");
3663 
3664  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3665  {
3666  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
3667  parameters.set<SystemBase *>("_sys") = &_displaced_problem->solverSys(nl_sys_num);
3669  }
3670  else
3671  {
3672  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
3673  {
3674  // We allow InterfaceKernels to request that they use_displaced_mesh,
3675  // but then be overridden when no displacements variables are
3676  // provided in the Mesh block. If that happened, update the value
3677  // of use_displaced_mesh appropriately for this InterfaceKernel.
3678  if (parameters.have_parameter<bool>("use_displaced_mesh"))
3679  parameters.set<bool>("use_displaced_mesh") = false;
3680  }
3681 
3682  parameters.set<SubProblem *>("_subproblem") = this;
3683  parameters.set<SystemBase *>("_sys") = _nl[nl_sys_num].get();
3684  }
3685 
3686  logAdd("InterfaceKernel", name, interface_kernel_name, parameters);
3687  _nl[nl_sys_num]->addInterfaceKernel(interface_kernel_name, name, parameters);
3688 
3690 }
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
bool _has_internal_edge_residual_objects
Whether the problem has dgkernels or interface kernels.

◆ addInterfaceMaterial()

void FEProblemBase::addInterfaceMaterial ( const std::string &  material_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 4130 of file FEProblemBase.C.

4133 {
4135 }
virtual void addMaterialHelper(std::vector< MaterialWarehouse *> warehouse, const std::string &material_name, const std::string &name, InputParameters &parameters)
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
MaterialWarehouse _interface_materials
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addJacobian()

void FEProblemBase::addJacobian ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 2069 of file FEProblemBase.C.

Referenced by ComputeDiracThread::postElement().

2070 {
2071  _assembly[tid][_current_nl_sys->number()]->addJacobian(Assembly::GlobalDataKey{});
2073  _assembly[tid][_current_nl_sys->number()]->addJacobianNonlocal(Assembly::GlobalDataKey{});
2074  if (_displaced_problem)
2075  {
2076  _displaced_problem->addJacobian(tid);
2078  _displaced_problem->addJacobianNonlocal(tid);
2079  }
2080 }
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addJacobianBlockTags()

void FEProblemBase::addJacobianBlockTags ( libMesh::SparseMatrix< libMesh::Number > &  jacobian,
unsigned int  ivar,
unsigned int  jvar,
const DofMap dof_map,
std::vector< dof_id_type > &  dof_indices,
const std::set< TagID > &  tags,
const THREAD_ID  tid 
)
virtualinherited

Definition at line 2144 of file FEProblemBase.C.

Referenced by ComputeJacobianBlocksThread::postElement().

2151 {
2152  _assembly[tid][_current_nl_sys->number()]->addJacobianBlockTags(
2153  jacobian, ivar, jvar, dof_map, dof_indices, Assembly::GlobalDataKey{}, tags);
2154 
2156  if (_nonlocal_cm[_current_nl_sys->number()](ivar, jvar) != 0)
2157  {
2158  MooseVariableFEBase & jv = _current_nl_sys->getVariable(tid, jvar);
2159  _assembly[tid][_current_nl_sys->number()]->addJacobianBlockNonlocalTags(
2160  jacobian,
2161  ivar,
2162  jvar,
2163  dof_map,
2164  dof_indices,
2165  jv.allDofIndices(),
2167  tags);
2168  }
2169 
2170  if (_displaced_problem)
2171  {
2172  _displaced_problem->addJacobianBlockTags(jacobian, ivar, jvar, dof_map, dof_indices, tags, tid);
2174  if (_nonlocal_cm[_current_nl_sys->number()](ivar, jvar) != 0)
2175  {
2176  MooseVariableFEBase & jv = _current_nl_sys->getVariable(tid, jvar);
2177  _displaced_problem->addJacobianBlockNonlocal(
2178  jacobian, ivar, jvar, dof_map, dof_indices, jv.allDofIndices(), tags, tid);
2179  }
2180  }
2181 }
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.
This class provides an interface for common operations on field variables of both FE and FV types wit...
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
const std::vector< dof_id_type > & allDofIndices() const
Get all global dofindices for the variable.
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseVariableFieldBase & getVariable(THREAD_ID tid, const std::string &var_name) const
Gets a reference to a variable of with specified name.
Definition: SystemBase.C:91
std::vector< libMesh::CouplingMatrix > _nonlocal_cm
nonlocal coupling matrix
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addJacobianLowerD()

void FEProblemBase::addJacobianLowerD ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 2099 of file FEProblemBase.C.

Referenced by ComputeResidualAndJacobianThread::accumulateLower(), and ComputeJacobianThread::accumulateLower().

2100 {
2101  _assembly[tid][_current_nl_sys->number()]->addJacobianLowerD(Assembly::GlobalDataKey{});
2102  if (_displaced_problem)
2103  _displaced_problem->addJacobianLowerD(tid);
2104 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addJacobianNeighbor() [1/3]

virtual void SubProblem::addJacobianNeighbor ( libMesh::SparseMatrix< libMesh::Number > &  jacobian,
unsigned int  ivar,
unsigned int  jvar,
const libMesh::DofMap dof_map,
std::vector< dof_id_type > &  dof_indices,
std::vector< dof_id_type > &  neighbor_dof_indices,
const std::set< TagID > &  tags,
const THREAD_ID  tid 
)
pure virtualinherited

Implemented in DisplacedProblem.

◆ addJacobianNeighbor() [2/3]

void FEProblemBase::addJacobianNeighbor ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 2083 of file FEProblemBase.C.

Referenced by ComputeResidualAndJacobianThread::accumulateNeighbor(), ComputeJacobianThread::accumulateNeighbor(), and ComputeJacobianBlocksThread::postInternalSide().

2084 {
2085  _assembly[tid][_current_nl_sys->number()]->addJacobianNeighbor(Assembly::GlobalDataKey{});
2086  if (_displaced_problem)
2087  _displaced_problem->addJacobianNeighbor(tid);
2088 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addJacobianNeighbor() [3/3]

virtual void FEProblemBase::addJacobianNeighbor ( libMesh::SparseMatrix< libMesh::Number > &  jacobian,
unsigned int  ivar,
unsigned int  jvar,
const DofMap &  dof_map,
std::vector< dof_id_type > &  dof_indices,
std::vector< dof_id_type > &  neighbor_dof_indices,
const std::set< TagID > &  tags,
const THREAD_ID  tid 
)
overridevirtualinherited

◆ addJacobianNeighborLowerD()

void FEProblemBase::addJacobianNeighborLowerD ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 2091 of file FEProblemBase.C.

Referenced by ComputeResidualAndJacobianThread::accumulateNeighborLower(), and ComputeJacobianThread::accumulateNeighborLower().

2092 {
2093  _assembly[tid][_current_nl_sys->number()]->addJacobianNeighborLowerD(Assembly::GlobalDataKey{});
2094  if (_displaced_problem)
2095  _displaced_problem->addJacobianNeighborLowerD(tid);
2096 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addJacobianOffDiagScalar()

void FEProblemBase::addJacobianOffDiagScalar ( unsigned int  ivar,
const THREAD_ID  tid = 0 
)
virtualinherited

Definition at line 2113 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeScalarKernelsJacobians().

2114 {
2115  _assembly[tid][_current_nl_sys->number()]->addJacobianOffDiagScalar(ivar,
2117 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addJacobianScalar()

void FEProblemBase::addJacobianScalar ( const THREAD_ID  tid = 0)
virtualinherited

Definition at line 2107 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeScalarKernelsJacobians().

2108 {
2109  _assembly[tid][_current_nl_sys->number()]->addJacobianScalar(Assembly::GlobalDataKey{});
2110 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addKernel()

void MFEMProblem::addKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Override of ExternalProblem::addKernel.

Creates the MOOSE-side MFEM kernel wrapper and the corresponding MFEM kernel to be used in the MFEM solve.

Reimplemented from FEProblemBase.

Definition at line 450 of file MFEMProblem.C.

453 {
454  auto kernel = addObject<MFEMKernel>(kernel_name, name, parameters).front();
455  const auto & kernel_object = *kernel;
456 
457  if (dynamic_cast<const MFEMComplexKernel *>(&kernel_object))
458  {
459  auto complex_kernel = std::dynamic_pointer_cast<MFEMComplexKernel>(kernel);
460  auto eqsys =
462  if (eqsys)
463  eqsys->AddComplexKernel(std::move(complex_kernel));
464  else
465  mooseError("Cannot add complex kernel with name '" + name +
466  "' because there is no corresponding equation system.");
467  }
468  else
469  {
470  auto eqsys =
472  if (eqsys)
473  eqsys->AddKernel(std::move(kernel));
474  else
475  mooseError("Cannot add kernel with name '" + name +
476  "' because there is no corresponding equation system.");
477  }
478 }
virtual void AddKernel(std::shared_ptr< MFEMKernel > kernel)
Add kernels.
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
Owns the weak-form mathematics of a MOOSE MFEM problem.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< Moose::MFEM::EquationSystem > eqn_system
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
void AddComplexKernel(std::shared_ptr< MFEMComplexKernel > kernel)
Add complex kernels.

◆ addKokkosAuxKernel()

virtual void FEProblemBase::addKokkosAuxKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosBoundaryCondition()

virtual void FEProblemBase::addKokkosBoundaryCondition ( const std::string &  bc_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosFunction()

virtual void FEProblemBase::addKokkosFunction ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Add a Kokkos function to the problem.

Parameters
typeThe Kokkos function type
nameThe Kokkos function name
parametersThe Kokkos function input parameters

Referenced by FEProblemBase::getKokkosFunction().

◆ addKokkosKernel()

virtual void FEProblemBase::addKokkosKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosLinearFVBC()

virtual void FEProblemBase::addKokkosLinearFVBC ( const std::string &  bc_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosLinearFVKernel()

virtual void FEProblemBase::addKokkosLinearFVKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosMaterial()

virtual void FEProblemBase::addKokkosMaterial ( const std::string &  material_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosMeshInitializationHook()

void FEProblemBase::addKokkosMeshInitializationHook ( std::function< void()>  function)
inlineinherited

Add a function hook that needs to be called after Kokkos mesh initialization.

Parameters
functionThe function to be called

Definition at line 2975 of file FEProblemBase.h.

Referenced by BlockRestrictable::initializeBlockRestrictable(), and BoundaryRestrictable::initializeBoundaryRestrictable().

2976  {
2977  _kokkos_mesh_initialization_hooks.push_back(function);
2978  }
std::vector< std::function< void()> > _kokkos_mesh_initialization_hooks
Container holding hooks for functions that need to be called after Kokkos mesh initialization.

◆ addKokkosNodalKernel()

virtual void FEProblemBase::addKokkosNodalKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosPostprocessor()

virtual void FEProblemBase::addKokkosPostprocessor ( const std::string &  pp_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosReporter()

virtual void FEProblemBase::addKokkosReporter ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosUserObject()

virtual void FEProblemBase::addKokkosUserObject ( const std::string &  user_object_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addKokkosVectorPostprocessor()

virtual void FEProblemBase::addKokkosVectorPostprocessor ( const std::string &  pp_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

◆ addLinearFVBC()

void FEProblemBase::addLinearFVBC ( const std::string &  fv_bc_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3643 of file FEProblemBase.C.

3646 {
3647  addObject<LinearFVBoundaryCondition>(bc_name, name, parameters);
3648 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addLinearFVKernel()

void FEProblemBase::addLinearFVKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3635 of file FEProblemBase.C.

3638 {
3639  addObject<LinearFVKernel>(kernel_name, name, parameters);
3640 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addLineSearch()

virtual void FEProblemBase::addLineSearch ( const InputParameters )
inlinevirtualinherited

add a MOOSE line search

Reimplemented in DumpObjectsProblem, and FEProblem.

Definition at line 816 of file FEProblemBase.h.

Referenced by FEProblemSolve::FEProblemSolve().

817  {
818  mooseError("Line search not implemented for this problem type yet.");
819  }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ addMarker()

void MFEMProblem::addMarker ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Override of FEProblemBase::addMarker.

Creates the MFEMRefinementMarker used for adaptive mesh refinement.

Reimplemented from FEProblemBase.

Definition at line 140 of file MFEMProblem.C.

143 {
144  getProblemData().refiner = addObject<MFEMRefinementMarker>(marker_type, name, parameters).front();
145 }
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< MFEMRefinementMarker > refiner

◆ addMaterial()

void MFEMProblem::addMaterial ( const std::string &  material_name,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Reimplemented from FEProblemBase.

Definition at line 302 of file MFEMProblem.C.

303 {
304  mooseError(
305  "MFEM materials must be added through the 'FunctorMaterials' block and not 'Materials'");
306 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ addMaterialHelper()

void FEProblemBase::addMaterialHelper ( std::vector< MaterialWarehouse *>  warehouse,
const std::string &  material_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 4138 of file FEProblemBase.C.

Referenced by FEProblemBase::addInterfaceMaterial(), and FEProblemBase::addMaterial().

4142 {
4143  parallel_object_only();
4144 
4145  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
4146  {
4147  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
4149  }
4150  else
4151  {
4152  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
4153  {
4154  // We allow Materials to request that they use_displaced_mesh,
4155  // but then be overridden when no displacements variables are
4156  // provided in the Mesh block. If that happened, update the value
4157  // of use_displaced_mesh appropriately for this Material.
4158  if (parameters.have_parameter<bool>("use_displaced_mesh"))
4159  parameters.set<bool>("use_displaced_mesh") = false;
4160  }
4161 
4162  parameters.set<SubProblem *>("_subproblem") = this;
4163  }
4164 
4165  unsigned int n_threads = libMesh::n_threads();
4166 
4167 #ifdef MOOSE_KOKKOS_ENABLED
4168  if (parameters.isKokkosObject())
4169  n_threads = 1;
4170 #endif
4171 
4172  for (THREAD_ID tid = 0; tid < n_threads; tid++)
4173  {
4174  // Create the general Block/Boundary MaterialBase object
4175  std::shared_ptr<MaterialBase> material =
4176  _factory.create<MaterialBase>(mat_name, name, parameters, tid);
4177  logAdd("Material", name, mat_name, parameters);
4178  bool discrete = !material->getParam<bool>("compute");
4179 
4180  // If the object is boundary restricted or if it is a functor material we do not create the
4181  // neighbor and face objects
4182  if (material->boundaryRestricted() || dynamic_cast<FunctorMaterial *>(material.get()))
4183  {
4184  _all_materials.addObject(material, tid);
4185  if (discrete)
4186  _discrete_materials.addObject(material, tid);
4187  else
4188  for (auto && warehouse : warehouses)
4189  warehouse->addObject(material, tid);
4190  }
4191 
4192  // Non-boundary restricted require face and neighbor objects
4193  else
4194  {
4195  // TODO: we only need to do this if we have needs for face materials (e.g.
4196  // FV, DG, etc.) - but currently we always do it. Figure out how to fix
4197  // this.
4198 
4199  // The name of the object being created, this is changed multiple times as objects are
4200  // created below
4201  std::string object_name;
4202 
4203  // Create a copy of the supplied parameters to the setting for "_material_data_type" isn't
4204  // used from a previous tid loop
4205  InputParameters current_parameters = parameters;
4206 
4207  // face material
4208  current_parameters.set<Moose::MaterialDataType>("_material_data_type") =
4210  object_name = name + "_face";
4211  std::shared_ptr<MaterialBase> face_material =
4212  _factory.create<MaterialBase>(mat_name, object_name, current_parameters, tid);
4213 
4214  // neighbor material
4215  current_parameters.set<Moose::MaterialDataType>("_material_data_type") =
4217  current_parameters.set<bool>("_neighbor") = true;
4218  object_name = name + "_neighbor";
4219  std::shared_ptr<MaterialBase> neighbor_material =
4220  _factory.create<MaterialBase>(mat_name, object_name, current_parameters, tid);
4221 
4222  // Store the material objects
4223  _all_materials.addObjects(material, neighbor_material, face_material, tid);
4224 
4225  if (discrete)
4226  _discrete_materials.addObjects(material, neighbor_material, face_material, tid);
4227  else
4228  for (auto && warehouse : warehouses)
4229  warehouse->addObjects(material, neighbor_material, face_material, tid);
4230 
4231  // Names of all controllable parameters for this Material object
4232  const std::string & base = parameters.getBase();
4233  MooseObjectParameterName name(MooseObjectName(base, material->name()), "*");
4234  const auto param_names =
4236 
4237  // Connect parameters of the primary Material object to those on the face and neighbor
4238  // objects
4239  for (const auto & p_name : param_names)
4240  {
4241  MooseObjectParameterName primary_name(MooseObjectName(base, material->name()),
4242  p_name.parameter());
4243  MooseObjectParameterName face_name(MooseObjectName(base, face_material->name()),
4244  p_name.parameter());
4245  MooseObjectParameterName neighbor_name(MooseObjectName(base, neighbor_material->name()),
4246  p_name.parameter());
4248  primary_name, face_name, false);
4250  primary_name, neighbor_name, false);
4251  }
4252  }
4253  }
4254 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
void addControllableParameterConnection(const MooseObjectParameterName &primary, const MooseObjectParameterName &secondary, bool error_on_empty=true)
Method for linking control parameters of different names.
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
unsigned int n_threads()
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
InputParameterWarehouse & getInputParameterWarehouse()
Get the InputParameterWarehouse for MooseObjects.
Definition: MooseApp.C:2867
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
MaterialDataType
MaterialData types.
Definition: MooseTypes.h:740
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
bool isKokkosObject() const
Returns whether this InputParameters belongs to a Kokkos object Checks whether MooseBase::kokkos_obje...
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
const std::string & getBase() const
std::vector< MooseObjectParameterName > getControllableParameterNames(const MooseObjectParameterName &input) const
Return a vector of parameters names matching the supplied name.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
FunctorMaterials compute functor material properties.
virtual std::unique_ptr< Base > create()=0
void addObjects(std::shared_ptr< MaterialBase > block, std::shared_ptr< MaterialBase > neighbor, std::shared_ptr< MaterialBase > face, THREAD_ID tid=0)
A special method unique to this class for adding Block, Neighbor, and Face material objects...
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
MaterialWarehouse _discrete_materials
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
std::shared_ptr< DisplacedProblem > _displaced_problem
A class for storing an input parameter name.
A class for storing the names of MooseObject by tag and object name.
virtual void addObject(std::shared_ptr< T > object, THREAD_ID tid=0, bool recurse=true) override
Adds an object to the storage structure.
MaterialBases compute MaterialProperties.
Definition: MaterialBase.h:62
MaterialWarehouse _all_materials
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ addMatrixTag()

TagID SubProblem::addMatrixTag ( TagName  tag_name)
virtualinherited

Create a Tag.

Tags can be associated with Vectors and Matrices and allow objects (such as Kernels) to arbitrarily contribute values to any set of vectors/matrics

Note: If the tag is already present then this will simply return the TagID of that Tag

Parameters
tag_nameThe name of the tag to create, the TagID will get automatically generated

Reimplemented in DisplacedProblem.

Definition at line 312 of file SubProblem.C.

Referenced by DisplacedProblem::addMatrixTag(), FEProblemBase::createTagMatrices(), LinearSystem::LinearSystem(), and NonlinearSystemBase::NonlinearSystemBase().

313 {
314  auto tag_name_upper = MooseUtils::toUpper(tag_name);
315  auto existing_tag = _matrix_tag_name_to_tag_id.find(tag_name_upper);
316  if (existing_tag == _matrix_tag_name_to_tag_id.end())
317  {
318  auto tag_id = _matrix_tag_name_to_tag_id.size();
319 
320  _matrix_tag_name_to_tag_id[tag_name_upper] = tag_id;
321 
322  _matrix_tag_id_to_tag_name[tag_id] = tag_name_upper;
323  }
324 
325  return _matrix_tag_name_to_tag_id.at(tag_name_upper);
326 }
std::map< TagName, TagID > _matrix_tag_name_to_tag_id
The currently declared tags.
Definition: SubProblem.h:1056
std::string toUpper(std::string name)
Convert supplied string to upper case.
std::map< TagID, TagName > _matrix_tag_id_to_tag_name
Reverse map.
Definition: SubProblem.h:1059

◆ addMeshDivision()

void FEProblemBase::addMeshDivision ( const std::string &  type,
const std::string &  name,
InputParameters params 
)
virtualinherited

Add a MeshDivision.

Definition at line 2789 of file FEProblemBase.C.

2792 {
2793  parallel_object_only();
2794  parameters.set<FEProblemBase *>("_fe_problem_base") = this;
2795  parameters.set<SubProblem *>("_subproblem") = this;
2796  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); tid++)
2797  {
2798  std::shared_ptr<MeshDivision> func = _factory.create<MeshDivision>(type, name, parameters, tid);
2799  _mesh_divisions.addObject(func, tid);
2800  }
2801 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
unsigned int n_threads()
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
Base class for MeshDivision objects.
Definition: MeshDivision.h:35
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
virtual std::unique_ptr< Base > create()=0
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
MooseObjectWarehouse< MeshDivision > _mesh_divisions
Warehouse to store mesh divisions NOTE: this could probably be moved to the MooseMesh instead of the ...
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
virtual void addObject(std::shared_ptr< T > object, THREAD_ID tid=0, bool recurse=true) override
Adds an object to the storage structure.
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ addMFEMFESpaceFromMOOSEVariable()

InputParameters MFEMProblem::addMFEMFESpaceFromMOOSEVariable ( InputParameters moosevar_params)

Method used to get an mfem FEC depending on the variable family specified in the input file.

This method is used in addAuxVariable to help create the MFEM grid function that corresponds to a given MOOSE aux-variable.

Definition at line 658 of file MFEMProblem.C.

Referenced by addGridFunction().

659 {
660 
661  InputParameters fespace_params = _factory.getValidParams("MFEMGenericFESpace");
662  InputParameters variable_params = _factory.getValidParams("MFEMVariable");
663 
664  const auto family = Utility::string_to_enum<FEFamily>(parameters.get<MooseEnum>("family"));
665  auto order = static_cast<int>(parameters.get<MooseEnum>("order"));
666  const auto dim = mesh().dimension();
667 
668  std::string space;
669  int vdim = 1;
670 
671  switch (family)
672  {
673  case FEFamily::LAGRANGE:
674  space = "H1";
675  break;
676  case FEFamily::NEDELEC_ONE:
677  space = "ND";
678  break;
679  case FEFamily::RAVIART_THOMAS:
680  space = "RT";
681  --order;
682  break;
683  case FEFamily::MONOMIAL:
684  case FEFamily::L2_LAGRANGE:
685  space = "L2";
686  break;
687  case FEFamily::LAGRANGE_VEC:
688  space = "H1";
689  vdim = dim;
690  break;
691  case FEFamily::MONOMIAL_VEC:
692  case FEFamily::L2_LAGRANGE_VEC:
693  space = "L2";
694  vdim = dim;
695  break;
696  default:
697  mooseError("Unable to set MFEM FESpace for MOOSE variable");
698  break;
699  }
700 
701  // Create fespace name. If this already exists, we will reuse this for
702  // the mfem variable ("gridfunction"). If using AMR, this implies all
703  // variables sharing the fespace are affected.
704  const auto fec_name = space + "_" + std::to_string(dim) + "D_P" + std::to_string(order);
705  const auto fes_name = fec_name + "_X" + std::to_string(vdim);
706 
707  // Set all fespace parameters.
708  fespace_params.set<std::string>("fec_name") = fec_name;
709  fespace_params.set<int>("vdim") = vdim;
710 
711  if (!hasMFEMObject("MFEMFESpace", fes_name))
712  addFESpace("MFEMGenericFESpace", fes_name, fespace_params);
713 
714  variable_params.set<MFEMFESpaceName>("fespace") = fes_name;
715 
716  return variable_params;
717 }
unsigned int dimension() const override
Returns MeshBase::mesh_dimension(), (not MeshBase::spatial_dimension()!) of the underlying libMesh me...
Definition: MFEMMesh.h:75
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
virtual MFEMMesh & mesh() override
Overwritten mesh() method from base MooseMesh to retrieve the correct mesh type, in this case MFEMMes...
Definition: MFEMProblem.C:777
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
InputParameters getValidParams(const std::string &name) const
Get valid parameters for the object.
Definition: Factory.C:68
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
static constexpr std::size_t dim
This is the dimension of all vector and tensor datastructures used in MOOSE.
Definition: Moose.h:165
bool hasMFEMObject(const std::string &system, const std::string &name) const
Determine whether an MFEM object with the supplied system and name exists.
Definition: MFEMProblem.C:894
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:54
void addFESpace(const std::string &type, const std::string &name, InputParameters &parameters)
Add an MFEM FESpace to the problem.
Definition: MFEMProblem.C:317
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ addMFEMSolver()

void MFEMProblem::addMFEMSolver ( const std::string &  user_object_name,
const std::string &  name,
InputParameters parameters 
)
virtual

Method called in AddMFEMSolverAction which records a solver for later dependency-ordered construction.

Definition at line 148 of file MFEMProblem.C.

151 {
152  mooseAssert(!_mfem_solver_definitions.count(name), "Multiple MFEM solvers named '" + name + "'.");
153  _mfem_solver_definitions.emplace(name, MFEMSolverDefinition{solver_type, &parameters});
154 }
std::map< std::string, MFEMSolverDefinition > _mfem_solver_definitions
Solver definitions recorded by AddMFEMSolverAction before the dependency resolver constructs them...
Definition: MFEMProblem.h:410
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addMultiApp()

void FEProblemBase::addMultiApp ( const std::string &  multi_app_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Add a MultiApp to the problem.

Definition at line 5800 of file FEProblemBase.C.

5803 {
5804  parallel_object_only();
5805 
5806  parameters.set<MPI_Comm>("_mpi_comm") = _communicator.get();
5807 
5808  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
5809  {
5810  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
5811  parameters.set<SystemBase *>("_sys") = &_displaced_problem->auxSys();
5812  _reinit_displaced_elem = true;
5813  }
5814  else
5815  {
5816  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
5817  {
5818  // We allow MultiApps to request that they use_displaced_mesh,
5819  // but then be overridden when no displacements variables are
5820  // provided in the Mesh block. If that happened, update the value
5821  // of use_displaced_mesh appropriately for this MultiApp.
5822  if (parameters.have_parameter<bool>("use_displaced_mesh"))
5823  parameters.set<bool>("use_displaced_mesh") = false;
5824  }
5825 
5826  parameters.set<SubProblem *>("_subproblem") = this;
5827  parameters.set<SystemBase *>("_sys") = _aux.get();
5828  }
5829 
5830  std::shared_ptr<MultiApp> multi_app = _factory.create<MultiApp>(multi_app_name, name, parameters);
5831  logAdd("MultiApp", name, multi_app_name, parameters);
5832  multi_app->setupPositions();
5833 
5834  _multi_apps.addObject(multi_app);
5835 
5836  // Store TransientMultiApp objects in another container, this is needed for calling computeDT
5837  std::shared_ptr<TransientMultiApp> trans_multi_app =
5839  if (trans_multi_app)
5840  _transient_multi_apps.addObject(trans_multi_app);
5841 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
void addObject(std::shared_ptr< T > object, THREAD_ID tid=0, bool recurse=true) override
Adds an object to the storage structure.
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
MultiApp Implementation for Transient Apps.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
const Parallel::Communicator & _communicator
ExecuteMooseObjectWarehouse< TransientMultiApp > _transient_multi_apps
Storage for TransientMultiApps (only needed for calling &#39;computeDT&#39;)
Base class for a system (of equations)
Definition: SystemBase.h:85
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
virtual std::unique_ptr< Base > create()=0
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
std::shared_ptr< DisplacedProblem > _displaced_problem
A MultiApp represents one or more MOOSE applications that are running simultaneously.
Definition: MultiApp.h:112

◆ addNodalKernel()

void FEProblemBase::addNodalKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3186 of file FEProblemBase.C.

3189 {
3190  parallel_object_only();
3191 
3192  const auto nl_sys_num = determineSolverSystem(parameters.varName("variable", name), true).second;
3193  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3194  {
3195  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
3196  parameters.set<SystemBase *>("_sys") = &_displaced_problem->solverSys(nl_sys_num);
3197  _reinit_displaced_elem = true;
3198  }
3199  else
3200  {
3201  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
3202  {
3203  // We allow NodalKernels to request that they use_displaced_mesh,
3204  // but then be overridden when no displacements variables are
3205  // provided in the Mesh block. If that happened, update the value
3206  // of use_displaced_mesh appropriately for this NodalKernel.
3207  if (parameters.have_parameter<bool>("use_displaced_mesh"))
3208  parameters.set<bool>("use_displaced_mesh") = false;
3209  }
3210 
3211  parameters.set<SubProblem *>("_subproblem") = this;
3212  parameters.set<SystemBase *>("_sys") = _nl[nl_sys_num].get();
3213  }
3214  logAdd("NodalKernel", name, kernel_name, parameters);
3215  _nl[nl_sys_num]->addNodalKernel(kernel_name, name, parameters);
3216 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addNotZeroedVectorTag()

void SubProblem::addNotZeroedVectorTag ( const TagID  tag)
inherited

Adds a vector tag to the list of vectors that will not be zeroed when other tagged vectors are.

Parameters
tagthe TagID of the vector that will be manually managed

Definition at line 150 of file SubProblem.C.

Referenced by FEProblemBase::createTagVectors().

151 {
152  _not_zeroed_tagged_vectors.insert(tag);
153 }
std::unordered_set< TagID > _not_zeroed_tagged_vectors
the list of vector tags that will not be zeroed when all other tags are
Definition: SubProblem.h:1132

◆ addObject()

template<typename T >
std::vector< std::shared_ptr< T > > FEProblemBase::addObject ( const std::string &  type,
const std::string &  name,
InputParameters parameters,
const bool  threaded = true,
const std::string &  var_param_name = "variable" 
)
inherited

Method for creating and adding an object to the warehouse.

Template Parameters
TThe base object type (registered in the Factory)
Parameters
typeString type of the object (registered in the Factory)
nameName for the object to be created
parametersInputParameters for the object
threadedWhether or not to create n_threads copies of the object
var_param_nameThe name of the parameter on the object which holds the primary variable.
Returns
A vector of shared_ptrs to the added objects

Definition at line 3692 of file FEProblemBase.h.

3697 {
3698  parallel_object_only();
3699 
3700  logAdd(MooseUtils::prettyCppType<T>(), name, type, parameters);
3701  // Add the _subproblem and _sys parameters depending on use_displaced_mesh
3702  addObjectParamsHelper(parameters, name, var_param_name);
3703 
3704  const auto n_threads = threaded ? libMesh::n_threads() : 1;
3705  std::vector<std::shared_ptr<T>> objects(n_threads);
3706  for (THREAD_ID tid = 0; tid < n_threads; ++tid)
3707  {
3708  std::shared_ptr<T> obj = _factory.create<T>(type, name, parameters, tid);
3709  theWarehouse().add(obj);
3710  objects[tid] = std::move(obj);
3711  }
3712 
3713  return objects;
3714 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
unsigned int n_threads()
void add(std::shared_ptr< MooseObject > obj)
add adds a new object to the warehouse and stores attributes/metadata about it for running queries/fi...
Definition: TheWarehouse.C:116
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
std::shared_ptr< MooseObject > create(const std::string &obj_name, const std::string &name, const InputParameters &parameters, THREAD_ID tid=0, bool print_deprecated=true)
Definition: Factory.C:142
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
void addObjectParamsHelper(InputParameters &params, const std::string &object_name, const std::string &var_param_name="variable")
Helper for setting the "_subproblem" and "_sys" parameters in addObject() and in addUserObject().
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ addObjectParamsHelper()

void FEProblemBase::addObjectParamsHelper ( InputParameters params,
const std::string &  object_name,
const std::string &  var_param_name = "variable" 
)
protectedinherited

Helper for setting the "_subproblem" and "_sys" parameters in addObject() and in addUserObject().

This is needed due to header includes/forward declaration issues

Definition at line 4539 of file FEProblemBase.C.

Referenced by FEProblemBase::addFVInterpolationMethod(), FEProblemBase::addObject(), and FEProblemBase::addUserObject().

4542 {
4543  // Due to objects like SolutionUserObject which manipulate libmesh objects
4544  // and variables directly at the back end, we need a default option here
4545  // which is going to be the pointer to the first solver system within this
4546  // problem
4547  unsigned int sys_num = 0;
4548  if (parameters.isParamValid(var_param_name))
4549  {
4550  const auto variable_name = parameters.varName(var_param_name, object_name);
4551  if (this->hasVariable(variable_name) || this->hasScalarVariable(variable_name))
4552  sys_num = getSystem(variable_name).number();
4553  }
4554  if (parameters.isParamValid("solver_sys"))
4555  {
4556  const auto var_sys_num = sys_num;
4557  sys_num = getSystemBase(parameters.get<SolverSystemName>("solver_sys")).number();
4558  if (sys_num != var_sys_num && parameters.isParamValid(var_param_name))
4559  mooseError("We dont support setting 'variable' to a variable that is not set to the same "
4560  "system as the 'solver_sys' parameter");
4561  }
4562 
4563  if (_displaced_problem && parameters.have_parameter<bool>("use_displaced_mesh") &&
4564  parameters.get<bool>("use_displaced_mesh"))
4565  {
4566  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
4567  if (sys_num == _aux->number())
4568  parameters.set<SystemBase *>("_sys") = &_displaced_problem->systemBaseAuxiliary();
4569  else
4570  parameters.set<SystemBase *>("_sys") = &_displaced_problem->solverSys(sys_num);
4571  }
4572  else
4573  {
4574  // The object requested use_displaced_mesh, but it was overridden
4575  // due to there being no displacements variables in the [Mesh] block.
4576  // If that happened, update the value of use_displaced_mesh appropriately.
4577  if (!_displaced_problem && parameters.have_parameter<bool>("use_displaced_mesh") &&
4578  parameters.get<bool>("use_displaced_mesh"))
4579  parameters.set<bool>("use_displaced_mesh") = false;
4580 
4581  parameters.set<SubProblem *>("_subproblem") = this;
4582 
4583  if (sys_num == _aux->number())
4584  parameters.set<SystemBase *>("_sys") = _aux.get();
4585  else
4586  parameters.set<SystemBase *>("_sys") = _solver_systems[sys_num].get();
4587  }
4588 }
virtual bool hasVariable(const std::string &var_name) const override
Whether or not this problem has the variable.
virtual libMesh::System & getSystem(const std::string &var_name) override
Returns the equation system containing the variable provided.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
virtual bool hasScalarVariable(const std::string &var_name) const override
Returns a Boolean indicating whether any system contains a variable with the name provided...
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
Base class for a system (of equations)
Definition: SystemBase.h:85
unsigned int number() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
virtual const SystemBase & getSystemBase(const unsigned int sys_num) const
Get constant reference to a system in this problem.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.

◆ addOutput()

void FEProblemBase::addOutput ( const std::string &  object_type,
const std::string &  object_name,
InputParameters parameters 
)
inherited

Adds an Output object.

Definition at line 9467 of file FEProblemBase.C.

9470 {
9471  parallel_object_only();
9472 
9473  // Get a reference to the OutputWarehouse
9474  OutputWarehouse & output_warehouse = _app.getOutputWarehouse();
9475 
9476  // Reject the reserved names for objects not built by MOOSE
9477  if (!parameters.get<bool>("_built_by_moose") && output_warehouse.isReservedName(object_name))
9478  mooseError("The name '", object_name, "' is a reserved name for output objects");
9479 
9480  // Check that an object by the same name does not already exist; this must be done before the
9481  // object is created to avoid getting misleading errors from the Parser
9482  if (output_warehouse.hasOutput(object_name))
9483  mooseError("An output object named '", object_name, "' already exists");
9484 
9485  // Add a pointer to the FEProblemBase class
9486  parameters.addPrivateParam<FEProblemBase *>("_fe_problem_base", this);
9487 
9488  // --show-input should enable the display of the input file on the screen
9489  if (object_type == "Console" && _app.getParam<bool>("show_input") &&
9490  parameters.get<bool>("output_screen"))
9491  parameters.set<ExecFlagEnum>("execute_input_on") = EXEC_INITIAL;
9492 
9493  // Apply only user-set parameters from the common [Outputs] block so that
9494  // each output type's own defaults are not overridden by common defaults.
9495  const InputParameters * common = output_warehouse.getCommonParameters();
9496  if (common)
9498 
9499  // Set the correct value for the binary flag for XDA/XDR output
9500  if (object_type == "XDR")
9501  parameters.set<bool>("_binary") = true;
9502  else if (object_type == "XDA")
9503  parameters.set<bool>("_binary") = false;
9504 
9505  // Adjust the checkpoint suffix if auto recovery was enabled
9506  if (object_name == "auto_recovery_checkpoint")
9507  parameters.set<std::string>("suffix") = "auto_recovery";
9508 
9509  // Create the object and add it to the warehouse
9510  std::shared_ptr<Output> output = _factory.create<Output>(object_type, object_name, parameters);
9511  logAdd("Output", object_name, object_type, parameters);
9512  output_warehouse.addOutput(output);
9513 }
A MultiMooseEnum object to hold "execute_on" flags.
Definition: ExecFlagEnum.h:21
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
Definition: MooseBase.h:406
void addPrivateParam(const std::string &name, const T &value)
These method add a parameter to the InputParameters object which can be retrieved like any other para...
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
bool isReservedName(const std::string &name)
Test if the given name is reserved.
bool hasOutput(const std::string &name) const
Returns true if the output object exists.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
Based class for output objects.
Definition: Output.h:43
virtual std::unique_ptr< Base > create()=0
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
Class for storing and utilizing output objects.
const InputParameters * getCommonParameters() const
Get a reference to the common output parameters.
void addOutput(std::shared_ptr< Output > output)
Adds an existing output object to the warehouse.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
void applyCommonUserSetParameters(const InputParameters &common, const std::vector< std::string > &exclude={}, const bool allow_private=false)
Variant of applyParameters that only applies parameters explicitly set by the user in common (i...
const ExecFlagType EXEC_INITIAL
Definition: Moose.C:30

◆ addPiecewiseByBlockLambdaFunctor()

template<typename T , typename PolymorphicLambda >
const Moose::FunctorBase< T > & SubProblem::addPiecewiseByBlockLambdaFunctor ( const std::string &  name,
PolymorphicLambda  my_lammy,
const std::set< ExecFlagType > &  clearance_schedule,
const MooseMesh mesh,
const std::set< SubdomainID > &  block_ids,
const THREAD_ID  tid 
)
inherited

Add a functor that has block-wise lambda definitions, e.g.

the evaluations of the functor are based on a user-provided lambda expression.

Parameters
nameThe name of the functor to add
my_lammyThe lambda expression that will be called when the functor is evaluated
clearance_scheduleHow often to clear functor evaluations. The default value is always, which means that the functor will be re-evaluated every time it is called. If it is something other than always, than cached values may be returned
meshThe mesh on which this functor operates
block_idsThe blocks on which the lambda expression is defined
tidThe thread on which the functor we are adding will run
Returns
The added functor

Definition at line 1356 of file SubProblem.h.

Referenced by FunctorMaterial::addFunctorPropertyByBlocks().

1362 {
1363  auto & pbblf_functors = _pbblf_functors[tid];
1364 
1365  auto [it, first_time_added] =
1366  pbblf_functors.emplace(name,
1367  std::make_unique<PiecewiseByBlockLambdaFunctor<T>>(
1368  name, my_lammy, clearance_schedule, mesh, block_ids));
1369 
1370  auto * functor = dynamic_cast<PiecewiseByBlockLambdaFunctor<T> *>(it->second.get());
1371  if (!functor)
1372  {
1373  if (first_time_added)
1374  mooseError("This should be impossible. If this was the first time we added the functor, then "
1375  "the dynamic cast absolutely should have succeeded");
1376  else
1377  mooseError("Attempted to add a lambda functor with the name '",
1378  name,
1379  "' but another lambda functor of that name returns a different type");
1380  }
1381 
1382  if (first_time_added)
1383  addFunctor(name, *functor, tid);
1384  else
1385  // The functor already exists
1386  functor->setFunctor(mesh, block_ids, my_lammy);
1387 
1388  return *functor;
1389 }
virtual MooseMesh & mesh()=0
A material property that is evaluated on-the-fly via calls to various overloads of operator() ...
void addFunctor(const std::string &name, const Moose::FunctorBase< T > &functor, const THREAD_ID tid)
add a functor to the problem functor container
Definition: SubProblem.h:1393
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::vector< std::map< std::string, std::unique_ptr< Moose::FunctorAbstract > > > _pbblf_functors
Container to hold PiecewiseByBlockLambdaFunctors.
Definition: SubProblem.h:1162
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ addPostprocessor()

void MFEMProblem::addPostprocessor ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Override of ExternalProblem::addPostprocessor.

In addition to creating the postprocessor object, it will create a coefficient that will hold its value.

Reimplemented from FEProblemBase.

Definition at line 627 of file MFEMProblem.C.

630 {
631  if (parameters.getSystemAttributeName() == "MFEMExecutedObject")
632  {
633  checkUserObjectNameCollision(name, "Postprocessor");
634  addObject<MFEMExecutedObject>(type, name, parameters);
636  getCoefficients().declareScalar<mfem::FunctionCoefficient>(
637  name, [&val](const mfem::Vector &) -> mfem::real_t { return val; });
638  }
639  else
641 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
void checkUserObjectNameCollision(const std::string &name, const std::string &type) const
Check for name collision between different user objects.
virtual void addPostprocessor(const std::string &pp_name, const std::string &name, InputParameters &parameters)
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
mfem::Coefficient & declareScalar(const std::string &name, const std::string &existing_or_literal)
Declare an alias to an existing scalar coefficient or, if it does not exist, try interpreting the nam...
Real PostprocessorValue
various MOOSE typedefs
Definition: MooseTypes.h:230
Moose::MFEM::CoefficientManager & getCoefficients()
Method to get the PropertyManager object for storing material properties and converting them to MFEM ...
Definition: MFEMProblem.h:265
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
const PostprocessorValue & getPostprocessorValueByName(const PostprocessorName &name, std::size_t t_index=0) const
Get a read-only reference to the value associated with a Postprocessor that exists.
const std::string & getSystemAttributeName() const
Get the system attribute name if it was registered.

◆ addPredictor()

void FEProblemBase::addPredictor ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 7372 of file FEProblemBase.C.

Referenced by AB2PredictorCorrector::AB2PredictorCorrector().

7375 {
7376  parallel_object_only();
7377 
7379  mooseError("Vector bounds cannot be used with LinearSystems!");
7380 
7381  parameters.set<SubProblem *>("_subproblem") = this;
7382  std::shared_ptr<Predictor> predictor = _factory.create<Predictor>(type, name, parameters);
7383  logAdd("Predictor", name, type, parameters);
7384 
7385  for (auto & nl : _nl)
7386  nl->setPredictor(predictor);
7387 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
virtual std::size_t numNonlinearSystems() const override
Base class for predictors.
Definition: Predictor.h:28
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
virtual std::unique_ptr< Base > create()=0
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
virtual std::size_t numLinearSystems() const override

◆ addQuadratureFunction()

void MFEMProblem::addQuadratureFunction ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)

Add an MFEM QuadratureFunction-backed coefficient to the problem.

Definition at line 801 of file MFEMProblem.C.

804 {
805  // The object declares its coefficient with the CoefficientManager on construction.
806  addObject<MFEMObject>(type, name, parameters);
807 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93

◆ addRealComponentToBC()

void MFEMProblem::addRealComponentToBC ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)

Adds a real component BC to the parent MFEMComplexIntegratedBC.

Definition at line 505 of file MFEMProblem.C.

508 {
510  getMFEMObject<MFEMComplexIntegratedBC>("BoundaryCondition", name).getSharedPtr());
511  parameters.set<VariableName>("variable") = parent_ptr->getParam<VariableName>("variable");
512  parameters.set<std::vector<BoundaryName>>("boundary") =
513  parent_ptr->getParam<std::vector<BoundaryName>>("boundary");
515  addObject<MFEMBoundaryCondition>(kernel_name, name + "_real", parameters).front());
516  parent_ptr->setRealBC(bc_ptr);
517 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
std::shared_ptr< MooseObject > getSharedPtr()
Get another shared pointer to this object that has the same ownership group.
Definition: MooseObject.C:70
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addRealComponentToKernel()

void MFEMProblem::addRealComponentToKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)

Adds a real component kernel to the parent MFEMComplexKernel.

Definition at line 481 of file MFEMProblem.C.

484 {
485  auto parent_ptr = std::dynamic_pointer_cast<MFEMComplexKernel>(
486  getMFEMObject<MFEMComplexKernel>("Kernel", name).getSharedPtr());
487  parameters.set<VariableName>("variable") = parent_ptr->getParam<VariableName>("variable");
488  auto kernel_ptr = addObject<MFEMKernel>(kernel_name, name + "_real", parameters).front();
489  parent_ptr->setRealKernel(kernel_ptr);
490 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
std::shared_ptr< MooseObject > getSharedPtr()
Get another shared pointer to this object that has the same ownership group.
Definition: MooseObject.C:70
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addReporter()

void FEProblemBase::addReporter ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Add a Reporter object to the simulation.

Parameters
typeC++ object type to construct
nameA uniquely identifying object name
parametersComplete parameters for the object to be created.

For an example use, refer to AddReporterAction.C/h

Definition at line 4632 of file FEProblemBase.C.

Referenced by MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer().

4635 {
4636  checkUserObjectNameCollision(name, "Reporter");
4637 
4639 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
void checkUserObjectNameCollision(const std::string &name, const std::string &type) const
Check for name collision between different user objects.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
virtual std::vector< std::shared_ptr< UserObject > > addUserObject(const std::string &user_object_name, const std::string &name, InputParameters &parameters)

◆ addResidual()

void FEProblemBase::addResidual ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 1954 of file FEProblemBase.C.

Referenced by ComputeDiracThread::postElement().

1955 {
1956  _assembly[tid][_current_nl_sys->number()]->addResidual(Assembly::GlobalDataKey{},
1958 
1959  if (_displaced_problem)
1960  _displaced_problem->addResidual(tid);
1961 }
virtual const std::vector< VectorTag > & currentResidualVectorTags() const override
Return the residual vector tags we are currently computing.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addResidualLower()

void FEProblemBase::addResidualLower ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 1974 of file FEProblemBase.C.

Referenced by ComputeResidualThread::accumulateLower(), ComputeResidualAndJacobianThread::accumulateLower(), ComputeResidualThread::accumulateNeighborLower(), and ComputeResidualAndJacobianThread::accumulateNeighborLower().

1975 {
1976  _assembly[tid][_current_nl_sys->number()]->addResidualLower(Assembly::GlobalDataKey{},
1978 
1979  if (_displaced_problem)
1980  _displaced_problem->addResidualLower(tid);
1981 }
virtual const std::vector< VectorTag > & currentResidualVectorTags() const override
Return the residual vector tags we are currently computing.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addResidualNeighbor()

void FEProblemBase::addResidualNeighbor ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 1964 of file FEProblemBase.C.

Referenced by ComputeResidualThread::accumulateNeighbor(), ComputeResidualAndJacobianThread::accumulateNeighbor(), ComputeResidualThread::accumulateNeighborLower(), and ComputeResidualAndJacobianThread::accumulateNeighborLower().

1965 {
1966  _assembly[tid][_current_nl_sys->number()]->addResidualNeighbor(Assembly::GlobalDataKey{},
1968 
1969  if (_displaced_problem)
1970  _displaced_problem->addResidualNeighbor(tid);
1971 }
virtual const std::vector< VectorTag > & currentResidualVectorTags() const override
Return the residual vector tags we are currently computing.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addResidualScalar()

void FEProblemBase::addResidualScalar ( const THREAD_ID  tid = 0)
virtualinherited

Definition at line 1984 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeResidualInternal().

1985 {
1986  _assembly[tid][_current_nl_sys->number()]->addResidualScalar(Assembly::GlobalDataKey{},
1988 }
virtual const std::vector< VectorTag > & currentResidualVectorTags() const override
Return the residual vector tags we are currently computing.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ addSampler()

void FEProblemBase::addSampler ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

The following functions will enable MOOSE to have the capability to import Samplers.

Definition at line 2875 of file FEProblemBase.C.

2878 {
2879  const auto samplers = addObject<Sampler>(type, name, parameters);
2880  for (auto & sampler : samplers)
2881  sampler->init();
2882 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93

◆ addScalarKernel()

void FEProblemBase::addScalarKernel ( const std::string &  kernel_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 3219 of file FEProblemBase.C.

3222 {
3223  parallel_object_only();
3224 
3225  const auto nl_sys_num = determineSolverSystem(parameters.varName("variable", name), true).second;
3226  if (!isSolverSystemNonlinear(nl_sys_num))
3227  mooseError("You are trying to add a ScalarKernel to a linear variable/system, which is not "
3228  "supported at the moment!");
3229 
3230  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
3231  {
3232  parameters.set<SubProblem *>("_subproblem") = _displaced_problem.get();
3233  parameters.set<SystemBase *>("_sys") = &_displaced_problem->solverSys(nl_sys_num);
3234  }
3235  else
3236  {
3237  if (_displaced_problem == nullptr && parameters.get<bool>("use_displaced_mesh"))
3238  {
3239  // We allow ScalarKernels to request that they use_displaced_mesh,
3240  // but then be overridden when no displacements variables are
3241  // provided in the Mesh block. If that happened, update the value
3242  // of use_displaced_mesh appropriately for this ScalarKernel.
3243  if (parameters.have_parameter<bool>("use_displaced_mesh"))
3244  parameters.set<bool>("use_displaced_mesh") = false;
3245  }
3246 
3247  parameters.set<SubProblem *>("_subproblem") = this;
3248  parameters.set<SystemBase *>("_sys") = _nl[nl_sys_num].get();
3249  }
3250 
3251  logAdd("ScalarKernel", name, kernel_name, parameters);
3252  _nl[nl_sys_num]->addScalarKernel(kernel_name, name, parameters);
3253 }
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
Base class for a system (of equations)
Definition: SystemBase.h:85
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
std::string varName(const std::string &var_param_name, const std::string &moose_object_with_var_param_name) const
Determine the actual variable name from the given variable parameter name.
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addSubMesh()

void MFEMProblem::addSubMesh ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)

Add an MFEM SubMesh to the problem.

Definition at line 791 of file MFEMProblem.C.

794 {
795  auto & mfem_submesh = *addObject<MFEMSubMesh>(var_type, var_name, parameters).front();
796  // Register submesh.
797  getProblemData().submeshes.Register(var_name, mfem_submesh.getSubMesh());
798 }
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
Moose::MFEM::SubMeshes submeshes
void Register(const std::string &field_name, FieldArgs &&... args)
Construct new field with name field_name and register.

◆ addTimeIntegrator()

void FEProblemBase::addTimeIntegrator ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 7337 of file FEProblemBase.C.

Referenced by TransientBase::setupTimeIntegrator().

7340 {
7341  parallel_object_only();
7342 
7343  parameters.set<SubProblem *>("_subproblem") = this;
7344  logAdd("TimeIntegrator", name, type, parameters);
7345  _aux->addTimeIntegrator(type, name + ":aux", parameters);
7346  for (auto & sys : _solver_systems)
7347  sys->addTimeIntegrator(type, name + ":" + sys->name(), parameters);
7348  _has_time_integrator = true;
7349 
7350  // add vectors to store u_dot, u_dotdot, udot_old, u_dotdot_old and
7351  // solution vectors older than 2 time steps, if requested by the time
7352  // integrator
7353  _aux->addDotVectors();
7354  for (auto & nl : _nl)
7355  {
7356  nl->addDotVectors();
7357 
7358  auto tag_udot = nl->getTimeIntegrators()[0]->uDotFactorTag();
7359  if (!nl->hasVector(tag_udot))
7360  nl->associateVectorToTag(*nl->solutionUDot(), tag_udot);
7361  auto tag_udotdot = nl->getTimeIntegrators()[0]->uDotDotFactorTag();
7362  if (!nl->hasVector(tag_udotdot) && uDotDotRequested())
7363  nl->associateVectorToTag(*nl->solutionUDotDot(), tag_udotdot);
7364  }
7365 
7366  if (_displaced_problem)
7367  // Time integrator does not exist when displaced problem is created.
7368  _displaced_problem->addTimeIntegrator();
7369 }
virtual bool uDotDotRequested()
Get boolean flag to check whether solution second time derivative needs to be stored.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
bool _has_time_integrator
Indicates whether or not this executioner has a time integrator (during setup)
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ addTransfer()

void MFEMProblem::addTransfer ( const std::string &  transfer_name,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Add transfers between MultiApps and/or MFEM SubMeshes.

Reimplemented from FEProblemBase.

Definition at line 810 of file MFEMProblem.C.

813 {
814  if (parameters.getBase() == "MFEMSubMeshTransfer")
815  addObject<MFEMExecutedObject>(transfer_name, name, parameters);
816  else
818 }
virtual void addTransfer(const std::string &transfer_name, const std::string &name, InputParameters &parameters)
Add a Transfer to the problem.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
const std::string & getBase() const
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ addUserObject()

std::vector< std::shared_ptr< UserObject > > FEProblemBase::addUserObject ( const std::string &  user_object_name,
const std::string &  name,
InputParameters parameters 
)
virtualinherited

Definition at line 4642 of file FEProblemBase.C.

Referenced by FEProblemBase::addPostprocessor(), FEProblemBase::addReporter(), PhysicsBase::addUserObject(), and FEProblemBase::addVectorPostprocessor().

4645 {
4646  parallel_object_only();
4647 
4648  std::vector<std::shared_ptr<UserObject>> uos;
4649 
4650  // Add the _subproblem and _sys parameters depending on use_displaced_mesh
4652 
4653  for (const auto tid : make_range(libMesh::n_threads()))
4654  {
4655  // Create the UserObject
4656  std::shared_ptr<UserObject> user_object =
4657  _factory.create<UserObject>(user_object_name, name, parameters, tid);
4658  logAdd("UserObject", name, user_object_name, parameters);
4659  uos.push_back(user_object);
4660 
4661  if (tid != 0)
4662  user_object->setPrimaryThreadCopy(uos[0].get());
4663 
4664  theWarehouse().add(user_object);
4665 
4666  // Attempt to create all the possible UserObject types
4667  auto euo = std::dynamic_pointer_cast<ElementUserObject>(user_object);
4668  auto suo = std::dynamic_pointer_cast<SideUserObject>(user_object);
4669  auto isuo = std::dynamic_pointer_cast<InternalSideUserObject>(user_object);
4670  auto iuo = std::dynamic_pointer_cast<InterfaceUserObjectBase>(user_object);
4671  auto nuo = std::dynamic_pointer_cast<NodalUserObject>(user_object);
4672  auto duo = std::dynamic_pointer_cast<DomainUserObject>(user_object);
4673  auto guo = std::dynamic_pointer_cast<GeneralUserObject>(user_object);
4674  auto tguo = std::dynamic_pointer_cast<ThreadedGeneralUserObject>(user_object);
4675  auto muo = std::dynamic_pointer_cast<MortarUserObject>(user_object);
4676 
4677  // Account for displaced mesh use
4678  if (_displaced_problem && parameters.get<bool>("use_displaced_mesh"))
4679  {
4680  // Whether to re-init or not depends on the attributes of the base classes.
4681  // For example, InterfaceUOBase has "_current_side_elem" and "_neighbor_elem"
4682  // so it needs to reinit on displaced neighbors and faces
4683  // _reinit_displaced_elem -> _current_elem will be reinited
4684  // _reinit_displaced_face -> _current_elem, lowerD if any and _current_side_elem to be
4685  // reinited _reinit_displaced_neighbor -> _current_elem, lowerD if any and _current_neighbor
4686  // to be reinited Note that as soon as you use materials on the displaced mesh, all three get
4687  // turned on.
4688  if (euo || nuo || duo)
4689  _reinit_displaced_elem = true;
4690  if (suo || duo || isuo || iuo)
4691  _reinit_displaced_face = true;
4692  if (iuo || duo || isuo)
4694  }
4695 
4696  // These objects only require one thread
4697  if ((guo && !tguo) || muo)
4698  break;
4699  }
4700 
4701  // Add as a Functor if it is one. We usually need to add the user object from thread 0 as the
4702  // registered functor for all threads because when user objects are thread joined, generally only
4703  // the primary thread copy ends up with all the data
4704  for (const auto tid : make_range(libMesh::n_threads()))
4705  {
4706  const decltype(uos)::size_type uo_index = uos.front()->needThreadedCopy() ? tid : 0;
4707  if (const auto functor = dynamic_cast<Moose::FunctorBase<Real> *>(uos[uo_index].get()))
4708  {
4709  this->addFunctor(name, *functor, tid);
4710  if (_displaced_problem)
4711  _displaced_problem->addFunctor(name, *functor, tid);
4712  }
4713  }
4714 
4715  return uos;
4716 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
unsigned int n_threads()
Base class for implementing interface user objects.
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
void add(std::shared_ptr< MooseObject > obj)
add adds a new object to the warehouse and stores attributes/metadata about it for running queries/fi...
Definition: TheWarehouse.C:116
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
void addFunctor(const std::string &name, const Moose::FunctorBase< T > &functor, const THREAD_ID tid)
add a functor to the problem functor container
Definition: SubProblem.h:1393
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters &params) const
Output information about the object just added to the problem.
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
Base class for user objects executed one or more sidesets, which may be on the outer boundary of the ...
This user object allows related evaluations on elements, boundaries, internal sides, interfaces in one single place.
Base class for creating new nodally-based mortar user objects.
A user object that runs over all the nodes and does an aggregation step to compute a single value...
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
virtual std::unique_ptr< Base > create()=0
TheWarehouse & theWarehouse() const
Base class for user objects executed on all element sides internal to one or more blocks...
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
IntRange< T > make_range(T beg, T end)
void addObjectParamsHelper(InputParameters &params, const std::string &object_name, const std::string &var_param_name="variable")
Helper for setting the "_subproblem" and "_sys" parameters in addObject() and in addUserObject().
std::shared_ptr< DisplacedProblem > _displaced_problem
Base class for user-specific data.
Definition: UserObject.h:19
An instance of this object type has one copy per thread that runs on each thread. ...

◆ addVariable()

void MFEMProblem::addVariable ( const std::string &  var_type,
const std::string &  var_name,
InputParameters parameters 
)
overridevirtual

Override of ExternalProblem::addVariable.

Sets a MFEM grid function (and time derivative, for transient problems) to be used in the MFEM solve.

Reimplemented from FEProblemBase.

Reimplemented in MFEMEigenproblem.

Definition at line 372 of file MFEMProblem.C.

375 {
376  validateVariableNumericType(var_type, var_name);
377  addGridFunction(var_type, var_name, parameters);
378  // MOOSE variables store DoFs for the trial variable and its time derivatives up to second order;
379  // MFEM GridFunctions store data for only one set of DoFs each, so we must add additional
380  // GridFunctions for time derivatives.
381  if (isTransient())
382  {
383  const auto time_derivative_var_name =
384  getMFEMObject<MFEMVariable>("MooseVariableBase", var_name).getTimeDerivativeName();
386  time_derivative_var_name);
387  addGridFunction(var_type, time_derivative_var_name, parameters);
388  }
389 }
void addGridFunction(const std::string &var_type, const std::string &var_name, InputParameters &parameters)
Adds one MFEM GridFunction to be used in the MFEM solve.
Definition: MFEMProblem.C:392
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
void addTimeDerivativeAssociation(const std::string &var_name, const std::string &time_derivative_var_name)
void validateVariableNumericType(const std::string &var_type, const std::string &var_name) const
Verify that a primary variable&#39;s numeric type matches the problem&#39;s equation system.
Definition: MFEMProblem.C:358
virtual bool isTransient() const override
Moose::MFEM::TimeDerivativeMap time_derivative_map

◆ addVectorPostprocessor()

void MFEMProblem::addVectorPostprocessor ( const std::string &  type,
const std::string &  name,
InputParameters parameters 
)
overridevirtual

Add a vector postprocessor and register its vectors with the MFEM execution system.

Reimplemented from FEProblemBase.

Definition at line 644 of file MFEMProblem.C.

647 {
648  if (parameters.getSystemAttributeName() == "MFEMExecutedObject")
649  {
650  checkUserObjectNameCollision(name, "VectorPostprocessor");
651  addObject<MFEMExecutedObject>(type, name, parameters);
652  }
653  else
655 }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
void checkUserObjectNameCollision(const std::string &name, const std::string &type) const
Check for name collision between different user objects.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
virtual void addVectorPostprocessor(const std::string &pp_name, const std::string &name, InputParameters &parameters)
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
const std::string & getSystemAttributeName() const
Get the system attribute name if it was registered.

◆ addVectorTag()

TagID SubProblem::addVectorTag ( const TagName &  tag_name,
const Moose::VectorTagType  type = Moose::VECTOR_TAG_RESIDUAL 
)
virtualinherited

Create a Tag.

Tags can be associated with Vectors and Matrices and allow objects (such as Kernels) to arbitrarily contribute values to any set of vectors/matrics

Note: If the tag is already present then this will simply return the TagID of that Tag, but the type must be the same.

Parameters
tag_nameThe name of the tag to create, the TagID will get automatically generated
typeThe type of the tag

Reimplemented in DisplacedProblem.

Definition at line 93 of file SubProblem.C.

Referenced by DisplacedProblem::addVectorTag(), SecantSolve::allocateStorage(), SteffensenSolve::allocateStorage(), PicardSolve::allocateStorage(), FEProblemBase::createTagSolutions(), FEProblemBase::createTagVectors(), NonlinearSystemBase::getResidualNonTimeVector(), NonlinearSystemBase::getResidualTimeVector(), LinearSystem::LinearSystem(), SystemBase::needSolutionState(), and NonlinearSystemBase::NonlinearSystemBase().

95 {
97  mooseError("Vector tag type cannot be VECTOR_TAG_ANY");
98 
99  const auto tag_name_upper = MooseUtils::toUpper(tag_name);
100 
101  // First, see if the tag exists already
102  for (const auto & vector_tag : _vector_tags)
103  {
104  mooseAssert(_vector_tags[vector_tag._id] == vector_tag, "Vector tags index mismatch");
105  if (vector_tag._name == tag_name_upper)
106  {
107  if (vector_tag._type != type)
108  mooseError("While attempting to add vector tag with name '",
109  tag_name_upper,
110  "' and type ",
111  type,
112  ",\na tag with the same name but type ",
113  vector_tag._type,
114  " was found.\n\nA tag can only exist with one type.");
115 
116  return vector_tag._id;
117  }
118  }
119 
120  // Doesn't exist - create it
121  const TagID new_tag_id = _vector_tags.size();
122  const TagTypeID new_tag_type_id = _typed_vector_tags[type].size();
123  // Primary storage for all tags where the index in the vector == the tag ID
124  _vector_tags.emplace_back(new_tag_id, new_tag_type_id, tag_name_upper, type);
125  // Secondary storage for each type so that we can have quick access to all tags of a type
126  _typed_vector_tags[type].emplace_back(new_tag_id, new_tag_type_id, tag_name_upper, type);
127  // Name map storage for quick name access
128  _vector_tags_name_map.emplace(tag_name_upper, new_tag_id);
129 
130  // Make sure that _vector_tags, _typed_vector_tags, and _vector_tags_name_map are sane
132 
133  return new_tag_id;
134 }
unsigned int TagTypeID
Definition: MooseTypes.h:239
unsigned int TagID
Definition: MooseTypes.h:238
std::vector< VectorTag > _vector_tags
The declared vector tags.
Definition: SubProblem.h:1185
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
std::string toUpper(std::string name)
Convert supplied string to upper case.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::map< TagName, TagID > _vector_tags_name_map
Map of vector tag TagName to TagID.
Definition: SubProblem.h:1195
std::vector< std::vector< VectorTag > > _typed_vector_tags
The vector tags associated with each VectorTagType This is kept separate from _vector_tags for quick ...
Definition: SubProblem.h:1192
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ advanceMultiApps()

void FEProblemBase::advanceMultiApps ( ExecFlagType  type)
inlineinherited

Deprecated method; use finishMultiAppStep and/or incrementMultiAppTStep depending on your purpose.

Definition at line 1684 of file FEProblemBase.h.

1685  {
1686  mooseDeprecated("Deprecated method; use finishMultiAppStep and/or incrementMultiAppTStep "
1687  "depending on your purpose");
1689  }
void finishMultiAppStep(ExecFlagType type, bool recurse_through_multiapp_levels=false)
Finish the MultiApp time step (endStep, postStep) associated with the ExecFlagType.
void mooseDeprecated(Args &&... args) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93

◆ advanceState()

void FEProblemBase::advanceState ( )
virtualinherited

Advance all of the state holding vectors / datastructures so that we can move to the next timestep.

Reimplemented in DumpObjectsProblem.

Definition at line 7176 of file FEProblemBase.C.

Referenced by MFEMSteady::execute(), SteadyBase::execute(), Eigenvalue::execute(), TransientBase::incrementStepOrReject(), NonlinearEigen::init(), TransientMultiApp::setupApp(), ExplicitTVDRK2::solve(), ExplicitRK2::solve(), TransientMultiApp::solveStep(), NonlinearEigen::takeStep(), and InversePowerMethod::takeStep().

7177 {
7178  TIME_SECTION("advanceState", 5, "Advancing State");
7179 
7180  for (auto & sys : _solver_systems)
7181  sys->copyOldSolutions();
7182  _aux->copyOldSolutions();
7183 
7184  if (_displaced_problem)
7185  {
7186  for (const auto i : index_range(_solver_systems))
7187  _displaced_problem->solverSys(i).copyOldSolutions();
7188  _displaced_problem->auxSys().copyOldSolutions();
7189  }
7190 
7192 
7194 
7197 
7200 
7203 
7204 #ifdef MOOSE_KOKKOS_ENABLED
7207 
7210 
7213 #endif
7214 }
void shift()
Shift the material properties in time.
MaterialPropertyStorage & _bnd_material_props
void shift()
Shift current, old, and older material property data storages.
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
void copyValuesBack()
Copies current chain control data values into old values.
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
ReporterData _reporter_data
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void copyValuesBack()
At the end of a timestep this method is called to copy the values back in time in preparation for the...
Definition: ReporterData.C:17
Moose::Kokkos::MaterialPropertyStorage & _kokkos_material_props
ChainControlDataSystem & getChainControlDataSystem()
Gets the system that manages the ChainControls.
Definition: MooseApp.h:891
std::shared_ptr< DisplacedProblem > _displaced_problem
MaterialPropertyStorage & _neighbor_material_props
Moose::Kokkos::MaterialPropertyStorage & _kokkos_bnd_material_props
MaterialPropertyStorage & _material_props
Moose::Kokkos::MaterialPropertyStorage & _kokkos_neighbor_material_props
auto index_range(const T &sizable)

◆ allowInvalidSolution()

bool FEProblemBase::allowInvalidSolution ( ) const
inlineinherited

Whether to accept / allow an invalid solution.

Definition at line 2406 of file FEProblemBase.h.

Referenced by FEProblemBase::acceptInvalidSolution().

2406 { return _allow_invalid_solution; }
const bool _allow_invalid_solution

◆ allowOutput() [1/2]

void FEProblemBase::allowOutput ( bool  state)
inherited

Ability to enable/disable all output calls.

This is needed by Multiapps and applications to disable output for cases when executioners call other executions and when Multiapps are sub cycling.

Definition at line 7283 of file FEProblemBase.C.

Referenced by TransientMultiApp::resetApp(), and TransientMultiApp::solveStep().

7284 {
7286 }
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
void allowOutput(bool state)
Ability to enable/disable output calls This is private, users should utilize FEProblemBase::allowOutp...
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409

◆ allowOutput() [2/2]

template<typename T >
void FEProblemBase::allowOutput ( bool  state)
inherited

Definition at line 3643 of file FEProblemBase.h.

3644 {
3645  _app.getOutputWarehouse().allowOutput<T>(state);
3646 }
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
void allowOutput(bool state)
Ability to enable/disable output calls This is private, users should utilize FEProblemBase::allowOutp...
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409

◆ areCoupled()

bool FEProblemBase::areCoupled ( const unsigned int  ivar,
const unsigned int  jvar,
const unsigned int  nl_sys_num 
) const
inherited

Definition at line 6708 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintJacobians().

6711 {
6712  return (*_cm[nl_sys])(ivar, jvar);
6713 }
std::vector< std::unique_ptr< libMesh::CouplingMatrix > > _cm
Coupling matrix for variables.

◆ assembly() [1/2]

Assembly & FEProblemBase::assembly ( const THREAD_ID  tid,
const unsigned int  sys_num 
)
inlineoverridevirtualinherited

Implements SubProblem.

Definition at line 3791 of file FEProblemBase.h.

Referenced by ArrayNodalBC::computeJacobian(), VectorNodalBC::computeJacobian(), NodalBC::computeJacobian(), NonlinearSystemBase::computeJacobianInternal(), NonlinearSystemBase::computeNodalBCsJacobian(), NonlinearSystemBase::computeNodalBCsResidualAndJacobian(), ArrayNodalBC::computeOffDiagJacobian(), VectorNodalBC::computeOffDiagJacobian(), NodalBC::computeOffDiagJacobian(), NonlinearSystemBase::constraintJacobians(), FEProblemBase::initialSetup(), ComputeBoundaryInitialConditionThread::onNode(), MaxQpsThread::operator()(), and FEProblemBase::reinitScalars().

3792 {
3793  mooseAssert(tid < _assembly.size(), "Assembly objects not initialized");
3794  mooseAssert(sys_num < _assembly[tid].size(),
3795  "System number larger than the assembly container size");
3796  return *_assembly[tid][sys_num];
3797 }
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.

◆ assembly() [2/2]

const Assembly & FEProblemBase::assembly ( const THREAD_ID  tid,
const unsigned int  sys_num 
) const
inlineoverridevirtualinherited

Implements SubProblem.

Definition at line 3800 of file FEProblemBase.h.

3801 {
3802  mooseAssert(tid < _assembly.size(), "Assembly objects not initialized");
3803  mooseAssert(sys_num < _assembly[tid].size(),
3804  "System number larger than the assembly container size");
3805  return *_assembly[tid][sys_num];
3806 }
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.

◆ automaticScaling() [1/4]

bool SubProblem::automaticScaling ( ) const
inherited

Automatic scaling getter.

Returns
A boolean representing whether we are performing automatic scaling

Definition at line 1163 of file SubProblem.C.

Referenced by FEProblemBase::automaticScaling(), and DisplacedProblem::DisplacedProblem().

1164 {
1165  // Currently going to assume that we are applying or not applying automatic scaling consistently
1166  // across nonlinear systems
1168 }
virtual const SystemBase & systemBaseNonlinear(const unsigned int sys_num) const =0
Return the nonlinear system object as a base class reference given the system number.
bool automaticScaling() const
Getter for whether we are performing automatic scaling.
Definition: SystemBase.h:123

◆ automaticScaling() [2/4]

void SubProblem::automaticScaling
inherited

Automatic scaling setter.

Parameters
automatic_scalingA boolean representing whether we are performing automatic scaling

Definition at line 1156 of file SubProblem.C.

1157 {
1158  for (const auto nl_sys_num : make_range(numNonlinearSystems()))
1159  systemBaseNonlinear(nl_sys_num).automaticScaling(automatic_scaling);
1160 }
virtual std::size_t numNonlinearSystems() const override
bool automaticScaling() const
Getter for whether we are performing automatic scaling.
Definition: SystemBase.h:123
virtual const SystemBase & systemBaseNonlinear(const unsigned int sys_num) const override
Return the nonlinear system object as a base class reference given the system number.
IntRange< T > make_range(T beg, T end)

◆ automaticScaling() [3/4]

bool SubProblem::automaticScaling
inherited

Automatic scaling getter.

Returns
A boolean representing whether we are performing automatic scaling

Definition at line 1163 of file SubProblem.C.

1164 {
1165  // Currently going to assume that we are applying or not applying automatic scaling consistently
1166  // across nonlinear systems
1168 }
bool automaticScaling() const
Getter for whether we are performing automatic scaling.
Definition: SystemBase.h:123
virtual const SystemBase & systemBaseNonlinear(const unsigned int sys_num) const override
Return the nonlinear system object as a base class reference given the system number.

◆ automaticScaling() [4/4]

void FEProblemBase::automaticScaling ( bool  automatic_scaling)
overridevirtualinherited

Automatic scaling setter.

Parameters
automatic_scalingA boolean representing whether we are performing automatic scaling

Reimplemented from SubProblem.

Definition at line 9646 of file FEProblemBase.C.

Referenced by DisplacedProblem::DisplacedProblem(), and FEProblemSolve::FEProblemSolve().

9647 {
9648  if (_displaced_problem)
9649  _displaced_problem->automaticScaling(automatic_scaling);
9650 
9651  SubProblem::automaticScaling(automatic_scaling);
9652 }
bool automaticScaling() const
Automatic scaling getter.
Definition: SubProblem.C:1163
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ backupMultiApps()

void FEProblemBase::backupMultiApps ( ExecFlagType  type)
inherited

Backup the MultiApps associated with the ExecFlagType.

Definition at line 6073 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup(), and FixedPointSolve::solve().

6074 {
6075  const auto & multi_apps = _multi_apps[type].getActiveObjects();
6076 
6077  if (multi_apps.size())
6078  {
6079  TIME_SECTION("backupMultiApps", 5, "Backing Up MultiApp");
6080 
6081  if (_verbose_multiapps)
6082  _console << COLOR_CYAN << "\nBacking Up MultiApps on " << type.name() << COLOR_DEFAULT
6083  << std::endl;
6084 
6085  for (const auto & multi_app : multi_apps)
6086  multi_app->backup();
6087 
6089 
6090  if (_verbose_multiapps)
6091  _console << COLOR_CYAN << "Finished Backing Up MultiApps on " << type.name() << "\n"
6092  << COLOR_DEFAULT << std::endl;
6093  }
6094 }
bool _parallel_barrier_messaging
Whether or not information about how many transfers have completed is printed.
const Parallel::Communicator & _communicator
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
void parallelBarrierNotify(const Parallel::Communicator &comm, bool messaging)
Definition: MooseUtils.C:327
bool _verbose_multiapps
Whether or not to be verbose with multiapps.

◆ bumpAllQRuleOrder()

void FEProblemBase::bumpAllQRuleOrder ( libMesh::Order  order,
SubdomainID  block 
)
inherited

Definition at line 6565 of file FEProblemBase.C.

6566 {
6567  for (unsigned int tid = 0; tid < libMesh::n_threads(); ++tid)
6568  for (const auto i : index_range(_nl))
6569  _assembly[tid][i]->bumpAllQRuleOrder(order, block);
6570 
6571  if (_displaced_problem)
6572  _displaced_problem->bumpAllQRuleOrder(order, block);
6573 
6574  updateMaxQps();
6575 }
unsigned int n_threads()
void bumpAllQRuleOrder(libMesh::Order order, SubdomainID block)
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
auto index_range(const T &sizable)

◆ bumpVolumeQRuleOrder()

void FEProblemBase::bumpVolumeQRuleOrder ( libMesh::Order  order,
SubdomainID  block 
)
inherited

Increases the element/volume quadrature order for the specified mesh block if and only if the current volume quadrature order is lower.

This can only cause the quadrature level to increase. If volume_order is lower than or equal to the current volume/elem quadrature rule order, then nothing is done (i.e. this function is idempotent).

Definition at line 6552 of file FEProblemBase.C.

6553 {
6554  for (unsigned int tid = 0; tid < libMesh::n_threads(); ++tid)
6555  for (const auto i : index_range(_nl))
6556  _assembly[tid][i]->bumpVolumeQRuleOrder(order, block);
6557 
6558  if (_displaced_problem)
6559  _displaced_problem->bumpVolumeQRuleOrder(order, block);
6560 
6561  updateMaxQps();
6562 }
unsigned int n_threads()
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
void bumpVolumeQRuleOrder(libMesh::Order order, SubdomainID block)
Increases the element/volume quadrature order for the specified mesh block if and only if the current...
std::shared_ptr< DisplacedProblem > _displaced_problem
auto index_range(const T &sizable)

◆ cacheJacobian()

void FEProblemBase::cacheJacobian ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 2120 of file FEProblemBase.C.

Referenced by ComputeResidualAndJacobianThread::accumulate(), NonlinearSystemBase::constraintJacobians(), and ComputeJacobianThread::postElement().

2121 {
2123  if (_displaced_problem)
2124  _displaced_problem->cacheJacobian(tid);
2125 }
std::shared_ptr< DisplacedProblem > _displaced_problem
virtual void cacheJacobian(const THREAD_ID tid)
Definition: SubProblem.C:1317

◆ cacheJacobianNeighbor()

void FEProblemBase::cacheJacobianNeighbor ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 2128 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintJacobians().

2129 {
2131  if (_displaced_problem)
2132  _displaced_problem->cacheJacobianNeighbor(tid);
2133 }
virtual void cacheJacobianNeighbor(const THREAD_ID tid)
Definition: SubProblem.C:1325
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ cacheResidual()

void FEProblemBase::cacheResidual ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 1991 of file FEProblemBase.C.

Referenced by ComputeResidualThread::accumulate(), ComputeResidualAndJacobianThread::accumulate(), and NonlinearSystemBase::constraintResiduals().

1992 {
1994  if (_displaced_problem)
1995  _displaced_problem->cacheResidual(tid);
1996 }
virtual void cacheResidual(const THREAD_ID tid)
Definition: SubProblem.C:1296
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ cacheResidualNeighbor()

void FEProblemBase::cacheResidualNeighbor ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 1999 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintResiduals().

2000 {
2002  if (_displaced_problem)
2003  _displaced_problem->cacheResidualNeighbor(tid);
2004 }
std::shared_ptr< DisplacedProblem > _displaced_problem
virtual void cacheResidualNeighbor(const THREAD_ID tid)
Definition: SubProblem.C:1303

◆ callMooseError() [1/2]

void MooseBase::callMooseError ( std::string  msg,
const bool  with_prefix,
const hit::Node *  node = nullptr,
const bool  show_trace = true 
) const
inherited

External method for calling moose error with added object context.

Parameters
msgThe message
with_prefixIf true, add the prefix from messagePrefix(), which is the object information (type, name, etc)
nodeOptional hit node to add file path context as a prefix
show_traceWhether or not to show a stack trace, defaults to true

Definition at line 105 of file MooseBase.C.

Referenced by InputParameters::callMooseError(), MooseBase::mooseDocumentedError(), MooseBase::mooseError(), and MooseBase::mooseErrorNonPrefixed().

109 {
110  callMooseError(&_app, _pars, msg, with_prefix, node, show_trace);
111 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
External method for calling moose error with added object context.
Definition: MooseBase.C:105

◆ callMooseError() [2/2]

void MooseBase::callMooseError ( MooseApp *const  app,
const InputParameters params,
std::string  msg,
const bool  with_prefix,
const hit::Node *  node,
const bool  show_trace = true 
)
staticinherited

External method for calling moose error with added object context.

Needed so that objects without the MooseBase context (InputParameters) can call errors with context

Parameters
appThe app pointer (if available); adds multiapp context and clears the console
paramsThe parameters, needed to obtain object information
msgThe message
with_prefixIf true, add the prefix from messagePrefix(), which is the object information (type, name, etc)
nodeOptional hit node to add file path context as a prefix
show_traceWhether or not to show a stack trace, defaults to true

Definition at line 114 of file MooseBase.C.

120 {
121  if (!node)
122  node = MooseBase::getHitNode(params);
123 
124  std::string multiapp_prefix = "";
125  if (app)
126  {
127  if (!app->isUltimateMaster())
128  multiapp_prefix = app->name();
130  }
131 
132  if (with_prefix)
133  // False here because the hit context will get processed by the node
134  msg = messagePrefix(params, false) + msg;
135 
136  moose::internal::mooseErrorRaw(msg, multiapp_prefix, node, show_trace);
137 }
bool isUltimateMaster() const
Whether or not this app is the ultimate master app.
Definition: MooseApp.h:866
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
void mooseErrorRaw(std::string msg, const std::string &prefix="", const hit::Node *node=nullptr, const bool show_trace=true)
Main callback for emitting a moose error.
Definition: MooseError.C:53
void mooseConsole()
Send current output buffer to Console output objects.
const hit::Node * getHitNode() const
Definition: MooseBase.h:136
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:256

◆ checkBlockMatProps()

void SubProblem::checkBlockMatProps ( )
virtualinherited

Checks block material properties integrity.

See also
FEProblemBase::checkProblemIntegrity

Definition at line 624 of file SubProblem.C.

Referenced by FEProblemBase::checkProblemIntegrity().

625 {
626  // Variable for storing all available blocks/boundaries from the mesh
627  std::set<SubdomainID> all_ids(mesh().meshSubdomains());
628 
629  std::stringstream errors;
630 
631  // Loop through the properties to check
632  for (const auto & check_it : _map_block_material_props_check)
633  {
634  // The current id for the property being checked (BoundaryID || BlockID)
635  SubdomainID check_id = check_it.first;
636 
637  std::set<SubdomainID> check_ids = {check_id};
638 
639  // Loop through all the block/boundary ids
640  for (const auto & id : check_ids)
641  {
642  // Loop through all the stored properties
643  for (const auto & prop_it : check_it.second)
644  {
645  // Produce an error if the material property is not defined on the current block/boundary
646  // and any block/boundary
647  // and not is not a zero material property.
648  if (_map_block_material_props[id].count(prop_it.second) == 0 &&
649  _zero_block_material_props[id].count(prop_it.second) == 0)
650  {
651  std::string check_name = restrictionSubdomainCheckName(id);
652  if (check_name.empty())
653  check_name = std::to_string(id);
654  errors << "Material property '" << prop_it.second << "', requested by '" << prop_it.first
655  << "' is not defined on block " << check_name << "\n";
656  }
657  }
658  }
659  }
660 
661  if (!errors.str().empty())
662  mooseError(errors.str());
663 }
virtual MooseMesh & mesh()=0
std::string restrictionSubdomainCheckName(SubdomainID check_id)
Helper functions for checking MaterialProperties.
Definition: SubProblem.C:773
std::map< SubdomainID, std::set< MaterialPropertyName > > _zero_block_material_props
Set of properties returned as zero properties.
Definition: SubProblem.h:1073
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::map< SubdomainID, std::multimap< std::string, std::string > > _map_block_material_props_check
Data structures of the requested material properties.
Definition: SubProblem.h:1085
std::map< SubdomainID, std::set< std::string > > _map_block_material_props
Map of material properties (block_id -> list of properties)
Definition: SubProblem.h:1067

◆ checkBoundaryMatProps()

void SubProblem::checkBoundaryMatProps ( )
virtualinherited

Checks boundary material properties integrity.

See also
FEProblemBase::checkProblemIntegrity

Definition at line 666 of file SubProblem.C.

Referenced by FEProblemBase::checkProblemIntegrity().

667 {
668  // Variable for storing the value for ANY_BOUNDARY_ID
670 
671  // Variable for storing all available blocks/boundaries from the mesh
672  std::set<BoundaryID> all_ids(mesh().getBoundaryIDs());
673 
674  std::stringstream errors;
675 
676  // Loop through the properties to check
677  for (const auto & check_it : _map_boundary_material_props_check)
678  {
679  // The current id for the property being checked (BoundaryID || BlockID)
680  BoundaryID check_id = check_it.first;
681 
682  // In the case when the material being checked has an ID is set to ANY, then loop through all
683  // the possible ids and verify that the material property is defined.
684  std::set<BoundaryID> check_ids{check_id};
685  if (check_id == any_id)
686  check_ids = all_ids;
687 
688  // Loop through all the block/boundary ids
689  for (const auto & id : check_ids)
690  {
691  // Loop through all the stored properties
692  for (const auto & prop_it : check_it.second)
693  {
694  // Produce an error if the material property is not defined on the current block/boundary
695  // and any block/boundary
696  // and not is not a zero material property.
697  if (_map_boundary_material_props[id].count(prop_it.second) == 0 &&
698  _map_boundary_material_props[any_id].count(prop_it.second) == 0 &&
699  _zero_boundary_material_props[id].count(prop_it.second) == 0 &&
700  _zero_boundary_material_props[any_id].count(prop_it.second) == 0)
701  {
702  std::string check_name = restrictionBoundaryCheckName(id);
703  if (check_name.empty())
704  check_name = std::to_string(id);
705  errors << "Material property '" << prop_it.second << "', requested by '" << prop_it.first
706  << "' is not defined on boundary " << check_name << "\n";
707  }
708  }
709  }
710  }
711 
712  if (!errors.str().empty())
713  mooseError(errors.str());
714 }
virtual MooseMesh & mesh()=0
std::map< BoundaryID, std::multimap< std::string, std::string > > _map_boundary_material_props_check
Definition: SubProblem.h:1086
std::string restrictionBoundaryCheckName(BoundaryID check_id)
Definition: SubProblem.C:784
std::map< BoundaryID, std::set< MaterialPropertyName > > _zero_boundary_material_props
Definition: SubProblem.h:1074
std::map< BoundaryID, std::set< std::string > > _map_boundary_material_props
Map for boundary material properties (boundary_id -> list of properties)
Definition: SubProblem.h:1070
boundary_id_type BoundaryID
std::vector< BoundaryID > getBoundaryIDs(const libMesh::MeshBase &mesh, const std::vector< BoundaryName > &boundary_name, bool generate_unknown, const std::set< BoundaryID > &mesh_boundary_ids)
Gets the boundary IDs with their names.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
const BoundaryID ANY_BOUNDARY_ID
Definition: MooseTypes.C:21

◆ checkCoordinateSystems()

void FEProblemBase::checkCoordinateSystems ( )
protectedinherited

Verify that there are no element type/coordinate type conflicts.

Definition at line 9245 of file FEProblemBase.C.

Referenced by FEProblemBase::checkProblemIntegrity().

9246 {
9248 }
MooseMesh & _mesh
void checkCoordinateSystems()
Performs a sanity check for every element in the mesh.
Definition: MooseMesh.C:4427

◆ checkDependMaterialsHelper()

void FEProblemBase::checkDependMaterialsHelper ( const std::map< SubdomainID, std::vector< std::shared_ptr< MaterialBase >>> &  materials_map)
protectedinherited

Helper method for checking Material object dependency.

See also
checkProblemIntegrity

These two sets are used to make sure that all dependent props on a block are actually supplied

Definition at line 9124 of file FEProblemBase.C.

Referenced by FEProblemBase::checkProblemIntegrity().

9126 {
9127  for (const auto & it : materials_map)
9128  {
9130  std::set<std::string> block_depend_props, block_supplied_props;
9131 
9132  for (const auto & mat1 : it.second)
9133  {
9134  auto & alldeps = mat1->getMatPropDependencies(); // includes requested stateful props
9135  for (auto & dep : alldeps)
9136  block_depend_props.insert(_material_prop_registry.getName(dep));
9137 
9138  // See if any of the active materials supply this property
9139  for (const auto & mat2 : it.second)
9140  {
9141  const std::set<std::string> & supplied_props = mat2->MaterialBase::getSuppliedItems();
9142  block_supplied_props.insert(supplied_props.begin(), supplied_props.end());
9143  }
9144  }
9145 
9146  // Add zero material properties specific to this block and unrestricted
9147  block_supplied_props.insert(_zero_block_material_props[it.first].begin(),
9148  _zero_block_material_props[it.first].end());
9149 
9150  // Error check to make sure all properties consumed by materials are supplied on this block
9151  std::set<std::string> difference;
9152  std::set_difference(block_depend_props.begin(),
9153  block_depend_props.end(),
9154  block_supplied_props.begin(),
9155  block_supplied_props.end(),
9156  std::inserter(difference, difference.end()));
9157 
9158  if (!difference.empty())
9159  {
9160  std::ostringstream oss;
9161  oss << "One or more Material Properties were not supplied on block ";
9162  const std::string & subdomain_name = _mesh.getSubdomainName(it.first);
9163  if (subdomain_name.length() > 0)
9164  oss << subdomain_name << " (" << it.first << ")";
9165  else
9166  oss << it.first;
9167  oss << ":\n";
9168  for (const auto & name : difference)
9169  oss << name << "\n";
9170  mooseError(oss.str());
9171  }
9172  }
9173 
9174  // This loop checks that materials are not supplied by multiple Material objects
9175  for (const auto & it : materials_map)
9176  {
9177  const auto & materials = it.second;
9178  std::set<std::string> inner_supplied, outer_supplied;
9179 
9180  for (const auto & outer_mat : materials)
9181  {
9182  // Storage for properties for this material (outer) and all other materials (inner)
9183  outer_supplied = outer_mat->getSuppliedItems();
9184  inner_supplied.clear();
9185 
9186  // Property to material map for error reporting
9187  std::map<std::string, std::set<std::string>> prop_to_mat;
9188  for (const auto & name : outer_supplied)
9189  prop_to_mat[name].insert(outer_mat->name());
9190 
9191  for (const auto & inner_mat : materials)
9192  {
9193  if (outer_mat == inner_mat)
9194  continue;
9195 
9196  // Check whether these materials are an AD pair
9197  auto outer_mat_type = outer_mat->type();
9198  auto inner_mat_type = inner_mat->type();
9199  removeSubstring(outer_mat_type, "<RESIDUAL>");
9200  removeSubstring(outer_mat_type, "<JACOBIAN>");
9201  removeSubstring(inner_mat_type, "<RESIDUAL>");
9202  removeSubstring(inner_mat_type, "<JACOBIAN>");
9203  if (outer_mat_type == inner_mat_type && outer_mat_type != outer_mat->type() &&
9204  inner_mat_type != inner_mat->type())
9205  continue;
9206 
9207  inner_supplied.insert(inner_mat->getSuppliedItems().begin(),
9208  inner_mat->getSuppliedItems().end());
9209 
9210  for (const auto & inner_supplied_name : inner_supplied)
9211  prop_to_mat[inner_supplied_name].insert(inner_mat->name());
9212  }
9213 
9214  // Test that a property isn't supplied on multiple blocks
9215  std::set<std::string> intersection;
9216  std::set_intersection(outer_supplied.begin(),
9217  outer_supplied.end(),
9218  inner_supplied.begin(),
9219  inner_supplied.end(),
9220  std::inserter(intersection, intersection.end()));
9221 
9222  if (!intersection.empty())
9223  {
9224  std::ostringstream oss;
9225  oss << "The following material properties are declared on block " << it.first
9226  << " by multiple materials:\n";
9227  oss << ConsoleUtils::indent(2) << std::setw(30) << std::left << "Material Property"
9228  << "Material Objects\n";
9229  for (const auto & outer_name : intersection)
9230  {
9231  oss << ConsoleUtils::indent(2) << std::setw(30) << std::left << outer_name;
9232  for (const auto & inner_name : prop_to_mat[outer_name])
9233  oss << inner_name << " ";
9234  oss << '\n';
9235  }
9236 
9237  mooseError(oss.str());
9238  break;
9239  }
9240  }
9241  }
9242 }
std::string indent(unsigned int spaces)
Create empty string for indenting.
Definition: ConsoleUtils.C:41
MaterialPropertyRegistry _material_prop_registry
const std::string & getSubdomainName(SubdomainID subdomain_id) const
Return the name of a block given an id.
Definition: MooseMesh.C:1750
void removeSubstring(std::string &main, const std::string &sub)
Definition: MooseUtils.C:1203
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MooseMesh & _mesh
std::map< SubdomainID, std::set< MaterialPropertyName > > _zero_block_material_props
Set of properties returned as zero properties.
Definition: SubProblem.h:1073
const std::string & getName(const unsigned int id) const
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
for(PetscInt i=0;i< nvars;++i)

◆ checkDisplacementOrders()

void FEProblemBase::checkDisplacementOrders ( )
protectedinherited

Verify that SECOND order mesh uses SECOND order displacements.

Definition at line 9048 of file FEProblemBase.C.

Referenced by FEProblemBase::checkProblemIntegrity().

9049 {
9050  if (_displaced_problem)
9051  {
9052  bool mesh_has_second_order_elements = false;
9053  for (const auto & elem : as_range(_displaced_mesh->activeLocalElementsBegin(),
9055  {
9056  if (elem->default_order() == SECOND)
9057  {
9058  mesh_has_second_order_elements = true;
9059  break;
9060  }
9061  }
9062 
9063  // We checked our local elements, so take the max over all processors.
9064  _displaced_mesh->comm().max(mesh_has_second_order_elements);
9065 
9066  // If the Mesh has second order elements, make sure the
9067  // displacement variables are second-order.
9068  if (mesh_has_second_order_elements)
9069  {
9070  const std::vector<std::string> & displacement_variables =
9071  _displaced_problem->getDisplacementVarNames();
9072 
9073  for (const auto & var_name : displacement_variables)
9074  {
9075  MooseVariableFEBase & mv =
9076  _displaced_problem->getVariable(/*tid=*/0,
9077  var_name,
9080  if (mv.order() != SECOND)
9081  mooseError("Error: mesh has SECOND order elements, so all displacement variables must be "
9082  "SECOND order.");
9083  }
9084  }
9085  }
9086 }
const Parallel::Communicator & comm() const
This class provides an interface for common operations on field variables of both FE and FV types wit...
SECOND
SimpleRange< IndexType > as_range(const std::pair< IndexType, IndexType > &p)
MeshBase::element_iterator activeLocalElementsBegin()
Calls active_local_nodes_begin/end() on the underlying libMesh mesh object.
Definition: MooseMesh.C:3151
libMesh::Order order() const
Get the order of this variable Note: Order enum can be implicitly converted to unsigned int...
void max(const T &r, T &o, Request &req) const
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
const MeshBase::element_iterator activeLocalElementsEnd()
Definition: MooseMesh.C:3157
MooseMesh * _displaced_mesh

◆ checkDuplicatePostprocessorVariableNames()

void FEProblemBase::checkDuplicatePostprocessorVariableNames ( )
inherited

Definition at line 1582 of file FEProblemBase.C.

Referenced by FEProblemBase::checkProblemIntegrity().

1583 {
1584  for (const auto & pp : _reporter_data.getPostprocessorNames())
1585  if (hasScalarVariable(pp))
1586  mooseError("Postprocessor \"" + pp +
1587  "\" has the same name as a scalar variable in the system.");
1588 }
virtual bool hasScalarVariable(const std::string &var_name) const override
Returns a Boolean indicating whether any system contains a variable with the name provided...
ReporterData _reporter_data
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::set< std::string > getPostprocessorNames() const
Return a list of all postprocessor names.
Definition: ReporterData.C:71

◆ checkExceptionAndStopSolve()

void FEProblemBase::checkExceptionAndStopSolve ( bool  print_message = true)
virtualinherited

Check to see if an exception has occurred on any processor and, if possible, force the solve to fail, which will result in the time step being cut.

Notes:

  • The exception have be registered by calling setException() prior to calling this.
  • This is collective on MPI, and must be called simultaneously by all processors!
  • If called when the solve can be interruped, it will do so and also throw a MooseException, which must be handled.
  • If called at a stage in the execution when the solve cannot be interupted (i.e., there is no solve active), it will generate an error and terminate the application.
  • DO NOT CALL THIS IN A THREADED REGION! This is meant to be called just after a threaded section.
Parameters
print_messagewhether to print a message with exception information

Definition at line 6996 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeJacobianInternal(), FEProblemBase::handleException(), and DisplacedProblem::updateMesh().

6997 {
6999  return;
7000 
7001  TIME_SECTION("checkExceptionAndStopSolve", 5);
7002 
7003  // See if any processor had an exception. If it did, get back the
7004  // processor that the exception occurred on.
7005  unsigned int processor_id;
7006 
7008 
7009  if (_has_exception)
7010  {
7012 
7015  {
7016  // Print the message
7017  if (_communicator.rank() == 0 && print_message)
7018  {
7019  _console << "\n" << _exception_message << "\n";
7020  if (isTransient())
7021  _console
7022  << "To recover, the solution will fail and then be re-attempted with a reduced time "
7023  "step.\n"
7024  << std::endl;
7025  }
7026 
7027  // Stop the solve -- this entails setting
7028  // SNESSetFunctionDomainError() or directly inserting NaNs in the
7029  // residual vector to let PETSc >= 3.6 return DIVERGED_NANORINF.
7030  if (_current_nl_sys)
7032 
7033  if (_current_linear_sys)
7035 
7036  // and close Aux system (we MUST do this here; see #11525)
7037  _aux->solution().close();
7038 
7039  // We've handled this exception, so we no longer have one.
7040  _has_exception = false;
7041 
7042  // Force the next non-linear convergence check to fail (and all further residual evaluation
7043  // to be skipped).
7045 
7046  // Repropagate the exception, so it can be caught at a higher level, typically
7047  // this is NonlinearSystem::computeResidual().
7049  }
7050  else
7051  mooseError("The following parallel-communicated exception was detected during " +
7052  Moose::stringify(_current_execute_on_flag) + " evaluation:\n" +
7054  "\nBecause this did not occur during residual evaluation, there"
7055  " is no way to handle this, so the solution is aborting.\n");
7056  }
7057 }
virtual void stopSolve(const ExecFlagType &exec_flag, const std::set< TagID > &vector_tags_to_close) override
Quit the current solve as soon as possible.
Definition: LinearSystem.C:335
bool _skip_exception_check
If or not skip &#39;exception and stop solve&#39;.
ExecFlagType _current_execute_on_flag
Current execute_on flag.
processor_id_type rank() const
bool _has_exception
Whether or not an exception has occurred.
const Parallel::Communicator & _communicator
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
LinearSystem * _current_linear_sys
The current linear system that we are solving.
void maxloc(T &r, unsigned int &max_id) const
const ExecFlagType EXEC_LINEAR
Definition: Moose.C:31
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
std::string _exception_message
The error message to go with an exception.
void broadcast(T &data, const unsigned int root_id=0, const bool identical_sizes=false) const
const ExecFlagType EXEC_POSTCHECK
Definition: Moose.C:35
const ExecFlagType EXEC_NONLINEAR
Definition: Moose.C:33
Provides a way for users to bail out of the current solve.
virtual void stopSolve(const ExecFlagType &exec_flag, const std::set< TagID > &vector_tags_to_close)=0
Quit the current solve as soon as possible.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::set< TagID > _fe_vector_tags
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
virtual bool isTransient() const override
bool _fail_next_system_convergence_check
processor_id_type processor_id() const

◆ checkingUOAuxState()

bool FEProblemBase::checkingUOAuxState ( ) const
inlineinherited

Return a flag to indicate whether we are executing user objects and auxliary kernels for state check Note: This function can return true only when hasUOAuxStateCheck() returns true, i.e.

the check has been activated by users through Problem/check_uo_aux_state input parameter.

Definition at line 228 of file FEProblemBase.h.

Referenced by MemoryUsage::execute(), VectorMemoryUsage::execute(), PerfGraphData::finalize(), MemoryUsage::finalize(), and VectorMemoryUsage::finalize().

228 { return _checking_uo_aux_state; }
bool _checking_uo_aux_state
Flag used to indicate whether we are doing the uo/aux state check in execute.

◆ checkNonlocalCoupling()

void FEProblemBase::checkNonlocalCoupling ( )
inherited
Returns
Flag indicating nonlocal coupling exists or not.

Definition at line 1721 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup().

1722 {
1723  TIME_SECTION("checkNonlocalCoupling", 5, "Checking Nonlocal Coupling");
1724 
1725  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); tid++)
1726  for (auto & nl : _nl)
1727  {
1728  const auto & all_kernels = nl->getKernelWarehouse();
1729  const auto & kernels = all_kernels.getObjects(tid);
1730  for (const auto & kernel : kernels)
1731  {
1732  std::shared_ptr<NonlocalKernel> nonlocal_kernel =
1734  if (nonlocal_kernel)
1735  {
1738  _nonlocal_kernels.addObject(kernel, tid);
1739  }
1740  }
1741  const MooseObjectWarehouse<IntegratedBCBase> & all_integrated_bcs =
1742  nl->getIntegratedBCWarehouse();
1743  const auto & integrated_bcs = all_integrated_bcs.getObjects(tid);
1744  for (const auto & integrated_bc : integrated_bcs)
1745  {
1746  std::shared_ptr<NonlocalIntegratedBC> nonlocal_integrated_bc =
1748  if (nonlocal_integrated_bc)
1749  {
1752  _nonlocal_integrated_bcs.addObject(integrated_bc, tid);
1753  }
1754  }
1755  }
1756 }
unsigned int n_threads()
NonlocalIntegratedBC is used for solving integral terms in integro-differential equations.
bool _requires_nonlocal_coupling
nonlocal coupling requirement flag
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
bool _calculate_jacobian_in_uo
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::vector< std::shared_ptr< T > > & getObjects(THREAD_ID tid=0) const
Retrieve complete vector to the all/block/boundary restricted objects for a given thread...
NonlocalKernel is used for solving integral terms in integro-differential equations.
virtual void addObject(std::shared_ptr< T > object, THREAD_ID tid=0, bool recurse=true) override
Adds an object to the storage structure.
unsigned int THREAD_ID
Definition: MooseTypes.h:237
MooseObjectWarehouse< IntegratedBCBase > _nonlocal_integrated_bcs
nonlocal integrated_bcs
MooseObjectWarehouse< KernelBase > _nonlocal_kernels
nonlocal kernels

◆ checkNonlocalCouplingRequirement()

bool FEProblemBase::checkNonlocalCouplingRequirement ( ) const
overridevirtualinherited
Returns
whether there will be nonlocal coupling at any point in the simulation, e.g. whether there are any active or inactive nonlocal kernels or boundary conditions

Implements SubProblem.

Definition at line 10076 of file FEProblemBase.C.

Referenced by DisplacedProblem::checkNonlocalCouplingRequirement(), ComputeJacobianThread::compute(), ComputeFullJacobianThread::computeOnBoundary(), and ComputeFullJacobianThread::computeOnElement().

10077 {
10079 }
bool _requires_nonlocal_coupling
nonlocal coupling requirement flag

◆ checkProblemIntegrity()

void FEProblemBase::checkProblemIntegrity ( )
virtualinherited

Method called to perform a series of sanity checks before a simulation is run.

This method doesn't return when errors are found, instead it generally calls mooseError() directly.

If a material is specified for any block in the simulation, then all blocks must have a material specified.

unsigned int is necessary to print SubdomainIDs in the statement below

vector is necessary to get the subdomain names

Reimplemented in EigenProblem.

Definition at line 8876 of file FEProblemBase.C.

Referenced by EigenProblem::checkProblemIntegrity().

8877 {
8878  TIME_SECTION("checkProblemIntegrity", 5);
8879 
8880  // Subdomains specified by the "Problem/block" parameter
8881  const auto & subdomain_names = getParam<std::vector<SubdomainName>>("block");
8882  auto mesh_subdomains_vec = MooseMeshUtils::getSubdomainIDs(_mesh, subdomain_names);
8883  std::set<SubdomainID> mesh_subdomains(mesh_subdomains_vec.begin(), mesh_subdomains_vec.end());
8884 
8885  // Check kernel coverage of subdomains (blocks) in the mesh
8888  {
8889  std::set<SubdomainID> blocks;
8892  blocks = mesh_subdomains;
8894  {
8895  blocks = mesh_subdomains;
8896  for (const auto & subdomain_name : _kernel_coverage_blocks)
8897  {
8898  const auto id = _mesh.getSubdomainID(subdomain_name);
8899  if (id == Moose::INVALID_BLOCK_ID)
8900  paramError("kernel_coverage_block_list",
8901  "Subdomain \"",
8902  subdomain_name,
8903  "\" not found in mesh.");
8904  blocks.erase(id);
8905  }
8906  }
8908  for (const auto & subdomain_name : _kernel_coverage_blocks)
8909  {
8910  const auto id = _mesh.getSubdomainID(subdomain_name);
8911  if (id == Moose::INVALID_BLOCK_ID)
8912  paramError("kernel_coverage_block_list",
8913  "Subdomain \"",
8914  subdomain_name,
8915  "\" not found in mesh.");
8916  blocks.insert(id);
8917  }
8918  if (!blocks.empty())
8919  for (auto & nl : _nl)
8920  nl->checkKernelCoverage(blocks);
8921  }
8922 
8923  // Check materials
8924  {
8925 #ifdef LIBMESH_ENABLE_AMR
8926  if ((_adaptivity.isOn() || _num_grid_steps) &&
8929  {
8930  _console << "Using EXPERIMENTAL Stateful Material Property projection with Adaptivity!\n"
8931  << std::flush;
8932  }
8933 #endif
8934 
8935  std::set<SubdomainID> local_mesh_subs(mesh_subdomains);
8936 
8939  {
8944  bool check_material_coverage = false;
8945  std::set<SubdomainID> ids = _all_materials.getActiveBlocks();
8946  for (const auto & id : ids)
8947  {
8948  local_mesh_subs.erase(id);
8949  check_material_coverage = true;
8950  }
8951 
8952  // did the user limit the subdomains to be checked?
8954  {
8955  for (const auto & subdomain_name : _material_coverage_blocks)
8956  {
8957  const auto id = _mesh.getSubdomainID(subdomain_name);
8958  if (id == Moose::INVALID_BLOCK_ID)
8959  paramError("material_coverage_block_list",
8960  "Subdomain \"" + subdomain_name + "\" not found in mesh.");
8961  local_mesh_subs.erase(id);
8962  }
8963  }
8965  {
8966  std::set<SubdomainID> blocks(local_mesh_subs);
8967  for (const auto & subdomain_name : _material_coverage_blocks)
8968  {
8969  const auto id = _mesh.getSubdomainID(subdomain_name);
8970  if (id == Moose::INVALID_BLOCK_ID)
8971  paramError("material_coverage_block_list",
8972  "Subdomain \"" + subdomain_name + "\" not found in mesh.");
8973  blocks.erase(id);
8974  }
8975  for (const auto id : blocks)
8976  local_mesh_subs.erase(id);
8977  }
8978 
8979  // also exclude mortar spaces from the material check
8980  auto && mortar_subdomain_ids = _mortar_data->getMortarSubdomainIDs();
8981  for (auto subdomain_id : mortar_subdomain_ids)
8982  local_mesh_subs.erase(subdomain_id);
8983 
8984  // Check Material Coverage
8985  if (check_material_coverage && !local_mesh_subs.empty())
8986  {
8987  std::stringstream extra_subdomain_ids;
8989  std::copy(local_mesh_subs.begin(),
8990  local_mesh_subs.end(),
8991  std::ostream_iterator<unsigned int>(extra_subdomain_ids, " "));
8993  std::vector<SubdomainID> local_mesh_subs_vec(local_mesh_subs.begin(),
8994  local_mesh_subs.end());
8995 
8996  mooseError("The following blocks from your input mesh do not contain an active material: " +
8997  extra_subdomain_ids.str() +
8998  "(names: " + Moose::stringify(_mesh.getSubdomainNames(local_mesh_subs_vec)) +
8999  ")\nWhen ANY mesh block contains a Material object, "
9000  "all blocks must contain a Material object.\n");
9001  }
9002  }
9003 
9004  // Check material properties on blocks and boundaries
9007 
9008  // Check that material properties exist when requested by other properties on a given block
9009  const auto & materials = _all_materials.getActiveObjects();
9010  for (const auto & material : materials)
9011  material->checkStatefulSanity();
9012 
9013  // auto mats_to_check = _materials.getActiveBlockObjects();
9014  // const auto & discrete_materials = _discrete_materials.getActiveBlockObjects();
9015  // for (const auto & map_it : discrete_materials)
9016  // for (const auto & container_element : map_it.second)
9017  // mats_to_check[map_it.first].push_back(container_element);
9020  }
9021 
9022  checkUserObjects();
9023 
9024  // Verify that we don't have any Element type/Coordinate Type conflicts
9026 
9027  // Coordinate transforms are only intended for use with MultiApps at this time. If you are not
9028  // using multiapps but still require these, contact a moose developer
9030  !hasMultiApps())
9031  mooseError("Coordinate transformation parameters, listed below, are only to be used in the "
9032  "context of application to application field transfers at this time. The mesh is "
9033  "not modified by these parameters within an application.\n"
9034  "You should likely use a 'TransformGenerator' in the [Mesh] block to achieve the "
9035  "desired mesh modification.\n\n",
9037 
9038  // If using displacements, verify that the order of the displacement
9039  // variables matches the order of the elements in the displaced
9040  // mesh.
9042 
9043  // Check for postprocessor names with same name as a scalar variable
9045 }
bool isUltimateMaster() const
Whether or not this app is the ultimate master app.
Definition: MooseApp.h:866
MaterialPropertyStorage & _bnd_material_props
void checkDependMaterialsHelper(const std::map< SubdomainID, std::vector< std::shared_ptr< MaterialBase >>> &materials_map)
Helper method for checking Material object dependency.
static InputParameters validParams()
Describes the parameters this object can take to setup transformations.
void paramError(const std::string &param, Args... args) const
Emits an error prefixed with the file and line number of the given param (from the input file) along ...
Definition: MooseBase.h:457
const std::map< SubdomainID, std::vector< std::shared_ptr< T > > > & getActiveBlockObjects(THREAD_ID tid=0) const
char ** blocks
std::vector< SubdomainName > _kernel_coverage_blocks
std::vector< SubdomainName > _material_coverage_blocks
unsigned int _num_grid_steps
Number of steps in a grid sequence.
std::vector< subdomain_id_type > getSubdomainIDs(const libMesh::MeshBase &mesh, const std::vector< SubdomainName > &subdomain_name)
Get the associated subdomainIDs for the subdomain names that are passed in.
bool isOn()
Is adaptivity on?
Definition: Adaptivity.h:193
const bool _skip_nl_system_check
const SubdomainID INVALID_BLOCK_ID
Definition: MooseTypes.C:20
virtual void checkBoundaryMatProps()
Checks boundary material properties integrity.
Definition: SubProblem.C:666
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
const bool & _solve
Whether or not to actually solve the nonlinear system.
std::set< SubdomainID > getActiveBlocks(THREAD_ID tid=0) const
Return a set of active SubdomainsIDs.
bool hasScalingOrRotationTransformation() const
Returns true if the app has scaling and/or rotation transformation.
void checkUserObjects()
void checkDisplacementOrders()
Verify that SECOND order mesh uses SECOND order displacements.
MooseMesh & _mesh
virtual void checkBlockMatProps()
Checks block material properties integrity.
Definition: SubProblem.C:624
Adaptivity _adaptivity
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
std::vector< SubdomainName > getSubdomainNames(const std::vector< SubdomainID > &subdomain_ids) const
Get the associated subdomainNames for the subdomain ids that are passed in.
Definition: MooseMesh.C:1756
MooseAppCoordTransform & coordTransform()
Definition: MooseMesh.h:2064
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data
void checkDuplicatePostprocessorVariableNames()
const bool _material_dependency_check
Determines whether a check to verify material dependencies on every subdomain.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
CoverageCheckMode _material_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active material...
MaterialPropertyStorage & _neighbor_material_props
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
bool hasMultiApps() const
Returns whether or not the current simulation has any multiapps.
CoverageCheckMode _kernel_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active kernel...
MaterialPropertyStorage & _material_props
MaterialWarehouse _all_materials
SubdomainID getSubdomainID(const SubdomainName &subdomain_name) const
Get the associated subdomain ID for the subdomain name.
Definition: MooseMesh.C:1718
void checkCoordinateSystems()
Verify that there are no element type/coordinate type conflicts.

◆ checkResidualForNans()

virtual bool FEProblemBase::checkResidualForNans ( ) const
inlineoverridevirtualinherited

Whether to check residual for NaN/Inf values.

Implements SubProblem.

Definition at line 231 of file FEProblemBase.h.

Referenced by DisplacedProblem::checkResidualForNans().

231 { return _check_residual_for_nans; }
bool _check_residual_for_nans
Whether to check the residual for NaN or Inf values.

◆ checkUserObjectJacobianRequirement()

void FEProblemBase::checkUserObjectJacobianRequirement ( THREAD_ID  tid)
inherited

Definition at line 1759 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup().

1760 {
1761  std::set<const MooseVariableFEBase *> uo_jacobian_moose_vars;
1762  {
1763  std::vector<ShapeElementUserObject *> objs;
1764  theWarehouse()
1765  .query()
1767  .condition<AttribThread>(tid)
1768  .queryInto(objs);
1769 
1770  for (const auto & uo : objs)
1771  {
1772  _calculate_jacobian_in_uo = uo->computeJacobianFlag();
1773  const auto & mv_deps = uo->jacobianMooseVariables();
1774  uo_jacobian_moose_vars.insert(mv_deps.begin(), mv_deps.end());
1775  }
1776  }
1777  {
1778  std::vector<ShapeSideUserObject *> objs;
1779  theWarehouse()
1780  .query()
1782  .condition<AttribThread>(tid)
1783  .queryInto(objs);
1784  for (const auto & uo : objs)
1785  {
1786  _calculate_jacobian_in_uo = uo->computeJacobianFlag();
1787  const auto & mv_deps = uo->jacobianMooseVariables();
1788  uo_jacobian_moose_vars.insert(mv_deps.begin(), mv_deps.end());
1789  }
1790  }
1791 
1792  _uo_jacobian_moose_vars[tid].assign(uo_jacobian_moose_vars.begin(), uo_jacobian_moose_vars.end());
1793  std::sort(
1794  _uo_jacobian_moose_vars[tid].begin(), _uo_jacobian_moose_vars[tid].end(), sortMooseVariables);
1795 }
bool _calculate_jacobian_in_uo
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
std::vector< std::vector< const MooseVariableFEBase * > > _uo_jacobian_moose_vars
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ checkUserObjectNameCollision()

void FEProblemBase::checkUserObjectNameCollision ( const std::string &  name,
const std::string &  type 
) const
inherited

Check for name collision between different user objects.

Parameters
nameThe object name being added
typeThe object type being added

Definition at line 4591 of file FEProblemBase.C.

Referenced by addPostprocessor(), FEProblemBase::addPostprocessor(), FEProblemBase::addReporter(), addVectorPostprocessor(), and FEProblemBase::addVectorPostprocessor().

4593 {
4594  if (hasUserObject(name))
4595  mooseError("A ",
4597  " already exists. You may not add a ",
4598  type,
4599  " by the same name.");
4600 
4601 #ifdef MOOSE_KOKKOS_ENABLED
4603  mooseError("A ",
4604  getKokkosUserObject<UserObjectBase>(name).typeAndName(),
4605  " already exists. You may not add a ",
4606  type,
4607  " by the same name.");
4608 #endif
4609 }
bool hasKokkosUserObject(const std::string &name) const
Check if there if a Kokkos user object of given name.
bool hasUserObject(const std::string &name) const
Check if there if a user object of given name.
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::string typeAndName() const
Get the class&#39;s combined type and name; useful in error handling.
Definition: MooseBase.C:57
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
const UserObject & getUserObjectBase(const std::string &name, const THREAD_ID tid=0) const
Get the user object by its name.

◆ checkUserObjects()

void FEProblemBase::checkUserObjects ( )
protectedinherited

Definition at line 9089 of file FEProblemBase.C.

Referenced by FEProblemBase::checkProblemIntegrity().

9090 {
9091  // Check user_objects block coverage
9092  std::set<SubdomainID> mesh_subdomains = _mesh.meshSubdomains();
9093  std::set<SubdomainID> user_objects_blocks;
9094 
9095  // gather names of all user_objects that were defined in the input file
9096  // and the blocks that they are defined on
9097  std::set<std::string> names;
9098 
9099  std::vector<UserObjectBase *> objects;
9101 
9102  for (const auto & obj : objects)
9103  names.insert(obj->name());
9104 
9105  // See if all referenced blocks are covered
9106  std::set<SubdomainID> difference;
9107  std::set_difference(user_objects_blocks.begin(),
9108  user_objects_blocks.end(),
9109  mesh_subdomains.begin(),
9110  mesh_subdomains.end(),
9111  std::inserter(difference, difference.end()));
9112 
9113  if (!difference.empty())
9114  {
9115  std::ostringstream oss;
9116  oss << "One or more UserObjects is referencing a nonexistent block:\n";
9117  for (const auto & id : difference)
9118  oss << id << "\n";
9119  mooseError(oss.str());
9120  }
9121 }
TheWarehouse & theWarehouse() const
MooseMesh & _mesh
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285
const std::set< SubdomainID > & meshSubdomains() const
Returns a read-only reference to the set of subdomains currently present in the Mesh.
Definition: MooseMesh.C:3271

◆ clearActiveElementalMooseVariables()

void FEProblemBase::clearActiveElementalMooseVariables ( const THREAD_ID  tid)
overridevirtualinherited

Clear the active elemental MooseVariableFEBase.

If there are no active variables then they will all be reinited. Call this after finishing the computation that was using a restricted set of MooseVariableFEBases

Parameters
tidThe thread id

Reimplemented from SubProblem.

Definition at line 6394 of file FEProblemBase.C.

Referenced by ComputeMaterialsObjectThread::post(), ComputeMarkerThread::post(), ComputeDiracThread::post(), ComputeIndicatorThread::post(), and ComputeUserObjectsThread::post().

6395 {
6397 
6398  if (_displaced_problem)
6399  _displaced_problem->clearActiveElementalMooseVariables(tid);
6400 }
virtual void clearActiveElementalMooseVariables(const THREAD_ID tid)
Clear the active elemental MooseVariableFieldBase.
Definition: SubProblem.C:467
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ clearActiveFEVariableCoupleableMatrixTags()

void FEProblemBase::clearActiveFEVariableCoupleableMatrixTags ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 6403 of file FEProblemBase.C.

6404 {
6406 
6407  if (_displaced_problem)
6408  _displaced_problem->clearActiveFEVariableCoupleableMatrixTags(tid);
6409 }
virtual void clearActiveFEVariableCoupleableMatrixTags(const THREAD_ID tid)
Definition: SubProblem.C:385
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ clearActiveFEVariableCoupleableVectorTags()

void FEProblemBase::clearActiveFEVariableCoupleableVectorTags ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 6412 of file FEProblemBase.C.

6413 {
6415 
6416  if (_displaced_problem)
6417  _displaced_problem->clearActiveFEVariableCoupleableVectorTags(tid);
6418 }
virtual void clearActiveFEVariableCoupleableVectorTags(const THREAD_ID tid)
Definition: SubProblem.C:379
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ clearActiveMaterialProperties()

void FEProblemBase::clearActiveMaterialProperties ( const THREAD_ID  tid)
inherited

Clear the active material properties.

Should be called at the end of every computing thread

Parameters
tidThe thread id

Definition at line 6460 of file FEProblemBase.C.

Referenced by NodalPatchRecovery::compute(), ComputeDiracThread::post(), ComputeIndicatorThread::post(), ComputeUserObjectsThread::post(), ComputeMarkerThread::subdomainChanged(), and ComputeIndicatorThread::subdomainChanged().

6461 {
6463 }
std::vector< unsigned char > _has_active_material_properties
Whether there are active material properties on each thread.

◆ clearActiveScalarVariableCoupleableMatrixTags()

void FEProblemBase::clearActiveScalarVariableCoupleableMatrixTags ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 6421 of file FEProblemBase.C.

Referenced by AuxiliarySystem::clearScalarVariableCoupleableTags().

6422 {
6424 
6425  if (_displaced_problem)
6426  _displaced_problem->clearActiveScalarVariableCoupleableMatrixTags(tid);
6427 }
virtual void clearActiveScalarVariableCoupleableMatrixTags(const THREAD_ID tid)
Definition: SubProblem.C:426
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ clearActiveScalarVariableCoupleableVectorTags()

void FEProblemBase::clearActiveScalarVariableCoupleableVectorTags ( const THREAD_ID  tid)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 6430 of file FEProblemBase.C.

Referenced by AuxiliarySystem::clearScalarVariableCoupleableTags().

6431 {
6433 
6434  if (_displaced_problem)
6435  _displaced_problem->clearActiveScalarVariableCoupleableVectorTags(tid);
6436 }
virtual void clearActiveScalarVariableCoupleableVectorTags(const THREAD_ID tid)
Definition: SubProblem.C:420
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ clearAllDofIndices()

void SubProblem::clearAllDofIndices ( )
inherited

Clear dof indices from variables in nl and aux systems.

Definition at line 1178 of file SubProblem.C.

Referenced by FEProblemBase::solve().

1179 {
1180  for (const auto nl_sys_num : make_range(numNonlinearSystems()))
1183 }
virtual const SystemBase & systemBaseNonlinear(const unsigned int sys_num) const =0
Return the nonlinear system object as a base class reference given the system number.
virtual const SystemBase & systemBaseAuxiliary() const =0
Return the auxiliary system object as a base class reference.
IntRange< T > make_range(T beg, T end)
virtual std::size_t numNonlinearSystems() const =0
void clearAllDofIndices()
Clear all dof indices from moose variables.
Definition: SystemBase.C:1602

◆ clearCurrentJacobianMatrixTags()

void FEProblemBase::clearCurrentJacobianMatrixTags ( )
inlineinherited

Clear the current Jacobian matrix tag data structure ...

if someone creates it

Definition at line 2916 of file FEProblemBase.h.

Referenced by FEProblemBase::resetState().

2916 {}

◆ clearCurrentResidualVectorTags()

void FEProblemBase::clearCurrentResidualVectorTags ( )
inlineinherited

Clear the current residual vector tag data structure.

Definition at line 3837 of file FEProblemBase.h.

Referenced by CrankNicolson::init(), and FEProblemBase::resetState().

3838 {
3840 }
std::vector< VectorTag > _current_residual_vector_tags
A data member to store the residual vector tag(s) passed into computeResidualTag(s).

◆ clearDiracInfo()

void FEProblemBase::clearDiracInfo ( )
overridevirtualinherited

Gets called before Dirac Kernels are asked to add the points they are supposed to be evaluated in.

Implements SubProblem.

Definition at line 2605 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeDiracContributions().

2606 {
2608 
2609  if (_displaced_problem)
2610  _displaced_problem->clearDiracInfo();
2611 }
void clearPoints()
Remove all of the current points and elements.
std::shared_ptr< DisplacedProblem > _displaced_problem
DiracKernelInfo _dirac_kernel_info
Definition: SubProblem.h:1064

◆ computeBounds()

void FEProblemBase::computeBounds ( libMesh::NonlinearImplicitSystem sys,
NumericVector< libMesh::Number > &  lower,
NumericVector< libMesh::Number > &  upper 
)
virtualinherited

Definition at line 8042 of file FEProblemBase.C.

Referenced by Moose::compute_bounds().

8045 {
8046  try
8047  {
8048  try
8049  {
8050  mooseAssert(_current_nl_sys && (sys.number() == _current_nl_sys->number()),
8051  "I expect these system numbers to be the same");
8052 
8053  if (!_current_nl_sys->hasVector("lower_bound") || !_current_nl_sys->hasVector("upper_bound"))
8054  return;
8055 
8056  TIME_SECTION("computeBounds", 1, "Computing Bounds");
8057 
8058  NumericVector<Number> & _lower = _current_nl_sys->getVector("lower_bound");
8059  NumericVector<Number> & _upper = _current_nl_sys->getVector("upper_bound");
8060  _lower.swap(lower);
8061  _upper.swap(upper);
8062  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); tid++)
8064 
8065  _aux->residualSetup();
8067  _lower.swap(lower);
8068  _upper.swap(upper);
8069  }
8070  catch (...)
8071  {
8072  handleException("computeBounds");
8073  }
8074  }
8075  catch (MooseException & e)
8076  {
8077  mooseError("Irrecoverable exception: " + std::string(e.what()));
8078  }
8079  catch (...)
8080  {
8081  mooseError("Unexpected exception type");
8082  }
8083 }
virtual const char * what() const
Get out the error message.
unsigned int n_threads()
bool hasVector(const std::string &tag_name) const
Check if the named vector exists in the system.
Definition: SystemBase.C:925
unsigned int number() const
void handleException(const std::string &calling_method)
Handle exceptions.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
const ExecFlagType EXEC_LINEAR
Definition: Moose.C:31
virtual void residualSetup(THREAD_ID tid=0) const override
Provides a way for users to bail out of the current solve.
virtual void swap(NumericVector< T > &v)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
virtual NumericVector< Number > & getVector(const std::string &name)
Get a raw NumericVector by name.
Definition: SystemBase.C:934
MaterialWarehouse _all_materials
void computeSystems(const ExecFlagType &type)
Do generic system computations.
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ computeDamping()

Real FEProblemBase::computeDamping ( const NumericVector< libMesh::Number > &  soln,
const NumericVector< libMesh::Number > &  update 
)
virtualinherited

Definition at line 8325 of file FEProblemBase.C.

Referenced by FEProblemBase::computePostCheck().

8327 {
8328  // Default to no damping
8329  Real damping = 1.0;
8330 
8331  if (_has_dampers)
8332  {
8333  TIME_SECTION("computeDamping", 1, "Computing Damping");
8334 
8335  // Save pointer to the current solution
8336  const NumericVector<Number> * _saved_current_solution = _current_nl_sys->currentSolution();
8337 
8339  // For now, do not re-compute auxiliary variables. Doing so allows a wild solution increment
8340  // to get to the material models, which may not be able to cope with drastically different
8341  // values. Once more complete dependency checking is in place, auxiliary variables (and
8342  // material properties) will be computed as needed by dampers.
8343  // _aux.compute();
8344  damping = _current_nl_sys->computeDamping(soln, update);
8345 
8346  // restore saved solution
8347  _current_nl_sys->setSolution(*_saved_current_solution);
8348  }
8349 
8350  return damping;
8351 }
Real computeDamping(const NumericVector< Number > &solution, const NumericVector< Number > &update)
Compute damping.
bool _has_dampers
Whether or not this system has any Dampers associated with it.
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual const NumericVector< Number > *const & currentSolution() const override final
The solution vector that is currently being operated on.
Definition: SolverSystem.h:135
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real

◆ computeIndicators()

void FEProblemBase::computeIndicators ( )
virtualinherited

Reimplemented in DumpObjectsProblem.

Definition at line 4976 of file FEProblemBase.C.

Referenced by FEProblemBase::computeIndicatorsAndMarkers(), TransientBase::endStep(), MFEMSteady::execute(), SteadyBase::execute(), Eigenvalue::execute(), and FEProblemBase::initialAdaptMesh().

4977 {
4978  // Initialize indicator aux variable fields
4980  {
4981  TIME_SECTION("computeIndicators", 1, "Computing Indicators");
4982 
4983  // Internal side indicators may lead to creating a much larger sparsity pattern than dictated by
4984  // the actual finite element scheme (e.g. CFEM)
4985  const auto old_do_derivatives = ADReal::do_derivatives;
4986  ADReal::do_derivatives = false;
4987 
4988  std::vector<std::string> fields;
4989 
4990  // Indicator Fields
4991  const auto & indicators = _indicators.getActiveObjects();
4992  for (const auto & indicator : indicators)
4993  fields.push_back(indicator->name());
4994 
4995  // InternalSideIndicator Fields
4996  const auto & internal_indicators = _internal_side_indicators.getActiveObjects();
4997  for (const auto & internal_indicator : internal_indicators)
4998  fields.push_back(internal_indicator->name());
4999 
5000  _aux->zeroVariables(fields);
5001 
5002  // compute Indicators
5003  ComputeIndicatorThread cit(*this);
5005  _aux->solution().close();
5006  _aux->update();
5007 
5008  ComputeIndicatorThread finalize_cit(*this, true);
5010  _aux->solution().close();
5011  _aux->update();
5012 
5013  ADReal::do_derivatives = old_do_derivatives;
5014  }
5015 }
MooseObjectWarehouse< InternalSideIndicatorBase > _internal_side_indicators
void parallel_reduce(const Range &range, Body &body, const Partitioner &, unsigned int n_threads=libMesh::n_threads())
const libMesh::ConstElemRange & getCurrentAlgebraicElementRange()
These are the element and nodes that contribute to the jacobian and residual for this local processor...
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseObjectWarehouse< Indicator > _indicators
PetscErrorCode PetscInt const PetscInt fields[]
bool hasActiveObjects(THREAD_ID tid=0) const

◆ computeIndicatorsAndMarkers()

void FEProblemBase::computeIndicatorsAndMarkers ( )
virtualinherited

Definition at line 4969 of file FEProblemBase.C.

4970 {
4972  computeMarkers();
4973 }
virtual void computeMarkers()
virtual void computeIndicators()

◆ computeJacobian()

void FEProblemBase::computeJacobian ( const NumericVector< libMesh::Number > &  soln,
libMesh::SparseMatrix< libMesh::Number > &  jacobian,
const unsigned int  nl_sys_num 
)
virtualinherited

Form a Jacobian matrix with the default tag (system).

Definition at line 7873 of file FEProblemBase.C.

Referenced by FEProblemBase::computeJacobianSys().

7876 {
7877  setCurrentNonlinearSystem(nl_sys_num);
7878 
7879  _fe_matrix_tags.clear();
7880 
7881  auto & tags = getMatrixTags();
7882  for (auto & tag : tags)
7883  _fe_matrix_tags.insert(tag.second);
7884 
7885  computeJacobianInternal(soln, jacobian, _fe_matrix_tags);
7886 }
void setCurrentNonlinearSystem(const unsigned int nl_sys_num)
virtual void computeJacobianInternal(const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian, const std::set< TagID > &tags)
Form a Jacobian matrix for multiple tags.
virtual std::map< TagName, TagID > & getMatrixTags()
Return all matrix tags in the system, where a tag is represented by a map from name to ID...
Definition: SubProblem.h:253
std::set< TagID > _fe_matrix_tags

◆ computeJacobianBlock()

void FEProblemBase::computeJacobianBlock ( libMesh::SparseMatrix< libMesh::Number > &  jacobian,
libMesh::System precond_system,
unsigned int  ivar,
unsigned int  jvar 
)
virtualinherited

Really not a good idea to use this.

It computes just one block of the Jacobian into a smaller matrix. Calling this in a loop is EXTREMELY ineffecient! Try to use computeJacobianBlocks() instead!

Parameters
jacobianThe matrix you want to fill
precond_systemThe libMesh::system of the preconditioning system
ivarthe block-row of the Jacobian
jvarthe block-column of the Jacobian

Definition at line 8030 of file FEProblemBase.C.

8034 {
8035  JacobianBlock jac_block(precond_system, jacobian, ivar, jvar);
8036  std::vector<JacobianBlock *> blocks = {&jac_block};
8037  mooseAssert(_current_nl_sys, "This should be non-null");
8039 }
Helper class for holding the preconditioning blocks to fill.
char ** blocks
virtual void computeJacobianBlocks(std::vector< JacobianBlock *> &blocks, const unsigned int nl_sys_num)
Computes several Jacobian blocks simultaneously, summing their contributions into smaller preconditio...
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158

◆ computeJacobianBlocks()

void FEProblemBase::computeJacobianBlocks ( std::vector< JacobianBlock *> &  blocks,
const unsigned int  nl_sys_num 
)
virtualinherited

Computes several Jacobian blocks simultaneously, summing their contributions into smaller preconditioning matrices.

Used by Physics-based preconditioning

Parameters
blocksThe blocks to fill in (JacobianBlock is defined in ComputeJacobianBlocksThread)

Reimplemented in EigenProblem.

Definition at line 8010 of file FEProblemBase.C.

Referenced by FEProblemBase::computeJacobianBlock(), and PhysicsBasedPreconditioner::setup().

8012 {
8013  TIME_SECTION("computeTransientImplicitJacobian", 2);
8014  setCurrentNonlinearSystem(nl_sys_num);
8015 
8016  if (_displaced_problem)
8017  {
8019  _displaced_problem->updateMesh();
8020  }
8021 
8023 
8027 }
void computeJacobianBlocks(std::vector< JacobianBlock *> &blocks)
Computes several Jacobian blocks simultaneously, summing their contributions into smaller preconditio...
char ** blocks
bool _currently_computing_jacobian
Flag to determine whether the problem is currently computing Jacobian.
Definition: SubProblem.h:1111
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
void setCurrentNonlinearSystem(const unsigned int nl_sys_num)
const ExecFlagType EXEC_PRE_DISPLACE
Definition: Moose.C:54
const ExecFlagType EXEC_NONLINEAR
Definition: Moose.C:33
std::shared_ptr< DisplacedProblem > _displaced_problem
void computeSystems(const ExecFlagType &type)
Do generic system computations.

◆ computeJacobianInternal()

void FEProblemBase::computeJacobianInternal ( const NumericVector< libMesh::Number > &  soln,
libMesh::SparseMatrix< libMesh::Number > &  jacobian,
const std::set< TagID > &  tags 
)
virtualinherited

Form a Jacobian matrix for multiple tags.

It should not be called directly by users.

Definition at line 7889 of file FEProblemBase.C.

Referenced by FEProblemBase::computeJacobian().

7892 {
7893  TIME_SECTION("computeJacobianInternal", 1);
7894 
7896 
7898 
7899  computeJacobianTags(tags);
7900 
7902 }
TagID systemMatrixTag() const override
Return the Matrix Tag ID for System.
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
virtual void associateMatrixToTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Associate a matrix to a tag.
Definition: SystemBase.C:1077
virtual void disassociateMatrixFromTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Disassociate a matrix from a tag.
Definition: SystemBase.C:1089
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual void computeJacobianTags(const std::set< TagID > &tags)
Form multiple matrices, and each is associated with a tag.

◆ computeJacobianSys()

void FEProblemBase::computeJacobianSys ( libMesh::NonlinearImplicitSystem sys,
const NumericVector< libMesh::Number > &  soln,
libMesh::SparseMatrix< libMesh::Number > &  jacobian 
)
virtualinherited

Form a Jacobian matrix.

It is called by Libmesh.

Definition at line 7849 of file FEProblemBase.C.

Referenced by Moose::compute_jacobian(), and NonlinearSystem::computeScalingJacobian().

7852 {
7853  // Reset before Jacobian setup, calculation & execution
7855  computeJacobian(soln, jacobian, sys.number());
7856 }
void resetIterationOccurences()
Reset the number of solution invalid occurrences back to zero.
unsigned int number() const
virtual void computeJacobian(const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian, const unsigned int nl_sys_num)
Form a Jacobian matrix with the default tag (system).
SolutionInvalidity & solutionInvalidity()
Get the SolutionInvalidity for this app.
Definition: MooseApp.h:185
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375

◆ computeJacobianTag()

void FEProblemBase::computeJacobianTag ( const NumericVector< libMesh::Number > &  soln,
libMesh::SparseMatrix< libMesh::Number > &  jacobian,
TagID  tag 
)
virtualinherited

Form a Jacobian matrix for a given tag.

Definition at line 7859 of file FEProblemBase.C.

Referenced by ActuallyExplicitEuler::solve(), and ExplicitSSPRungeKutta::solveStage().

7862 {
7864 
7865  _current_nl_sys->associateMatrixToTag(jacobian, tag);
7866 
7867  computeJacobianTags({tag});
7868 
7870 }
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
virtual void associateMatrixToTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Associate a matrix to a tag.
Definition: SystemBase.C:1077
virtual void disassociateMatrixFromTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Disassociate a matrix from a tag.
Definition: SystemBase.C:1089
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual void computeJacobianTags(const std::set< TagID > &tags)
Form multiple matrices, and each is associated with a tag.

◆ computeJacobianTags()

void FEProblemBase::computeJacobianTags ( const std::set< TagID > &  tags)
virtualinherited

Form multiple matrices, and each is associated with a tag.

Definition at line 7905 of file FEProblemBase.C.

Referenced by EigenProblem::computeJacobianAB(), FEProblemBase::computeJacobianInternal(), EigenProblem::computeJacobianTag(), FEProblemBase::computeJacobianTag(), and EigenProblem::computeMatricesTags().

7906 {
7907  try
7908  {
7909  try
7910  {
7911  if (!_has_jacobian || !_const_jacobian)
7912  {
7913  TIME_SECTION("computeJacobianTags", 5, "Computing Jacobian");
7914 
7915  for (auto tag : tags)
7916  if (_current_nl_sys->hasMatrix(tag))
7917  {
7918  auto & matrix = _current_nl_sys->getMatrix(tag);
7921  else
7922  matrix.zero();
7924  // PETSc algorithms require diagonal allocations regardless of whether there is
7925  // non-zero diagonal dependence. With global AD indexing we only add non-zero
7926  // dependence, so PETSc will scream at us unless we artificially add the diagonals.
7927  for (auto index : make_range(matrix.row_start(), matrix.row_stop()))
7928  matrix.add(index, index, 0);
7929  }
7930 
7931  _aux->zeroVariablesForJacobian();
7932 
7933  unsigned int n_threads = libMesh::n_threads();
7934 
7935  // Random interface objects
7936  for (const auto & it : _random_data_objects)
7937  it.second->updateSeeds(EXEC_NONLINEAR);
7938 
7941  if (_displaced_problem)
7942  _displaced_problem->setCurrentlyComputingJacobian(true);
7943 
7946 
7947  for (unsigned int tid = 0; tid < n_threads; tid++)
7948  reinitScalars(tid);
7949 
7951 
7952  _aux->jacobianSetup();
7953 
7954  if (_displaced_problem)
7955  {
7957  _displaced_problem->updateMesh();
7958  }
7959 
7960  for (unsigned int tid = 0; tid < n_threads; tid++)
7961  {
7964  }
7965 
7966 #ifdef MOOSE_KOKKOS_ENABLED
7968 #endif
7969 
7971 
7973 
7975 
7977 
7979 
7981 
7982  // For explicit Euler calculations for example we often compute the Jacobian one time and
7983  // then re-use it over and over. If we're performing automatic scaling, we don't want to
7984  // use that kernel, diagonal-block only Jacobian for our actual matrix when performing
7985  // solves!
7987  _has_jacobian = true;
7988  }
7989  }
7990  catch (...)
7991  {
7992  handleException("computeJacobianTags");
7993  }
7994  }
7995  catch (const MooseException &)
7996  {
7997  // The buck stops here, we have already handled the exception by
7998  // calling the system's stopSolve() method, it is now up to PETSc to return a
7999  // "diverged" reason during the next solve.
8000  }
8001  catch (...)
8002  {
8003  mooseError("Unexpected exception type");
8004  }
8005 
8006  resetState();
8007 }
virtual void restore_original_nonzero_pattern()
unsigned int n_threads()
ExecFlagType _current_execute_on_flag
Current execute_on flag.
bool _has_jacobian
Indicates if the Jacobian was computed.
virtual void jacobianSetup(THREAD_ID tid=0) const override
bool _currently_computing_jacobian
Flag to determine whether the problem is currently computing Jacobian.
Definition: SubProblem.h:1111
virtual void reinitScalars(const THREAD_ID tid, bool reinit_for_derivative_reordering=false) override
fills the VariableValue arrays for scalar variables from the solution vector
bool computingScalingJacobian() const
Whether we are computing an initial Jacobian for automatic variable scaling.
Definition: SystemBase.C:1554
virtual bool hasMatrix(TagID tag) const
Check if the tagged matrix exists in the system.
Definition: SystemBase.h:361
bool has_static_condensation() const
MooseObjectWarehouse< Moose::FunctionBase > _kokkos_functions
virtual void resetState()
Reset state of this object in preparation for the next evaluation.
void jacobianSetup()
Calls the jacobianSetup function for each of the output objects.
virtual void computeUserObjects(const ExecFlagType &type, const Moose::AuxGroup &group)
Call compute methods on UserObjects.
void handleException(const std::string &calling_method)
Handle exceptions.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
void computeJacobianTags(const std::set< TagID > &tags)
Computes multiple (tag associated) Jacobian matricese.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
A map of objects that consume random numbers.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
bool haveADObjects() const
Method for reading wehther we have any ad objects.
Definition: SubProblem.h:779
virtual void jacobianSetup(THREAD_ID tid=0) const
const ExecFlagType EXEC_PRE_DISPLACE
Definition: Moose.C:54
const ExecFlagType EXEC_NONLINEAR
Definition: Moose.C:33
Provides a way for users to bail out of the current solve.
const bool _restore_original_nonzero_pattern
Whether we should restore the original nonzero pattern for every Jacobian evaluation.
virtual libMesh::SparseMatrix< Number > & getMatrix(TagID tag)
Get a raw SparseMatrix.
Definition: SystemBase.C:1025
void executeControls(const ExecFlagType &exec_type)
Performs setup and execute calls for Control objects.
IntRange< T > make_range(T beg, T end)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseObjectWarehouse< Function > _functions
functions
bool execMultiApps(ExecFlagType type, bool auto_advance=true)
Execute the MultiApps associated with the ExecFlagType.
bool _const_jacobian
true if the Jacobian is constant
bool _safe_access_tagged_matrices
Is it safe to retrieve data from tagged matrices.
Definition: SubProblem.h:1123
MaterialWarehouse _all_materials
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
void computeSystems(const ExecFlagType &type)
Do generic system computations.
void execTransfers(ExecFlagType type)
Execute the Transfers associated with the ExecFlagType.
virtual libMesh::System & system() override
Get the reference to the libMesh system.

◆ computeKokkosUserObjectsInternal()

void FEProblemBase::computeKokkosUserObjectsInternal ( const ExecFlagType type,
TheWarehouse::Query query 
)
protectedinherited

◆ computeLinearSystemSys()

void FEProblemBase::computeLinearSystemSys ( libMesh::LinearImplicitSystem sys,
libMesh::SparseMatrix< libMesh::Number > &  system_matrix,
NumericVector< libMesh::Number > &  rhs,
const bool  compute_gradients = true 
)
virtualinherited

Assemble both the right hand side and the system matrix of a given linear system.

Parameters
sysThe linear system which should be assembled
system_matrixThe sparse matrix which should hold the system matrix
rhsThe vector which should hold the right hand side
compute_gradientsA flag to disable the computation of new gradients during the assembly, can be used to lag gradients

Definition at line 8086 of file FEProblemBase.C.

Referenced by Moose::compute_linear_system(), and FEProblemBase::computeResidualL2Norm().

8090 {
8091  TIME_SECTION("computeLinearSystemSys", 5);
8092 
8094 
8097 
8098  // We are using the residual tag system for right hand sides so we fetch everything
8099  const auto & vector_tags = getVectorTags(Moose::VECTOR_TAG_RESIDUAL);
8100 
8101  // We filter out tags which do not have associated vectors in the current
8102  // system. This is essential to be able to use system-dependent vector tags.
8105 
8109  compute_gradients);
8110 
8115  // We reset the tags to the default containers for further operations
8120 }
TagID rightHandSideVectorTag() const
Definition: LinearSystem.h:153
virtual TagID systemMatrixTag() const override
Return the Matrix Tag ID for System.
Definition: LinearSystem.h:154
virtual void associateVectorToTag(NumericVector< Number > &vec, TagID tag)
Associate a vector for a given tag.
Definition: SystemBase.C:982
static void selectVectorTagsFromSystem(const SystemBase &system, const std::vector< VectorTag > &input_vector_tags, std::set< TagID > &selected_tags)
Select the vector tags which belong to a specific system.
Definition: SubProblem.C:290
virtual void associateMatrixToTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Associate a matrix to a tag.
Definition: SystemBase.C:1077
SparseMatrix< Number > & getSystemMatrix()
Fetching the system matrix from the libmesh system.
Definition: LinearSystem.h:165
std::set< TagID > _linear_matrix_tags
Temporary storage for filtered matrix tags for linear systems.
virtual void disassociateMatrixFromTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Disassociate a matrix from a tag.
Definition: SystemBase.C:1089
virtual const NumericVector< Number > *const & currentSolution() const override final
The solution vector that is currently being operated on.
Definition: SolverSystem.h:135
std::vector< VectorTag > getVectorTags(const std::set< TagID > &tag_ids) const
Definition: SubProblem.C:173
virtual void disassociateVectorFromTag(NumericVector< Number > &vec, TagID tag)
Disassociate a given vector from a given tag.
LinearSystem * _current_linear_sys
The current linear system that we are solving.
virtual std::map< TagName, TagID > & getMatrixTags()
Return all matrix tags in the system, where a tag is represented by a map from name to ID...
Definition: SubProblem.h:253
NumericVector< Number > & getRightHandSideVector()
Fetching the right hand side vector from the libmesh system.
Definition: LinearSystem.h:158
void setCurrentLinearSystem(unsigned int sys_num)
Set the current linear system pointer.
static void selectMatrixTagsFromSystem(const SystemBase &system, const std::map< TagName, TagID > &input_matrix_tags, std::set< TagID > &selected_tags)
Select the matrix tags which belong to a specific system.
Definition: SubProblem.C:301
void computeLinearSystemTags(const NumericVector< libMesh::Number > &soln, const std::set< TagID > &vector_tags, const std::set< TagID > &matrix_tags, const bool compute_gradients=true)
Assemble the current linear system given a set of vector and matrix tags.
unsigned int linearSysNum(const LinearSystemName &linear_sys_name) const override
const std::string & name() const
std::set< TagID > _linear_vector_tags
Temporary storage for filtered vector tags for linear systems.

◆ computeLinearSystemTags()

void FEProblemBase::computeLinearSystemTags ( const NumericVector< libMesh::Number > &  soln,
const std::set< TagID > &  vector_tags,
const std::set< TagID > &  matrix_tags,
const bool  compute_gradients = true 
)
inherited

Assemble the current linear system given a set of vector and matrix tags.

Parameters
solnThe solution which should be used for the system assembly
vector_tagsThe vector tags for the right hand side
matrix_tagsThe matrix tags for the matrix
compute_gradientsA flag to disable the computation of new gradients during the assembly, can be used to lag gradients

Definition at line 8123 of file FEProblemBase.C.

Referenced by FEProblemBase::computeLinearSystemSys().

8127 {
8128  TIME_SECTION("computeLinearSystemTags", 5, "Computing Linear System");
8129 
8131 
8132  for (auto tag : matrix_tags)
8133  {
8134  auto & matrix = _current_linear_sys->getMatrix(tag);
8135  matrix.zero();
8136  }
8137 
8138  unsigned int n_threads = libMesh::n_threads();
8139 
8141 
8142  // Random interface objects
8143  for (const auto & it : _random_data_objects)
8144  it.second->updateSeeds(EXEC_NONLINEAR);
8145 
8148 
8150 
8151  _aux->jacobianSetup();
8152 
8153  for (THREAD_ID tid = 0; tid < n_threads; tid++)
8154  {
8156  }
8157 
8158 #ifdef MOOSE_KOKKOS_ENABLED
8160 #endif
8161 
8162  try
8163  {
8165  }
8166  catch (MooseException & e)
8167  {
8168  _console << "\nA MooseException was raised during Auxiliary variable computation.\n"
8169  << "The next solve will fail, the timestep will be reduced, and we will try again.\n"
8170  << std::endl;
8171 
8172  // We know the next solve is going to fail, so there's no point in
8173  // computing anything else after this. Plus, using incompletely
8174  // computed AuxVariables in subsequent calculations could lead to
8175  // other errors or unhandled exceptions being thrown.
8176  return;
8177  }
8178 
8181 
8183 
8184  _current_linear_sys->computeLinearSystemTags(vector_tags, matrix_tags, compute_gradients);
8185 
8186  // Reset execution flag as after this point we are no longer on LINEAR
8188 
8189  // These are the relevant parts of resetState()
8192 }
unsigned int n_threads()
ExecFlagType _current_execute_on_flag
Current execute_on flag.
const ExecFlagType EXEC_NONE
Definition: Moose.C:29
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
MooseObjectWarehouse< Moose::FunctionBase > _kokkos_functions
void jacobianSetup()
Calls the jacobianSetup function for each of the output objects.
virtual void computeUserObjects(const ExecFlagType &type, const Moose::AuxGroup &group)
Call compute methods on UserObjects.
virtual void zero()=0
bool _safe_access_tagged_vectors
Is it safe to retrieve data from tagged vectors.
Definition: SubProblem.h:1126
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
LinearSystem * _current_linear_sys
The current linear system that we are solving.
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
A map of objects that consume random numbers.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
virtual void jacobianSetup(THREAD_ID tid=0) const
const ExecFlagType EXEC_NONLINEAR
Definition: Moose.C:33
Provides a way for users to bail out of the current solve.
virtual libMesh::SparseMatrix< Number > & getMatrix(TagID tag)
Get a raw SparseMatrix.
Definition: SystemBase.C:1025
void executeControls(const ExecFlagType &exec_type)
Performs setup and execute calls for Control objects.
MooseObjectWarehouse< Function > _functions
functions
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
bool execMultiApps(ExecFlagType type, bool auto_advance=true)
Execute the MultiApps associated with the ExecFlagType.
bool _safe_access_tagged_matrices
Is it safe to retrieve data from tagged matrices.
Definition: SubProblem.h:1123
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
void computeSystems(const ExecFlagType &type)
Do generic system computations.
void computeLinearSystemTags(const std::set< TagID > &vector_tags, const std::set< TagID > &matrix_tags, const bool compute_gradients=true)
Compute the right hand side and the system matrix of the system for given tags.
Definition: LinearSystem.C:185
void execTransfers(ExecFlagType type)
Execute the Transfers associated with the ExecFlagType.
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ computeMarkers()

void FEProblemBase::computeMarkers ( )
virtualinherited

Reimplemented in DumpObjectsProblem.

Definition at line 5018 of file FEProblemBase.C.

Referenced by FEProblemBase::adaptMesh(), FEProblemBase::computeIndicatorsAndMarkers(), TransientBase::endStep(), MFEMSteady::execute(), SteadyBase::execute(), Eigenvalue::execute(), and FEProblemBase::initialAdaptMesh().

5019 {
5020  if (_markers.hasActiveObjects())
5021  {
5022  TIME_SECTION("computeMarkers", 1, "Computing Markers");
5023 
5024  std::vector<std::string> fields;
5025 
5026  // Marker Fields
5027  const auto & markers = _markers.getActiveObjects();
5028  for (const auto & marker : markers)
5029  fields.push_back(marker->name());
5030 
5031  _aux->zeroVariables(fields);
5032 
5034 
5035  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); ++tid)
5036  {
5037  const auto & markers = _markers.getActiveObjects(tid);
5038  for (const auto & marker : markers)
5039  marker->markerSetup();
5040  }
5041 
5042  ComputeMarkerThread cmt(*this);
5044 
5045  _aux->solution().close();
5046  _aux->update();
5047  }
5048 }
unsigned int n_threads()
void updateErrorVectors()
Update the ErrorVectors that have been requested through calls to getErrorVector().
Definition: Adaptivity.C:399
void parallel_reduce(const Range &range, Body &body, const Partitioner &, unsigned int n_threads=libMesh::n_threads())
const libMesh::ConstElemRange & getCurrentAlgebraicElementRange()
These are the element and nodes that contribute to the jacobian and residual for this local processor...
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
Adaptivity _adaptivity
PetscErrorCode PetscInt const PetscInt fields[]
bool hasActiveObjects(THREAD_ID tid=0) const
MooseObjectWarehouse< Marker > _markers
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ computeMultiAppsDT()

Real FEProblemBase::computeMultiAppsDT ( ExecFlagType  type)
inherited

Find the smallest timestep over all MultiApps.

Definition at line 6125 of file FEProblemBase.C.

Referenced by TransientBase::constrainDTFromMultiApp().

6126 {
6127  const auto & multi_apps = _transient_multi_apps[type].getActiveObjects();
6128 
6129  Real smallest_dt = std::numeric_limits<Real>::max();
6130 
6131  for (const auto & multi_app : multi_apps)
6132  smallest_dt = std::min(smallest_dt, multi_app->computeDT());
6133 
6134  return smallest_dt;
6135 }
ExecuteMooseObjectWarehouse< TransientMultiApp > _transient_multi_apps
Storage for TransientMultiApps (only needed for calling &#39;computeDT&#39;)
auto max(const L &left, const R &right)
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
auto min(const L &left, const R &right)

◆ computeNearNullSpace()

void FEProblemBase::computeNearNullSpace ( libMesh::NonlinearImplicitSystem sys,
std::vector< NumericVector< libMesh::Number > *> &  sp 
)
virtualinherited

Definition at line 8195 of file FEProblemBase.C.

Referenced by Moose::compute_nearnullspace().

8197 {
8198  mooseAssert(_current_nl_sys && (sys.number() == _current_nl_sys->number()),
8199  "I expect these system numbers to be the same");
8200 
8201  sp.clear();
8202  for (unsigned int i = 0; i < subspaceDim("NearNullSpace"); ++i)
8203  {
8204  std::stringstream postfix;
8205  postfix << "_" << i;
8206  std::string modename = "NearNullSpace" + postfix.str();
8207  sp.push_back(&_current_nl_sys->getVector(modename));
8208  }
8209 }
unsigned int subspaceDim(const std::string &prefix) const
Dimension of the subspace spanned by vectors with a given prefix.
unsigned int number() const
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
virtual NumericVector< Number > & getVector(const std::string &name)
Get a raw NumericVector by name.
Definition: SystemBase.C:934

◆ computeNullSpace()

void FEProblemBase::computeNullSpace ( libMesh::NonlinearImplicitSystem sys,
std::vector< NumericVector< libMesh::Number > *> &  sp 
)
virtualinherited

Definition at line 8212 of file FEProblemBase.C.

Referenced by Moose::compute_nullspace().

8214 {
8215  mooseAssert(_current_nl_sys && (sys.number() == _current_nl_sys->number()),
8216  "I expect these system numbers to be the same");
8217  sp.clear();
8218  for (unsigned int i = 0; i < subspaceDim("NullSpace"); ++i)
8219  {
8220  std::stringstream postfix;
8221  postfix << "_" << i;
8222  sp.push_back(&_current_nl_sys->getVector("NullSpace" + postfix.str()));
8223  }
8224 }
unsigned int subspaceDim(const std::string &prefix) const
Dimension of the subspace spanned by vectors with a given prefix.
unsigned int number() const
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
virtual NumericVector< Number > & getVector(const std::string &name)
Get a raw NumericVector by name.
Definition: SystemBase.C:934

◆ computePostCheck()

void FEProblemBase::computePostCheck ( libMesh::NonlinearImplicitSystem sys,
const NumericVector< libMesh::Number > &  old_soln,
NumericVector< libMesh::Number > &  search_direction,
NumericVector< libMesh::Number > &  new_soln,
bool &  changed_search_direction,
bool &  changed_new_soln 
)
virtualinherited

Definition at line 8242 of file FEProblemBase.C.

Referenced by Moose::compute_postcheck().

8248 {
8249  mooseAssert(_current_nl_sys && (sys.number() == _current_nl_sys->number()),
8250  "I expect these system numbers to be the same");
8251 
8252  // This function replaces the old PetscSupport::dampedCheck() function.
8253  //
8254  // 1.) Recreate code in PetscSupport::dampedCheck() for constructing
8255  // ghosted "soln" and "update" vectors.
8256  // 2.) Call FEProblemBase::computeDamping() with these ghost vectors.
8257  // 3.) Recreate the code in PetscSupport::dampedCheck() to actually update
8258  // the solution vector based on the damping, and set the "changed" flags
8259  // appropriately.
8260 
8261  TIME_SECTION("computePostCheck", 2, "Computing Post Check");
8262 
8264 
8265  // MOOSE's FEProblemBase doesn't update the solution during the
8266  // postcheck, but FEProblemBase-derived classes might.
8268  {
8269  // We need ghosted versions of new_soln and search_direction (the
8270  // ones we get from libmesh/PETSc are PARALLEL vectors. To make
8271  // our lives simpler, we use the same ghosting pattern as the
8272  // system's current_local_solution to create new ghosted vectors.
8273 
8274  // Construct zeroed-out clones with the same ghosted dofs as the
8275  // System's current_local_solution.
8276  std::unique_ptr<NumericVector<Number>> ghosted_solution =
8277  sys.current_local_solution->zero_clone(),
8278  ghosted_search_direction =
8279  sys.current_local_solution->zero_clone();
8280 
8281  // Copy values from input vectors into clones with ghosted values.
8282  *ghosted_solution = new_soln;
8283  *ghosted_search_direction = search_direction;
8284 
8285  if (_has_dampers)
8286  {
8287  // Compute the damping coefficient using the ghosted vectors
8288  Real damping = computeDamping(*ghosted_solution, *ghosted_search_direction);
8289 
8290  // If some non-trivial damping was computed, update the new_soln
8291  // vector accordingly.
8292  if (damping < 1.0)
8293  {
8294  new_soln = old_soln;
8295  new_soln.add(-damping, search_direction);
8296  changed_new_soln = true;
8297  }
8298  }
8299 
8300  if (shouldUpdateSolution())
8301  {
8302  // Update the ghosted copy of the new solution, if necessary.
8303  if (changed_new_soln)
8304  *ghosted_solution = new_soln;
8305 
8306  bool updated_solution = updateSolution(new_soln, *ghosted_solution);
8307  if (updated_solution)
8308  changed_new_soln = true;
8309  }
8310  }
8311 
8313  {
8315  _aux->copyCurrentIntoPreviousNL();
8316  }
8317 
8318  // MOOSE doesn't change the search_direction
8319  changed_search_direction = false;
8320 
8322 }
ExecFlagType _current_execute_on_flag
Current execute_on flag.
virtual void setPreviousNewtonSolution(const NumericVector< Number > &soln)
bool _has_dampers
Whether or not this system has any Dampers associated with it.
const ExecFlagType EXEC_NONE
Definition: Moose.C:29
unsigned int number() const
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual bool shouldUpdateSolution()
Check to see whether the problem should update the solution.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
virtual bool vectorTagExists(const TagID tag_id) const
Check to see if a particular Tag exists.
Definition: SubProblem.h:201
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
const ExecFlagType EXEC_POSTCHECK
Definition: Moose.C:35
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
std::unique_ptr< NumericVector< Number > > current_local_solution
virtual bool updateSolution(NumericVector< libMesh::Number > &vec_solution, NumericVector< libMesh::Number > &ghosted_solution)
Update the solution.
virtual void add(const numeric_index_type i, const T value)=0
const TagName PREVIOUS_NL_SOLUTION_TAG
Definition: MooseTypes.C:28
virtual Real computeDamping(const NumericVector< libMesh::Number > &soln, const NumericVector< libMesh::Number > &update)

◆ computeResidual() [1/2]

void FEProblemBase::computeResidual ( libMesh::NonlinearImplicitSystem sys,
const NumericVector< libMesh::Number > &  soln,
NumericVector< libMesh::Number > &  residual 
)
inherited

This function is called by Libmesh to form a residual.

This is deprecated. We should remove this as soon as RattleSnake is fixed.

Referenced by FEProblemBase::computeResidualL2Norm(), FEProblemBase::computeResidualSys(), ActuallyExplicitEuler::solve(), and ExplicitSSPRungeKutta::solveStage().

◆ computeResidual() [2/2]

virtual void FEProblemBase::computeResidual ( const NumericVector< libMesh::Number > &  soln,
NumericVector< libMesh::Number > &  residual,
const unsigned int  nl_sys_num 
)
virtualinherited

Form a residual with default tags (nontime, time, residual).

◆ computeResidualAndJacobian()

void FEProblemBase::computeResidualAndJacobian ( const NumericVector< libMesh::Number > &  soln,
NumericVector< libMesh::Number > &  residual,
libMesh::SparseMatrix< libMesh::Number > &  jacobian 
)
inherited

Form a residual and Jacobian with default tags.

Definition at line 7483 of file FEProblemBase.C.

Referenced by ComputeResidualAndJacobian::residual_and_jacobian().

7486 {
7487  try
7488  {
7489  try
7490  {
7491  // vector tags
7493  const auto & residual_vector_tags = getVectorTags(Moose::VECTOR_TAG_RESIDUAL);
7494 
7495  mooseAssert(_fe_vector_tags.empty(),
7496  "This should be empty indicating a clean starting state");
7497  // We filter out tags which do not have associated vectors in the current nonlinear
7498  // system. This is essential to be able to use system-dependent residual tags.
7500 
7502 
7503  // matrix tags
7504  {
7505  _fe_matrix_tags.clear();
7506 
7507  auto & tags = getMatrixTags();
7508  for (auto & tag : tags)
7509  _fe_matrix_tags.insert(tag.second);
7510  }
7511 
7513 
7516 
7517  for (const auto tag : _fe_matrix_tags)
7518  if (_current_nl_sys->hasMatrix(tag))
7519  {
7520  auto & matrix = _current_nl_sys->getMatrix(tag);
7521  matrix.zero();
7523  // PETSc algorithms require diagonal allocations regardless of whether there is non-zero
7524  // diagonal dependence. With global AD indexing we only add non-zero
7525  // dependence, so PETSc will scream at us unless we artificially add the diagonals.
7526  for (auto index : make_range(matrix.row_start(), matrix.row_stop()))
7527  matrix.add(index, index, 0);
7528  }
7529 
7530  _aux->zeroVariablesForResidual();
7531 
7532  unsigned int n_threads = libMesh::n_threads();
7533 
7535 
7536  // Random interface objects
7537  for (const auto & it : _random_data_objects)
7538  it.second->updateSeeds(EXEC_LINEAR);
7539 
7543  if (_displaced_problem)
7544  {
7545  _displaced_problem->setCurrentlyComputingResidual(true);
7546  _displaced_problem->setCurrentlyComputingJacobian(true);
7547  _displaced_problem->setCurrentlyComputingResidualAndJacobian(true);
7548  }
7549 
7551 
7553 
7554  for (unsigned int tid = 0; tid < n_threads; tid++)
7555  reinitScalars(tid);
7556 
7558 
7559  _aux->residualSetup();
7560 
7561  if (_displaced_problem)
7562  {
7564  _displaced_problem->updateMesh();
7565  if (_mortar_data->hasDisplacedObjects())
7566  updateMortarMesh();
7567  }
7568 
7569  for (THREAD_ID tid = 0; tid < n_threads; tid++)
7570  {
7573  }
7574 
7575 #ifdef MOOSE_KOKKOS_ENABLED
7577 #endif
7578 
7580 
7582 
7584 
7586 
7589 
7591 
7594  }
7595  catch (...)
7596  {
7597  handleException("computeResidualAndJacobian");
7598  }
7599  }
7600  catch (const MooseException &)
7601  {
7602  // The buck stops here, we have already handled the exception by
7603  // calling the system's stopSolve() method, it is now up to PETSc to return a
7604  // "diverged" reason during the next solve.
7605  }
7606  catch (...)
7607  {
7608  mooseError("Unexpected exception type");
7609  }
7610 
7611  resetState();
7612  _fe_vector_tags.clear();
7613  _fe_matrix_tags.clear();
7614 }
virtual void residualSetup(THREAD_ID tid=0) const
unsigned int n_threads()
ExecFlagType _current_execute_on_flag
Current execute_on flag.
TagID systemMatrixTag() const override
Return the Matrix Tag ID for System.
virtual void reinitScalars(const THREAD_ID tid, bool reinit_for_derivative_reordering=false) override
fills the VariableValue arrays for scalar variables from the solution vector
void setCurrentlyComputingResidual(bool currently_computing_residual) final
Set whether or not the problem is in the process of computing the residual.
virtual void associateVectorToTag(NumericVector< Number > &vec, TagID tag)
Associate a vector for a given tag.
Definition: SystemBase.C:982
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
virtual bool hasMatrix(TagID tag) const
Check if the tagged matrix exists in the system.
Definition: SystemBase.h:361
static void selectVectorTagsFromSystem(const SystemBase &system, const std::vector< VectorTag > &input_vector_tags, std::set< TagID > &selected_tags)
Select the vector tags which belong to a specific system.
Definition: SubProblem.C:290
virtual void associateMatrixToTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Associate a matrix to a tag.
Definition: SystemBase.C:1077
bool has_static_condensation() const
void setCurrentlyComputingResidualAndJacobian(bool currently_computing_residual_and_jacobian)
Set whether or not the problem is in the process of computing the Jacobian.
Definition: SubProblem.h:1511
MooseObjectWarehouse< Moose::FunctionBase > _kokkos_functions
virtual void disassociateMatrixFromTag(libMesh::SparseMatrix< Number > &matrix, TagID tag)
Disassociate a matrix from a tag.
Definition: SystemBase.C:1089
void setCurrentlyComputingJacobian(const bool currently_computing_jacobian)
Set whether or not the problem is in the process of computing the Jacobian.
Definition: SubProblem.h:697
virtual void resetState()
Reset state of this object in preparation for the next evaluation.
virtual void computeUserObjects(const ExecFlagType &type, const Moose::AuxGroup &group)
Call compute methods on UserObjects.
void computeResidualAndJacobianTags(const std::set< TagID > &vector_tags, const std::set< TagID > &matrix_tags)
Form possibly multiple tag-associated vectors and matrices.
void handleException(const std::string &calling_method)
Handle exceptions.
virtual void zero()=0
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
bool _safe_access_tagged_vectors
Is it safe to retrieve data from tagged vectors.
Definition: SubProblem.h:1126
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::vector< VectorTag > getVectorTags(const std::set< TagID > &tag_ids) const
Definition: SubProblem.C:173
virtual void disassociateVectorFromTag(NumericVector< Number > &vec, TagID tag)
Disassociate a given vector from a given tag.
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
A map of objects that consume random numbers.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
const ExecFlagType EXEC_LINEAR
Definition: Moose.C:31
bool haveADObjects() const
Method for reading wehther we have any ad objects.
Definition: SubProblem.h:779
virtual std::map< TagName, TagID > & getMatrixTags()
Return all matrix tags in the system, where a tag is represented by a map from name to ID...
Definition: SubProblem.h:253
TagID residualVectorTag() const override
void residualSetup()
Calls the residualSetup function for each of the output objects.
virtual void residualSetup(THREAD_ID tid=0) const override
const ExecFlagType EXEC_PRE_DISPLACE
Definition: Moose.C:54
virtual void updateMortarMesh()
std::set< TagID > _fe_matrix_tags
Provides a way for users to bail out of the current solve.
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data
virtual libMesh::SparseMatrix< Number > & getMatrix(TagID tag)
Get a raw SparseMatrix.
Definition: SystemBase.C:1025
void executeControls(const ExecFlagType &exec_type)
Performs setup and execute calls for Control objects.
IntRange< T > make_range(T beg, T end)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::set< TagID > _fe_vector_tags
std::shared_ptr< DisplacedProblem > _displaced_problem
void setCurrentResidualVectorTags(const std::set< TagID > &vector_tags)
Set the current residual vector tag data structure based on the passed in tag IDs.
MooseObjectWarehouse< Function > _functions
functions
bool execMultiApps(ExecFlagType type, bool auto_advance=true)
Execute the MultiApps associated with the ExecFlagType.
bool _safe_access_tagged_matrices
Is it safe to retrieve data from tagged matrices.
Definition: SubProblem.h:1123
MaterialWarehouse _all_materials
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
void computeSystems(const ExecFlagType &type)
Do generic system computations.
void execTransfers(ExecFlagType type)
Execute the Transfers associated with the ExecFlagType.
unsigned int THREAD_ID
Definition: MooseTypes.h:237
virtual libMesh::System & system() override
Get the reference to the libMesh system.

◆ computeResidualInternal()

void FEProblemBase::computeResidualInternal ( const NumericVector< libMesh::Number > &  soln,
NumericVector< libMesh::Number > &  residual,
const std::set< TagID > &  tags 
)
virtualinherited

Form a residual vector for a set of tags.

It should not be called directly by users.

Definition at line 7646 of file FEProblemBase.C.

7649 {
7650  parallel_object_only();
7651 
7652  TIME_SECTION("computeResidualInternal", 1);
7653 
7654  try
7655  {
7657 
7659 
7660  computeResidualTags(tags);
7661 
7663  }
7664  catch (MooseException & e)
7665  {
7666  // If a MooseException propagates all the way to here, it means
7667  // that it was thrown from a MOOSE system where we do not
7668  // (currently) properly support the throwing of exceptions, and
7669  // therefore we have no choice but to error out. It may be
7670  // *possible* to handle exceptions from other systems, but in the
7671  // meantime, we don't want to silently swallow any unhandled
7672  // exceptions here.
7673  mooseError("An unhandled MooseException was raised during residual computation. Please "
7674  "contact the MOOSE team for assistance.");
7675  }
7676 }
virtual void associateVectorToTag(NumericVector< Number > &vec, TagID tag)
Associate a vector for a given tag.
Definition: SystemBase.C:982
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
virtual void computeResidualTags(const std::set< TagID > &tags)
Form multiple residual vectors and each is associated with one tag.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual void disassociateVectorFromTag(NumericVector< Number > &vec, TagID tag)
Disassociate a given vector from a given tag.
TagID residualVectorTag() const override
Provides a way for users to bail out of the current solve.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ computeResidualL2Norm() [1/3]

Real FEProblemBase::computeResidualL2Norm ( NonlinearSystemBase sys)
inherited

Computes the residual of a nonlinear system using whatever is sitting in the current solution vector then returns the L2 norm.

Definition at line 7390 of file FEProblemBase.C.

Referenced by DefaultMultiAppFixedPointConvergence::checkConvergence(), Residual::getValue(), DefaultMultiAppFixedPointConvergence::initialize(), and DefaultMultiAppFixedPointConvergence::preExecute().

7391 {
7392  _current_nl_sys = &sys;
7393  computeResidual(*sys.currentSolution(), sys.RHS(), sys.number());
7394  return sys.RHS().l2_norm();
7395 }
virtual Real l2_norm() const=0
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual const NumericVector< Number > *const & currentSolution() const override final
The solution vector that is currently being operated on.
Definition: SolverSystem.h:135
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
void computeResidual(libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual)
This function is called by Libmesh to form a residual.
virtual NumericVector< Number > & RHS()=0

◆ computeResidualL2Norm() [2/3]

Real FEProblemBase::computeResidualL2Norm ( LinearSystem sys)
inherited

Computes the residual of a linear system using whatever is sitting in the current solution vector then returns the L2 norm.

Definition at line 7398 of file FEProblemBase.C.

7399 {
7400  _current_linear_sys = &sys;
7401 
7402  // We assemble the current system to check the current residual
7405  *sys.linearImplicitSystem().rhs,
7406  /*compute fresh gradients*/ true);
7407 
7408  // Unfortunate, but we have to allocate a new vector for the residual
7409  auto residual = sys.linearImplicitSystem().rhs->clone();
7410  residual->scale(-1.0);
7411  residual->add_vector(*sys.currentSolution(), *sys.linearImplicitSystem().matrix);
7412  return residual->l2_norm();
7413 }
libMesh::LinearImplicitSystem & linearImplicitSystem()
Return a reference to the stored linear implicit system.
Definition: LinearSystem.h:125
NumericVector< Number > * rhs
virtual std::unique_ptr< NumericVector< T > > clone() const=0
virtual void computeLinearSystemSys(libMesh::LinearImplicitSystem &sys, libMesh::SparseMatrix< libMesh::Number > &system_matrix, NumericVector< libMesh::Number > &rhs, const bool compute_gradients=true)
Assemble both the right hand side and the system matrix of a given linear system. ...
virtual const NumericVector< Number > *const & currentSolution() const override final
The solution vector that is currently being operated on.
Definition: SolverSystem.h:135
LinearSystem * _current_linear_sys
The current linear system that we are solving.
SparseMatrix< Number > * matrix

◆ computeResidualL2Norm() [3/3]

Real FEProblemBase::computeResidualL2Norm ( )
virtualinherited

Computes the residual using whatever is sitting in the current solution vector then returns the L2 norm.

Returns
The L2 norm of the residual

Reimplemented in EigenProblem.

Definition at line 7416 of file FEProblemBase.C.

7417 {
7418  TIME_SECTION("computeResidualL2Norm", 2, "Computing L2 Norm of Residual");
7419 
7420  // We use sum the squared norms of the individual systems and then take the square root of it
7421  Real l2_norm = 0.0;
7422  for (auto sys : _nl)
7423  {
7424  const auto norm = computeResidualL2Norm(*sys);
7425  l2_norm += norm * norm;
7426  }
7427 
7428  for (auto sys : _linear_systems)
7429  {
7430  const auto norm = computeResidualL2Norm(*sys);
7431  l2_norm += norm * norm;
7432  }
7433 
7434  return std::sqrt(l2_norm);
7435 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
CTSub CT_OPERATOR_BINARY CTMul CTCompareLess CTCompareGreater CTCompareEqual _arg template * sqrt(_arg)) *_arg.template D< dtag >()) CT_SIMPLE_UNARY_FUNCTION(tanh
auto norm(const T &a)
virtual Real computeResidualL2Norm()
Computes the residual using whatever is sitting in the current solution vector then returns the L2 no...
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.

◆ computeResidualSys()

void FEProblemBase::computeResidualSys ( libMesh::NonlinearImplicitSystem sys,
const NumericVector< libMesh::Number > &  soln,
NumericVector< libMesh::Number > &  residual 
)
virtualinherited

This function is called by Libmesh to form a residual.

Definition at line 7438 of file FEProblemBase.C.

Referenced by NonlinearSystem::computeScalingResidual(), ComputeResidualFunctor::residual(), ComputeFDResidualFunctor::residual(), and NonlinearSystem::solve().

7441 {
7442  parallel_object_only();
7443 
7444  TIME_SECTION("computeResidualSys", 5);
7445  // Reset before residual setup, calculation & execution
7447 
7448  computeResidual(soln, residual, sys.number());
7449 }
void resetIterationOccurences()
Reset the number of solution invalid occurrences back to zero.
unsigned int number() const
SolutionInvalidity & solutionInvalidity()
Get the SolutionInvalidity for this app.
Definition: MooseApp.h:185
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
void computeResidual(libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual)
This function is called by Libmesh to form a residual.

◆ computeResidualTag()

void FEProblemBase::computeResidualTag ( const NumericVector< libMesh::Number > &  soln,
NumericVector< libMesh::Number > &  residual,
TagID  tag 
)
virtualinherited

Form a residual vector for a given tag.

Definition at line 7617 of file FEProblemBase.C.

7620 {
7621  try
7622  {
7624 
7625  _current_nl_sys->associateVectorToTag(residual, tag);
7626 
7627  computeResidualTags({tag});
7628 
7630  }
7631  catch (MooseException & e)
7632  {
7633  // If a MooseException propagates all the way to here, it means
7634  // that it was thrown from a MOOSE system where we do not
7635  // (currently) properly support the throwing of exceptions, and
7636  // therefore we have no choice but to error out. It may be
7637  // *possible* to handle exceptions from other systems, but in the
7638  // meantime, we don't want to silently swallow any unhandled
7639  // exceptions here.
7640  mooseError("An unhandled MooseException was raised during residual computation. Please "
7641  "contact the MOOSE team for assistance.");
7642  }
7643 }
virtual void associateVectorToTag(NumericVector< Number > &vec, TagID tag)
Associate a vector for a given tag.
Definition: SystemBase.C:982
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
virtual void computeResidualTags(const std::set< TagID > &tags)
Form multiple residual vectors and each is associated with one tag.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual void disassociateVectorFromTag(NumericVector< Number > &vec, TagID tag)
Disassociate a given vector from a given tag.
Provides a way for users to bail out of the current solve.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ computeResidualTags()

void FEProblemBase::computeResidualTags ( const std::set< TagID > &  tags)
virtualinherited

Form multiple residual vectors and each is associated with one tag.

Definition at line 7765 of file FEProblemBase.C.

Referenced by EigenProblem::computeResidualAB(), FEProblemBase::computeResidualInternal(), EigenProblem::computeResidualTag(), FEProblemBase::computeResidualTag(), and FEProblemBase::computeResidualType().

7766 {
7767  parallel_object_only();
7768 
7769  try
7770  {
7771  try
7772  {
7773  TIME_SECTION("computeResidualTags", 5, "Computing Residual");
7774 
7775  ADReal::do_derivatives = false;
7776 
7778 
7779  _aux->zeroVariablesForResidual();
7780 
7781  unsigned int n_threads = libMesh::n_threads();
7782 
7784 
7785  // Random interface objects
7786  for (const auto & it : _random_data_objects)
7787  it.second->updateSeeds(EXEC_LINEAR);
7788 
7790 
7792 
7793  for (unsigned int tid = 0; tid < n_threads; tid++)
7794  reinitScalars(tid);
7795 
7797 
7798  _aux->residualSetup();
7799 
7800  if (_displaced_problem)
7801  {
7803  _displaced_problem->updateMesh();
7804  if (_mortar_data->hasDisplacedObjects())
7805  updateMortarMesh();
7806  }
7807 
7808  for (THREAD_ID tid = 0; tid < n_threads; tid++)
7809  {
7812  }
7813 
7814 #ifdef MOOSE_KOKKOS_ENABLED
7816 #endif
7817 
7819 
7821 
7823 
7825 
7828  }
7829  catch (...)
7830  {
7831  handleException("computeResidualTags");
7832  }
7833  }
7834  catch (const MooseException &)
7835  {
7836  // The buck stops here, we have already handled the exception by
7837  // calling the system's stopSolve() method, it is now up to PETSc to return a
7838  // "diverged" reason during the next solve.
7839  }
7840  catch (...)
7841  {
7842  mooseError("Unexpected exception type");
7843  }
7844 
7845  resetState();
7846 }
virtual void residualSetup(THREAD_ID tid=0) const
unsigned int n_threads()
ExecFlagType _current_execute_on_flag
Current execute_on flag.
virtual void reinitScalars(const THREAD_ID tid, bool reinit_for_derivative_reordering=false) override
fills the VariableValue arrays for scalar variables from the solution vector
MooseObjectWarehouse< Moose::FunctionBase > _kokkos_functions
void computeResidualTags(const std::set< TagID > &tags)
Form multiple tag-associated residual vectors for all the given tags.
virtual void resetState()
Reset state of this object in preparation for the next evaluation.
virtual void computeUserObjects(const ExecFlagType &type, const Moose::AuxGroup &group)
Call compute methods on UserObjects.
void handleException(const std::string &calling_method)
Handle exceptions.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
bool _safe_access_tagged_vectors
Is it safe to retrieve data from tagged vectors.
Definition: SubProblem.h:1126
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
A map of objects that consume random numbers.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
const ExecFlagType EXEC_LINEAR
Definition: Moose.C:31
void residualSetup()
Calls the residualSetup function for each of the output objects.
virtual void residualSetup(THREAD_ID tid=0) const override
const ExecFlagType EXEC_PRE_DISPLACE
Definition: Moose.C:54
virtual void updateMortarMesh()
Provides a way for users to bail out of the current solve.
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data
void executeControls(const ExecFlagType &exec_type)
Performs setup and execute calls for Control objects.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::shared_ptr< DisplacedProblem > _displaced_problem
void setCurrentResidualVectorTags(const std::set< TagID > &vector_tags)
Set the current residual vector tag data structure based on the passed in tag IDs.
MooseObjectWarehouse< Function > _functions
functions
bool execMultiApps(ExecFlagType type, bool auto_advance=true)
Execute the MultiApps associated with the ExecFlagType.
MaterialWarehouse _all_materials
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
void computeSystems(const ExecFlagType &type)
Do generic system computations.
void execTransfers(ExecFlagType type)
Execute the Transfers associated with the ExecFlagType.
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ computeResidualType()

void FEProblemBase::computeResidualType ( const NumericVector< libMesh::Number > &  soln,
NumericVector< libMesh::Number > &  residual,
TagID  tag 
)
virtualinherited

Form a residual vector for a given tag and "residual" tag.

Definition at line 7679 of file FEProblemBase.C.

7682 {
7683  TIME_SECTION("computeResidualType", 5);
7684 
7685  try
7686  {
7688 
7690 
7692 
7694  }
7695  catch (MooseException & e)
7696  {
7697  // If a MooseException propagates all the way to here, it means
7698  // that it was thrown from a MOOSE system where we do not
7699  // (currently) properly support the throwing of exceptions, and
7700  // therefore we have no choice but to error out. It may be
7701  // *possible* to handle exceptions from other systems, but in the
7702  // meantime, we don't want to silently swallow any unhandled
7703  // exceptions here.
7704  mooseError("An unhandled MooseException was raised during residual computation. Please "
7705  "contact the MOOSE team for assistance.");
7706  }
7707 }
virtual void associateVectorToTag(NumericVector< Number > &vec, TagID tag)
Associate a vector for a given tag.
Definition: SystemBase.C:982
void setSolution(const NumericVector< Number > &soln)
Set the solution to a given vector.
Definition: SolverSystem.C:67
virtual void computeResidualTags(const std::set< TagID > &tags)
Form multiple residual vectors and each is associated with one tag.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
virtual void disassociateVectorFromTag(NumericVector< Number > &vec, TagID tag)
Disassociate a given vector from a given tag.
TagID residualVectorTag() const override
Provides a way for users to bail out of the current solve.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ computeSystems()

void FEProblemBase::computeSystems ( const ExecFlagType type)
protectedinherited

Do generic system computations.

Definition at line 9977 of file FEProblemBase.C.

Referenced by FEProblemBase::computeBounds(), EigenProblem::computeJacobianBlocks(), FEProblemBase::computeJacobianBlocks(), FEProblemBase::computeJacobianTags(), FEProblemBase::computeLinearSystemTags(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), and FEProblemBase::execute().

9978 {
9979  // When performing an adjoint solve in the optimization module, the current solver system is the
9980  // adjoint. However, the adjoint solve requires having accurate time derivative calculations for
9981  // the forward system. The cleanest way to handle such uses is just to compute the time
9982  // derivatives for all solver systems instead of trying to guess which ones we need and don't need
9983  for (auto & solver_sys : _solver_systems)
9984  solver_sys->compute(type);
9985 
9986  _aux->compute(type);
9987 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93

◆ computeTransposeNullSpace()

void FEProblemBase::computeTransposeNullSpace ( libMesh::NonlinearImplicitSystem sys,
std::vector< NumericVector< libMesh::Number > *> &  sp 
)
virtualinherited

Definition at line 8227 of file FEProblemBase.C.

Referenced by Moose::compute_transpose_nullspace().

8229 {
8230  mooseAssert(_current_nl_sys && (sys.number() == _current_nl_sys->number()),
8231  "I expect these system numbers to be the same");
8232  sp.clear();
8233  for (unsigned int i = 0; i < subspaceDim("TransposeNullSpace"); ++i)
8234  {
8235  std::stringstream postfix;
8236  postfix << "_" << i;
8237  sp.push_back(&_current_nl_sys->getVector("TransposeNullSpace" + postfix.str()));
8238  }
8239 }
unsigned int subspaceDim(const std::string &prefix) const
Dimension of the subspace spanned by vectors with a given prefix.
unsigned int number() const
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
virtual NumericVector< Number > & getVector(const std::string &name)
Get a raw NumericVector by name.
Definition: SystemBase.C:934

◆ computeUserObjectByName()

void FEProblemBase::computeUserObjectByName ( const ExecFlagType type,
const Moose::AuxGroup group,
const std::string &  name 
)
virtualinherited

Compute an user object with the given name.

Definition at line 5303 of file FEProblemBase.C.

Referenced by MultiAppConservativeTransfer::adjustTransferredSolution(), MultiAppConservativeTransfer::adjustTransferredSolutionNearestPoint(), MultiAppPostprocessorToAuxScalarTransfer::execute(), MultiAppPostprocessorTransfer::execute(), MultiAppGeneralFieldUserObjectTransfer::execute(), MultiAppGeneralFieldFunctorTransfer::execute(), MultiAppUserObjectTransfer::execute(), MultiAppVectorPostprocessorTransfer::executeToMultiapp(), and MultiAppConservativeTransfer::postExecute().

5306 {
5307  const auto old_exec_flag = _current_execute_on_flag;
5309 
5310  std::set<int> execution_groups;
5311 
5312 #ifdef MOOSE_KOKKOS_ENABLED
5313  TheWarehouse::Query kokkos_query =
5314  getUOQuery("KokkosUserObject", type, group).condition<AttribName>(name);
5315  getUOExecutionGroups(kokkos_query, execution_groups);
5316 #endif
5317 
5318  TheWarehouse::Query query = getUOQuery("UserObject", type, group).condition<AttribName>(name);
5319  getUOExecutionGroups(query, execution_groups);
5320 
5321  for (const auto execution_group : execution_groups)
5322  {
5323 #ifdef MOOSE_KOKKOS_ENABLED
5325  type, kokkos_query.clone().condition<AttribExecutionOrderGroup>(execution_group));
5326 #endif
5327 
5329  query.clone().condition<AttribExecutionOrderGroup>(execution_group));
5330  }
5331 
5332  _current_execute_on_flag = old_exec_flag;
5333 }
ExecFlagType _current_execute_on_flag
Current execute_on flag.
QueryCache is a convenient way to construct and pass around (possible partially constructed) warehous...
Definition: TheWarehouse.h:209
void computeUserObjectsInternal(const ExecFlagType &type, TheWarehouse::Query &query)
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
void computeKokkosUserObjectsInternal(const ExecFlagType &type, TheWarehouse::Query &query)
void getUOExecutionGroups(TheWarehouse::Query &query, std::set< int > &execution_groups) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
QueryCache clone() const
clone creates and returns an independent copy of the query in its current state.
Definition: TheWarehouse.h:293
query_obj query
TheWarehouse::Query getUOQuery(const std::string &system, const ExecFlagType &type, const Moose::AuxGroup &group) const
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ computeUserObjects()

void FEProblemBase::computeUserObjects ( const ExecFlagType type,
const Moose::AuxGroup group 
)
virtualinherited

Call compute methods on UserObjects.

Definition at line 5336 of file FEProblemBase.C.

Referenced by FEProblemBase::computeJacobianTags(), FEProblemBase::computeLinearSystemTags(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), FEProblemBase::execute(), and FEProblemBase::initialSetup().

5337 {
5338  std::set<int> execution_groups;
5339 
5340 #ifdef MOOSE_KOKKOS_ENABLED
5341  TheWarehouse::Query kokkos_query = getUOQuery("KokkosUserObject", type, group);
5342  getUOExecutionGroups(kokkos_query, execution_groups);
5343 #endif
5344 
5345  TheWarehouse::Query query = getUOQuery("UserObject", type, group);
5346  getUOExecutionGroups(query, execution_groups);
5347 
5348  for (const auto execution_group : execution_groups)
5349  {
5350 #ifdef MOOSE_KOKKOS_ENABLED
5352  type, kokkos_query.clone().condition<AttribExecutionOrderGroup>(execution_group));
5353 #endif
5354 
5356  query.clone().condition<AttribExecutionOrderGroup>(execution_group));
5357  }
5358 }
QueryCache is a convenient way to construct and pass around (possible partially constructed) warehous...
Definition: TheWarehouse.h:209
void computeUserObjectsInternal(const ExecFlagType &type, TheWarehouse::Query &query)
void computeKokkosUserObjectsInternal(const ExecFlagType &type, TheWarehouse::Query &query)
void getUOExecutionGroups(TheWarehouse::Query &query, std::set< int > &execution_groups) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
QueryCache clone() const
clone creates and returns an independent copy of the query in its current state.
Definition: TheWarehouse.h:293
query_obj query
TheWarehouse::Query getUOQuery(const std::string &system, const ExecFlagType &type, const Moose::AuxGroup &group) const
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ computeUserObjectsInternal()

void FEProblemBase::computeUserObjectsInternal ( const ExecFlagType type,
TheWarehouse::Query query 
)
protectedinherited

Definition at line 5361 of file FEProblemBase.C.

Referenced by FEProblemBase::computeUserObjectByName(), and FEProblemBase::computeUserObjects().

5362 {
5363  try
5364  {
5365  TIME_SECTION("computeUserObjects", 1, "Computing User Objects");
5366 
5367  std::vector<GeneralUserObject *> genobjs;
5368  query.clone().condition<AttribInterfaces>(Interfaces::GeneralUserObject).queryInto(genobjs);
5369 
5370  std::vector<UserObject *> userobjs;
5371  query.clone()
5375  .queryInto(userobjs);
5376 
5377  std::vector<UserObject *> tgobjs;
5378  query.clone()
5380  .queryInto(tgobjs);
5381 
5382  std::vector<UserObject *> nodal;
5383  query.clone().condition<AttribInterfaces>(Interfaces::NodalUserObject).queryInto(nodal);
5384 
5385  std::vector<MortarUserObject *> mortar;
5386  query.clone().condition<AttribInterfaces>(Interfaces::MortarUserObject).queryInto(mortar);
5387 
5388  if (userobjs.empty() && genobjs.empty() && tgobjs.empty() && nodal.empty() && mortar.empty())
5389  return;
5390 
5391  // Start the timer here since we have at least one active user object
5392  std::string compute_uo_tag = "computeUserObjects(" + Moose::stringify(type) + ")";
5393 
5394  // Perform Residual/Jacobian setups
5395  if (type == EXEC_LINEAR)
5396  {
5397  for (auto obj : userobjs)
5398  obj->residualSetup();
5399  for (auto obj : nodal)
5400  obj->residualSetup();
5401  for (auto obj : mortar)
5402  obj->residualSetup();
5403  for (auto obj : tgobjs)
5404  obj->residualSetup();
5405  for (auto obj : genobjs)
5406  obj->residualSetup();
5407  }
5408  else if (type == EXEC_NONLINEAR)
5409  {
5410  for (auto obj : userobjs)
5411  obj->jacobianSetup();
5412  for (auto obj : nodal)
5413  obj->jacobianSetup();
5414  for (auto obj : mortar)
5415  obj->jacobianSetup();
5416  for (auto obj : tgobjs)
5417  obj->jacobianSetup();
5418  for (auto obj : genobjs)
5419  obj->jacobianSetup();
5420  }
5421 
5422  for (auto obj : userobjs)
5423  obj->initialize();
5424 
5425  // Execute Side/InternalSide/Interface/Elemental/DomainUserObjects
5426  if (!userobjs.empty())
5427  {
5428  // non-nodal user objects have to be run separately before the nodal user objects run
5429  // because some nodal user objects (NodalNormal related) depend on elemental user objects
5430  // :-(
5431  ComputeUserObjectsThread cppt(*this, query);
5433 
5434  // There is one instance in rattlesnake where an elemental user object's finalize depends
5435  // on a side user object having been finalized first :-(
5442  }
5443 
5444  // if any elemental user object may have written to variables we need to close the aux solution
5445  for (const auto & uo : userobjs)
5446  if (auto euo = dynamic_cast<const ElementUserObject *>(uo);
5447  euo && euo->hasWritableCoupledVariables())
5448  {
5449  _aux->solution().close();
5450  _aux->system().update();
5451  break;
5452  }
5453 
5454  // Execute NodalUserObjects
5455  // BISON has an axial reloc elemental user object that has a finalize func that depends on a
5456  // nodal user object's prev value. So we can't initialize this until after elemental objects
5457  // have been finalized :-(
5458  for (auto obj : nodal)
5459  obj->initialize();
5460  if (query.clone().condition<AttribInterfaces>(Interfaces::NodalUserObject).count() > 0)
5461  {
5462  ComputeNodalUserObjectsThread cnppt(*this, query);
5465  }
5466 
5467  // if any nodal user object may have written to variables we need to close the aux solution
5468  for (const auto & uo : nodal)
5469  if (auto nuo = dynamic_cast<const NodalUserObject *>(uo);
5470  nuo && nuo->hasWritableCoupledVariables())
5471  {
5472  _aux->solution().close();
5473  _aux->system().update();
5474  break;
5475  }
5476 
5477  // Execute MortarUserObjects
5478  {
5479  for (auto obj : mortar)
5480  obj->initialize();
5481  if (!mortar.empty())
5482  {
5483  auto create_and_run_mortar_functors = [this, type, &mortar](const bool displaced)
5484  {
5485  // go over mortar interfaces and construct functors
5486  const auto & mortar_interfaces = getMortarInterfaces(displaced);
5487  for (const auto & [primary_secondary_boundary_pair, interface_config] : mortar_interfaces)
5488  {
5489  auto mortar_uos_to_execute =
5490  getMortarUserObjects(primary_secondary_boundary_pair.first,
5491  primary_secondary_boundary_pair.second,
5492  displaced,
5493  mortar);
5494 
5495  auto * const subproblem = displaced
5496  ? static_cast<SubProblem *>(_displaced_problem.get())
5497  : static_cast<SubProblem *>(this);
5498  MortarUserObjectThread muot(mortar_uos_to_execute,
5499  *interface_config.amg,
5500  *subproblem,
5501  *this,
5502  displaced,
5503  subproblem->assembly(0, 0));
5504 
5505  muot();
5506  }
5507  };
5508 
5509  create_and_run_mortar_functors(false);
5510  if (_displaced_problem)
5511  create_and_run_mortar_functors(true);
5512  }
5513  for (auto obj : mortar)
5514  obj->finalize();
5515  }
5516 
5517  // Execute threaded general user objects
5518  for (auto obj : tgobjs)
5519  obj->initialize();
5520  std::vector<GeneralUserObject *> tguos_zero;
5521  query.clone()
5522  .condition<AttribThread>(0)
5523  .condition<AttribInterfaces>(Interfaces::ThreadedGeneralUserObject)
5524  .queryInto(tguos_zero);
5525  for (auto obj : tguos_zero)
5526  {
5527  std::vector<GeneralUserObject *> tguos;
5528  auto q = query.clone()
5529  .condition<AttribName>(obj->name())
5530  .condition<AttribInterfaces>(Interfaces::ThreadedGeneralUserObject);
5531  q.queryInto(tguos);
5532 
5534 
5535  // Force one thread per ThreadedGeneralUserObject via grainsize
5537  tguos.end(),
5538  /*grainsize=*/1),
5539  ctguot);
5540  joinAndFinalize(q);
5541  }
5542 
5543  // Execute general user objects
5545  }
5546  catch (...)
5547  {
5548  handleException("computeUserObjectsInternal");
5549  }
5550 }
void joinAndFinalize(TheWarehouse::Query query, bool isgen=false)
void parallel_reduce(const Range &range, Body &body, const Partitioner &, unsigned int n_threads=libMesh::n_threads())
Thread to compute threaded general user objects.
const libMesh::ConstElemRange & getCurrentAlgebraicElementRange()
These are the element and nodes that contribute to the jacobian and residual for this local processor...
const libMesh::ConstNodeRange & getCurrentAlgebraicNodeRange()
void handleException(const std::string &calling_method)
Handle exceptions.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::vector< MortarUserObject * > getMortarUserObjects(BoundaryID primary_boundary_id, BoundaryID secondary_boundary_id, bool displaced, const std::vector< MortarUserObject *> &mortar_uo_superset)
Helper for getting mortar objects corresponding to primary boundary ID, secondary boundary ID...
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
StoredRange< std::vector< GeneralUserObject * >::iterator, GeneralUserObject * > GeneralUserObjectRange
const ExecFlagType EXEC_LINEAR
Definition: Moose.C:31
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
query_obj query
const ExecFlagType EXEC_NONLINEAR
Definition: Moose.C:33
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78
Class for threaded computation of UserObjects.
std::shared_ptr< DisplacedProblem > _displaced_problem
const std::unordered_map< std::pair< BoundaryID, BoundaryID >, MortarInterfaceConfig > & getMortarInterfaces(bool on_displaced) const

◆ computingNonlinearResid() [1/4]

bool SubProblem::computingNonlinearResid ( ) const
inlineinherited

Returns true if the problem is in the process of computing the nonlinear residual.

Definition at line 715 of file SubProblem.h.

bool _computing_nonlinear_residual
Whether the non-linear residual is being evaluated.
Definition: SubProblem.h:1117

◆ computingNonlinearResid() [2/4]

bool SubProblem::computingNonlinearResid
inlineinherited

Returns true if the problem is in the process of computing the nonlinear residual.

Definition at line 715 of file SubProblem.h.

bool _computing_nonlinear_residual
Whether the non-linear residual is being evaluated.
Definition: SubProblem.h:1117

◆ computingNonlinearResid() [3/4]

virtual void SubProblem::computingNonlinearResid
inlineinherited

Set whether or not the problem is in the process of computing the nonlinear residual.

Definition at line 720 of file SubProblem.h.

721  {
722  _computing_nonlinear_residual = computing_nonlinear_residual;
723  }
bool _computing_nonlinear_residual
Whether the non-linear residual is being evaluated.
Definition: SubProblem.h:1117

◆ computingNonlinearResid() [4/4]

void FEProblemBase::computingNonlinearResid ( bool  computing_nonlinear_residual)
finalvirtualinherited

Set whether or not the problem is in the process of computing the nonlinear residual.

Reimplemented from SubProblem.

Definition at line 9612 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeResidualInternal(), NonlinearSystemBase::computeScaling(), ComputeFDResidualFunctor::residual(), ComputeResidualFunctor::residual(), and ComputeResidualAndJacobian::residual_and_jacobian().

9613 {
9614  parallel_object_only();
9615 
9616  if (_displaced_problem)
9617  _displaced_problem->computingNonlinearResid(computing_nonlinear_residual);
9618  _computing_nonlinear_residual = computing_nonlinear_residual;
9619 }
bool _computing_nonlinear_residual
Whether the non-linear residual is being evaluated.
Definition: SubProblem.h:1117
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ computingPreSMOResidual()

bool FEProblemBase::computingPreSMOResidual ( const unsigned int  nl_sys_num) const
overridevirtualinherited

Returns true if the problem is in the process of computing it's initial residual.

Returns
Whether or not the problem is currently computing the initial residual.

Implements SubProblem.

Definition at line 7152 of file FEProblemBase.C.

Referenced by DisplacedProblem::computingPreSMOResidual().

7153 {
7154  return _nl[nl_sys_num]->computingPreSMOResidual();
7155 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ computingScalingJacobian() [1/2]

void FEProblemBase::computingScalingJacobian ( bool  computing_scaling_jacobian)
inlineinherited

Setter for whether we're computing the scaling jacobian.

Definition at line 2796 of file FEProblemBase.h.

Referenced by ComputeJacobianThread::compute(), SolverSystem::compute(), NonlinearSystemBase::computeJacobianInternal(), NonlinearSystemBase::computeScaling(), and DisplacedProblem::computingScalingJacobian().

2797  {
2798  _computing_scaling_jacobian = computing_scaling_jacobian;
2799  }
bool _computing_scaling_jacobian
Flag used to indicate whether we are computing the scaling Jacobian.

◆ computingScalingJacobian() [2/2]

bool FEProblemBase::computingScalingJacobian ( ) const
inlinefinaloverridevirtualinherited

Getter for whether we're computing the scaling jacobian.

Implements SubProblem.

Definition at line 2801 of file FEProblemBase.h.

2801 { return _computing_scaling_jacobian; }
bool _computing_scaling_jacobian
Flag used to indicate whether we are computing the scaling Jacobian.

◆ computingScalingResidual() [1/2]

void FEProblemBase::computingScalingResidual ( bool  computing_scaling_residual)
inlineinherited

Setter for whether we're computing the scaling residual.

Definition at line 2806 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::computeResidualInternal(), NonlinearSystemBase::computeResidualTags(), NonlinearSystemBase::computeScaling(), and DisplacedProblem::computingScalingResidual().

2807  {
2808  _computing_scaling_residual = computing_scaling_residual;
2809  }
bool _computing_scaling_residual
Flag used to indicate whether we are computing the scaling Residual.

◆ computingScalingResidual() [2/2]

bool FEProblemBase::computingScalingResidual ( ) const
inlinefinaloverridevirtualinherited
Returns
whether we are currently computing a residual for automatic scaling purposes

Implements SubProblem.

Definition at line 2814 of file FEProblemBase.h.

2814 { return _computing_scaling_residual; }
bool _computing_scaling_residual
Flag used to indicate whether we are computing the scaling Residual.

◆ connectControllableParams()

void MooseBase::connectControllableParams ( const std::string &  parameter,
const std::string &  object_type,
const std::string &  object_name,
const std::string &  object_parameter 
) const
inherited

Connect controllable parameter of this action with the controllable parameters of the objects added by this action.

Parameters
parameterName of the controllable parameter of this action
object_typeType of the object added by this action.
object_nameName of the object added by this action.
object_parameterName of the parameter of the object.

Definition at line 77 of file MooseBase.C.

81 {
82  auto & factory = _app.getFactory();
83  auto & ip_warehouse = _app.getInputParameterWarehouse();
84 
85  MooseObjectParameterName primary_name(uniqueName(), parameter);
86  const auto base_type = factory.getValidParams(object_type).getBase();
87  MooseObjectParameterName secondary_name(base_type, object_name, object_parameter);
88  ip_warehouse.addControllableParameterConnection(primary_name, secondary_name);
89 
90  const auto & tags = _pars.get<std::vector<std::string>>("control_tags");
91  for (const auto & tag : tags)
92  {
93  if (!tag.empty())
94  {
95  // Only adds the parameter with the different control tags if the derived class
96  // properly registers the parameter to its own syntax
97  MooseObjectParameterName tagged_name(tag, name(), parameter);
98  ip_warehouse.addControllableParameterConnection(
99  tagged_name, secondary_name, /*error_on_empty=*/false);
100  }
101  }
102 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
InputParameterWarehouse & getInputParameterWarehouse()
Get the InputParameterWarehouse for MooseObjects.
Definition: MooseApp.C:2867
MooseObjectName uniqueName() const
Definition: MooseBase.C:69
Factory & getFactory()
Retrieve a writable reference to the Factory associated with this App.
Definition: MooseApp.h:407
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
A class for storing an input parameter name.

◆ console()

const ConsoleStream& Problem::console ( ) const
inlineinherited

Return console handle.

Definition at line 48 of file Problem.h.

Referenced by Moose::SlepcSupport::mooseSlepcEPSMonitor(), ComputeMarkerThread::printBlockExecutionInformation(), ComputeDiracThread::printBlockExecutionInformation(), ComputeIndicatorThread::printBlockExecutionInformation(), ComputeUserObjectsThread::printBlockExecutionInformation(), ComputeLinearFVElementalThread::printBlockExecutionInformation(), ComputeLinearFVFaceThread::printBlockExecutionInformation(), NonlinearThread::printBlockExecutionInformation(), NonlinearThread::printBoundaryExecutionInformation(), ComputeFVInitialConditionThread::printGeneralExecutionInformation(), ComputeInitialConditionThread::printGeneralExecutionInformation(), ComputeNodalUserObjectsThread::printGeneralExecutionInformation(), ComputeNodalKernelBcsThread::printGeneralExecutionInformation(), ComputeNodalKernelBCJacobiansThread::printGeneralExecutionInformation(), ComputeElemDampingThread::printGeneralExecutionInformation(), ComputeNodalKernelsThread::printGeneralExecutionInformation(), ComputeNodalDampingThread::printGeneralExecutionInformation(), ComputeMarkerThread::printGeneralExecutionInformation(), ComputeDiracThread::printGeneralExecutionInformation(), ComputeIndicatorThread::printGeneralExecutionInformation(), ComputeNodalKernelJacobiansThread::printGeneralExecutionInformation(), ComputeThreadedGeneralUserObjectsThread::printGeneralExecutionInformation(), ComputeUserObjectsThread::printGeneralExecutionInformation(), ComputeLinearFVElementalThread::printGeneralExecutionInformation(), ComputeLinearFVFaceThread::printGeneralExecutionInformation(), and NonlinearThread::printGeneralExecutionInformation().

48 { return _console; }
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.

◆ constJacobian()

bool FEProblemBase::constJacobian ( ) const
inherited

Returns _const_jacobian (whether a MOOSE object has specified that the Jacobian is the same as the previous time it was computed)

Definition at line 9461 of file FEProblemBase.C.

Referenced by Moose::SlepcSupport::moosePetscSNESFormMatricesTags(), and Moose::SlepcSupport::moosePetscSNESFormMatrixTag().

9462 {
9463  return _const_jacobian;
9464 }
bool _const_jacobian
true if the Jacobian is constant

◆ converged()

virtual bool SubProblem::converged ( const unsigned int  sys_num)
inlinevirtualinherited

Eventually we want to convert this virtual over to taking a solver system number argument.

We will have to first convert apps to use solverSystemConverged, and then once that is done, we can change this signature. Then we can go through the apps again and convert back to this changed API

Definition at line 113 of file SubProblem.h.

Referenced by FEProblemBase::initialSetup(), EigenExecutionerBase::inversePowerIteration(), EigenExecutionerBase::nonlinearSolve(), FEProblemSolve::solve(), LStableDirk2::solve(), LStableDirk3::solve(), ImplicitMidpoint::solve(), ExplicitTVDRK2::solve(), AStableDirk4::solve(), LStableDirk4::solve(), ExplicitRK2::solve(), DisplacedProblem::solverSystemConverged(), SubProblem::solverSystemConverged(), and AB2PredictorCorrector::step().

113 { return solverSystemConverged(sys_num); }
virtual bool solverSystemConverged(const unsigned int sys_num)
Definition: SubProblem.h:100

◆ coordTransform()

MooseAppCoordTransform & FEProblemBase::coordTransform ( )
inherited
Returns
the coordinate transformation object that describes how to transform this problem's coordinate system into the canonical/reference coordinate system

Definition at line 9848 of file FEProblemBase.C.

9849 {
9850  return mesh().coordTransform();
9851 }
MooseAppCoordTransform & coordTransform()
Definition: MooseMesh.h:2064
virtual MooseMesh & mesh() override

◆ copySolutionsBackwards()

void FEProblemBase::copySolutionsBackwards ( )
virtualinherited

Definition at line 7158 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup().

7159 {
7160  TIME_SECTION("copySolutionsBackwards", 3, "Copying Solutions Backward");
7161 
7162  for (auto & sys : _solver_systems)
7163  sys->copySolutionsBackwards();
7164  _aux->copySolutionsBackwards();
7165 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ coupling()

Moose::CouplingType FEProblemBase::coupling ( ) const
inlineinherited

Definition at line 196 of file FEProblemBase.h.

Referenced by DiffusionLHDGAssemblyHelper::checkCoupling(), and NonlinearSystemBase::computeJacobianInternal().

196 { return _coupling; }
Moose::CouplingType _coupling
Type of variable coupling.

◆ couplingEntries()

std::vector< std::pair< MooseVariableFieldBase *, MooseVariableFieldBase * > > & FEProblemBase::couplingEntries ( const THREAD_ID  tid,
const unsigned int  nl_sys_num 
)
inherited

◆ couplingMatrix()

const libMesh::CouplingMatrix * FEProblemBase::couplingMatrix ( const unsigned int  nl_sys_num) const
inlineoverridevirtualinherited

The coupling matrix defining what blocks exist in the preconditioning matrix.

Implements SubProblem.

Definition at line 3809 of file FEProblemBase.h.

Referenced by DiffusionLHDGAssemblyHelper::checkCoupling(), DisplacedProblem::couplingMatrix(), and DisplacedProblem::init().

3810 {
3811  return _cm[i].get();
3812 }
std::vector< std::unique_ptr< libMesh::CouplingMatrix > > _cm
Coupling matrix for variables.

◆ createMortarInterface()

void FEProblemBase::createMortarInterface ( const std::pair< BoundaryID, BoundaryID > &  primary_secondary_boundary_pair,
const std::pair< SubdomainID, SubdomainID > &  primary_secondary_subdomain_pair,
bool  on_displaced,
bool  periodic,
const bool  debug,
const bool  correct_edge_dropping,
const Real  minimum_projection_angle,
const Mortar3DSubpatchPlane  mortar_3d_subpatch_plane,
const MooseEnum triangulation,
const bool  triangulate_triangles,
const Mortar3DQuadraturePointMapping  mortar_3d_qp_mapping = Mortar3DQuadraturePointMapping::NORMAL_PROJECTION 
)
inherited

Definition at line 8402 of file FEProblemBase.C.

8414 {
8415  _has_mortar = true;
8416 
8417  if (on_displaced)
8418  return _mortar_data->createMortarInterface(primary_secondary_boundary_pair,
8419  primary_secondary_subdomain_pair,
8421  on_displaced,
8422  periodic,
8423  debug,
8424  correct_edge_dropping,
8425  minimum_projection_angle,
8426  mortar_3d_subpatch_plane,
8427  triangulation,
8428  triangulate_triangles,
8429  mortar_3d_qp_mapping);
8430  else
8431  return _mortar_data->createMortarInterface(primary_secondary_boundary_pair,
8432  primary_secondary_subdomain_pair,
8433  *this,
8434  on_displaced,
8435  periodic,
8436  debug,
8437  correct_edge_dropping,
8438  minimum_projection_angle,
8439  mortar_3d_subpatch_plane,
8440  triangulation,
8441  triangulate_triangles,
8442  mortar_3d_qp_mapping);
8443 }
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data
std::shared_ptr< DisplacedProblem > _displaced_problem
bool _has_mortar
Whether the simulation requires mortar coupling.

◆ createQRules()

void FEProblemBase::createQRules ( libMesh::QuadratureType  type,
libMesh::Order  order,
libMesh::Order  volume_order = libMesh::INVALID_ORDER,
libMesh::Order  face_order = libMesh::INVALID_ORDER,
SubdomainID  block = Moose::ANY_BLOCK_ID,
bool  allow_negative_qweights = true 
)
virtualinherited

Definition at line 6578 of file FEProblemBase.C.

6584 {
6585  if (order == INVALID_ORDER)
6586  {
6587  // automatically determine the integration order
6588  order = _solver_systems[0]->getMinQuadratureOrder();
6589  for (const auto i : make_range(std::size_t(1), _solver_systems.size()))
6590  if (order < _solver_systems[i]->getMinQuadratureOrder())
6591  order = _solver_systems[i]->getMinQuadratureOrder();
6592  if (order < _aux->getMinQuadratureOrder())
6593  order = _aux->getMinQuadratureOrder();
6594  }
6595 
6596  if (volume_order == INVALID_ORDER)
6597  volume_order = order;
6598 
6599  if (face_order == INVALID_ORDER)
6600  face_order = order;
6601 
6602  for (unsigned int tid = 0; tid < libMesh::n_threads(); ++tid)
6603  for (const auto i : index_range(_solver_systems))
6604  _assembly[tid][i]->createQRules(
6605  type, order, volume_order, face_order, block, allow_negative_qweights);
6606 
6607  if (_displaced_problem)
6608  _displaced_problem->createQRules(
6609  type, order, volume_order, face_order, block, allow_negative_qweights);
6610 
6611  updateMaxQps();
6612 }
unsigned int n_threads()
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
virtual void createQRules(libMesh::QuadratureType type, libMesh::Order order, libMesh::Order volume_order=libMesh::INVALID_ORDER, libMesh::Order face_order=libMesh::INVALID_ORDER, SubdomainID block=Moose::ANY_BLOCK_ID, bool allow_negative_qweights=true)
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
IntRange< T > make_range(T beg, T end)
std::shared_ptr< DisplacedProblem > _displaced_problem
auto index_range(const T &sizable)

◆ createTagMatrices()

void FEProblemBase::createTagMatrices ( CreateTaggedMatrixKey  )
inherited

Definition at line 714 of file FEProblemBase.C.

715 {
716  auto & matrices = getParam<std::vector<std::vector<TagName>>>("extra_tag_matrices");
717  for (const auto sys_num : index_range(matrices))
718  for (auto & matrix : matrices[sys_num])
719  {
720  auto tag = addMatrixTag(matrix);
721  _solver_systems[sys_num]->addMatrix(tag);
722  }
723 
724  for (auto & sys : _solver_systems)
725  sys->sizeVariableMatrixData();
726  _aux->sizeVariableMatrixData();
727 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
virtual TagID addMatrixTag(TagName tag_name)
Create a Tag.
Definition: SubProblem.C:312
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
auto index_range(const T &sizable)

◆ createTagSolutions()

void FEProblemBase::createTagSolutions ( )
protectedinherited

Create extra tagged solution vectors.

Definition at line 730 of file FEProblemBase.C.

Referenced by DumpObjectsProblem::DumpObjectsProblem(), EigenProblem::EigenProblem(), ExternalProblem::ExternalProblem(), and FEProblem::FEProblem().

731 {
732  for (auto & vector : getParam<std::vector<TagName>>("extra_tag_solutions"))
733  {
734  auto tag = addVectorTag(vector, Moose::VECTOR_TAG_SOLUTION);
735  for (auto & sys : _solver_systems)
736  sys->addVector(tag, false, libMesh::GHOSTED);
737  _aux->addVector(tag, false, libMesh::GHOSTED);
738  }
739 
741  {
742  // We'll populate the zeroth state of the nonlinear iterations with the current solution for
743  // ease of use in doing things like copying solutions backwards. We're just storing pointers in
744  // the solution states containers so populating the zeroth state does not cost us the memory of
745  // a new vector
747  }
748 
750  for (auto & sys : _solver_systems)
751  sys->associateVectorToTag(*sys->system().current_local_solution.get(), tag);
752  _aux->associateVectorToTag(*_aux->system().current_local_solution.get(), tag);
753 }
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
Definition: MooseBase.h:406
virtual TagID addVectorTag(const TagName &tag_name, const Moose::VectorTagType type=Moose::VECTOR_TAG_RESIDUAL)
Create a Tag.
Definition: SubProblem.C:93
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
bool _previous_nl_solution_required
Indicates we need to save the previous NL iteration variable values.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void needSolutionState(unsigned int oldest_needed, Moose::SolutionIterationType iteration_type)
Declare that we need up to old (1) or older (2) solution states for a given type of iteration...
const TagName SOLUTION_TAG
Definition: MooseTypes.C:25

◆ createTagVectors()

void FEProblemBase::createTagVectors ( )
protectedinherited

Create extra tagged vectors and matrices.

Definition at line 692 of file FEProblemBase.C.

Referenced by DumpObjectsProblem::DumpObjectsProblem(), EigenProblem::EigenProblem(), ExternalProblem::ExternalProblem(), and FEProblem::FEProblem().

693 {
694  // add vectors and their tags to system
695  auto & vectors = getParam<std::vector<std::vector<TagName>>>("extra_tag_vectors");
696  for (const auto sys_num : index_range(vectors))
697  for (auto & vector : vectors[sys_num])
698  {
699  auto tag = addVectorTag(vector);
700  _solver_systems[sys_num]->addVector(tag, false, libMesh::GHOSTED);
701  }
702 
703  auto & not_zeroed_vectors = getParam<std::vector<std::vector<TagName>>>("not_zeroed_tag_vectors");
704  for (const auto sys_num : index_range(not_zeroed_vectors))
705  for (auto & vector : not_zeroed_vectors[sys_num])
706  {
707  auto tag = addVectorTag(vector);
708  _solver_systems[sys_num]->addVector(tag, false, GHOSTED);
710  }
711 }
virtual TagID addVectorTag(const TagName &tag_name, const Moose::VectorTagType type=Moose::VECTOR_TAG_RESIDUAL)
Create a Tag.
Definition: SubProblem.C:93
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
auto index_range(const T &sizable)
void addNotZeroedVectorTag(const TagID tag)
Adds a vector tag to the list of vectors that will not be zeroed when other tagged vectors are...
Definition: SubProblem.C:150

◆ currentLinearSysNum()

unsigned int FEProblemBase::currentLinearSysNum ( ) const
overridevirtualinherited
Returns
the current linear system number

Implements SubProblem.

Definition at line 9865 of file FEProblemBase.C.

Referenced by DisplacedProblem::currentLinearSysNum().

9866 {
9867  // If we don't have linear systems this should be an invalid number
9868  unsigned int current_linear_sys_num = libMesh::invalid_uint;
9869  if (_linear_systems.size())
9870  current_linear_sys_num = currentLinearSystem().number();
9871 
9872  return current_linear_sys_num;
9873 }
const unsigned int invalid_uint
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
LinearSystem & currentLinearSystem()
Get a non-constant reference to the current linear system.
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.

◆ currentLinearSystem() [1/2]

LinearSystem & FEProblemBase::currentLinearSystem ( )
inlineinherited

Get a non-constant reference to the current linear system.

Definition at line 3777 of file FEProblemBase.h.

Referenced by FEProblemBase::currentLinearSysNum(), and Moose::PetscSupport::petscLinearConverged().

3778 {
3779  mooseAssert(_current_linear_sys, "The linear system is not currently set");
3780  return *_current_linear_sys;
3781 }
LinearSystem * _current_linear_sys
The current linear system that we are solving.

◆ currentLinearSystem() [2/2]

const LinearSystem & FEProblemBase::currentLinearSystem ( ) const
inlineinherited

Get a constant reference to the current linear system.

Definition at line 3784 of file FEProblemBase.h.

3785 {
3786  mooseAssert(_current_linear_sys, "The linear system is not currently set");
3787  return *_current_linear_sys;
3788 }
LinearSystem * _current_linear_sys
The current linear system that we are solving.

◆ currentlyComputingJacobian()

const bool& SubProblem::currentlyComputingJacobian ( ) const
inlineinherited

Returns true if the problem is in the process of computing the Jacobian.

Definition at line 692 of file SubProblem.h.

Referenced by PenetrationLocator::detectPenetration(), ComputeUserObjectsThread::onBoundary(), ComputeUserObjectsThread::onElement(), ComputeUserObjectsThread::printBlockExecutionInformation(), SubProblem::reinitElemFaceRef(), and NEML2Utils::shouldCompute().

bool _currently_computing_jacobian
Flag to determine whether the problem is currently computing Jacobian.
Definition: SubProblem.h:1111

◆ currentlyComputingResidual() [1/2]

const bool& SubProblem::currentlyComputingResidual ( ) const
inlineinherited

Returns true if the problem is in the process of computing the residual.

Definition at line 728 of file SubProblem.h.

bool _currently_computing_residual
Whether the residual is being evaluated.
Definition: SubProblem.h:1120

◆ currentlyComputingResidual() [2/2]

const bool& SubProblem::currentlyComputingResidual
inlineinherited

Returns true if the problem is in the process of computing the residual.

Definition at line 728 of file SubProblem.h.

bool _currently_computing_residual
Whether the residual is being evaluated.
Definition: SubProblem.h:1120

◆ currentlyComputingResidualAndJacobian()

const bool & SubProblem::currentlyComputingResidualAndJacobian ( ) const
inlineinherited

Returns true if the problem is in the process of computing the residual and the Jacobian.

Definition at line 1505 of file SubProblem.h.

Referenced by SubProblem::reinitElemFaceRef(), and NEML2Utils::shouldCompute().

1506 {
1508 }
bool _currently_computing_residual_and_jacobian
Flag to determine whether the problem is currently computing the residual and Jacobian.
Definition: SubProblem.h:1114

◆ currentNlSysNum()

unsigned int FEProblemBase::currentNlSysNum ( ) const
overridevirtualinherited
Returns
the current nonlinear system number

Implements SubProblem.

Definition at line 9854 of file FEProblemBase.C.

Referenced by DisplacedProblem::currentNlSysNum(), FEProblemBase::jacobianSetup(), and FEProblemBase::residualSetup().

9855 {
9856  // If we don't have nonlinear systems this should be an invalid number
9857  unsigned int current_nl_sys_num = libMesh::invalid_uint;
9858  if (_nl.size())
9859  current_nl_sys_num = currentNonlinearSystem().number();
9860 
9861  return current_nl_sys_num;
9862 }
const unsigned int invalid_uint
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
NonlinearSystemBase & currentNonlinearSystem()
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158

◆ currentNonlinearSystem() [1/2]

NonlinearSystemBase & FEProblemBase::currentNonlinearSystem ( )
inlineinherited

Definition at line 3747 of file FEProblemBase.h.

Referenced by FEProblemBase::currentNlSysNum(), NonlinearSystemBase::jacobianSetup(), DefaultNonlinearConvergence::nonlinearSystem(), VariableResidualNormsDebugOutput::output(), Moose::PetscSupport::petscNonlinearConverged(), NonlinearSystemBase::residualSetup(), and PetscOutput::solveSetup().

3748 {
3749  mooseAssert(_current_nl_sys, "The nonlinear system is not currently set");
3750  return *_current_nl_sys;
3751 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.

◆ currentNonlinearSystem() [2/2]

const NonlinearSystemBase & FEProblemBase::currentNonlinearSystem ( ) const
inlineinherited

Definition at line 3754 of file FEProblemBase.h.

3755 {
3756  mooseAssert(_current_nl_sys, "The nonlinear system is not currently set");
3757  return *_current_nl_sys;
3758 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.

◆ currentResidualVectorTags()

const std::vector< VectorTag > & FEProblemBase::currentResidualVectorTags ( ) const
inlineoverridevirtualinherited

Return the residual vector tags we are currently computing.

Implements SubProblem.

Definition at line 3825 of file FEProblemBase.h.

Referenced by FEProblemBase::addCachedResidualDirectly(), FEProblemBase::addResidual(), FEProblemBase::addResidualLower(), FEProblemBase::addResidualNeighbor(), FEProblemBase::addResidualScalar(), and DisplacedProblem::currentResidualVectorTags().

3826 {
3828 }
std::vector< VectorTag > _current_residual_vector_tags
A data member to store the residual vector tag(s) passed into computeResidualTag(s).

◆ customSetup()

void FEProblemBase::customSetup ( const ExecFlagType exec_type)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 5068 of file FEProblemBase.C.

Referenced by FEProblemBase::execute().

5069 {
5070  SubProblem::customSetup(exec_type);
5071 
5072  if (_line_search)
5073  _line_search->customSetup(exec_type);
5074 
5075  unsigned int n_threads = libMesh::n_threads();
5076  for (THREAD_ID tid = 0; tid < n_threads; tid++)
5077  {
5078  _all_materials.customSetup(exec_type, tid);
5079  _functions.customSetup(exec_type, tid);
5080  }
5081 
5082 #ifdef MOOSE_KOKKOS_ENABLED
5083  _kokkos_functions.customSetup(exec_type);
5084 #endif
5085 
5086  _aux->customSetup(exec_type);
5087  for (auto & nl : _nl)
5088  nl->customSetup(exec_type);
5089 
5090  if (_displaced_problem)
5091  _displaced_problem->customSetup(exec_type);
5092 
5093  for (THREAD_ID tid = 0; tid < n_threads; tid++)
5094  {
5095  _internal_side_indicators.customSetup(exec_type, tid);
5096  _indicators.customSetup(exec_type, tid);
5097  _markers.customSetup(exec_type, tid);
5098  }
5099 
5100  std::vector<UserObject *> userobjs;
5101  theWarehouse().query().condition<AttribSystem>("UserObject").queryIntoUnsorted(userobjs);
5102  for (auto obj : userobjs)
5103  obj->customSetup(exec_type);
5104 
5105 #ifdef MOOSE_KOKKOS_ENABLED
5106  {
5107  std::vector<UserObjectBase *> userobjs;
5108  theWarehouse().query().condition<AttribSystem>("KokkosUserObject").queryIntoUnsorted(userobjs);
5109  for (auto obj : userobjs)
5110  obj->customSetup(exec_type);
5111  }
5112 #endif
5113 
5114  _app.getOutputWarehouse().customSetup(exec_type);
5115 }
unsigned int n_threads()
MooseObjectWarehouse< InternalSideIndicatorBase > _internal_side_indicators
virtual void customSetup(const ExecFlagType &exec_type, THREAD_ID tid=0) const
void customSetup(const ExecFlagType &exec_type)
Calls the setup function for each of the output objects.
MooseObjectWarehouse< Moose::FunctionBase > _kokkos_functions
virtual void customSetup(const ExecFlagType &exec_type)
Definition: SubProblem.C:1196
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
TheWarehouse & theWarehouse() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
MooseObjectWarehouse< Indicator > _indicators
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseObjectWarehouse< Function > _functions
functions
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285
MooseObjectWarehouse< Marker > _markers
MaterialWarehouse _all_materials
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
unsigned int THREAD_ID
Definition: MooseTypes.h:237
std::shared_ptr< LineSearch > _line_search

◆ declareManagedRestartableDataWithContext()

template<typename T , typename... Args>
Restartable::ManagedValue< T > Restartable::declareManagedRestartableDataWithContext ( const std::string &  data_name,
void context,
Args &&...  args 
)
protectedinherited

Declares a piece of "managed" restartable data and initialize it.

Here, "managed" restartable data means that the caller can destruct this data upon destruction of the return value of this method. Therefore, this ManagedValue<T> wrapper should survive after the final calls to dataStore() for it. That is... at the very end.

This is needed for objects whose destruction ordering is important, and enables natural c++ destruction in reverse construction order of the object that declares it.

See delcareRestartableData and declareRestartableDataWithContext for more information.

Definition at line 283 of file Restartable.h.

286 {
287  auto & data_ptr =
288  declareRestartableDataHelper<T>(data_name, context, std::forward<Args>(args)...);
289  return Restartable::ManagedValue<T>(data_ptr);
290 }
Wrapper class for restartable data that is "managed.
Definition: Restartable.h:42

◆ declareRecoverableData()

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

Declare a piece of data as "recoverable" 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)
argsArguments to forward to the constructor of the data

Definition at line 358 of file Restartable.h.

359 {
360  const auto full_name = restartableName(data_name);
361 
363 
364  return declareRestartableDataWithContext<T>(data_name, nullptr, std::forward<Args>(args)...);
365 }
std::string restartableName(const std::string &data_name) const
Gets the name of a piece of restartable data given a data name, adding the system name and object nam...
Definition: Restartable.C:78
void registerRestartableNameWithFilterOnApp(const std::string &name, Moose::RESTARTABLE_FILTER filter)
Helper function for actually registering the restartable data.
Definition: Restartable.C:71

◆ declareRestartableData()

template<typename T , typename... Args>
T & Restartable::declareRestartableData ( const std::string &  data_name,
Args &&...  args 
)
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)
argsArguments to forward to the constructor of the data

Definition at line 276 of file Restartable.h.

277 {
278  return declareRestartableDataWithContext<T>(data_name, nullptr, std::forward<Args>(args)...);
279 }

◆ declareRestartableDataWithContext()

template<typename T , typename... Args>
T & Restartable::declareRestartableDataWithContext ( const std::string &  data_name,
void context,
Args &&...  args 
)
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)
contextContext pointer that will be passed to the load and store functions
argsArguments to forward to the constructor of the data

Definition at line 301 of file Restartable.h.

304 {
305  return declareRestartableDataHelper<T>(data_name, context, std::forward<Args>(args)...).set();
306 }

◆ declareRestartableDataWithObjectName()

template<typename T , typename... Args>
T & Restartable::declareRestartableDataWithObjectName ( const std::string &  data_name,
const std::string &  object_name,
Args &&...  args 
)
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.
argsArguments to forward to the constructor of the data

Definition at line 330 of file Restartable.h.

333 {
334  return declareRestartableDataWithObjectNameWithContext<T>(
335  data_name, object_name, nullptr, std::forward<Args>(args)...);
336 }

◆ declareRestartableDataWithObjectNameWithContext()

template<typename T , typename... Args>
T & Restartable::declareRestartableDataWithObjectNameWithContext ( const std::string &  data_name,
const std::string &  object_name,
void context,
Args &&...  args 
)
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
argsArguments to forward to the constructor of the data

Definition at line 340 of file Restartable.h.

344 {
345  std::string old_name = _restartable_name;
346 
347  _restartable_name = object_name;
348 
349  T & value = declareRestartableDataWithContext<T>(data_name, context, std::forward<Args>(args)...);
350 
351  _restartable_name = old_name;
352 
353  return value;
354 }
std::string _restartable_name
The name of the object.
Definition: Restartable.h:250
Real value(unsigned n, unsigned alpha, unsigned beta, Real x)

◆ defaultGhosting()

bool SubProblem::defaultGhosting ( )
inlineinherited

Whether or not the user has requested default ghosting ot be on.

Definition at line 144 of file SubProblem.h.

Referenced by DisplacedSystem::DisplacedSystem(), and NonlinearSystemBase::NonlinearSystemBase().

144 { return _default_ghosting; }
bool _default_ghosting
Whether or not to use default libMesh coupling.
Definition: SubProblem.h:1105

◆ diracKernelInfo()

DiracKernelInfo & SubProblem::diracKernelInfo ( )
virtualinherited

Definition at line 749 of file SubProblem.C.

750 {
751  return _dirac_kernel_info;
752 }
DiracKernelInfo _dirac_kernel_info
Definition: SubProblem.h:1064

◆ displaceMesh()

void MFEMProblem::displaceMesh ( )

Displace the mesh, if mesh displacement is enabled.

Definition at line 720 of file MFEMProblem.C.

Referenced by MFEMProblemSolve::solve().

721 {
722  // Displace mesh
723  if (mesh().shouldDisplace())
724  {
725  mesh().displace(static_cast<mfem::GridFunction const &>(*getMeshDisplacementGridFunction()));
726  // TODO: update FESpaces GridFunctions etc for transient solves
727  }
728 }
virtual MFEMMesh & mesh() override
Overwritten mesh() method from base MooseMesh to retrieve the correct mesh type, in this case MFEMMes...
Definition: MFEMProblem.C:777
void displace(mfem::GridFunction const &displacement)
Displace the nodes of the mesh by the given displacement.
Definition: MFEMMesh.C:145
std::optional< std::reference_wrapper< mfem::ParGridFunction const > > getMeshDisplacementGridFunction()
Returns optional reference to the displacement GridFunction to apply to nodes.
Definition: MFEMProblem.C:731

◆ doingPRefinement()

bool SubProblem::doingPRefinement ( ) const
inherited
Returns
whether we're doing p-refinement

Definition at line 1366 of file SubProblem.C.

Referenced by FEProblemBase::meshChanged().

1367 {
1368  return mesh().doingPRefinement();
1369 }
virtual MooseMesh & mesh()=0
void doingPRefinement(bool doing_p_refinement)
Indicate whether the kind of adaptivity we&#39;re doing includes p-refinement.
Definition: MooseMesh.h:1504

◆ dt()

virtual Real& FEProblemBase::dt ( ) const
inlinevirtualinherited

◆ dtOld()

virtual Real& FEProblemBase::dtOld ( ) const
inlinevirtualinherited

Definition at line 578 of file FEProblemBase.h.

Referenced by IterationAdaptiveDT::acceptStep().

578 { return _dt_old; }

◆ duplicateVariableCheck()

bool FEProblemBase::duplicateVariableCheck ( const std::string &  var_name,
const libMesh::FEType type,
bool  is_aux,
const std::set< SubdomainID > *const  active_subdomains 
)
protectedinherited

Helper to check for duplicate variable names across systems or within a single system.

Definition at line 2910 of file FEProblemBase.C.

Referenced by FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), and FEProblemBase::addVariable().

2914 {
2915  std::set<SubdomainID> subdomainIDs;
2916  if (active_subdomains->size() == 0)
2917  {
2918  const auto subdomains = _mesh.meshSubdomains();
2919  subdomainIDs.insert(subdomains.begin(), subdomains.end());
2920  }
2921  else
2922  subdomainIDs.insert(active_subdomains->begin(), active_subdomains->end());
2923 
2924  for (auto & sys : _solver_systems)
2925  {
2926  SystemBase * curr_sys_ptr = sys.get();
2927  SystemBase * other_sys_ptr = _aux.get();
2928  std::string error_prefix = "";
2929  if (is_aux)
2930  {
2931  curr_sys_ptr = _aux.get();
2932  other_sys_ptr = sys.get();
2933  error_prefix = "aux";
2934  }
2935 
2936  if (other_sys_ptr->hasVariable(var_name))
2937  mooseError("Cannot have an auxiliary variable and a solver variable with the same name: ",
2938  var_name);
2939 
2940  if (curr_sys_ptr->hasVariable(var_name))
2941  {
2942  const Variable & var =
2943  curr_sys_ptr->system().variable(curr_sys_ptr->system().variable_number(var_name));
2944 
2945  // variable type
2946  if (var.type() != type)
2947  {
2948  const auto stringifyType = [](FEType t)
2949  { return Moose::stringify(t.family) + " of order " + Moose::stringify(t.order); };
2950 
2951  mooseError("Mismatching types are specified for ",
2952  error_prefix,
2953  "variable with name '",
2954  var_name,
2955  "': '",
2956  stringifyType(var.type()),
2957  "' and '",
2958  stringifyType(type),
2959  "'");
2960  }
2961 
2962  // block-restriction
2963  if (!(active_subdomains->size() == 0 && var.active_subdomains().size() == 0))
2964  {
2965  const auto varActiveSubdomains = var.active_subdomains();
2966  std::set<SubdomainID> varSubdomainIDs;
2967  if (varActiveSubdomains.size() == 0)
2968  {
2969  const auto subdomains = _mesh.meshSubdomains();
2970  varSubdomainIDs.insert(subdomains.begin(), subdomains.end());
2971  }
2972  else
2973  varSubdomainIDs.insert(varActiveSubdomains.begin(), varActiveSubdomains.end());
2974 
2975  // Is subdomainIDs a subset of varSubdomainIDs? With this we allow the case that the newly
2976  // requested block restriction is only a subset of the existing one.
2977  const auto isSubset = std::includes(varSubdomainIDs.begin(),
2978  varSubdomainIDs.end(),
2979  subdomainIDs.begin(),
2980  subdomainIDs.end());
2981 
2982  if (!isSubset)
2983  {
2984  // helper function: make a string from a set of subdomain ids
2985  const auto stringifySubdomains = [this](std::set<SubdomainID> subdomainIDs)
2986  {
2987  std::stringstream s;
2988  for (auto const i : subdomainIDs)
2989  {
2990  // do we need to insert a comma?
2991  if (s.tellp() != 0)
2992  s << ", ";
2993 
2994  // insert subdomain name and id -or- only the id (if no name is given)
2995  const auto subdomainName = _mesh.getSubdomainName(i);
2996  if (subdomainName.empty())
2997  s << i;
2998  else
2999  s << subdomainName << " (" << i << ")";
3000  }
3001  return s.str();
3002  };
3003 
3004  const std::string msg = "Mismatching block-restrictions are specified for " +
3005  error_prefix + "variable with name '" + var_name + "': {" +
3006  stringifySubdomains(varSubdomainIDs) + "} and {" +
3007  stringifySubdomains(subdomainIDs) + "}";
3008 
3009  mooseError(msg);
3010  }
3011  }
3012 
3013  return true;
3014  }
3015  }
3016 
3017  return false;
3018 }
const Variable & variable(unsigned int var) const
virtual libMesh::System & system()=0
Get the reference to the libMesh system.
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
Base class for a system (of equations)
Definition: SystemBase.h:85
const std::string & getSubdomainName(SubdomainID subdomain_id) const
Return the name of a block given an id.
Definition: MooseMesh.C:1750
unsigned int variable_number(std::string_view var) const
const std::set< subdomain_id_type > & active_subdomains() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseMesh & _mesh
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
virtual bool hasVariable(const std::string &var_name) const
Query a system for a variable.
Definition: SystemBase.C:852
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
const std::set< SubdomainID > & meshSubdomains() const
Returns a read-only reference to the set of subdomains currently present in the Mesh.
Definition: MooseMesh.C:3271
const FEType & type() const

◆ enabled()

virtual bool MooseObject::enabled ( ) const
inlinevirtualinherited

Return the enabled status of the object.

Reimplemented in EigenKernel.

Definition at line 49 of file MooseObject.h.

Referenced by EigenKernel::enabled(), BlockRestrictionDebugOutput::printBlockRestrictionGroups(), BlockRestrictionDebugOutput::printBoundaryRestrictionGroups(), and NodeFaceConstraint::validParams().

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

◆ errorOnJacobianNonzeroReallocation()

bool FEProblemBase::errorOnJacobianNonzeroReallocation ( ) const
inlineinherited

Will return True if the user wants to get an error when a nonzero is reallocated in the Jacobian by PETSc.

Definition at line 2366 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::computeJacobianBlocks(), NonlinearSystemBase::computeJacobianInternal(), LinearSystem::computeLinearSystemInternal(), NonlinearSystemBase::computeResidualAndJacobianInternal(), and NonlinearSystemBase::constraintJacobians().

2367  {
2369  }
bool _error_on_jacobian_nonzero_reallocation
Whether to error when the Jacobian is re-allocated, usually because the sparsity pattern changed...

◆ errorPrefix()

std::string MooseBase::errorPrefix ( const std::string &  ) const
inlineinherited

Deprecated message prefix; the error type is no longer used.

Definition at line 264 of file MooseBase.h.

264 { return messagePrefix(); }
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:256

◆ es()

virtual libMesh::EquationSystems& FEProblemBase::es ( )
inlineoverridevirtualinherited

Implements SubProblem.

Definition at line 180 of file FEProblemBase.h.

Referenced by FEProblemBase::adaptMesh(), PhysicsBasedPreconditioner::addSystem(), MooseMesh::cacheFaceInfoVariableOwnership(), MooseMesh::cacheFVElementalDoFs(), DefaultNonlinearConvergence::DefaultNonlinearConvergence(), EigenProblem::EigenProblem(), MultiAppProjectionTransfer::execute(), FEProblem::FEProblem(), FEProblemBase::FEProblemBase(), FEProblemSolve::FEProblemSolve(), MultiAppFieldTransfer::getEquationSystem(), FEProblemBase::getEvaluableElementRange(), MFEMMultiAppTransfer::getlibMeshEquationSystem(), Adaptivity::init(), FEProblemBase::init(), MultiAppProjectionTransfer::initialSetup(), SampledOutput::initSample(), EigenExecutionerBase::inversePowerIteration(), FEProblemBase::meshChanged(), EigenExecutionerBase::nonlinearSolve(), DOFMapOutput::output(), Output::Output(), Moose::PetscSupport::petscSetKSPDefaults(), MultiAppProjectionTransfer::projectSolution(), FEProblemBase::reinitBecauseOfGhostingOrNewGeomObjects(), Moose::SlepcSupport::setEigenProblemSolverParams(), ExplicitTimeIntegrator::solveLinearSystem(), FEProblemBase::timestepSetup(), and SampledOutput::updateSample().

180 { return _req.set().es(); }
libMesh::EquationSystems & es()
Restartable::ManagedValue< RestartableEquationSystems > _req
The EquationSystems object, wrapped for restart.

◆ execMultiApps()

bool FEProblemBase::execMultiApps ( ExecFlagType  type,
bool  auto_advance = true 
)
inherited

Execute the MultiApps associated with the ExecFlagType.

Definition at line 5968 of file FEProblemBase.C.

Referenced by FEProblemBase::adaptMesh(), FEProblemBase::computeJacobianTags(), FEProblemBase::computeLinearSystemTags(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), MFEMSteady::execute(), SteadyBase::execute(), TransientBase::execute(), Eigenvalue::execute(), FEProblemBase::initialSetup(), EigenExecutionerBase::postExecute(), FixedPointSolve::solve(), FixedPointSolve::solveStep(), and MFEMTransient::takeStep().

5969 {
5970  // Active MultiApps
5971  const std::vector<MooseSharedPointer<MultiApp>> & multi_apps =
5973 
5974  // Do anything that needs to be done to Apps before transfers
5975  for (const auto & multi_app : multi_apps)
5976  multi_app->preTransfer(_dt, _time);
5977 
5978  // Execute Transfers _to_ MultiApps
5980 
5981  // Execute Transfers _between_ Multiapps
5983 
5984  // Execute MultiApps
5985  if (multi_apps.size())
5986  {
5987  TIME_SECTION("execMultiApps", 1, "Executing MultiApps", false);
5988 
5989  if (_verbose_multiapps)
5990  _console << COLOR_CYAN << "\nExecuting MultiApps on " << Moose::stringify(type)
5991  << COLOR_DEFAULT << std::endl;
5992 
5993  bool success = true;
5994 
5995  for (const auto & multi_app : multi_apps)
5996  {
5997  success = multi_app->solveStep(_dt, _time, auto_advance);
5998  // no need to finish executing the subapps if one fails
5999  if (!success)
6000  break;
6001  }
6002 
6004 
6005  _communicator.min(success);
6006 
6007  if (!success)
6008  return false;
6009 
6010  if (_verbose_multiapps)
6011  _console << COLOR_CYAN << "Finished Executing MultiApps on " << Moose::stringify(type) << "\n"
6012  << COLOR_DEFAULT << std::endl;
6013  }
6014 
6015  // Execute Transfers _from_ MultiApps
6017 
6018  // If we made it here then everything passed
6019  return true;
6020 }
bool _parallel_barrier_messaging
Whether or not information about how many transfers have completed is printed.
const Parallel::Communicator & _communicator
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
void min(const T &r, T &o, Request &req) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
void execMultiAppTransfers(ExecFlagType type, Transfer::DIRECTION direction)
Execute MultiAppTransfers associated with execution flag and direction.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
void parallelBarrierNotify(const Parallel::Communicator &comm, bool messaging)
Definition: MooseUtils.C:327
bool _verbose_multiapps
Whether or not to be verbose with multiapps.

◆ execMultiAppTransfers()

void FEProblemBase::execMultiAppTransfers ( ExecFlagType  type,
Transfer::DIRECTION  direction 
)
inherited

Execute MultiAppTransfers associated with execution flag and direction.

Parameters
typeThe execution flag to execute.
directionThe direction (to or from) to transfer.

Definition at line 5868 of file FEProblemBase.C.

Referenced by FEProblemBase::execMultiApps().

5869 {
5870  bool to_multiapp = direction == MultiAppTransfer::TO_MULTIAPP;
5871  bool from_multiapp = direction == MultiAppTransfer::FROM_MULTIAPP;
5872  std::string string_direction;
5873  if (to_multiapp)
5874  string_direction = " To ";
5875  else if (from_multiapp)
5876  string_direction = " From ";
5877  else
5878  string_direction = " Between ";
5879 
5880  const MooseObjectWarehouse<Transfer> & wh = to_multiapp ? _to_multi_app_transfers[type]
5881  : from_multiapp ? _from_multi_app_transfers[type]
5883 
5884  if (wh.hasActiveObjects())
5885  {
5886  TIME_SECTION("execMultiAppTransfers", 1, "Executing Transfers");
5887 
5888  const auto & transfers = wh.getActiveObjects();
5889 
5890  if (_verbose_multiapps)
5891  {
5892  _console << COLOR_CYAN << "\nTransfers on " << Moose::stringify(type) << string_direction
5893  << "MultiApps" << COLOR_DEFAULT << ":" << std::endl;
5894 
5896  {"Name", "Type", "From", "To"});
5897 
5898  // Build Table of Transfer Info
5899  for (const auto & transfer : transfers)
5900  {
5901  auto multiapp_transfer = dynamic_cast<MultiAppTransfer *>(transfer.get());
5902 
5903  table.addRow(multiapp_transfer->name(),
5904  multiapp_transfer->type(),
5905  multiapp_transfer->getFromName(),
5906  multiapp_transfer->getToName());
5907  }
5908 
5909  // Print it
5910  table.print(_console);
5911  }
5912 
5913  for (const auto & transfer : transfers)
5914  {
5915  transfer->setCurrentDirection(direction);
5916  transfer->execute();
5917  }
5918 
5920 
5921  if (_verbose_multiapps)
5922  _console << COLOR_CYAN << "Transfers on " << Moose::stringify(type) << " Are Finished\n"
5923  << COLOR_DEFAULT << std::endl;
5924  }
5925  else if (_multi_apps[type].getActiveObjects().size())
5926  {
5927  if (_verbose_multiapps)
5928  _console << COLOR_CYAN << "\nNo Transfers on " << Moose::stringify(type) << string_direction
5929  << "MultiApps\n"
5930  << COLOR_DEFAULT << std::endl;
5931  }
5932 }
bool _parallel_barrier_messaging
Whether or not information about how many transfers have completed is printed.
A class for "pretty printing" a table of data.
Definition: PerfGraph.h:34
void setCurrentDirection(const int direction)
Set this Transfer to be executed in a given direction.
Definition: Transfer.h:89
const Parallel::Communicator & _communicator
ExecuteMooseObjectWarehouse< Transfer > _from_multi_app_transfers
Transfers executed just after MultiApps to transfer data from them.
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
ExecuteMooseObjectWarehouse< Transfer > _to_multi_app_transfers
Transfers executed just before MultiApps to transfer data to them.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
bool hasActiveObjects(THREAD_ID tid=0) const
Base class for all MultiAppTransfer objects.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
ExecuteMooseObjectWarehouse< Transfer > _between_multi_app_transfers
Transfers executed just before MultiApps to transfer data between them.
void parallelBarrierNotify(const Parallel::Communicator &comm, bool messaging)
Definition: MooseUtils.C:327
bool _verbose_multiapps
Whether or not to be verbose with multiapps.

◆ execTransfers()

void FEProblemBase::execTransfers ( ExecFlagType  type)
inherited

Execute the Transfers associated with the ExecFlagType.

Note: This does not execute MultiApp Transfers! Those are executed automatically when MultiApps are executed.

Definition at line 6138 of file FEProblemBase.C.

Referenced by FEProblemBase::computeJacobianTags(), FEProblemBase::computeLinearSystemTags(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), MFEMSteady::execute(), FEProblemBase::initialSetup(), FixedPointSolve::solve(), FixedPointSolve::solveStep(), and MFEMTransient::takeStep().

6139 {
6140  if (_transfers[type].hasActiveObjects())
6141  {
6142  TIME_SECTION("execTransfers", 3, "Executing Transfers");
6143 
6144  const auto & transfers = _transfers[type].getActiveObjects();
6145 
6146  for (const auto & transfer : transfers)
6147  transfer->execute();
6148  }
6149 }
ExecuteMooseObjectWarehouse< Transfer > _transfers
Normal Transfers.
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93

◆ execute()

void MFEMProblem::execute ( const ExecFlagType exec_type)
overridevirtual

Convenience function for performing execution of MOOSE systems.

Reimplemented from FEProblemBase.

Definition at line 110 of file MFEMProblem.C.

Referenced by MFEMSteady::execute(), and MFEMSteady::init().

111 {
112  setCurrentExecuteOnFlag(exec_type);
113  executeMFEMObjects(exec_type);
114 
115  ExternalProblem::execute(exec_type);
116 }
void executeMFEMObjects(const ExecFlagType &exec_type)
Execute MFEM executed objects scheduled on the supplied execute flag.
Definition: MFEMProblem.C:829
void setCurrentExecuteOnFlag(const ExecFlagType &)
virtual void execute(const ExecFlagType &exec_type)
Convenience function for performing execution of MOOSE systems.

◆ executeAllObjects()

void FEProblemBase::executeAllObjects ( const ExecFlagType exec_type)
virtualinherited

Definition at line 5063 of file FEProblemBase.C.

Referenced by Executor::exec().

5064 {
5065 }

◆ executeControls()

void FEProblemBase::executeControls ( const ExecFlagType exec_type)
inherited

Performs setup and execute calls for Control objects.

Definition at line 5553 of file FEProblemBase.C.

Referenced by FEProblemBase::computeJacobianTags(), FEProblemBase::computeLinearSystemTags(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), FEProblemBase::execute(), and FEProblemBase::initialSetup().

5554 {
5555  if (_control_warehouse[exec_type].hasActiveObjects())
5556  {
5557  TIME_SECTION("executeControls", 1, "Executing Controls");
5558 
5560 
5561  auto controls_wh = _control_warehouse[exec_type];
5562  // Add all of the dependencies into the resolver and sort them
5563  for (const auto & it : controls_wh.getActiveObjects())
5564  {
5565  // Make sure an item with no dependencies comes out too!
5566  resolver.addItem(it);
5567 
5568  std::vector<std::string> & dependent_controls = it->getDependencies();
5569  for (const auto & depend_name : dependent_controls)
5570  {
5571  if (controls_wh.hasActiveObject(depend_name))
5572  {
5573  auto dep_control = controls_wh.getActiveObject(depend_name);
5574  resolver.addEdge(dep_control, it);
5575  }
5576  else
5577  mooseError("The Control \"",
5578  depend_name,
5579  "\" was not created, did you make a "
5580  "spelling mistake or forget to include it "
5581  "in your input file?");
5582  }
5583  }
5584 
5585  const auto & ordered_controls = resolver.getSortedValues();
5586 
5587  if (!ordered_controls.empty())
5588  {
5589  // already called by initialSetup when exec_type == EXEC_INITIAL
5590  if (exec_type != EXEC_INITIAL)
5591  _control_warehouse.setup(exec_type);
5592 
5593  // Run the controls in the proper order
5594  for (const auto & control : ordered_controls)
5595  control->execute();
5596  }
5597  }
5598 }
ExecuteMooseObjectWarehouse< Control > _control_warehouse
The control logic warehouse.
const std::vector< T > & getSortedValues()
This function also returns dependency resolved values but with a simpler single vector interface...
void setup(const ExecFlagType &exec_flag, THREAD_ID tid=0) const
void addEdge(const T &a, const T &b)
Add an edge between nodes &#39;a&#39; and &#39;b&#39;.
void addItem(const T &value)
Add an independent item to the set.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
Class that represents the dependecy as a graph.
const ExecFlagType EXEC_INITIAL
Definition: Moose.C:30

◆ executeMFEMObjects()

void MFEMProblem::executeMFEMObjects ( const ExecFlagType exec_type)

Execute MFEM executed objects scheduled on the supplied execute flag.

Definition at line 829 of file MFEMProblem.C.

Referenced by execute().

830 {
831  std::vector<MFEMExecutedObject *> objects;
832  theWarehouse()
833  .query()
834  .condition<AttribSystem>("MFEMExecutedObject")
835  .condition<AttribExecOns>(exec_type)
836  .condition<AttribThread>(0)
837  .queryInto(objects);
838 
839  std::map<std::string, const MFEMExecutedObject *> suppliers;
840  for (auto * const object : objects)
841  for (const auto & item : object->getSuppliedItems())
842  {
843  const auto [it, inserted] = suppliers.emplace(item, object);
844  if (!inserted && it->second != object)
845  mooseError("MFEM executed-object dependency ambiguity on ",
846  exec_type,
847  ": both '",
848  it->second->name(),
849  "' and '",
850  object->name(),
851  "' supply '",
852  item,
853  "'.");
854  }
855 
856  for (auto * const object : objects)
857  {
858  object->initialize();
859  object->execute();
860  object->finalize();
861 
862  if (auto * const pp = dynamic_cast<const Postprocessor *>(object))
863  {
864  _reporter_data.finalize(pp->PPName());
865  setPostprocessorValueByName(pp->PPName(), pp->getValue());
866  }
867 
868  if (auto * const vpp = dynamic_cast<VectorPostprocessor *>(object))
869  _reporter_data.finalize(vpp->PPName());
870  }
871 }
void setPostprocessorValueByName(const PostprocessorName &name, const PostprocessorValue &value, std::size_t t_index=0)
Set the value of a PostprocessorValue.
ReporterData _reporter_data
TheWarehouse & theWarehouse() const
void finalize(const std::string &object_name)
Helper function for performing post calculation actions via the ReporterContext objects.
Definition: ReporterData.C:48
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ executeSamplers()

void FEProblemBase::executeSamplers ( const ExecFlagType exec_type)
inherited

Performs setup and execute calls for Sampler objects.

Definition at line 5601 of file FEProblemBase.C.

Referenced by FEProblemBase::execute().

5602 {
5603  // TODO: This should be done in a threaded loop, but this should be super quick so for now
5604  // do a serial loop.
5605  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); ++tid)
5606  {
5607  std::vector<Sampler *> objects;
5608  theWarehouse()
5609  .query()
5610  .condition<AttribSystem>("Sampler")
5611  .condition<AttribThread>(tid)
5612  .condition<AttribExecOns>(exec_type)
5613  .queryInto(objects);
5614 
5615  if (!objects.empty())
5616  {
5617  TIME_SECTION("executeSamplers", 1, "Executing Samplers");
5618  FEProblemBase::objectSetupHelper<Sampler>(objects, exec_type);
5619  FEProblemBase::objectExecuteHelper<Sampler>(objects);
5620  }
5621  }
5622 }
unsigned int n_threads()
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ externalSolve()

virtual void MFEMProblem::externalSolve ( )
inlineoverridevirtual

New interface for solving an External problem.

"solve()" is finalized here to provide callbacks for solution syncing.

Implements ExternalProblem.

Definition at line 48 of file MFEMProblem.h.

48 {}

◆ feBackend()

Moose::FEBackend MFEMProblem::feBackend ( ) const
inlineoverridevirtual

Reimplemented from FEProblemBase.

Definition at line 313 of file MFEMProblem.h.

◆ finalizeMultiApps()

void FEProblemBase::finalizeMultiApps ( )
inherited

Definition at line 6023 of file FEProblemBase.C.

Referenced by MFEMSteady::execute(), SteadyBase::execute(), TransientBase::execute(), and Eigenvalue::execute().

6024 {
6025  const auto & multi_apps = _multi_apps.getActiveObjects();
6026 
6027  for (const auto & multi_app : multi_apps)
6028  multi_app->finalize();
6029 }
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.

◆ finalNonlinearResidual()

Real FEProblemBase::finalNonlinearResidual ( const unsigned int  nl_sys_num) const
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 7146 of file FEProblemBase.C.

7147 {
7148  return _nl[nl_sys_num]->finalNonlinearResidual();
7149 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ finishMultiAppStep()

void FEProblemBase::finishMultiAppStep ( ExecFlagType  type,
bool  recurse_through_multiapp_levels = false 
)
inherited

Finish the MultiApp time step (endStep, postStep) associated with the ExecFlagType.

Optionally recurse through all multi-app levels

Definition at line 6051 of file FEProblemBase.C.

Referenced by FEProblemBase::advanceMultiApps(), TransientBase::execute(), TransientMultiApp::finishStep(), and TransientBase::incrementStepOrReject().

6052 {
6053  const auto & multi_apps = _multi_apps[type].getActiveObjects();
6054 
6055  if (multi_apps.size())
6056  {
6057  if (_verbose_multiapps)
6058  _console << COLOR_CYAN << "\nAdvancing MultiApps on " << type.name() << COLOR_DEFAULT
6059  << std::endl;
6060 
6061  for (const auto & multi_app : multi_apps)
6062  multi_app->finishStep(recurse_through_multiapp_levels);
6063 
6065 
6066  if (_verbose_multiapps)
6067  _console << COLOR_CYAN << "Finished Advancing MultiApps on " << type.name() << "\n"
6068  << COLOR_DEFAULT << std::endl;
6069  }
6070 }
bool _parallel_barrier_messaging
Whether or not information about how many transfers have completed is printed.
const Parallel::Communicator & _communicator
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
void parallelBarrierNotify(const Parallel::Communicator &comm, bool messaging)
Definition: MooseUtils.C:327
bool _verbose_multiapps
Whether or not to be verbose with multiapps.

◆ flagInvalidSolutionInternal()

template<bool warning>
template void SolutionInvalidInterface::flagInvalidSolutionInternal< false > ( const InvalidSolutionID  invalid_solution_id) const
protectedinherited

Set solution invalid mark for the given solution ID.

Definition at line 41 of file SolutionInvalidInterface.C.

43 {
44  mooseAssert(
45  warning == moose::internal::getSolutionInvalidityRegistry().item(invalid_solution_id).warning,
46  "Inconsistent warning flag");
47  auto & solution_invalidity = _si_moose_base.getMooseApp().solutionInvalidity();
48  if constexpr (!warning)
50  solution_invalidity.printDebug(invalid_solution_id);
51  return solution_invalidity.flagInvalidSolutionInternal(invalid_solution_id);
52 }
const FEProblemBase * _si_problem
A pointer to FEProblem base.
void printDebug(InvalidSolutionID _invalid_solution_id) const
Immediately print the section and message for debug purpose.
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
SolutionInvalidity & solutionInvalidity()
Get the SolutionInvalidity for this app.
Definition: MooseApp.h:185
SolutionInvalidityRegistry & getSolutionInvalidityRegistry()
Get the global SolutionInvalidityRegistry singleton.
bool immediatelyPrintInvalidSolution() const
Whether or not the solution invalid warnings are printed out immediately.
const MooseBase & _si_moose_base
The MooseBase that owns this interface.

◆ forceOutput()

void FEProblemBase::forceOutput ( )
inherited

Indicates that the next call to outputStep should be forced.

This is needed by the MultiApp system, if forceOutput is called the next call to outputStep, regardless of the type supplied to the call, will be executed with EXEC_FORCED.

Forced output will NOT override the allowOutput flag.

Definition at line 7289 of file FEProblemBase.C.

Referenced by TransientMultiApp::solveStep().

7290 {
7292 }
void forceOutput()
Indicates that the next call to outputStep should be forced This is private, users should utilize FEP...
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409

◆ fvBCsIntegrityCheck() [1/2]

bool FEProblemBase::fvBCsIntegrityCheck ( ) const
inlineinherited
Returns
whether to perform a boundary condition integrity check for finite volume

Definition at line 2725 of file FEProblemBase.h.

2725 { return _fv_bcs_integrity_check; }
bool _fv_bcs_integrity_check
Whether to check overlapping Dirichlet and Flux BCs and/or multiple DirichletBCs per sideset...

◆ fvBCsIntegrityCheck() [2/2]

void FEProblemBase::fvBCsIntegrityCheck ( bool  fv_bcs_integrity_check)
inlineinherited
Parameters
fv_bcs_integrity_checkWhether to perform a boundary condition integrity check for finite volume

Definition at line 3815 of file FEProblemBase.h.

3816 {
3818  // the user has requested that we don't check integrity so we will honor that
3819  return;
3820 
3821  _fv_bcs_integrity_check = fv_bcs_integrity_check;
3822 }
bool _fv_bcs_integrity_check
Whether to check overlapping Dirichlet and Flux BCs and/or multiple DirichletBCs per sideset...

◆ geomSearchData()

virtual GeometricSearchData& FEProblemBase::geomSearchData ( )
inlineoverridevirtualinherited

◆ getActiveElementalMooseVariables()

const std::set< MooseVariableFEBase * > & SubProblem::getActiveElementalMooseVariables ( const THREAD_ID  tid) const
virtualinherited

Get the MOOSE variables to be reinited on each element.

Parameters
tidThe thread id

Definition at line 455 of file SubProblem.C.

Referenced by SystemBase::prepare(), SystemBase::prepareFace(), FEProblemBase::prepareMaterials(), and SystemBase::reinitElem().

456 {
458 }
std::vector< std::set< MooseVariableFieldBase * > > _active_elemental_moose_variables
This is the set of MooseVariableFieldBase that will actually get reinited by a call to reinit(elem) ...
Definition: SubProblem.h:1090

◆ getActiveFEVariableCoupleableMatrixTags()

const std::set< TagID > & SubProblem::getActiveFEVariableCoupleableMatrixTags ( const THREAD_ID  tid) const
inherited

Definition at line 391 of file SubProblem.C.

392 {
394 }
std::vector< std::set< TagID > > _active_fe_var_coupleable_matrix_tags
Definition: SubProblem.h:1096

◆ getActiveFEVariableCoupleableVectorTags()

const std::set< TagID > & SubProblem::getActiveFEVariableCoupleableVectorTags ( const THREAD_ID  tid) const
inherited

Definition at line 397 of file SubProblem.C.

Referenced by MultiAppVariableValueSamplePostprocessorTransfer::execute().

398 {
400 }
std::vector< std::set< TagID > > _active_fe_var_coupleable_vector_tags
Definition: SubProblem.h:1098

◆ getActiveScalarVariableCoupleableMatrixTags()

const std::set< TagID > & SubProblem::getActiveScalarVariableCoupleableMatrixTags ( const THREAD_ID  tid) const
inherited

Definition at line 432 of file SubProblem.C.

Referenced by MooseVariableScalar::reinit().

433 {
435 }
std::vector< std::set< TagID > > _active_sc_var_coupleable_matrix_tags
Definition: SubProblem.h:1100

◆ getActiveScalarVariableCoupleableVectorTags()

const std::set< TagID > & SubProblem::getActiveScalarVariableCoupleableVectorTags ( const THREAD_ID  tid) const
inherited

Definition at line 438 of file SubProblem.C.

439 {
441 }
std::vector< std::set< TagID > > _active_sc_var_coupleable_vector_tags
Definition: SubProblem.h:1102

◆ getActualFieldVariable()

MooseVariableFieldBase & FEProblemBase::getActualFieldVariable ( const THREAD_ID  tid,
const std::string &  var_name 
)
overridevirtualinherited

Returns the variable reference for requested MooseVariableField which may be in any system.

Implements SubProblem.

Definition at line 6268 of file FEProblemBase.C.

Referenced by MultiAppVariableValueSampleTransfer::execute().

6269 {
6270  for (auto & sys : _solver_systems)
6271  if (sys->hasVariable(var_name))
6272  return sys->getActualFieldVariable<Real>(tid, var_name);
6273  if (_aux->hasVariable(var_name))
6274  return _aux->getActualFieldVariable<Real>(tid, var_name);
6275 
6276  mooseError("Unknown variable " + var_name);
6277 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getArrayVariable()

ArrayMooseVariable & FEProblemBase::getArrayVariable ( const THREAD_ID  tid,
const std::string &  var_name 
)
overridevirtualinherited

Returns the variable reference for requested ArrayMooseVariable which may be in any system.

Implements SubProblem.

Definition at line 6292 of file FEProblemBase.C.

Referenced by CoupleableMooseVariableDependencyIntermediateInterface::coupledArrayValueByName(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), and PointwiseRenormalizeVector::PointwiseRenormalizeVector().

6293 {
6294  for (auto & sys : _solver_systems)
6295  if (sys->hasVariable(var_name))
6296  return sys->getFieldVariable<RealEigenVector>(tid, var_name);
6297  if (_aux->hasVariable(var_name))
6298  return _aux->getFieldVariable<RealEigenVector>(tid, var_name);
6299 
6300  mooseError("Unknown variable " + var_name);
6301 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
Eigen::Matrix< Real, Eigen::Dynamic, 1 > RealEigenVector
Definition: MooseTypes.h:147

◆ getAuxiliarySystem()

AuxiliarySystem& FEProblemBase::getAuxiliarySystem ( )
inlineinherited

Definition at line 1072 of file FEProblemBase.h.

Referenced by Adaptivity::adaptMesh(), DisplacedProblem::addTimeIntegrator(), ElementSubdomainModifierBase::applyIC(), TransientMultiApp::appTransferVector(), MooseMesh::cacheFaceInfoVariableOwnership(), MooseMesh::cacheFVElementalDoFs(), PNGOutput::calculateRescalingValues(), NonlinearSystemBase::computeJacobianInternal(), NonlinearSystemBase::computeNodalBCsJacobian(), NonlinearSystemBase::computeNodalBCsResidual(), NonlinearSystemBase::computeResidualTags(), NonlinearSystemBase::constraintResiduals(), DisplacedProblem::DisplacedProblem(), EigenExecutionerBase::EigenExecutionerBase(), FEProblemBase::execute(), FEProblemBase::initialSetup(), ActivateElementsUserObjectBase::initSolutions(), EigenExecutionerBase::inversePowerIteration(), PNGOutput::makeMeshFunc(), MultiAppVariableValueSamplePostprocessorTransfer::MultiAppVariableValueSamplePostprocessorTransfer(), ConsoleUtils::outputAuxiliarySystemInformation(), BlockRestrictionDebugOutput::printBlockRestrictionGroups(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), BlockRestrictionDebugOutput::printBoundaryRestrictionGroups(), MultiApp::restore(), NonlinearSystemBase::setConstraintSecondaryValues(), TransientMultiApp::setupApp(), TransientMultiApp::solveStep(), AB2PredictorCorrector::step(), DisplacedProblem::syncSolutions(), and Coupleable::writableCoupledValue().

1072 { return *_aux; }
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ getAuxVariableNames()

std::vector< VariableName > MFEMProblem::getAuxVariableNames ( )
virtual

Returns all the variable names from the auxiliary system base.

This is helpful in the syncSolutions() method when transferring variable data.

Definition at line 771 of file MFEMProblem.C.

772 {
774 }
virtual const SystemBase & systemBaseAuxiliary() const override
Return the auxiliary system object as a base class reference.
const std::vector< VariableName > & getVariableNames() const
Definition: SystemBase.h:863

◆ getAxisymmetricRadialCoord()

unsigned int SubProblem::getAxisymmetricRadialCoord ( ) const
inherited

Returns the desired radial direction for RZ coordinate transformation.

Returns
The coordinate direction for the radial direction

Definition at line 797 of file SubProblem.C.

798 {
799  return mesh().getAxisymmetricRadialCoord();
800 }
virtual MooseMesh & mesh()=0
unsigned int getAxisymmetricRadialCoord() const
Returns the desired radial direction for RZ coordinate transformation.
Definition: MooseMesh.C:4414

◆ getBase()

const std::string& MooseBase::getBase ( ) const
inlineinherited
Returns
The registered base for this object (set via InputParameters::registerBase())

Definition at line 147 of file MooseBase.h.

Referenced by Factory::copyConstruct(), and MooseBase::uniqueParameterName().

147 { return _pars.getBase(); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
const std::string & getBase() const

◆ getBndMaterialPropertyStorage()

const MaterialPropertyStorage& FEProblemBase::getBndMaterialPropertyStorage ( )
inlineinherited

Definition at line 2059 of file FEProblemBase.h.

2059 { return _bnd_material_props; }
MaterialPropertyStorage & _bnd_material_props

◆ getCheckedPointerParam()

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

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 450 of file MooseBase.h.

451 {
452  return _pars.getCheckedPointerParam<T>(name, error_string);
453 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
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 std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ getCoefficients()

Moose::MFEM::CoefficientManager& MFEMProblem::getCoefficients ( )
inline

Method to get the PropertyManager object for storing material properties and converting them to MFEM coefficients.

This is used by Material and Kernel classes (among others).

Definition at line 265 of file MFEMProblem.h.

Referenced by addFunction(), addPostprocessor(), MFEMComplexVariable::declareCoefficients(), MFEMVariable::declareCoefficients(), MFEMObject::getMatrixCoefficientByName(), MFEMObject::getScalarCoefficientByName(), MFEMObject::getVectorCoefficientByName(), MFEMParsedFunction::initialSetup(), MFEMScalarQuadratureFunction::MFEMScalarQuadratureFunction(), and MFEMVectorQuadratureFunction::MFEMVectorQuadratureFunction().

265 { return _problem_data.coefficients; }
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
Moose::MFEM::CoefficientManager coefficients

◆ getComm()

MPI_Comm MFEMProblem::getComm ( )
inline

◆ getComplexGridFunction()

std::shared_ptr<mfem::ParComplexGridFunction> MFEMProblem::getComplexGridFunction ( const std::string &  name)
inline
Returns
a shared pointer to an MFEM parallel complex grid function

Definition at line 348 of file MFEMProblem.h.

Referenced by MFEMComplexSumAux::MFEMComplexSumAux(), MultiAppMFEMCopyTransfer::transferVariables(), and MultiAppMFEMShapeEvaluationTransfer::transferVariables().

349  {
351  }
Moose::MFEM::ComplexGridFunctions cmplx_gridfunctions
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< T > GetShared(const std::string &field_name) const
Returns a shared pointer to the field. This is guaranteed to return a non-null shared pointer...

◆ getConsumedPropertyMap()

const std::map< MooseObjectName, std::set< std::string > > & SubProblem::getConsumedPropertyMap ( ) const
inherited

Return the map that tracks the object with consumed material properties.

Definition at line 743 of file SubProblem.C.

Referenced by MaterialPropertyDebugOutput::output().

744 {
746 }
std::map< MooseObjectName, std::set< std::string > > _consumed_material_properties
Definition: SubProblem.h:1203

◆ getControlWarehouse()

ExecuteMooseObjectWarehouse<Control>& FEProblemBase::getControlWarehouse ( )
inlineinherited

Reference to the control logic warehouse.

Definition at line 2517 of file FEProblemBase.h.

Referenced by LibtorchArtificialNeuralNetParameters::initialSetup(), and LibtorchControlValuePostprocessor::initialSetup().

2517 { return _control_warehouse; }
ExecuteMooseObjectWarehouse< Control > _control_warehouse
The control logic warehouse.

◆ getConvergence()

Convergence & FEProblemBase::getConvergence ( const std::string &  name,
const THREAD_ID  tid = 0 
) const
virtualinherited

Gets a Convergence object.

Definition at line 2773 of file FEProblemBase.C.

Referenced by TransientBase::convergedToSteadyState(), FEProblemSolve::convergenceSetup(), FixedPointSolve::examineFixedPointConvergence(), FixedPointIterationAdaptiveDT::init(), TransientBase::init(), ParsedConvergence::initializeConvergenceSymbol(), SteffensenSolve::initialSetup(), FixedPointSolve::initialSetup(), Moose::PetscSupport::petscLinearConverged(), Moose::PetscSupport::petscNonlinearConverged(), FixedPointSolve::solve(), and FixedPointSolve::solveStep().

2774 {
2775  auto * const ret = dynamic_cast<Convergence *>(_convergences.getActiveObject(name, tid).get());
2776  if (!ret)
2777  mooseError("The Convergence object '", name, "' does not exist.");
2778 
2779  return *ret;
2780 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MooseObjectWarehouse< Convergence > _convergences
convergence warehouse
std::shared_ptr< T > getActiveObject(const std::string &name, THREAD_ID tid=0) const
Base class for convergence criteria.
Definition: Convergence.h:21
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getConvergenceObjects()

const std::vector< std::shared_ptr< Convergence > > & FEProblemBase::getConvergenceObjects ( const THREAD_ID  tid = 0) const
virtualinherited

Gets the Convergence objects.

Definition at line 2783 of file FEProblemBase.C.

2784 {
2785  return _convergences.getActiveObjects(tid);
2786 }
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
MooseObjectWarehouse< Convergence > _convergences
convergence warehouse

◆ getCoordSystem()

Moose::CoordinateSystemType SubProblem::getCoordSystem ( SubdomainID  sid) const
inherited

Definition at line 1283 of file SubProblem.C.

Referenced by BlockRestrictable::getBlockCoordSystem(), MultiApp::getBoundingBox(), Assembly::reinitLowerDElem(), Assembly::reinitNeighborLowerDElem(), and Assembly::setCoordinateTransformation().

1284 {
1285  return mesh().getCoordSystem(sid);
1286 }
virtual MooseMesh & mesh()=0
Moose::CoordinateSystemType getCoordSystem(SubdomainID sid) const
Get the coordinate system type, e.g.
Definition: MooseMesh.C:4295

◆ getCurrentAlgebraicBndNodeRange()

const ConstBndNodeRange & FEProblemBase::getCurrentAlgebraicBndNodeRange ( )
inherited

◆ getCurrentAlgebraicElementRange()

const ConstElemRange & FEProblemBase::getCurrentAlgebraicElementRange ( )
inherited

These are the element and nodes that contribute to the jacobian and residual for this local processor.

getCurrentAlgebraicElementRange() returns the element range that contributes to the system getCurrentAlgebraicNodeRange() returns the node range that contributes to the system getCurrentAlgebraicBndNodeRange returns the boundary node ranges that contributes to the system

Definition at line 9990 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeDamping(), FEProblemBase::computeIndicators(), NonlinearSystemBase::computeJacobianBlocks(), NonlinearSystemBase::computeJacobianInternal(), FEProblemBase::computeMarkers(), NonlinearSystemBase::computeResidualAndJacobianInternal(), NonlinearSystemBase::computeResidualInternal(), NonlinearSystemBase::computeScaling(), FEProblemBase::computeUserObjectsInternal(), FEProblemBase::initialSetup(), FEProblemBase::projectSolution(), and FEProblemBase::updateMaxQps().

9991 {
9994 
9996 }
std::unique_ptr< libMesh::ConstElemRange > _current_algebraic_elem_range
MooseMesh & _mesh
const libMesh::ConstElemRange * getActiveLocalElementRange()
Return pointers to range objects for various types of ranges (local nodes, boundary elems...
Definition: MooseMesh.C:1240

◆ getCurrentAlgebraicNodeRange()

const ConstNodeRange & FEProblemBase::getCurrentAlgebraicNodeRange ( )
inherited

Definition at line 9998 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeDamping(), NonlinearSystemBase::computeJacobianInternal(), NonlinearSystemBase::computeResidualInternal(), FEProblemBase::computeUserObjectsInternal(), and FEProblemBase::initialSetup().

9999 {
10001  return *_mesh.getLocalNodeRange();
10002 
10004 }
std::unique_ptr< libMesh::ConstNodeRange > _current_algebraic_node_range
libMesh::ConstNodeRange * getLocalNodeRange()
Definition: MooseMesh.C:1269
MooseMesh & _mesh

◆ getCurrentExecuteOnFlag()

const ExecFlagType & FEProblemBase::getCurrentExecuteOnFlag ( ) const
inherited

Return/set the current execution flag.

Returns EXEC_NONE when not being executed.

See also
FEProblemBase::execute

Definition at line 5051 of file FEProblemBase.C.

Referenced by MultiAppGeneralFieldTransfer::acceptPointInOriginMesh(), MultiAppTransfer::checkParentAppUserObjectExecuteOn(), MultiAppGeneralFieldTransfer::closestToPosition(), MultiAppGeneralFieldKDTreeTransferBase::computeNumSources(), CartesianGridDivision::divisionIndex(), CylindricalGridDivision::divisionIndex(), SphericalGridDivision::divisionIndex(), NearestPositionsDivision::divisionIndex(), PositionsFunctorValueSampler::execute(), PIDTransientControl::execute(), Terminator::execute(), Control::getControllableParameterByName(), Material::getMaterialByName(), MultiAppGeneralFieldKDTreeTransferBase::getNumDivisions(), NumPositions::getValue(), PositionsFunctorValueSampler::initialize(), DistributedPositions::initialize(), TransformedPositions::initialize(), ParsedDownSelectionPositions::initialize(), MultiAppGeneralFieldTransfer::locatePointReceivers(), ComputeUserObjectsThread::printBlockExecutionInformation(), ComputeFVInitialConditionThread::printGeneralExecutionInformation(), ComputeInitialConditionThread::printGeneralExecutionInformation(), ComputeNodalUserObjectsThread::printGeneralExecutionInformation(), ComputeNodalKernelBcsThread::printGeneralExecutionInformation(), ComputeNodalKernelsThread::printGeneralExecutionInformation(), ComputeElemDampingThread::printGeneralExecutionInformation(), ComputeNodalKernelBCJacobiansThread::printGeneralExecutionInformation(), ComputeMarkerThread::printGeneralExecutionInformation(), ComputeNodalDampingThread::printGeneralExecutionInformation(), ComputeDiracThread::printGeneralExecutionInformation(), ComputeIndicatorThread::printGeneralExecutionInformation(), ComputeNodalKernelJacobiansThread::printGeneralExecutionInformation(), ComputeThreadedGeneralUserObjectsThread::printGeneralExecutionInformation(), ComputeUserObjectsThread::printGeneralExecutionInformation(), ComputeLinearFVElementalThread::printGeneralExecutionInformation(), ComputeLinearFVFaceThread::printGeneralExecutionInformation(), NonlinearThread::printGeneralExecutionInformation(), MultiApp::restore(), SolutionInvalidityOutput::shouldOutput(), ElementReporter::shouldStore(), NodalReporter::shouldStore(), and GeneralReporter::shouldStore().

5052 {
5053  return _current_execute_on_flag;
5054 }
ExecFlagType _current_execute_on_flag
Current execute_on flag.

◆ getCurrentICState()

unsigned short FEProblemBase::getCurrentICState ( )
inherited

Retrieves the current initial condition state.

Returns
current initial condition state

Definition at line 10049 of file FEProblemBase.C.

Referenced by ComputeInitialConditionThread::operator()().

10050 {
10051  return _current_ic_state;
10052 }
unsigned short _current_ic_state

◆ getDataFileName()

std::string DataFileInterface::getDataFileName ( const std::string &  param) const
inherited

Deprecated method.

The data file paths are now automatically set within the InputParameters object, so using getParam<DataFileName>("param_name") is now sufficient.

Definition at line 21 of file DataFileInterface.C.

22 {
23  _parent.mooseDeprecated("getDataFileName() is deprecated. The file path is now directly set "
24  "within the InputParameters.\nUse getParam<DataFileName>(\"",
25  param,
26  "\") instead.");
27  return _parent.getParam<DataFileName>(param);
28 }
const T & getParam(const std::string &name) const
Retrieve a parameter for the object.
Definition: MooseBase.h:406
void mooseDeprecated(Args &&... args) const
Emits a deprecation warning prefixed with the object name and type, and a stack trace.
Definition: MooseBase.h:317
const ParallelParamObject & _parent

◆ getDataFileNameByName()

std::string DataFileInterface::getDataFileNameByName ( const std::string &  relative_path) const
inherited

Deprecated method.

Use getDataFilePath() instead.

Definition at line 31 of file DataFileInterface.C.

32 {
33  _parent.mooseDeprecated("getDataFileNameByName() is deprecated. Use getDataFilePath(\"",
34  relative_path,
35  "\") instead.");
36  return getDataFilePath(relative_path);
37 }
std::string getDataFilePath(const std::string &relative_path) const
Returns the path of a data file for a given relative file path.
void mooseDeprecated(Args &&... args) const
Emits a deprecation warning prefixed with the object name and type, and a stack trace.
Definition: MooseBase.h:317
const ParallelParamObject & _parent

◆ getDataFilePath()

std::string DataFileInterface::getDataFilePath ( const std::string &  relative_path) const
inherited

Returns the path of a data file for a given relative file path.

This can be used for hardcoded datafile names and will search the same locations as getDataFileName

Definition at line 40 of file DataFileInterface.C.

Referenced by DataFileInterface::getDataFileNameByName().

41 {
42  // This should only ever be used with relative paths. There is no point to
43  // use this search path with an absolute path.
44  if (std::filesystem::path(relative_path).is_absolute())
45  _parent.mooseWarning("While using getDataFilePath(\"",
46  relative_path,
47  "\"): This API should not be used for absolute paths.");
48 
49  // This will search the data paths for this relative path
50  std::optional<std::string> error;
51  Moose::DataFileUtils::Path found_path;
52  {
53  // Throw on error so that if getPath() fails, we can throw an error
54  // with the context of _parent.mooseError()
55  Moose::ScopedThrowOnError scoped_throw_on_error;
56 
57  try
58  {
59  found_path = Moose::DataFileUtils::getPath(relative_path);
60  }
61  catch (std::exception & e)
62  {
63  error = e.what();
64  }
65  }
66 
67  if (error)
68  _parent.mooseError(*error);
69 
70  mooseAssert(found_path.context == Moose::DataFileUtils::Context::DATA,
71  "Should only ever obtain data");
72  mooseAssert(found_path.data_name, "Should be set");
73 
74  const std::string msg =
75  "Using data file '" + found_path.path + "' from " + *found_path.data_name + " data";
76  _parent.mooseInfo(msg);
77 
78  return found_path.path;
79 }
void mooseInfo(Args &&... args) const
Definition: MooseBase.h:334
Context context
Context for the file (where it came from)
Definition: DataFileUtils.h:52
From installed/in-tree data.
Path getPath(std::string path, const GetPathOptions &options={})
Get the data path for a given path, searching the registered data.
Definition: DataFileUtils.C:22
Representation of a data file path.
Definition: DataFileUtils.h:40
std::optional< std::string > data_name
The name of the data registry the file came from (with context == DATA)
Definition: DataFileUtils.h:54
Scoped helper for setting Moose::_throw_on_error during this scope.
Definition: Moose.h:297
void mooseWarning(Args &&... args) const
Emits a warning prefixed with object name and type.
Definition: MooseBase.h:299
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
const ParallelParamObject & _parent

◆ getDiracElements()

void FEProblemBase::getDiracElements ( std::set< const Elem *> &  elems)
overridevirtualinherited

Fills "elems" with the elements that should be looped over for Dirac Kernels.

Implements SubProblem.

Definition at line 2586 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeDiracContributions().

2587 {
2588  // First add in the undisplaced elements
2589  elems = _dirac_kernel_info.getElements();
2590 
2591  if (_displaced_problem)
2592  {
2593  std::set<const Elem *> displaced_elements;
2594  _displaced_problem->getDiracElements(displaced_elements);
2595 
2596  { // Use the ids from the displaced elements to get the undisplaced elements
2597  // and add them to the list
2598  for (const auto & elem : displaced_elements)
2599  elems.insert(_mesh.elemPtr(elem->id()));
2600  }
2601  }
2602 }
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
MooseMesh & _mesh
std::shared_ptr< DisplacedProblem > _displaced_problem
std::set< const Elem * > & getElements()
Returns a writeable reference to the _elements container.
DiracKernelInfo _dirac_kernel_info
Definition: SubProblem.h:1064

◆ getDiscreteMaterialWarehouse()

const MaterialWarehouse& FEProblemBase::getDiscreteMaterialWarehouse ( ) const
inlineinherited

Definition at line 2306 of file FEProblemBase.h.

2306 { return _discrete_materials; }
MaterialWarehouse _discrete_materials

◆ getDisplacedProblem() [1/2]

virtual std::shared_ptr<const DisplacedProblem> FEProblemBase::getDisplacedProblem ( ) const
inlinevirtualinherited

Definition at line 1989 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::assembleScalingVector(), MooseApp::attachRelationshipManagers(), NonlinearSystemBase::augmentSparsity(), NonlinearSystemBase::computeJacobianInternal(), NonlinearSystemBase::computeResidualAndJacobianInternal(), NonlinearSystemBase::computeResidualInternal(), NonlinearSystemBase::computeScaling(), NonlinearSystemBase::constraintJacobians(), NonlinearSystemBase::constraintResiduals(), MultiApp::createApp(), DMMooseGetEmbedding_Private(), DMSetUp_Moose_Pre(), ActivateElementsUserObjectBase::execute(), MultiAppUserObjectTransfer::execute(), ActivateElementsUserObjectBase::finalize(), RadialAverage::finalize(), MultiApp::getBoundingBox(), MultiAppFieldTransfer::getEquationSystem(), MFEMMultiAppTransfer::getlibMeshEquationSystem(), Exodus::handleExodusIOMeshRenumbering(), EigenExecutionerBase::init(), Adaptivity::init(), NonlinearSystemBase::initialSetup(), FEProblemBase::initialSetup(), EigenExecutionerBase::inversePowerIteration(), Output::Output(), Exodus::outputSetup(), NonlinearSystemBase::overwriteNodeFace(), NonlinearSystemBase::reinitNodeFace(), NonlinearSystemBase::setConstraintSecondaryValues(), NonlinearSystemBase::setInitialSolution(), ActivateElementsUserObjectBase::setNewBoundayName(), and Moose::PeriodicBCHelper::setupPeriodicBoundaries().

1990  {
1991  return _displaced_problem;
1992  }
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ getDisplacedProblem() [2/2]

virtual std::shared_ptr<DisplacedProblem> FEProblemBase::getDisplacedProblem ( )
inlinevirtualinherited

Definition at line 1993 of file FEProblemBase.h.

1993 { return _displaced_problem; }
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ getDistribution()

Distribution & FEProblemBase::getDistribution ( const std::string &  name)
virtualinherited

Definition at line 2855 of file FEProblemBase.C.

Referenced by DistributionInterface::getDistribution(), and DistributionInterface::getDistributionByName().

2856 {
2857  std::vector<Distribution *> objs;
2858  theWarehouse()
2859  .query()
2860  .condition<AttribSystem>("Distribution")
2861  .condition<AttribName>(name)
2862  .queryInto(objs);
2863  if (objs.empty())
2864  {
2865  mooseAssert(getMooseApp().actionWarehouse().isTaskComplete("add_distribution"),
2866  "A Distribution getter was called before Distributions have been constructed. "
2867  "If you are attempting to access this object in the constructor of another object "
2868  "then make sure that the Distribution is constructed before the object using it.");
2869  mooseError("Unable to find Distribution with name '" + name + "'");
2870  }
2871  return *(objs[0]);
2872 }
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getEvaluableElementRange()

const ConstElemRange & FEProblemBase::getEvaluableElementRange ( )
inherited

In general, {evaluable elements} >= {local elements} U {algebraic ghosting elements}.

That is, the number of evaluable elements does NOT necessarily equal to the number of local and algebraic ghosting elements. For example, if using a Lagrange basis for all variables, if a non-local, non-algebraically-ghosted element is surrounded by neighbors which are local or algebraically ghosted, then all the nodal (Lagrange) degrees of freedom associated with the non-local, non-algebraically-ghosted element will be evaluable, and hence that element will be considered evaluable.

getNonlinearEvaluableElementRange() returns the evaluable element range based on the nonlinear system dofmap; getAuxliaryEvaluableElementRange() returns the evaluable element range based on the auxiliary system dofmap; getEvaluableElementRange() returns the element range that is evaluable based on both the nonlinear dofmap and the auxliary dofmap.

Definition at line 880 of file FEProblemBase.C.

Referenced by NodalPatchRecoveryBase::gatherRequestList().

881 {
883  {
884  std::vector<const DofMap *> dof_maps(es().n_systems());
885  for (const auto i : make_range(es().n_systems()))
886  {
887  const auto & sys = es().get_system(i);
888  dof_maps[i] = &sys.get_dof_map();
889  }
891  std::make_unique<ConstElemRange>(_mesh.getMesh().multi_evaluable_elements_begin(dof_maps),
892  _mesh.getMesh().multi_evaluable_elements_end(dof_maps));
893  }
895 }
const T_sys & get_system(std::string_view name) const
MeshBase & getMesh()
Accessor for the underlying libMesh Mesh object.
Definition: MooseMesh.C:3548
virtual libMesh::EquationSystems & es() override
MooseMesh & _mesh
IntRange< T > make_range(T beg, T end)
std::unique_ptr< libMesh::ConstElemRange > _evaluable_local_elem_range

◆ getExecutor()

virtual Executor& FEProblemBase::getExecutor ( const std::string &  name)
inlinevirtualinherited

Definition at line 2438 of file FEProblemBase.h.

2438 { return _app.getExecutor(name); }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
Executor * getExecutor() const
Definition: MooseApp.h:341

◆ getFailNextNonlinearConvergenceCheck()

bool FEProblemBase::getFailNextNonlinearConvergenceCheck ( ) const
inlineinherited

Whether it will skip further residual evaluations and fail the next nonlinear convergence check(s)

Definition at line 2857 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::computeScaling(), NonlinearSystem::converged(), Moose::PetscSupport::petscNonlinearConverged(), and ComputeResidualFunctor::residual().

bool getFailNextSystemConvergenceCheck() const
Whether it will fail the next system convergence check(s), triggering failed step behavior...

◆ getFailNextSystemConvergenceCheck()

bool FEProblemBase::getFailNextSystemConvergenceCheck ( ) const
inlineinherited

Whether it will fail the next system convergence check(s), triggering failed step behavior.

Definition at line 2859 of file FEProblemBase.h.

Referenced by FEProblemBase::getFailNextNonlinearConvergenceCheck(), and Moose::PetscSupport::petscLinearConverged().

bool _fail_next_system_convergence_check

◆ getFunction()

Function & FEProblemBase::getFunction ( const std::string &  name,
const THREAD_ID  tid = 0 
)
virtualinherited

Definition at line 2715 of file FEProblemBase.C.

Referenced by addFunction(), FunctionInterface::getFunctionByName(), FunctionPeriodicBoundary::getFunctions(), IterationAdaptiveDT::init(), MooseParsedFunctionWrapper::initialize(), ChainControlParsedFunctionWrapper::initializeFunctionInputs(), and ParsedConvergence::initializeFunctionSymbol().

2716 {
2717  // This thread lock is necessary since this method will create functions
2718  // for all threads if one is missing.
2719  Threads::spin_mutex::scoped_lock lock(get_function_mutex);
2720 
2721  if (!hasFunction(name, tid))
2722  {
2723  // If we didn't find a function, it might be a default function, attempt to construct one now
2724  std::istringstream ss(name);
2725  Real real_value;
2726 
2727  // First see if it's just a constant. If it is, build a ConstantFunction
2728  if (ss >> real_value && ss.eof())
2729  {
2730  InputParameters params = _factory.getValidParams("ConstantFunction");
2731  params.set<Real>("value") = real_value;
2732  addFunction("ConstantFunction", ss.str(), params);
2733  }
2734  else
2735  {
2737  std::string vars = "x,y,z,t,NaN,pi,e";
2738  if (fp.Parse(name, vars) == -1) // -1 for success
2739  {
2740  // It parsed ok, so build a MooseParsedFunction
2741  InputParameters params = _factory.getValidParams("ParsedFunction");
2742  params.set<std::string>("expression") = name;
2743  addFunction("ParsedFunction", name, params);
2744  }
2745  }
2746 
2747  // Try once more
2748  if (!hasFunction(name, tid))
2749  {
2750  mooseAssert(getMooseApp().actionWarehouse().isTaskComplete("add_function"),
2751  "getFunction() was called before Functions have been constructed. The requested "
2752  "Function '" +
2753  name + "' may exist in the input file, but Functions are not available yet.");
2754 
2755  mooseError("Unable to find function " + name);
2756  }
2757  }
2758 
2759  auto * const ret = dynamic_cast<Function *>(_functions.getActiveObject(name, tid).get());
2760  if (!ret)
2761  mooseError("No function named ", name, " of appropriate type");
2762 
2763  return *ret;
2764 }
Base class for function objects.
Definition: Function.h:29
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
Threads::spin_mutex get_function_mutex
char ** vars
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< T > getActiveObject(const std::string &name, THREAD_ID tid=0) const
virtual void addFunction(const std::string &type, const std::string &name, InputParameters &parameters)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
MooseObjectWarehouse< Function > _functions
functions
virtual bool hasFunction(const std::string &name, const THREAD_ID tid=0)

◆ getFunctionWarehouse()

const MooseObjectWarehouse<Function>& FEProblemBase::getFunctionWarehouse ( )
inlineinherited

Definition at line 2295 of file FEProblemBase.h.

2295 { return _functions; }
MooseObjectWarehouse< Function > _functions
functions

◆ getFunctor()

template<typename T >
const Moose::Functor< T > & SubProblem::getFunctor ( const std::string &  name,
const THREAD_ID  tid,
const std::string &  requestor_name,
bool  requestor_is_ad 
)
inherited
Template Parameters
TThe type that the functor will return when evaluated, e.g. ADReal or Real
Parameters
nameThe name of the functor to retrieve
tidThe thread ID that we are retrieving the functor property for
requestor_nameThe name of the object that is requesting this functor property
requestor_is_adWhether the requesting object is an AD object
Returns
a constant reference to the functor

Definition at line 1232 of file SubProblem.h.

Referenced by FunctorInterface::getFunctorByName().

1236 {
1237  mooseAssert(tid < _functors.size(), "Too large a thread ID");
1238 
1239  // Log the requestor
1240  _functor_to_requestors["wraps_" + name].insert(requestor_name);
1241 
1242  constexpr bool requested_functor_is_ad =
1243  !std::is_same<T, typename MetaPhysicL::RawType<T>::value_type>::value;
1244 
1245  auto & functor_to_request_info = _functor_to_request_info[tid];
1246 
1247  // Get the requested functor if we already have it
1248  auto & functors = _functors[tid];
1249  if (auto find_ret = functors.find("wraps_" + name); find_ret != functors.end())
1250  {
1251  if (functors.count("wraps_" + name) > 1)
1252  mooseError("Attempted to get a functor with the name '",
1253  name,
1254  "' but multiple (" + std::to_string(functors.count("wraps_" + name)) +
1255  ") functors match. Make sure that you do not have functor material "
1256  "properties, functions, postprocessors or variables with the same names.");
1257 
1258  auto & [true_functor_is, non_ad_functor, ad_functor] = find_ret->second;
1259  auto & functor_wrapper = requested_functor_is_ad ? *ad_functor : *non_ad_functor;
1260 
1261  auto * const functor = dynamic_cast<Moose::Functor<T> *>(&functor_wrapper);
1262  if (!functor)
1263  mooseError("A call to SubProblem::getFunctor requested a functor named '",
1264  name,
1265  "' that returns the type: '",
1266  libMesh::demangle(typeid(T).name()),
1267  "'. However, that functor already exists and returns a different type: '",
1268  functor_wrapper.returnType(),
1269  "'");
1270 
1271  if (functor->template wrapsType<Moose::NullFunctor<T>>())
1272  // Store for future checking when the actual functor gets added
1273  functor_to_request_info.emplace(name,
1274  std::make_pair(requested_functor_is_ad, requestor_is_ad));
1275  else
1276  {
1277  // We already have the actual functor
1278  if (true_functor_is == SubProblem::TrueFunctorIs::UNSET)
1279  mooseError("We already have the functor; it should not be unset");
1280 
1281  // Check for whether this is a valid request
1282  // We allow auxiliary variables and linear variables to be retrieved as non AD
1283  if (!requested_functor_is_ad && requestor_is_ad &&
1284  true_functor_is == SubProblem::TrueFunctorIs::AD &&
1286  mooseError("The AD object '",
1287  requestor_name,
1288  "' is requesting the functor '",
1289  name,
1290  "' as a non-AD functor even though it is truly an AD functor, which is not "
1291  "allowed, since this may unintentionally drop derivatives.");
1292  }
1293 
1294  return *functor;
1295  }
1296 
1297  // We don't have the functor yet but we could have it in the future. We'll create null functors
1298  // for now
1299  functor_to_request_info.emplace(name, std::make_pair(requested_functor_is_ad, requestor_is_ad));
1300  if constexpr (requested_functor_is_ad)
1301  {
1302  typedef typename MetaPhysicL::RawType<T>::value_type NonADType;
1303  typedef T ADType;
1304 
1305  auto emplace_ret =
1306  functors.emplace("wraps_" + name,
1307  std::make_tuple(SubProblem::TrueFunctorIs::UNSET,
1308  std::make_unique<Moose::Functor<NonADType>>(
1309  std::make_unique<Moose::NullFunctor<NonADType>>()),
1310  std::make_unique<Moose::Functor<ADType>>(
1311  std::make_unique<Moose::NullFunctor<ADType>>())));
1312 
1313  return static_cast<Moose::Functor<T> &>(*(requested_functor_is_ad
1314  ? std::get<2>(emplace_ret->second)
1315  : std::get<1>(emplace_ret->second)));
1316  }
1317  else
1318  {
1319  typedef T NonADType;
1320  typedef typename Moose::ADType<T>::type ADType;
1321 
1322  auto emplace_ret =
1323  functors.emplace("wraps_" + name,
1324  std::make_tuple(SubProblem::TrueFunctorIs::UNSET,
1325  std::make_unique<Moose::Functor<NonADType>>(
1326  std::make_unique<Moose::NullFunctor<NonADType>>()),
1327  std::make_unique<Moose::Functor<ADType>>(
1328  std::make_unique<Moose::NullFunctor<ADType>>())));
1329 
1330  return static_cast<Moose::Functor<T> &>(*(requested_functor_is_ad
1331  ? std::get<2>(emplace_ret->second)
1332  : std::get<1>(emplace_ret->second)));
1333  }
1334 }
std::map< std::string, std::set< std::string > > _functor_to_requestors
The requestors of functors where the key is the prop name and the value is a set of names of requesto...
Definition: SubProblem.h:1172
This is a wrapper that forwards calls to the implementation, which can be switched out at any time wi...
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::vector< std::multimap< std::string, std::pair< bool, bool > > > _functor_to_request_info
A multimap (for each thread) from unfilled functor requests to whether the requests were for AD funct...
Definition: SubProblem.h:1176
std::string demangle(const char *name)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::vector< std::multimap< std::string, std::tuple< TrueFunctorIs, std::unique_ptr< Moose::FunctorEnvelopeBase >, std::unique_ptr< Moose::FunctorEnvelopeBase > > > > _functors
A container holding pointers to all the functors in our problem.
Definition: SubProblem.h:1159
virtual bool hasLinearVariable(const std::string &var_name) const
Whether or not this problem has this linear variable.
Definition: SubProblem.C:803
A functor that serves as a placeholder during the simulation setup phase if a functor consumer reques...
virtual bool hasAuxiliaryVariable(const std::string &var_name) const
Whether or not this problem has this auxiliary variable.
Definition: SubProblem.C:812

◆ getFVAdvectedInterpolationMethod()

const FVAdvectedInterpolationMethod & FEProblemBase::getFVAdvectedInterpolationMethod ( const InterpolationMethodName &  name,
const THREAD_ID  tid = 0 
) const
inherited

Retrieve an advected interpolation method.

Parameters
nameThe name of the method.
tidThe thread ID.

Definition at line 4831 of file FEProblemBase.C.

Referenced by FVInterpolationMethodInterface::getFVAdvectedInterpolationMethod().

4833 {
4834  const auto & method = getFVInterpolationMethod(name, tid);
4835  const auto * advected_method = dynamic_cast<const FVAdvectedInterpolationMethod *>(&method);
4836 
4837  if (!advected_method)
4838  mooseError("FVInterpolationMethod '",
4839  name,
4840  "' (",
4841  method.type(),
4842  ") is not an advected interpolation method.");
4843 
4844  return *advected_method;
4845 }
Interface for interpolation methods that provide matrix and RHS contributions for advected face value...
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const FVInterpolationMethod & getFVInterpolationMethod(const InterpolationMethodName &name, const THREAD_ID tid=0) const
Retrieve an FV interpolation method.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getFVFaceInterpolationMethod()

const FVFaceInterpolationMethod & FEProblemBase::getFVFaceInterpolationMethod ( const InterpolationMethodName &  name,
const THREAD_ID  tid = 0 
) const
inherited

Retrieve a scalar face interpolation method.

Parameters
nameThe name of the method.
tidThe thread ID.

Definition at line 4814 of file FEProblemBase.C.

Referenced by FVInterpolationMethodInterface::getFVFaceInterpolationMethod().

4816 {
4817  const auto & method = getFVInterpolationMethod(name, tid);
4818  const auto * face_method = dynamic_cast<const FVFaceInterpolationMethod *>(&method);
4819 
4820  if (!face_method)
4821  mooseError("FVInterpolationMethod '",
4822  name,
4823  "' (",
4824  method.type(),
4825  ") is not a scalar face interpolation method.");
4826 
4827  return *face_method;
4828 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const FVInterpolationMethod & getFVInterpolationMethod(const InterpolationMethodName &name, const THREAD_ID tid=0) const
Retrieve an FV interpolation method.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
Abstract base class for interpolation methods that produce a scalar face value from adjacent cell val...

◆ getFVInitialConditionWarehouse()

const FVInitialConditionWarehouse& FEProblemBase::getFVInitialConditionWarehouse ( ) const
inlineinherited

◆ getFVInterpolationMethod()

const FVInterpolationMethod & FEProblemBase::getFVInterpolationMethod ( const InterpolationMethodName &  name,
const THREAD_ID  tid = 0 
) const
inherited

Retrieve an FV interpolation method.

Parameters
nameThe name of the method.
tidThe thread ID.

Definition at line 4787 of file FEProblemBase.C.

Referenced by FEProblemBase::getFVAdvectedInterpolationMethod(), and FEProblemBase::getFVFaceInterpolationMethod().

4789 {
4790  std::vector<FVInterpolationMethod *> methods;
4791  theWarehouse()
4792  .query()
4793  .condition<AttribSystem>("FVInterpolationMethod")
4794  .condition<AttribThread>(tid)
4795  .condition<AttribName>(name)
4796  .queryInto(methods);
4797 
4798  if (methods.empty())
4799  {
4800  mooseAssert(getMooseApp().actionWarehouse().isTaskComplete("add_interpolation_method"),
4801  "An FVInterpolationMethod getter was called before FVInterpolationMethods have "
4802  "been constructed. If you are attempting to access this object in the constructor "
4803  "of another object then make sure that the FVInterpolationMethod is constructed "
4804  "before the object using it.");
4805 
4806  mooseError("Unable to find FVInterpolationMethod with name '", name, "'");
4807  }
4808 
4809  mooseAssert(methods.size() == 1, "Expected a single FVInterpolationMethod per thread");
4810  return *(methods[0]);
4811 }
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getFVMatsAndDependencies()

void FEProblemBase::getFVMatsAndDependencies ( SubdomainID  block_id,
std::vector< std::shared_ptr< MaterialBase >> &  face_materials,
std::vector< std::shared_ptr< MaterialBase >> &  neighbor_materials,
std::set< MooseVariableFieldBase *> &  variables,
const THREAD_ID  tid 
)
inherited

Get the materials and variables potentially needed for FV.

Parameters
block_idSubdomainID The subdomain id that we want to retrieve materials for
face_materialsThe face materials container that we will fill
neighbor_materialsThe neighbor materials container that we will fill
variablesThe variables container that we will fill that our materials depend on
tidThe thread id

Definition at line 9685 of file FEProblemBase.C.

9691 {
9692  if (_materials[Moose::FACE_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
9693  {
9694  auto & this_face_mats =
9696  for (std::shared_ptr<MaterialBase> face_mat : this_face_mats)
9697  if (face_mat->ghostable())
9698  {
9699  face_materials.push_back(face_mat);
9700  auto & var_deps = face_mat->getMooseVariableDependencies();
9701  for (auto * var : var_deps)
9702  {
9703  if (!var->isFV())
9704  mooseError(
9705  "Ghostable materials should only have finite volume variables coupled into them.");
9706  else if (face_mat->hasStatefulProperties())
9707  mooseError("Finite volume materials do not currently support stateful properties.");
9708  variables.insert(var);
9709  }
9710  }
9711  }
9712 
9713  if (_materials[Moose::NEIGHBOR_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
9714  {
9715  auto & this_neighbor_mats =
9717  for (std::shared_ptr<MaterialBase> neighbor_mat : this_neighbor_mats)
9718  if (neighbor_mat->ghostable())
9719  {
9720  neighbor_materials.push_back(neighbor_mat);
9721 #ifndef NDEBUG
9722  auto & var_deps = neighbor_mat->getMooseVariableDependencies();
9723  for (auto * var : var_deps)
9724  {
9725  if (!var->isFV())
9726  mooseError(
9727  "Ghostable materials should only have finite volume variables coupled into them.");
9728  else if (neighbor_mat->hasStatefulProperties())
9729  mooseError("Finite volume materials do not currently support stateful properties.");
9730  auto pr = variables.insert(var);
9731  mooseAssert(!pr.second,
9732  "We should not have inserted any new variables dependencies from our "
9733  "neighbor materials that didn't exist for our face materials");
9734  }
9735 #endif
9736  }
9737  }
9738 }
const std::map< SubdomainID, std::vector< std::shared_ptr< T > > > & getActiveBlockObjects(THREAD_ID tid=0) const
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
MaterialWarehouse _materials

◆ getGridFunction()

std::shared_ptr<mfem::ParGridFunction> MFEMProblem::getGridFunction ( const std::string &  name)
inline
Returns
a shared pointer to an MFEM parallel grid function

Definition at line 340 of file MFEMProblem.h.

Referenced by MFEML2ZienkiewiczZhuIndicator::createEstimator(), MFEMScalarIC::execute(), MFEMVectorIC::execute(), MFEMScalarBoundaryIC::execute(), MFEMSumAux::MFEMSumAux(), MultiAppMFEMCopyTransfer::transferVariables(), MultiApplibMeshToMFEMShapeEvaluationTransfer::transferVariables(), MultiAppMFEMShapeEvaluationTransfer::transferVariables(), and MultiAppMFEMTolibMeshShapeEvaluationTransfer::transferVariables().

341  {
343  }
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< T > GetShared(const std::string &field_name) const
Returns a shared pointer to the field. This is guaranteed to return a non-null shared pointer...
Moose::MFEM::GridFunctions gridfunctions

◆ getHitNode()

const hit::Node* MooseBase::getHitNode ( ) const
inlineinherited
Returns
The block-level hit node for this object, if any

Definition at line 136 of file MooseBase.h.

Referenced by FEProblemBase::addAnyRedistributers(), MooseBase::callMooseError(), MooseBase::getHitNode(), and MooseBase::messagePrefix().

136 { return getHitNode(_pars); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
const hit::Node * getHitNode() const
Definition: MooseBase.h:136

◆ getIndicatorWarehouse()

const MooseObjectWarehouse<Indicator>& FEProblemBase::getIndicatorWarehouse ( )
inlineinherited

Return indicator/marker storage.

Definition at line 2085 of file FEProblemBase.h.

2085 { return _indicators; }
MooseObjectWarehouse< Indicator > _indicators

◆ getInitialConditionWarehouse()

const InitialConditionWarehouse& FEProblemBase::getInitialConditionWarehouse ( ) const
inlineinherited

◆ getInterfaceMaterialsWarehouse()

const MaterialWarehouse& FEProblemBase::getInterfaceMaterialsWarehouse ( ) const
inlineinherited

Definition at line 2307 of file FEProblemBase.h.

2307 { return _interface_materials; }
MaterialWarehouse _interface_materials

◆ getInternalSideIndicatorWarehouse()

const MooseObjectWarehouse<InternalSideIndicatorBase>& FEProblemBase::getInternalSideIndicatorWarehouse ( )
inlineinherited

Definition at line 2086 of file FEProblemBase.h.

2087  {
2089  }
MooseObjectWarehouse< InternalSideIndicatorBase > _internal_side_indicators

◆ getKokkosBndMaterialPropertyStorage()

Moose::Kokkos::MaterialPropertyStorage& FEProblemBase::getKokkosBndMaterialPropertyStorage ( )
inlineinherited

Definition at line 2070 of file FEProblemBase.h.

2071  {
2073  }
Moose::Kokkos::MaterialPropertyStorage & _kokkos_bnd_material_props

◆ getKokkosFESystem() [1/2]

Moose::Kokkos::FESystem& FEProblemBase::getKokkosFESystem ( const unsigned int  sys_num)
inherited

Get the Kokkos FESystem of a specified number.

Parameters
sys_numThe system number
Returns
The Kokkos FESystem

◆ getKokkosFESystem() [2/2]

const Moose::Kokkos::FESystem& FEProblemBase::getKokkosFESystem ( const unsigned int  sys_num) const
inherited

◆ getKokkosFESystems() [1/2]

Moose::Kokkos::Array<Moose::Kokkos::FESystem>& FEProblemBase::getKokkosFESystems ( )
inlineinherited

Get the Kokkos FESystem array (populated only when FE Kokkos objects exist)

Returns
The array of Kokkos FESystem objects

Definition at line 882 of file FEProblemBase.h.

883  {
884  return _kokkos_fe_systems;
885  }
Moose::Kokkos::Array< Moose::Kokkos::FESystem > _kokkos_fe_systems
FESystem array - sparsely populated (only slots for systems needing a Kokkos::FESystem) ...

◆ getKokkosFESystems() [2/2]

const Moose::Kokkos::Array<Moose::Kokkos::FESystem>& FEProblemBase::getKokkosFESystems ( ) const
inlineinherited

Definition at line 886 of file FEProblemBase.h.

887  {
888  return _kokkos_fe_systems;
889  }
Moose::Kokkos::Array< Moose::Kokkos::FESystem > _kokkos_fe_systems
FESystem array - sparsely populated (only slots for systems needing a Kokkos::FESystem) ...

◆ getKokkosFunction() [1/2]

virtual Moose::Kokkos::Function FEProblemBase::getKokkosFunction ( const std::string &  name)
virtualinherited

Get a Kokkos function in an abstract type.

Parameters
nameThe Kokkos function name
Returns
The copy of the Kokkos function in the abstract type

◆ getKokkosFunction() [2/2]

template<typename T >
T & FEProblemBase::getKokkosFunction ( const std::string &  name)
inherited

Get a Kokkos function in a concrete type.

Template Parameters
TThe Kokkos function type
Parameters
nameThe Kokkos function name
Returns
The reference of the Kokkos function in the concrete type

Definition at line 3845 of file FEProblemBase.h.

3846 {
3847  if (!hasKokkosFunction(name))
3848  {
3849  // If we didn't find a function, it might be a default function, attempt to construct one now
3850  std::istringstream ss(name);
3851  Real real_value;
3852 
3853  // First see if it's just a constant. If it is, build a ConstantFunction
3854  if (ss >> real_value && ss.eof())
3855  {
3856  InputParameters params = _factory.getValidParams("KokkosConstantFunction");
3857  params.set<Real>("value") = real_value;
3858  addKokkosFunction("KokkosConstantFunction", ss.str(), params);
3859  }
3860 
3861  // Try once more
3862  if (!hasKokkosFunction(name))
3863  mooseError("Unable to find Kokkos function '" + name, "'");
3864  }
3865 
3866  auto * const ret = dynamic_cast<T *>(_kokkos_functions.getActiveObject(name).get());
3867  if (!ret)
3868  mooseError("No Kokkos function named '", name, "' of appropriate type");
3869 
3870  return *ret;
3871 }
Factory & _factory
The Factory for building objects.
Definition: SubProblem.h:1062
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
InputParameters getValidParams(const std::string &name) const
Get valid parameters for the object.
Definition: Factory.C:68
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
virtual bool hasKokkosFunction(const std::string &name) const
Get whether a Kokkos function exists.
MooseObjectWarehouse< Moose::FunctionBase > _kokkos_functions
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< T > getActiveObject(const std::string &name, THREAD_ID tid=0) const
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
virtual void addKokkosFunction(const std::string &type, const std::string &name, InputParameters &parameters)
Add a Kokkos function to the problem.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getKokkosMaterialData()

MaterialData& FEProblemBase::getKokkosMaterialData ( Moose::MaterialDataType  type,
const MooseObject object = nullptr 
) const
inherited
Returns
The Kokkos MaterialData for the type type for thread tid

Referenced by BlockRestrictable::initializeBlockRestrictable().

◆ getKokkosMaterialPropertyStorage()

Moose::Kokkos::MaterialPropertyStorage& FEProblemBase::getKokkosMaterialPropertyStorage ( )
inlineinherited

Definition at line 2066 of file FEProblemBase.h.

2067  {
2068  return _kokkos_material_props;
2069  }
Moose::Kokkos::MaterialPropertyStorage & _kokkos_material_props

◆ getKokkosMaterialPropertyStorageConsumers()

const std::set<const MooseObject *>& FEProblemBase::getKokkosMaterialPropertyStorageConsumers ( Moose::MaterialDataType  type) const
inherited
Returns
The consumers of the Kokkos MaterialPropertyStorage for the type type

◆ getKokkosMaterialsWarehouse()

const MaterialWarehouse& FEProblemBase::getKokkosMaterialsWarehouse ( ) const
inlineinherited

Definition at line 2313 of file FEProblemBase.h.

2313 { return _kokkos_materials; }
MaterialWarehouse _kokkos_materials

◆ getKokkosNeighborMaterialPropertyStorage()

Moose::Kokkos::MaterialPropertyStorage& FEProblemBase::getKokkosNeighborMaterialPropertyStorage ( )
inlineinherited

Definition at line 2074 of file FEProblemBase.h.

2075  {
2077  }
Moose::Kokkos::MaterialPropertyStorage & _kokkos_neighbor_material_props

◆ getKokkosSystem() [1/2]

Moose::Kokkos::System& FEProblemBase::getKokkosSystem ( const unsigned int  sys_num)
inherited

Get the Kokkos System of a specified number.

Parameters
sys_numThe system number
Returns
The Kokkos System

◆ getKokkosSystem() [2/2]

const Moose::Kokkos::System& FEProblemBase::getKokkosSystem ( const unsigned int  sys_num) const
inherited

◆ getKokkosSystems() [1/2]

Moose::Kokkos::Array<Moose::Kokkos::System>& FEProblemBase::getKokkosSystems ( )
inlineinherited

Get the Kokkos System array (always populated when any Kokkos object exists)

Returns
The array of Kokkos System objects

Definition at line 870 of file FEProblemBase.h.

870 { return _kokkos_systems; }
Moose::Kokkos::Array< Moose::Kokkos::System > _kokkos_systems
System array - sparsely populated (only slots for systems needing a Kokkos::System) ...

◆ getKokkosSystems() [2/2]

const Moose::Kokkos::Array<Moose::Kokkos::System>& FEProblemBase::getKokkosSystems ( ) const
inlineinherited

Definition at line 871 of file FEProblemBase.h.

872  {
873  return _kokkos_systems;
874  }
Moose::Kokkos::Array< Moose::Kokkos::System > _kokkos_systems
System array - sparsely populated (only slots for systems needing a Kokkos::System) ...

◆ getKokkosUserObject()

template<class T >
const T& FEProblemBase::getKokkosUserObject ( const std::string &  name) const
inlineinherited

Get the Kokkos user object by its name.

Parameters
nameThe name of the Kokkos user object being retrieved
Returns
const reference to the Kokkos user object

Definition at line 1439 of file FEProblemBase.h.

Referenced by UserObjectInterface::getUserObjectFromFEProblem().

1440  {
1441  std::vector<T *> objs;
1442  theWarehouse()
1443  .query()
1444  .condition<AttribSystem>("KokkosUserObject")
1445  .condition<AttribName>(name)
1446  .queryInto(objs);
1447  if (objs.empty())
1448  mooseError("Unable to find Kokkos user object with name '" + name + "'");
1449  return *(objs[0]);
1450  }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getLinearConvergenceNames()

const std::vector< ConvergenceName > & FEProblemBase::getLinearConvergenceNames ( ) const
inherited

Gets the linear convergence object name(s).

Definition at line 9794 of file FEProblemBase.C.

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

9795 {
9797  return *_linear_convergence_names;
9798  mooseError("The linear convergence name(s) have not been set.");
9799 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::optional< std::vector< ConvergenceName > > _linear_convergence_names
Linear system(s) convergence name(s) (if any)

◆ getLinearSystem() [1/2]

LinearSystem & FEProblemBase::getLinearSystem ( unsigned int  sys_num)
inlineinherited

Get non-constant reference to a linear system.

Parameters
sys_numThe number of the linear system

Definition at line 3761 of file FEProblemBase.h.

Referenced by IterationAdaptiveDT::acceptStep(), Moose::compute_linear_system(), Moose::PetscSupport::petscSetDefaults(), and FEProblemSolve::solve().

3762 {
3763  mooseAssert(sys_num < _linear_systems.size(),
3764  "System number greater than the number of linear systems");
3765  return *_linear_systems[sys_num];
3766 }
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.

◆ getLinearSystem() [2/2]

const LinearSystem & FEProblemBase::getLinearSystem ( unsigned int  sys_num) const
inlineinherited

Get a constant reference to a linear system.

Parameters
sys_numThe number of the linear system

Definition at line 3769 of file FEProblemBase.h.

3770 {
3771  mooseAssert(sys_num < _linear_systems.size(),
3772  "System number greater than the number of linear systems");
3773  return *_linear_systems[sys_num];
3774 }
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.

◆ getLinearSystemNames()

const std::vector<LinearSystemName>& FEProblemBase::getLinearSystemNames ( ) const
inlineinherited
Returns
the linear system names in the problem

Definition at line 2938 of file FEProblemBase.h.

Referenced by PhysicsBase::initializePhysics(), and MultiSystemSolveObject::MultiSystemSolveObject().

2938 { return _linear_sys_names; }
const std::vector< LinearSystemName > _linear_sys_names
The linear system names.

◆ getLineSearch()

LineSearch* FEProblemBase::getLineSearch ( )
inlineoverridevirtualinherited

getter for the MOOSE line search

Implements SubProblem.

Definition at line 829 of file FEProblemBase.h.

Referenced by DisplacedProblem::getLineSearch().

829 { return _line_search.get(); }
std::shared_ptr< LineSearch > _line_search

◆ getMarkerWarehouse()

const MooseObjectWarehouse<Marker>& FEProblemBase::getMarkerWarehouse ( )
inlineinherited

Definition at line 2090 of file FEProblemBase.h.

2090 { return _markers; }
MooseObjectWarehouse< Marker > _markers

◆ getMaterial()

std::shared_ptr< MaterialBase > FEProblemBase::getMaterial ( std::string  name,
Moose::MaterialDataType  type,
const THREAD_ID  tid = 0,
bool  no_warn = false 
)
inherited

Return a pointer to a MaterialBase object.

If no_warn is true, suppress warning about retrieving a material reference potentially during the material's calculation.

This will return enabled or disabled objects, the main purpose is for iterative materials.

Definition at line 4000 of file FEProblemBase.C.

Referenced by MaterialPropertyInterface::getMaterialByName().

4004 {
4005  switch (type)
4006  {
4008  name += "_neighbor";
4009  break;
4011  name += "_face";
4012  break;
4013  default:
4014  break;
4015  }
4016 
4017  std::shared_ptr<MaterialBase> material = _all_materials[type].getActiveObject(name, tid);
4018  if (!no_warn && material->getParam<bool>("compute") && type == Moose::BLOCK_MATERIAL_DATA)
4019  mooseWarning("You are retrieving a Material object (",
4020  material->name(),
4021  "), but its compute flag is set to true. This indicates that MOOSE is "
4022  "computing this property which may not be desired and produce un-expected "
4023  "results.");
4024 
4025  return material;
4026 }
void mooseWarning(Args &&... args) const
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< T > getActiveObject(const std::string &name, THREAD_ID tid=0) const
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
MaterialWarehouse _all_materials

◆ getMaterialData()

MaterialData & FEProblemBase::getMaterialData ( Moose::MaterialDataType  type,
const THREAD_ID  tid = 0,
const MooseObject object = nullptr 
) const
inherited
Returns
The MaterialData for the type type for thread tid

Definition at line 4029 of file FEProblemBase.C.

Referenced by BlockRestrictable::initializeBlockRestrictable(), and FEProblemBase::resizeMaterialData().

4032 {
4033  switch (type)
4034  {
4036  if (object)
4037  _material_props.addConsumer(type, object);
4038  return _material_props.getMaterialData(tid);
4040  if (object)
4046  if (object)
4049  }
4050 
4051  mooseError("FEProblemBase::getMaterialData(): Invalid MaterialDataType ", type);
4052 }
MaterialPropertyStorage & _bnd_material_props
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
void addConsumer(Moose::MaterialDataType type, const MooseObject *object)
Add object as the consumer of storage of type type.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
MaterialPropertyStorage & _neighbor_material_props
const MaterialData & getMaterialData(const THREAD_ID tid) const
MaterialPropertyStorage & _material_props

◆ getMaterialPropertyBlockNames()

std::vector< SubdomainName > SubProblem::getMaterialPropertyBlockNames ( const std::string &  prop_name)
virtualinherited

Get a vector of block id equivalences that the material property is defined on.

Definition at line 490 of file SubProblem.C.

Referenced by MaterialPropertyInterface::getMaterialPropertyBlockNames().

491 {
492  std::set<SubdomainID> blocks = getMaterialPropertyBlocks(prop_name);
493  std::vector<SubdomainName> block_names;
494  block_names.reserve(blocks.size());
495  for (const auto & block_id : blocks)
496  {
497  SubdomainName name;
498  name = mesh().getMesh().subdomain_name(block_id);
499  if (name.empty())
500  {
501  std::ostringstream oss;
502  oss << block_id;
503  name = oss.str();
504  }
505  block_names.push_back(name);
506  }
507 
508  return block_names;
509 }
virtual MooseMesh & mesh()=0
char ** blocks
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MeshBase & getMesh()
Accessor for the underlying libMesh Mesh object.
Definition: MooseMesh.C:3548
std::string & subdomain_name(subdomain_id_type id)
virtual std::set< SubdomainID > getMaterialPropertyBlocks(const std::string &prop_name)
Get a vector containing the block ids the material property is defined on.
Definition: SubProblem.C:474

◆ getMaterialPropertyBlocks()

std::set< SubdomainID > SubProblem::getMaterialPropertyBlocks ( const std::string &  prop_name)
virtualinherited

Get a vector containing the block ids the material property is defined on.

Definition at line 474 of file SubProblem.C.

Referenced by SubProblem::getMaterialPropertyBlockNames(), and MaterialPropertyInterface::getMaterialPropertyBlocks().

475 {
476  std::set<SubdomainID> blocks;
477 
478  for (const auto & it : _map_block_material_props)
479  {
480  const std::set<std::string> & prop_names = it.second;
481  std::set<std::string>::iterator name_it = prop_names.find(prop_name);
482  if (name_it != prop_names.end())
483  blocks.insert(it.first);
484  }
485 
486  return blocks;
487 }
char ** blocks
std::map< SubdomainID, std::set< std::string > > _map_block_material_props
Map of material properties (block_id -> list of properties)
Definition: SubProblem.h:1067

◆ getMaterialPropertyBoundaryIDs()

std::set< BoundaryID > SubProblem::getMaterialPropertyBoundaryIDs ( const std::string &  prop_name)
virtualinherited

Get a vector containing the block ids the material property is defined on.

Definition at line 526 of file SubProblem.C.

Referenced by MaterialPropertyInterface::getMaterialPropertyBoundaryIDs(), and SubProblem::getMaterialPropertyBoundaryNames().

527 {
528  std::set<BoundaryID> boundaries;
529 
530  for (const auto & it : _map_boundary_material_props)
531  {
532  const std::set<std::string> & prop_names = it.second;
533  std::set<std::string>::iterator name_it = prop_names.find(prop_name);
534  if (name_it != prop_names.end())
535  boundaries.insert(it.first);
536  }
537 
538  return boundaries;
539 }
std::map< BoundaryID, std::set< std::string > > _map_boundary_material_props
Map for boundary material properties (boundary_id -> list of properties)
Definition: SubProblem.h:1070

◆ getMaterialPropertyBoundaryNames()

std::vector< BoundaryName > SubProblem::getMaterialPropertyBoundaryNames ( const std::string &  prop_name)
virtualinherited

Get a vector of block id equivalences that the material property is defined on.

Definition at line 542 of file SubProblem.C.

Referenced by MaterialPropertyInterface::getMaterialPropertyBoundaryNames().

543 {
544  std::set<BoundaryID> boundaries = getMaterialPropertyBoundaryIDs(prop_name);
545  std::vector<BoundaryName> boundary_names;
546  boundary_names.reserve(boundaries.size());
547  const BoundaryInfo & boundary_info = mesh().getMesh().get_boundary_info();
548 
549  for (const auto & bnd_id : boundaries)
550  {
551  BoundaryName name;
552  if (bnd_id == Moose::ANY_BOUNDARY_ID)
553  name = "ANY_BOUNDARY_ID";
554  else
555  {
556  name = boundary_info.get_sideset_name(bnd_id);
557  if (name.empty())
558  {
559  std::ostringstream oss;
560  oss << bnd_id;
561  name = oss.str();
562  }
563  }
564  boundary_names.push_back(name);
565  }
566 
567  return boundary_names;
568 }
virtual MooseMesh & mesh()=0
virtual std::set< BoundaryID > getMaterialPropertyBoundaryIDs(const std::string &prop_name)
Get a vector containing the block ids the material property is defined on.
Definition: SubProblem.C:526
const BoundaryInfo & get_boundary_info() const
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MeshBase & getMesh()
Accessor for the underlying libMesh Mesh object.
Definition: MooseMesh.C:3548
const std::string & get_sideset_name(boundary_id_type id) const
const BoundaryID ANY_BOUNDARY_ID
Definition: MooseTypes.C:21

◆ getMaterialPropertyRegistry()

const MaterialPropertyRegistry& FEProblemBase::getMaterialPropertyRegistry ( ) const
inlineinherited
Returns
A reference to the material property registry

Definition at line 2048 of file FEProblemBase.h.

Referenced by MaterialBase::checkStatefulSanity().

2049  {
2050  return _material_prop_registry;
2051  }
MaterialPropertyRegistry _material_prop_registry

◆ getMaterialPropertyStorage()

const MaterialPropertyStorage& FEProblemBase::getMaterialPropertyStorage ( )
inlineinherited

Return a reference to the material property storage.

Returns
A const reference to the material property storage

Definition at line 2058 of file FEProblemBase.h.

2058 { return _material_props; }
MaterialPropertyStorage & _material_props

◆ getMaterialPropertyStorageConsumers()

const std::set< const MooseObject * > & FEProblemBase::getMaterialPropertyStorageConsumers ( Moose::MaterialDataType  type) const
inherited
Returns
The consumers of the MaterialPropertyStorage for the type type

Definition at line 4055 of file FEProblemBase.C.

4056 {
4057  switch (type)
4058  {
4067  }
4068 
4069  mooseError("FEProblemBase::getMaterialPropertyStorageConsumers(): Invalid MaterialDataType ",
4070  type);
4071 }
MaterialPropertyStorage & _bnd_material_props
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
const std::set< const MooseObject * > & getConsumers(Moose::MaterialDataType type) const
MaterialPropertyStorage & _neighbor_material_props
MaterialPropertyStorage & _material_props

◆ getMaterialWarehouse()

const MaterialWarehouse& FEProblemBase::getMaterialWarehouse ( ) const
inlineinherited

◆ getMatrixTagID()

TagID SubProblem::getMatrixTagID ( const TagName &  tag_name) const
virtualinherited

Get a TagID from a TagName.

Reimplemented in DisplacedProblem.

Definition at line 343 of file SubProblem.C.

Referenced by Coupleable::coupledMatrixTagValue(), Coupleable::coupledMatrixTagValues(), ExplicitTimeIntegrator::ExplicitTimeIntegrator(), DisplacedProblem::getMatrixTagID(), TaggingInterface::TaggingInterface(), and TaggingInterface::useMatrixTag().

344 {
345  auto tag_name_upper = MooseUtils::toUpper(tag_name);
346 
347  if (!matrixTagExists(tag_name))
348  mooseError("Matrix tag: ",
349  tag_name,
350  " does not exist. ",
351  "If this is a TimeKernel then this may have happened because you didn't "
352  "specify a Transient Executioner.");
353 
354  return _matrix_tag_name_to_tag_id.at(tag_name_upper);
355 }
std::map< TagName, TagID > _matrix_tag_name_to_tag_id
The currently declared tags.
Definition: SubProblem.h:1056
std::string toUpper(std::string name)
Convert supplied string to upper case.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
virtual bool matrixTagExists(const TagName &tag_name) const
Check to see if a particular Tag exists.
Definition: SubProblem.C:329

◆ getMatrixTags()

virtual std::map<TagName, TagID>& SubProblem::getMatrixTags ( )
inlinevirtualinherited

Return all matrix tags in the system, where a tag is represented by a map from name to ID.

Definition at line 253 of file SubProblem.h.

Referenced by NonlinearSystemBase::computeJacobian(), FEProblemBase::computeJacobian(), EigenProblem::computeJacobianAB(), NonlinearSystemBase::computeJacobianBlocks(), EigenProblem::computeJacobianTag(), FEProblemBase::computeLinearSystemSys(), and FEProblemBase::computeResidualAndJacobian().

253 { return _matrix_tag_name_to_tag_id; }
std::map< TagName, TagID > _matrix_tag_name_to_tag_id
The currently declared tags.
Definition: SubProblem.h:1056

◆ getMaxQps()

unsigned int FEProblemBase::getMaxQps ( ) const
inherited
Returns
The maximum number of quadrature points in use on any element in this problem.

Definition at line 1707 of file FEProblemBase.C.

Referenced by MaterialBase::getMaxQps(), MaterialPropertyInterface::getMaxQps(), FEProblemBase::initialSetup(), FEProblemBase::reinitDirac(), Material::subdomainSetup(), and FEProblemBase::updateMaxQps().

1708 {
1710  mooseError("Max QPS uninitialized");
1711  return _max_qps;
1712 }
auto max(const L &left, const R &right)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
unsigned int _max_qps
Maximum number of quadrature points used in the problem.

◆ getMaxScalarOrder()

Order FEProblemBase::getMaxScalarOrder ( ) const
inherited
Returns
The maximum order for all scalar variables in this problem's systems.

Definition at line 1715 of file FEProblemBase.C.

Referenced by ScalarCoupleable::coupledScalarOrder(), ScalarCoupleable::getADDefaultValue(), and ScalarCoupleable::getDefaultValue().

1716 {
1717  return _max_scalar_order;
1718 }
libMesh::Order _max_scalar_order
Maximum scalar variable order.

◆ getMeshDisplacementGridFunction()

std::optional< std::reference_wrapper< mfem::ParGridFunction const > > MFEMProblem::getMeshDisplacementGridFunction ( )

Returns optional reference to the displacement GridFunction to apply to nodes.

Definition at line 731 of file MFEMProblem.C.

Referenced by displaceMesh().

732 {
733  // If C++23 transform were available this would be easier
734  auto const displacement_variable = mesh().getMeshDisplacementVariable();
735  if (displacement_variable)
736  {
737  return *_problem_data.gridfunctions.Get(displacement_variable.value());
738  }
739  else
740  {
741  return std::nullopt;
742  }
743 }
std::optional< std::reference_wrapper< std::string const > > getMeshDisplacementVariable() const
Returns an optional reference to displacement variable name.
Definition: MFEMMesh.h:63
virtual MFEMMesh & mesh() override
Overwritten mesh() method from base MooseMesh to retrieve the correct mesh type, in this case MFEMMes...
Definition: MFEMProblem.C:777
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
T * Get(const std::string &field_name) const
Returns a non-owning pointer to the field. This is guaranteed to return a non-null pointer...
Moose::MFEM::GridFunctions gridfunctions

◆ getMeshDivision()

MeshDivision & FEProblemBase::getMeshDivision ( const std::string &  name,
const THREAD_ID  tid = 0 
) const
inherited

Get a MeshDivision.

Definition at line 2804 of file FEProblemBase.C.

Referenced by NestedDivision::NestedDivision().

2805 {
2806  auto * const ret = dynamic_cast<MeshDivision *>(_mesh_divisions.getActiveObject(name, tid).get());
2807  if (!ret)
2808  mooseError("No MeshDivision object named ", name, " of appropriate type");
2809  return *ret;
2810 }
Base class for MeshDivision objects.
Definition: MeshDivision.h:35
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::shared_ptr< T > getActiveObject(const std::string &name, THREAD_ID tid=0) const
MooseObjectWarehouse< MeshDivision > _mesh_divisions
Warehouse to store mesh divisions NOTE: this could probably be moved to the MooseMesh instead of the ...
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getMFEMObject()

template<typename T >
T & MFEMProblem::getMFEMObject ( const std::string &  system,
const std::string &  name,
const THREAD_ID  tid = 0 
) const

Retrieve an MFEM object from the warehouse by system and name.

Definition at line 418 of file MFEMProblem.h.

Referenced by MFEMFESpaceHierarchy::buildHierarchy(), MFEML2ZienkiewiczZhuIndicator::createEstimator(), MFEMRefinementMarker::initialSetup(), MFEML2ZienkiewiczZhuIndicator::MFEML2ZienkiewiczZhuIndicator(), MFEMVariable::MFEMVariable(), and Moose::MFEM::LinearSolverBase::SetPreconditioner().

421 {
422  std::vector<T *> objs;
423  theWarehouse()
424  .query()
425  .condition<AttribSystem>(system)
426  .condition<AttribThread>(tid)
427  .condition<AttribName>(name)
428  .queryInto(objs);
429  if (objs.empty())
430  mooseError("Unable to find MFEM object with system '" + system + "' and name '" + name + "'");
431  mooseAssert(objs.size() == 1, "Shouldn't find more than one object with given system and name");
432  return *(objs[0]);
433 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getMFEMVariableMesh()

const mfem::ParMesh& MFEMProblem::getMFEMVariableMesh ( std::string  var_name)
inline

Return the ParMesh associated with a particular variable.

Definition at line 286 of file MFEMProblem.h.

287  {
288  if (_problem_data.gridfunctions.Has(var_name))
289  return *_problem_data.gridfunctions.Get(var_name)->ParFESpace()->GetParMesh();
290  else if (_problem_data.cmplx_gridfunctions.Has(var_name))
291  return *_problem_data.cmplx_gridfunctions.Get(var_name)->ParFESpace()->GetParMesh();
292  else
293  mooseError("Variable " + var_name +
294  " not found in MFEMProblem real or complex gridfunctions.");
295  }
Moose::MFEM::ComplexGridFunctions cmplx_gridfunctions
bool Has(const std::string &field_name) const
Predicate to check if a field is registered with name field_name.
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
T * Get(const std::string &field_name) const
Returns a non-owning pointer to the field. This is guaranteed to return a non-null pointer...
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
Moose::MFEM::GridFunctions gridfunctions

◆ getMooseApp()

MooseApp& MooseBase::getMooseApp ( ) const
inlineinherited

Get the MooseApp this class is associated with.

Definition at line 87 of file MooseBase.h.

Referenced by ChainControlSetupAction::act(), AddDefaultConvergenceAction::addDefaultMultiAppFixedPointConvergence(), AddDefaultConvergenceAction::addDefaultNonlinearConvergence(), AddDefaultConvergenceAction::addDefaultSteadyStateConvergence(), FEProblemBase::advanceState(), ParsedChainControl::buildFunction(), ReporterTransferInterface::checkHasReporterValue(), AddDefaultConvergenceAction::checkUnusedMultiAppFixedPointConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedNonlinearConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedSteadyStateConvergenceParameters(), Coupleable::checkWritableVar(), ComponentPhysicsInterface::ComponentPhysicsInterface(), Coupleable::Coupleable(), MortarInterfaceWarehouse::createMortarInterface(), EigenProblem::doFreeNonlinearPowerIterations(), Terminator::execute(), FEProblemSolve::FEProblemSolve(), SolutionInvalidInterface::flagInvalidSolutionInternal(), ChainControl::getChainControlDataSystem(), FEProblemBase::getDistribution(), FEProblemBase::getFunction(), FEProblemBase::getFVInterpolationMethod(), FEProblemBase::getMultiApp(), FEProblemBase::getSampler(), DefaultConvergenceBase::getSharedExecutionerParam(), FEProblemBase::getUserObjectBase(), FEProblemBase::getVectorPostprocessorObjectByName(), ChainControlDataPostprocessor::initialSetup(), MaterialPropertyInterface::MaterialPropertyInterface(), MooseVariableDataFV< OutputType >::MooseVariableDataFV(), ProgressOutput::output(), PetscOutputInterface::petscLinearOutput(), PetscOutputInterface::petscNonlinearOutput(), PetscOutputInterface::PetscOutputInterface(), PostprocessorInterface::postprocessorsAdded(), MultiApp::preTransfer(), Reporter::Reporter(), ReporterInterface::reportersAdded(), MultiApp::restore(), and VectorPostprocessorInterface::vectorPostprocessorsAdded().

87 { return _app; }
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375

◆ getMortarInterface() [1/2]

const AutomaticMortarGeneration & FEProblemBase::getMortarInterface ( const std::pair< BoundaryID, BoundaryID > &  primary_secondary_boundary_pair,
const std::pair< SubdomainID, SubdomainID > &  primary_secondary_subdomain_pair,
bool  on_displaced 
) const
inherited

Return the undisplaced or displaced mortar generation object associated with the provided boundaries and subdomains.

Definition at line 8446 of file FEProblemBase.C.

8450 {
8451  return _mortar_data->getMortarInterface(
8452  primary_secondary_boundary_pair, primary_secondary_subdomain_pair, on_displaced);
8453 }
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data

◆ getMortarInterface() [2/2]

AutomaticMortarGeneration & FEProblemBase::getMortarInterface ( const std::pair< BoundaryID, BoundaryID > &  primary_secondary_boundary_pair,
const std::pair< SubdomainID, SubdomainID > &  primary_secondary_subdomain_pair,
bool  on_displaced 
)
inherited

Definition at line 8456 of file FEProblemBase.C.

8460 {
8461  return _mortar_data->getMortarInterface(
8462  primary_secondary_boundary_pair, primary_secondary_subdomain_pair, on_displaced);
8463 }
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data

◆ getMortarInterfaces()

const std::unordered_map< std::pair< BoundaryID, BoundaryID >, MortarInterfaceConfig > & FEProblemBase::getMortarInterfaces ( bool  on_displaced) const
inherited

Definition at line 10082 of file FEProblemBase.C.

Referenced by FEProblemBase::computeUserObjectsInternal(), MortarSegmentMeshReporter::execute(), and NonlinearSystemBase::initialSetup().

10083 {
10084  return _mortar_data->getMortarInterfaces(on_displaced);
10085 }
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data

◆ getMultiApp()

std::shared_ptr< MultiApp > FEProblemBase::getMultiApp ( const std::string &  multi_app_name) const
inherited

Get a MultiApp object by name.

Definition at line 5856 of file FEProblemBase.C.

Referenced by FEProblemBase::addTransfer(), MultiAppPositions::initialize(), and MultiAppTransfer::MultiAppTransfer().

5857 {
5858  if (!hasMultiApp(multi_app_name))
5859  mooseAssert(getMooseApp().actionWarehouse().isTaskComplete("add_multi_app"),
5860  "A MultiApp getter was called before MultiApps have been constructed. "
5861  "If you are attempting to access this object in the constructor of another object "
5862  "then make sure that the MultiApp is constructed before the object using it.");
5863 
5864  return _multi_apps.getObject(multi_app_name);
5865 }
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
std::shared_ptr< T > getObject(const std::string &name, THREAD_ID tid=0) const
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
bool hasMultiApp(const std::string &name) const

◆ getMultiAppFixedPointConvergenceName()

const ConvergenceName & FEProblemBase::getMultiAppFixedPointConvergenceName ( ) const
inherited

Gets the MultiApp fixed point convergence object name.

Definition at line 9802 of file FEProblemBase.C.

Referenced by FEProblemBase::addDefaultMultiAppFixedPointConvergence(), FixedPointSolve::examineFixedPointConvergence(), FixedPointIterationAdaptiveDT::init(), SteffensenSolve::initialSetup(), FixedPointSolve::initialSetup(), FixedPointSolve::solve(), and FixedPointSolve::solveStep().

9803 {
9806  else
9807  mooseError("The fixed point convergence name has not been set.");
9808 }
std::optional< ConvergenceName > _multiapp_fixed_point_convergence_name
MultiApp fixed point convergence name.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getMultiAppTransferWarehouse()

const ExecuteMooseObjectWarehouse< Transfer > & FEProblemBase::getMultiAppTransferWarehouse ( Transfer::DIRECTION  direction) const
inherited

Return the complete warehouse for MultiAppTransfer object for the given direction.

Definition at line 5957 of file FEProblemBase.C.

5958 {
5959  if (direction == MultiAppTransfer::TO_MULTIAPP)
5960  return _to_multi_app_transfers;
5961  else if (direction == MultiAppTransfer::FROM_MULTIAPP)
5963  else
5965 }
ExecuteMooseObjectWarehouse< Transfer > _from_multi_app_transfers
Transfers executed just after MultiApps to transfer data from them.
ExecuteMooseObjectWarehouse< Transfer > _to_multi_app_transfers
Transfers executed just before MultiApps to transfer data to them.
ExecuteMooseObjectWarehouse< Transfer > _between_multi_app_transfers
Transfers executed just before MultiApps to transfer data between them.

◆ getMultiAppWarehouse()

ExecuteMooseObjectWarehouse<MultiApp>& FEProblemBase::getMultiAppWarehouse ( )
inlineinherited

Definition at line 2541 of file FEProblemBase.h.

Referenced by MooseApp::collectCitations(), and MooseApp::errorCheck().

2541 { return _multi_apps; }
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.

◆ getNeighborMaterialPropertyStorage()

const MaterialPropertyStorage& FEProblemBase::getNeighborMaterialPropertyStorage ( )
inlineinherited

Definition at line 2060 of file FEProblemBase.h.

2061  {
2062  return _neighbor_material_props;
2063  }
MaterialPropertyStorage & _neighbor_material_props

◆ getNonlinearConvergenceNames()

const std::vector< ConvergenceName > & FEProblemBase::getNonlinearConvergenceNames ( ) const
inherited

Gets the nonlinear system convergence object name(s).

Definition at line 9770 of file FEProblemBase.C.

Referenced by ReferenceResidualProblem::addDefaultNonlinearConvergence(), FEProblemBase::addDefaultNonlinearConvergence(), FEProblemSolve::convergenceSetup(), and Moose::PetscSupport::petscNonlinearConverged().

9771 {
9774  mooseError("The nonlinear system convergence name(s) have not been set.");
9775 }
std::optional< std::vector< ConvergenceName > > _nonlinear_convergence_names
Nonlinear system(s) convergence name(s)
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getNonlinearEvaluableElementRange()

const ConstElemRange & FEProblemBase::getNonlinearEvaluableElementRange ( )
inherited

Definition at line 898 of file FEProblemBase.C.

Referenced by ElemSideNeighborLayersTester::execute().

899 {
901  {
902  std::vector<const DofMap *> dof_maps(_nl.size());
903  for (const auto i : index_range(dof_maps))
904  dof_maps[i] = &_nl[i]->dofMap();
906  std::make_unique<ConstElemRange>(_mesh.getMesh().multi_evaluable_elements_begin(dof_maps),
907  _mesh.getMesh().multi_evaluable_elements_end(dof_maps));
908  }
909 
911 }
std::unique_ptr< libMesh::ConstElemRange > _nl_evaluable_local_elem_range
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
MeshBase & getMesh()
Accessor for the underlying libMesh Mesh object.
Definition: MooseMesh.C:3548
MooseMesh & _mesh
auto index_range(const T &sizable)

◆ getNonlinearSystem()

NonlinearSystem & FEProblemBase::getNonlinearSystem ( const unsigned int  sys_num)
virtualinherited

Reimplemented in FEProblem.

Definition at line 2819 of file FEProblemBase.C.

Referenced by PNGOutput::calculateRescalingValues(), and PNGOutput::makeMeshFunc().

2820 {
2821  mooseDeprecated("FEProblemBase::getNonlinearSystem() is deprecated, please use "
2822  "FEProblemBase::getNonlinearSystemBase() \n");
2823 
2824  mooseAssert(sys_num < _nl.size(), "System number greater than the number of nonlinear systems");
2825  auto nl_sys = std::dynamic_pointer_cast<NonlinearSystem>(_nl[sys_num]);
2826 
2827  if (!nl_sys)
2828  mooseError("This is not a NonlinearSystem");
2829 
2830  return *nl_sys;
2831 }
std::unique_ptr< T_DEST, T_DELETER > dynamic_pointer_cast(std::unique_ptr< T_SRC, T_DELETER > &src)
These are reworked from https://stackoverflow.com/a/11003103.
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
void mooseDeprecated(Args &&... args) const
Nonlinear system to be solved.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getNonlinearSystemBase() [1/2]

NonlinearSystemBase & FEProblemBase::getNonlinearSystemBase ( const unsigned int  sys_num)
inlineinherited

Definition at line 3717 of file FEProblemBase.h.

Referenced by IterationAdaptiveDT::acceptStep(), DisplacedProblem::addTimeIntegrator(), ADKernelTempl< T >::ADKernelTempl(), ElementSubdomainModifierBase::applyIC(), ArrayKernel::ArrayKernel(), Eigenvalue::checkIntegrity(), PseudoTimestep::currentResidualNorm(), DisplacedProblem::DisplacedProblem(), AB2PredictorCorrector::estimateTimeError(), VariableResidual::execute(), MatrixSymmetryCheck::execute(), GreaterThanLessThanPostprocessor::execute(), Executioner::Executioner(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), NumResidualEvaluations::getValue(), Residual::getValue(), ActivateElementsUserObjectBase::initSolutions(), Kernel::Kernel(), ReferenceResidualConvergence::nonlinearSystem(), BoundaryElemIntegrityCheckThread::operator()(), DOFMapOutput::output(), SolutionHistory::output(), ConsoleUtils::outputExecutionInformation(), Console::outputSystemInformation(), Moose::PetscSupport::petscSetDefaults(), ReferenceResidualConvergence::ReferenceResidualConvergence(), Moose::PetscSupport::setLineSearchFromParams(), SingleMatrixPreconditioner::SingleMatrixPreconditioner(), AB2PredictorCorrector::step(), DisplacedProblem::syncSolutions(), and Console::writeVariableNorms().

3718 {
3719  mooseAssert(sys_num < _nl.size(), "System number greater than the number of nonlinear systems");
3720  return *_nl[sys_num];
3721 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ getNonlinearSystemBase() [2/2]

const NonlinearSystemBase & FEProblemBase::getNonlinearSystemBase ( const unsigned int  sys_num) const
inlineinherited

Definition at line 3724 of file FEProblemBase.h.

3725 {
3726  mooseAssert(sys_num < _nl.size(), "System number greater than the number of nonlinear systems");
3727  return *_nl[sys_num];
3728 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ getNonlinearSystemNames()

const std::vector<NonlinearSystemName>& FEProblemBase::getNonlinearSystemNames ( ) const
inlineinherited
Returns
the nolinear system names in the problem

Definition at line 2934 of file FEProblemBase.h.

Referenced by PhysicsBase::initializePhysics(), Console::meshChanged(), MultiSystemSolveObject::MultiSystemSolveObject(), ConsoleUtils::outputExecutionInformation(), and Console::outputSystemInformation().

2934 { return _nl_sys_names; }
const std::vector< NonlinearSystemName > _nl_sys_names
The nonlinear system names.

◆ getNumCyclesCompleted()

unsigned int FEProblemBase::getNumCyclesCompleted ( )
inlineinherited
Returns
The number of adaptivity cycles completed.

Definition at line 2126 of file FEProblemBase.h.

2126 { return _cycles_completed; }
unsigned int _cycles_completed

◆ getNumericType()

NumericType MFEMProblem::getNumericType ( ) const
inline

Retrieve the numeric type of the problem.

Definition at line 365 of file MFEMProblem.h.

365 { return _num_type; }
NumericType _num_type
The numeric representation currently active for this problem.
Definition: MFEMProblem.h:402

◆ getParam() [1/2]

template<typename T >
const T & MooseBase::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 406 of file MooseBase.h.

Referenced by CreateDisplacedProblemAction::act(), CommonOutputAction::act(), CylinderComponent::addMeshGenerators(), FEProblemBase::addOutput(), DiffusionPhysicsBase::addPostprocessors(), ArrayParsedAux::ArrayParsedAux(), BicubicSplineFunction::BicubicSplineFunction(), ComponentPhysicsInterface::ComponentPhysicsInterface(), Console::Console(), FEProblemBase::createTagSolutions(), CutMeshByLevelSetGenerator::CutMeshByLevelSetGenerator(), DebugResidualAux::DebugResidualAux(), AccumulateReporter::declareLateValues(), DerivativeParsedMaterialTempl< is_ad >::DerivativeParsedMaterialTempl(), DynamicObjectRegistrationAction::DynamicObjectRegistrationAction(), EigenKernel::EigenKernel(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), MFEMEigenvaluesPostprocessor::execute(), FEProblemSolve::FEProblemSolve(), ParsedVectorReporter::finalize(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), FixedPointSolve::FixedPointSolve(), ParsedSubdomainGeneratorBase::functionInitialize(), FVInterfaceKernel::FVInterfaceKernel(), BoundaryLayerSubdomainGenerator::generate(), ExtraNodesetGenerator::generate(), FileMeshGenerator::generate(), OrientSurfaceMeshGenerator::generate(), RefineBlockGenerator::generate(), RefineSidesetGenerator::generate(), SubdomainsFromPartitionerGenerator::generate(), BreakMeshByBlockGenerator::generate(), BlockDeletionGenerator::generate(), CoarsenBlockGenerator::generate(), GeneratedMeshGenerator::generate(), MeshExtruderGenerator::generate(), XYDelaunayGenerator::generate(), GenericConstantRankTwoTensorTempl< is_ad >::GenericConstantRankTwoTensorTempl(), GenericConstantSymmetricRankTwoTensorTempl< is_ad >::GenericConstantSymmetricRankTwoTensorTempl(), GeometricSearchInterface::GeometricSearchInterface(), MooseApp::getCheckpointDirectories(), DataFileInterface::getDataFileName(), ExecutorInterface::getExecutor(), MFEMExecutedObject::getRequestedItems(), GhostingUserObject::GhostingUserObject(), FixedPointIterationAdaptiveDT::init(), TimeSequenceStepper::init(), IterationAdaptiveDT::init(), AdvancedOutput::init(), AdvancedOutput::initAvailableLists(), AttribThread::initFrom(), AttribSysNum::initFrom(), AttribResidualObject::initFrom(), AttribDisplaced::initFrom(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), Console::initialSetup(), SampledOutput::initSample(), IterationAdaptiveDT::limitDTToPostprocessorValue(), MooseMesh::MooseMesh(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MultiPostprocessorConvergence::MultiPostprocessorConvergence(), MultiSystemSolveObject::MultiSystemSolveObject(), NEML2ModelExecutor::NEML2ModelExecutor(), NestedDivision::NestedDivision(), PerfGraphOutput::output(), Console::outputSystemInformation(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedElementDeletionGenerator::ParsedElementDeletionGenerator(), ParsedGenerateNodeset::ParsedGenerateNodeset(), ParsedGenerateSideset::ParsedGenerateSideset(), ParsedMaterialTempl< is_ad >::ParsedMaterialTempl(), ParsedNodeTransformGenerator::ParsedNodeTransformGenerator(), ParsedODEKernel::ParsedODEKernel(), ParsedPostprocessor::ParsedPostprocessor(), ParsedReporterBase::ParsedReporterBase(), ParsedVectorReporter::ParsedVectorReporter(), PiecewiseByBlockFunctorMaterialTempl< T >::PiecewiseByBlockFunctorMaterialTempl(), PiecewiseConstantByBlockMaterialTempl< is_ad >::PiecewiseConstantByBlockMaterialTempl(), ProjectSideSetOntoLevelSetGenerator::ProjectSideSetOntoLevelSetGenerator(), ReferenceResidualInterface::ReferenceResidualInterface(), RenameBlockGenerator::RenameBlockGenerator(), Moose::FV::setInterpolationMethod(), SetupMeshAction::setupMesh(), Output::setWallTimeIntervalFromCommandLineParam(), SingleMatrixPreconditioner::SingleMatrixPreconditioner(), TimePeriod::TimePeriod(), UniqueExtraIDMeshGenerator::UniqueExtraIDMeshGenerator(), FunctorIC::value(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), and VectorOfPostprocessors::VectorOfPostprocessors().

407 {
408  return InputParameters::getParamHelper<T>(name, _pars);
409 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ getParam() [2/2]

template<typename T1 , typename T2 >
std::vector< std::pair< T1, T2 > > MooseBase::getParam ( const std::string &  param1,
const std::string &  param2 
) const
inherited

Retrieve two parameters and provide pair of parameters for the object.

Parameters
param1The name of first parameter
param2The name of second parameter
Returns
Vector of pairs of first and second parameters

Definition at line 443 of file MooseBase.h.

444 {
445  return _pars.get<T1, T2>(param1, param2);
446 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.

◆ getPetscOptions()

Moose::PetscSupport::PetscOptions& FEProblemBase::getPetscOptions ( )
inlineinherited

◆ getPositionsObject()

const Positions & FEProblemBase::getPositionsObject ( const std::string &  name) const
inherited

Get the Positions object by its name.

Parameters
nameThe name of the Positions object being retrieved
Returns
Const reference to the Positions object

Definition at line 4759 of file FEProblemBase.C.

Referenced by DistributedPositions::DistributedPositions(), MultiApp::fillPositions(), ParsedDownSelectionPositions::initialize(), Positions::initialized(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), and TransformedPositions::TransformedPositions().

4760 {
4761  std::vector<Positions *> objs;
4762  theWarehouse()
4763  .query()
4764  .condition<AttribSystem>("UserObject")
4765  .condition<AttribName>(name)
4766  .queryInto(objs);
4767  if (objs.empty())
4768  mooseError("Unable to find Positions object with name '" + name + "'");
4769  mooseAssert(objs.size() == 1, "Should only find one Positions");
4770  return *(objs[0]);
4771 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getPostprocessorObjectByName()

const Postprocessor & FEProblemBase::getPostprocessorObjectByName ( const PostprocessorName &  object_name,
const THREAD_ID  tid = 0 
) const
inherited

Return the Postprocessor object registered under the supplied object name.

Parameters
object_nameThe name of the Postprocessor object
tidThe thread identifier for thread-local object lookup

Definition at line 4867 of file FEProblemBase.C.

4869 {
4870  std::vector<Postprocessor *> objs;
4871  theWarehouse()
4872  .query()
4874  .condition<AttribThread>(tid)
4875  .condition<AttribName>(object_name)
4876  .queryInto(objs);
4877 
4878  if (objs.empty())
4879  mooseError("Unable to find Postprocessor with name '", object_name, "'");
4880  mooseAssert(objs.size() == 1,
4881  "We shouldn't find more than one postprocessor object for a given name");
4882  return *(objs[0]);
4883 }
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getPostprocessorValueByName()

const PostprocessorValue & FEProblemBase::getPostprocessorValueByName ( const PostprocessorName &  name,
std::size_t  t_index = 0 
) const
inherited

Get a read-only reference to the value associated with a Postprocessor that exists.

Parameters
nameThe name of the post-processor
t_indexFlag for getting current (0), old (1), or older (2) values
Returns
The reference to the value at the given time index

Note: This method is only for retrieving values that already exist, the Postprocessor and PostprocessorInterface objects should be used rather than this method for creating and getting values within objects.

Definition at line 4886 of file FEProblemBase.C.

Referenced by addPostprocessor(), MultiAppConservativeTransfer::adjustTransferredSolution(), MultiAppConservativeTransfer::adjustTransferredSolutionNearestPoint(), MultiApp::appPostprocessorValue(), MultiAppPostprocessorToAuxScalarTransfer::execute(), MultiAppPostprocessorTransfer::execute(), EigenProblem::formNorm(), MooseParsedFunctionWrapper::initialize(), ParsedConvergence::initializePostprocessorSymbol(), EigenExecutionerBase::inversePowerIteration(), Nemesis::outputPostprocessors(), Exodus::outputPostprocessors(), TableOutput::outputPostprocessorsRow(), EigenProblem::postScaleEigenVector(), and TableOutput::shouldOutputPostprocessorsRow().

4888 {
4890  t_index);
4891 }
ReporterData _reporter_data
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const T & getReporterValue(const ReporterName &reporter_name, const MooseObject &consumer, const ReporterMode &mode, const std::size_t time_index=0) const
Method for returning read only references to Reporter values.
Definition: ReporterData.h:394
Real PostprocessorValue
various MOOSE typedefs
Definition: MooseTypes.h:230
A ReporterName that represents a Postprocessor.
Definition: ReporterName.h:143

◆ getProblemData() [1/2]

MFEMProblemData& MFEMProblem::getProblemData ( )
inline

◆ getProblemData() [2/2]

const MFEMProblemData& MFEMProblem::getProblemData ( ) const
inline

Return the current MFEM problem data in a const context.

Definition at line 276 of file MFEMProblem.h.

276 { return _problem_data; }
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397

◆ getRegularMaterialsWarehouse()

const MaterialWarehouse& FEProblemBase::getRegularMaterialsWarehouse ( ) const
inlineinherited

Definition at line 2305 of file FEProblemBase.h.

Referenced by Moose::Mortar::setupMortarMaterials().

2305 { return _materials; }
MaterialWarehouse _materials

◆ getRenamedParam()

template<typename T >
const T & MooseBase::getRenamedParam ( const std::string &  old_name,
const std::string &  new_name 
) const
inherited

Retrieve a renamed parameter for the object.

This helper makes sure we check both names before erroring, and that only one parameter is passed to avoid silent errors

Parameters
old_namethe old name for the parameter
new_namethe new name for the parameter

Definition at line 420 of file MooseBase.h.

421 {
422  // Most important: accept new parameter
423  if (isParamSetByUser(new_name) && !isParamValid(old_name))
424  return getParam<T>(new_name);
425  // Second most: accept old parameter
426  if (isParamValid(old_name) && !isParamSetByUser(new_name))
427  return getParam<T>(old_name);
428  // Third most: accept default for new parameter
429  if (isParamValid(new_name) && !isParamValid(old_name))
430  return getParam<T>(new_name);
431  // Refuse: no default, no value passed
432  if (!isParamValid(old_name) && !isParamValid(new_name))
433  mooseError("parameter '" + new_name +
434  "' is being retrieved without being set.\nDid you misspell it?");
435  // Refuse: both old and new parameters set by user
436  else
437  mooseError("Parameter '" + new_name + "' may not be provided alongside former parameter '" +
438  old_name + "'");
439 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
bool isParamValid(const std::string &name) const
Test if the supplied parameter is valid.
Definition: MooseBase.h:199
bool isParamSetByUser(const std::string &name) const
Test if the supplied parameter is set by a user, as opposed to not set or set to default.
Definition: MooseBase.h:205

◆ getReporterData() [1/2]

const ReporterData& FEProblemBase::getReporterData ( ) const
inlineinherited

Provides const access the ReporterData object.

NOTE: There is a private non-const version of this function that uses a key object only constructable by the correct interfaces. This was done by design to encourage the use of the Reporter and ReporterInterface classes.

Definition at line 1380 of file FEProblemBase.h.

Referenced by ReporterTransferInterface::addReporterTransferMode(), ReporterTransferInterface::checkHasReporterValue(), ReporterTransferInterface::clearVectorReporter(), ConstantPostprocessor::ConstantPostprocessor(), AccumulateReporter::declareAccumulateHelper(), ReporterTransferInterface::declareClone(), AccumulateReporter::declareLateValues(), VectorPostprocessor::declareVector(), ReporterTransferInterface::declareVectorClone(), FEProblemBase::execute(), PostprocessorInterface::getPostprocessorValueByNameInternal(), VectorPostprocessorInterface::getVectorPostprocessorByNameHelper(), VectorPostprocessorInterface::getVectorPostprocessorContextByNameHelper(), PostprocessorInterface::hasPostprocessorByName(), VectorPostprocessorInterface::hasVectorPostprocessorByName(), ReporterPositions::initialize(), ReporterTimes::initialize(), MooseParsedFunctionWrapper::initialize(), ParsedConvergence::initializeSymbols(), JSONOutput::initialSetup(), PostprocessorInterface::isDefaultPostprocessorValueByName(), ReporterDebugOutput::output(), Receiver::Receiver(), ReporterTransferInterface::resizeReporter(), ReporterTransferInterface::sumVectorReporter(), ReporterTransferInterface::transferFromVectorReporter(), ReporterTransferInterface::transferReporter(), and ReporterTransferInterface::transferToVectorReporter().

1380 { return _reporter_data; }
ReporterData _reporter_data

◆ getReporterData() [2/2]

ReporterData& FEProblemBase::getReporterData ( ReporterData::WriteKey  )
inlineinherited

Provides non-const access the ReporterData object that is used to store reporter values.

see ReporterData.h

Definition at line 1387 of file FEProblemBase.h.

1387 { return _reporter_data; }
ReporterData _reporter_data

◆ getRestartableData()

template<typename T , typename... Args>
const T & Restartable::getRestartableData ( const std::string &  data_name) const
protectedinherited

Declare a piece of data as "restartable" and initialize it Similar to declareRestartableData but returns a const reference to the object.

Forwarded arguments are not allowed in this case because we assume that the object is restarted and we won't need different constructors to initialize it.

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

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

Definition at line 294 of file Restartable.h.

295 {
296  return declareRestartableDataHelper<T>(data_name, nullptr).get();
297 }

◆ getRestartableEquationSystems()

const RestartableEquationSystems & FEProblemBase::getRestartableEquationSystems ( ) const
inherited

Get the RestartableEquationSystems object.

Definition at line 6340 of file FEProblemBase.C.

6341 {
6342  return _req.get();
6343 }
const T & get() const
Get the restartable value.
Definition: Restartable.h:58
Restartable::ManagedValue< RestartableEquationSystems > _req
The EquationSystems object, wrapped for restart.

◆ getSampler()

Sampler & FEProblemBase::getSampler ( const std::string &  name,
const THREAD_ID  tid = 0 
)
virtualinherited

Definition at line 2885 of file FEProblemBase.C.

Referenced by SamplerInterface::getSampler(), and SamplerInterface::getSamplerByName().

2886 {
2887  std::vector<Sampler *> objs;
2888  theWarehouse()
2889  .query()
2890  .condition<AttribSystem>("Sampler")
2891  .condition<AttribThread>(tid)
2892  .condition<AttribName>(name)
2893  .queryInto(objs);
2894  if (objs.empty())
2895  {
2896  mooseAssert(getMooseApp().actionWarehouse().isTaskComplete("add_sampler"),
2897  "A Sampler getter was called before Samplers have been constructed. "
2898  "If you are attempting to access this object in the constructor of another object "
2899  "then make sure that the Sampler is constructed before the object using it.");
2900 
2901  mooseError(
2902  "Unable to find Sampler with name '" + name +
2903  "', if you are attempting to access this object in the constructor of another object then "
2904  "make sure that the Sampler is constructed before the object using it.");
2905  }
2906  return *(objs[0]);
2907 }
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getScalarVariable()

MooseVariableScalar & FEProblemBase::getScalarVariable ( const THREAD_ID  tid,
const std::string &  var_name 
)
overridevirtualinherited

Returns the scalar variable reference from whichever system contains it.

Implements SubProblem.

Definition at line 6316 of file FEProblemBase.C.

Referenced by FEProblemBase::addInitialCondition(), EigenProblem::adjustEigenVector(), MultiAppScalarToAuxScalarTransfer::execute(), MooseParsedFunctionWrapper::initialize(), ChainControlParsedFunctionWrapper::initializeFunctionInputs(), TableOutput::outputScalarVariables(), Nemesis::outputScalarVariables(), and Exodus::outputScalarVariables().

6317 {
6318  for (auto & sys : _solver_systems)
6319  if (sys->hasScalarVariable(var_name))
6320  return sys->getScalarVariable(tid, var_name);
6321  if (_aux->hasScalarVariable(var_name))
6322  return _aux->getScalarVariable(tid, var_name);
6323 
6324  mooseError("Unknown variable " + var_name);
6325 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getSharedPtr() [1/2]

std::shared_ptr< MooseObject > MooseObject::getSharedPtr ( )
inherited

Get another shared pointer to this object that has the same ownership group.

Wrapper around shared_from_this().

Definition at line 70 of file MooseObject.C.

Referenced by addImagComponentToBC(), addImagComponentToKernel(), addRealComponentToBC(), addRealComponentToKernel(), and WebServerControl::addServerAction().

71 {
72  try
73  {
74  return shared_from_this();
75  }
76  catch (std::bad_weak_ptr &)
77  {
78  mooseError(not_shared_error);
79  }
80 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getSharedPtr() [2/2]

std::shared_ptr< const MooseObject > MooseObject::getSharedPtr ( ) const
inherited

Definition at line 83 of file MooseObject.C.

84 {
85  try
86  {
87  return shared_from_this();
88  }
89  catch (std::bad_weak_ptr &)
90  {
91  mooseError(not_shared_error);
92  }
93 }
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getSolverSystem() [1/2]

SolverSystem & FEProblemBase::getSolverSystem ( unsigned int  sys_num)
inlineinherited

Get non-constant reference to a solver system.

Parameters
sys_numThe number of the solver system

Definition at line 3731 of file FEProblemBase.h.

Referenced by Adaptivity::adaptMesh(), Moose::PetscSupport::addPetscOptionsFromCommandline(), MooseApp::attachRelationshipManagers(), MooseMesh::cacheFaceInfoVariableOwnership(), MooseMesh::cacheFVElementalDoFs(), Adaptivity::init(), FixedPointSolve::initialSetup(), MultiSystemSolveObject::MultiSystemSolveObject(), ConsoleUtils::outputSolverSystemInformation(), Moose::PetscSupport::petscSetDefaultKSPNormType(), and Moose::PetscSupport::petscSetDefaultPCSide().

3732 {
3733  mooseAssert(sys_num < _solver_systems.size(),
3734  "System number greater than the number of solver systems");
3735  return *_solver_systems[sys_num];
3736 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.

◆ getSolverSystem() [2/2]

const SolverSystem & FEProblemBase::getSolverSystem ( unsigned int  sys_num) const
inlineinherited

Get a constant reference to a solver system.

Parameters
sys_numThe number of the solver system

Definition at line 3739 of file FEProblemBase.h.

3740 {
3741  mooseAssert(sys_num < _solver_systems.size(),
3742  "System number greater than the number of solver systems");
3743  return *_solver_systems[sys_num];
3744 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.

◆ getSolverSystemNames()

const std::vector<SolverSystemName>& FEProblemBase::getSolverSystemNames ( ) const
inlineinherited
Returns
the solver system names in the problem

Definition at line 2942 of file FEProblemBase.h.

Referenced by ConsoleUtils::outputExecutionInformation().

2942 { return _solver_sys_names; }
std::vector< SolverSystemName > _solver_sys_names
The union of nonlinear and linear system names.

◆ getStandardVariable()

MooseVariable & FEProblemBase::getStandardVariable ( const THREAD_ID  tid,
const std::string &  var_name 
)
overridevirtualinherited

Returns the variable reference for requested MooseVariable which may be in any system.

Implements SubProblem.

Definition at line 6256 of file FEProblemBase.C.

Referenced by CoupleableMooseVariableDependencyIntermediateInterface::coupledValueByName(), FEProblemBase::projectFunctionOnCustomRange(), LinearFVKernel::requestVariableCellGradient(), and ElementSubdomainModifierBase::storeOverriddenDofValues().

6257 {
6258  for (auto & sys : _solver_systems)
6259  if (sys->hasVariable(var_name))
6260  return sys->getFieldVariable<Real>(tid, var_name);
6261  if (_aux->hasVariable(var_name))
6262  return _aux->getFieldVariable<Real>(tid, var_name);
6263 
6264  mooseError("Unknown variable " + var_name);
6265 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getSteadyStateConvergenceName()

const ConvergenceName & FEProblemBase::getSteadyStateConvergenceName ( ) const
inherited

Gets the steady-state detection convergence object name.

Definition at line 9811 of file FEProblemBase.C.

Referenced by FEProblemBase::addDefaultSteadyStateConvergence(), TransientBase::convergedToSteadyState(), and TransientBase::init().

9812 {
9814  return _steady_state_convergence_name.value();
9815  else
9816  mooseError("The steady convergence name has not been set.");
9817 }
std::optional< ConvergenceName > _steady_state_convergence_name
Steady-state detection convergence name.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getSystem()

System & FEProblemBase::getSystem ( const std::string &  var_name)
overridevirtualinherited

Returns the equation system containing the variable provided.

Implements SubProblem.

Definition at line 6328 of file FEProblemBase.C.

Referenced by FEProblemBase::addObjectParamsHelper(), MultiApp::appTransferVector(), FunctorChangeFunctorMaterialTempl< is_ad >::FunctorChangeFunctorMaterialTempl(), ElementSubdomainModifierBase::gatherPatchElements(), and ElementSubdomainModifierBase::storeOverriddenDofValues().

6329 {
6330  const auto [var_in_sys, sys_num] = determineSolverSystem(var_name);
6331  if (var_in_sys)
6332  return _solver_systems[sys_num]->system();
6333  else if (_aux->hasVariable(var_name) || _aux->hasScalarVariable(var_name))
6334  return _aux->system();
6335  else
6336  mooseError("Unable to find a system containing the variable " + var_name);
6337 }
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const override
Determine what solver system the provided variable name lies in.
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getSystemBase() [1/3]

const SystemBase & FEProblemBase::getSystemBase ( const unsigned int  sys_num) const
virtualinherited

Get constant reference to a system in this problem.

Parameters
sys_numThe number of the system

Definition at line 9524 of file FEProblemBase.C.

Referenced by FEProblemBase::addObjectParamsHelper(), PhysicsBase::copyVariablesFromMesh(), FEProblemBase::getSystemBase(), FEProblemBase::projectFunctionOnCustomRange(), and ElementSubdomainModifierBase::restoreOverriddenDofValues().

9525 {
9526  if (sys_num < _solver_systems.size())
9527  return *_solver_systems[sys_num];
9528 
9529  return *_aux;
9530 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ getSystemBase() [2/3]

SystemBase & FEProblemBase::getSystemBase ( const unsigned int  sys_num)
virtualinherited

Get non-constant reference to a system in this problem.

Parameters
sys_numThe number of the system

Definition at line 9545 of file FEProblemBase.C.

9546 {
9547  if (sys_num < _solver_systems.size())
9548  return *_solver_systems[sys_num];
9549 
9550  return *_aux;
9551 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ getSystemBase() [3/3]

SystemBase & FEProblemBase::getSystemBase ( const std::string &  sys_name)
inherited

Get non-constant reference to a system in this problem.

Parameters
sys_nameThe name of the system

Definition at line 9533 of file FEProblemBase.C.

9534 {
9535  if (std::find(_solver_sys_names.begin(), _solver_sys_names.end(), sys_name) !=
9536  _solver_sys_names.end())
9537  return getSystemBase(solverSysNum(sys_name));
9538  else if (sys_name == "aux0")
9539  return *_aux;
9540  else
9541  mooseError("System '" + sys_name + "' was requested from problem but does not exist.");
9542 }
KOKKOS_INLINE_FUNCTION const T * find(const T &target, const T *const begin, const T *const end)
Find a value in an array.
Definition: KokkosUtils.h:40
std::vector< SolverSystemName > _solver_sys_names
The union of nonlinear and linear system names.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
virtual const SystemBase & getSystemBase(const unsigned int sys_num) const
Get constant reference to a system in this problem.
unsigned int solverSysNum(const SolverSystemName &solver_sys_name) const override
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getTimeFromStateArg()

Real FEProblemBase::getTimeFromStateArg ( const Moose::StateArg state) const
inherited

Returns the time associated with the requested state.

Definition at line 7316 of file FEProblemBase.C.

Referenced by Function::evaluate(), Function::evaluateDotHelper(), Function::evaluateGradientHelper(), Function::evaluateHelper(), and ParsedFunctorMaterialTempl< is_ad >::ParsedFunctorMaterialTempl().

7317 {
7319  // If we are any iteration type other than time (e.g. nonlinear), then temporally we are still
7320  // in the present time
7321  return time();
7322 
7323  switch (state.state)
7324  {
7325  case 0:
7326  return time();
7327 
7328  case 1:
7329  return timeOld();
7330 
7331  default:
7332  mooseError("Unhandled state ", state.state, " in FEProblemBase::getTimeFromStateArg");
7333  }
7334 }
virtual Real & time() const
SolutionIterationType iteration_type
The solution iteration type, e.g. time or nonlinear.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
virtual Real & timeOld() const
unsigned int state
The state.

◆ getTransfers() [1/2]

std::vector< std::shared_ptr< Transfer > > FEProblemBase::getTransfers ( ExecFlagType  type,
Transfer::DIRECTION  direction 
) const
inherited

Get Transfers by ExecFlagType and direction.

Definition at line 5935 of file FEProblemBase.C.

5936 {
5937  if (direction == MultiAppTransfer::TO_MULTIAPP)
5939  else if (direction == MultiAppTransfer::FROM_MULTIAPP)
5941  else
5943 }
ExecuteMooseObjectWarehouse< Transfer > _from_multi_app_transfers
Transfers executed just after MultiApps to transfer data from them.
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
ExecuteMooseObjectWarehouse< Transfer > _to_multi_app_transfers
Transfers executed just before MultiApps to transfer data to them.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
ExecuteMooseObjectWarehouse< Transfer > _between_multi_app_transfers
Transfers executed just before MultiApps to transfer data between them.

◆ getTransfers() [2/2]

std::vector< std::shared_ptr< Transfer > > FEProblemBase::getTransfers ( Transfer::DIRECTION  direction) const
inherited

Definition at line 5946 of file FEProblemBase.C.

5947 {
5948  if (direction == MultiAppTransfer::TO_MULTIAPP)
5950  else if (direction == MultiAppTransfer::FROM_MULTIAPP)
5952  else
5954 }
ExecuteMooseObjectWarehouse< Transfer > _from_multi_app_transfers
Transfers executed just after MultiApps to transfer data from them.
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
ExecuteMooseObjectWarehouse< Transfer > _to_multi_app_transfers
Transfers executed just before MultiApps to transfer data to them.
ExecuteMooseObjectWarehouse< Transfer > _between_multi_app_transfers
Transfers executed just before MultiApps to transfer data between them.

◆ getUserObject()

template<class T >
T& FEProblemBase::getUserObject ( const std::string &  name,
unsigned int  tid = 0 
) const
inlineinherited

Get the user object by its name.

Parameters
nameThe name of the user object being retrieved
Returns
Reference to the user object

Definition at line 1399 of file FEProblemBase.h.

Referenced by ChangeOverFixedPointPostprocessor::ChangeOverFixedPointPostprocessor(), ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), MultiAppTransfer::checkParentAppUserObjectExecuteOn(), ExtraIDIntegralReporter::ExtraIDIntegralReporter(), ReporterTransferInterface::hideVariableHelper(), EigenExecutionerBase::init(), IntegralPreservingFunctionIC::initialSetup(), EigenProblemSolve::initialSetup(), ElementSubdomainModifierBase::initialSetup(), EigenExecutionerBase::inversePowerIteration(), and NEML2FEInterpolation::syncWithMainThread().

1400  {
1401  std::vector<T *> objs;
1402  theWarehouse()
1403  .query()
1404  .condition<AttribSystem>("UserObject")
1405  .condition<AttribThread>(tid)
1406  .condition<AttribName>(name)
1407  .queryInto(objs);
1408  if (objs.empty())
1409  mooseError("Unable to find user object with name '" + name + "'");
1410  return *(objs[0]);
1411  }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getUserObjectBase()

const UserObject & FEProblemBase::getUserObjectBase ( const std::string &  name,
const THREAD_ID  tid = 0 
) const
inherited

Get the user object by its name.

Parameters
nameThe name of the user object being retrieved
tidThe thread of the user object (defaults to 0)
Returns
Const reference to the user object

Definition at line 4736 of file FEProblemBase.C.

Referenced by MultiAppConservativeTransfer::adjustTransferredSolution(), MultiAppConservativeTransfer::adjustTransferredSolutionNearestPoint(), MultiApp::appUserObjectBase(), EigenProblem::checkProblemIntegrity(), FEProblemBase::checkUserObjectNameCollision(), UserObjectInterface::getUserObjectFromFEProblem(), MultiAppCloneReporterTransfer::initialSetup(), MultiAppConservativeTransfer::initialSetup(), Terminator::initialSetup(), and FunctorIC::value().

4737 {
4738  std::vector<UserObject *> objs;
4739  theWarehouse()
4740  .query()
4741  .condition<AttribSystem>("UserObject")
4742  .condition<AttribThread>(tid)
4743  .condition<AttribName>(name)
4744  .queryInto(objs);
4745  if (objs.empty())
4746  {
4747  mooseAssert(getMooseApp().actionWarehouse().isTaskComplete("add_user_object"),
4748  "A UserObject getter was called before UserObjects have been constructed. The "
4749  "requested UserObject '" +
4750  name + "' may exist in the input file, but UserObjects are not available yet.");
4751 
4752  mooseError("Unable to find user object with name '" + name + "'");
4753  }
4754  mooseAssert(objs.size() == 1, "Should only find one UO");
4755  return *(objs[0]);
4756 }
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getUserObjectJacobianVariables()

const std::vector<const MooseVariableFEBase *>& FEProblemBase::getUserObjectJacobianVariables ( const THREAD_ID  tid) const
inlineinherited

Definition at line 353 of file FEProblemBase.h.

Referenced by ComputeUserObjectsThread::onBoundary(), and ComputeUserObjectsThread::onElement().

354  {
355  return _uo_jacobian_moose_vars[tid];
356  }
std::vector< std::vector< const MooseVariableFEBase * > > _uo_jacobian_moose_vars

◆ getVariable() [1/4]

virtual const MooseVariableFieldBase& SubProblem::getVariable
inherited

Returns the variable reference for requested variable which must be of the expected_var_type (Nonlinear vs.

Auxiliary) and expected_var_field_type (standard, scalar, vector). The default values of VAR_ANY and VAR_FIELD_ANY should be used when "any" type of variable is acceptable. Throws an error if the variable in question is not in the expected System or of the expected type.

◆ getVariable() [2/4]

virtual MooseVariableFieldBase& SubProblem::getVariable
inlineinherited

Definition at line 279 of file SubProblem.h.

283  {
284  return const_cast<MooseVariableFieldBase &>(const_cast<const SubProblem *>(this)->getVariable(
285  tid, var_name, expected_var_type, expected_var_field_type));
286  }
This class provides an interface for common operations on field variables of both FE and FV types wit...
virtual const MooseVariableFieldBase & getVariable(const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY) const override
Returns the variable reference for requested variable which must be of the expected_var_type (Nonline...
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78

◆ getVariable() [3/4]

const MooseVariableFieldBase & FEProblemBase::getVariable ( const THREAD_ID  tid,
const std::string &  var_name,
Moose::VarKindType  expected_var_type = Moose::VarKindType::VAR_ANY,
Moose::VarFieldType  expected_var_field_type = Moose::VarFieldType::VAR_FIELD_ANY 
) const
overridevirtualinherited

Returns the variable reference for requested variable which must be of the expected_var_type (Nonlinear vs.

Auxiliary) and expected_var_field_type (standard, scalar, vector). The default values of VAR_ANY and VAR_FIELD_ANY should be used when "any" type of variable is acceptable. Throws an error if the variable in question is not in the expected System or of the expected type.

Implements SubProblem.

Definition at line 6246 of file FEProblemBase.C.

Referenced by FEProblemBase::addFVInitialCondition(), FEProblemBase::addInitialCondition(), EigenProblem::adjustEigenVector(), MultiAppConservativeTransfer::adjustTransferredSolution(), MultiAppConservativeTransfer::adjustTransferredSolutionNearestPoint(), MultiAppGeneralFieldNearestLocationTransfer::buildKDTrees(), MultiAppGeneralFieldShapeEvaluationTransfer::buildMeshFunctions(), CoupleableMooseVariableDependencyIntermediateInterface::coupledArrayValueByName(), CoupleableMooseVariableDependencyIntermediateInterface::coupledValueByName(), NodalNormalsCorner::execute(), NodalNormalsEvaluator::execute(), MultiAppProjectionTransfer::execute(), MultiAppGeometricInterpolationTransfer::execute(), MultiAppUserObjectTransfer::execute(), NodalNormalsPreprocessor::execute(), NEML2FEInterpolation::getMOOSEVariable(), LazyCoupleable::init(), AdvancedOutput::initAvailableLists(), MultiAppGeneralFieldNearestLocationTransfer::initialSetup(), MultiAppProjectionTransfer::initialSetup(), AdvancedOutput::initShowHideLists(), MultiApplibMeshToMFEMShapeEvaluationTransfer::interpolatelibMeshVariable(), SolutionUserObjectBase::pointValueWrapper(), PointwiseRenormalizeVector::PointwiseRenormalizeVector(), BlockRestrictionDebugOutput::printBlockRestrictionGroups(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), MultiAppProjectionTransfer::projectSolution(), MultiAppDofCopyTransfer::transfer(), MultiAppShapeEvaluationTransfer::transferVariable(), and MultiAppMFEMTolibMeshShapeEvaluationTransfer::transferVariables().

6250 {
6251  return getVariableHelper(
6252  tid, var_name, expected_var_type, expected_var_field_type, _solver_systems, *_aux);
6253 }
MooseVariableFieldBase & getVariableHelper(const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type, Moose::VarFieldType expected_var_field_type, const std::vector< T > &nls, const SystemBase &aux) const
Helper function called by getVariable that handles the logic for checking whether Variables of the re...
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ getVariable() [4/4]

virtual MooseVariableFieldBase& SubProblem::getVariable ( const THREAD_ID  tid,
const std::string &  var_name,
Moose::VarKindType  expected_var_type = Moose::VarKindType::VAR_ANY,
Moose::VarFieldType  expected_var_field_type = Moose::VarFieldType::VAR_FIELD_ANY 
)
inlinevirtualinherited

Definition at line 279 of file SubProblem.h.

283  {
284  return const_cast<MooseVariableFieldBase &>(const_cast<const SubProblem *>(this)->getVariable(
285  tid, var_name, expected_var_type, expected_var_field_type));
286  }
This class provides an interface for common operations on field variables of both FE and FV types wit...
virtual const MooseVariableFieldBase & getVariable(const THREAD_ID tid, const std::string &var_name, Moose::VarKindType expected_var_type=Moose::VarKindType::VAR_ANY, Moose::VarFieldType expected_var_field_type=Moose::VarFieldType::VAR_FIELD_ANY) const =0
Returns the variable reference for requested variable which must be of the expected_var_type (Nonline...
Generic class for solving transient nonlinear problems.
Definition: SubProblem.h:78

◆ getVariableHelper() [1/2]

template<typename T >
MooseVariableFEBase& SubProblem::getVariableHelper ( const THREAD_ID  tid,
const std::string &  var_name,
Moose::VarKindType  expected_var_type,
Moose::VarFieldType  expected_var_field_type,
const std::vector< T > &  systems,
const SystemBase aux 
) const
inherited

Definition at line 819 of file SubProblem.C.

825 {
826  // Eventual return value
827  MooseVariableFEBase * var = nullptr;
828 
829  const auto [var_in_sys, sys_num] = determineSolverSystem(var_name);
830 
831  // First check that the variable is found on the expected system.
832  if (expected_var_type == Moose::VarKindType::VAR_ANY)
833  {
834  if (var_in_sys)
835  var = &(systems[sys_num]->getVariable(tid, var_name));
836  else if (aux.hasVariable(var_name))
837  var = &(aux.getVariable(tid, var_name));
838  else
839  mooseError("Unknown variable " + var_name);
840  }
841  else if (expected_var_type == Moose::VarKindType::VAR_SOLVER && var_in_sys &&
842  systems[sys_num]->hasVariable(var_name))
843  var = &(systems[sys_num]->getVariable(tid, var_name));
844  else if (expected_var_type == Moose::VarKindType::VAR_AUXILIARY && aux.hasVariable(var_name))
845  var = &(aux.getVariable(tid, var_name));
846  else
847  {
848  std::string expected_var_type_string =
849  (expected_var_type == Moose::VarKindType::VAR_SOLVER ? "nonlinear" : "auxiliary");
850  mooseError("No ",
851  expected_var_type_string,
852  " variable named ",
853  var_name,
854  " found. "
855  "Did you specify an auxiliary variable when you meant to specify a nonlinear "
856  "variable (or vice-versa)?");
857  }
858 
859  // Now make sure the var found has the expected field type.
860  if ((expected_var_field_type == Moose::VarFieldType::VAR_FIELD_ANY) ||
861  (expected_var_field_type == var->fieldType()))
862  return *var;
863  else
864  {
865  std::string expected_var_field_type_string =
866  MooseUtils::toLower(Moose::stringify(expected_var_field_type));
867  std::string var_field_type_string = MooseUtils::toLower(Moose::stringify(var->fieldType()));
868 
869  mooseError("No ",
870  expected_var_field_type_string,
871  " variable named ",
872  var_name,
873  " found. "
874  "Did you specify a ",
875  var_field_type_string,
876  " variable when you meant to specify a ",
877  expected_var_field_type_string,
878  " variable?");
879  }
880 }
This class provides an interface for common operations on field variables of both FE and FV types wit...
std::string toLower(std::string name)
Convert supplied string to lower case.
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
virtual bool hasVariable(const std::string &var_name) const =0
Whether or not this problem has the variable.
virtual bool hasVariable(const std::string &var_name) const
Query a system for a variable.
Definition: SystemBase.C:852
virtual std::pair< bool, unsigned int > determineSolverSystem(const std::string &var_name, bool error_if_not_found=false) const =0
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
virtual Moose::VarFieldType fieldType() const =0
Field type of this variable.
MooseVariableFieldBase & getVariable(THREAD_ID tid, const std::string &var_name) const
Gets a reference to a variable of with specified name.
Definition: SystemBase.C:91

◆ getVariableHelper() [2/2]

template<typename T >
MooseVariableFieldBase& SubProblem::getVariableHelper ( const THREAD_ID  tid,
const std::string &  var_name,
Moose::VarKindType  expected_var_type,
Moose::VarFieldType  expected_var_field_type,
const std::vector< T > &  nls,
const SystemBase aux 
) const
protectedinherited

Helper function called by getVariable that handles the logic for checking whether Variables of the requested type are available.

Referenced by DisplacedProblem::getVariable(), and FEProblemBase::getVariable().

◆ getVariableNames()

std::vector< VariableName > FEProblemBase::getVariableNames ( )
virtualinherited

Returns a list of all the variables in the problem (both from the NL and Aux systems.

Definition at line 9266 of file FEProblemBase.C.

Referenced by EigenProblem::adjustEigenVector(), AdvancedOutput::initAvailableLists(), and ElementSubdomainModifierBase::initialSetup().

9267 {
9268  std::vector<VariableName> names;
9269 
9270  for (auto & sys : _solver_systems)
9271  {
9272  const std::vector<VariableName> & var_names = sys->getVariableNames();
9273  names.insert(names.end(), var_names.begin(), var_names.end());
9274  }
9275 
9276  const std::vector<VariableName> & aux_var_names = _aux->getVariableNames();
9277  names.insert(names.end(), aux_var_names.begin(), aux_var_names.end());
9278 
9279  return names;
9280 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ getVectorPostprocessorObjectByName()

const VectorPostprocessor & FEProblemBase::getVectorPostprocessorObjectByName ( const std::string &  object_name,
const THREAD_ID  tid = 0 
) const
inherited

Return the VPP object given the name.

Parameters
object_nameThe name of the VPP object
Returns
Desired VPP object

This is used by various output objects as well as the scatter value handling.

See also
CSV.C, XMLOutput.C, VectorPostprocessorInterface.C

Definition at line 4930 of file FEProblemBase.C.

Referenced by CombinedVectorPostprocessor::CombinedVectorPostprocessor(), VectorPostprocessorInterface::isVectorPostprocessorDistributedByName(), CSV::output(), and XMLOutput::outputVectorPostprocessors().

4932 {
4933  std::vector<VectorPostprocessor *> objs;
4934  theWarehouse()
4935  .query()
4937  .condition<AttribThread>(tid)
4938  .condition<AttribName>(object_name)
4939  .queryInto(objs);
4940 
4941  if (objs.empty())
4942  {
4943  mooseAssert(
4944  getMooseApp().actionWarehouse().isTaskComplete("add_vector_postprocessor"),
4945  "A VectorPostprocessor getter was called before VectorPostprocessors have been "
4946  "constructed. The requested VectorPostprocessor '" +
4947  object_name +
4948  "' may exist in the input file, but VectorPostprocessors are not available yet.");
4949 
4950  mooseError("Unable to find VectorPostprocessor with name '", object_name, "'");
4951  }
4952  mooseAssert(objs.size() == 1,
4953  "We shouldn't find more than one vector postprocessor object for a given name");
4954  return *(objs[0]);
4955 }
MooseApp & getMooseApp() const
Get the MooseApp this class is associated with.
Definition: MooseBase.h:87
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ getVectorPostprocessorValueByName()

const VectorPostprocessorValue & FEProblemBase::getVectorPostprocessorValueByName ( const std::string &  object_name,
const std::string &  vector_name,
std::size_t  t_index = 0 
) const
inherited

Get a read-only reference to the vector value associated with the VectorPostprocessor.

Parameters
object_nameThe name of the VPP object.
vector_nameThe namve of the decalred vector within the object.
Returns
Referent to the vector of data.

Note: This method is only for retrieving values that already exist, the VectorPostprocessor and VectorPostprocessorInterface objects should be used rather than this method for creating and getting values within objects.

Definition at line 4911 of file FEProblemBase.C.

Referenced by HistogramVectorPostprocessor::execute().

4914 {
4916  VectorPostprocessorReporterName(object_name, vector_name), t_index);
4917 }
A ReporterName that represents a VectorPostprocessor.
Definition: ReporterName.h:152
ReporterData _reporter_data
const T & getReporterValue(const ReporterName &reporter_name, const MooseObject &consumer, const ReporterMode &mode, const std::size_t time_index=0) const
Method for returning read only references to Reporter values.
Definition: ReporterData.h:394
std::vector< Real > VectorPostprocessorValue
Definition: MooseTypes.h:231

◆ getVectorTag()

const VectorTag & SubProblem::getVectorTag ( const TagID  tag_id) const
virtualinherited

Get a VectorTag from a TagID.

Reimplemented in DisplacedProblem.

Definition at line 162 of file SubProblem.C.

Referenced by FEProblemBase::addCachedResidualDirectly(), Assembly::cacheResidual(), Assembly::cacheResidualNodes(), DisplacedProblem::getVectorTag(), SubProblem::getVectorTags(), TaggingInterface::prepareVectorTagInternal(), TaggingInterface::prepareVectorTagLower(), TaggingInterface::prepareVectorTagNeighbor(), FEProblemBase::setResidual(), and FEProblemBase::setResidualNeighbor().

163 {
164  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
165 
166  if (!vectorTagExists(tag_id))
167  mooseError("Vector tag with ID ", tag_id, " does not exist");
168 
169  return _vector_tags[tag_id];
170 }
std::vector< VectorTag > _vector_tags
The declared vector tags.
Definition: SubProblem.h:1185
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
virtual bool vectorTagExists(const TagID tag_id) const
Check to see if a particular Tag exists.
Definition: SubProblem.h:201
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getVectorTagID()

TagID SubProblem::getVectorTagID ( const TagName &  tag_name) const
virtualinherited

Get a TagID from a TagName.

Reimplemented in DisplacedProblem.

Definition at line 204 of file SubProblem.C.

Referenced by Coupleable::coupledVectorTagArrayGradient(), Coupleable::coupledVectorTagArrayGradients(), Coupleable::coupledVectorTagArrayValues(), Coupleable::coupledVectorTagDofValues(), Coupleable::coupledVectorTagGradient(), Coupleable::coupledVectorTagGradients(), Coupleable::coupledVectorTagValues(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), DisplacedProblem::getVectorTagID(), MooseVariableDataBase< OutputType >::MooseVariableDataBase(), ReferenceResidualConvergence::ReferenceResidualConvergence(), SolverSystem::setSolution(), TaggingInterface::TaggingInterface(), TagVectorAux::TagVectorAux(), MultiAppDofCopyTransfer::transfer(), TaggingInterface::useVectorTag(), Coupleable::vectorTagDofValueHelper(), and Coupleable::vectorTagValueHelper().

205 {
206  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
207 
208  const auto tag_name_upper = MooseUtils::toUpper(tag_name);
209  const auto search = _vector_tags_name_map.find(tag_name_upper);
210  if (search != _vector_tags_name_map.end())
211  return search->second;
212 
213  std::string message =
214  tag_name_upper == "TIME"
215  ? ".\n\nThis may occur if "
216  "you have a TimeKernel in your problem but did not specify a transient executioner."
217  : "";
218  mooseError("Vector tag '", tag_name_upper, "' does not exist", message);
219 }
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
std::string toUpper(std::string name)
Convert supplied string to upper case.
std::map< TagName, TagID > _vector_tags_name_map
Map of vector tag TagName to TagID.
Definition: SubProblem.h:1195
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getVectorTags() [1/2]

std::vector< VectorTag > SubProblem::getVectorTags ( const std::set< TagID > &  tag_ids) const
inherited

Definition at line 173 of file SubProblem.C.

Referenced by FEProblemBase::computeLinearSystemSys(), EigenProblem::computeResidualAB(), FEProblemBase::computeResidualAndJacobian(), EigenProblem::computeResidualTag(), ComputeResidualAndJacobianThread::determineObjectWarehouses(), DisplacedProblem::getVectorTags(), SubProblem::numVectorTags(), ComputeMortarFunctor::operator()(), and FEProblemBase::setCurrentResidualVectorTags().

174 {
175  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
176 
177  std::vector<VectorTag> tags;
178  tags.reserve(tag_ids.size());
179  for (const auto & tag_id : tag_ids)
180  tags.push_back(getVectorTag(tag_id));
181  return tags;
182 }
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
virtual const VectorTag & getVectorTag(const TagID tag_id) const
Get a VectorTag from a TagID.
Definition: SubProblem.C:162

◆ getVectorTags() [2/2]

const std::vector< VectorTag > & SubProblem::getVectorTags ( const Moose::VectorTagType  type = Moose::VECTOR_TAG_ANY) const
virtualinherited

Return all vector tags, where a tag is represented by a map from name to ID.

Can optionally be limited to a vector tag type.

Reimplemented in DisplacedProblem.

Definition at line 185 of file SubProblem.C.

186 {
187  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
188 
190  return _vector_tags;
191  else
192  return _typed_vector_tags[type];
193 }
std::vector< VectorTag > _vector_tags
The declared vector tags.
Definition: SubProblem.h:1185
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::vector< std::vector< VectorTag > > _typed_vector_tags
The vector tags associated with each VectorTagType This is kept separate from _vector_tags for quick ...
Definition: SubProblem.h:1192

◆ getVectorVariable()

VectorMooseVariable & FEProblemBase::getVectorVariable ( const THREAD_ID  tid,
const std::string &  var_name 
)
overridevirtualinherited

Returns the variable reference for requested VectorMooseVariable which may be in any system.

Implements SubProblem.

Definition at line 6280 of file FEProblemBase.C.

6281 {
6282  for (auto & sys : _solver_systems)
6283  if (sys->hasVariable(var_name))
6284  return sys->getFieldVariable<RealVectorValue>(tid, var_name);
6285  if (_aux->hasVariable(var_name))
6286  return _aux->getFieldVariable<RealVectorValue>(tid, var_name);
6287 
6288  mooseError("Unknown variable " + var_name);
6289 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ getXFEM()

std::shared_ptr<XFEMInterface> FEProblemBase::getXFEM ( )
inlineinherited

Get a pointer to the XFEM controller object.

Definition at line 2143 of file FEProblemBase.h.

2143 { return _xfem; }
std::shared_ptr< XFEMInterface > _xfem
Pointer to XFEM controller.

◆ ghostedElems()

virtual std::set<dof_id_type>& SubProblem::ghostedElems ( )
inlinevirtualinherited

Return the list of elements that should have their DoFs ghosted to this processor.

Returns
The list

Reimplemented in DisplacedProblem.

Definition at line 680 of file SubProblem.h.

Referenced by SystemBase::augmentSendList(), NearestNodeLocator::findNodes(), DisplacedProblem::ghostedElems(), and NearestNodeLocator::updatePatch().

680 { return _ghosted_elems; }
std::set< dof_id_type > _ghosted_elems
Elements that should have Dofs ghosted to the local processor.
Definition: SubProblem.h:1108

◆ ghostGhostedBoundaries()

void FEProblemBase::ghostGhostedBoundaries ( )
overridevirtualinherited

Causes the boundaries added using addGhostedBoundary to actually be ghosted.

Implements SubProblem.

Definition at line 2240 of file FEProblemBase.C.

Referenced by DisplacedProblem::ghostGhostedBoundaries(), FEProblemBase::init(), and FEProblemBase::meshChanged().

2241 {
2242  TIME_SECTION("ghostGhostedBoundaries", 3, "Ghosting Ghosted Boundaries");
2243 
2245 
2246  if (_displaced_problem)
2248 }
MooseMesh & _mesh
std::shared_ptr< DisplacedProblem > _displaced_problem
void ghostGhostedBoundaries()
Actually do the ghosting of boundaries that need to be ghosted to this processor. ...
Definition: MooseMesh.C:3414
MooseMesh * _displaced_mesh

◆ hasActiveElementalMooseVariables()

bool SubProblem::hasActiveElementalMooseVariables ( const THREAD_ID  tid) const
virtualinherited

Whether or not a list of active elemental moose variables has been set.

Returns
True if there has been a list of active elemental moose variables set, False otherwise

Definition at line 461 of file SubProblem.C.

Referenced by SystemBase::prepare(), SystemBase::prepareFace(), and SystemBase::reinitElem().

462 {
464 }
std::vector< unsigned int > _has_active_elemental_moose_variables
Whether or not there is currently a list of active elemental moose variables.
Definition: SubProblem.h:1094

◆ hasActiveMaterialProperties()

bool FEProblemBase::hasActiveMaterialProperties ( const THREAD_ID  tid) const
inherited

Method to check whether or not a list of active material roperties has been set.

This method is called by reinitMaterials to determine whether Material computeProperties methods need to be called. If the return is False, this check prevents unnecessary material property computation

Parameters
tidThe thread id
Returns
True if there has been a list of active material properties set, False otherwise

Definition at line 6454 of file FEProblemBase.C.

Referenced by ComputeMarkerThread::onElement(), FEProblemBase::reinitMaterials(), FEProblemBase::reinitMaterialsBoundary(), FEProblemBase::reinitMaterialsFace(), FEProblemBase::reinitMaterialsFaceOnBoundary(), FEProblemBase::reinitMaterialsInterface(), FEProblemBase::reinitMaterialsNeighbor(), and FEProblemBase::reinitMaterialsNeighborOnBoundary().

6455 {
6456  return _has_active_material_properties[tid];
6457 }
std::vector< unsigned char > _has_active_material_properties
Whether there are active material properties on each thread.

◆ hasAuxiliaryVariable()

bool SubProblem::hasAuxiliaryVariable ( const std::string &  var_name) const
virtualinherited

Whether or not this problem has this auxiliary variable.

Definition at line 812 of file SubProblem.C.

Referenced by FixedPointSolve::findTransformedSystem(), FunctorChangeFunctorMaterialTempl< is_ad >::FunctorChangeFunctorMaterialTempl(), SubProblem::getFunctor(), and NearestNodeValueAux::NearestNodeValueAux().

813 {
814  return systemBaseAuxiliary().hasVariable(var_name);
815 }
virtual const SystemBase & systemBaseAuxiliary() const =0
Return the auxiliary system object as a base class reference.
virtual bool hasVariable(const std::string &var_name) const
Query a system for a variable.
Definition: SystemBase.C:852

◆ hasBase()

bool MooseBase::hasBase ( ) const
inlineinherited
Returns
Whether or not this object has a registered base (set via InputParameters::registerBase())

Definition at line 142 of file MooseBase.h.

142 { return _pars.hasBase(); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
bool hasBase() const

◆ hasBlockMaterialProperty()

bool SubProblem::hasBlockMaterialProperty ( SubdomainID  block_id,
const std::string &  prop_name 
)
virtualinherited

Check if a material property is defined on a block.

Definition at line 512 of file SubProblem.C.

513 {
514  auto it = _map_block_material_props.find(bid);
515  if (it == _map_block_material_props.end())
516  return false;
517 
518  if (it->second.count(prop_name) > 0)
519  return true;
520  else
521  return false;
522 }
std::map< SubdomainID, std::set< std::string > > _map_block_material_props
Map of material properties (block_id -> list of properties)
Definition: SubProblem.h:1067

◆ hasBoundaryMaterialProperty()

bool SubProblem::hasBoundaryMaterialProperty ( BoundaryID  boundary_id,
const std::string &  prop_name 
)
virtualinherited

Check if a material property is defined on a block.

Definition at line 571 of file SubProblem.C.

572 {
573  auto it = _map_boundary_material_props.find(bid);
574  if (it == _map_boundary_material_props.end())
575  return false;
576 
577  if (it->second.count(prop_name) > 0)
578  return true;
579  else
580  return false;
581 }
std::map< BoundaryID, std::set< std::string > > _map_boundary_material_props
Map for boundary material properties (boundary_id -> list of properties)
Definition: SubProblem.h:1070

◆ hasConvergence()

bool FEProblemBase::hasConvergence ( const std::string &  name,
const THREAD_ID  tid = 0 
) const
virtualinherited

Returns true if the problem has a Convergence object of the given name.

Definition at line 2767 of file FEProblemBase.C.

Referenced by ParsedConvergence::initializeSymbols().

2768 {
2769  return _convergences.hasActiveObject(name, tid);
2770 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
MooseObjectWarehouse< Convergence > _convergences
convergence warehouse
bool hasActiveObject(const std::string &name, THREAD_ID tid=0) const
Convenience functions for checking/getting specific objects.

◆ hasDampers()

bool FEProblemBase::hasDampers ( )
inlineinherited

Whether or not this system has dampers.

Definition at line 1624 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::preInit(), and NonlinearSystem::solve().

1624 { return _has_dampers; }
bool _has_dampers
Whether or not this system has any Dampers associated with it.

◆ hasDistribution()

bool FEProblemBase::hasDistribution ( const std::string &  name) const
virtualinherited

Definition at line 2843 of file FEProblemBase.C.

2844 {
2845  std::vector<Distribution *> objs;
2846  theWarehouse()
2847  .query()
2848  .condition<AttribSystem>("Distribution")
2849  .condition<AttribName>(name)
2850  .queryInto(objs);
2851  return !objs.empty();
2852 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ hasException()

virtual bool FEProblemBase::hasException ( )
inlinevirtualinherited

Whether or not an exception has occurred.

Definition at line 535 of file FEProblemBase.h.

Referenced by NonlinearSystem::converged(), ThreadedElementLoop< ConstElemPointerRange >::keepGoing(), and ThreadedNodeLoop< ConstBndNodeRange, ConstBndNodeRange::const_iterator >::keepGoing().

535 { return _has_exception; }
bool _has_exception
Whether or not an exception has occurred.

◆ hasFunction()

bool FEProblemBase::hasFunction ( const std::string &  name,
const THREAD_ID  tid = 0 
)
virtualinherited

Definition at line 2709 of file FEProblemBase.C.

Referenced by DiffusionCG::addFEBCs(), DiffusionCG::addFEKernels(), DiffusionFV::addFVBCs(), DiffusionFV::addFVKernels(), FunctorIC::FunctorIC(), FEProblemBase::getFunction(), FunctionInterface::hasFunctionByName(), MooseParsedFunctionWrapper::initialize(), ChainControlParsedFunctionWrapper::initializeFunctionInputs(), ParsedConvergence::initializeSymbols(), and MooseParsedFunction::initialSetup().

2710 {
2711  return _functions.hasActiveObject(name, tid);
2712 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool hasActiveObject(const std::string &name, THREAD_ID tid=0) const
Convenience functions for checking/getting specific objects.
MooseObjectWarehouse< Function > _functions
functions

◆ hasFunctor()

bool SubProblem::hasFunctor ( const std::string &  name,
const THREAD_ID  tid 
) const
inherited

checks whether we have a functor corresponding to name on the thread id tid

Definition at line 1275 of file SubProblem.C.

Referenced by FunctorInterface::isFunctor().

1276 {
1277  mooseAssert(tid < _functors.size(), "Too large a thread ID");
1278  auto & functors = _functors[tid];
1279  return (functors.find("wraps_" + name) != functors.end());
1280 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::vector< std::multimap< std::string, std::tuple< TrueFunctorIs, std::unique_ptr< Moose::FunctorEnvelopeBase >, std::unique_ptr< Moose::FunctorEnvelopeBase > > > > _functors
A container holding pointers to all the functors in our problem.
Definition: SubProblem.h:1159

◆ hasFunctorWithType()

template<typename T >
bool SubProblem::hasFunctorWithType ( const std::string &  name,
const THREAD_ID  tid 
) const
inherited

checks whether we have a functor of type T corresponding to name on the thread id tid

Definition at line 1338 of file SubProblem.h.

1339 {
1340  mooseAssert(tid < _functors.size(), "Too large a thread ID");
1341  auto & functors = _functors[tid];
1342 
1343  const auto & it = functors.find("wraps_" + name);
1344  constexpr bool requested_functor_is_ad =
1345  !std::is_same<T, typename MetaPhysicL::RawType<T>::value_type>::value;
1346 
1347  if (it == functors.end())
1348  return false;
1349  else
1350  return dynamic_cast<Moose::Functor<T> *>(
1351  requested_functor_is_ad ? std::get<2>(it->second).get() : std::get<1>(it->second).get());
1352 }
This is a wrapper that forwards calls to the implementation, which can be switched out at any time wi...
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::vector< std::multimap< std::string, std::tuple< TrueFunctorIs, std::unique_ptr< Moose::FunctorEnvelopeBase >, std::unique_ptr< Moose::FunctorEnvelopeBase > > > > _functors
A container holding pointers to all the functors in our problem.
Definition: SubProblem.h:1159
const Elem & get(const ElemType type_in)

◆ hasFVInterpolationMethod()

bool FEProblemBase::hasFVInterpolationMethod ( const InterpolationMethodName &  name) const
inherited

Check if an FV interpolation method with a given name exists.

Definition at line 4848 of file FEProblemBase.C.

Referenced by FVInterpolationMethodInterface::hasFVInterpolationMethod().

4849 {
4850  std::vector<FVInterpolationMethod *> methods;
4851  theWarehouse()
4852  .query()
4853  .condition<AttribSystem>("FVInterpolationMethod")
4854  .condition<AttribThread>(0)
4855  .condition<AttribName>(name)
4856  .queryInto(methods);
4857  return !methods.empty();
4858 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ hasInitialAdaptivity() [1/2]

bool FEProblemBase::hasInitialAdaptivity ( ) const
inlineinherited

Return a Boolean indicating whether initial AMR is turned on.

Definition at line 2131 of file FEProblemBase.h.

2131 { return _adaptivity.getInitialSteps() > 0; }
Adaptivity _adaptivity
unsigned int getInitialSteps() const
Pull out the number of initial steps previously set by calling init()
Definition: Adaptivity.h:112

◆ hasInitialAdaptivity() [2/2]

bool FEProblemBase::hasInitialAdaptivity ( ) const
inlineinherited

Return a Boolean indicating whether initial AMR is turned on.

Definition at line 2136 of file FEProblemBase.h.

2136 { return false; }

◆ hasJacobian()

bool FEProblemBase::hasJacobian ( ) const
inherited

Returns _has_jacobian.

Definition at line 9455 of file FEProblemBase.C.

9456 {
9457  return _has_jacobian;
9458 }
bool _has_jacobian
Indicates if the Jacobian was computed.

◆ hasKokkosFunction()

virtual bool FEProblemBase::hasKokkosFunction ( const std::string &  name) const
virtualinherited

Get whether a Kokkos function exists.

Parameters
nameThe Kokkos function name
Returns
Whether a Kokkos function exists

Referenced by FEProblemBase::getKokkosFunction().

◆ hasKokkosObjects()

bool FEProblemBase::hasKokkosObjects ( ) const
inlineinherited
Returns
whether any Kokkos object was added in the problem

Definition at line 2966 of file FEProblemBase.h.

Referenced by MooseMesh::update().

2966 { return _has_kokkos_objects; }
bool _has_kokkos_objects
Whether we have any Kokkos objects.

◆ hasKokkosResidualObjects()

bool FEProblemBase::hasKokkosResidualObjects ( ) const
inlineinherited

◆ hasKokkosUserObject()

bool FEProblemBase::hasKokkosUserObject ( const std::string &  name) const
inherited

Check if there if a Kokkos user object of given name.

Parameters
nameThe name of the Kokkos user object being checked for
Returns
true if the Kokkos user object exists, false otherwise

Referenced by FEProblemBase::checkUserObjectNameCollision(), UserObjectInterface::getUserObjectFromFEProblem(), and UserObjectInterface::hasUserObjectByName().

◆ hasLinearConvergenceObjects()

bool FEProblemBase::hasLinearConvergenceObjects ( ) const
inherited

Whether we have linear convergence objects.

Definition at line 9778 of file FEProblemBase.C.

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

9779 {
9780  // If false,this means we have not set one, not that we are querying this too early
9781  // TODO: once there is a default linear CV object, error on the 'not set' case
9782  return _linear_convergence_names.has_value();
9783 }
std::optional< std::vector< ConvergenceName > > _linear_convergence_names
Linear system(s) convergence name(s) (if any)

◆ hasLinearVariable()

bool SubProblem::hasLinearVariable ( const std::string &  var_name) const
virtualinherited

Whether or not this problem has this linear variable.

Definition at line 803 of file SubProblem.C.

Referenced by SubProblem::getFunctor().

804 {
805  for (const auto i : make_range(numLinearSystems()))
806  if (systemBaseLinear(i).hasVariable(var_name))
807  return true;
808  return false;
809 }
virtual bool hasVariable(const std::string &var_name) const =0
Whether or not this problem has the variable.
IntRange< T > make_range(T beg, T end)
virtual const SystemBase & systemBaseLinear(const unsigned int sys_num) const =0
Return the linear system object as a base class reference given the system number.
virtual std::size_t numLinearSystems() const =0

◆ hasMFEMObject()

bool MFEMProblem::hasMFEMObject ( const std::string &  system,
const std::string &  name 
) const

Determine whether an MFEM object with the supplied system and name exists.

Definition at line 894 of file MFEMProblem.C.

Referenced by addMFEMFESpaceFromMOOSEVariable().

895 {
896  std::vector<MooseObject *> objs;
897  theWarehouse()
898  .query()
899  .condition<AttribSystem>(system)
900  .condition<AttribThread>(0)
901  .condition<AttribName>(name)
902  .queryInto(objs);
903  return !objs.empty();
904 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ hasMortarCoupling()

virtual bool FEProblemBase::hasMortarCoupling ( ) const
inlinevirtualinherited

Whether the simulation has mortar coupling.

Definition at line 2664 of file FEProblemBase.h.

2664 { return _has_mortar; }
bool _has_mortar
Whether the simulation requires mortar coupling.

◆ hasMultiApp()

bool FEProblemBase::hasMultiApp ( const std::string &  name) const
inherited

Definition at line 5850 of file FEProblemBase.C.

Referenced by FEProblemBase::getMultiApp().

5851 {
5852  return _multi_apps.hasActiveObject(multi_app_name);
5853 }
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
bool hasActiveObject(const std::string &name, THREAD_ID tid=0) const
Convenience functions for checking/getting specific objects.

◆ hasMultiApps() [1/2]

bool FEProblemBase::hasMultiApps ( ) const
inlineinherited

Returns whether or not the current simulation has any multiapps.

Definition at line 1610 of file FEProblemBase.h.

Referenced by DefaultMultiAppFixedPointConvergence::checkConvergence(), FEProblemBase::checkProblemIntegrity(), DefaultMultiAppFixedPointConvergence::DefaultMultiAppFixedPointConvergence(), FixedPointIterationAdaptiveDT::init(), and DefaultMultiAppFixedPointConvergence::preExecute().

1610 { return _multi_apps.hasActiveObjects(); }
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
bool hasActiveObjects(THREAD_ID tid=0) const

◆ hasMultiApps() [2/2]

bool FEProblemBase::hasMultiApps ( ExecFlagType  type) const
inherited

Definition at line 5844 of file FEProblemBase.C.

5845 {
5846  return _multi_apps[type].hasActiveObjects();
5847 }
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
bool hasActiveObjects(THREAD_ID tid=0) const

◆ hasNeighborCoupling()

virtual bool FEProblemBase::hasNeighborCoupling ( ) const
inlinevirtualinherited

Whether the simulation has neighbor coupling.

Definition at line 2659 of file FEProblemBase.h.

bool _has_internal_edge_residual_objects
Whether the problem has dgkernels or interface kernels.

◆ hasNonlocalCoupling()

virtual bool FEProblemBase::hasNonlocalCoupling ( ) const
inlineoverridevirtualinherited

Whether the simulation has active nonlocal coupling which should be accounted for in the Jacobian.

For this to return true, there must be at least one active nonlocal kernel or boundary condition

Implements SubProblem.

Definition at line 2921 of file FEProblemBase.h.

Referenced by DisplacedProblem::hasNonlocalCoupling().

2921 { return _has_nonlocal_coupling; }
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.

◆ hasPostprocessor()

bool FEProblemBase::hasPostprocessor ( const std::string &  name) const
inherited

Deprecated.

Use hasPostprocessorValueByName

Definition at line 4903 of file FEProblemBase.C.

Referenced by GenericFunctorTimeDerivativeMaterialTempl< is_ad >::GenericFunctorTimeDerivativeMaterialTempl().

4904 {
4905  mooseDeprecated("FEProblemBase::hasPostprocssor is being removed; use "
4906  "hasPostprocessorValueByName instead.");
4908 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
void mooseDeprecated(Args &&... args) const
bool hasPostprocessorValueByName(const PostprocessorName &name) const
Whether or not a Postprocessor value exists by a given name.

◆ hasPostprocessorValueByName()

bool FEProblemBase::hasPostprocessorValueByName ( const PostprocessorName &  name) const
inherited

Whether or not a Postprocessor value exists by a given name.

Parameters
nameThe name of the Postprocessor
Returns
True if a Postprocessor value exists

Note: You should prioritize the use of PostprocessorInterface::hasPostprocessor and PostprocessorInterface::hasPostprocessorByName over this method when possible.

Definition at line 4861 of file FEProblemBase.C.

Referenced by DiffusionCG::addFEBCs(), DiffusionCG::addFEKernels(), DiffusionFV::addFVKernels(), FunctorExtremaPositions::FunctorExtremaPositions(), FEProblemBase::hasPostprocessor(), MooseParsedFunction::initialSetup(), and FunctorIC::value().

4862 {
4864 }
ReporterData _reporter_data
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
Real PostprocessorValue
various MOOSE typedefs
Definition: MooseTypes.h:230
A ReporterName that represents a Postprocessor.
Definition: ReporterName.h:143
bool hasReporterValue(const ReporterName &reporter_name) const
Return True if a Reporter value with the given type and name have been created.
Definition: ReporterData.h:458

◆ hasScalarVariable()

bool FEProblemBase::hasScalarVariable ( const std::string &  var_name) const
overridevirtualinherited

Returns a Boolean indicating whether any system contains a variable with the name provided.

Implements SubProblem.

Definition at line 6304 of file FEProblemBase.C.

Referenced by FEProblemBase::addInitialCondition(), FEProblemBase::addObjectParamsHelper(), EigenProblem::adjustEigenVector(), FEProblemBase::checkDuplicatePostprocessorVariableNames(), AdvancedOutput::initAvailableLists(), MooseParsedFunctionWrapper::initialize(), ChainControlParsedFunctionWrapper::initializeFunctionInputs(), MooseParsedFunction::initialSetup(), AdvancedOutput::initShowHideLists(), and Split::setup().

6305 {
6306  for (auto & sys : _solver_systems)
6307  if (sys->hasScalarVariable(var_name))
6308  return true;
6309  if (_aux->hasScalarVariable(var_name))
6310  return true;
6311 
6312  return false;
6313 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ hasScalingVector()

void SubProblem::hasScalingVector ( const unsigned int  nl_sys_num)
inherited

Tells this problem that the assembly associated with the given nonlinear system number involves a scaling vector.

Definition at line 1171 of file SubProblem.C.

Referenced by SystemBase::addScalingVector().

1172 {
1173  for (const THREAD_ID tid : make_range(libMesh::n_threads()))
1174  assembly(tid, nl_sys_num).hasScalingVector();
1175 }
unsigned int n_threads()
void hasScalingVector()
signals this object that a vector containing variable scaling factors should be used when doing resid...
Definition: Assembly.C:4559
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int sys_num)=0
IntRange< T > make_range(T beg, T end)
unsigned int THREAD_ID
Definition: MooseTypes.h:237

◆ hasSetMultiAppFixedPointConvergenceName()

bool FEProblemBase::hasSetMultiAppFixedPointConvergenceName ( ) const
inlineinherited

Returns true if the problem has set the fixed point convergence name.

Definition at line 771 of file FEProblemBase.h.

772  {
773  return _multiapp_fixed_point_convergence_name.has_value();
774  }
std::optional< ConvergenceName > _multiapp_fixed_point_convergence_name
MultiApp fixed point convergence name.

◆ hasSetSteadyStateConvergenceName()

bool FEProblemBase::hasSetSteadyStateConvergenceName ( ) const
inlineinherited

Returns true if the problem has set the steady-state detection convergence name.

Definition at line 776 of file FEProblemBase.h.

777  {
778  return _steady_state_convergence_name.has_value();
779  }
std::optional< ConvergenceName > _steady_state_convergence_name
Steady-state detection convergence name.

◆ hasSolutionState()

bool FEProblemBase::hasSolutionState ( unsigned int  state,
Moose::SolutionIterationType  iteration_type 
) const
inherited

Whether we need up to old (1) or older (2) solution states for a given type of iteration.

Parameters
oldest_neededoldest solution state needed
iteration_typethe type of iteration for which old/older states are needed

Definition at line 764 of file FEProblemBase.C.

766 {
767  bool has_solution_state = false;
768  for (auto & sys : _solver_systems)
769  has_solution_state |= sys->hasSolutionState(state, iteration_type);
770  has_solution_state |= _aux->hasSolutionState(state, iteration_type);
771  return has_solution_state;
772 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ hasSolverVariable()

bool FEProblemBase::hasSolverVariable ( const std::string &  var_name) const
inherited

Definition at line 6236 of file FEProblemBase.C.

Referenced by FunctorChangeFunctorMaterialTempl< is_ad >::FunctorChangeFunctorMaterialTempl().

6237 {
6238  for (auto & sys : _solver_systems)
6239  if (sys->hasVariable(var_name))
6240  return true;
6241 
6242  return false;
6243 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.

◆ hasTimeIntegrator()

bool FEProblemBase::hasTimeIntegrator ( ) const
inlineinherited

Returns whether or not this Problem has a TimeIntegrator.

Definition at line 2419 of file FEProblemBase.h.

Referenced by TransientBase::setupTimeIntegrator().

2419 { return _has_time_integrator; }
bool _has_time_integrator
Indicates whether or not this executioner has a time integrator (during setup)

◆ hasUOAuxStateCheck()

bool FEProblemBase::hasUOAuxStateCheck ( ) const
inlineinherited

Whether or not MOOSE will perform a user object/auxiliary kernel state check.

Definition at line 220 of file FEProblemBase.h.

220 { return _uo_aux_state_check; }
const bool _uo_aux_state_check
Whether or not checking the state of uo/aux evaluation.

◆ hasUserObject()

bool FEProblemBase::hasUserObject ( const std::string &  name) const
inherited

Check if there if a user object of given name.

Parameters
nameThe name of the user object being checked for
Returns
true if the user object exists, false otherwise

Definition at line 4774 of file FEProblemBase.C.

Referenced by FEProblemBase::checkUserObjectNameCollision(), DistributedPositions::DistributedPositions(), MultiAppGeneralFieldFunctorTransfer::execute(), UserObjectInterface::getUserObjectFromFEProblem(), UserObjectInterface::hasUserObjectByName(), ReporterTransferInterface::hideVariableHelper(), ParsedDownSelectionPositions::initialize(), and TransformedPositions::TransformedPositions().

4775 {
4776  std::vector<UserObject *> objs;
4777  theWarehouse()
4778  .query()
4779  .condition<AttribSystem>("UserObject")
4780  .condition<AttribThread>(0)
4781  .condition<AttribName>(name)
4782  .queryInto(objs);
4783  return !objs.empty();
4784 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
TheWarehouse & theWarehouse() const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ hasVariable()

bool FEProblemBase::hasVariable ( const std::string &  var_name) const
overridevirtualinherited

Whether or not this problem has the variable.

Implements SubProblem.

Definition at line 6224 of file FEProblemBase.C.

Referenced by DiffusionCG::addFEBCs(), DiffusionCG::addFEKernels(), FEProblemBase::addFVInitialCondition(), DiffusionFV::addFVKernels(), FEProblemBase::addInitialCondition(), FEProblemBase::addObjectParamsHelper(), MultiAppTransfer::checkVariable(), FunctorIC::FunctorIC(), LazyCoupleable::init(), AdvancedOutput::initAvailableLists(), MooseParsedFunction::initialSetup(), AdvancedOutput::initShowHideLists(), BlockRestrictionDebugOutput::printBlockRestrictionGroups(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), and Split::setup().

6225 {
6226  for (auto & sys : _solver_systems)
6227  if (sys->hasVariable(var_name))
6228  return true;
6229  if (_aux->hasVariable(var_name))
6230  return true;
6231 
6232  return false;
6233 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ haveADObjects() [1/4]

bool SubProblem::haveADObjects ( ) const
inlineinherited

Method for reading wehther we have any ad objects.

Definition at line 779 of file SubProblem.h.

Referenced by FEProblemBase::computeJacobianTags(), FEProblemBase::computeResidualAndJacobian(), and FEProblemBase::init().

779 { return _have_ad_objects; }
bool _have_ad_objects
AD flag indicating whether any AD objects have been added.
Definition: SubProblem.h:1129

◆ haveADObjects() [2/4]

virtual void SubProblem::haveADObjects
inlineinherited

Method for setting whether we have any ad objects.

Definition at line 775 of file SubProblem.h.

775 { _have_ad_objects = have_ad_objects; }
bool _have_ad_objects
AD flag indicating whether any AD objects have been added.
Definition: SubProblem.h:1129

◆ haveADObjects() [3/4]

bool SubProblem::haveADObjects
inlineinherited

Method for reading wehther we have any ad objects.

Definition at line 779 of file SubProblem.h.

779 { return _have_ad_objects; }
bool _have_ad_objects
AD flag indicating whether any AD objects have been added.
Definition: SubProblem.h:1129

◆ haveADObjects() [4/4]

void FEProblemBase::haveADObjects ( bool  have_ad_objects)
overridevirtualinherited

Method for setting whether we have any ad objects.

Reimplemented from SubProblem.

Definition at line 9516 of file FEProblemBase.C.

9517 {
9518  _have_ad_objects = have_ad_objects;
9519  if (_displaced_problem)
9520  _displaced_problem->SubProblem::haveADObjects(have_ad_objects);
9521 }
bool _have_ad_objects
AD flag indicating whether any AD objects have been added.
Definition: SubProblem.h:1129
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ haveDisplaced()

bool FEProblemBase::haveDisplaced ( ) const
inlinefinaloverridevirtualinherited

Whether we have a displaced problem in our simulation.

Implements SubProblem.

Definition at line 2755 of file FEProblemBase.h.

2755 { return _displaced_problem.get(); }
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ haveFV()

virtual bool FEProblemBase::haveFV ( ) const
inlineoverridevirtualinherited

◆ havePRefinement()

bool SubProblem::havePRefinement ( ) const
inlineinherited

Query whether p-refinement has been requested at any point during the simulation.

Definition at line 1024 of file SubProblem.h.

Referenced by AdvancedOutput::initAvailableLists(), and FEProblemBase::meshChanged().

1024 { return _have_p_refinement; }
bool _have_p_refinement
Whether p-refinement has been requested at any point during the simulation.
Definition: SubProblem.h:1220

◆ haveXFEM()

bool FEProblemBase::haveXFEM ( )
inlineinherited

Find out whether the current analysis is using XFEM.

Definition at line 2146 of file FEProblemBase.h.

Referenced by FEProblemBase::initialSetup(), FixedPointSolve::solveStep(), TransientBase::takeStep(), and FEProblemBase::updateMeshXFEM().

2146 { return _xfem != nullptr; }
std::shared_ptr< XFEMInterface > _xfem
Pointer to XFEM controller.

◆ hRefine()

bool MFEMProblem::hRefine ( )
inline

If AMR is enabled, request (and perform if needed) h-refinement.

Definition at line 330 of file MFEMProblem.h.

Referenced by MFEMProblemSolve::solve().

330 { return _problem_data.refiner && _problem_data.refiner->hRefine(); }
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
std::shared_ptr< MFEMRefinementMarker > refiner

◆ identifyVariableGroupsInNL()

bool FEProblemBase::identifyVariableGroupsInNL ( ) const
inlineinherited

Whether to identify variable groups in nonlinear systems.

This affects dof ordering

Definition at line 2926 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::NonlinearSystemBase().

const bool _identify_variable_groups_in_nl
Whether to identify variable groups in nonlinear systems. This affects dof ordering.

◆ ignoreZerosInJacobian()

bool FEProblemBase::ignoreZerosInJacobian ( ) const
inlineinherited

Will return true if zeros in the Jacobian are to be dropped from the sparsity pattern.

Note that this can make preserving the matrix sparsity pattern impossible.

Definition at line 2391 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::computeJacobianInternal(), NonlinearSystemBase::computeResidualAndJacobianInternal(), and NonlinearSystemBase::constraintJacobians().

2391 { return _ignore_zeros_in_jacobian; }
bool _ignore_zeros_in_jacobian
Whether to ignore zeros in the Jacobian, thereby leading to a reduced sparsity pattern.

◆ immediatelyPrintInvalidSolution()

bool FEProblemBase::immediatelyPrintInvalidSolution ( ) const
inlineinherited

Whether or not the solution invalid warnings are printed out immediately.

Definition at line 2416 of file FEProblemBase.h.

Referenced by SolutionInvalidInterface::flagInvalidSolutionInternal().

const bool & _immediately_print_invalid_solution

◆ incrementMultiAppTStep()

void FEProblemBase::incrementMultiAppTStep ( ExecFlagType  type)
inherited

Advance the MultiApps t_step (incrementStepOrReject) associated with the ExecFlagType.

Definition at line 6041 of file FEProblemBase.C.

Referenced by TransientBase::incrementStepOrReject().

6042 {
6043  const auto & multi_apps = _multi_apps[type].getActiveObjects();
6044 
6045  if (multi_apps.size())
6046  for (const auto & multi_app : multi_apps)
6047  multi_app->incrementTStep(_time);
6048 }
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.

◆ init()

void FEProblemBase::init ( )
overridevirtualinherited

Implements Problem.

Reimplemented in FEProblem, and EigenProblem.

Definition at line 6728 of file FEProblemBase.C.

Referenced by EigenProblem::init(), and FEProblem::init().

6729 {
6730  if (_initialized)
6731  return;
6732 
6733  TIME_SECTION("init", 2, "Initializing");
6734 
6735  // call executioner's preProblemInit so that it can do some setups before problem init
6737 
6738  // If we have AD and we are doing global AD indexing, then we should by default set the matrix
6739  // coupling to full. If the user has told us to trust their coupling matrix, then this call will
6740  // not do anything
6743 
6744  for (const auto i : index_range(_nl))
6745  {
6746  auto & nl = _nl[i];
6747  auto & cm = _cm[i];
6748 
6749  unsigned int n_vars = nl->nVariables();
6750  {
6751  TIME_SECTION("fillCouplingMatrix", 3, "Filling Coupling Matrix");
6752 
6753  switch (_coupling)
6754  {
6755  case Moose::COUPLING_DIAG:
6756  cm = std::make_unique<CouplingMatrix>(n_vars);
6757  for (unsigned int i = 0; i < n_vars; i++)
6758  (*cm)(i, i) = 1;
6759  break;
6760 
6761  // for full jacobian
6762  case Moose::COUPLING_FULL:
6763  cm = std::make_unique<CouplingMatrix>(n_vars);
6764  for (unsigned int i = 0; i < n_vars; i++)
6765  for (unsigned int j = 0; j < n_vars; j++)
6766  (*cm)(i, j) = 1;
6767  break;
6768 
6770  // do nothing, _cm was already set through couplingMatrix() call
6771  break;
6772  }
6773  }
6774 
6775  nl->dofMap()._dof_coupling = cm.get();
6776 
6777  // If there are no variables, make sure to pass a nullptr coupling
6778  // matrix, to avoid warnings about non-nullptr yet empty
6779  // CouplingMatrices.
6780  if (n_vars == 0)
6781  nl->dofMap()._dof_coupling = nullptr;
6782 
6783  nl->dofMap().attach_extra_sparsity_function(&extraSparsity, nl.get());
6784  nl->dofMap().attach_extra_send_list_function(&extraSendList, nl.get());
6785  _aux->dofMap().attach_extra_send_list_function(&extraSendList, _aux.get());
6786 
6787  if (!_skip_nl_system_check && _solve && n_vars == 0)
6788  mooseError("No variables specified in nonlinear system '", nl->name(), "'.");
6789  }
6790 
6791  ghostGhostedBoundaries(); // We do this again right here in case new boundaries have been added
6792 
6793  // We may have added element/nodes to the mesh in ghostGhostedBoundaries so we need to update
6794  // all of our mesh information. We need to make sure that mesh information is up-to-date before
6795  // EquationSystems::init because that will call through to updateGeomSearch (for sparsity
6796  // augmentation) and if we haven't added back boundary node information before that latter call,
6797  // then we're screwed. We'll get things like "Unable to find closest node!"
6798  _mesh.meshChanged();
6799  if (_displaced_problem)
6801 
6802  if (_mesh.doingPRefinement())
6803  {
6805  if (_displaced_problem)
6806  _displaced_problem->preparePRefinement();
6807  }
6808 
6809  // do not assemble system matrix for JFNK solve
6810  for (auto & nl : _nl)
6811  if (solverParams(nl->number())._type == Moose::ST_JFNK)
6812  nl->turnOffJacobian();
6813 
6814  for (auto & sys : _solver_systems)
6815  sys->preInit();
6816  _aux->preInit();
6817 
6818  // Build the mortar segment meshes, if they haven't been already, for a couple reasons:
6819  // 1) Get the ghosting correct for both static and dynamic meshes
6820  // 2) Make sure the mortar mesh is built for mortar constraints that live on the static mesh
6821  //
6822  // It is worth-while to note that mortar meshes that live on a dynamic mesh will be built
6823  // during residual and Jacobian evaluation because when displacements are solution variables
6824  // the mortar mesh will move and change during the course of a non-linear solve. We DO NOT
6825  // redo ghosting during non-linear solve, so for purpose 1) the below call has to be made
6826  if (!_mortar_data->initialized())
6827  updateMortarMesh();
6828 
6829  {
6830  TIME_SECTION("EquationSystems::Init", 2, "Initializing Equation Systems");
6831  es().init();
6832  }
6833 
6834  for (auto & sys : _solver_systems)
6835  sys->postInit();
6836  _aux->postInit();
6837 
6838  // Now that the equation system and the dof distribution is done, we can generate the
6839  // finite volume-related parts if needed.
6840  if (haveFV())
6842 
6843  for (auto & sys : _solver_systems)
6844  sys->update();
6845  _aux->update();
6846 
6847  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); ++tid)
6848  for (const auto i : index_range(_nl))
6849  {
6850  mooseAssert(
6851  _cm[i],
6852  "Coupling matrix not set for system "
6853  << i
6854  << ". This should only happen if a preconditioner was not setup for this system");
6855  _assembly[tid][i]->init(_cm[i].get());
6856  }
6857 
6858  if (_displaced_problem)
6859  _displaced_problem->init();
6860 
6861 #ifdef MOOSE_KOKKOS_ENABLED
6862  if (_has_kokkos_objects)
6863  initKokkos();
6864 #endif
6865 
6866  _initialized = true;
6867 }
void extraSparsity(libMesh::SparsityPattern::Graph &sparsity, std::vector< dof_id_type > &n_nz, std::vector< dof_id_type > &n_oz, void *context)
Free function used for a libMesh callback.
Definition: SystemBase.C:48
unsigned int n_threads()
virtual bool haveFV() const override
returns true if this problem includes/needs finite volume functionality.
void setCoupling(Moose::CouplingType type)
Set the coupling between variables TODO: allow user-defined coupling.
bool _has_kokkos_objects
Whether we have any Kokkos objects.
bool globalADIndexing()
Whether we are using global AD indexing.
Definition: ADUtils.h:28
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
void preparePRefinement()
Prepare DofMap and Assembly classes with our p-refinement information.
Definition: SubProblem.C:1337
const bool _skip_nl_system_check
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const bool & _solve
Whether or not to actually solve the nonlinear system.
unsigned int n_vars
Moose::CouplingType _coupling
Type of variable coupling.
void extraSendList(std::vector< dof_id_type > &send_list, void *context)
///< Type of coordinate system
Definition: SystemBase.C:40
Jacobian-Free Newton Krylov.
Definition: MooseTypes.h:894
virtual libMesh::EquationSystems & es() override
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseMesh & _mesh
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
bool haveADObjects() const
Method for reading wehther we have any ad objects.
Definition: SubProblem.h:779
Executioner * getExecutioner() const
Retrieve the Executioner for this App.
Definition: MooseApp.C:2015
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
virtual void updateMortarMesh()
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data
virtual void preProblemInit()
Perform initializations during executing actions right before init_problem task.
Definition: Executioner.h:57
void initKokkos()
Construct Kokkos assembly and systems and allocate Kokkos material property storages.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
SolverParams & solverParams(unsigned int solver_sys_num=0)
Get the solver parameters.
std::shared_ptr< DisplacedProblem > _displaced_problem
std::vector< std::unique_ptr< libMesh::CouplingMatrix > > _cm
Coupling matrix for variables.
void doingPRefinement(bool doing_p_refinement)
Indicate whether the kind of adaptivity we&#39;re doing includes p-refinement.
Definition: MooseMesh.h:1504
auto index_range(const T &sizable)
const std::string & _type
The type of this class.
Definition: MooseBase.h:378
MooseMesh * _displaced_mesh
void meshChanged()
Declares that the MooseMesh has changed, invalidates cached data and rebuilds caches.
Definition: MooseMesh.C:887
unsigned int THREAD_ID
Definition: MooseTypes.h:237
virtual void ghostGhostedBoundaries() override
Causes the boundaries added using addGhostedBoundary to actually be ghosted.
void setupFiniteVolumeMeshData() const
Sets up the additional data needed for finite volume computations.
Definition: MooseMesh.C:4192

◆ initElementStatefulProps()

void FEProblemBase::initElementStatefulProps ( const libMesh::ConstElemRange elem_range,
const bool  threaded 
)
inherited

Initialize stateful properties for elements in a specific elem_range This is needed when elements/boundary nodes are added to a specific subdomain at an intermediate step.

Definition at line 8860 of file FEProblemBase.C.

Referenced by ActivateElementsUserObjectBase::finalize(), ElementSubdomainModifierBase::initElementStatefulProps(), and FEProblemBase::initialSetup().

8861 {
8864  if (threaded)
8865  Threads::parallel_reduce(elem_range, cmt);
8866  else
8867  cmt(elem_range, true);
8868 
8869 #ifdef MOOSE_KOKKOS_ENABLED
8870  if (_has_kokkos_objects)
8872 #endif
8873 }
MaterialPropertyStorage & _bnd_material_props
bool _has_kokkos_objects
Whether we have any Kokkos objects.
void parallel_reduce(const Range &range, Body &body, const Partitioner &, unsigned int n_threads=libMesh::n_threads())
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
MaterialPropertyStorage & _neighbor_material_props
MaterialPropertyStorage & _material_props
void initKokkosStatefulProps()

◆ initialAdaptMesh()

void FEProblemBase::initialAdaptMesh ( )
virtualinherited

Definition at line 8528 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup().

8529 {
8530  unsigned int n = adaptivity().getInitialSteps();
8531  _cycles_completed = 0;
8532  if (n)
8533  {
8534  if (!_mesh.interiorLowerDBlocks().empty() || !_mesh.boundaryLowerDBlocks().empty())
8535  mooseError("HFEM does not support mesh adaptivity currently.");
8536 
8537  TIME_SECTION("initialAdaptMesh", 2, "Performing Initial Adaptivity");
8538 
8539  for (unsigned int i = 0; i < n; i++)
8540  {
8542  computeMarkers();
8543 
8545  {
8546  meshChanged(
8547  /*intermediate_change=*/false, /*contract_mesh=*/true, /*clean_refinement_flags=*/true);
8548 
8549  // reproject the initial condition
8550  projectSolution();
8551 
8553  }
8554  else
8555  {
8556  _console << "Mesh unchanged, skipping remaining steps..." << std::endl;
8557  return;
8558  }
8559  }
8560  }
8561 }
bool initialAdaptMesh()
Used during initial adaptivity.
Definition: Adaptivity.C:295
virtual void meshChanged()
Deprecated.
const std::set< SubdomainID > & interiorLowerDBlocks() const
Definition: MooseMesh.h:1552
unsigned int _cycles_completed
virtual void computeMarkers()
void projectSolution()
virtual void computeIndicators()
MooseMesh & _mesh
Adaptivity _adaptivity
const std::set< SubdomainID > & boundaryLowerDBlocks() const
Definition: MooseMesh.h:1556
unsigned int getInitialSteps() const
Pull out the number of initial steps previously set by calling init()
Definition: Adaptivity.h:112
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
Adaptivity & adaptivity()

◆ initialized()

bool FEProblemBase::initialized ( ) const
inlineinherited
Returns
Whether the problem was initialized, i.e. whether init() has executed

Definition at line 168 of file FEProblemBase.h.

Referenced by MooseMesh::update().

168 { return _initialized; }

◆ initialSetup()

void MFEMProblem::initialSetup ( )
overridevirtual

Reimplemented from SubProblem.

Definition at line 88 of file MFEMProblem.C.

Referenced by MFEMSteady::init().

89 {
91 
92  std::vector<MFEMExecutedObject *> objects;
93  theWarehouse()
94  .query()
95  .condition<AttribSystem>("MFEMExecutedObject")
96  .condition<AttribThread>(0)
97  .queryInto(objects);
98  for (auto * const object : objects)
99  object->initialSetup();
100 
101  // MFEM indicators create their estimators during addIndicator(); markers still need an explicit
102  // setup pass because they are no longer initialized through the libMesh/MOOSE user-object path.
103  std::vector<MFEMRefinementMarker *> markers;
104  theWarehouse().query().condition<AttribSystem>("Marker").queryInto(markers);
105  for (auto marker : markers)
106  marker->initialSetup();
107 }
TheWarehouse & theWarehouse() const
void initialSetup() override
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ initKokkos()

void FEProblemBase::initKokkos ( )
inherited

Construct Kokkos assembly and systems and allocate Kokkos material property storages.

Referenced by FEProblemBase::init().

◆ initKokkosStatefulProps()

void FEProblemBase::initKokkosStatefulProps ( )
inherited

◆ initNullSpaceVectors()

void FEProblemBase::initNullSpaceVectors ( const InputParameters parameters,
std::vector< std::shared_ptr< NonlinearSystemBase >> &  nl 
)
virtualinherited

Definition at line 789 of file FEProblemBase.C.

Referenced by EigenProblem::EigenProblem(), and FEProblem::FEProblem().

791 {
792  TIME_SECTION("initNullSpaceVectors", 5, "Initializing Null Space Vectors");
793 
794  unsigned int dimNullSpace = parameters.get<unsigned int>("null_space_dimension");
795  unsigned int dimTransposeNullSpace =
796  parameters.get<unsigned int>("transpose_null_space_dimension");
797  unsigned int dimNearNullSpace = parameters.get<unsigned int>("near_null_space_dimension");
798  for (unsigned int i = 0; i < dimNullSpace; ++i)
799  {
800  std::ostringstream oss;
801  oss << "_" << i;
802  // do not project, since this will be recomputed, but make it ghosted, since the near nullspace
803  // builder might march over all nodes
804  for (auto & nl : nls)
805  nl->addVector("NullSpace" + oss.str(), false, libMesh::GHOSTED);
806  }
807  _subspace_dim["NullSpace"] = dimNullSpace;
808  for (unsigned int i = 0; i < dimTransposeNullSpace; ++i)
809  {
810  std::ostringstream oss;
811  oss << "_" << i;
812  // do not project, since this will be recomputed, but make it ghosted, since the near nullspace
813  // builder might march over all nodes
814  for (auto & nl : nls)
815  nl->addVector("TransposeNullSpace" + oss.str(), false, libMesh::GHOSTED);
816  }
817  _subspace_dim["TransposeNullSpace"] = dimTransposeNullSpace;
818  for (unsigned int i = 0; i < dimNearNullSpace; ++i)
819  {
820  std::ostringstream oss;
821  oss << "_" << i;
822  // do not project, since this will be recomputed, but make it ghosted, since the near-nullspace
823  // builder might march over all semilocal nodes
824  for (auto & nl : nls)
825  nl->addVector("NearNullSpace" + oss.str(), false, libMesh::GHOSTED);
826  }
827  _subspace_dim["NearNullSpace"] = dimNearNullSpace;
828 }
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
std::map< std::string, unsigned int > _subspace_dim
Dimension of the subspace spanned by the vectors with a given prefix.

◆ initPetscOutputAndSomeSolverSettings()

void FEProblemBase::initPetscOutputAndSomeSolverSettings ( )
virtualinherited

Reinitialize PETSc output for proper linear/nonlinear iteration display.

This also may be used for some PETSc-related solver settings

Reimplemented in EigenProblem.

Definition at line 7295 of file FEProblemBase.C.

Referenced by FEProblemBase::possiblyRebuildGeomSearchPatches(), LStableDirk2::solve(), LStableDirk3::solve(), ImplicitMidpoint::solve(), ExplicitTVDRK2::solve(), LStableDirk4::solve(), AStableDirk4::solve(), ExplicitRK2::solve(), and FEProblemBase::solve().

7296 {
7299 }
void petscSetDefaults(FEProblemBase &problem)
Sets the default options for PETSc.
Definition: PetscSupport.C:598
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
void solveSetup()
Calls the timestepSetup function for each of the output objects.
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409

◆ initXFEM()

void FEProblemBase::initXFEM ( std::shared_ptr< XFEMInterface xfem)
inherited

Create XFEM controller object.

Definition at line 8626 of file FEProblemBase.C.

8627 {
8628  _xfem = xfem;
8629  _xfem->setMesh(&_mesh);
8630  if (_displaced_mesh)
8631  _xfem->setDisplacedMesh(_displaced_mesh);
8632 
8633  auto fill_data = [](auto & storage)
8634  {
8635  std::vector<MaterialData *> data(libMesh::n_threads());
8636  for (const auto tid : make_range(libMesh::n_threads()))
8637  data[tid] = &storage.getMaterialData(tid);
8638  return data;
8639  };
8640  _xfem->setMaterialData(fill_data(_material_props));
8641  _xfem->setBoundaryMaterialData(fill_data(_bnd_material_props));
8642 
8643  unsigned int n_threads = libMesh::n_threads();
8644  for (unsigned int i = 0; i < n_threads; ++i)
8645  for (const auto nl_sys_num : index_range(_nl))
8646  {
8647  _assembly[i][nl_sys_num]->setXFEM(_xfem);
8648  if (_displaced_problem)
8649  _displaced_problem->assembly(i, nl_sys_num).setXFEM(_xfem);
8650  }
8651 }
void fill_data(std::map< processor_id_type, std::vector< std::set< unsigned int >>> &data, int M)
MaterialPropertyStorage & _bnd_material_props
unsigned int n_threads()
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
MooseMesh & _mesh
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
IntRange< T > make_range(T beg, T end)
std::shared_ptr< DisplacedProblem > _displaced_problem
std::shared_ptr< XFEMInterface > _xfem
Pointer to XFEM controller.
MaterialPropertyStorage & _material_props
auto index_range(const T &sizable)
MooseMesh * _displaced_mesh

◆ isKokkosObject()

bool MooseObject::isKokkosObject ( ) const
inlineinherited

Get whether this object is a Kokkos functor The parameter MooseBase::kokkos_object_param is set by the Kokkos base classes.

Definition at line 63 of file MooseObject.h.

Referenced by AttribKokkos::initFrom(), BlockRestrictable::initializeBlockRestrictable(), and BoundaryRestrictable::initializeBoundaryRestrictable().

63 { return parameters().isKokkosObject(); }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
bool isKokkosObject() const
Returns whether this InputParameters belongs to a Kokkos object Checks whether MooseBase::kokkos_obje...

◆ isMatPropRequested()

bool SubProblem::isMatPropRequested ( const std::string &  prop_name) const
virtualinherited

Find out if a material property has been requested by any object.

Definition at line 731 of file SubProblem.C.

732 {
733  return _material_property_requested.find(prop_name) != _material_property_requested.end();
734 }
std::set< std::string > _material_property_requested
set containing all material property names that have been requested by getMaterialProperty* ...
Definition: SubProblem.h:1077

◆ isParamSetByUser()

bool MooseBase::isParamSetByUser ( const std::string &  name) const
inlineinherited

Test if the supplied parameter is set by a user, as opposed to not set or set to default.

Parameters
nameThe name of the parameter to test

Definition at line 205 of file MooseBase.h.

Referenced by SetupDebugAction::act(), DiffusionCG::addFEBCs(), DiffusionPhysicsBase::addInitialConditions(), CylinderComponent::addMeshGenerators(), AdvancedExtruderGenerator::AdvancedExtruderGenerator(), MFEMMesh::buildMesh(), MFEMDomainSubMesh::buildSubMesh(), MFEMBoundarySubMesh::buildSubMesh(), LibtorchNeuralNetControl::conditionalParameterError(), ConservativeAdvectionBCTempl< false >::ConservativeAdvectionBCTempl(), MooseApp::copyInputs(), DiffusionPhysicsBase::DiffusionPhysicsBase(), MooseApp::errorCheck(), FileMesh::FileMesh(), FullSolveMultiApp::FullSolveMultiApp(), OrientSurfaceMeshGenerator::generate(), SurfaceSubdomainsFromAllNormalsGenerator::generate(), MFEMVectorFESpace::getFECName(), MooseBase::getRenamedParam(), DefaultConvergenceBase::getSharedExecutionerParam(), MFEMMesh::init(), AddVariableAction::init(), PhysicsBase::initializePhysics(), ElementSubdomainModifierBase::initialSetup(), MatrixSymmetryCheck::MatrixSymmetryCheck(), MeshDiagnosticsGenerator::MeshDiagnosticsGenerator(), MFEMVariable::MFEMVariable(), MortarConstraintBase::MortarConstraintBase(), MultiAppGeneralFieldFunctorTransfer::MultiAppGeneralFieldFunctorTransfer(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), OrientSurfaceMeshGenerator::OrientSurfaceMeshGenerator(), SolutionInvalidityOutput::output(), Output::Output(), MultiAppGeneralFieldTransfer::outputValueConflicts(), PetscExternalPartitioner::partition(), PolyLineMeshFollowingNodeSetGenerator::PolyLineMeshFollowingNodeSetGenerator(), MooseMesh::prepare(), SolutionUserObjectBase::readXda(), ReferenceResidualConvergence::ReferenceResidualConvergence(), PhysicsBase::reportPotentiallyMissedParameters(), MooseApp::run(), MooseApp::runInputFile(), MooseApp::runInputs(), Moose::MFEM::LinearSolverBase::SetPreconditioner(), SetupMeshAction::setupMesh(), MooseApp::setupOptions(), SideSetsFromBoundingBoxGenerator::SideSetsFromBoundingBoxGenerator(), SmoothMeshGenerator::SmoothMeshGenerator(), SurfaceSubdomainsDelaunayRemesher::SurfaceSubdomainsDelaunayRemesher(), SurfaceSubdomainsFromAllNormalsGenerator::SurfaceSubdomainsFromAllNormalsGenerator(), TagVectorAux::TagVectorAux(), TimedSubdomainModifier::TimedSubdomainModifier(), TimeIntegratedPostprocessor::TimeIntegratedPostprocessor(), XYDelaunayGenerator::XYDelaunayGenerator(), and XYZDelaunayGenerator::XYZDelaunayGenerator().

206  {
207  return _pars.isParamSetByUser(name);
208  }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool isParamSetByUser(const std::string &name) const
Method returns true if the parameter was set by the user.

◆ isParamValid()

bool MooseBase::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 199 of file MooseBase.h.

Referenced by HierarchicalGridPartitioner::_do_partition(), GridPartitioner::_do_partition(), CopyNodalVarsAction::act(), AutoCheckpointAction::act(), SetupMeshAction::act(), SetupDebugAction::act(), ComposeTimeStepperAction::act(), AddVariableAction::act(), SetAdaptivityOptionsAction::act(), CreateDisplacedProblemAction::act(), CommonOutputAction::act(), DiffusionCG::addFEKernels(), DiffusionFV::addFVBCs(), DiffusionFV::addFVKernels(), DiffusionPhysicsBase::addInitialConditions(), ComponentJunction::addMeshGenerators(), CylinderComponent::addMeshGenerators(), DiffusionPhysicsBase::addPostprocessors(), AdvancedExtruderGenerator::AdvancedExtruderGenerator(), AdvectiveFluxAux::AdvectiveFluxAux(), ArrayHFEMDirichletBC::ArrayHFEMDirichletBC(), ArrayVarReductionAux::ArrayVarReductionAux(), BicubicSplineFunction::BicubicSplineFunction(), BlockDeletionGenerator::BlockDeletionGenerator(), BSplineCurveGenerator::BSplineCurveGenerator(), TimedSubdomainModifier::buildFromFile(), ParsedChainControl::buildFunction(), GeneratedMesh::buildMesh(), MooseMesh::buildTypedMesh(), CartesianGridDivision::CartesianGridDivision(), CartesianMeshGenerator::CartesianMeshGenerator(), MultiAppTransfer::checkParentAppUserObjectExecuteOn(), LibmeshPartitioner::clone(), SampledOutput::cloneMesh(), CombinedVectorPostprocessor::CombinedVectorPostprocessor(), CombinerGenerator::CombinerGenerator(), ComponentJunction::ComponentJunction(), ConservativeAdvectionBCTempl< false >::ConservativeAdvectionBCTempl(), ConservativeAdvectionTempl< is_ad >::ConservativeAdvectionTempl(), FEProblemSolve::convergenceSetup(), CopyMeshPartitioner::CopyMeshPartitioner(), CSVReaderVectorPostprocessor::CSVReaderVectorPostprocessor(), CutMeshByLevelSetGeneratorBase::CutMeshByLevelSetGeneratorBase(), ConstantReporter::declareConstantReporterValue(), ConstantReporter::declareConstantReporterValues(), DGKernelBase::DGKernelBase(), DiffusionFluxAux::DiffusionFluxAux(), DomainUserObject::DomainUserObject(), DynamicObjectRegistrationAction::DynamicObjectRegistrationAction(), EigenProblemSolve::EigenProblemSolve(), ElementGenerator::ElementGenerator(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), BSplineCurveGenerator::endDirection(), BSplineCurveGenerator::endPoint(), PIDTransientControl::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppUserObjectTransfer::execute(), Exodus::Exodus(), ExtraIDIntegralReporter::ExtraIDIntegralReporter(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemBase::FEProblemBase(), FEProblemSolve::FEProblemSolve(), FileOutput::FileOutput(), SpatialUserObjectVectorPostprocessor::fillPoints(), CombinerGenerator::fillPositions(), MultiApp::fillPositions(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), FixedPointSolve::FixedPointSolve(), FunctionDT::FunctionDT(), FunctionValuePostprocessor::FunctionValuePostprocessor(), FVInterfaceKernel::FVInterfaceKernel(), FVMassMatrix::FVMassMatrix(), SurfaceSubdomainsDelaunayRemesher::General2DDelaunay(), AddMetaDataGenerator::generate(), BreakBoundaryOnSubdomainGenerator::generate(), ElementGenerator::generate(), FileMeshGenerator::generate(), LowerDBlockFromSidesetGenerator::generate(), ExtraNodesetGenerator::generate(), OrientSurfaceMeshGenerator::generate(), RenumberBySubdomainGenerator::generate(), SphereMeshGenerator::generate(), SubdomainPerElementGenerator::generate(), BlockDeletionGenerator::generate(), BSplineCurveGenerator::generate(), ConcentricCircleMeshGenerator::generate(), GeneratedMeshGenerator::generate(), ParsedSubdomainGeneratorBase::generate(), SideSetsFromNodeSetsGenerator::generate(), MeshExtruderGenerator::generate(), ParsedExtraElementIDGenerator::generate(), XYZDelaunayGenerator::generate(), XYDelaunayGenerator::generate(), XYMeshLineCutter::generate(), ManifoldSubdomainGenerator::generate(), SubdomainBoundingBoxGenerator::generate(), DistributedRectilinearMeshGenerator::generate(), PropertyReadFile::getFileNames(), MultiAppNearestNodeTransfer::getLocalEntitiesAndComponents(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), MooseBase::getRenamedParam(), MultiAppNearestNodeTransfer::getTargetLocalNodes(), AddPeriodicBCAction::getVariables(), Terminator::handleMessage(), HFEMDirichletBC::HFEMDirichletBC(), EigenExecutionerBase::init(), IterationAdaptiveDT::init(), AdvancedOutput::initAvailableLists(), AdvancedOutput::initExecutionTypes(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), MultiAppCloneReporterTransfer::initialSetup(), SolutionIC::initialSetup(), MultiAppVariableValueSampleTransfer::initialSetup(), SolutionScalarAux::initialSetup(), EigenProblemSolve::initialSetup(), ParsedConvergence::initialSetup(), PiecewiseTabularBase::initialSetup(), SolutionAux::initialSetup(), PIDTransientControl::initialSetup(), Console::initialSetup(), MooseParsedVectorFunction::initialSetup(), MultiAppGeneralFieldTransfer::initialSetup(), MooseParsedGradFunction::initialSetup(), MooseParsedFunction::initialSetup(), SampledOutput::initSample(), IterationAdaptiveDT::IterationAdaptiveDT(), LeastSquaresFit::LeastSquaresFit(), LibmeshPartitioner::LibmeshPartitioner(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), PNGOutput::makePNG(), MassMatrix::MassMatrix(), MatCoupledForce::MatCoupledForce(), MeshGeneratorComponent::MeshGeneratorComponent(), MFEMProblemSolve::MFEMProblemSolve(), MooseMesh::MooseMesh(), MoosePreconditioner::MoosePreconditioner(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MooseVariableFV< Real >::MooseVariableFV(), MortarConstraintBase::MortarConstraintBase(), MoveNodeGenerator::MoveNodeGenerator(), MultiApp::MultiApp(), MultiAppCloneReporterTransfer::MultiAppCloneReporterTransfer(), MultiAppGeneralFieldKDTreeTransferBase::MultiAppGeneralFieldKDTreeTransferBase(), MultiAppGeneralFieldShapeEvaluationTransfer::MultiAppGeneralFieldShapeEvaluationTransfer(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppGeneralFieldUserObjectTransfer::MultiAppGeneralFieldUserObjectTransfer(), MultiAppPostprocessorInterpolationTransfer::MultiAppPostprocessorInterpolationTransfer(), MultiAppPostprocessorTransfer::MultiAppPostprocessorTransfer(), MultiAppReporterTransfer::MultiAppReporterTransfer(), MultiAppTransfer::MultiAppTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), MultiAppVariableValueSampleTransfer::MultiAppVariableValueSampleTransfer(), MultiPostprocessorConvergence::MultiPostprocessorConvergence(), MultiSystemSolveObject::MultiSystemSolveObject(), NodeSetsGeneratorBase::NodeSetsGeneratorBase(), EigenExecutionerBase::normalizeSolution(), OrientSurfaceMeshGenerator::OrientSurfaceMeshGenerator(), Output::Output(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedSubdomainGeneratorBase::ParsedSubdomainGeneratorBase(), PetscOutput::PetscOutput(), PhysicsBasedPreconditioner::PhysicsBasedPreconditioner(), EqualValueBoundaryConstraint::pickPrimaryNode(), PIDTransientControl::PIDTransientControl(), PiecewiseTabularBase::PiecewiseTabularBase(), PlaneIDMeshGenerator::PlaneIDMeshGenerator(), EqualValueBoundaryConstraint::populateSecondaryNodes(), MooseMesh::prepare(), MultiApp::readCommandLineArguments(), SolutionUserObjectBase::readExodusIIOrNemesis(), ReferenceResidualInterface::ReferenceResidualInterface(), RenameBlockGenerator::RenameBlockGenerator(), ReporterPointSource::ReporterPointSource(), PhysicsBase::reportPotentiallyMissedParameters(), ParsedSubdomainMeshGenerator::setBlockName(), MooseMesh::setCoordSystem(), FileOutput::setFileBase(), FileOutput::setFileBaseInternal(), SurfaceMeshGeneratorBase::setup(), Split::setup(), SideSetsGeneratorBase::setup(), SetupMeshAction::setupMesh(), MooseApp::setupOptions(), Output::setWallTimeIntervalFromCommandLineParam(), SideDiffusiveFluxIntegralTempl< is_ad, Real >::SideDiffusiveFluxIntegralTempl(), SideSetsGeneratorBase::SideSetsGeneratorBase(), SolutionUserObjectBase::SolutionUserObjectBase(), BSplineCurveGenerator::startDirection(), BSplineCurveGenerator::startPoint(), Terminator::Terminator(), TimeIntervalTimes::TimeIntervalTimes(), TimePeriod::TimePeriod(), PIDTransientControl::timestepSetup(), MultiAppDofCopyTransfer::transfer(), TransformGenerator::TransformGenerator(), TransientBase::TransientBase(), FunctorIC::value(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl(), XYDelaunayGenerator::XYDelaunayGenerator(), and XYZDelaunayGenerator::XYZDelaunayGenerator().

199 { return _pars.isParamValid(name); }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.

◆ isSNESMFReuseBaseSetbyUser()

bool FEProblemBase::isSNESMFReuseBaseSetbyUser ( )
inlineinherited

Return a flag to indicate if _snesmf_reuse_base is set by users.

Definition at line 2585 of file FEProblemBase.h.

bool _snesmf_reuse_base_set_by_user
If or not _snesmf_reuse_base is set by user.

◆ isSolverSystemNonlinear()

bool FEProblemBase::isSolverSystemNonlinear ( const unsigned int  sys_num)
inlineinherited

◆ isSolveTerminationRequested()

virtual bool Problem::isSolveTerminationRequested ( ) const
inlinevirtualinherited

Check of termination has been requested.

This should be called by transient Executioners in the keepGoing() member.

Definition at line 43 of file Problem.h.

Referenced by WebServerControl::execute(), and TransientBase::keepGoing().

43 { return _termination_requested; };
bool _termination_requested
True if termination of the solve has been requested.
Definition: Problem.h:58

◆ isTransient()

virtual bool FEProblemBase::isTransient ( ) const
inlineoverridevirtualinherited

◆ jacobianSetup()

void FEProblemBase::jacobianSetup ( )
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 9834 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::jacobianSetup().

9835 {
9837  // We need to setup all the nonlinear systems other than our current one which actually called
9838  // this method (so we have to make sure we don't go in a circle)
9839  for (const auto i : make_range(numNonlinearSystems()))
9840  if (i != currentNlSysNum())
9841  _nl[i]->jacobianSetup();
9842  // We don't setup the aux sys because that's been done elsewhere
9843  if (_displaced_problem)
9844  _displaced_problem->jacobianSetup();
9845 }
virtual std::size_t numNonlinearSystems() const override
virtual void jacobianSetup()
Definition: SubProblem.C:1212
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
virtual unsigned int currentNlSysNum() const override
IntRange< T > make_range(T beg, T end)
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ kokkosAssembly() [1/2]

Moose::Kokkos::Assembly& FEProblemBase::kokkosAssembly ( )
inlineinherited

Definition at line 362 of file FEProblemBase.h.

362 { return _kokkos_assembly; }
Moose::Kokkos::Assembly _kokkos_assembly

◆ kokkosAssembly() [2/2]

const Moose::Kokkos::Assembly& FEProblemBase::kokkosAssembly ( ) const
inlineinherited

Definition at line 363 of file FEProblemBase.h.

363 { return _kokkos_assembly; }
Moose::Kokkos::Assembly _kokkos_assembly

◆ linearSysNum()

unsigned int FEProblemBase::linearSysNum ( const LinearSystemName &  linear_sys_name) const
overridevirtualinherited
Returns
the linear system number corresponding to the provided linear_sys_name

Implements SubProblem.

Definition at line 6881 of file FEProblemBase.C.

Referenced by Moose::compute_linear_system(), FEProblemBase::computeLinearSystemSys(), LinearSystem::computeLinearSystemTags(), and DisplacedProblem::linearSysNum().

6882 {
6883  std::istringstream ss(linear_sys_name);
6884  unsigned int linear_sys_num;
6885  if (!(ss >> linear_sys_num) || !ss.eof())
6886  linear_sys_num = libmesh_map_find(_linear_sys_name_to_num, linear_sys_name);
6887 
6888  return linear_sys_num;
6889 }
std::map< LinearSystemName, unsigned int > _linear_sys_name_to_num
Map from linear system name to number.

◆ lineSearch()

void FEProblemBase::lineSearch ( )
virtualinherited

execute MOOSE line search

Definition at line 2813 of file FEProblemBase.C.

Referenced by ComputeLineSearchObjectWrapper::linesearch().

2814 {
2815  _line_search->lineSearch();
2816 }
std::shared_ptr< LineSearch > _line_search

◆ logAdd()

void FEProblemBase::logAdd ( const std::string &  system,
const std::string &  name,
const std::string &  type,
const InputParameters params 
) const
inherited

Output information about the object just added to the problem.

Definition at line 4527 of file FEProblemBase.C.

Referenced by FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxScalarKernel(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), FEProblemBase::addConstraint(), FEProblemBase::addDamper(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addFunction(), FEProblemBase::addFunctorMaterial(), FEProblemBase::addFVInterpolationMethod(), FEProblemBase::addIndicator(), FEProblemBase::addInitialCondition(), FEProblemBase::addInterfaceKernel(), FEProblemBase::addMarker(), FEProblemBase::addMaterialHelper(), FEProblemBase::addMultiApp(), FEProblemBase::addNodalKernel(), FEProblemBase::addObject(), FEProblemBase::addOutput(), FEProblemBase::addPredictor(), FEProblemBase::addScalarKernel(), FEProblemBase::addTimeIntegrator(), FEProblemBase::addTransfer(), FEProblemBase::addUserObject(), FEProblemBase::addVariable(), FEProblemBase::setAuxKernelParamsAndLog(), and FEProblemBase::setResidualObjectParamsAndLog().

4531 {
4532  if (_verbose_setup != "false")
4533  _console << "[DBG] Adding " << system << " '" << name << "' of type " << type << std::endl;
4534  if (_verbose_setup == "extra")
4535  _console << params << std::endl;
4536 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
MooseEnum _verbose_setup
Whether or not to be verbose during setup.

◆ markFamilyPRefinement()

void SubProblem::markFamilyPRefinement ( const InputParameters params)
inherited

Mark a variable family for either disabling or enabling p-refinement with valid parameters of a variable.

Definition at line 1372 of file SubProblem.C.

Referenced by FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxVariable(), and FEProblemBase::addVariable().

1373 {
1374  auto family = Utility::string_to_enum<FEFamily>(params.get<MooseEnum>("family"));
1375  bool flag = _default_families_without_p_refinement.count(family);
1376  if (params.isParamValid("disable_p_refinement"))
1377  flag = params.get<bool>("disable_p_refinement");
1378 
1379  auto [it, inserted] = _family_for_p_refinement.emplace(family, flag);
1380  if (!inserted && flag != it->second)
1381  mooseError("'disable_p_refinement' not set consistently for variables in ", family);
1382 }
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
std::unordered_map< FEFamily, bool > _family_for_p_refinement
Indicate whether a family is disabled for p-refinement.
Definition: SubProblem.h:1223
static const std::unordered_set< FEFamily > _default_families_without_p_refinement
The set of variable families by default disable p-refinement.
Definition: SubProblem.h:1225
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:54
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
bool isParamValid(const std::string &name) const
This method returns parameters that have been initialized in one fashion or another, i.e.

◆ markMatPropRequested()

void SubProblem::markMatPropRequested ( const std::string &  prop_name)
virtualinherited

Helper method for adding a material property name to the _material_property_requested set.

Definition at line 725 of file SubProblem.C.

Referenced by MaterialBase::markMatPropRequested(), and MaterialPropertyInterface::markMatPropRequested().

726 {
727  _material_property_requested.insert(prop_name);
728 }
std::set< std::string > _material_property_requested
set containing all material property names that have been requested by getMaterialProperty* ...
Definition: SubProblem.h:1077

◆ matrixTagExists() [1/2]

bool SubProblem::matrixTagExists ( const TagName &  tag_name) const
virtualinherited

Check to see if a particular Tag exists.

Reimplemented in DisplacedProblem.

Definition at line 329 of file SubProblem.C.

Referenced by SystemBase::addMatrix(), SystemBase::associateMatrixToTag(), Coupleable::coupledMatrixTagValue(), Coupleable::coupledMatrixTagValues(), SystemBase::disassociateDefaultMatrixTags(), SystemBase::disassociateMatrixFromTag(), SystemBase::getMatrix(), SubProblem::getMatrixTagID(), SystemBase::matrixTagActive(), DisplacedProblem::matrixTagExists(), SystemBase::removeMatrix(), and TaggingInterface::useMatrixTag().

330 {
331  auto tag_name_upper = MooseUtils::toUpper(tag_name);
332 
333  return _matrix_tag_name_to_tag_id.find(tag_name_upper) != _matrix_tag_name_to_tag_id.end();
334 }
std::map< TagName, TagID > _matrix_tag_name_to_tag_id
The currently declared tags.
Definition: SubProblem.h:1056
std::string toUpper(std::string name)
Convert supplied string to upper case.

◆ matrixTagExists() [2/2]

bool SubProblem::matrixTagExists ( TagID  tag_id) const
virtualinherited

Check to see if a particular Tag exists.

Reimplemented in DisplacedProblem.

Definition at line 337 of file SubProblem.C.

338 {
339  return _matrix_tag_id_to_tag_name.find(tag_id) != _matrix_tag_id_to_tag_name.end();
340 }
std::map< TagID, TagName > _matrix_tag_id_to_tag_name
Reverse map.
Definition: SubProblem.h:1059

◆ matrixTagName()

TagName SubProblem::matrixTagName ( TagID  tag)
virtualinherited

Retrieve the name associated with a TagID.

Reimplemented in DisplacedProblem.

Definition at line 358 of file SubProblem.C.

Referenced by SystemBase::addMatrix(), DisplacedProblem::matrixTagName(), and SystemBase::removeMatrix().

359 {
360  return _matrix_tag_id_to_tag_name[tag];
361 }
std::map< TagID, TagName > _matrix_tag_id_to_tag_name
Reverse map.
Definition: SubProblem.h:1059

◆ mesh() [1/4]

MFEMMesh & MFEMProblem::mesh ( )
overridevirtual

Overwritten mesh() method from base MooseMesh to retrieve the correct mesh type, in this case MFEMMesh.

Reimplemented from FEProblemBase.

Definition at line 777 of file MFEMProblem.C.

Referenced by SetMFEMMeshFESpaceAction::act(), addMFEMFESpaceFromMOOSEVariable(), displaceMesh(), getMeshDisplacementGridFunction(), mesh(), and setMesh().

778 {
779  mooseAssert(ExternalProblem::mesh().type() == "MFEMMesh",
780  "Please choose the MFEMMesh mesh type for an MFEMProblem\n");
781  return static_cast<MFEMMesh &>(_mesh);
782 }
MooseMesh & _mesh
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
MFEMMesh inherits a MOOSE mesh class which allows us to work with other MOOSE objects.
Definition: MFEMMesh.h:20
virtual MooseMesh & mesh() override

◆ mesh() [2/4]

const MFEMMesh & MFEMProblem::mesh ( ) const
overridevirtual

Reimplemented from FEProblemBase.

Definition at line 785 of file MFEMProblem.C.

786 {
787  return const_cast<MFEMProblem *>(this)->mesh();
788 }
virtual MFEMMesh & mesh() override
Overwritten mesh() method from base MooseMesh to retrieve the correct mesh type, in this case MFEMMes...
Definition: MFEMProblem.C:777

◆ mesh() [3/4]

const MooseMesh & FEProblemBase::mesh ( bool  use_displaced) const
overridevirtualinherited

Implements SubProblem.

Definition at line 674 of file FEProblemBase.C.

675 {
676  if (use_displaced && !_displaced_problem)
677  mooseWarning("Displaced mesh was requested but the displaced problem does not exist. "
678  "Regular mesh will be returned");
679  return ((use_displaced && _displaced_problem) ? _displaced_problem->mesh() : mesh());
680 }
void mooseWarning(Args &&... args) const
virtual MooseMesh & mesh() override
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ mesh() [4/4]

MooseMesh & FEProblemBase::mesh ( bool  use_displaced)
inherited

Definition at line 683 of file FEProblemBase.C.

684 {
685  if (use_displaced && !_displaced_problem)
686  mooseWarning("Displaced mesh was requested but the displaced problem does not exist. "
687  "Regular mesh will be returned");
688  return ((use_displaced && _displaced_problem) ? _displaced_problem->mesh() : mesh());
689 }
void mooseWarning(Args &&... args) const
virtual MooseMesh & mesh() override
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ meshChanged() [1/2]

void FEProblemBase::meshChanged ( bool  intermediate_change,
bool  contract_mesh,
bool  clean_refinement_flags 
)
virtualinherited

Update data after a mesh change.

Iff intermediate_change is true, only perform updates as necessary to prepare for another mesh change immediately-subsequent. An example of data that is not updated during an intermediate change is libMesh System matrix data. An example of data that is updated during an intermediate change is libMesh System vectors. These vectors are projected or restricted based off of adaptive mesh refinement or the changing of element subdomain IDs. The flags contract_mesh and clean_refinement_flags should generally only be set to true when the mesh has changed due to mesh refinement. contract_mesh deletes children of coarsened elements and renumbers nodes and elements. clean_refinement_flags resets refinement flags such that any subsequent calls to System::restrict_vectors or System::prolong_vectors before another AMR step do not mistakenly attempt to re-do the restriction/prolongation which occurred in this method

Definition at line 8684 of file FEProblemBase.C.

Referenced by SidesetAroundSubdomainUpdater::finalize(), ActivateElementsUserObjectBase::finalize(), Exodus::handleExodusIOMeshRenumbering(), ElementSubdomainModifierBase::modify(), MooseApp::restore(), TransientMultiApp::setupApp(), and Adaptivity::uniformRefineWithProjection().

8687 {
8688  TIME_SECTION("meshChanged", 3, "Handling Mesh Changes");
8689 
8691 
8694  _mesh.cacheChangedLists(); // Currently only used with adaptivity and stateful material
8695  // properties
8696 
8697  // Clear these out because they corresponded to the old mesh
8698  _ghosted_elems.clear();
8700 
8701  // The mesh changed. We notify the MooseMesh first, because
8702  // callbacks (e.g. for sparsity calculations) triggered by the
8703  // EquationSystems reinit may require up-to-date MooseMesh caches.
8704  _mesh.meshChanged();
8705 
8706  // If we're just going to alter the mesh again, all we need to
8707  // handle here is AMR and projections, not full system reinit
8708  if (intermediate_change)
8709  es().reinit_solutions();
8710  else
8711  es().reinit();
8712 
8713  if (contract_mesh)
8714  // Once vectors are restricted, we can delete children of coarsened elements
8715  _mesh.getMesh().contract();
8716  if (clean_refinement_flags)
8717  {
8718  // Finally clear refinement flags so that if someone tries to project vectors again without
8719  // an intervening mesh refinement to clear flags they won't run into trouble
8720  MeshRefinement refinement(_mesh.getMesh());
8721  refinement.clean_refinement_flags();
8722  }
8723 
8724  if (!intermediate_change)
8725  {
8726  // Since the mesh has changed, we need to make sure that we update any of our
8727  // MOOSE-system specific data.
8728  for (auto & sys : _solver_systems)
8729  sys->reinit();
8730  _aux->reinit();
8731  }
8732 
8733  // Updating MooseMesh first breaks other adaptivity code, unless we
8734  // then *again* update the MooseMesh caches. E.g. the definition of
8735  // "active" and "local" may have been *changed* by refinement and
8736  // repartitioning done in EquationSystems::reinit().
8737  _mesh.meshChanged();
8738 
8739  // If we have finite volume variables, we will need to recompute additional elemental/face
8740  // quantities
8743 
8744  // Let the meshChangedInterface notify the mesh changed event before we update the active
8745  // semilocal nodes, because the set of ghosted elements may potentially be updated during a mesh
8746  // changed event.
8747  for (const auto & mci : _notify_when_mesh_changes)
8748  mci->meshChanged();
8749 
8750  // Since the Mesh changed, update the PointLocator object used by DiracKernels.
8752 
8753  // Need to redo ghosting
8755 
8756  if (_displaced_problem)
8757  {
8758  _displaced_problem->meshChanged(contract_mesh, clean_refinement_flags);
8760  }
8761 
8763 
8766 
8767  // Just like we reinitialized our geometric search objects, we also need to reinitialize our
8768  // mortar meshes. Note that this needs to happen after DisplacedProblem::meshChanged because the
8769  // mortar mesh discretization will depend necessarily on the displaced mesh being re-displaced
8770  _mortar_data->meshChanged();
8771 
8772  // Nonlinear systems hold the mortar mesh functors. The domains of definition of the mortar
8773  // functors might have changed when the mesh changed.
8774  for (auto & nl_sys : _nl)
8775  nl_sys->reinitMortarFunctors();
8776 
8777  reinitBecauseOfGhostingOrNewGeomObjects(/*mortar_changed=*/true);
8778 
8779  // We need to create new storage for newly active elements, and copy
8780  // stateful properties from the old elements.
8783  {
8784  if (havePRefinement())
8786 
8787  // Prolong properties onto newly refined elements' children
8788  {
8790  /* refine = */ true, *this, _material_props, _bnd_material_props, _assembly);
8791  const auto & range = *_mesh.refinedElementRange();
8792  Threads::parallel_reduce(range, pmp);
8793 
8794  // Concurrent erasure from the shared hash map is not safe while we are reading from it in
8795  // ProjectMaterialProperties, so we handle erasure here. Moreover, erasure based on key is
8796  // not thread safe in and of itself because it is a read-write operation. Note that we do not
8797  // do the erasure for p-refinement because the coarse level element is the same as our active
8798  // refined level element
8799  if (!doingPRefinement())
8800  for (const auto & elem : range)
8801  {
8805  }
8806  }
8807 
8808  // Restrict properties onto newly coarsened elements
8809  {
8811  /* refine = */ false, *this, _material_props, _bnd_material_props, _assembly);
8812  const auto & range = *_mesh.coarsenedElementRange();
8813  Threads::parallel_reduce(range, pmp);
8814  // Note that we do not do the erasure for p-refinement because the coarse level element is the
8815  // same as our active refined level element
8816  if (!doingPRefinement())
8817  for (const auto & elem : range)
8818  {
8819  auto && coarsened_children = _mesh.coarsenedElementChildren(elem);
8820  for (auto && child : coarsened_children)
8821  {
8825  }
8826  }
8827  }
8828  }
8829 
8832 
8833  _has_jacobian = false; // we have to recompute jacobian when mesh changed
8834 
8835  // Now for backwards compatibility with user code that overrode the old no-arg meshChanged we must
8836  // call it here
8837  meshChanged();
8838 }
void setVariableAllDoFMap(const std::vector< const MooseVariableFEBase *> &moose_vars)
bool isFiniteVolumeInfoDirty() const
Definition: MooseMesh.h:1461
virtual void meshChanged()
Deprecated.
void reinitBecauseOfGhostingOrNewGeomObjects(bool mortar_changed=false)
Call when it is possible that the needs for ghosted elements has changed.
MaterialPropertyStorage & _bnd_material_props
bool _has_jacobian
Indicates if the Jacobian was computed.
virtual bool haveFV() const override
returns true if this problem includes/needs finite volume functionality.
void eraseProperty(const Elem *elem)
Remove the property storage and element pointer from internal data structures Use this when elements ...
void cacheChangedLists()
Cache information about what elements were refined and coarsened in the previous step.
Definition: MooseMesh.C:917
void markMeshChangedForBackup()
Mark this app as requiring mesh topology data in its next Backup object.
Definition: MooseApp.h:755
void parallel_reduce(const Range &range, Body &body, const Partitioner &, unsigned int n_threads=libMesh::n_threads())
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
ConstElemPointerRange * refinedElementRange() const
Return a range that is suitable for threaded execution over elements that were just refined...
Definition: MooseMesh.C:935
std::set< dof_id_type > _ghosted_elems
Elements that should have Dofs ghosted to the local processor.
Definition: SubProblem.h:1108
std::unique_ptr< libMesh::ConstElemRange > _nl_evaluable_local_elem_range
bool _calculate_jacobian_in_uo
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
bool havePRefinement() const
Query whether p-refinement has been requested at any point during the simulation. ...
Definition: SubProblem.h:1024
MeshBase & getMesh()
Accessor for the underlying libMesh Mesh object.
Definition: MooseMesh.C:3548
std::vector< MeshChangedInterface * > _notify_when_mesh_changes
Objects to be notified when the mesh changes.
virtual libMesh::EquationSystems & es() override
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseMesh & _mesh
void reinit()
Completely redo all geometric search objects.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
bool doingPRefinement() const
Definition: SubProblem.C:1366
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
const std::vector< const Elem * > & coarsenedElementChildren(const Elem *elem) const
Get the newly removed children element ids for an element that was just coarsened.
Definition: MooseMesh.C:947
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data
virtual bool contract()=0
void updateActiveSemiLocalNodeRange(std::set< dof_id_type > &ghosted_elems)
Clears the "semi-local" node list and rebuilds it.
Definition: MooseMesh.C:955
std::vector< std::vector< const MooseVariableFEBase * > > _uo_jacobian_moose_vars
std::shared_ptr< DisplacedProblem > _displaced_problem
GeometricSearchData _geometric_search_data
bool _has_initialized_stateful
Whether nor not stateful materials have been initialized.
MaterialPropertyStorage & _neighbor_material_props
ConstElemPointerRange * coarsenedElementRange() const
Return a range that is suitable for threaded execution over elements that were just coarsened...
Definition: MooseMesh.C:941
std::unique_ptr< libMesh::ConstElemRange > _evaluable_local_elem_range
DiracKernelInfo _dirac_kernel_info
Definition: SubProblem.h:1064
MaterialPropertyStorage & _material_props
void updatePointLocator(const MooseMesh &mesh)
Called during FEProblemBase::meshChanged() to update the PointLocator object used by the DiracKernels...
MooseMesh * _displaced_mesh
void meshChanged()
Declares that the MooseMesh has changed, invalidates cached data and rebuilds caches.
Definition: MooseMesh.C:887
void buildPRefinementAndCoarseningMaps(Assembly *assembly)
Definition: MooseMesh.C:2418
virtual void ghostGhostedBoundaries() override
Causes the boundaries added using addGhostedBoundary to actually be ghosted.
void setupFiniteVolumeMeshData() const
Sets up the additional data needed for finite volume computations.
Definition: MooseMesh.C:4192

◆ meshChanged() [2/2]

virtual void FEProblemBase::meshChanged ( )
inlineprotectedvirtualinherited

Deprecated.

Users should switch to overriding the meshChanged which takes arguments

Definition at line 2985 of file FEProblemBase.h.

Referenced by FEProblemBase::adaptMesh(), FEProblemBase::initialAdaptMesh(), FEProblemBase::meshChanged(), FEProblemBase::timestepSetup(), FEProblemBase::uniformRefine(), and FEProblemBase::updateMeshXFEM().

2985 {}

◆ meshDisplaced()

void FEProblemBase::meshDisplaced ( )
protectedvirtualinherited

Update data after a mesh displaced.

Definition at line 8853 of file FEProblemBase.C.

Referenced by DisplacedProblem::updateMesh().

8854 {
8855  for (const auto & mdi : _notify_when_mesh_displaces)
8856  mdi->meshDisplaced();
8857 }
std::vector< MeshDisplacedInterface * > _notify_when_mesh_displaces
Objects to be notified when the mesh displaces.

◆ messagePrefix()

std::string MooseBase::messagePrefix ( const bool  hit_prefix = true) const
inlineinherited
Returns
A prefix to be used in messages that contain the input file location associated with this object (if any) and the name and type of the object.

Definition at line 256 of file MooseBase.h.

Referenced by MooseBase::callMooseError(), MooseBase::errorPrefix(), MooseBase::mooseDeprecated(), MooseBase::mooseDeprecatedNoTrace(), MooseBase::mooseInfo(), and MooseBase::mooseWarning().

257  {
258  return messagePrefix(_pars, hit_prefix);
259  }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:256

◆ mooseDeprecated() [1/2]

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

Definition at line 87 of file SolutionInvalidInterface.h.

Referenced by FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), FEProblemBase::advanceMultiApps(), MultiApp::appProblem(), ChangeOverTimestepPostprocessor::ChangeOverTimestepPostprocessor(), AddVariableAction::determineType(), EigenProblem::EigenProblem(), MooseMesh::elem(), UserForcingFunction::f(), FaceFaceConstraint::FaceFaceConstraint(), FunctionDT::FunctionDT(), RandomICBase::generateRandom(), MooseMesh::getBoundariesToElems(), Control::getExecuteOptions(), FEProblemBase::getNonlinearSystem(), FEProblemBase::hasPostprocessor(), MooseMesh::isTranslatedPeriodic(), MultiAppNearestNodeTransfer::MultiAppNearestNodeTransfer(), MultiAppShapeEvaluationTransfer::MultiAppShapeEvaluationTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), NodalScalarKernel::NodalScalarKernel(), MooseMesh::node(), FixedPointSolve::numPicardIts(), RelationshipManager::operator>=(), PercentChangePostprocessor::PercentChangePostprocessor(), ReferenceResidualConvergence::ReferenceResidualConvergence(), Residual::Residual(), MooseMesh::setBoundaryToNormalMap(), Exodus::setOutputDimension(), TagVectorAux::TagVectorAux(), UserForcingFunction::UserForcingFunction(), and VariableResidual::VariableResidual().

88  {
89  _si_moose_base.MooseBase::mooseDeprecated(std::forward<Args>(args)...);
90  flagSolutionWarningMultipleRegistration(_si_moose_base.name() + ": deprecation");
91  }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const MooseBase & _si_moose_base
The MooseBase that owns this interface.

◆ mooseDeprecated() [2/2]

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

Emits a deprecation warning prefixed with the object name and type, and a stack trace.

Definition at line 317 of file MooseBase.h.

Referenced by MooseApp::addCapability(), DataFileInterface::getDataFileName(), DataFileInterface::getDataFileNameByName(), MooseApp::getRecoverFileBase(), MooseApp::hasRecoverFileBase(), and MooseApp::setupOptions().

318  {
320  _console, false, true, true, messagePrefix(true), std::forward<Args>(args)...);
321  }
void mooseDeprecatedStream(S &oss, const bool expired, const bool print_title, const bool show_trace, Args &&... args)
Definition: MooseError.h:252
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:256

◆ mooseDeprecatedNoTrace()

template<typename... Args>
void MooseBase::mooseDeprecatedNoTrace ( Args &&...  args) const
inlineinherited

Emits a deprecation warning prefixed with the object name and type, and no stack trace.

Definition at line 327 of file MooseBase.h.

328  {
330  _console, false, true, false, messagePrefix(true), std::forward<Args>(args)...);
331  }
void mooseDeprecatedStream(S &oss, const bool expired, const bool print_title, const bool show_trace, Args &&... args)
Definition: MooseError.h:252
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:256

◆ mooseDocumentedError()

template<typename... Args>
void MooseBase::mooseDocumentedError ( const std::string &  repo_name,
const unsigned int  issue_num,
Args &&...  args 
) const
inlineinherited

Definition at line 277 of file MooseBase.h.

Referenced by ArrayDGLowerDKernel::ArrayDGLowerDKernel(), ArrayHFEMDirichletBC::ArrayHFEMDirichletBC(), ArrayLowerDIntegratedBC::ArrayLowerDIntegratedBC(), DGLowerDKernel::DGLowerDKernel(), HFEMDirichletBC::HFEMDirichletBC(), LowerDIntegratedBC::LowerDIntegratedBC(), and ManifoldSubdomainGenerator::ManifoldSubdomainGenerator().

280  {
282  repo_name, issue_num, argumentsToString(std::forward<Args>(args)...)),
283  /* with_prefix = */ true);
284  }
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
External method for calling moose error with added object context.
Definition: MooseBase.C:105
std::string formatMooseDocumentedError(const std::string &repo_name, const unsigned int issue_num, const std::string &msg)
Formats a documented error.
Definition: MooseError.C:142

◆ mooseError()

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

Emits an error prefixed with object name and type and optionally a file path to the top-level block parameter if available.

Definition at line 271 of file MooseBase.h.

Referenced by CopyMeshPartitioner::_do_partition(), HierarchicalGridPartitioner::_do_partition(), GridPartitioner::_do_partition(), PetscExternalPartitioner::_do_partition(), MultiAppGeneralFieldTransfer::acceptPointInOriginMesh(), CheckIntegrityAction::act(), AddMeshGeneratorAction::act(), AddICAction::act(), CheckFVBCAction::act(), AddVectorPostprocessorAction::act(), CreateExecutionerAction::act(), AddBoundsVectorsAction::act(), AddFVICAction::act(), SetupMeshCompleteAction::act(), InitProblemAction::act(), CreateProblemAction::act(), CreateProblemDefaultAction::act(), AdaptivityAction::act(), CombineComponentsMeshes::act(), SetupMeshAction::act(), SplitMeshAction::act(), AddTimeStepperAction::act(), ChainControlSetupAction::act(), DeprecatedBlockAction::act(), SetupDebugAction::act(), CSGOnlyAction::act(), SetupTimeStepperAction::act(), SetupPredictorAction::act(), CreateDisplacedProblemAction::act(), MaterialDerivativeTestAction::act(), SetAdaptivityOptionsAction::act(), MaterialOutputAction::act(), CommonOutputAction::act(), AddPeriodicBCAction::act(), Action::Action(), FEProblemBase::adaptMesh(), ADArrayReaction::ADArrayReaction(), MooseVariableFV< Real >::adCurlSln(), MooseVariableFV< Real >::adCurlSlnNeighbor(), AddActionComponentAction::AddActionComponentAction(), addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), DiffusionCG::addBoundaryConditionsFromComponents(), PhysicsComponentInterface::addBoundaryConditionsFromComponents(), MooseApp::addCapabilityInternal(), FEProblemBase::addConstraint(), FEProblemBase::addDamper(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), DistributedRectilinearMeshGenerator::addElement(), MooseApp::addExecutor(), addFESpace(), addFESpaceHierarchy(), FEProblemBase::addFunction(), SubProblem::addFunctor(), FEProblemBase::addFVInitialCondition(), ADDGKernel::ADDGKernel(), FEProblemBase::addHDGKernel(), FEProblemBase::addInitialCondition(), PhysicsComponentInterface::addInitialConditionsFromComponents(), FEProblemBase::addInterfaceKernel(), addKernel(), FEProblemBase::addKernel(), FEProblem::addLineSearch(), FEProblemBase::addLineSearch(), addMaterial(), LinearFVFluxKernel::addMatrixContribution(), ComponentJunction::addMeshGenerators(), MeshGenerator::addMeshSubgenerator(), addMFEMFESpaceFromMOOSEVariable(), FEProblemBase::addObjectParamsHelper(), FEProblemBase::addOutput(), SubProblem::addPiecewiseByBlockLambdaFunctor(), DistributedRectilinearMeshGenerator::addPoint(), DiracKernelBase::addPointWithValidId(), FEProblemBase::addPredictor(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), MooseMesh::addQuadratureNode(), Action::addRelationshipManager(), LinearFVFluxKernel::addRightHandSideContribution(), FEProblemBase::addScalarKernel(), WebServerControl::addServerAction(), MFEMEigenproblem::addVariable(), AddVariableAction::addVariable(), SubProblem::addVectorTag(), MooseLinearVariableFV< Real >::adError(), ADInterfaceKernelTempl< T >::ADInterfaceKernelTempl(), ADPiecewiseLinearInterpolationMaterial::ADPiecewiseLinearInterpolationMaterial(), MooseVariableScalar::adUDot(), Output::advancedExecuteOn(), NEML2ModelExecutor::advanceState(), AdvectiveFluxAux::AdvectiveFluxAux(), MooseVariableBase::allDofIndices(), MooseApp::appNameToLibName(), MultiApp::appPostprocessorValue(), MultiApp::appProblem(), MultiApp::appProblemBase(), MultiApp::appUserObjectBase(), ArrayConstantIC::ArrayConstantIC(), ArrayDGKernel::ArrayDGKernel(), ArrayDiffusion::ArrayDiffusion(), ArrayFunctionIC::ArrayFunctionIC(), ArrayReaction::ArrayReaction(), ArrayTimeDerivative::ArrayTimeDerivative(), ArrayVariableValueVolumeHistogram::ArrayVariableValueVolumeHistogram(), MooseApp::attachRelationshipManagers(), Function::average(), Axisymmetric2D3DSolutionFunction::Axisymmetric2D3DSolutionFunction(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), BicubicSplineFunction::BicubicSplineFunction(), BlockDeletionGenerator::BlockDeletionGenerator(), BoundingValueElementDamper::BoundingValueElementDamper(), BoundingValueNodalDamper::BoundingValueNodalDamper(), MooseMesh::buildCoarseningMap(), MultiApp::buildComm(), DistributedRectilinearMeshGenerator::buildCube(), PiecewiseTabularInterface::buildFromFile(), TimedSubdomainModifier::buildFromFile(), PiecewiseTabularInterface::buildFromJSON(), TimedSubdomainModifier::buildFromParameters(), PiecewiseTabularInterface::buildFromXY(), PiecewiseLinearBase::buildInterpolation(), MooseMesh::buildLowerDMesh(), TiledMesh::buildMesh(), GeneratedMesh::buildMesh(), SpiralAnnularMesh::buildMesh(), MeshGeneratorMesh::buildMesh(), ImageMeshGenerator::buildMesh3D(), ImageMesh::buildMesh3D(), MFEMGeometricMultigridSolver::BuildMultigrid(), MooseMesh::buildRefinementMap(), MaterialBase::buildRequiredMaterials(), MooseMesh::buildTypedMesh(), MooseMesh::cacheFaceInfoVariableOwnership(), CartesianGridDivision::CartesianGridDivision(), CartesianMeshGenerator::CartesianMeshGenerator(), ChangeOverFixedPointPostprocessor::ChangeOverFixedPointPostprocessor(), ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), EigenExecutionerBase::chebyshev(), SubProblem::checkBlockMatProps(), PhysicsBase::checkBlockRestrictionIdentical(), ComponentBoundaryConditionInterface::checkBoundaryConditionsAllRequested(), SubProblem::checkBoundaryMatProps(), PhysicsBase::checkComponentType(), IterationCountConvergence::checkConvergence(), MooseMesh::checkCoordinateSystems(), DiffusionLHDGAssemblyHelper::checkCoupling(), FEProblemBase::checkDependMaterialsHelper(), FEProblemBase::checkDisplacementOrders(), FEProblemBase::checkDuplicatePostprocessorVariableNames(), DefaultConvergenceBase::checkDuplicateSetSharedExecutionerParams(), MooseMesh::checkDuplicateSubdomainNames(), FEProblemBase::checkExceptionAndStopSolve(), NEML2ModelExecutor::checkExecutionStage(), MaterialBase::checkExecutionStage(), MeshGenerator::checkGetMesh(), ReporterTransferInterface::checkHasReporterValue(), FEProblemBase::checkICRestartError(), Steady::checkIntegrity(), EigenExecutionerBase::checkIntegrity(), Eigenvalue::checkIntegrity(), DefaultMultiAppFixedPointConvergence::checkIterationType(), DefaultSteadyStateConvergence::checkIterationType(), DefaultNonlinearConvergence::checkIterationType(), ExplicitTimeIntegrator::checkLinearConvergence(), MooseApp::checkMetaDataIntegrity(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), MeshDiagnosticsGenerator::checkNonMatchingEdges(), PostprocessorInterface::checkParam(), Moose::PeriodicBCHelper::checkPeriodicParams(), FEProblemBase::checkProblemIntegrity(), Sampler::checkReinitStatus(), MultiAppGeneralFieldKDTreeTransferBase::checkRestrictionsForSource(), MultiAppMFEMCopyTransfer::checkSiblingsTransferSupported(), MultiAppPostprocessorToAuxScalarTransfer::checkSiblingsTransferSupported(), MultiAppScalarToAuxScalarTransfer::checkSiblingsTransferSupported(), MultiAppPostprocessorTransfer::checkSiblingsTransferSupported(), MultiAppReporterTransfer::checkSiblingsTransferSupported(), MultiAppCopyTransfer::checkSiblingsTransferSupported(), MultiAppTransfer::checkSiblingsTransferSupported(), MaterialBase::checkStatefulSanity(), AddDefaultConvergenceAction::checkUnusedMultiAppFixedPointConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedNonlinearConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedSteadyStateConvergenceParameters(), FEProblemBase::checkUserObjectNameCollision(), FEProblemBase::checkUserObjects(), Moose::PetscSupport::checkUserProvidedPetscOption(), MFEMMultiAppTransfer::checkValidTransferProblemTypes(), DomainUserObject::checkVariable(), MultiAppTransfer::checkVariable(), MeshDiagnosticsGenerator::checkWatertightNodesets(), MeshDiagnosticsGenerator::checkWatertightSidesets(), LibmeshPartitioner::clone(), MooseMesh::clone(), CombinerGenerator::CombinerGenerator(), ComparisonPostprocessor::comparisonIsTrue(), MFEMComplexAuxKernel::complexAdd(), MooseVariableFieldBase::componentName(), CompositeFunction::CompositeFunction(), ElementH1ErrorFunctionAux::compute(), NodalPatchRecovery::compute(), FEProblemBase::computeBounds(), VariableCondensationPreconditioner::computeDInverseDiag(), CompositionDT::computeDT(), ArrayDGKernel::computeElemNeighJacobian(), ArrayDGKernel::computeElemNeighResidual(), BoundaryLinearFVFluxIntegral::computeFaceInfoIntegral(), InternalSideIntegralPostprocessor::computeFaceInfoIntegral(), SideIntegralPostprocessor::computeFaceInfoIntegral(), MooseVariableFieldBase::computeFaceValues(), IterationAdaptiveDT::computeFailedDT(), TimeStepper::computeFailedDT(), MooseMesh::computeFiniteVolumeCoords(), HistogramVectorPostprocessor::computeHistogram(), ArrayKernel::computeJacobian(), ArrayIntegratedBC::computeJacobian(), FVFluxKernel::computeJacobian(), NodalConstraint::computeJacobian(), FEProblemBase::computeJacobianTags(), LowerDIntegratedBC::computeLowerDOffDiagJacobian(), ArrayLowerDIntegratedBC::computeLowerDOffDiagJacobian(), EigenProblem::computeMatricesTags(), ArrayDGKernel::computeOffDiagElemNeighJacobian(), ArrayKernel::computeOffDiagJacobian(), ArrayIntegratedBC::computeOffDiagJacobian(), FVElementalKernel::computeOffDiagJacobian(), Moose::Kokkos::ResidualObject::computeOffDiagJacobian(), MortarScalarBase::computeOffDiagJacobianScalar(), DGLowerDKernel::computeOffDiagLowerDJacobian(), ArrayDGLowerDKernel::computeOffDiagLowerDJacobian(), MaterialBase::computeProperties(), BoundaryLinearFVFluxIntegral::computeQpIntegral(), SideFVFluxBCIntegral::computeQpIntegral(), ScalarKernel::computeQpJacobian(), TiedValueConstraint::computeQpJacobian(), CoupledTiedValueConstraint::computeQpJacobian(), NodalEqualValueConstraint::computeQpJacobian(), LinearNodalConstraint::computeQpJacobian(), EqualValueBoundaryConstraint::computeQpJacobian(), NodeElemConstraint::computeQpJacobian(), ADArrayNodalKernel::computeQpJacobian(), CoupledTiedValueConstraint::computeQpOffDiagJacobian(), ScalarKernel::computeQpResidual(), MassMatrix::computeQpResidual(), HDGKernel::computeQpResidual(), DiffusionLHDGDirichletBC::computeQpResidual(), DiffusionLHDGPrescribedGradientBC::computeQpResidual(), NodalEqualValueConstraint::computeQpResidual(), ElementAndTraceScalarHDGBC::computeQpResidual(), KernelValue::computeQpResidual(), TorchScriptMaterial::computeQpValues(), InterfaceQpValueUserObject::computeRealValue(), ArrayKernel::computeResidual(), ArrayIntegratedBC::computeResidual(), FVFluxBC::computeResidual(), FVFluxKernel::computeResidual(), NodalConstraint::computeResidual(), FVFluxKernel::computeResidualAndJacobian(), ResidualObject::computeResidualAndJacobian(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualInternal(), FEProblemBase::computeResidualTag(), FEProblemBase::computeResidualTags(), FEProblemBase::computeResidualType(), KernelScalarBase::computeScalarOffDiagJacobian(), ADKernelScalarBase::computeScalarQpResidual(), ADMortarScalarBase::computeScalarQpResidual(), MortarScalarBase::computeScalarQpResidual(), KernelScalarBase::computeScalarQpResidual(), TimeStepper::computeStep(), ActuallyExplicitEuler::computeTimeDerivatives(), ExplicitEuler::computeTimeDerivatives(), ImplicitEuler::computeTimeDerivatives(), BDF2::computeTimeDerivatives(), NewmarkBeta::computeTimeDerivatives(), CentralDifference::computeTimeDerivatives(), CrankNicolson::computeTimeDerivatives(), LStableDirk2::computeTimeDerivatives(), LStableDirk3::computeTimeDerivatives(), ImplicitMidpoint::computeTimeDerivatives(), ExplicitTVDRK2::computeTimeDerivatives(), AStableDirk4::computeTimeDerivatives(), LStableDirk4::computeTimeDerivatives(), ExplicitRK2::computeTimeDerivatives(), MultiAppGeometricInterpolationTransfer::computeTransformation(), BuildArrayVariableAux::computeValue(), TagVectorArrayVariableAux::computeValue(), NearestNodeValueAux::computeValue(), ProjectionAux::computeValue(), PenetrationAux::computeValue(), ConcentricCircleMesh::ConcentricCircleMesh(), ConditionalEnableControl::ConditionalEnableControl(), ConservativeAdvectionBCTempl< false >::ConservativeAdvectionBCTempl(), TimeStepper::constrainStep(), LibtorchNeuralNetControl::controlNeuralNet(), TransientBase::convergedToSteadyState(), ParsedConvergence::convertRealToBool(), MooseApp::copyInputs(), CopyMeshPartitioner::CopyMeshPartitioner(), CoupledForceNodalKernel::CoupledForceNodalKernel(), MultiApp::createApp(), MFEML2ZienkiewiczZhuIndicator::createEstimator(), MooseApp::createExecutors(), AddVariableAction::createInitialConditionAction(), MooseApp::createRMFromTemplateAndInit(), Function::curl(), MooseVariableFV< Real >::curlPhi(), CutMeshByPlaneGenerator::CutMeshByPlaneGenerator(), SidesetInfoVectorPostprocessor::dataHelper(), ReporterTransferInterface::declareClone(), Moose::Kokkos::MaterialBase::declareKokkosPropertyInternal(), MeshGenerator::declareMeshProperty(), ReporterTransferInterface::declareVectorClone(), DefaultSteadyStateConvergence::DefaultSteadyStateConvergence(), FunctorRelationshipManager::delete_remote_elements(), MooseMesh::deleteRemoteElements(), BicubicSplineFunction::derivative(), DerivativeSumMaterialTempl< is_ad >::DerivativeSumMaterialTempl(), MooseApp::determineLibtorchDeviceType(), FEProblemBase::determineSolverSystem(), DGKernel::DGKernel(), MeshDiagnosticsGenerator::diagnosticsLog(), DistributedPositions::DistributedPositions(), Function::div(), FunctorBinnedValuesDivision::divisionIndex(), MooseVariableFV< Real >::divPhi(), FunctorRelationshipManager::dofmap_reinit(), EigenProblem::doFreeNonlinearPowerIterations(), FEProblemBase::duplicateVariableCheck(), MooseApp::dynamicAllRegistration(), MooseApp::dynamicAppRegistration(), EigenProblem::EigenProblem(), EigenProblemSolve::EigenProblemSolve(), Eigenvalues::Eigenvalues(), ElementalVariableValue::ElementalVariableValue(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), ElementIntegerAux::ElementIntegerAux(), ElementMaterialSampler::ElementMaterialSampler(), ElementQualityAux::ElementQualityAux(), ElementUOAux::ElementUOAux(), ExtraIDIntegralVectorPostprocessor::elementValue(), DistributedRectilinearMeshGenerator::elemId(), ProjectionAux::elemOnNodeVariableIsDefinedOn(), EigenKernel::enabled(), MooseApp::errorCheck(), MooseMesh::errorIfDistributedMesh(), MultiAppTransfer::errorIfObjectExecutesOnTransferInSourceApp(), SideIntegralPostprocessor::errorNoFaceInfo(), SideIntegralFunctorPostprocessorTempl< false >::errorNoFaceInfo(), SolutionUserObjectBase::evalMeshFunction(), SolutionUserObjectBase::evalMeshFunctionGradient(), SolutionUserObjectBase::evalMultiValuedMeshFunction(), SolutionUserObjectBase::evalMultiValuedMeshFunctionGradient(), FixedPointSolve::examineFixedPointConvergence(), MultiAppGeneralFieldTransfer::examineReceivedValueConflicts(), RealToBoolChainControl::execute(), RestartableDataReporter::execute(), DiscreteElementUserObject::execute(), NodalValueSampler::execute(), MFEMMultiAppTransfer::execute(), MultiAppPostprocessorToAuxScalarTransfer::execute(), PositionsFunctorValueSampler::execute(), MultiAppScalarToAuxScalarTransfer::execute(), MFEMEigenvaluesPostprocessor::execute(), MultiAppPostprocessorTransfer::execute(), MultiAppPostprocessorInterpolationTransfer::execute(), ElementQualityChecker::execute(), GreaterThanLessThanPostprocessor::execute(), PointValue::execute(), MultiAppVariableValueSampleTransfer::execute(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), FindValueOnLine::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppCopyTransfer::execute(), MultiAppUserObjectTransfer::execute(), InterfaceQpUserObjectBase::execute(), MultiAppGeometricInterpolationTransfer::execute(), TransientBase::execute(), LeastSquaresFit::execute(), LeastSquaresFitHistory::execute(), VectorPostprocessorComparison::execute(), Eigenvalue::execute(), WebServerControl::execute(), TimeExtremeValue::execute(), NEML2Assembly::execute(), DomainUserObject::execute(), NEML2FEInterpolation::execute(), FEProblemBase::execute(), FEProblemBase::executeControls(), MooseApp::executeExecutioner(), MultiAppVectorPostprocessorTransfer::executeFromMultiapp(), executeMFEMObjects(), MultiAppVectorPostprocessorTransfer::executeToMultiapp(), Exodus::Exodus(), ExplicitSSPRungeKutta::ExplicitSSPRungeKutta(), MultiAppMFEMTolibMeshShapeEvaluationTransfer::extractlibMeshNodePositions(), MultiAppGeneralFieldTransfer::extractOutgoingPoints(), NEML2ModelExecutor::extractOutputs(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemSolve::FEProblemSolve(), FileOutput::FileOutput(), NEML2ModelExecutor::fillInputs(), QuadraturePointMultiApp::fillPositions(), CentroidMultiApp::fillPositions(), MultiApp::fillPositions(), MultiAppGeometricInterpolationTransfer::fillSourceInterpolationPoints(), VerifyNodalUniqueID::finalize(), VerifyElementUniqueID::finalize(), ParsedVectorReporter::finalize(), ParsedVectorVectorRealReductionReporter::finalize(), DiscreteElementUserObject::finalize(), ElementQualityChecker::finalize(), MemoryUsage::finalize(), PointSamplerBase::finalize(), DiscreteVariableResidualNorm::finalize(), NearestPointAverage::finalize(), NearestPointIntegralVariablePostprocessor::finalize(), NEML2Assembly::finalize(), MooseApp::finalizeRestore(), Transfer::find_sys(), MFEMCutTransitionSubMesh::findFaceNormal(), DiracKernelInfo::findPoint(), FixedPointSolve::findTransformedSystem(), FixedPointSolve::FixedPointSolve(), FunctionDT::FunctionDT(), FunctionMaterialBase< is_ad >::FunctionMaterialBase(), FunctionScalarAux::FunctionScalarAux(), FunctionScalarIC::FunctionScalarIC(), LinearFVBoundaryCondition::functorFaceArg(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), FVInitialConditionTempl< T >::FVInitialConditionTempl(), FVMassMatrix::FVMassMatrix(), FVMatAdvection::FVMatAdvection(), FVScalarLagrangeMultiplierInterface::FVScalarLagrangeMultiplierInterface(), GapValueAux::GapValueAux(), WorkBalance::gather(), ElementSubdomainModifierBase::gatherPatchElements(), Boundary2DDelaunayGenerator::General2DDelaunay(), SurfaceSubdomainsDelaunayRemesher::General2DDelaunay(), ElementOrderConversionGenerator::generate(), MoveNodeGenerator::generate(), PlaneIDMeshGenerator::generate(), RenameBlockGenerator::generate(), RenameBoundaryGenerator::generate(), RenumberBySubdomainGenerator::generate(), SideSetsFromNormalsGenerator::generate(), SubdomainPerElementGenerator::generate(), TiledMeshGenerator::generate(), ExtraNodesetGenerator::generate(), FileMeshGenerator::generate(), LowerDBlockFromSidesetGenerator::generate(), MeshRepairGenerator::generate(), SideSetsFromPointsGenerator::generate(), SmoothMeshGenerator::generate(), StitchMeshGenerator::generate(), MeshDiagnosticsGenerator::generate(), CoarsenBlockGenerator::generate(), GeneratedMeshGenerator::generate(), FlipSidesetGenerator::generate(), ParsedGenerateNodeset::generate(), PolyLineMeshFollowingNodeSetGenerator::generate(), ProjectSideSetOntoLevelSetGenerator::generate(), SideSetsFromAllNormalsGenerator::generate(), SideSetsFromBoundingBoxGenerator::generate(), StackGenerator::generate(), SurfaceSubdomainsFromAllNormalsGenerator::generate(), XYZDelaunayGenerator::generate(), CombinerGenerator::generate(), MeshExtruderGenerator::generate(), AdvancedExtruderGenerator::generate(), MeshCollectionGenerator::generate(), SpiralAnnularMeshGenerator::generate(), XYMeshLineCutter::generate(), Boundary2DDelaunayGenerator::generate(), CutMeshByLevelSetGeneratorBase::generate(), PatternedMeshGenerator::generate(), SubdomainBoundingBoxGenerator::generate(), DistributedRectilinearMeshGenerator::generate(), BoundingBoxNodeSetGenerator::generate(), MeshGenerator::generateCSG(), MeshGenerator::generateData(), GeneratedMesh::GeneratedMesh(), GeneratedMeshGenerator::GeneratedMeshGenerator(), MeshGenerator::generateInternal(), MeshGenerator::generateInternalCSG(), CircularBoundaryCorrectionGenerator::generateRadialCorrectionFactor(), RandomICBase::generateRandom(), GenericConstantMaterialTempl< is_ad >::GenericConstantMaterialTempl(), GenericConstantVectorMaterialTempl< is_ad >::GenericConstantVectorMaterialTempl(), GenericFunctionMaterialTempl< is_ad >::GenericFunctionMaterialTempl(), GenericFunctionVectorMaterialTempl< is_ad >::GenericFunctionVectorMaterialTempl(), GenericFunctorGradientMaterialTempl< is_ad >::GenericFunctorGradientMaterialTempl(), GenericFunctorMaterialTempl< is_ad >::GenericFunctorMaterialTempl(), GenericFunctorTimeDerivativeMaterialTempl< is_ad >::GenericFunctorTimeDerivativeMaterialTempl(), GenericVectorFunctorMaterialTempl< is_ad >::GenericVectorFunctorMaterialTempl(), DisplacedProblem::getActualFieldVariable(), FEProblemBase::getActualFieldVariable(), DisplacedProblem::getArrayVariable(), FEProblemBase::getArrayVariable(), MooseMesh::getAxisymmetricRadialCoord(), NEML2BatchIndexGenerator::getBatchIndex(), MooseMesh::getBlockConnectedBlocks(), VariableOldValueBounds::getBound(), MooseMesh::getBoundaryID(), MultiApp::getBoundingBox(), ChainControl::getChainControlDataByName(), WebServerControl::getClientInfo(), MooseMesh::getCoarseningMap(), NodalPatchRecoveryBase::getCoefficients(), MultiApp::getCommandLineArgs(), MooseVariableBase::getContinuity(), Control::getControllableParameterByName(), FEProblemBase::getConvergence(), MooseMesh::getCoordSystem(), PhysicsBase::getCoupledPhysics(), PropertyReadFile::getData(), DataFileInterface::getDataFilePath(), TransfiniteMeshGenerator::getDiscreteEdge(), FEProblemBase::getDistribution(), MooseVariableBase::getDofIndices(), VariableCondensationPreconditioner::getDofToCondense(), TransfiniteMeshGenerator::getEdge(), GhostingUserObject::getElementalValue(), ElementUOProvider::getElementalValueLong(), ElementUOProvider::getElementalValueReal(), PropertyReadFile::getElementData(), MooseMesh::getElementIDIndex(), Material::getElementIDNeighbor(), Material::getElementIDNeighborByName(), MooseMesh::getElemIDMapping(), MooseMesh::getElemIDsOnBlocks(), MultiAppFieldTransfer::getEquationSystem(), WebServerControl::Response::getError(), MultiApp::getExecutioner(), MooseApp::getExecutor(), MFEMVectorFESpace::getFECName(), MultiAppTransfer::getFromMultiApp(), MultiAppTransfer::getFromMultiAppInfo(), FEProblemBase::getFunction(), SubProblem::getFunctor(), FEProblemBase::getFVAdvectedInterpolationMethod(), FEProblemBase::getFVFaceInterpolationMethod(), FEProblemBase::getFVInterpolationMethod(), FEProblemBase::getFVMatsAndDependencies(), MooseMesh::getGeneralAxisymmetricCoordAxis(), MaterialPropertyInterface::getGenericMaterialPropertyByName(), DistributedRectilinearMeshGenerator::getGhostNeighbors(), DistributedRectilinearMeshGenerator::getIndices(), MaterialPropertyInterface::getKokkosBlockMaterialProperty(), FEProblemBase::getKokkosFunction(), FunctionInterface::getKokkosFunctionByName(), MaterialPropertyInterface::getKokkosMaterialPropertyByName(), FEProblemBase::getKokkosUserObject(), MFEMMultiAppTransfer::getlibMeshEquationSystem(), FEProblemBase::getLinearConvergenceNames(), SolutionUserObjectBase::getLocalVarIndex(), Material::getMaterialByName(), FEProblemBase::getMaterialData(), FEProblemBase::getMaterialPropertyStorageConsumers(), SubProblem::getMatrixTagID(), AnnularMesh::getMaxInDimension(), GeneratedMesh::getMaxInDimension(), FEProblemBase::getMaxQps(), FEProblemBase::getMeshDivision(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), getMFEMObject(), getMFEMVariableMesh(), GeneratedMesh::getMinInDimension(), AnnularMesh::getMinInDimension(), NEML2FEInterpolation::getMOOSEVariable(), MultiAppTransfer::getMultiApp(), FEProblemBase::getMultiAppFixedPointConvergenceName(), DistributedRectilinearMeshGenerator::getNeighbors(), Times::getNextTime(), MooseMesh::getNodeBlockIds(), PropertyReadFile::getNodeData(), MooseMesh::getNodeList(), FEProblemBase::getNonlinearConvergenceNames(), EigenProblem::getNonlinearEigenSystem(), FEProblemBase::getNonlinearSystem(), NEML2ModelExecutor::getOutput(), NEML2ModelExecutor::getOutputDerivative(), NEML2ModelExecutor::getOutputParameterDerivative(), MooseMesh::getPairedBoundaryMapping(), MaterialOutputAction::getParams(), ImageMeshGenerator::GetPixelInfo(), ImageMesh::GetPixelInfo(), PlaneIDMeshGenerator::getPlaneID(), Positions::getPosition(), Positions::getPositions(), FEProblemBase::getPositionsObject(), Positions::getPositionsVector2D(), Positions::getPositionsVector3D(), Positions::getPositionsVector4D(), FEProblemBase::getPostprocessorObjectByName(), PostprocessorInterface::getPostprocessorValueByNameInternal(), Times::getPreviousTime(), EqualValueBoundaryConstraint::getPrimaryNodeIDByCoord(), ComponentMaterialPropertyInterface::getPropertyValue(), InterfaceQpUserObjectBase::getQpValue(), MooseMesh::getRefinementMap(), MooseBase::getRenamedParam(), ReporterInterface::getReporterContextBaseByName(), ReporterInterface::getReporterName(), Reporter::getReporterValueName(), MooseApp::getRestartableDataMap(), MooseApp::getRestartableDataMapName(), MooseApp::getRestartableMetaData(), MooseApp::getRMClone(), FEProblemBase::getSampler(), DisplacedProblem::getScalarVariable(), FEProblemBase::getScalarVariable(), MooseObject::getSharedPtr(), InterfaceQpUserObjectBase::getSideAverageValue(), PhysicsBase::getSolverSystem(), DisplacedProblem::getStandardVariable(), FEProblemBase::getStandardVariable(), FEProblemBase::getSteadyStateConvergenceName(), MooseMesh::getSubdomainBoundaryIds(), TimedSubdomainModifier::getSubdomainIDAndCheck(), DisplacedProblem::getSystem(), FEProblemBase::getSystem(), FEProblemBase::getSystemBase(), Times::getTimeAtIndex(), FEProblemBase::getTimeFromStateArg(), TransientBase::getTimeIntegratorNames(), Times::getTimes(), MultiAppTransfer::getToMultiApp(), MultiAppTransfer::getToMultiAppInfo(), MooseMesh::getUniqueCoordSystem(), FEProblemBase::getUserObject(), FEProblemBase::getUserObjectBase(), UserObjectInterface::getUserObjectBaseByName(), UserObjectInterface::getUserObjectName(), NumRelationshipManagers::getValue(), VectorPostprocessorComponent::getValue(), Residual::getValue(), SideAverageValue::getValue(), JSONFileReader::getValue(), LineValueSampler::getValue(), FindValueOnLine::getValueAtPoint(), SubProblem::getVariableHelper(), AddPeriodicBCAction::getVariables(), JSONFileReader::getVector(), VectorPostprocessorInterface::getVectorPostprocessorName(), FEProblemBase::getVectorPostprocessorObjectByName(), SubProblem::getVectorTag(), SubProblem::getVectorTagID(), DisplacedProblem::getVectorVariable(), FEProblemBase::getVectorVariable(), GhostingFromUOAux::GhostingFromUOAux(), EqualValueBoundaryConstraint::ghostPrimary(), MultiApp::globalAppToLocal(), MooseParsedVectorFunction::gradient(), Function::gradient(), MooseLinearVariableFV< Real >::gradientStateError(), FEProblemBase::handleException(), Terminator::handleMessage(), MooseVariableBase::hasDoFsOnNodes(), PostprocessorInterface::hasPostprocessor(), PostprocessorInterface::hasPostprocessorByName(), ReporterInterface::hasReporterValue(), ReporterInterface::hasReporterValueByName(), VectorPostprocessorInterface::hasVectorPostprocessor(), VectorPostprocessorInterface::hasVectorPostprocessorByName(), HDGKernel::HDGKernel(), TransientBase::incrementStepOrReject(), NEML2Action::inferMOOSEIOType(), FixedPointIterationAdaptiveDT::init(), CrankNicolson::init(), CSVTimeSequenceStepper::init(), EigenExecutionerBase::init(), ExplicitTimeIntegrator::init(), TransientBase::init(), FEProblem::init(), AddAuxVariableAction::init(), IterationAdaptiveDT::init(), MFEMMesh::init(), AddVariableAction::init(), MooseMesh::init(), Sampler::init(), FEProblemBase::init(), MultiApp::init(), FEProblemBase::initialAdaptMesh(), NestedDivision::initialize(), ReporterPositions::initialize(), DistributedPositions::initialize(), TransformedPositions::initialize(), ElementGroupCentroidPositions::initialize(), ReporterTimes::initialize(), FunctorPositions::initialize(), FunctorTimes::initialize(), ParsedDownSelectionPositions::initialize(), ParsedConvergence::initializeConstantSymbol(), PhysicsBase::initializePhysics(), SteffensenSolve::initialSetup(), MultiAppCloneReporterTransfer::initialSetup(), SolutionIC::initialSetup(), MultiAppConservativeTransfer::initialSetup(), PiecewiseLinearBase::initialSetup(), IntegralPreservingFunctionIC::initialSetup(), ChainControlDataPostprocessor::initialSetup(), FullSolveMultiApp::initialSetup(), PiecewiseLinear::initialSetup(), MFEMSamplerBase::initialSetup(), MultiAppGeneralFieldNearestLocationTransfer::initialSetup(), CoarsenedPiecewiseLinear::initialSetup(), EigenProblemSolve::initialSetup(), SolutionScalarAux::initialSetup(), MultiAppDofCopyTransfer::initialSetup(), LinearFVAnisotropicDiffusion::initialSetup(), LinearFVAdvection::initialSetup(), SolutionAux::initialSetup(), ExplicitTimeIntegrator::initialSetup(), LinearFVDiffusion::initialSetup(), ReferenceResidualConvergence::initialSetup(), NodalVariableValue::initialSetup(), Axisymmetric2D3DSolutionFunction::initialSetup(), ElementSubdomainModifierBase::initialSetup(), Exodus::initialSetup(), CSV::initialSetup(), MooseParsedFunction::initialSetup(), AuxKernelBase::initialSetup(), NEML2FEInterpolation::initialSetup(), SolutionUserObjectBase::initialSetup(), FEProblemBase::initialSetup(), SubProblem::initialSetup(), AdvancedOutput::initOutputList(), AdvancedOutput::initShowHideLists(), Function::integral(), InterfaceDiffusiveFluxIntegralTempl< is_ad >::InterfaceDiffusiveFluxIntegralTempl(), InterfaceIntegralVariableValuePostprocessor::InterfaceIntegralVariableValuePostprocessor(), InterfaceKernelTempl< T >::InterfaceKernelTempl(), InterfaceTimeKernel::InterfaceTimeKernel(), InternalSideIndicatorBase::InternalSideIndicatorBase(), MultiAppGeometricInterpolationTransfer::interpolateTargetPoints(), EigenExecutionerBase::inversePowerIteration(), InversePowerMethod::InversePowerMethod(), Sampler::isAdaptiveSamplingCompleted(), MooseMesh::isBoundaryFullyExternalToSubdomains(), MooseVariableBase::isNodal(), IterationAdaptiveDT::IterationAdaptiveDT(), IterationCountConvergence::IterationCountConvergence(), LeastSquaresFit::LeastSquaresFit(), LibmeshPartitioner::LibmeshPartitioner(), MooseApp::libNameToAppName(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), LinearCombinationPostprocessor::LinearCombinationPostprocessor(), LinearNodalConstraint::LinearNodalConstraint(), LineMaterialSamplerBase< Real >::LineMaterialSamplerBase(), LineSearch::lineSearch(), LineValueSampler::LineValueSampler(), MooseApp::loadLibraryAndDependencies(), MultiAppGeneralFieldTransfer::locatePointReceivers(), LowerBoundNodalKernel::LowerBoundNodalKernel(), MooseLinearVariableFV< Real >::lowerDError(), PNGOutput::makePNG(), ReporterPointMarker::markerSetup(), SubProblem::markFamilyPRefinement(), MassMatrix::MassMatrix(), Material::Material(), MaterialRealTensorValueAuxTempl< is_ad >::MaterialRealTensorValueAuxTempl(), MaterialRealVectorValueAuxTempl< T, is_ad, is_functor >::MaterialRealVectorValueAuxTempl(), MaterialStdVectorRealGradientAux::MaterialStdVectorRealGradientAux(), Distribution::median(), FunctorRelationshipManager::mesh_reinit(), NEML2ModelExecutor::meshChanged(), MeshDiagnosticsGenerator::MeshDiagnosticsGenerator(), MeshExtruderGenerator::MeshExtruderGenerator(), MeshRepairGenerator::MeshRepairGenerator(), MFEMComplexExteriorProductAux::MFEMComplexExteriorProductAux(), MFEMComplexInnerProductAux::MFEMComplexInnerProductAux(), MFEMCrossProductAux::MFEMCrossProductAux(), MFEMEigenproblem::MFEMEigenproblem(), MFEMGeometricMultigridSolver::MFEMGeometricMultigridSolver(), MFEMInnerProductAux::MFEMInnerProductAux(), MFEMNDtoRTAux::MFEMNDtoRTAux(), MFEMSamplerBase::MFEMSamplerBase(), SetupMeshAction::modifyParamsForUseSplit(), MeshMetaDataInterface::mooseErrorInternal(), MooseLinearVariableFV< Real >::MooseLinearVariableFV(), MooseMesh::MooseMesh(), MooseObject::MooseObject(), UserObjectInterface::mooseObjectError(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MooseVariableConstMonomial::MooseVariableConstMonomial(), MoveNodeGenerator::MoveNodeGenerator(), MultiApp::MultiApp(), MultiAppTransfer::MultiAppTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), MultiAppVariableValueSamplePostprocessorTransfer::MultiAppVariableValueSamplePostprocessorTransfer(), MultiPostprocessorConvergence::MultiPostprocessorConvergence(), NearestNodeDistanceAux::NearestNodeDistanceAux(), FEProblemBase::needsPreviousNewtonIteration(), NewmarkBeta::NewmarkBeta(), NodalConstraint::NodalConstraint(), MooseVariableFV< Real >::nodalDofIndex(), MooseVariableFV< Real >::nodalDofIndexNeighbor(), MooseLinearVariableFV< Real >::nodalError(), MooseVariableFV< Real >::nodalMatrixTagValue(), NodalPatchRecoveryAuxBase::NodalPatchRecoveryAuxBase(), NodalScalarKernel::NodalScalarKernel(), MooseVariableFV< Real >::nodalValueArray(), MooseVariableFV< Real >::nodalValueOldArray(), MooseVariableFV< Real >::nodalValueOlderArray(), NodalVariableValue::NodalVariableValue(), MooseVariableFV< Real >::nodalVectorTagValue(), DistributedRectilinearMeshGenerator::nodeId(), MooseVariableFV< Real >::numberOfDofsNeighbor(), NumFailedTimeSteps::NumFailedTimeSteps(), DistributedRectilinearMeshGenerator::numNeighbors(), NumNonlinearIterations::NumNonlinearIterations(), NumVars::NumVars(), Output::onInterval(), FunctorRelationshipManager::operator()(), RelationshipManager::operator==(), ActionComponent::outerSurfaceArea(), ActionComponent::outerSurfaceBoundaries(), XDA::output(), SolutionHistory::output(), Exodus::output(), Output::Output(), AdvancedOutput::outputElementalVariables(), AdvancedOutput::outputInput(), MooseApp::outputMachineReadableData(), AdvancedOutput::outputNodalVariables(), AdvancedOutput::outputPostprocessors(), AdvancedOutput::outputReporters(), AdvancedOutput::outputScalarVariables(), Nemesis::outputSetup(), Exodus::outputSetup(), AdvancedOutput::outputSystemInformation(), Console::outputVectorPostprocessors(), AdvancedOutput::outputVectorPostprocessors(), DistributedRectilinearMeshGenerator::paritionSquarely(), PiecewiseBilinear::parse(), ParsedConvergence::ParsedConvergence(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedODEKernel::ParsedODEKernel(), MultiAppConservativeTransfer::performAdjustment(), ExplicitTimeIntegrator::performExplicitSolve(), PetscExternalPartitioner::PetscExternalPartitioner(), MooseVariableFV< Real >::phiLowerSize(), PhysicsBasedPreconditioner::PhysicsBasedPreconditioner(), EqualValueBoundaryConstraint::pickPrimaryNode(), PIDTransientControl::PIDTransientControl(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseFunction::PiecewiseFunction(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), PiecewiseMulticonstant::PiecewiseMulticonstant(), PiecewiseMultiInterpolation::PiecewiseMultiInterpolation(), PiecewiseTabularBase::PiecewiseTabularBase(), PiecewiseTabularInterface::PiecewiseTabularInterface(), ProjectSideSetOntoLevelSetGenerator::pointPairLevelSetInterception(), CutMeshByLevelSetGeneratorBase::pointPairLevelSetInterception(), SolutionUserObjectBase::pointValueGradientWrapper(), SolutionUserObjectBase::pointValueWrapper(), ReporterInterface::possiblyCheckHasReporter(), VectorPostprocessorInterface::possiblyCheckHasVectorPostprocessorByName(), LStableDirk2::postResidual(), LStableDirk3::postResidual(), ImplicitMidpoint::postResidual(), ExplicitTVDRK2::postResidual(), LStableDirk4::postResidual(), AStableDirk4::postResidual(), ExplicitRK2::postResidual(), EigenProblem::postScaleEigenVector(), VariableCondensationPreconditioner::preallocateCondensedJacobian(), ADKernelValueTempl< T >::precomputeQpJacobian(), FunctorKernel::precomputeQpResidual(), Predictor::Predictor(), TransientBase::preExecute(), MooseMesh::prepare(), MooseMesh::prepared(), ElementSubdomainModifierBase::prepareVariableForReinitialization(), FixedPointSolve::printFixedPointConvergenceReason(), MultiAppMFEMTolibMeshShapeEvaluationTransfer::projectlibMeshNodalValues(), PseudoTimestep::PseudoTimestep(), MultiApp::readCommandLineArguments(), PropertyReadFile::readData(), SolutionUserObjectBase::readExodusIIOrNemesis(), SolutionUserObjectBase::readXda(), CoarsenBlockGenerator::recursiveCoarsen(), MooseApp::recursivelyCreateExecutors(), FunctorRelationshipManager::redistribute(), MooseApp::registerRestartableData(), MooseApp::registerRestartableNameWithFilter(), Sampler::reinit(), RelativeSolutionDifferenceNorm::RelativeSolutionDifferenceNorm(), MFEMTransient::relativeSolutionDifferenceNorm(), MooseApp::removeRelationshipManager(), PhysicsBase::reportPotentiallyMissedParameters(), MFEMEigenproblem::resolveMFEMSolvers(), resolveMFEMSolvers(), MooseApp::restore(), RinglebMesh::RinglebMesh(), RinglebMeshGenerator::RinglebMeshGenerator(), MooseApp::run(), MooseApp::runInputs(), PiecewiseMultiInterpolation::sample(), ScalarComponentIC::ScalarComponentIC(), MortarScalarBase::scalarVariable(), DistributedRectilinearMeshGenerator::scaleNodalPositions(), BicubicSplineFunction::secondDerivative(), MooseVariableFV< Real >::secondPhi(), MooseVariableFV< Real >::secondPhiFace(), MooseVariableFV< Real >::secondPhiFaceNeighbor(), MooseVariableFV< Real >::secondPhiNeighbor(), FunctorRelationshipManager::set_mesh(), MooseVariableBase::setActiveTags(), DistributedRectilinearMeshGenerator::setBoundaryNames(), MooseMesh::setCoordSystem(), FEProblemBase::setCoupling(), PiecewiseBase::setData(), FileOutput::setFileBaseInternal(), MooseMesh::setGeneralAxisymmetricCoordAxes(), FEProblemSolve::setInnerSolve(), ADArrayNodalKernel::setJacobian(), MFEMPetscNonlinearSolver::SetLinearSolver(), MeshGenerator::setMeshProperty(), MooseApp::setMFEMDevice(), FVPointValueConstraint::setMyElem(), FEProblemBase::setNonlocalCouplingMatrix(), Sampler::setNumberOfCols(), Sampler::setNumberOfRandomSeeds(), Sampler::setNumberOfRows(), Exodus::setOutputDimensionInExodusWriter(), Moose::MFEM::LinearSolverBase::SetPreconditioner(), MultiAppGeneralFieldTransfer::setSolutionVectorValues(), Split::setup(), TransientMultiApp::setupApp(), Moose::PeriodicBCHelper::setupAutoPeriodicBoundaries(), Moose::PeriodicBCHelper::setupManualPeriodicBoundaries(), SetupMeshAction::setupMesh(), MooseApp::setupOptions(), TimeSequenceStepperBase::setupSequence(), TransientBase::setupTimeIntegrator(), TimePeriodBase::setupTimes(), IntegratedBCBase::shouldApply(), PhysicsBase::shouldCreateIC(), PhysicsBase::shouldCreateTimeDerivative(), PhysicsBase::shouldCreateVariable(), SideAdvectiveFluxIntegralTempl< is_ad >::SideAdvectiveFluxIntegralTempl(), SideDiffusiveFluxIntegralTempl< is_ad, Real >::SideDiffusiveFluxIntegralTempl(), SideSetsFromNormalsGenerator::SideSetsFromNormalsGenerator(), SideSetsFromPointsGenerator::SideSetsFromPointsGenerator(), SingleMatrixPreconditioner::SingleMatrixPreconditioner(), MooseVariableBase::sizeMatrixTagData(), SmoothMeshGenerator::SmoothMeshGenerator(), SolutionTimeAdaptiveDT::SolutionTimeAdaptiveDT(), SolutionUserObjectBase::SolutionUserObjectBase(), Moose::MFEM::LinearSolverBase::Solve(), ExplicitTVDRK2::solve(), ExplicitRK2::solve(), TimeIntegrator::solve(), FEProblemBase::solverSysNum(), FullSolveMultiApp::solveStep(), SpatialAverageBase::SpatialAverageBase(), UserObject::spatialPoints(), NearestPointIntegralVariablePostprocessor::spatialValue(), NearestPointAverage::spatialValue(), UserObject::spatialValue(), MeshDivisionFunctorReductionVectorPostprocessor::spatialValue(), SpiralAnnularMesh::SpiralAnnularMesh(), SpiralAnnularMeshGenerator::SpiralAnnularMeshGenerator(), MeshRepairGenerator::splitNonConvexPolygons(), WebServerControl::startServer(), StitchedMesh::StitchedMesh(), MultiAppGeometricInterpolationTransfer::subdomainIDsNode(), Constraint::subdomainSetup(), NodalUserObject::subdomainSetup(), GeneralUserObject::subdomainSetup(), MaterialBase::subdomainSetup(), FEProblemBase::swapBackMaterialsNeighbor(), DisplacedProblem::systemBaseLinear(), Console::systemInfoFlags(), FEProblemBase::systemNumForVariable(), TerminateChainControl::terminate(), Terminator::Terminator(), CutMeshByLevelSetGeneratorBase::tet4ElemCutter(), ThreadedGeneralUserObject::threadJoin(), DiscreteElementUserObject::threadJoin(), GeneralUserObject::threadJoin(), Function::timeDerivative(), TimedSubdomainModifier::TimedSubdomainModifier(), TimeExtremeValue::TimeExtremeValue(), Function::timeIntegral(), TimeIntegratedPostprocessor::TimeIntegratedPostprocessor(), MooseLinearVariableFV< Real >::timeIntegratorError(), TimeIntervalTimes::TimeIntervalTimes(), TimePeriodBase::TimePeriodBase(), VectorPostprocessorVisualizationAux::timestepSetup(), MultiAppDofCopyTransfer::transfer(), MultiAppShapeEvaluationTransfer::transferVariable(), MultiAppMFEMCopyTransfer::transferVariables(), MultiApplibMeshToMFEMShapeEvaluationTransfer::transferVariables(), MultiAppMFEMShapeEvaluationTransfer::transferVariables(), MultiAppMFEMTolibMeshShapeEvaluationTransfer::transferVariables(), TransformedPositions::TransformedPositions(), FEProblemBase::trustUserCouplingMatrix(), ParsedCurveGenerator::tSectionSpaceDefiner(), MooseVariableScalar::uDot(), MooseVariableScalar::uDotDot(), MooseVariableScalar::uDotDotOld(), FEProblemBase::uDotDotOldRequested(), MooseVariableScalar::uDotOld(), FEProblemBase::uDotOldRequested(), MooseBase::uniqueName(), Positions::unrollMultiDPositions(), ScalarKernelBase::uOld(), AuxScalarKernel::uOld(), Checkpoint::updateCheckpointFiles(), NEML2FEInterpolation::updateDofMap(), NEML2FEInterpolation::updateGradPhi(), SolutionUserObjectBase::updateInterpolationBracketingTimeIndices(), FEProblemBase::updateMaxQps(), NEML2FEInterpolation::updatePhi(), UpperBoundNodalKernel::UpperBoundNodalKernel(), NearestPointAverage::userObjectValue(), NearestPointIntegralVariablePostprocessor::userObjectValue(), BoundingBoxIC::value(), PiecewiseConstantFromCSV::value(), IntegralPreservingFunctionIC::value(), Axisymmetric2D3DSolutionFunction::value(), Function::value(), ValueRangeMarker::ValueRangeMarker(), ValueThresholdMarker::ValueThresholdMarker(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), PhysicsBase::variableExists(), MultiAppTransfer::variableIntegrityCheck(), VariableTimeIntegrationAux::VariableTimeIntegrationAux(), AddVariableAction::variableType(), VariableValueVolumeHistogram::VariableValueVolumeHistogram(), VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl(), VectorNodalBC::VectorNodalBC(), SubProblem::vectorTagName(), SubProblem::vectorTagType(), MooseParsedGradFunction::vectorValue(), MooseParsedFunction::vectorValue(), Function::vectorValue(), SubProblem::verifyVectorTags(), ActionComponent::volume(), VTKOutput::VTKOutput(), WebServerControl::WebServerControl(), MFEMMesh::writeRecoveryFiles(), MooseApp::writeRestartableMetaData(), DOFMapOutput::writeStreamToFile(), and Console::writeStreamToFile().

272  {
273  callMooseError(argumentsToString(std::forward<Args>(args)...), /* with_prefix = */ true);
274  }
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
External method for calling moose error with added object context.
Definition: MooseBase.C:105

◆ mooseErrorNonPrefixed()

template<typename... Args>
void MooseBase::mooseErrorNonPrefixed ( Args &&...  args) const
inlineinherited

Emits an error without the prefixing included in mooseError().

Definition at line 290 of file MooseBase.h.

291  {
292  callMooseError(argumentsToString(std::forward<Args>(args)...), /* with_prefix = */ false);
293  }
void callMooseError(std::string msg, const bool with_prefix, const hit::Node *node=nullptr, const bool show_trace=true) const
External method for calling moose error with added object context.
Definition: MooseBase.C:105

◆ mooseInfo()

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

Definition at line 334 of file MooseBase.h.

Referenced by SetupRecoverFileBaseAction::act(), AStableDirk4::AStableDirk4(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), MultiAppGeneralFieldKDTreeTransferBase::evaluateNearestNodeFromKDTrees(), PIDTransientControl::execute(), Executioner::Executioner(), ExplicitRK2::ExplicitRK2(), ExplicitTVDRK2::ExplicitTVDRK2(), FixedPointSolve::findTransformedSystem(), PolyLineMeshFollowingNodeSetGenerator::generate(), ManifoldSubdomainGenerator::generate(), DataFileInterface::getDataFilePath(), ImplicitMidpoint::ImplicitMidpoint(), ParsedDownSelectionPositions::initialize(), PropertyReadFile::initialize(), MultiAppGeneralFieldTransfer::initialSetup(), InversePowerMethod::InversePowerMethod(), LStableDirk2::LStableDirk2(), LStableDirk3::LStableDirk3(), LStableDirk4::LStableDirk4(), PNGOutput::makeMeshFunc(), MultiAppTransfer::mapBackWithoutCollapsing(), NonlinearEigen::NonlinearEigen(), SolutionInvalidityOutput::output(), MultiAppGeneralFieldTransfer::outputValueConflicts(), MooseBase::paramInfo(), ProjectionAux::ProjectionAux(), MFEMDataCollection::registerFields(), FEProblemBase::setRestartFile(), MooseApp::setupOptions(), SolutionUserObjectBase::SolutionUserObjectBase(), SymmetryTransformGenerator::SymmetryTransformGenerator(), TransientBase::takeStep(), TimeIntegratedPostprocessor::TimeIntegratedPostprocessor(), and TransientBase::TransientBase().

335  {
336  moose::internal::mooseInfoStream(_console, messagePrefix(true), std::forward<Args>(args)...);
337  }
void mooseInfoStream(S &oss, Args &&... args)
Definition: MooseError.h:245
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:256

◆ mooseWarning() [1/2]

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

Definition at line 73 of file SolutionInvalidInterface.h.

Referenced by CopyMeshPartitioner::_do_partition(), AddKernelAction::act(), MeshOnlyAction::act(), AddFunctionAction::act(), MaterialOutputAction::act(), CommonOutputAction::act(), addFunction(), MooseMesh::addPeriodicVariable(), BoundaryMarker::BoundaryMarker(), DistributedRectilinearMeshGenerator::buildCube(), MultiAppVariableValueSamplePostprocessorTransfer::cacheElemToPostprocessorData(), CartesianMeshGenerator::CartesianMeshGenerator(), CheckOutputAction::checkConsoleOutput(), MultiAppTransfer::checkMultiAppExecuteOn(), MeshDiagnosticsGenerator::checkNonMatchingEdges(), MeshDiagnosticsGenerator::checkPolygons(), ActionComponent::checkRequiredTasks(), PhysicsBase::checkRequiredTasks(), SampledOutput::cloneMesh(), MultiAppGeneralFieldTransfer::closestToPosition(), VariableValueElementSubdomainModifier::computeSubdomainID(), GapValueAux::computeValue(), MultiApp::createApp(), DebugResidualAux::DebugResidualAux(), MeshDiagnosticsGenerator::diagnosticsLog(), SphericalGridDivision::divisionIndex(), CartesianGridDivision::divisionIndex(), CylindricalGridDivision::divisionIndex(), ElementMaterialSampler::ElementMaterialSampler(), Postprocessor::evaluateDotWarning(), MeshDivisionFunctorReductionVectorPostprocessor::execute(), ElementQualityChecker::finalize(), FiniteDifferencePreconditioner::FiniteDifferencePreconditioner(), FixedPointSolve::FixedPointSolve(), RenumberBySubdomainGenerator::generate(), SubdomainPerElementGenerator::generate(), BSplineCurveGenerator::generate(), StitchMeshGenerator::generate(), SurfaceSubdomainsFromAllNormalsGenerator::generate(), ParsedGenerateSideset::generate(), SurfaceSubdomainsDelaunayRemesher::generate(), SurfaceMeshGeneratorBase::get2DElemNormal(), MultiAppTransfer::getAppInfo(), FunctorBinnedValuesDivision::getBinIndex(), MFEMVectorFESpace::getFECName(), PointSamplerBase::getLocalElemContainingPoint(), FEProblemBase::getMaterial(), LineValueSampler::getValue(), Terminator::handleMessage(), IndicatorMarker::IndicatorMarker(), SphericalGridDivision::initialize(), ElementGroupCentroidPositions::initialize(), CartesianGridDivision::initialize(), CylindricalGridDivision::initialize(), MFEMPointScalarCoefficientValueSampler::initialSetup(), MultiAppGeneralFieldNearestLocationTransfer::initialSetup(), MFEMVariableSamplerBase::initialSetup(), MFEMRefinementMarker::initialSetup(), BoundsBase::initialSetup(), MultiAppGeneralFieldTransfer::initialSetup(), ElementSubdomainModifierBase::initialSetup(), FEProblemBase::initialSetup(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), MaterialBase::initStatefulProperties(), LeastSquaresFit::LeastSquaresFit(), IterationAdaptiveDT::limitDTToPostprocessorValue(), PNGOutput::makePNG(), FEProblemBase::mesh(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), NewmarkBeta::NewmarkBeta(), NodalPatchRecovery::NodalPatchRecovery(), NonlocalIntegratedBC::NonlocalIntegratedBC(), NonlocalKernel::NonlocalKernel(), Output::Output(), MaterialOutputAction::outputHelper(), MultiAppGeneralFieldTransfer::outputValueConflicts(), PiecewiseConstantFromCSV::PiecewiseConstantFromCSV(), Executioner::problem(), PropertyReadFile::readData(), TestSourceStepper::rejectStep(), PhysicsBase::reportPotentiallyMissedParameters(), MaterialBase::resetQpProperties(), SecondTimeDerivativeAux::SecondTimeDerivativeAux(), MooseMesh::setCoordSystem(), SidesetAroundSubdomainUpdater::SidesetAroundSubdomainUpdater(), FEProblemBase::sizeZeroes(), TransientMultiApp::solveStep(), MeshRepairGenerator::splitNonConvexPolygons(), Tecplot::Tecplot(), TimeDerivativeAux::TimeDerivativeAux(), Checkpoint::updateCheckpointFiles(), SampledOutput::updateSample(), PiecewiseConstantFromCSV::value(), and VariableCondensationPreconditioner::VariableCondensationPreconditioner().

74  {
75  _si_moose_base.MooseBase::mooseWarning(std::forward<Args>(args)...);
76  flagSolutionWarningMultipleRegistration(_si_moose_base.name() + ": warning");
77  }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const MooseBase & _si_moose_base
The MooseBase that owns this interface.

◆ mooseWarning() [2/2]

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

Emits a warning prefixed with object name and type.

Definition at line 299 of file MooseBase.h.

Referenced by DiracKernelInfo::findPoint(), DataFileInterface::getDataFilePath(), MooseApp::loadLibraryAndDependencies(), and MooseBase::paramWarning().

300  {
301  moose::internal::mooseWarningStream(_console, messagePrefix(true), std::forward<Args>(args)...);
302  }
void mooseWarningStream(S &oss, Args &&... args)
Definition: MooseError.h:197
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::string messagePrefix(const bool hit_prefix=true) const
Definition: MooseBase.h:256

◆ mooseWarningNonPrefixed() [1/2]

template<typename... Args>
void SolutionInvalidInterface::mooseWarningNonPrefixed ( Args &&...  args) const
inlineinherited

Definition at line 80 of file SolutionInvalidInterface.h.

81  {
82  _si_moose_base.MooseBase::mooseWarningNonPrefixed(std::forward<Args>(args)...);
83  flagSolutionWarningMultipleRegistration(_si_moose_base.name() + ": warning");
84  }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const MooseBase & _si_moose_base
The MooseBase that owns this interface.

◆ mooseWarningNonPrefixed() [2/2]

template<typename... Args>
void MooseBase::mooseWarningNonPrefixed ( Args &&...  args) const
inlineinherited

Emits a warning without the prefixing included in mooseWarning().

Definition at line 308 of file MooseBase.h.

309  {
310  moose::internal::mooseWarningStream(_console, std::forward<Args>(args)...);
311  }
void mooseWarningStream(S &oss, Args &&... args)
Definition: MooseError.h:197
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.

◆ mortarData() [1/2]

const MortarInterfaceWarehouse& FEProblemBase::mortarData ( ) const
inlineinherited

Returns the mortar data object.

Definition at line 2653 of file FEProblemBase.h.

2653 { return *_mortar_data; }
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data

◆ mortarData() [2/2]

MortarInterfaceWarehouse& FEProblemBase::mortarData ( )
inlineinherited

Definition at line 2654 of file FEProblemBase.h.

2654 { return *_mortar_data; }
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data

◆ name()

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

Get the name of the class.

Returns
The name of the class

Definition at line 103 of file MooseBase.h.

Referenced by AddElementalFieldAction::act(), CopyNodalVarsAction::act(), AdaptivityAction::act(), AddTimeStepperAction::act(), CSGOnlyAction::act(), DeprecatedBlockAction::act(), SetupTimeIntegratorAction::act(), AddActionComponentAction::act(), SetupResidualDebugAction::act(), DisplayGhostingAction::act(), MaterialOutputAction::act(), CommonOutputAction::act(), AddPeriodicBCAction::act(), FEProblemBase::addAnyRedistributers(), Executioner::addAttributeReporter(), addAuxKernel(), FEProblemBase::addAuxKernel(), FEProblemBase::addAuxScalarKernel(), DisplacedProblem::addAuxVariable(), addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), PhysicsComponentInterface::addComponent(), FEProblemBase::addConstraint(), FEProblemBase::addConvergence(), FEProblemBase::addDamper(), Registry::addDataFilePath(), Registry::addDataFilePathCapability(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addDistribution(), MooseApp::addExecutor(), MooseApp::addExecutorParams(), addFESpace(), addFESpaceHierarchy(), addFunction(), FEProblemBase::addFunction(), SubProblem::addFunctor(), addFunctorMaterial(), FEProblemBase::addFunctorMaterial(), FunctorMaterial::addFunctorProperty(), FunctorMaterial::addFunctorPropertyByBlocks(), FEProblemBase::addFVBC(), FEProblemBase::addFVInitialCondition(), FEProblemBase::addFVInterfaceKernel(), FEProblemBase::addFVInterpolationMethod(), FEProblemBase::addFVKernel(), ADDGKernel::ADDGKernel(), FEProblemBase::addHDGKernel(), addImagComponentToBC(), addImagComponentToKernel(), addIndicator(), FEProblemBase::addIndicator(), addInitialCondition(), FEProblemBase::addInitialCondition(), FEProblemBase::addInterfaceKernel(), FEProblemBase::addInterfaceMaterial(), BoundaryIntegralValueConstraint::additionalROVariables(), DiffusionLHDGKernel::additionalROVariables(), ElementAndTraceScalarHDGAssemblyHelper::additionalROVariables(), addKernel(), FEProblemBase::addKernel(), FEProblemBase::addLinearFVBC(), FEProblemBase::addLinearFVKernel(), addMarker(), FEProblemBase::addMarker(), FEProblemBase::addMaterial(), FEProblemBase::addMaterialHelper(), ComponentMaterialPropertyInterface::addMaterials(), FEProblemBase::addMeshDivision(), MooseApp::addMeshGenerator(), ComponentJunction::addMeshGenerators(), CylinderComponent::addMeshGenerators(), ComponentMeshTransformHelper::addMeshGenerators(), MeshGenerator::addMeshSubgenerator(), addMFEMSolver(), Registry::addMissingDataFilePath(), FEProblemBase::addMultiApp(), FEProblemBase::addNodalKernel(), InitialConditionWarehouse::addObject(), FEProblemBase::addObject(), ComponentPhysicsInterface::addPhysics(), SubProblem::addPiecewiseByBlockLambdaFunctor(), addPostprocessor(), FEProblemBase::addPostprocessor(), InitialConditionBase::addPostprocessorDependencyHelper(), AuxKernelBase::addPostprocessorDependencyHelper(), UserObjectBase::addPostprocessorDependencyHelper(), FEProblemBase::addPredictor(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), addQuadratureFunction(), addRealComponentToBC(), addRealComponentToKernel(), Action::addRelationshipManager(), FEProblemBase::addReporter(), FEProblemBase::addSampler(), FEProblemBase::addScalarKernel(), WebServerControl::addServerActionsInternal(), FEProblemBase::addTimeIntegrator(), addTransfer(), FEProblemBase::addTransfer(), PhysicsBase::addUserObject(), FEProblemBase::addUserObject(), InitialConditionBase::addUserObjectDependencyHelper(), AuxKernelBase::addUserObjectDependencyHelper(), UserObjectBase::addUserObjectDependencyHelper(), DisplacedProblem::addVariable(), addVectorPostprocessor(), FEProblemBase::addVectorPostprocessor(), AuxKernelBase::addVectorPostprocessorDependencyHelper(), UserObjectBase::addVectorPostprocessorDependencyHelper(), MooseLinearVariableFV< Real >::adError(), Output::advancedExecuteOn(), AdvancedExtruderGenerator::AdvancedExtruderGenerator(), NEML2ModelExecutor::advanceState(), MooseVariableBase::allDofIndices(), MooseApp::appBinaryName(), MooseApp::appendMeshGenerator(), Registry::appNameFromAppPath(), MultiApp::appPostprocessorValue(), MultiApp::appProblem(), MultiApp::appProblemBase(), MultiApp::appUserObjectBase(), ArrayDGKernel::ArrayDGKernel(), ArrayParsedAux::ArrayParsedAux(), PhysicsBase::assignBlocks(), AStableDirk4::AStableDirk4(), Function::average(), MultiApp::backup(), CoarsenedPiecewiseLinear::buildCoarsenedGrid(), PiecewiseTabularInterface::buildFromFile(), PiecewiseTabularInterface::buildFromXY(), MFEMGeometricMultigridSolver::BuildMultigrid(), MooseMesh::buildNodeListFromSideList(), MultiAppVariableValueSamplePostprocessorTransfer::cacheElemToPostprocessorData(), MooseBase::callMooseError(), ChangeOverFixedPointPostprocessor::ChangeOverFixedPointPostprocessor(), ChangeOverTimePostprocessor::ChangeOverTimePostprocessor(), PhysicsBase::checkBlockRestrictionIdentical(), PhysicsBase::checkComponentType(), ParsedConvergence::checkConvergence(), DefaultNonlinearConvergence::checkConvergence(), Registry::checkDataFilePathName(), FEProblemBase::checkDependMaterialsHelper(), TaggingInterface::checkForNans(), SamplerBase::checkForStandardFieldVariableType(), ReporterTransferInterface::checkHasReporterValue(), FEProblemBase::checkICRestartError(), Moose::Kokkos::Material::checkMaterialProperty(), Material::checkMaterialProperty(), MooseApp::checkMetaDataIntegrity(), Damper::checkMinDamping(), MultiAppTransfer::checkParentAppUserObjectExecuteOn(), Checkpoint::checkpointInfo(), FEProblemBase::checkUserObjectNameCollision(), DomainUserObject::checkVariable(), BlockRestrictable::checkVariable(), Coupleable::checkWritableVar(), MooseVariableFieldBase::componentName(), CompositeFunction::CompositeFunction(), MaterialBase::computeProperties(), FEProblemBase::computeUserObjectByName(), VectorPostprocessorVisualizationAux::computeValue(), MooseBase::connectControllableParams(), ConstantPostprocessor::ConstantPostprocessor(), Coupleable::coupledName(), CommonOutputAction::create(), MultiApp::createApp(), MooseApp::createExecutors(), MeshGeneratorSystem::createMeshGeneratorOrder(), MooseApp::createRecoverablePerfGraph(), CutMeshByPlaneGenerator::CutMeshByPlaneGenerator(), DebugResidualAux::DebugResidualAux(), MaterialBase::declareADProperty(), MFEMComplexVariable::declareCoefficients(), MFEMVariable::declareCoefficients(), Moose::Kokkos::MaterialBase::declareKokkosOnDemandProperty(), Moose::Kokkos::MaterialBase::declareKokkosProperty(), MeshGenerator::declareMeshesForSubByName(), MeshGenerator::declareNullMeshName(), MaterialBase::declareProperty(), DOFMapOutput::demangle(), DerivativeSumMaterialTempl< is_ad >::DerivativeSumMaterialTempl(), MooseMesh::detectPairedSidesets(), Registry::determineDataFilePath(), DGKernel::DGKernel(), DGKernelBase::DGKernelBase(), DomainUserObject::DomainUserObject(), DumpObjectsProblem::dumpObjectHelper(), ElementDamper::ElementDamper(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), ElementMaterialSampler::ElementMaterialSampler(), ElementValueSampler::ElementValueSampler(), EigenKernel::enabled(), MooseMesh::errorIfDistributedMesh(), SolutionUserObjectBase::evalMeshFunction(), SolutionUserObjectBase::evalMeshFunctionGradient(), SolutionUserObjectBase::evalMultiValuedMeshFunction(), SolutionUserObjectBase::evalMultiValuedMeshFunctionGradient(), SideValueSampler::execute(), RestartableDataReporter::execute(), GreaterThanLessThanPostprocessor::execute(), PointValue::execute(), MultiAppNearestNodeTransfer::execute(), MultiAppProjectionTransfer::execute(), MultiAppUserObjectTransfer::execute(), WebServerControl::execute(), MultiAppGeneralFieldTransfer::execute(), ActionWarehouse::executeActionsWithAction(), Exodus::Exodus(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemBase::FEProblemBase(), NEML2ModelExecutor::fillInputs(), MultiApp::fillPositions(), MultiAppGeometricInterpolationTransfer::fillSourceInterpolationPoints(), PointSamplerBase::finalize(), ChainControl::fullControlDataName(), FunctionArrayAux::FunctionArrayAux(), FunctionDT::FunctionDT(), FunctionIC::functionName(), FVFunctionIC::functionName(), FunctorPositions::FunctorPositions(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), FVInitialConditionTempl< T >::FVInitialConditionTempl(), FVOneVarDiffusionInterface::FVOneVarDiffusionInterface(), GapValueAux::GapValueAux(), MooseServer::gatherDocumentSymbols(), BoundaryDeletionGenerator::generate(), UniqueExtraIDMeshGenerator::generate(), RenameBoundaryGenerator::generate(), RenumberBySubdomainGenerator::generate(), RenameBlockGenerator::generate(), ParsedSubdomainGeneratorBase::generate(), SideSetsFromNodeSetsGenerator::generate(), StitchBoundaryMeshGenerator::generate(), StitchMeshGenerator::generate(), SubdomainsFromPartitionerGenerator::generate(), BreakMeshByBlockGenerator::generate(), GeneratedMeshGenerator::generate(), ParsedExtraElementIDGenerator::generate(), ManifoldSubdomainGenerator::generate(), SubdomainBoundingBoxGenerator::generate(), MeshGenerator::generateInternal(), MeshGenerator::generateInternalCSG(), InterfaceMaterial::getADMaterialProperty(), Material::getADMaterialProperty(), MultiAppTransfer::getAppInfo(), MooseMesh::getBoundaryString(), MultiApp::getBoundingBox(), MooseBase::getCheckedPointerParam(), MooseApp::getCheckpointDirectories(), getComplexGridFunction(), Control::getControllableParameterByName(), Control::getControllableValue(), Control::getControllableValueByName(), FEProblemBase::getConvergence(), MeshGenerator::getCSGBase(), MeshGenerator::getCSGBasesByName(), Registry::getDataFilePath(), UserObjectBase::getDependObjects(), DistributionInterface::getDistribution(), FEProblemBase::getDistribution(), DistributionInterface::getDistributionByName(), ElementUOProvider::getElementalValueLong(), ElementUOProvider::getElementalValueReal(), MultiApp::getExecutioner(), MooseApp::getExecutor(), FEProblemBase::getExecutor(), OutputWarehouse::getFileNumbers(), FEProblemBase::getFunction(), SubProblem::getFunctor(), FEProblemBase::getFVAdvectedInterpolationMethod(), FEProblemBase::getFVFaceInterpolationMethod(), FEProblemBase::getFVInterpolationMethod(), NodalPatchRecovery::getGenericMaterialProperty(), InterfaceMaterial::getGenericMaterialProperty(), AuxKernelTempl< Real >::getGenericMaterialProperty(), Material::getGenericMaterialProperty(), InterfaceMaterial::getGenericNeighborMaterialProperty(), InterfaceMaterial::getGenericNeighborMaterialPropertyByName(), Material::getGenericOptionalMaterialProperty(), MaterialBase::getGenericZeroMaterialProperty(), getGridFunction(), FEProblemBase::getKokkosFunction(), FEProblemBase::getKokkosUserObject(), SolutionUserObjectBase::getLocalVarIndex(), Marker::getMarkerValue(), Material::getMaterial(), FEProblemBase::getMaterial(), Material::getMaterialByName(), NodalPatchRecovery::getMaterialProperty(), InterfaceMaterial::getMaterialProperty(), AuxKernelTempl< Real >::getMaterialProperty(), Material::getMaterialProperty(), SubProblem::getMaterialPropertyBlockNames(), SubProblem::getMaterialPropertyBoundaryNames(), NodalPatchRecovery::getMaterialPropertyOld(), AuxKernelTempl< Real >::getMaterialPropertyOld(), InterfaceMaterial::getMaterialPropertyOld(), Material::getMaterialPropertyOld(), NodalPatchRecovery::getMaterialPropertyOlder(), AuxKernelTempl< Real >::getMaterialPropertyOlder(), InterfaceMaterial::getMaterialPropertyOlder(), Material::getMaterialPropertyOlder(), MFEMObject::getMatrixCoefficient(), MFEMObject::getMatrixCoefficientByName(), MeshGenerator::getMesh(), FEProblemBase::getMeshDivision(), MeshGenerator::getMeshesByName(), MooseApp::getMeshGenerator(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), getMFEMObject(), ActionWarehouse::getMooseAppName(), NEML2FEInterpolation::getMOOSEVariable(), MultiAppTransfer::getMultiApp(), InterfaceMaterial::getNeighborADMaterialProperty(), InterfaceMaterial::getNeighborMaterialProperty(), InterfaceMaterial::getNeighborMaterialPropertyOld(), InterfaceMaterial::getNeighborMaterialPropertyOlder(), MooseServer::getObjectParameters(), Material::getOptionalADMaterialProperty(), Material::getOptionalMaterialProperty(), Material::getOptionalMaterialPropertyOld(), Material::getOptionalMaterialPropertyOlder(), OutputWarehouse::getOutput(), MooseBase::getParam(), FEProblemBase::getPositionsObject(), FEProblemBase::getPostprocessorValueByName(), ComponentMaterialPropertyInterface::getPropertyValue(), ReporterData::getReporterInfo(), MFEMExecutedObject::getRequestedItems(), MooseApp::getRestartableDataMap(), MooseApp::getRestartableDataMapName(), MooseApp::getRestartableMetaData(), FEProblemBase::getSampler(), MFEMObject::getScalarCoefficient(), MFEMObject::getScalarCoefficientByName(), TimedSubdomainModifier::getSubdomainIDAndCheck(), MFEMExecutedObject::getSuppliedItems(), TransientBase::getTimeStepperName(), ProjectedStatefulMaterialStorageAction::getTypeEnum(), FEProblemBase::getUserObject(), FEProblemBase::getUserObjectBase(), MFEMObject::getVectorCoefficient(), MFEMObject::getVectorCoefficientByName(), Terminator::handleMessage(), Control::hasControllableParameterByName(), FEProblemBase::hasConvergence(), FEProblemBase::hasDistribution(), FEProblemBase::hasFunction(), SubProblem::hasFunctor(), SubProblem::hasFunctorWithType(), FEProblemBase::hasFVInterpolationMethod(), MooseApp::hasMeshGenerator(), hasMFEMObject(), AdvancedOutput::hasOutputHelper(), FEProblemBase::hasPostprocessor(), FEProblemBase::hasPostprocessorValueByName(), MooseApp::hasRelationshipManager(), MooseApp::hasRestartableDataMap(), MooseApp::hasRestartableMetaData(), FEProblemBase::hasUserObject(), NEML2Action::inferMOOSEIOType(), IterationAdaptiveDT::init(), AddVariableAction::init(), AdvancedOutput::init(), AdvancedOutput::initAvailableLists(), AdvancedOutput::initExecutionTypes(), AttribName::initFrom(), NestedDivision::initialize(), TransformedPositions::initialize(), BoundaryRestrictable::initializeBoundaryRestrictable(), JSONOutput::initialSetup(), BoundaryLinearFVFluxIntegral::initialSetup(), SideFVFluxBCIntegral::initialSetup(), SolutionScalarAux::initialSetup(), MultiAppProjectionTransfer::initialSetup(), MultiAppGeneralFieldFunctorTransfer::initialSetup(), NodalVariableValue::initialSetup(), Console::initialSetup(), AuxKernelBase::initialSetup(), SolutionUserObjectBase::initialSetup(), AdvancedOutput::initOutputList(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), MaterialBase::initStatefulProperties(), Function::integral(), InterfaceKernelTempl< T >::InterfaceKernelTempl(), MultiAppGeometricInterpolationTransfer::interpolateTargetPoints(), MeshGenerator::isChildMeshGenerator(), DerivativeMaterialInterface< JvarMapKernelInterface< GenericKernelGrad< is_ad > > >::isNotObjectVariable(), MeshGenerator::isNullMeshName(), MooseBase::isParamSetByUser(), MooseBase::isParamValid(), MeshGenerator::isParentMeshGenerator(), LinearCombinationFunction::LinearCombinationFunction(), FEProblemBase::logAdd(), MooseLinearVariableFV< Real >::lowerDError(), Marker::Marker(), MaterialBase::markMatPropRequested(), Material::Material(), MaterialDerivativeTestKernelBase< Real >::MaterialDerivativeTestKernelBase(), Distribution::median(), MemoryUsageReporter::MemoryUsageReporter(), NEML2ModelExecutor::meshChanged(), MeshGenerator::meshPropertyPrefix(), MooseBase::messagePrefix(), MFEMGeometricMultigridSolver::MFEMGeometricMultigridSolver(), MFEMScalarQuadratureFunction::MFEMScalarQuadratureFunction(), MFEMVectorQuadratureFunction::MFEMVectorQuadratureFunction(), OutputWarehouse::mooseConsole(), SolutionInvalidInterface::mooseDeprecated(), MooseVariableBase::MooseVariableBase(), MooseVariableInterface< Real >::MooseVariableInterface(), SolutionInvalidInterface::mooseWarning(), SolutionInvalidInterface::mooseWarningNonPrefixed(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), NEML2PreKernel::NEML2PreKernel(), NodalDamper::NodalDamper(), MooseLinearVariableFV< Real >::nodalError(), NodalPatchRecoveryAuxBase::NodalPatchRecoveryAuxBase(), NodalValueSampler::NodalValueSampler(), Registry::objData(), MeshGenerator::Comparator::operator()(), ProgressOutput::output(), DOFMapOutput::output(), Output::Output(), AdvancedOutput::outputElementalVariables(), ConsoleUtils::outputExecutionInformation(), MaterialOutputAction::outputHelper(), AdvancedOutput::outputInput(), AdvancedOutput::outputNodalVariables(), Nemesis::outputPostprocessors(), Exodus::outputPostprocessors(), AdvancedOutput::outputPostprocessors(), TableOutput::outputReporter(), AdvancedOutput::outputReporters(), AdvancedOutput::outputScalarVariables(), AdvancedOutput::outputSystemInformation(), AdvancedOutput::outputVectorPostprocessors(), SolutionInvalidInterface::paramWarning(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedODEKernel::ParsedODEKernel(), ComponentPhysicsInterface::physicsExists(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseByBlockFunctorMaterialTempl< T >::PiecewiseByBlockFunctorMaterialTempl(), PiecewiseFunction::PiecewiseFunction(), MooseApp::possiblyLoadRestartableMetaData(), MFEMExecutedObject::postprocessorDependencyKey(), PhysicsBase::prefix(), MooseMesh::prepare(), BlockRestrictionDebugOutput::printBlockRestrictionGroups(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), BlockRestrictionDebugOutput::printBoundaryRestrictionGroups(), PerfGraphLivePrint::printStats(), FEProblemBase::projectInitialConditionOnCustomRange(), MooseBase::queryParam(), MultiApp::readCommandLineArguments(), Receiver::Receiver(), Executor::Result::record(), AppFactory::reg(), Registry::registerObjectsTo(), FEProblemBase::registerRandomInterface(), MooseApp::registerRestartableDataMapName(), MooseApp::registerRestartableNameWithFilter(), MaterialBase::resetQpProperties(), MultiApp::restore(), ScalarComponentIC::ScalarComponentIC(), MultiApp::setAppOutputFileBase(), FEProblemBase::setAuxKernelParamsAndLog(), MooseMesh::setBoundaryName(), Control::setControllableValue(), Control::setControllableValueByName(), OutputWarehouse::setFileNumbers(), FEProblemBase::setPostprocessorValueByName(), FEProblemBase::setResidualObjectParamsAndLog(), MooseMesh::setSubdomainName(), SurfaceMeshGeneratorBase::setup(), NodeSetsGeneratorBase::setup(), Split::setup(), SideSetsGeneratorBase::setup(), TransientMultiApp::setupApp(), NEML2Action::setupOutputMappings(), FullSolveMultiApp::showStatusMessage(), SideSetExtruderGenerator::SideSetExtruderGenerator(), TransientMultiApp::solveStep(), UserObject::spatialValue(), StitchedMesh::StitchedMesh(), SubProblem::storeBoundaryDelayedCheckMatProp(), SubProblem::storeBoundaryMatPropName(), MaterialBase::storeBoundaryZeroMatProp(), SubProblem::storeBoundaryZeroMatProp(), SubProblem::storeSubdomainDelayedCheckMatProp(), SubProblem::storeSubdomainMatPropName(), MaterialBase::storeSubdomainZeroMatProp(), SubProblem::storeSubdomainZeroMatProp(), ConstraintWarehouse::subdomainsCovered(), MaterialBase::subdomainSetup(), SumPostprocessor::SumPostprocessor(), MFEMPostprocessor::suppliedPostprocessorName(), MFEMVectorPostprocessor::suppliedVectorPostprocessorName(), NEML2FEInterpolation::syncWithMainThread(), TaggingInterface::TaggingInterface(), MooseLinearVariableFV< Real >::timeIntegratorError(), VectorPostprocessorVisualizationAux::timestepSetup(), ElementSubdomainModifierBase::timestepSetup(), to_json(), MultiAppDofCopyTransfer::transfer(), MultiAppShapeEvaluationTransfer::transferVariable(), MultiAppMFEMCopyTransfer::transferVariables(), MultiAppMFEMShapeEvaluationTransfer::transferVariables(), TransientMultiApp::TransientMultiApp(), MooseServer::traverseParseTreeAndFillSymbols(), MooseBase::typeAndName(), MooseBase::uniqueParameterName(), FVQpFluxBC::uOnGhost(), FVQpFluxBC::uOnUSub(), UserObjectBase::UserObjectBase(), UserObjectInterface::userObjectName(), ParsedAux::validateGenericVectorNames(), MFEMExecutedObject::variableDependencyKey(), PhysicsBase::variableExists(), MultiAppTransfer::variableIntegrityCheck(), VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl(), MFEMExecutedObject::vectorPostprocessorDependencyKey(), Convergence::verboseOutput(), AdvancedOutput::wantOutput(), Coupleable::writableCoupledValue(), Coupleable::writableVariable(), Console::write(), and MooseApp::writeRestartableMetaData().

104  {
105  mooseAssert(_name.size(), "Empty name");
106  return _name;
107  }
const std::string & _name
The name of this class.
Definition: MooseBase.h:381

◆ needBoundaryMaterialOnSide()

bool FEProblemBase::needBoundaryMaterialOnSide ( BoundaryID  bnd_id,
const THREAD_ID  tid 
)
inherited

These methods are used to determine whether stateful material properties need to be stored on internal sides.

There are five situations where this may be the case: 1) DGKernels 2) IntegratedBCs 3)InternalSideUserObjects 4)ElementalAuxBCs 5)InterfaceUserObjects

Method 1:

Parameters
bnd_idthe boundary id for which to see if stateful material properties need to be stored
tidthe THREAD_ID of the caller
Returns
Boolean indicating whether material properties need to be stored

Method 2:

Parameters
subdomain_idthe subdomain id for which to see if stateful material properties need to be stored
tidthe THREAD_ID of the caller
Returns
Boolean indicating whether material properties need to be stored

Definition at line 9308 of file FEProblemBase.C.

Referenced by ComputeMaterialsObjectThread::onBoundary(), ProjectMaterialProperties::onBoundary(), FEProblemBase::reinitMaterialsBoundary(), FEProblemBase::reinitMaterialsFaceOnBoundary(), and FEProblemBase::reinitMaterialsNeighborOnBoundary().

9309 {
9310  if (_bnd_mat_side_cache[tid].find(bnd_id) == _bnd_mat_side_cache[tid].end())
9311  {
9312  auto & bnd_mat_side_cache = _bnd_mat_side_cache[tid][bnd_id];
9313  bnd_mat_side_cache = false;
9314 
9315  // Check systems
9316  if (_aux->needMaterialOnSide(bnd_id))
9317  {
9318  bnd_mat_side_cache = true;
9319  return true;
9320  }
9321  for (auto & nl : _nl)
9322  if (nl->needBoundaryMaterialOnSide(bnd_id, tid))
9323  {
9324  bnd_mat_side_cache = true;
9325  return true;
9326  }
9327 
9328  // TODO: these objects should be checked for whether they actually consume materials
9329  // NOTE: InterfaceUO can use use boundary properties too
9330  if (theWarehouse()
9331  .query()
9332  .condition<AttribThread>(tid)
9333  .condition<AttribInterfaces>(Interfaces::SideUserObject | Interfaces::DomainUserObject |
9335  .condition<AttribBoundaries>(bnd_id)
9336  .count() > 0)
9337  {
9338  bnd_mat_side_cache = true;
9339  return true;
9340  }
9341  }
9342 
9343  return _bnd_mat_side_cache[tid][bnd_id];
9344 }
KOKKOS_INLINE_FUNCTION const T * find(const T &target, const T *const begin, const T *const end)
Find a value in an array.
Definition: KokkosUtils.h:40
std::vector< std::unordered_map< BoundaryID, bool > > _bnd_mat_side_cache
Cache for calculating materials on side.
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
TheWarehouse & theWarehouse() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
AttribBoundaries tracks all boundary IDs associated with an object.
Definition: Attributes.h:189
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ needFV()

virtual void FEProblemBase::needFV ( )
inlineoverridevirtualinherited

marks this problem as including/needing finite volume functionality.

Implements SubProblem.

Definition at line 2918 of file FEProblemBase.h.

Referenced by DiffusionFV::initializePhysicsAdditional(), and DisplacedProblem::needFV().

2918 { _have_fv = true; }
bool _have_fv
Whether we are performing some calculations with finite volume discretizations.

◆ needInterfaceMaterialOnSide()

bool FEProblemBase::needInterfaceMaterialOnSide ( BoundaryID  bnd_id,
const THREAD_ID  tid 
)
inherited

Definition at line 9347 of file FEProblemBase.C.

Referenced by ComputeMaterialsObjectThread::onInterface(), FEProblemBase::reinitMaterialsFaceOnBoundary(), FEProblemBase::reinitMaterialsInterface(), and FEProblemBase::reinitMaterialsNeighborOnBoundary().

9348 {
9349  if (_interface_mat_side_cache[tid].find(bnd_id) == _interface_mat_side_cache[tid].end())
9350  {
9351  auto & interface_mat_side_cache = _interface_mat_side_cache[tid][bnd_id];
9352  interface_mat_side_cache = false;
9353 
9354  // Aux-system has not needed interface materials so far
9355  for (auto & nl : _nl)
9356  if (nl->needInterfaceMaterialOnSide(bnd_id, tid))
9357  {
9358  interface_mat_side_cache = true;
9359  return true;
9360  }
9361 
9362  // TODO: these objects should be checked for whether they actually consume materials
9363  if (theWarehouse()
9364  .query()
9365  .condition<AttribThread>(tid)
9366  .condition<AttribInterfaces>(Interfaces::InterfaceUserObject |
9368  .condition<AttribBoundaries>(bnd_id)
9369  .count() > 0)
9370  {
9371  interface_mat_side_cache = true;
9372  return true;
9373  }
9374  else if (_interface_materials.hasActiveBoundaryObjects(bnd_id, tid))
9375  {
9376  interface_mat_side_cache = true;
9377  return true;
9378  }
9379  }
9380  return _interface_mat_side_cache[tid][bnd_id];
9381 }
KOKKOS_INLINE_FUNCTION const T * find(const T &target, const T *const begin, const T *const end)
Find a value in an array.
Definition: KokkosUtils.h:40
MaterialWarehouse _interface_materials
bool hasActiveBoundaryObjects(THREAD_ID tid=0) const
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
TheWarehouse & theWarehouse() const
AttribBoundaries tracks all boundary IDs associated with an object.
Definition: Attributes.h:189
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285
std::vector< std::unordered_map< BoundaryID, bool > > _interface_mat_side_cache
Cache for calculating materials on interface.

◆ needInternalNeighborSideMaterial()

bool FEProblemBase::needInternalNeighborSideMaterial ( SubdomainID  subdomain_id,
const THREAD_ID  tid 
)
inherited

Definition at line 9384 of file FEProblemBase.C.

Referenced by FEProblemBase::reinitMaterialsFaceOnBoundary(), FEProblemBase::reinitMaterialsNeighborOnBoundary(), ComputeMaterialsObjectThread::subdomainChanged(), and ProjectMaterialProperties::subdomainChanged().

9385 {
9386  if (_block_mat_side_cache[tid].find(subdomain_id) == _block_mat_side_cache[tid].end())
9387  {
9388  _block_mat_side_cache[tid][subdomain_id] = false;
9389 
9390  for (auto & nl : _nl)
9391  if (nl->needInternalNeighborSideMaterial(subdomain_id, tid))
9392  {
9393  _block_mat_side_cache[tid][subdomain_id] = true;
9394  return true;
9395  }
9396 
9397  // TODO: these objects should be checked for whether they actually consume materials
9398  if (theWarehouse()
9399  .query()
9400  .condition<AttribThread>(tid)
9401  .condition<AttribInterfaces>(Interfaces::InternalSideUserObject |
9403  .condition<AttribSubdomains>(subdomain_id)
9404  .count() > 0)
9405  {
9406  _block_mat_side_cache[tid][subdomain_id] = true;
9407  return true;
9408  }
9409  }
9410 
9411  return _block_mat_side_cache[tid][subdomain_id];
9412 }
KOKKOS_INLINE_FUNCTION const T * find(const T &target, const T *const begin, const T *const end)
Find a value in an array.
Definition: KokkosUtils.h:40
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
TheWarehouse & theWarehouse() const
std::vector< std::unordered_map< SubdomainID, bool > > _block_mat_side_cache
Cache for calculating materials on side.
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285

◆ needSolutionState()

void FEProblemBase::needSolutionState ( unsigned int  oldest_needed,
Moose::SolutionIterationType  iteration_type 
)
inherited

Declare that we need up to old (1) or older (2) solution states for a given type of iteration.

Parameters
oldest_neededoldest solution state needed
iteration_typethe type of iteration for which old/older states are needed

Definition at line 756 of file FEProblemBase.C.

Referenced by FEProblemBase::createTagSolutions().

757 {
758  for (auto & sys : _solver_systems)
759  sys->needSolutionState(state, iteration_type);
760  _aux->needSolutionState(state, iteration_type);
761 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ needsPreviousMultiAppFixedPointIterationAuxiliary() [1/2]

void FEProblemBase::needsPreviousMultiAppFixedPointIterationAuxiliary ( bool  state)
inherited

Set a flag that indicated that user required values for the previous multiapp fixed point iterate for the auxiliary system.

Definition at line 9443 of file FEProblemBase.C.

Referenced by FunctorChangeFunctorMaterialTempl< is_ad >::FunctorChangeFunctorMaterialTempl(), and FixedPointSolve::initialSetup().

9444 {
9446 }
bool _previous_multiapp_fp_aux_solution_required
Indicates we need to save the previous multiapp fixed-point iteration auxiliary variable values...

◆ needsPreviousMultiAppFixedPointIterationAuxiliary() [2/2]

bool FEProblemBase::needsPreviousMultiAppFixedPointIterationAuxiliary ( ) const
inherited

Check to see whether we need to compute the variable values of the previous multiapp fixed point iteration for the auxiliary system.

Returns
true if the user required values of the previous multiapp fixed point iteration from the auxiliary system

Definition at line 9449 of file FEProblemBase.C.

9450 {
9452 }
bool _previous_multiapp_fp_aux_solution_required
Indicates we need to save the previous multiapp fixed-point iteration auxiliary variable values...

◆ needsPreviousMultiAppFixedPointIterationSolution() [1/2]

void FEProblemBase::needsPreviousMultiAppFixedPointIterationSolution ( bool  needed,
const unsigned int  solver_sys_num 
)
inherited

Set a flag that indicated that user required values for the previous multiapp fixed point iterate for the solver systems (not auxiliary)

Parameters
neededthe value that should be set to the flag
solver_sys_numthe index of the solver system for which the previous iteration is needed

Definition at line 9429 of file FEProblemBase.C.

Referenced by FunctorChangeFunctorMaterialTempl< is_ad >::FunctorChangeFunctorMaterialTempl(), and FixedPointSolve::initialSetup().

9431 {
9432  _previous_multiapp_fp_nl_solution_required[solver_sys_num] = needed;
9433 }
std::vector< bool > _previous_multiapp_fp_nl_solution_required
Indicates we need to save the previous multiapp fixed-point iteration solver variable values...

◆ needsPreviousMultiAppFixedPointIterationSolution() [2/2]

bool FEProblemBase::needsPreviousMultiAppFixedPointIterationSolution ( const unsigned int  solver_sys_num) const
inherited

Check to see whether we need to compute the variable values of the previous multiapp fixed point iteration for the solver systems (not auxiliary)

Parameters
solver_sys_numthe index of the solver system for which the previous iteration is needed
Returns
true if the user required values of the previous multiapp fixed point iteration

Definition at line 9436 of file FEProblemBase.C.

9438 {
9439  return _previous_multiapp_fp_nl_solution_required[solver_sys_num];
9440 }
std::vector< bool > _previous_multiapp_fp_nl_solution_required
Indicates we need to save the previous multiapp fixed-point iteration solver variable values...

◆ needsPreviousNewtonIteration() [1/2]

void FEProblemBase::needsPreviousNewtonIteration ( bool  state)
inherited

Set a flag that indicated that user required values for the previous Newton iterate.

Definition at line 9421 of file FEProblemBase.C.

Referenced by Coupleable::coupledGradientPreviousNL(), Coupleable::coupledNodalValuePreviousNL(), Coupleable::coupledSecondPreviousNL(), Coupleable::coupledValuePreviousNL(), and NonlinearSystem::solve().

9422 {
9424  mooseError("Previous nonlinear solution is required but not added through "
9425  "Problem/previous_nl_solution_required=true");
9426 }
virtual bool vectorTagExists(const TagID tag_id) const
Check to see if a particular Tag exists.
Definition: SubProblem.h:201
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
const TagName PREVIOUS_NL_SOLUTION_TAG
Definition: MooseTypes.C:28

◆ needsPreviousNewtonIteration() [2/2]

bool FEProblemBase::needsPreviousNewtonIteration ( ) const
inherited

Check to see whether we need to compute the variable values of the previous Newton iterate.

Returns
true if the user required values of the previous Newton iterate

Definition at line 9415 of file FEProblemBase.C.

9416 {
9418 }
virtual bool vectorTagExists(const TagID tag_id) const
Check to see if a particular Tag exists.
Definition: SubProblem.h:201
const TagName PREVIOUS_NL_SOLUTION_TAG
Definition: MooseTypes.C:28

◆ needToAddDefaultMultiAppFixedPointConvergence()

bool FEProblemBase::needToAddDefaultMultiAppFixedPointConvergence ( ) const
inlineinherited

Returns true if the problem needs to add the default fixed point convergence.

Definition at line 746 of file FEProblemBase.h.

747  {
749  }
bool _need_to_add_default_multiapp_fixed_point_convergence
Flag that the problem needs to add the default fixed point convergence.

◆ needToAddDefaultNonlinearConvergence()

bool FEProblemBase::needToAddDefaultNonlinearConvergence ( ) const
inlineinherited

Returns true if the problem needs to add the default nonlinear convergence.

Definition at line 741 of file FEProblemBase.h.

742  {
744  }
bool _need_to_add_default_nonlinear_convergence
Flag that the problem needs to add the default nonlinear convergence.

◆ needToAddDefaultSteadyStateConvergence()

bool FEProblemBase::needToAddDefaultSteadyStateConvergence ( ) const
inlineinherited

Returns true if the problem needs to add the default steady-state detection convergence.

Definition at line 751 of file FEProblemBase.h.

752  {
754  }
bool _need_to_add_default_steady_state_convergence
Flag that the problem needs to add the default steady convergence.

◆ neighborSubdomainSetup()

void FEProblemBase::neighborSubdomainSetup ( SubdomainID  subdomain,
const THREAD_ID  tid 
)
virtualinherited

Definition at line 2629 of file FEProblemBase.C.

Referenced by ThreadedFaceLoop< RangeType >::neighborSubdomainChanged().

2630 {
2631  _all_materials.neighborSubdomainSetup(subdomain, tid);
2632 }
virtual void neighborSubdomainSetup(THREAD_ID tid=0) const
MaterialWarehouse _all_materials

◆ newAssemblyArray()

void FEProblemBase::newAssemblyArray ( std::vector< std::shared_ptr< SolverSystem >> &  solver_systems)
virtualinherited

Definition at line 775 of file FEProblemBase.C.

Referenced by DumpObjectsProblem::DumpObjectsProblem(), EigenProblem::EigenProblem(), ExternalProblem::ExternalProblem(), and FEProblem::FEProblem().

776 {
777  unsigned int n_threads = libMesh::n_threads();
778 
779  _assembly.resize(n_threads);
780  for (const auto i : make_range(n_threads))
781  {
782  _assembly[i].resize(solver_systems.size());
783  for (const auto j : index_range(solver_systems))
784  _assembly[i][j] = std::make_unique<Assembly>(*solver_systems[j], i);
785  }
786 }
unsigned int n_threads()
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
IntRange< T > make_range(T beg, T end)
auto index_range(const T &sizable)

◆ nlConverged()

bool SubProblem::nlConverged ( const unsigned int  nl_sys_num)
virtualinherited
Returns
whether the given nonlinear system nl_sys_num is converged.

Definition at line 717 of file SubProblem.C.

718 {
719  mooseAssert(nl_sys_num < numNonlinearSystems(),
720  "The nonlinear system number is higher than the number of systems we have!");
721  return solverSystemConverged(nl_sys_num);
722 }
virtual std::size_t numNonlinearSystems() const =0
virtual bool solverSystemConverged(const unsigned int sys_num)
Definition: SubProblem.h:100

◆ nLinearIterations()

unsigned int FEProblemBase::nLinearIterations ( const unsigned int  nl_sys_num) const
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 7140 of file FEProblemBase.C.

Referenced by PiecewiseLinearFromVectorPostprocessor::valueInternal().

7141 {
7142  return _nl[nl_sys_num]->nLinearIterations();
7143 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ nlSysNum()

unsigned int FEProblemBase::nlSysNum ( const NonlinearSystemName &  nl_sys_name) const
overridevirtualinherited
Returns
the nonlinear system number corresponding to the provided nl_sys_name

Implements SubProblem.

Definition at line 6870 of file FEProblemBase.C.

Referenced by DisplacedProblem::nlSysNum().

6871 {
6872  std::istringstream ss(nl_sys_name);
6873  unsigned int nl_sys_num;
6874  if (!(ss >> nl_sys_num) || !ss.eof())
6875  nl_sys_num = libmesh_map_find(_nl_sys_name_to_num, nl_sys_name);
6876 
6877  return nl_sys_num;
6878 }
std::map< NonlinearSystemName, unsigned int > _nl_sys_name_to_num
Map from nonlinear system name to number.

◆ nNonlinearIterations()

unsigned int FEProblemBase::nNonlinearIterations ( const unsigned int  nl_sys_num) const
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 7134 of file FEProblemBase.C.

Referenced by PiecewiseLinearFromVectorPostprocessor::valueInternal().

7135 {
7136  return _nl[nl_sys_num]->nNonlinearIterations();
7137 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ nonlocalCouplingEntries()

std::vector< std::pair< MooseVariableFieldBase *, MooseVariableFieldBase * > > & FEProblemBase::nonlocalCouplingEntries ( const THREAD_ID  tid,
const unsigned int  nl_sys_num 
)
inherited

Definition at line 6722 of file FEProblemBase.C.

Referenced by ComputeFullJacobianThread::computeOnBoundary(), and ComputeFullJacobianThread::computeOnElement().

6723 {
6724  return _assembly[tid][nl_sys]->nonlocalCouplingEntries();
6725 }
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.

◆ nonlocalCouplingMatrix()

const libMesh::CouplingMatrix & FEProblemBase::nonlocalCouplingMatrix ( const unsigned  i) const
overridevirtualinherited
Returns
the nonlocal coupling matrix for the i'th nonlinear system

Implements SubProblem.

Definition at line 10070 of file FEProblemBase.C.

Referenced by DisplacedProblem::nonlocalCouplingMatrix().

10071 {
10072  return _nonlocal_cm[i];
10073 }
std::vector< libMesh::CouplingMatrix > _nonlocal_cm
nonlocal coupling matrix

◆ notifyWhenMeshChanges()

void FEProblemBase::notifyWhenMeshChanges ( MeshChangedInterface mci)
inherited

Register an object that derives from MeshChangedInterface to be notified when the mesh changes.

Definition at line 8841 of file FEProblemBase.C.

Referenced by MeshChangedInterface::MeshChangedInterface().

8842 {
8843  _notify_when_mesh_changes.push_back(mci);
8844 }
std::vector< MeshChangedInterface * > _notify_when_mesh_changes
Objects to be notified when the mesh changes.

◆ notifyWhenMeshDisplaces()

void FEProblemBase::notifyWhenMeshDisplaces ( MeshDisplacedInterface mdi)
inherited

Register an object that derives from MeshDisplacedInterface to be notified when the displaced mesh gets updated.

Definition at line 8847 of file FEProblemBase.C.

Referenced by MeshDisplacedInterface::MeshDisplacedInterface().

8848 {
8849  _notify_when_mesh_displaces.push_back(mdi);
8850 }
std::vector< MeshDisplacedInterface * > _notify_when_mesh_displaces
Objects to be notified when the mesh displaces.

◆ numGridSteps()

void FEProblemBase::numGridSteps ( unsigned int  num_grid_steps)
inlineinherited

Set the number of steps in a grid sequences.

Definition at line 2675 of file FEProblemBase.h.

Referenced by FEProblemSolve::FEProblemSolve().

2675 { _num_grid_steps = num_grid_steps; }
unsigned int _num_grid_steps
Number of steps in a grid sequence.

◆ numLinearSystems()

virtual std::size_t FEProblemBase::numLinearSystems ( ) const
inlineoverridevirtualinherited

◆ numMatrixTags()

virtual unsigned int SubProblem::numMatrixTags ( ) const
inlinevirtualinherited

◆ numNonlinearSystems()

virtual std::size_t FEProblemBase::numNonlinearSystems ( ) const
inlineoverridevirtualinherited

◆ numSolverSystems()

virtual std::size_t FEProblemBase::numSolverSystems ( ) const
inlineoverridevirtualinherited

◆ numVectorTags()

unsigned int SubProblem::numVectorTags ( const Moose::VectorTagType  type = Moose::VECTOR_TAG_ANY) const
virtualinherited

The total number of tags, which can be limited to the tag type.

Reimplemented in DisplacedProblem.

Definition at line 196 of file SubProblem.C.

Referenced by NonlinearSystemBase::computeNodalBCsResidual(), NonlinearSystemBase::computeResidualInternal(), ComputeResidualThread::determineObjectWarehouses(), MooseVariableDataBase< OutputType >::MooseVariableDataBase(), MooseVariableScalar::MooseVariableScalar(), DisplacedProblem::numVectorTags(), ComputeNodalKernelBcsThread::pre(), and ComputeNodalKernelsThread::pre().

197 {
198  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
199 
200  return getVectorTags(type).size();
201 }
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
std::vector< VectorTag > getVectorTags(const std::set< TagID > &tag_ids) const
Definition: SubProblem.C:173

◆ objectExecuteHelper()

template<typename T >
void FEProblemBase::objectExecuteHelper ( const std::vector< T *> &  objects)
staticinherited

Definition at line 3684 of file FEProblemBase.h.

3685 {
3686  for (T * obj_ptr : objects)
3687  obj_ptr->execute();
3688 }

◆ objectSetupHelper()

template<typename T >
void FEProblemBase::objectSetupHelper ( const std::vector< T *> &  objects,
const ExecFlagType exec_flag 
)
staticinherited

Helpers for calling the necessary setup/execute functions for the supplied objects.

Definition at line 3650 of file FEProblemBase.h.

3651 {
3652  if (exec_flag == EXEC_INITIAL)
3653  {
3654  for (T * obj_ptr : objects)
3655  obj_ptr->initialSetup();
3656  }
3657 
3658  else if (exec_flag == EXEC_TIMESTEP_BEGIN)
3659  {
3660  for (const auto obj_ptr : objects)
3661  obj_ptr->timestepSetup();
3662  }
3663  else if (exec_flag == EXEC_SUBDOMAIN)
3664  {
3665  for (const auto obj_ptr : objects)
3666  obj_ptr->subdomainSetup();
3667  }
3668 
3669  else if (exec_flag == EXEC_NONLINEAR)
3670  {
3671  for (const auto obj_ptr : objects)
3672  obj_ptr->jacobianSetup();
3673  }
3674 
3675  else if (exec_flag == EXEC_LINEAR)
3676  {
3677  for (const auto obj_ptr : objects)
3678  obj_ptr->residualSetup();
3679  }
3680 }
const ExecFlagType EXEC_TIMESTEP_BEGIN
Definition: Moose.C:37
const ExecFlagType EXEC_LINEAR
Definition: Moose.C:31
const ExecFlagType EXEC_NONLINEAR
Definition: Moose.C:33
const ExecFlagType EXEC_SUBDOMAIN
Definition: Moose.C:52
const ExecFlagType EXEC_INITIAL
Definition: Moose.C:30

◆ onlyAllowDefaultNonlinearConvergence()

virtual bool FEProblemBase::onlyAllowDefaultNonlinearConvergence ( ) const
inlinevirtualinherited

Returns true if an error will result if the user supplies 'nonlinear_convergence'.

Some problems are strongly tied to their convergence, and it does not make sense to use any convergence other than their default and additionally would be error-prone.

Reimplemented in ReferenceResidualProblem.

Definition at line 795 of file FEProblemBase.h.

Referenced by FEProblemSolve::FEProblemSolve().

795 { return false; }

◆ onTimestepBegin()

void FEProblemBase::onTimestepBegin ( )
overridevirtualinherited

Implements SubProblem.

Definition at line 7302 of file FEProblemBase.C.

Referenced by MFEMTransient::takeStep(), and TransientBase::takeStep().

7303 {
7304  TIME_SECTION("onTimestepBegin", 2);
7305 
7306  for (auto & nl : _nl)
7307  nl->onTimestepBegin();
7308 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ onTimestepEnd()

void FEProblemBase::onTimestepEnd ( )
overridevirtualinherited

◆ outputStep()

void FEProblemBase::outputStep ( ExecFlagType  type)
virtualinherited

Output the current step.

Will ensure that everything is in the proper state to be outputted. Then tell the OutputWarehouse to do its thing

Parameters
typeThe type execution flag (see Moose.h)

Reimplemented in DumpObjectsProblem.

Definition at line 7265 of file FEProblemBase.C.

Referenced by TransientBase::endStep(), MFEMSteady::execute(), TransientBase::execute(), SteadyBase::execute(), Eigenvalue::execute(), InversePowerMethod::init(), NonlinearEigen::init(), EigenExecutionerBase::postExecute(), TransientBase::preExecute(), FixedPointSolve::solve(), TransientMultiApp::solveStep(), and FixedPointSolve::solveStep().

7266 {
7267  TIME_SECTION("outputStep", 1, "Outputting");
7268 
7270 
7271  for (auto & sys : _solver_systems)
7272  sys->update();
7273  _aux->update();
7274 
7275  if (_displaced_problem)
7276  _displaced_problem->syncSolutions();
7278 
7280 }
void outputStep(ExecFlagType type)
Calls the outputStep method for each output object.
const ExecFlagType EXEC_NONE
Definition: Moose.C:29
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
void setCurrentExecuteOnFlag(const ExecFlagType &)
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
std::shared_ptr< DisplacedProblem > _displaced_problem
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409

◆ paramError()

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

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 457 of file MooseBase.h.

Referenced by HierarchicalGridPartitioner::_do_partition(), AutoCheckpointAction::act(), SetupDebugAction::act(), CommonOutputAction::act(), DiffusionCG::addFEKernels(), DiffusionFV::addFVKernels(), NEML2ModelExecutor::addGatheredParameter(), NEML2ModelExecutor::addGatheredVariable(), ADDGKernel::ADDGKernel(), ComponentJunction::addMeshGenerators(), CylinderComponent::addMeshGenerators(), ReporterPointSource::addPoints(), ADIntegratedBCTempl< T >::ADIntegratedBCTempl(), ADKernelTempl< T >::ADKernelTempl(), ADPenaltyPeriodicSegmentalConstraint::ADPenaltyPeriodicSegmentalConstraint(), ADPeriodicSegmentalConstraint::ADPeriodicSegmentalConstraint(), AdvancedExtruderGenerator::AdvancedExtruderGenerator(), AdvectiveFluxAux::AdvectiveFluxAux(), ADVectorFunctionDirichletBC::ADVectorFunctionDirichletBC(), AnnularMesh::AnnularMesh(), AnnularMeshGenerator::AnnularMeshGenerator(), ArrayBodyForce::ArrayBodyForce(), ArrayCoupledForce::ArrayCoupledForce(), ArrayDGKernel::ArrayDGKernel(), ArrayDGLowerDKernel::ArrayDGLowerDKernel(), ArrayDirichletBC::ArrayDirichletBC(), ArrayHFEMDirichletBC::ArrayHFEMDirichletBC(), ArrayIntegratedBC::ArrayIntegratedBC(), ArrayKernel::ArrayKernel(), ArrayLowerDIntegratedBC::ArrayLowerDIntegratedBC(), ArrayParsedAux::ArrayParsedAux(), ArrayPenaltyDirichletBC::ArrayPenaltyDirichletBC(), ArrayReactionNodalKernelTempl< is_ad >::ArrayReactionNodalKernelTempl(), ArrayVacuumBC::ArrayVacuumBC(), ArrayVarReductionAux::ArrayVarReductionAux(), ParsedSubdomainIDsGenerator::assignElemSubdomainID(), AuxKernelBase::AuxKernelBase(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), BlockDeletionGenerator::BlockDeletionGenerator(), BlockWeightedPartitioner::BlockWeightedPartitioner(), BoundaryIntegralValueConstraint::BoundaryIntegralValueConstraint(), BoundaryLinearFVFluxIntegral::BoundaryLinearFVFluxIntegral(), BoundsBase::BoundsBase(), BreakMeshByBlockGenerator::BreakMeshByBlockGenerator(), BSplineCurveGenerator::BSplineCurveGenerator(), BuildArrayVariableAux::BuildArrayVariableAux(), MFEMFESpaceHierarchy::buildHierarchy(), MFEMMesh::buildMesh(), MFEMGeometricMultigridSolver::BuildMultigrid(), TimeSequenceStepperBase::buildSequence(), CartesianGridDivision::CartesianGridDivision(), CartesianMeshGenerator::CartesianMeshGenerator(), checkComponent(), Moose::Kokkos::ParsedObjectBase::checkDuplicateSymbols(), MeshGenerator::checkGetMesh(), ComponentInitialConditionInterface::checkInitialConditionsAllRequested(), BatchMeshGeneratorAction::checkInputParameterType(), PhysicsBase::checkIntegrityEarly(), PostprocessorInterface::checkParam(), FEProblemBase::checkProblemIntegrity(), MultiAppReporterTransfer::checkSiblingsTransferSupported(), MFEMMultiAppTransfer::checkValidTransferProblemTypes(), Coupleable::checkVar(), MultiAppTransfer::checkVariable(), CircularBoundaryCorrectionGenerator::CircularBoundaryCorrectionGenerator(), CircularBoundaryCorrectionGenerator::circularCenterCalculator(), MultiAppGeneralFieldTransfer::closestToPosition(), CoarsenBlockGenerator::CoarsenBlockGenerator(), CombinedVectorPostprocessor::CombinedVectorPostprocessor(), CombinerGenerator::CombinerGenerator(), ComponentInitialConditionInterface::ComponentInitialConditionInterface(), ComponentJunction::ComponentJunction(), ComponentMaterialPropertyInterface::ComponentMaterialPropertyInterface(), CompositionDT::CompositionDT(), ConcentricCircleMeshGenerator::ConcentricCircleMeshGenerator(), LibtorchNeuralNetControl::conditionalParameterError(), ConservativeAdvectionBCTempl< false >::ConservativeAdvectionBCTempl(), ConservativeAdvectionTempl< is_ad >::ConservativeAdvectionTempl(), ConstantVectorPostprocessor::ConstantVectorPostprocessor(), ContainsPointAux::ContainsPointAux(), CopyValueAux::CopyValueAux(), MultiAppGeneralFieldTransfer::correctSolutionVectorValues(), Coupleable::Coupleable(), CoupledForceTempl< is_ad >::CoupledForceTempl(), CoupledValueFunctionMaterialTempl< is_ad >::CoupledValueFunctionMaterialTempl(), MultiApp::createApp(), MeshGeneratorSystem::createMeshGenerator(), CylindricalGridDivision::CylindricalGridDivision(), DebugResidualAux::DebugResidualAux(), ConstantReporter::declareConstantReporterValue(), ConstantReporter::declareConstantReporterValues(), AccumulateReporter::declareLateValues(), DefaultMultiAppFixedPointConvergence::DefaultMultiAppFixedPointConvergence(), DGKernel::DGKernel(), DGKernelBase::DGKernelBase(), DGLowerDKernel::DGLowerDKernel(), DiffusionFluxAux::DiffusionFluxAux(), DomainUserObject::DomainUserObject(), EigenProblem::EigenProblem(), EigenProblemSolve::EigenProblemSolve(), ElementAdaptivityLevelAux::ElementAdaptivityLevelAux(), ElementGenerator::ElementGenerator(), ElementGroupCentroidPositions::ElementGroupCentroidPositions(), ElementLengthAux::ElementLengthAux(), ElementLpNormAux::ElementLpNormAux(), ElementNormalAux::ElementNormalAux(), ExtraIDIntegralVectorPostprocessor::elementValue(), ElementValueSampler::ElementValueSampler(), ElementVectorL2Error::ElementVectorL2Error(), EqualValueEmbeddedConstraintTempl< is_ad >::EqualValueEmbeddedConstraintTempl(), ReporterPointSource::errorCheck(), StitchMeshGeneratorBase::errorMissingBoundary(), ExamplePatchMeshGenerator::ExamplePatchMeshGenerator(), MultiAppNearestNodeTransfer::execute(), MultiAppUserObjectTransfer::execute(), ExtraElementIDAux::ExtraElementIDAux(), ExtraElementIntegerDivision::ExtraElementIntegerDivision(), ExtraIDIntegralVectorPostprocessor::ExtraIDIntegralVectorPostprocessor(), FEProblemBase::FEProblemBase(), FEProblemSolve::FEProblemSolve(), FileMeshGenerator::FileMeshGenerator(), FillBetweenCurvesGenerator::FillBetweenCurvesGenerator(), FillBetweenSidesetsGenerator::FillBetweenSidesetsGenerator(), SpatialUserObjectVectorPostprocessor::fillPoints(), CombinerGenerator::fillPositions(), MultiApp::fillPositions(), InternalSideIndicatorBase::finalize(), FixedPointSolve::findTransformedSystem(), FixedPointSolve::FixedPointSolve(), ForcingFunctionAux::ForcingFunctionAux(), FullSolveMultiApp::FullSolveMultiApp(), FunctionArrayAux::FunctionArrayAux(), FunctionValuePostprocessor::FunctionValuePostprocessor(), FunctorADConverterTempl< T >::FunctorADConverterTempl(), FunctorAux::FunctorAux(), FunctorBinnedValuesDivision::FunctorBinnedValuesDivision(), FunctorCoordinatesFunctionAux::FunctorCoordinatesFunctionAux(), FunctorElementalGradientAuxTempl< is_ad >::FunctorElementalGradientAuxTempl(), FunctorExtremaPositions::FunctorExtremaPositions(), FunctorIC::FunctorIC(), FunctorPositions::FunctorPositions(), FunctorVectorElementalAuxTempl< is_ad >::FunctorVectorElementalAuxTempl(), FVAdvection::FVAdvection(), FVFluxBC::FVFluxBC(), FVInterfaceKernel::FVInterfaceKernel(), FVOneVarDiffusionInterface::FVOneVarDiffusionInterface(), FVTwoVarContinuityConstraint::FVTwoVarContinuityConstraint(), Boundary2DDelaunayGenerator::General2DDelaunay(), SurfaceSubdomainsDelaunayRemesher::General2DDelaunay(), BoundaryDeletionGenerator::generate(), UniqueExtraIDMeshGenerator::generate(), AddMetaDataGenerator::generate(), LowerDBlockFromSidesetGenerator::generate(), BlockToMeshConverterGenerator::generate(), BreakBoundaryOnSubdomainGenerator::generate(), ExtraNodesetGenerator::generate(), PlaneIDMeshGenerator::generate(), RenameBlockGenerator::generate(), RenameBoundaryGenerator::generate(), RenumberBySubdomainGenerator::generate(), BlockDeletionGenerator::generate(), BoundaryElementConversionGenerator::generate(), BreakMeshByBlockGenerator::generate(), CoarsenBlockGenerator::generate(), ElementsToTetrahedronsConverter::generate(), FillBetweenCurvesGenerator::generate(), FillBetweenSidesetsGenerator::generate(), FlipSidesetGenerator::generate(), GeneratedMeshGenerator::generate(), ParsedSubdomainGeneratorBase::generate(), RefineBlockGenerator::generate(), RefineSidesetGenerator::generate(), SideSetsFromNodeSetsGenerator::generate(), SubdomainsFromPartitionerGenerator::generate(), XYZDelaunayGenerator::generate(), CombinerGenerator::generate(), AdvancedExtruderGenerator::generate(), BreakMeshByElementGenerator::generate(), MeshCollectionGenerator::generate(), MeshExtruderGenerator::generate(), ParsedExtraElementIDGenerator::generate(), PolyLineMeshFollowingNodeSetGenerator::generate(), ProjectSideSetOntoLevelSetGenerator::generate(), StackGenerator::generate(), CircularBoundaryCorrectionGenerator::generate(), ParsedCurveGenerator::generate(), XYMeshLineCutter::generate(), Boundary2DDelaunayGenerator::generate(), CutMeshByLevelSetGeneratorBase::generate(), SurfaceSubdomainsDelaunayRemesher::generate(), ManifoldSubdomainGenerator::generate(), PatternedMeshGenerator::generate(), SubdomainBoundingBoxGenerator::generate(), GeneratedMeshGenerator::GeneratedMeshGenerator(), BoundaryLayerUtils::generateOffsetPolyline(), GenericConstantStdVectorMaterialTempl< is_ad >::GenericConstantStdVectorMaterialTempl(), GenericFunctorGradientMaterialTempl< is_ad >::GenericFunctorGradientMaterialTempl(), GenericFunctorMaterialTempl< is_ad >::GenericFunctorMaterialTempl(), GenericFunctorTimeDerivativeMaterialTempl< is_ad >::GenericFunctorTimeDerivativeMaterialTempl(), GenericVectorFunctorMaterialTempl< is_ad >::GenericVectorFunctorMaterialTempl(), PropertyReadFile::getBlockData(), ComponentBoundaryConditionInterface::getBoundaryCondition(), MultiApp::getCommandLineArgs(), PropertyReadFile::getData(), PropertyReadFile::getFileNames(), Sampler::getGlobalSamples(), ComponentInitialConditionInterface::getInitialCondition(), NEML2Action::getInputParameterMapping(), MultiAppNearestNodeTransfer::getLocalEntitiesAndComponents(), Sampler::getLocalSamples(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), Sampler::getNextLocalRow(), FEProblemSolve::getParamFromNonlinearSystemVectorParam(), PostprocessorInterface::getPostprocessorNameInternal(), PostprocessorInterface::getPostprocessorValueInternal(), MultiAppNearestNodeTransfer::getTargetLocalNodes(), UserObjectInterface::getUserObjectBase(), UserObjectInterface::getUserObjectName(), AddPeriodicBCAction::getVariables(), HFEMDirichletBC::HFEMDirichletBC(), MFEMTransient::init(), AddVariableAction::init(), MultiApp::init(), DistributedPositions::initialize(), BlockWeightedPartitioner::initialize(), BlockRestrictable::initializeBlockRestrictable(), BoundaryRestrictable::initializeBoundaryRestrictable(), PhysicsBase::initializePhysics(), JSONOutput::initialSetup(), MultiAppCloneReporterTransfer::initialSetup(), SolutionIC::initialSetup(), MultiAppGeneralFieldKDTreeTransferBase::initialSetup(), BoundaryLinearFVFluxIntegral::initialSetup(), FullSolveMultiApp::initialSetup(), SideFVFluxBCIntegral::initialSetup(), MultiAppVariableValueSamplePostprocessorTransfer::initialSetup(), MFEMPointScalarCoefficientValueSampler::initialSetup(), MultiAppGeneralFieldNearestLocationTransfer::initialSetup(), MultiAppDofCopyTransfer::initialSetup(), HistogramVectorPostprocessor::initialSetup(), ReferenceResidualConvergence::initialSetup(), PiecewiseConstantFromCSV::initialSetup(), LibtorchControlValuePostprocessor::initialSetup(), MultiAppGeneralFieldTransfer::initialSetup(), ElementSubdomainModifierBase::initialSetup(), SampledOutput::initSample(), AddMetaDataGenerator::inputChecker(), IntegratedBC::IntegratedBC(), InterfaceDiffusiveFluxIntegralTempl< is_ad >::InterfaceDiffusiveFluxIntegralTempl(), InterfaceValueUserObjectAux::InterfaceValueUserObjectAux(), InternalSideIndicatorBase::InternalSideIndicatorBase(), InterpolatedStatefulMaterialTempl< T >::InterpolatedStatefulMaterialTempl(), InversePowerMethod::InversePowerMethod(), IterationAdaptiveDT::IterationAdaptiveDT(), MultiApp::keepSolutionDuringRestore(), Kernel::Kernel(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), LinearCombinationFunction::LinearCombinationFunction(), LinearFVAdvectionDiffusionFunctorRobinBC::LinearFVAdvectionDiffusionFunctorRobinBC(), LowerDIntegratedBC::LowerDIntegratedBC(), PNGOutput::makeMeshFunc(), MatCoupledForce::MatCoupledForce(), MaterialADConverterTempl< T >::MaterialADConverterTempl(), MaterialFunctorConverterTempl< T >::MaterialFunctorConverterTempl(), MatReactionTempl< false >::MatReactionTempl(), MatrixSymmetryCheck::MatrixSymmetryCheck(), PatternedMeshGenerator::mergeSubdomainNameMaps(), MeshCollectionGenerator::MeshCollectionGenerator(), MeshDiagnosticsGenerator::MeshDiagnosticsGenerator(), MeshDivisionAux::MeshDivisionAux(), MeshGenerator::MeshGenerator(), MeshGeneratorComponent::MeshGeneratorComponent(), MFEMComplexSumAux::MFEMComplexSumAux(), MFEMFunctorMaterial::MFEMFunctorMaterial(), MFEMGenericFunctorMaterial::MFEMGenericFunctorMaterial(), MFEMGenericFunctorVectorMaterial::MFEMGenericFunctorVectorMaterial(), MFEMGeometricMultigridSolver::MFEMGeometricMultigridSolver(), MFEMMultiAppTransfer::MFEMMultiAppTransfer(), MFEMNDtoRTAux::MFEMNDtoRTAux(), MFEMSumAux::MFEMSumAux(), MFEMVariable::MFEMVariable(), MooseLinearVariableFV< Real >::MooseLinearVariableFV(), UserObjectInterface::mooseObjectError(), MoosePreconditioner::MoosePreconditioner(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), MooseVariableBase::MooseVariableBase(), MortarConstraintBase::MortarConstraintBase(), MortarNodalAuxKernelTempl< ComputeValueType >::MortarNodalAuxKernelTempl(), MultiApp::moveApp(), MoveNodeGenerator::MoveNodeGenerator(), MultiApp::MultiApp(), MultiAppCloneReporterTransfer::MultiAppCloneReporterTransfer(), MultiAppGeneralFieldFunctorTransfer::MultiAppGeneralFieldFunctorTransfer(), MultiAppGeneralFieldKDTreeTransferBase::MultiAppGeneralFieldKDTreeTransferBase(), MultiAppGeneralFieldShapeEvaluationTransfer::MultiAppGeneralFieldShapeEvaluationTransfer(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppGeneralFieldUserObjectTransfer::MultiAppGeneralFieldUserObjectTransfer(), MultiAppGeometricInterpolationTransfer::MultiAppGeometricInterpolationTransfer(), MultiAppNearestNodeTransfer::MultiAppNearestNodeTransfer(), MultiAppPostprocessorInterpolationTransfer::MultiAppPostprocessorInterpolationTransfer(), MultiAppPostprocessorToAuxScalarTransfer::MultiAppPostprocessorToAuxScalarTransfer(), MultiAppPostprocessorTransfer::MultiAppPostprocessorTransfer(), MultiAppProjectionTransfer::MultiAppProjectionTransfer(), MultiAppReporterTransfer::MultiAppReporterTransfer(), MultiAppScalarToAuxScalarTransfer::MultiAppScalarToAuxScalarTransfer(), MultiAppShapeEvaluationTransfer::MultiAppShapeEvaluationTransfer(), MultiAppTransfer::MultiAppTransfer(), MultiAppUserObjectTransfer::MultiAppUserObjectTransfer(), MultiAppVariableValueSamplePostprocessorTransfer::MultiAppVariableValueSamplePostprocessorTransfer(), MultiAppVariableValueSampleTransfer::MultiAppVariableValueSampleTransfer(), MultiAppVectorPostprocessorTransfer::MultiAppVectorPostprocessorTransfer(), MultiSystemSolveObject::MultiSystemSolveObject(), NearestNodeValueAux::NearestNodeValueAux(), NEML2Action::NEML2Action(), NEML2PreKernel::NEML2PreKernel(), NestedDivision::NestedDivision(), NodalBC::NodalBC(), NodalEqualValueConstraint::NodalEqualValueConstraint(), NodalKernel::NodalKernel(), NodalPatchRecoveryAux::NodalPatchRecoveryAux(), NodalValueSampler::NodalValueSampler(), NumDOFs::NumDOFs(), OrientSurfaceMeshGenerator::OrientSurfaceMeshGenerator(), Output::Output(), ParsedCurveGenerator::ParsedCurveGenerator(), ParsedFunctorMaterialTempl< is_ad >::ParsedFunctorMaterialTempl(), ParsedPostprocessor::ParsedPostprocessor(), ParsedReporterBase::ParsedReporterBase(), ParsedScalarReporter::ParsedScalarReporter(), ParsedSubdomainGeneratorBase::ParsedSubdomainGeneratorBase(), ParsedVectorRealReductionReporter::ParsedVectorRealReductionReporter(), ParsedVectorReporter::ParsedVectorReporter(), ParsedVectorVectorRealReductionReporter::ParsedVectorVectorRealReductionReporter(), PatternedMeshGenerator::PatternedMeshGenerator(), PenaltyPeriodicSegmentalConstraint::PenaltyPeriodicSegmentalConstraint(), PeriodicSegmentalConstraint::PeriodicSegmentalConstraint(), PIDTransientControl::PIDTransientControl(), PlaneDeletionGenerator::PlaneDeletionGenerator(), PlaneIDMeshGenerator::PlaneIDMeshGenerator(), PointwiseRenormalizeVector::PointwiseRenormalizeVector(), PolyLineMeshFollowingNodeSetGenerator::PolyLineMeshFollowingNodeSetGenerator(), EqualValueBoundaryConstraint::populateSecondaryNodes(), ReporterInterface::possiblyCheckHasReporter(), VectorPostprocessorInterface::possiblyCheckHasVectorPostprocessor(), LibmeshPartitioner::prepareBlocksForSubdomainPartitioner(), ProjectedMaterialPropertyNodalPatchRecoveryAux::ProjectedMaterialPropertyNodalPatchRecoveryAux(), ProjectSideSetOntoLevelSetGenerator::ProjectSideSetOntoLevelSetGenerator(), PropertyReadFile::PropertyReadFile(), RandomIC::RandomIC(), RankTwoTensorFromComponentProperties::RankTwoTensorFromComponentProperties(), MultiApp::readCommandLineArguments(), PropertyReadFile::readData(), SolutionUserObjectBase::readExodusIIOrNemesis(), SolutionUserObjectBase::readXda(), ReferenceResidualConvergence::ReferenceResidualConvergence(), RefineBlockGenerator::RefineBlockGenerator(), RefineSidesetGenerator::RefineSidesetGenerator(), RenameBlockGenerator::RenameBlockGenerator(), RenameBoundaryGenerator::RenameBoundaryGenerator(), ReporterPointSource::ReporterPointSource(), FEProblemBase::restoreSolutions(), SecondTimeDerivativeAux::SecondTimeDerivativeAux(), FEProblemBase::setLinearConvergenceNames(), FEProblemBase::setNonlinearConvergenceNames(), MooseMesh::setPartitioner(), SurfaceMeshGeneratorBase::setup(), NodeSetsGeneratorBase::setup(), SideSetsGeneratorBase::setup(), CylinderComponent::setupComponent(), NEML2Action::setupDerivativeMappings(), NEML2Action::setupInputMappings(), MultiSystemSolveObject::setupMultiSystemFixedPointRelaxationFactors(), NEML2Action::setupParameterDerivativeMappings(), NEML2Action::setupParameterMappings(), SetupQuadratureAction::SetupQuadratureAction(), SidesetAroundSubdomainUpdater::SidesetAroundSubdomainUpdater(), SideSetsFromBoundingBoxGenerator::SideSetsFromBoundingBoxGenerator(), SideValueSampler::SideValueSampler(), SingleRankPartitioner::SingleRankPartitioner(), SphericalGridDivision::SphericalGridDivision(), StitchBoundaryMeshGenerator::StitchBoundaryMeshGenerator(), StitchMeshGenerator::StitchMeshGenerator(), SurfaceSubdomainsDelaunayRemesher::SurfaceSubdomainsDelaunayRemesher(), SymmetryTransformGenerator::SymmetryTransformGenerator(), TagVectorAux::TagVectorAux(), Terminator::Terminator(), TimeDerivativeAux::TimeDerivativeAux(), Transfer::Transfer(), TransformGenerator::TransformGenerator(), TransientMultiApp::TransientMultiApp(), CylinderComponent::translation(), MeshTriangulationUtils::triangulateWithDelaunay(), ParsedCurveGenerator::tSectionSpaceDefiner(), UniqueExtraIDMeshGenerator::UniqueExtraIDMeshGenerator(), UserObjectBase::UserObjectBase(), Checkpoint::validateExecuteOn(), ParsedAux::validateGenericVectorNames(), validateVariableNumericType(), FunctorIC::value(), VariableCondensationPreconditioner::VariableCondensationPreconditioner(), VectorBodyForce::VectorBodyForce(), VectorFunctionDirichletBC::VectorFunctionDirichletBC(), VectorFunctionIC::VectorFunctionIC(), VolumeAux::VolumeAux(), WebServerControl::WebServerControl(), XYDelaunayGenerator::XYDelaunayGenerator(), XYMeshLineCutter::XYMeshLineCutter(), and XYZDelaunayGenerator::XYZDelaunayGenerator().

458 {
459  _pars.paramError(param, std::forward<Args>(args)...);
460 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
void paramError(const std::string &param, Args... args) const
Emits a parameter error prefixed with the parameter location and object information if available...

◆ parameters()

const InputParameters& MooseBase::parameters ( ) const
inlineinherited

Get the parameters of the object.

Returns
The parameters of the object

Definition at line 131 of file MooseBase.h.

Referenced by MeshOnlyAction::act(), SplitMeshAction::act(), SetupDebugAction::act(), CSGOnlyAction::act(), AddActionComponentAction::act(), CommonOutputAction::act(), Action::Action(), FEProblemBase::addAnyRedistributers(), addAuxKernel(), FEProblemBase::addAuxKernel(), FEProblemBase::addAuxScalarKernel(), addAuxVariable(), DisplacedProblem::addAuxVariable(), addBoundaryCondition(), FEProblemBase::addBoundaryCondition(), FEProblemBase::addConstraint(), FEProblemBase::addConvergence(), FEProblemBase::addDamper(), AddDefaultConvergenceAction::addDefaultMultiAppFixedPointConvergence(), FEProblemBase::addDefaultMultiAppFixedPointConvergence(), ReferenceResidualProblem::addDefaultNonlinearConvergence(), AddDefaultConvergenceAction::addDefaultNonlinearConvergence(), FEProblemBase::addDefaultNonlinearConvergence(), AddDefaultConvergenceAction::addDefaultSteadyStateConvergence(), FEProblemBase::addDefaultSteadyStateConvergence(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addDistribution(), addFESpace(), addFESpaceHierarchy(), addFunction(), FEProblemBase::addFunction(), addFunctorMaterial(), FEProblemBase::addFunctorMaterial(), FEProblemBase::addFVBC(), FEProblemBase::addFVInitialCondition(), FEProblemBase::addFVInterfaceKernel(), FEProblemBase::addFVInterpolationMethod(), FEProblemBase::addFVKernel(), addGridFunction(), FEProblemBase::addHDGKernel(), addImagComponentToBC(), addImagComponentToKernel(), addIndicator(), FEProblemBase::addIndicator(), addInitialCondition(), FEProblemBase::addInitialCondition(), DiffusionPhysicsBase::addInitialConditions(), FEProblemBase::addInterfaceKernel(), FEProblemBase::addInterfaceMaterial(), addKernel(), FEProblemBase::addKernel(), FEProblemBase::addLinearFVBC(), FEProblemBase::addLinearFVKernel(), FEProblem::addLineSearch(), addMarker(), FEProblemBase::addMarker(), FEProblemBase::addMaterial(), FEProblemBase::addMaterialHelper(), FEProblemBase::addMeshDivision(), addMFEMFESpaceFromMOOSEVariable(), addMFEMSolver(), FEProblemBase::addMultiApp(), FEProblemBase::addNodalKernel(), FEProblemBase::addObject(), FEProblemBase::addObjectParamsHelper(), FEProblemBase::addOutput(), addPostprocessor(), FEProblemBase::addPostprocessor(), FEProblemBase::addPredictor(), addQuadratureFunction(), addRealComponentToBC(), addRealComponentToKernel(), FEProblemBase::addReporter(), FEProblemBase::addSampler(), FEProblemBase::addScalarKernel(), addSubMesh(), FEProblemBase::addTimeIntegrator(), addTransfer(), FEProblemBase::addTransfer(), FEProblemBase::addUserObject(), MFEMEigenproblem::addVariable(), addVariable(), DisplacedProblem::addVariable(), addVectorPostprocessor(), FEProblemBase::addVectorPostprocessor(), ADPiecewiseLinearInterpolationMaterial::ADPiecewiseLinearInterpolationMaterial(), AdvancedOutput::AdvancedOutput(), ADVectorFunctionDirichletBC::ADVectorFunctionDirichletBC(), AnnularMesh::AnnularMesh(), AnnularMeshGenerator::AnnularMeshGenerator(), Action::associateWithParameter(), AuxKernelBase::AuxKernelBase(), AuxScalarKernel::AuxScalarKernel(), BoundsBase::BoundsBase(), MooseMesh::buildTypedMesh(), PostprocessorInterface::checkParam(), AddDefaultConvergenceAction::checkUnusedMultiAppFixedPointConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedNonlinearConvergenceParameters(), AddDefaultConvergenceAction::checkUnusedSteadyStateConvergenceParameters(), SampledOutput::cloneMesh(), LibtorchNeuralNetControl::conditionalParameterError(), Console::Console(), MooseMeshUtils::copyIntoMesh(), CommonOutputAction::create(), MultiApp::createApp(), Postprocessor::declareValue(), DumpObjectsProblem::deduceNecessaryParameters(), DefaultMultiAppFixedPointConvergence::DefaultMultiAppFixedPointConvergence(), DumpObjectsProblem::dumpObjectHelper(), DumpObjectsProblem::DumpObjectsProblem(), EigenProblem::EigenProblem(), EigenProblemSolve::EigenProblemSolve(), ElementMaterialSampler::ElementMaterialSampler(), ExamplePatchMeshGenerator::ExamplePatchMeshGenerator(), Executor::Executor(), Exodus::Exodus(), ElementSubdomainModifierBase::extrapolatePolynomial(), FEProblem::FEProblem(), FixedPointSolve::FixedPointSolve(), FunctorSmootherTempl< T >::FunctorSmootherTempl(), GapValueAux::GapValueAux(), ParsedSubdomainGeneratorBase::generate(), ActionWarehouse::getCurrentActionName(), ExecutorInterface::getExecutor(), Material::getMaterial(), Moose::PeriodicBCHelper::getParams(), ReporterInterface::getReporterName(), Reporter::getReporterValueName(), UserObjectInterface::getUserObjectName(), AuxKernelBase::getVariableHelper(), VectorPostprocessorInterface::getVectorPostprocessorName(), GhostingUserObject::GhostingUserObject(), MeshGeneratorSystem::hasDataDrivenAllowed(), AttribSystem::initFrom(), AttribDisplaced::initFrom(), BlockRestrictable::initializeBlockRestrictable(), FullSolveMultiApp::initialSetup(), FEProblemBase::initNullSpaceVectors(), InterfaceDiffusiveFluxIntegralTempl< is_ad >::InterfaceDiffusiveFluxIntegralTempl(), InterfaceIntegralVariableValuePostprocessor::InterfaceIntegralVariableValuePostprocessor(), InterfaceKernelTempl< T >::InterfaceKernelTempl(), MooseObject::isKokkosObject(), isValid(), IterationAdaptiveDT::IterationAdaptiveDT(), LibtorchNeuralNetControl::LibtorchNeuralNetControl(), MooseObject::MooseObject(), UserObjectInterface::mooseObjectError(), MooseVariableInterface< Real >::MooseVariableInterface(), MultiApp::MultiApp(), MultiAppGeneralFieldTransfer::MultiAppGeneralFieldTransfer(), MultiAppGeneralFieldUserObjectTransfer::MultiAppGeneralFieldUserObjectTransfer(), MultiAppTransfer::MultiAppTransfer(), MultiAppVariableValueSamplePostprocessorTransfer::MultiAppVariableValueSamplePostprocessorTransfer(), NodeFaceConstraint::NodeFaceConstraint(), ConsoleUtils::outputLegacyInformation(), OverlayMeshGenerator::OverlayMeshGenerator(), ParsedReporterBase::ParsedReporterBase(), ParsedScalarReporter::ParsedScalarReporter(), PenetrationAux::PenetrationAux(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), NEML2Action::printSummary(), ProjectedStatefulMaterialStorageAction::processProperty(), PropertyReadFile::PropertyReadFile(), PseudoTimestep::PseudoTimestep(), RandomIC::RandomIC(), ReferenceResidualConvergence::ReferenceResidualConvergence(), InputParameterWarehouse::removeInputParameters(), FEProblemBase::setAuxKernelParamsAndLog(), FEProblem::setInputParametersFEProblem(), FEProblemBase::setInputParametersFEProblem(), FEProblemBase::setResidualObjectParamsAndLog(), SideSetsGeneratorBase::setup(), NonlinearSystemBase::shouldEvaluatePreSMOResidual(), SideSetsFromBoundingBoxGenerator::SideSetsFromBoundingBoxGenerator(), Moose::PetscSupport::storePetscOptions(), DumpObjectsProblem::stringifyParameters(), TaggingInterface::TaggingInterface(), Transfer::Transfer(), TransientBase::TransientBase(), VectorBodyForce::VectorBodyForce(), VectorFunctionDirichletBC::VectorFunctionDirichletBC(), VectorFunctionIC::VectorFunctionIC(), and VectorMagnitudeFunctorMaterialTempl< is_ad >::VectorMagnitudeFunctorMaterialTempl().

131 { return _pars; }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384

◆ paramInfo()

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

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 471 of file MooseBase.h.

Referenced by GridPartitioner::_do_partition(), ComboMarker::ComboMarker(), Control::Control(), FunctorIC::FunctorIC(), and TransientMultiApp::TransientMultiApp().

472 {
473  mooseInfo(_pars.paramMessage(param, std::forward<Args>(args)...));
474 }
std::string paramMessage(const std::string &param, Args... args) const
void mooseInfo(Args &&... args) const
Definition: MooseBase.h:334
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384

◆ paramWarning() [1/2]

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

◆ paramWarning() [2/2]

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

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 464 of file MooseBase.h.

465 {
466  mooseWarning(_pars.paramMessage(param, std::forward<Args>(args)...));
467 }
std::string paramMessage(const std::string &param, Args... args) const
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
void mooseWarning(Args &&... args) const
Emits a warning prefixed with object name and type.
Definition: MooseBase.h:299

◆ parentOutputPositionChanged()

void FEProblemBase::parentOutputPositionChanged ( )
inherited

Calls parentOutputPositionChanged() on all sub apps.

Definition at line 4958 of file FEProblemBase.C.

Referenced by TransientBase::parentOutputPositionChanged().

4959 {
4960  for (const auto & it : _multi_apps)
4961  {
4962  const auto & objects = it.second.getActiveObjects();
4963  for (const auto & obj : objects)
4964  obj->parentOutputPositionChanged();
4965  }
4966 }
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.

◆ perfGraph()

PerfGraph & PerfGraphInterface::perfGraph ( )
inherited

Get the PerfGraph.

Definition at line 86 of file PerfGraphInterface.C.

Referenced by CommonOutputAction::act(), PerfGraphData::finalize(), PerfGraphReporter::finalize(), and PerfGraphOutput::output().

87 {
88  return _pg_moose_app.perfGraph();
89 }
MooseApp & _pg_moose_app
The MooseApp that owns the PerfGraph.
PerfGraph & perfGraph()
Get the PerfGraph for this app.
Definition: MooseApp.h:179

◆ petscOptionsDatabase()

PetscOptions& FEProblemBase::petscOptionsDatabase ( )
inlineinherited

Definition at line 2593 of file FEProblemBase.h.

Referenced by EigenProblemSolve::initialSetup().

2593 { return _petsc_option_data_base; }
PetscOptions _petsc_option_data_base

◆ petscOptionsInserted()

bool& FEProblemBase::petscOptionsInserted ( )
inlineinherited

If PETSc options are already inserted.

Definition at line 2590 of file FEProblemBase.h.

Referenced by EigenProblemSolve::initialSetup().

2590 { return _is_petsc_options_inserted; }
bool _is_petsc_options_inserted
If or not PETSc options have been added to database.

◆ possiblyRebuildGeomSearchPatches()

void FEProblemBase::possiblyRebuildGeomSearchPatches ( )
virtualinherited

Definition at line 8466 of file FEProblemBase.C.

Referenced by FEProblemBase::solve().

8467 {
8468  if (_displaced_problem) // Only need to do this if things are moving...
8469  {
8470  TIME_SECTION("possiblyRebuildGeomSearchPatches", 5, "Rebuilding Geometric Search Patches");
8471 
8472  switch (_mesh.getPatchUpdateStrategy())
8473  {
8474  case Moose::Never:
8475  break;
8476  case Moose::Iteration:
8477  // Update the list of ghosted elements at the start of the time step
8480 
8481  _displaced_problem->geomSearchData().updateGhostedElems();
8483 
8484  // The commands below ensure that the sparsity of the Jacobian matrix is
8485  // augmented at the start of the time step using neighbor nodes from the end
8486  // of the previous time step.
8487 
8489 
8490  // This is needed to reinitialize PETSc output
8492 
8493  break;
8494 
8495  case Moose::Auto:
8496  {
8497  Real max = _displaced_problem->geomSearchData().maxPatchPercentage();
8499 
8500  // If we haven't moved very far through the patch
8501  if (max < 0.4)
8502  break;
8503  }
8504  libmesh_fallthrough();
8505 
8506  // Let this fall through if things do need to be updated...
8507  case Moose::Always:
8508  // Flush output here to see the message before the reinitialization, which could take a
8509  // while
8510  _console << "\n\nUpdating geometric search patches\n" << std::endl;
8511 
8514 
8515  _displaced_problem->geomSearchData().clearNearestNodeLocators();
8517 
8519 
8520  // This is needed to reinitialize PETSc output
8522  }
8523  }
8524 }
virtual void initPetscOutputAndSomeSolverSettings()
Reinitialize PETSc output for proper linear/nonlinear iteration display.
void reinitBecauseOfGhostingOrNewGeomObjects(bool mortar_changed=false)
Call when it is possible that the needs for ghosted elements has changed.
const Parallel::Communicator & _communicator
std::set< dof_id_type > _ghosted_elems
Elements that should have Dofs ghosted to the local processor.
Definition: SubProblem.h:1108
auto max(const L &left, const R &right)
void updateGhostedElems()
Updates the list of ghosted elements at the start of each time step for the nonlinear iteration patch...
MooseMesh & _mesh
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void updateActiveSemiLocalNodeRange(std::set< dof_id_type > &ghosted_elems)
Clears the "semi-local" node list and rebuilds it.
Definition: MooseMesh.C:955
void max(const T &r, T &o, Request &req) const
std::shared_ptr< DisplacedProblem > _displaced_problem
GeometricSearchData _geometric_search_data
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
const Moose::PatchUpdateType & getPatchUpdateStrategy() const
Get the current patch update strategy.
Definition: MooseMesh.C:3513
void clearNearestNodeLocators()
Clear out the Penetration Locators so they will redo the search.
MooseMesh * _displaced_mesh

◆ postExecute()

void FEProblemBase::postExecute ( )
virtualinherited

Method called at the end of the simulation.

Definition at line 6032 of file FEProblemBase.C.

Referenced by MFEMSteady::execute(), SteadyBase::execute(), TransientBase::execute(), and Eigenvalue::execute().

6033 {
6034  const auto & multi_apps = _multi_apps.getActiveObjects();
6035 
6036  for (const auto & multi_app : multi_apps)
6037  multi_app->postExecute();
6038 }
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.

◆ predictorCleanup()

void FEProblemBase::predictorCleanup ( NumericVector< libMesh::Number > &  ghosted_solution)
virtualinherited

Perform cleanup tasks after application of predictor to solution vector.

Parameters
ghosted_solutionGhosted solution vector

Definition at line 8367 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::setInitialSolution().

8368 {
8369 }

◆ pRefine()

bool MFEMProblem::pRefine ( )
inline

If AMR is enabled, request (and perform if needed) p-refinement.

Definition at line 335 of file MFEMProblem.h.

Referenced by MFEMProblemSolve::solve().

335 { return _problem_data.refiner && _problem_data.refiner->pRefine(); }
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
std::shared_ptr< MFEMRefinementMarker > refiner

◆ prepare() [1/2]

virtual void FEProblemBase::prepare ( const Elem *  elem,
const THREAD_ID  tid 
)
overridevirtualinherited

◆ prepare() [2/2]

virtual void FEProblemBase::prepare ( const Elem *  elem,
unsigned int  ivar,
unsigned int  jvar,
const std::vector< dof_id_type > &  dof_indices,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

◆ prepareAssembly()

void FEProblemBase::prepareAssembly ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 1929 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintJacobians(), NonlinearSystemBase::constraintResiduals(), NonlinearSystemBase::reinitNodeFace(), and NonlinearSystemBase::setConstraintSecondaryValues().

1930 {
1931  _assembly[tid][_current_nl_sys->number()]->prepare();
1933  _assembly[tid][_current_nl_sys->number()]->prepareNonlocal();
1934 
1935  if (_displaced_problem &&
1937  {
1938  _displaced_problem->prepareAssembly(tid);
1940  _displaced_problem->prepareNonlocal(tid);
1941  }
1942 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ prepareAssemblyNeighbor()

void FEProblemBase::prepareAssemblyNeighbor ( const THREAD_ID  tid)
virtualinherited

Begin a fresh neighbor accumulation phase by sizing and zeroing the neighbor blocks.

Definition at line 1945 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintJacobians().

1946 {
1947  _assembly[tid][_current_nl_sys->number()]->prepareNeighbor();
1948 
1950  _displaced_problem->prepareAssemblyNeighbor(tid);
1951 }
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ prepareFace()

void FEProblemBase::prepareFace ( const Elem elem,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 1843 of file FEProblemBase.C.

Referenced by ComputeUserObjectsThread::onInterface(), and ComputeUserObjectsThread::onInternalSide().

1844 {
1845  for (auto & nl : _nl)
1846  nl->prepareFace(tid, true);
1847  _aux->prepareFace(tid, false);
1848 
1850  _displaced_problem->prepareFace(_displaced_mesh->elemPtr(elem->id()), tid);
1851 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
dof_id_type id() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseMesh * _displaced_mesh

◆ prepareFaceShapes()

void FEProblemBase::prepareFaceShapes ( unsigned int  var,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2213 of file FEProblemBase.C.

Referenced by ComputeUserObjectsThread::onBoundary().

2214 {
2215  _assembly[tid][_current_nl_sys->number()]->copyFaceShapes(var);
2216 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.

◆ prepareKokkosMaterials()

void FEProblemBase::prepareKokkosMaterials ( const std::unordered_set< unsigned int > &  consumer_needed_mat_props)
inherited

◆ prepareMaterials()

void FEProblemBase::prepareMaterials ( const std::unordered_set< unsigned int > &  consumer_needed_mat_props,
const SubdomainID  blk_id,
const THREAD_ID  tid 
)
inherited

Add the MooseVariables and the material properties that the current materials depend on to the dependency list.

Parameters
consumer_needed_mat_propsThe material properties needed by consumer objects (other than the materials themselves)
blk_idThe subdomain ID for which we are preparing our list of needed vars and props
tidThe thread ID we are preparing the requirements for

This MUST be done after the moose variable dependency list has been set for all the other objects using the setActiveElementalMooseVariables API!

Definition at line 4257 of file FEProblemBase.C.

Referenced by ComputeMarkerThread::subdomainChanged(), ComputeIndicatorThread::subdomainChanged(), NonlinearThread::subdomainChanged(), and ComputeUserObjectsThread::subdomainChanged().

4260 {
4261  std::set<MooseVariableFEBase *> needed_moose_vars;
4262  std::unordered_set<unsigned int> needed_mat_props;
4263 
4264  if (_all_materials.hasActiveBlockObjects(blk_id, tid))
4265  {
4266  _all_materials.updateVariableDependency(needed_moose_vars, tid);
4267  _all_materials.updateBlockMatPropDependency(blk_id, needed_mat_props, tid);
4268  }
4269 
4270  const auto & ids = _mesh.getSubdomainBoundaryIds(blk_id);
4271  for (const auto id : ids)
4272  {
4273  _materials.updateBoundaryVariableDependency(id, needed_moose_vars, tid);
4274  _materials.updateBoundaryMatPropDependency(id, needed_mat_props, tid);
4275  }
4276 
4277  const auto & current_active_elemental_moose_variables = getActiveElementalMooseVariables(tid);
4278  needed_moose_vars.insert(current_active_elemental_moose_variables.begin(),
4279  current_active_elemental_moose_variables.end());
4280 
4281  needed_mat_props.insert(consumer_needed_mat_props.begin(), consumer_needed_mat_props.end());
4282 
4283  setActiveElementalMooseVariables(needed_moose_vars, tid);
4284  setActiveMaterialProperties(needed_mat_props, tid);
4285 }
void updateVariableDependency(std::set< MooseVariableFieldBase *> &needed_moose_vars, THREAD_ID tid=0) const
Update variable dependency vector.
void setActiveMaterialProperties(const std::unordered_set< unsigned int > &mat_prop_ids, const THREAD_ID tid)
Record and set the material properties required by the current computing thread.
bool hasActiveBlockObjects(THREAD_ID tid=0) const
const std::set< BoundaryID > & getSubdomainBoundaryIds(const SubdomainID subdomain_id) const
Get the list of boundary ids associated with the given subdomain id.
Definition: MooseMesh.C:3597
virtual const std::set< MooseVariableFieldBase * > & getActiveElementalMooseVariables(const THREAD_ID tid) const
Get the MOOSE variables to be reinited on each element.
Definition: SubProblem.C:455
virtual void setActiveElementalMooseVariables(const std::set< MooseVariableFEBase *> &moose_vars, const THREAD_ID tid) override
Set the MOOSE variables to be reinited on each element.
MooseMesh & _mesh
void updateBlockMatPropDependency(SubdomainID id, std::unordered_set< unsigned int > &needed_mat_props, THREAD_ID tid=0, const bool producer_only=false) const
void updateBoundaryMatPropDependency(std::unordered_set< unsigned int > &needed_mat_props, THREAD_ID tid=0, const bool producer_only=false) const
void updateBoundaryVariableDependency(std::set< MooseVariableFieldBase *> &needed_moose_vars, THREAD_ID tid=0) const
MaterialWarehouse _all_materials
MaterialWarehouse _materials

◆ prepareNeighborShapes()

void FEProblemBase::prepareNeighborShapes ( unsigned int  var,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2219 of file FEProblemBase.C.

2220 {
2221  _assembly[tid][_current_nl_sys->number()]->copyNeighborShapes(var);
2222 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.

◆ preparePRefinement()

void SubProblem::preparePRefinement ( )
inherited

Prepare DofMap and Assembly classes with our p-refinement information.

Definition at line 1337 of file SubProblem.C.

Referenced by FEProblemBase::init().

1338 {
1339  std::unordered_set<FEFamily> disable_families;
1340  for (const auto & [family, flag] : _family_for_p_refinement)
1341  if (flag)
1342  disable_families.insert(family);
1343 
1344  for (const auto tid : make_range(libMesh::n_threads()))
1345  for (const auto s : make_range(numNonlinearSystems()))
1346  assembly(tid, s).havePRefinement(disable_families);
1347 
1348  auto & eq = es();
1349  for (const auto family : disable_families)
1350  for (const auto i : make_range(eq.n_systems()))
1351  {
1352  auto & system = eq.get_system(i);
1353  auto & dof_map = system.get_dof_map();
1354  for (const auto vg : make_range(system.n_variable_groups()))
1355  {
1356  const auto & var_group = system.variable_group(vg);
1357  if (var_group.type().family == family)
1358  dof_map.should_p_refine(vg, false);
1359  }
1360  }
1361 
1362  _have_p_refinement = true;
1363 }
unsigned int n_threads()
virtual libMesh::EquationSystems & es()=0
std::unordered_map< FEFamily, bool > _family_for_p_refinement
Indicate whether a family is disabled for p-refinement.
Definition: SubProblem.h:1223
void havePRefinement(const std::unordered_set< FEFamily > &disable_p_refinement_for_families)
Indicate that we have p-refinement.
Definition: Assembly.C:4844
bool _have_p_refinement
Whether p-refinement has been requested at any point during the simulation.
Definition: SubProblem.h:1220
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int sys_num)=0
IntRange< T > make_range(T beg, T end)
virtual std::size_t numNonlinearSystems() const =0

◆ prepareShapes()

void FEProblemBase::prepareShapes ( unsigned int  var,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2207 of file FEProblemBase.C.

Referenced by ComputeUserObjectsThread::onElement().

2208 {
2209  _assembly[tid][_current_nl_sys->number()]->copyShapes(var);
2210 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.

◆ preserveMatrixSparsityPattern()

bool FEProblemBase::preserveMatrixSparsityPattern ( ) const
inlineinherited

Will return True if the executioner in use requires preserving the sparsity pattern of the matrices being formed during the solve.

This is usually the Jacobian.

Definition at line 2380 of file FEProblemBase.h.

bool _preserve_matrix_sparsity_pattern
Whether to preserve the system matrix / Jacobian sparsity pattern, using 0-valued entries usually...

◆ projectFunctionOnCustomRange()

void FEProblemBase::projectFunctionOnCustomRange ( ConstElemRange elem_range,
Number(*)(const Point &, const libMesh::Parameters &, const std::string &, const std::string &)  func,
Gradient(*)(const Point &, const libMesh::Parameters &, const std::string &, const std::string &)  func_grad,
const libMesh::Parameters params,
const std::vector< VariableName > &  target_vars 
)
inherited

Project a function onto a range of elements for a given variable.

Parameters
elem_rangeElement range to project on
funcFunction to project
func_gradGradient of the function
paramsParameters to pass to the function
target_varsvariable names to project

Definition at line 3967 of file FEProblemBase.C.

Referenced by ElementSubdomainModifierBase::extrapolatePolynomial().

3978 {
3979  mooseAssert(!Threads::in_threads,
3980  "We're performing a projection based on data from just the thread 0 variable, so any "
3981  "modifications to the variable solution must have been thread joined already");
3982 
3983  std::unordered_map<unsigned int, std::vector<unsigned int>> sys_to_var_nums;
3984 
3985  for (const auto & target_var : target_vars)
3986  {
3987  const auto sn = systemNumForVariable(target_var);
3988  const auto & var = getStandardVariable(0, target_var);
3989  sys_to_var_nums[sn].push_back(var.number());
3990  }
3991 
3992  for (const auto & [sys_num, var_nums] : sys_to_var_nums)
3993  {
3994  System & libmesh_sys = getSystemBase(sys_num).system();
3995  libmesh_sys.project_solution(func, func_grad, params, elem_range, var_nums);
3996  }
3997 }
virtual libMesh::System & system()=0
Get the reference to the libMesh system.
void project_solution(FunctionBase< Number > *f, FunctionBase< Gradient > *g=nullptr, std::optional< ConstElemRange > active_local_range=std::nullopt, std::optional< std::vector< unsigned int >> variable_numbers=std::nullopt) const
unsigned int systemNumForVariable(const VariableName &variable_name) const
virtual MooseVariable & getStandardVariable(const THREAD_ID tid, const std::string &var_name) override
Returns the variable reference for requested MooseVariable which may be in any system.
virtual const SystemBase & getSystemBase(const unsigned int sys_num) const
Get constant reference to a system in this problem.

◆ projectInitialConditionOnCustomRange()

void FEProblemBase::projectInitialConditionOnCustomRange ( libMesh::ConstElemRange elem_range,
ConstBndNodeRange bnd_node_range,
const std::optional< std::set< VariableName >> &  target_vars = std::nullopt 
)
inherited

Project initial conditions for custom elem_range and bnd_node_range This is needed when elements/boundary nodes are added to a specific subdomain at an intermediate step.

Parameters
elem_rangeElement range to project on
bnd_node_rangeBoundary node range to project on
target_varsSet of variable names to project ICs

Definition at line 3892 of file FEProblemBase.C.

Referenced by ElementSubdomainModifierBase::applyIC(), and ActivateElementsUserObjectBase::initSolutions().

3896 {
3897  if (target_vars)
3898  {
3899  ComputeInitialConditionThread cic(*this, &(*target_vars));
3900  Threads::parallel_reduce(elem_range, cic);
3901  }
3902  else
3903  {
3904  ComputeInitialConditionThread cic(*this);
3905  Threads::parallel_reduce(elem_range, cic);
3906  }
3907 
3908  // Need to close the solution vector here so that boundary ICs take precendence
3909  for (auto & nl : _nl)
3910  nl->solution().close();
3911  _aux->solution().close();
3912 
3913  if (target_vars)
3914  {
3915  ComputeBoundaryInitialConditionThread cbic(*this, &(*target_vars));
3916  Threads::parallel_reduce(bnd_nodes, cbic);
3917  }
3918  else
3919  {
3921  Threads::parallel_reduce(bnd_nodes, cbic);
3922  }
3923 
3924  for (auto & nl : _nl)
3925  nl->solution().close();
3926  _aux->solution().close();
3927 
3928  // Also, load values into the SCALAR dofs
3929  // Note: We assume that all SCALAR dofs are on the
3930  // processor with highest ID
3931  if (processor_id() == (n_processors() - 1) && _scalar_ics.hasActiveObjects())
3932  {
3933  const auto & ics = _scalar_ics.getActiveObjects();
3934  for (const auto & ic : ics)
3935  {
3936  MooseVariableScalar & var = ic->variable();
3937 
3938  if (target_vars && !target_vars->count(var.name()))
3939  continue;
3940 
3941  var.reinit();
3942 
3943  DenseVector<Number> vals(var.order());
3944  ic->compute(vals);
3945 
3946  const unsigned int n_scalar_dofs = var.dofIndices().size();
3947  for (unsigned int i = 0; i < n_scalar_dofs; i++)
3948  {
3949  const auto global_index = var.dofIndices()[i];
3950  var.sys().solution().set(global_index, vals(i));
3951  var.setValue(i, vals(i));
3952  }
3953  }
3954  }
3955 
3956  for (auto & nl : _nl)
3957  {
3958  nl->solution().close();
3959  nl->solution().localize(*nl->system().current_local_solution, nl->dofMap().get_send_list());
3960  }
3961 
3962  _aux->solution().close();
3963  _aux->solution().localize(*_aux->sys().current_local_solution, _aux->dofMap().get_send_list());
3964 }
NumericVector< Number > & solution()
Definition: SystemBase.h:197
void reinit(bool reinit_for_derivative_reordering=false)
Fill out the VariableValue arrays from the system solution vector.
void parallel_reduce(const Range &range, Body &body, const Partitioner &, unsigned int n_threads=libMesh::n_threads())
ScalarInitialConditionWarehouse _scalar_ics
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
processor_id_type n_processors() const
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void setValue(unsigned int i, Number value)
Set the nodal value for this variable (to keep everything up to date.
virtual const std::vector< dof_id_type > & dofIndices() const
Get local DoF indices.
libMesh::Order order() const
Get the order of this variable Note: Order enum can be implicitly converted to unsigned int...
bool hasActiveObjects(THREAD_ID tid=0) const
Class for scalar variables (they are different).
virtual void set(const numeric_index_type i, const T value)=0
processor_id_type processor_id() const
SystemBase & sys()
Get the system this variable is part of.

◆ projectSolution()

void FEProblemBase::projectSolution ( )
inherited

Definition at line 3826 of file FEProblemBase.C.

Referenced by FEProblemBase::initialAdaptMesh(), and FEProblemBase::initialSetup().

3827 {
3828  TIME_SECTION("projectSolution", 2, "Projecting Initial Solutions")
3829 
3830  FloatingPointExceptionGuard fpe_guard(_app);
3831 
3832  ComputeInitialConditionThread cic(*this);
3833  Threads::parallel_reduce(getCurrentAlgebraicElementRange(), cic);
3834 
3835  if (haveFV())
3836  {
3838  ElemInfoRange elem_info_range(_mesh.ownedElemInfoBegin(), _mesh.ownedElemInfoEnd());
3839 
3840  ComputeFVInitialConditionThread cfvic(*this);
3841  Threads::parallel_reduce(elem_info_range, cfvic);
3842  }
3843 
3844  // Need to close the solution vector here so that boundary ICs take precendence
3845  for (auto & nl : _nl)
3846  nl->solution().close();
3847  _aux->solution().close();
3848 
3849  // now run boundary-restricted initial conditions
3852 
3853  for (auto & nl : _nl)
3854  nl->solution().close();
3855  _aux->solution().close();
3856 
3857  // Also, load values into the SCALAR dofs
3858  // Note: We assume that all SCALAR dofs are on the
3859  // processor with highest ID
3860  if (processor_id() == (n_processors() - 1) && _scalar_ics.hasActiveObjects())
3861  {
3862  const auto & ics = _scalar_ics.getActiveObjects();
3863  for (const auto & ic : ics)
3864  {
3865  MooseVariableScalar & var = ic->variable();
3866  var.reinit();
3867 
3868  DenseVector<Number> vals(var.order());
3869  ic->compute(vals);
3870 
3871  const unsigned int n_scalar_dofs = var.dofIndices().size();
3872  for (unsigned int i = 0; i < n_scalar_dofs; i++)
3873  {
3874  const auto global_index = var.dofIndices()[i];
3875  var.sys().solution().set(global_index, vals(i));
3876  var.setValue(i, vals(i));
3877  }
3878  }
3879  }
3880 
3881  for (auto & sys : _solver_systems)
3882  {
3883  sys->solution().close();
3884  sys->solution().localize(*sys->system().current_local_solution, sys->dofMap().get_send_list());
3885  }
3886 
3887  _aux->solution().close();
3888  _aux->solution().localize(*_aux->sys().current_local_solution, _aux->dofMap().get_send_list());
3889 }
NumericVector< Number > & solution()
Definition: SystemBase.h:197
virtual bool haveFV() const override
returns true if this problem includes/needs finite volume functionality.
void reinit(bool reinit_for_derivative_reordering=false)
Fill out the VariableValue arrays from the system solution vector.
void parallel_reduce(const Range &range, Body &body, const Partitioner &, unsigned int n_threads=libMesh::n_threads())
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
const libMesh::ConstElemRange & getCurrentAlgebraicElementRange()
These are the element and nodes that contribute to the jacobian and residual for this local processor...
Scope guard for starting and stopping Floating Point Exception Trapping.
elem_info_iterator ownedElemInfoBegin()
Iterators to owned faceInfo objects.
Definition: MooseMesh.C:1516
ScalarInitialConditionWarehouse _scalar_ics
const ConstBndNodeRange & getCurrentAlgebraicBndNodeRange()
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
processor_id_type n_processors() const
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void setValue(unsigned int i, Number value)
Set the nodal value for this variable (to keep everything up to date.
MooseMesh & _mesh
virtual const std::vector< dof_id_type > & dofIndices() const
Get local DoF indices.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
libMesh::Order order() const
Get the order of this variable Note: Order enum can be implicitly converted to unsigned int...
bool hasActiveObjects(THREAD_ID tid=0) const
if(!dmm->_nl) SETERRQ(PETSC_COMM_WORLD
Class for scalar variables (they are different).
elem_info_iterator ownedElemInfoEnd()
Definition: MooseMesh.C:1524
virtual void set(const numeric_index_type i, const T value)=0
processor_id_type processor_id() const
SystemBase & sys()
Get the system this variable is part of.

◆ queryParam()

template<typename T >
const T * MooseBase::queryParam ( const std::string &  name) const
inherited

Query a parameter for the object.

If a parameter of the given name and type does not exist or if the parameter is not valid, nullptr will be returned

Parameters
nameThe name of the parameter
Returns
A pointer to the parameter value, if it exists

Definition at line 413 of file MooseBase.h.

Referenced by MFEMExecutedObject::getRequestedItems(), and MFEMGeometricMultigridSolver::MFEMGeometricMultigridSolver().

414 {
415  return _pars.queryParam<T>(name);
416 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const T * queryParam(const std::string &name) const
Query a parameter.

◆ rebalanceMesh()

void MFEMProblem::rebalanceMesh ( mfem::ParMesh &  pmesh)

Rebalance the (necessarily nonconforming) mesh.

Definition at line 746 of file MFEMProblem.C.

Referenced by MFEMRefinementMarker::hRefine().

747 {
748  if (pmesh.Nonconforming())
749  {
750  pmesh.Rebalance();
751  updateFESpaces();
753  }
754 }
void updateGridFunctions()
Calls Update() on all gridfunctions.
Definition: MFEMProblem.C:764
void updateFESpaces()
Calls Update() on all FE spaces.
Definition: MFEMProblem.C:757

◆ registerInvalidSolutionInternal()

InvalidSolutionID SolutionInvalidInterface::registerInvalidSolutionInternal ( const std::string &  message,
const bool  warning 
) const
protectedinherited

Definition at line 55 of file SolutionInvalidInterface.C.

57 {
59  _si_moose_base.type(), message, warning);
60 }
InvalidSolutionID registerInvalidity(const std::string &object_type, const std::string &message, const bool warning)
Call to register an invalid calculation.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
SolutionInvalidityRegistry & getSolutionInvalidityRegistry()
Get the global SolutionInvalidityRegistry singleton.
const MooseBase & _si_moose_base
The MooseBase that owns this interface.

◆ registerRandomInterface()

void FEProblemBase::registerRandomInterface ( RandomInterface random_interface,
const std::string &  name 
)
inherited

Definition at line 9298 of file FEProblemBase.C.

Referenced by RandomInterface::setRandomResetFrequency().

9299 {
9300  auto insert_pair = moose_try_emplace(
9301  _random_data_objects, name, std::make_unique<RandomData>(*this, random_interface));
9302 
9303  auto random_data_ptr = insert_pair.first->second.get();
9304  random_interface.setRandomDataPointer(random_data_ptr);
9305 }
std::pair< typename M::iterator, bool > moose_try_emplace(M &m, const typename M::key_type &k, Args &&... args)
Function to mirror the behavior of the C++17 std::map::try_emplace() method (no hint).
Definition: Moose.h:103
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
A map of objects that consume random numbers.
void setRandomDataPointer(RandomData *random_data)

◆ registerTimedSection() [1/2]

PerfID PerfGraphInterface::registerTimedSection ( const std::string &  section_name,
const unsigned int  level 
) const
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 61 of file PerfGraphInterface.C.

63 {
64  const auto timed_section_name = timedSectionName(section_name);
65  if (!moose::internal::getPerfGraphRegistry().sectionExists(timed_section_name))
66  return moose::internal::getPerfGraphRegistry().registerSection(timed_section_name, level);
67  else
68  return moose::internal::getPerfGraphRegistry().sectionID(timed_section_name);
69 }
PerfID registerSection(const std::string &section_name, const unsigned int level)
Call to register a named section for timing.
std::string timedSectionName(const std::string &section_name) const
PerfID sectionID(const std::string &section_name) const
Given a name return the PerfID The name of the section.
PerfGraphRegistry & getPerfGraphRegistry()
Get the global PerfGraphRegistry singleton.

◆ registerTimedSection() [2/2]

PerfID PerfGraphInterface::registerTimedSection ( const std::string &  section_name,
const unsigned int  level,
const std::string &  live_message,
const bool  print_dots = true 
) const
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)
live_messageThe message to be printed to the screen during execution
print_dotsWhether or not progress dots should be printed for this section
Returns
The ID of the section - use when starting timing

Definition at line 72 of file PerfGraphInterface.C.

76 {
77  const auto timed_section_name = timedSectionName(section_name);
78  if (!moose::internal::getPerfGraphRegistry().sectionExists(timed_section_name))
80  timedSectionName(section_name), level, live_message, print_dots);
81  else
82  return moose::internal::getPerfGraphRegistry().sectionID(timed_section_name);
83 }
PerfID registerSection(const std::string &section_name, const unsigned int level)
Call to register a named section for timing.
std::string timedSectionName(const std::string &section_name) const
PerfID sectionID(const std::string &section_name) const
Given a name return the PerfID The name of the section.
PerfGraphRegistry & getPerfGraphRegistry()
Get the global PerfGraphRegistry singleton.

◆ registerUnfilledFunctorRequest()

template<typename T >
void SubProblem::registerUnfilledFunctorRequest ( T *  functor_interface,
const std::string &  functor_name,
const THREAD_ID  tid 
)
inherited

Register an unfulfilled functor request.

◆ reinitBecauseOfGhostingOrNewGeomObjects()

void FEProblemBase::reinitBecauseOfGhostingOrNewGeomObjects ( bool  mortar_changed = false)
protectedinherited

Call when it is possible that the needs for ghosted elements has changed.

Parameters
mortar_changedWhether an update of mortar data has been requested since the last EquationSystems (re)initialization

Definition at line 5662 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup(), FEProblemBase::meshChanged(), and FEProblemBase::possiblyRebuildGeomSearchPatches().

5663 {
5664  TIME_SECTION("reinitBecauseOfGhostingOrNewGeomObjects",
5665  3,
5666  "Reinitializing Because of Geometric Search Objects");
5667 
5668  // Need to see if _any_ processor has ghosted elems or geometry objects.
5669  bool needs_reinit = !_ghosted_elems.empty();
5670  needs_reinit = needs_reinit || !_geometric_search_data._nearest_node_locators.empty() ||
5671  (_mortar_data->hasObjects() && mortar_changed);
5672  needs_reinit =
5673  needs_reinit || (_displaced_problem &&
5674  (!_displaced_problem->geomSearchData()._nearest_node_locators.empty() ||
5675  (_mortar_data->hasDisplacedObjects() && mortar_changed)));
5676  _communicator.max(needs_reinit);
5677 
5678  if (needs_reinit)
5679  {
5680  // Call reinit to get the ghosted vectors correct now that some geometric search has been done
5681  es().reinit();
5682 
5683  if (_displaced_mesh)
5684  _displaced_problem->es().reinit();
5685  }
5686 }
const Parallel::Communicator & _communicator
std::set< dof_id_type > _ghosted_elems
Elements that should have Dofs ghosted to the local processor.
Definition: SubProblem.h:1108
std::map< std::pair< BoundaryID, BoundaryID >, NearestNodeLocator * > _nearest_node_locators
virtual libMesh::EquationSystems & es() override
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data
void max(const T &r, T &o, Request &req) const
std::shared_ptr< DisplacedProblem > _displaced_problem
GeometricSearchData _geometric_search_data
MooseMesh * _displaced_mesh

◆ reinitDirac()

bool FEProblemBase::reinitDirac ( const Elem elem,
const THREAD_ID  tid 
)
overridevirtualinherited

Returns true if the Problem has Dirac kernels it needs to compute on elem.

The maximum number of qps can rise if several Dirac points are added to a single element. In that case we need to resize the zeros to compensate.

Implements SubProblem.

Definition at line 2258 of file FEProblemBase.C.

Referenced by ComputeDiracThread::onElement().

2259 {
2260  std::vector<Point> & points = _dirac_kernel_info.getPoints()[elem].first;
2261 
2262  unsigned int n_points = points.size();
2263 
2264  if (n_points)
2265  {
2266  if (n_points > _max_qps)
2267  {
2268  _max_qps = n_points;
2269 
2274  unsigned int max_qpts = getMaxQps();
2275  for (unsigned int tid = 0; tid < libMesh::n_threads(); ++tid)
2276  {
2277  // the highest available order in libMesh is 43
2278  _scalar_zero[tid].resize(FORTYTHIRD, 0);
2279  _zero[tid].resize(max_qpts, 0);
2280  _grad_zero[tid].resize(max_qpts, RealGradient(0.));
2281  _second_zero[tid].resize(max_qpts, RealTensor(0.));
2282  _vector_zero[tid].resize(max_qpts, RealGradient(0.));
2283  _vector_curl_zero[tid].resize(max_qpts, RealGradient(0.));
2284  }
2285  }
2286 
2287  for (const auto i : index_range(_nl))
2288  {
2289  _assembly[tid][i]->reinitAtPhysical(elem, points);
2290  _nl[i]->prepare(tid);
2291  }
2292  _aux->prepare(tid);
2293 
2294  reinitElem(elem, tid);
2295  }
2296 
2297  _assembly[tid][_current_nl_sys->number()]->prepare();
2299  _assembly[tid][_current_nl_sys->number()]->prepareNonlocal();
2300 
2301  bool have_points = n_points > 0;
2303  {
2304  have_points |= _displaced_problem->reinitDirac(_displaced_mesh->elemPtr(elem->id()), tid);
2306  _displaced_problem->prepareNonlocal(tid);
2307  }
2308 
2309  return have_points;
2310 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
unsigned int n_threads()
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.
std::vector< VariableSecond > _second_zero
std::vector< VectorVariableCurl > _vector_curl_zero
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
MultiPointMap & getPoints()
Returns a writeable reference to the _points container.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
dof_id_type id() const
virtual void reinitElem(const Elem *elem, const THREAD_ID tid) override
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::vector< VariableGradient > _grad_zero
std::vector< VariableValue > _scalar_zero
std::vector< VariableValue > _zero
std::shared_ptr< DisplacedProblem > _displaced_problem
std::vector< VectorVariableValue > _vector_zero
unsigned int _max_qps
Maximum number of quadrature points used in the problem.
DiracKernelInfo _dirac_kernel_info
Definition: SubProblem.h:1064
auto index_range(const T &sizable)
MooseMesh * _displaced_mesh
unsigned int getMaxQps() const

◆ reinitElem()

void FEProblemBase::reinitElem ( const Elem elem,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2313 of file FEProblemBase.C.

Referenced by NodalPatchRecovery::compute(), ComputeMarkerThread::onElement(), ComputeElemDampingThread::onElement(), ComputeIndicatorThread::onElement(), ComputeMaterialsObjectThread::onElement(), ComputeUserObjectsThread::onElement(), ComputeInitialConditionThread::operator()(), FEProblemBase::reinitDirac(), and FEProblemBase::reinitElemPhys().

2314 {
2315  for (auto & sys : _solver_systems)
2316  sys->reinitElem(elem, tid);
2317  _aux->reinitElem(elem, tid);
2318 
2320  _displaced_problem->reinitElem(_displaced_mesh->elemPtr(elem->id()), tid);
2321 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
dof_id_type id() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseMesh * _displaced_mesh

◆ reinitElemFace() [1/2]

void FEProblemBase::reinitElemFace ( const Elem *  elem,
unsigned int  side,
BoundaryID  ,
const THREAD_ID  tid 
)
inherited

◆ reinitElemFace() [2/2]

virtual void FEProblemBase::reinitElemFace ( const Elem *  elem,
unsigned int  side,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

◆ reinitElemFaceRef()

void FEProblemBase::reinitElemFaceRef ( const Elem elem,
unsigned int  side,
Real  tolerance,
const std::vector< Point > *const  pts,
const std::vector< Real > *const  weights = nullptr,
const THREAD_ID  tid = 0 
)
overridevirtualinherited

reinitialize FE objects on a given element on a given side at a given set of reference points and then compute variable data.

Note that this method makes no assumptions about what's been called beforehand, e.g. you don't have to call some prepare method before this one. This is an all-in-one reinit

Reimplemented from SubProblem.

Definition at line 9655 of file FEProblemBase.C.

Referenced by Moose::Mortar::loopOverMortarSegments().

9661 {
9662  SubProblem::reinitElemFaceRef(elem, side, tolerance, pts, weights, tid);
9663 
9664  if (_displaced_problem)
9665  _displaced_problem->reinitElemFaceRef(
9666  _displaced_mesh->elemPtr(elem->id()), side, tolerance, pts, weights, tid);
9667 }
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
dof_id_type id() const
virtual void reinitElemFaceRef(const Elem *elem, unsigned int side, Real tolerance, const std::vector< Point > *const pts, const std::vector< Real > *const weights=nullptr, const THREAD_ID tid=0)
reinitialize FE objects on a given element on a given side at a given set of reference points and the...
Definition: SubProblem.C:883
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseMesh * _displaced_mesh

◆ reinitElemNeighborAndLowerD()

void FEProblemBase::reinitElemNeighborAndLowerD ( const Elem elem,
unsigned int  side,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2499 of file FEProblemBase.C.

Referenced by ComputeMaterialsObjectThread::onInternalSide(), and NonlinearThread::onInternalSide().

2502 {
2503  reinitNeighbor(elem, side, tid);
2504 
2505  const Elem * lower_d_elem = _mesh.getLowerDElem(elem, side);
2506  if (lower_d_elem && _mesh.interiorLowerDBlocks().count(lower_d_elem->subdomain_id()) > 0)
2507  reinitLowerDElem(lower_d_elem, tid);
2508  else
2509  {
2510  // with mesh refinement, lower-dimensional element might be defined on neighbor side
2511  auto & neighbor = _assembly[tid][0]->neighbor();
2512  auto & neighbor_side = _assembly[tid][0]->neighborSide();
2513  const Elem * lower_d_elem_neighbor = _mesh.getLowerDElem(neighbor, neighbor_side);
2514  if (lower_d_elem_neighbor &&
2515  _mesh.interiorLowerDBlocks().count(lower_d_elem_neighbor->subdomain_id()) > 0)
2516  {
2517  auto qps = _assembly[tid][0]->qPointsFaceNeighbor().stdVector();
2518  std::vector<Point> reference_points;
2519  FEMap::inverse_map(
2520  lower_d_elem_neighbor->dim(), lower_d_elem_neighbor, qps, reference_points);
2521  reinitLowerDElem(lower_d_elem_neighbor, tid, &reference_points);
2522  }
2523  }
2524 
2526  _displaced_problem->reinitElemNeighborAndLowerD(
2527  _displaced_mesh->elemPtr(elem->id()), side, tid);
2528 }
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
const std::set< SubdomainID > & interiorLowerDBlocks() const
Definition: MooseMesh.h:1552
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
const Elem * getLowerDElem(const Elem *, unsigned short int) const
Returns a const pointer to a lower dimensional element that corresponds to a side of a higher dimensi...
Definition: MooseMesh.C:1688
dof_id_type id() const
MooseMesh & _mesh
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
virtual void reinitLowerDElem(const Elem *lower_d_elem, const THREAD_ID tid, const std::vector< Point > *const pts=nullptr, const std::vector< Real > *const weights=nullptr) override
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
subdomain_id_type subdomain_id() const
virtual unsigned short dim() const=0
std::shared_ptr< DisplacedProblem > _displaced_problem
virtual void reinitNeighbor(const Elem *elem, unsigned int side, const THREAD_ID tid) override
MooseMesh * _displaced_mesh

◆ reinitElemPhys()

void FEProblemBase::reinitElemPhys ( const Elem elem,
const std::vector< Point > &  phys_points_in_elem,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2324 of file FEProblemBase.C.

Referenced by MultiAppVariableValueSamplePostprocessorTransfer::execute().

2327 {
2328  mooseAssert(_mesh.queryElemPtr(elem->id()) == elem,
2329  "Are you calling this method with a displaced mesh element?");
2330 
2331  for (const auto i : index_range(_solver_systems))
2332  {
2333  _assembly[tid][i]->reinitAtPhysical(elem, phys_points_in_elem);
2334  _solver_systems[i]->prepare(tid);
2335  _assembly[tid][i]->prepare();
2337  _assembly[tid][i]->prepareNonlocal();
2338  }
2339  _aux->prepare(tid);
2340 
2341  reinitElem(elem, tid);
2342 }
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
virtual Elem * queryElemPtr(const dof_id_type i)
Definition: MooseMesh.C:3225
dof_id_type id() const
virtual void reinitElem(const Elem *elem, const THREAD_ID tid) override
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseMesh & _mesh
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
auto index_range(const T &sizable)

◆ reinitFVFace()

void SubProblem::reinitFVFace ( const THREAD_ID  tid,
const FaceInfo fi 
)
inherited

reinitialize the finite volume assembly data for the provided face and thread

Definition at line 1289 of file SubProblem.C.

1290 {
1291  for (const auto nl : make_range(numNonlinearSystems()))
1292  assembly(tid, nl).reinitFVFace(fi);
1293 }
void reinitFVFace(const FaceInfo &fi)
Definition: Assembly.C:1859
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int sys_num)=0
IntRange< T > make_range(T beg, T end)
virtual std::size_t numNonlinearSystems() const =0

◆ reinitGeomSearch()

void SubProblem::reinitGeomSearch ( )
inherited

reinitialize this object's geometric search data, e.g.

do things like clear and re-add quadrature nodes

Definition at line 1407 of file SubProblem.C.

1408 {
1409  geomSearchData().reinit();
1410 }
void reinit()
Completely redo all geometric search objects.
virtual GeometricSearchData & geomSearchData()=0

◆ reinitKokkosMaterials()

void FEProblemBase::reinitKokkosMaterials ( )
inherited

◆ reinitLowerDElem()

void FEProblemBase::reinitLowerDElem ( const Elem lower_d_elem,
const THREAD_ID  tid,
const std::vector< Point > *const  pts = nullptr,
const std::vector< Real > *const  weights = nullptr 
)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 2372 of file FEProblemBase.C.

Referenced by ComputeUserObjectsThread::onBoundary(), NonlinearThread::prepareFace(), and FEProblemBase::reinitElemNeighborAndLowerD().

2376 {
2377  SubProblem::reinitLowerDElem(lower_d_elem, tid, pts, weights);
2378 
2380  _displaced_problem->reinitLowerDElem(
2381  _displaced_mesh->elemPtr(lower_d_elem->id()), tid, pts, weights);
2382 }
virtual void reinitLowerDElem(const Elem *lower_d_elem, const THREAD_ID tid, const std::vector< Point > *const pts=nullptr, const std::vector< Real > *const weights=nullptr)
Definition: SubProblem.C:958
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
dof_id_type id() const
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseMesh * _displaced_mesh

◆ reinitMaterials()

void FEProblemBase::reinitMaterials ( SubdomainID  blk_id,
const THREAD_ID  tid,
bool  swap_stateful = true 
)
inherited

Definition at line 4288 of file FEProblemBase.C.

Referenced by NodalPatchRecovery::compute(), ComputeMarkerThread::onElement(), ComputeIndicatorThread::onElement(), ComputeDiracThread::onElement(), and ComputeUserObjectsThread::onElement().

4289 {
4290  if (hasActiveMaterialProperties(tid))
4291  {
4292  auto && elem = _assembly[tid][0]->elem();
4293  unsigned int n_points = _assembly[tid][0]->qRule()->n_points();
4294 
4295  auto & material_data = _material_props.getMaterialData(tid);
4296  material_data.resize(n_points);
4297 
4298  // Only swap if requested
4299  if (swap_stateful)
4300  material_data.swap(*elem);
4301 
4302  if (_discrete_materials.hasActiveBlockObjects(blk_id, tid))
4303  material_data.reset(_discrete_materials.getActiveBlockObjects(blk_id, tid));
4304 
4305  if (_materials.hasActiveBlockObjects(blk_id, tid))
4306  material_data.reinit(_materials.getActiveBlockObjects(blk_id, tid));
4307  }
4308 }
bool hasActiveBlockObjects(THREAD_ID tid=0) const
const std::map< SubdomainID, std::vector< std::shared_ptr< T > > > & getActiveBlockObjects(THREAD_ID tid=0) const
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
MaterialWarehouse _discrete_materials
const MaterialData & getMaterialData(const THREAD_ID tid) const
MaterialPropertyStorage & _material_props
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.
void resize(unsigned int n_qpoints)
Resize the data to hold properties for n_qpoints quadrature points.
Definition: MaterialData.C:21
MaterialWarehouse _materials

◆ reinitMaterialsBoundary()

void FEProblemBase::reinitMaterialsBoundary ( BoundaryID  boundary_id,
const THREAD_ID  tid,
bool  swap_stateful = true,
const std::deque< MaterialBase *> *  reinit_mats = nullptr 
)
inherited

reinit materials on a boundary

Parameters
boundary_idThe boundary on which to reinit corresponding materials
tidThe thread id
swap_statefulWhether to swap stateful material properties between MaterialData and MaterialPropertyStorage
execute_statefulWhether to execute material objects that have stateful properties. This should be false when for example executing material objects for mortar contexts in which stateful properties don't make sense
reinit_matsspecific list of materials to reinit. Used notably in the context of mortar with stateful elements

Definition at line 4433 of file FEProblemBase.C.

Referenced by Moose::Mortar::loopOverMortarSegments(), ComputeUserObjectsThread::onBoundary(), NonlinearThread::onInterface(), ComputeUserObjectsThread::onInterface(), and NonlinearThread::prepareFace().

4437 {
4438  if (hasActiveMaterialProperties(tid) && needBoundaryMaterialOnSide(boundary_id, tid))
4439  {
4440  auto && elem = _assembly[tid][0]->elem();
4441  unsigned int side = _assembly[tid][0]->side();
4442  unsigned int n_points = _assembly[tid][0]->qRuleFace()->n_points();
4443 
4444  auto & bnd_material_data = _bnd_material_props.getMaterialData(tid);
4445  bnd_material_data.resize(n_points);
4446 
4447  if (swap_stateful && !bnd_material_data.isSwapped())
4448  bnd_material_data.swap(*elem, side);
4449 
4450  if (_discrete_materials.hasActiveBoundaryObjects(boundary_id, tid))
4451  bnd_material_data.reset(_discrete_materials.getActiveBoundaryObjects(boundary_id, tid));
4452 
4453  if (reinit_mats)
4454  bnd_material_data.reinit(*reinit_mats);
4455  else if (_materials.hasActiveBoundaryObjects(boundary_id, tid))
4456  bnd_material_data.reinit(_materials.getActiveBoundaryObjects(boundary_id, tid));
4457  }
4458 }
MaterialPropertyStorage & _bnd_material_props
bool needBoundaryMaterialOnSide(BoundaryID bnd_id, const THREAD_ID tid)
These methods are used to determine whether stateful material properties need to be stored on interna...
bool hasActiveBoundaryObjects(THREAD_ID tid=0) const
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
const std::map< BoundaryID, std::vector< std::shared_ptr< T > > > & getActiveBoundaryObjects(THREAD_ID tid=0) const
MaterialWarehouse _discrete_materials
const MaterialData & getMaterialData(const THREAD_ID tid) const
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.
void resize(unsigned int n_qpoints)
Resize the data to hold properties for n_qpoints quadrature points.
Definition: MaterialData.C:21
MaterialWarehouse _materials

◆ reinitMaterialsFace()

void FEProblemBase::reinitMaterialsFace ( SubdomainID  blk_id,
const THREAD_ID  tid,
bool  swap_stateful = true,
const std::deque< MaterialBase *> *  reinit_mats = nullptr 
)
inherited

reinit materials on element faces

Parameters
blk_idThe subdomain on which the element owning the face lives
tidThe thread id
swap_statefulWhether to swap stateful material properties between MaterialData and MaterialPropertyStorage
reinit_matsspecific list of materials to reinit. Used notably in the context of mortar with stateful elements

Definition at line 4311 of file FEProblemBase.C.

Referenced by Moose::Mortar::loopOverMortarSegments(), ComputeIndicatorThread::onInternalSide(), NonlinearThread::onInternalSide(), ComputeUserObjectsThread::onInternalSide(), and NonlinearThread::prepareFace().

4315 {
4316  // we reinit more often than needed here because we dont have a way to check whether
4317  // we need to compute the face materials on a particular (possibly external) face
4318  if (hasActiveMaterialProperties(tid))
4319  {
4320  auto && elem = _assembly[tid][0]->elem();
4321  unsigned int side = _assembly[tid][0]->side();
4322  unsigned int n_points = _assembly[tid][0]->qRuleFace()->n_points();
4323 
4324  auto & bnd_material_data = _bnd_material_props.getMaterialData(tid);
4325  bnd_material_data.resize(n_points);
4326 
4327  if (swap_stateful && !bnd_material_data.isSwapped())
4328  bnd_material_data.swap(*elem, side);
4329 
4330  if (_discrete_materials[Moose::FACE_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
4331  bnd_material_data.reset(
4332  _discrete_materials[Moose::FACE_MATERIAL_DATA].getActiveBlockObjects(blk_id, tid));
4333 
4334  if (reinit_mats)
4335  bnd_material_data.reinit(*reinit_mats);
4336  else if (_materials[Moose::FACE_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
4337  bnd_material_data.reinit(
4338  _materials[Moose::FACE_MATERIAL_DATA].getActiveBlockObjects(blk_id, tid));
4339  }
4340 }
MaterialPropertyStorage & _bnd_material_props
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
MaterialWarehouse _discrete_materials
const MaterialData & getMaterialData(const THREAD_ID tid) const
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.
void resize(unsigned int n_qpoints)
Resize the data to hold properties for n_qpoints quadrature points.
Definition: MaterialData.C:21
MaterialWarehouse _materials

◆ reinitMaterialsFaceOnBoundary()

void FEProblemBase::reinitMaterialsFaceOnBoundary ( const BoundaryID  boundary_id,
const SubdomainID  blk_id,
const THREAD_ID  tid,
const bool  swap_stateful = true,
const std::deque< MaterialBase *> *const  reinit_mats = nullptr 
)
inherited

reinit materials on element faces on a boundary (internal or external) This specific routine helps us not reinit when don't need to

Parameters
boundary_idThe boundary on which the face belongs
blk_idThe block id to which the element (who owns the face) belong
tidThe thread id
swap_statefulWhether to swap stateful material properties between MaterialData and MaterialPropertyStorage
reinit_matsspecific list of materials to reinit. Used notably in the context of mortar with stateful elements

Definition at line 4343 of file FEProblemBase.C.

Referenced by ComputeUserObjectsThread::onBoundary(), NonlinearThread::onInterface(), ComputeUserObjectsThread::onInterface(), and NonlinearThread::prepareFace().

4348 {
4349  if (hasActiveMaterialProperties(tid) && (needBoundaryMaterialOnSide(boundary_id, tid) ||
4350  needInterfaceMaterialOnSide(boundary_id, tid) ||
4351  needInternalNeighborSideMaterial(blk_id, tid)))
4352  {
4353  const auto * const elem = _assembly[tid][0]->elem();
4354  unsigned int side = _assembly[tid][0]->side();
4355  unsigned int n_points = _assembly[tid][0]->qRuleFace()->n_points();
4356 
4357  auto & bnd_material_data = _bnd_material_props.getMaterialData(tid);
4358  bnd_material_data.resize(n_points);
4359 
4360  if (swap_stateful && !bnd_material_data.isSwapped())
4361  bnd_material_data.swap(*elem, side);
4362 
4363  if (_discrete_materials[Moose::FACE_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
4364  bnd_material_data.reset(
4365  _discrete_materials[Moose::FACE_MATERIAL_DATA].getActiveBlockObjects(blk_id, tid));
4366 
4367  if (reinit_mats)
4368  bnd_material_data.reinit(*reinit_mats);
4369  else if (_materials[Moose::FACE_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
4370  bnd_material_data.reinit(
4371  _materials[Moose::FACE_MATERIAL_DATA].getActiveBlockObjects(blk_id, tid));
4372  }
4373 }
MaterialPropertyStorage & _bnd_material_props
bool needBoundaryMaterialOnSide(BoundaryID bnd_id, const THREAD_ID tid)
These methods are used to determine whether stateful material properties need to be stored on interna...
bool needInternalNeighborSideMaterial(SubdomainID subdomain_id, const THREAD_ID tid)
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
MaterialWarehouse _discrete_materials
bool needInterfaceMaterialOnSide(BoundaryID bnd_id, const THREAD_ID tid)
const MaterialData & getMaterialData(const THREAD_ID tid) const
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.
void resize(unsigned int n_qpoints)
Resize the data to hold properties for n_qpoints quadrature points.
Definition: MaterialData.C:21
MaterialWarehouse _materials

◆ reinitMaterialsInterface()

void FEProblemBase::reinitMaterialsInterface ( BoundaryID  boundary_id,
const THREAD_ID  tid,
bool  swap_stateful = true 
)
inherited

Definition at line 4461 of file FEProblemBase.C.

Referenced by NonlinearThread::onInterface(), and ComputeUserObjectsThread::onInterface().

4464 {
4465  if (hasActiveMaterialProperties(tid) && needInterfaceMaterialOnSide(boundary_id, tid))
4466  {
4467  const Elem * const & elem = _assembly[tid][0]->elem();
4468  unsigned int side = _assembly[tid][0]->side();
4469  unsigned int n_points = _assembly[tid][0]->qRuleFace()->n_points();
4470 
4471  auto & bnd_material_data = _bnd_material_props.getMaterialData(tid);
4472  bnd_material_data.resize(n_points);
4473 
4474  if (swap_stateful && !bnd_material_data.isSwapped())
4475  bnd_material_data.swap(*elem, side);
4476 
4477  if (_interface_materials.hasActiveBoundaryObjects(boundary_id, tid))
4478  bnd_material_data.reinit(_interface_materials.getActiveBoundaryObjects(boundary_id, tid));
4479  }
4480 }
MaterialPropertyStorage & _bnd_material_props
MaterialWarehouse _interface_materials
bool hasActiveBoundaryObjects(THREAD_ID tid=0) const
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
const std::map< BoundaryID, std::vector< std::shared_ptr< T > > > & getActiveBoundaryObjects(THREAD_ID tid=0) const
bool needInterfaceMaterialOnSide(BoundaryID bnd_id, const THREAD_ID tid)
const MaterialData & getMaterialData(const THREAD_ID tid) const
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.
void resize(unsigned int n_qpoints)
Resize the data to hold properties for n_qpoints quadrature points.
Definition: MaterialData.C:21

◆ reinitMaterialsNeighbor()

void FEProblemBase::reinitMaterialsNeighbor ( SubdomainID  blk_id,
const THREAD_ID  tid,
bool  swap_stateful = true,
const std::deque< MaterialBase *> *  reinit_mats = nullptr 
)
inherited

reinit materials on the neighboring element face

Parameters
blk_idThe subdomain on which the neighbor element lives
tidThe thread id
swap_statefulWhether to swap stateful material properties between MaterialData and MaterialPropertyStorage
reinit_matsspecific list of materials to reinit. Used notably in the context of mortar with stateful elements

Definition at line 4393 of file FEProblemBase.C.

Referenced by Moose::Mortar::loopOverMortarSegments(), ComputeUserObjectsThread::onInterface(), ComputeIndicatorThread::onInternalSide(), NonlinearThread::onInternalSide(), ComputeUserObjectsThread::onInternalSide(), FEProblemBase::reinitMaterialsNeighborOnBoundary(), and NonlinearSystemBase::reinitNodeFace().

4397 {
4398  if (hasActiveMaterialProperties(tid))
4399  {
4400  // NOTE: this will not work with h-adaptivity
4401  // lindsayad: why not?
4402 
4403  const Elem * neighbor = _assembly[tid][0]->neighbor();
4404  unsigned int neighbor_side = neighbor->which_neighbor_am_i(_assembly[tid][0]->elem());
4405 
4406  mooseAssert(neighbor, "neighbor should be non-null");
4407  mooseAssert(blk_id == neighbor->subdomain_id(),
4408  "The provided blk_id " << blk_id << " and neighbor subdomain ID "
4409  << neighbor->subdomain_id() << " do not match.");
4410 
4411  unsigned int n_points = _assembly[tid][0]->qRuleNeighbor()->n_points();
4412 
4413  auto & neighbor_material_data = _neighbor_material_props.getMaterialData(tid);
4414  neighbor_material_data.resize(n_points);
4415 
4416  // Only swap if requested
4417  if (swap_stateful)
4418  neighbor_material_data.swap(*neighbor, neighbor_side);
4419 
4420  if (_discrete_materials[Moose::NEIGHBOR_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
4421  neighbor_material_data.reset(
4422  _discrete_materials[Moose::NEIGHBOR_MATERIAL_DATA].getActiveBlockObjects(blk_id, tid));
4423 
4424  if (reinit_mats)
4425  neighbor_material_data.reinit(*reinit_mats);
4426  else if (_materials[Moose::NEIGHBOR_MATERIAL_DATA].hasActiveBlockObjects(blk_id, tid))
4427  neighbor_material_data.reinit(
4428  _materials[Moose::NEIGHBOR_MATERIAL_DATA].getActiveBlockObjects(blk_id, tid));
4429  }
4430 }
unsigned int which_neighbor_am_i(const Elem *e) const
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
MaterialWarehouse _discrete_materials
subdomain_id_type subdomain_id() const
MaterialPropertyStorage & _neighbor_material_props
const MaterialData & getMaterialData(const THREAD_ID tid) const
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.
void resize(unsigned int n_qpoints)
Resize the data to hold properties for n_qpoints quadrature points.
Definition: MaterialData.C:21
MaterialWarehouse _materials

◆ reinitMaterialsNeighborOnBoundary()

void FEProblemBase::reinitMaterialsNeighborOnBoundary ( const BoundaryID  boundary_id,
const SubdomainID  blk_id,
const THREAD_ID  tid,
const bool  swap_stateful = true,
const std::deque< MaterialBase *> *const  reinit_mats = nullptr 
)
inherited

reinit materials on neighbor element (usually faces) on a boundary (internal or external) This specific routine helps us not reinit when don't need to

Parameters
boundary_idThe boundary on which the face belongs
blk_idThe block id to which the element (who owns the face) belong
tidThe thread id
swap_statefulWhether to swap stateful material properties between MaterialData and MaterialPropertyStorage
reinit_matsspecific list of materials to reinit. Used notably in the context of mortar with stateful elements

Definition at line 4376 of file FEProblemBase.C.

Referenced by NonlinearThread::onInterface().

4382 {
4383  // Since objects don't declare whether they need the face or neighbor (side) material properties,
4384  // we use the same criteria for skipping material property computations as for face material
4385  // properties This could be a future optimization.
4386  if (hasActiveMaterialProperties(tid) && (needBoundaryMaterialOnSide(boundary_id, tid) ||
4387  needInterfaceMaterialOnSide(boundary_id, tid) ||
4388  needInternalNeighborSideMaterial(blk_id, tid)))
4389  reinitMaterialsNeighbor(blk_id, tid, swap_stateful, reinit_mats);
4390 }
bool needBoundaryMaterialOnSide(BoundaryID bnd_id, const THREAD_ID tid)
These methods are used to determine whether stateful material properties need to be stored on interna...
void reinitMaterialsNeighbor(SubdomainID blk_id, const THREAD_ID tid, bool swap_stateful=true, const std::deque< MaterialBase *> *reinit_mats=nullptr)
reinit materials on the neighboring element face
bool needInternalNeighborSideMaterial(SubdomainID subdomain_id, const THREAD_ID tid)
bool needInterfaceMaterialOnSide(BoundaryID bnd_id, const THREAD_ID tid)
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.

◆ reinitMortarElem()

void SubProblem::reinitMortarElem ( const Elem elem,
const THREAD_ID  tid = 0 
)
inherited

Reinit a mortar element to obtain a valid JxW.

Definition at line 995 of file SubProblem.C.

Referenced by Moose::Mortar::loopOverMortarSegments().

996 {
997  for (const auto nl_sys_num : make_range(numNonlinearSystems()))
998  assembly(tid, nl_sys_num).reinitMortarElem(elem);
999 }
void reinitMortarElem(const Elem *elem)
reinitialize a mortar segment mesh element in order to get a proper JxW
Definition: Assembly.C:2406
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int sys_num)=0
IntRange< T > make_range(T beg, T end)
virtual std::size_t numNonlinearSystems() const =0

◆ reinitMortarUserObjects()

void FEProblemBase::reinitMortarUserObjects ( BoundaryID  primary_boundary_id,
BoundaryID  secondary_boundary_id,
bool  displaced 
)
inherited

Call reinit on mortar user objects with matching primary boundary ID, secondary boundary ID, and displacement characteristics.

Definition at line 9920 of file FEProblemBase.C.

Referenced by Moose::Mortar::loopOverMortarSegments().

9923 {
9924  const auto mortar_uos =
9925  getMortarUserObjects(primary_boundary_id, secondary_boundary_id, displaced);
9926  for (auto * const mortar_uo : mortar_uos)
9927  {
9928  mortar_uo->setNormals();
9929  mortar_uo->reinit();
9930  }
9931 }
std::vector< MortarUserObject * > getMortarUserObjects(BoundaryID primary_boundary_id, BoundaryID secondary_boundary_id, bool displaced, const std::vector< MortarUserObject *> &mortar_uo_superset)
Helper for getting mortar objects corresponding to primary boundary ID, secondary boundary ID...

◆ reinitNeighbor()

void FEProblemBase::reinitNeighbor ( const Elem elem,
unsigned int  side,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2460 of file FEProblemBase.C.

Referenced by ComputeMaterialsObjectThread::onInterface(), NonlinearThread::onInterface(), ComputeUserObjectsThread::onInterface(), ComputeIndicatorThread::onInternalSide(), ComputeUserObjectsThread::onInternalSide(), and FEProblemBase::reinitElemNeighborAndLowerD().

2461 {
2462  setNeighborSubdomainID(elem, side, tid);
2463 
2464  const Elem * neighbor = elem->neighbor_ptr(side);
2465  unsigned int neighbor_side = neighbor->which_neighbor_am_i(elem);
2466 
2467  for (const auto i : index_range(_nl))
2468  {
2469  _assembly[tid][i]->reinitElemAndNeighbor(elem, side, neighbor, neighbor_side);
2470  _nl[i]->prepareNeighbor(tid);
2471  // Called during stateful material property evaluation outside of solve
2472  _assembly[tid][i]->prepareNeighbor();
2473  }
2474  _aux->prepareNeighbor(tid);
2475 
2476  for (auto & nl : _nl)
2477  {
2478  nl->reinitElemFace(elem, side, tid);
2479  nl->reinitNeighborFace(neighbor, neighbor_side, tid);
2480  }
2481  _aux->reinitElemFace(elem, side, tid);
2482  _aux->reinitNeighborFace(neighbor, neighbor_side, tid);
2483 
2485  {
2486  // There are cases like for cohesive zone modeling without significant sliding where we cannot
2487  // use FEInterface::inverse_map in Assembly::reinitElemAndNeighbor in the displaced problem
2488  // because the physical points coming from the element don't actually lie on the neighbor.
2489  // Moreover, what's the point of doing another physical point inversion in other cases? We only
2490  // care about the reference points which we can just take from the undisplaced computation
2491  const auto & displaced_ref_pts = _assembly[tid][0]->qRuleNeighbor()->get_points();
2492 
2493  _displaced_problem->reinitNeighbor(
2494  _displaced_mesh->elemPtr(elem->id()), side, tid, &displaced_ref_pts);
2495  }
2496 }
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
dof_id_type id() const
unsigned int which_neighbor_am_i(const Elem *e) const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
const Elem * neighbor_ptr(unsigned int i) const
std::shared_ptr< DisplacedProblem > _displaced_problem
virtual void setNeighborSubdomainID(const Elem *elem, unsigned int side, const THREAD_ID tid) override
auto index_range(const T &sizable)
MooseMesh * _displaced_mesh

◆ reinitNeighborFaceRef()

void FEProblemBase::reinitNeighborFaceRef ( const Elem neighbor_elem,
unsigned int  neighbor_side,
Real  tolerance,
const std::vector< Point > *const  pts,
const std::vector< Real > *const  weights = nullptr,
const THREAD_ID  tid = 0 
)
overridevirtualinherited

reinitialize FE objects on a given neighbor element on a given side at a given set of reference points and then compute variable data.

Note that this method makes no assumptions about what's been called beforehand, e.g. you don't have to call some prepare method before this one. This is an all-in-one reinit

Reimplemented from SubProblem.

Definition at line 9670 of file FEProblemBase.C.

Referenced by Moose::Mortar::loopOverMortarSegments().

9676 {
9677  SubProblem::reinitNeighborFaceRef(neighbor_elem, neighbor_side, tolerance, pts, weights, tid);
9678 
9679  if (_displaced_problem)
9680  _displaced_problem->reinitNeighborFaceRef(
9681  _displaced_mesh->elemPtr(neighbor_elem->id()), neighbor_side, tolerance, pts, weights, tid);
9682 }
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
virtual void reinitNeighborFaceRef(const Elem *neighbor_elem, unsigned int neighbor_side, Real tolerance, const std::vector< Point > *const pts, const std::vector< Real > *const weights=nullptr, const THREAD_ID tid=0)
reinitialize FE objects on a given neighbor element on a given side at a given set of reference point...
Definition: SubProblem.C:922
dof_id_type id() const
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseMesh * _displaced_mesh

◆ reinitNeighborLowerDElem()

void SubProblem::reinitNeighborLowerDElem ( const Elem elem,
const THREAD_ID  tid = 0 
)
inherited

reinitialize a neighboring lower dimensional element

Definition at line 988 of file SubProblem.C.

Referenced by Moose::Mortar::loopOverMortarSegments().

989 {
990  for (const auto nl_sys_num : make_range(numNonlinearSystems()))
991  assembly(tid, nl_sys_num).reinitNeighborLowerDElem(elem);
992 }
void reinitNeighborLowerDElem(const Elem *elem)
reinitialize a neighboring lower dimensional element
Definition: Assembly.C:2385
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int sys_num)=0
IntRange< T > make_range(T beg, T end)
virtual std::size_t numNonlinearSystems() const =0

◆ reinitNeighborPhys() [1/2]

virtual void FEProblemBase::reinitNeighborPhys ( const Elem *  neighbor,
unsigned int  neighbor_side,
const std::vector< Point > &  physical_points,
const THREAD_ID  tid 
)
overridevirtualinherited

◆ reinitNeighborPhys() [2/2]

virtual void FEProblemBase::reinitNeighborPhys ( const Elem *  neighbor,
const std::vector< Point > &  physical_points,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

◆ reinitNode()

void FEProblemBase::reinitNode ( const Node node,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2385 of file FEProblemBase.C.

Referenced by NodalPatchRecovery::compute(), NonlinearSystemBase::computeResidualInternal(), ComputeNodalUserObjectsThread::onNode(), ComputeNodalDampingThread::onNode(), ComputeNodalKernelsThread::onNode(), and ComputeNodalKernelJacobiansThread::onNode().

2386 {
2388  _displaced_problem->reinitNode(&_displaced_mesh->nodeRef(node->id()), tid);
2389 
2390  for (const auto i : index_range(_nl))
2391  {
2392  _assembly[tid][i]->reinit(node);
2393  _nl[i]->reinitNode(node, tid);
2394  }
2395  _aux->reinitNode(node, tid);
2396 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
virtual const Node & nodeRef(const dof_id_type i) const
Definition: MooseMesh.C:839
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
dof_id_type id() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
auto index_range(const T &sizable)
MooseMesh * _displaced_mesh

◆ reinitNodeFace()

void FEProblemBase::reinitNodeFace ( const Node node,
BoundaryID  bnd_id,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2399 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeJacobianBlocks(), NonlinearSystemBase::computeNodalBCsJacobian(), NonlinearSystemBase::computeNodalBCsResidual(), NonlinearSystemBase::computeNodalBCsResidualAndJacobian(), NonlinearSystemBase::constraintJacobians(), NonlinearSystemBase::constraintResiduals(), ComputeNodalKernelBcsThread::onNode(), ComputeNodalKernelBCJacobiansThread::onNode(), NonlinearSystemBase::reinitNodeFace(), NonlinearSystemBase::setConstraintSecondaryValues(), and NonlinearSystemBase::setInitialSolution().

2400 {
2402  _displaced_problem->reinitNodeFace(&_displaced_mesh->nodeRef(node->id()), bnd_id, tid);
2403 
2404  for (const auto i : index_range(_nl))
2405  {
2406  _assembly[tid][i]->reinit(node);
2407  _nl[i]->reinitNodeFace(node, bnd_id, tid);
2408  }
2409  _aux->reinitNodeFace(node, bnd_id, tid);
2410 }
virtual const Node & nodeRef(const dof_id_type i) const
Definition: MooseMesh.C:839
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
dof_id_type id() const
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
std::shared_ptr< DisplacedProblem > _displaced_problem
auto index_range(const T &sizable)
MooseMesh * _displaced_mesh

◆ reinitNodes()

void FEProblemBase::reinitNodes ( const std::vector< dof_id_type > &  nodes,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2413 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::enforceNodalConstraintsJacobian(), and NonlinearSystemBase::enforceNodalConstraintsResidual().

2414 {
2416  _displaced_problem->reinitNodes(nodes, tid);
2417 
2418  for (auto & nl : _nl)
2419  nl->reinitNodes(nodes, tid);
2420  _aux->reinitNodes(nodes, tid);
2421 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ reinitNodesNeighbor()

void FEProblemBase::reinitNodesNeighbor ( const std::vector< dof_id_type > &  nodes,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 2424 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::enforceNodalConstraintsJacobian(), and NonlinearSystemBase::enforceNodalConstraintsResidual().

2425 {
2427  _displaced_problem->reinitNodesNeighbor(nodes, tid);
2428 
2429  for (auto & nl : _nl)
2430  nl->reinitNodesNeighbor(nodes, tid);
2431  _aux->reinitNodesNeighbor(nodes, tid);
2432 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ reinitOffDiagScalars()

void FEProblemBase::reinitOffDiagScalars ( const THREAD_ID  tid)
overridevirtualinherited

Implements SubProblem.

Definition at line 2452 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeScalarKernelsJacobians(), NonlinearSystemBase::constraintJacobians(), and NonlinearThread::onElement().

2453 {
2454  _assembly[tid][_current_nl_sys->number()]->prepareOffDiagScalar();
2455  if (_displaced_problem)
2456  _displaced_problem->reinitOffDiagScalars(tid);
2457 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ reinitScalars()

void FEProblemBase::reinitScalars ( const THREAD_ID  tid,
bool  reinit_for_derivative_reordering = false 
)
overridevirtualinherited

fills the VariableValue arrays for scalar variables from the solution vector

Parameters
tidThe thread id
reinit_for_derivative_reorderingA flag indicating whether we are reinitializing for the purpose of re-ordering derivative information for ADNodalBCs

Implements SubProblem.

Definition at line 2435 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::computeJacobianBlocks(), NonlinearSystemBase::computeJacobianInternal(), FEProblemBase::computeJacobianTags(), NonlinearSystemBase::computeNodalBCsJacobian(), FEProblemBase::computeResidualAndJacobian(), NonlinearSystemBase::computeResidualAndJacobianInternal(), NonlinearSystemBase::computeResidualInternal(), FEProblemBase::computeResidualTags(), NonlinearSystemBase::computeScalarKernelsJacobians(), AuxiliarySystem::computeScalarVars(), and FEProblemBase::initialSetup().

2436 {
2437  TIME_SECTION("reinitScalars", 3, "Reinitializing Scalar Variables");
2438 
2440  _displaced_problem->reinitScalars(tid, reinit_for_derivative_reordering);
2441 
2442  for (auto & nl : _nl)
2443  nl->reinitScalars(tid, reinit_for_derivative_reordering);
2444  _aux->reinitScalars(tid, reinit_for_derivative_reordering);
2445 
2446  // This is called outside of residual/Jacobian call-backs
2447  for (auto & assembly : _assembly[tid])
2449 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
void prepareScalar()
Definition: Assembly.C:2953
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int sys_num) override
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ removeAlgebraicGhostingFunctor()

void SubProblem::removeAlgebraicGhostingFunctor ( libMesh::GhostingFunctor algebraic_gf)
inherited

Remove an algebraic ghosting functor from this problem's DofMaps.

Definition at line 1068 of file SubProblem.C.

1069 {
1070  EquationSystems & eq = es();
1071  const auto n_sys = eq.n_systems();
1072  DofMap & nl_dof_map = eq.get_system(0).get_dof_map();
1073 
1074  const bool found_in_root_sys =
1076  nl_dof_map.algebraic_ghosting_functors_end(),
1077  &algebraic_gf) != nl_dof_map.algebraic_ghosting_functors_end();
1078 
1079 #ifndef NDEBUG
1080  const bool found_in_our_map =
1081  _root_alg_gf_to_sys_clones.find(&algebraic_gf) != _root_alg_gf_to_sys_clones.end();
1082  mooseAssert(found_in_root_sys == found_in_our_map,
1083  "If the ghosting functor exists in the root DofMap, then we need to have a key for "
1084  "it in our gf to clones map");
1085 #endif
1086 
1087  if (found_in_root_sys) // libMesh yells if we try to remove
1088  // something that's not there
1089  nl_dof_map.remove_algebraic_ghosting_functor(algebraic_gf);
1090 
1091  auto it = _root_alg_gf_to_sys_clones.find(&algebraic_gf);
1092  if (it == _root_alg_gf_to_sys_clones.end())
1093  return;
1094 
1095  auto & clones_vec = it->second;
1096  mooseAssert((n_sys - 1) == clones_vec.size(),
1097  "The size of the gf clones vector doesn't match the number of systems minus one");
1098  if (clones_vec.empty())
1099  {
1100  mooseAssert(n_sys == 1, "The clones vector should only be empty if there is only one system");
1101  return;
1102  }
1103 
1104  for (const auto i : make_range(n_sys))
1105  eq.get_system(i + 1).get_dof_map().remove_algebraic_ghosting_functor(*clones_vec[i]);
1106 
1107  _root_alg_gf_to_sys_clones.erase(it->first);
1108 }
KOKKOS_INLINE_FUNCTION const T * find(const T &target, const T *const begin, const T *const end)
Find a value in an array.
Definition: KokkosUtils.h:40
unsigned int n_systems() const
GhostingFunctorIterator algebraic_ghosting_functors_begin() const
GhostingFunctorIterator algebraic_ghosting_functors_end() const
const T_sys & get_system(std::string_view name) const
virtual libMesh::EquationSystems & es()=0
std::unordered_map< libMesh::GhostingFunctor *, std::vector< std::shared_ptr< libMesh::GhostingFunctor > > > _root_alg_gf_to_sys_clones
A map from a root algebraic ghosting functor, e.g.
Definition: SubProblem.h:1210
IntRange< T > make_range(T beg, T end)
void remove_algebraic_ghosting_functor(GhostingFunctor &evaluable_functor)

◆ removeCouplingGhostingFunctor()

void SubProblem::removeCouplingGhostingFunctor ( libMesh::GhostingFunctor coupling_gf)
inherited

Remove a coupling ghosting functor from this problem's DofMaps.

Definition at line 1111 of file SubProblem.C.

1112 {
1113  EquationSystems & eq = es();
1114  const auto num_nl_sys = numNonlinearSystems();
1115  if (!num_nl_sys)
1116  return;
1117 
1118  DofMap & nl_dof_map = eq.get_system(0).get_dof_map();
1119  const bool found_in_root_sys = std::find(nl_dof_map.coupling_functors_begin(),
1120  nl_dof_map.coupling_functors_end(),
1121  &coupling_gf) != nl_dof_map.coupling_functors_end();
1122 
1123 #ifndef NDEBUG
1124  const bool found_in_our_map =
1126  mooseAssert(found_in_root_sys == found_in_our_map,
1127  "If the ghosting functor exists in the root DofMap, then we need to have a key for "
1128  "it in our gf to clones map");
1129 #endif
1130 
1131  if (found_in_root_sys) // libMesh yells if we try to remove
1132  // something that's not there
1133  nl_dof_map.remove_coupling_functor(coupling_gf);
1134 
1135  auto it = _root_coupling_gf_to_sys_clones.find(&coupling_gf);
1136  if (it == _root_coupling_gf_to_sys_clones.end())
1137  return;
1138 
1139  auto & clones_vec = it->second;
1140  mooseAssert((num_nl_sys - 1) == clones_vec.size(),
1141  "The size of the gf clones vector doesn't match the number of systems minus one");
1142  if (clones_vec.empty())
1143  {
1144  mooseAssert(num_nl_sys == 1,
1145  "The clones vector should only be empty if there is only one nonlinear system");
1146  return;
1147  }
1148 
1149  for (const auto i : make_range(num_nl_sys))
1150  eq.get_system(i + 1).get_dof_map().remove_coupling_functor(*clones_vec[i]);
1151 
1152  _root_coupling_gf_to_sys_clones.erase(it->first);
1153 }
KOKKOS_INLINE_FUNCTION const T * find(const T &target, const T *const begin, const T *const end)
Find a value in an array.
Definition: KokkosUtils.h:40
std::unordered_map< libMesh::GhostingFunctor *, std::vector< std::shared_ptr< libMesh::GhostingFunctor > > > _root_coupling_gf_to_sys_clones
A map from a root coupling ghosting functor, e.g.
Definition: SubProblem.h:1217
const T_sys & get_system(std::string_view name) const
virtual libMesh::EquationSystems & es()=0
GhostingFunctorIterator coupling_functors_end() const
void remove_coupling_functor(GhostingFunctor &coupling_functor)
IntRange< T > make_range(T beg, T end)
virtual std::size_t numNonlinearSystems() const =0
GhostingFunctorIterator coupling_functors_begin() const

◆ reportMooseObjectDependency()

void FEProblemBase::reportMooseObjectDependency ( MooseObject a,
MooseObject b 
)
inherited

Register a MOOSE object dependency so we can either order operations properly or report when we cannot.

a -> b (a depends on b)

Definition at line 5656 of file FEProblemBase.C.

5657 {
5658  //<< "Object " << a->name() << " -> " << b->name() << std::endl;
5659 }

◆ resetFailNextNonlinearConvergenceCheck()

void FEProblemBase::resetFailNextNonlinearConvergenceCheck ( )
inlineinherited

Tell the problem that the nonlinear convergence check(s) may proceed as normal.

Definition at line 2867 of file FEProblemBase.h.

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

void resetFailNextSystemConvergenceCheck()
Tell the problem that the system convergence check(s) may proceed as normal.

◆ resetFailNextSystemConvergenceCheck()

void FEProblemBase::resetFailNextSystemConvergenceCheck ( )
inlineinherited

Tell the problem that the system convergence check(s) may proceed as normal.

Definition at line 2869 of file FEProblemBase.h.

Referenced by Moose::PetscSupport::petscLinearConverged(), and FEProblemBase::resetFailNextNonlinearConvergenceCheck().

bool _fail_next_system_convergence_check

◆ residualSetup()

void FEProblemBase::residualSetup ( )
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 9820 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::residualSetup().

9821 {
9823  // We need to setup all the nonlinear systems other than our current one which actually called
9824  // this method (so we have to make sure we don't go in a circle)
9825  for (const auto i : make_range(numNonlinearSystems()))
9826  if (i != currentNlSysNum())
9827  _nl[i]->residualSetup();
9828  // We don't setup the aux sys because that's been done elsewhere
9829  if (_displaced_problem)
9830  _displaced_problem->residualSetup();
9831 }
virtual std::size_t numNonlinearSystems() const override
virtual void residualSetup()
Definition: SubProblem.C:1204
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
virtual unsigned int currentNlSysNum() const override
IntRange< T > make_range(T beg, T end)
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ resizeMaterialData()

void FEProblemBase::resizeMaterialData ( Moose::MaterialDataType  data_type,
unsigned int  nqp,
const THREAD_ID  tid 
)
inherited

Resize material data.

Parameters
data_typeThe type of material data to resize
nqpThe number of quadrature points to resize for
tidThe thread ID

Definition at line 9741 of file FEProblemBase.C.

9744 {
9745  getMaterialData(data_type, tid).resize(nqp);
9746 }
MPI_Datatype data_type
MaterialData & getMaterialData(Moose::MaterialDataType type, const THREAD_ID tid=0, const MooseObject *object=nullptr) const
void resize(unsigned int n_qpoints)
Resize the data to hold properties for n_qpoints quadrature points.
Definition: MaterialData.C:21

◆ resolveMFEMSolvers()

void MFEMProblem::resolveMFEMSolvers ( )
virtual

Construct recorded MFEM solvers in dependency order and select the problem driver solver(s).

Reimplemented in MFEMEigenproblem.

Definition at line 157 of file MFEMProblem.C.

Referenced by MFEMEigenproblem::resolveMFEMSolvers().

158 {
159  if (_mfem_solver_definitions.empty())
160  return;
161 
163 
164  for (auto & [solver_name, definition] : _mfem_solver_definitions)
165  {
166  const auto dependencies = getMFEMSolverDependencies(*definition.parameters);
167  if (dependencies.empty())
168  resolver.addNode(solver_name);
169 
170  for (const auto & dependency_name : dependencies)
171  {
172  auto dependency_it = _mfem_solver_definitions.find(dependency_name);
173  if (dependency_it == _mfem_solver_definitions.end())
174  mooseError("MFEM solver '",
175  solver_name,
176  "' references MFEM solver '",
177  dependency_name,
178  "', but no solver with that name was provided in the [Solvers] block.");
179 
180  dependency_it->second.referenced = true;
181  resolver.addEdge(dependency_name, solver_name);
182  }
183  }
184 
185  const std::vector<std::string> * sorted_solver_names = nullptr;
186  try
187  {
188  sorted_solver_names = &resolver.getSortedValues();
189  }
191  {
192  mooseError("Cyclic MFEM solver dependency detected: ",
193  MooseUtils::join(e.getCyclicDependencies(), " <- "));
194  }
195 
196  auto & problem_data = getProblemData();
197  mooseAssert(!problem_data.jacobian_solver, "MFEM linear solver driver already assigned");
198  mooseAssert(!problem_data.nonlinear_solver, "MFEM nonlinear solver driver already assigned");
199 
200  for (const auto & solver_name : *sorted_solver_names)
201  {
202  auto & definition = libmesh_map_find(_mfem_solver_definitions, solver_name);
203  auto solver =
204  addObject<Moose::MFEM::SolverBase>(definition.type, solver_name, *definition.parameters)
205  .front();
206 
207  if (definition.referenced)
208  continue;
209 
210  if (auto lin_solver = std::dynamic_pointer_cast<Moose::MFEM::LinearSolverBase>(solver))
211  {
212  if (problem_data.jacobian_solver)
213  mooseError("Multiple MFEM linear solver drivers provided. '",
214  problem_data.jacobian_solver->name(),
215  "' and '",
216  lin_solver->name(),
217  "' are not referenced by another MFEM solver.");
218  problem_data.jacobian_solver = lin_solver;
219  }
220  else if (auto nonlinear_solver =
221  std::dynamic_pointer_cast<Moose::MFEM::NonlinearSolverBase>(solver);
222  nonlinear_solver)
223  {
224  if (problem_data.nonlinear_solver)
225  mooseError("Multiple MFEM nonlinear solver drivers provided. '",
226  problem_data.nonlinear_solver->name(),
227  "' and '",
228  nonlinear_solver->name(),
229  "' are not referenced by another MFEM solver.");
230  problem_data.nonlinear_solver = nonlinear_solver;
231  }
232  else
233  mooseError("Unsupported MFEM solver object type '",
234  solver->type(),
235  "' for solver '",
236  solver->name(),
237  "'.");
238  }
239 
240  _mfem_solver_definitions.clear();
241 }
std::map< std::string, MFEMSolverDefinition > _mfem_solver_definitions
Solver definitions recorded by AddMFEMSolverAction before the dependency resolver constructs them...
Definition: MFEMProblem.h:410
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
const std::vector< T > & getSortedValues()
This function also returns dependency resolved values but with a simpler single vector interface...
void addEdge(const T &a, const T &b)
Add an edge between nodes &#39;a&#39; and &#39;b&#39;.
void addNode(const T &a)
Add a node &#39;a&#39; to the graph.
const std::vector< T > & getCyclicDependencies() const
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ restartableName()

std::string Restartable::restartableName ( const std::string &  data_name) const
protectedinherited

Gets the name of a piece of restartable data given a data name, adding the system name and object name prefix.

This should only be used in this interface and in testing.

Definition at line 78 of file Restartable.C.

Referenced by Restartable::declareRecoverableData(), and Restartable::declareRestartableDataHelper().

79 {
80  return _restartable_system_name + "/" + _restartable_name + "/" + data_name;
81 }
std::string _restartable_name
The name of the object.
Definition: Restartable.h:250
const std::string _restartable_system_name
The system name this object is in.
Definition: Restartable.h:237

◆ restoreMultiApps()

void FEProblemBase::restoreMultiApps ( ExecFlagType  type,
bool  force = false 
)
inherited

Restore the MultiApps associated with the ExecFlagType.

Parameters
forceForce restoration because something went wrong with the solve

Definition at line 6097 of file FEProblemBase.C.

Referenced by TransientBase::incrementStepOrReject(), and FixedPointSolve::solve().

6098 {
6099  const auto & multi_apps = _multi_apps[type].getActiveObjects();
6100 
6101  if (multi_apps.size())
6102  {
6103  if (_verbose_multiapps)
6104  {
6105  if (force)
6106  _console << COLOR_CYAN << "\nRestoring Multiapps on " << type.name()
6107  << " because of solve failure!" << COLOR_DEFAULT << std::endl;
6108  else
6109  _console << COLOR_CYAN << "\nRestoring MultiApps on " << type.name() << COLOR_DEFAULT
6110  << std::endl;
6111  }
6112 
6113  for (const auto & multi_app : multi_apps)
6114  multi_app->restore(force);
6115 
6117 
6118  if (_verbose_multiapps)
6119  _console << COLOR_CYAN << "Finished Restoring MultiApps on " << type.name() << "\n"
6120  << COLOR_DEFAULT << std::endl;
6121  }
6122 }
bool _parallel_barrier_messaging
Whether or not information about how many transfers have completed is printed.
const Parallel::Communicator & _communicator
const std::vector< std::shared_ptr< T > > & getActiveObjects(THREAD_ID tid=0) const
Retrieve complete vector to the active all/block/boundary restricted objects for a given thread...
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
void parallelBarrierNotify(const Parallel::Communicator &comm, bool messaging)
Definition: MooseUtils.C:327
bool _verbose_multiapps
Whether or not to be verbose with multiapps.

◆ restoreOldSolutions()

void FEProblemBase::restoreOldSolutions ( )
virtualinherited

Restore old solutions from the backup vectors and deallocate them.

Definition at line 7255 of file FEProblemBase.C.

Referenced by EigenExecutionerBase::inversePowerIteration().

7256 {
7257  TIME_SECTION("restoreOldSolutions", 5, "Restoring Old Solutions");
7258 
7259  for (auto & sys : _solver_systems)
7260  sys->restoreOldSolutions();
7261  _aux->restoreOldSolutions();
7262 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ restoreOriginalNonzeroPattern()

bool FEProblemBase::restoreOriginalNonzeroPattern ( ) const
inlineinherited
Returns
Whether the original matrix nonzero pattern is restored before each Jacobian assembly

Definition at line 2360 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::computeJacobianInternal().

const bool _restore_original_nonzero_pattern
Whether we should restore the original nonzero pattern for every Jacobian evaluation.

◆ restoreSolutions()

void FEProblemBase::restoreSolutions ( )
virtualinherited

Definition at line 7217 of file FEProblemBase.C.

Referenced by ActivateElementsUserObjectBase::initSolutions(), TimeStepper::rejectStep(), and FEProblemBase::updateMeshXFEM().

7218 {
7219  TIME_SECTION("restoreSolutions", 5, "Restoring Solutions");
7220 
7221  if (!_not_zeroed_tagged_vectors.empty())
7222  paramError("not_zeroed_tag_vectors",
7223  "There is currently no way to restore not-zeroed vectors.");
7224 
7225  for (auto & sys : _solver_systems)
7226  {
7227  if (_verbose_restore)
7228  _console << "Restoring solutions on system " << sys->name() << "..." << std::endl;
7229  sys->restoreSolutions();
7230  }
7231 
7232  if (_verbose_restore)
7233  _console << "Restoring solutions on Auxiliary system..." << std::endl;
7234  _aux->restoreSolutions();
7235 
7236  if (_verbose_restore)
7237  _console << "Restoring postprocessor, vector-postprocessor, and reporter data..." << std::endl;
7239 
7240  if (_displaced_problem)
7241  _displaced_problem->updateMesh();
7242 }
void paramError(const std::string &param, Args... args) const
Emits an error prefixed with the file and line number of the given param (from the input file) along ...
Definition: MooseBase.h:457
std::unordered_set< TagID > _not_zeroed_tagged_vectors
the list of vector tags that will not be zeroed when all other tags are
Definition: SubProblem.h:1132
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
bool _verbose_restore
Whether or not to be verbose on solution restoration post a failed time step.
ReporterData _reporter_data
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
std::shared_ptr< DisplacedProblem > _displaced_problem
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
void restoreState(bool verbose=false)
When a time step fails, this method is called to revert the current reporter values to their old stat...
Definition: ReporterData.C:24

◆ safeAccessTaggedMatrices()

virtual bool SubProblem::safeAccessTaggedMatrices ( ) const
inlinevirtualinherited

Is it safe to access the tagged matrices.

Reimplemented in DisplacedProblem.

Definition at line 739 of file SubProblem.h.

Referenced by MooseVariableScalar::reinit(), and DisplacedProblem::safeAccessTaggedMatrices().

bool _safe_access_tagged_matrices
Is it safe to retrieve data from tagged matrices.
Definition: SubProblem.h:1123

◆ safeAccessTaggedVectors()

virtual bool SubProblem::safeAccessTaggedVectors ( ) const
inlinevirtualinherited

Is it safe to access the tagged vectors.

Reimplemented in DisplacedProblem.

Definition at line 742 of file SubProblem.h.

Referenced by MooseVariableScalar::reinit(), and DisplacedProblem::safeAccessTaggedVectors().

742 { return _safe_access_tagged_vectors; }
bool _safe_access_tagged_vectors
Is it safe to retrieve data from tagged vectors.
Definition: SubProblem.h:1126

◆ saveOldSolutions()

void FEProblemBase::saveOldSolutions ( )
virtualinherited

Allocate vectors and save old solutions into them.

Definition at line 7245 of file FEProblemBase.C.

Referenced by EigenExecutionerBase::inversePowerIteration().

7246 {
7247  TIME_SECTION("saveOldSolutions", 5, "Saving Old Solutions");
7248 
7249  for (auto & sys : _solver_systems)
7250  sys->saveOldSolutions();
7251  _aux->saveOldSolutions();
7252 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ selectMatrixTagsFromSystem()

void SubProblem::selectMatrixTagsFromSystem ( const SystemBase system,
const std::map< TagName, TagID > &  input_matrix_tags,
std::set< TagID > &  selected_tags 
)
staticinherited

Select the matrix tags which belong to a specific system.

Parameters
systemReference to the system
input_matrix_tagsA map of matrix tags
selected_tagsA set which gets populated by the tag-ids that belong to the system

Definition at line 301 of file SubProblem.C.

Referenced by FEProblemBase::computeLinearSystemSys().

304 {
305  selected_tags.clear();
306  for (const auto & matrix_tag_pair : input_matrix_tags)
307  if (system.hasMatrix(matrix_tag_pair.second))
308  selected_tags.insert(matrix_tag_pair.second);
309 }
virtual bool hasMatrix(TagID tag) const
Check if the tagged matrix exists in the system.
Definition: SystemBase.h:361

◆ selectVectorTagsFromSystem()

void SubProblem::selectVectorTagsFromSystem ( const SystemBase system,
const std::vector< VectorTag > &  input_vector_tags,
std::set< TagID > &  selected_tags 
)
staticinherited

Select the vector tags which belong to a specific system.

Parameters
systemReference to the system
input_vector_tagsA vector of vector tags
selected_tagsA set which gets populated by the tag-ids that belong to the system

Definition at line 290 of file SubProblem.C.

Referenced by FEProblemBase::computeLinearSystemSys(), FEProblemBase::computeResidualAndJacobian(), and ComputeResidualAndJacobianThread::determineObjectWarehouses().

293 {
294  selected_tags.clear();
295  for (const auto & vector_tag : input_vector_tags)
296  if (system.hasVector(vector_tag._id))
297  selected_tags.insert(vector_tag._id);
298 }
bool hasVector(const std::string &tag_name) const
Check if the named vector exists in the system.
Definition: SystemBase.C:925

◆ setActiveElementalMooseVariables()

void FEProblemBase::setActiveElementalMooseVariables ( const std::set< MooseVariableFEBase *> &  moose_vars,
const THREAD_ID  tid 
)
overridevirtualinherited

Set the MOOSE variables to be reinited on each element.

Parameters
moose_varsA set of variables that need to be reinited each time reinit() is called.
tidThe thread id

Reimplemented from SubProblem.

Definition at line 6384 of file FEProblemBase.C.

Referenced by FEProblemBase::prepareMaterials(), ComputeMarkerThread::subdomainChanged(), ComputeMaterialsObjectThread::subdomainChanged(), ComputeIndicatorThread::subdomainChanged(), ComputeDiracThread::subdomainChanged(), NonlinearThread::subdomainChanged(), and ComputeUserObjectsThread::subdomainChanged().

6386 {
6388 
6389  if (_displaced_problem)
6390  _displaced_problem->setActiveElementalMooseVariables(moose_vars, tid);
6391 }
virtual void setActiveElementalMooseVariables(const std::set< MooseVariableFieldBase *> &moose_vars, const THREAD_ID tid)
Set the MOOSE variables to be reinited on each element.
Definition: SubProblem.C:444
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ setActiveFEVariableCoupleableMatrixTags()

void FEProblemBase::setActiveFEVariableCoupleableMatrixTags ( std::set< TagID > &  mtags,
const THREAD_ID  tid 
)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 6346 of file FEProblemBase.C.

6347 {
6349 
6350  if (_displaced_problem)
6351  _displaced_problem->setActiveFEVariableCoupleableMatrixTags(mtags, tid);
6352 }
virtual void setActiveFEVariableCoupleableMatrixTags(std::set< TagID > &mtags, const THREAD_ID tid)
Definition: SubProblem.C:364
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ setActiveFEVariableCoupleableVectorTags()

void FEProblemBase::setActiveFEVariableCoupleableVectorTags ( std::set< TagID > &  vtags,
const THREAD_ID  tid 
)
overridevirtualinherited

◆ setActiveMaterialProperties()

void FEProblemBase::setActiveMaterialProperties ( const std::unordered_set< unsigned int > &  mat_prop_ids,
const THREAD_ID  tid 
)
inherited

Record and set the material properties required by the current computing thread.

Parameters
mat_prop_idsThe set of material properties required by the current computing thread.
tidThe thread id

Definition at line 6439 of file FEProblemBase.C.

Referenced by Moose::Mortar::loopOverMortarSegments(), FEProblemBase::prepareMaterials(), NodalPatchRecovery::reinitPatch(), NonlinearSystemBase::setConstraintSecondaryValues(), and ComputeDiracThread::subdomainChanged().

6441 {
6442  // mark active properties in every material
6443  for (auto & mat : _all_materials.getObjects(tid))
6444  mat->setActiveProperties(mat_prop_ids);
6445  for (auto & mat : _all_materials[Moose::FACE_MATERIAL_DATA].getObjects(tid))
6446  mat->setActiveProperties(mat_prop_ids);
6447  for (auto & mat : _all_materials[Moose::NEIGHBOR_MATERIAL_DATA].getObjects(tid))
6448  mat->setActiveProperties(mat_prop_ids);
6449 
6450  _has_active_material_properties[tid] = !mat_prop_ids.empty();
6451 }
const std::vector< std::shared_ptr< T > > & getObjects(THREAD_ID tid=0) const
Retrieve complete vector to the all/block/boundary restricted objects for a given thread...
std::vector< unsigned char > _has_active_material_properties
Whether there are active material properties on each thread.
MaterialWarehouse _all_materials

◆ setActiveScalarVariableCoupleableMatrixTags()

void FEProblemBase::setActiveScalarVariableCoupleableMatrixTags ( std::set< TagID > &  mtags,
const THREAD_ID  tid 
)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 6364 of file FEProblemBase.C.

Referenced by AuxiliarySystem::setScalarVariableCoupleableTags().

6366 {
6368 
6369  if (_displaced_problem)
6370  _displaced_problem->setActiveScalarVariableCoupleableMatrixTags(mtags, tid);
6371 }
virtual void setActiveScalarVariableCoupleableMatrixTags(std::set< TagID > &mtags, const THREAD_ID tid)
Definition: SubProblem.C:403
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ setActiveScalarVariableCoupleableVectorTags()

void FEProblemBase::setActiveScalarVariableCoupleableVectorTags ( std::set< TagID > &  vtags,
const THREAD_ID  tid 
)
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 6374 of file FEProblemBase.C.

Referenced by AuxiliarySystem::setScalarVariableCoupleableTags().

6376 {
6378 
6379  if (_displaced_problem)
6380  _displaced_problem->setActiveScalarVariableCoupleableVectorTags(vtags, tid);
6381 }
virtual void setActiveScalarVariableCoupleableVectorTags(std::set< TagID > &vtags, const THREAD_ID tid)
Definition: SubProblem.C:410
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ setAxisymmetricCoordAxis()

void FEProblemBase::setAxisymmetricCoordAxis ( const MooseEnum rz_coord_axis)
inherited

Definition at line 874 of file FEProblemBase.C.

875 {
876  _mesh.setAxisymmetricCoordAxis(rz_coord_axis);
877 }
MooseMesh & _mesh
void setAxisymmetricCoordAxis(const MooseEnum &rz_coord_axis)
For axisymmetric simulations, set the symmetry coordinate axis.
Definition: MooseMesh.C:4333

◆ setChainControlDataOutput()

void SubProblem::setChainControlDataOutput ( bool  set_output)
inlineinherited

Setter for debug chain control data output.

Definition at line 934 of file SubProblem.h.

934 { _show_chain_control_data = set_output; }
bool _show_chain_control_data
Whether to output a list of all the chain control data.
Definition: SubProblem.h:1182

◆ setCheckResidualForNans()

void FEProblemBase::setCheckResidualForNans ( bool  check_residual_for_nans)
inlineinherited

Setter for residual NaN/Inf checking.

Definition at line 234 of file FEProblemBase.h.

235  {
236  _check_residual_for_nans = check_residual_for_nans;
237  }
bool _check_residual_for_nans
Whether to check the residual for NaN or Inf values.

◆ setConstJacobian()

void FEProblemBase::setConstJacobian ( bool  state)
inlineinherited

Set flag that Jacobian is constant (for optimization purposes)

Parameters
stateTrue if the Jacobian is constant, false otherwise

Definition at line 2203 of file FEProblemBase.h.

Referenced by ExplicitEuler::preSolve(), ExplicitTVDRK2::preSolve(), and ExplicitRK2::preSolve().

2203 { _const_jacobian = state; }
bool _const_jacobian
true if the Jacobian is constant

◆ setCoordSystem()

void FEProblemBase::setCoordSystem ( const std::vector< SubdomainName > &  blocks,
const MultiMooseEnum coord_sys 
)
inherited

Definition at line 866 of file FEProblemBase.C.

868 {
869  TIME_SECTION("setCoordSystem", 5, "Setting Coordinate System");
870  _mesh.setCoordSystem(blocks, coord_sys);
871 }
char ** blocks
MooseMesh & _mesh
void setCoordSystem(const std::vector< SubdomainName > &blocks, const MultiMooseEnum &coord_sys)
Set the coordinate system for the provided blocks to coord_sys.
Definition: MooseMesh.C:4201

◆ setCoupling()

void FEProblemBase::setCoupling ( Moose::CouplingType  type)
inherited

Set the coupling between variables TODO: allow user-defined coupling.

Parameters
typeType of coupling

Definition at line 6615 of file FEProblemBase.C.

Referenced by FEProblemBase::init(), FEProblemBase::setCouplingMatrix(), and Moose::SlepcSupport::setEigenProblemSolverParams().

6616 {
6618  {
6620  mooseError("Someone told us (the FEProblemBase) to trust the user coupling matrix, but we "
6621  "haven't been provided a coupling matrix!");
6622 
6623  // We've been told to trust the user coupling matrix, so we're going to leave things alone
6624  return;
6625  }
6626 
6627  _coupling = type;
6628 }
bool _trust_user_coupling_matrix
Whether to trust the user coupling matrix no matter what.
Moose::CouplingType _coupling
Type of variable coupling.
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ setCouplingMatrix() [1/2]

void FEProblemBase::setCouplingMatrix ( std::unique_ptr< libMesh::CouplingMatrix cm,
const unsigned int  nl_sys_num 
)
inherited

Set custom coupling matrix.

Parameters
cmcoupling matrix to be set
nl_sys_numwhich nonlinear system we are setting the coupling matrix for

Definition at line 6639 of file FEProblemBase.C.

Referenced by MoosePreconditioner::setCouplingMatrix().

6640 {
6642  _cm[i] = std::move(cm);
6643 }
void setCoupling(Moose::CouplingType type)
Set the coupling between variables TODO: allow user-defined coupling.
std::vector< std::unique_ptr< libMesh::CouplingMatrix > > _cm
Coupling matrix for variables.

◆ setCouplingMatrix() [2/2]

void FEProblemBase::setCouplingMatrix ( libMesh::CouplingMatrix cm,
const unsigned int  nl_sys_num 
)
inherited

Definition at line 6631 of file FEProblemBase.C.

6632 {
6633  // TODO: Deprecate method
6635  _cm[i].reset(cm);
6636 }
void setCoupling(Moose::CouplingType type)
Set the coupling between variables TODO: allow user-defined coupling.
std::vector< std::unique_ptr< libMesh::CouplingMatrix > > _cm
Coupling matrix for variables.

◆ setCurrentAlgebraicBndNodeRange()

void FEProblemBase::setCurrentAlgebraicBndNodeRange ( ConstBndNodeRange range)
inherited

Definition at line 10037 of file FEProblemBase.C.

10038 {
10039  if (!range)
10040  {
10042  return;
10043  }
10044 
10045  _current_algebraic_bnd_node_range = std::make_unique<ConstBndNodeRange>(*range);
10046 }
std::unique_ptr< ConstBndNodeRange > _current_algebraic_bnd_node_range

◆ setCurrentAlgebraicElementRange()

void FEProblemBase::setCurrentAlgebraicElementRange ( libMesh::ConstElemRange range)
inherited

These functions allow setting custom ranges for the algebraic elements, nodes, and boundary nodes that contribute to the jacobian and residual for this local processor.

setCurrentAlgebraicElementRange() sets the element range that contributes to the system. A nullptr will reset the range to use the mesh's range.

setCurrentAlgebraicNodeRange() sets the node range that contributes to the system. A nullptr will reset the range to use the mesh's range.

setCurrentAlgebraicBndNodeRange() sets the boundary node range that contributes to the system. A nullptr will reset the range to use the mesh's range.

Parameters
rangeA pointer to the const range object representing the algebraic elements, nodes, or boundary nodes.

Definition at line 10015 of file FEProblemBase.C.

10016 {
10017  if (!range)
10018  {
10020  return;
10021  }
10022 
10023  _current_algebraic_elem_range = std::make_unique<ConstElemRange>(*range);
10024 }
std::unique_ptr< libMesh::ConstElemRange > _current_algebraic_elem_range

◆ setCurrentAlgebraicNodeRange()

void FEProblemBase::setCurrentAlgebraicNodeRange ( libMesh::ConstNodeRange range)
inherited

Definition at line 10026 of file FEProblemBase.C.

10027 {
10028  if (!range)
10029  {
10031  return;
10032  }
10033 
10034  _current_algebraic_node_range = std::make_unique<ConstNodeRange>(*range);
10035 }
std::unique_ptr< libMesh::ConstNodeRange > _current_algebraic_node_range

◆ setCurrentBoundaryID()

void FEProblemBase::setCurrentBoundaryID ( BoundaryID  bid,
const THREAD_ID  tid 
)
overridevirtualinherited

sets the current boundary ID in assembly

Reimplemented from SubProblem.

Definition at line 9951 of file FEProblemBase.C.

9952 {
9954  if (_displaced_problem)
9955  _displaced_problem->setCurrentBoundaryID(bid, tid);
9956 }
virtual void setCurrentBoundaryID(BoundaryID bid, const THREAD_ID tid)
sets the current boundary ID in assembly
Definition: SubProblem.C:790
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ setCurrentExecuteOnFlag()

void FEProblemBase::setCurrentExecuteOnFlag ( const ExecFlagType flag)
inherited

Definition at line 5057 of file FEProblemBase.C.

Referenced by execute(), FEProblemBase::execute(), FEProblemBase::initialSetup(), and FEProblemBase::outputStep().

5058 {
5059  _current_execute_on_flag = flag;
5060 }
ExecFlagType _current_execute_on_flag
Current execute_on flag.

◆ setCurrentLinearSystem()

void FEProblemBase::setCurrentLinearSystem ( unsigned int  sys_num)
inherited

Set the current linear system pointer.

Parameters
sys_numThe number of linear system

Definition at line 9968 of file FEProblemBase.C.

Referenced by FEProblemBase::computeLinearSystemSys(), LinearSystem::computeLinearSystemTags(), and FEProblemBase::solveLinearSystem().

9969 {
9970  mooseAssert(sys_num < _linear_systems.size(),
9971  "System number greater than the number of linear systems");
9972  _current_linear_sys = _linear_systems[sys_num].get();
9974 }
LinearSystem * _current_linear_sys
The current linear system that we are solving.
SolverSystem * _current_solver_sys
The current solver system.
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.

◆ setCurrentLowerDElem()

void FEProblemBase::setCurrentLowerDElem ( const Elem *const  lower_d_elem,
const THREAD_ID  tid 
)
overridevirtualinherited

Set the current lower dimensional element.

This can be null

Reimplemented from SubProblem.

Definition at line 9942 of file FEProblemBase.C.

9943 {
9944  SubProblem::setCurrentLowerDElem(lower_d_elem, tid);
9945  if (_displaced_problem)
9946  _displaced_problem->setCurrentLowerDElem(
9947  lower_d_elem ? _displaced_mesh->elemPtr(lower_d_elem->id()) : nullptr, tid);
9948 }
virtual Elem * elemPtr(const dof_id_type i)
Definition: MooseMesh.C:3213
virtual void setCurrentLowerDElem(const Elem *const lower_d_elem, const THREAD_ID tid)
Set the current lower dimensional element.
Definition: SubProblem.C:1385
dof_id_type id() const
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseMesh * _displaced_mesh

◆ setCurrentlyComputingJacobian()

void SubProblem::setCurrentlyComputingJacobian ( const bool  currently_computing_jacobian)
inlineinherited

Set whether or not the problem is in the process of computing the Jacobian.

Definition at line 697 of file SubProblem.h.

Referenced by FEProblemBase::computeResidualAndJacobian(), and FEProblemBase::resetState().

698  {
699  _currently_computing_jacobian = currently_computing_jacobian;
700  }
bool _currently_computing_jacobian
Flag to determine whether the problem is currently computing Jacobian.
Definition: SubProblem.h:1111

◆ setCurrentlyComputingResidual()

void FEProblemBase::setCurrentlyComputingResidual ( bool  currently_computing_residual)
finalvirtualinherited

Set whether or not the problem is in the process of computing the residual.

Reimplemented from SubProblem.

Definition at line 9622 of file FEProblemBase.C.

Referenced by FEProblemBase::computeResidualAndJacobian(), NonlinearSystemBase::computeResidualTags(), and FEProblemBase::resetState().

9623 {
9624  if (_displaced_problem)
9625  _displaced_problem->setCurrentlyComputingResidual(currently_computing_residual);
9626  _currently_computing_residual = currently_computing_residual;
9627 }
std::shared_ptr< DisplacedProblem > _displaced_problem
bool _currently_computing_residual
Whether the residual is being evaluated.
Definition: SubProblem.h:1120

◆ setCurrentlyComputingResidualAndJacobian()

void SubProblem::setCurrentlyComputingResidualAndJacobian ( bool  currently_computing_residual_and_jacobian)
inlineinherited

Set whether or not the problem is in the process of computing the Jacobian.

Definition at line 1511 of file SubProblem.h.

Referenced by FEProblemBase::computeResidualAndJacobian(), and FEProblemBase::resetState().

1513 {
1514  _currently_computing_residual_and_jacobian = currently_computing_residual_and_jacobian;
1515 }
bool _currently_computing_residual_and_jacobian
Flag to determine whether the problem is currently computing the residual and Jacobian.
Definition: SubProblem.h:1114

◆ setCurrentNonlinearSystem()

void FEProblemBase::setCurrentNonlinearSystem ( const unsigned int  nl_sys_num)
inherited

Definition at line 9959 of file FEProblemBase.C.

Referenced by FEProblemBase::computeJacobian(), EigenProblem::computeJacobianAB(), EigenProblem::computeJacobianBlocks(), FEProblemBase::computeJacobianBlocks(), NonlinearSystemBase::computeJacobianInternal(), EigenProblem::computeJacobianTag(), EigenProblem::computeMatricesTags(), EigenProblem::computeResidualTag(), NonlinearSystemBase::computeResidualTags(), ExternalProblem::ExternalProblem(), FEProblem::FEProblem(), EigenProblem::solve(), and FEProblemBase::solve().

9960 {
9961  mooseAssert(nl_sys_num < _nl.size(),
9962  "System number greater than the number of nonlinear systems");
9963  _current_nl_sys = _nl[nl_sys_num].get();
9965 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
SolverSystem * _current_solver_sys
The current solver system.

◆ setCurrentResidualVectorTags()

void FEProblemBase::setCurrentResidualVectorTags ( const std::set< TagID > &  vector_tags)
inlineinherited

Set the current residual vector tag data structure based on the passed in tag IDs.

Definition at line 3831 of file FEProblemBase.h.

Referenced by FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), and CrankNicolson::init().

3832 {
3834 }
std::vector< VectorTag > _current_residual_vector_tags
A data member to store the residual vector tag(s) passed into computeResidualTag(s).
std::vector< VectorTag > getVectorTags(const std::set< TagID > &tag_ids) const
Definition: SubProblem.C:173

◆ setCurrentSubdomainID()

void FEProblemBase::setCurrentSubdomainID ( const Elem elem,
const THREAD_ID  tid 
)
overridevirtualinherited

Implements SubProblem.

Definition at line 1890 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintJacobians(), NonlinearSystemBase::constraintResiduals(), MultiAppVariableValueSamplePostprocessorTransfer::execute(), ElementalVariableValue::execute(), and ComputeInitialConditionThread::operator()().

1891 {
1892  SubdomainID did = elem->subdomain_id();
1893  for (const auto i : index_range(_solver_systems))
1894  {
1895  _assembly[tid][i]->setCurrentSubdomainID(did);
1896  if (_displaced_problem &&
1898  _displaced_problem->assembly(tid, i).setCurrentSubdomainID(did);
1899  }
1900 }
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
subdomain_id_type subdomain_id() const
std::shared_ptr< DisplacedProblem > _displaced_problem
auto index_range(const T &sizable)

◆ setErrorOnJacobianNonzeroReallocation()

void FEProblemBase::setErrorOnJacobianNonzeroReallocation ( bool  state)
inlineinherited

Definition at line 2371 of file FEProblemBase.h.

2372  {
2374  }
bool _error_on_jacobian_nonzero_reallocation
Whether to error when the Jacobian is re-allocated, usually because the sparsity pattern changed...

◆ setException()

void FEProblemBase::setException ( const std::string &  message)
virtualinherited

Set an exception, which is stored at this point by toggling a member variable in this class, and which must be followed up with by a call to checkExceptionAndStopSolve().

Parameters
messageThe error message describing the exception, which will get printed when checkExceptionAndStopSolve() is called

Definition at line 6989 of file FEProblemBase.C.

Referenced by ComputeThreadedGeneralUserObjectsThread::caughtMooseException(), ThreadedNodeLoop< ConstBndNodeRange, ConstBndNodeRange::const_iterator >::caughtMooseException(), ThreadedFaceLoop< RangeType >::caughtMooseException(), NonlinearSystemBase::computeDamping(), AuxiliarySystem::computeElementalVarsHelper(), AuxiliarySystem::computeMortarNodalVars(), FEProblemBase::handleException(), ComputeMortarFunctor::operator()(), and DisplacedProblem::updateMesh().

6990 {
6991  _has_exception = true;
6992  _exception_message = message;
6993 }
bool _has_exception
Whether or not an exception has occurred.
std::string _exception_message
The error message to go with an exception.

◆ setExecutionPrinting()

void FEProblemBase::setExecutionPrinting ( const ExecFlagEnum print_exec)
inlineinherited

Definition at line 2875 of file FEProblemBase.h.

2875 { _print_execution_on = print_exec; }
ExecFlagEnum _print_execution_on
When to print the execution of loops.

◆ setFailNextNonlinearConvergenceCheck()

void FEProblemBase::setFailNextNonlinearConvergenceCheck ( )
inlineinherited

Skip further residual evaluations and fail the next nonlinear convergence check(s)

Definition at line 2862 of file FEProblemBase.h.

Referenced by Terminator::execute().

void setFailNextSystemConvergenceCheck()
Tell the problem that the system(s) cannot be considered converged next time convergence is checked...

◆ setFailNextSystemConvergenceCheck()

void FEProblemBase::setFailNextSystemConvergenceCheck ( )
inlineinherited

Tell the problem that the system(s) cannot be considered converged next time convergence is checked.

Definition at line 2864 of file FEProblemBase.h.

Referenced by FEProblemBase::setFailNextNonlinearConvergenceCheck().

bool _fail_next_system_convergence_check

◆ setFunctorOutput()

void SubProblem::setFunctorOutput ( bool  set_output)
inlineinherited

Setter for debug functor output.

Definition at line 932 of file SubProblem.h.

932 { _show_functors = set_output; }
bool _show_functors
Whether to output a list of the functors used and requested (currently only at initialSetup) ...
Definition: SubProblem.h:1179

◆ setIgnoreZerosInJacobian()

void FEProblemBase::setIgnoreZerosInJacobian ( bool  state)
inlineinherited

Set whether the zeros in the Jacobian should be dropped from the sparsity pattern.

Definition at line 2394 of file FEProblemBase.h.

2394 { _ignore_zeros_in_jacobian = state; }
bool _ignore_zeros_in_jacobian
Whether to ignore zeros in the Jacobian, thereby leading to a reduced sparsity pattern.

◆ setInputParametersFEProblem()

virtual void FEProblemBase::setInputParametersFEProblem ( InputParameters parameters)
inlinevirtualinherited

Reimplemented in FEProblem.

Definition at line 1024 of file FEProblemBase.h.

Referenced by FEProblem::setInputParametersFEProblem().

1025  {
1026  parameters.set<FEProblemBase *>("_fe_problem_base") = this;
1027  }
const InputParameters & parameters() const
Get the parameters of the object.
Definition: MooseBase.h:131
T & set(const std::string &name, bool quiet_mode=false)
Returns a writable reference to the named parameters.
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.

◆ setKernelCoverageCheck() [1/2]

void FEProblemBase::setKernelCoverageCheck ( CoverageCheckMode  mode)
inlineinherited

Set flag to indicate whether kernel coverage checks should be performed.

This check makes sure that at least one kernel is active on all subdomains in the domain (default: true).

Definition at line 2209 of file FEProblemBase.h.

2209 { _kernel_coverage_check = mode; }
CoverageCheckMode _kernel_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active kernel...

◆ setKernelCoverageCheck() [2/2]

void FEProblemBase::setKernelCoverageCheck ( bool  flag)
inlineinherited

Set flag to indicate whether kernel coverage checks should be performed.

This check makes sure that at least one kernel is active on all subdomains in the domain (default: true).

Definition at line 2215 of file FEProblemBase.h.

2216  {
2218  }
CoverageCheckMode _kernel_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active kernel...

◆ setLinearConvergenceNames()

void FEProblemBase::setLinearConvergenceNames ( const std::vector< ConvergenceName > &  convergence_names)
inherited

Sets the linear convergence object name(s) if there is one.

Definition at line 9786 of file FEProblemBase.C.

Referenced by FEProblemSolve::FEProblemSolve().

9787 {
9788  if (convergence_names.size() != numLinearSystems())
9789  paramError("linear_convergence", "There must be one convergence object per linear system");
9790  _linear_convergence_names = convergence_names;
9791 }
void paramError(const std::string &param, Args... args) const
Emits an error prefixed with the file and line number of the given param (from the input file) along ...
Definition: MooseBase.h:457
std::optional< std::vector< ConvergenceName > > _linear_convergence_names
Linear system(s) convergence name(s) (if any)
virtual std::size_t numLinearSystems() const override

◆ setMaterialCoverageCheck() [1/2]

void FEProblemBase::setMaterialCoverageCheck ( CoverageCheckMode  mode)
inlineinherited

Set flag to indicate whether material coverage checks should be performed.

This check makes sure that at least one material is active on all subdomains in the domain if any material is supplied. If no materials are supplied anywhere, a simulation is still considered OK as long as no properties are being requested anywhere.

Definition at line 2226 of file FEProblemBase.h.

2226 { _material_coverage_check = mode; }
CoverageCheckMode _material_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active material...

◆ setMaterialCoverageCheck() [2/2]

void FEProblemBase::setMaterialCoverageCheck ( bool  flag)
inlineinherited

Set flag to indicate whether material coverage checks should be performed.

This check makes sure that at least one material is active on all subdomains in the domain if any material is supplied. If no materials are supplied anywhere, a simulation is still considered OK as long as no properties are being requested anywhere.

Definition at line 2234 of file FEProblemBase.h.

2235  {
2237  }
CoverageCheckMode _material_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active material...

◆ setMesh()

void MFEMProblem::setMesh ( )

Set the mesh used by MFEM.

Definition at line 119 of file MFEMProblem.C.

120 {
121  auto pmesh = mesh().getMFEMParMeshPtr();
122  getProblemData().pmesh = pmesh;
123  getProblemData().comm = pmesh->GetComm();
124  getProblemData().num_procs = pmesh->GetNRanks();
125  getProblemData().myid = pmesh->GetMyRank();
126 }
std::shared_ptr< mfem::ParMesh > pmesh
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
virtual MFEMMesh & mesh() override
Overwritten mesh() method from base MooseMesh to retrieve the correct mesh type, in this case MFEMMes...
Definition: MFEMProblem.C:777
std::shared_ptr< mfem::ParMesh > getMFEMParMeshPtr()
Copy a shared_ptr to the mfem::ParMesh object.
Definition: MFEMMesh.h:40

◆ setMultiAppFixedPointConvergenceName()

void FEProblemBase::setMultiAppFixedPointConvergenceName ( const ConvergenceName &  convergence_name)
inherited

Sets the MultiApp fixed point convergence object name if there is one.

Definition at line 9758 of file FEProblemBase.C.

Referenced by FixedPointSolve::FixedPointSolve().

9759 {
9760  _multiapp_fixed_point_convergence_name = convergence_name;
9761 }
std::optional< ConvergenceName > _multiapp_fixed_point_convergence_name
MultiApp fixed point convergence name.

◆ setNeedToAddDefaultMultiAppFixedPointConvergence()

void FEProblemBase::setNeedToAddDefaultMultiAppFixedPointConvergence ( )
inlineinherited

Sets _need_to_add_default_multiapp_fixed_point_convergence to true.

Definition at line 761 of file FEProblemBase.h.

Referenced by FixedPointSolve::FixedPointSolve().

762  {
764  }
bool _need_to_add_default_multiapp_fixed_point_convergence
Flag that the problem needs to add the default fixed point convergence.

◆ setNeedToAddDefaultNonlinearConvergence()

void FEProblemBase::setNeedToAddDefaultNonlinearConvergence ( )
inlineinherited

Sets _need_to_add_default_nonlinear_convergence to true.

Definition at line 756 of file FEProblemBase.h.

Referenced by FEProblemSolve::FEProblemSolve().

757  {
759  }
bool _need_to_add_default_nonlinear_convergence
Flag that the problem needs to add the default nonlinear convergence.

◆ setNeedToAddDefaultSteadyStateConvergence()

void FEProblemBase::setNeedToAddDefaultSteadyStateConvergence ( )
inlineinherited

Sets _need_to_add_default_steady_state_convergence to true.

Definition at line 766 of file FEProblemBase.h.

Referenced by TransientBase::TransientBase().

767  {
769  }
bool _need_to_add_default_steady_state_convergence
Flag that the problem needs to add the default steady convergence.

◆ setNeighborSubdomainID() [1/2]

virtual void FEProblemBase::setNeighborSubdomainID ( const Elem *  elem,
unsigned int  side,
const THREAD_ID  tid 
)
overridevirtualinherited

◆ setNeighborSubdomainID() [2/2]

virtual void FEProblemBase::setNeighborSubdomainID ( const Elem *  elem,
const THREAD_ID  tid 
)
virtualinherited

◆ setNonlinearConvergenceNames()

void FEProblemBase::setNonlinearConvergenceNames ( const std::vector< ConvergenceName > &  convergence_names)
inherited

Sets the nonlinear convergence object name(s) if there is one.

Definition at line 9749 of file FEProblemBase.C.

Referenced by FEProblemSolve::FEProblemSolve().

9750 {
9751  if (convergence_names.size() != numNonlinearSystems())
9752  paramError("nonlinear_convergence",
9753  "There must be one convergence object per nonlinear system");
9754  _nonlinear_convergence_names = convergence_names;
9755 }
void paramError(const std::string &param, Args... args) const
Emits an error prefixed with the file and line number of the given param (from the input file) along ...
Definition: MooseBase.h:457
virtual std::size_t numNonlinearSystems() const override
std::optional< std::vector< ConvergenceName > > _nonlinear_convergence_names
Nonlinear system(s) convergence name(s)

◆ setNonlocalCouplingMatrix()

void FEProblemBase::setNonlocalCouplingMatrix ( )
inherited

Set custom coupling matrix for variables requiring nonlocal contribution.

Definition at line 6656 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup().

6657 {
6658  TIME_SECTION("setNonlocalCouplingMatrix", 5, "Setting Nonlocal Coupling Matrix");
6659 
6660  if (_nl.size() > 1)
6661  mooseError("Nonlocal kernels are weirdly stored on the FEProblem so we don't currently support "
6662  "multiple nonlinear systems with nonlocal kernels.");
6663 
6664  for (const auto nl_sys_num : index_range(_nl))
6665  {
6666  auto & nl = _nl[nl_sys_num];
6667  auto & nonlocal_cm = _nonlocal_cm[nl_sys_num];
6668  unsigned int n_vars = nl->nVariables();
6669  nonlocal_cm.resize(n_vars);
6670  const auto & vars = nl->getVariables(0);
6671  const auto & nonlocal_kernel = _nonlocal_kernels.getObjects();
6672  const auto & nonlocal_integrated_bc = _nonlocal_integrated_bcs.getObjects();
6673  for (const auto & ivar : vars)
6674  {
6675  for (const auto & kernel : nonlocal_kernel)
6676  {
6677  for (unsigned int i = ivar->number(); i < ivar->number() + ivar->count(); ++i)
6678  if (i == kernel->variable().number())
6679  for (const auto & jvar : vars)
6680  {
6681  const auto it = _var_dof_map.find(jvar->name());
6682  if (it != _var_dof_map.end())
6683  {
6684  unsigned int j = jvar->number();
6685  nonlocal_cm(i, j) = 1;
6686  }
6687  }
6688  }
6689  for (const auto & integrated_bc : nonlocal_integrated_bc)
6690  {
6691  for (unsigned int i = ivar->number(); i < ivar->number() + ivar->count(); ++i)
6692  if (i == integrated_bc->variable().number())
6693  for (const auto & jvar : vars)
6694  {
6695  const auto it = _var_dof_map.find(jvar->name());
6696  if (it != _var_dof_map.end())
6697  {
6698  unsigned int j = jvar->number();
6699  nonlocal_cm(i, j) = 1;
6700  }
6701  }
6702  }
6703  }
6704  }
6705 }
char ** vars
std::map< std::string, std::vector< dof_id_type > > _var_dof_map
Definition: SubProblem.h:682
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
const std::vector< std::shared_ptr< T > > & getObjects(THREAD_ID tid=0) const
Retrieve complete vector to the all/block/boundary restricted objects for a given thread...
unsigned int n_vars
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
std::vector< libMesh::CouplingMatrix > _nonlocal_cm
nonlocal coupling matrix
auto index_range(const T &sizable)
MooseObjectWarehouse< IntegratedBCBase > _nonlocal_integrated_bcs
nonlocal integrated_bcs
MooseObjectWarehouse< KernelBase > _nonlocal_kernels
nonlocal kernels

◆ setParallelBarrierMessaging()

void FEProblemBase::setParallelBarrierMessaging ( bool  flag)
inlineinherited

Toggle parallel barrier messaging (defaults to on).

Definition at line 2242 of file FEProblemBase.h.

2242 { _parallel_barrier_messaging = flag; }
bool _parallel_barrier_messaging
Whether or not information about how many transfers have completed is printed.

◆ setPostprocessorValueByName()

void FEProblemBase::setPostprocessorValueByName ( const PostprocessorName &  name,
const PostprocessorValue value,
std::size_t  t_index = 0 
)
inherited

Set the value of a PostprocessorValue.

Parameters
nameThe name of the post-processor
t_indexFlag for getting current (0), old (1), or older (2) values
Returns
The reference to the value at the given time index

Note: This method is only for setting values that already exist, the Postprocessor and PostprocessorInterface objects should be used rather than this method for creating and getting values within objects.

WARNING! This method should be used with caution. It exists to allow Transfers and other similar objects to modify Postprocessor values. It is not intended for general use.

Definition at line 4894 of file FEProblemBase.C.

Referenced by MultiAppPostprocessorTransfer::execute(), PIDTransientControl::execute(), executeMFEMObjects(), PIDTransientControl::initialSetup(), FEProblemBase::joinAndFinalize(), PIDTransientControl::timestepSetup(), SecantSolve::transformPostprocessors(), SteffensenSolve::transformPostprocessors(), and PicardSolve::transformPostprocessors().

4897 {
4899  PostprocessorReporterName(name), value, t_index);
4900 }
ReporterData _reporter_data
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
Real value(unsigned n, unsigned alpha, unsigned beta, Real x)
Real PostprocessorValue
various MOOSE typedefs
Definition: MooseTypes.h:230
void setReporterValue(const ReporterName &reporter_name, const T &value, const std::size_t time_index=0)
Method for setting Reporter values that already exist.
Definition: ReporterData.h:494
A ReporterName that represents a Postprocessor.
Definition: ReporterName.h:143

◆ setPreserveMatrixSparsityPattern()

void FEProblemBase::setPreserveMatrixSparsityPattern ( bool  preserve)
inherited

Set whether the sparsity pattern of the matrices being formed during the solve (usually the Jacobian) should be preserved.

This global setting can be retrieved by kernels, notably those using AD, to decide whether to take additional care to preserve the sparsity pattern

Definition at line 4074 of file FEProblemBase.C.

4075 {
4076  if (_ignore_zeros_in_jacobian && preserve)
4077  paramWarning(
4078  "ignore_zeros_in_jacobian",
4079  "We likely cannot preserve the sparsity pattern if ignoring zeros in the Jacobian, which "
4080  "leads to removing those entries from the Jacobian sparsity pattern");
4082 }
bool _ignore_zeros_in_jacobian
Whether to ignore zeros in the Jacobian, thereby leading to a reduced sparsity pattern.
bool _preserve_matrix_sparsity_pattern
Whether to preserve the system matrix / Jacobian sparsity pattern, using 0-valued entries usually...
void paramWarning(const std::string &param, Args... args) const

◆ setResidual() [1/2]

virtual void SubProblem::setResidual ( libMesh::NumericVector< libMesh::Number > &  residual,
const THREAD_ID  tid 
)
pure virtualinherited

◆ setResidual() [2/2]

void FEProblemBase::setResidual ( NumericVector< libMesh::Number > &  residual,
const THREAD_ID  tid 
)
overridevirtualinherited

Definition at line 2049 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::constraintResiduals().

2050 {
2051  _assembly[tid][_current_nl_sys->number()]->setResidual(
2052  residual,
2054  getVectorTag(_nl[_current_nl_sys->number()]->residualVectorTag()));
2055  if (_displaced_problem)
2056  _displaced_problem->setResidual(residual, tid);
2057 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
virtual const VectorTag & getVectorTag(const TagID tag_id) const
Get a VectorTag from a TagID.
Definition: SubProblem.C:162
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ setResidualNeighbor() [1/2]

virtual void SubProblem::setResidualNeighbor ( libMesh::NumericVector< libMesh::Number > &  residual,
const THREAD_ID  tid 
)
pure virtualinherited

◆ setResidualNeighbor() [2/2]

void FEProblemBase::setResidualNeighbor ( NumericVector< libMesh::Number > &  residual,
const THREAD_ID  tid 
)
overridevirtualinherited

Definition at line 2060 of file FEProblemBase.C.

2061 {
2062  _assembly[tid][_current_nl_sys->number()]->setResidualNeighbor(
2064  if (_displaced_problem)
2065  _displaced_problem->setResidualNeighbor(residual, tid);
2066 }
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
unsigned int number() const
Gets the number of this system.
Definition: SystemBase.C:1158
TagID residualVectorTag() const override
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
virtual const VectorTag & getVectorTag(const TagID tag_id) const
Get a VectorTag from a TagID.
Definition: SubProblem.C:162
Key structure for APIs manipulating global vectors/matrices.
Definition: Assembly.h:844

◆ setRestartFile()

void FEProblemBase::setRestartFile ( const std::string &  file_name)
inherited

Communicate to the Resurector the name of the restart filer.

Parameters
file_nameThe file name for restarting from

Definition at line 9251 of file FEProblemBase.C.

Referenced by Executioner::Executioner(), and FEProblemBase::FEProblemBase().

9252 {
9253  if (_app.isRecovering())
9254  {
9255  mooseInfo("Restart file ", file_name, " is NOT being used since we are performing recovery.");
9256  }
9257  else
9258  {
9259  _app.setRestart(true);
9260  _app.setRestartRecoverFileBase(file_name);
9261  mooseInfo("Using ", file_name, " for restart.");
9262  }
9263 }
void mooseInfo(Args &&... args) const
Definition: MooseBase.h:334
void setRestartRecoverFileBase(const std::string &file_base)
mutator for recover_base (set by RecoverBaseAction)
Definition: MooseApp.h:512
void setRestart(bool value)
Sets the restart/recover flags.
Definition: MooseApp.C:2879
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
bool isRecovering() const
Whether or not this is a "recover" calculation.
Definition: MooseApp.C:1669

◆ setSNESMFReuseBase()

void FEProblemBase::setSNESMFReuseBase ( bool  reuse,
bool  set_by_user 
)
inlineinherited

If or not to reuse the base vector for matrix-free calculation.

Definition at line 2564 of file FEProblemBase.h.

Referenced by FEProblemSolve::FEProblemSolve().

2565  {
2566  _snesmf_reuse_base = reuse, _snesmf_reuse_base_set_by_user = set_by_user;
2567  }
bool _snesmf_reuse_base_set_by_user
If or not _snesmf_reuse_base is set by user.
bool _snesmf_reuse_base
If or not to resuse the base vector for matrix-free calculation.

◆ setSteadyStateConvergenceName()

void FEProblemBase::setSteadyStateConvergenceName ( const ConvergenceName &  convergence_name)
inherited

Sets the steady-state detection convergence object name if there is one.

Definition at line 9764 of file FEProblemBase.C.

Referenced by TransientBase::TransientBase().

9765 {
9766  _steady_state_convergence_name = convergence_name;
9767 }
std::optional< ConvergenceName > _steady_state_convergence_name
Steady-state detection convergence name.

◆ setUDotDotOldRequested()

virtual void FEProblemBase::setUDotDotOldRequested ( const bool  u_dotdot_old_requested)
inlinevirtualinherited

Set boolean flag to true to store old solution second time derivative.

Definition at line 2612 of file FEProblemBase.h.

Referenced by CentralDifference::CentralDifference(), and NewmarkBeta::NewmarkBeta().

2613  {
2614  _u_dotdot_old_requested = u_dotdot_old_requested;
2615  }
bool _u_dotdot_old_requested
Whether old solution second time derivative needs to be stored.

◆ setUDotDotRequested()

virtual void FEProblemBase::setUDotDotRequested ( const bool  u_dotdot_requested)
inlinevirtualinherited

Set boolean flag to true to store solution second time derivative.

Definition at line 2600 of file FEProblemBase.h.

Referenced by CentralDifference::CentralDifference(), and NewmarkBeta::NewmarkBeta().

2601  {
2602  _u_dotdot_requested = u_dotdot_requested;
2603  }
bool _u_dotdot_requested
Whether solution second time derivative needs to be stored.

◆ setUDotOldRequested()

virtual void FEProblemBase::setUDotOldRequested ( const bool  u_dot_old_requested)
inlinevirtualinherited

Set boolean flag to true to store old solution time derivative.

Definition at line 2606 of file FEProblemBase.h.

Referenced by CentralDifference::CentralDifference(), and NewmarkBeta::NewmarkBeta().

2607  {
2608  _u_dot_old_requested = u_dot_old_requested;
2609  }
bool _u_dot_old_requested
Whether old solution time derivative needs to be stored.

◆ setUDotRequested()

virtual void FEProblemBase::setUDotRequested ( const bool  u_dot_requested)
inlinevirtualinherited

Set boolean flag to true to store solution time derivative.

Definition at line 2597 of file FEProblemBase.h.

Referenced by TimeIntegrator::TimeIntegrator().

2597 { _u_dot_requested = u_dot_requested; }
bool _u_dot_requested
Whether solution time derivative needs to be stored.

◆ setupDampers()

void FEProblemBase::setupDampers ( )
inherited

Definition at line 5713 of file FEProblemBase.C.

5714 {
5715  for (auto & nl : _nl)
5716  nl->setupDampers();
5717 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ setVariableAllDoFMap()

void FEProblemBase::setVariableAllDoFMap ( const std::vector< const MooseVariableFEBase *> &  moose_vars)
inherited

Definition at line 1798 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup(), and FEProblemBase::meshChanged().

1799 {
1800  for (unsigned int i = 0; i < moose_vars.size(); ++i)
1801  {
1802  VariableName var_name = moose_vars[i]->name();
1803  auto & sys = _solver_systems[moose_vars[i]->sys().number()];
1804  sys->setVariableGlobalDoFs(var_name);
1805  _var_dof_map[var_name] = sys->getVariableGlobalDoFs();
1806  }
1807 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::map< std::string, std::vector< dof_id_type > > _var_dof_map
Definition: SubProblem.h:682

◆ setVectorPostprocessorValueByName()

void FEProblemBase::setVectorPostprocessorValueByName ( const std::string &  object_name,
const std::string &  vector_name,
const VectorPostprocessorValue value,
std::size_t  t_index = 0 
)
inherited

Set the value of a VectorPostprocessor vector.

Parameters
object_nameThe name of the VPP object
vector_nameThe name of the declared vector
valueThe data to apply to the vector
t_indexFlag for getting current (0), old (1), or older (2) values

Definition at line 4920 of file FEProblemBase.C.

4924 {
4926  VectorPostprocessorReporterName(object_name, vector_name), value, t_index);
4927 }
A ReporterName that represents a VectorPostprocessor.
Definition: ReporterName.h:152
ReporterData _reporter_data
Real value(unsigned n, unsigned alpha, unsigned beta, Real x)
void setReporterValue(const ReporterName &reporter_name, const T &value, const std::size_t time_index=0)
Method for setting Reporter values that already exist.
Definition: ReporterData.h:494
std::vector< Real > VectorPostprocessorValue
Definition: MooseTypes.h:231

◆ setVerboseProblem()

void FEProblemBase::setVerboseProblem ( bool  verbose)
inherited

Make the problem be verbose.

Definition at line 9934 of file FEProblemBase.C.

Referenced by PhysicsBase::initializePhysics().

9935 {
9936  _verbose_setup = verbose ? "true" : "false";
9937  _verbose_multiapps = verbose;
9938  _verbose_restore = verbose;
9939 }
bool _verbose_restore
Whether or not to be verbose on solution restoration post a failed time step.
MooseEnum _verbose_setup
Whether or not to be verbose during setup.
bool _verbose_multiapps
Whether or not to be verbose with multiapps.

◆ shouldPrintExecution()

bool FEProblemBase::shouldPrintExecution ( const THREAD_ID  tid) const
inherited

Check whether the problem should output execution orders at this time.

Definition at line 9876 of file FEProblemBase.C.

Referenced by FEProblemBase::joinAndFinalize(), ComputeMarkerThread::printBlockExecutionInformation(), ComputeDiracThread::printBlockExecutionInformation(), ComputeIndicatorThread::printBlockExecutionInformation(), ComputeUserObjectsThread::printBlockExecutionInformation(), ComputeLinearFVElementalThread::printBlockExecutionInformation(), ComputeLinearFVFaceThread::printBlockExecutionInformation(), NonlinearThread::printBlockExecutionInformation(), NonlinearThread::printBoundaryExecutionInformation(), ComputeFVInitialConditionThread::printGeneralExecutionInformation(), ComputeInitialConditionThread::printGeneralExecutionInformation(), ComputeNodalUserObjectsThread::printGeneralExecutionInformation(), ComputeNodalKernelBcsThread::printGeneralExecutionInformation(), ComputeNodalKernelsThread::printGeneralExecutionInformation(), ComputeElemDampingThread::printGeneralExecutionInformation(), ComputeNodalKernelBCJacobiansThread::printGeneralExecutionInformation(), ComputeNodalDampingThread::printGeneralExecutionInformation(), ComputeMarkerThread::printGeneralExecutionInformation(), ComputeDiracThread::printGeneralExecutionInformation(), ComputeIndicatorThread::printGeneralExecutionInformation(), ComputeNodalKernelJacobiansThread::printGeneralExecutionInformation(), ComputeThreadedGeneralUserObjectsThread::printGeneralExecutionInformation(), ComputeUserObjectsThread::printGeneralExecutionInformation(), ComputeLinearFVElementalThread::printGeneralExecutionInformation(), ComputeLinearFVFaceThread::printGeneralExecutionInformation(), and NonlinearThread::printGeneralExecutionInformation().

9877 {
9878  // For now, only support printing from thread 0
9879  if (tid != 0)
9880  return false;
9881 
9884  return true;
9885  else
9886  return false;
9887 }
ExecFlagType _current_execute_on_flag
Current execute_on flag.
const ExecFlagType EXEC_ALWAYS
Definition: Moose.C:53
ExecFlagEnum _print_execution_on
When to print the execution of loops.
bool isValueSet(const std::string &value) const
Methods for seeing if a value is set in the MultiMooseEnum.

◆ shouldSolve()

bool FEProblemBase::shouldSolve ( ) const
inlineinherited

Definition at line 2648 of file FEProblemBase.h.

Referenced by ExternalProblem::solve(), FEProblemSolve::solve(), MFEMProblemSolve::solve(), and TransientBase::TransientBase().

2648 { return _solve; }
const bool & _solve
Whether or not to actually solve the nonlinear system.

◆ shouldUpdateSolution()

bool FEProblemBase::shouldUpdateSolution ( )
virtualinherited

Check to see whether the problem should update the solution.

Returns
true if the problem should update the solution, false otherwise

Definition at line 8354 of file FEProblemBase.C.

Referenced by FEProblemBase::computePostCheck(), and NonlinearSystem::solve().

8355 {
8356  return false;
8357 }

◆ showInvalidSolutionConsole()

bool FEProblemBase::showInvalidSolutionConsole ( ) const
inlineinherited

Whether or not to print out the invalid solutions summary table in console.

Definition at line 2411 of file FEProblemBase.h.

Referenced by SolverSystem::checkInvalidSolution().

const bool _show_invalid_solution_console

◆ sizeZeroes()

void FEProblemBase::sizeZeroes ( unsigned int  size,
const THREAD_ID  tid 
)
virtualinherited

Definition at line 2251 of file FEProblemBase.C.

2252 {
2253  mooseDoOnce(mooseWarning(
2254  "This function is deprecated and no longer performs any function. Please do not call it."));
2255 }
void mooseWarning(Args &&... args) const

◆ skipExceptionCheck()

void FEProblemBase::skipExceptionCheck ( bool  skip_exception_check)
inlineinherited

Set a flag that indicates if we want to skip exception and stop solve.

Definition at line 2577 of file FEProblemBase.h.

Referenced by FEProblemSolve::FEProblemSolve().

2578  {
2579  _skip_exception_check = skip_exception_check;
2580  }
bool _skip_exception_check
If or not skip &#39;exception and stop solve&#39;.

◆ skipNextForwardSolutionCopyToOld()

void FEProblemBase::skipNextForwardSolutionCopyToOld ( )
inherited

Prevents the copy of the solution vector to the old solution vector in each system.

Old -> Older is still performed This is useful for MultiApps fixed point iterations

Definition at line 7168 of file FEProblemBase.C.

Referenced by FullSolveMultiApp::solveStep().

7169 {
7170  for (auto & sys : _solver_systems)
7171  sys->skipNextSolutionToOldCopy();
7172  _aux->skipNextSolutionToOldCopy();
7173 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ solve()

void ExternalProblem::solve ( unsigned int  nl_sys_num = 0)
finaloverridevirtualinherited

Solve is implemented to providing syncing to/from the "transfer" mesh.

Reimplemented from FEProblemBase.

Definition at line 64 of file ExternalProblem.C.

65 {
66  TIME_SECTION("solve", 1, "Solving", false)
67 
68  syncSolutions(Direction::TO_EXTERNAL_APP);
69  if (shouldSolve())
70  externalSolve();
71  syncSolutions(Direction::FROM_EXTERNAL_APP);
72 }
bool shouldSolve() const
virtual void syncSolutions(Direction direction)=0
Method to transfer data to/from the external application to the associated transfer mesh...
if(!dmm->_nl) SETERRQ(PETSC_COMM_WORLD
virtual void externalSolve()=0
New interface for solving an External problem.

◆ solveLinearSystem()

void FEProblemBase::solveLinearSystem ( const unsigned int  linear_sys_num,
const Moose::PetscSupport::PetscOptions po = nullptr 
)
virtualinherited

Build and solve a linear system.

Parameters
linear_sys_numThe number of the linear system (1,..,num. of lin. systems)
poThe petsc options for the solve, if not supplied, the defaults are used

Reimplemented in DumpObjectsProblem.

Definition at line 7085 of file FEProblemBase.C.

Referenced by FEProblemSolve::solve().

7087 {
7088  TIME_SECTION("solve", 1, "Solving", false);
7089 
7090  setCurrentLinearSystem(linear_sys_num);
7091 
7092  const Moose::PetscSupport::PetscOptions & options = po ? *po : _petsc_options;
7093  auto & solver_params = _solver_params[numNonlinearSystems() + linear_sys_num];
7094 
7095  // Set custom convergence criteria
7097 
7098 #if PETSC_RELEASE_LESS_THAN(3, 12, 0)
7099  LibmeshPetscCall(Moose::PetscSupport::petscSetOptions(
7100  options, solver_params)); // Make sure the PETSc options are setup for this app
7101 #else
7102  // Now this database will be the default
7103  // Each app should have only one database
7104  if (!_app.isUltimateMaster())
7105  LibmeshPetscCall(PetscOptionsPush(_petsc_option_data_base));
7106 
7107  // We did not add PETSc options to database yet
7109  {
7110  Moose::PetscSupport::petscSetOptions(options, solver_params, this);
7112  }
7113 #endif
7114 
7115  if (_solve)
7117 
7118 #if !PETSC_RELEASE_LESS_THAN(3, 12, 0)
7119  if (!_app.isUltimateMaster())
7120  LibmeshPetscCall(PetscOptionsPop());
7121 #endif
7122 }
bool isUltimateMaster() const
Whether or not this app is the ultimate master app.
Definition: MooseApp.h:866
virtual std::size_t numNonlinearSystems() const override
void petscSetDefaults(FEProblemBase &problem)
Sets the default options for PETSc.
Definition: PetscSupport.C:598
std::vector< SolverParams > _solver_params
bool _is_petsc_options_inserted
If or not PETSc options have been added to database.
A struct for storing the various types of petsc options and values.
Definition: PetscSupport.h:44
PetscOptions _petsc_option_data_base
const bool & _solve
Whether or not to actually solve the nonlinear system.
LinearSystem * _current_linear_sys
The current linear system that we are solving.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
virtual void solve() override
Solve the system (using libMesh magic)
Definition: LinearSystem.C:308
void petscSetOptions(const PetscOptions &po, const SolverParams &solver_params, FEProblemBase *const problem=nullptr)
A function for setting the PETSc options in PETSc from the options supplied to MOOSE.
Definition: PetscSupport.C:378
void setCurrentLinearSystem(unsigned int sys_num)
Set the current linear system pointer.
Moose::PetscSupport::PetscOptions _petsc_options
PETSc option storage.

◆ solverParams() [1/2]

SolverParams & FEProblemBase::solverParams ( unsigned int  solver_sys_num = 0)
inherited

Get the solver parameters.

Definition at line 9283 of file FEProblemBase.C.

Referenced by NonlinearEigenSystem::attachPreconditioner(), SolverSystem::compute(), SlepcEigenSolverConfiguration::configure_solver(), EigenProblemSolve::EigenProblemSolve(), ExplicitTimeIntegrator::ExplicitTimeIntegrator(), FEProblemSolve::FEProblemSolve(), EigenProblem::init(), ExplicitTimeIntegrator::init(), FEProblemBase::init(), EigenProblemSolve::initialSetup(), EigenProblem::isNonlinearEigenvalueSolver(), Moose::SlepcSupport::mooseSlepcEigenFormFunctionA(), Moose::SlepcSupport::mooseSlepcEigenFormFunctionAB(), Moose::SlepcSupport::mooseSlepcEigenFormFunctionB(), Moose::SlepcSupport::mooseSlepcEigenFormJacobianA(), MooseStaticCondensationPreconditioner::MooseStaticCondensationPreconditioner(), ConsoleUtils::outputExecutionInformation(), PhysicsBasedPreconditioner::PhysicsBasedPreconditioner(), NonlinearSystem::residualAndJacobianTogether(), Moose::SlepcSupport::setEigenProblemSolverParams(), Moose::PetscSupport::setLineSearchFromParams(), Moose::PetscSupport::setMFFDTypeFromParams(), Moose::PetscSupport::setSinglePetscOption(), Moose::PetscSupport::setSolveTypeFromParams(), NonlinearSystemBase::shouldEvaluatePreSMOResidual(), EigenProblem::solve(), FEProblemBase::solverParams(), EigenProblem::solverTypeString(), FEProblemBase::solverTypeString(), and Moose::SlepcSupport::storeSolveType().

9284 {
9285  mooseAssert(solver_sys_num < numSolverSystems(),
9286  "Solver system number '" << solver_sys_num << "' is out of bounds. We have '"
9287  << numSolverSystems() << "' solver systems");
9288  return _solver_params[solver_sys_num];
9289 }
std::vector< SolverParams > _solver_params
virtual std::size_t numSolverSystems() const override

◆ solverParams() [2/2]

const SolverParams & FEProblemBase::solverParams ( unsigned int  solver_sys_num = 0) const
inherited

const version

Definition at line 9292 of file FEProblemBase.C.

9293 {
9294  return const_cast<FEProblemBase *>(this)->solverParams(solver_sys_num);
9295 }
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
SolverParams & solverParams(unsigned int solver_sys_num=0)
Get the solver parameters.

◆ solverSysNum()

unsigned int FEProblemBase::solverSysNum ( const SolverSystemName &  solver_sys_name) const
overridevirtualinherited
Returns
the solver system number corresponding to the provided solver_sys_name

Implements SubProblem.

Definition at line 6892 of file FEProblemBase.C.

Referenced by FEProblemBase::addVariable(), FEProblemBase::getSystemBase(), MultiSystemSolveObject::MultiSystemSolveObject(), and DisplacedProblem::solverSysNum().

6893 {
6894  std::istringstream ss(solver_sys_name);
6895  unsigned int solver_sys_num;
6896  if (!(ss >> solver_sys_num) || !ss.eof())
6897  {
6898  const auto & search = _solver_sys_name_to_num.find(solver_sys_name);
6899  if (search == _solver_sys_name_to_num.end())
6900  mooseError("The solver system number was requested for system '" + solver_sys_name,
6901  "' but this system does not exist in the Problem. Systems can be added to the "
6902  "problem using the 'nl_sys_names'/'linear_sys_names' parameter.\nSystems in the "
6903  "Problem: " +
6905  solver_sys_num = search->second;
6906  }
6907 
6908  return solver_sys_num;
6909 }
std::map< SolverSystemName, unsigned int > _solver_sys_name_to_num
Map connecting solver system names with their respective systems.
std::vector< SolverSystemName > _solver_sys_names
The union of nonlinear and linear system names.
std::string stringify(const T &t)
conversion to string
Definition: Conversion.h:64
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ solverSystemConverged()

bool FEProblemBase::solverSystemConverged ( const unsigned int  sys_num)
overridevirtualinherited
Returns
whether the given solver system sys_num is converged

Reimplemented from SubProblem.

Reimplemented in EigenProblem.

Definition at line 7125 of file FEProblemBase.C.

7126 {
7127  if (_solve)
7128  return _solver_systems[sys_num]->converged();
7129  else
7130  return true;
7131 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
const bool & _solve
Whether or not to actually solve the nonlinear system.

◆ solverTypeString()

std::string MFEMProblem::solverTypeString ( unsigned int  solver_sys_num)
overridevirtual

Return solver type as a human readable string.

Reimplemented from FEProblemBase.

Definition at line 874 of file MFEMProblem.C.

875 {
876  mooseAssert(solver_sys_num == 0, "No support for multi-system with MFEM right now");
877 
878  std::vector<std::string> solvers;
879 
880  if (getProblemData().nonlinear_solver)
881  solvers.push_back(MooseUtils::prettyCppType(getProblemData().nonlinear_solver.get()));
882 
884  {
885  solvers.push_back(MooseUtils::prettyCppType(getProblemData().jacobian_solver.get()));
886  if (const auto * prec = getProblemData().jacobian_solver->GetPreconditioner())
887  solvers.push_back(MooseUtils::prettyCppType(prec));
888  }
889 
890  return solvers.empty() ? "None" : MooseUtils::stringJoin(solvers);
891 }
MFEMProblemData & getProblemData()
Method to get the current MFEMProblemData object storing the current data specifying the FE problem...
Definition: MFEMProblem.h:271
std::shared_ptr< Moose::MFEM::LinearSolverBase > jacobian_solver
std::string stringJoin(const std::vector< std::string > &values, const std::string &separator=" ")
Concatenates value into a single string separated by separator.
std::string prettyCppType(const std::string &cpp_type)
Definition: MooseUtils.C:1140

◆ startedInitialSetup()

virtual bool FEProblemBase::startedInitialSetup ( )
inlinevirtualinherited

Returns true if we are in or beyond the initialSetup stage.

Definition at line 569 of file FEProblemBase.h.

Referenced by NEML2ModelExecutor::checkExecutionStage(), MaterialBase::checkExecutionStage(), and MaterialPropertyInterface::checkExecutionStage().

569 { return _started_initial_setup; }
bool _started_initial_setup
At or beyond initialSteup stage.

◆ storeBoundaryDelayedCheckMatProp()

void SubProblem::storeBoundaryDelayedCheckMatProp ( const std::string &  requestor,
BoundaryID  boundary_id,
const std::string &  name 
)
virtualinherited

Adds to a map based on boundary ids of material properties to validate.

Parameters
requestorThe MOOSE object name requesting the material property
boundary_idThe block id for the MaterialProperty
nameThe name of the property

Definition at line 616 of file SubProblem.C.

Referenced by MaterialPropertyInterface::checkMaterialProperty().

619 {
620  _map_boundary_material_props_check[boundary_id].insert(std::make_pair(requestor, name));
621 }
std::map< BoundaryID, std::multimap< std::string, std::string > > _map_boundary_material_props_check
Definition: SubProblem.h:1086
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ storeBoundaryMatPropName()

void SubProblem::storeBoundaryMatPropName ( BoundaryID  boundary_id,
const std::string &  name 
)
virtualinherited

Adds the given material property to a storage map based on boundary ids.

This is method is called from within the Material class when the property is first registered.

Parameters
boundary_idThe block id for the MaterialProperty
nameThe name of the property

Definition at line 590 of file SubProblem.C.

Referenced by MaterialBase::registerPropName().

591 {
592  _map_boundary_material_props[boundary_id].insert(name);
593 }
std::map< BoundaryID, std::set< std::string > > _map_boundary_material_props
Map for boundary material properties (boundary_id -> list of properties)
Definition: SubProblem.h:1070
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ storeBoundaryZeroMatProp()

void SubProblem::storeBoundaryZeroMatProp ( BoundaryID  boundary_id,
const MaterialPropertyName &  name 
)
virtualinherited

Adds to a map based on boundary ids of material properties for which a zero value can be returned.

Thes properties are optional and will not trigger a missing material property error.

Parameters
boundary_idThe block id for the MaterialProperty
nameThe name of the property

Definition at line 602 of file SubProblem.C.

Referenced by MaterialBase::storeBoundaryZeroMatProp().

603 {
604  _zero_boundary_material_props[boundary_id].insert(name);
605 }
std::map< BoundaryID, std::set< MaterialPropertyName > > _zero_boundary_material_props
Definition: SubProblem.h:1074
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103

◆ storeSubdomainDelayedCheckMatProp()

void SubProblem::storeSubdomainDelayedCheckMatProp ( const std::string &  requestor,
SubdomainID  block_id,
const std::string &  name 
)
virtualinherited

Adds to a map based on block ids of material properties to validate.

Parameters
block_idThe block id for the MaterialProperty
nameThe name of the property

Definition at line 608 of file SubProblem.C.

Referenced by MaterialPropertyInterface::checkMaterialProperty().

611 {
612  _map_block_material_props_check[block_id].insert(std::make_pair(requestor, name));
613 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::map< SubdomainID, std::multimap< std::string, std::string > > _map_block_material_props_check
Data structures of the requested material properties.
Definition: SubProblem.h:1085

◆ storeSubdomainMatPropName()

void SubProblem::storeSubdomainMatPropName ( SubdomainID  block_id,
const std::string &  name 
)
virtualinherited

Adds the given material property to a storage map based on block ids.

This is method is called from within the Material class when the property is first registered.

Parameters
block_idThe block id for the MaterialProperty
nameThe name of the property

Definition at line 584 of file SubProblem.C.

Referenced by MaterialBase::registerPropName().

585 {
586  _map_block_material_props[block_id].insert(name);
587 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::map< SubdomainID, std::set< std::string > > _map_block_material_props
Map of material properties (block_id -> list of properties)
Definition: SubProblem.h:1067

◆ storeSubdomainZeroMatProp()

void SubProblem::storeSubdomainZeroMatProp ( SubdomainID  block_id,
const MaterialPropertyName &  name 
)
virtualinherited

Adds to a map based on block ids of material properties for which a zero value can be returned.

Thes properties are optional and will not trigger a missing material property error.

Parameters
block_idThe block id for the MaterialProperty
nameThe name of the property

Definition at line 596 of file SubProblem.C.

Referenced by MaterialBase::storeSubdomainZeroMatProp().

597 {
598  _zero_block_material_props[block_id].insert(name);
599 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
std::map< SubdomainID, std::set< MaterialPropertyName > > _zero_block_material_props
Set of properties returned as zero properties.
Definition: SubProblem.h:1073

◆ subdomainSetup()

void FEProblemBase::subdomainSetup ( SubdomainID  subdomain,
const THREAD_ID  tid 
)
virtualinherited

Definition at line 2614 of file FEProblemBase.C.

Referenced by ComputeMarkerThread::subdomainChanged(), ComputeIndicatorThread::subdomainChanged(), ComputeMaterialsObjectThread::subdomainChanged(), ComputeDiracThread::subdomainChanged(), NonlinearThread::subdomainChanged(), ComputeUserObjectsThread::subdomainChanged(), and ThreadedFaceLoop< RangeType >::subdomainChanged().

2615 {
2616  _all_materials.subdomainSetup(subdomain, tid);
2617  // Call the subdomain methods of the output system, these are not threaded so only call it once
2618  if (tid == 0)
2620 
2621  for (auto & nl : _nl)
2622  nl->subdomainSetup(subdomain, tid);
2623 
2624  // FIXME: call displaced_problem->subdomainSetup() ?
2625  // When adding possibility with materials being evaluated on displaced mesh
2626 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
virtual void subdomainSetup(THREAD_ID tid=0) const override
void subdomainSetup()
Calls the subdomainSetup function for each of the output objects.
MaterialWarehouse _all_materials
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409

◆ subspaceDim()

unsigned int FEProblemBase::subspaceDim ( const std::string &  prefix) const
inlineinherited

Dimension of the subspace spanned by vectors with a given prefix.

Parameters
prefixPrefix of the vectors spanning the subspace.

Definition at line 2284 of file FEProblemBase.h.

Referenced by FEProblemBase::computeNearNullSpace(), FEProblemBase::computeNullSpace(), and FEProblemBase::computeTransposeNullSpace().

2285  {
2286  if (_subspace_dim.count(prefix))
2287  return _subspace_dim.find(prefix)->second;
2288  else
2289  return 0;
2290  }
std::map< std::string, unsigned int > _subspace_dim
Dimension of the subspace spanned by the vectors with a given prefix.

◆ swapBackMaterials()

void FEProblemBase::swapBackMaterials ( const THREAD_ID  tid)
virtualinherited

Definition at line 4483 of file FEProblemBase.C.

Referenced by NodalPatchRecovery::compute(), LineMaterialSamplerBase< Real >::execute(), ComputeMarkerThread::onElement(), ComputeElemAuxVarsThread< AuxKernelType >::onElement(), ComputeIndicatorThread::onElement(), NonlinearThread::onElement(), and ComputeUserObjectsThread::onElement().

4484 {
4485  auto && elem = _assembly[tid][0]->elem();
4487 }
void swapBack(const Elem &elem, unsigned int side=0)
material properties for given element (and possible side)
Definition: MaterialData.C:58
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
const MaterialData & getMaterialData(const THREAD_ID tid) const
MaterialPropertyStorage & _material_props

◆ swapBackMaterialsFace()

void FEProblemBase::swapBackMaterialsFace ( const THREAD_ID  tid)
virtualinherited

Definition at line 4490 of file FEProblemBase.C.

Referenced by NonlinearThread::onBoundary(), ComputeUserObjectsThread::onBoundary(), NonlinearThread::onInterface(), ComputeUserObjectsThread::onInterface(), ComputeIndicatorThread::onInternalSide(), NonlinearThread::onInternalSide(), ComputeUserObjectsThread::onInternalSide(), and ComputeElemAuxBcsThread< AuxKernelType >::operator()().

4491 {
4492  auto && elem = _assembly[tid][0]->elem();
4493  unsigned int side = _assembly[tid][0]->side();
4494  _bnd_material_props.getMaterialData(tid).swapBack(*elem, side);
4495 }
MaterialPropertyStorage & _bnd_material_props
void swapBack(const Elem &elem, unsigned int side=0)
material properties for given element (and possible side)
Definition: MaterialData.C:58
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
const MaterialData & getMaterialData(const THREAD_ID tid) const

◆ swapBackMaterialsNeighbor()

void FEProblemBase::swapBackMaterialsNeighbor ( const THREAD_ID  tid)
virtualinherited

Definition at line 4498 of file FEProblemBase.C.

Referenced by NonlinearThread::onInterface(), ComputeUserObjectsThread::onInterface(), ComputeIndicatorThread::onInternalSide(), NonlinearThread::onInternalSide(), ComputeUserObjectsThread::onInternalSide(), and ComputeElemAuxBcsThread< AuxKernelType >::operator()().

4499 {
4500  // NOTE: this will not work with h-adaptivity
4501  const Elem * neighbor = _assembly[tid][0]->neighbor();
4502  unsigned int neighbor_side =
4503  neighbor ? neighbor->which_neighbor_am_i(_assembly[tid][0]->elem()) : libMesh::invalid_uint;
4504 
4505  if (!neighbor)
4506  {
4507  if (haveFV())
4508  {
4509  // If neighbor is null, then we're on the neighbor side of a mesh boundary, e.g. we're off
4510  // the mesh in ghost-land. If we're using the finite volume method, then variable values and
4511  // consequently material properties have well-defined values in this ghost region outside of
4512  // the mesh and we really do want to reinit our neighbor materials in this case. Since we're
4513  // off in ghost land it's safe to do swaps with `MaterialPropertyStorage` using the elem and
4514  // elem_side keys
4515  neighbor = _assembly[tid][0]->elem();
4516  neighbor_side = _assembly[tid][0]->side();
4517  mooseAssert(neighbor, "We should have an appropriate value for elem coming from Assembly");
4518  }
4519  else
4520  mooseError("neighbor is null in Assembly!");
4521  }
4522 
4523  _neighbor_material_props.getMaterialData(tid).swapBack(*neighbor, neighbor_side);
4524 }
const unsigned int invalid_uint
virtual bool haveFV() const override
returns true if this problem includes/needs finite volume functionality.
void swapBack(const Elem &elem, unsigned int side=0)
material properties for given element (and possible side)
Definition: MaterialData.C:58
unsigned int which_neighbor_am_i(const Elem *e) const
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
MaterialPropertyStorage & _neighbor_material_props
const MaterialData & getMaterialData(const THREAD_ID tid) const

◆ syncSolutions()

virtual void MFEMProblem::syncSolutions ( Direction  direction)
inlineoverridevirtual

Method to transfer data to/from the external application to the associated transfer mesh.

Implements ExternalProblem.

Definition at line 49 of file MFEMProblem.h.

49 {}

◆ systemBaseAuxiliary() [1/2]

const SystemBase & FEProblemBase::systemBaseAuxiliary ( ) const
overridevirtualinherited

Return the auxiliary system object as a base class reference.

Implements SubProblem.

Definition at line 9600 of file FEProblemBase.C.

Referenced by PhysicsBase::copyVariablesFromMesh(), and getAuxVariableNames().

9601 {
9602  return *_aux;
9603 }
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ systemBaseAuxiliary() [2/2]

SystemBase & FEProblemBase::systemBaseAuxiliary ( )
overridevirtualinherited

Implements SubProblem.

Definition at line 9606 of file FEProblemBase.C.

9607 {
9608  return *_aux;
9609 }
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.

◆ systemBaseLinear() [1/2]

const SystemBase & FEProblemBase::systemBaseLinear ( unsigned int  sys_num) const
overridevirtualinherited

Get a constant base class reference to a linear system.

Parameters
sys_numThe number of the linear system

Implements SubProblem.

Definition at line 9568 of file FEProblemBase.C.

9569 {
9570  mooseAssert(sys_num < _linear_systems.size(),
9571  "System number greater than the number of linear systems");
9572  return *_linear_systems[sys_num];
9573 }
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.

◆ systemBaseLinear() [2/2]

SystemBase & FEProblemBase::systemBaseLinear ( unsigned int  sys_num)
overridevirtualinherited

Get a non-constant base class reference to a linear system.

Parameters
sys_numThe number of the linear system

Implements SubProblem.

Definition at line 9576 of file FEProblemBase.C.

9577 {
9578  mooseAssert(sys_num < _linear_systems.size(),
9579  "System number greater than the number of linear systems");
9580  return *_linear_systems[sys_num];
9581 }
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.

◆ systemBaseNonlinear() [1/2]

const SystemBase & FEProblemBase::systemBaseNonlinear ( const unsigned int  sys_num) const
overridevirtualinherited

Return the nonlinear system object as a base class reference given the system number.

Implements SubProblem.

Definition at line 9554 of file FEProblemBase.C.

9555 {
9556  mooseAssert(sys_num < _nl.size(), "System number greater than the number of nonlinear systems");
9557  return *_nl[sys_num];
9558 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ systemBaseNonlinear() [2/2]

SystemBase & FEProblemBase::systemBaseNonlinear ( const unsigned int  sys_num)
overridevirtualinherited

Implements SubProblem.

Definition at line 9561 of file FEProblemBase.C.

9562 {
9563  mooseAssert(sys_num < _nl.size(), "System number greater than the number of nonlinear systems");
9564  return *_nl[sys_num];
9565 }
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.

◆ systemBaseSolver() [1/2]

const SystemBase & FEProblemBase::systemBaseSolver ( const unsigned int  sys_num) const
overridevirtualinherited

Return the solver system object as a base class reference given the system number.

Implements SubProblem.

Definition at line 9584 of file FEProblemBase.C.

9585 {
9586  mooseAssert(sys_num < _solver_systems.size(),
9587  "System number greater than the number of solver systems");
9588  return *_solver_systems[sys_num];
9589 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.

◆ systemBaseSolver() [2/2]

SystemBase & FEProblemBase::systemBaseSolver ( const unsigned int  sys_num)
overridevirtualinherited

Implements SubProblem.

Definition at line 9592 of file FEProblemBase.C.

9593 {
9594  mooseAssert(sys_num < _solver_systems.size(),
9595  "System number greater than the number of solver systems");
9596  return *_solver_systems[sys_num];
9597 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.

◆ systemNumForVariable()

unsigned int FEProblemBase::systemNumForVariable ( const VariableName &  variable_name) const
inherited
Returns
the system number for the provided variable_name Can be nonlinear or auxiliary

Definition at line 6912 of file FEProblemBase.C.

Referenced by FEProblemBase::projectFunctionOnCustomRange(), and ElementSubdomainModifierBase::restoreOverriddenDofValues().

6913 {
6914  for (const auto & solver_sys : _solver_systems)
6915  if (solver_sys->hasVariable(variable_name))
6916  return solver_sys->number();
6917  mooseAssert(_aux, "Should have an auxiliary system");
6918  if (_aux->hasVariable(variable_name))
6919  return _aux->number();
6920 
6921  mooseError("Variable '",
6922  variable_name,
6923  "' was not found in any solver (nonlinear/linear) or auxiliary system");
6924 }
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ terminateSolve()

virtual void Problem::terminateSolve ( )
inlinevirtualinherited

Allow objects to request clean termination of the solve.

Definition at line 37 of file Problem.h.

Referenced by WebServerControl::execute(), Terminator::execute(), and TerminateChainControl::terminate().

37 { _termination_requested = true; };
bool _termination_requested
True if termination of the solve has been requested.
Definition: Problem.h:58

◆ theWarehouse()

TheWarehouse& FEProblemBase::theWarehouse ( ) const
inlineinherited

Definition at line 2559 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::addBoundaryCondition(), NonlinearSystemBase::addDGKernel(), NonlinearSystemBase::addDiracKernel(), FEProblemBase::addFVInterpolationMethod(), NonlinearSystemBase::addHDGKernel(), NonlinearSystemBase::addInterfaceKernel(), NonlinearSystemBase::addKernel(), NonlinearSystemBase::addNodalKernel(), FEProblemBase::addObject(), NonlinearSystemBase::addScalarKernel(), NonlinearSystemBase::addSplit(), FEProblemBase::addUserObject(), NonlinearSystemBase::checkKernelCoverage(), FEProblemBase::checkUserObjectJacobianRequirement(), FEProblemBase::checkUserObjects(), NonlinearSystemBase::computeJacobianInternal(), NonlinearSystemBase::computeResidualAndJacobianInternal(), NonlinearSystemBase::computeResidualInternal(), LinearSystem::containsTimeKernel(), FEProblemBase::customSetup(), ComputeResidualThread::determineObjectWarehouses(), ComputeResidualAndJacobianThread::determineObjectWarehouses(), executeMFEMObjects(), FEProblemBase::executeSamplers(), ComputeLinearFVElementalThread::fetchBlockSystemContributionObjects(), ComputeLinearFVFaceThread::fetchBlockSystemContributionObjects(), FEProblemBase::getDistribution(), FEProblemBase::getFVInterpolationMethod(), NonlinearSystemBase::getFVSetupObjects(), FEProblemBase::getKokkosUserObject(), getMFEMObject(), FEProblemBase::getMortarUserObjects(), FEProblemBase::getPositionsObject(), FEProblemBase::getPostprocessorObjectByName(), FEProblemBase::getSampler(), CompositionDT::getTimeSteppers(), FEProblemBase::getUOQuery(), FEProblemBase::getUserObject(), FEProblemBase::getUserObjectBase(), FEProblemBase::getVectorPostprocessorObjectByName(), FEProblemBase::hasDistribution(), FEProblemBase::hasFVInterpolationMethod(), hasMFEMObject(), FEProblemBase::hasUserObject(), VectorPostprocessorInterface::hasVectorPostprocessorByName(), BoundaryLinearFVFluxIntegral::initialSetup(), SideFVFluxBCIntegral::initialSetup(), ExplicitTimeIntegrator::initialSetup(), initialSetup(), LinearSystem::initialSetup(), FEProblemBase::initialSetup(), AdvancedOutput::initPostprocessorOrVectorPostprocessorLists(), FEProblemBase::needBoundaryMaterialOnSide(), FEProblemBase::needInterfaceMaterialOnSide(), FEProblemBase::needInternalNeighborSideMaterial(), JSONOutput::outputReporters(), BlockRestrictionDebugOutput::printBlockRestrictionGroups(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), BlockRestrictionDebugOutput::printBoundaryRestrictionGroups(), ComputeLinearFVElementalThread::setupSystemContributionObjects(), ComputeLinearFVFaceThread::setupSystemContributionObjects(), NonlinearThread::subdomainChanged(), and FEProblemBase::timestepSetup().

2559 { return _app.theWarehouse(); }
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
TheWarehouse & theWarehouse()
Definition: MooseApp.h:143

◆ time()

virtual Real& FEProblemBase::time ( ) const
inlinevirtualinherited

◆ timedSectionName()

std::string PerfGraphInterface::timedSectionName ( const std::string &  section_name) const
protectedinherited
Returns
The name of the timed section with the name section_name.

Optionally adds a prefix if one is defined.

Definition at line 55 of file PerfGraphInterface.C.

Referenced by PerfGraphInterface::registerTimedSection().

56 {
57  return _prefix.empty() ? "" : (_prefix + "::") + section_name;
58 }
const std::string _prefix
A prefix to use for all sections.

◆ timeOld()

virtual Real& FEProblemBase::timeOld ( ) const
inlinevirtualinherited

◆ timeStep()

virtual int& FEProblemBase::timeStep ( ) const
inlinevirtualinherited

◆ timestepSetup()

void FEProblemBase::timestepSetup ( )
overridevirtualinherited

Reimplemented from SubProblem.

Definition at line 1591 of file FEProblemBase.C.

Referenced by MFEMSteady::execute(), SteadyBase::execute(), Eigenvalue::execute(), NonlinearEigen::takeStep(), MFEMTransient::takeStep(), and TransientBase::takeStep().

1592 {
1594 
1595  if (_t_step > 1 && _num_grid_steps)
1596  {
1597  libMesh::MeshRefinement mesh_refinement(_mesh);
1598  std::unique_ptr<libMesh::MeshRefinement> displaced_mesh_refinement(nullptr);
1599  if (_displaced_mesh)
1600  displaced_mesh_refinement = std::make_unique<libMesh::MeshRefinement>(*_displaced_mesh);
1601 
1602  for (MooseIndex(_num_grid_steps) i = 0; i < _num_grid_steps; ++i)
1603  {
1604  if (_displaced_problem)
1605  // If the DisplacedProblem is active, undisplace the DisplacedMesh in preparation for
1606  // refinement. We can't safely refine the DisplacedMesh directly, since the Hilbert keys
1607  // computed on the inconsistenly-displaced Mesh are different on different processors,
1608  // leading to inconsistent Hilbert keys. We must do this before the undisplaced Mesh is
1609  // coarsensed, so that the element and node numbering is still consistent. We also have to
1610  // make sure this is done during every step of coarsening otherwise different partitions
1611  // will be generated for the reference and displaced meshes (even for replicated)
1612  _displaced_problem->undisplaceMesh();
1613 
1614  mesh_refinement.uniformly_coarsen();
1615  if (_displaced_mesh)
1616  displaced_mesh_refinement->uniformly_coarsen();
1617 
1618  // Mark this as an intermediate change because we do not yet want to reinit_systems. E.g. we
1619  // need things to happen in the following order for the undisplaced problem:
1620  // u1) EquationSystems::reinit_solutions. This will restrict the solution vectors and then
1621  // contract the mesh
1622  // u2) MooseMesh::meshChanged. This will update the node/side lists and other
1623  // things which needs to happen after the contraction
1624  // u3) GeometricSearchData::reinit. Once the node/side lists are updated we can perform our
1625  // geometric searches which will aid in determining sparsity patterns
1626  //
1627  // We do these things for the displaced problem (if it exists)
1628  // d1) EquationSystems::reinit. Restrict the displaced problem vector copies and then contract
1629  // the mesh. It's safe to do a full reinit with the displaced because there are no
1630  // matrices that sparsity pattern calculations will be conducted for
1631  // d2) MooseMesh::meshChanged. This will update the node/side lists and other
1632  // things which needs to happen after the contraction
1633  // d3) UpdateDisplacedMeshThread::operator(). Re-displace the mesh using the *displaced*
1634  // solution vector copy because we don't know the state of the reference solution vector.
1635  // It's safe to use the displaced copy because we are outside of a non-linear solve,
1636  // and there is no concern about differences between solution and current_local_solution
1637  // d4) GeometricSearchData::reinit. With the node/side lists updated and the mesh
1638  // re-displaced, we can perform our geometric searches, which will aid in determining the
1639  // sparsity pattern of the matrix held by the libMesh::ImplicitSystem held by the
1640  // NonlinearSystem held by this
1641  meshChanged(
1642  /*intermediate_change=*/true, /*contract_mesh=*/true, /*clean_refinement_flags=*/true);
1643  }
1644 
1645  // u4) Now that all the geometric searches have been done (both undisplaced and displaced),
1646  // we're ready to update the sparsity pattern
1647  es().reinit_systems();
1648  }
1649 
1651  if (_line_search)
1652  _line_search->timestepSetup();
1653 
1654  // Random interface objects
1655  for (const auto & it : _random_data_objects)
1656  it.second->updateSeeds(EXEC_TIMESTEP_BEGIN);
1657 
1658  unsigned int n_threads = libMesh::n_threads();
1659  for (THREAD_ID tid = 0; tid < n_threads; tid++)
1660  {
1663  }
1664 
1665 #ifdef MOOSE_KOKKOS_ENABLED
1667 #endif
1668 
1669  _aux->timestepSetup();
1670  for (auto & sys : _solver_systems)
1671  sys->timestepSetup();
1672 
1673  if (_displaced_problem)
1674  // timestepSetup for displaced systems
1675  _displaced_problem->timestepSetup();
1676 
1677  for (THREAD_ID tid = 0; tid < n_threads; tid++)
1678  {
1681  _markers.timestepSetup(tid);
1682  }
1683 
1684  std::vector<UserObject *> userobjs;
1685  theWarehouse().query().condition<AttribSystem>("UserObject").queryIntoUnsorted(userobjs);
1686  for (auto obj : userobjs)
1687  obj->timestepSetup();
1688 
1689 #ifdef MOOSE_KOKKOS_ENABLED
1690  {
1691  std::vector<UserObjectBase *> userobjs;
1692  theWarehouse().query().condition<AttribSystem>("KokkosUserObject").queryIntoUnsorted(userobjs);
1693  for (auto obj : userobjs)
1694  obj->timestepSetup();
1695  }
1696 #endif
1697 
1698  // Timestep setup of output objects
1700 
1703  _has_nonlocal_coupling = true;
1704 }
virtual void meshChanged()
Deprecated.
unsigned int n_threads()
MooseObjectWarehouse< InternalSideIndicatorBase > _internal_side_indicators
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.
ExecuteMooseObjectWarehouse< Control > _control_warehouse
The control logic warehouse.
virtual void timestepSetup(THREAD_ID tid=0) const override
bool _requires_nonlocal_coupling
nonlocal coupling requirement flag
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
unsigned int _num_grid_steps
Number of steps in a grid sequence.
MooseObjectWarehouse< Moose::FunctionBase > _kokkos_functions
virtual void reinit_systems()
TheWarehouse & theWarehouse() const
const ExecFlagType EXEC_TIMESTEP_BEGIN
Definition: Moose.C:37
virtual void timestepSetup(THREAD_ID tid=0) const
virtual libMesh::EquationSystems & es() override
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseMesh & _mesh
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
A map of objects that consume random numbers.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
MooseObjectWarehouse< Indicator > _indicators
virtual void timestepSetup()
Definition: SubProblem.C:1186
bool hasActiveObjects(THREAD_ID tid=0) const
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
Definition: TheWarehouse.h:467
std::shared_ptr< DisplacedProblem > _displaced_problem
MooseObjectWarehouse< Function > _functions
functions
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
Definition: TheWarehouse.h:285
MooseObjectWarehouse< Marker > _markers
MaterialWarehouse _all_materials
void timestepSetup()
Calls the timestepSetup function for each of the output objects.
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
Definition: MooseApp.C:2409
MooseMesh * _displaced_mesh
unsigned int THREAD_ID
Definition: MooseTypes.h:237
MooseObjectWarehouse< IntegratedBCBase > _nonlocal_integrated_bcs
nonlocal integrated_bcs
std::shared_ptr< LineSearch > _line_search
MooseObjectWarehouse< KernelBase > _nonlocal_kernels
nonlocal kernels

◆ transient()

virtual void FEProblemBase::transient ( bool  trans)
inlinevirtualinherited

Definition at line 584 of file FEProblemBase.h.

Referenced by EigenExecutionerBase::EigenExecutionerBase(), and TransientBase::TransientBase().

584 { _transient = trans; }

◆ trustUserCouplingMatrix()

void FEProblemBase::trustUserCouplingMatrix ( )
inherited

Whether to trust the user coupling matrix even if we want to do things like be paranoid and create a full coupling matrix.

See https://github.com/idaholab/moose/issues/16395 for detailed background

Definition at line 6646 of file FEProblemBase.C.

Referenced by SingleMatrixPreconditioner::SingleMatrixPreconditioner().

6647 {
6649  mooseError("Someone told us (the FEProblemBase) to trust the user coupling matrix, but we "
6650  "haven't been provided a coupling matrix!");
6651 
6653 }
bool _trust_user_coupling_matrix
Whether to trust the user coupling matrix no matter what.
Moose::CouplingType _coupling
Type of variable coupling.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ type()

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

Get the type of this class.

Returns
the name of the type of this class

Definition at line 93 of file MooseBase.h.

Referenced by CreateProblemDefaultAction::act(), SetupDebugAction::act(), MaterialDerivativeTestAction::act(), MaterialOutputAction::act(), FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), FEProblemBase::addConvergence(), FEProblemBase::addDistribution(), MooseApp::addExecutor(), MooseApp::addExecutorParams(), addFESpace(), addFESpaceHierarchy(), addFunction(), FEProblemBase::addFunction(), FEProblemBase::addMeshDivision(), MooseApp::addMeshGenerator(), MeshGenerator::addMeshSubgenerator(), FEProblemBase::addObject(), addPostprocessor(), FEProblemBase::addPredictor(), CreateDisplacedProblemAction::addProxyRelationshipManagers(), addQuadratureFunction(), FEProblemBase::addReporter(), FEProblemBase::addSampler(), WebServerControl::addServerActionsInternal(), FEProblemBase::addTimeIntegrator(), MooseServer::addValuesToList(), addVectorPostprocessor(), DisplacedProblem::addVectorTag(), SubProblem::addVectorTag(), FEProblemBase::advanceMultiApps(), MooseApp::appendMeshGenerator(), AuxKernelBase::AuxKernelBase(), FEProblemBase::backupMultiApps(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), BoundaryPreservedMarker::BoundaryPreservedMarker(), DistributedRectilinearMeshGenerator::buildCube(), MooseMesh::buildHRefinementAndCoarseningMaps(), MooseMesh::buildLowerDMesh(), MooseMesh::buildPRefinementAndCoarseningMaps(), PhysicsBase::checkComponentType(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), ActionComponent::checkRequiredTasks(), PhysicsBase::checkRequiredTasks(), FEProblemBase::checkUserObjectNameCollision(), MFEMMultiAppTransfer::checkValidTransferProblemTypes(), ADDGKernel::computeElemNeighJacobian(), DGKernel::computeElemNeighJacobian(), ElemElemConstraint::computeElemNeighJacobian(), ArrayDGKernel::computeElemNeighJacobian(), ADDGKernel::computeElemNeighResidual(), DGKernel::computeElemNeighResidual(), ElemElemConstraint::computeElemNeighResidual(), ArrayDGKernel::computeElemNeighResidual(), LowerDIntegratedBC::computeLowerDJacobian(), ArrayLowerDIntegratedBC::computeLowerDJacobian(), DGLowerDKernel::computeLowerDJacobian(), ArrayDGLowerDKernel::computeLowerDJacobian(), LowerDIntegratedBC::computeLowerDOffDiagJacobian(), ArrayLowerDIntegratedBC::computeLowerDOffDiagJacobian(), ArrayHFEMDirichletBC::computeLowerDQpJacobian(), ArrayHFEMDiffusion::computeLowerDQpJacobian(), HFEMDirichletBC::computeLowerDQpJacobian(), HFEMDiffusion::computeLowerDQpJacobian(), ArrayHFEMDirichletBC::computeLowerDQpOffDiagJacobian(), HFEMDirichletBC::computeLowerDQpOffDiagJacobian(), ArrayLowerDIntegratedBC::computeLowerDQpOffDiagJacobian(), ArrayDGLowerDKernel::computeLowerDQpOffDiagJacobian(), FEProblemBase::computeMultiAppsDT(), ADDGKernel::computeOffDiagElemNeighJacobian(), DGKernel::computeOffDiagElemNeighJacobian(), ArrayDGKernel::computeOffDiagElemNeighJacobian(), DGLowerDKernel::computeOffDiagLowerDJacobian(), ArrayDGLowerDKernel::computeOffDiagLowerDJacobian(), DGConvection::computeQpJacobian(), ScalarKernel::computeQpJacobian(), InterfaceDiffusion::computeQpJacobian(), ArrayDGDiffusion::computeQpJacobian(), InterfaceReaction::computeQpJacobian(), CoupledTiedValueConstraint::computeQpJacobian(), TiedValueConstraint::computeQpJacobian(), DGDiffusion::computeQpJacobian(), LinearNodalConstraint::computeQpJacobian(), EqualValueBoundaryConstraint::computeQpJacobian(), CoupledTiedValueConstraint::computeQpOffDiagJacobian(), HFEMTrialJump::computeQpOffDiagJacobian(), HFEMTestJump::computeQpOffDiagJacobian(), ArrayDGKernel::computeQpOffDiagJacobian(), DGConvection::computeQpResidual(), ArrayHFEMDiffusion::computeQpResidual(), HFEMDiffusion::computeQpResidual(), ScalarKernel::computeQpResidual(), InterfaceDiffusion::computeQpResidual(), ArrayDGDiffusion::computeQpResidual(), ADMatInterfaceReaction::computeQpResidual(), InterfaceReaction::computeQpResidual(), ADDGAdvection::computeQpResidual(), CoupledTiedValueConstraint::computeQpResidual(), TiedValueConstraint::computeQpResidual(), LinearNodalConstraint::computeQpResidual(), ADDGDiffusion::computeQpResidual(), DGDiffusion::computeQpResidual(), HFEMTrialJump::computeQpResidual(), HFEMTestJump::computeQpResidual(), EqualValueBoundaryConstraint::computeQpResidual(), FEProblemBase::computeSystems(), FEProblemBase::computeUserObjectByName(), FEProblemBase::computeUserObjects(), FEProblemBase::computeUserObjectsInternal(), DisplacedProblem::createQRules(), FEProblemBase::createQRules(), MooseApp::createRecoverablePerfGraph(), DumpObjectsProblem::deduceNecessaryParameters(), DumpObjectsProblem::dumpObjectHelper(), FEProblemBase::duplicateVariableCheck(), FEProblemBase::execMultiApps(), FEProblemBase::execMultiAppTransfers(), FEProblemBase::execTransfers(), SteadyBase::execute(), WebServerControl::execute(), ActionWarehouse::executeActionsWithAction(), FEProblemBase::finishMultiAppStep(), FVScalarLagrangeMultiplierInterface::FVScalarLagrangeMultiplierInterface(), MooseServer::gatherDocumentReferencesLocations(), Boundary2DDelaunayGenerator::General2DDelaunay(), SurfaceSubdomainsDelaunayRemesher::General2DDelaunay(), LowerDBlockFromSidesetGenerator::generate(), SubdomainPerElementGenerator::generate(), Boundary2DDelaunayGenerator::generate(), PatternedMeshGenerator::generate(), MeshGenerator::generateInternal(), MeshGenerator::generateInternalCSG(), MultiAppTransfer::getAppInfo(), TransfiniteMeshGenerator::getEdge(), ElementGenerator::getElemType(), MooseServer::getInputLookupDefinitionNodes(), FEProblemBase::getMaterial(), FEProblemBase::getMaterialData(), FEProblemBase::getMaterialPropertyStorageConsumers(), MaterialOutputAction::getParams(), ReporterData::getReporterInfo(), MooseServer::getSyntaxMetadata(), FEProblemBase::getTransfers(), FEProblemBase::getUOQuery(), DisplacedProblem::getVectorTags(), SubProblem::getVectorTags(), CommonOutputAction::hasConsole(), FEProblemBase::hasMultiApps(), AdvancedOutput::hasOutput(), FEProblemBase::incrementMultiAppTStep(), NEML2Action::inferMOOSEIOType(), AdvancedOutput::initAvailableLists(), FunctorPositions::initialize(), FunctorTimes::initialize(), MultiAppConservativeTransfer::initialSetup(), LinearFVAdvection::initialSetup(), LinearFVAnisotropicDiffusion::initialSetup(), LinearFVDiffusion::initialSetup(), ArrayDGDiffusion::initQpResidual(), AdvancedOutput::initShowHideLists(), RelationshipManager::isType(), FEProblemBase::logAdd(), MaterialFunctorConverterTempl< T >::MaterialFunctorConverterTempl(), mesh(), MooseObject::MooseObject(), DisplacedProblem::numVectorTags(), SubProblem::numVectorTags(), Console::output(), AdvancedOutput::output(), ConsoleUtils::outputExecutionInformation(), SampledOutput::outputStep(), Output::outputStep(), FEProblemBase::outputStep(), MooseServer::parseDocumentForDiagnostics(), MooseMesh::prepare(), ProjectedStatefulMaterialStorageAction::processProperty(), MooseApp::recursivelyCreateExecutors(), SolutionInvalidInterface::registerInvalidSolutionInternal(), FEProblemBase::restoreMultiApps(), MeshRepairGenerator::separateSubdomainsByElementType(), FEProblemBase::setCoupling(), MooseApp::setupOptions(), ExplicitTVDRK2::solve(), ExplicitRK2::solve(), Reporter::store(), MooseBase::typeAndName(), ScalarKernelBase::uOld(), AuxScalarKernel::uOld(), DisplacedProblem::updateGeomSearch(), FEProblemBase::updateGeomSearch(), UserObjectInterface::userObjectType(), and AdvancedOutput::wantOutput().

94  {
95  mooseAssert(_type.size(), "Empty type");
96  return _type;
97  }
const std::string & _type
The type of this class.
Definition: MooseBase.h:378

◆ typeAndName()

std::string MooseBase::typeAndName ( ) const
inherited

Get the class's combined type and name; useful in error handling.

Returns
The type and name of this class in the form '<type()> "<name()>"'.

Definition at line 57 of file MooseBase.C.

Referenced by MaterialPropertyStorage::addProperty(), FEProblemBase::checkUserObjectNameCollision(), MeshGeneratorSystem::dataDrivenError(), ReporterContext< std::vector< T > >::finalize(), ReporterData::getReporterInfo(), MFEMPointScalarCoefficientValueSampler::initialSetup(), MFEMSamplerBase::initialSetup(), MFEMVariableSamplerBase::initialSetup(), and WebServerControl::outputMessage().

58 {
59  return type() + std::string(" \"") + name() + std::string("\"");
60 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93

◆ uDotDotOldRequested()

virtual bool FEProblemBase::uDotDotOldRequested ( )
inlinevirtualinherited

Get boolean flag to check whether old solution second time derivative needs to be stored.

Definition at line 2635 of file FEProblemBase.h.

Referenced by SystemBase::addDotVectors().

2636  {
2638  mooseError("FEProblemBase: When requesting old second time derivative of solution, current "
2639  "second time derivation of solution should also be stored. Please set "
2640  "`u_dotdot_requested` to true using setUDotDotRequested.");
2641  return _u_dotdot_old_requested;
2642  }
bool _u_dotdot_old_requested
Whether old solution second time derivative needs to be stored.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
bool _u_dotdot_requested
Whether solution second time derivative needs to be stored.

◆ uDotDotRequested()

virtual bool FEProblemBase::uDotDotRequested ( )
inlinevirtualinherited

Get boolean flag to check whether solution second time derivative needs to be stored.

Definition at line 2621 of file FEProblemBase.h.

Referenced by SystemBase::addDotVectors(), and FEProblemBase::addTimeIntegrator().

2621 { return _u_dotdot_requested; }
bool _u_dotdot_requested
Whether solution second time derivative needs to be stored.

◆ uDotOldRequested()

virtual bool FEProblemBase::uDotOldRequested ( )
inlinevirtualinherited

Get boolean flag to check whether old solution time derivative needs to be stored.

Definition at line 2624 of file FEProblemBase.h.

Referenced by SystemBase::addDotVectors().

2625  {
2627  mooseError("FEProblemBase: When requesting old time derivative of solution, current time "
2628  "derivative of solution should also be stored. Please set `u_dot_requested` to "
2629  "true using setUDotRequested.");
2630 
2631  return _u_dot_old_requested;
2632  }
bool _u_dot_requested
Whether solution time derivative needs to be stored.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
bool _u_dot_old_requested
Whether old solution time derivative needs to be stored.

◆ uDotRequested()

virtual bool FEProblemBase::uDotRequested ( )
inlinevirtualinherited

Get boolean flag to check whether solution time derivative needs to be stored.

Definition at line 2618 of file FEProblemBase.h.

Referenced by SystemBase::addDotVectors().

2618 { return _u_dot_requested; }
bool _u_dot_requested
Whether solution time derivative needs to be stored.

◆ uniformRefine()

void FEProblemBase::uniformRefine ( )
inherited

uniformly refine the problem mesh(es).

This will also prolong the the solution, and in order for that to be safe, we can only perform one refinement at a time

Definition at line 9630 of file FEProblemBase.C.

Referenced by FEProblemSolve::solve().

9631 {
9632  // ResetDisplacedMeshThread::onNode looks up the reference mesh by ID, so we need to make sure
9633  // we undisplace before adapting the reference mesh
9634  if (_displaced_problem)
9635  _displaced_problem->undisplaceMesh();
9636 
9638  if (_displaced_problem)
9640 
9641  meshChanged(
9642  /*intermediate_change=*/false, /*contract_mesh=*/true, /*clean_refinement_flags=*/true);
9643 }
virtual void meshChanged()
Deprecated.
static void uniformRefine(MooseMesh *mesh, unsigned int level=libMesh::invalid_uint)
Performs uniform refinement of the passed Mesh object.
Definition: Adaptivity.C:301
MooseMesh & _mesh
std::shared_ptr< DisplacedProblem > _displaced_problem

◆ uniqueName()

MooseObjectName MooseBase::uniqueName ( ) const
inherited
Returns
The unique name for accessing input parameters of this object in the InputParameterWarehouse

Definition at line 69 of file MooseBase.C.

Referenced by MooseBase::connectControllableParams(), and Action::uniqueActionName().

70 {
71  if (!_pars.have_parameter<std::string>(unique_name_param))
72  mooseError("uniqueName(): Object does not have a unique name");
73  return MooseObjectName(_pars.get<std::string>(unique_name_param));
74 }
const InputParameters & _pars
The object&#39;s parameters.
Definition: MooseBase.h:384
std::vector< std::pair< R1, R2 > > get(const std::string &param1, const std::string &param2) const
Combine two vector parameters into a single vector of pairs.
static const std::string unique_name_param
The name of the parameter that contains the unique object name.
Definition: MooseBase.h:57
bool have_parameter(std::string_view name) const
A wrapper around the Parameters base class method.
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271
A class for storing the names of MooseObject by tag and object name.

◆ uniqueParameterName()

MooseObjectParameterName MooseBase::uniqueParameterName ( const std::string &  parameter_name) const
inherited
Returns
The unique parameter name of a valid parameter of this object for accessing parameter controls

Definition at line 63 of file MooseBase.C.

64 {
65  return MooseObjectParameterName(getBase(), name(), parameter_name);
66 }
const std::string & name() const
Get the name of the class.
Definition: MooseBase.h:103
A class for storing an input parameter name.
const std::string & getBase() const
Definition: MooseBase.h:147

◆ updateActiveObjects()

void FEProblemBase::updateActiveObjects ( )
virtualinherited

Update the active objects in the warehouses.

Reimplemented in DumpObjectsProblem.

Definition at line 5625 of file FEProblemBase.C.

Referenced by MooseEigenSystem::eigenKernelOnCurrent(), MooseEigenSystem::eigenKernelOnOld(), and FixedPointSolve::solveStep().

5626 {
5627  TIME_SECTION("updateActiveObjects", 5, "Updating Active Objects");
5628 
5629  for (THREAD_ID tid = 0; tid < libMesh::n_threads(); ++tid)
5630  {
5631  for (auto & nl : _nl)
5632  nl->updateActive(tid);
5633  _aux->updateActive(tid);
5636  _markers.updateActive(tid);
5638  _materials.updateActive(tid);
5640  }
5641 
5649 
5650 #ifdef MOOSE_KOKKOS_ENABLED
5652 #endif
5653 }
unsigned int n_threads()
MooseObjectWarehouse< InternalSideIndicatorBase > _internal_side_indicators
ExecuteMooseObjectWarehouse< Control > _control_warehouse
The control logic warehouse.
void updateActive(THREAD_ID tid=0) override
Updates the active objects storage.
MaterialWarehouse _kokkos_materials
ExecuteMooseObjectWarehouse< TransientMultiApp > _transient_multi_apps
Storage for TransientMultiApps (only needed for calling &#39;computeDT&#39;)
ExecuteMooseObjectWarehouse< Transfer > _from_multi_app_transfers
Transfers executed just after MultiApps to transfer data from them.
ExecuteMooseObjectWarehouse< Transfer > _transfers
Normal Transfers.
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
ExecuteMooseObjectWarehouse< Transfer > _to_multi_app_transfers
Transfers executed just before MultiApps to transfer data to them.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
MooseObjectWarehouse< Indicator > _indicators
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
MaterialWarehouse _discrete_materials
virtual void updateActive(THREAD_ID tid=0) override
Update the active status of Kernels.
ExecuteMooseObjectWarehouse< Transfer > _between_multi_app_transfers
Transfers executed just before MultiApps to transfer data between them.
MooseObjectWarehouse< Marker > _markers
MaterialWarehouse _all_materials
virtual void updateActive(THREAD_ID tid=0) override
Update the active status of Kernels.
unsigned int THREAD_ID
Definition: MooseTypes.h:237
MaterialWarehouse _materials

◆ updateFESpaces()

void MFEMProblem::updateFESpaces ( )

Calls Update() on all FE spaces.

Definition at line 757 of file MFEMProblem.C.

Referenced by MFEMRefinementMarker::hRefine(), and rebalanceMesh().

758 {
759  for (const auto & fe_space_pair : _problem_data.fespaces)
760  fe_space_pair.second->Update();
761 }
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
Moose::MFEM::FESpaces fespaces

◆ updateGeomSearch()

void FEProblemBase::updateGeomSearch ( GeometricSearchData::GeometricSearchType  type = GeometricSearchData::ALL)
overridevirtualinherited

Update this object's geometric search data as well as the displaced problem's if it exists.

Implements SubProblem.

Definition at line 8381 of file FEProblemBase.C.

Referenced by NonlinearSystemBase::augmentSparsity(), and FEProblemBase::initialSetup().

8382 {
8383  TIME_SECTION("updateGeometricSearch", 3, "Updating Geometric Search");
8384 
8386 
8387  if (_displaced_problem)
8388  _displaced_problem->updateGeomSearch(type);
8389 }
const std::string & type() const
Get the type of this class.
Definition: MooseBase.h:93
void update(GeometricSearchType type=ALL)
Update all of the search objects.
std::shared_ptr< DisplacedProblem > _displaced_problem
GeometricSearchData _geometric_search_data

◆ updateGridFunctions()

void MFEMProblem::updateGridFunctions ( )

Calls Update() on all gridfunctions.

Definition at line 764 of file MFEMProblem.C.

Referenced by MFEMRefinementMarker::hRefine(), MFEMRefinementMarker::pRefine(), and rebalanceMesh().

765 {
766  for (const auto & gridfunction_pair : _problem_data.gridfunctions)
767  gridfunction_pair.second->Update();
768 }
MFEMProblemData _problem_data
Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.
Definition: MFEMProblem.h:397
Moose::MFEM::GridFunctions gridfunctions

◆ updateMeshXFEM()

bool FEProblemBase::updateMeshXFEM ( )
virtualinherited

Update the mesh due to changing XFEM cuts.

Definition at line 8654 of file FEProblemBase.C.

Referenced by FEProblemBase::initialSetup(), and FixedPointSolve::solveStep().

8655 {
8656  TIME_SECTION("updateMeshXFEM", 5, "Updating XFEM");
8657 
8658  bool updated = false;
8659  if (haveXFEM())
8660  {
8661  if (_xfem->updateHeal())
8662  // XFEM exodiff tests rely on a given numbering because they cannot use map = true due to
8663  // having coincident elements. While conceptually speaking we do not need to contract the
8664  // mesh, we need its call to renumber_nodes_and_elements in order to preserve these tests
8665  meshChanged(
8666  /*intermediate_change=*/false, /*contract_mesh=*/true, /*clean_refinement_flags=*/false);
8667 
8668  updated = _xfem->update(_time, _nl, *_aux);
8669  if (updated)
8670  {
8671  meshChanged(
8672  /*intermediate_change=*/false, /*contract_mesh=*/true, /*clean_refinement_flags=*/false);
8673  _xfem->initSolution(_nl, *_aux);
8674  restoreSolutions();
8675  _console << "\nXFEM update complete: Mesh modified" << std::endl;
8676  }
8677  else
8678  _console << "\nXFEM update complete: Mesh not modified" << std::endl;
8679  }
8680  return updated;
8681 }
virtual void meshChanged()
Deprecated.
bool haveXFEM()
Find out whether the current analysis is using XFEM.
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
virtual void restoreSolutions()
const ConsoleStream _console
An instance of helper class to write streams to the Console objects.
std::shared_ptr< XFEMInterface > _xfem
Pointer to XFEM controller.

◆ updateMortarMesh()

void FEProblemBase::updateMortarMesh ( )
virtualinherited

Definition at line 8392 of file FEProblemBase.C.

Referenced by FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), FEProblemBase::init(), and FEProblemBase::initialSetup().

8393 {
8394  TIME_SECTION("updateMortarMesh", 5, "Updating Mortar Mesh");
8395 
8396  FloatingPointExceptionGuard fpe_guard(_app);
8397 
8398  _mortar_data->update();
8399 }
Scope guard for starting and stopping Floating Point Exception Trapping.
MooseApp & _app
The MOOSE application this is associated with.
Definition: MooseBase.h:375
std::unique_ptr< MortarInterfaceWarehouse > _mortar_data

◆ updateSolution()

bool FEProblemBase::updateSolution ( NumericVector< libMesh::Number > &  vec_solution,
NumericVector< libMesh::Number > &  ghosted_solution 
)
virtualinherited

Update the solution.

Parameters
vec_solutionLocal solution vector that gets modified by this method
ghosted_solutionGhosted solution vector
Returns
true if the solution was modified, false otherwise

Definition at line 8360 of file FEProblemBase.C.

Referenced by FEProblemBase::computePostCheck().

8362 {
8363  return false;
8364 }

◆ useHashTableMatrixAssembly()

bool FEProblemBase::useHashTableMatrixAssembly ( ) const
inlineinherited

Definition at line 2960 of file FEProblemBase.h.

Referenced by NonlinearSystemBase::addConstraint().

const bool _use_hash_table_matrix_assembly
Whether to assemble matrices using hash tables instead of preallocating matrix memory.

◆ useSNESMFReuseBase()

bool FEProblemBase::useSNESMFReuseBase ( )
inlineinherited

Return a flag that indicates if we are reusing the vector base.

Definition at line 2572 of file FEProblemBase.h.

Referenced by NonlinearSystem::potentiallySetupFiniteDifferencing().

2572 { return _snesmf_reuse_base; }
bool _snesmf_reuse_base
If or not to resuse the base vector for matrix-free calculation.

◆ validateVariableNumericType()

void MFEMProblem::validateVariableNumericType ( const std::string &  var_type,
const std::string &  var_name 
) const
protected

Verify that a primary variable's numeric type matches the problem's equation system.

Definition at line 358 of file MFEMProblem.C.

Referenced by MFEMEigenproblem::addVariable(), and addVariable().

360 {
361  const bool variable_is_complex = var_type == "MFEMComplexVariable";
362  const bool problem_is_complex = _num_type == NumericType::COMPLEX;
363  if (variable_is_complex != problem_is_complex)
364  paramError("numeric_type",
365  "The problem numeric type does not match primary MFEM variable '",
366  var_name,
367  "', which is ",
368  variable_is_complex ? "complex." : "real.");
369 }
void paramError(const std::string &param, Args... args) const
Emits an error prefixed with the file and line number of the given param (from the input file) along ...
Definition: MooseBase.h:457
NumericType _num_type
The numeric representation currently active for this problem.
Definition: MFEMProblem.h:402

◆ validParams()

InputParameters MFEMProblem::validParams ( )
static

Return the input parameters used to construct an MFEM problem.

Definition at line 60 of file MFEMProblem.C.

Referenced by MFEMEigenproblem::validParams().

61 {
63  params.addClassDescription("Problem type for building and solving the finite element problem "
64  "using the MFEM finite element library.");
65  MooseEnum numeric_types("real complex", "real");
66  params.addParam<MooseEnum>("numeric_type", numeric_types, "Number type used for the problem");
67 
68  return params;
69 }
static InputParameters validParams()
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
Definition: MooseEnum.h:54
void addClassDescription(const std::string &doc_string)
This method adds a description of the class that will be displayed in the input file syntax dump...
void addParam(const std::string &name, const S &value, const std::string &doc_string)
These methods add an optional parameter and a documentation string to the InputParameters object...

◆ vectorTagExists() [1/2]

virtual bool SubProblem::vectorTagExists ( const TagID  tag_id) const
inlinevirtualinherited

◆ vectorTagExists() [2/2]

bool SubProblem::vectorTagExists ( const TagName &  tag_name) const
virtualinherited

Check to see if a particular Tag exists by using Tag name.

Reimplemented in DisplacedProblem.

Definition at line 137 of file SubProblem.C.

138 {
139  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
140 
141  const auto tag_name_upper = MooseUtils::toUpper(tag_name);
142  for (const auto & vector_tag : _vector_tags)
143  if (vector_tag._name == tag_name_upper)
144  return true;
145 
146  return false;
147 }
std::vector< VectorTag > _vector_tags
The declared vector tags.
Definition: SubProblem.h:1185
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
std::string toUpper(std::string name)
Convert supplied string to upper case.

◆ vectorTagName()

TagName SubProblem::vectorTagName ( const TagID  tag) const
virtualinherited

Retrieve the name associated with a TagID.

Reimplemented in DisplacedProblem.

Definition at line 222 of file SubProblem.C.

Referenced by SystemBase::closeTaggedVector(), NonlinearSystemBase::getResidualNonTimeVector(), NonlinearSystemBase::getResidualTimeVector(), SystemBase::removeVector(), NonlinearSystemBase::residualGhosted(), DisplacedProblem::vectorTagName(), and SystemBase::zeroTaggedVector().

223 {
224  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
225  if (!vectorTagExists(tag_id))
226  mooseError("Vector tag with ID ", tag_id, " does not exist");
227 
228  return _vector_tags[tag_id]._name;
229 }
std::vector< VectorTag > _vector_tags
The declared vector tags.
Definition: SubProblem.h:1185
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
virtual bool vectorTagExists(const TagID tag_id) const
Check to see if a particular Tag exists.
Definition: SubProblem.h:201
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ vectorTagNotZeroed()

bool SubProblem::vectorTagNotZeroed ( const TagID  tag) const
inherited

Checks if a vector tag is in the list of vectors that will not be zeroed when other tagged vectors are.

Parameters
tagthe TagID of the vector that is currently being checked
Returns
false if the tag is not within the set of vectors that are intended to not be zero or if the set is empty. returns true otherwise

Definition at line 156 of file SubProblem.C.

Referenced by SystemBase::zeroTaggedVector().

157 {
158  return _not_zeroed_tagged_vectors.count(tag);
159 }
std::unordered_set< TagID > _not_zeroed_tagged_vectors
the list of vector tags that will not be zeroed when all other tags are
Definition: SubProblem.h:1132

◆ vectorTagType()

Moose::VectorTagType SubProblem::vectorTagType ( const TagID  tag_id) const
virtualinherited

Reimplemented in DisplacedProblem.

Definition at line 232 of file SubProblem.C.

Referenced by MooseVariableScalar::reinit(), TaggingInterface::TaggingInterface(), TagVectorAux::TagVectorAux(), and DisplacedProblem::vectorTagType().

233 {
234  mooseAssert(verifyVectorTags(), "Vector tag storage invalid");
235  if (!vectorTagExists(tag_id))
236  mooseError("Vector tag with ID ", tag_id, " does not exist");
237 
238  return _vector_tags[tag_id]._type;
239 }
std::vector< VectorTag > _vector_tags
The declared vector tags.
Definition: SubProblem.h:1185
bool verifyVectorTags() const
Verify the integrity of _vector_tags and _typed_vector_tags.
Definition: SubProblem.C:242
virtual bool vectorTagExists(const TagID tag_id) const
Check to see if a particular Tag exists.
Definition: SubProblem.h:201
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

◆ verboseMultiApps()

bool FEProblemBase::verboseMultiApps ( ) const
inlineinherited

Whether or not to use verbose printing for MultiApps.

Definition at line 2250 of file FEProblemBase.h.

Referenced by MultiApp::backup(), MultiApp::createApp(), MultiApp::restore(), FullSolveMultiApp::showStatusMessage(), and TransientMultiApp::solveStep().

2250 { return _verbose_multiapps; }
bool _verbose_multiapps
Whether or not to be verbose with multiapps.

◆ verifyVectorTags()

bool SubProblem::verifyVectorTags ( ) const
protectedinherited

Verify the integrity of _vector_tags and _typed_vector_tags.

Definition at line 242 of file SubProblem.C.

Referenced by SubProblem::addVectorTag(), SubProblem::getVectorTag(), SubProblem::getVectorTagID(), SubProblem::getVectorTags(), SubProblem::numVectorTags(), SubProblem::vectorTagExists(), SubProblem::vectorTagName(), and SubProblem::vectorTagType().

243 {
244  for (TagID tag_id = 0; tag_id < _vector_tags.size(); ++tag_id)
245  {
246  const auto & vector_tag = _vector_tags[tag_id];
247 
248  if (vector_tag._id != tag_id)
249  mooseError("Vector tag ", vector_tag._id, " id mismatch in _vector_tags");
250  if (vector_tag._type == Moose::VECTOR_TAG_ANY)
251  mooseError("Vector tag '", vector_tag._name, "' has type VECTOR_TAG_ANY");
252 
253  const auto search = _vector_tags_name_map.find(vector_tag._name);
254  if (search == _vector_tags_name_map.end())
255  mooseError("Vector tag ", vector_tag._id, " is not in _vector_tags_name_map");
256  else if (search->second != tag_id)
257  mooseError("Vector tag ", vector_tag._id, " has incorrect id in _vector_tags_name_map");
258 
259  unsigned int found_in_type = 0;
260  for (TagTypeID tag_type_id = 0; tag_type_id < _typed_vector_tags[vector_tag._type].size();
261  ++tag_type_id)
262  {
263  const auto & vector_tag_type = _typed_vector_tags[vector_tag._type][tag_type_id];
264  if (vector_tag_type == vector_tag)
265  {
266  ++found_in_type;
267  if (vector_tag_type._type_id != tag_type_id)
268  mooseError("Type ID for Vector tag ", tag_id, " is incorrect");
269  }
270  }
271 
272  if (found_in_type == 0)
273  mooseError("Vector tag ", tag_id, " not found in _typed_vector_tags");
274  if (found_in_type > 1)
275  mooseError("Vector tag ", tag_id, " found multiple times in _typed_vector_tags");
276  }
277 
278  unsigned int num_typed_vector_tags = 0;
279  for (const auto & typed_vector_tags : _typed_vector_tags)
280  num_typed_vector_tags += typed_vector_tags.size();
281  if (num_typed_vector_tags != _vector_tags.size())
282  mooseError("Size mismatch between _vector_tags and _typed_vector_tags");
283  if (_vector_tags_name_map.size() != _vector_tags.size())
284  mooseError("Size mismatch between _vector_tags and _vector_tags_name_map");
285 
286  return true;
287 }
unsigned int TagTypeID
Definition: MooseTypes.h:239
unsigned int TagID
Definition: MooseTypes.h:238
std::vector< VectorTag > _vector_tags
The declared vector tags.
Definition: SubProblem.h:1185
std::map< TagName, TagID > _vector_tags_name_map
Map of vector tag TagName to TagID.
Definition: SubProblem.h:1195
std::vector< std::vector< VectorTag > > _typed_vector_tags
The vector tags associated with each VectorTagType This is kept separate from _vector_tags for quick ...
Definition: SubProblem.h:1192
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type and optionally a file path to the top-level block p...
Definition: MooseBase.h:271

Member Data Documentation

◆ _action_factory

ActionFactory& ParallelParamObject::_action_factory
protectedinherited

◆ _active_elemental_moose_variables

std::vector<std::set<MooseVariableFieldBase *> > SubProblem::_active_elemental_moose_variables
protectedinherited

This is the set of MooseVariableFieldBase that will actually get reinited by a call to reinit(elem)

Definition at line 1090 of file SubProblem.h.

Referenced by SubProblem::clearActiveElementalMooseVariables(), SubProblem::getActiveElementalMooseVariables(), SubProblem::setActiveElementalMooseVariables(), and SubProblem::SubProblem().

◆ _active_fe_var_coupleable_matrix_tags

std::vector<std::set<TagID> > SubProblem::_active_fe_var_coupleable_matrix_tags
protectedinherited

◆ _active_fe_var_coupleable_vector_tags

std::vector<std::set<TagID> > SubProblem::_active_fe_var_coupleable_vector_tags
protectedinherited

◆ _active_sc_var_coupleable_matrix_tags

std::vector<std::set<TagID> > SubProblem::_active_sc_var_coupleable_matrix_tags
protectedinherited

◆ _active_sc_var_coupleable_vector_tags

std::vector<std::set<TagID> > SubProblem::_active_sc_var_coupleable_vector_tags
protectedinherited

◆ _ad_grad_zero

std::vector<MooseArray<ADRealVectorValue> > FEProblemBase::_ad_grad_zero
inherited

◆ _ad_second_zero

std::vector<MooseArray<ADRealTensorValue> > FEProblemBase::_ad_second_zero
inherited

◆ _ad_zero

std::vector<MooseArray<ADReal> > FEProblemBase::_ad_zero
inherited

◆ _adaptivity

Adaptivity FEProblemBase::_adaptivity
protectedinherited

◆ _all_materials

MaterialWarehouse FEProblemBase::_all_materials
protectedinherited

◆ _app

MooseApp& MooseBase::_app
protectedinherited

The MOOSE application this is associated with.

Definition at line 375 of file MooseBase.h.

◆ _assembly

std::vector<std::vector<std::unique_ptr<Assembly> > > FEProblemBase::_assembly
protectedinherited

The Assembly objects.

The first index corresponds to the thread ID and the second index corresponds to the nonlinear system number

Definition at line 3155 of file FEProblemBase.h.

Referenced by FEProblemBase::addCachedResidualDirectly(), FEProblemBase::addJacobian(), FEProblemBase::addJacobianBlockTags(), FEProblemBase::addJacobianLowerD(), FEProblemBase::addJacobianNeighbor(), FEProblemBase::addJacobianNeighborLowerD(), FEProblemBase::addJacobianOffDiagScalar(), FEProblemBase::addJacobianScalar(), FEProblemBase::addResidual(), FEProblemBase::addResidualLower(), FEProblemBase::addResidualNeighbor(), FEProblemBase::addResidualScalar(), FEProblemBase::assembly(), FEProblemBase::bumpAllQRuleOrder(), FEProblemBase::bumpVolumeQRuleOrder(), FEProblemBase::couplingEntries(), FEProblemBase::createQRules(), FEProblemBase::init(), FEProblemBase::initElementStatefulProps(), FEProblemBase::initialSetup(), FEProblemBase::initXFEM(), FEProblemBase::meshChanged(), FEProblemBase::newAssemblyArray(), FEProblemBase::nonlocalCouplingEntries(), FEProblemBase::prepareAssembly(), FEProblemBase::prepareAssemblyNeighbor(), FEProblemBase::prepareFaceShapes(), FEProblemBase::prepareNeighborShapes(), FEProblemBase::prepareShapes(), FEProblemBase::reinitDirac(), FEProblemBase::reinitElemNeighborAndLowerD(), FEProblemBase::reinitElemPhys(), FEProblemBase::reinitMaterials(), FEProblemBase::reinitMaterialsBoundary(), FEProblemBase::reinitMaterialsFace(), FEProblemBase::reinitMaterialsFaceOnBoundary(), FEProblemBase::reinitMaterialsInterface(), FEProblemBase::reinitMaterialsNeighbor(), FEProblemBase::reinitNeighbor(), FEProblemBase::reinitNode(), FEProblemBase::reinitNodeFace(), FEProblemBase::reinitOffDiagScalars(), FEProblemBase::reinitScalars(), FEProblemBase::setCurrentSubdomainID(), FEProblemBase::setResidual(), FEProblemBase::setResidualNeighbor(), FEProblemBase::swapBackMaterials(), FEProblemBase::swapBackMaterialsFace(), and FEProblemBase::swapBackMaterialsNeighbor().

◆ _aux

std::shared_ptr<AuxiliarySystem> FEProblemBase::_aux
protectedinherited

The auxiliary system.

Definition at line 3138 of file FEProblemBase.h.

Referenced by FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxKernel(), FEProblemBase::addAuxScalarKernel(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), FEProblemBase::addIndicator(), FEProblemBase::addMarker(), FEProblemBase::addMultiApp(), FEProblemBase::addObjectParamsHelper(), FEProblemBase::addTimeIntegrator(), FEProblemBase::addTransfer(), FEProblemBase::advanceState(), FEProblemBase::checkExceptionAndStopSolve(), FEProblemBase::computeBounds(), FEProblemBase::computeIndicators(), FEProblemBase::computeJacobianTags(), FEProblemBase::computeLinearSystemTags(), FEProblemBase::computeMarkers(), FEProblemBase::computePostCheck(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), FEProblemBase::computeSystems(), FEProblemBase::computeUserObjectsInternal(), FEProblemBase::copySolutionsBackwards(), FEProblemBase::createQRules(), FEProblemBase::createTagMatrices(), FEProblemBase::createTagSolutions(), FEProblemBase::customSetup(), FEProblemBase::determineSolverSystem(), DumpObjectsProblem::DumpObjectsProblem(), FEProblemBase::duplicateVariableCheck(), EigenProblem::EigenProblem(), FEProblemBase::execute(), ExternalProblem::ExternalProblem(), FEProblem::FEProblem(), FEProblemBase::getActualFieldVariable(), FEProblemBase::getArrayVariable(), FEProblemBase::getAuxiliarySystem(), FEProblemBase::getScalarVariable(), FEProblemBase::getStandardVariable(), FEProblemBase::getSystem(), FEProblemBase::getSystemBase(), FEProblemBase::getVariable(), FEProblemBase::getVariableNames(), FEProblemBase::getVectorVariable(), FEProblemBase::hasScalarVariable(), FEProblemBase::hasSolutionState(), FEProblemBase::hasVariable(), FEProblemBase::init(), FEProblemBase::initialSetup(), FEProblemBase::meshChanged(), FEProblemBase::needBoundaryMaterialOnSide(), FEProblemBase::needSolutionState(), FEProblemBase::outputStep(), FEProblemBase::prepareFace(), FEProblemBase::projectInitialConditionOnCustomRange(), FEProblemBase::projectSolution(), FEProblemBase::reinitDirac(), FEProblemBase::reinitElem(), FEProblemBase::reinitElemPhys(), FEProblemBase::reinitNeighbor(), FEProblemBase::reinitNode(), FEProblemBase::reinitNodeFace(), FEProblemBase::reinitNodes(), FEProblemBase::reinitNodesNeighbor(), FEProblemBase::reinitScalars(), FEProblemBase::restoreOldSolutions(), FEProblemBase::restoreSolutions(), FEProblemBase::saveOldSolutions(), FEProblemBase::setAuxKernelParamsAndLog(), FEProblemBase::skipNextForwardSolutionCopyToOld(), FEProblemBase::systemBaseAuxiliary(), FEProblemBase::systemNumForVariable(), FEProblemBase::timestepSetup(), FEProblemBase::updateActiveObjects(), and FEProblemBase::updateMeshXFEM().

◆ _aux_evaluable_local_elem_range

std::unique_ptr<libMesh::ConstElemRange> FEProblemBase::_aux_evaluable_local_elem_range
protectedinherited

Definition at line 3450 of file FEProblemBase.h.

◆ _between_multi_app_transfers

ExecuteMooseObjectWarehouse<Transfer> FEProblemBase::_between_multi_app_transfers
protectedinherited

◆ _block_mat_side_cache

std::vector<std::unordered_map<SubdomainID, bool> > FEProblemBase::_block_mat_side_cache
protectedinherited

Cache for calculating materials on side.

Definition at line 3246 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase(), and FEProblemBase::needInternalNeighborSideMaterial().

◆ _bnd_mat_side_cache

std::vector<std::unordered_map<BoundaryID, bool> > FEProblemBase::_bnd_mat_side_cache
protectedinherited

Cache for calculating materials on side.

Definition at line 3249 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase(), and FEProblemBase::needBoundaryMaterialOnSide().

◆ _bnd_material_props

MaterialPropertyStorage& FEProblemBase::_bnd_material_props
protectedinherited

◆ _boundary_restricted_elem_integrity_check

const bool FEProblemBase::_boundary_restricted_elem_integrity_check
protectedinherited

whether to perform checking of boundary restricted elemental object variable dependencies, e.g.

whether the variable dependencies are defined on the selected boundaries

Definition at line 3384 of file FEProblemBase.h.

Referenced by FEProblemBase::initialSetup().

◆ _boundary_restricted_node_integrity_check

const bool FEProblemBase::_boundary_restricted_node_integrity_check
protectedinherited

whether to perform checking of boundary restricted nodal object variable dependencies, e.g.

whether the variable dependencies are defined on the selected boundaries

Definition at line 3380 of file FEProblemBase.h.

Referenced by FEProblemBase::initialSetup().

◆ _calculate_jacobian_in_uo

bool FEProblemBase::_calculate_jacobian_in_uo
protectedinherited

◆ _check_residual_for_nans

bool FEProblemBase::_check_residual_for_nans
protectedinherited

Whether to check the residual for NaN or Inf values.

Definition at line 3401 of file FEProblemBase.h.

Referenced by FEProblemBase::checkResidualForNans(), and FEProblemBase::setCheckResidualForNans().

◆ _cli_option_found

bool Problem::_cli_option_found
protectedinherited

True if the CLI option is found.

Definition at line 52 of file Problem.h.

Referenced by Problem::_setCLIOption().

◆ _cm

std::vector<std::unique_ptr<libMesh::CouplingMatrix> > FEProblemBase::_cm
protectedinherited

◆ _color_output

bool Problem::_color_output
protectedinherited

True if we're going to attempt to write color output.

Definition at line 55 of file Problem.h.

◆ _computing_nonlinear_residual

bool SubProblem::_computing_nonlinear_residual
protectedinherited

Whether the non-linear residual is being evaluated.

Definition at line 1117 of file SubProblem.h.

Referenced by SubProblem::computingNonlinearResid(), and FEProblemBase::computingNonlinearResid().

◆ _console

const ConsoleStream ConsoleStreamInterface::_console
inherited

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

Definition at line 31 of file ConsoleStreamInterface.h.

Referenced by IterationAdaptiveDT::acceptStep(), MeshOnlyAction::act(), SetupDebugAction::act(), MaterialOutputAction::act(), Adaptivity::adaptMesh(), FEProblemBase::adaptMesh(), PerfGraph::addToExecutionList(), SimplePredictor::apply(), SystemBase::applyScalingFactors(), MultiApp::backup(), FEProblemBase::backupMultiApps(), CoarsenedPiecewiseLinear::buildCoarsenedGrid(), DefaultSteadyStateConvergence::checkConvergence(), MeshDiagnosticsGenerator::checkElementOverlap(), MeshDiagnosticsGenerator::checkElementTypes(), MeshDiagnosticsGenerator::checkElementVolumes(), FEProblemBase::checkExceptionAndStopSolve(), SolverSystem::checkInvalidSolution(), MeshDiagnosticsGenerator::checkLocalJacobians(), MeshDiagnosticsGenerator::checkNonConformalMesh(), MeshDiagnosticsGenerator::checkNonConformalMeshFromAdaptivity(), MeshDiagnosticsGenerator::checkNonMatchingEdges(), MeshDiagnosticsGenerator::checkNonPlanarSides(), MeshDiagnosticsGenerator::checkPolygons(), FEProblemBase::checkProblemIntegrity(), ReferenceResidualConvergence::checkResidualConvergence(), MeshDiagnosticsGenerator::checkSidesetsOrientation(), MeshDiagnosticsGenerator::checkWatertightNodesets(), MeshDiagnosticsGenerator::checkWatertightSidesets(), IterationAdaptiveDT::computeAdaptiveDT(), TransientBase::computeConstrainedDT(), DefaultMultiAppFixedPointConvergence::computeCustomConvergencePostprocessor(), NonlinearSystemBase::computeDamping(), FixedPointIterationAdaptiveDT::computeDT(), IterationAdaptiveDT::computeDT(), IterationAdaptiveDT::computeFailedDT(), IterationAdaptiveDT::computeInitialDT(), IterationAdaptiveDT::computeInterpolationDT(), LinearSystem::computeLinearSystemTags(), FEProblemBase::computeLinearSystemTags(), NonlinearSystemBase::computeScaling(), Problem::console(), IterationAdaptiveDT::constrainStep(), TimeStepper::constrainStep(), MultiApp::createApp(), FEProblemBase::execMultiApps(), FEProblemBase::execMultiAppTransfers(), MFEMSteady::execute(), MessageFromInput::execute(), SteadyBase::execute(), Eigenvalue::execute(), ActionWarehouse::executeActionsWithAction(), ActionWarehouse::executeAllActions(), MeshGeneratorSystem::executeMeshGenerators(), ElementQualityChecker::finalize(), SidesetAroundSubdomainUpdater::finalize(), FEProblemBase::finishMultiAppStep(), MeshRepairGenerator::fixOverlappingNodes(), SurfaceSubdomainsDelaunayRemesher::General2DDelaunay(), OrientSurfaceMeshGenerator::generate(), CoarsenBlockGenerator::generate(), PolyLineMeshFollowingNodeSetGenerator::generate(), MeshGenerator::generateInternal(), VariableCondensationPreconditioner::getDofToCondense(), NonlinearEigen::init(), InversePowerMethod::init(), FEProblemBase::initialAdaptMesh(), DefaultMultiAppFixedPointConvergence::initialize(), SubProblem::initialSetup(), EigenExecutionerBase::inversePowerIteration(), FEProblemBase::joinAndFinalize(), TransientBase::keepGoing(), IterationAdaptiveDT::limitDTByFunction(), IterationAdaptiveDT::limitDTToPostprocessorValue(), FEProblemBase::logAdd(), EigenExecutionerBase::makeBXConsistent(), Console::meshChanged(), SurfaceDelaunayGeneratorBase::meshNormalDeviation2D(), MooseBase::mooseDeprecated(), MooseBase::mooseDeprecatedNoTrace(), MooseBase::mooseInfo(), MooseBase::mooseWarning(), MooseBase::mooseWarningNonPrefixed(), ReferenceResidualConvergence::nonlinearConvergenceSetup(), ReporterDebugOutput::output(), PerfGraphOutput::output(), SolutionInvalidityOutput::output(), MaterialPropertyDebugOutput::output(), DOFMapOutput::output(), VariableResidualNormsDebugOutput::output(), Console::output(), ControlOutput::outputActiveObjects(), ControlOutput::outputChangedControls(), ControlOutput::outputControls(), Console::outputInput(), WebServerControl::outputMessage(), Console::outputPostprocessors(), PseudoTimestep::outputPseudoTimestep(), Console::outputReporters(), DefaultMultiAppFixedPointConvergence::outputResidualNorm(), Console::outputScalarVariables(), Console::outputSystemInformation(), FEProblemBase::possiblyRebuildGeomSearchPatches(), EigenExecutionerBase::postExecute(), AB2PredictorCorrector::postSolve(), ActionWarehouse::printActionDependencySets(), BlockRestrictionDebugOutput::printBlockRestrictionGroups(), BlockRestrictionDebugOutput::printBlockRestrictionMap(), BlockRestrictionDebugOutput::printBoundaryRestrictionGroups(), SolutionInvalidity::printDebug(), EigenExecutionerBase::printEigenvalue(), SecantSolve::printFixedPointConvergenceHistory(), SteffensenSolve::printFixedPointConvergenceHistory(), PicardSolve::printFixedPointConvergenceHistory(), FixedPointSolve::printFixedPointConvergenceReason(), PerfGraphLivePrint::printLiveMessage(), MaterialPropertyDebugOutput::printMaterialMap(), PerfGraphLivePrint::printStats(), NEML2Action::printSummary(), AutomaticMortarGeneration::projectPrimaryNodesSinglePair(), AutomaticMortarGeneration::projectSecondaryNodesSinglePair(), CoarsenBlockGenerator::recursiveCoarsen(), SolutionTimeAdaptiveDT::rejectStep(), MultiApp::restore(), FEProblemBase::restoreMultiApps(), FEProblemBase::restoreSolutions(), NonlinearSystemBase::setInitialSolution(), MooseApp::setupOptions(), Checkpoint::shouldOutput(), SubProblem::showFunctorRequestors(), SubProblem::showFunctors(), FullSolveMultiApp::showStatusMessage(), EigenProblem::solve(), FEProblemSolve::solve(), FixedPointSolve::solve(), NonlinearSystem::solve(), LStableDirk2::solve(), LStableDirk3::solve(), ImplicitMidpoint::solve(), LinearSystem::solve(), ExplicitTVDRK2::solve(), AStableDirk4::solve(), LStableDirk4::solve(), ExplicitRK2::solve(), TransientMultiApp::solveStep(), FixedPointSolve::solveStep(), MeshRepairGenerator::splitNonConvexPolygons(), PerfGraphLivePrint::start(), WebServerControl::startServer(), AB2PredictorCorrector::step(), NonlinearEigen::takeStep(), MFEMTransient::takeStep(), TransientBase::takeStep(), TerminateChainControl::terminate(), SubProblem::timestepSetup(), FEProblemBase::updateMeshXFEM(), Convergence::verboseOutput(), Console::writeTimestepInformation(), Console::writeVariableNorms(), and FEProblemBase::~FEProblemBase().

◆ _const_jacobian

bool FEProblemBase::_const_jacobian
protectedinherited

true if the Jacobian is constant

Definition at line 3348 of file FEProblemBase.h.

Referenced by FEProblemBase::computeJacobianTags(), FEProblemBase::constJacobian(), and FEProblemBase::setConstJacobian().

◆ _control_warehouse

ExecuteMooseObjectWarehouse<Control> FEProblemBase::_control_warehouse
protectedinherited

◆ _convergences

MooseObjectWarehouse<Convergence> FEProblemBase::_convergences
protectedinherited

◆ _coupling

Moose::CouplingType FEProblemBase::_coupling
protectedinherited

◆ _current_algebraic_bnd_node_range

std::unique_ptr<ConstBndNodeRange> FEProblemBase::_current_algebraic_bnd_node_range
protectedinherited

◆ _current_algebraic_elem_range

std::unique_ptr<libMesh::ConstElemRange> FEProblemBase::_current_algebraic_elem_range
protectedinherited

◆ _current_algebraic_node_range

std::unique_ptr<libMesh::ConstNodeRange> FEProblemBase::_current_algebraic_node_range
protectedinherited

◆ _current_execute_on_flag

ExecFlagType FEProblemBase::_current_execute_on_flag
protectedinherited

◆ _current_ic_state

unsigned short FEProblemBase::_current_ic_state
protectedinherited

◆ _current_linear_sys

LinearSystem* FEProblemBase::_current_linear_sys
protectedinherited

◆ _current_nl_sys

NonlinearSystemBase* FEProblemBase::_current_nl_sys
protectedinherited

The current nonlinear system that we are solving.

Definition at line 3120 of file FEProblemBase.h.

Referenced by FEProblemBase::addCachedResidualDirectly(), FEProblemBase::addJacobian(), FEProblemBase::addJacobianBlockTags(), FEProblemBase::addJacobianLowerD(), FEProblemBase::addJacobianNeighbor(), FEProblemBase::addJacobianNeighborLowerD(), FEProblemBase::addJacobianOffDiagScalar(), FEProblemBase::addJacobianScalar(), FEProblemBase::addResidual(), FEProblemBase::addResidualLower(), FEProblemBase::addResidualNeighbor(), FEProblemBase::addResidualScalar(), FEProblemBase::checkExceptionAndStopSolve(), FEProblemBase::computeBounds(), FEProblemBase::computeDamping(), FEProblemBase::computeJacobianBlock(), EigenProblem::computeJacobianBlocks(), FEProblemBase::computeJacobianBlocks(), FEProblemBase::computeJacobianInternal(), FEProblemBase::computeJacobianTag(), FEProblemBase::computeJacobianTags(), FEProblemBase::computeNearNullSpace(), FEProblemBase::computeNullSpace(), FEProblemBase::computePostCheck(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualInternal(), FEProblemBase::computeResidualL2Norm(), FEProblemBase::computeResidualTag(), FEProblemBase::computeResidualTags(), FEProblemBase::computeResidualType(), FEProblemBase::computeTransposeNullSpace(), FEProblemBase::currentNonlinearSystem(), EigenProblem::doFreeNonlinearPowerIterations(), EigenProblem::EigenProblem(), FEProblemBase::prepareAssembly(), FEProblemBase::prepareAssemblyNeighbor(), FEProblemBase::prepareFaceShapes(), FEProblemBase::prepareNeighborShapes(), FEProblemBase::prepareShapes(), FEProblemBase::reinitDirac(), FEProblemBase::reinitOffDiagScalars(), FEProblemBase::setCurrentNonlinearSystem(), FEProblemBase::setResidual(), FEProblemBase::setResidualNeighbor(), EigenProblem::solve(), and FEProblemBase::solve().

◆ _current_solver_sys

SolverSystem* FEProblemBase::_current_solver_sys
protectedinherited

The current solver system.

Definition at line 3123 of file FEProblemBase.h.

Referenced by FEProblemBase::setCurrentLinearSystem(), and FEProblemBase::setCurrentNonlinearSystem().

◆ _currently_computing_jacobian

bool SubProblem::_currently_computing_jacobian
protectedinherited

◆ _currently_computing_residual

bool SubProblem::_currently_computing_residual
protectedinherited

◆ _currently_computing_residual_and_jacobian

bool SubProblem::_currently_computing_residual_and_jacobian
protectedinherited

Flag to determine whether the problem is currently computing the residual and Jacobian.

Definition at line 1114 of file SubProblem.h.

Referenced by SubProblem::currentlyComputingResidualAndJacobian(), and SubProblem::setCurrentlyComputingResidualAndJacobian().

◆ _cycles_completed

unsigned int FEProblemBase::_cycles_completed
protectedinherited

◆ _default_ghosting

bool SubProblem::_default_ghosting
protectedinherited

Whether or not to use default libMesh coupling.

Definition at line 1105 of file SubProblem.h.

Referenced by SubProblem::defaultGhosting().

◆ _dirac_kernel_info

DiracKernelInfo SubProblem::_dirac_kernel_info
protectedinherited

◆ _discrete_materials

MaterialWarehouse FEProblemBase::_discrete_materials
protectedinherited

◆ _displaced_mesh

MooseMesh* FEProblemBase::_displaced_mesh
protectedinherited

◆ _displaced_problem

std::shared_ptr<DisplacedProblem> FEProblemBase::_displaced_problem
protectedinherited

Definition at line 3315 of file FEProblemBase.h.

Referenced by FEProblemBase::adaptMesh(), FEProblemBase::addAnyRedistributers(), FEProblemBase::addAuxArrayVariable(), FEProblemBase::addAuxScalarKernel(), FEProblemBase::addAuxScalarVariable(), FEProblemBase::addAuxVariable(), FEProblemBase::addCachedJacobian(), FEProblemBase::addCachedResidual(), FEProblemBase::addCachedResidualDirectly(), FEProblemBase::addConstraint(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addDisplacedProblem(), FEProblemBase::addFunction(), FEProblemBase::addFunctorMaterial(), FEProblemBase::addFVKernel(), FEProblemBase::addGhostedBoundary(), FEProblemBase::addIndicator(), FEProblemBase::addInterfaceKernel(), FEProblemBase::addJacobian(), FEProblemBase::addJacobianBlockTags(), FEProblemBase::addJacobianLowerD(), FEProblemBase::addJacobianNeighbor(), FEProblemBase::addJacobianNeighborLowerD(), FEProblemBase::addMarker(), FEProblemBase::addMaterialHelper(), FEProblemBase::addMultiApp(), FEProblemBase::addNodalKernel(), FEProblemBase::addObjectParamsHelper(), FEProblemBase::addResidual(), FEProblemBase::addResidualLower(), FEProblemBase::addResidualNeighbor(), FEProblemBase::addScalarKernel(), FEProblemBase::addTimeIntegrator(), FEProblemBase::addTransfer(), FEProblemBase::addUserObject(), FEProblemBase::addVariable(), FEProblemBase::advanceState(), FEProblemBase::automaticScaling(), FEProblemBase::bumpAllQRuleOrder(), FEProblemBase::bumpVolumeQRuleOrder(), FEProblemBase::cacheJacobian(), FEProblemBase::cacheJacobianNeighbor(), FEProblemBase::cacheResidual(), FEProblemBase::cacheResidualNeighbor(), FEProblemBase::checkDisplacementOrders(), FEProblemBase::clearActiveElementalMooseVariables(), FEProblemBase::clearActiveFEVariableCoupleableMatrixTags(), FEProblemBase::clearActiveFEVariableCoupleableVectorTags(), FEProblemBase::clearActiveScalarVariableCoupleableMatrixTags(), FEProblemBase::clearActiveScalarVariableCoupleableVectorTags(), FEProblemBase::clearDiracInfo(), EigenProblem::computeJacobianBlocks(), FEProblemBase::computeJacobianBlocks(), FEProblemBase::computeJacobianTags(), FEProblemBase::computeResidualAndJacobian(), FEProblemBase::computeResidualTags(), FEProblemBase::computeUserObjectsInternal(), FEProblemBase::computingNonlinearResid(), FEProblemBase::createMortarInterface(), FEProblemBase::createQRules(), FEProblemBase::customSetup(), FEProblemBase::execute(), FEProblemBase::getDiracElements(), FEProblemBase::getDisplacedProblem(), FEProblemBase::getMortarUserObjects(), FEProblemBase::ghostGhostedBoundaries(), FEProblemBase::haveADObjects(), FEProblemBase::haveDisplaced(), FEProblemBase::init(), FEProblemBase::initialSetup(), FEProblemBase::initXFEM(), FEProblemBase::jacobianSetup(), FEProblemBase::mesh(), FEProblemBase::meshChanged(), FEProblemBase::outputStep(), FEProblemBase::possiblyRebuildGeomSearchPatches(), FEProblemBase::prepareAssembly(), FEProblemBase::prepareAssemblyNeighbor(), FEProblemBase::prepareFace(), FEProblemBase::reinitBecauseOfGhostingOrNewGeomObjects(), FEProblemBase::reinitDirac(), FEProblemBase::reinitElem(), FEProblemBase::reinitElemFaceRef(), FEProblemBase::reinitElemNeighborAndLowerD(), FEProblemBase::reinitLowerDElem(), FEProblemBase::reinitNeighbor(), FEProblemBase::reinitNeighborFaceRef(), FEProblemBase::reinitNode(), FEProblemBase::reinitNodeFace(), FEProblemBase::reinitNodes(), FEProblemBase::reinitNodesNeighbor(), FEProblemBase::reinitOffDiagScalars(), FEProblemBase::reinitScalars(), FEProblemBase::resetState(), FEProblemBase::residualSetup(), FEProblemBase::restoreSolutions(), FEProblemBase::setActiveElementalMooseVariables(), FEProblemBase::setActiveFEVariableCoupleableMatrixTags(), FEProblemBase::setActiveFEVariableCoupleableVectorTags(), FEProblemBase::setActiveScalarVariableCoupleableMatrixTags(), FEProblemBase::setActiveScalarVariableCoupleableVectorTags(), FEProblemBase::setAuxKernelParamsAndLog(), FEProblemBase::setCurrentBoundaryID(), FEProblemBase::setCurrentLowerDElem(), FEProblemBase::setCurrentlyComputingResidual(), FEProblemBase::setCurrentSubdomainID(), FEProblemBase::setResidual(), FEProblemBase::setResidualNeighbor(), FEProblemBase::setResidualObjectParamsAndLog(), EigenProblem::solve(), FEProblemBase::solve(), FEProblemBase::timestepSetup(), FEProblemBase::uniformRefine(), and FEProblemBase::updateGeomSearch().

◆ _dt

Real& FEProblemBase::_dt
protectedinherited

◆ _dt_old

Real& FEProblemBase::_dt_old
protectedinherited

Definition at line 3080 of file FEProblemBase.h.

Referenced by FEProblemBase::dtOld(), and FEProblemBase::FEProblemBase().

◆ _enabled

const bool& MooseObject::_enabled
protectedinherited

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

Definition at line 71 of file MooseObject.h.

Referenced by MooseObject::enabled().

◆ _evaluable_local_elem_range

std::unique_ptr<libMesh::ConstElemRange> FEProblemBase::_evaluable_local_elem_range
protectedinherited

◆ _exception_message

std::string FEProblemBase::_exception_message
protectedinherited

The error message to go with an exception.

Definition at line 3429 of file FEProblemBase.h.

Referenced by FEProblemBase::checkExceptionAndStopSolve(), and FEProblemBase::setException().

◆ _factory

Factory& SubProblem::_factory
protectedinherited

◆ _fe_matrix_tags

std::set<TagID> FEProblemBase::_fe_matrix_tags
protectedinherited

◆ _fe_vector_tags

std::set<TagID> FEProblemBase::_fe_vector_tags
protectedinherited

◆ _from_multi_app_transfers

ExecuteMooseObjectWarehouse<Transfer> FEProblemBase::_from_multi_app_transfers
protectedinherited

◆ _functions

MooseObjectWarehouse<Function> FEProblemBase::_functions
protectedinherited

◆ _fv_bcs_integrity_check

bool FEProblemBase::_fv_bcs_integrity_check
protectedinherited

Whether to check overlapping Dirichlet and Flux BCs and/or multiple DirichletBCs per sideset.

Definition at line 3391 of file FEProblemBase.h.

Referenced by FEProblemBase::fvBCsIntegrityCheck().

◆ _fv_ics

FVInitialConditionWarehouse FEProblemBase::_fv_ics
protectedinherited

◆ _geometric_search_data

GeometricSearchData FEProblemBase::_geometric_search_data
protectedinherited

◆ _ghosted_elems

std::set<dof_id_type> SubProblem::_ghosted_elems
protectedinherited

◆ _grad_phi_zero

std::vector<VariablePhiGradient> FEProblemBase::_grad_phi_zero
inherited

◆ _grad_zero

std::vector<VariableGradient> FEProblemBase::_grad_zero
inherited

◆ _has_active_elemental_moose_variables

std::vector<unsigned int> SubProblem::_has_active_elemental_moose_variables
protectedinherited

Whether or not there is currently a list of active elemental moose variables.

Definition at line 1094 of file SubProblem.h.

Referenced by SubProblem::clearActiveElementalMooseVariables(), SubProblem::hasActiveElementalMooseVariables(), SubProblem::setActiveElementalMooseVariables(), and SubProblem::SubProblem().

◆ _has_active_material_properties

std::vector<unsigned char> FEProblemBase::_has_active_material_properties
protectedinherited

◆ _has_constraints

bool FEProblemBase::_has_constraints
protectedinherited

Whether or not this system has any Constraints.

Definition at line 3333 of file FEProblemBase.h.

Referenced by FEProblemBase::addConstraint(), NonlinearSystemBase::computeJacobianInternal(), and NonlinearSystemBase::computeResidualInternal().

◆ _has_dampers

bool FEProblemBase::_has_dampers
protectedinherited

Whether or not this system has any Dampers associated with it.

Definition at line 3330 of file FEProblemBase.h.

Referenced by FEProblemBase::addDamper(), FEProblemBase::computeDamping(), FEProblemBase::computePostCheck(), and FEProblemBase::hasDampers().

◆ _has_exception

bool FEProblemBase::_has_exception
protectedinherited

Whether or not an exception has occurred.

Definition at line 3414 of file FEProblemBase.h.

Referenced by FEProblemBase::checkExceptionAndStopSolve(), FEProblemBase::hasException(), and FEProblemBase::setException().

◆ _has_initialized_stateful

bool FEProblemBase::_has_initialized_stateful
protectedinherited

Whether nor not stateful materials have been initialized.

Definition at line 3345 of file FEProblemBase.h.

Referenced by FEProblemBase::initialSetup(), and FEProblemBase::meshChanged().

◆ _has_jacobian

bool FEProblemBase::_has_jacobian
protectedinherited

Indicates if the Jacobian was computed.

Definition at line 3351 of file FEProblemBase.h.

Referenced by FEProblemBase::computeJacobianTags(), FEProblemBase::hasJacobian(), and FEProblemBase::meshChanged().

◆ _has_nonlocal_coupling

bool FEProblemBase::_has_nonlocal_coupling
protectedinherited

◆ _has_time_integrator

bool FEProblemBase::_has_time_integrator
protectedinherited

Indicates whether or not this executioner has a time integrator (during setup)

Definition at line 3411 of file FEProblemBase.h.

Referenced by FEProblemBase::addTimeIntegrator(), and FEProblemBase::hasTimeIntegrator().

◆ _have_ad_objects

bool SubProblem::_have_ad_objects
protectedinherited

AD flag indicating whether any AD objects have been added.

Definition at line 1129 of file SubProblem.h.

Referenced by DisplacedProblem::haveADObjects(), SubProblem::haveADObjects(), and FEProblemBase::haveADObjects().

◆ _ics

InitialConditionWarehouse FEProblemBase::_ics
protectedinherited

◆ _indicators

MooseObjectWarehouse<Indicator> FEProblemBase::_indicators
protectedinherited

◆ _initialized

bool FEProblemBase::_initialized
protectedinherited

Definition at line 3051 of file FEProblemBase.h.

Referenced by FEProblemBase::init(), and FEProblemBase::initialized().

◆ _input_file_saved

bool FEProblemBase::_input_file_saved
protectedinherited

whether input file has been written

Definition at line 3327 of file FEProblemBase.h.

◆ _interface_mat_side_cache

std::vector<std::unordered_map<BoundaryID, bool> > FEProblemBase::_interface_mat_side_cache
protectedinherited

Cache for calculating materials on interface.

Definition at line 3252 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase(), and FEProblemBase::needInterfaceMaterialOnSide().

◆ _interface_materials

MaterialWarehouse FEProblemBase::_interface_materials
protectedinherited

◆ _internal_side_indicators

MooseObjectWarehouse<InternalSideIndicatorBase> FEProblemBase::_internal_side_indicators
protectedinherited

◆ _is_petsc_options_inserted

bool FEProblemBase::_is_petsc_options_inserted
protectedinherited

If or not PETSc options have been added to database.

Definition at line 3444 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase(), FEProblemBase::petscOptionsInserted(), FEProblemBase::solve(), and FEProblemBase::solveLinearSystem().

◆ _kernel_coverage_blocks

std::vector<SubdomainName> FEProblemBase::_kernel_coverage_blocks
protectedinherited

◆ _kernel_coverage_check

CoverageCheckMode FEProblemBase::_kernel_coverage_check
protectedinherited

Determines whether and which subdomains are to be checked to ensure that they have an active kernel.

Definition at line 3375 of file FEProblemBase.h.

Referenced by FEProblemBase::checkProblemIntegrity(), FEProblemBase::FEProblemBase(), and FEProblemBase::setKernelCoverageCheck().

◆ _kokkos_assembly

Moose::Kokkos::Assembly FEProblemBase::_kokkos_assembly
protectedinherited

Definition at line 3158 of file FEProblemBase.h.

Referenced by FEProblemBase::kokkosAssembly().

◆ _kokkos_bnd_material_props

Moose::Kokkos::MaterialPropertyStorage& FEProblemBase::_kokkos_bnd_material_props
protectedinherited

◆ _kokkos_fe_systems

Moose::Kokkos::Array<Moose::Kokkos::FESystem> FEProblemBase::_kokkos_fe_systems
protectedinherited

FESystem array - sparsely populated (only slots for systems needing a Kokkos::FESystem)

Definition at line 3147 of file FEProblemBase.h.

Referenced by FEProblemBase::getKokkosFESystems().

◆ _kokkos_functions

MooseObjectWarehouse<Moose::FunctionBase> FEProblemBase::_kokkos_functions
protectedinherited

◆ _kokkos_material_props

Moose::Kokkos::MaterialPropertyStorage& FEProblemBase::_kokkos_material_props
protectedinherited

◆ _kokkos_materials

MaterialWarehouse FEProblemBase::_kokkos_materials
protectedinherited

◆ _kokkos_neighbor_material_props

Moose::Kokkos::MaterialPropertyStorage& FEProblemBase::_kokkos_neighbor_material_props
protectedinherited

◆ _kokkos_systems

Moose::Kokkos::Array<Moose::Kokkos::System> FEProblemBase::_kokkos_systems
protectedinherited

System array - sparsely populated (only slots for systems needing a Kokkos::System)

Definition at line 3145 of file FEProblemBase.h.

Referenced by FEProblemBase::getKokkosSystems().

◆ _line_search

std::shared_ptr<LineSearch> FEProblemBase::_line_search
protectedinherited

◆ _linear_convergence_names

std::optional<std::vector<ConvergenceName> > FEProblemBase::_linear_convergence_names
protectedinherited

Linear system(s) convergence name(s) (if any)

Definition at line 3056 of file FEProblemBase.h.

Referenced by FEProblemBase::getLinearConvergenceNames(), FEProblemBase::hasLinearConvergenceObjects(), and FEProblemBase::setLinearConvergenceNames().

◆ _linear_matrix_tags

std::set<TagID> FEProblemBase::_linear_matrix_tags
protectedinherited

Temporary storage for filtered matrix tags for linear systems.

Definition at line 3070 of file FEProblemBase.h.

Referenced by FEProblemBase::computeLinearSystemSys().

◆ _linear_sys_name_to_num

std::map<LinearSystemName, unsigned int> FEProblemBase::_linear_sys_name_to_num
protectedinherited

Map from linear system name to number.

Definition at line 3099 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase(), and FEProblemBase::linearSysNum().

◆ _linear_sys_names

const std::vector<LinearSystemName> FEProblemBase::_linear_sys_names
protectedinherited

◆ _linear_systems

std::vector<std::shared_ptr<LinearSystem> > FEProblemBase::_linear_systems
protectedinherited

◆ _linear_vector_tags

std::set<TagID> FEProblemBase::_linear_vector_tags
protectedinherited

Temporary storage for filtered vector tags for linear systems.

Definition at line 3067 of file FEProblemBase.h.

Referenced by FEProblemBase::computeLinearSystemSys().

◆ _map_block_material_props

std::map<SubdomainID, std::set<std::string> > SubProblem::_map_block_material_props
protectedinherited

Map of material properties (block_id -> list of properties)

Definition at line 1067 of file SubProblem.h.

Referenced by SubProblem::checkBlockMatProps(), SubProblem::getMaterialPropertyBlocks(), SubProblem::hasBlockMaterialProperty(), and SubProblem::storeSubdomainMatPropName().

◆ _map_block_material_props_check

std::map<SubdomainID, std::multimap<std::string, std::string> > SubProblem::_map_block_material_props_check
protectedinherited

Data structures of the requested material properties.

We store them in a map from boundary/block id to multimap. Each of the multimaps is a list of requestor object names to material property names.

Definition at line 1085 of file SubProblem.h.

Referenced by SubProblem::checkBlockMatProps(), and SubProblem::storeSubdomainDelayedCheckMatProp().

◆ _map_boundary_material_props

std::map<BoundaryID, std::set<std::string> > SubProblem::_map_boundary_material_props
protectedinherited

Map for boundary material properties (boundary_id -> list of properties)

Definition at line 1070 of file SubProblem.h.

Referenced by SubProblem::checkBoundaryMatProps(), SubProblem::getMaterialPropertyBoundaryIDs(), SubProblem::hasBoundaryMaterialProperty(), and SubProblem::storeBoundaryMatPropName().

◆ _map_boundary_material_props_check

std::map<BoundaryID, std::multimap<std::string, std::string> > SubProblem::_map_boundary_material_props_check
protectedinherited

◆ _markers

MooseObjectWarehouse<Marker> FEProblemBase::_markers
protectedinherited

◆ _material_coverage_blocks

std::vector<SubdomainName> FEProblemBase::_material_coverage_blocks
protectedinherited

◆ _material_coverage_check

CoverageCheckMode FEProblemBase::_material_coverage_check
protectedinherited

Determines whether and which subdomains are to be checked to ensure that they have an active material.

Definition at line 3387 of file FEProblemBase.h.

Referenced by FEProblemBase::checkProblemIntegrity(), FEProblemBase::FEProblemBase(), and FEProblemBase::setMaterialCoverageCheck().

◆ _material_dependency_check

const bool FEProblemBase::_material_dependency_check
protectedinherited

Determines whether a check to verify material dependencies on every subdomain.

Definition at line 3394 of file FEProblemBase.h.

Referenced by FEProblemBase::checkProblemIntegrity().

◆ _material_prop_registry

MaterialPropertyRegistry FEProblemBase::_material_prop_registry
protectedinherited

◆ _material_property_requested

std::set<std::string> SubProblem::_material_property_requested
protectedinherited

set containing all material property names that have been requested by getMaterialProperty*

Definition at line 1077 of file SubProblem.h.

Referenced by SubProblem::isMatPropRequested(), and SubProblem::markMatPropRequested().

◆ _material_props

MaterialPropertyStorage& FEProblemBase::_material_props
protectedinherited

◆ _materials

MaterialWarehouse FEProblemBase::_materials
protectedinherited

◆ _matrix_tag_id_to_tag_name

std::map<TagID, TagName> SubProblem::_matrix_tag_id_to_tag_name
protectedinherited

Reverse map.

Definition at line 1059 of file SubProblem.h.

Referenced by SubProblem::addMatrixTag(), SubProblem::matrixTagExists(), and SubProblem::matrixTagName().

◆ _matrix_tag_name_to_tag_id

std::map<TagName, TagID> SubProblem::_matrix_tag_name_to_tag_id
protectedinherited

◆ _max_qps

unsigned int FEProblemBase::_max_qps
protectedinherited

Maximum number of quadrature points used in the problem.

Definition at line 3405 of file FEProblemBase.h.

Referenced by FEProblemBase::getMaxQps(), FEProblemBase::reinitDirac(), and FEProblemBase::updateMaxQps().

◆ _max_scalar_order

libMesh::Order FEProblemBase::_max_scalar_order
protectedinherited

Maximum scalar variable order.

Definition at line 3408 of file FEProblemBase.h.

Referenced by FEProblemBase::addAuxScalarVariable(), and FEProblemBase::getMaxScalarOrder().

◆ _mesh

MooseMesh& FEProblemBase::_mesh
protectedinherited

◆ _mesh_divisions

MooseObjectWarehouse<MeshDivision> FEProblemBase::_mesh_divisions
protectedinherited

Warehouse to store mesh divisions NOTE: this could probably be moved to the MooseMesh instead of the Problem Time (and people's uses) will tell where this fits best.

Definition at line 3164 of file FEProblemBase.h.

Referenced by FEProblemBase::addMeshDivision(), and FEProblemBase::getMeshDivision().

◆ _mfem_solver_definitions

std::map<std::string, MFEMSolverDefinition> MFEMProblem::_mfem_solver_definitions
protected

Solver definitions recorded by AddMFEMSolverAction before the dependency resolver constructs them.

Each key is the user-provided solver object name, which corresponds to a child block name under [Solvers]. Solver parameters of type MFEMSolverName refer to these same keys when declaring dependencies between solver objects.

Definition at line 410 of file MFEMProblem.h.

Referenced by addMFEMSolver(), and resolveMFEMSolvers().

◆ _mortar_data

std::unique_ptr<MortarInterfaceWarehouse> FEProblemBase::_mortar_data
protectedinherited

◆ _multi_apps

ExecuteMooseObjectWarehouse<MultiApp> FEProblemBase::_multi_apps
protectedinherited

◆ _multiapp_fixed_point_convergence_name

std::optional<ConvergenceName> FEProblemBase::_multiapp_fixed_point_convergence_name
protectedinherited

◆ _name

const std::string& MooseBase::_name
protectedinherited

The name of this class.

Definition at line 381 of file MooseBase.h.

Referenced by AddBCAction::act(), AddConstraintAction::act(), AddInterfaceKernelAction::act(), AddDamperAction::act(), AddScalarKernelAction::act(), PartitionerAction::act(), AddMeshGeneratorAction::act(), AddFVInitialConditionAction::act(), AddInitialConditionAction::act(), AddDiracKernelAction::act(), AddUserObjectAction::act(), AddFVInterfaceKernelAction::act(), AddKernelAction::act(), AddMaterialAction::act(), AddIndicatorAction::act(), AddMultiAppAction::act(), AddNodalKernelAction::act(), AddDGKernelAction::act(), AddMarkerAction::act(), AddPostprocessorAction::act(), AddTransferAction::act(), AddFunctorMaterialAction::act(), AddVectorPostprocessorAction::act(), ReadExecutorParamsAction::act(), AddPositionsAction::act(), AddReporterAction::act(), AddTimesAction::act(), AddFieldSplitAction::act(), AddFVKernelAction::act(), AddFVBCAction::act(), AddHDGKernelAction::act(), AddDistributionAction::act(), AddConvergenceAction::act(), SetupPreconditionerAction::act(), SetupTimeIntegratorAction::act(), AddFunctionAction::act(), AddMeshDivisionAction::act(), AddFVInterpolationMethodAction::act(), AddTimeStepperAction::act(), AddOutputAction::act(), AddLinearFVBCAction::act(), AddLinearFVKernelAction::act(), AddCorrectorAction::act(), AddMeshModifiersAction::act(), AddMFEMComplexKernelComponentAction::act(), AddSamplerAction::act(), AddMFEMComplexBCComponentAction::act(), AddControlAction::act(), AddMFEMFESpaceAction::act(), AddMFEMQuadratureFunctionAction::act(), AddMFEMSubMeshAction::act(), AddMFEMSolverAction::act(), AddMFEMFESpaceHierarchyAction::act(), ADPiecewiseLinearInterpolationMaterial::ADPiecewiseLinearInterpolationMaterial(), BatchMeshGeneratorAction::BatchMeshGeneratorAction(), PiecewiseLinearBase::buildInterpolation(), CombinerGenerator::CombinerGenerator(), Executor::Executor(), ExtraIDIntegralReporter::ExtraIDIntegralReporter(), QuadraturePointMultiApp::fillPositions(), CentroidMultiApp::fillPositions(), MultiApp::fillPositions(), FunctionDT::FunctionDT(), FillBetweenCurvesGenerator::generate(), FillBetweenPointVectorsGenerator::generate(), FillBetweenSidesetsGenerator::generate(), MooseBase::MooseBase(), NearestPointBase< LayeredSideDiffusiveFluxAverage, SideIntegralVariableUserObject >::name(), ReferenceResidualConvergence::nonlinearConvergenceSetup(), ParsedFunctorMaterialTempl< is_ad >::ParsedFunctorMaterialTempl(), PiecewiseBilinear::PiecewiseBilinear(), PiecewiseLinearInterpolationMaterial::PiecewiseLinearInterpolationMaterial(), PiecewiseBase::setData(), and AddVariableAction::varName().

◆ _need_to_add_default_multiapp_fixed_point_convergence

bool FEProblemBase::_need_to_add_default_multiapp_fixed_point_convergence
protectedinherited

Flag that the problem needs to add the default fixed point convergence.

Definition at line 3085 of file FEProblemBase.h.

Referenced by FEProblemBase::needToAddDefaultMultiAppFixedPointConvergence(), and FEProblemBase::setNeedToAddDefaultMultiAppFixedPointConvergence().

◆ _need_to_add_default_nonlinear_convergence

bool FEProblemBase::_need_to_add_default_nonlinear_convergence
protectedinherited

Flag that the problem needs to add the default nonlinear convergence.

Definition at line 3083 of file FEProblemBase.h.

Referenced by FEProblemBase::needToAddDefaultNonlinearConvergence(), and FEProblemBase::setNeedToAddDefaultNonlinearConvergence().

◆ _need_to_add_default_steady_state_convergence

bool FEProblemBase::_need_to_add_default_steady_state_convergence
protectedinherited

Flag that the problem needs to add the default steady convergence.

Definition at line 3087 of file FEProblemBase.h.

Referenced by FEProblemBase::needToAddDefaultSteadyStateConvergence(), and FEProblemBase::setNeedToAddDefaultSteadyStateConvergence().

◆ _needs_old_newton_iter

bool FEProblemBase::_needs_old_newton_iter
protectedinherited

Indicates that we need to compute variable values for previous Newton iteration.

Definition at line 3354 of file FEProblemBase.h.

◆ _neighbor_material_props

MaterialPropertyStorage& FEProblemBase::_neighbor_material_props
protectedinherited

◆ _nl

std::vector<std::shared_ptr<NonlinearSystemBase> > FEProblemBase::_nl
protectedinherited

The nonlinear systems.

Definition at line 3114 of file FEProblemBase.h.

Referenced by FEProblemBase::addBoundaryCondition(), FEProblemBase::addConstraint(), FEProblemBase::addDamper(), FEProblemBase::addDGKernel(), FEProblemBase::addDiracKernel(), FEProblemBase::addHDGKernel(), FEProblemBase::addInterfaceKernel(), FEProblemBase::addKernel(), FEProblemBase::addNodalKernel(), FEProblemBase::addPredictor(), FEProblemBase::addScalarKernel(), FEProblemBase::addTimeIntegrator(), FEProblemBase::bumpAllQRuleOrder(), FEProblemBase::bumpVolumeQRuleOrder(), FEProblemBase::checkNonlocalCoupling(), FEProblemBase::checkProblemIntegrity(), FEProblemBase::computeResidualL2Norm(), FEProblemBase::computingPreSMOResidual(), FEProblemBase::currentNlSysNum(), FEProblemBase::customSetup(), DumpObjectsProblem::DumpObjectsProblem(), EigenProblem::EigenProblem(), ExternalProblem::ExternalProblem(), FEProblem::FEProblem(), FEProblemBase::finalNonlinearResidual(), FEProblemBase::getNonlinearEvaluableElementRange(), FEProblemBase::getNonlinearSystem(), FEProblemBase::getNonlinearSystemBase(), FEProblemBase::init(), FEProblemBase::initialSetup(), FEProblemBase::initXFEM(), FEProblemBase::jacobianSetup(), FEProblemBase::meshChanged(), FEProblemBase::needBoundaryMaterialOnSide(), FEProblemBase::needInterfaceMaterialOnSide(), FEProblemBase::needInternalNeighborSideMaterial(), FEProblemBase::nLinearIterations(), FEProblemBase::nNonlinearIterations(), FEProblemBase::onTimestepBegin(), FEProblemBase::prepareFace(), FEProblemBase::projectInitialConditionOnCustomRange(), FEProblemBase::projectSolution(), FEProblemBase::reinitDirac(), FEProblemBase::reinitNeighbor(), FEProblemBase::reinitNode(), FEProblemBase::reinitNodeFace(), FEProblemBase::reinitNodes(), FEProblemBase::reinitNodesNeighbor(), FEProblemBase::reinitScalars(), FEProblemBase::residualSetup(), FEProblemBase::setCurrentNonlinearSystem(), FEProblemBase::setNonlocalCouplingMatrix(), FEProblemBase::setResidual(), FEProblemBase::setResidualObjectParamsAndLog(), FEProblemBase::setupDampers(), FEProblemBase::subdomainSetup(), FEProblemBase::systemBaseNonlinear(), FEProblemBase::updateActiveObjects(), and FEProblemBase::updateMeshXFEM().

◆ _nl_evaluable_local_elem_range

std::unique_ptr<libMesh::ConstElemRange> FEProblemBase::_nl_evaluable_local_elem_range
protectedinherited

◆ _nl_sys_name_to_num

std::map<NonlinearSystemName, unsigned int> FEProblemBase::_nl_sys_name_to_num
protectedinherited

Map from nonlinear system name to number.

Definition at line 3117 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase(), and FEProblemBase::nlSysNum().

◆ _nl_sys_names

const std::vector<NonlinearSystemName> FEProblemBase::_nl_sys_names
protectedinherited

◆ _nonlinear_convergence_names

std::optional<std::vector<ConvergenceName> > FEProblemBase::_nonlinear_convergence_names
protectedinherited

Nonlinear system(s) convergence name(s)

Definition at line 3054 of file FEProblemBase.h.

Referenced by FEProblemBase::getNonlinearConvergenceNames(), and FEProblemBase::setNonlinearConvergenceNames().

◆ _nonlocal_integrated_bcs

MooseObjectWarehouse<IntegratedBCBase> FEProblemBase::_nonlocal_integrated_bcs
protectedinherited

◆ _nonlocal_kernels

MooseObjectWarehouse<KernelBase> FEProblemBase::_nonlocal_kernels
protectedinherited

◆ _not_zeroed_tagged_vectors

std::unordered_set<TagID> SubProblem::_not_zeroed_tagged_vectors
protectedinherited

the list of vector tags that will not be zeroed when all other tags are

Definition at line 1132 of file SubProblem.h.

Referenced by SubProblem::addNotZeroedVectorTag(), FEProblemBase::restoreSolutions(), and SubProblem::vectorTagNotZeroed().

◆ _notify_when_mesh_changes

std::vector<MeshChangedInterface *> FEProblemBase::_notify_when_mesh_changes
protectedinherited

Objects to be notified when the mesh changes.

Definition at line 3255 of file FEProblemBase.h.

Referenced by FEProblemBase::meshChanged(), and FEProblemBase::notifyWhenMeshChanges().

◆ _notify_when_mesh_displaces

std::vector<MeshDisplacedInterface *> FEProblemBase::_notify_when_mesh_displaces
protectedinherited

Objects to be notified when the mesh displaces.

Definition at line 3258 of file FEProblemBase.h.

Referenced by FEProblemBase::meshDisplaced(), and FEProblemBase::notifyWhenMeshDisplaces().

◆ _num_linear_sys

const std::size_t FEProblemBase::_num_linear_sys
protectedinherited

◆ _num_nl_sys

const std::size_t FEProblemBase::_num_nl_sys
protectedinherited

◆ _num_type

NumericType MFEMProblem::_num_type
protected

The numeric representation currently active for this problem.

Definition at line 402 of file MFEMProblem.h.

Referenced by getNumericType(), MFEMEigenproblem::MFEMEigenproblem(), and validateVariableNumericType().

◆ _parallel_barrier_messaging

bool FEProblemBase::_parallel_barrier_messaging
protectedinherited

◆ _pars

const InputParameters& MooseBase::_pars
protectedinherited

The object's parameters.

Definition at line 384 of file MooseBase.h.

Referenced by AddFVICAction::act(), AddICAction::act(), CreateProblemDefaultAction::act(), CreateProblemAction::act(), SetupMeshAction::act(), ComposeTimeStepperAction::act(), SetupDebugAction::act(), AddAuxKernelAction::act(), AddMFEMComplexKernelComponentAction::act(), AddMFEMComplexBCComponentAction::act(), CommonOutputAction::act(), FunctorMaterial::addFunctorPropertyByBlocks(), BreakMeshByBlockGenerator::BreakMeshByBlockGenerator(), PNGOutput::calculateRescalingValues(), MooseBase::callMooseError(), MooseBase::connectControllableParams(), Console::Console(), MooseApp::copyInputs(), MaterialBase::declareADProperty(), Moose::Kokkos::MaterialBase::declareKokkosOnDemandProperty(), Moose::Kokkos::MaterialBase::declareKokkosProperty(), MaterialBase::declareProperty(), FEProblemSolve::FEProblemSolve(), FunctionMaterialBase< is_ad >::FunctionMaterialBase(), FileMeshGenerator::generate(), MooseBase::getBase(), MooseBase::getCheckedPointerParam(), MaterialBase::getGenericZeroMaterialProperty(), MooseBase::getHitNode(), MeshGenerator::getMeshGeneratorNameFromParam(), MeshGenerator::getMeshGeneratorNamesFromParam(), MooseBase::getParam(), MooseBase::hasBase(), MeshGenerator::hasGenerateCSG(), MeshGenerator::hasGenerateData(), AddVariableAction::init(), AdvancedOutput::initExecutionTypes(), EigenProblemSolve::initialSetup(), Console::initialSetup(), MooseBase::isParamSetByUser(), MooseBase::isParamValid(), MultiApp::keepSolutionDuringRestore(), MooseBase::messagePrefix(), MooseBase::MooseBase(), MultiSystemSolveObject::MultiSystemSolveObject(), MooseApp::outputMachineReadableData(), MooseBase::paramError(), MooseBase::parameters(), MooseBase::paramInfo(), MooseBase::paramWarning(), MooseMesh::prepare(), MooseBase::queryParam(), MooseMesh::setCoordSystem(), MooseMesh::setPartitionerHelper(), SetupMeshAction::setupMesh(), TransientBase::setupTimeIntegrator(), MooseApp::showInputs(), and MooseBase::uniqueName().

◆ _petsc_option_data_base

PetscOptions FEProblemBase::_petsc_option_data_base
protectedinherited

◆ _petsc_options

Moose::PetscSupport::PetscOptions FEProblemBase::_petsc_options
protectedinherited

PETSc option storage.

Definition at line 3438 of file FEProblemBase.h.

Referenced by FEProblemBase::getPetscOptions(), FEProblemBase::solve(), and FEProblemBase::solveLinearSystem().

◆ _pg_moose_app

MooseApp& PerfGraphInterface::_pg_moose_app
protectedinherited

The MooseApp that owns the PerfGraph.

Definition at line 135 of file PerfGraphInterface.h.

Referenced by PerfGraphInterface::perfGraph().

◆ _phi_zero

std::vector<VariablePhiValue> FEProblemBase::_phi_zero
inherited

◆ _point_zero

std::vector<Point> FEProblemBase::_point_zero
inherited

Definition at line 2509 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase().

◆ _prefix

const std::string PerfGraphInterface::_prefix
protectedinherited

A prefix to use for all sections.

Definition at line 138 of file PerfGraphInterface.h.

Referenced by PerfGraphInterface::timedSectionName().

◆ _previous_multiapp_fp_aux_solution_required

bool FEProblemBase::_previous_multiapp_fp_aux_solution_required
protectedinherited

Indicates we need to save the previous multiapp fixed-point iteration auxiliary variable values.

Definition at line 3361 of file FEProblemBase.h.

Referenced by FEProblemBase::needsPreviousMultiAppFixedPointIterationAuxiliary().

◆ _previous_multiapp_fp_nl_solution_required

std::vector<bool> FEProblemBase::_previous_multiapp_fp_nl_solution_required
protectedinherited

Indicates we need to save the previous multiapp fixed-point iteration solver variable values.

Definition at line 3359 of file FEProblemBase.h.

Referenced by FEProblemBase::needsPreviousMultiAppFixedPointIterationSolution().

◆ _previous_nl_solution_required

bool FEProblemBase::_previous_nl_solution_required
protectedinherited

Indicates we need to save the previous NL iteration variable values.

Definition at line 3357 of file FEProblemBase.h.

Referenced by FEProblemBase::createTagSolutions().

◆ _problem_data

MFEMProblemData MFEMProblem::_problem_data
protected

Aggregated MFEM-side state for meshes, spaces, variables, coefficients, and solvers.

Definition at line 397 of file MFEMProblem.h.

Referenced by getCoefficients(), getComplexGridFunction(), getGridFunction(), getMeshDisplacementGridFunction(), getMFEMVariableMesh(), getProblemData(), hRefine(), pRefine(), updateFESpaces(), and updateGridFunctions().

◆ _random_data_objects

std::map<std::string, std::unique_ptr<RandomData> > FEProblemBase::_random_data_objects
protectedinherited

◆ _real_zero

std::vector<Real> FEProblemBase::_real_zero
inherited

Convenience zeros.

Definition at line 2498 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase().

◆ _reinit_displaced_elem

bool FEProblemBase::_reinit_displaced_elem
protectedinherited

◆ _reinit_displaced_face

bool FEProblemBase::_reinit_displaced_face
protectedinherited

◆ _reinit_displaced_neighbor

bool FEProblemBase::_reinit_displaced_neighbor
protectedinherited

◆ _reporter_data

ReporterData FEProblemBase::_reporter_data
protectedinherited

◆ _restartable_app

MooseApp& Restartable::_restartable_app
protectedinherited

Reference to the application.

Definition at line 234 of file Restartable.h.

Referenced by Restartable::registerRestartableDataOnApp(), and Restartable::registerRestartableNameWithFilterOnApp().

◆ _restartable_read_only

const bool Restartable::_restartable_read_only
protectedinherited

Flag for toggling read only status (see ReporterData)

Definition at line 243 of file Restartable.h.

Referenced by Restartable::registerRestartableDataOnApp().

◆ _restartable_system_name

const std::string Restartable::_restartable_system_name
protectedinherited

The system name this object is in.

Definition at line 237 of file Restartable.h.

Referenced by Restartable::restartableName().

◆ _restartable_tid

const THREAD_ID Restartable::_restartable_tid
protectedinherited

The thread ID for this object.

Definition at line 240 of file Restartable.h.

Referenced by Restartable::declareRestartableDataHelper().

◆ _safe_access_tagged_matrices

bool SubProblem::_safe_access_tagged_matrices
protectedinherited

◆ _safe_access_tagged_vectors

bool SubProblem::_safe_access_tagged_vectors
protectedinherited

◆ _scalar_ics

ScalarInitialConditionWarehouse FEProblemBase::_scalar_ics
protectedinherited

◆ _scalar_zero

std::vector<VariableValue> FEProblemBase::_scalar_zero
inherited

◆ _second_phi_zero

std::vector<VariablePhiSecond> FEProblemBase::_second_phi_zero
inherited

◆ _second_zero

std::vector<VariableSecond> FEProblemBase::_second_zero
inherited

◆ _skip_exception_check

bool FEProblemBase::_skip_exception_check
protectedinherited

If or not skip 'exception and stop solve'.

Definition at line 3339 of file FEProblemBase.h.

Referenced by FEProblemBase::checkExceptionAndStopSolve(), FEProblemBase::initialSetup(), and FEProblemBase::skipExceptionCheck().

◆ _snesmf_reuse_base

bool FEProblemBase::_snesmf_reuse_base
protectedinherited

If or not to resuse the base vector for matrix-free calculation.

Definition at line 3336 of file FEProblemBase.h.

Referenced by FEProblemBase::setSNESMFReuseBase(), and FEProblemBase::useSNESMFReuseBase().

◆ _snesmf_reuse_base_set_by_user

bool FEProblemBase::_snesmf_reuse_base_set_by_user
protectedinherited

If or not _snesmf_reuse_base is set by user.

Definition at line 3342 of file FEProblemBase.h.

Referenced by FEProblemBase::isSNESMFReuseBaseSetbyUser(), and FEProblemBase::setSNESMFReuseBase().

◆ _solution_state_data

Moose::MFEM::SolutionState& MFEMProblem::_solution_state_data
protected

Restartable MFEM solution state associated with this problem.

Definition at line 413 of file MFEMProblem.h.

◆ _solve

const bool& FEProblemBase::_solve
protectedinherited

◆ _solver_params

std::vector<SolverParams> FEProblemBase::_solver_params
protectedinherited

◆ _solver_sys_name_to_num

std::map<SolverSystemName, unsigned int> FEProblemBase::_solver_sys_name_to_num
protectedinherited

Map connecting solver system names with their respective systems.

Definition at line 3132 of file FEProblemBase.h.

Referenced by FEProblemBase::FEProblemBase(), and FEProblemBase::solverSysNum().

◆ _solver_sys_names

std::vector<SolverSystemName> FEProblemBase::_solver_sys_names
protectedinherited

◆ _solver_systems

std::vector<std::shared_ptr<SolverSystem> > FEProblemBase::_solver_systems
protectedinherited

Combined container to base pointer of every solver system.

Definition at line 3126 of file FEProblemBase.h.

Referenced by FEProblemBase::addObjectParamsHelper(), FEProblemBase::addTimeIntegrator(), FEProblemBase::addVariable(), FEProblemBase::advanceState(), FEProblemBase::computeSystems(), FEProblemBase::copySolutionsBackwards(), FEProblemBase::createQRules(), FEProblemBase::createTagMatrices(), FEProblemBase::createTagSolutions(), FEProblemBase::createTagVectors(), FEProblemBase::determineSolverSystem(), DumpObjectsProblem::DumpObjectsProblem(), FEProblemBase::duplicateVariableCheck(), EigenProblem::EigenProblem(), ExternalProblem::ExternalProblem(), FEProblem::FEProblem(), FEProblemBase::getActualFieldVariable(), FEProblemBase::getArrayVariable(), FEProblemBase::getScalarVariable(), FEProblemBase::getSolverSystem(), FEProblemBase::getStandardVariable(), FEProblemBase::getSystem(), FEProblemBase::getSystemBase(), FEProblemBase::getVariable(), FEProblemBase::getVariableNames(), FEProblemBase::getVectorVariable(), FEProblemBase::hasScalarVariable(), FEProblemBase::hasSolutionState(), FEProblemBase::hasSolverVariable(), FEProblemBase::hasVariable(), FEProblem::init(), FEProblemBase::init(), FEProblemBase::initialSetup(), FEProblemBase::meshChanged(), FEProblemBase::needSolutionState(), FEProblemBase::outputStep(), FEProblemBase::projectSolution(), FEProblemBase::reinitElem(), FEProblemBase::reinitElemPhys(), FEProblemBase::restoreOldSolutions(), FEProblemBase::restoreSolutions(), FEProblemBase::saveOldSolutions(), FEProblemBase::setAuxKernelParamsAndLog(), FEProblemBase::setCurrentSubdomainID(), Moose::PetscSupport::setSinglePetscOption(), FEProblemBase::setVariableAllDoFMap(), FEProblemBase::skipNextForwardSolutionCopyToOld(), FEProblemBase::solverSystemConverged(), FEProblemBase::systemBaseSolver(), FEProblemBase::systemNumForVariable(), and FEProblemBase::timestepSetup().

◆ _solver_var_to_sys_num

std::map<SolverVariableName, unsigned int> FEProblemBase::_solver_var_to_sys_num
protectedinherited

Map connecting variable names with their respective solver systems.

Definition at line 3129 of file FEProblemBase.h.

Referenced by FEProblemBase::addVariable(), and FEProblemBase::determineSolverSystem().

◆ _steady_state_convergence_name

std::optional<ConvergenceName> FEProblemBase::_steady_state_convergence_name
protectedinherited

◆ _subspace_dim

std::map<std::string, unsigned int> FEProblemBase::_subspace_dim
protectedinherited

Dimension of the subspace spanned by the vectors with a given prefix.

Definition at line 3151 of file FEProblemBase.h.

Referenced by FEProblemBase::initNullSpaceVectors(), and FEProblemBase::subspaceDim().

◆ _t_step

int& FEProblemBase::_t_step
protectedinherited

◆ _termination_requested

bool Problem::_termination_requested
protectedinherited

True if termination of the solve has been requested.

Definition at line 58 of file Problem.h.

Referenced by Problem::isSolveTerminationRequested(), and Problem::terminateSolve().

◆ _time

Real& FEProblemBase::_time
protectedinherited

◆ _time_old

Real& FEProblemBase::_time_old
protectedinherited

◆ _to_multi_app_transfers

ExecuteMooseObjectWarehouse<Transfer> FEProblemBase::_to_multi_app_transfers
protectedinherited

◆ _transfers

ExecuteMooseObjectWarehouse<Transfer> FEProblemBase::_transfers
protectedinherited

◆ _transient

bool FEProblemBase::_transient
protectedinherited

Definition at line 3075 of file FEProblemBase.h.

Referenced by FEProblemBase::isTransient(), and FEProblemBase::transient().

◆ _transient_multi_apps

ExecuteMooseObjectWarehouse<TransientMultiApp> FEProblemBase::_transient_multi_apps
protectedinherited

Storage for TransientMultiApps (only needed for calling 'computeDT')

Definition at line 3228 of file FEProblemBase.h.

Referenced by FEProblemBase::addMultiApp(), FEProblemBase::computeMultiAppsDT(), and FEProblemBase::updateActiveObjects().

◆ _type

const std::string& MooseBase::_type
protectedinherited

◆ _uo_aux_state_check

const bool FEProblemBase::_uo_aux_state_check
protectedinherited

Whether or not checking the state of uo/aux evaluation.

Definition at line 3397 of file FEProblemBase.h.

Referenced by FEProblemBase::execute(), and FEProblemBase::hasUOAuxStateCheck().

◆ _uo_jacobian_moose_vars

std::vector<std::vector<const MooseVariableFEBase *> > FEProblemBase::_uo_jacobian_moose_vars
protectedinherited

◆ _use_hash_table_matrix_assembly

const bool FEProblemBase::_use_hash_table_matrix_assembly
protectedinherited

Whether to assemble matrices using hash tables instead of preallocating matrix memory.

This can be a good option if the sparsity pattern changes throughout the course of the simulation

Definition at line 3465 of file FEProblemBase.h.

Referenced by EigenProblem::EigenProblem(), FEProblem::FEProblem(), and FEProblemBase::useHashTableMatrixAssembly().

◆ _using_ad_mat_props

bool FEProblemBase::_using_ad_mat_props
protectedinherited

Automatic differentiaion (AD) flag which indicates whether any consumer has requested an AD material property or whether any suppier has declared an AD material property.

Definition at line 3458 of file FEProblemBase.h.

◆ _using_default_nl

const bool FEProblemBase::_using_default_nl
protectedinherited

Boolean to check if we have the default nonlinear system.

Definition at line 3105 of file FEProblemBase.h.

◆ _var_dof_map

std::map<std::string, std::vector<dof_id_type> > SubProblem::_var_dof_map
inherited

◆ _vector_curl_zero

std::vector<VectorVariableCurl> FEProblemBase::_vector_curl_zero
inherited

◆ _vector_zero

std::vector<VectorVariableValue> FEProblemBase::_vector_zero
inherited

◆ _verbose_multiapps

bool FEProblemBase::_verbose_multiapps
protectedinherited

◆ _verbose_restore

bool FEProblemBase::_verbose_restore
protectedinherited

Whether or not to be verbose on solution restoration post a failed time step.

Definition at line 3426 of file FEProblemBase.h.

Referenced by FEProblemBase::restoreSolutions(), and FEProblemBase::setVerboseProblem().

◆ _verbose_setup

MooseEnum FEProblemBase::_verbose_setup
protectedinherited

Whether or not to be verbose during setup.

Definition at line 3420 of file FEProblemBase.h.

Referenced by FEProblemBase::logAdd(), and FEProblemBase::setVerboseProblem().

◆ _xfem

std::shared_ptr<XFEMInterface> FEProblemBase::_xfem
protectedinherited

Pointer to XFEM controller.

Definition at line 3311 of file FEProblemBase.h.

Referenced by FEProblemBase::getXFEM(), FEProblemBase::haveXFEM(), FEProblemBase::initXFEM(), and FEProblemBase::updateMeshXFEM().

◆ _zero

std::vector<VariableValue> FEProblemBase::_zero
inherited

◆ _zero_block_material_props

std::map<SubdomainID, std::set<MaterialPropertyName> > SubProblem::_zero_block_material_props
protectedinherited

Set of properties returned as zero properties.

Definition at line 1073 of file SubProblem.h.

Referenced by SubProblem::checkBlockMatProps(), FEProblemBase::checkDependMaterialsHelper(), and SubProblem::storeSubdomainZeroMatProp().

◆ _zero_boundary_material_props

std::map<BoundaryID, std::set<MaterialPropertyName> > SubProblem::_zero_boundary_material_props
protectedinherited

◆ app_param

const std::string MooseBase::app_param = "_moose_app"
staticinherited

◆ kokkos_object_param

const std::string MooseBase::kokkos_object_param = "_kokkos_object"
staticinherited

The name of the parameter that indicates an object is a Kokkos functor.

Definition at line 64 of file MooseBase.h.

Referenced by InputParameters::isKokkosObject().

◆ moose_base_param

const std::string MooseBase::moose_base_param = "_moose_base"
staticinherited

The name of the parameter that contains the moose system base.

Definition at line 61 of file MooseBase.h.

Referenced by InputParameters::getBase(), InputParameters::hasBase(), and InputParameters::registerBase().

◆ name_param

const std::string MooseBase::name_param = "_object_name"
staticinherited

◆ type_param

const std::string MooseBase::type_param = "_type"
staticinherited

◆ unique_name_param

const std::string MooseBase::unique_name_param = "_unique_name"
staticinherited

The name of the parameter that contains the unique object name.

Definition at line 57 of file MooseBase.h.

Referenced by InputParameterWarehouse::addInputParameters(), AppFactory::create(), InputParameterWarehouse::removeInputParameters(), MooseBase::uniqueName(), and MooseBase::validParams().

◆ usingCombinedWarningSolutionWarnings

MooseObject::usingCombinedWarningSolutionWarnings
inherited

Definition at line 67 of file MooseObject.h.


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