We spend a lot of time learning different theories (for instance, theory of differential forms, sobolev spaces, homology groups, distributions). Although (at least most parts of) these theories are very natural and understandable when we read them from books, they are very difficult to create at the first place: it could take tens of years of effort of a large number of excellent mathematicians.
After learning those theories, we do exercises or solve problems, but most of the time, we are just using the tools stated in the book. Even the chance that we come up with a "new" definition ourselves is rare. (By "new", I mean "have not learnt", even if someone else have created it before.) So here is my question:
What are some problems which prompts the creation of a new theory?
EDIT: Just to clarify, I am looking for some problems which give everybody a chance to experience the process of creating new mathematics; so the problem need not be as difficult as Riemann conjecture.
By "new theory", I just mean something that help us formulate the problem in a different way. For example, this video on a chess board puzzle has the idea of creating new theories, because unlike other less interesting puzzles about chess board which can be solved by just carefully counting the squares, this video mentions a new way of looking at the problem, namely the vertices of a hypercube.
I have also seen other similar puzzles like this. Apparently, almost all of them are on discrete mathematics, so it would be really interesting if anyone could provide such a "theory creating" problem in other areas of mathematics (e.g. analysis).
Of course, not all theories are created to tackle specific problems, so other ways of experiencing inventing new maths could also be suggested.
Well, here is my h'penny's worth :
In trying and eventually succeeding in proving Fermat's last Theorem, Andrew Wiles developed vast swaths of new mathematics. (As had others before him even without managing a proof). The problems are all around; The Riemann Hypothesis - with the tantalising "video's" of the zeros in the complex plane - and other "millennium problems" for example. The worthwhile problems tend to not be easy though !
The Millenium Prize problems : https://en.wikipedia.org/wiki/Millennium_Prize_Problems
The Riemnann Hypothesis : https://en.wikipedia.org/wiki/Riemann_hypothesis
Andrew Wiles : https://en.wikipedia.org/wiki/Andrew_Wiles
Kummer Theory : https://en.wikipedia.org/wiki/Kummer_theory
(Thanks for the lead to Kummer Theory, Hagen von Eitzen !)