https://mooseframework.inl.gov
ProjectedMaterialPropertyNodalPatchRecoveryAux.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://mooseframework.inl.gov
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
12 
14 
17 {
19  params.addRequiredParam<unsigned int>("component",
20  "Serial access component for the recovered type");
21  return params;
22 }
23 
25  const InputParameters & parameters)
26  : NodalPatchRecoveryAuxBase(parameters),
27  _npr(getUserObject<ProjectedStatefulMaterialNodalPatchRecoveryBase>("nodal_patch_recovery_uo")),
28  _component(getParam<unsigned int>("component"))
29 {
30  // Check user object block restriction for consistency
31  if (!isBlockSubset(_npr.blockIDs()))
32  paramError("nodal_patch_recovery_uo",
33  "Nodal patch recovery auxiliary kernel is not defined in a subset of blocks of the "
34  "associated user object. Revise your input file.");
35 }
36 
37 Real
39 {
41 }
virtual Real nodalPatchRecovery() override
Override this to get the fitted value from a Nodal Patch Recovery User Object.
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:435
const Node *const & _current_node
Current node (valid only for nodal kernels)
Definition: AuxKernel.h:214
const ProjectedStatefulMaterialNodalPatchRecoveryBase & _npr
User object holding the data needed for patch recovery.
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
virtual const std::set< SubdomainID > & blockIDs() const
Return the block subdomain ids for this object Note, if this is not block restricted, this function returns all mesh subdomain ids.
std::vector< dof_id_type > _elem_ids
local patch of elements used for recovery
void addRequiredParam(const std::string &name, const std::string &doc_string)
This method adds a parameter and documentation string to the InputParameters object that will be extr...
static InputParameters validParams()
bool isBlockSubset(const std::set< SubdomainID > &ids) const
Test if the class block ids are a subset of the supplied objects.
registerMooseObject("MooseApp", ProjectedMaterialPropertyNodalPatchRecoveryAux)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const unsigned int _component
Property component (index into a serialized representation of the property)
virtual Real nodalPatchRecovery(const Point &p, const std::vector< dof_id_type > &elem_ids, std::size_t component) const =0
void ErrorVector unsigned int