Julius O
http://localhost:4000
Julius O >-Thu, 01 Aug 2019 19:50:41 -0400The Area of a Square
http://localhost:4000/2019/07/26/the-area-of-a-square.html
<p>
Here's a funny idea. Suppose someone forgot the formula for the area of a square, known since antiquity to be
</p>
<figure>
\begin{align*}
\Large{ A_{square} }
&= \Large{s \cdot s }\\
&= \Large{s^2.}
\end{align*}
</figure>
<p>
It's ok, we forget things all the time. So without knowing this, let's try to figure this out with calculus. First, let's loosely define a square to be a two-dimensional, four-sided shape with all sides of equal length, whose sides meet at 90-degree (right) angles.
</p>
<p>
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
Figure 1. Plot of a square of sides \(s\), with solid black representative rectangle of height \(s\) and width \(dx\) inscribed in the square, located in the first quadrant of the Cartesian plane, starting from the origin.
</span>
</p>
<figure>
<img class="svgAsset" src="/assets/images/content/joIntegrateSquareArea.svg" alt="joIntegrateSquareArea.svg">
</figure>
<p>
<a href="http://mathworld.wolfram.com/Integral.html"><strong>INTEGRATION</strong></a> will be used to find the <em>area under the curve</em>. In this case, a flat (and rather boring) curve serves as the top boundary of the square, denoted by the solid black line, \(s\). Next, the area must be explicitly defined to include only the region contained inside the square, so the following boundary conditions are imposed:
</p>
<figure>
\begin{align*}
\Large{ 0 \le x \le s },\\
\Large{ 0 \le y \le s }.
\end{align*}
</figure>
<p>
We've restricted the area to be the closed (inclusive of endpoints) interval of \(0\) to \(s\) on both the \(x\) and \(y\)-axes, written compactly as \([0,s]\). The dotted line marks the right-most boundary of the square, closing off the area we want. Now, what's the black strip contained within the square? Let's imagine it to be a plank of <a href="https://en.wikipedia.org/wiki/Allocasuarina_luehmannii">Australian buloke</a> wood flooring inside the square. It has a height \(s\), since it fits perfectly inside the square from top to bottom, and a width \(dx\). All we can say for now is that the plank has an infinitely small width of \(dx\) that can't be given an exact numerical value such as \(0.1\), \(0.01\), or even \(0.0000000001\). Also, the location of the plank highlighted inside Figure 1 is unimportant—it can be placed anywhere inside the bounded area of the square. So while \(dx\) can't be used immediately, it will be a critical component during the problem's construction.
</p>
<p>
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
Figure 2. Similar to Figure 1, but with representative rectangle removed, and replaced with many narrow bands inscribing and filling the square. The bands represent an infinite number of very small areas that are added together to find the whole area of the square. Don't bother counting or measuring the bands. That's not the point!
</span>
</p>
<figure>
<img class="svgAsset" src="/assets/images/content/joIntegrateSquareAreaStrips.svg" alt="joIntegrateSquareAreaStrips.svg">
</figure>
<p>
<span class="newthought">The big idea</span> with integration is that by dividing the area of the curve into infinitely many planks, calculating the area of each plank, and adding them together, you've then computed the total area under the curve. Think of each plank as a "piece of square." Combine and add all the pieces of the square together like a jigsaw puzzle, and you've got the whole square. Likewise, just as a pizza is divided into eight slices with each of your friends getting one slice, they can all be said to have a piece of the pizza. Now if everyone were to combine all the slices together (though highly unlikely), it would again form the whole pizza.
</p>
<figure>
\begin{align*}
\Large{A_{square}}
&= \Large{ \int_0^s s\, dx } && \text{(1)}\\
&= \Large{ s\int_0^s dx } && \text{(2)}\\
&= \Large{ s \cdot [x]_{x=0}^{x=s} } && \text{(3)}\\
&= \Large{ s \cdot ([s] - [0]) } && \text{(4)}\\
&= \Large{ s \cdot s } && \text{(5)}\\
&= \Large{ s^2. } && \text{(6)}
\end{align*}
</figure>
<p>
Alright, time to construct the math. Line 1 sets up the integral that says starting from zero and ending with \(s\) along the \(x\)-axis, calculate each infinitely small plank of the area that has a height \(s\) and width \(dx\).
</p>
<p>
Line 2 is interesting. While \(s\) is a variable, it represents a number, any number you want that's \(\ge 0\). To be constant also means that it remains the same throughout the problem, and <em>does not depend on the \(x\)-axis</em>. Since \(s\) is independent of \(x\), it can be pulled outside of the integral and be used after the integral has been evaluated.
</p>
<p>
For line 3, recall what was said about the piece of square or piece of pizza. If you combined all the pieces of the square or pizza together, you get the whole square and whole pizza, respectively. In the same way, adding up all the pieces of \(dx\) becomes \(\Large{x}\).
</p>
<p>
In line 4, observe that in line 3, \(x\) is assigned a value of \(s\) on the top and \(0\) at the bottom. These are the limits of integration, or the upper and lower bounds of the interval, which is also placed at the ends of the fancy s-shaped integral sign (\(\int\)). Simply plug-in the top value into \(x\), and subtract from it the bottom value after it's been plugged-in for \(x\) as well, leaving a simple subtraction problem with \(s-0=s\).
</p>
<p>
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
While a trivial exercise, it still provides a fundamental understanding of what integration aims to achieve. Break up what you're trying to solve into very small pieces, get an answer for every small piece, then add all the pieces up to get an answer.
</span>
The remaining lines reveal the area of the square to simply be the product of its sides, \(s^{2}\). Thankfully, no surprises there!
</p>
Fri, 26 Jul 2019 13:30:00 -0400
http://localhost:4000/2019/07/26/the-area-of-a-square.html
Proof by Induction for the Sum of Squares Formula
http://localhost:4000/2019/07/11/proof-by-induction-for-the-sum-of-squares-formula.html
<h2>Problem</h2>
<p>
Use induction to prove that
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
Sidenotes here and inside the proof will provide commentary, in addition to numbering each step of the proof-building process for easy reference. They are not part of the proof itself, and must be omitted when written.
</span>
</p>
<figure>
$$\sum_{k=0}^{n} k^{2} = \dfrac{n(n+1)(2n+1)}{6}$$
</figure>
<p>
for all \(n \ge 0\).
</p>
<hr>
<p>NOTE: \(k\) is a placeholder variable representing each number in a series starting from \(0\), and up to and including \(n\). Shove the current value of \(n\) into \(k\), evaluate, and do the same for the next value of \(n\), etc. The "E"-shaped figure is an uppercase Sigma from the Greek alphabet. Because Sigma's spelled with an "s", it's used to represent a <strong>s</strong>ummation, or <strong>s</strong>um. The left-hand side (LHS) reads, <em>"the sum from k equals zero to n of k squared."</em></p>
<hr>
<p>
<strong>1. Basis step</strong>
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
Since the formula claims to work for all numbers greater than or equal to (\(\ge\)) \(0\), \(0\) must be tested on both sides. The series on the LHS states to start at \(0\), square \(0\), and stop. The RHS is simply plug and chug.
</span>
</p>
<p>For \(n=0\), the left-hand side (LHS) yields:</p>
<figure>
$$\sum_{k=0}^{0} k^{2} = 0^{2} = 0.$$
</figure>
<p>And the right-hand side (RHS) yields:</p>
<figure>
$$\dfrac{0(0+1)(2 \cdot 0 + 1)}{6}=0.$$
</figure>
<p>So the equation holds on both sides for \(n=0\).</p>
<p>
<strong>2. Assume the result for \(n\)</strong>.
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
With the Basis step verified in Step 1, we assume the result to be true for \(n\), and restate the original problem.
</span>
</p>
<figure>
$$\sum_{k=0}^{n} k^{2} = \dfrac{n(n+1)(2n+1)}{6}.$$
</figure>
<p>
<strong>3. Prove the result for \((n+1)\)</strong>.
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
<em>"If you can show that the next thing exists in the current thing, then you've proved that the current thing works for all subsequent things."</em>
</span>
</p>
<figure>
\begin{align*}
\sum_{k=0}^{n} k^{2} + (n+1)^{2}
&= \dfrac{(n+1)((n+1)+1)(2(n+1)+1)}{6}\\
&= \dfrac{(n+1)(n+2)(2n+2+1)}{6}\\
&= \dfrac{(n+1)(n+2)(2n+3)}{6}.
\end{align*}
</figure>
<hr>
<p>NOTE: Recall that the sum of squares formula on the LHS starts at \(0\), ends after the n-th value is squared and added, and is supposedly equivalent to the algebra on the RHS. For the LHS and RHS to stay equal to each other, any changes made to one side must also be made to the other side. Adding, subtracting, multiplying, or dividing a number on the LHS, must also be done to the opposite side to preserve equality. Observe the last number in the sum of squares formula is \(n\), the "current thing." Since \(n\) can be any number we want that's \(\ge 0\), what would be the NEXT number after \(n\)?</p>
<p>That number would be \(\mathbf{(n+1)}\), or the "next thing" we'll try to coax out from the "current thing." And since we need to square the next number prior to adding it to the series, we'll have to add \(\mathbf{(n+1)^{2}}\) to both sides of the equation. But instead of tacking on \(\mathbf{(n+1)^{2}}\) to the RHS (we'll do this in the next step, the proof itself) as we did to the LHS, we're going to use the RHS of Step 2, and carefully insert and replace all instances of \(n\) with \(n+1\), and simplify. Since the formula claims to work for all \(n \ge 0\), then it should also work for \(n+1\), the next number after the n-th number. </p>
<p>So the proof in the next step must show that the result is equal to</p>
<figure>
\begin{align*}
\dfrac{(n+1)(n+2)(2n+3)}{6},
\end{align*}
</figure>
<p>or the proof fails.</p>
<hr>
<p>
<strong>4. Proof</strong>
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
Each line must be justified, beginning with the Induction Hypothesis, or what we're trying to prove. The rest is algebra and simplification. Notice in the next to last line of the proof, the result must look the same as what was found in Step 3. If pressed for time on a test and can't factor the cubic polynomial quickly, just go back to Step 3, F.O.I.L. and multiply out the terms on scratchpaper to see if the cubic polynomial is the same as what you got in Step 4. If they're equal, then you've got it, and can finish the proof with writing the cubic polynomial in factored form.
</span>
</p>
<figure>
\begin{align*}
\sum_{k=0}^{n} k^{2} + (n+1)^{2}
&= \dfrac{n(n+1)(2n+1)}{6} + (n+1)^{2} && \text{(Induction Hypothesis)}\\
&= \dfrac{n(n+1)(2n+1)+6(n+1)^{2}}{6} && \text{(Algebra)}\\
&= \dfrac{(n^{2} + n)(2n+1)+6(n+1)(n+1)}{6} && \text{(Algebra)}\\
&= \dfrac{2n^{3} + n^{2} + 2n^{2} + n + 6n^{2} + 12n + 6}{6} && \text{(Algebra)}\\
&= \dfrac{2n^{3} + 9n^{2} + 13n + 6}{6} && \text{(Algebra)}\\
&= \dfrac{(n+1)(n+2)(2n+3)}{6}. && \text{(Algebra)}
\end{align*}
</figure>
<p><strong>5. Conclusion</strong></p>
<p>
This proves the result for \((n+1)\), so the result is true for all \(n \ge 0\) by induction. \(\Box\)
<label for="mn-demo" class="margin-toggle">⊕</label>
<input type="checkbox" id="mn-demo" class="margin-toggle"/>
<span class="marginnote">
The proof is finished with a concluding statement.
</span>
</p>
<hr>
<p>NOTE: Focusing on the algebra, what induction shows is that inserting the "next thing" into the "current thing" of the formula's RHS representation is equivalent to adding the square of the "next thing" to the "current thing." Amazing!</p>
<figure>
$$\dfrac{(n+1)(n+2)(2n+3)}{6} = \dfrac{n(n+1)(2n+1)}{6} + (n+1)^{2}.$$
</figure>
<hr>
Thu, 11 Jul 2019 15:55:00 -0400
http://localhost:4000/2019/07/11/proof-by-induction-for-the-sum-of-squares-formula.html
Induction
http://localhost:4000/2019/07/05/induction.html
<p>Consider the formula for computing the sum of squares:</p>
<figure>
$$\sum_{k=0}^{n} k^{2} = \dfrac{n(n+1)(2n+1)}{6}.$$
</figure>
<p>The formula says there are two ways to find a solution. The conventional way, shown by the left-hand side (LHS) of the equation, says that starting from 0, square 0, then add to it the square of 1, then add to it the square of 2, and continue adding subsequent squares to the series, finally stopping after the n-th number is squared and added. Then just add all the terms in the series together and get an answer.</p>
<p>For example, in calculating the sum of the squares up to and including 10, the LHS method is applied to yield:</p>
<figure>
$$0^{2} + 1^{2} + 2^{2} + 3^{2} + 4^{2} + 5^{2} + 6^{2} + 7^{2} + 8^{2} + 9^{2} + 10^{2} = 385.$$
</figure>
<p>Now the right-hand side (RHS) claims to get the same answer as the LHS simply by substituting the highest term (\(10\) in for \(n\)), and evaluating the expression. With skepticism, substituting and evaluating the RHS yields:</p>
<figure>
$$\dfrac{10(10+1)(2 \cdot 10 + 1)}{6} = \dfrac{10 \cdot 11 \cdot 21}{6} = \dfrac{2310}{6} = 385.$$
</figure>
<p>So while the formula appears to work for a specific example, does it also work with other numbers? Can we be absolutely sure it would work for the first thousand, million, billion, or even trillion square numbers? A reasonable idea would be to keep a continuously expanding (and large and dusty) book of calculations in the library that we could look up to be sure the formula works for a particular example. Just have a computer continuously calculate the sums of the squares using the LHS and RHS methods, and check to see if both sides equal each other. Surely, performing continuous calculations using larger and larger numbers provides more than ample evidence in proving that the formula is true and universal for other numbers!</p>
<p><span class="marginnote">In 1910, mathematicians Alfred North Whitehead and Bertrand Russell published <a href="https://en.wikipedia.org/wiki/Principia_Mathematica"><em>Principia Mathematica</em></a> to build and prove mathematical foundations from first principles. It took nearly 400 pages of symbolic logic to prove that \(1+1=2\).</span>It turns out that in math, <em>specific examples can't be used as proofs</em>. In writing proofs, only variables, symbols, and previously proven ideas such as axioms, corollaries, lemmas, and theorems can be used as building blocks to show the truth or falsity of a statement. So how do we prove this? The good news is we have a powerful tool at our disposal which will rigorously prove and answer this question.</p>
<p>That tool, is <strong><a href="https://en.wikipedia.org/wiki/Mathematical_induction">INDUCTION</a></strong>. And here's my take on what it means:</p>
<blockquote>
<p><em>"If you can show that the next thing exists in the current thing, then you've proved that the current thing works for all subsequent things."</em></p>
</blockquote>
<p>In the next post, we'll see induction in action, and apply it in proving the sum of squares formula.</p>
Fri, 05 Jul 2019 23:41:00 -0400
http://localhost:4000/2019/07/05/induction.html