00001 /*************************************************************************** 00002 lagrangemesh.h - description 00003 ------------------- 00004 begin : Fri Feb 13 2004 00005 copyright : (C) 2004 by Roman Geus 00006 email : roman.geus@psi.ch 00007 ***************************************************************************/ 00008 00009 /*************************************************************************** 00010 * * 00011 * This program is free software; you can redistribute it and/or modify * 00012 * it under the terms of the GNU General Public License as published by * 00013 * the Free Software Foundation; either version 2 of the License, or * 00014 * (at your option) any later version. * 00015 * * 00016 ***************************************************************************/ 00017 00018 #ifndef LAGRANGEMESH_H 00019 #define LAGRANGEMESH_H 00020 00021 #include <vector> 00022 #include "tetmesh/tetmesh.h" 00023 #include "tetmesh/paralleltetmesh.h" 00024 00029 class LagrangeMesh { 00030 public: 00031 LagrangeMesh(mesh::TetMesh* mesh, int order, int sym_plane_config); 00032 ~LagrangeMesh(); 00033 00037 mesh::id_t gdof(mesh::id_t ldof) const; 00038 00042 bool is_owned_gdof(mesh::id_t gdof) const; 00043 00047 mesh::id_t map_dof(mesh::id_t orig_dof) const; 00048 00053 mesh::id_t get_num_my_dofs(int order) const; 00054 00059 mesh::id_t get_num_global_mdofs(int order) const; 00060 00061 mesh::id_t get_num_global_dofs(int order) const; 00062 00063 private: // private methods 00065 void set_map(unsigned int sym_plane_config); 00066 private: // private data 00068 mesh::TetMesh* _mesh; 00070 mesh::ParallelTetMesh* _pmesh; 00072 int _order; 00074 std::vector<mesh::id_t> _map; 00076 std::vector<mesh::id_t> _nof_orig_dofs; 00078 std::vector<mesh::id_t> _nof_mapped_dofs; 00079 00081 std::vector<mesh::id_t> _num_global_dofs; 00082 00086 std::map<mesh::id_t, mesh::id_t> _mgid_map; 00087 }; 00088 00089 #endif