MOAB: Mesh Oriented datABase
(version 5.2.1)
|
00001 #ifndef SPHERE_DECOMP_HPP 00002 #define SPHERE_DECOMP_HPP 00003 00004 #include "moab/Interface.hpp" 00005 00006 class SphereDecomp 00007 { 00008 public: 00009 SphereDecomp( moab::Interface* impl ); 00010 00011 moab::ErrorCode build_sphere_mesh( const char* sphere_radii_tag_name, moab::EntityHandle* hex_set = NULL ); 00012 00013 private: 00014 //! compute subdivision vertices on entities of specified dimension 00015 moab::ErrorCode compute_nodes( const int dim ); 00016 00017 //! subdivide tets based on subdiv vertices, returning in lists according 00018 //! to whether they're inside or outside spheres 00019 moab::ErrorCode build_hexes( std::vector< moab::EntityHandle >& sphere_hexes, 00020 std::vector< moab::EntityHandle >& interstic_hexes ); 00021 00022 //! subdivide an individual tet 00023 moab::ErrorCode subdivide_tet( moab::EntityHandle tet, std::vector< moab::EntityHandle >& sphere_hexes, 00024 std::vector< moab::EntityHandle >& interstic_hexes ); 00025 00026 //! retrieve the subdivision vertices for a given entity in a given tet, 00027 //! placing them in the array oriented wrt the tet 00028 moab::ErrorCode retrieve_subdiv_verts( moab::EntityHandle tet, moab::EntityHandle this_ent, 00029 const moab::EntityHandle* tet_conn, const int dim, 00030 moab::EntityHandle* subdiv_verts ); 00031 00032 //! tag used to hold sphere radii (assigned to vertices) 00033 moab::Tag sphereRadiiTag; 00034 00035 //! used to store subdiv vertices for a given d>0 entity 00036 moab::Tag subdivVerticesTag; 00037 00038 //! MOAB interface ptr 00039 moab::Interface* mbImpl; 00040 }; 00041 #endif