Made basic framework for running the simulation.