HyperHDG
file.hxx
Go to the documentation of this file.
1 #pragma once // Ensure that file is included only once in a single compilation.
2 
3 #include <HyperHDG/dense_la.hxx>
4 #include <HyperHDG/hy_assert.hxx>
7 
8 namespace Geometry
9 {
10 /*!*************************************************************************************************
11  * \brief Hypergraph geometry based on an input file.
12  *
13  * The geometry class File is a set of hyperedges. Each of these tensorial hyperedges is represented
14  * by its vertices (given within the file). For consistency, it is assumed that the vertices are
15  * given in lexicographical order. Also the hypernodes are assumed to be given in lexicographical
16  * order to ensure that geometry and topology of all hyperedges fit.
17  *
18  * \tparam hyEdge_dimT Dimension of a hyperedge, i.e., 1 is for PDEs defined on graphs, 2 is
19  * for PDEs defined on surfaces, and 3 is for PDEs defined on volumes.
20  * \tparam space_dimT The dimension of the space, the object is located in. This number should
21  * be larger than or equal to hyEdge_dimT.
22  * \tparam vectorT The typename of the large vector type. Defaults to std::vector.
23  * \tparam pointT The typename of a Point class. Defaults to \c Point<space_dimT, float>.
24  * \tparam mapping_tM The mapping which should depened on the aforementioned three template
25  * arguments. Default is linear mapping.
26  * \tparam hyEdge_dimTM Dimension of a hyperedge, i.e., 1 is for PDEs defined on graphs, 2 is
27  * for PDEs defined on surfaces, and 3 is for PDEs defined on volumes.
28  * Template parameter for the mapping which defaults to hyEdge_dimT.
29  * \tparam space_dimTM The dimension of the space, the object is located in. This number should
30  * be larger than or equal to hyEdge_dimT.
31  * Template parameter for the mapping which defaults to space_dimT.
32  * \tparam pt_coord_tM The floating point type in which points/vertices are represented.
33  * Default is the floating point of the point class.
34  * Template parameter for the mapping which defaults to pt_coord_t.
35  * \tparam hyEdge_index_t The index type for hyperedges. Default is \c unsigned \c int.
36  * \tparam hyNode_index_t The index type for hypernodes. Default is \c hyNode_index_t.
37  * \tparam pt_index_t The index type of points. Default is \c hyNode_index_t.
38  *
39  * \authors Guido Kanschat, Heidelberg University, 2019--2020.
40  * \authors Andreas Rupp, Heidelberg University, 2019--2020.
41  **************************************************************************************************/
42 template <unsigned int hyEdge_dimT,
43  unsigned int space_dimT,
44  template <typename...> typename vectorT = std::vector,
45  typename pointT = Point<space_dimT, float>,
46  template <unsigned int, unsigned int, typename> typename mapping_tM = Mapping::Linear,
47  unsigned int hyEdge_dimTM = hyEdge_dimT,
48  unsigned int space_dimTM = space_dimT,
49  typename pt_coord_tM = typename pointT::value_type,
50  typename hyEdge_index_t = unsigned int,
51  typename hyNode_index_t = hyEdge_index_t,
52  typename pt_index_t = hyNode_index_t>
53 class File
54 {
55  /*!***********************************************************************************************
56  * \brief The point type is the floating point type of \c pointT.
57  ************************************************************************************************/
58  using pt_coord_t = typename pointT::value_type;
59  /*!***********************************************************************************************
60  * \brief The mapping type is \c mapping_tt with given template parameters.
61  ************************************************************************************************/
62  using mapping_t = mapping_tM<hyEdge_dimTM, space_dimTM, pt_coord_tM>;
63  /*!***********************************************************************************************
64  * \brief Definition of the geometry of a hypergraph's edges.
65  ************************************************************************************************/
66  class hyEdge
67  {
68  public:
69  /*!*********************************************************************************************
70  * \brief Return dimension of the hyperedge.
71  **********************************************************************************************/
72  static constexpr unsigned int hyEdge_dim() { return hyEdge_dimT; }
73  /*!*********************************************************************************************
74  * \brief Return dimension of the surrounding space.
75  **********************************************************************************************/
76  static constexpr unsigned int space_dim() { return space_dimT; }
77 
78  private:
79  /*!*********************************************************************************************
80  * \brief Reference to parent hypergraph.
81  **********************************************************************************************/
83  /*!*********************************************************************************************
84  * \brief Index of the hyperedge within the hypergraph.
85  **********************************************************************************************/
86  const hyEdge_index_t index_;
87  /*!*********************************************************************************************
88  * \brief Hold an instance of a mapping type to be able to calculate normals and so on.
89  **********************************************************************************************/
91  /*!*********************************************************************************************
92  * \brief Return vertex of specified index of a hyperedge.
93  **********************************************************************************************/
94  pointT point(const unsigned int pt_index) const
95  {
98  .points_hyEdge[index_ / hyGraph_geometry_.n_loc_ref_elem][pt_index]];
99  }
100 
101  public:
102  /*!*********************************************************************************************
103  * \brief Construct hyperedge from hypergraph and index.
104  **********************************************************************************************/
105  hyEdge(const File& hyGraph_geometry, const hyEdge_index_t index)
106  : hyGraph_geometry_(hyGraph_geometry), index_(index)
107  {
108  Point<space_dimT, pt_coord_t> translation = point(0);
110  for (unsigned int dim = 0; dim < hyEdge_dimT; ++dim)
111  matrix.set_column(dim, point(1 << dim) - translation);
112 
116  for (unsigned int dim = 0; dim < hyEdge_dimT; ++dim)
117  translation += (pt_coord_t)Wrapper::interior_coordinate(elem, dim) * matrix.get_column(dim);
118 
119  mapping = mapping_t(translation, matrix);
120  }
121  /*!*********************************************************************************************
122  * \brief Map n_vec points from reference to physical element.
123  *
124  * \param points Matrix whose columns consist of the points to be mapped.
125  * \retval phy_points Matrix whose columns consist of the mapped points.
126  **********************************************************************************************/
127  template <unsigned int n_vec>
129  const SmallMat<hyEdge_dimT, n_vec, pt_coord_t>& points) const
130  {
131  for (unsigned int i = 0; i < points.size(); ++i)
132  hy_assert(points[i] >= 0. && points[i] <= 1., "Point must lie in reference square!");
133  return mapping.map_reference_to_physical(points);
134  }
135  /*!*********************************************************************************************
136  * \brief Map n_vec points from reference to physical element.
137  *
138  * \param points Matrix whose columns consist of the points to be mapped.
139  * \retval points Matrix whose columns consist of the mapped points.
140  **********************************************************************************************/
141  template <unsigned int n_vec>
144  {
145  for (unsigned int i = 0; i < points.size(); ++i)
146  hy_assert(points[i] >= 0. && points[i] <= 1., "Point must lie in reference square!");
147  points = mapping.map_reference_to_physical(points);
148  return points;
149  }
150  /*!*********************************************************************************************
151  * \brief Return matrix column of the affine-linear transformation.
152  *
153  * \param index Index of the matrix column to be returned.
154  * \retval column The specified matrix column.
155  **********************************************************************************************/
157  {
158  hy_assert(index < hyEdge_dimT, "There are only " << hyEdge_dimT << " spanning vectors.");
159  return mapping.get_column(index);
160  }
161  /*!*********************************************************************************************
162  * \brief Return reduced matrix R of the QR decomposition.
163  **********************************************************************************************/
164  const SmallSquareMat<hyEdge_dimT, pt_coord_t>& mat_r() const { return mapping.mat_r(); }
165  /*!*********************************************************************************************
166  * \brief Return matrix Q of the QR decomposition of the linear transoformation.
167  **********************************************************************************************/
168  const SmallSquareMat<space_dimT, pt_coord_t> mat_q() const { return mapping.mat_q(); }
169  /*!*********************************************************************************************
170  * \brief Return Haussdorff/Lebesque measure of the hyperedge.
171  **********************************************************************************************/
172  pt_coord_t area() const { return std::abs(mapping.functional_determinant_hyEdge()); }
173  /*!*********************************************************************************************
174  * \brief Return Haussdorff measure of the specified hypernode.
175  **********************************************************************************************/
176  pt_coord_t face_area(const unsigned int index) const
177  {
178  hy_assert(index < 2 * hyEdge_dimT, "A hyperedge has 2 * dim(hyEdge) faces.");
179  return std::abs(mapping.functional_determinant_hyNode(index / 2));
180  }
181  /*!*********************************************************************************************
182  * \brief Return local normal of given index.
183  *
184  * Return outer unit normal with respect to the hypernode which is spanned by the vectors
185  * spanning the phyiscal element, orthogonally projected to a hyEdge_dimT dimensional space,
186  * but the vector of the given index. This is an element of the same dimension as the
187  * reference element.
188  **********************************************************************************************/
190  {
191  hy_assert(index < 2 * hyEdge_dimT, "A hyperedge has 2 * dim(hyEdge) inner normals.");
192  Point<hyEdge_dimT, pt_coord_t> normal = mapping.local_normal(index / 2);
193  if (index % 2 == 1)
194  normal *= -1.;
195  return normal;
196  }
197  /*!*********************************************************************************************
198  * \brief Return inner normal of given index.
199  *
200  * Return outer unit normal with respect to the hypernode which is spanned by all vectors
201  * spanning the phyiscal element, but the vector of the given index. The vector has to be in
202  * the span of the columns of the local transformation matrix. This is an element of the same
203  * dimension as the full space.
204  **********************************************************************************************/
206  {
207  hy_assert(index < 2 * hyEdge_dimT, "A hyperedge has 2 * dim(hyEdge) inner normals.");
208  Point<space_dimT, pt_coord_t> normal = mapping.inner_normal(index / 2);
209  if (index % 2 == 1)
210  normal *= -1.;
211  return normal;
212  }
213  /*!*********************************************************************************************
214  * \brief Return barycenter of face of given index.
215  **********************************************************************************************/
217  {
218  hy_assert(index < 2 * hyEdge_dimT, "A hyperedge has 2 * dim(hyEdge) inner normals.");
219  Point<hyEdge_dimT, pt_coord_t> local_center(0.5);
220  local_center[index / 2] = index % 2 ? 1. : 0.;
221  return map_ref_to_phys(local_center);
222  }
223  /*!*********************************************************************************************
224  * \brief Return outer normal of given index.
225  *
226  * Return unit normal with respect to the hyperedge within the full space.
227  **********************************************************************************************/
229  {
230  hy_assert(index < space_dimT - hyEdge_dimT,
231  "This function returns one of the dim(space) - dim(hyEdge) orthonormal vectors "
232  << "which are orthogonal to the hyperedge.");
233  return mapping.outer_normal(index);
234  }
235  /*!*********************************************************************************************
236  * \brief Return lexicographically ordered equidistant tensorial point of given index.
237  **********************************************************************************************/
238  template <unsigned int n_sub_points, typename one_dim_float_t>
240  unsigned int index,
241  const SmallVec<n_sub_points, one_dim_float_t>& points_1d) const
242  {
243  static_assert(n_sub_points > 0, "No subpoints do not make sense!");
244  hy_assert(index < std::pow(n_sub_points, hyEdge_dimT),
245  "The index must not exceed the number of prescribed lexicographic points.");
247  for (unsigned int dim = 0; dim < hyEdge_dimT; ++dim)
248  {
249  pt[dim] = (pt_coord_t)points_1d[index % n_sub_points];
250  index /= n_sub_points;
251  }
252  return mapping.map_reference_to_physical(pt);
253  }
254  /*!*********************************************************************************************
255  * \brief Return equidistant tensorial point of given index on a given boundary (slightly
256  * moved away from the boundary using boundary_scale), ordered lexicographically.
257  **********************************************************************************************/
258  template <unsigned int n_sub_points, typename one_dim_float_t>
260  unsigned int index,
261  unsigned int boundary_number,
262  float boundary_scale,
263  const SmallVec<n_sub_points, one_dim_float_t>& points_1d) const
264  {
265  static_assert(n_sub_points > 0, "No subpoints do not make sense!");
266  hy_assert(index < std::pow(n_sub_points, hyEdge_dimT - 1) * hyEdge_dimT * 2,
267  "The index must not exceed the number of prescribed lexicographic points.");
268  Point<hyEdge_dimT - 1, pt_coord_t> subpt;
269  index = index - std::pow(n_sub_points, hyEdge_dimT - 1) * boundary_number;
270  for (unsigned int subdim = 0; subdim < hyEdge_dimT - 1; ++subdim)
271  {
272  subpt[subdim] = (pt_coord_t)points_1d[index % n_sub_points];
273  index /= n_sub_points;
274  }
276  unsigned int subd = 0;
277  for (unsigned int d = 0; d < hyEdge_dimT; d++)
278  {
279  if (boundary_number / 2 == d)
280  pt[d] = boundary_scale * (boundary_number % 2 - 0.5) + 0.5;
281  else
282  pt[d] = subpt[subd++];
283  }
284  return mapping.map_reference_to_physical(pt);
285  }
286  }; // end of class hyEdge
287 
288  public:
289  /*!***********************************************************************************************
290  * \brief Returns the template parameter representing the dimension of a hyperedge.
291  *
292  * \retval hyEdge_dimT The dimension of a hyperedge.
293  ************************************************************************************************/
294  static constexpr unsigned int hyEdge_dim() { return hyEdge_dimT; }
295  /*!***********************************************************************************************
296  * \brief Returns the template parameter representing the dimension of the space.
297  *
298  * \retval space_dimT The dimension of the space.
299  ************************************************************************************************/
300  static constexpr unsigned int space_dim() { return space_dimT; }
301 
302  private:
303  /*!***********************************************************************************************
304  * \brief Domain Info containing all the information of the hypergraph (cf. ReadDomain.hxx).
305  ************************************************************************************************/
306  const DomainInfo<hyEdge_dimT,
307  space_dimT,
308  vectorT,
309  pointT,
310  hyEdge_index_t,
311  hyNode_index_t,
312  pt_index_t>& domain_info_;
313 
314  /*!***********************************************************************************************
315  * \brief Refinment level corresponds to number of subintervals per dimension.
316  ************************************************************************************************/
317  unsigned int n_subintervals_;
318  /*!***********************************************************************************************
319  * \brief Tensor product chain complex for refined elements.
320  ************************************************************************************************/
322  /*!***********************************************************************************************
323  * \brief Number of refined elements per element.
324  ************************************************************************************************/
325  unsigned int n_loc_ref_elem;
326 
327  public:
328  /*!***********************************************************************************************
329  * \brief Defines the return value of the class.
330  *
331  * The \c class \c Geometry::File defines the geometry of the hypergraph. It "contains" the
332  * different hyperedges (that actually are constructed everytime access is needed from e.g. the
333  * solver class). Thus, its main purpose is to provide a structure that administrates the
334  * hyperedges that are the return value of this structure.
335  ************************************************************************************************/
337  /*!***********************************************************************************************
338  * \brief Define the value type of input argument for standard constructor.
339  ************************************************************************************************/
340  typedef Topology::
341  File<hyEdge_dimT, space_dimT, vectorT, pointT, hyEdge_index_t, hyNode_index_t, pt_index_t>
343  /*!***********************************************************************************************
344  * \brief Construct a hypergraph which is read from a file.
345  *
346  * Constructs a hypergraph from a \c Topology::File containing the elementens per spatial
347  * dimension which is given as by its topology.
348  *
349  * \param topology The topology of the hypergraph that has the geometry of the unit cube.
350  ************************************************************************************************/
352  : domain_info_(topology.domain_info()),
355  Wrapper::create_tpcc<hyEdge_dimT, hyEdge_dimT, TPCC::boundaries::both, hyEdge_index_t>(
356  SmallVec<hyEdge_dimT, unsigned int>(n_subintervals_))),
357  n_loc_ref_elem(Hypercube<hyEdge_dimT>::pow(n_subintervals_))
358  {
359  }
360  /*!***********************************************************************************************
361  * \brief Get geometrical hyperedge of given index.
362  *
363  * This function returns the hyperedge of the given index, i.e., it returns the geometrical
364  * hyperedge (\b not the topological information). The geometrical informatiom comprises the
365  * indices of adjacent vertices (i.e. points) and information about their respective positions.
366  * It is equivalent to \c get_hyEdge.
367  *
368  * \param index The index of the hyperedge to be returned.
369  * \retval hyperedge Geometrical information on the hyperedge (cf. \c value_type).
370  ************************************************************************************************/
371  value_type operator[](const hyEdge_index_t index) const { return get_hyEdge(index); }
372  /*!***********************************************************************************************
373  * \brief Get geometrical hyperedge of given index.
374  *
375  * This function returns the hyperedge of the given index, i.e., it returns the geometrical
376  * hyperedge (\b not the topological information). The geometrical informatiom comprises the
377  * indices of adjacent vertices (i.e. points) and information about their respective positions.
378  * It is equivalent to \c operator[].
379  *
380  * \param index The index of the hyperedge to be returned.
381  * \retval hyperedge Geometrical information on the hyperedge (cf. \c value_type).
382  ************************************************************************************************/
383  value_type get_hyEdge(const hyEdge_index_t index) const
384  {
386  "Index must be non-negative and smaller than "
387  << domain_info_.n_hyEdges << " (which is the amount of hyperedges). It was "
388  << index << "!");
389  return hyEdge(*this, index);
390  }
391  /*!***********************************************************************************************
392  * \brief Return the refinement level (equal to number of subintervals).
393  ************************************************************************************************/
394  unsigned int get_refinement() const { return n_subintervals_; }
395  /*!***********************************************************************************************
396  * \brief Set the refinement level (equal to number of subintervals).
397  ************************************************************************************************/
398  void set_refinement(unsigned int level)
399  {
400  n_subintervals_ = level;
402  Wrapper::create_tpcc<hyEdge_dimT, hyEdge_dimT, TPCC::boundaries::both, hyEdge_index_t>(
405  }
406 }; // end class File
407 
408 } // end namespace Geometry
TPCC::Element
Tensor coordinates for a facet of dimension k in the complex of dimension n.
Definition: element.h:38
Geometry::File
Hypergraph geometry based on an input file.
Definition: file.hxx:53
hy_assert.hxx
This file provides the function hy_assert.
Geometry::File::hyEdge::outer_normal
Point< space_dimT, pt_coord_t > outer_normal(const unsigned int index) const
Return outer normal of given index.
Definition: file.hxx:228
Geometry::File::hyEdge::local_normal
Point< hyEdge_dimT, pt_coord_t > local_normal(const unsigned int index) const
Return local normal of given index.
Definition: file.hxx:189
Wrapper
A namespace containing the different wrapper functions.
Definition: lapack.hxx:20
check_push_test.index
index
Definition: check_push_test.py:10
TPCC::both
@ both
Definition: lexicographic.h:11
Geometry::File::File
File(const constructor_value_type &topology)
Construct a hypergraph which is read from a file.
Definition: file.hxx:351
Geometry::File::hyEdge::boundary_lexicographic
Point< space_dimT, pt_coord_t > boundary_lexicographic(unsigned int index, unsigned int boundary_number, float boundary_scale, const SmallVec< n_sub_points, one_dim_float_t > &points_1d) const
Return equidistant tensorial point of given index on a given boundary (slightly moved away from the b...
Definition: file.hxx:259
Geometry::File::hyEdge::point
pointT point(const unsigned int pt_index) const
Return vertex of specified index of a hyperedge.
Definition: file.hxx:94
linear.hxx
Geometry
A namespace containing classes describing hypergraph geometries.
Definition: file.hxx:8
Geometry::File::domain_info_
const DomainInfo< hyEdge_dimT, space_dimT, vectorT, pointT, hyEdge_index_t, hyNode_index_t, pt_index_t > & domain_info_
Domain Info containing all the information of the hypergraph (cf. ReadDomain.hxx).
Definition: file.hxx:312
Topology::File
Hypergraph topology based on an input file.
Definition: file.hxx:43
Geometry::File::hyEdge::map_ref_to_phys
SmallMat< space_dimT, n_vec, pt_coord_t > & map_ref_to_phys(SmallMat< space_dimT, n_vec, pt_coord_t > &points) const
Map n_vec points from reference to physical element.
Definition: file.hxx:142
TPCC::boundaries
boundaries
Definition: lexicographic.h:9
Geometry::File::hyEdge::mapping
mapping_t mapping
Hold an instance of a mapping type to be able to calculate normals and so on.
Definition: file.hxx:90
Geometry::File::hyEdge::face_area
pt_coord_t face_area(const unsigned int index) const
Return Haussdorff measure of the specified hypernode.
Definition: file.hxx:176
Geometry::File::hyEdge::area
pt_coord_t area() const
Return Haussdorff/Lebesque measure of the hyperedge.
Definition: file.hxx:172
Geometry::File::tpcc_ref_elem_
Wrapper::tpcc_t< hyEdge_dimT, hyEdge_dimT, TPCC::boundaries::both, hyEdge_index_t > tpcc_ref_elem_
Tensor product chain complex for refined elements.
Definition: file.hxx:321
file.hxx
Geometry::File::get_refinement
unsigned int get_refinement() const
Return the refinement level (equal to number of subintervals).
Definition: file.hxx:394
Geometry::File::pt_coord_t
typename pointT::value_type pt_coord_t
The point type is the floating point type of pointT.
Definition: file.hxx:58
Wrapper::interior_coordinate
unsigned int interior_coordinate(const auto &elem, const unsigned int index)
Return coordinate value with respect to index-th orthonormal direction of element.
Definition: tpcc.hxx:159
Wrapper::get_element
auto get_element(const auto &tpcc, const auto index)
Return the element of given index the TPCC.
Definition: tpcc.hxx:92
SmallMat::size
static constexpr unsigned int size()
Return size a SmallMat.
Definition: dense_la.hxx:54
TPCC
Definition: combinations.h:8
Geometry::File::operator[]
value_type operator[](const hyEdge_index_t index) const
Get geometrical hyperedge of given index.
Definition: file.hxx:371
Geometry::File::hyEdge::mat_q
const SmallSquareMat< space_dimT, pt_coord_t > mat_q() const
Return matrix Q of the QR decomposition of the linear transoformation.
Definition: file.hxx:168
Geometry::File::hyEdge::index_
const hyEdge_index_t index_
Index of the hyperedge within the hypergraph.
Definition: file.hxx:86
Geometry::File::value_type
hyEdge value_type
Defines the return value of the class.
Definition: file.hxx:336
Wrapper::n_elements
index_t n_elements(const auto &tpcc)
Return the element of given index the TPCC.
Definition: tpcc.hxx:80
Mapping::Linear
Mapping of a unit hypercube to a parallelotope — can also be used for simplices.
Definition: linear.hxx:18
TPCC::Lexicographic
Lexicographic enumeration of the k-dimensional faces in a tensor product chain complex of dimension n...
Definition: lexicographic.h:44
Geometry::File::constructor_value_type
Topology::File< hyEdge_dimT, space_dimT, vectorT, pointT, hyEdge_index_t, hyNode_index_t, pt_index_t > constructor_value_type
Define the value type of input argument for standard constructor.
Definition: file.hxx:342
Geometry::File::hyEdge::hyEdge_dim
static constexpr unsigned int hyEdge_dim()
Return dimension of the hyperedge.
Definition: file.hxx:72
Geometry::File::mapping_t
mapping_tM< hyEdge_dimTM, space_dimTM, pt_coord_tM > mapping_t
The mapping type is mapping_tt with given template parameters.
Definition: file.hxx:62
Geometry::File::hyEdge::space_dim
static constexpr unsigned int space_dim()
Return dimension of the surrounding space.
Definition: file.hxx:76
Hypercube::pow
static constexpr unsigned int pow(unsigned int base)
Return n to the power dim.
Definition: hypercube.hxx:25
Geometry::File::hyEdge::lexicographic
Point< space_dimT, pt_coord_t > lexicographic(unsigned int index, const SmallVec< n_sub_points, one_dim_float_t > &points_1d) const
Return lexicographically ordered equidistant tensorial point of given index.
Definition: file.hxx:239
Geometry::File::hyEdge_dim
static constexpr unsigned int hyEdge_dim()
Returns the template parameter representing the dimension of a hyperedge.
Definition: file.hxx:294
Geometry::File::hyEdge::hyEdge
hyEdge(const File &hyGraph_geometry, const hyEdge_index_t index)
Construct hyperedge from hypergraph and index.
Definition: file.hxx:105
hy_assert
#define hy_assert(Expr, Msg)
The assertion to be used within HyperHDG — deactivate using -DNDEBUG compile flag.
Definition: hy_assert.hxx:38
dense_la.hxx
Geometry::File::hyEdge::inner_normal
Point< space_dimT, pt_coord_t > inner_normal(const unsigned int index) const
Return inner normal of given index.
Definition: file.hxx:205
Geometry::File::set_refinement
void set_refinement(unsigned int level)
Set the refinement level (equal to number of subintervals).
Definition: file.hxx:398
Geometry::File::space_dim
static constexpr unsigned int space_dim()
Returns the template parameter representing the dimension of the space.
Definition: file.hxx:300
Geometry::File::n_subintervals_
unsigned int n_subintervals_
Refinment level corresponds to number of subintervals per dimension.
Definition: file.hxx:317
diffusion_uniform.topology
topology
Definition: diffusion_uniform.py:18
Geometry::File::hyEdge::face_barycenter
Point< space_dimT, pt_coord_t > face_barycenter(const unsigned int index) const
Return barycenter of face of given index.
Definition: file.hxx:216
SmallMat::get_column
SmallMat< n_rowsT, 1, mat_entry_t > get_column(const unsigned int col) const
Return a column of a SmallMat.
Definition: dense_la.hxx:206
Wrapper::create_tpcc
tpcc_t< hyEdge_dim, space_dim, bndT, index_t > create_tpcc(const SmallVec< space_dim, index_t > &vec)
Create a tensor product chain complex.
Definition: tpcc.hxx:62
Geometry::File::n_loc_ref_elem
unsigned int n_loc_ref_elem
Number of refined elements per element.
Definition: file.hxx:325
DomainInfo
Hold all topological and geometrical information of a hypergraph.
Definition: read_domain.hxx:59
Geometry::File::hyEdge
Definition of the geometry of a hypergraph's edges.
Definition: file.hxx:66
Geometry::File::hyEdge::mat_r
const SmallSquareMat< hyEdge_dimT, pt_coord_t > & mat_r() const
Return reduced matrix R of the QR decomposition.
Definition: file.hxx:164
Geometry::File::hyEdge::hyGraph_geometry_
const File & hyGraph_geometry_
Reference to parent hypergraph.
Definition: file.hxx:82
SmallMat::set_column
void set_column(const unsigned int col, const SmallMat< n_rowsT, 1, mat_entry_t > col_vec)
Set column of a SmallMat.
Definition: dense_la.hxx:220
Geometry::File::get_hyEdge
value_type get_hyEdge(const hyEdge_index_t index) const
Get geometrical hyperedge of given index.
Definition: file.hxx:383
SmallMat
This class implements a small/dense matrix.
Definition: dense_la.hxx:34
Geometry::File::hyEdge::span_vec
SmallVec< space_dimT, pt_coord_t > span_vec(const unsigned int index) const
Return matrix column of the affine-linear transformation.
Definition: file.hxx:156
Geometry::File::hyEdge::map_ref_to_phys
SmallMat< space_dimT, n_vec, pt_coord_t > map_ref_to_phys(const SmallMat< hyEdge_dimT, n_vec, pt_coord_t > &points) const
Map n_vec points from reference to physical element.
Definition: file.hxx:128
Hypercube
Helper class containing numbers and functions related to hypercubes.
Definition: hypercube.hxx:12