From 901ea3ac042ce56a97b89e5b235405e27e643191 Mon Sep 17 00:00:00 2001
From: Adrian Burri <burriad@dune-project.org>
Date: Fri, 7 Oct 2005 10:07:22 +0000
Subject: [PATCH] Added Dune<->Alu edge mapping on reference face

[[Imported from SVN: r3076]]
---
 grid/alu3dgrid/topology.cc | 15 +++++++++++++++
 grid/alu3dgrid/topology.hh |  5 +++++
 2 files changed, 20 insertions(+)

diff --git a/grid/alu3dgrid/topology.cc b/grid/alu3dgrid/topology.cc
index 801180ea5..0f2a26172 100644
--- a/grid/alu3dgrid/topology.cc
+++ b/grid/alu3dgrid/topology.cc
@@ -114,5 +114,20 @@ namespace Dune {
   const int FaceTopologyMapping<hexa>::
   alu2duneVertex_[EntityCount<hexa>::numVerticesPerFace] = {0, 2, 3, 1};
 
+  template <>
+  const int FaceTopologyMapping<tetra>::
+  dune2aluEdge_[EntityCount<tetra>::numEdgesPerFace] = {1, 2, 0};
+
+  template <>
+  const int FaceTopologyMapping<hexa>::
+  dune2aluEdge_[EntityCount<hexa>::numEdgesPerFace] = {0, 2, 3, 1};
+
+  template <>
+  const int FaceTopologyMapping<tetra>::
+  alu2duneEdge_[EntityCount<tetra>::numEdgesPerFace] = {2, 0, 1};
+
+  template <>
+  const int FaceTopologyMapping<hexa>::
+  alu2duneEdge_[EntityCount<hexa>::numEdgesPerFace] = {0, 3, 1, 2};
 
 } // end namespace Dune
diff --git a/grid/alu3dgrid/topology.hh b/grid/alu3dgrid/topology.hh
index f1acba89e..c6b31d672 100644
--- a/grid/alu3dgrid/topology.hh
+++ b/grid/alu3dgrid/topology.hh
@@ -15,6 +15,7 @@ namespace Dune {
     enum {numFaces = 4};
     enum {numVertices = 4};
     enum {numVerticesPerFace = 3};
+    enum {numEdgesPerFace = 3};
   };
 
   template <>
@@ -22,6 +23,7 @@ namespace Dune {
     enum {numFaces = 6};
     enum {numVertices = 8};
     enum {numVerticesPerFace = 4};
+    enum {numEdgesPerFace = 4};
   };
 
 
@@ -104,6 +106,9 @@ namespace Dune {
   private:
     const static int dune2aluVertex_[EntityCount<type>::numVerticesPerFace];
     const static int alu2duneVertex_[EntityCount<type>::numVerticesPerFace];
+
+    const static int dune2aluEdge_[EntityCount<type>::numEdgesPerFace];
+    const static int alu2duneEdge_[EntityCount<type>::numEdgesPerFace];
   };
 
   inline const ALU3dImplTraits<tetra>::GEOFaceType*
-- 
GitLab