simulate the universe in javascript