25 "The FeatureFloodCount UserObject to get values from.",
26 "Use \"flood_counter\" instead.");
28 "The FeatureFloodCount UserObject to get values from.");
29 params.
addParam<
unsigned int>(
"map_index",
30 "The index of which map to retrieve values from when "
31 "using FeatureFloodCount with multiple maps.");
32 MooseEnum field_display(
"UNIQUE_REGION VARIABLE_COLORING GHOSTED_ENTITIES HALOS CENTROID "
33 "ACTIVE_BOUNDS INTERSECTS_SPECIFIED_BOUNDARY",
37 "Determines how the auxilary field should be colored. "
38 "(UNIQUE_REGION and VARIABLE_COLORING are nodal, CENTROID is "
39 "elemental, default: UNIQUE_REGION)");
49 _var_idx(isParamValid(
"map_index") ? getParam<unsigned
int>(
"map_index")
50 :
std::numeric_limits<
std::size_t>::max()),
58 "UNIQUE_REGION, VARIABLE_COLORING, GHOSTED_ENTITIES and HALOS must be on variable "
59 "types that match the entity mode of the FeatureFloodCounter");
62 _field_type == FieldType::INTERSECTS_SPECIFIED_BOUNDARY))
64 "The selected option is only available for elemental aux variables");
72 case FieldType::UNIQUE_REGION:
73 case FieldType::VARIABLE_COLORING:
74 case FieldType::GHOSTED_ENTITIES:
75 case FieldType::HALOS:
76 case FieldType::CENTROID:
77 case FieldType::INTERSECTS_SPECIFIED_BOUNDARY:
82 case FieldType::ACTIVE_BOUNDS:
85 _value = std::count_if(var_to_features.begin(),
86 var_to_features.end(),
87 [](
unsigned int feature_id)
88 { return feature_id != FeatureFloodCount::invalid_id; });
94 paramError(
"field_display",
"Unimplemented type");
registerMooseObject("PhaseFieldApp", FeatureFloodCountAux)
const ExecFlagType EXEC_TIMESTEP_END
const ExecFlagType EXEC_INITIAL
void ErrorVector unsigned int
const Elem *const & _current_elem
const Node *const & _current_node
static InputParameters validParams()
Function auxiliary value.
virtual void precalculateValue() override
const FieldType _field_type
Real _value
precalculated element value
virtual Real computeValue() override
FeatureFloodCountAux(const InputParameters ¶meters)
const std::size_t _var_idx
static InputParameters validParams()
Factory constructor, takes parameters so that all derived classes can be built using the same constru...
const FeatureFloodCount & _flood_counter
Function being used to compute the value of this kernel.
This object will mark nodes or elements of continuous regions all with a unique number for the purpos...
virtual Real getEntityValue(dof_id_type entity_id, FieldType field_type, std::size_t var_index=0) const
virtual const std::vector< unsigned int > & getVarToFeatureVector(dof_id_type elem_id) const
Returns a list of active unique feature ids for a particular element.
void paramError(const std::string ¶m, Args... args) const