59 Real
getData(
const Elem *
const elem,
const unsigned int prop_num)
const;
67 Real
getElementData(
const Elem *
const elem,
const unsigned int prop_num)
const;
75 Real
getNodeData(
const Node *
const node,
const unsigned int prop_num)
const;
84 Real
getVoronoiData(
const Point & point,
const unsigned int prop_num)
const;
92 Real
getBlockData(
const Elem *
const elem,
const unsigned int prop_num)
const;
const InputParameters & parameters() const
Get the parameters of the object.
This is a "smart" enum class intended to replace many of the shortcomings in the C++ enum type It sho...
MooseMesh wraps a libMesh::Mesh object and enhances its capabilities by caching additional data and s...
Utility class for reading delimited data (e.g., CSV data).
Read properties from file - grain, element, node or block Input file syntax: prop1 prop2 etc.
Real getData(const Elem *const elem, const unsigned int prop_num) const
This function retrieves property data for elements.
unsigned int getNumProperties() const
Returns the number of properties (columns) read in the file.
ReadTypeEnum getReadType() const
Returns the ordering of data expected in the CSV file.
Real getElementData(const Elem *const elem, const unsigned int prop_num) const
This function retrieves properties for elements, from a file that has element-based data.
virtual void execute()
Execute method.
virtual void finalize()
Finalize.
const unsigned int _rand_seed
Random seed - used for generating grain centers.
const bool _use_random_tesselation
Parameters for the nearest neighbor / grain interpolation Whether to use a random tesselation for the...
unsigned int & _current_file_index
Index of the file we last read.
Real getVoronoiData(const Point &point, const unsigned int prop_num) const
This function retrieves properties for elements from a file with nearest neighbor / grain based prope...
bool _block_zero
Do the block numbers start with zero or one?
std::vector< FileName > _prop_file_names
Name of file containing property values.
virtual ~PropertyReadFile()
BoundingBox _bounding_box
Bounding box for the mesh.
Real getNodeData(const Node *const node, const unsigned int prop_num) const
This function retrieves properties for nodes, from a file that has node-based data.
const unsigned int _ngrain
Legacy attribute to keep Grizzly functional, see idaholab/moose#19109, idaholab/Grizzly#182.
MooseUtils::DelimitedFileReader _reader
Use DelimitedFileReader to read and store data from file.
void readData()
This function reads the data from file.
virtual void initVoronoiCenterPoints()
This function generates voronoi tesselation center points Presently random generated.
virtual void initialize()
Called before execute() is ever called so that data can be cleared.
bool & _initialize_called_once
To keep track of initialization to avoid reading the files twice.
Real getBlockData(const Elem *const elem, const unsigned int prop_num) const
This function retrieves properties for elements, from a file that has block-based data.
const ReadTypeEnum _read_type
Type of read - element, grain, or block.
const unsigned int _nblock
Number of blocks (for reading a CSV file with properties ordered by blocks)
const MooseEnum _rve_type
Type of voronoi tesselation/grain structure - non-periodic default.
std::vector< Point > _center
const unsigned int _nvoronoi
Number of grains (for reading a CSV file with properties ordered by grains)
std::vector< FileName > getFileNames()
Retrieve the property file names from the parameters.
static InputParameters validParams()
Real minPeriodicDistance(const Point &, const Point &) const
This function calculates minimum distance between 2 points considering periodicity of the simulation ...
ReadTypeEnum
How data is organized in the CSV file.
const unsigned int _nprop
Class attributes useful for range-checking Number of properties in a row.
const bool _load_on_construction
Whether to read the first CSV file in the constructor or on the first initialization before execution...