Skip to content
Snippets Groups Projects
Commit 6f1ad27a authored by Radek Hušek's avatar Radek Hušek Committed by Radek Hušek
Browse files

Add group Z5

It looks like Petersen graph is Z5-connected...
parent 3a18d05b
No related branches found
No related tags found
No related merge requests found
...@@ -14,6 +14,7 @@ template < typename T_ > struct Name { \ ...@@ -14,6 +14,7 @@ template < typename T_ > struct Name { \
static const T zero = 0; \ static const T zero = 0; \
} }
MakeRing(Z5, 5, (a + b) % 5, (5 - a) % 5, (a * b) % 5, 1);
MakeRing(Z4, 4, (a + b) & 3, (4 - a) & 3, (a * b) & 3, 1); MakeRing(Z4, 4, (a + b) & 3, (4 - a) & 3, (a * b) & 3, 1);
MakeRing(Z2_2, 4, a^b, a, a&b, 3); MakeRing(Z2_2, 4, a^b, a, a&b, 3);
......
...@@ -7,6 +7,8 @@ cdef extern from "group-connectivity.h" namespace "Ring": ...@@ -7,6 +7,8 @@ cdef extern from "group-connectivity.h" namespace "Ring":
pass pass
cdef cppclass Z2_2[T]: cdef cppclass Z2_2[T]:
pass pass
cdef cppclass Z5[T]:
pass
cdef extern from "group-connectivity.h": cdef extern from "group-connectivity.h":
cdef cppclass AbstractTester: cdef cppclass AbstractTester:
...@@ -35,6 +37,8 @@ def testGroupConnectivity(G, group = "Z4", debug = False): ...@@ -35,6 +37,8 @@ def testGroupConnectivity(G, group = "Z4", debug = False):
tester = new Tester[Z4[int]]() tester = new Tester[Z4[int]]()
elif group == "Z2_2": elif group == "Z2_2":
tester = new Tester[Z2_2[int]]() tester = new Tester[Z2_2[int]]()
elif group == "Z5":
tester = new Tester[Z5[int]]()
assert(tester != NULL) assert(tester != NULL)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment