Ramanujan’s insights into pi are now guiding scientists toward a deeper understanding of how the universe works.