def test_SwendsenWang_ClassicalIsing_Sparse_WithEigenImpl(self): #classial ising with Eigen implementation(sparse) system = S.make_classical_ising_Eigen(self.sparse.gen_spin(self.seed_for_spin), self.sparse) #schedulelist schedule_list = U.make_classical_schedule_list(0.1, 100.0, 100, 2000) #anneal A.Algorithm_SwendsenWang_run(system, self.seed_for_mc, schedule_list) #result spin result_spin = R.get_solution(system) #compare self.assertTrue(self.true_groundstate == result_spin)
def test_SingleSpinFlip_ClassicalIsing_Dense_WithEigenImpl(self): #classial ising (dense) system = S.make_classical_ising_Eigen(self.dense.gen_spin(self.seed_for_spin), self.dense) #schedulelist schedule_list = U.make_classical_schedule_list(0.1, 100.0, 100, 100) #anneal A.Algorithm_SingleSpinFlip_run(system, self.seed_for_mc, schedule_list) #result spin result_spin = R.get_solution(system) #compare self.assertTrue(self.true_groundstate == result_spin)