From 4bd62c70ae7bc876b0a73b6339d8bd38276e2dcc Mon Sep 17 00:00:00 2001 From: ellis <eshoag2@illinois.edu> Date: Wed, 1 Mar 2017 22:59:37 -0600 Subject: [PATCH] Added InterPartitionAdjacency class --- meshmode/mesh/__init__.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/meshmode/mesh/__init__.py b/meshmode/mesh/__init__.py index 413b79df..237bc2c4 100644 --- a/meshmode/mesh/__init__.py +++ b/meshmode/mesh/__init__.py @@ -381,6 +381,27 @@ class NodalAdjacency(Record): # }}} +# {{{ partition adjacency + +class InterPartitionAdjacency(): + """ + Describes adjacency information of elements between partitions. + """ + + def __init__(self): + self.elements = [] + self.element_faces = [] + self.neighbors = [] + self.neighbor_faces = [] + + def add_connection(self, elem, face, neighbor, neighbor_face): + self.elements.append(elem) + self.element_faces.append(face) + self.neighbors.append(neighbor) + self.neighbor_faces.append(neighbor_face) + +# }}} + # {{{ facial adjacency -- GitLab