The prevailing astronomical model of the cosmos in Europe in the 1,400 years leading up to the 16th century was the Ptolemaic System, a geocentric model created by the Roman citizen Claudius Ptolemy in his Almagest, dating from about 150 CE. Throughout the Middle Ages it was spoken of as the authoritative text on astronomy, although its author remained a little understood figure frequently mistaken as one of the Ptolemaic rulers of Egypt. The Ptolemaic system drew on many previous theories that viewed Earth as a stationary center of the universe. Stars were embedded in a large outer sphere which rotated relatively rapidly, while the planets dwelt in smaller spheres between—a separate one for each planet. To account for apparent anomalies in this view, such as the apparent retrograde motion of the planets, a system of deferents and epicycles was used. The planet was said to revolve in a small circle (the epicycle) about a center, which itself revolved in a larger circle (the deferent) about a center on or near the Earth.