summaryrefslogtreecommitdiff
path: root/lib/include/graph.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/include/graph.hpp')
-rw-r--r--lib/include/graph.hpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/lib/include/graph.hpp b/lib/include/graph.hpp
new file mode 100644
index 0000000..80cdd66
--- /dev/null
+++ b/lib/include/graph.hpp
@@ -0,0 +1,29 @@
+
+#pragma once
+
+#include <cmath>
+#include <vector>
+#include <array>
+
+class graph {
+ public:
+ typedef struct coordinate {
+ double x;
+ double y;
+ } coordinate;
+
+ typedef struct vertex {
+ coordinate r;
+ } vertex;
+
+ typedef std::array<unsigned int, 2> edge;
+
+ std::vector<vertex> vertices;
+ std::vector<edge> edges;
+
+ std::vector<vertex> dual_vertices;
+ std::vector<edge> dual_edges;
+
+ graph(unsigned int L);
+};
+