Loading [MathJax]/extensions/tex2jax.js
ug4
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
dof_index_storage.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2013-2015: G-CSC, Goethe University Frankfurt
3 * Author: Andreas Vogel
4 *
5 * This file is part of UG4.
6 *
7 * UG4 is free software: you can redistribute it and/or modify it under the
8 * terms of the GNU Lesser General Public License version 3 (as published by the
9 * Free Software Foundation) with the following additional attribution
10 * requirements (according to LGPL/GPL v3 §7):
11 *
12 * (1) The following notice must be displayed in the Appropriate Legal Notices
13 * of covered and combined works: "Based on UG4 (www.ug4.org/license)".
14 *
15 * (2) The following notice must be displayed at a prominent place in the
16 * terminal output of covered works: "Based on UG4 (www.ug4.org/license)".
17 *
18 * (3) The following bibliography is recommended for citation and must be
19 * preserved in all covered files:
20 * "Reiter, S., Vogel, A., Heppner, I., Rupp, M., and Wittum, G. A massively
21 * parallel geometric multigrid solver on hierarchically distributed grids.
22 * Computing and visualization in science 16, 4 (2013), 151-164"
23 * "Vogel, A., Reiter, S., Rupp, M., Nägel, A., and Wittum, G. UG4 -- a novel
24 * flexible software system for simulating pde based models on high performance
25 * computers. Computing and visualization in science 16, 4 (2013), 165-179"
26 *
27 * This program is distributed in the hope that it will be useful,
28 * but WITHOUT ANY WARRANTY; without even the implied warranty of
29 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 * GNU Lesser General Public License for more details.
31 */
32
33#ifndef __H__UG__LIB_DISC__DOF_MANAGER__DOF_INDEX_STORAGE__
34#define __H__UG__LIB_DISC__DOF_MANAGER__DOF_INDEX_STORAGE__
35
37
38namespace ug{
39
41{
42 public:
45
47
48 public:
52
55 size_t& obj_index(GridObject* obj);
56 inline size_t& obj_index(Vertex* vrt) {return m_aaIndexVRT[vrt];}
57 inline size_t& obj_index(Edge* ed) {return m_aaIndexEDGE[ed];}
58 inline size_t& obj_index(Face* face) {return m_aaIndexFACE[face];}
59 inline size_t& obj_index(Volume* vol) {return m_aaIndexVOL[vol];}
61
64 const size_t& obj_index(GridObject* obj) const;
65 inline const size_t& obj_index(Vertex* vrt) const {return m_aaIndexVRT[vrt];}
66 inline const size_t& obj_index(Edge* ed) const {return m_aaIndexEDGE[ed];}
67 inline const size_t& obj_index(Face* face) const {return m_aaIndexFACE[face];}
68 inline const size_t& obj_index(Volume* vol) const {return m_aaIndexVOL[vol];}
70
71 protected:
73 void init_attachments();
74
76 void clear_attachments();
77
78 protected:
81
85
93
101};
102
103} // end namespace ug
104
105
106#endif /* __H__UG__LIB_DISC__DOF_MANAGER__DOF_INDEX_STORAGE__ */
Definition smart_pointer.h:296
Definition smart_pointer.h:108
A generic specialization of IAttachment.
Definition attachment_pipe.h:263
Definition dof_distribution_info.h:152
Definition dof_index_storage.h:41
edge_attachment_accessor_type m_aaIndexEDGE
Definition dof_index_storage.h:97
const size_t & obj_index(Volume *vol) const
Definition dof_index_storage.h:68
vertex_attachment_accessor_type m_aaIndexVRT
Definition dof_index_storage.h:96
void clear_attachments()
removes the attachments
Definition dof_index_storage.cpp:73
Grid::AttachmentAccessor< Vertex, ADoF > vertex_attachment_accessor_type
Definition dof_index_storage.h:88
size_t & obj_index(Face *face)
Definition dof_index_storage.h:58
SmartPtr< MultiGrid > m_spMG
Multi Grid.
Definition dof_index_storage.h:80
size_t & obj_index(Edge *ed)
Definition dof_index_storage.h:57
const size_t & obj_index(Face *face) const
Definition dof_index_storage.h:67
volume_attachment_accessor_type m_aaIndexVOL
Definition dof_index_storage.h:99
size_t & obj_index(GridObject *obj)
Definition dof_index_storage.cpp:87
Grid::AttachmentAccessor< Edge, ADoF > edge_attachment_accessor_type
Definition dof_index_storage.h:89
ADoF m_aIndex
Definition dof_index_storage.h:84
const size_t & obj_index(Edge *ed) const
Definition dof_index_storage.h:66
SmartPtr< MultiGrid > multi_grid()
returns the multigrid
Definition dof_index_storage.h:50
void init_attachments()
initializes the attachments
Definition dof_index_storage.cpp:52
Grid::AttachmentAccessor< Face, ADoF > face_attachment_accessor_type
Definition dof_index_storage.h:90
size_t & obj_index(Vertex *vrt)
Definition dof_index_storage.h:56
~DoFIndexStorage()
Definition dof_index_storage.cpp:47
ConstSmartPtr< MultiGrid > multi_grid() const
Definition dof_index_storage.h:51
face_attachment_accessor_type m_aaIndexFACE
Definition dof_index_storage.h:98
size_t & obj_index(Volume *vol)
Definition dof_index_storage.h:59
Grid::AttachmentAccessor< Volume, ADoF > volume_attachment_accessor_type
Definition dof_index_storage.h:91
const size_t & obj_index(Vertex *vrt) const
Definition dof_index_storage.h:65
ug::Attachment< size_t > ADoF
Attachment type.
Definition dof_index_storage.h:83
Base-class for edges.
Definition grid_base_objects.h:397
Faces are 2-dimensional objects.
Definition grid_base_objects.h:510
the generic attachment-accessor for access to grids attachment pipes.
Definition grid.h:182
The base class for all geometric objects, such as vertices, edges, faces, volumes,...
Definition grid_base_objects.h:157
Base-class for all vertex-types.
Definition grid_base_objects.h:231
Volumes are 3-dimensional objects.
Definition grid_base_objects.h:754
the ug namespace