# NavList:

## A Community Devoted to the Preservation and Practice of Celestial Navigation and Other Methods of Traditional Wayfinding

**Re: First sine table (Ptolemy)**

**From:**George Huxtable

**Date:**2009 Jan 24, 11:54 -0000

Frank gave a recipe for generating sine and cosines (copied below), starting with an approximation for sine and cos of 1�, which give me, from a calculator, starting values of .01745329252 and .9938476797, respectively. I wondered how accurate that recipe might be, when compared with the predictions for sines implicit in Ptolemy's table of chords, as decribed in my posting [7137], which dated back to around 150 AD, and laid out in detail at- www.cs.xu.edu/math/math147/02f/ptolemy/ptolemytext.html . I have used Frank's recipe to calculate sin 2� and cos 2�, and then reiterated to obtain, from those, a value for sin 4� by the same method, which has given- sin 4�=.06976001. Compare this with the true value of- sin 4�=.06975647 and with Ptolemy's value, implicit in chord of arc 8�- sin 4�=.06975694. The error in Ptolemy's value is much less, and I suggest that this was not just a numerical fluke. Unless I've made an error, which is always possible, it shows that over 1800 years ago, there already existed a method that was more precise than what Frank is suggesting, though the knowledge became lost. To increase the precision, Frank might (as he suggested) have to reduce his starting value below 1�, which would then have entailed even more iterations, each of which would have to be carried out to high precision and without arithmetical errors, using long-arithmetic without benefit of calculators. Of course, Ptolemy had to perform similar tasks, without even the benefit of modern decimal arithmetic. George. contact George Huxtable, at george{at}hux.me.uk or at +44 1865 820222 (from UK, 01865 820222) or at 1 Sandy Lane, Southmoor, Abingdon, Oxon OX13 5HX, UK. ================================== ----- Original Message ----- From:To: Sent: Saturday, January 24, 2009 7:23 AM Subject: [NavList 7149] Re: First sine table (Ptolemy) Jim, you asked: "Were infinite series used in the initial creation of tables?" No, not the early tables. One way to generate tables is to use the trigonometric identities for sums and differences of angles. Consider this: we know some exact values, e.g. sine and cosine of 0�, 30�, 45�, 60�, 90�. If you have arbitrarily good values for the square root of two and the square root of three, then you have arbitrarily good values for the trig functions of those angles. Now we can also calculate the sine of one degree to fairly good accuracy using a variety of methods (see below). That's our anchor. And the cosine of one degree is sqrt(1-sin^2(1)) so we calculate that one by hand as accurately as possible. Then how do we get the sine and cosine of 2 degrees? Use the identities: sin(a+b) = sin(a)*cos(b) + sin(b)*cos(a), cos(a+b) = cos(a)*cos(b) - sin(a)*sin(b), which in this case would be sin(2�) = sin(1�)*cos(1�) + sin(1�)*cos(1�), cos(2�) = cos(1�)*cos(1�) - sin(1�)*sin(1�). And then the sine and cosine of 3 degrees? Just build on the previous result: sin(3�) = sin(2�)*cos(1�) + sin(1�)*cos(2�), cos(3�) = cos(2�)*cos(1�) - sin(2�)*sin(1�). And so on... And note that you really only need to calculate from 0 to 45 degrees. After that, you just re-label the table using sin(x) = cos(90-x) etc. Next we look up all of these values in our table of logarithms (let's assume someone has already provided us with that) and then we can get a table of tangents rather quickly from tan(a) = inverselog[logsin(a)-logcos(a)]. These are the general sorts of calculations that were used. There are lots of tricks for speeding things up and reducing error. For example, we can get exact values for the sine and cosine of 15 degrees using half-angle identities. And from there, the sine/cosine of 7.5 degrees. Then going back to the sum identities, we get "exact" values for any angle that is a multiple of 7.5 degrees. Finally, up at the top I mentioned that we need the sine of 1 degree. At some level of accuracy the sine of a small angle is equal to the arc. That is, sin(x degrees) = x*pi/180, for a small angle. For a low accuracy table, you could assume that this holds for x=1�. For a higher accuracy table, you would assume that this holds for x=1'. Then you build up arcminute by arcminute until you get a better value for the sine of 1 degree and proceed again as above. -FER --~--~---------~--~----~------------~-------~--~----~ Navigation List archive: www.fer3.com/arc To post, email NavList@fer3.com To unsubscribe, email NavList-unsubscribe@fer3.com -~----------~----~----~----~------~----~------~--~---