How the Andromeda Galaxy Works