refactoring to be able to handle metropolis and simulated annealing later on