\chapter{Polar coordinates and complex numbers} The rectangular coordinate system is immensely useful, but it is not the only way to assign an address to a point in the plane and sometimes it is not the most useful. In applications to physical problems where there is some ``cylindrical symmetry'', such as a vibrating drum or water moving along a pipe, the most natural coordinates are often polar coordinates rather than rectangular coordinates. In many experimental situations, our location is fixed and we, using sonar or radar, take readings in different directions (Figure \ref{fig:9-1-2}); this information can be graphed using rectangular coordinates (e.g., with the angle on the horizontal axis and the measurement on the vertical axis). \begin{figure}[h!] \begin{minipage}{\textwidth} \begin{center} \vspace{1.0 cm} \includegraphics[height=4cm,width=13cm]{graphs/fig9-1-1.eps} \end{center} \end{minipage} \caption{Sonar and radar use polar coordinates.} \label{fig:9-1-1} \end{figure} \newpage \noindent Sometimes, however, it is more useful to plot the information in a way similar to the way in which it was collected, as magnitudes along radial lines (Figure \ref{fig:9-1-2}). This system is called the Polar Coordinate System. \begin{figure}[h!] \begin{minipage}{\textwidth} \begin{center} %\vspace{1.0 cm} \includegraphics[height=4cm,width=5cm]{graphs/fig9-1-2.eps} \end{center} \end{minipage} \caption{Polar coordinates.} \label{fig:9-1-2} \end{figure} \begin{example} \label{ex:polar1} SOS! You've just received a distress signal from a ship located at A on your radar screen (Figure \ref{fig:9-1-3}). Describe its location to your captain so your vessel can speed to the rescue. \begin{figure}[h!] \begin{minipage}{\textwidth} \begin{center} %\vspace{1.0 cm} \includegraphics[height=5cm,width=10cm]{graphs/fig9-1-3.eps} \end{center} \end{minipage} \caption{Polar coordinate figure for Example \ref{ex:polar1}.} \label{fig:9-1-3} \end{figure} Solution: You could convert the relative location of the other ship to rectangular coordinates and then tell your captain to go due east for 7.5 miles and north for 13 miles, but that certainly is not the quickest way to reach the other ship. It is better to tell the captain to sail for 15 miles in the direction of $60^o$. If the distressed ship was at B on the radar screen, your vessel should sail for 10 miles in the direction $150^o$. (Real radar screens have $0^o$ at the top of the screen, but the convention in mathematics is to put $0^o$ in the direction of the positive $x$--axis and to measure positive angles counterclockwise from there. And of course a real sailor speaks of ``bearing'' and ``range'' instead of direction and magnitude.) \end{example} \begin{practice} Describe the locations of the ships at C and D in Figure \ref{fig:9-1-3} by giving a distance and a direction to those ships from your current position at the center of the radar screen. \end{practice} {\it Points in Polar Coordinates}: To construct a polar coordinate system we need a starting point (called the origin or pole) for the magnitude measurements and a starting direction (called the polar axis) for the angle measurements. A {\bf polar coordinate pair} for a point $P$ in the plane is an ordered pair $(r,\theta)$, where $r$ is the directed distance along a radial line from $O$ to $P$, and $\theta$ is the angle formed by the polar axis and the segment $OP$. The angle $\theta$ is positive when the angle of the radial line $OP$ is measured counterclockwise from the polar axis, and $\theta$ is negative when measured clockwise. {\it Degree or Radian Measure for $\theta$?}: Either degree or radian measure can be used for the angle in the polar coordinate system, but when we differentiate and integrate trigonometric functions of $\theta$ we will {\it always} want all of the angles to be given in {\it radian measure}. From now on, we will primarily use radian measure. {\it You should assume that all angles are given in radian measure unless the units ``$\, ^o$'' (``degrees'') are shown.} In the rectangular coordinate system, the derivative $dy/dx$ measured both the rate of change of $y$ with respect to $x$ and the slope of the tangent line. In the polar coordinate system $dr/d\theta$ measures the rate of change of $r$ with respect to $\theta$. The sign of $dr/d\theta$ tells us whether $r$ is increasing or decreasing as $\theta$ increases. \begin{figure}[h!] \begin{minipage}{\textwidth} \begin{center} %\vspace{1.0 cm} \includegraphics[height=4cm,width=6cm]{graphs/fig9-2-1.eps} \end{center} \end{minipage} \caption{$r$ changing as a function of $\theta$.} \label{fig:9-2-1} \end{figure} \section{Polar Coordinates} Rectangular coordinates allow us to describe a point $(x,y)$ in the plane in a different way, namely $$ (x,y) \leftrightarrow (r, \theta), $$ where $r$ is any real number and $\theta$ is an angle. Polar coordinates are extremely useful, especially when thinking about complex numbers. Note, however, that the $(r,\theta)$ representation of a point is very non-unique. First, $\theta$ is not determined by the point. You could add $2\pi$ to it and get the same point: $$\left(2,\frac{\pi}{4}\right)= \left(2,\frac{9\pi}{4}\right) = \left(2,\frac{\pi}{4}+389\cdot 2\pi\right). = \left(2,\frac{-7\pi}{4}\right) $$ Also that $r$ can be negative introduces further non-uniqueness: $$ \left(1, \frac{\pi}{2}\right) = \left(-1, \frac{3\pi}{2}\right). $$ Think about this as follows: facing in the direction $3\pi/2$ and backing up 1 meter gets you to the same point as looking in the direction $\pi/2$ and walking forward 1 meter. We can convert back and forth between cartesian and polar coordinates using that \begin{align}\label{eqn:polar1} x&=r\cos(\theta)\\ y&=r\sin(\theta), \end{align} and in the other direction \begin{align}\label{eqn:polar2} r^2&=x^2 + y^2\\ \tan(\theta)&=\frac{y}{x} \end{align} (Thus $r = \pm \sqrt{x^2+y^2}$ and $\theta = \tan^{-1}(y/x).$) \begin{figure}[h!] \begin{minipage}{\textwidth} \begin{center} \vspace{1.0 cm} \includegraphics[height=4cm,width=13cm]{graphs/fig9-1-19.eps} \end{center} \end{minipage} \caption{Rectangular to polar coordinate conversion.} \label{fig:9-1-19} \end{figure} \begin{example} Sketch $r=\sin(\theta)$, which is a circle sitting on top the $x$ axis. \begin{figure}[h!] \begin{minipage}{\textwidth} \begin{center} %\vspace{-1.0 cm} \begin{tabular}{cc} \includegraphics[height=5cm,width=6cm]{graphs/sage-polar1.eps} & \includegraphics[height=5cm,width=6cm]{graphs/sage-polar2.eps} \\ \end{tabular} \end{center} \end{minipage} \caption{Plot of (a) $r=1$, $0<\theta<\pi/6$, and (b) $r=\sin(\theta)$, $0<\theta<2\pi$.} \label{fig:sage-polar1} \end{figure} We plug in points for one period of the function we are graphing---in this case $[0,2\pi]$: \begin{center} \begin{tabular}{|l|l|}\hline 0 & $\sin(0) = 0$\\ $\pi/6$ & $\sin(\pi/6) = 1/2$\\ $\pi/4$& $\sin(\pi/4) =\frac{\sqrt{2}}{2}$\\ $\pi/2$ & $\sin(\pi/2) = 1$\\ $3\pi/4$ & $\sin(3\pi/4) = \frac{\sqrt{2}}{2}$\\ $\pi$ & $\sin(\pi) = 0$\\ $\pi + \pi/6$ & $\sin(\pi+\pi/6) = -1/2$\\\hline \end{tabular} \end{center} Notice it is nice to allow $r$ to be negative, so we don't have to restrict the input. BUT it is really painful to draw this graph by hand. To more accurately draw the graph, let's try converting the equation to one involving polar coordinates. This is easier if we multiply both sides by $r$: $$ r^2 = r\sin(\theta). $$ Note that the new equation has the extra solution $(r=0,\theta=\text{anything})$, so we have to be careful not to include this point. Now convert to cartesian coordinates using (\ref{eqn:polar1}) to obtain (\ref{eqn:polar2}): \begin{equation} \label{eqn:polar3} x^2 + y^2 = y. \end{equation} The graph of (\ref{eqn:polar3}) is the same as that of $r=\sin(\theta)$. To confirm this we complete the square: \begin{align*} x^2 + y^2 &= y\\ x^2 + y^2 - y &= 0\\ x^2 + (y-1/2)^2 &= 1/4\\ \end{align*} Thus the graph of (\ref{eqn:polar3}) is a circle of radius $1/2$ centered at $(0,1/2)$. \end{example} Actually {\em any} polar graph\index{polar graph} of the form $r=a\sin(\theta) +b\cos(\theta)$ is a circle (exercise for the interested reader). \section{Areas in Polar Coordinates} The previous section introduced the polar coordinate system and discussed how to plot points, how to create graphs of functions (from data, a rectangular graph, or a formula), and how to convert back and forth between the polar and rectangular coordinate systems. This section examines calculus in polar coordinates: rates of changes, slopes of tangent lines, areas, and lengths of curves. The results we obtain may look different, but they all follow from the approaches used in the rectangular coordinate system. We know how to compute the area of a sector, i.e., piece of a circle with angle $\theta$. [[draw picture]]. This is the basic polar region. The area is $$ A = \text{(fraction of the circle)}\cdot \text{(area of circle)} = \left(\frac{\theta}{2\pi}\right) \cdot \pi r^2 = \frac{1}{2} r^2 \theta. $$ We now imitate what we did before with Riemann sums. We chop up, approximate, and take a limit. Break the interval of angles from $a$ to $b$ into $n$ subintervals. Choose $\theta_i^*$ in each interval. The area of each slice is approximately $(1/2) f(\theta_i^*)^2 \theta_i^2$. Thus $$ A = \text{Area of the shaded region} \sim \sum_{i=1}^n \frac{1}{2} f(\theta_i^*)^2 \Delta(\theta). $$ Taking the limit, we see that $$ A = \lim_{n\to\infty} \sum_{i=1}^n \frac{1}{2} f(\theta_i^*)^2 \Delta(\theta) = \frac{1}{2} \cdot \int_{a}^{b} f(\theta)^2 d\theta. $$ Amazing! By understanding the definition of Riemann sum, we've derived a formula for areas swept out by a polar graph. But does it work in practice? \begin{example} Find the area enclosed by one leaf of the four-leaved rose $r=\cos(2\theta)$. %\figtwo{Graph of $y=\cos(2x)$ and $r=\cos(2\theta)$}% %{example_4rosecos}{example_4rose} %sage: gnuplot.plot('set polar; plot [0:2*pi] cos(2*t)', 'example_4rose') %sage: gnuplot.plot('plot [0:2*pi] cos(2*x)', 'example_4rosecos') \begin{figure}[h!] \begin{minipage}{\textwidth} \begin{center} %\vspace{1.0 cm} \includegraphics[height=4cm,width=12cm]{graphs/sage-polar4.eps} \end{center} \end{minipage} \caption{Graph of $y=\cos(2x)$ and $r=\cos(2\theta)$.} \label{fig:polar4} \end{figure} This was plotted in \sage using these commands: \vskip .1in \begin{Verbatim}[fontsize=\scriptsize,fontfamily=courier,fontshape=tt,frame=single,label=\sage] sage: P1 = polar_plot(lambda x:cos(2*x), 0, 2*pi, rgbcolor=(0,0,1)) sage: P2 = plot(lambda x:cos(2*x), 0, 2*pi, rgbcolor=(1,0,0),linestyle=":") sage: show(P1+P2) \end{Verbatim} \vskip .1in \noindent To find the area using the methods we know so far, we would need to find a function $y=f(x)$ that gives the ``height'' of the leaf. Multiplying both sides of the equation $r=\cos(2\theta)$ by $r$ yields $$ r^2 = r\cos(2\theta) = r(\cos^2 \theta - \sin^2 \theta) = \frac{1}{r}((r\cos\theta)^2 - (r\sin\theta)^2). $$ Because $r^2 = x^2 + y^2$ and $x=r\cos(\theta)$ and $y=r\sin(\theta)$, we have $$ x^2 + y^2 = \frac{1}{\sqrt{x^2+y^2}} (x^2 - y^2). $$ Solving for $y$ is a crazy mess, and then integrating? It seems impossible! But it isn't... if we remember the basic idea of calculus: subdivide and take a limit. We need the boundaries of integration. Start at $\theta=-\pi/4$ and go to $\theta=\pi/4$. As a check, note that $\cos((-\pi/4) \cdot 2) = 0 = \cos((\pi/4) \cdot 2).$ We evaluate \begin{align*} \frac{1}{2} \cdot \int_{-\pi/4}^{\pi/4} \cos(2\theta)^2 d\theta &= \int_{0}^{\pi/4} \cos(2\theta)^2 d\theta \qquad \text{(even function)}\\ &= \frac{1}{2} \int_{0}^{\pi/4} (1+\cos(4\theta)) d\theta \\ &= \frac{1}{2} \left[ \theta + \frac{1}{4}\cdot \sin(4\theta)\right]_{0}^{\pi/4} \\ &= \frac{\pi}{8}. \end{align*} We used that \begin{equation} \label{eqn:costwosintwo} \cos^2(x) = (1+\cos(2x))/2 \qquad\text{and}\qquad \sin^2(x) = (1-\sin(2x))/2, \end{equation} which follow from $$\cos(2x) = \cos^2(x) - \sin^2(x) = 2\cos^2(x) - 1 = 1-2\sin^2(x).$$ \end{example}