If you can't see the pdf below, please sign in to your SNU email account and then try again. If you don't have an SNU account, try clicking on this link.
Showing posts with label history. Show all posts
Showing posts with label history. Show all posts
Thursday, 1 November 2012
Saturday, 15 September 2012
Brahmagupta's Sine Interpolation
We assume intervals of fixed width $\delta$. We are thus looking at the angles 0, $\delta$, $2\delta$, ..., $i\delta$ ,... Suppose a table is available for the Sines of these angles: $\sin(0)$, $\sin(\delta)$, $\sin(2\delta)$, ..., $\sin(i\delta)$, ... Our task is to estimate the value of $\sin(x)$ when $x$ is not a tabulated angle. Suppose $x$ is between $x_{i-1}=(i-1)\delta$ and $x_i=i\delta$. The total change of the Sine function over this interval is $\sin(x_i)-\sin(x_{i-1})$ and we denote this by $\triangle\sin_i$. If this change were happening linearly then every unit change in the angle would produce a change of
$$\frac{\triangle\sin_i}{\delta}$$ in the Sine function. In moving from $x_{i-1}$ to $x$ we would therefore create a change of
$$\frac{\triangle\sin_i}{\delta}(x-x_{i-1})$$ This gives the following approximation, which is called linear interpolation:
$$\sin(x)-\sin(x_{i-1}) \approx \frac{\triangle\sin_i}{\delta}(x-x_{i-1}) \quad\mbox{or}\quad \sin(x) \approx \sin(x_{i-1}) + \frac{\triangle\sin_i}{\delta}(x-x_{i-1})$$
In linear interpolation we match the function which a straight line which meets it at 2 points: $x_{i-1}$ and $x_i$. Brahmagupta's approach amounts to improving this by matching the function with a quadratic which meets it at 3 points: $x_{i-2}$, $x_{i-1}$ and $x_i$. To derive this formula (and we don't know the steps Brahmagupta took) we start with a form similar to the linear interpolation formula: $$\sin(x)\approx \sin(x_{i-1}) + (x-x_{i-1})p(x)$$ where $p(x)$ is a linear function $Ax+B$. This already does the right thing at $x_{i-1}$. We have to choose $p(x)$ so that it also does the right thing at $x_{i-2}$ and $x_i$. In other words, we need $p(x)$ to satisfy the following: $$\sin(x_{i-2})=\sin(x_{i-1}) + (x_{i-2}-x_{i-1})p(x_{i-2})$$ $$\sin(x_{i})=\sin(x_{i-1}) + (x_{i}-x_{i-1})p(x_{i})$$ These can be rearranged into $$p(x_{i-2}) = \frac{\triangle\sin_{i-1}}{\delta}$$ $$p(x_{i}) = \frac{\triangle\sin_{i}}{\delta}$$
This is again a linear interpolation problem and we have already seen how to solve it: \begin{eqnarray*}
p(x) &=&p(x_{i-2}) + \frac{x-x_{i-2}}{x_i-x_{i-2}}(p(x_i)-p(x_{i-2}))= \frac{\triangle\sin_{i-1}}{\delta}+\frac{x-x_{i-2}}{2\delta}\left(\frac{\triangle\sin_{i}-\triangle\sin_{i-1}}{\delta}\right)\\
&=& \frac{\triangle\sin_{i-1}}{\delta}+\frac{x-x_{i-1}+\delta}{2\delta}\left(\frac{\triangle\sin_{i}-\triangle\sin_{i-1}}{\delta}\right) = \frac{\triangle\sin_i+\triangle\sin_{i-1}}{2\delta}+\frac{x-x_{i-1}}{\delta^2}\left(\frac{\triangle\sin_{i}-\triangle\sin_{i-1}}{2}\right)
\end{eqnarray*}
$$\sin(x) \approx \sin(x_{i-1}) + \frac{x-x_{i-1}}{\delta}\left(\frac{\triangle\sin_i+\triangle\sin_{i-1}}{2}+\frac{x-x_{i-1}}{\delta}\left(\frac{\triangle\sin_{i}-\triangle\sin_{i-1}}{2}\right)\right)$$ Brahmagupta used $\delta=15^o =900'$. So his base trigonometric table needed only five values (ignoring the trivial cases of 0 and 90 degrees). And here are graphs showing the accuracy of his formula between 60 and 75 degrees:
![]() |
| Linear Interpolation |
![]() |
| Brahmagupta's Quadratic Interpolation |
Wednesday, 5 September 2012
A 1400 Year Old Formula for Sine
Bhaskara was an Indian mathematician who lived in the 7th century AD. One of his claims to fame was his commentary Aryabhatiyabhasya, which is our main source for understanding Aryabhata's cryptic verses. Another was a formula describing the Sine function through a rational approximation. In our terminology, measuring angles in radians, his formula becomes:
$$\sin(x) \approx \frac{16x(\pi-x)}{5\pi^2-4x(\pi-x)},\qquad (0\le x\le \frac{\pi}{2})$$
$$\sin(x) \approx \frac{16x(\pi-x)}{5\pi^2-4x(\pi-x)},\qquad (0\le x\le \frac{\pi}{2})$$
In this post, we will take a graphical approach to "discovering" this formula. Of course, we are not claiming Bhaskara thought like this. Perhaps he did not need to, as his skill and judgement in direct computation would have been far beyond ours.
Let's start by looking at the Sine function from 0 to $\pi$ (Again, Bhaskara would have only gone up to $\pi/2$ or 90 degrees.) The graph looks like part of an inverted parabola:
A parabola that is 0 at origin and $\pi$ must have the form $y=Cx(\pi-x)$, for some constant $C$. Now we want the central value of $y$, at $x=\pi/2$, to be 1. The actual value is $C\pi^2/4$ and so we set $C\pi^2/4=1$ and solve to obtain $C=4/\pi^2$. In Bhaskara's time, a popular estimate for $\pi$ was $\sqrt{10}\approx 3.16$. If we substitute that, we get $C=0.4$. We have obtained an estimate
$$\sin(x) \approx 0.4\, x(\pi-x)$$
How good is this? Let's compare the graphs:
Not bad! We could easily be satisfied with this. But Bhaskara was not, so let's take a closer look. There are two ways of testing the closeness of quantities: their difference could be close to zero, or their ratio could be close to 1. Correspondingly, there are two ways of adjusting a quantity so that it becomes closer to another - by shifting or scaling. Let's first look at the difference between $\sin(x)$ and the quadratic approximation:
This kind of shape can be generated by a 4th degree polynomial. But adjusting the coefficients of that polynomial so that it has zeroes and peaks at the right locations calls for quite a bit of fiddling. So let's look at the ratio:
This looks much simpler - a quadratic again! To match this, we need a quadratic that is 1.25 at the ends and 1 in the middle. The following one does the trick:
$$1.25-0.1\,x(\pi-x)$$
keeping in mind that $\pi^2\approx 10$. So we have
$$\frac{0.4\,x(\pi-x)}{\sin(x)} \approx 1.25-0.1\,x(\pi-x)$$
or
$$\sin(x)\approx \frac{0.4\,x(\pi-x)}{1.25-0.1x(\pi-x)} = \frac{16\,x(\pi-x)}{50-4\,x(\pi-x)} \approx \frac{16\,x(\pi-x)}{5\pi^2-4\,x(\pi-x)}$$
Let us ask, one last time, how good is our approximation? And answer again with a graph:
$$1.25-0.1\,x(\pi-x)$$
keeping in mind that $\pi^2\approx 10$. So we have
$$\frac{0.4\,x(\pi-x)}{\sin(x)} \approx 1.25-0.1\,x(\pi-x)$$
or
$$\sin(x)\approx \frac{0.4\,x(\pi-x)}{1.25-0.1x(\pi-x)} = \frac{16\,x(\pi-x)}{50-4\,x(\pi-x)} \approx \frac{16\,x(\pi-x)}{5\pi^2-4\,x(\pi-x)}$$
Let us ask, one last time, how good is our approximation? And answer again with a graph:
The red and blue curves representing the two functions overlap too perfectly for the eye to distinguish them.
Saturday, 1 September 2012
Wednesday, 15 August 2012
CCC 101 - Mesopotamia & Indus Valley
Notes for Lecture 3 and parts of Lecture 4: Mesopotamia and Indus Civilizations.
(If you can't view, log out from any Google accounts and refresh.)
(If you can't view, log out from any Google accounts and refresh.)
Sunday, 12 August 2012
CCC 101 - Course Intro & Ancient Egypt
- Lecture 1 - Course Introduction
- Lecture 2 - Ancient Egypt
Saturday, 21 July 2012
CCC 101 - Mathematics in India
Syllabus
for CCC 101 – Mathematics in India
Credits
(Lec:Tut:Lab) =
1.5:0:0 (3 lectures weekly over a half-semester)
Prerequisites:
None
Overview:
Mathematics
had a rich history in ancient and medieval India. Indian
mathematicians made original contributions to algebra, number theory
and geometry; while the Kerala school made fundamental discoveries
related to differential calculus and infinite series two centuries
before their full development by Newton and Leibniz. This course will
provide an overview of the story of mathematics in India, and also
incorporate the social context and the connections with other
civilizations.
Detailed
Syllabus: Issues
of dating, translation and interpretation; prehistory; the ancient
civilizations of Egypt, Iraq, China and America; Indus Valley
Civilization; Mathematics in the Vedas and Puranas; Pythagoras
theorem; Applications to grammar, logic, astronomy and technology;
Medieval mathematicians and schools of mathematics; Universities;
Invention of Zero; Trigonometry; Rates of change; π; Connections
with Greece, China and the Arabs; The Kerala school.
Assessment:
- Assignments20%Class Performance10%Term Paper40%Presentation30%
References:
- Mathematics in India by Kim Plofker, Princeton University Press.
- Studies in the History of Indian Mathematics by C S Seshadri (ed.), Hindustan Book Agency.
- Contributions to the History of Indian Mathematics by Gerard G Emch et al (ed.), Hindustan Book Agency.
- History of Mathematics by Carl B Boyer and Uta C Merzbach, Wiley.
Subscribe to:
Posts (Atom)

