(3 of 6)
Although the theory of relativity fit well with the laws that govern electricity and magnetism, it wasn't compatible with Newton's law of gravity. This law said that if you changed the distribution of matter in one region of space, the change in the gravitational field would be felt instantaneously everywhere else in the universe. Not only would this mean you could send signals faster than light (something that was forbidden by relativity), but it also required the Absolute or Universal Time that relativity had abolished in favor of personal or relativistic time.
Einstein was aware of this difficulty in 1907, while he was still at the patent office in Bern, but didn't begin to think seriously about the problem until he was at the German University in Prague in 1911. He realized that there is a close relationship between acceleration and a gravitational field. Someone in a closed box cannot tell whether he is sitting at rest in the earth's gravitational field or being accelerated by a rocket in free space. (This being before the age of Star Trek, Einstein thought of people in elevators rather than spaceships. But you cannot accelerate or fall freely very far in an elevator before disaster strikes.)
If the earth were flat, one could equally well say that the apple fell on Newton's head because of gravity or that Newton's head hit the apple because he and the surface of the earth were accelerating upward. This equivalence between acceleration and gravity didn't seem to work for a round earth, however; people on the other side of the world would have to be accelerating in the opposite direction but staying at a constant distance from us.
On his return to Zurich in 1912 Einstein had a brainstorm. He realized that the equivalence of gravity and acceleration could work if there was some give-and-take in the geometry of reality. What if space-time--an entity Einstein invented to incorporate the three familiar dimensions of space with a fourth dimension, time--was curved, and not flat, as had been assumed? His idea was that mass and energy would warp space-time in some manner yet to be determined. Objects like apples or planets would try to move in straight lines through space-time, but their paths would appear to be bent by a gravitational field because space-time is curved.
With the help of his friend Marcel Grossmann, Einstein studied the theory of curved spaces and surfaces that had been developed by Bernhard Riemann as a piece of abstract mathematics, without any thought that it would be relevant to the real world. In 1913, Einstein and Grossmann wrote a paper in which they put forward the idea that what we think of as gravitational forces are just an expression of the fact that space-time is curved. However, because of a mistake by Einstein (who was quite human and fallible), they weren't able to find the equations that related the curvature of space-time to the mass and energy in it.