BELFEM 0.9.0
Berkeley Lab Finite Element Framework
Loading...
Searching...
No Matches
cl_Edge.hpp
Go to the documentation of this file.
1/*
2 * BELFEM -- The Berkeley Lab Finite Element Framework
3 * Copyright (c) 2026, The Regents of the University of California,
4 * through Lawrence Berkeley National Laboratory (subject to receipt of any required
5 * approvals from the U.S. Dept. of Energy). All rights reserved.
6 *
7 * Developers: Christian Messe, Gregory Giard
8 *
9 * See the top-level LICENSE file for the complete license and disclaimer.
10 */
11
12#ifndef BELFEM_CL_EDGE_HPP
13#define BELFEM_CL_EDGE_HPP
14
15#include "typedefs.hpp"
16#include "assert.hpp"
17#include "cl_Cell.hpp"
18#include "cl_Vertex.hpp"
19
20namespace belfem
21{
22 namespace mesh
23 {
24//-----------------------------------------------------------------------------
25
29 class Edge : public Vertex
30 {
31 Edge * mPeriodic = nullptr;
32
33//-----------------------------------------------------------------------------
34 public:
35//-----------------------------------------------------------------------------
36
37 Edge();
38
39//-----------------------------------------------------------------------------
40
41 ~Edge() override;
42
43//-----------------------------------------------------------------------------
44
46 entity_type() const override ;
47
48//-----------------------------------------------------------------------------
49 size_t
50 memory() const ;
51
52//------------------------------------------------------------------------------
53
54 void
55 set_periodic( Edge * aEdge ) ;
56
57 Edge *
58 periodic() ;
59
60 const Edge *
61 periodic() const ;
62
63 bool
64 is_periodic() const ;
65
66//-----------------------------------------------------------------------------
67 };
68//-----------------------------------------------------------------------------
69
70 inline EntityType
72 {
73 return EntityType::EDGE ;
74 }
75
76 //-----------------------------------------------------------------------------
77
78 inline size_t
80 {
81 return sizeof( Edge ) + this->array_memory() ;
82 }
83
84//-----------------------------------------------------------------------------
85
86 inline void
88 {
89 mPeriodic = aEdge ;
90 }
91
92 inline Edge *
94 {
95 return mPeriodic ;
96 }
97
98 inline const Edge *
100 {
101 return mPeriodic ;
102 }
103
104 inline bool
106 {
107 return mPeriodic != nullptr ;
108 }
109
110 //-----------------------------------------------------------------------------
111 }
112}
113#endif //BELFEM_CL_EDGE_HPP
Special Edge class for NEDELEC-Type elements.
Definition cl_Edge.hpp:30
bool is_periodic() const
Definition cl_Edge.hpp:105
size_t memory() const
Definition cl_Edge.hpp:79
Edge * periodic()
Definition cl_Edge.hpp:93
Edge()
Definition cl_Edge.cpp:20
EntityType entity_type() const override
returns the type of this vertex
Definition cl_Edge.hpp:71
void set_periodic(Edge *aEdge)
Definition cl_Edge.hpp:87
Vertex()
Definition cl_Vertex.cpp:24
size_t array_memory() const
Definition cl_Vertex.hpp:304
Definition cl_EF_EdgeFunction.hpp:17
USER GUIDES:
Definition cl_Capacitor.cpp:16
EntityType
Definition Mesh_Enums.hpp:116
@ EDGE
Definition Mesh_Enums.hpp:118