summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xmetastablebin66904 -> 0 bytes
-rw-r--r--metastable.cpp11
2 files changed, 6 insertions, 5 deletions
diff --git a/metastable b/metastable
deleted file mode 100755
index 4a470c4..0000000
--- a/metastable
+++ /dev/null
Binary files differ
diff --git a/metastable.cpp b/metastable.cpp
index bebb96a..5986b97 100644
--- a/metastable.cpp
+++ b/metastable.cpp
@@ -6,6 +6,7 @@
#include <iostream>
#include <sstream>
+#include "pcg-cpp/include/pcg_random.hpp"
#include "randutils/randutils.hpp"
#include "wolff/lib/wolff_models/ising.hpp"
@@ -90,7 +91,7 @@ private:
std::string model_string;
public:
- meas(const system<ising_t, ising_t, graph<>>& S, double H)
+ meas(const wolff::system<ising_t, ising_t, graph<>>& S, double H)
: mag_dist(S.nv + 1, 0), energy_mag_dist(S.nv + 1) {
M = S.nv * S.s[0];
E = S.ne;
@@ -106,7 +107,7 @@ public:
update_distribution_file("e", energy_mag_dist, model_string);
}
- void plain_bond_visited(const system<ising_t, ising_t, graph<>>&,
+ void plain_bond_visited(const wolff::system<ising_t, ising_t, graph<>>&,
const typename graph<>::halfedge&, const ising_t&, double dE) override {
if (dE > 0) {
E -= 2;
@@ -115,12 +116,12 @@ public:
}
}
- void ghost_bond_visited(const system<ising_t, ising_t, graph<>>&, const typename graph<>::vertex&,
+ void ghost_bond_visited(const wolff::system<ising_t, ising_t, graph<>>&, const typename graph<>::vertex&,
const ising_t& s_old, const ising_t& s_new, double dE) override {
M += s_new - s_old;
}
- void post_cluster(unsigned, unsigned, const system<ising_t, ising_t, graph<>>& S) override {
+ void post_cluster(unsigned, unsigned, const wolff::system<ising_t, ising_t, graph<>>& S) override {
mag_dist[(S.nv + M) / 2]++;
energy_mag_dist[(S.nv + M) / 2][(E + S.ne) / 2]++;
}
@@ -168,7 +169,7 @@ int main(int argc, char* argv[]) {
graph<> G(D, L);
// initialize the system
- system<ising_t, ising_t, graph<>> S(G, T, Z, B);
+ wolff::system<ising_t, ising_t, graph<>> S(G, T, Z, B);
randutils::auto_seed_128 seeds;
std::mt19937 rng(seeds);