Adding the nodes and running the simulation