In this PhD thesis, I describe work done in the CosmoGrid and AMUSE projects. CosmoGrid is a _CDM N-body simulation containing 8.5 billion dark matter particles within a volume of only (30 Mpc)^3,... Show moreIn this PhD thesis, I describe work done in the CosmoGrid and AMUSE projects. CosmoGrid is a _CDM N-body simulation containing 8.5 billion dark matter particles within a volume of only (30 Mpc)^3, resulting in very high mass resolution. In order to run such a large simulation, we investigate a method of combining multiple supercomputers via a fast network; combining them into one large machine for the final calculation. We compare the results of CosmoGrid to previous _CDM simulations, and use the finalised CosmoGrid data to investigate how an aligned group of galaxies in a void region might have formed. Combining CosmoGrid with the Astrophysical Multipurpose Software Environment (AMUSE), we investigate a method to embed simulated star clusters in a large-scale environment such as a dark matter halo. Finally, we use this method to run self-consistent simulations of open star clusters embedded in a forming Milky Way-like galaxy. Show less