www.mooseframework.org
DiscreteNucleationMap.h
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 #ifndef DISCRETENUCLEATIONMAP_H
8 #define DISCRETENUCLEATIONMAP_H
9 
10 #include "ElementUserObject.h"
12 
14 
15 template <>
16 InputParameters validParams<DiscreteNucleationMap>();
17 
23 class DiscreteNucleationMap : public ElementUserObject
24 {
25 public:
26  DiscreteNucleationMap(const InputParameters & parameters);
27 
28  virtual void initialize();
29  virtual void execute();
30  virtual void threadJoin(const UserObject & y);
31  virtual void finalize() {}
32 
33  virtual void meshChanged();
34 
35  const std::vector<Real> & nuclei(const Elem *) const;
36 
37 protected:
40 
43 
45  std::vector<Real> _elem_map;
46 
48  std::vector<Real> _zero_map;
49 
52 
54  int _periodic;
55 
57  const Real _radius;
58 
60  const Real _int_width;
61 
64 
67  using NucleusMap = std::unordered_map<dof_id_type, std::vector<Real>>;
70 };
71 
72 #endif // DISCRETENUCLEATIONMAP_H
This UserObject maintains a per QP map that indicates if a nucleus is present or not.
bool _mesh_changed
Did the mesh change since the last execution of this PP?
virtual void threadJoin(const UserObject &y)
int _periodic
variable number to use for minPeriodicDistance calls (i.e. use the periodicity of this variable) ...
std::unordered_map< dof_id_type, std::vector< Real >> NucleusMap
const Real _int_width
Nucleus interface width.
const DiscreteNucleationInserter & _inserter
UserObject that manages nucleus insertin and deletion.
DiscreteNucleationMap(const InputParameters &parameters)
This UserObject manages the insertion and expiration of nuclei in the simulation domain it manages a ...
std::vector< NucleusLocation > NucleusList
Every MPI task should keep a full list of nuclei (in case they cross domains with their finite radii)...
InputParameters validParams< DiscreteNucleationMap >()
std::vector< Real > _zero_map
Dummy map for elements without nuclei.
const Real _radius
Nucleus radius.
std::vector< Real > _elem_map
Buffer for building the per QP map.
bool _rebuild_map
Do we need to rebuild the map during this timestep?
const DiscreteNucleationInserter::NucleusList & _nucleus_list
list of nuclei maintained bu the inserter object
const std::vector< Real > & nuclei(const Elem *) const