Go to the documentation of this file. 1 #pragma once // Ensure that file is included only once in a single compilation.
35 template <
unsigned int hyEdge_dimT,
36 unsigned int space_dimT,
37 template <
typename...>
typename vectorT = std::vector,
39 typename hyEdge_index_t =
unsigned int,
40 typename hyNode_index_t = hyEdge_index_t,
41 typename pt_index_t = hyNode_index_t,
42 typename NodeOrientationT =
SmallVec<2 * hyEdge_dimT - 2,
unsigned int> >
54 static constexpr
unsigned int n_hyNodes() {
return 2 * hyEdge_dimT; }
110 static constexpr
unsigned int hyEdge_dim() {
return hyEdge_dimT; }
114 static constexpr
unsigned int space_dim() {
return space_dimT; }
193 pt_index_t>(filename)),
245 hy_assert(index < n_hyEdges_ && index >= 0,
"Index must be non-negative and smaller than "
247 <<
" (which is the amount of hyperedges). It was "
298 Wrapper::create_tpcc<hyEdge_dimT, hyEdge_dimT, TPCC::boundaries::both, hyEdge_index_t>(
Tensor coordinates for a facet of dimension k in the complex of dimension n.
Definition: element.h:38
const value_type operator[](const hyEdge_index_t index) const
Get topological hyperedge of given index.
Definition: file.hxx:234
This file provides the function hy_assert.
const DomainInfo< hyEdge_dimT, space_dimT, vectorT, pointT, hyEdge_index_t, hyNode_index_t, pt_index_t > & domain_info() const
Return the whole domain info related to a hypergraph.
Definition: file.hxx:275
std::array< hyNode_index_t, 2 *hyEdge_dimT > hyNode_indices_
Indices of the hypernodes adjacent to the hyperedge.
Definition: file.hxx:69
unsigned int n_coarse_face
Number of refined corase faces.
Definition: file.hxx:161
static constexpr unsigned int hyEdge_dim()
Return local dimension of the hypergraph's hyperedges.
Definition: file.hxx:110
A namespace containing the different wrapper functions.
Definition: lapack.hxx:20
const value_type get_hyEdge(const hyEdge_index_t index) const
Get topological hyperedge of given index.
Definition: file.hxx:243
hyNode_index_t n_hyNodes_
Total amount of hypernodes.
Definition: file.hxx:170
index
Definition: check_push_test.py:10
unsigned int n_subintervals_
Refinment level corresponds to number of subintervals per dimension.
Definition: file.hxx:132
index_t get_index(const auto &tpcc, const auto &elem)
Return index of given element within TPCC.
Definition: tpcc.hxx:102
@ both
Definition: lexicographic.h:11
A namespace containing different classes describing hypergraph topologies.
Definition: cubic.hxx:7
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:127
const NodeOrientationT get_hyNode_oriantation(unsigned int) const
Return orienation of hypernode.
Definition: file.hxx:103
Hypergraph topology based on an input file.
Definition: file.hxx:43
index_t get_index_in_slice(const auto &tpcc, const auto &elem)
Return index of given element within TPCC.
Definition: tpcc.hxx:112
boundaries
Definition: lexicographic.h:9
unsigned int exterior_coordinate(const auto &elem, const unsigned int index)
Return coordinate value with respect to index-th orthonormal direction on element.
Definition: tpcc.hxx:150
unsigned int n_face_per_face
Number of refined faces per corase face.
Definition: file.hxx:149
This file provides the functions of the submodule TPCC.
auto get_face(const auto &elem, const unsigned int index)
Return i-th element facet.
Definition: tpcc.hxx:121
unsigned int get_refinement() const
Return the refinement level (equal to number of subintervals).
Definition: file.hxx:290
void set_refinement(unsigned int level)
Set the refinement level (equal to number of subintervals).
Definition: file.hxx:294
Definition of the topology of a hypergraph's edges.
Definition: file.hxx:48
auto tpcc_faces(const auto &elements)
Create a tensor product chain complex associated to the facets.
Definition: tpcc.hxx:72
Wrapper::tpcc_t< hyEdge_dimT - 1, hyEdge_dimT, TPCC::boundaries::none, hyNode_index_t > tpcc_ref_faces_
Tensor product chain complex for refining a hyperedge into faces.
Definition: file.hxx:141
@ none
Definition: lexicographic.h:12
File(const File< hyEdge_dimT, space_dimT > &other)
Copy constructor.
Definition: file.hxx:211
auto get_element(const auto &tpcc, const auto index)
Return the element of given index the TPCC.
Definition: tpcc.hxx:92
const File & hyGraph_topology_
Reference to parent hypergraph.
Definition: file.hxx:60
Definition: combinations.h:8
index_t n_elements(const auto &tpcc)
Return the element of given index the TPCC.
Definition: tpcc.hxx:80
const Wrapper::tpcc_t< hyEdge_dimT, hyEdge_dimT, TPCC::boundaries::both, hyNode_index_t > & tpcc_ref_elem() const
Tensor product chain complex of 'local' / refined elements.
Definition: file.hxx:283
File(const constructor_value_type &filename)
Construct a topology from a given filename.
Definition: file.hxx:186
hyEdge(const File &topology, const hyEdge_index_t index)
Construct hyperedge from hypergraph and index.
Definition: file.hxx:75
Lexicographic enumeration of the k-dimensional faces in a tensor product chain complex of dimension n...
Definition: lexicographic.h:44
const hyEdge_index_t n_hyEdges() const
Return the number of hyperedges making up the hypergraph.
Definition: file.hxx:256
DomainInfo< hyEdge_dim, space_dim, vectorT, pointT, hyEdge_index_t, hyNode_index_t, pt_index_t > read_domain(std::string filename)
General Function to read domain from input file.
Definition: read_domain.hxx:362
const auto & get_hyNode_indices() const
Return hypernodes of a hyperedge.
Definition: file.hxx:99
unsigned int n_elem_per_elem
Number of refined elements per corase element.
Definition: file.hxx:145
hyEdge value_type
Defines the return value of the class.
Definition: file.hxx:176
static constexpr unsigned int pow(unsigned int base)
Return n to the power dim.
Definition: hypercube.hxx:25
static constexpr unsigned int space_dim()
Return dimension of the surrounding space.
Definition: file.hxx:114
const hyNode_index_t n_hyNodes() const
Return the number of hypernodes making up the hypergraph.
Definition: file.hxx:262
unsigned int n_face_per_elem
Number of refined faces per corase element.
Definition: file.hxx:153
hyEdge_index_t n_hyEdges_
Total amount of hyperedges.
Definition: file.hxx:166
#define hy_assert(Expr, Msg)
The assertion to be used within HyperHDG — deactivate using -DNDEBUG compile flag.
Definition: hy_assert.hxx:38
Wrapper::tpcc_t< hyEdge_dimT, hyEdge_dimT, TPCC::boundaries::both, hyNode_index_t > tpcc_ref_elem_
Tensor product chain complex for refining a hyperedge into elements.
Definition: file.hxx:136
std::string constructor_value_type
Defines the value type of input argument for standard constructor.
Definition: file.hxx:180
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
const hyEdge_index_t index_
Index of the hyperedge within the hypergraph.
Definition: file.hxx:64
unsigned int n_coarse_elem
Number of refined corase elements.
Definition: file.hxx:157
Hold all topological and geometrical information of a hypergraph.
Definition: read_domain.hxx:59
static constexpr unsigned int n_hyNodes()
Number of hypernodes per hyperedge.
Definition: file.hxx:54
This class implements a small/dense matrix.
Definition: dense_la.hxx:34
Helper class containing numbers and functions related to hypercubes.
Definition: hypercube.hxx:12