https://mooseframework.inl.gov
Loading...
Searching...
No Matches
GrainTrackerInterface.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 "InputParameters.h"
13#include "FeatureFloodCount.h"
14
15// Forward declarations
16
21{
22public:
24
34 virtual Real getEntityValue(dof_id_type entity_id,
36 std::size_t var_index = 0) const = 0;
37
43 virtual const std::vector<unsigned int> & getVarToFeatureVector(dof_id_type elem_id) const = 0;
44
49 virtual unsigned int getFeatureVar(unsigned int feature_id) const = 0;
50
57 virtual std::size_t getNumberActiveGrains() const = 0;
58
64 virtual std::size_t getTotalFeatureCount() const = 0;
65
69 virtual Point getGrainCentroid(unsigned int grain_id) const = 0;
70
74 virtual bool doesFeatureIntersectBoundary(unsigned int grain_id) const = 0;
75
79 virtual std::vector<unsigned int> getNewGrainIDs() const;
80};
This class defines the interface for the GrainTracking objects.
static InputParameters validParams()
virtual bool doesFeatureIntersectBoundary(unsigned int grain_id) const =0
Returns a Boolean indicating whether this grain is in contact with any boundary of the domain.
virtual unsigned int getFeatureVar(unsigned int feature_id) const =0
Return the variable index (typically order parameter) for the given feature.
virtual std::vector< unsigned int > getNewGrainIDs() const
This method returns all of the new ids generated in an invocation of the GrainTracker.
virtual std::size_t getTotalFeatureCount() const =0
Returns a number large enough to contain the largest ID for all grains in use.
virtual const std::vector< unsigned int > & getVarToFeatureVector(dof_id_type elem_id) const =0
Returns a list of active unique feature ids for a particular element.
virtual Point getGrainCentroid(unsigned int grain_id) const =0
Returns the centroid for the given grain number.
virtual Real getEntityValue(dof_id_type entity_id, FeatureFloodCount::FieldType, std::size_t var_index=0) const =0
Accessor for retrieving either nodal or elemental information (unique grains or variable indicies)
virtual std::size_t getNumberActiveGrains() const =0
Returns the number of active grains current stored in the GrainTracker.