diff --git a/cpp/switchchain_canonical_properties.cpp b/cpp/switchchain_canonical_properties.cpp index 33a1de32cbbcc660a8680fda623dacff5318b629..0ef9a6c3cda2474221862e96a7db23c2208ccd09 100644 --- a/cpp/switchchain_canonical_properties.cpp +++ b/cpp/switchchain_canonical_properties.cpp @@ -50,10 +50,17 @@ int main(int argc, char* argv[]) { //const int totalDegreeSamples = 5000; auto getMixingTime = [](int n, float tau) { - return int(50.0f * (50.0f - 30.0f * (tau - 2.0f)) * n); + return int(50.0f * (50.0f - 10.0f * (tau - 2.0f)) * n); + }; + auto getMeasurements = [](int n, float tau) { + (void)n; + (void)tau; + return 10; + }; + auto getMeasureSkip = [](int n, float tau) { + (void)tau; + return n; // Take a sample every ... steps }; - constexpr int measurements = 10; - constexpr int measureSkip = 1000; // Take a sample every ... steps // Output file std::ofstream outfile; @@ -72,7 +79,7 @@ int main(int argc, char* argv[]) { << " step " << numVerticesStep << std::endl; outfile << "tauValues: " << tauValues << std::endl; outfile << "Canonical degree sequence.\n"; - outfile << "mixingTime: 50 * (50 - 30 (tau - 2)) n\n"; + outfile << "mixingTime: 50 * (50 - 10 (tau - 2)) n\n"; outfile << "data:\n"; outfile << "1: {n,tau}\n"; outfile << "2: avgTriangles\n"; @@ -118,12 +125,12 @@ int main(int argc, char* argv[]) { std::array avgAspectrum; std::array avgLspectrum; - auto getSpectralValues = - [](const std::vector &s) -> std::array { - auto l1 = s[s.size() - 1]; - auto l2 = s[s.size() - 2]; - return {l1, l1 - l2, l1 / l2}; - }; + //auto getSpectralValues = + // [](const std::vector &s) -> std::array { + // auto l1 = s[s.size() - 1]; + // auto l2 = s[s.size() - 2]; + // return {l1, l1 - l2, l1 / l2}; + //}; GraphSpectrum gs_start(g); GraphSpectrum gs(chain.g); @@ -139,6 +146,8 @@ int main(int argc, char* argv[]) { int movesDone = 0; avgAspectrum.fill(0); avgLspectrum.fill(0); + int measurements = getMeasurements(numVertices, tau); + int measureSkip = getMeasureSkip(numVertices, tau); for (int i = 0; i < measurements; ++i) { for (int j = 0; j < measureSkip; ++j) if (chain.doMove())