The sky moved in a regular way. But there were a few irregularities, chief among them the retrograde motion of the planets. The ancient modelers of the cosmos were quite challenged by how to address them. For several reasons, circles were the tool of choice. The heavens were to be thought of as spheres within spheres.
Specifically, the earth was placed at the center and was surrounded my numerous concentric crystalline spheres. The spheres rotated at different rates, along different axes, allowing the sun and planets to move slower than the stars. But this model did an inadequate job of explaining retrograde motion even with many shells (Aristotle’s model, for example, had some 55 spherical shells.
To help deal with the problem of retrograde motion, a new layer of complexity was introduced. The planets would not move simply in a circle but they would rotate on a circle, which in turn, rotated around the sun. The smaller circle is the epicycle and the larger circle is the deferent. Claudius Ptolemaeus (we call him Ptolemy) lived from c. 90 to c. 167. and worked in this system. But even the simple addition of the epicycle was not enough. The epicycle had to rotate around on the deferent not with respect to the center, but uniformly with respect to an off-center point called the equant.
Ptolemy’s model was astoundingly successful inasmuch as it dominated astronomy for over a thousand years. It was the model to which almost all others deferred or sought to improve. But it was a cumbersome and burdensome model which lost accuracy with time. The following simulator shows some of the complexity of the model: Ptolemy’s Model Simulation