Mundy: Multibody Nonlocal Dynamics Version of the Day
Loading...
Searching...
No Matches
mundy::mesh::FieldDeclarationT< T > Class Template Reference

#include <DeclareField.hpp>

Public Types

using field_value_typeype = T

Public Member Functions

Constructors and Assignment Operators
 FieldDeclarationT (stk::mesh::MetaData &meta_data)
 Canonical constructor.
 FieldDeclarationT (const FieldDeclarationT &)=default
 Copy/Move constructors and assignment operators.
 FieldDeclarationT (FieldDeclarationT &&)=default
FieldDeclarationToperator= (const FieldDeclarationT &)=default
FieldDeclarationToperator= (FieldDeclarationT &&)=default

Fluent interface

class FieldDeclaration
FieldDeclarationT rank (stk::mesh::EntityRank rank)
 Set the entity rank of the field (must be called before declare()).
FieldDeclarationT name (const std::string &field_name)
 Set the name of the field (must be called before declare()).
FieldDeclarationT role (Ioss::Field::RoleType field_role)
 Set the io role of the field (optional).
FieldDeclarationT output_type (stk::io::FieldOutputType output_type)
 Set the stk output type of the field (optional).
stk::mesh::Field< T > & declare ()
 Declare a field with the given stk output type and role.
stk::mesh::MetaDatameta_data () const
bool has_rank () const
bool has_name () const
bool has_role () const
bool has_output_type () const
stk::mesh::EntityRank rank_value () const
const std::string & name_value () const
Ioss::Field::RoleType role_value () const
stk::io::FieldOutputType output_type_value () const

Member Typedef Documentation

◆ field_value_typeype

template<typename T>
using mundy::mesh::FieldDeclarationT< T >::field_value_typeype = T

Constructor & Destructor Documentation

◆ FieldDeclarationT() [1/3]

template<typename T>
mundy::mesh::FieldDeclarationT< T >::FieldDeclarationT ( stk::mesh::MetaData & meta_data)
inline

◆ FieldDeclarationT() [2/3]

template<typename T>
mundy::mesh::FieldDeclarationT< T >::FieldDeclarationT ( const FieldDeclarationT< T > & )
default

◆ FieldDeclarationT() [3/3]

template<typename T>
mundy::mesh::FieldDeclarationT< T >::FieldDeclarationT ( FieldDeclarationT< T > && )
default

Member Function Documentation

◆ operator=() [1/2]

template<typename T>
FieldDeclarationT & mundy::mesh::FieldDeclarationT< T >::operator= ( const FieldDeclarationT< T > & )
default

◆ operator=() [2/2]

template<typename T>
FieldDeclarationT & mundy::mesh::FieldDeclarationT< T >::operator= ( FieldDeclarationT< T > && )
default

◆ rank()

template<typename T>
FieldDeclarationT mundy::mesh::FieldDeclarationT< T >::rank ( stk::mesh::EntityRank rank)
inline

◆ name()

template<typename T>
FieldDeclarationT mundy::mesh::FieldDeclarationT< T >::name ( const std::string & field_name)
inline

◆ role()

template<typename T>
FieldDeclarationT mundy::mesh::FieldDeclarationT< T >::role ( Ioss::Field::RoleType field_role)
inline

The typical Mundy application will label fields as TRANSIENT or MESH. Note, the NODE_COORDINATES field is special and is automatically assigned the MESH role by stk. If you attempt to give it a different role, an error will be thrown.

Possible roles include: INTERNAL, MESH, /‍**< A field which is used to define the basic geometry or topology of the model and is not normally transient in nature. Examples would be element connectivity or nodal coordinates. *‍/ ATTRIBUTE, /‍**< A field which is used to define an attribute on an EntityBlock derived class. Examples would be thickness of the elements in a shell element block or the radius of particles in a particle element block. *‍/ MAP, COMMUNICATION, MESH_REDUCTION, /‍**< A field which summarizes some non-transient data about an entity (

See also
REDUCTION). This could be an offset applied to an element block, or the units system of a model or the name of the solid model which this entity is modelling... *‍/ INFORMATION = MESH_REDUCTION, REDUCTION, /‍**< A field which typically summarizes some transient data about an entity. The size of this field is typically not proportional to the number of entities in a GroupingEntity. An example would be average displacement over a group of nodes or the kinetic energy of a model. This data is also transient. *‍/ TRANSIENT /‍**< A field which is typically calculated at multiple steps or times in an analysis. These are typically "results" data. Examples would be nodal displacement or element stress. *‍/

◆ output_type()

template<typename T>
FieldDeclarationT mundy::mesh::FieldDeclarationT< T >::output_type ( stk::io::FieldOutputType output_type)
inline

The output type for a field defines how its individual components are subscripted. For example a vector2 field with name "velocity" will have components velocity_x, velocity_y.

The possible output types and their resulting subscripting are: SCALAR, // [] VECTOR_2D, // [x, y] VECTOR_3D, // [x, y, z] FULL_TENSOR_36, // [xx, yy, zz, xy, yz, zx, yx, zy, xz] FULL_TENSOR_32, // [xx, yy, zz, xy, yx] FULL_TENSOR_22, // [xx, yy, xy, yx] FULL_TENSOR_16, // [xx, xy, yz, zx, yx, zy, xz] FULL_TENSOR_12, // [xx, xy, yx] SYM_TENSOR_33, // [xx, yy, zz, xy, yz, zx] SYM_TENSOR_31, // [xx, yy, zz, xy] SYM_TENSOR_21, // [xx, yy, xy] SYM_TENSOR_13, // [xx, xy, yz, zx] SYM_TENSOR_11, // [xx, xy] SYM_TENSOR_10, // [xx] ASYM_TENSOR_03, // [xy, yz, zx] ASYM_TENSOR_02, // [xy, yz] ASYM_TENSOR_01, // [xy] MATRIX_22, // [xx, xy, yx, yy] MATRIX_33, // [xx, xy, xz, yx, yy, yz, zx, zy, zz] QUATERNION_2D, // [s, q] QUATERNION_3D, // [x, y, z, q] CUSTOM // User-defined subscripting

◆ declare()

template<typename T>
stk::mesh::Field< T > & mundy::mesh::FieldDeclarationT< T >::declare ( )
inline

◆ meta_data()

template<typename T>
stk::mesh::MetaData & mundy::mesh::FieldDeclarationT< T >::meta_data ( ) const
inline

◆ has_rank()

template<typename T>
bool mundy::mesh::FieldDeclarationT< T >::has_rank ( ) const
inline

◆ has_name()

template<typename T>
bool mundy::mesh::FieldDeclarationT< T >::has_name ( ) const
inline

◆ has_role()

template<typename T>
bool mundy::mesh::FieldDeclarationT< T >::has_role ( ) const
inline

◆ has_output_type()

template<typename T>
bool mundy::mesh::FieldDeclarationT< T >::has_output_type ( ) const
inline

◆ rank_value()

template<typename T>
stk::mesh::EntityRank mundy::mesh::FieldDeclarationT< T >::rank_value ( ) const
inline

◆ name_value()

template<typename T>
const std::string & mundy::mesh::FieldDeclarationT< T >::name_value ( ) const
inline

◆ role_value()

template<typename T>
Ioss::Field::RoleType mundy::mesh::FieldDeclarationT< T >::role_value ( ) const
inline

◆ output_type_value()

template<typename T>
stk::io::FieldOutputType mundy::mesh::FieldDeclarationT< T >::output_type_value ( ) const
inline

◆ FieldDeclaration

template<typename T>
friend class FieldDeclaration
friend