summaryrefslogtreecommitdiff
path: root/examples/src/models/potts/symmetric.hpp
diff options
context:
space:
mode:
authorJaron Kent-Dobias <jaron@kent-dobias.com>2018-10-17 19:33:25 -0400
committerJaron Kent-Dobias <jaron@kent-dobias.com>2018-10-17 19:33:25 -0400
commitf2f7a072216dfafab89851e4ff3e0b2c3eb16663 (patch)
treef9c7e1e4e91ce8b0ec9cef9f2423029fe7b7f049 /examples/src/models/potts/symmetric.hpp
parent1343a3fe6bd17a2487f12a0d61be8dc83cd722a0 (diff)
downloadc++-f2f7a072216dfafab89851e4ff3e0b2c3eb16663.tar.gz
c++-f2f7a072216dfafab89851e4ff3e0b2c3eb16663.tar.bz2
c++-f2f7a072216dfafab89851e4ff3e0b2c3eb16663.zip
removed a lot of research code to simplify library and examples for publication
Diffstat (limited to 'examples/src/models/potts/symmetric.hpp')
-rw-r--r--examples/src/models/potts/symmetric.hpp52
1 files changed, 0 insertions, 52 deletions
diff --git a/examples/src/models/potts/symmetric.hpp b/examples/src/models/potts/symmetric.hpp
deleted file mode 100644
index bc8673f..0000000
--- a/examples/src/models/potts/symmetric.hpp
+++ /dev/null
@@ -1,52 +0,0 @@
-
-#pragma once
-
-#include <stdlib.h>
-#include <array>
-#include <wolff/types.h>
-#include "potts.hpp"
-
-template <q_t q>
-class symmetric_t : public std::array<q_t, q> {
- public:
-
- symmetric_t() {
- for (q_t i = 0; i < q; i++) {
- (*this)[i] = i;
- }
- }
-
- potts_t<q> act(const potts_t<q> &s) const {
- return potts_t<q>((*this)[s.x]);
- }
-
- symmetric_t<q> act(const symmetric_t<q>& r) const {
- symmetric_t<q> r_rot;
- for (q_t i = 0; i < q; i++) {
- r_rot[i] = (*this)[r[i]];
- }
-
- return r_rot;
- }
-
- potts_t<q> act_inverse(const potts_t<q>& s) const {
- for (q_t i = 0; i < q; i++) {
- if ((*this)[i] == s.x) {
- return potts_t<q>(i);
- }
- }
-
- printf("Your spin wasn't a valid state!", s.x);
- exit(EXIT_FAILURE);
- }
-
- symmetric_t<q> act_inverse(const symmetric_t<q>& r) const {
- symmetric_t<q> r_rot;
- for (q_t i = 0; i < q; i++) {
- r_rot[(*this)[i]] = r[i];
- }
-
- return r_rot;
- }
-};
-