Fi & Lu Area Algebra Trigonometry Functions Complex Numbers Calculus
Fi liked the pretty curves that she saw when tackling trigonometry. She imagined skiing on those curves, speeding up on the downslopes and slowing down on the upslopes. Lu realized that the steepness of the slopes could be measured by looking at nearby points. Mom said that this was called differentiation. “You can draw a tangent to the curve at a point—a straight line that just touches the curve at that point. The slope of that tangent is just how much it goes up for each unit it goes forward. You can approximate the tangent by taking two points on the curve very close to each other and drawing a line between them. As the two points get closer together, they provide a better approximation to the tangent. (Click the plot below.)
“For a function \(f(x)\), we can define the derivative of \(f(x)\) with respect to \(x\), the function that gives the slope of the tangent to \(f(x)\) at each point \(x\), as \[\frac{df(x)}{dx} = \lim_{\delta\rightarrow 0} \frac{f(x+\delta)-f(x)}{\delta}\] “This is a standard notation for derivative, but it’s a bit strange. The \(d\) should not be considered as a separate entity, but as paired with the thing that follows it. And that’s why the derivative of a derivative, called the second derivative is written as \[\frac{d^2f(x)}{dx^2}\] “It’s not much of a stretch to see that \[f(x+\delta) = f(x) + \frac{df(x)}{dx}\delta + o(\delta)\] where \(o(\delta)\) means some function \(h\) such that \[\lim_{\delta\rightarrow 0}\frac{h(\delta)}{\delta} = 0\] “From these definitions, we can deduce some properties of derivatives: \begin{align*}\frac{d(f(x)+g(x))}{dx} &= \lim_{\delta\rightarrow 0} \frac{f(x+\delta)+g(x+\delta)-f(x)-g(x)}{\delta} \\ &= \lim_{\delta\rightarrow 0} \frac{f(x+\delta)-f(x)}{\delta} + \lim_{\delta\rightarrow 0} \frac{g(x+\delta)-g(x)}{\delta}\\ &= \frac{df(x)}{dx} + \frac{dg(x)}{dx}\end{align*} \begin{align*}\frac{d(f(x)g(x))}{dx} &= \lim_{\delta\rightarrow 0} \frac{f(x+\delta)g(x+\delta)-f(x)g(x)}{\delta} \\ &= \lim_{\delta\rightarrow 0} \frac{(f(x)+\frac{df(x)}{dx}\delta+o(\delta))(g(x)+\frac{dg(x)}{dx}\delta+o(\delta))-f(x)g(x)}{\delta} \\ &= \lim_{\delta\rightarrow 0}\frac{f(x)g(x)+f(x)\frac{dg(x)}{dx}\delta+\frac{df(x)}{dx}g(x)\delta+o(\delta)-f(x)g(x)}{\delta} \\ &= f(x)\frac{dg(x)}{dx}+\frac{df(x)}{dx}g(x)\end{align*} \begin{align*}\frac{d(f(g(x))}{dx} &= \lim_{\delta\rightarrow 0} \frac{f(g(x+\delta))-f(g(x))}{\delta} \\ &= \lim_{\delta\rightarrow 0} \frac{(f(g(x)+\frac{dg(x)}{dx}\delta+o(\delta))-f(g(x))}{\delta} \\ &= \lim_{\delta\rightarrow 0}\frac{f(g(x))+\frac{df(g(x))}{dg(x)}\left(\frac{dg(x)}{dx}\delta+o(\delta)\right)-f(g(x))}{\delta} \\ &= \frac{df(g(x))}{dg(x)}\frac{dg(x)}{dx}\end{align*} ”Let’s tackle a few examples. When we talked about polynomials, we defined the derivative and said that the definition would make sense when we covered calculus. Well, \[d(x^n)/dx = \lim_{\delta\rightarrow 0} \frac{(x+\delta)^n-x^n}{\delta} = \frac{x^n + n\delta x^{n-1} + o(\delta) - x^n}{\delta} = nx^{n-1}\] “Another example that comes to mind is \(b^x\). \[\frac{d(b^x)}{dx} = \lim_{\delta\rightarrow 0} \frac{b^{x+\delta}-b^x}{\delta} = \lim_{\delta\rightarrow 0} \frac{b^x (b^\delta-1)}{\delta} = b^x \lim_{\delta\rightarrow 0} \frac{b^\delta-1}{\delta}\] “But what is that last limit? There’s some \(b\) for which that limit is 1; let’s call that number \(e\). We’ll write \(\ln\) for \(\log_e\) and call \(\ln\) the natural logarithm, and say that \(e\) is the base of natural logarithms. Then we have \[\frac{d(e^x)}{dx} = e^x\] and so \[\frac{d(b^x)}{dx} = \frac{d(e^{x\ln b})}{dx} = \frac{d(e^{x\ln b})}{d(x\ln b)} \frac{d(x\ln b)}{dx} = e^{x\ln b} \ln b = b^x \ln b\] “A question that comes to mind is what is the derivative of \(\ln x\)? Well \[ 1 = \frac{dx}{dx} = \frac{d(e^{\ln x})}{dx} = \frac{d(e^{\ln x})}{d(\ln x)}\frac{d(\ln x)}{dx} = e^{\ln x}\frac{d(\ln x)}{dx} = x \frac{d(\ln x)}{dx}\] so \[\frac{d(\ln x)}{dx} = \frac{1}{x}\] “As another example, we can use our knowledge of trigonometry to compute the derivative of \(\sin x\): \begin{align*}\frac{d(\sin x)}{dx} &= \lim_{\delta\rightarrow 0} \frac{\sin(x+\delta)-\sin x}{\delta} \\ &= \lim_{\delta\rightarrow 0} \frac{\sin x \cos\delta + \cos x \sin\delta-\sin x}{\delta} \\ &= \lim_{\delta\rightarrow 0} \frac{\cos x \sin\delta-(1-\cos\delta)\sin x}{\delta}\end{align*} “We can notice that \(1-\cos\delta = (1-cos^2\delta)/(1+\cos\delta) = \sin^2\delta/(1+\cos\delta)\). We know that \(\sin 0 = 0\) and \(\cos 0 = 1\), while \(\lim_{\delta\rightarrow 0} \frac{\sin\delta}{\delta} = 1\), so we see that \begin{align*}\frac{d(\sin x)}{dx} &= \lim_{\delta\rightarrow 0} \frac{\cos x \sin\delta-(1-\cos\delta)\sin x}{\delta} \\ &= \lim_{\delta\rightarrow 0} \frac{\cos x \sin\delta-\frac{\sin^2\delta}{1+\cos\delta}\sin x}{\delta} \\ &= \left(\cos x - \frac{\sin 0}{1+\cos 0} \sin x\right) \lim_{\delta\rightarrow 0} \frac{\sin\delta}{\delta} \\ &= \cos x\end{align*} “We can then easily compute the derivative of \(\cos x\): \[\frac{d(\cos x)}{dx} = \frac{d(\sin(\frac{\pi}{2}-x))}{dx} = \frac{d(\sin(\frac{\pi}{2}-x))}{d(\frac{\pi}{2}-x)}\frac{d(\frac{\pi}{2}-x)}{dx} = \cos(\frac{\pi}{2}-x)(-1) = -\sin x\] “And now we can compute the derivative of \(\tan x\): \[\frac{d(\tan x)}{dx} = \frac{d((\sin x) (\cos x)^{-1})}{dx} = (\cos x) (\cos x)^{-1} + (\sin x) (-(\cos x)^{-2}) (-\sin x) = 1 + \tan^2 x\] “And this allows us to compute the derivative of the inverse of \(\tan x\), called \(\arctan x\), the angle whose tangent is \(x\): \[1 = \frac{dx}{dx} = \frac{d(\tan(\arctan x))}{dx} = (1+(\tan(\arctan x))^2)\frac{d(\arctan x)}{dx} = (1+x^2)\frac{d(\arctan x)}{dx}\] so \[\frac{d(\arctan x)}{dx} = \frac{1}{1+x^2}\]
“We can do the same thing for \(\arctan x\), but it’s actually easier to first expand \(\frac{1}{1+x^2}\) as a power series by direct division and then ask what that’s the derivative of: \[\frac{1}{1+x^2} = \sum_{n=0}^\infty (-1)^n x^{2n}\] \[\arctan x = \sum_{n=0}^\infty (-1)^n \frac{x^{2n+1}}{2n+1}\] “Just as with \(\ln (1-x)\), this can’t work for \(|x|>1\), as the sum diverges. But for \(x=1\), it gives a series for \(\frac{\pi}{4}\). Sadly, this converges very slowly, but the tangent addition formula can be used to find faster formulas using arctan. In 1706, John Machin used \(\frac{\pi}{4} = 4\arctan\frac{1}{5} - \arctan\frac{1}{239}\) to calculate a hundred digits of \(\pi\). Of course, now we have computers as well as much faster algorithms.”
Logarithms and exponentiation are opposites. \(\log_b x\) is the exponent that base \(b\) has to be raised to to get \(x\): \(b^{\log_b x}=x\). Of course that also means that \(\log_b b^x = x\).
Since \(b^c b^d = b^{c+d}\), multiplying two numbers is equivalent to adding their logarithms: \(xy =b^{\log_b x}b^{\log_b y} = b^{\log_b x + \log_b y}\), so \(\log_b xy = \log_b x + \log_b y\). And since \(b^{cd} = (b^c)^d\), we can see, by raising \(a\) to each side, that \(\log_a b\ \log_b c = \log_a c\).
The natural base for logarithms is \(e\), sometimes called Euler’s number. Using \(\log\) without specifying the base can sometimes mean the base is ten (“common logarithm”) and sometimes mean the base is \(e\) (“natural logarithm”), and occasionally even that the base is two. So, as is quite common, we use \(\ln\) to mean \(\log_e\).