https://mooseframework.inl.gov
GhostingUserObject.h
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 
10 #pragma once
11 
12 #include "GeneralUserObject.h"
13 
14 #include "libmesh/ghosting_functor.h"
15 
16 #include <unordered_map>
17 
18 class MooseMesh;
20 
27 {
28 public:
30 
32 
33  virtual void initialSetup() override;
34 
35  virtual void initialize() override {}
36  virtual void execute() override {}
37  virtual void finalize() override {}
38 
39  virtual void meshChanged() override;
40 
41  Real getElementalValue(const Elem * elem,
43  processor_id_type pid) const;
44 
45 private:
47  std::vector<processor_id_type> _pids;
48 
53  std::vector<std::unordered_map<processor_id_type, libMesh::GhostingFunctor::map_type>> _maps;
54 
57 };
std::vector< std::unordered_map< processor_id_type, libMesh::GhostingFunctor::map_type > > _maps
Ghost Functor maps Dimension one: Map type (Geometric, Algebraic) Dimension two: Proc ID -> Map Dimen...
std::vector< processor_id_type > _pids
The PID to show the ghosting for.
RelationshipManagerType
Main types of Relationship Managers.
Definition: MooseTypes.h:963
virtual void execute() override
Execute method.
virtual void initialSetup() override
Gets called at the beginning of the simulation before this object is asked to do its job...
Real getElementalValue(const Elem *elem, Moose::RelationshipManagerType rm_type, processor_id_type pid) const
The main MOOSE class responsible for handling user-defined parameters in almost every MOOSE system...
This object loops over all of the underlying ghosting functors added by libMesh or MOOSE through Rela...
Nonlinear system to be solved.
uint8_t processor_id_type
GhostingUserObject(const InputParameters &parameters)
MooseMesh wraps a libMesh::Mesh object and enhances its capabilities by caching additional data and s...
Definition: MooseMesh.h:88
virtual void finalize() override
Finalize.
virtual void meshChanged() override
Called on this object when the mesh changes.
NonlinearSystemBase & _nl
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
virtual void initialize() override
Called before execute() is ever called so that data can be cleared.
static InputParameters validParams()
const InputParameters & parameters() const
Get the parameters of the object.