Ptolemaic system parameters I recently learned about the Ptolemaic system, which seems pretty accurate. There is even a simulator on the Internet: https://astro.unl.edu/naap/ssm/animations/ptolemaic.html
You can see that there are parameters which are used to describe the planets motion and my question is simple:

Given the observations of the sky, how did Ptolemy (and the physicists that came after) adjusted these parameters so that the theory fits the observations ? Is there a method or is it purely by trials and errors? 

Maybe the answer is simple but I'm not a physicist (though mathematically trained) and I was never taught Ptolemaic science!
 A: This issue is highly complex, but basically Ptolemy started from a handful of observations, specially chosen in order to exploit their symmetries and bring out what he was looking for.
For example, to find Saturn's apogee (the direction where a point on Saturn's deferent is farthest from Earth) Ptolemy worked with 3 mean oppositions, that is moments where the position of Saturn is totally opposite to the Mean Sun. That's because according to his theory at that moment the position of the Epicycle Center would coincide with the position of the planet. Using those 3 directions and the number of days elapsed between them, he worked out the value of the Apogee.
If you want to know more, read Olaf Pedersen's "A Survey of the Almagest" where all those procedures are explained in clear detail. What I said about the apogee can be found in page 273 onwards.
A: One way in which Ptolemy adjusted his theory to fit observations was to create epicycles (small loops added to the orbit) to explain the apparent retrograde motion of Mars at a certain point of its orbit around the Earth, as was believed in those days. The real explanation was, of course, the fact that our speedier Earth overtakes Mars so that it appears for a short while that Mars is moving backwards. I sometimes wonder if modern physics has an equivalent of epicycles somewhere, and suggest that quantum mechanics is the best place to look for it.
