41 #include "libmesh/enum_quadrature_type.h" 42 #include "libmesh/equation_systems.h" 44 #include <unordered_map> 100 class NonlinearImplicitSystem;
101 class LinearImplicitSystem;
173 const unsigned int nl_sys_num);
184 areCoupled(
const unsigned int ivar,
const unsigned int jvar,
const unsigned int nl_sys_num)
const;
206 std::vector<std::pair<MooseVariableFEBase *, MooseVariableFEBase *>> &
208 std::vector<std::pair<MooseVariableFEBase *, MooseVariableFEBase *>> &
211 virtual bool hasVariable(
const std::string & var_name)
const override;
217 const std::string & var_name,
222 const std::string & var_name)
override;
224 const std::string & var_name)
override;
226 const std::string & var_name)
override;
228 const std::string & var_name)
override;
232 const std::string & var_name)
override;
278 bool allow_negative_qweights =
true);
308 const std::vector<const MooseVariableFEBase *> &
331 virtual void prepare(
const Elem * elem,
334 const std::vector<dof_id_type> & dof_indices,
352 const std::vector<Point> & phys_points_in_elem,
358 const std::vector<Point> *
const pts =
nullptr,
359 const std::vector<Real> *
const weights =
nullptr)
override;
367 unsigned int neighbor_side,
368 const std::vector<Point> & physical_points,
371 const std::vector<Point> & physical_points,
376 bool reinit_for_derivative_reordering =
false)
override;
386 virtual void newAssemblyArray(std::vector<std::shared_ptr<SolverSystem>> & solver_systems);
388 std::vector<std::shared_ptr<NonlinearSystemBase>> & nl);
390 virtual void init()
override;
391 virtual void solve(
const unsigned int nl_sys_num);
497 virtual unsigned int nLinearIterations(
const unsigned int nl_sys_num)
const override;
528 const std::string &
name,
581 template <
typename T>
609 void logAdd(
const std::string & system,
610 const std::string &
name,
611 const std::string &
type,
632 virtual const std::vector<std::shared_ptr<Convergence>> &
714 mooseError(
"Line search not implemented for this problem type yet.");
827 virtual void addKernel(
const std::string & kernel_name,
828 const std::string &
name,
830 virtual void addHDGKernel(
const std::string & kernel_name,
831 const std::string &
name,
834 const std::string &
name,
837 const std::string &
name,
840 const std::string &
name,
859 const std::string & var_name,
864 const std::set<SubdomainID> *
const active_subdomains = NULL);
867 unsigned int components,
868 const std::set<SubdomainID> *
const active_subdomains = NULL);
871 Real scale_factor = 1.,
872 const std::set<SubdomainID> *
const active_subdomains = NULL);
873 virtual void addAuxKernel(
const std::string & kernel_name,
874 const std::string &
name,
877 const std::string &
name,
884 const std::string &
name,
888 virtual void addDGKernel(
const std::string & kernel_name,
889 const std::string &
name,
892 virtual void addFVKernel(
const std::string & kernel_name,
893 const std::string &
name,
897 const std::string &
name,
902 const std::string &
name,
906 const std::string &
name,
911 const std::string &
name,
916 const std::string &
name,
925 const std::string &
name,
945 virtual void addMaterial(
const std::string & material_name,
946 const std::string &
name,
949 const std::string & material_name,
950 const std::string &
name,
953 const std::string &
name,
956 const std::string &
name,
970 void prepareMaterials(
const std::unordered_set<unsigned int> & consumer_needed_mat_props,
988 bool swap_stateful =
true,
989 const std::deque<MaterialBase *> * reinit_mats =
nullptr);
1003 bool swap_stateful =
true,
1004 const std::deque<MaterialBase *> * reinit_mats =
nullptr);
1018 bool swap_stateful =
true,
1019 const std::deque<MaterialBase *> * reinit_mats =
nullptr);
1068 template <
typename T>
1069 std::vector<std::shared_ptr<T>>
addObject(
const std::string &
type,
1070 const std::string &
name,
1072 const bool threaded =
true,
1073 const std::string & var_param_name =
"variable");
1077 const std::string &
name,
1082 const std::string &
name,
1113 virtual std::vector<std::shared_ptr<UserObject>>
addUserObject(
1120 "This function is deprecated, use theWarehouse().query() to construct a query instead");
1132 std::vector<T *> objs;
1136 .condition<AttribThread>(tid)
1140 mooseError(
"Unable to find user object with name '" +
name +
"'");
1186 std::size_t t_index = 0)
const;
1204 std::size_t t_index = 0);
1223 const std::string & vector_name,
1224 std::size_t t_index = 0)
const;
1234 const std::string & vector_name,
1236 std::size_t t_index = 0);
1259 virtual void addDamper(
const std::string & damper_name,
1260 const std::string &
name,
1270 virtual void addIndicator(
const std::string & indicator_name,
1271 const std::string &
name,
1275 virtual void addMarker(
const std::string & marker_name,
1276 const std::string &
name,
1282 virtual void addMultiApp(
const std::string & multi_app_name,
1283 const std::string &
name,
1289 std::shared_ptr<MultiApp>
getMultiApp(
const std::string & multi_app_name)
const;
1329 mooseDeprecated(
"Deprecated method; use finishMultiAppStep and/or incrementMultiAppTStep " 1330 "depending on your purpose");
1359 virtual void addTransfer(
const std::string & transfer_name,
1360 const std::string &
name,
1395 const NumericVector<libMesh::Number> & soln,
1396 NumericVector<libMesh::Number> & residual);
1402 const NumericVector<libMesh::Number> & soln,
1403 NumericVector<libMesh::Number> & residual);
1408 virtual void computeResidual(
const NumericVector<libMesh::Number> & soln,
1409 NumericVector<libMesh::Number> & residual,
1410 const unsigned int nl_sys_num);
1416 NumericVector<libMesh::Number> & residual,
1423 NumericVector<libMesh::Number> & residual,
1429 NumericVector<libMesh::Number> & residual,
1437 NumericVector<libMesh::Number> & residual,
1438 const std::set<TagID> & tags);
1448 const NumericVector<libMesh::Number> & soln,
1453 virtual void computeJacobian(
const NumericVector<libMesh::Number> & soln,
1455 const unsigned int nl_sys_num);
1469 const std::set<TagID> & tags);
1485 const unsigned int nl_sys_num);
1516 NumericVector<libMesh::Number> & rhs,
1517 const bool compute_gradients =
true);
1529 const std::set<TagID> & vector_tags,
1530 const std::set<TagID> & matrix_tags,
1531 const bool compute_gradients =
true);
1534 const NumericVector<libMesh::Number> & update);
1548 virtual bool updateSolution(NumericVector<libMesh::Number> & vec_solution,
1549 NumericVector<libMesh::Number> & ghosted_solution);
1555 virtual void predictorCleanup(NumericVector<libMesh::Number> & ghosted_solution);
1558 NumericVector<libMesh::Number> & lower,
1559 NumericVector<libMesh::Number> & upper);
1561 std::vector<NumericVector<libMesh::Number> *> & sp);
1563 std::vector<NumericVector<libMesh::Number> *> & sp);
1565 std::vector<NumericVector<libMesh::Number> *> & sp);
1567 const NumericVector<libMesh::Number> & old_soln,
1568 NumericVector<libMesh::Number> & search_direction,
1569 NumericVector<libMesh::Number> & new_soln,
1570 bool & changed_search_direction,
1571 bool & changed_new_soln);
1596 virtual void setResidual(NumericVector<libMesh::Number> & residual,
const THREAD_ID tid)
override;
1607 const DofMap & dof_map,
1608 std::vector<dof_id_type> & dof_indices,
1609 const std::set<TagID> & tags,
1614 const DofMap & dof_map,
1615 std::vector<dof_id_type> & dof_indices,
1616 std::vector<dof_id_type> & neighbor_dof_indices,
1617 const std::set<TagID> & tags,
1643 const std::pair<BoundaryID, BoundaryID> & primary_secondary_boundary_pair,
1644 const std::pair<SubdomainID, SubdomainID> & primary_secondary_subdomain_pair,
1648 const bool correct_edge_dropping,
1649 const Real minimum_projection_angle);
1657 getMortarInterface(
const std::pair<BoundaryID, BoundaryID> & primary_secondary_boundary_pair,
1658 const std::pair<SubdomainID, SubdomainID> & primary_secondary_subdomain_pair,
1659 bool on_displaced)
const;
1662 getMortarInterface(
const std::pair<BoundaryID, BoundaryID> & primary_secondary_boundary_pair,
1663 const std::pair<SubdomainID, SubdomainID> & primary_secondary_subdomain_pair,
1733 #ifdef LIBMESH_ENABLE_AMR 1757 #endif // LIBMESH_ENABLE_AMR 1760 void initXFEM(std::shared_ptr<XFEMInterface> xfem);
1786 meshChanged(
bool intermediate_change,
bool contract_mesh,
bool clean_refinement_flags);
1930 bool no_warn =
false);
2030 const std::string &
name);
2141 #if !PETSC_RELEASE_LESS_THAN(3, 12, 0) 2176 mooseError(
"FEProblemBase: When requesting old time derivative of solution, current time " 2177 "derivative of solution should also be stored. Please set `u_dot_requested` to " 2178 "true using setUDotRequested.");
2187 mooseError(
"FEProblemBase: When requesting old second time derivative of solution, current " 2188 "second time derivation of solution should also be stored. Please set " 2189 "`u_dotdot_requested` to true using setUDotDotRequested.");
2239 template <
typename T>
2241 template <
typename T>
2254 const std::vector<Point> *
const pts,
2255 const std::vector<Real> *
const weights =
nullptr,
2265 unsigned int neighbor_side,
2267 const std::vector<Point> *
const pts,
2268 const std::vector<Real> *
const weights =
nullptr,
2291 std::vector<std::shared_ptr<MaterialBase>> & face_materials,
2292 std::vector<std::shared_ptr<MaterialBase>> & neighbor_materials,
2293 std::set<MooseVariableFieldBase *> & variables,
2387 virtual unsigned int nlSysNum(
const NonlinearSystemName & nl_sys_name)
const override;
2392 unsigned int linearSysNum(
const LinearSystemName & linear_sys_name)
const override;
2397 unsigned int solverSysNum(
const SolverSystemName & solver_sys_name)
const override;
2539 const std::string &
name,
2541 const unsigned int nl_sys_num,
2542 const std::string & base_name,
2543 bool & reinit_displaced);
2614 std::vector<std::shared_ptr<NonlinearSystemBase>>
_nl;
2638 std::shared_ptr<AuxiliarySystem>
_aux;
2641 std::vector<std::unique_ptr<libMesh::CouplingMatrix>>
_cm;
2648 std::vector<std::vector<std::unique_ptr<Assembly>>>
_assembly;
2743 const std::set<SubdomainID> *
const active_subdomains);
2760 const std::map<
SubdomainID, std::vector<std::shared_ptr<MaterialBase>>> & materials_map);
2779 const std::string & object_name,
2780 const std::string & var_param_name =
"variable");
2782 #ifdef LIBMESH_ENABLE_AMR 2907 #if !PETSC_RELEASE_LESS_THAN(3, 12, 0) 2946 std::vector<MortarUserObject *>
2950 const std::vector<MortarUserObject *> & mortar_uo_superset);
2969 virtual std::pair<bool, unsigned int>
2971 bool error_if_not_found =
false)
const override;
2980 const std::string &
name,
2981 const VariableName & var_name);
3088 const std::string & value,
3094 template <
typename T>
3101 template <
typename T>
3107 for (T * obj_ptr : objects)
3108 obj_ptr->initialSetup();
3113 for (
const auto obj_ptr : objects)
3114 obj_ptr->timestepSetup();
3118 for (
const auto obj_ptr : objects)
3119 obj_ptr->subdomainSetup();
3124 for (
const auto obj_ptr : objects)
3125 obj_ptr->jacobianSetup();
3130 for (
const auto obj_ptr : objects)
3131 obj_ptr->residualSetup();
3135 template <
typename T>
3139 for (T * obj_ptr : objects)
3143 template <
typename T>
3144 std::vector<std::shared_ptr<T>>
3146 const std::string &
name,
3148 const bool threaded,
3149 const std::string & var_param_name)
3151 parallel_object_only();
3158 std::vector<std::shared_ptr<T>> objects(
n_threads);
3163 objects[tid] = std::move(obj);
3172 mooseAssert(sys_num <
_nl.size(),
"System number greater than the number of nonlinear systems");
3173 return *
_nl[sys_num];
3179 mooseAssert(sys_num <
_nl.size(),
"System number greater than the number of nonlinear systems");
3180 return *
_nl[sys_num];
3187 "System number greater than the number of solver systems");
3195 "System number greater than the number of solver systems");
3202 mooseAssert(
_current_nl_sys,
"The nonlinear system is not currently set");
3209 mooseAssert(
_current_nl_sys,
"The nonlinear system is not currently set");
3217 "System number greater than the number of linear systems");
3225 "System number greater than the number of linear systems");
3246 mooseAssert(tid <
_assembly.size(),
"Assembly objects not initialized");
3247 mooseAssert(sys_num <
_assembly[tid].size(),
3248 "System number larger than the assembly container size");
3255 mooseAssert(tid <
_assembly.size(),
"Assembly objects not initialized");
3256 mooseAssert(sys_num <
_assembly[tid].size(),
3257 "System number larger than the assembly container size");
3264 return _cm[i].get();
3277 inline const std::vector<VectorTag> &
bool _reinit_displaced_elem
Whether to call DisplacedProblem::reinitElem when this->reinitElem is called.
virtual void addInterfaceMaterial(const std::string &material_name, const std::string &name, InputParameters ¶meters)
std::map< NonlinearSystemName, unsigned int > _nl_sys_name_to_num
Map from nonlinear system name to number.
void setCurrentAlgebraicElementRange(libMesh::ConstElemRange *range)
These functions allow setting custom ranges for the algebraic elements, nodes, and boundary nodes tha...
std::vector< Point > _point_zero
Interface for objects that need parallel consistent random numbers without patterns over the course o...
virtual void computeJacobianTag(const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian, TagID tag)
Form a Jacobian matrix for a given tag.
unsigned short getCurrentICState()
Retrieves the current initial condition state.
void resetFailNextNonlinearConvergenceCheck()
Tell the problem that the nonlinear convergence check(s) may proceed as normal.
bool _u_dot_requested
Whether solution time derivative needs to be stored.
Warehouse for storing scalar initial conditions.
virtual void addFVInitialCondition(const std::string &ic_name, const std::string &name, InputParameters ¶meters)
Add an initial condition for a finite volume variables.
virtual void addMaterialHelper(std::vector< MaterialWarehouse *> warehouse, const std::string &material_name, const std::string &name, InputParameters ¶meters)
virtual bool hasNeighborCoupling() const
Whether the simulation has neighbor coupling.
virtual bool hasVariable(const std::string &var_name) const override
Whether or not this problem has the variable.
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.
const bool _regard_general_exceptions_as_errors
If we catch an exception during residual/Jacobian evaluaton for which we don't have specific handling...
const std::vector< NonlinearSystemName > & getNonlinearSystemNames() const
const std::size_t _num_nl_sys
The number of nonlinear systems.
void setVariableAllDoFMap(const std::vector< const MooseVariableFEBase *> &moose_vars)
virtual void initPetscOutputAndSomeSolverSettings()
Reinitialize PETSc output for proper linear/nonlinear iteration display.
void setKernelCoverageCheck(CoverageCheckMode mode)
Set flag to indicate whether kernel coverage checks should be performed.
const std::vector< ConvergenceName > & getNonlinearConvergenceNames() const
Gets the nonlinear system convergence object name(s).
void timestepSetup() override
virtual void addSampler(const std::string &type, const std::string &name, InputParameters ¶meters)
The following functions will enable MOOSE to have the capability to import Samplers.
bool _skip_exception_check
If or not skip 'exception and stop solve'.
virtual void setUDotDotOldRequested(const bool u_dotdot_old_requested)
Set boolean flag to true to store old solution second time derivative.
Helper class for holding the preconditioning blocks to fill.
bool _reinit_displaced_neighbor
Whether to call DisplacedProblem::reinitNeighbor when this->reinitNeighbor is called.
virtual void meshChanged()
Deprecated.
virtual void addDamper(const std::string &damper_name, const std::string &name, InputParameters ¶meters)
std::map< LinearSystemName, unsigned int > _linear_sys_name_to_num
Map from linear system name to number.
Moose::PetscSupport::PetscOptions & getPetscOptions()
Retrieve a writable reference the PETSc options (used by PetscSupport)
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.
std::vector< MooseArray< ADRealTensorValue > > _ad_second_zero
virtual Real & dtOld() const
bool _need_to_add_default_steady_state_convergence
Flag that the problem needs to add the default steady convergence.
virtual void prepareFace(const Elem *elem, const THREAD_ID tid) override
Base class for function objects.
void setPreserveMatrixSparsityPattern(bool preserve)
Set whether the sparsity pattern of the matrices being formed during the solve (usually the Jacobian)...
void reinitBecauseOfGhostingOrNewGeomObjects(bool mortar_changed=false)
Call when it is possible that the needs for ghosted elements has changed.
virtual void addTransfer(const std::string &transfer_name, const std::string &name, InputParameters ¶meters)
Add a Transfer to the problem.
const MortarData & mortarData() const
Returns the mortar data object.
virtual libMesh::System & getSystem(const std::string &var_name) override
Returns the equation system containing the variable provided.
A MultiMooseEnum object to hold "execute_on" flags.
static SolverParams makeLinearSolverParams()
Make basic solver params for linear solves.
bool _snesmf_reuse_base_set_by_user
If or not _snesmf_reuse_base is set by user.
bool _parallel_barrier_messaging
Whether or not information about how many transfers have completed is printed.
virtual void addResidualLower(const THREAD_ID tid) override
bool _computing_scaling_jacobian
Flag used to indicate whether we are computing the scaling Jacobian.
A class for creating restricted objects.
virtual void addJacobianLowerD(const THREAD_ID tid) override
Factory & _factory
The Factory for building objects.
virtual void clearActiveScalarVariableCoupleableVectorTags(const THREAD_ID tid) override
MaterialPropertyStorage & _bnd_material_props
virtual void addGhostedElem(dof_id_type elem_id) override
Will make sure that all dofs connected to elem_id are ghosted to this processor.
void setNonlocalCouplingMatrix()
Set custom coupling matrix for variables requiring nonlocal contribution.
void setExecutionPrinting(const ExecFlagEnum &print_exec)
virtual Real & time() const
std::vector< std::pair< MooseVariableFEBase *, MooseVariableFEBase * > > & couplingEntries(const THREAD_ID tid, const unsigned int nl_sys_num)
void checkDependMaterialsHelper(const std::map< SubdomainID, std::vector< std::shared_ptr< MaterialBase >>> &materials_map)
Helper method for checking Material object dependency.
void setNeedToAddDefaultSteadyStateConvergence()
Sets _need_to_add_default_steady_state_convergence to true.
virtual void cacheResidualNeighbor(const THREAD_ID tid) override
virtual void setInputParametersFEProblem(InputParameters ¶meters)
bool identifyVariableGroupsInNL() const
Whether to identify variable groups in nonlinear systems.
ExecFlagType _current_execute_on_flag
Current execute_on flag.
void clearCurrentResidualVectorTags()
Clear the current residual vector tag data structure.
QueryCache is a convenient way to construct and pass around (possible partially constructed) warehous...
T & getUserObject(const std::string &name, unsigned int tid=0) const
Get the user object by its name.
std::shared_ptr< DisplacedProblem > displaced_problem
virtual bool hasNonlocalCoupling() const override
Whether the simulation has active nonlocal coupling which should be accounted for in the Jacobian...
void setNeedToAddDefaultMultiAppFixedPointConvergence()
Sets _need_to_add_default_multiapp_fixed_point_convergence to true.
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...
virtual void meshDisplaced()
Update data after a mesh displaced.
virtual bool uDotDotOldRequested()
Get boolean flag to check whether old solution second time derivative needs to be stored...
void mooseDeprecated(Args &&... args) const
std::optional< ConvergenceName > _multiapp_fixed_point_convergence_name
MultiApp fixed point convergence name.
Keeps track of stuff related to assembling.
MooseAppCoordTransform & coordTransform()
virtual void setActiveFEVariableCoupleableMatrixTags(std::set< TagID > &mtags, const THREAD_ID tid) override
void setResidualObjectParamsAndLog(const std::string &ro_name, const std::string &name, InputParameters ¶ms, 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.
void setCurrentAlgebraicNodeRange(libMesh::ConstNodeRange *range)
bool _error_on_jacobian_nonzero_reallocation
Whether to error when the Jacobian is re-allocated, usually because the sparsity pattern changed...
virtual void reinitNode(const Node *node, const THREAD_ID tid) override
virtual std::size_t numNonlinearSystems() const override
virtual void predictorCleanup(NumericVector< libMesh::Number > &ghosted_solution)
Perform cleanup tasks after application of predictor to solution vector.
virtual void prepare(const Elem *elem, const THREAD_ID tid) override
bool verboseMultiApps() const
Whether or not to use verbose printing for MultiApps.
bool _has_jacobian
Indicates if the Jacobian was computed.
virtual bool haveFV() const override
returns true if this problem includes/needs finite volume functionality.
Interface for objects acting when the mesh has been displaced.
MooseObjectWarehouse< InternalSideIndicatorBase > _internal_side_indicators
bool _has_dampers
Whether or not this system has any Dampers associated with it.
std::vector< SubdomainName > _kernel_coverage_blocks
virtual void setUDotDotRequested(const bool u_dotdot_requested)
Set boolean flag to true to store solution second time derivative.
virtual Distribution & getDistribution(const std::string &name)
bool haveDisplaced() const override final
Whether we have a displaced problem in our simulation.
bool _has_nonlocal_coupling
Indicates if nonlocal coupling is required/exists.
void setCurrentAlgebraicBndNodeRange(ConstBndNodeRange *range)
This is the base class for Samplers as used within the Stochastic Tools module.
bool areCoupled(const unsigned int ivar, const unsigned int jvar, const unsigned int nl_sys_num) const
Registry class for material property IDs and names.
void setPostprocessorValueByName(const PostprocessorName &name, const PostprocessorValue &value, std::size_t t_index=0)
Set the value of a PostprocessorValue.
virtual void clearActiveScalarVariableCoupleableMatrixTags(const THREAD_ID tid) override
virtual void postExecute()
Method called at the end of the simulation.
bool isSolverSystemNonlinear(const unsigned int sys_num)
Check if the solver system is nonlinear.
void joinAndFinalize(TheWarehouse::Query query, bool isgen=false)
std::vector< MooseArray< ADRealVectorValue > > _ad_grad_zero
Warehouse for storing initial conditions.
std::vector< SolverParams > _solver_params
const std::vector< SolverSystemName > & getSolverSystemNames() const
ExecuteMooseObjectWarehouse< Control > _control_warehouse
The control logic warehouse.
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::unique_ptr< libMesh::ConstNodeRange > _current_algebraic_node_range
virtual void setActiveScalarVariableCoupleableMatrixTags(std::set< TagID > &mtags, const THREAD_ID tid) override
void setCoupling(Moose::CouplingType type)
Set the coupling between variables TODO: allow user-defined coupling.
const ExecFlagType & getCurrentExecuteOnFlag() const
Return/set the current execution flag.
unsigned int _cycles_completed
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
virtual bool uDotRequested()
Get boolean flag to check whether solution time derivative needs to be stored.
virtual void init() override
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...
virtual void needFV() override
marks this problem as including/needing finite volume functionality.
virtual void getDiracElements(std::set< const Elem *> &elems) override
Fills "elems" with the elements that should be looped over for Dirac Kernels.
void parentOutputPositionChanged()
Calls parentOutputPositionChanged() on all sub apps.
virtual void addInterfaceKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
bool _is_petsc_options_inserted
If or not PETSc options have been added to database.
void setCurrentlyComputingResidual(bool currently_computing_residual) final
Set whether or not the problem is in the process of computing the residual.
virtual void addMaterial(const std::string &material_name, const std::string &name, InputParameters ¶meters)
virtual void lineSearch()
execute MOOSE line search
virtual bool checkNonlocalCouplingRequirement() const override
virtual bool uDotDotRequested()
Get boolean flag to check whether solution second time derivative needs to be stored.
unsigned short _current_ic_state
virtual void reinitNeighborPhys(const Elem *neighbor, unsigned int neighbor_side, const std::vector< Point > &physical_points, const THREAD_ID tid) override
std::vector< MeshDisplacedInterface * > _notify_when_mesh_displaces
Objects to be notified when the mesh displaces.
void trustUserCouplingMatrix()
Whether to trust the user coupling matrix even if we want to do things like be paranoid and create a ...
virtual void newAssemblyArray(std::vector< std::shared_ptr< SolverSystem >> &solver_systems)
const bool _uo_aux_state_check
Whether or not checking the state of uo/aux evaluation.
virtual void addMeshDivision(const std::string &type, const std::string &name, InputParameters ¶ms)
Add a MeshDivision.
bool _computing_scaling_residual
Flag used to indicate whether we are computing the scaling Residual.
A struct for storing the various types of petsc options and values.
virtual void computeMarkers()
void reportMooseObjectDependency(MooseObject *a, MooseObject *b)
Register a MOOSE object dependency so we can either order operations properly or report when we canno...
void residualSetup() override
MaterialDataType
MaterialData types.
void computeUserObjectsInternal(const ExecFlagType &type, const Moose::AuxGroup &group, TheWarehouse::Query &query)
virtual bool onlyAllowDefaultNonlinearConvergence() const
Returns true if an error will result if the user supplies 'nonlinear_convergence'.
Positions objects are under the hood Reporters.
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...
std::shared_ptr< MooseObject > create(const std::string &obj_name, const std::string &name, const InputParameters ¶meters, THREAD_ID tid=0, bool print_deprecated=true)
virtual void reinitNodes(const std::vector< dof_id_type > &nodes, const THREAD_ID tid) override
virtual void updateActiveObjects()
Update the active objects in the warehouses.
Stores the stateful material properties computed by materials.
virtual void computeIndicatorsAndMarkers()
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
virtual void addJacobianOffDiagScalar(unsigned int ivar, const THREAD_ID tid=0)
virtual void setException(const std::string &message)
Set an exception, which is stored at this point by toggling a member variable in this class...
virtual void addJacobian(const THREAD_ID tid) override
virtual void addAuxScalarKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
void setErrorOnJacobianNonzeroReallocation(bool state)
PetscOptions _petsc_option_data_base
virtual const std::vector< VectorTag > & currentResidualVectorTags() const override
Return the residual vector tags we are currently computing.
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...
std::vector< VectorTag > _current_residual_vector_tags
A data member to store the residual vector tag(s) passed into computeResidualTag(s).
std::vector< SubdomainName > _material_coverage_blocks
void setSteadyStateConvergenceName(const ConvergenceName &convergence_name)
Sets the steady-state detection convergence object name if there is one.
virtual void addAuxScalarVariable(const std::string &var_name, libMesh::Order order, Real scale_factor=1., const std::set< SubdomainID > *const active_subdomains=NULL)
virtual const SystemBase & systemBaseLinear(unsigned int sys_num) const override
Get a constant base class reference to a linear system.
void logAdd(const std::string &system, const std::string &name, const std::string &type, const InputParameters ¶ms) const
Output information about the object just added to the problem.
virtual bool hasScalarVariable(const std::string &var_name) const override
Returns a Boolean indicating whether any system contains a variable with the name provided...
MultiApp Implementation for Transient Apps.
void resizeMaterialData(Moose::MaterialDataType data_type, unsigned int nqp, const THREAD_ID tid)
Resize material data.
Warehouse for storing finite volume initial conditions.
void finishMultiAppStep(ExecFlagType type, bool recurse_through_multiapp_levels=false)
Finish the MultiApp time step (endStep, postStep) associated with the ExecFlagType.
virtual void addFunctorMaterial(const std::string &functor_material_name, const std::string &name, InputParameters ¶meters)
std::vector< VariableSecond > _second_zero
std::map< SolverVariableName, unsigned int > _solver_var_to_sys_num
Map connecting variable names with their respective solver systems.
std::vector< MooseArray< ADReal > > _ad_zero
bool _requires_nonlocal_coupling
nonlocal coupling requirement flag
virtual void onTimestepEnd() override
virtual void computeNearNullSpace(libMesh::NonlinearImplicitSystem &sys, std::vector< NumericVector< libMesh::Number > *> &sp)
virtual void addNodalKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
std::vector< std::shared_ptr< SolverSystem > > _solver_systems
Combined container to base pointer of every solver system.
MaterialData & getMaterialData(Moose::MaterialDataType type, const THREAD_ID tid=0) const
All Distributions should inherit from this class.
std::vector< VectorVariableCurl > _vector_curl_zero
virtual bool hasMortarCoupling() const
Whether the simulation has mortar coupling.
Base class for user objects executed one or more sidesets, which may be on the outer boundary of the ...
bool _has_exception
Whether or not an exception has occurred.
unsigned int _num_grid_steps
Number of steps in a grid sequence.
bool _needs_old_newton_iter
Indicates that we need to compute variable values for previous Newton iteration.
bool haveXFEM()
Find out whether the current analysis is using XFEM.
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)
void registerRandomInterface(RandomInterface &random_interface, const std::string &name)
bool _has_time_integrator
Indicates whether or not this executioner has a time integrator (during setup)
This class provides an interface for common operations on field variables of both FE and FV types wit...
ExecuteMooseObjectWarehouse< MultiApp > & getMultiAppWarehouse()
virtual void addAuxKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
MaterialPropertyRegistry _material_prop_registry
void clearActiveMaterialProperties(const THREAD_ID tid)
Clear the active material properties.
virtual unsigned int nLinearIterations(const unsigned int nl_sys_num) const override
MaterialBase objects are special in that they have additional objects created automatically (see FEPr...
ExecuteMooseObjectWarehouse< TransientMultiApp > _transient_multi_apps
Storage for TransientMultiApps (only needed for calling 'computeDT')
MaterialWarehouse _interface_materials
bool hasUserObject(const std::string &name) const
Check if there if a user object of given name.
The following methods are specializations for using the libMesh::Parallel::packed_range_* routines fo...
bool _ignore_zeros_in_jacobian
Whether to ignore zeros in the Jacobian, thereby leading to a reduced sparsity pattern.
const libMesh::ConstElemRange & getCurrentAlgebraicElementRange()
These are the element and nodes that contribute to the jacobian and residual for this local processor...
void setCurrentExecuteOnFlag(const ExecFlagType &)
const MaterialWarehouse & getMaterialWarehouse() const
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.
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/bou...
const libMesh::ConstNodeRange & getCurrentAlgebraicNodeRange()
void computingScalingJacobian(bool computing_scaling_jacobian)
Setter for whether we're computing the scaling jacobian.
ExecuteMooseObjectWarehouse< Transfer > _from_multi_app_transfers
Transfers executed just after MultiApps to transfer data from them.
virtual void addKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
Base class for a system (of equations)
const InitialConditionWarehouse & getInitialConditionWarehouse() const
Return InitialCondition storage.
virtual void addAuxVariable(const std::string &var_type, const std::string &var_name, InputParameters ¶ms)
Canonical method for adding an auxiliary variable.
std::optional< ConvergenceName > _steady_state_convergence_name
Steady-state detection convergence name.
Base class for MeshDivision objects.
const MaterialPropertyStorage & getBndMaterialPropertyStorage()
bool computingNonlinearResid() const
Returns true if the problem is in the process of computing the nonlinear residual.
virtual void addFVInterfaceKernel(const std::string &fv_ik_name, const std::string &name, InputParameters ¶meters)
MeshDivision & getMeshDivision(const std::string &name, const THREAD_ID tid=0) const
Get a MeshDivision.
unsigned int getNumCyclesCompleted()
Base class for creating new nodally-based mortar user objects.
bool hasDampers()
Whether or not this system has dampers.
const Positions & getPositionsObject(const std::string &name) const
Get the Positions object by its name.
std::map< SolverSystemName, unsigned int > _solver_sys_name_to_num
Map connecting solver system names with their respective systems.
FEProblemBase(const InputParameters ¶meters)
void setFailNextNonlinearConvergenceCheck()
Skip further residual evaluations and fail the next nonlinear convergence check(s) ...
virtual Executor & getExecutor(const std::string &name)
virtual void cacheJacobianNeighbor(const THREAD_ID tid) override
Specialization of SubProblem for solving nonlinear equations plus auxiliary equations.
bool needToAddDefaultSteadyStateConvergence() const
Returns true if the problem needs to add the default steady-state detection convergence.
std::vector< std::unordered_map< BoundaryID, bool > > _bnd_mat_side_cache
Cache for calculating materials on side.
bool _have_fv
Whether we are performing some calculations with finite volume discretizations.
bool hasLinearConvergenceObjects() const
Whether we have linear convergence objects.
ExecFlagEnum _print_execution_on
When to print the execution of loops.
virtual const std::string & name() const
Get the name of the class.
virtual void setResidual(NumericVector< libMesh::Number > &residual, const THREAD_ID tid) override
bool & petscOptionsInserted()
If PETSc options are already inserted.
virtual void solve(const unsigned int nl_sys_num)
virtual void setCurrentLowerDElem(const Elem *const lower_d_elem, const THREAD_ID tid) override
Set the current lower dimensional element.
std::set< TagID > _linear_matrix_tags
Temporary storage for filtered matrix tags for linear systems.
void bumpAllQRuleOrder(libMesh::Order order, SubdomainID block)
Real computeMultiAppsDT(ExecFlagType type)
Find the smallest timestep over all MultiApps.
void setParallelBarrierMessaging(bool flag)
Toggle parallel barrier messaging (defaults to on).
const MaterialWarehouse & getRegularMaterialsWarehouse() const
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...
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
std::unique_ptr< libMesh::ConstElemRange > _nl_evaluable_local_elem_range
void projectInitialConditionOnCustomRange(libMesh::ConstElemRange &elem_range, ConstBndNodeRange &bnd_node_range)
Project initial conditions for custom elem_range and bnd_node_range This is needed when elements/boun...
virtual void computeResidualTags(const std::set< TagID > &tags)
Form multiple residual vectors and each is associated with one tag.
const bool & currentlyComputingResidual() const
Returns true if the problem is in the process of computing the residual.
void setMaterialCoverageCheck(CoverageCheckMode mode)
Set flag to indicate whether material coverage checks should be performed.
virtual void computeJacobianSys(libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &soln, libMesh::SparseMatrix< libMesh::Number > &jacobian)
Form a Jacobian matrix.
std::shared_ptr< MultiApp > getMultiApp(const std::string &multi_app_name) const
Get a MultiApp object by name.
ExecuteMooseObjectWarehouse< UserObject > _all_user_objects
virtual void reinitElemNeighborAndLowerD(const Elem *elem, unsigned int side, const THREAD_ID tid) override
bool hasSolverVariable(const std::string &var_name) const
AuxGroup
Flag for AuxKernel related execution type.
virtual void addMarker(const std::string &marker_name, const std::string &name, InputParameters ¶meters)
unsigned int subspaceDim(const std::string &prefix) const
Dimension of the subspace spanned by vectors with a given prefix.
virtual GeometricSearchData & geomSearchData() override
virtual void setUDotOldRequested(const bool u_dot_old_requested)
Set boolean flag to true to store old solution time derivative.
bool needsPreviousNewtonIteration() const
Check to see whether we need to compute the variable values of the previous Newton iterate...
virtual void addBoundaryCondition(const std::string &bc_name, const std::string &name, InputParameters ¶meters)
const libMesh::CouplingMatrix * couplingMatrix(const unsigned int nl_sys_num) const override
The coupling matrix defining what blocks exist in the preconditioning matrix.
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. ...
This class is a container/interface for the objects involved in automatic generation of mortar spaces...
virtual Assembly & assembly(const THREAD_ID tid, const unsigned int sys_num) override
const bool _skip_nl_system_check
virtual void resetState()
Reset state of this object in preparation for the next evaluation.
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 vec...
virtual void addInitialCondition(const std::string &ic_name, const std::string &name, InputParameters ¶meters)
ScalarInitialConditionWarehouse _scalar_ics
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. ...
Nonlinear system to be solved.
void skipExceptionCheck(bool skip_exception_check)
Set a flag that indicates if we want to skip exception and stop solve.
virtual void swapBackMaterialsFace(const THREAD_ID tid)
virtual void addDistribution(const std::string &type, const std::string &name, InputParameters ¶meters)
The following functions will enable MOOSE to have the capability to import distributions.
virtual void advanceState()
Advance all of the state holding vectors / datastructures so that we can move to the next timestep...
A user object that runs over all the nodes and does an aggregation step to compute a single value...
ExecuteMooseObjectWarehouse< Transfer > _transfers
Normal Transfers.
const VectorPostprocessorValue & getVectorPostprocessorValueByName(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.
MooseLinearConvergenceReason
virtual Function & getFunction(const std::string &name, const THREAD_ID tid=0)
virtual void addPredictor(const std::string &type, const std::string &name, InputParameters ¶meters)
virtual void computeJacobianBlocks(std::vector< JacobianBlock *> &blocks, const unsigned int nl_sys_num)
Computes several Jacobian blocks simultaneously, summing their contributions into smaller preconditio...
virtual void addLineSearch(const InputParameters &)
add a MOOSE line search
virtual void copySolutionsBackwards()
const ConstBndNodeRange & getCurrentAlgebraicBndNodeRange()
bool _calculate_jacobian_in_uo
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 the...
virtual void prepareFaceShapes(unsigned int var, const THREAD_ID tid) override
virtual void addPostprocessor(const std::string &pp_name, const std::string &name, InputParameters ¶meters)
virtual Real finalNonlinearResidual(const unsigned int nl_sys_num) const override
std::vector< std::shared_ptr< NonlinearSystemBase > > _nl
The nonlinear systems.
bool automaticScaling() const
Automatic scaling getter.
virtual void computeUserObjects(const ExecFlagType &type, const Moose::AuxGroup &group)
Call compute methods on UserObjects.
virtual void setActiveElementalMooseVariables(const std::set< MooseVariableFEBase *> &moose_vars, const THREAD_ID tid) override
Set the MOOSE variables to be reinited on each element.
const MaterialWarehouse & getInterfaceMaterialsWarehouse() const
std::vector< VariablePhiGradient > _grad_phi_zero
const std::vector< const MooseVariableFEBase * > & getUserObjectJacobianVariables(const THREAD_ID tid) const
const MaterialWarehouse & getDiscreteMaterialWarehouse() const
bool hasJacobian() const
Returns _has_jacobian.
void notifyWhenMeshDisplaces(MeshDisplacedInterface *mdi)
Register an object that derives from MeshDisplacedInterface to be notified when the displaced mesh ge...
void createTagSolutions()
Create extra tagged solution vectors.
std::vector< SolverSystemName > _solver_sys_names
The union of nonlinear and linear system names.
virtual void execute(const ExecFlagType &exec_type)
Convenience function for performing execution of MOOSE systems.
bool _verbose_restore
Whether or not to be verbose on solution restoration post a failed time step.
bool _previous_nl_solution_required
Indicates we need to save the previous NL iteration variable values.
bool _trust_user_coupling_matrix
Whether to trust the user coupling matrix no matter what.
const ConvergenceName & getSteadyStateConvergenceName() const
Gets the steady-state detection convergence object name.
void handleException(const std::string &calling_method)
Handle exceptions.
virtual std::vector< VariableName > getVariableNames()
Returns a list of all the variables in the problem (both from the NL and Aux systems.
ReporterData _reporter_data
void uniformRefine()
uniformly refine the problem mesh(es).
bool hasSetMultiAppFixedPointConvergenceName() const
Returns true if the problem has set the fixed point convergence name.
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.
const ReporterData & getReporterData() const
Provides const access the ReporterData object.
virtual const libMesh::CouplingMatrix & nonlocalCouplingMatrix(const unsigned i) const override
std::unique_ptr< libMesh::ConstElemRange > _current_algebraic_elem_range
const bool & _immediately_print_invalid_solution
std::vector< std::shared_ptr< Transfer > > getTransfers(ExecFlagType type, Transfer::DIRECTION direction) const
Get Transfers by ExecFlagType and direction.
bool hasSetSteadyStateConvergenceName() const
Returns true if the problem has set the steady-state detection convergence name.
virtual void addConvergence(const std::string &type, const std::string &name, InputParameters ¶meters)
Adds a Convergence object.
bool shouldPrintExecution(const THREAD_ID tid) const
Check whether the problem should output execution orders at this time.
const bool & _solve
Whether or not to actually solve the nonlinear system.
virtual const SystemBase & systemBaseSolver(const unsigned int sys_num) const override
Return the solver system object as a base class reference given the system number.
ExecuteMooseObjectWarehouse< Transfer > _to_multi_app_transfers
Transfers executed just before MultiApps to transfer data to them.
NonlinearSystemBase * _current_nl_sys
The current nonlinear system that we are solving.
MooseObjectWarehouse< Convergence > _convergences
convergence warehouse
Interface for notifications that the mesh has changed.
void setCurrentNonlinearSystem(const unsigned int nl_sys_num)
virtual std::shared_ptr< DisplacedProblem > getDisplacedProblem()
This is the common base class for the three main kernel types implemented in MOOSE, Kernel, VectorKernel and ArrayKernel.
void numGridSteps(unsigned int num_grid_steps)
Set the number of steps in a grid sequences.
Base class for convergence criteria.
bool _input_file_saved
whether input file has been written
virtual void reinitElem(const Elem *elem, const THREAD_ID tid) override
bool needSubdomainMaterialOnSide(SubdomainID subdomain_id, const THREAD_ID tid)
virtual Convergence & getConvergence(const std::string &name, const THREAD_ID tid=0) const
Gets a Convergence object.
TheWarehouse & theWarehouse() const
void createTagVectors()
Create extra tagged vectors and matrices.
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 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
void setMultiAppFixedPointConvergenceName(const ConvergenceName &convergence_name)
Sets the MultiApp fixed point convergence object name if there is one.
Moose::CouplingType _coupling
Type of variable coupling.
Every object that can be built by the factory should be derived from this class.
virtual bool shouldUpdateSolution()
Check to see whether the problem should update the solution.
const ConvergenceName & getMultiAppFixedPointConvergenceName() const
Gets the MultiApp fixed point convergence object name.
Real getTimeFromStateArg(const Moose::StateArg &state) const
Returns the time associated with the requested state.
virtual std::string solverTypeString(unsigned int solver_sys_num=0)
Return solver type as a human readable string.
const ExecFlagType EXEC_TIMESTEP_BEGIN
void executeSamplers(const ExecFlagType &exec_type)
Performs setup and execute calls for Sampler objects.
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 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).
void addOutput(const std::string &, const std::string &, InputParameters &)
Adds an Output object.
boundary_id_type BoundaryID
const MooseObjectWarehouse< InternalSideIndicatorBase > & getInternalSideIndicatorWarehouse()
virtual void setUDotRequested(const bool u_dot_requested)
Set boolean flag to true to store solution time derivative.
const bool _allow_ics_during_restart
bool constJacobian() const
Returns _const_jacobian (whether a MOOSE object has specified that the Jacobian is the same as the pr...
virtual void clearActiveFEVariableCoupleableMatrixTags(const THREAD_ID tid) override
std::vector< MeshChangedInterface * > _notify_when_mesh_changes
Objects to be notified when the mesh changes.
void checkNonlocalCoupling()
void addDefaultSteadyStateConvergence(const InputParameters ¶ms)
Adds the default steady-state detection Convergence.
VarKindType
Framework-wide stuff.
NonlinearSystemBase & currentNonlinearSystem()
void computingScalingResidual(bool computing_scaling_residual)
Setter for whether we're computing the scaling residual.
void checkDisplacementOrders()
Verify that SECOND order mesh uses SECOND order displacements.
virtual void addFunction(const std::string &type, const std::string &name, InputParameters ¶meters)
Real PostprocessorValue
various MOOSE typedefs
virtual void addJacobianNeighbor(const THREAD_ID tid) override
virtual libMesh::EquationSystems & es() override
std::vector< std::unordered_map< SubdomainID, bool > > _block_mat_side_cache
Cache for calculating materials on side.
bool hasTimeIntegrator() const
Returns whether or not this Problem has a TimeIntegrator.
std::shared_ptr< AuxiliarySystem > _aux
The auxiliary system.
TheWarehouse is a container for MooseObjects that allows querying/filtering over various customizeabl...
virtual void addVectorPostprocessor(const std::string &pp_name, const std::string &name, InputParameters ¶meters)
const bool _allow_invalid_solution
MooseMesh wraps a libMesh::Mesh object and enhances its capabilities by caching additional data and s...
virtual unsigned int currentNlSysNum() const override
const MaterialPropertyStorage & getMaterialPropertyStorage()
Return a reference to the material property storage.
virtual void computeIndicators()
bool hasInitialAdaptivity() const
Return a Boolean indicating whether initial AMR is turned on.
virtual MooseVariableScalar & getScalarVariable(const THREAD_ID tid, const std::string &var_name) override
Returns the scalar variable reference from whichever system contains it.
static void objectSetupHelper(const std::vector< T *> &objects, const ExecFlagType &exec_flag)
Helpers for calling the necessary setup/execute functions for the supplied objects.
const bool _boundary_restricted_node_integrity_check
whether to perform checking of boundary restricted nodal object variable dependencies, e.g.
virtual void setActiveScalarVariableCoupleableVectorTags(std::set< TagID > &vtags, const THREAD_ID tid) override
virtual bool uDotOldRequested()
Get boolean flag to check whether old solution time derivative needs to be stored.
virtual bool updateMeshXFEM()
Update the mesh due to changing XFEM cuts.
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.
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...
virtual void restoreSolutions()
bool fvBCsIntegrityCheck() const
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.
bool _u_dotdot_old_requested
Whether old solution second time derivative needs to be stored.
void setFailNextSystemConvergenceCheck()
Tell the problem that the system(s) cannot be considered converged next time convergence is checked...
void addAnyRedistributers()
const std::string & type() const
Get the type of this class.
bool hasPostprocessorValueByName(const PostprocessorName &name) const
Whether or not a Postprocessor value exists by a given name.
const ExecuteMooseObjectWarehouse< UserObject > & getUserObjects() const
void setAxisymmetricCoordAxis(const MooseEnum &rz_coord_axis)
void initialSetup() override
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
std::vector< VectorTag > getVectorTags(const std::set< TagID > &tag_ids) const
bool allowInvalidSolution() const
Whether to accept / allow an invalid solution.
virtual const SystemBase & systemBaseAuxiliary() const override
Return the auxiliary system object as a base class reference.
void setLinearConvergenceNames(const std::vector< ConvergenceName > &convergence_names)
Sets the linear convergence object name(s) if there is one.
void checkUserObjectJacobianRequirement(THREAD_ID tid)
MooseVariableFieldBase & getActualFieldVariable(const THREAD_ID tid, const std::string &var_name) override
Returns the variable reference for requested MooseVariableField which may be in any system...
LineSearch * getLineSearch() override
getter for the MOOSE line search
virtual void computeNullSpace(libMesh::NonlinearImplicitSystem &sys, std::vector< NumericVector< libMesh::Number > *> &sp)
virtual void addTimeIntegrator(const std::string &type, const std::string &name, InputParameters ¶meters)
LinearSystem * _current_linear_sys
The current linear system that we are solving.
virtual void cacheResidual(const THREAD_ID tid) override
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.
const bool _force_restart
void forceOutput()
Indicates that the next call to outputStep should be forced.
const VectorPostprocessor & getVectorPostprocessorObjectByName(const std::string &object_name, const THREAD_ID tid=0) const
Return the VPP object given the name.
std::vector< VariablePhiSecond > _second_phi_zero
bool _started_initial_setup
At or beyond initialSteup stage.
std::map< std::string, std::unique_ptr< RandomData > > _random_data_objects
A map of objects that consume random numbers.
bool errorOnJacobianNonzeroReallocation() const
Will return True if the user wants to get an error when a nonzero is reallocated in the Jacobian by P...
std::unique_ptr< ConstBndNodeRange > _current_algebraic_bnd_node_range
virtual void addResidual(const THREAD_ID tid) override
NonlinearSystemBase & getNonlinearSystemBase(const unsigned int sys_num)
virtual void addResidualNeighbor(const THREAD_ID tid) override
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 point...
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...
MooseApp & _app
The MOOSE application this is associated with.
Moose::CouplingType coupling() const
virtual void clearActiveFEVariableCoupleableVectorTags(const THREAD_ID tid) override
void setCouplingMatrix(std::unique_ptr< libMesh::CouplingMatrix > cm, const unsigned int nl_sys_num)
Set custom coupling matrix.
virtual void addDefaultNonlinearConvergence(const InputParameters ¶ms)
Adds the default nonlinear Convergence associated with the problem.
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...
void setNonlinearConvergenceNames(const std::vector< ConvergenceName > &convergence_names)
Sets the nonlinear convergence object name(s) if there is one.
const ExecFlagType EXEC_LINEAR
virtual bool solverSystemConverged(const unsigned int solver_sys_num) override
std::string _exception_message
The error message to go with an exception.
void setNeedToAddDefaultNonlinearConvergence()
Sets _need_to_add_default_nonlinear_convergence to true.
virtual void checkProblemIntegrity()
Method called to perform a series of sanity checks before a simulation is run.
AuxiliarySystem & getAuxiliarySystem()
virtual void updateGeomSearch(GeometricSearchData::GeometricSearchType type=GeometricSearchData::ALL) override
MooseObjectWarehouse< MeshDivision > _mesh_divisions
Warehouse to store mesh divisions NOTE: this could probably be moved to the MooseMesh instead of the ...
virtual void addConstraint(const std::string &c_name, const std::string &name, InputParameters ¶meters)
MooseObjectWarehouse< Indicator > _indicators
virtual void addMultiApp(const std::string &multi_app_name, const std::string &name, InputParameters ¶meters)
Add a MultiApp to the problem.
virtual void prepareAssembly(const THREAD_ID tid) override
bool haveADObjects() const
Method for reading wehther we have any ad objects.
unsigned int systemNumForVariable(const VariableName &variable_name) const
bool _checking_uo_aux_state
Flag used to indicate whether we are doing the uo/aux state check in execute.
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.
bool _fv_bcs_integrity_check
Whether to check overlapping Dirichlet and Flux BCs and/or multiple DirichletBCs per sideset...
const MooseObjectWarehouse< Indicator > & getIndicatorWarehouse()
Return indicator/marker storage.
InitialConditions are objects that set the initial value of variables.
bool showInvalidSolutionConsole() const
Whether or not to print out the invalid solutions summary table in console.
Base class for user objects executed on all element sides internal to one or more blocks...
virtual void initNullSpaceVectors(const InputParameters ¶meters, std::vector< std::shared_ptr< NonlinearSystemBase >> &nl)
virtual void setCurrentSubdomainID(const Elem *elem, const THREAD_ID tid) override
bool getFailNextSystemConvergenceCheck() const
Whether it will fail the next system convergence check(s), triggering failed step behavior...
virtual void clearDiracInfo() override
Gets called before Dirac Kernels are asked to add the points they are supposed to be evaluated in...
virtual void addIndicator(const std::string &indicator_name, const std::string &name, InputParameters ¶meters)
virtual void reinitNodesNeighbor(const std::vector< dof_id_type > &nodes, const THREAD_ID tid) override
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.
GeometricSearchType
Used to select groups of geometric search objects to update.
void backupMultiApps(ExecFlagType type)
Backup the MultiApps associated with the ExecFlagType.
The SolutionInvalidity will contain all the information about the occurrence(s) of solution invalidit...
virtual void addVariable(const std::string &var_type, const std::string &var_name, InputParameters ¶ms)
Canonical method for adding a non-linear variable.
const std::vector< LinearSystemName > & getLinearSystemNames() const
ExecuteMooseObjectWarehouse< MultiApp > _multi_apps
MultiApp Warehouse.
virtual int & timeStep() const
virtual Moose::FEBackend feBackend() const
LinearSystem & getLinearSystem(unsigned int sys_num)
Get non-constant reference to a linear system.
std::vector< std::vector< std::unique_ptr< Assembly > > > _assembly
The Assembly objects.
virtual void addDisplacedProblem(std::shared_ptr< DisplacedProblem > displaced_problem)
void computeResidual(libMesh::NonlinearImplicitSystem &sys, const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual)
This function is called by Libmesh to form a residual.
static void objectExecuteHelper(const std::vector< T *> &objects)
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.
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.
void setCoordSystem(const std::vector< SubdomainName > &blocks, const MultiMooseEnum &coord_sys)
Materials compute MaterialProperties.
virtual void swapBackMaterialsNeighbor(const THREAD_ID tid)
const bool _show_invalid_solution_console
virtual void addLinearFVKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
std::unique_ptr< libMesh::ConstElemRange > _aux_evaluable_local_elem_range
virtual NonlinearSystem & getNonlinearSystem(const unsigned int sys_num)
bool _snesmf_reuse_base
If or not to resuse the base vector for matrix-free calculation.
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.
void setKernelCoverageCheck(bool flag)
Set flag to indicate whether kernel coverage checks should be performed.
This is the XFEMInterface class.
bool _need_to_add_default_multiapp_fixed_point_convergence
Flag that the problem needs to add the default fixed point convergence.
const std::vector< NonlinearSystemName > _nl_sys_names
The nonlinear system names.
const ExecFlagType EXEC_NONLINEAR
std::vector< Real > VectorPostprocessorValue
const FVInitialConditionWarehouse & getFVInitialConditionWarehouse() const
Return FVInitialCondition storage.
virtual void updateMortarMesh()
void addDefaultMultiAppFixedPointConvergence(const InputParameters ¶ms)
Adds the default fixed point Convergence associated with the problem.
std::set< TagID > _fe_matrix_tags
virtual void addAuxArrayVariable(const std::string &var_name, const libMesh::FEType &type, unsigned int components, const std::set< SubdomainID > *const active_subdomains=NULL)
const ExecuteMooseObjectWarehouse< Transfer > & getMultiAppTransferWarehouse(Transfer::DIRECTION direction) const
Return the complete warehouse for MultiAppTransfer object for the given direction.
virtual const SystemBase & getSystemBase(const unsigned int sys_num) const
Get constant reference to a system in this problem.
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 isSNESMFReuseBaseSetbyUser()
Return a flag to indicate if _snesmf_reuse_base is set by users.
virtual void addReporter(const std::string &type, const std::string &name, InputParameters ¶meters)
Add a Reporter object to the simulation.
virtual void swapBackMaterials(const THREAD_ID tid)
std::vector< VariablePhiValue > _phi_zero
InitialConditionWarehouse _ics
std::vector< unsigned char > _has_active_material_properties
Whether there are active material properties on each thread.
const SubdomainID ANY_BLOCK_ID
MaterialWarehouse _discrete_materials
bool _reinit_displaced_face
Whether to call DisplacedProblem::reinitElemFace when this->reinitElemFace is called.
void setSinglePetscOption(const std::string &name, const std::string &value="", FEProblemBase *const problem=nullptr)
A wrapper function for dealing with different versions of PetscOptionsSetValue.
virtual void addDGKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
virtual void setCurrentBoundaryID(BoundaryID bid, const THREAD_ID tid) override
sets the current boundary ID in assembly
SolverSystem * _current_solver_sys
The current solver system.
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
virtual std::shared_ptr< const DisplacedProblem > getDisplacedProblem() const
Takes care of everything related to mesh adaptivity.
std::optional< std::vector< ConvergenceName > > _nonlinear_convergence_names
Nonlinear system(s) convergence name(s)
Generic class for solving transient nonlinear problems.
void setConstJacobian(bool state)
Set flag that Jacobian is constant (for optimization purposes)
Class for containing MooseEnum item information.
unsigned int solverSysNum(const SolverSystemName &solver_sys_name) const override
Base class for Control objects.
std::shared_ptr< MaterialBase > getMaterial(std::string name, Moose::MaterialDataType type, const THREAD_ID tid=0, bool no_warn=false)
Return a pointer to a MaterialBase object.
std::vector< VariableGradient > _grad_zero
bool hasActiveObjects(THREAD_ID tid=0) const
void clearCurrentJacobianMatrixTags()
Clear the current Jacobian matrix tag data structure ...
virtual void subdomainSetup(SubdomainID subdomain, const THREAD_ID tid)
virtual void restoreOldSolutions()
Restore old solutions from the backup vectors and deallocate them.
unsigned int getInitialSteps() const
Pull out the number of initial steps previously set by calling init()
void reinitMaterials(SubdomainID blk_id, const THREAD_ID tid, bool swap_stateful=true)
const bool _identify_variable_groups_in_nl
Whether to identify variable groups in nonlinear systems. This affects dof ordering.
PetscOptions & petscOptionsDatabase()
bool acceptInvalidSolution() const
Whether or not to accept the solution based on its invalidity.
const AutomaticMortarGeneration & getMortarInterface(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 ...
const bool _restore_original_nonzero_pattern
Whether we should restore the original nonzero pattern for every Jacobian evaluation.
void execMultiAppTransfers(ExecFlagType type, Transfer::DIRECTION direction)
Execute MultiAppTransfers associated with execution flag and direction.
void restoreMultiApps(ExecFlagType type, bool force=false)
Restore the MultiApps associated with the ExecFlagType.
virtual void addLinearFVBC(const std::string &fv_bc_name, const std::string &name, InputParameters ¶meters)
void customSetup(const ExecFlagType &exec_type) override
void setRestartFile(const std::string &file_name)
Communicate to the Resurector the name of the restart filer.
void setCurrentLinearSystem(unsigned int sys_num)
Set the current linear system pointer.
void executeControls(const ExecFlagType &exec_type)
Performs setup and execute calls for Control objects.
MortarData & mortarData()
virtual std::vector< std::shared_ptr< UserObject > > addUserObject(const std::string &user_object_name, const std::string &name, InputParameters ¶meters)
Query query()
query creates and returns an initialized a query object for querying objects from the warehouse...
void allowOutput(bool state)
Ability to enable/disable output calls This is private, users should utilize FEProblemBase::allowOutp...
virtual void onTimestepBegin() override
virtual void computeBounds(libMesh::NonlinearImplicitSystem &sys, NumericVector< libMesh::Number > &lower, NumericVector< libMesh::Number > &upper)
Nonlinear system to be solved.
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)
void checkDuplicatePostprocessorVariableNames()
void computeResidualAndJacobian(const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual, libMesh::SparseMatrix< libMesh::Number > &jacobian)
Form a residual and Jacobian with default tags.
std::vector< std::pair< MooseVariableFEBase *, MooseVariableFEBase * > > & nonlocalCouplingEntries(const THREAD_ID tid, const unsigned int nl_sys_num)
bool _using_ad_mat_props
Automatic differentiaion (AD) flag which indicates whether any consumer has requested an AD material ...
std::vector< VariableValue > _scalar_zero
virtual Real computeResidualL2Norm()
Computes the residual using whatever is sitting in the current solution vector then returns the L2 no...
const std::vector< LinearSystemName > _linear_sys_names
The linear system names.
std::shared_ptr< XFEMInterface > getXFEM()
Get a pointer to the XFEM controller object.
bool getFailNextNonlinearConvergenceCheck() const
Whether it will skip further residual evaluations and fail the next nonlinear convergence check(s) ...
void incrementMultiAppTStep(ExecFlagType type)
Advance the MultiApps t_step (incrementStepOrReject) associated with the ExecFlagType.
Class for scalar variables (they are different).
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.
void bumpVolumeQRuleOrder(libMesh::Order order, SubdomainID block)
Increases the element/volume quadrature order for the specified mesh block if and only if the current...
const bool _material_dependency_check
Determines whether a check to verify material dependencies on every subdomain.
std::vector< std::vector< const MooseVariableFEBase * > > _uo_jacobian_moose_vars
virtual MooseMesh & mesh() override
std::vector< VariableValue > _zero
unsigned int linearSysNum(const LinearSystemName &linear_sys_name) const override
LinearSystem & currentLinearSystem()
Get a non-constant reference to the current linear system.
void resetFailNextSystemConvergenceCheck()
Tell the problem that the system convergence check(s) may proceed as normal.
libMesh::EquationSystems & es()
std::set< TagID > _fe_vector_tags
void mooseError(Args &&... args) const
Emits an error prefixed with object name and type.
void addObjectParamsHelper(InputParameters ¶ms, 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().
Base class for deriving any boundary condition of a integrated type.
SolverParams & solverParams(unsigned int solver_sys_num=0)
Get the solver parameters.
SolverSystem & getSolverSystem(unsigned int sys_num)
Get non-constant reference to a solver system.
virtual void saveOldSolutions()
Allocate vectors and save old solutions into them.
virtual void computeTransposeNullSpace(libMesh::NonlinearImplicitSystem &sys, std::vector< NumericVector< libMesh::Number > *> &sp)
bool hasPostprocessor(const std::string &name) const
Deprecated.
virtual bool updateSolution(NumericVector< libMesh::Number > &vec_solution, NumericVector< libMesh::Number > &ghosted_solution)
Update the solution.
std::shared_ptr< DisplacedProblem > _displaced_problem
GeometricSearchData _geometric_search_data
const InputParameters & parameters() const
Get the parameters of the object.
State argument for evaluating functors.
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
virtual Real & timeOld() const
Proxy for accessing MaterialPropertyStorage.
std::vector< VectorVariableValue > _vector_zero
bool hasMultiApp(const std::string &name) const
bool _u_dot_old_requested
Whether old solution time derivative needs to be stored.
bool ignoreZerosInJacobian() const
Will return true if zeros in the Jacobian are to be dropped from the sparsity pattern.
std::vector< std::unique_ptr< libMesh::CouplingMatrix > > _cm
Coupling matrix for variables.
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)
bool needInterfaceMaterialOnSide(BoundaryID bnd_id, const THREAD_ID tid)
void reinitElemFace(const Elem *elem, unsigned int side, BoundaryID, const THREAD_ID tid)
Linear system to be solved.
bool needToAddDefaultNonlinearConvergence() const
Returns true if the problem needs to add the default nonlinear convergence.
std::optional< std::vector< ConvergenceName > > _linear_convergence_names
Linear system(s) convergence name(s) (if any)
bool useSNESMFReuseBase()
Return a flag that indicates if we are reusing the vector base.
std::vector< std::shared_ptr< T > > addObject(const std::string &type, const std::string &name, InputParameters ¶meters, const bool threaded=true, const std::string &var_param_name="variable")
Method for creating and adding an object to the warehouse.
bool _has_initialized_stateful
Whether nor not stateful materials have been initialized.
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...
virtual void setResidualNeighbor(NumericVector< libMesh::Number > &residual, const THREAD_ID tid) override
QueryCache & condition(Args &&... args)
Adds a new condition to the query.
unsigned int _max_qps
Maximum number of quadrature points used in the problem.
void setMaterialCoverageCheck(bool flag)
Set flag to indicate whether material coverage checks should be performed.
static InputParameters validParams()
virtual void addScalarKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
TheWarehouse & theWarehouse()
bool _preserve_matrix_sparsity_pattern
Whether to preserve the system matrix / Jacobian sparsity pattern, using 0-valued entries usually...
Base class for implementing interface user objects.
virtual unsigned int nNonlinearIterations(const unsigned int nl_sys_num) const override
CoverageCheckMode _material_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active material...
virtual std::size_t numLinearSystems() const override
MaterialPropertyStorage & _neighbor_material_props
const std::size_t _num_linear_sys
The number of linear systems.
std::map< std::string, unsigned int > _subspace_dim
Dimension of the subspace spanned by the vectors with a given prefix.
ReporterData & getReporterData(ReporterData::WriteKey)
Provides non-const access the ReporterData object that is used to store reporter values.
const libMesh::ConstElemRange & getEvaluableElementRange()
In general, {evaluable elements} >= {local elements} U {algebraic ghosting elements}.
const bool _use_hash_table_matrix_assembly
Whether to assemble matrices using hash tables instead of preallocating matrix memory.
bool restoreOriginalNonzeroPattern() const
const UserObject & getUserObjectBase(const std::string &name, const THREAD_ID tid=0) const
Get the user object by its name.
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type...
bool _has_internal_edge_residual_objects
Whether the problem has dgkernels or interface kernels.
bool computingScalingJacobian() const override final
Getter for whether we're computing the scaling jacobian.
bool execMultiApps(ExecFlagType type, bool auto_advance=true)
Execute the MultiApps associated with the ExecFlagType.
ExecuteMooseObjectWarehouse< Control > & getControlWarehouse()
Reference to the control logic warehouse.
const std::unordered_map< std::pair< BoundaryID, BoundaryID >, AutomaticMortarGeneration > & getMortarInterfaces(bool on_displaced) const
const ExecFlagType EXEC_SUBDOMAIN
virtual ArrayMooseVariable & getArrayVariable(const THREAD_ID tid, const std::string &var_name) override
Returns the variable reference for requested ArrayMooseVariable which may be in any system...
const MooseObjectWarehouse< Marker > & getMarkerWarehouse()
bool _has_constraints
Whether or not this system has any Constraints.
virtual bool isTransient() const override
bool _need_to_add_default_nonlinear_convergence
Flag that the problem needs to add the default nonlinear convergence.
bool hasMultiApps() const
Returns whether or not the current simulation has any multiapps.
virtual void reinitNeighbor(const Elem *elem, unsigned int side, const THREAD_ID tid) override
void notifyWhenMeshChanges(MeshChangedInterface *mci)
Register an object that derives from MeshChangedInterface to be notified when the mesh changes...
void setSNESMFReuseBase(bool reuse, bool set_by_user)
If or not to reuse the base vector for matrix-free calculation.
std::unique_ptr< libMesh::ConstElemRange > _evaluable_local_elem_range
bool computingScalingResidual() const override final
virtual void executeAllObjects(const ExecFlagType &exec_type)
CoverageCheckMode _kernel_coverage_check
Determines whether and which subdomains are to be checked to ensure that they have an active kernel...
virtual void setActiveFEVariableCoupleableVectorTags(std::set< TagID > &vtags, const THREAD_ID tid) override
bool _fail_next_system_convergence_check
std::vector< std::shared_ptr< LinearSystem > > _linear_systems
The vector of linear systems.
std::shared_ptr< XFEMInterface > _xfem
Pointer to XFEM controller.
const bool _boundary_restricted_elem_integrity_check
whether to perform checking of boundary restricted elemental object variable dependencies, e.g.
virtual void prepareShapes(unsigned int var, const THREAD_ID tid) override
void reinitMaterialsInterface(BoundaryID boundary_id, const THREAD_ID tid, bool swap_stateful=true)
bool _const_jacobian
true if the Jacobian is constant
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.
virtual void solveLinearSystem(const unsigned int linear_sys_num, const Moose::PetscSupport::PetscOptions *po=nullptr)
Build and solve a linear system.
virtual void computeUserObjectByName(const ExecFlagType &type, const Moose::AuxGroup &group, const std::string &name)
Compute an user object with the given name.
const MaterialPropertyRegistry & getMaterialPropertyRegistry() const
virtual void possiblyRebuildGeomSearchPatches()
std::set< TagID > _linear_vector_tags
Temporary storage for filtered vector tags for linear systems.
A MultiApp represents one or more MOOSE applications that are running simultaneously.
bool checkingUOAuxState() const
Return a flag to indicate whether we are executing user objects and auxliary kernels for state check ...
const libMesh::ConstElemRange & getNonlinearEvaluableElementRange()
MaterialPropertyStorage & _material_props
Base class for Postprocessors that produce a vector of values.
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 depend...
virtual void addFVKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
virtual void addFVBC(const std::string &fv_bc_name, const std::string &name, InputParameters ¶meters)
libMesh::Order _max_scalar_order
Maximum scalar variable order.
virtual void addGhostedBoundary(BoundaryID boundary_id) override
Will make sure that all necessary elements from boundary_id are ghosted to this processor.
virtual bool hasFunction(const std::string &name, const THREAD_ID tid=0)
Adaptivity & adaptivity()
bool hasActiveMaterialProperties(const THREAD_ID tid) const
Method to check whether or not a list of active material roperties has been set.
ExecuteMooseObjectWarehouse< Transfer > _between_multi_app_transfers
Transfers executed just before MultiApps to transfer data between them.
bool hasUOAuxStateCheck() const
Whether or not MOOSE will perform a user object/auxiliary kernel state check.
virtual void cacheJacobian(const THREAD_ID tid) override
void jacobianSetup() override
virtual std::size_t numSolverSystems() const override
virtual void addHDGKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
Executor * getExecutor() const
virtual Real & dt() const
void advanceMultiApps(ExecFlagType type)
Deprecated method; use finishMultiAppStep and/or incrementMultiAppTStep depending on your purpose...
bool immediatelyPrintInvalidSolution() const
Whether or not the solution invalid warnings are printed out immediately.
Restartable::ManagedValue< RestartableEquationSystems > _req
The EquationSystems object, wrapped for restart.
virtual unsigned int currentLinearSysNum() const override
std::vector< libMesh::CouplingMatrix > _nonlocal_cm
nonlocal coupling matrix
virtual void reinitNodeFace(const Node *node, BoundaryID bnd_id, const THREAD_ID tid) override
virtual void reinitOffDiagScalars(const THREAD_ID tid) override
virtual void reinitElemPhys(const Elem *elem, const std::vector< Point > &phys_points_in_elem, const THREAD_ID tid) override
std::vector< std::unordered_map< BoundaryID, bool > > _interface_mat_side_cache
Cache for calculating materials on interface.
virtual void addJacobianNeighborLowerD(const THREAD_ID tid) override
virtual void prepareNeighborShapes(unsigned int var, const THREAD_ID tid) override
MooseObjectWarehouse< Marker > _markers
FVInitialConditionWarehouse _fv_ics
void setVerboseProblem(bool verbose)
Make the problem be verbose.
virtual void setNeighborSubdomainID(const Elem *elem, unsigned int side, const THREAD_ID tid) override
virtual bool hasException()
Whether or not an exception has occurred.
virtual void initialAdaptMesh()
virtual void addResidualScalar(const THREAD_ID tid=0)
const bool _using_default_nl
Boolean to check if we have the default nonlinear system.
MaterialWarehouse _all_materials
bool _u_dotdot_requested
Whether solution second time derivative needs to be stored.
virtual void addCachedResidual(const THREAD_ID tid) override
A system that holds auxiliary variables.
Moose::PetscSupport::PetscOptions _petsc_options
PETSc option storage.
Crank-Nicolson time integrator.
virtual const std::vector< std::shared_ptr< Convergence > > & getConvergenceObjects(const THREAD_ID tid=0) const
Gets the Convergence objects.
bool preserveMatrixSparsityPattern() const
Will return True if the executioner in use requires preserving the sparsity pattern of the matrices b...
virtual void clearActiveElementalMooseVariables(const THREAD_ID tid) override
Clear the active elemental MooseVariableFEBase.
Base class for user-specific data.
void allowOutput(bool state)
Ability to enable/disable all output calls.
virtual Sampler & getSampler(const std::string &name, const THREAD_ID tid=0)
virtual void outputStep(ExecFlagType type)
Output the current step.
virtual unsigned int nlSysNum(const NonlinearSystemName &nl_sys_name) const override
OutputWarehouse & getOutputWarehouse()
Get the OutputWarehouse objects.
MooseEnum _verbose_setup
Whether or not to be verbose during setup.
bool needToAddDefaultMultiAppFixedPointConvergence() const
Returns true if the problem needs to add the default fixed point convergence.
void setIgnoreZerosInJacobian(bool state)
Set whether the zeros in the Jacobian should be dropped from the sparsity pattern.
void computeSystems(const ExecFlagType &type)
Do generic system computations.
virtual void computeJacobianTags(const std::set< TagID > &tags)
Form multiple matrices, and each is associated with a tag.
MooseMesh * _displaced_mesh
bool _has_mortar
Whether the simulation requires mortar coupling.
libMesh::Order getMaxScalarOrder() const
void execTransfers(ExecFlagType type)
Execute the Transfers associated with the ExecFlagType.
const std::vector< ConvergenceName > & getLinearConvergenceNames() const
Gets the linear convergence object name(s).
virtual void ghostGhostedBoundaries() override
Causes the boundaries added using addGhostedBoundary to actually be ghosted.
The Executor class directs the execution flow of simulations.
MaterialWarehouse _materials
virtual void addJacobianScalar(const THREAD_ID tid=0)
const MaterialPropertyStorage & getNeighborMaterialPropertyStorage()
virtual void addDiracKernel(const std::string &kernel_name, const std::string &name, InputParameters ¶meters)
MooseObjectWarehouse< IntegratedBCBase > _nonlocal_integrated_bcs
nonlocal integrated_bcs
virtual const MooseMesh & mesh() const override
virtual void computeResidualTag(const NumericVector< libMesh::Number > &soln, NumericVector< libMesh::Number > &residual, TagID tag)
Form a residual vector for a given tag.
virtual bool startedInitialSetup()
Returns true if we are in or beyond the initialSetup stage.
virtual VectorMooseVariable & getVectorVariable(const THREAD_ID tid, const std::string &var_name) override
Returns the variable reference for requested VectorMooseVariable which may be in any system...
std::shared_ptr< LineSearch > _line_search
void initXFEM(std::shared_ptr< XFEMInterface > xfem)
Create XFEM controller object.
Base class for all Transfer objects.
virtual void neighborSubdomainSetup(SubdomainID subdomain, const THREAD_ID tid)
virtual void addCachedJacobian(const THREAD_ID tid) override
virtual void sizeZeroes(unsigned int size, const THREAD_ID tid)
virtual Real computeDamping(const NumericVector< libMesh::Number > &soln, const NumericVector< libMesh::Number > &update)
std::vector< Real > _real_zero
Convenience zeros.
MooseObjectWarehouse< KernelBase > _nonlocal_kernels
nonlocal kernels
void checkCoordinateSystems()
Verify that there are no element type/coordinate type conflicts.
unsigned int getMaxQps() const
const ExecFlagType EXEC_INITIAL
bool _verbose_multiapps
Whether or not to be verbose with multiapps.
This is a helper class for managing the storage of declared Reporter object values.