https://mooseframework.inl.gov
ComputeGrainCenterUserObject.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 "ElementUserObject.h"
13 
14 // Forward Declarations
15 
20 {
21 public:
23 
25 
26  virtual void initialize();
27  virtual void execute();
28  virtual void threadJoin(const UserObject & y);
29  virtual void finalize();
30 
31  const std::vector<Real> & getGrainVolumes() const;
32  const std::vector<Point> & getGrainCenters() const;
33 
34 protected:
35  unsigned int _qp;
36  unsigned int _ncrys;
37  const std::vector<const VariableValue *> _vals;
38  unsigned int _ncomp;
40  std::vector<Real> _grain_data;
41  std::vector<Real> _grain_volumes;
42  std::vector<Point> _grain_centers;
44 };
std::vector< Real > _grain_data
storing volumes and centers of all the grains
virtual void threadJoin(const UserObject &y)
This UserObject computes a volumes and centers of grains.
const std::vector< double > y
const std::vector< Real > & getGrainVolumes() const
const std::vector< const VariableValue * > _vals
const std::vector< Point > & getGrainCenters() const
ComputeGrainCenterUserObject(const InputParameters &parameters)
const InputParameters & parameters() const