How did the sun wind up in the middle of the solar system? Did the materials, gas and dust that eventually formed the planets come from the sun?

Since our solar system is already formed, we must try to reconstruct its history by studying current star formation in our local neighborhood, the Milky Way galaxy.