Sierra Toolkit  Version of the Day
Gmesh_STKmesh_Fixture.hpp
1 #ifndef stk_io_util_Gmesh_STKmesh_Fixture_hpp
2 #define stk_io_util_Gmesh_STKmesh_Fixture_hpp
3 
4 #include <stk_util/parallel/Parallel.hpp>
5 #include <stk_mesh/base/Types.hpp>
6 #include <stk_mesh/fem/FEMMetaData.hpp>
7 #include <stk_mesh/base/BulkData.hpp>
8 #include <stk_io/MeshReadWriteUtils.hpp>
9 
10 #include <vector>
11 #include <string>
12 
13 namespace stk_classic {
14 namespace io {
15 namespace util {
16 
22 {
23  public:
24 
34  Gmesh_STKmesh_Fixture(stk_classic::ParallelMachine comm, const std::string& gmesh_spec);
35 
40  void commit();
41 
47  size_t getSurfElemCount(size_t surf_id) const;
48 
57  std::pair<int, double> getSurfCoordInfo(size_t surf_id) const;
58 
62  size_t getSideCount() const;
63 
67  size_t getElemCount() const;
68 
72  size_t getNodeCount() const;
73 
77  const std::vector<std::string> & getSidesetNames() const
78  { return m_sideset_names; }
79 
84  { return m_sideset_parts; }
85 
93  { return m_meta_data.get_meta_data(m_meta_data); }
94 
95  const stk_classic::mesh::fem::FEMMetaData & getFEMMetaData() const
96  { return m_meta_data; }
97 
98  stk_classic::mesh::fem::FEMMetaData & getFEMMetaData()
99  { return m_meta_data; }
100 
105  { return m_bulk_data; }
106 
108  { return m_bulk_data; }
109 
110  private:
113 
115  stk_classic::mesh::BulkData m_bulk_data;
116 
122  stk_classic::io::MeshData m_mesh_data;
123 
125  std::vector<std::string> m_sideset_names;
126 
128  stk_classic::mesh::PartVector m_sideset_parts;
129 
131  int m_num_x;
132 
134  int m_num_y;
135 
137  int m_num_z;
138 };
139 
140 }//namespace util
141 }//namespace io
142 }//namespace stk_classic
143 
144 #endif
stk_classic::io::util::Gmesh_STKmesh_Fixture::getSideParts
const stk_classic::mesh::PartVector & getSideParts() const
Definition: Gmesh_STKmesh_Fixture.hpp:83
stk_classic::io::util::Gmesh_STKmesh_Fixture
Definition: Gmesh_STKmesh_Fixture.hpp:21
stk_classic::ParallelMachine
MPI_Comm ParallelMachine
Definition: Parallel.hpp:32
stk_classic::io::util::Gmesh_STKmesh_Fixture::commit
void commit()
Definition: Gmesh_STKmesh_Fixture.cpp:62
stk_classic::io::util::Gmesh_STKmesh_Fixture::getMetaData
stk_classic::mesh::MetaData & getMetaData()
Definition: Gmesh_STKmesh_Fixture.hpp:92
stk_classic::mesh::fem::FEMMetaData::get_meta_data
static MetaData & get_meta_data(FEMMetaData &fem_meta)
Getter for MetaData off of a FEMMetaData object.
Definition: FEMMetaData.hpp:113
stk_classic::io::util::Gmesh_STKmesh_Fixture::getElemCount
size_t getElemCount() const
Definition: Gmesh_STKmesh_Fixture.cpp:138
stk_classic::io::util::Gmesh_STKmesh_Fixture::getSurfElemCount
size_t getSurfElemCount(size_t surf_id) const
Definition: Gmesh_STKmesh_Fixture.cpp:71
stk_classic
Sierra Toolkit.
Definition: AlgorithmRunner.cpp:16
stk_classic::mesh::MetaData
The manager of an integrated collection of parts and fields.
Definition: MetaData.hpp:56
stk_classic::mesh::PartVector
std::vector< Part * > PartVector
Collections of parts are frequently maintained as a vector of Part pointers.
Definition: Types.hpp:31
stk_classic::io::util::Gmesh_STKmesh_Fixture::Gmesh_STKmesh_Fixture
Gmesh_STKmesh_Fixture(stk_classic::ParallelMachine comm, const std::string &gmesh_spec)
Definition: Gmesh_STKmesh_Fixture.cpp:25
stk_classic::io::util::Gmesh_STKmesh_Fixture::getNodeCount
size_t getNodeCount() const
Definition: Gmesh_STKmesh_Fixture.cpp:145
stk_classic::io::util::Gmesh_STKmesh_Fixture::getBulkData
const stk_classic::mesh::BulkData & getBulkData() const
Definition: Gmesh_STKmesh_Fixture.hpp:104
stk_classic::io::util::Gmesh_STKmesh_Fixture::getSideCount
size_t getSideCount() const
Definition: Gmesh_STKmesh_Fixture.cpp:131
stk_classic::io::util::Gmesh_STKmesh_Fixture::getSurfCoordInfo
std::pair< int, double > getSurfCoordInfo(size_t surf_id) const
Definition: Gmesh_STKmesh_Fixture.cpp:98
stk_classic::io::util::Gmesh_STKmesh_Fixture::getSidesetNames
const std::vector< std::string > & getSidesetNames() const
Definition: Gmesh_STKmesh_Fixture.hpp:77
stk_classic::mesh::fem::FEMMetaData
FEMMetaData is a class that implements a Finite Element Method skin on top of the Sierra Tool Kit Met...
Definition: FEMMetaData.hpp:54
stk_classic::mesh::BulkData
Manager for an integrated collection of entities, entity relations, and buckets of field data.
Definition: BulkData.hpp:49