Fast optimization methods for machine learning, and game-theoretic models of cultural evolution